Debian Codegraph @

configure

raw
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by Autoconf 2.52.20260412.
4 #
5 # Copyright 2003-2025,2026 Thomas E. Dickey
6 # Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
7 # Free Software Foundation, Inc.
8 # This configure script is free software; the Free Software Foundation
9 # gives unlimited permission to copy, distribute and modify it.
10
11 # Avoid depending upon Character Ranges.
12 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
13 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
14 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
15 as_cr_digits='0123456789'
16 as_cr_alnum=$as_cr_Letters$as_cr_digits
17
18 # Sed expression to map a string onto a valid variable name.
19 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
20
21 # Sed expression to map a string onto a valid CPP name.
22 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
23
24 # Be Bourne compatible
25 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
26 emulate sh
27 NULLCMD=:
28 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
29 set -o posix
30 fi
31
32 # Name of the executable.
33 as_me=`echo "$0" |sed 's,.*[\\/],,'`
34
35 if expr a : '\(a\)' >/dev/null 2>&1; then
36 as_expr="expr"
37 else
38 as_expr="false"
39 fi
40
41 rm -f conf$$ conf$$.exe conf$$.file
42 echo >conf$$.file
43 if ln -s conf$$.file conf$$ 2>/dev/null; then
44 # We could just check for DJGPP; but this test a) works b) is more generic
45 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
46 if test -f conf$$.exe; then
47 # Don't use ln at all; we don't have any links
48 as_ln_s='cp -p'
49 else
50 as_ln_s='ln -s'
51 fi
52 elif ln conf$$.file conf$$ 2>/dev/null; then
53 as_ln_s='ln'
54 else
55 as_ln_s='cp -p'
56 fi
57 rm -f conf$$ conf$$.exe conf$$.file
58
59 as_executable_p="test -f"
60
61 # Support unset when possible.
62 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
63 as_unset="unset"
64 else
65 as_unset="false"
66 fi
67
68 # NLS nuisances.
69 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
70 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
71 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
72 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
73 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
74 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
75 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
76 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
77
78 # IFS
79 # We need space, tab and new line, in precisely that order.
80 as_nl='
81 '
82 IFS=" $as_nl"
83
84 # CDPATH.
85 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
86
87 # Name of the host.
88 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
89 # so uname gets run too.
90 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
91
92 exec 6>&1
93
94 #
95 # Initializations.
96 #
97 ac_default_prefix=/usr/local
98 cross_compiling=no
99 subdirs=
100 MFLAGS=
101 MAKEFLAGS=
102 SHELL=${CONFIG_SHELL-/bin/sh}
103
104 # Maximum number of lines to put in a shell here document.
105 # This variable seems obsolete. It should probably be removed, and
106 # only ac_max_sed_lines should be used.
107 : "${ac_max_here_lines=38}"
108
109 ac_unique_file="charproc.c"
110 # Factoring default headers for most tests.
111 ac_includes_default="\
112 #include <stdio.h>
113 #if HAVE_SYS_TYPES_H
114 # include <sys/types.h>
115 #endif
116 #if HAVE_SYS_STAT_H
117 # include <sys/stat.h>
118 #endif
119 #if STDC_HEADERS
120 # include <stdlib.h>
121 # include <stddef.h>
122 #else
123 # if HAVE_STDLIB_H
124 # include <stdlib.h>
125 # endif
126 #endif
127 #if HAVE_STRING_H
128 # if !STDC_HEADERS && HAVE_MEMORY_H
129 # include <memory.h>
130 # endif
131 # include <string.h>
132 #endif
133 #if HAVE_STRINGS_H
134 # include <strings.h>
135 #endif
136 #if HAVE_INTTYPES_H
137 # include <inttypes.h>
138 #else
139 # if HAVE_STDINT_H
140 # include <stdint.h>
141 # endif
142 #endif
143 #if HAVE_UNISTD_H
144 # include <unistd.h>
145 #endif"
146
147 # Initialize some variables set by options.
148 ac_init_help=
149 ac_init_version=false
150 # The variables have the same names as the options, with
151 # dashes changed to underlines.
152 cache_file=/dev/null
153 exec_prefix=NONE
154 no_create=
155 no_recursion=
156 prefix=NONE
157 program_prefix=NONE
158 program_suffix=NONE
159 program_transform_name=s,x,x,
160 silent=
161 site=
162 srcdir=
163 verbose=
164 x_includes=NONE
165 x_libraries=NONE
166
167 # Installation directory options.
168 # These are left unexpanded so users can "make install exec_prefix=/foo"
169 # and all the variables that are supposed to be based on exec_prefix
170 # by default will actually change.
171 # Use braces instead of parens because sh, perl, etc. also accept them.
172 bindir='${exec_prefix}/bin'
173 sbindir='${exec_prefix}/sbin'
174 libexecdir='${exec_prefix}/libexec'
175 datarootdir='${prefix}/share'
176 datadir='${datarootdir}'
177 sysconfdir='${prefix}/etc'
178 sharedstatedir='${prefix}/com'
179 localstatedir='${prefix}/var'
180 runstatedir='${localstatedir}/run'
181 libdir='${exec_prefix}/lib'
182 includedir='${prefix}/include'
183 oldincludedir='/usr/include'
184 infodir='${datarootdir}/info'
185 mandir='${datarootdir}/man'
186
187 # Identity of this package.
188 PACKAGE_NAME=
189 PACKAGE_TARNAME=
190 PACKAGE_VERSION=
191 PACKAGE_STRING=
192 PACKAGE_BUGREPORT=
193
194 ac_prev=
195 for ac_option
196 do
197 # If the previous option needs an argument, assign it.
198 if test -n "$ac_prev"; then
199 eval "$ac_prev=\$ac_option"
200 ac_prev=
201 continue
202 fi
203
204 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
205
206 # Accept the important Cygnus configure options, so we can diagnose typos.
207
208 case "$ac_option" in
209
210 -bindir | --bindir | --bindi | --bind | --bin | --bi)
211 ac_prev=bindir ;;
212 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
213 bindir=$ac_optarg ;;
214
215 -build | --build | --buil | --bui | --bu)
216 ac_prev=build_alias ;;
217 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
218 build_alias=$ac_optarg ;;
219
220 -cache-file | --cache-file | --cache-fil | --cache-fi \
221 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
222 ac_prev=cache_file ;;
223 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
224 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
225 cache_file=$ac_optarg ;;
226
227 --config-cache | -C)
228 cache_file=config.cache ;;
229
230 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
231 ac_prev=datadir ;;
232 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
233 | --da=*)
234 datadir=$ac_optarg ;;
235
236 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
237 | --dataroo | --dataro | --datar)
238 ac_prev=datarootdir ;;
239 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
240 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
241 datarootdir=$ac_optarg ;;
242
243 -disable-* | --disable-*)
244 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
245 # Reject names that are not valid shell variable names.
246 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
247 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
248 { (exit 1); exit 1; }; }
249 ac_feature=`echo "$ac_feature" | sed 's/-/_/g'`
250 eval "enable_$ac_feature=no" ;;
251
252 -enable-* | --enable-*)
253 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
254 # Reject names that are not valid shell variable names.
255 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
256 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
257 { (exit 1); exit 1; }; }
258 ac_feature=`echo "$ac_feature" | sed 's/-/_/g'`
259 case "$ac_option" in
260 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
261 *) ac_optarg=yes ;;
262 esac
263 eval "enable_$ac_feature='$ac_optarg'" ;;
264
265 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
266 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
267 | --exec | --exe | --ex)
268 ac_prev=exec_prefix ;;
269 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
270 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
271 | --exec=* | --exe=* | --ex=*)
272 exec_prefix=$ac_optarg ;;
273
274 -gas | --gas | --ga | --g)
275 # Obsolete; use --with-gas.
276 with_gas=yes ;;
277
278 -help | --help | --hel | --he | -h)
279 ac_init_help=long ;;
280 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
281 ac_init_help=recursive ;;
282 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
283 ac_init_help=short ;;
284
285 -host | --host | --hos | --ho)
286 ac_prev=host_alias ;;
287 -host=* | --host=* | --hos=* | --ho=*)
288 host_alias=$ac_optarg ;;
289
290 -includedir | --includedir | --includedi | --included | --include \
291 | --includ | --inclu | --incl | --inc)
292 ac_prev=includedir ;;
293 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
294 | --includ=* | --inclu=* | --incl=* | --inc=*)
295 includedir=$ac_optarg ;;
296
297 -infodir | --infodir | --infodi | --infod | --info | --inf)
298 ac_prev=infodir ;;
299 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
300 infodir=$ac_optarg ;;
301
302 -libdir | --libdir | --libdi | --libd)
303 ac_prev=libdir ;;
304 -libdir=* | --libdir=* | --libdi=* | --libd=*)
305 libdir=$ac_optarg ;;
306
307 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
308 | --libexe | --libex | --libe)
309 ac_prev=libexecdir ;;
310 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
311 | --libexe=* | --libex=* | --libe=*)
312 libexecdir=$ac_optarg ;;
313
314 -localstatedir | --localstatedir | --localstatedi | --localstated \
315 | --localstate | --localstat | --localsta | --localst \
316 | --locals | --local | --loca | --loc | --lo)
317 ac_prev=localstatedir ;;
318 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
319 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
320 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
321 localstatedir=$ac_optarg ;;
322
323 -runstatedir | --runstatedir | --runstatedi | --runstated \
324 | --runstate | --runstat | --runsta | --runst \
325 | --runs | --run | --ru)
326 ac_prev=runstatedir ;;
327 -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
328 | --runstate=* | --runstat=* | --runsta=* | --runst=* \
329 | --runs=* | --run=* | --ru=*)
330 runstatedir=$ac_optarg ;;
331
332 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
333 ac_prev=mandir ;;
334 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
335 mandir=$ac_optarg ;;
336
337 -nfp | --nfp | --nf)
338 # Obsolete; use --without-fp.
339 with_fp=no ;;
340
341 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
342 | --no-cr | --no-c)
343 no_create=yes ;;
344
345 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
346 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
347 no_recursion=yes ;;
348
349 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
350 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
351 | --oldin | --oldi | --old | --ol | --o)
352 ac_prev=oldincludedir ;;
353 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
354 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
355 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
356 oldincludedir=$ac_optarg ;;
357
358 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
359 ac_prev=prefix ;;
360 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
361 prefix=$ac_optarg ;;
362
363 -program-prefix | --program-prefix | --program-prefi | --program-pref \
364 | --program-pre | --program-pr | --program-p)
365 ac_prev=program_prefix ;;
366 -program-prefix=* | --program-prefix=* | --program-prefi=* \
367 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
368 program_prefix=$ac_optarg ;;
369
370 -program-suffix | --program-suffix | --program-suffi | --program-suff \
371 | --program-suf | --program-su | --program-s)
372 ac_prev=program_suffix ;;
373 -program-suffix=* | --program-suffix=* | --program-suffi=* \
374 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
375 program_suffix=$ac_optarg ;;
376
377 -program-transform-name | --program-transform-name \
378 | --program-transform-nam | --program-transform-na \
379 | --program-transform-n | --program-transform- \
380 | --program-transform | --program-transfor \
381 | --program-transfo | --program-transf \
382 | --program-trans | --program-tran \
383 | --progr-tra | --program-tr | --program-t)
384 ac_prev=program_transform_name ;;
385 -program-transform-name=* | --program-transform-name=* \
386 | --program-transform-nam=* | --program-transform-na=* \
387 | --program-transform-n=* | --program-transform-=* \
388 | --program-transform=* | --program-transfor=* \
389 | --program-transfo=* | --program-transf=* \
390 | --program-trans=* | --program-tran=* \
391 | --progr-tra=* | --program-tr=* | --program-t=*)
392 program_transform_name=$ac_optarg ;;
393
394 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
395 | -silent | --silent | --silen | --sile | --sil)
396 silent=yes ;;
397
398 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
399 ac_prev=sbindir ;;
400 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
401 | --sbi=* | --sb=*)
402 sbindir=$ac_optarg ;;
403
404 -sharedstatedir | --sharedstatedir | --sharedstatedi \
405 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
406 | --sharedst | --shareds | --shared | --share | --shar \
407 | --sha | --sh)
408 ac_prev=sharedstatedir ;;
409 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
410 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
411 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
412 | --sha=* | --sh=*)
413 sharedstatedir=$ac_optarg ;;
414
415 -site | --site | --sit)
416 ac_prev=site ;;
417 -site=* | --site=* | --sit=*)
418 site=$ac_optarg ;;
419
420 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
421 ac_prev=srcdir ;;
422 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
423 srcdir=$ac_optarg ;;
424
425 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
426 | --syscon | --sysco | --sysc | --sys | --sy)
427 ac_prev=sysconfdir ;;
428 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
429 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
430 sysconfdir=$ac_optarg ;;
431
432 -target | --target | --targe | --targ | --tar | --ta | --t)
433 ac_prev=target_alias ;;
434 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
435 target_alias=$ac_optarg ;;
436
437 -v | -verbose | --verbose | --verbos | --verbo | --verb)
438 verbose=yes ;;
439
440 -version | --version | --versio | --versi | --vers | -V)
441 ac_init_version=: ;;
442
443 -with-* | --with-*)
444 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
445 # Reject names that are not valid shell variable names.
446 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
447 { echo "$as_me: error: invalid package name: $ac_package" >&2
448 { (exit 1); exit 1; }; }
449 ac_package=`echo "$ac_package" | sed 's/-/_/g'`
450 case "$ac_option" in
451 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
452 *) ac_optarg=yes ;;
453 esac
454 eval "with_$ac_package='$ac_optarg'" ;;
455
456 -without-* | --without-*)
457 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
458 # Reject names that are not valid shell variable names.
459 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
460 { echo "$as_me: error: invalid package name: $ac_package" >&2
461 { (exit 1); exit 1; }; }
462 ac_package=`echo "$ac_package" | sed 's/-/_/g'`
463 eval "with_$ac_package=no" ;;
464
465 --x)
466 # Obsolete; use --with-x.
467 with_x=yes ;;
468
469 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
470 | --x-incl | --x-inc | --x-in | --x-i)
471 ac_prev=x_includes ;;
472 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
473 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
474 x_includes=$ac_optarg ;;
475
476 -x-libraries | --x-libraries | --x-librarie | --x-librari \
477 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
478 ac_prev=x_libraries ;;
479 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
480 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
481 x_libraries=$ac_optarg ;;
482
483 -*dir | -dvi* | -doc* | -html* | -local* | -pdf* | -ps* )
484 echo "$as_me: WARNING: unsupported option: $ac_option" >&2
485 ;;
486
487 -*) { echo "$as_me: error: unrecognized option: $ac_option
488 Try \`$0 --help' for more information." >&2
489 { (exit 1); exit 1; }; }
490 ;;
491
492 *=*)
493 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
494 # Reject names that are not valid shell variable names.
495 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
496 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
497 { (exit 1); exit 1; }; }
498 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
499 eval "$ac_envvar='$ac_optarg'"
500 export "$ac_envvar" ;;
501
502 *)
503 # FIXME: should be removed in autoconf 3.0.
504 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
505 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
506 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
507 : "${build_alias=$ac_option}" "${host_alias=$ac_option}" "${target_alias=$ac_option}"
508 ;;
509
510 esac
511 done
512
513 if test -n "$ac_prev"; then
514 ac_option=--`echo "$ac_prev" | sed 's/_/-/g'`
515 { echo "$as_me: error: missing argument to $ac_option" >&2
516 { (exit 1); exit 1; }; }
517 fi
518
519 # Be sure to have absolute paths.
520 for ac_var in exec_prefix prefix
521 do
522 eval ac_val=$`echo "$ac_var"`
523 case "$ac_val" in
524 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
525 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
526 { (exit 1); exit 1; }; };;
527 esac
528 done
529
530 # Be sure to have absolute paths.
531 for ac_var in bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir \
532 localstatedir libdir includedir oldincludedir infodir mandir
533 do
534 eval ac_val=$`echo "$ac_var"`
535 case "$ac_val" in
536 [\\/$]* | ?:[\\/]* ) ;;
537 *) { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
538 { (exit 1); exit 1; }; };;
539 esac
540 done
541
542 # There might be people who depend on the old broken behavior: `$host'
543 # used to hold the argument of --host etc.
544 build=$build_alias
545 host=$host_alias
546 target=$target_alias
547
548 # FIXME: should be removed in autoconf 3.0.
549 if test "x$host_alias" != x; then
550 if test "x$build_alias" = x; then
551 cross_compiling=maybe
552 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
553 If a cross compiler is detected then cross compile mode will be used." >&2
554 elif test "x$build_alias" != "x$host_alias"; then
555 cross_compiling=yes
556 fi
557 fi
558
559 ac_tool_prefix=
560 test -n "$host_alias" && ac_tool_prefix=$host_alias-
561
562 test "$silent" = yes && exec 6>/dev/null
563
564 # Find the source files, if location was not specified.
565 if test -z "$srcdir"; then
566 ac_srcdir_defaulted=yes
567 # Try the directory containing this script, then its parent.
568 ac_prog=$0
569 ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
570 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
571 srcdir=$ac_confdir
572 if test ! -r "$srcdir/$ac_unique_file"; then
573 srcdir=..
574 fi
575 else
576 ac_srcdir_defaulted=no
577 fi
578 if test ! -r "$srcdir/$ac_unique_file"; then
579 if test "$ac_srcdir_defaulted" = yes; then
580 { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
581 { (exit 1); exit 1; }; }
582 else
583 { echo "$as_me: error: cannot find sources in $srcdir" >&2
584 { (exit 1); exit 1; }; }
585 fi
586 fi
587 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
588 ac_env_build_alias_set=${build_alias+set}
589 ac_env_build_alias_value=$build_alias
590 ac_cv_env_build_alias_set=${build_alias+set}
591 ac_cv_env_build_alias_value=$build_alias
592 ac_env_host_alias_set=${host_alias+set}
593 ac_env_host_alias_value=$host_alias
594 ac_cv_env_host_alias_set=${host_alias+set}
595 ac_cv_env_host_alias_value=$host_alias
596 ac_env_target_alias_set=${target_alias+set}
597 ac_env_target_alias_value=$target_alias
598 ac_cv_env_target_alias_set=${target_alias+set}
599 ac_cv_env_target_alias_value=$target_alias
600 ac_env_CC_set=${CC+set}
601 ac_env_CC_value=$CC
602 ac_cv_env_CC_set=${CC+set}
603 ac_cv_env_CC_value=$CC
604 ac_env_CFLAGS_set=${CFLAGS+set}
605 ac_env_CFLAGS_value=$CFLAGS
606 ac_cv_env_CFLAGS_set=${CFLAGS+set}
607 ac_cv_env_CFLAGS_value=$CFLAGS
608 ac_env_LDFLAGS_set=${LDFLAGS+set}
609 ac_env_LDFLAGS_value=$LDFLAGS
610 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
611 ac_cv_env_LDFLAGS_value=$LDFLAGS
612 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
613 ac_env_CPPFLAGS_value=$CPPFLAGS
614 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
615 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
616 ac_env_CPP_set=${CPP+set}
617 ac_env_CPP_value=$CPP
618 ac_cv_env_CPP_set=${CPP+set}
619 ac_cv_env_CPP_value=$CPP
620
621 #
622 # Report the --help message.
623 #
624 if test "$ac_init_help" = "long"; then
625 # Omit some internal or obsolete options to make the list less imposing.
626 # This message is too long to be a string in the A/UX 3.1 sh.
627 cat <<EOF
628 \`configure' configures this package to adapt to many kinds of systems.
629
630 Usage: $0 [OPTION]... [VAR=VALUE]...
631
632 To assign environment variables (e.g., CC, CFLAGS...), specify them as
633 VAR=VALUE. See below for descriptions of some of the useful variables.
634
635 Defaults for the options are specified in brackets.
636
637 Configuration:
638 -h, --help display this help and exit
639 --help=short display options specific to this package
640 --help=recursive display the short help of all the included packages
641 -V, --version display version information and exit
642 -q, --quiet, --silent do not print \`checking...' messages
643 --cache-file=FILE cache test results in FILE [disabled]
644 -C, --config-cache alias for \`--cache-file=config.cache'
645 -n, --no-create do not create output files
646 --srcdir=DIR find the sources in DIR [configure dir or \`..']
647
648 EOF
649
650 cat <<EOF
651 Installation directories:
652 --prefix=PREFIX install architecture-independent files in PREFIX
653 [$ac_default_prefix]
654 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
655 [PREFIX]
656
657 By default, \`make install' will install all the files in
658 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
659 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
660 for instance \`--prefix=\$HOME'.
661
662 For better control, use the options below.
663
664 Fine tuning of the installation directories:
665 --bindir=DIR user executables [EPREFIX/bin]
666 --sbindir=DIR system admin executables [EPREFIX/sbin]
667 --libexecdir=DIR program executables [EPREFIX/libexec]
668 --datarootdir=DIR read-only architecture-independent data [PREFIX/share]
669 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
670 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
671 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
672 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
673 --runstatedir=DIR extra definition of runtime data [LOCALSTATEDIR/run]
674 --libdir=DIR object code libraries [EPREFIX/lib]
675 --includedir=DIR C header files [PREFIX/include]
676 --oldincludedir=DIR C header files for non-gcc [/usr/include]
677 --infodir=DIR info documentation [DATAROOTDIR/info]
678 --mandir=DIR man documentation [DATAROOTDIR/man]
679 EOF
680
681 cat <<\EOF
682
683 Program names:
684 --program-prefix=PREFIX prepend PREFIX to installed program names
685 --program-suffix=SUFFIX append SUFFIX to installed program names
686 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
687
688 X features:
689 --x-includes=DIR X include files are in DIR
690 --x-libraries=DIR X library files are in DIR
691
692 System types:
693 --build=BUILD configure for building on BUILD [guessed]
694 --host=HOST build programs to run on HOST [BUILD]
695 --target=TARGET configure for building compilers for TARGET [HOST]
696 EOF
697 fi
698
699 if test -n "$ac_init_help"; then
700
701 cat <<\EOF
702
703 Optional Packages:
704 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
705 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
706
707 Optional Features:
708 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
709 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
710
711 --with-system-type=XXX test: override derived host system-type
712 Compile/Install Options:
713 --disable-full-tgetent disable check for full tgetent function
714 --with-app-class=XXX override X applications class (default XTerm)
715 --with-app-defaults=DIR directory in which to install resource files (EPREFIX/lib/X11/app-defaults)
716 --with-icon-name[=XXX] override icon name (default: mini.xterm)
717 --with-icon-symlink[=XXX] make symbolic link for icon name (default: xterm)
718 --with-pixmapdir=DIR directory in which to install pixmaps (DATADIR/pixmaps)
719 --with-icondir=DIR directory in which to install icons for desktop
720 --with-icon-theme[=XXX] install icons into desktop theme (hicolor)
721 --disable-desktop disable install of xterm desktop files
722 --with-desktop-category=XXX one or more desktop categories or auto
723 --with-reference=XXX program to use as permissions-reference
724 --with-xterm-symlink[=XXX] make symbolic link to installed xterm
725 --disable-openpty disable openpty, prefer other interfaces
726 --disable-setuid disable setuid in xterm, do not install setuid/setgid
727 --disable-setgid disable setgid in xterm, do not install setuid/setgid
728 --with-setuid[=XXX] use the given setuid user
729 --with-utmp-setgid[=XXX] use setgid to match utmp/utmpx file
730 --with-utempter use utempter library for access to utmp
731 --with-utmp-path=XXX use XXX rather than auto for utmp path
732 --with-wtmp-path=XXX use XXX rather than auto for wtmp path
733 --with-tty-group[=XXX] use XXX for the tty-group
734 --with-x use the X Window System
735 --with-pkg-config[=CMD] enable/disable use of pkg-config and its name CMD
736 --with-xpm[=DIR] use Xpm library for colored icon, may specify path
737 --without-xinerama do not use Xinerama extension for multiscreen support
738 --with-Xaw3d link with Xaw 3d library
739 --with-Xaw3dxft link with Xaw 3d xft library
740 --with-neXtaw link with neXT Athena library
741 --with-XawPlus link with Athena-Plus library
742 --disable-xcursor disable cursorTheme resource
743 --enable-narrowproto enable narrow prototypes for X libraries
744 --enable-imake enable use of imake for definitions
745 --with-man2html[=XXX] use XXX rather than groff
746 Terminal Configuration:
747 --with-terminal-id=V set default decTerminalID (default: vt420)
748 --with-terminal-type=T set default $TERM (default: xterm)
749 --with-xterm-kbs[=XXX] specify if xterm backspace-key sends BS or DEL
750 --enable-backarrow-key set default backarrowKey resource (default: true)
751 --enable-backarrow-is-erase set default backarrowKeyIsErase resource (default: false)
752 --enable-delete-is-del set default deleteIsDEL resource (default: maybe)
753 --enable-pty-erase set default ptyInitialErase resource (default: maybe)
754 --enable-alt-sends-esc set default altSendsEscape resource (default: no)
755 --enable-meta-sends-esc set default metaSendsEscape resource (default: no)
756 --with-own-terminfo[=P] set default $TERMINFO (default: from environment)
757 --enable-env-terminfo setenv $TERMINFO if --with-own-terminfo gives value
758 Optional Features:
759 --disable-active-icon disable X11R6.3 active-icon feature
760 --disable-ansi-color disable ANSI color
761 --disable-16-color disable 16-color support
762 --disable-256-color disable 256-color support
763 --disable-direct-color disable direct-color support
764 --disable-88-color disable 88-color support
765 --disable-blink-cursor disable support for blinking cursor
766 --enable-block-select meta-button1 begins block-selection
767 --enable-broken-osc allow broken Linux OSC-strings
768 --disable-broken-st disallow broken string-terminators
769 --enable-builtin-xpms compile-in icon data
770 --disable-c1-print disallow -k8 option for printable 128-159
771 --disable-bold-color disable PC-style mapping of bold colors
772 --disable-color-class disable separate color class resources
773 --disable-color-mode disable default colorMode resource
774 --disable-highlighting disable support for color highlighting
775 --disable-doublechars disable support for double-size chars
776 --disable-boxchars disable fallback-support for box chars
777 --disable-exec-selection disable "exec-formatted" and "exec-selection" actions
778 --enable-exec-xterm enable "spawn-new-terminal" action
779 --enable-double-buffer enable double-buffering in default resources
780 --disable-freetype disable freetype library-support
781 --with-freetype-config configure script to use for FreeType
782 --with-freetype-cflags -D/-I options for compiling with FreeType
783 --with-freetype-libs -L/-l options to link FreeType
784 --enable-hp-fkeys enable support for HP-style function keys
785 --enable-sco-fkeys enable support for SCO-style function keys
786 --disable-sun-fkeys disable support for Sun-style function keys
787 --disable-fifo-lines disable FIFO-storage for saved-lines
788 --disable-i18n disable internationalization
789 --disable-initial-erase disable setup for stty erase
790 --disable-input-method disable input-method
791 --enable-load-vt-fonts enable load-vt-fonts() action
792 --enable-logging enable logging
793 --enable-logfile-exec enable exec'd logfile filter
794 --disable-maximize disable actions for iconify/deiconify/maximize/restore
795 --disable-num-lock disable NumLock keypad support
796 --disable-paste64 disable get/set base64 selection data
797 --disable-pty-handshake disable pty-handshake support
798 --disable-readline-mouse disable support for mouse in readline applications
799 --disable-regex disable regular-expression selections
800 --with-pcre2=[XXX] use PCRE2 package XXX for regular-expressions
801 --with-pcre use PCRE for regular-expressions
802 --disable-rightbar disable right-scrollbar support
803 --disable-samename disable check for redundant name-change
804 --disable-selection-ops disable selection-action operations
805 --disable-session-mgt disable support for session management
806 --enable-status-line enable support for status-line
807 --disable-tcap-fkeys disable termcap function-keys support
808 --disable-tcap-query disable compiled-in termcap-query support
809 --disable-tek4014 disable tek4014 emulation
810 --enable-toolbar compile-in toolbar for pulldown menus
811 --disable-vt52 disable VT52 emulation
812 --disable-wide-attrs disable wide-attribute support
813 --disable-wide-chars disable wide-character support
814 --enable-16bit-chars enable 16-bit character support
815 --enable-mini-luit enable mini-luit (built-in Latin9 support)
816 --disable-luit enable luit filter (Unicode translation)
817 --enable-dabbrev enable dynamic-abbreviation support
818 --enable-dec-locator enable DECterm Locator support
819 --disable-screen-dumps disable XHTML and SVG screen dumps
820 --enable-regis-graphics enable ReGIS graphics support
821 --disable-sixel-graphics disable sixel graphics support
822 --disable-print-graphics disable screen dump to sixel support
823 --disable-rectangles disable VT420 rectangle support
824 --disable-resize-adjust disable resize/cursor-adjust feature
825 --disable-ziconbeep disable -ziconbeep option
826 Testing/development Options:
827 --enable-trace test: set to enable debugging traces
828 --with-dmalloc test: use Gray Watson's dmalloc library
829 --with-dbmalloc test: use Conor Cahill's dbmalloc library
830 --with-valgrind test: use valgrind
831 --disable-leaks test: free permanent memory, analyze leaks
832 --disable-echo do not display "compiling" commands
833 --enable-xmc-glitch test: enable xmc magic-cookie emulation
834 --enable-warnings test: turn on gcc compiler warnings
835 --enable-stdnoreturn enable C11 _Noreturn feature for diagnostics
836 --disable-rpath-hack don't add rpath options for additional libraries
837
838 Some influential environment variables:
839 CC C compiler command
840 CFLAGS C compiler flags
841 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
842 nonstandard directory <lib dir>
843 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
844 headers in a nonstandard directory <include dir>
845 CPP C preprocessor
846
847 Use these variables to override the choices made by `configure' or to help
848 it to find libraries and programs with nonstandard names/locations.
849
850 EOF
851 fi
852
853 if test "$ac_init_help" = "recursive"; then
854 # If there are subdirs, report their specific --help.
855 ac_popdir=`pwd`
856 for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
857 cd "$ac_subdir"
858 # A "../" for each directory in /$ac_subdir.
859 ac_dots=`echo "$ac_subdir" |
860 sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
861
862 case "$srcdir" in
863 .) # No --srcdir option. We are building in place.
864 ac_sub_srcdir="$srcdir" ;;
865 [\\/]* | ?:[\\/]* ) # Absolute path.
866 ac_sub_srcdir="$srcdir/$ac_subdir" ;;
867 *) # Relative path.
868 ac_sub_srcdir="$ac_dots$srcdir/$ac_subdir" ;;
869 esac
870
871 # Check for guested configure; otherwise get Cygnus style configure.
872 if test -f "$ac_sub_srcdir/configure.gnu"; then
873 echo
874 $SHELL "$ac_sub_srcdir/configure.gnu" --help=recursive
875 elif test -f "$ac_sub_srcdir/configure"; then
876 echo
877 $SHELL "$ac_sub_srcdir/configure" --help=recursive
878 elif test -f "$ac_sub_srcdir/configure.ac" ||
879 test -f "$ac_sub_srcdir/configure.in"; then
880 echo
881 "$ac_configure" --help
882 else
883 echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
884 fi
885 cd "$ac_popdir"
886 done
887 fi
888
889 test -n "$ac_init_help" && exit 0
890 if "$ac_init_version"; then
891 cat <<\EOF
892
893 Copyright 2003-2025,2026 Thomas E. Dickey
894 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
895 Free Software Foundation, Inc.
896 This configure script is free software; the Free Software Foundation
897 gives unlimited permission to copy, distribute and modify it.
898 EOF
899 exit 0
900 fi
901 exec 5>config.log
902 cat >&5 <<EOF
903 This file contains any messages produced by compilers while
904 running configure, to aid debugging if configure makes a mistake.
905
906 It was created by $as_me, which was
907 generated by GNU Autoconf 2.52.20260412. Invocation command line was
908
909 $ $0 $@
910
911 EOF
912 {
913 cat <<_ASUNAME
914 ## ---------- ##
915 ## Platform. ##
916 ## ---------- ##
917
918 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
919 uname -m = `(uname -m) 2>/dev/null || echo unknown`
920 uname -r = `(uname -r) 2>/dev/null || echo unknown`
921 uname -s = `(uname -s) 2>/dev/null || echo unknown`
922 uname -v = `(uname -v) 2>/dev/null || echo unknown`
923
924 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
925 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
926
927 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
928 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
929 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
930 hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
931 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
932 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
933 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
934
935 PATH = $PATH
936
937 _ASUNAME
938 } >&5
939
940 cat >&5 <<EOF
941 ## ------------ ##
942 ## Core tests. ##
943 ## ------------ ##
944
945 EOF
946
947 # Keep a trace of the command line.
948 # Strip out --no-create and --no-recursion so they do not pile up.
949 # Also quote any args containing shell meta-characters.
950 ac_configure_args=
951 ac_sep=
952 for ac_arg
953 do
954 case "$ac_arg" in
955 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
956 | --no-cr | --no-c) ;;
957 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
958 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
959 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
960 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
961 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
962 ac_sep=" " ;;
963 *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
964 ac_sep=" " ;;
965 esac
966 # Get rid of the leading space.
967 done
968
969 # When interrupted or exit'd, cleanup temporary files, and complete
970 # config.log. We remove comments because anyway the quotes in there
971 # would cause problems or look ugly.
972 trap 'exit_status=$?
973 # Save into config.log some information that might help in debugging.
974 echo >&5
975 echo "## ----------------- ##" >&5
976 echo "## Cache variables. ##" >&5
977 echo "## ----------------- ##" >&5
978 echo >&5
979 # The following way of writing the cache mishandles newlines in values,
980 {
981 (set) 2>&1 |
982 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
983 *ac_space=\ *)
984 sed -n \
985 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
986 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
987 ;;
988 *)
989 sed -n \
990 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
991 ;;
992 esac;
993 } >&5
994 sed "/^$/d" confdefs.h >conftest.log
995 if test -s conftest.log; then
996 echo >&5
997 echo "## ------------ ##" >&5
998 echo "## confdefs.h. ##" >&5
999 echo "## ------------ ##" >&5
1000 echo >&5
1001 cat conftest.log >&5
1002 fi
1003 (echo; echo) >&5
1004 test "$ac_signal" != 0 &&
1005 echo "$as_me: caught signal $ac_signal" >&5
1006 echo "$as_me: exit $exit_status" >&5
1007 rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
1008 exit $exit_status
1009 ' 0
1010 for ac_signal in 1 2 13 15; do
1011 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' "$ac_signal"
1012 done
1013 ac_signal=0
1014
1015 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1016 rm -rf conftest* confdefs.h
1017 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
1018 echo >confdefs.h
1019
1020 # Let the site file select an alternate cache file if it wants to.
1021 # Prefer explicitly selected file to automatically selected ones.
1022 if test -z "$CONFIG_SITE"; then
1023 if test "x$prefix" != xNONE; then
1024 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1025 else
1026 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1027 fi
1028 fi
1029 for ac_site_file in $CONFIG_SITE; do
1030 if test -r "$ac_site_file"; then
1031 { echo "$as_me:1031: loading site script $ac_site_file" >&5
1032 echo "$as_me: loading site script $ac_site_file" >&6;}
1033 cat "$ac_site_file" >&5
1034 . "$ac_site_file"
1035 fi
1036 done
1037
1038 if test -r "$cache_file"; then
1039 # Some versions of bash will fail to source /dev/null (special
1040 # files actually), so we avoid doing that.
1041 if test -f "$cache_file"; then
1042 { echo "$as_me:1042: loading cache $cache_file" >&5
1043 echo "$as_me: loading cache $cache_file" >&6;}
1044 case $cache_file in
1045 [\\/]* | ?:[\\/]* ) . $cache_file;;
1046 *) . ./$cache_file;;
1047 esac
1048 fi
1049 else
1050 { echo "$as_me:1050: creating cache $cache_file" >&5
1051 echo "$as_me: creating cache $cache_file" >&6;}
1052 >$cache_file
1053 fi
1054
1055 # Check that the precious variables saved in the cache have kept the same
1056 # value.
1057 ac_cache_corrupted=false
1058 for ac_var in `(set) 2>&1 |
1059 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1060 eval ac_old_set=\$ac_cv_env_${ac_var}_set
1061 eval ac_new_set=\$ac_env_${ac_var}_set
1062 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1063 eval ac_new_val="\$ac_env_${ac_var}_value"
1064 case "$ac_old_set,$ac_new_set" in
1065 set,)
1066 { echo "$as_me:1066: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1067 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1068 ac_cache_corrupted=: ;;
1069 ,set)
1070 { echo "$as_me:1070: error: \`$ac_var' was not set in the previous run" >&5
1071 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1072 ac_cache_corrupted=: ;;
1073 ,);;
1074 *)
1075 if test "x$ac_old_val" != "x$ac_new_val"; then
1076 { echo "$as_me:1076: error: \`$ac_var' has changed since the previous run:" >&5
1077 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1078 { echo "$as_me:1078: former value: $ac_old_val" >&5
1079 echo "$as_me: former value: $ac_old_val" >&2;}
1080 { echo "$as_me:1080: current value: $ac_new_val" >&5
1081 echo "$as_me: current value: $ac_new_val" >&2;}
1082 ac_cache_corrupted=:
1083 fi;;
1084 esac
1085 # Pass precious variables to config.status. It doesn't matter if
1086 # we pass some twice (in addition to the command line arguments).
1087 if test "$ac_new_set" = set; then
1088 case "$ac_new_val" in
1089 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1090 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
1091 ac_configure_args="$ac_configure_args '$ac_arg'"
1092 ;;
1093 *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
1094 ;;
1095 esac
1096 fi
1097 done
1098 if "$ac_cache_corrupted"; then
1099 { echo "$as_me:1099: error: changes in the environment can compromise the build" >&5
1100 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1101 { { echo "$as_me:1101: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1102 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1103 { (exit 1); exit 1; }; }
1104 fi
1105
1106 ac_ext=c
1107 ac_cpp='$CPP $CPPFLAGS'
1108 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
1109 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
1110 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1111 ac_main_return="return"
1112
1113 case `echo "testing\c" 2>/dev/null; echo 1,2,3`,`echo -n testing 2>/dev/null; echo 1,2,3` in
1114 *c*,-n*) ECHO_N=
1115 ECHO_C= # newlines do not sed ;-) only broken shells would use this case anyway
1116 ECHO_T=' '
1117 ;;
1118 *c*,* ) ECHO_N=-n
1119 ECHO_C=
1120 ECHO_T=
1121 ;;
1122 *) ECHO_N=
1123 ECHO_C='\c'
1124 ECHO_T=
1125 ;;
1126 esac
1127 echo "#! $SHELL" >conftest.sh
1128 echo "exit 0" >>conftest.sh
1129 chmod +x conftest.sh
1130 if { (echo "$as_me:1130: PATH=\".;.\"; conftest.sh") >&5
1131 (PATH=".;."; conftest.sh) 2>&5
1132 ac_status=$?
1133 echo "$as_me:1133: \$? = $ac_status" >&5
1134 (exit "$ac_status"); }; then
1135 ac_path_separator=';'
1136 else
1137 ac_path_separator=:
1138 fi
1139 PATH_SEPARATOR="$ac_path_separator"
1140 rm -f conftest.sh
1141
1142 ac_config_headers="$ac_config_headers xtermcfg.h:xtermcfg.hin"
1143
1144 ac_aux_dir=
1145 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1146 if test -f "$ac_dir/install-sh"; then
1147 ac_aux_dir=$ac_dir
1148 ac_install_sh="$ac_aux_dir/install-sh -c"
1149 break
1150 elif test -f "$ac_dir/install.sh"; then
1151 ac_aux_dir=$ac_dir
1152 ac_install_sh="$ac_aux_dir/install.sh -c"
1153 break
1154 elif test -f "$ac_dir/shtool"; then
1155 ac_aux_dir=$ac_dir
1156 ac_install_sh="$ac_aux_dir/shtool install -c"
1157 break
1158 fi
1159 done
1160 if test -z "$ac_aux_dir"; then
1161 { { echo "$as_me:1161: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1162 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1163 { (exit 1); exit 1; }; }
1164 fi
1165 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1166 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1167 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1168
1169 # Make sure we can run config.sub.
1170 $ac_config_sub sun4 >/dev/null 2>&1 ||
1171 { { echo "$as_me:1171: error: cannot run $ac_config_sub" >&5
1172 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1173 { (exit 1); exit 1; }; }
1174
1175 echo "$as_me:1175: checking build system type" >&5
1176 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1177 if test "${ac_cv_build+set}" = set; then
1178 echo $ECHO_N "(cached) $ECHO_C" >&6
1179 else
1180 ac_cv_build_alias=$build_alias
1181 test -z "$ac_cv_build_alias" &&
1182 ac_cv_build_alias=`$ac_config_guess`
1183 test -z "$ac_cv_build_alias" &&
1184 { { echo "$as_me:1184: error: cannot guess build type; you must specify one" >&5
1185 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1186 { (exit 1); exit 1; }; }
1187 ac_cv_build=`$ac_config_sub "$ac_cv_build_alias"` ||
1188 { { echo "$as_me:1188: error: $ac_config_sub $ac_cv_build_alias failed." >&5
1189 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
1190 { (exit 1); exit 1; }; }
1191
1192 fi
1193 echo "$as_me:1193: result: $ac_cv_build" >&5
1194 echo "${ECHO_T}$ac_cv_build" >&6
1195 build=$ac_cv_build
1196 build_cpu=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1197 build_vendor=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1198 build_os=`echo "$ac_cv_build" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1199
1200 if test -f "$srcdir/config.guess" || test -f "$ac_aux_dir/config.guess" ; then
1201 echo "$as_me:1201: checking host system type" >&5
1202 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1203 if test "${ac_cv_host+set}" = set; then
1204 echo $ECHO_N "(cached) $ECHO_C" >&6
1205 else
1206 ac_cv_host_alias=$host_alias
1207 test -z "$ac_cv_host_alias" &&
1208 ac_cv_host_alias=$ac_cv_build_alias
1209 ac_cv_host=`$ac_config_sub "$ac_cv_host_alias"` ||
1210 { { echo "$as_me:1210: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1211 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1212 { (exit 1); exit 1; }; }
1213
1214 fi
1215 echo "$as_me:1215: result: $ac_cv_host" >&5
1216 echo "${ECHO_T}$ac_cv_host" >&6
1217 host=$ac_cv_host
1218 host_cpu=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1219 host_vendor=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1220 host_os=`echo "$ac_cv_host" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1221
1222 system_name="$host_os"
1223 else
1224 system_name="`(uname -s -r) 2>/dev/null`"
1225 if test -z "$system_name" ; then
1226 system_name="`(hostname) 2>/dev/null`"
1227 fi
1228 fi
1229 test -n "$system_name" &&
1230 cat >>confdefs.h <<EOF
1231 #define SYSTEM_NAME "$system_name"
1232 EOF
1233
1234 if test "${cf_cv_system_name+set}" = set; then
1235 echo $ECHO_N "(cached) $ECHO_C" >&6
1236 else
1237 cf_cv_system_name="$system_name"
1238 fi
1239
1240 test -z "$system_name" && system_name="$cf_cv_system_name"
1241 test -n "$cf_cv_system_name" && echo "$as_me:1241: result: Configuring for $cf_cv_system_name" >&5
1242 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
1243
1244 if test ".$system_name" != ".$cf_cv_system_name" ; then
1245 echo "$as_me:1245: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
1246 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
1247 { { echo "$as_me:1247: error: \"Please remove config.cache and try again.\"" >&5
1248 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
1249 { (exit 1); exit 1; }; }
1250 fi
1251
1252 ### checks for alternative programs
1253
1254 case "$host_os" in
1255 (openedition) : "${CFLAGS=\"-O2 -Wc,dll -Wl,EDIT=NO\"}"
1256 : "${CPPFLAGS=\"-D_ALL_SOURCE\"}"
1257 : "${LIBS=\"/usr/lib/Xaw.x /usr/lib/SM.x /usr/lib/ICE.x /usr/lib/X11.x\"}"
1258 : "${CC=c89}";;
1259 (darwin*)
1260 : "${LDFLAGS}=\"${LDFLAGS} -Wl,-bind_at_load\"";;
1261 esac
1262
1263 ac_ext=c
1264 ac_cpp='$CPP $CPPFLAGS'
1265 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
1266 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
1267 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1268 ac_main_return="return"
1269 if test -n "$ac_tool_prefix"; then
1270 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1271 set dummy ${ac_tool_prefix}gcc; ac_word=$2
1272 echo "$as_me:1272: checking for $ac_word" >&5
1273 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1274 if test "${ac_cv_prog_CC+set}" = set; then
1275 echo $ECHO_N "(cached) $ECHO_C" >&6
1276 else
1277 if test -n "$CC"; then
1278 ac_cv_prog_CC="$CC" # Let the user override the test.
1279 else
1280 ac_save_IFS=$IFS; IFS=$ac_path_separator
1281 ac_dummy="$PATH"
1282 for ac_dir in $ac_dummy; do
1283 IFS=$ac_save_IFS
1284 test -z "$ac_dir" && ac_dir=.
1285 $as_executable_p "$ac_dir/$ac_word" || continue
1286 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1287 echo "$as_me:1287: found $ac_dir/$ac_word" >&5
1288 break
1289 done
1290
1291 fi
1292 fi
1293 CC=$ac_cv_prog_CC
1294 if test -n "$CC"; then
1295 echo "$as_me:1295: result: $CC" >&5
1296 echo "${ECHO_T}$CC" >&6
1297 else
1298 echo "$as_me:1298: result: no" >&5
1299 echo "${ECHO_T}no" >&6
1300 fi
1301
1302 fi
1303 if test -z "$ac_cv_prog_CC"; then
1304 ac_ct_CC=$CC
1305 # Extract the first word of "gcc", so it can be a program name with args.
1306 set dummy gcc; ac_word=$2
1307 echo "$as_me:1307: checking for $ac_word" >&5
1308 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1309 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1310 echo $ECHO_N "(cached) $ECHO_C" >&6
1311 else
1312 if test -n "$ac_ct_CC"; then
1313 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1314 else
1315 ac_save_IFS=$IFS; IFS=$ac_path_separator
1316 ac_dummy="$PATH"
1317 for ac_dir in $ac_dummy; do
1318 IFS=$ac_save_IFS
1319 test -z "$ac_dir" && ac_dir=.
1320 $as_executable_p "$ac_dir/$ac_word" || continue
1321 ac_cv_prog_ac_ct_CC="gcc"
1322 echo "$as_me:1322: found $ac_dir/$ac_word" >&5
1323 break
1324 done
1325
1326 fi
1327 fi
1328 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1329 if test -n "$ac_ct_CC"; then
1330 echo "$as_me:1330: result: $ac_ct_CC" >&5
1331 echo "${ECHO_T}$ac_ct_CC" >&6
1332 else
1333 echo "$as_me:1333: result: no" >&5
1334 echo "${ECHO_T}no" >&6
1335 fi
1336
1337 CC=$ac_ct_CC
1338 else
1339 CC="$ac_cv_prog_CC"
1340 fi
1341
1342 if test -z "$CC"; then
1343 if test -n "$ac_tool_prefix"; then
1344 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1345 set dummy ${ac_tool_prefix}cc; ac_word=$2
1346 echo "$as_me:1346: checking for $ac_word" >&5
1347 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1348 if test "${ac_cv_prog_CC+set}" = set; then
1349 echo $ECHO_N "(cached) $ECHO_C" >&6
1350 else
1351 if test -n "$CC"; then
1352 ac_cv_prog_CC="$CC" # Let the user override the test.
1353 else
1354 ac_save_IFS=$IFS; IFS=$ac_path_separator
1355 ac_dummy="$PATH"
1356 for ac_dir in $ac_dummy; do
1357 IFS=$ac_save_IFS
1358 test -z "$ac_dir" && ac_dir=.
1359 $as_executable_p "$ac_dir/$ac_word" || continue
1360 ac_cv_prog_CC="${ac_tool_prefix}cc"
1361 echo "$as_me:1361: found $ac_dir/$ac_word" >&5
1362 break
1363 done
1364
1365 fi
1366 fi
1367 CC=$ac_cv_prog_CC
1368 if test -n "$CC"; then
1369 echo "$as_me:1369: result: $CC" >&5
1370 echo "${ECHO_T}$CC" >&6
1371 else
1372 echo "$as_me:1372: result: no" >&5
1373 echo "${ECHO_T}no" >&6
1374 fi
1375
1376 fi
1377 if test -z "$ac_cv_prog_CC"; then
1378 ac_ct_CC=$CC
1379 # Extract the first word of "cc", so it can be a program name with args.
1380 set dummy cc; ac_word=$2
1381 echo "$as_me:1381: checking for $ac_word" >&5
1382 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1383 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1384 echo $ECHO_N "(cached) $ECHO_C" >&6
1385 else
1386 if test -n "$ac_ct_CC"; then
1387 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1388 else
1389 ac_save_IFS=$IFS; IFS=$ac_path_separator
1390 ac_dummy="$PATH"
1391 for ac_dir in $ac_dummy; do
1392 IFS=$ac_save_IFS
1393 test -z "$ac_dir" && ac_dir=.
1394 $as_executable_p "$ac_dir/$ac_word" || continue
1395 ac_cv_prog_ac_ct_CC="cc"
1396 echo "$as_me:1396: found $ac_dir/$ac_word" >&5
1397 break
1398 done
1399
1400 fi
1401 fi
1402 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1403 if test -n "$ac_ct_CC"; then
1404 echo "$as_me:1404: result: $ac_ct_CC" >&5
1405 echo "${ECHO_T}$ac_ct_CC" >&6
1406 else
1407 echo "$as_me:1407: result: no" >&5
1408 echo "${ECHO_T}no" >&6
1409 fi
1410
1411 CC=$ac_ct_CC
1412 else
1413 CC="$ac_cv_prog_CC"
1414 fi
1415
1416 fi
1417 if test -z "$CC"; then
1418 # Extract the first word of "cc", so it can be a program name with args.
1419 set dummy cc; ac_word=$2
1420 echo "$as_me:1420: checking for $ac_word" >&5
1421 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1422 if test "${ac_cv_prog_CC+set}" = set; then
1423 echo $ECHO_N "(cached) $ECHO_C" >&6
1424 else
1425 if test -n "$CC"; then
1426 ac_cv_prog_CC="$CC" # Let the user override the test.
1427 else
1428 ac_prog_rejected=no
1429 ac_save_IFS=$IFS; IFS=$ac_path_separator
1430 ac_dummy="$PATH"
1431 for ac_dir in $ac_dummy; do
1432 IFS=$ac_save_IFS
1433 test -z "$ac_dir" && ac_dir=.
1434 $as_executable_p "$ac_dir/$ac_word" || continue
1435 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1436 ac_prog_rejected=yes
1437 continue
1438 fi
1439 ac_cv_prog_CC="cc"
1440 echo "$as_me:1440: found $ac_dir/$ac_word" >&5
1441 break
1442 done
1443
1444 if test "$ac_prog_rejected" = yes; then
1445 # We found a bogon in the path, so make sure we never use it.
1446 set dummy $ac_cv_prog_CC
1447 shift
1448 if test $# != 0; then
1449 # We chose a different compiler from the bogus one.
1450 # However, it has the same basename, so the bogon will be chosen
1451 # first if we set CC to just the basename; use the full file name.
1452 shift
1453 set dummy "$ac_dir/$ac_word" ${1+"$@"}
1454 shift
1455 ac_cv_prog_CC="$@"
1456 fi
1457 fi
1458 fi
1459 fi
1460 CC=$ac_cv_prog_CC
1461 if test -n "$CC"; then
1462 echo "$as_me:1462: result: $CC" >&5
1463 echo "${ECHO_T}$CC" >&6
1464 else
1465 echo "$as_me:1465: result: no" >&5
1466 echo "${ECHO_T}no" >&6
1467 fi
1468
1469 fi
1470 if test -z "$CC"; then
1471 if test -n "$ac_tool_prefix"; then
1472 for ac_prog in cl
1473 do
1474 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1475 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1476 echo "$as_me:1476: checking for $ac_word" >&5
1477 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1478 if test "${ac_cv_prog_CC+set}" = set; then
1479 echo $ECHO_N "(cached) $ECHO_C" >&6
1480 else
1481 if test -n "$CC"; then
1482 ac_cv_prog_CC="$CC" # Let the user override the test.
1483 else
1484 ac_save_IFS=$IFS; IFS=$ac_path_separator
1485 ac_dummy="$PATH"
1486 for ac_dir in $ac_dummy; do
1487 IFS=$ac_save_IFS
1488 test -z "$ac_dir" && ac_dir=.
1489 $as_executable_p "$ac_dir/$ac_word" || continue
1490 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1491 echo "$as_me:1491: found $ac_dir/$ac_word" >&5
1492 break
1493 done
1494
1495 fi
1496 fi
1497 CC=$ac_cv_prog_CC
1498 if test -n "$CC"; then
1499 echo "$as_me:1499: result: $CC" >&5
1500 echo "${ECHO_T}$CC" >&6
1501 else
1502 echo "$as_me:1502: result: no" >&5
1503 echo "${ECHO_T}no" >&6
1504 fi
1505
1506 test -n "$CC" && break
1507 done
1508 fi
1509 if test -z "$CC"; then
1510 ac_ct_CC=$CC
1511 for ac_prog in cl
1512 do
1513 # Extract the first word of "$ac_prog", so it can be a program name with args.
1514 set dummy $ac_prog; ac_word=$2
1515 echo "$as_me:1515: checking for $ac_word" >&5
1516 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1517 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1518 echo $ECHO_N "(cached) $ECHO_C" >&6
1519 else
1520 if test -n "$ac_ct_CC"; then
1521 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1522 else
1523 ac_save_IFS=$IFS; IFS=$ac_path_separator
1524 ac_dummy="$PATH"
1525 for ac_dir in $ac_dummy; do
1526 IFS=$ac_save_IFS
1527 test -z "$ac_dir" && ac_dir=.
1528 $as_executable_p "$ac_dir/$ac_word" || continue
1529 ac_cv_prog_ac_ct_CC="$ac_prog"
1530 echo "$as_me:1530: found $ac_dir/$ac_word" >&5
1531 break
1532 done
1533
1534 fi
1535 fi
1536 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1537 if test -n "$ac_ct_CC"; then
1538 echo "$as_me:1538: result: $ac_ct_CC" >&5
1539 echo "${ECHO_T}$ac_ct_CC" >&6
1540 else
1541 echo "$as_me:1541: result: no" >&5
1542 echo "${ECHO_T}no" >&6
1543 fi
1544
1545 test -n "$ac_ct_CC" && break
1546 done
1547
1548 CC=$ac_ct_CC
1549 fi
1550
1551 fi
1552
1553 test -z "$CC" && { { echo "$as_me:1553: error: no acceptable cc found in \$PATH" >&5
1554 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1555 { (exit 1); exit 1; }; }
1556
1557 # Provide some information about the compiler.
1558 echo "$as_me:1558:" \
1559 "checking for C compiler version" >&5
1560 ac_compiler=`set X $ac_compile; echo "$2"`
1561 { (eval echo "$as_me:1561: \"$ac_compiler --version </dev/null >&5\"") >&5
1562 (eval $ac_compiler --version </dev/null >&5) 2>&5
1563 ac_status=$?
1564 echo "$as_me:1564: \$? = $ac_status" >&5
1565 (exit "$ac_status"); }
1566 { (eval echo "$as_me:1566: \"$ac_compiler -v </dev/null >&5\"") >&5
1567 (eval $ac_compiler -v </dev/null >&5) 2>&5
1568 ac_status=$?
1569 echo "$as_me:1569: \$? = $ac_status" >&5
1570 (exit "$ac_status"); }
1571 { (eval echo "$as_me:1571: \"$ac_compiler -V </dev/null >&5\"") >&5
1572 (eval $ac_compiler -V </dev/null >&5) 2>&5
1573 ac_status=$?
1574 echo "$as_me:1574: \$? = $ac_status" >&5
1575 (exit "$ac_status"); }
1576
1577 cat >"conftest.$ac_ext" <<_ACEOF
1578 #line 1578 "configure"
1579 #include "confdefs.h"
1580
1581 int
1582 main (void)
1583 {
1584
1585 ;
1586 return 0;
1587 }
1588 _ACEOF
1589 ac_clean_files_save=$ac_clean_files
1590 ac_clean_files="$ac_clean_files a.out a.exe"
1591 # Try to create an executable without -o first, disregard a.out.
1592 # It will help us diagnose broken compilers, and finding out an intuition
1593 # of exeext.
1594 echo "$as_me:1594: checking for C compiler default output" >&5
1595 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1596 ac_link_default=`echo "$ac_link" | sed 's/ -o *"conftest[^"]*"//'`
1597 if { (eval echo "$as_me:1597: \"$ac_link_default\"") >&5
1598 (eval $ac_link_default) 2>&5
1599 ac_status=$?
1600 echo "$as_me:1600: \$? = $ac_status" >&5
1601 (exit "$ac_status"); }; then
1602 # Find the output, starting from the most likely. This scheme is
1603 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
1604 # resort.
1605 for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1606 ls a.out conftest 2>/dev/null;
1607 ls a.* conftest.* 2>/dev/null`; do
1608 case $ac_file in
1609 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1610 a.out ) # We found the default executable, but exeext='' is most
1611 # certainly right.
1612 break;;
1613 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1614 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1615 export ac_cv_exeext
1616 break;;
1617 * ) break;;
1618 esac
1619 done
1620 else
1621 echo "$as_me: failed program was:" >&5
1622 cat "conftest.$ac_ext" >&5
1623 { { echo "$as_me:1623: error: C compiler cannot create executables" >&5
1624 echo "$as_me: error: C compiler cannot create executables" >&2;}
1625 { (exit 77); exit 77; }; }
1626 fi
1627
1628 ac_exeext=$ac_cv_exeext
1629 echo "$as_me:1629: result: $ac_file" >&5
1630 echo "${ECHO_T}$ac_file" >&6
1631
1632 # Check the compiler produces executables we can run. If not, either
1633 # the compiler is broken, or we cross compile.
1634 echo "$as_me:1634: checking whether the C compiler works" >&5
1635 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1636 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1637 # If not cross compiling, check that we can run a simple program.
1638 if test "$cross_compiling" != yes; then
1639 if { ac_try='./$ac_file'
1640 { (eval echo "$as_me:1640: \"$ac_try\"") >&5
1641 (eval $ac_try) 2>&5
1642 ac_status=$?
1643 echo "$as_me:1643: \$? = $ac_status" >&5
1644 (exit "$ac_status"); }; }; then
1645 cross_compiling=no
1646 else
1647 if test "$cross_compiling" = maybe; then
1648 cross_compiling=yes
1649 else
1650 { { echo "$as_me:1650: error: cannot run C compiled programs.
1651 If you meant to cross compile, use \`--host'." >&5
1652 echo "$as_me: error: cannot run C compiled programs.
1653 If you meant to cross compile, use \`--host'." >&2;}
1654 { (exit 1); exit 1; }; }
1655 fi
1656 fi
1657 fi
1658 echo "$as_me:1658: result: yes" >&5
1659 echo "${ECHO_T}yes" >&6
1660
1661 rm -f a.out a.exe "conftest$ac_cv_exeext"
1662 ac_clean_files=$ac_clean_files_save
1663 # Check the compiler produces executables we can run. If not, either
1664 # the compiler is broken, or we cross compile.
1665 echo "$as_me:1665: checking whether we are cross compiling" >&5
1666 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1667 echo "$as_me:1667: result: $cross_compiling" >&5
1668 echo "${ECHO_T}$cross_compiling" >&6
1669
1670 echo "$as_me:1670: checking for executable suffix" >&5
1671 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1672 if { (eval echo "$as_me:1672: \"$ac_link\"") >&5
1673 (eval $ac_link) 2>&5
1674 ac_status=$?
1675 echo "$as_me:1675: \$? = $ac_status" >&5
1676 (exit "$ac_status"); }; then
1677 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1678 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1679 # work properly (i.e., refer to `conftest.exe'), while it won't with
1680 # `rm'.
1681 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1682 case $ac_file in
1683 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
1684 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1685 export ac_cv_exeext
1686 break;;
1687 * ) break;;
1688 esac
1689 done
1690 else
1691 { { echo "$as_me:1691: error: cannot compute EXEEXT: cannot compile and link" >&5
1692 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1693 { (exit 1); exit 1; }; }
1694 fi
1695
1696 rm -f "conftest$ac_cv_exeext"
1697 echo "$as_me:1697: result: $ac_cv_exeext" >&5
1698 echo "${ECHO_T}$ac_cv_exeext" >&6
1699
1700 rm -f "conftest.$ac_ext"
1701 EXEEXT=$ac_cv_exeext
1702 ac_exeext=$EXEEXT
1703 echo "$as_me:1703: checking for object suffix" >&5
1704 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1705 if test "${ac_cv_objext+set}" = set; then
1706 echo $ECHO_N "(cached) $ECHO_C" >&6
1707 else
1708 cat >"conftest.$ac_ext" <<_ACEOF
1709 #line 1709 "configure"
1710 #include "confdefs.h"
1711
1712 int
1713 main (void)
1714 {
1715
1716 ;
1717 return 0;
1718 }
1719 _ACEOF
1720 rm -f conftest.o conftest.obj
1721 if { (eval echo "$as_me:1721: \"$ac_compile\"") >&5
1722 (eval $ac_compile) 2>&5
1723 ac_status=$?
1724 echo "$as_me:1724: \$? = $ac_status" >&5
1725 (exit "$ac_status"); }; then
1726 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1727 case $ac_file in
1728 *.$ac_ext | *.xcoff | *.tds | *.d | *.dbg | *.pdb | *.xSYM | *.map | *.inf ) ;;
1729 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1730 break;;
1731 esac
1732 done
1733 else
1734 echo "$as_me: failed program was:" >&5
1735 cat "conftest.$ac_ext" >&5
1736 { { echo "$as_me:1736: error: cannot compute OBJEXT: cannot compile" >&5
1737 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1738 { (exit 1); exit 1; }; }
1739 fi
1740
1741 rm -f "conftest.$ac_cv_objext" "conftest.$ac_ext"
1742 fi
1743 echo "$as_me:1743: result: $ac_cv_objext" >&5
1744 echo "${ECHO_T}$ac_cv_objext" >&6
1745 OBJEXT=$ac_cv_objext
1746 ac_objext=$OBJEXT
1747 echo "$as_me:1747: checking whether we are using the GNU C compiler" >&5
1748 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1749 if test "${ac_cv_c_compiler_gnu+set}" = set; then
1750 echo $ECHO_N "(cached) $ECHO_C" >&6
1751 else
1752 cat >"conftest.$ac_ext" <<_ACEOF
1753 #line 1753 "configure"
1754 #include "confdefs.h"
1755
1756 int
1757 main (void)
1758 {
1759 #ifndef __GNUC__
1760 choke me
1761 #endif
1762
1763 ;
1764 return 0;
1765 }
1766 _ACEOF
1767 rm -f "conftest.$ac_objext"
1768 if { (eval echo "$as_me:1768: \"$ac_compile\"") >&5
1769 (eval $ac_compile) 2>&5
1770 ac_status=$?
1771 echo "$as_me:1771: \$? = $ac_status" >&5
1772 (exit "$ac_status"); } &&
1773 { ac_try='test -s "conftest.$ac_objext"'
1774 { (eval echo "$as_me:1774: \"$ac_try\"") >&5
1775 (eval $ac_try) 2>&5
1776 ac_status=$?
1777 echo "$as_me:1777: \$? = $ac_status" >&5
1778 (exit "$ac_status"); }; }; then
1779 ac_compiler_gnu=yes
1780 else
1781 echo "$as_me: failed program was:" >&5
1782 cat "conftest.$ac_ext" >&5
1783 ac_compiler_gnu=no
1784 fi
1785 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1786 ac_cv_c_compiler_gnu=$ac_compiler_gnu
1787
1788 fi
1789 echo "$as_me:1789: result: $ac_cv_c_compiler_gnu" >&5
1790 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1791 GCC=`test $ac_compiler_gnu = yes && echo yes`
1792 ac_test_CFLAGS=${CFLAGS+set}
1793 ac_save_CFLAGS=$CFLAGS
1794 CFLAGS="-g"
1795 echo "$as_me:1795: checking whether $CC accepts -g" >&5
1796 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1797 if test "${ac_cv_prog_cc_g+set}" = set; then
1798 echo $ECHO_N "(cached) $ECHO_C" >&6
1799 else
1800 cat >"conftest.$ac_ext" <<_ACEOF
1801 #line 1801 "configure"
1802 #include "confdefs.h"
1803
1804 int
1805 main (void)
1806 {
1807
1808 ;
1809 return 0;
1810 }
1811 _ACEOF
1812 rm -f "conftest.$ac_objext"
1813 if { (eval echo "$as_me:1813: \"$ac_compile\"") >&5
1814 (eval $ac_compile) 2>&5
1815 ac_status=$?
1816 echo "$as_me:1816: \$? = $ac_status" >&5
1817 (exit "$ac_status"); } &&
1818 { ac_try='test -s "conftest.$ac_objext"'
1819 { (eval echo "$as_me:1819: \"$ac_try\"") >&5
1820 (eval $ac_try) 2>&5
1821 ac_status=$?
1822 echo "$as_me:1822: \$? = $ac_status" >&5
1823 (exit "$ac_status"); }; }; then
1824 ac_cv_prog_cc_g=yes
1825 else
1826 echo "$as_me: failed program was:" >&5
1827 cat "conftest.$ac_ext" >&5
1828 ac_cv_prog_cc_g=no
1829 fi
1830 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1831 fi
1832 echo "$as_me:1832: result: $ac_cv_prog_cc_g" >&5
1833 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1834 if test "$ac_test_CFLAGS" = set; then
1835 CFLAGS=$ac_save_CFLAGS
1836 elif test $ac_cv_prog_cc_g = yes; then
1837 if test "$GCC" = yes; then
1838 CFLAGS="-g -O2"
1839 else
1840 CFLAGS="-g"
1841 fi
1842 else
1843 if test "$GCC" = yes; then
1844 CFLAGS="-O2"
1845 else
1846 CFLAGS=
1847 fi
1848 fi
1849 # Some people use a C++ compiler to compile C. Since we use `exit',
1850 # in C++ we need to declare it. In case someone uses the same compiler
1851 # for both compiling C and C++ we need to have the C++ compiler decide
1852 # the declaration of exit, since it's the most demanding environment.
1853 cat >"conftest.$ac_ext" <<_ACEOF
1854 #ifndef __cplusplus
1855 choke me
1856 #endif
1857 _ACEOF
1858 rm -f "conftest.$ac_objext"
1859 if { (eval echo "$as_me:1859: \"$ac_compile\"") >&5
1860 (eval $ac_compile) 2>&5
1861 ac_status=$?
1862 echo "$as_me:1862: \$? = $ac_status" >&5
1863 (exit "$ac_status"); } &&
1864 { ac_try='test -s "conftest.$ac_objext"'
1865 { (eval echo "$as_me:1865: \"$ac_try\"") >&5
1866 (eval $ac_try) 2>&5
1867 ac_status=$?
1868 echo "$as_me:1868: \$? = $ac_status" >&5
1869 (exit "$ac_status"); }; }; then
1870 for ac_declaration in \
1871 ''\
1872 '#include <stdlib.h>' \
1873 'extern "C" void std::exit (int) throw (); using std::exit;' \
1874 'extern "C" void std::exit (int); using std::exit;' \
1875 'extern "C" void exit (int) throw ();' \
1876 'extern "C" void exit (int);' \
1877 'void exit (int);'
1878 do
1879 cat >"conftest.$ac_ext" <<_ACEOF
1880 #line 1880 "configure"
1881 #include "confdefs.h"
1882 #include <stdlib.h>
1883 $ac_declaration
1884 int
1885 main (void)
1886 {
1887 exit (42);
1888 ;
1889 return 0;
1890 }
1891 _ACEOF
1892 rm -f "conftest.$ac_objext"
1893 if { (eval echo "$as_me:1893: \"$ac_compile\"") >&5
1894 (eval $ac_compile) 2>&5
1895 ac_status=$?
1896 echo "$as_me:1896: \$? = $ac_status" >&5
1897 (exit "$ac_status"); } &&
1898 { ac_try='test -s "conftest.$ac_objext"'
1899 { (eval echo "$as_me:1899: \"$ac_try\"") >&5
1900 (eval $ac_try) 2>&5
1901 ac_status=$?
1902 echo "$as_me:1902: \$? = $ac_status" >&5
1903 (exit "$ac_status"); }; }; then
1904 :
1905 else
1906 echo "$as_me: failed program was:" >&5
1907 cat "conftest.$ac_ext" >&5
1908 continue
1909 fi
1910 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1911 cat >"conftest.$ac_ext" <<_ACEOF
1912 #line 1912 "configure"
1913 #include "confdefs.h"
1914 $ac_declaration
1915 int
1916 main (void)
1917 {
1918 exit (42);
1919 ;
1920 return 0;
1921 }
1922 _ACEOF
1923 rm -f "conftest.$ac_objext"
1924 if { (eval echo "$as_me:1924: \"$ac_compile\"") >&5
1925 (eval $ac_compile) 2>&5
1926 ac_status=$?
1927 echo "$as_me:1927: \$? = $ac_status" >&5
1928 (exit "$ac_status"); } &&
1929 { ac_try='test -s "conftest.$ac_objext"'
1930 { (eval echo "$as_me:1930: \"$ac_try\"") >&5
1931 (eval $ac_try) 2>&5
1932 ac_status=$?
1933 echo "$as_me:1933: \$? = $ac_status" >&5
1934 (exit "$ac_status"); }; }; then
1935 break
1936 else
1937 echo "$as_me: failed program was:" >&5
1938 cat "conftest.$ac_ext" >&5
1939 fi
1940 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1941 done
1942 rm -rf conftest*
1943 if test -n "$ac_declaration"; then
1944 echo '#ifdef __cplusplus' >>confdefs.h
1945 echo "$ac_declaration" >>confdefs.h
1946 echo '#endif' >>confdefs.h
1947 fi
1948
1949 else
1950 echo "$as_me: failed program was:" >&5
1951 cat "conftest.$ac_ext" >&5
1952 fi
1953 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
1954 ac_ext=c
1955 ac_cpp='$CPP $CPPFLAGS'
1956 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
1957 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
1958 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1959 ac_main_return="return"
1960
1961 GCC_VERSION=none
1962 if test "$GCC" = yes ; then
1963 echo "$as_me:1963: checking version of $CC" >&5
1964 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
1965 GCC_VERSION="`${CC} --version 2>/dev/null | sed -e '2,$d' -e 's/^[^(]*([^)][^)]*) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
1966 test -z "$GCC_VERSION" && GCC_VERSION=unknown
1967 echo "$as_me:1967: result: $GCC_VERSION" >&5
1968 echo "${ECHO_T}$GCC_VERSION" >&6
1969 fi
1970
1971 INTEL_COMPILER=no
1972
1973 if test "$GCC" = yes ; then
1974 case "$host_os" in
1975 (linux*|gnu*)
1976 echo "$as_me:1976: checking if this is really Intel C compiler" >&5
1977 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
1978 cf_save_CFLAGS="$CFLAGS"
1979 CFLAGS="$CFLAGS -no-gcc"
1980 cat >"conftest.$ac_ext" <<_ACEOF
1981 #line 1981 "configure"
1982 #include "confdefs.h"
1983
1984 int
1985 main (void)
1986 {
1987
1988 #ifdef __INTEL_COMPILER
1989 #else
1990 #error __INTEL_COMPILER is not defined
1991 #endif
1992
1993 ;
1994 return 0;
1995 }
1996 _ACEOF
1997 rm -f "conftest.$ac_objext"
1998 if { (eval echo "$as_me:1998: \"$ac_compile\"") >&5
1999 (eval $ac_compile) 2>&5
2000 ac_status=$?
2001 echo "$as_me:2001: \$? = $ac_status" >&5
2002 (exit "$ac_status"); } &&
2003 { ac_try='test -s "conftest.$ac_objext"'
2004 { (eval echo "$as_me:2004: \"$ac_try\"") >&5
2005 (eval $ac_try) 2>&5
2006 ac_status=$?
2007 echo "$as_me:2007: \$? = $ac_status" >&5
2008 (exit "$ac_status"); }; }; then
2009 INTEL_COMPILER=yes
2010 cf_save_CFLAGS="$cf_save_CFLAGS -we147"
2011
2012 else
2013 echo "$as_me: failed program was:" >&5
2014 cat "conftest.$ac_ext" >&5
2015 fi
2016 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
2017 CFLAGS="$cf_save_CFLAGS"
2018 echo "$as_me:2018: result: $INTEL_COMPILER" >&5
2019 echo "${ECHO_T}$INTEL_COMPILER" >&6
2020 ;;
2021 esac
2022 fi
2023
2024 CLANG_COMPILER=no
2025
2026 if test "$GCC" = yes ; then
2027 echo "$as_me:2027: checking if this is really Clang C compiler" >&5
2028 echo $ECHO_N "checking if this is really Clang C compiler... $ECHO_C" >&6
2029 cf_save_CFLAGS="$CFLAGS"
2030 cat >"conftest.$ac_ext" <<_ACEOF
2031 #line 2031 "configure"
2032 #include "confdefs.h"
2033
2034 int
2035 main (void)
2036 {
2037
2038 #ifdef __clang__
2039 #else
2040 #error __clang__ is not defined
2041 #endif
2042
2043 ;
2044 return 0;
2045 }
2046 _ACEOF
2047 rm -f "conftest.$ac_objext"
2048 if { (eval echo "$as_me:2048: \"$ac_compile\"") >&5
2049 (eval $ac_compile) 2>&5
2050 ac_status=$?
2051 echo "$as_me:2051: \$? = $ac_status" >&5
2052 (exit "$ac_status"); } &&
2053 { ac_try='test -s "conftest.$ac_objext"'
2054 { (eval echo "$as_me:2054: \"$ac_try\"") >&5
2055 (eval $ac_try) 2>&5
2056 ac_status=$?
2057 echo "$as_me:2057: \$? = $ac_status" >&5
2058 (exit "$ac_status"); }; }; then
2059 CLANG_COMPILER=yes
2060
2061 else
2062 echo "$as_me: failed program was:" >&5
2063 cat "conftest.$ac_ext" >&5
2064 fi
2065 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
2066 CFLAGS="$cf_save_CFLAGS"
2067 echo "$as_me:2067: result: $CLANG_COMPILER" >&5
2068 echo "${ECHO_T}$CLANG_COMPILER" >&6
2069 fi
2070
2071 CLANG_VERSION=none
2072
2073 if test "x$CLANG_COMPILER" = "xyes" ; then
2074 case "$CC" in
2075 (c[1-9][0-9]|*/c[1-9][0-9])
2076 { echo "$as_me:2076: WARNING: replacing broken compiler alias $CC" >&5
2077 echo "$as_me: WARNING: replacing broken compiler alias $CC" >&2;}
2078 CFLAGS="$CFLAGS -std=`echo "$CC" | sed -e 's%.*/%%'`"
2079 CC=clang
2080 ;;
2081 esac
2082
2083 echo "$as_me:2083: checking version of $CC" >&5
2084 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
2085 CLANG_VERSION="`$CC --version 2>/dev/null | sed -e '2,$d' -e 's/^.*(CLANG[^)]*) //' -e 's/^.*(Debian[^)]*) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
2086 test -z "$CLANG_VERSION" && CLANG_VERSION=unknown
2087 echo "$as_me:2087: result: $CLANG_VERSION" >&5
2088 echo "${ECHO_T}$CLANG_VERSION" >&6
2089
2090 for cf_clang_opt in \
2091 -Qunused-arguments \
2092 -Wno-error=implicit-function-declaration
2093 do
2094 echo "$as_me:2094: checking if option $cf_clang_opt works" >&5
2095 echo $ECHO_N "checking if option $cf_clang_opt works... $ECHO_C" >&6
2096 cf_save_CFLAGS="$CFLAGS"
2097 CFLAGS="$CFLAGS $cf_clang_opt"
2098 cat >"conftest.$ac_ext" <<_ACEOF
2099 #line 2099 "configure"
2100 #include "confdefs.h"
2101
2102 #include <stdio.h>
2103 int
2104 main (void)
2105 {
2106
2107 printf("hello!\\n");
2108 ;
2109 return 0;
2110 }
2111 _ACEOF
2112 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
2113 if { (eval echo "$as_me:2113: \"$ac_link\"") >&5
2114 (eval $ac_link) 2>&5
2115 ac_status=$?
2116 echo "$as_me:2116: \$? = $ac_status" >&5
2117 (exit "$ac_status"); } &&
2118 { ac_try='test -s "conftest$ac_exeext"'
2119 { (eval echo "$as_me:2119: \"$ac_try\"") >&5
2120 (eval $ac_try) 2>&5
2121 ac_status=$?
2122 echo "$as_me:2122: \$? = $ac_status" >&5
2123 (exit "$ac_status"); }; }; then
2124
2125 cf_clang_optok=yes
2126 else
2127 echo "$as_me: failed program was:" >&5
2128 cat "conftest.$ac_ext" >&5
2129
2130 cf_clang_optok=no
2131 fi
2132 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
2133 echo "$as_me:2133: result: $cf_clang_optok" >&5
2134 echo "${ECHO_T}$cf_clang_optok" >&6
2135 CFLAGS="$cf_save_CFLAGS"
2136 if test "$cf_clang_optok" = yes; then
2137 test -n "$verbose" && echo " adding option $cf_clang_opt" 1>&6
2138
2139 echo "${as_me:-configure}:2139: testing adding option $cf_clang_opt ..." 1>&5
2140
2141 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2142 CFLAGS="${CFLAGS}$cf_clang_opt"
2143
2144 fi
2145 done
2146 fi
2147
2148 echo "$as_me:2148: checking for $CC option to accept ANSI C" >&5
2149 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2150 if test "${ac_cv_prog_cc_stdc+set}" = set; then
2151 echo $ECHO_N "(cached) $ECHO_C" >&6
2152 else
2153 ac_cv_prog_cc_stdc=no
2154 ac_save_CC=$CC
2155 cat >"conftest.$ac_ext" <<_ACEOF
2156 #line 2156 "configure"
2157 #include "confdefs.h"
2158 #include <stdarg.h>
2159 #include <stdio.h>
2160 #include <sys/types.h>
2161 #include <sys/stat.h>
2162 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
2163 struct buf { int x; };
2164 FILE * (*rcsopen) (struct buf *, struct stat *, int);
2165 static char *e (char **p, int i)
2166 {
2167 return p[i];
2168 }
2169 static char *f (char * (*g) (char **, int), char **p, ...)
2170 {
2171 char *s;
2172 va_list v;
2173 va_start (v,p);
2174 s = g (p, va_arg (v,int));
2175 va_end (v);
2176 return s;
2177 }
2178 int test (int i, double x);
2179 struct s1 {int (*f) (int a);};
2180 struct s2 {int (*f) (double a);};
2181 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2182 int argc;
2183 int
2184 main (void)
2185 {
2186 char *argv[3];
2187 static char first_arg[] = "first";
2188 static char other_arg[] = "other";
2189 argv[0] = first_arg;
2190 argv[1] = other_arg;
2191 argv[2] = NULL;
2192 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
2193 ;
2194 return 0;
2195 }
2196 _ACEOF
2197 # Don't try gcc -ansi; that turns off useful extensions and
2198 # breaks some systems' header files.
2199 # AIX -qlanglvl=ansi
2200 # Ultrix and OSF/1 -std1
2201 # HP-UX 10.20 and later -Ae
2202 # HP-UX older versions -Aa -D_HPUX_SOURCE
2203 # SVR4 -Xc -D__EXTENSIONS__
2204 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2205 do
2206 CC="$ac_save_CC $ac_arg"
2207 rm -f "conftest.$ac_objext"
2208 if { (eval echo "$as_me:2208: \"$ac_compile\"") >&5
2209 (eval $ac_compile) 2>&5
2210 ac_status=$?
2211 echo "$as_me:2211: \$? = $ac_status" >&5
2212 (exit "$ac_status"); } &&
2213 { ac_try='test -s "conftest.$ac_objext"'
2214 { (eval echo "$as_me:2214: \"$ac_try\"") >&5
2215 (eval $ac_try) 2>&5
2216 ac_status=$?
2217 echo "$as_me:2217: \$? = $ac_status" >&5
2218 (exit "$ac_status"); }; }; then
2219 ac_cv_prog_cc_stdc=$ac_arg
2220 break
2221 else
2222 echo "$as_me: failed program was:" >&5
2223 cat "conftest.$ac_ext" >&5
2224 fi
2225 rm -f "conftest.$ac_objext"
2226 done
2227 rm -f "conftest.$ac_ext" "conftest.$ac_objext"
2228 CC=$ac_save_CC
2229
2230 fi
2231
2232 case "x$ac_cv_prog_cc_stdc" in
2233 x|xno)
2234 echo "$as_me:2234: result: none needed" >&5
2235 echo "${ECHO_T}none needed" >&6 ;;
2236 *)
2237 echo "$as_me:2237: result: $ac_cv_prog_cc_stdc" >&5
2238 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2239 CC="$CC $ac_cv_prog_cc_stdc" ;;
2240 esac
2241
2242 # This should have been defined by AC_PROG_CC
2243 : "${CC:=cc}"
2244
2245 echo "$as_me:2245: checking \$CFLAGS variable" >&5
2246 echo $ECHO_N "checking \$CFLAGS variable... $ECHO_C" >&6
2247 case "x$CFLAGS" in
2248 (*-[IUD]*)
2249 echo "$as_me:2249: result: broken" >&5
2250 echo "${ECHO_T}broken" >&6
2251 { echo "$as_me:2251: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&5
2252 echo "$as_me: WARNING: your environment uses the CFLAGS variable to hold CPPFLAGS options" >&2;}
2253 cf_flags="$CFLAGS"
2254 CFLAGS=
2255 for cf_arg in $cf_flags
2256 do
2257
2258 cf_fix_cppflags=no
2259 cf_new_cflags=
2260 cf_new_cppflags=
2261 cf_new_extra_cppflags=
2262
2263 for cf_add_cflags in $cf_arg
2264 do
2265 case "$cf_fix_cppflags" in
2266 (no)
2267 case "$cf_add_cflags" in
2268 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2269 case "$cf_add_cflags" in
2270 (-D*)
2271 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2272
2273 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2274 && test -z "${cf_tst_cflags}" \
2275 && cf_fix_cppflags=yes
2276
2277 if test "$cf_fix_cppflags" = yes ; then
2278
2279 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2280 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2281
2282 continue
2283 elif test "${cf_tst_cflags}" = "\"'" ; then
2284
2285 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2286 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2287
2288 continue
2289 fi
2290 ;;
2291 esac
2292 case "$CPPFLAGS" in
2293 (*$cf_add_cflags)
2294 ;;
2295 (*)
2296 case "$cf_add_cflags" in
2297 (-D*)
2298 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2299
2300 CPPFLAGS=`echo "$CPPFLAGS" | \
2301 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2302 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2303
2304 ;;
2305 esac
2306
2307 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2308 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2309
2310 ;;
2311 esac
2312 ;;
2313 (*)
2314
2315 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2316 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2317
2318 ;;
2319 esac
2320 ;;
2321 (yes)
2322
2323 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2324 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2325
2326 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
2327
2328 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2329 && test -z "${cf_tst_cflags}" \
2330 && cf_fix_cppflags=no
2331 ;;
2332 esac
2333 done
2334
2335 if test -n "$cf_new_cflags" ; then
2336
2337 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2338 CFLAGS="${CFLAGS}$cf_new_cflags"
2339
2340 fi
2341
2342 if test -n "$cf_new_cppflags" ; then
2343
2344 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2345 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2346
2347 fi
2348
2349 if test -n "$cf_new_extra_cppflags" ; then
2350
2351 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2352 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2353
2354 fi
2355
2356 done
2357 ;;
2358 (*)
2359 echo "$as_me:2359: result: ok" >&5
2360 echo "${ECHO_T}ok" >&6
2361 ;;
2362 esac
2363
2364 echo "$as_me:2364: checking \$CC variable" >&5
2365 echo $ECHO_N "checking \$CC variable... $ECHO_C" >&6
2366 case "$CC" in
2367 (*[\ \ ]-*)
2368 echo "$as_me:2368: result: broken" >&5
2369 echo "${ECHO_T}broken" >&6
2370 { echo "$as_me:2370: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&5
2371 echo "$as_me: WARNING: your environment uses the CC variable to hold CFLAGS/CPPFLAGS options" >&2;}
2372 # humor him...
2373 cf_prog=`echo "$CC" | sed -e 's/ / /g' -e 's/[ ]* / /g' -e 's/[ ]*[ ]-[^ ].*//'`
2374 cf_flags=`echo "$CC" | sed -e "s%^$cf_prog%%"`
2375 CC="$cf_prog"
2376 for cf_arg in $cf_flags
2377 do
2378 case "x$cf_arg" in
2379 (x-[IUDfgOW]*)
2380
2381 cf_fix_cppflags=no
2382 cf_new_cflags=
2383 cf_new_cppflags=
2384 cf_new_extra_cppflags=
2385
2386 for cf_add_cflags in $cf_arg
2387 do
2388 case "$cf_fix_cppflags" in
2389 (no)
2390 case "$cf_add_cflags" in
2391 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
2392 case "$cf_add_cflags" in
2393 (-D*)
2394 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
2395
2396 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2397 && test -z "${cf_tst_cflags}" \
2398 && cf_fix_cppflags=yes
2399
2400 if test "$cf_fix_cppflags" = yes ; then
2401
2402 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2403 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2404
2405 continue
2406 elif test "${cf_tst_cflags}" = "\"'" ; then
2407
2408 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2409 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2410
2411 continue
2412 fi
2413 ;;
2414 esac
2415 case "$CPPFLAGS" in
2416 (*$cf_add_cflags)
2417 ;;
2418 (*)
2419 case "$cf_add_cflags" in
2420 (-D*)
2421 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
2422
2423 CPPFLAGS=`echo "$CPPFLAGS" | \
2424 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
2425 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
2426
2427 ;;
2428 esac
2429
2430 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
2431 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
2432
2433 ;;
2434 esac
2435 ;;
2436 (*)
2437
2438 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
2439 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
2440
2441 ;;
2442 esac
2443 ;;
2444 (yes)
2445
2446 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
2447 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
2448
2449 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
2450
2451 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
2452 && test -z "${cf_tst_cflags}" \
2453 && cf_fix_cppflags=no
2454 ;;
2455 esac
2456 done
2457
2458 if test -n "$cf_new_cflags" ; then
2459
2460 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
2461 CFLAGS="${CFLAGS}$cf_new_cflags"
2462
2463 fi
2464
2465 if test -n "$cf_new_cppflags" ; then
2466
2467 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
2468 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
2469
2470 fi
2471
2472 if test -n "$cf_new_extra_cppflags" ; then
2473
2474 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
2475 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
2476
2477 fi
2478
2479 ;;
2480 (*)
2481 CC="$CC $cf_arg"
2482 ;;
2483 esac
2484 done
2485 test -n "$verbose" && echo " resulting CC: '$CC'" 1>&6
2486
2487 echo "${as_me:-configure}:2487: testing resulting CC: '$CC' ..." 1>&5
2488
2489 test -n "$verbose" && echo " resulting CFLAGS: '$CFLAGS'" 1>&6
2490
2491 echo "${as_me:-configure}:2491: testing resulting CFLAGS: '$CFLAGS' ..." 1>&5
2492
2493 test -n "$verbose" && echo " resulting CPPFLAGS: '$CPPFLAGS'" 1>&6
2494
2495 echo "${as_me:-configure}:2495: testing resulting CPPFLAGS: '$CPPFLAGS' ..." 1>&5
2496
2497 ;;
2498 (*)
2499 echo "$as_me:2499: result: ok" >&5
2500 echo "${ECHO_T}ok" >&6
2501 ;;
2502 esac
2503
2504 echo "$as_me:2504: checking for inline" >&5
2505 echo $ECHO_N "checking for inline... $ECHO_C" >&6
2506 if test "${ac_cv_c_inline+set}" = set; then
2507 echo $ECHO_N "(cached) $ECHO_C" >&6
2508 else
2509 ac_cv_c_inline=no
2510 for ac_kw in inline __inline__ __inline; do
2511 cat >"conftest.$ac_ext" <<_ACEOF
2512 #line 2512 "configure"
2513 #include "confdefs.h"
2514 #ifndef __cplusplus
2515 static $ac_kw int static_foo (void) {return 0; }
2516 $ac_kw int foo (void) {return 0; }
2517 #endif
2518
2519 _ACEOF
2520 rm -f "conftest.$ac_objext"
2521 if { (eval echo "$as_me:2521: \"$ac_compile\"") >&5
2522 (eval $ac_compile) 2>&5
2523 ac_status=$?
2524 echo "$as_me:2524: \$? = $ac_status" >&5
2525 (exit "$ac_status"); } &&
2526 { ac_try='test -s "conftest.$ac_objext"'
2527 { (eval echo "$as_me:2527: \"$ac_try\"") >&5
2528 (eval $ac_try) 2>&5
2529 ac_status=$?
2530 echo "$as_me:2530: \$? = $ac_status" >&5
2531 (exit "$ac_status"); }; }; then
2532 ac_cv_c_inline=$ac_kw; break
2533 else
2534 echo "$as_me: failed program was:" >&5
2535 cat "conftest.$ac_ext" >&5
2536 fi
2537 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
2538 done
2539
2540 fi
2541 echo "$as_me:2541: result: $ac_cv_c_inline" >&5
2542 echo "${ECHO_T}$ac_cv_c_inline" >&6
2543 case $ac_cv_c_inline in
2544 inline | yes) ;;
2545 no)
2546 cat >>confdefs.h <<\EOF
2547 #define inline
2548 EOF
2549 ;;
2550 *) cat >>confdefs.h <<EOF
2551 #define inline $ac_cv_c_inline
2552 EOF
2553 ;;
2554 esac
2555
2556 for ac_prog in ggrep grep
2557 do
2558 # Extract the first word of "$ac_prog", so it can be a program name with args.
2559 set dummy $ac_prog; ac_word=$2
2560 echo "$as_me:2560: checking for $ac_word" >&5
2561 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2562 if test "${ac_cv_prog_GREP+set}" = set; then
2563 echo $ECHO_N "(cached) $ECHO_C" >&6
2564 else
2565 if test -n "$GREP"; then
2566 ac_cv_prog_GREP="$GREP" # Let the user override the test.
2567 else
2568 ac_save_IFS=$IFS; IFS=$ac_path_separator
2569 ac_dummy="$PATH"
2570 for ac_dir in $ac_dummy; do
2571 IFS=$ac_save_IFS
2572 test -z "$ac_dir" && ac_dir=.
2573 $as_executable_p "$ac_dir/$ac_word" || continue
2574 ac_cv_prog_GREP="$ac_prog"
2575 echo "$as_me:2575: found $ac_dir/$ac_word" >&5
2576 break
2577 done
2578
2579 fi
2580 fi
2581 GREP=$ac_cv_prog_GREP
2582 if test -n "$GREP"; then
2583 echo "$as_me:2583: result: $GREP" >&5
2584 echo "${ECHO_T}$GREP" >&6
2585 else
2586 echo "$as_me:2586: result: no" >&5
2587 echo "${ECHO_T}no" >&6
2588 fi
2589
2590 test -n "$GREP" && break
2591 done
2592 test -n "$GREP" || GREP=": "
2593
2594 echo "$as_me:2594: checking for egrep" >&5
2595 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
2596 if test "${ac_cv_path_EGREP+set}" = set; then
2597 echo $ECHO_N "(cached) $ECHO_C" >&6
2598 else
2599 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
2600 then ac_cv_path_EGREP="$GREP -E"
2601 else
2602 for ac_prog in gegrep egrep
2603 do
2604 # Extract the first word of "$ac_prog", so it can be a program name with args.
2605 set dummy $ac_prog; ac_word=$2
2606 echo "$as_me:2606: checking for $ac_word" >&5
2607 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2608 if test "${ac_cv_path_EGREP+set}" = set; then
2609 echo $ECHO_N "(cached) $ECHO_C" >&6
2610 else
2611 case $EGREP in
2612 [\\/]* | ?:[\\/]*)
2613 ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path.
2614 ;;
2615 *)
2616 ac_save_IFS=$IFS; IFS=$ac_path_separator
2617 ac_dummy="$PATH"
2618 for ac_dir in $ac_dummy; do
2619 IFS=$ac_save_IFS
2620 test -z "$ac_dir" && ac_dir=.
2621 if $as_executable_p "$ac_dir/$ac_word"; then
2622 ac_cv_path_EGREP="$ac_dir/$ac_word"
2623 echo "$as_me:2623: found $ac_dir/$ac_word" >&5
2624 break
2625 fi
2626 done
2627
2628 ;;
2629 esac
2630 fi
2631 EGREP=$ac_cv_path_EGREP
2632
2633 if test -n "$EGREP"; then
2634 echo "$as_me:2634: result: $EGREP" >&5
2635 echo "${ECHO_T}$EGREP" >&6
2636 else
2637 echo "$as_me:2637: result: no" >&5
2638 echo "${ECHO_T}no" >&6
2639 fi
2640
2641 test -n "$EGREP" && break
2642 done
2643 test -n "$EGREP" || EGREP=": "
2644
2645 test "x$ac_cv_path_EGREP" = "x:" && { { echo "$as_me:2645: error: cannot find workable egrep" >&5
2646 echo "$as_me: error: cannot find workable egrep" >&2;}
2647 { (exit 1); exit 1; }; }
2648 fi
2649 fi
2650 echo "$as_me:2650: result: $ac_cv_path_EGREP" >&5
2651 echo "${ECHO_T}$ac_cv_path_EGREP" >&6
2652 EGREP="$ac_cv_path_EGREP"
2653
2654 ac_ext=c
2655 ac_cpp='$CPP $CPPFLAGS'
2656 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
2657 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
2658 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2659 ac_main_return="return"
2660 echo "$as_me:2660: checking how to run the C preprocessor" >&5
2661 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2662 # On Suns, sometimes $CPP names a directory.
2663 if test -n "$CPP" && test -d "$CPP"; then
2664 CPP=
2665 fi
2666 if test -z "$CPP"; then
2667 if test "${ac_cv_prog_CPP+set}" = set; then
2668 echo $ECHO_N "(cached) $ECHO_C" >&6
2669 else
2670 # Double quotes because CPP needs to be expanded
2671 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2672 do
2673 ac_preproc_ok=false
2674 for ac_c_preproc_warn_flag in '' yes
2675 do
2676 # Use a header file that comes with gcc, so configuring glibc
2677 # with a fresh cross-compiler works.
2678 # On the NeXT, cc -E runs the code through the compiler's parser,
2679 # not just through cpp. "Syntax error" is here to catch this case.
2680 cat >"conftest.$ac_ext" <<_ACEOF
2681 #line 2681 "configure"
2682 #include "confdefs.h"
2683 #include <assert.h>
2684 Syntax error
2685 _ACEOF
2686 if { (eval echo "$as_me:2686: \"$ac_cpp "conftest.$ac_ext"\"") >&5
2687 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
2688 ac_status=$?
2689 $EGREP -v '^ *\+' conftest.er1 >conftest.err
2690 rm -f conftest.er1
2691 cat conftest.err >&5
2692 echo "$as_me:2692: \$? = $ac_status" >&5
2693 (exit "$ac_status"); } >/dev/null; then
2694 if test -s conftest.err; then
2695 ac_cpp_err=$ac_c_preproc_warn_flag
2696 else
2697 ac_cpp_err=
2698 fi
2699 else
2700 ac_cpp_err=yes
2701 fi
2702 if test -z "$ac_cpp_err"; then
2703 :
2704 else
2705 echo "$as_me: failed program was:" >&5
2706 cat "conftest.$ac_ext" >&5
2707 # Broken: fails on valid input.
2708 continue
2709 fi
2710 rm -f conftest.err "conftest.$ac_ext"
2711
2712 # OK, works on sane cases. Now check whether non-existent headers
2713 # can be detected and how.
2714 cat >"conftest.$ac_ext" <<_ACEOF
2715 #line 2715 "configure"
2716 #include "confdefs.h"
2717 #include <ac_nonexistent.h>
2718 _ACEOF
2719 if { (eval echo "$as_me:2719: \"$ac_cpp "conftest.$ac_ext"\"") >&5
2720 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
2721 ac_status=$?
2722 $EGREP -v '^ *\+' conftest.er1 >conftest.err
2723 rm -f conftest.er1
2724 cat conftest.err >&5
2725 echo "$as_me:2725: \$? = $ac_status" >&5
2726 (exit "$ac_status"); } >/dev/null; then
2727 if test -s conftest.err; then
2728 ac_cpp_err=$ac_c_preproc_warn_flag
2729 else
2730 ac_cpp_err=
2731 fi
2732 else
2733 ac_cpp_err=yes
2734 fi
2735 if test -z "$ac_cpp_err"; then
2736 # Broken: success on invalid input.
2737 continue
2738 else
2739 echo "$as_me: failed program was:" >&5
2740 cat "conftest.$ac_ext" >&5
2741 # Passes both tests.
2742 ac_preproc_ok=:
2743 break
2744 fi
2745 rm -f conftest.err "conftest.$ac_ext"
2746
2747 done
2748 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2749 rm -f conftest.err "conftest.$ac_ext"
2750 if $ac_preproc_ok; then
2751 break
2752 fi
2753
2754 done
2755 ac_cv_prog_CPP=$CPP
2756
2757 fi
2758 CPP=$ac_cv_prog_CPP
2759 else
2760 ac_cv_prog_CPP=$CPP
2761 fi
2762 echo "$as_me:2762: result: $CPP" >&5
2763 echo "${ECHO_T}$CPP" >&6
2764 ac_preproc_ok=false
2765 for ac_c_preproc_warn_flag in '' yes
2766 do
2767 # Use a header file that comes with gcc, so configuring glibc
2768 # with a fresh cross-compiler works.
2769 # On the NeXT, cc -E runs the code through the compiler's parser,
2770 # not just through cpp. "Syntax error" is here to catch this case.
2771 cat >"conftest.$ac_ext" <<_ACEOF
2772 #line 2772 "configure"
2773 #include "confdefs.h"
2774 #include <assert.h>
2775 Syntax error
2776 _ACEOF
2777 if { (eval echo "$as_me:2777: \"$ac_cpp "conftest.$ac_ext"\"") >&5
2778 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
2779 ac_status=$?
2780 $EGREP -v '^ *\+' conftest.er1 >conftest.err
2781 rm -f conftest.er1
2782 cat conftest.err >&5
2783 echo "$as_me:2783: \$? = $ac_status" >&5
2784 (exit "$ac_status"); } >/dev/null; then
2785 if test -s conftest.err; then
2786 ac_cpp_err=$ac_c_preproc_warn_flag
2787 else
2788 ac_cpp_err=
2789 fi
2790 else
2791 ac_cpp_err=yes
2792 fi
2793 if test -z "$ac_cpp_err"; then
2794 :
2795 else
2796 echo "$as_me: failed program was:" >&5
2797 cat "conftest.$ac_ext" >&5
2798 # Broken: fails on valid input.
2799 continue
2800 fi
2801 rm -f conftest.err "conftest.$ac_ext"
2802
2803 # OK, works on sane cases. Now check whether non-existent headers
2804 # can be detected and how.
2805 cat >"conftest.$ac_ext" <<_ACEOF
2806 #line 2806 "configure"
2807 #include "confdefs.h"
2808 #include <ac_nonexistent.h>
2809 _ACEOF
2810 if { (eval echo "$as_me:2810: \"$ac_cpp "conftest.$ac_ext"\"") >&5
2811 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
2812 ac_status=$?
2813 $EGREP -v '^ *\+' conftest.er1 >conftest.err
2814 rm -f conftest.er1
2815 cat conftest.err >&5
2816 echo "$as_me:2816: \$? = $ac_status" >&5
2817 (exit "$ac_status"); } >/dev/null; then
2818 if test -s conftest.err; then
2819 ac_cpp_err=$ac_c_preproc_warn_flag
2820 else
2821 ac_cpp_err=
2822 fi
2823 else
2824 ac_cpp_err=yes
2825 fi
2826 if test -z "$ac_cpp_err"; then
2827 # Broken: success on invalid input.
2828 continue
2829 else
2830 echo "$as_me: failed program was:" >&5
2831 cat "conftest.$ac_ext" >&5
2832 # Passes both tests.
2833 ac_preproc_ok=:
2834 break
2835 fi
2836 rm -f conftest.err "conftest.$ac_ext"
2837
2838 done
2839 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2840 rm -f conftest.err "conftest.$ac_ext"
2841 if $ac_preproc_ok; then
2842 :
2843 else
2844 { { echo "$as_me:2844: error: C preprocessor \"$CPP\" fails sanity check" >&5
2845 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2846 { (exit 1); exit 1; }; }
2847 fi
2848
2849 ac_ext=c
2850 ac_cpp='$CPP $CPPFLAGS'
2851 ac_compile='$CC -c $CFLAGS $CPPFLAGS "conftest.$ac_ext" >&5'
2852 ac_link='$CC -o "conftest$ac_exeext" $CFLAGS $CPPFLAGS $LDFLAGS "conftest.$ac_ext" $LIBS >&5'
2853 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2854 ac_main_return="return"
2855
2856 for ac_prog in mawk gawk nawk awk
2857 do
2858 # Extract the first word of "$ac_prog", so it can be a program name with args.
2859 set dummy $ac_prog; ac_word=$2
2860 echo "$as_me:2860: checking for $ac_word" >&5
2861 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2862 if test "${ac_cv_prog_AWK+set}" = set; then
2863 echo $ECHO_N "(cached) $ECHO_C" >&6
2864 else
2865 if test -n "$AWK"; then
2866 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2867 else
2868 ac_save_IFS=$IFS; IFS=$ac_path_separator
2869 ac_dummy="$PATH"
2870 for ac_dir in $ac_dummy; do
2871 IFS=$ac_save_IFS
2872 test -z "$ac_dir" && ac_dir=.
2873 $as_executable_p "$ac_dir/$ac_word" || continue
2874 ac_cv_prog_AWK="$ac_prog"
2875 echo "$as_me:2875: found $ac_dir/$ac_word" >&5
2876 break
2877 done
2878
2879 fi
2880 fi
2881 AWK=$ac_cv_prog_AWK
2882 if test -n "$AWK"; then
2883 echo "$as_me:2883: result: $AWK" >&5
2884 echo "${ECHO_T}$AWK" >&6
2885 else
2886 echo "$as_me:2886: result: no" >&5
2887 echo "${ECHO_T}no" >&6
2888 fi
2889
2890 test -n "$AWK" && break
2891 done
2892
2893 if test -f "$srcdir/config.guess" || test -f "$ac_aux_dir/config.guess" ; then
2894 echo "$as_me:2894: checking target system type" >&5
2895 echo $ECHO_N "checking target system type... $ECHO_C" >&6
2896 if test "${ac_cv_target+set}" = set; then
2897 echo $ECHO_N "(cached) $ECHO_C" >&6
2898 else
2899 ac_cv_target_alias=$target_alias
2900 test "x$ac_cv_target_alias" = "x" &&
2901 ac_cv_target_alias=$ac_cv_host_alias
2902 ac_cv_target=`$ac_config_sub "$ac_cv_target_alias"` ||
2903 { { echo "$as_me:2903: error: $ac_config_sub $ac_cv_target_alias failed" >&5
2904 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
2905 { (exit 1); exit 1; }; }
2906
2907 fi
2908 echo "$as_me:2908: result: $ac_cv_target" >&5
2909 echo "${ECHO_T}$ac_cv_target" >&6
2910 target=$ac_cv_target
2911 target_cpu=`echo "$ac_cv_target" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
2912 target_vendor=`echo "$ac_cv_target" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
2913 target_os=`echo "$ac_cv_target" | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
2914
2915 # The aliases save the names the user supplied, while $host etc.
2916 # will get canonicalized.
2917 test -n "$target_alias" &&
2918 test "$program_prefix$program_suffix$program_transform_name" = \
2919 NONENONEs,x,x, &&
2920 program_prefix=${target_alias}-
2921 system_name="$host_os"
2922 else
2923 system_name="`(uname -s -r) 2>/dev/null`"
2924 if test -z "$system_name" ; then
2925 system_name="`(hostname) 2>/dev/null`"
2926 fi
2927 fi
2928 test -n "$system_name" &&
2929 cat >>confdefs.h <<EOF
2930 #define SYSTEM_NAME "$system_name"
2931 EOF
2932
2933 if test "${cf_cv_system_name+set}" = set; then
2934 echo $ECHO_N "(cached) $ECHO_C" >&6
2935 else
2936 cf_cv_system_name="$system_name"
2937 fi
2938
2939 test -z "$system_name" && system_name="$cf_cv_system_name"
2940 test -n "$cf_cv_system_name" && echo "$as_me:2940: result: Configuring for $cf_cv_system_name" >&5
2941 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
2942
2943 if test ".$system_name" != ".$cf_cv_system_name" ; then
2944 echo "$as_me:2944: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
2945 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
2946 { { echo "$as_me:2946: error: \"Please remove config.cache and try again.\"" >&5
2947 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
2948 { (exit 1); exit 1; }; }
2949 fi
2950
2951 # Check whether --with-system-type or --without-system-type was given.
2952 if test "${with_system_type+set}" = set; then
2953 withval="$with_system_type"
2954 { echo "$as_me:2954: WARNING: overriding system type to $withval" >&5
2955 echo "$as_me: WARNING: overriding system type to $withval" >&2;}
2956 cf_cv_system_name=$withval
2957 host_os=$withval
2958
2959 fi;
2960
2961 case "$cf_cv_system_name" in
2962 (cygwin*|msys*|mingw32*|mingw64|os2*)
2963 GLOB_FULLPATH_POSIX='/*'
2964 GLOB_FULLPATH_OTHER='[a-zA-Z]:[\\/]*'
2965 ;;
2966 (*)
2967 GLOB_FULLPATH_POSIX='/*'
2968 GLOB_FULLPATH_OTHER=$GLOB_FULLPATH_POSIX
2969 ;;
2970 esac
2971
2972 # Find a good install program. We prefer a C program (faster),
2973 # so one script is as good as another. But avoid the broken or
2974 # incompatible versions:
2975 # SysV /etc/install, /usr/sbin/install
2976 # SunOS /usr/etc/install
2977 # IRIX /sbin/install
2978 # AIX /bin/install
2979 # AmigaOS /C/install, which installs bootblocks on floppy discs
2980 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2981 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2982 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2983 # ./install, which can be erroneously created by make from ./install.sh.
2984 echo "$as_me:2984: checking for a BSD compatible install" >&5
2985 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
2986 if test -z "$INSTALL"; then
2987 if test "${ac_cv_path_install+set}" = set; then
2988 echo $ECHO_N "(cached) $ECHO_C" >&6
2989 else
2990 ac_save_IFS=$IFS; IFS=$ac_path_separator
2991 for ac_dir in $PATH; do
2992 IFS=$ac_save_IFS
2993 # Account for people who put trailing slashes in PATH elements.
2994 case $ac_dir/ in
2995 / | ./ | .// | /cC/* \
2996 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
2997 | /usr/ucb/* ) ;;
2998 *)
2999 # OSF1 and SCO ODT 3.0 have their own names for install.
3000 # Don't use installbsd from OSF since it installs stuff as root
3001 # by default.
3002 for ac_prog in ginstall scoinst install; do
3003 if $as_executable_p "$ac_dir/$ac_prog"; then
3004 if test $ac_prog = install &&
3005 grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
3006 # AIX install. It has an incompatible calling convention.
3007 :
3008 elif test $ac_prog = install &&
3009 grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
3010 # program-specific install script used by HP pwplus--don't use.
3011 :
3012 else
3013 ac_cv_path_install="$ac_dir/$ac_prog -c"
3014 break 2
3015 fi
3016 fi
3017 done
3018 ;;
3019 esac
3020 done
3021
3022 fi
3023 if test "${ac_cv_path_install+set}" = set; then
3024 INSTALL=$ac_cv_path_install
3025 else
3026 # As a last resort, use the slow shell script. We don't cache a
3027 # path for INSTALL within a source directory, because that will
3028 # break other packages using the cache if that directory is
3029 # removed, or if the path is relative.
3030 INSTALL=$ac_install_sh
3031 fi
3032 fi
3033 echo "$as_me:3033: result: $INSTALL" >&5
3034 echo "${ECHO_T}$INSTALL" >&6
3035
3036 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3037 # It thinks the first close brace ends the variable substitution.
3038 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3039
3040 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3041
3042 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3043
3044 if test "x$INSTALL" = "x./install-sh -c"; then
3045 if test -f /usr/sbin/install ; then
3046 case "$host_os" in
3047 (linux*gnu*|uclinux*|gnu*|mint*|k*bsd*-gnu|cygwin|msys|mingw*|linux*uclibc)
3048 INSTALL=/usr/sbin/install
3049 ;;
3050 esac
3051 fi
3052 fi
3053 case x$INSTALL in
3054 (x$GLOB_FULLPATH_POSIX|x$GLOB_FULLPATH_OTHER)
3055 ;;
3056 (*)
3057 cf_dir=`echo "$INSTALL" | sed -e 's%/[^/]*$%%'`
3058 test -z "$cf_dir" && cf_dir=.
3059 INSTALL="`cd \"$cf_dir\" && pwd`"/"`echo "$INSTALL" | sed -e 's%^.*/%%'`"
3060 ;;
3061 esac
3062
3063 echo "$as_me:3063: checking whether ln -s works" >&5
3064 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
3065 LN_S=$as_ln_s
3066 if test "$LN_S" = "ln -s"; then
3067 echo "$as_me:3067: result: yes" >&5
3068 echo "${ECHO_T}yes" >&6
3069 else
3070 echo "$as_me:3070: result: no, using $LN_S" >&5
3071 echo "${ECHO_T}no, using $LN_S" >&6
3072 fi
3073
3074 test "$program_prefix" != NONE &&
3075 program_transform_name="s,^,$program_prefix,;$program_transform_name"
3076 # Use a double $ so make ignores it.
3077 test "$program_suffix" != NONE &&
3078 program_transform_name="s,\$,$program_suffix,;$program_transform_name"
3079 # Double any \ or $. echo might interpret backslashes.
3080 # By default was `s,x,x', remove it if useless.
3081 cat <<\_ACEOF >conftest.sed
3082 s/[\\$]/&&/g;s/;s,x,x,$//
3083 _ACEOF
3084 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
3085 rm conftest.sed
3086
3087 for ac_prog in lint cppcheck splint
3088 do
3089 # Extract the first word of "$ac_prog", so it can be a program name with args.
3090 set dummy $ac_prog; ac_word=$2
3091 echo "$as_me:3091: checking for $ac_word" >&5
3092 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3093 if test "${ac_cv_prog_LINT+set}" = set; then
3094 echo $ECHO_N "(cached) $ECHO_C" >&6
3095 else
3096 if test -n "$LINT"; then
3097 ac_cv_prog_LINT="$LINT" # Let the user override the test.
3098 else
3099 ac_save_IFS=$IFS; IFS=$ac_path_separator
3100 ac_dummy="$PATH"
3101 for ac_dir in $ac_dummy; do
3102 IFS=$ac_save_IFS
3103 test -z "$ac_dir" && ac_dir=.
3104 $as_executable_p "$ac_dir/$ac_word" || continue
3105 ac_cv_prog_LINT="$ac_prog"
3106 echo "$as_me:3106: found $ac_dir/$ac_word" >&5
3107 break
3108 done
3109
3110 fi
3111 fi
3112 LINT=$ac_cv_prog_LINT
3113 if test -n "$LINT"; then
3114 echo "$as_me:3114: result: $LINT" >&5
3115 echo "${ECHO_T}$LINT" >&6
3116 else
3117 echo "$as_me:3117: result: no" >&5
3118 echo "${ECHO_T}no" >&6
3119 fi
3120
3121 test -n "$LINT" && break
3122 done
3123
3124 case "x$LINT" in
3125 (xlint|x*/lint) # NetBSD 10
3126 test -z "$LINT_OPTS" && LINT_OPTS="-chapbrxzgFS -v -Ac11"
3127 ;;
3128 (xcppcheck|x*/cppcheck)
3129 test -z "$LINT_OPTS" && LINT_OPTS="--enable=all -D__CPPCHECK__"
3130 ;;
3131 esac
3132
3133 echo "$as_me:3133: checking for \".PHONY\" make-support" >&5
3134 echo $ECHO_N "checking for \".PHONY\" make-support... $ECHO_C" >&6
3135 if test "${cf_cv_make_PHONY+set}" = set; then
3136 echo $ECHO_N "(cached) $ECHO_C" >&6
3137 else
3138
3139 rm -rf conftest*
3140 (
3141 mkdir conftest || exit 1
3142 cd conftest
3143 cat >makefile <<'CF_EOF'
3144 .PHONY: always
3145 DATA=0
3146 always: always.out
3147 @echo "** making $@ $(DATA)"
3148 once: once.out
3149 @echo "** making $@ $(DATA)"
3150 always.out:
3151 @echo "** making $@ $(DATA)"
3152 echo $(DATA) > $@
3153 once.out:
3154 @echo "** making $@ $(DATA)"
3155 echo $(DATA) > $@
3156 CF_EOF
3157 for cf_data in 1 2 3
3158 do
3159 ${MAKE:-make} always DATA=$cf_data
3160 ${MAKE:-make} once DATA=$cf_data
3161 ${MAKE:-make} -t always once
3162 if test -f always ; then
3163 echo "no (case 1)" > ../conftest.tmp
3164 elif test ! -f always.out ; then
3165 echo "no (case 2)" > ../conftest.tmp
3166 elif test ! -f once.out ; then
3167 echo "no (case 3)" > ../conftest.tmp
3168 elif ! cmp -s always.out once.out ; then
3169 echo "no (case 4)" > ../conftest.tmp
3170 diff always.out once.out
3171 else
3172 cf_check="`cat always.out`"
3173 if test "x$cf_check" != "x$cf_data" ; then
3174 echo "no (case 5)" > ../conftest.tmp
3175 else
3176 echo yes > ../conftest.tmp
3177 rm -f ./*.out
3178 continue
3179 fi
3180 fi
3181 break
3182 done
3183 ) >&5 2>&1
3184 cf_cv_make_PHONY="`cat conftest.tmp`"
3185 rm -rf conftest*
3186
3187 fi
3188 echo "$as_me:3188: result: $cf_cv_make_PHONY" >&5
3189 echo "${ECHO_T}$cf_cv_make_PHONY" >&6
3190 MAKE_NO_PHONY="#"
3191 MAKE_PHONY="#"
3192 test "x$cf_cv_make_PHONY" = xyes && MAKE_PHONY=
3193 test "x$cf_cv_make_PHONY" != xyes && MAKE_NO_PHONY=
3194
3195 ### checks for compiler characteristics
3196
3197 echo "$as_me:3197: checking if the POSIX test-macros are already defined" >&5
3198 echo $ECHO_N "checking if the POSIX test-macros are already defined... $ECHO_C" >&6
3199 if test "${cf_cv_posix_visible+set}" = set; then
3200 echo $ECHO_N "(cached) $ECHO_C" >&6
3201 else
3202
3203 cat >"conftest.$ac_ext" <<_ACEOF
3204 #line 3204 "configure"
3205 #include "confdefs.h"
3206 #include <stdio.h>
3207 int
3208 main (void)
3209 {
3210
3211 #if defined(__POSIX_VISIBLE) && ((__POSIX_VISIBLE - 0L) > 0) \
3212 && defined(__XSI_VISIBLE) && ((__XSI_VISIBLE - 0L) > 0) \
3213 && defined(__BSD_VISIBLE) && ((__BSD_VISIBLE - 0L) > 0) \
3214 && defined(__ISO_C_VISIBLE) && ((__ISO_C_VISIBLE - 0L) > 0)
3215 #error conflicting symbols found
3216 #endif
3217
3218 ;
3219 return 0;
3220 }
3221 _ACEOF
3222 rm -f "conftest.$ac_objext"
3223 if { (eval echo "$as_me:3223: \"$ac_compile\"") >&5
3224 (eval $ac_compile) 2>&5
3225 ac_status=$?
3226 echo "$as_me:3226: \$? = $ac_status" >&5
3227 (exit "$ac_status"); } &&
3228 { ac_try='test -s "conftest.$ac_objext"'
3229 { (eval echo "$as_me:3229: \"$ac_try\"") >&5
3230 (eval $ac_try) 2>&5
3231 ac_status=$?
3232 echo "$as_me:3232: \$? = $ac_status" >&5
3233 (exit "$ac_status"); }; }; then
3234 cf_cv_posix_visible=no
3235 else
3236 echo "$as_me: failed program was:" >&5
3237 cat "conftest.$ac_ext" >&5
3238 cf_cv_posix_visible=yes
3239 fi
3240 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3241
3242 fi
3243 echo "$as_me:3243: result: $cf_cv_posix_visible" >&5
3244 echo "${ECHO_T}$cf_cv_posix_visible" >&6
3245
3246 if test "$cf_cv_posix_visible" = no; then
3247
3248 cf_XOPEN_SOURCE=700
3249 cf_POSIX_C_SOURCE=199506L
3250 cf_xopen_source=
3251
3252 case "$host_os" in
3253 (aix[4-7]*)
3254 cf_xopen_source="-D_ALL_SOURCE"
3255 ;;
3256 (darwin[0-8].*)
3257 cf_xopen_source="-D_APPLE_C_SOURCE"
3258 ;;
3259 (darwin*)
3260 cf_xopen_source="-D_DARWIN_C_SOURCE"
3261 cf_XOPEN_SOURCE=
3262 ;;
3263 (freebsd*|dragonfly*|midnightbsd*)
3264 # 5.x headers associate
3265 # _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
3266 # _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
3267 cf_POSIX_C_SOURCE=200112L
3268 cf_XOPEN_SOURCE=600
3269 cf_xopen_source="-D_BSD_TYPES -D__BSD_VISIBLE -D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
3270 ;;
3271 (hpux11*)
3272 cf_xopen_source="-D_HPUX_SOURCE -D_XOPEN_SOURCE=500"
3273 ;;
3274 (hpux*)
3275 cf_xopen_source="-D_HPUX_SOURCE"
3276 ;;
3277 (irix[56].*)
3278 cf_xopen_source="-D_SGI_SOURCE"
3279 cf_XOPEN_SOURCE=
3280 ;;
3281 (linux*gnu*|uclinux*|gnu*|mint*|k*bsd*-gnu|cygwin|msys|mingw*|linux*uclibc)
3282
3283 cf_gnu_xopen_source=$cf_XOPEN_SOURCE
3284
3285 echo "$as_me:3285: checking if this is the GNU C library" >&5
3286 echo $ECHO_N "checking if this is the GNU C library... $ECHO_C" >&6
3287 if test "${cf_cv_gnu_library+set}" = set; then
3288 echo $ECHO_N "(cached) $ECHO_C" >&6
3289 else
3290
3291 cat >"conftest.$ac_ext" <<_ACEOF
3292 #line 3292 "configure"
3293 #include "confdefs.h"
3294 #include <sys/types.h>
3295 int
3296 main (void)
3297 {
3298
3299 #if __GLIBC__ > 0 && __GLIBC_MINOR__ >= 0
3300 return 0;
3301 #elif __NEWLIB__ > 0 && __NEWLIB_MINOR__ >= 0
3302 return 0;
3303 #else
3304 # error not GNU C library
3305 #endif
3306 ;
3307 return 0;
3308 }
3309 _ACEOF
3310 rm -f "conftest.$ac_objext"
3311 if { (eval echo "$as_me:3311: \"$ac_compile\"") >&5
3312 (eval $ac_compile) 2>&5
3313 ac_status=$?
3314 echo "$as_me:3314: \$? = $ac_status" >&5
3315 (exit "$ac_status"); } &&
3316 { ac_try='test -s "conftest.$ac_objext"'
3317 { (eval echo "$as_me:3317: \"$ac_try\"") >&5
3318 (eval $ac_try) 2>&5
3319 ac_status=$?
3320 echo "$as_me:3320: \$? = $ac_status" >&5
3321 (exit "$ac_status"); }; }; then
3322 cf_cv_gnu_library=yes
3323 else
3324 echo "$as_me: failed program was:" >&5
3325 cat "conftest.$ac_ext" >&5
3326 cf_cv_gnu_library=no
3327 fi
3328 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3329
3330 fi
3331 echo "$as_me:3331: result: $cf_cv_gnu_library" >&5
3332 echo "${ECHO_T}$cf_cv_gnu_library" >&6
3333
3334 if test x$cf_cv_gnu_library = xyes; then
3335
3336 # With glibc 2.19 (13 years after this check was begun), _DEFAULT_SOURCE
3337 # was changed to help a little. newlib incorporated the change about 4
3338 # years later.
3339 echo "$as_me:3339: checking if _DEFAULT_SOURCE can be used as a basis" >&5
3340 echo $ECHO_N "checking if _DEFAULT_SOURCE can be used as a basis... $ECHO_C" >&6
3341 if test "${cf_cv_gnu_library_219+set}" = set; then
3342 echo $ECHO_N "(cached) $ECHO_C" >&6
3343 else
3344
3345 cf_save="$CPPFLAGS"
3346
3347 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3348 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
3349
3350 cat >"conftest.$ac_ext" <<_ACEOF
3351 #line 3351 "configure"
3352 #include "confdefs.h"
3353 #include <sys/types.h>
3354 int
3355 main (void)
3356 {
3357
3358 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 19) || (__GLIBC__ > 2)
3359 return 0;
3360 #elif (__NEWLIB__ == 2 && __NEWLIB_MINOR__ >= 4) || (__GLIBC__ > 3)
3361 return 0;
3362 #else
3363 # error GNU C library __GLIBC__.__GLIBC_MINOR__ is too old
3364 #endif
3365 ;
3366 return 0;
3367 }
3368 _ACEOF
3369 rm -f "conftest.$ac_objext"
3370 if { (eval echo "$as_me:3370: \"$ac_compile\"") >&5
3371 (eval $ac_compile) 2>&5
3372 ac_status=$?
3373 echo "$as_me:3373: \$? = $ac_status" >&5
3374 (exit "$ac_status"); } &&
3375 { ac_try='test -s "conftest.$ac_objext"'
3376 { (eval echo "$as_me:3376: \"$ac_try\"") >&5
3377 (eval $ac_try) 2>&5
3378 ac_status=$?
3379 echo "$as_me:3379: \$? = $ac_status" >&5
3380 (exit "$ac_status"); }; }; then
3381 cf_cv_gnu_library_219=yes
3382 else
3383 echo "$as_me: failed program was:" >&5
3384 cat "conftest.$ac_ext" >&5
3385 cf_cv_gnu_library_219=no
3386 fi
3387 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3388 CPPFLAGS="$cf_save"
3389
3390 fi
3391 echo "$as_me:3391: result: $cf_cv_gnu_library_219" >&5
3392 echo "${ECHO_T}$cf_cv_gnu_library_219" >&6
3393
3394 if test "x$cf_cv_gnu_library_219" = xyes; then
3395 cf_save="$CPPFLAGS"
3396 echo "$as_me:3396: checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE" >&5
3397 echo $ECHO_N "checking if _XOPEN_SOURCE=$cf_gnu_xopen_source works with _DEFAULT_SOURCE... $ECHO_C" >&6
3398 if test "${cf_cv_gnu_dftsrc_219+set}" = set; then
3399 echo $ECHO_N "(cached) $ECHO_C" >&6
3400 else
3401
3402 cf_fix_cppflags=no
3403 cf_new_cflags=
3404 cf_new_cppflags=
3405 cf_new_extra_cppflags=
3406
3407 for cf_add_cflags in -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=$cf_gnu_xopen_source
3408 do
3409 case "$cf_fix_cppflags" in
3410 (no)
3411 case "$cf_add_cflags" in
3412 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
3413 case "$cf_add_cflags" in
3414 (-D*)
3415 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3416
3417 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3418 && test -z "${cf_tst_cflags}" \
3419 && cf_fix_cppflags=yes
3420
3421 if test "$cf_fix_cppflags" = yes ; then
3422
3423 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3424 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3425
3426 continue
3427 elif test "${cf_tst_cflags}" = "\"'" ; then
3428
3429 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3430 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3431
3432 continue
3433 fi
3434 ;;
3435 esac
3436 case "$CPPFLAGS" in
3437 (*$cf_add_cflags)
3438 ;;
3439 (*)
3440 case "$cf_add_cflags" in
3441 (-D*)
3442 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3443
3444 CPPFLAGS=`echo "$CPPFLAGS" | \
3445 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3446 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3447
3448 ;;
3449 esac
3450
3451 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
3452 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
3453
3454 ;;
3455 esac
3456 ;;
3457 (*)
3458
3459 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
3460 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
3461
3462 ;;
3463 esac
3464 ;;
3465 (yes)
3466
3467 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3468 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3469
3470 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
3471
3472 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3473 && test -z "${cf_tst_cflags}" \
3474 && cf_fix_cppflags=no
3475 ;;
3476 esac
3477 done
3478
3479 if test -n "$cf_new_cflags" ; then
3480
3481 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
3482 CFLAGS="${CFLAGS}$cf_new_cflags"
3483
3484 fi
3485
3486 if test -n "$cf_new_cppflags" ; then
3487
3488 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3489 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
3490
3491 fi
3492
3493 if test -n "$cf_new_extra_cppflags" ; then
3494
3495 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
3496 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
3497
3498 fi
3499
3500 cat >"conftest.$ac_ext" <<_ACEOF
3501 #line 3501 "configure"
3502 #include "confdefs.h"
3503
3504 #include <limits.h>
3505 #include <sys/types.h>
3506
3507 int
3508 main (void)
3509 {
3510
3511 #if (_XOPEN_SOURCE >= $cf_gnu_xopen_source) && (MB_LEN_MAX > 1)
3512 return 0;
3513 #else
3514 # error GNU C library is too old
3515 #endif
3516 ;
3517 return 0;
3518 }
3519 _ACEOF
3520 rm -f "conftest.$ac_objext"
3521 if { (eval echo "$as_me:3521: \"$ac_compile\"") >&5
3522 (eval $ac_compile) 2>&5
3523 ac_status=$?
3524 echo "$as_me:3524: \$? = $ac_status" >&5
3525 (exit "$ac_status"); } &&
3526 { ac_try='test -s "conftest.$ac_objext"'
3527 { (eval echo "$as_me:3527: \"$ac_try\"") >&5
3528 (eval $ac_try) 2>&5
3529 ac_status=$?
3530 echo "$as_me:3530: \$? = $ac_status" >&5
3531 (exit "$ac_status"); }; }; then
3532 cf_cv_gnu_dftsrc_219=yes
3533 else
3534 echo "$as_me: failed program was:" >&5
3535 cat "conftest.$ac_ext" >&5
3536 cf_cv_gnu_dftsrc_219=no
3537 fi
3538 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3539
3540 fi
3541 echo "$as_me:3541: result: $cf_cv_gnu_dftsrc_219" >&5
3542 echo "${ECHO_T}$cf_cv_gnu_dftsrc_219" >&6
3543 test "x$cf_cv_gnu_dftsrc_219" = "xyes" || CPPFLAGS="$cf_save"
3544 else
3545 cf_cv_gnu_dftsrc_219=maybe
3546 fi
3547
3548 if test "x$cf_cv_gnu_dftsrc_219" != xyes; then
3549
3550 echo "$as_me:3550: checking if we must define _GNU_SOURCE" >&5
3551 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
3552 if test "${cf_cv_gnu_source+set}" = set; then
3553 echo $ECHO_N "(cached) $ECHO_C" >&6
3554 else
3555
3556 cat >"conftest.$ac_ext" <<_ACEOF
3557 #line 3557 "configure"
3558 #include "confdefs.h"
3559 #include <sys/types.h>
3560 int
3561 main (void)
3562 {
3563
3564 #ifndef _XOPEN_SOURCE
3565 #error expected _XOPEN_SOURCE to be defined
3566 #endif
3567 ;
3568 return 0;
3569 }
3570 _ACEOF
3571 rm -f "conftest.$ac_objext"
3572 if { (eval echo "$as_me:3572: \"$ac_compile\"") >&5
3573 (eval $ac_compile) 2>&5
3574 ac_status=$?
3575 echo "$as_me:3575: \$? = $ac_status" >&5
3576 (exit "$ac_status"); } &&
3577 { ac_try='test -s "conftest.$ac_objext"'
3578 { (eval echo "$as_me:3578: \"$ac_try\"") >&5
3579 (eval $ac_try) 2>&5
3580 ac_status=$?
3581 echo "$as_me:3581: \$? = $ac_status" >&5
3582 (exit "$ac_status"); }; }; then
3583 cf_cv_gnu_source=no
3584 else
3585 echo "$as_me: failed program was:" >&5
3586 cat "conftest.$ac_ext" >&5
3587 cf_save="$CPPFLAGS"
3588
3589 cf_fix_cppflags=no
3590 cf_new_cflags=
3591 cf_new_cppflags=
3592 cf_new_extra_cppflags=
3593
3594 for cf_add_cflags in -D_GNU_SOURCE
3595 do
3596 case "$cf_fix_cppflags" in
3597 (no)
3598 case "$cf_add_cflags" in
3599 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
3600 case "$cf_add_cflags" in
3601 (-D*)
3602 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3603
3604 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3605 && test -z "${cf_tst_cflags}" \
3606 && cf_fix_cppflags=yes
3607
3608 if test "$cf_fix_cppflags" = yes ; then
3609
3610 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3611 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3612
3613 continue
3614 elif test "${cf_tst_cflags}" = "\"'" ; then
3615
3616 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3617 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3618
3619 continue
3620 fi
3621 ;;
3622 esac
3623 case "$CPPFLAGS" in
3624 (*$cf_add_cflags)
3625 ;;
3626 (*)
3627 case "$cf_add_cflags" in
3628 (-D*)
3629 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
3630
3631 CPPFLAGS=`echo "$CPPFLAGS" | \
3632 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
3633 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
3634
3635 ;;
3636 esac
3637
3638 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
3639 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
3640
3641 ;;
3642 esac
3643 ;;
3644 (*)
3645
3646 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
3647 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
3648
3649 ;;
3650 esac
3651 ;;
3652 (yes)
3653
3654 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3655 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3656
3657 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
3658
3659 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3660 && test -z "${cf_tst_cflags}" \
3661 && cf_fix_cppflags=no
3662 ;;
3663 esac
3664 done
3665
3666 if test -n "$cf_new_cflags" ; then
3667
3668 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
3669 CFLAGS="${CFLAGS}$cf_new_cflags"
3670
3671 fi
3672
3673 if test -n "$cf_new_cppflags" ; then
3674
3675 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3676 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
3677
3678 fi
3679
3680 if test -n "$cf_new_extra_cppflags" ; then
3681
3682 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
3683 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
3684
3685 fi
3686
3687 cat >"conftest.$ac_ext" <<_ACEOF
3688 #line 3688 "configure"
3689 #include "confdefs.h"
3690 #include <sys/types.h>
3691 int
3692 main (void)
3693 {
3694
3695 #ifdef _XOPEN_SOURCE
3696 #error expected _XOPEN_SOURCE to be undefined
3697 #endif
3698 ;
3699 return 0;
3700 }
3701 _ACEOF
3702 rm -f "conftest.$ac_objext"
3703 if { (eval echo "$as_me:3703: \"$ac_compile\"") >&5
3704 (eval $ac_compile) 2>&5
3705 ac_status=$?
3706 echo "$as_me:3706: \$? = $ac_status" >&5
3707 (exit "$ac_status"); } &&
3708 { ac_try='test -s "conftest.$ac_objext"'
3709 { (eval echo "$as_me:3709: \"$ac_try\"") >&5
3710 (eval $ac_try) 2>&5
3711 ac_status=$?
3712 echo "$as_me:3712: \$? = $ac_status" >&5
3713 (exit "$ac_status"); }; }; then
3714 cf_cv_gnu_source=no
3715 else
3716 echo "$as_me: failed program was:" >&5
3717 cat "conftest.$ac_ext" >&5
3718 cf_cv_gnu_source=yes
3719 fi
3720 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3721 CPPFLAGS="$cf_save"
3722
3723 fi
3724 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3725
3726 fi
3727 echo "$as_me:3727: result: $cf_cv_gnu_source" >&5
3728 echo "${ECHO_T}$cf_cv_gnu_source" >&6
3729
3730 if test "$cf_cv_gnu_source" = yes
3731 then
3732 echo "$as_me:3732: checking if we should also define _DEFAULT_SOURCE" >&5
3733 echo $ECHO_N "checking if we should also define _DEFAULT_SOURCE... $ECHO_C" >&6
3734 if test "${cf_cv_default_source+set}" = set; then
3735 echo $ECHO_N "(cached) $ECHO_C" >&6
3736 else
3737
3738 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3739 CPPFLAGS="${CPPFLAGS}-D_GNU_SOURCE"
3740
3741 cat >"conftest.$ac_ext" <<_ACEOF
3742 #line 3742 "configure"
3743 #include "confdefs.h"
3744 #include <sys/types.h>
3745 int
3746 main (void)
3747 {
3748
3749 #ifdef _DEFAULT_SOURCE
3750 #error expected _DEFAULT_SOURCE to be undefined
3751 #endif
3752 ;
3753 return 0;
3754 }
3755 _ACEOF
3756 rm -f "conftest.$ac_objext"
3757 if { (eval echo "$as_me:3757: \"$ac_compile\"") >&5
3758 (eval $ac_compile) 2>&5
3759 ac_status=$?
3760 echo "$as_me:3760: \$? = $ac_status" >&5
3761 (exit "$ac_status"); } &&
3762 { ac_try='test -s "conftest.$ac_objext"'
3763 { (eval echo "$as_me:3763: \"$ac_try\"") >&5
3764 (eval $ac_try) 2>&5
3765 ac_status=$?
3766 echo "$as_me:3766: \$? = $ac_status" >&5
3767 (exit "$ac_status"); }; }; then
3768 cf_cv_default_source=no
3769 else
3770 echo "$as_me: failed program was:" >&5
3771 cat "conftest.$ac_ext" >&5
3772 cf_cv_default_source=yes
3773 fi
3774 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3775
3776 fi
3777 echo "$as_me:3777: result: $cf_cv_default_source" >&5
3778 echo "${ECHO_T}$cf_cv_default_source" >&6
3779 if test "$cf_cv_default_source" = yes
3780 then
3781
3782 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3783 CPPFLAGS="${CPPFLAGS}-D_DEFAULT_SOURCE"
3784
3785 fi
3786 fi
3787 fi
3788
3789 fi
3790
3791 ;;
3792 linux*musl)
3793 cf_xopen_source="-D_BSD_SOURCE"
3794 ;;
3795 (minix*)
3796 cf_xopen_source="-D_NETBSD_SOURCE" # POSIX.1-2001 features are ifdef'd with this...
3797 ;;
3798 (mirbsd*)
3799 # setting _XOPEN_SOURCE or _POSIX_SOURCE breaks <sys/select.h> and other headers which use u_int / u_short types
3800 cf_XOPEN_SOURCE=
3801
3802 if test "$cf_cv_posix_visible" = no; then
3803
3804 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
3805
3806 cf_save_CFLAGS="$CFLAGS"
3807 cf_save_CPPFLAGS="$CPPFLAGS"
3808
3809 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
3810 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3811 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3812
3813 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
3814 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
3815 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
3816
3817 echo "$as_me:3817: checking if we should define _POSIX_C_SOURCE" >&5
3818 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
3819 if test "${cf_cv_posix_c_source+set}" = set; then
3820 echo $ECHO_N "(cached) $ECHO_C" >&6
3821 else
3822
3823 echo "${as_me:-configure}:3823: testing if the symbol is already defined go no further ..." 1>&5
3824
3825 cat >"conftest.$ac_ext" <<_ACEOF
3826 #line 3826 "configure"
3827 #include "confdefs.h"
3828 #include <sys/types.h>
3829 int
3830 main (void)
3831 {
3832
3833 #ifndef _POSIX_C_SOURCE
3834 #error _POSIX_C_SOURCE is not defined
3835 #endif
3836 ;
3837 return 0;
3838 }
3839 _ACEOF
3840 rm -f "conftest.$ac_objext"
3841 if { (eval echo "$as_me:3841: \"$ac_compile\"") >&5
3842 (eval $ac_compile) 2>&5
3843 ac_status=$?
3844 echo "$as_me:3844: \$? = $ac_status" >&5
3845 (exit "$ac_status"); } &&
3846 { ac_try='test -s "conftest.$ac_objext"'
3847 { (eval echo "$as_me:3847: \"$ac_try\"") >&5
3848 (eval $ac_try) 2>&5
3849 ac_status=$?
3850 echo "$as_me:3850: \$? = $ac_status" >&5
3851 (exit "$ac_status"); }; }; then
3852 cf_cv_posix_c_source=no
3853 else
3854 echo "$as_me: failed program was:" >&5
3855 cat "conftest.$ac_ext" >&5
3856 cf_want_posix_source=no
3857 case .$cf_POSIX_C_SOURCE in
3858 (.[12]??*)
3859 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3860 ;;
3861 (.2)
3862 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
3863 cf_want_posix_source=yes
3864 ;;
3865 (.*)
3866 cf_want_posix_source=yes
3867 ;;
3868 esac
3869 if test "$cf_want_posix_source" = yes ; then
3870 cat >"conftest.$ac_ext" <<_ACEOF
3871 #line 3871 "configure"
3872 #include "confdefs.h"
3873 #include <sys/types.h>
3874 int
3875 main (void)
3876 {
3877
3878 #ifdef _POSIX_SOURCE
3879 #error _POSIX_SOURCE is defined
3880 #endif
3881 ;
3882 return 0;
3883 }
3884 _ACEOF
3885 rm -f "conftest.$ac_objext"
3886 if { (eval echo "$as_me:3886: \"$ac_compile\"") >&5
3887 (eval $ac_compile) 2>&5
3888 ac_status=$?
3889 echo "$as_me:3889: \$? = $ac_status" >&5
3890 (exit "$ac_status"); } &&
3891 { ac_try='test -s "conftest.$ac_objext"'
3892 { (eval echo "$as_me:3892: \"$ac_try\"") >&5
3893 (eval $ac_try) 2>&5
3894 ac_status=$?
3895 echo "$as_me:3895: \$? = $ac_status" >&5
3896 (exit "$ac_status"); }; }; then
3897 :
3898 else
3899 echo "$as_me: failed program was:" >&5
3900 cat "conftest.$ac_ext" >&5
3901 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
3902 fi
3903 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3904 fi
3905
3906 echo "${as_me:-configure}:3906: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
3907
3908 CFLAGS="$cf_trim_CFLAGS"
3909 CPPFLAGS="$cf_trim_CPPFLAGS"
3910
3911 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
3912 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
3913
3914 echo "${as_me:-configure}:3914: testing if the second compile does not leave our definition intact error ..." 1>&5
3915
3916 cat >"conftest.$ac_ext" <<_ACEOF
3917 #line 3917 "configure"
3918 #include "confdefs.h"
3919 #include <sys/types.h>
3920 int
3921 main (void)
3922 {
3923
3924 #ifndef _POSIX_C_SOURCE
3925 #error _POSIX_C_SOURCE is not defined
3926 #endif
3927 ;
3928 return 0;
3929 }
3930 _ACEOF
3931 rm -f "conftest.$ac_objext"
3932 if { (eval echo "$as_me:3932: \"$ac_compile\"") >&5
3933 (eval $ac_compile) 2>&5
3934 ac_status=$?
3935 echo "$as_me:3935: \$? = $ac_status" >&5
3936 (exit "$ac_status"); } &&
3937 { ac_try='test -s "conftest.$ac_objext"'
3938 { (eval echo "$as_me:3938: \"$ac_try\"") >&5
3939 (eval $ac_try) 2>&5
3940 ac_status=$?
3941 echo "$as_me:3941: \$? = $ac_status" >&5
3942 (exit "$ac_status"); }; }; then
3943 :
3944 else
3945 echo "$as_me: failed program was:" >&5
3946 cat "conftest.$ac_ext" >&5
3947 cf_cv_posix_c_source=no
3948 fi
3949 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3950 CFLAGS="$cf_save_CFLAGS"
3951 CPPFLAGS="$cf_save_CPPFLAGS"
3952
3953 fi
3954 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
3955
3956 fi
3957 echo "$as_me:3957: result: $cf_cv_posix_c_source" >&5
3958 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
3959
3960 if test "$cf_cv_posix_c_source" != no ; then
3961 CFLAGS="$cf_trim_CFLAGS"
3962 CPPFLAGS="$cf_trim_CPPFLAGS"
3963
3964 cf_fix_cppflags=no
3965 cf_new_cflags=
3966 cf_new_cppflags=
3967 cf_new_extra_cppflags=
3968
3969 for cf_add_cflags in $cf_cv_posix_c_source
3970 do
3971 case "$cf_fix_cppflags" in
3972 (no)
3973 case "$cf_add_cflags" in
3974 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
3975 case "$cf_add_cflags" in
3976 (-D*)
3977 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
3978
3979 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
3980 && test -z "${cf_tst_cflags}" \
3981 && cf_fix_cppflags=yes
3982
3983 if test "$cf_fix_cppflags" = yes ; then
3984
3985 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3986 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3987
3988 continue
3989 elif test "${cf_tst_cflags}" = "\"'" ; then
3990
3991 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
3992 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
3993
3994 continue
3995 fi
3996 ;;
3997 esac
3998 case "$CPPFLAGS" in
3999 (*$cf_add_cflags)
4000 ;;
4001 (*)
4002 case "$cf_add_cflags" in
4003 (-D*)
4004 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4005
4006 CPPFLAGS=`echo "$CPPFLAGS" | \
4007 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4008 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4009
4010 ;;
4011 esac
4012
4013 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4014 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4015
4016 ;;
4017 esac
4018 ;;
4019 (*)
4020
4021 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4022 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4023
4024 ;;
4025 esac
4026 ;;
4027 (yes)
4028
4029 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4030 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4031
4032 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4033
4034 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4035 && test -z "${cf_tst_cflags}" \
4036 && cf_fix_cppflags=no
4037 ;;
4038 esac
4039 done
4040
4041 if test -n "$cf_new_cflags" ; then
4042
4043 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4044 CFLAGS="${CFLAGS}$cf_new_cflags"
4045
4046 fi
4047
4048 if test -n "$cf_new_cppflags" ; then
4049
4050 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4051 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4052
4053 fi
4054
4055 if test -n "$cf_new_extra_cppflags" ; then
4056
4057 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4058 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4059
4060 fi
4061
4062 fi
4063
4064 fi # cf_cv_posix_visible
4065
4066 ;;
4067 (netbsd*)
4068 cf_xopen_source="-D_NETBSD_SOURCE" # setting _XOPEN_SOURCE breaks IPv6 for lynx on NetBSD 1.6, breaks xterm, is not needed for ncursesw
4069 ;;
4070 (openbsd[6-9]*)
4071 # OpenBSD 6.x has broken locale support, both compile-time and runtime.
4072 # see https://www.mail-archive.com/[email protected]/msg13200.html
4073 # Abusing the conformance level is a workaround.
4074 { echo "$as_me:4074: WARNING: this system does not provide usable locale support" >&5
4075 echo "$as_me: WARNING: this system does not provide usable locale support" >&2;}
4076 cf_xopen_source="-D_BSD_SOURCE"
4077 cf_XOPEN_SOURCE=700
4078 ;;
4079 (openbsd[4-5]*)
4080 # setting _XOPEN_SOURCE lower than 500 breaks g++ compile with wchar.h, needed for ncursesw
4081 cf_xopen_source="-D_BSD_SOURCE"
4082 cf_XOPEN_SOURCE=600
4083 ;;
4084 (openbsd*)
4085 # setting _XOPEN_SOURCE breaks xterm on OpenBSD 2.8, is not needed for ncursesw
4086 ;;
4087 (osf[45]*)
4088 cf_xopen_source="-D_OSF_SOURCE"
4089 ;;
4090 (nto-qnx*)
4091 cf_xopen_source="-D_QNX_SOURCE"
4092 ;;
4093 (sco*)
4094 # setting _XOPEN_SOURCE breaks Lynx on SCO Unix / OpenServer
4095 ;;
4096 (solaris2.*)
4097 cf_xopen_source="-D__EXTENSIONS__"
4098 cf_cv_xopen_source=broken
4099 ;;
4100 (sysv4.2uw2.*) # Novell/SCO UnixWare 2.x (tested on 2.1.2)
4101 cf_XOPEN_SOURCE=
4102 cf_POSIX_C_SOURCE=
4103 ;;
4104 (*)
4105
4106 echo "$as_me:4106: checking if we should define _XOPEN_SOURCE" >&5
4107 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
4108 if test "${cf_cv_xopen_source+set}" = set; then
4109 echo $ECHO_N "(cached) $ECHO_C" >&6
4110 else
4111
4112 cat >"conftest.$ac_ext" <<_ACEOF
4113 #line 4113 "configure"
4114 #include "confdefs.h"
4115
4116 $ac_includes_default
4117
4118 int
4119 main (void)
4120 {
4121
4122 #ifndef _XOPEN_SOURCE
4123 #error _XOPEN_SOURCE is not defined
4124 #endif
4125
4126 ;
4127 return 0;
4128 }
4129 _ACEOF
4130 rm -f "conftest.$ac_objext"
4131 if { (eval echo "$as_me:4131: \"$ac_compile\"") >&5
4132 (eval $ac_compile) 2>&5
4133 ac_status=$?
4134 echo "$as_me:4134: \$? = $ac_status" >&5
4135 (exit "$ac_status"); } &&
4136 { ac_try='test -s "conftest.$ac_objext"'
4137 { (eval echo "$as_me:4137: \"$ac_try\"") >&5
4138 (eval $ac_try) 2>&5
4139 ac_status=$?
4140 echo "$as_me:4140: \$? = $ac_status" >&5
4141 (exit "$ac_status"); }; }; then
4142 cf_cv_xopen_source=no
4143 else
4144 echo "$as_me: failed program was:" >&5
4145 cat "conftest.$ac_ext" >&5
4146 cf_save="$CPPFLAGS"
4147
4148 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4149 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
4150
4151 cat >"conftest.$ac_ext" <<_ACEOF
4152 #line 4152 "configure"
4153 #include "confdefs.h"
4154
4155 $ac_includes_default
4156
4157 int
4158 main (void)
4159 {
4160
4161 #ifndef _XOPEN_SOURCE
4162 #error _XOPEN_SOURCE is not defined
4163 #endif
4164
4165 ;
4166 return 0;
4167 }
4168 _ACEOF
4169 rm -f "conftest.$ac_objext"
4170 if { (eval echo "$as_me:4170: \"$ac_compile\"") >&5
4171 (eval $ac_compile) 2>&5
4172 ac_status=$?
4173 echo "$as_me:4173: \$? = $ac_status" >&5
4174 (exit "$ac_status"); } &&
4175 { ac_try='test -s "conftest.$ac_objext"'
4176 { (eval echo "$as_me:4176: \"$ac_try\"") >&5
4177 (eval $ac_try) 2>&5
4178 ac_status=$?
4179 echo "$as_me:4179: \$? = $ac_status" >&5
4180 (exit "$ac_status"); }; }; then
4181 cf_cv_xopen_source=no
4182 else
4183 echo "$as_me: failed program was:" >&5
4184 cat "conftest.$ac_ext" >&5
4185 cf_cv_xopen_source=$cf_XOPEN_SOURCE
4186 fi
4187 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4188 CPPFLAGS="$cf_save"
4189
4190 fi
4191 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4192
4193 fi
4194 echo "$as_me:4194: result: $cf_cv_xopen_source" >&5
4195 echo "${ECHO_T}$cf_cv_xopen_source" >&6
4196
4197 if test "$cf_cv_xopen_source" != no ; then
4198
4199 CFLAGS=`echo "$CFLAGS" | \
4200 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4201 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4202
4203 CPPFLAGS=`echo "$CPPFLAGS" | \
4204 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4205 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4206
4207 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
4208
4209 for cf_add_cflags in $cf_temp_xopen_source
4210 do
4211 case "x$cf_add_cflags" in
4212 (x-[DU]*)
4213
4214 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
4215 while true
4216 do
4217 cf_old_cflag=`echo "x$CFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
4218 test "$CFLAGS" != "$cf_old_cflag" || break
4219
4220 CFLAGS="$cf_old_cflag"
4221 done
4222
4223 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
4224 while true
4225 do
4226 cf_old_cflag=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
4227 test "$CPPFLAGS" != "$cf_old_cflag" || break
4228
4229 CPPFLAGS="$cf_old_cflag"
4230 done
4231
4232 ;;
4233 esac
4234
4235 cf_fix_cppflags=no
4236 cf_new_cflags=
4237 cf_new_cppflags=
4238 cf_new_extra_cppflags=
4239
4240 for cf_add_cflags in $cf_add_cflags
4241 do
4242 case "$cf_fix_cppflags" in
4243 (no)
4244 case "$cf_add_cflags" in
4245 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4246 case "$cf_add_cflags" in
4247 (-D*)
4248 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4249
4250 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4251 && test -z "${cf_tst_cflags}" \
4252 && cf_fix_cppflags=yes
4253
4254 if test "$cf_fix_cppflags" = yes ; then
4255
4256 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4257 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4258
4259 continue
4260 elif test "${cf_tst_cflags}" = "\"'" ; then
4261
4262 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4263 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4264
4265 continue
4266 fi
4267 ;;
4268 esac
4269 case "$CPPFLAGS" in
4270 (*$cf_add_cflags)
4271 ;;
4272 (*)
4273 case "$cf_add_cflags" in
4274 (-D*)
4275 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4276
4277 CPPFLAGS=`echo "$CPPFLAGS" | \
4278 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4279 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4280
4281 ;;
4282 esac
4283
4284 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4285 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4286
4287 ;;
4288 esac
4289 ;;
4290 (*)
4291
4292 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4293 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4294
4295 ;;
4296 esac
4297 ;;
4298 (yes)
4299
4300 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4301 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4302
4303 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4304
4305 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4306 && test -z "${cf_tst_cflags}" \
4307 && cf_fix_cppflags=no
4308 ;;
4309 esac
4310 done
4311
4312 if test -n "$cf_new_cflags" ; then
4313
4314 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4315 CFLAGS="${CFLAGS}$cf_new_cflags"
4316
4317 fi
4318
4319 if test -n "$cf_new_cppflags" ; then
4320
4321 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4322 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4323
4324 fi
4325
4326 if test -n "$cf_new_extra_cppflags" ; then
4327
4328 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4329 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4330
4331 fi
4332
4333 done
4334
4335 fi
4336
4337 cf_save_xopen_cppflags="$CPPFLAGS"
4338
4339 if test "$cf_cv_posix_visible" = no; then
4340
4341 cf_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE
4342
4343 cf_save_CFLAGS="$CFLAGS"
4344 cf_save_CPPFLAGS="$CPPFLAGS"
4345
4346 cf_trim_CFLAGS=`echo "$cf_save_CFLAGS" | \
4347 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4348 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4349
4350 cf_trim_CPPFLAGS=`echo "$cf_save_CPPFLAGS" | \
4351 sed -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4352 -e 's/-[UD]'"_POSIX_C_SOURCE"'\(=[^ ]*\)\?$//g'`
4353
4354 echo "$as_me:4354: checking if we should define _POSIX_C_SOURCE" >&5
4355 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
4356 if test "${cf_cv_posix_c_source+set}" = set; then
4357 echo $ECHO_N "(cached) $ECHO_C" >&6
4358 else
4359
4360 echo "${as_me:-configure}:4360: testing if the symbol is already defined go no further ..." 1>&5
4361
4362 cat >"conftest.$ac_ext" <<_ACEOF
4363 #line 4363 "configure"
4364 #include "confdefs.h"
4365 #include <sys/types.h>
4366 int
4367 main (void)
4368 {
4369
4370 #ifndef _POSIX_C_SOURCE
4371 #error _POSIX_C_SOURCE is not defined
4372 #endif
4373 ;
4374 return 0;
4375 }
4376 _ACEOF
4377 rm -f "conftest.$ac_objext"
4378 if { (eval echo "$as_me:4378: \"$ac_compile\"") >&5
4379 (eval $ac_compile) 2>&5
4380 ac_status=$?
4381 echo "$as_me:4381: \$? = $ac_status" >&5
4382 (exit "$ac_status"); } &&
4383 { ac_try='test -s "conftest.$ac_objext"'
4384 { (eval echo "$as_me:4384: \"$ac_try\"") >&5
4385 (eval $ac_try) 2>&5
4386 ac_status=$?
4387 echo "$as_me:4387: \$? = $ac_status" >&5
4388 (exit "$ac_status"); }; }; then
4389 cf_cv_posix_c_source=no
4390 else
4391 echo "$as_me: failed program was:" >&5
4392 cat "conftest.$ac_ext" >&5
4393 cf_want_posix_source=no
4394 case .$cf_POSIX_C_SOURCE in
4395 (.[12]??*)
4396 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4397 ;;
4398 (.2)
4399 cf_cv_posix_c_source="-D_POSIX_C_SOURCE=$cf_POSIX_C_SOURCE"
4400 cf_want_posix_source=yes
4401 ;;
4402 (.*)
4403 cf_want_posix_source=yes
4404 ;;
4405 esac
4406 if test "$cf_want_posix_source" = yes ; then
4407 cat >"conftest.$ac_ext" <<_ACEOF
4408 #line 4408 "configure"
4409 #include "confdefs.h"
4410 #include <sys/types.h>
4411 int
4412 main (void)
4413 {
4414
4415 #ifdef _POSIX_SOURCE
4416 #error _POSIX_SOURCE is defined
4417 #endif
4418 ;
4419 return 0;
4420 }
4421 _ACEOF
4422 rm -f "conftest.$ac_objext"
4423 if { (eval echo "$as_me:4423: \"$ac_compile\"") >&5
4424 (eval $ac_compile) 2>&5
4425 ac_status=$?
4426 echo "$as_me:4426: \$? = $ac_status" >&5
4427 (exit "$ac_status"); } &&
4428 { ac_try='test -s "conftest.$ac_objext"'
4429 { (eval echo "$as_me:4429: \"$ac_try\"") >&5
4430 (eval $ac_try) 2>&5
4431 ac_status=$?
4432 echo "$as_me:4432: \$? = $ac_status" >&5
4433 (exit "$ac_status"); }; }; then
4434 :
4435 else
4436 echo "$as_me: failed program was:" >&5
4437 cat "conftest.$ac_ext" >&5
4438 cf_cv_posix_c_source="$cf_cv_posix_c_source -D_POSIX_SOURCE"
4439 fi
4440 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4441 fi
4442
4443 echo "${as_me:-configure}:4443: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
4444
4445 CFLAGS="$cf_trim_CFLAGS"
4446 CPPFLAGS="$cf_trim_CPPFLAGS"
4447
4448 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4449 CPPFLAGS="${CPPFLAGS}$cf_cv_posix_c_source"
4450
4451 echo "${as_me:-configure}:4451: testing if the second compile does not leave our definition intact error ..." 1>&5
4452
4453 cat >"conftest.$ac_ext" <<_ACEOF
4454 #line 4454 "configure"
4455 #include "confdefs.h"
4456 #include <sys/types.h>
4457 int
4458 main (void)
4459 {
4460
4461 #ifndef _POSIX_C_SOURCE
4462 #error _POSIX_C_SOURCE is not defined
4463 #endif
4464 ;
4465 return 0;
4466 }
4467 _ACEOF
4468 rm -f "conftest.$ac_objext"
4469 if { (eval echo "$as_me:4469: \"$ac_compile\"") >&5
4470 (eval $ac_compile) 2>&5
4471 ac_status=$?
4472 echo "$as_me:4472: \$? = $ac_status" >&5
4473 (exit "$ac_status"); } &&
4474 { ac_try='test -s "conftest.$ac_objext"'
4475 { (eval echo "$as_me:4475: \"$ac_try\"") >&5
4476 (eval $ac_try) 2>&5
4477 ac_status=$?
4478 echo "$as_me:4478: \$? = $ac_status" >&5
4479 (exit "$ac_status"); }; }; then
4480 :
4481 else
4482 echo "$as_me: failed program was:" >&5
4483 cat "conftest.$ac_ext" >&5
4484 cf_cv_posix_c_source=no
4485 fi
4486 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4487 CFLAGS="$cf_save_CFLAGS"
4488 CPPFLAGS="$cf_save_CPPFLAGS"
4489
4490 fi
4491 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4492
4493 fi
4494 echo "$as_me:4494: result: $cf_cv_posix_c_source" >&5
4495 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
4496
4497 if test "$cf_cv_posix_c_source" != no ; then
4498 CFLAGS="$cf_trim_CFLAGS"
4499 CPPFLAGS="$cf_trim_CPPFLAGS"
4500
4501 cf_fix_cppflags=no
4502 cf_new_cflags=
4503 cf_new_cppflags=
4504 cf_new_extra_cppflags=
4505
4506 for cf_add_cflags in $cf_cv_posix_c_source
4507 do
4508 case "$cf_fix_cppflags" in
4509 (no)
4510 case "$cf_add_cflags" in
4511 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4512 case "$cf_add_cflags" in
4513 (-D*)
4514 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4515
4516 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4517 && test -z "${cf_tst_cflags}" \
4518 && cf_fix_cppflags=yes
4519
4520 if test "$cf_fix_cppflags" = yes ; then
4521
4522 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4523 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4524
4525 continue
4526 elif test "${cf_tst_cflags}" = "\"'" ; then
4527
4528 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4529 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4530
4531 continue
4532 fi
4533 ;;
4534 esac
4535 case "$CPPFLAGS" in
4536 (*$cf_add_cflags)
4537 ;;
4538 (*)
4539 case "$cf_add_cflags" in
4540 (-D*)
4541 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4542
4543 CPPFLAGS=`echo "$CPPFLAGS" | \
4544 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4545 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4546
4547 ;;
4548 esac
4549
4550 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4551 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4552
4553 ;;
4554 esac
4555 ;;
4556 (*)
4557
4558 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4559 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4560
4561 ;;
4562 esac
4563 ;;
4564 (yes)
4565
4566 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4567 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4568
4569 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4570
4571 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4572 && test -z "${cf_tst_cflags}" \
4573 && cf_fix_cppflags=no
4574 ;;
4575 esac
4576 done
4577
4578 if test -n "$cf_new_cflags" ; then
4579
4580 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4581 CFLAGS="${CFLAGS}$cf_new_cflags"
4582
4583 fi
4584
4585 if test -n "$cf_new_cppflags" ; then
4586
4587 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4588 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4589
4590 fi
4591
4592 if test -n "$cf_new_extra_cppflags" ; then
4593
4594 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4595 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4596
4597 fi
4598
4599 fi
4600
4601 fi # cf_cv_posix_visible
4602
4603 # Some of these niche implementations use copy/paste, double-check...
4604 if test "$cf_cv_xopen_source" = no ; then
4605 test -n "$verbose" && echo " checking if _POSIX_C_SOURCE interferes with _XOPEN_SOURCE" 1>&6
4606
4607 echo "${as_me:-configure}:4607: testing checking if _POSIX_C_SOURCE interferes with _XOPEN_SOURCE ..." 1>&5
4608
4609 cat >"conftest.$ac_ext" <<_ACEOF
4610 #line 4610 "configure"
4611 #include "confdefs.h"
4612
4613 $ac_includes_default
4614
4615 int
4616 main (void)
4617 {
4618
4619 #ifndef _XOPEN_SOURCE
4620 #error _XOPEN_SOURCE is not defined
4621 #endif
4622
4623 ;
4624 return 0;
4625 }
4626 _ACEOF
4627 rm -f "conftest.$ac_objext"
4628 if { (eval echo "$as_me:4628: \"$ac_compile\"") >&5
4629 (eval $ac_compile) 2>&5
4630 ac_status=$?
4631 echo "$as_me:4631: \$? = $ac_status" >&5
4632 (exit "$ac_status"); } &&
4633 { ac_try='test -s "conftest.$ac_objext"'
4634 { (eval echo "$as_me:4634: \"$ac_try\"") >&5
4635 (eval $ac_try) 2>&5
4636 ac_status=$?
4637 echo "$as_me:4637: \$? = $ac_status" >&5
4638 (exit "$ac_status"); }; }; then
4639 :
4640 else
4641 echo "$as_me: failed program was:" >&5
4642 cat "conftest.$ac_ext" >&5
4643
4644 { echo "$as_me:4644: WARNING: _POSIX_C_SOURCE definition is not usable" >&5
4645 echo "$as_me: WARNING: _POSIX_C_SOURCE definition is not usable" >&2;}
4646 CPPFLAGS="$cf_save_xopen_cppflags"
4647 fi
4648 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4649 fi
4650 ;;
4651 esac
4652
4653 if test -n "$cf_xopen_source" ; then
4654
4655 for cf_add_cflags in $cf_xopen_source
4656 do
4657 case "x$cf_add_cflags" in
4658 (x-[DU]*)
4659
4660 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
4661 while true
4662 do
4663 cf_old_cflag=`echo "x$CFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
4664 test "$CFLAGS" != "$cf_old_cflag" || break
4665 test -n "$verbose" && echo " removing old option $cf_add_cflags from CFLAGS" 1>&6
4666
4667 echo "${as_me:-configure}:4667: testing removing old option $cf_add_cflags from CFLAGS ..." 1>&5
4668
4669 CFLAGS="$cf_old_cflag"
4670 done
4671
4672 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
4673 while true
4674 do
4675 cf_old_cflag=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
4676 test "$CPPFLAGS" != "$cf_old_cflag" || break
4677 test -n "$verbose" && echo " removing old option $cf_add_cflags from CPPFLAGS" 1>&6
4678
4679 echo "${as_me:-configure}:4679: testing removing old option $cf_add_cflags from CPPFLAGS ..." 1>&5
4680
4681 CPPFLAGS="$cf_old_cflag"
4682 done
4683
4684 ;;
4685 esac
4686
4687 cf_fix_cppflags=no
4688 cf_new_cflags=
4689 cf_new_cppflags=
4690 cf_new_extra_cppflags=
4691
4692 for cf_add_cflags in $cf_add_cflags
4693 do
4694 case "$cf_fix_cppflags" in
4695 (no)
4696 case "$cf_add_cflags" in
4697 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
4698 case "$cf_add_cflags" in
4699 (-D*)
4700 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
4701
4702 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4703 && test -z "${cf_tst_cflags}" \
4704 && cf_fix_cppflags=yes
4705
4706 if test "$cf_fix_cppflags" = yes ; then
4707
4708 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4709 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4710
4711 continue
4712 elif test "${cf_tst_cflags}" = "\"'" ; then
4713
4714 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4715 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4716
4717 continue
4718 fi
4719 ;;
4720 esac
4721 case "$CPPFLAGS" in
4722 (*$cf_add_cflags)
4723 ;;
4724 (*)
4725 case "$cf_add_cflags" in
4726 (-D*)
4727 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
4728
4729 CPPFLAGS=`echo "$CPPFLAGS" | \
4730 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
4731 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
4732
4733 ;;
4734 esac
4735
4736 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
4737 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
4738
4739 ;;
4740 esac
4741 ;;
4742 (*)
4743
4744 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
4745 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
4746
4747 ;;
4748 esac
4749 ;;
4750 (yes)
4751
4752 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
4753 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
4754
4755 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
4756
4757 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
4758 && test -z "${cf_tst_cflags}" \
4759 && cf_fix_cppflags=no
4760 ;;
4761 esac
4762 done
4763
4764 if test -n "$cf_new_cflags" ; then
4765 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
4766
4767 echo "${as_me:-configure}:4767: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
4768
4769 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
4770 CFLAGS="${CFLAGS}$cf_new_cflags"
4771
4772 fi
4773
4774 if test -n "$cf_new_cppflags" ; then
4775 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
4776
4777 echo "${as_me:-configure}:4777: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
4778
4779 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4780 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
4781
4782 fi
4783
4784 if test -n "$cf_new_extra_cppflags" ; then
4785 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
4786
4787 echo "${as_me:-configure}:4787: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
4788
4789 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
4790 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
4791
4792 fi
4793
4794 done
4795
4796 fi
4797
4798 if test -n "$cf_XOPEN_SOURCE" && test -z "$cf_cv_xopen_source" ; then
4799 echo "$as_me:4799: checking if _XOPEN_SOURCE really is set" >&5
4800 echo $ECHO_N "checking if _XOPEN_SOURCE really is set... $ECHO_C" >&6
4801 cat >"conftest.$ac_ext" <<_ACEOF
4802 #line 4802 "configure"
4803 #include "confdefs.h"
4804 #include <stdlib.h>
4805 int
4806 main (void)
4807 {
4808
4809 #ifndef _XOPEN_SOURCE
4810 #error _XOPEN_SOURCE is not defined
4811 #endif
4812 ;
4813 return 0;
4814 }
4815 _ACEOF
4816 rm -f "conftest.$ac_objext"
4817 if { (eval echo "$as_me:4817: \"$ac_compile\"") >&5
4818 (eval $ac_compile) 2>&5
4819 ac_status=$?
4820 echo "$as_me:4820: \$? = $ac_status" >&5
4821 (exit "$ac_status"); } &&
4822 { ac_try='test -s "conftest.$ac_objext"'
4823 { (eval echo "$as_me:4823: \"$ac_try\"") >&5
4824 (eval $ac_try) 2>&5
4825 ac_status=$?
4826 echo "$as_me:4826: \$? = $ac_status" >&5
4827 (exit "$ac_status"); }; }; then
4828 cf_XOPEN_SOURCE_set=yes
4829 else
4830 echo "$as_me: failed program was:" >&5
4831 cat "conftest.$ac_ext" >&5
4832 cf_XOPEN_SOURCE_set=no
4833 fi
4834 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4835 echo "$as_me:4835: result: $cf_XOPEN_SOURCE_set" >&5
4836 echo "${ECHO_T}$cf_XOPEN_SOURCE_set" >&6
4837 if test "$cf_XOPEN_SOURCE_set" = yes
4838 then
4839 cat >"conftest.$ac_ext" <<_ACEOF
4840 #line 4840 "configure"
4841 #include "confdefs.h"
4842 #include <stdlib.h>
4843 int
4844 main (void)
4845 {
4846
4847 #if (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
4848 #error (_XOPEN_SOURCE - 0) < $cf_XOPEN_SOURCE
4849 #endif
4850 ;
4851 return 0;
4852 }
4853 _ACEOF
4854 rm -f "conftest.$ac_objext"
4855 if { (eval echo "$as_me:4855: \"$ac_compile\"") >&5
4856 (eval $ac_compile) 2>&5
4857 ac_status=$?
4858 echo "$as_me:4858: \$? = $ac_status" >&5
4859 (exit "$ac_status"); } &&
4860 { ac_try='test -s "conftest.$ac_objext"'
4861 { (eval echo "$as_me:4861: \"$ac_try\"") >&5
4862 (eval $ac_try) 2>&5
4863 ac_status=$?
4864 echo "$as_me:4864: \$? = $ac_status" >&5
4865 (exit "$ac_status"); }; }; then
4866 cf_XOPEN_SOURCE_set_ok=yes
4867 else
4868 echo "$as_me: failed program was:" >&5
4869 cat "conftest.$ac_ext" >&5
4870 cf_XOPEN_SOURCE_set_ok=no
4871 fi
4872 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4873 if test "$cf_XOPEN_SOURCE_set_ok" = no
4874 then
4875 { echo "$as_me:4875: WARNING: _XOPEN_SOURCE is lower than requested" >&5
4876 echo "$as_me: WARNING: _XOPEN_SOURCE is lower than requested" >&2;}
4877 fi
4878 else
4879
4880 echo "$as_me:4880: checking if we should define _XOPEN_SOURCE" >&5
4881 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
4882 if test "${cf_cv_xopen_source+set}" = set; then
4883 echo $ECHO_N "(cached) $ECHO_C" >&6
4884 else
4885
4886 cat >"conftest.$ac_ext" <<_ACEOF
4887 #line 4887 "configure"
4888 #include "confdefs.h"
4889
4890 $ac_includes_default
4891
4892 int
4893 main (void)
4894 {
4895
4896 #ifndef _XOPEN_SOURCE
4897 #error _XOPEN_SOURCE is not defined
4898 #endif
4899
4900 ;
4901 return 0;
4902 }
4903 _ACEOF
4904 rm -f "conftest.$ac_objext"
4905 if { (eval echo "$as_me:4905: \"$ac_compile\"") >&5
4906 (eval $ac_compile) 2>&5
4907 ac_status=$?
4908 echo "$as_me:4908: \$? = $ac_status" >&5
4909 (exit "$ac_status"); } &&
4910 { ac_try='test -s "conftest.$ac_objext"'
4911 { (eval echo "$as_me:4911: \"$ac_try\"") >&5
4912 (eval $ac_try) 2>&5
4913 ac_status=$?
4914 echo "$as_me:4914: \$? = $ac_status" >&5
4915 (exit "$ac_status"); }; }; then
4916 cf_cv_xopen_source=no
4917 else
4918 echo "$as_me: failed program was:" >&5
4919 cat "conftest.$ac_ext" >&5
4920 cf_save="$CPPFLAGS"
4921
4922 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
4923 CPPFLAGS="${CPPFLAGS}-D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
4924
4925 cat >"conftest.$ac_ext" <<_ACEOF
4926 #line 4926 "configure"
4927 #include "confdefs.h"
4928
4929 $ac_includes_default
4930
4931 int
4932 main (void)
4933 {
4934
4935 #ifndef _XOPEN_SOURCE
4936 #error _XOPEN_SOURCE is not defined
4937 #endif
4938
4939 ;
4940 return 0;
4941 }
4942 _ACEOF
4943 rm -f "conftest.$ac_objext"
4944 if { (eval echo "$as_me:4944: \"$ac_compile\"") >&5
4945 (eval $ac_compile) 2>&5
4946 ac_status=$?
4947 echo "$as_me:4947: \$? = $ac_status" >&5
4948 (exit "$ac_status"); } &&
4949 { ac_try='test -s "conftest.$ac_objext"'
4950 { (eval echo "$as_me:4950: \"$ac_try\"") >&5
4951 (eval $ac_try) 2>&5
4952 ac_status=$?
4953 echo "$as_me:4953: \$? = $ac_status" >&5
4954 (exit "$ac_status"); }; }; then
4955 cf_cv_xopen_source=no
4956 else
4957 echo "$as_me: failed program was:" >&5
4958 cat "conftest.$ac_ext" >&5
4959 cf_cv_xopen_source=$cf_XOPEN_SOURCE
4960 fi
4961 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4962 CPPFLAGS="$cf_save"
4963
4964 fi
4965 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
4966
4967 fi
4968 echo "$as_me:4968: result: $cf_cv_xopen_source" >&5
4969 echo "${ECHO_T}$cf_cv_xopen_source" >&6
4970
4971 if test "$cf_cv_xopen_source" != no ; then
4972
4973 CFLAGS=`echo "$CFLAGS" | \
4974 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4975 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4976
4977 CPPFLAGS=`echo "$CPPFLAGS" | \
4978 sed -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?[ ]/ /g' \
4979 -e 's/-[UD]'"_XOPEN_SOURCE"'\(=[^ ]*\)\?$//g'`
4980
4981 cf_temp_xopen_source="-D_XOPEN_SOURCE=$cf_cv_xopen_source"
4982
4983 for cf_add_cflags in $cf_temp_xopen_source
4984 do
4985 case "x$cf_add_cflags" in
4986 (x-[DU]*)
4987
4988 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
4989 while true
4990 do
4991 cf_old_cflag=`echo "x$CFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
4992 test "$CFLAGS" != "$cf_old_cflag" || break
4993
4994 CFLAGS="$cf_old_cflag"
4995 done
4996
4997 cf_tmp_cflag=`echo "x$cf_add_cflags" | sed -e 's/^.//' -e 's/=.*//'`
4998 while true
4999 do
5000 cf_old_cflag=`echo "x$CPPFLAGS" | sed -e 's/^.//' -e 's/[ ][ ]*-/ -/g' -e "s%$cf_tmp_cflag\\(=[^ ][^ ]*\\)\?%%" -e 's/^[ ]*//' -e 's%[ ][ ]*-D% -D%g' -e 's%[ ][ ]*-I% -I%g'`
5001 test "$CPPFLAGS" != "$cf_old_cflag" || break
5002
5003 CPPFLAGS="$cf_old_cflag"
5004 done
5005
5006 ;;
5007 esac
5008
5009 cf_fix_cppflags=no
5010 cf_new_cflags=
5011 cf_new_cppflags=
5012 cf_new_extra_cppflags=
5013
5014 for cf_add_cflags in $cf_add_cflags
5015 do
5016 case "$cf_fix_cppflags" in
5017 (no)
5018 case "$cf_add_cflags" in
5019 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
5020 case "$cf_add_cflags" in
5021 (-D*)
5022 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
5023
5024 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5025 && test -z "${cf_tst_cflags}" \
5026 && cf_fix_cppflags=yes
5027
5028 if test "$cf_fix_cppflags" = yes ; then
5029
5030 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5031 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5032
5033 continue
5034 elif test "${cf_tst_cflags}" = "\"'" ; then
5035
5036 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5037 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5038
5039 continue
5040 fi
5041 ;;
5042 esac
5043 case "$CPPFLAGS" in
5044 (*$cf_add_cflags)
5045 ;;
5046 (*)
5047 case "$cf_add_cflags" in
5048 (-D*)
5049 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
5050
5051 CPPFLAGS=`echo "$CPPFLAGS" | \
5052 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
5053 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
5054
5055 ;;
5056 esac
5057
5058 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
5059 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
5060
5061 ;;
5062 esac
5063 ;;
5064 (*)
5065
5066 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
5067 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
5068
5069 ;;
5070 esac
5071 ;;
5072 (yes)
5073
5074 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
5075 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
5076
5077 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
5078
5079 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
5080 && test -z "${cf_tst_cflags}" \
5081 && cf_fix_cppflags=no
5082 ;;
5083 esac
5084 done
5085
5086 if test -n "$cf_new_cflags" ; then
5087
5088 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
5089 CFLAGS="${CFLAGS}$cf_new_cflags"
5090
5091 fi
5092
5093 if test -n "$cf_new_cppflags" ; then
5094
5095 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
5096 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
5097
5098 fi
5099
5100 if test -n "$cf_new_extra_cppflags" ; then
5101
5102 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
5103 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
5104
5105 fi
5106
5107 done
5108
5109 fi
5110
5111 fi
5112 fi
5113 fi # cf_cv_posix_visible
5114
5115 echo "$as_me:5115: checking if SIGWINCH is defined" >&5
5116 echo $ECHO_N "checking if SIGWINCH is defined... $ECHO_C" >&6
5117 if test "${cf_cv_define_sigwinch+set}" = set; then
5118 echo $ECHO_N "(cached) $ECHO_C" >&6
5119 else
5120
5121 cat >"conftest.$ac_ext" <<_ACEOF
5122 #line 5122 "configure"
5123 #include "confdefs.h"
5124
5125 #include <sys/types.h>
5126 #include <sys/signal.h>
5127
5128 int
5129 main (void)
5130 {
5131 int x = SIGWINCH; (void)x
5132 ;
5133 return 0;
5134 }
5135 _ACEOF
5136 rm -f "conftest.$ac_objext"
5137 if { (eval echo "$as_me:5137: \"$ac_compile\"") >&5
5138 (eval $ac_compile) 2>&5
5139 ac_status=$?
5140 echo "$as_me:5140: \$? = $ac_status" >&5
5141 (exit "$ac_status"); } &&
5142 { ac_try='test -s "conftest.$ac_objext"'
5143 { (eval echo "$as_me:5143: \"$ac_try\"") >&5
5144 (eval $ac_try) 2>&5
5145 ac_status=$?
5146 echo "$as_me:5146: \$? = $ac_status" >&5
5147 (exit "$ac_status"); }; }; then
5148 cf_cv_define_sigwinch=yes
5149 else
5150 echo "$as_me: failed program was:" >&5
5151 cat "conftest.$ac_ext" >&5
5152 cat >"conftest.$ac_ext" <<_ACEOF
5153 #line 5153 "configure"
5154 #include "confdefs.h"
5155
5156 #undef _XOPEN_SOURCE
5157 #undef _POSIX_SOURCE
5158 #undef _POSIX_C_SOURCE
5159 #include <sys/types.h>
5160 #include <sys/signal.h>
5161
5162 int
5163 main (void)
5164 {
5165 int x = SIGWINCH; (void)x
5166 ;
5167 return 0;
5168 }
5169 _ACEOF
5170 rm -f "conftest.$ac_objext"
5171 if { (eval echo "$as_me:5171: \"$ac_compile\"") >&5
5172 (eval $ac_compile) 2>&5
5173 ac_status=$?
5174 echo "$as_me:5174: \$? = $ac_status" >&5
5175 (exit "$ac_status"); } &&
5176 { ac_try='test -s "conftest.$ac_objext"'
5177 { (eval echo "$as_me:5177: \"$ac_try\"") >&5
5178 (eval $ac_try) 2>&5
5179 ac_status=$?
5180 echo "$as_me:5180: \$? = $ac_status" >&5
5181 (exit "$ac_status"); }; }; then
5182 cf_cv_define_sigwinch=maybe
5183 else
5184 echo "$as_me: failed program was:" >&5
5185 cat "conftest.$ac_ext" >&5
5186 cf_cv_define_sigwinch=no
5187 fi
5188 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5189
5190 fi
5191 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5192
5193 fi
5194 echo "$as_me:5194: result: $cf_cv_define_sigwinch" >&5
5195 echo "${ECHO_T}$cf_cv_define_sigwinch" >&6
5196
5197 if test "$cf_cv_define_sigwinch" = maybe ; then
5198 echo "$as_me:5198: checking for actual SIGWINCH definition" >&5
5199 echo $ECHO_N "checking for actual SIGWINCH definition... $ECHO_C" >&6
5200 if test "${cf_cv_fixup_sigwinch+set}" = set; then
5201 echo $ECHO_N "(cached) $ECHO_C" >&6
5202 else
5203
5204 cf_cv_fixup_sigwinch=unknown
5205 cf_sigwinch=32
5206 while test "$cf_sigwinch" != 1
5207 do
5208 cat >"conftest.$ac_ext" <<_ACEOF
5209 #line 5209 "configure"
5210 #include "confdefs.h"
5211
5212 #undef _XOPEN_SOURCE
5213 #undef _POSIX_SOURCE
5214 #undef _POSIX_C_SOURCE
5215 #include <sys/types.h>
5216 #include <sys/signal.h>
5217
5218 int
5219 main (void)
5220 {
5221
5222 #if SIGWINCH != $cf_sigwinch
5223 #error SIGWINCH is not $cf_sigwinch
5224 #endif
5225 int x = SIGWINCH; (void)x
5226 ;
5227 return 0;
5228 }
5229 _ACEOF
5230 rm -f "conftest.$ac_objext"
5231 if { (eval echo "$as_me:5231: \"$ac_compile\"") >&5
5232 (eval $ac_compile) 2>&5
5233 ac_status=$?
5234 echo "$as_me:5234: \$? = $ac_status" >&5
5235 (exit "$ac_status"); } &&
5236 { ac_try='test -s "conftest.$ac_objext"'
5237 { (eval echo "$as_me:5237: \"$ac_try\"") >&5
5238 (eval $ac_try) 2>&5
5239 ac_status=$?
5240 echo "$as_me:5240: \$? = $ac_status" >&5
5241 (exit "$ac_status"); }; }; then
5242 cf_cv_fixup_sigwinch=$cf_sigwinch
5243 break
5244 else
5245 echo "$as_me: failed program was:" >&5
5246 cat "conftest.$ac_ext" >&5
5247 fi
5248 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5249
5250 cf_sigwinch="`expr "$cf_sigwinch" - 1`"
5251 done
5252
5253 fi
5254 echo "$as_me:5254: result: $cf_cv_fixup_sigwinch" >&5
5255 echo "${ECHO_T}$cf_cv_fixup_sigwinch" >&6
5256
5257 if test "$cf_cv_fixup_sigwinch" != unknown ; then
5258 CPPFLAGS="$CPPFLAGS -DSIGWINCH=$cf_cv_fixup_sigwinch"
5259 fi
5260 fi
5261
5262 ### checks for header files
5263
5264 echo "$as_me:5264: checking for ANSI C header files" >&5
5265 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
5266 if test "${ac_cv_header_stdc+set}" = set; then
5267 echo $ECHO_N "(cached) $ECHO_C" >&6
5268 else
5269 cat >"conftest.$ac_ext" <<_ACEOF
5270 #line 5270 "configure"
5271 #include "confdefs.h"
5272 #include <stdlib.h>
5273 #include <stdarg.h>
5274 #include <string.h>
5275 #include <float.h>
5276
5277 _ACEOF
5278 if { (eval echo "$as_me:5278: \"$ac_cpp "conftest.$ac_ext"\"") >&5
5279 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
5280 ac_status=$?
5281 $EGREP -v '^ *\+' conftest.er1 >conftest.err
5282 rm -f conftest.er1
5283 cat conftest.err >&5
5284 echo "$as_me:5284: \$? = $ac_status" >&5
5285 (exit "$ac_status"); } >/dev/null; then
5286 if test -s conftest.err; then
5287 ac_cpp_err=$ac_c_preproc_warn_flag
5288 else
5289 ac_cpp_err=
5290 fi
5291 else
5292 ac_cpp_err=yes
5293 fi
5294 if test -z "$ac_cpp_err"; then
5295 ac_cv_header_stdc=yes
5296 else
5297 echo "$as_me: failed program was:" >&5
5298 cat "conftest.$ac_ext" >&5
5299 ac_cv_header_stdc=no
5300 fi
5301 rm -f conftest.err "conftest.$ac_ext"
5302
5303 if test $ac_cv_header_stdc = yes; then
5304 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5305 cat >"conftest.$ac_ext" <<_ACEOF
5306 #line 5306 "configure"
5307 #include "confdefs.h"
5308 #include <string.h>
5309
5310 _ACEOF
5311 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5312 $EGREP "memchr" >/dev/null 2>&1; then
5313 :
5314 else
5315 ac_cv_header_stdc=no
5316 fi
5317 rm -rf conftest*
5318
5319 fi
5320
5321 if test $ac_cv_header_stdc = yes; then
5322 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5323 cat >"conftest.$ac_ext" <<_ACEOF
5324 #line 5324 "configure"
5325 #include "confdefs.h"
5326 #include <stdlib.h>
5327
5328 _ACEOF
5329 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5330 $EGREP "free" >/dev/null 2>&1; then
5331 :
5332 else
5333 ac_cv_header_stdc=no
5334 fi
5335 rm -rf conftest*
5336
5337 fi
5338
5339 if test $ac_cv_header_stdc = yes; then
5340 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5341 if test "$cross_compiling" = yes; then
5342 :
5343 else
5344 cat >"conftest.$ac_ext" <<_ACEOF
5345 #line 5345 "configure"
5346 #include "confdefs.h"
5347 #include <ctype.h>
5348 #if ((' ' & 0x0FF) == 0x020)
5349 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5350 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5351 #else
5352 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
5353 || ('j' <= (c) && (c) <= 'r') \
5354 || ('s' <= (c) && (c) <= 'z'))
5355 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5356 #endif
5357
5358 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
5359 int
5360 main (void)
5361 {
5362 int i;
5363 for (i = 0; i < 256; i++)
5364 if (XOR (islower (i), ISLOWER (i))
5365 || toupper (i) != TOUPPER (i))
5366 $ac_main_return(2);
5367 $ac_main_return (0);
5368 }
5369 _ACEOF
5370 rm -f "conftest$ac_exeext"
5371 if { (eval echo "$as_me:5371: \"$ac_link\"") >&5
5372 (eval $ac_link) 2>&5
5373 ac_status=$?
5374 echo "$as_me:5374: \$? = $ac_status" >&5
5375 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
5376 { (eval echo "$as_me:5376: \"$ac_try\"") >&5
5377 (eval $ac_try) 2>&5
5378 ac_status=$?
5379 echo "$as_me:5379: \$? = $ac_status" >&5
5380 (exit "$ac_status"); }; }; then
5381 :
5382 else
5383 echo "$as_me: program exited with status $ac_status" >&5
5384 echo "$as_me: failed program was:" >&5
5385 cat "conftest.$ac_ext" >&5
5386 ac_cv_header_stdc=no
5387 fi
5388 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
5389 fi
5390 fi
5391 fi
5392 echo "$as_me:5392: result: $ac_cv_header_stdc" >&5
5393 echo "${ECHO_T}$ac_cv_header_stdc" >&6
5394 if test $ac_cv_header_stdc = yes; then
5395
5396 cat >>confdefs.h <<\EOF
5397 #define STDC_HEADERS 1
5398 EOF
5399
5400 fi
5401
5402 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
5403
5404 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
5405 inttypes.h stdint.h unistd.h
5406 do
5407 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5408 echo "$as_me:5408: checking for $ac_header" >&5
5409 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5410 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5411 echo $ECHO_N "(cached) $ECHO_C" >&6
5412 else
5413 cat >"conftest.$ac_ext" <<_ACEOF
5414 #line 5414 "configure"
5415 #include "confdefs.h"
5416 $ac_includes_default
5417 #include <$ac_header>
5418 _ACEOF
5419 rm -f "conftest.$ac_objext"
5420 if { (eval echo "$as_me:5420: \"$ac_compile\"") >&5
5421 (eval $ac_compile) 2>&5
5422 ac_status=$?
5423 echo "$as_me:5423: \$? = $ac_status" >&5
5424 (exit "$ac_status"); } &&
5425 { ac_try='test -s "conftest.$ac_objext"'
5426 { (eval echo "$as_me:5426: \"$ac_try\"") >&5
5427 (eval $ac_try) 2>&5
5428 ac_status=$?
5429 echo "$as_me:5429: \$? = $ac_status" >&5
5430 (exit "$ac_status"); }; }; then
5431 eval "$as_ac_Header=yes"
5432 else
5433 echo "$as_me: failed program was:" >&5
5434 cat "conftest.$ac_ext" >&5
5435 eval "$as_ac_Header=no"
5436 fi
5437 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5438 fi
5439 echo "$as_me:5439: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
5440 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
5441 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
5442 cat >>confdefs.h <<EOF
5443 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5444 EOF
5445
5446 fi
5447 done
5448
5449 echo "$as_me:5449: checking whether exit is declared" >&5
5450 echo $ECHO_N "checking whether exit is declared... $ECHO_C" >&6
5451 if test "${ac_cv_have_decl_exit+set}" = set; then
5452 echo $ECHO_N "(cached) $ECHO_C" >&6
5453 else
5454 cat >"conftest.$ac_ext" <<_ACEOF
5455 #line 5455 "configure"
5456 #include "confdefs.h"
5457 $ac_includes_default
5458 int
5459 main (void)
5460 {
5461 #ifndef exit
5462 (void) exit;
5463 #endif
5464
5465 ;
5466 return 0;
5467 }
5468 _ACEOF
5469 rm -f "conftest.$ac_objext"
5470 if { (eval echo "$as_me:5470: \"$ac_compile\"") >&5
5471 (eval $ac_compile) 2>&5
5472 ac_status=$?
5473 echo "$as_me:5473: \$? = $ac_status" >&5
5474 (exit "$ac_status"); } &&
5475 { ac_try='test -s "conftest.$ac_objext"'
5476 { (eval echo "$as_me:5476: \"$ac_try\"") >&5
5477 (eval $ac_try) 2>&5
5478 ac_status=$?
5479 echo "$as_me:5479: \$? = $ac_status" >&5
5480 (exit "$ac_status"); }; }; then
5481 ac_cv_have_decl_exit=yes
5482 else
5483 echo "$as_me: failed program was:" >&5
5484 cat "conftest.$ac_ext" >&5
5485 ac_cv_have_decl_exit=no
5486 fi
5487 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5488 fi
5489 echo "$as_me:5489: result: $ac_cv_have_decl_exit" >&5
5490 echo "${ECHO_T}$ac_cv_have_decl_exit" >&6
5491
5492 for ac_header in \
5493 ncurses/curses.h \
5494 ncurses/term.h \
5495 sys/ptem.h \
5496 sys/ttydefaults.h \
5497 term.h \
5498 termios.h \
5499 wchar.h \
5500
5501 do
5502 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5503 echo "$as_me:5503: checking for $ac_header" >&5
5504 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
5505 if eval "test \"\${$as_ac_Header+set}\" = set"; then
5506 echo $ECHO_N "(cached) $ECHO_C" >&6
5507 else
5508 cat >"conftest.$ac_ext" <<_ACEOF
5509 #line 5509 "configure"
5510 #include "confdefs.h"
5511 #include <$ac_header>
5512 _ACEOF
5513 if { (eval echo "$as_me:5513: \"$ac_cpp "conftest.$ac_ext"\"") >&5
5514 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
5515 ac_status=$?
5516 $EGREP -v '^ *\+' conftest.er1 >conftest.err
5517 rm -f conftest.er1
5518 cat conftest.err >&5
5519 echo "$as_me:5519: \$? = $ac_status" >&5
5520 (exit "$ac_status"); } >/dev/null; then
5521 if test -s conftest.err; then
5522 ac_cpp_err=$ac_c_preproc_warn_flag
5523 else
5524 ac_cpp_err=
5525 fi
5526 else
5527 ac_cpp_err=yes
5528 fi
5529 if test -z "$ac_cpp_err"; then
5530 eval "$as_ac_Header=yes"
5531 else
5532 echo "$as_me: failed program was:" >&5
5533 cat "conftest.$ac_ext" >&5
5534 eval "$as_ac_Header=no"
5535 fi
5536 rm -f conftest.err "conftest.$ac_ext"
5537 fi
5538 echo "$as_me:5538: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
5539 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
5540 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
5541 cat >>confdefs.h <<EOF
5542 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5543 EOF
5544
5545 fi
5546 done
5547
5548 echo "$as_me:5548: checking whether time.h and sys/time.h may both be included" >&5
5549 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
5550 if test "${ac_cv_header_time+set}" = set; then
5551 echo $ECHO_N "(cached) $ECHO_C" >&6
5552 else
5553 cat >"conftest.$ac_ext" <<_ACEOF
5554 #line 5554 "configure"
5555 #include "confdefs.h"
5556 #include <sys/types.h>
5557 #include <sys/time.h>
5558 #include <time.h>
5559
5560 int
5561 main (void)
5562 {
5563 if ((struct tm *) 0)
5564 return 0;
5565 ;
5566 return 0;
5567 }
5568 _ACEOF
5569 rm -f "conftest.$ac_objext"
5570 if { (eval echo "$as_me:5570: \"$ac_compile\"") >&5
5571 (eval $ac_compile) 2>&5
5572 ac_status=$?
5573 echo "$as_me:5573: \$? = $ac_status" >&5
5574 (exit "$ac_status"); } &&
5575 { ac_try='test -s "conftest.$ac_objext"'
5576 { (eval echo "$as_me:5576: \"$ac_try\"") >&5
5577 (eval $ac_try) 2>&5
5578 ac_status=$?
5579 echo "$as_me:5579: \$? = $ac_status" >&5
5580 (exit "$ac_status"); }; }; then
5581 ac_cv_header_time=yes
5582 else
5583 echo "$as_me: failed program was:" >&5
5584 cat "conftest.$ac_ext" >&5
5585 ac_cv_header_time=no
5586 fi
5587 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5588 fi
5589 echo "$as_me:5589: result: $ac_cv_header_time" >&5
5590 echo "${ECHO_T}$ac_cv_header_time" >&6
5591 if test $ac_cv_header_time = yes; then
5592
5593 cat >>confdefs.h <<\EOF
5594 #define TIME_WITH_SYS_TIME 1
5595 EOF
5596
5597 fi
5598
5599 echo "$as_me:5599: checking for nl_langinfo and CODESET" >&5
5600 echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
5601 if test "${am_cv_langinfo_codeset+set}" = set; then
5602 echo $ECHO_N "(cached) $ECHO_C" >&6
5603 else
5604 cat >"conftest.$ac_ext" <<_ACEOF
5605 #line 5605 "configure"
5606 #include "confdefs.h"
5607
5608 $ac_includes_default
5609 #include <langinfo.h>
5610 int
5611 main (void)
5612 {
5613 char* cs = nl_langinfo(CODESET); (void)cs
5614 ;
5615 return 0;
5616 }
5617 _ACEOF
5618 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
5619 if { (eval echo "$as_me:5619: \"$ac_link\"") >&5
5620 (eval $ac_link) 2>&5
5621 ac_status=$?
5622 echo "$as_me:5622: \$? = $ac_status" >&5
5623 (exit "$ac_status"); } &&
5624 { ac_try='test -s "conftest$ac_exeext"'
5625 { (eval echo "$as_me:5625: \"$ac_try\"") >&5
5626 (eval $ac_try) 2>&5
5627 ac_status=$?
5628 echo "$as_me:5628: \$? = $ac_status" >&5
5629 (exit "$ac_status"); }; }; then
5630 am_cv_langinfo_codeset=yes
5631 else
5632 echo "$as_me: failed program was:" >&5
5633 cat "conftest.$ac_ext" >&5
5634 am_cv_langinfo_codeset=no
5635 fi
5636 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
5637
5638 fi
5639 echo "$as_me:5639: result: $am_cv_langinfo_codeset" >&5
5640 echo "${ECHO_T}$am_cv_langinfo_codeset" >&6
5641 if test "$am_cv_langinfo_codeset" = yes; then
5642
5643 cat >>confdefs.h <<\EOF
5644 #define HAVE_LANGINFO_CODESET 1
5645 EOF
5646
5647 fi
5648
5649 ### checks for typedefs
5650
5651 echo "$as_me:5651: checking for signal global datatype" >&5
5652 echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6
5653 if test "${cf_cv_sig_atomic_t+set}" = set; then
5654 echo $ECHO_N "(cached) $ECHO_C" >&6
5655 else
5656
5657 for cf_type in \
5658 "volatile sig_atomic_t" \
5659 "sig_atomic_t" \
5660 "int"
5661 do
5662 cat >"conftest.$ac_ext" <<_ACEOF
5663 #line 5663 "configure"
5664 #include "confdefs.h"
5665
5666 #include <sys/types.h>
5667 #include <signal.h>
5668 #include <stdio.h>
5669
5670 extern $cf_type x;
5671 $cf_type x;
5672 static void handler(int sig)
5673 {
5674 (void)sig;
5675 x = 5;
5676 }
5677 int
5678 main (void)
5679 {
5680 signal(SIGINT, handler);
5681 x = 1
5682 ;
5683 return 0;
5684 }
5685 _ACEOF
5686 rm -f "conftest.$ac_objext"
5687 if { (eval echo "$as_me:5687: \"$ac_compile\"") >&5
5688 (eval $ac_compile) 2>&5
5689 ac_status=$?
5690 echo "$as_me:5690: \$? = $ac_status" >&5
5691 (exit "$ac_status"); } &&
5692 { ac_try='test -s "conftest.$ac_objext"'
5693 { (eval echo "$as_me:5693: \"$ac_try\"") >&5
5694 (eval $ac_try) 2>&5
5695 ac_status=$?
5696 echo "$as_me:5696: \$? = $ac_status" >&5
5697 (exit "$ac_status"); }; }; then
5698 cf_cv_sig_atomic_t=$cf_type
5699 else
5700 echo "$as_me: failed program was:" >&5
5701 cat "conftest.$ac_ext" >&5
5702 cf_cv_sig_atomic_t=no
5703 fi
5704 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5705 test "$cf_cv_sig_atomic_t" != no && break
5706 done
5707
5708 fi
5709
5710 echo "$as_me:5710: result: $cf_cv_sig_atomic_t" >&5
5711 echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6
5712 test "$cf_cv_sig_atomic_t" != no &&
5713 cat >>confdefs.h <<EOF
5714 #define SIG_ATOMIC_T $cf_cv_sig_atomic_t
5715 EOF
5716
5717 echo "$as_me:5717: checking for time_t" >&5
5718 echo $ECHO_N "checking for time_t... $ECHO_C" >&6
5719 if test "${ac_cv_type_time_t+set}" = set; then
5720 echo $ECHO_N "(cached) $ECHO_C" >&6
5721 else
5722 cat >"conftest.$ac_ext" <<_ACEOF
5723 #line 5723 "configure"
5724 #include "confdefs.h"
5725 $ac_includes_default
5726 int
5727 main (void)
5728 {
5729 if ((time_t *) 0)
5730 return 0;
5731 if (sizeof (time_t))
5732 return 0;
5733 ;
5734 return 0;
5735 }
5736 _ACEOF
5737 rm -f "conftest.$ac_objext"
5738 if { (eval echo "$as_me:5738: \"$ac_compile\"") >&5
5739 (eval $ac_compile) 2>&5
5740 ac_status=$?
5741 echo "$as_me:5741: \$? = $ac_status" >&5
5742 (exit "$ac_status"); } &&
5743 { ac_try='test -s "conftest.$ac_objext"'
5744 { (eval echo "$as_me:5744: \"$ac_try\"") >&5
5745 (eval $ac_try) 2>&5
5746 ac_status=$?
5747 echo "$as_me:5747: \$? = $ac_status" >&5
5748 (exit "$ac_status"); }; }; then
5749 ac_cv_type_time_t=yes
5750 else
5751 echo "$as_me: failed program was:" >&5
5752 cat "conftest.$ac_ext" >&5
5753 ac_cv_type_time_t=no
5754 fi
5755 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5756 fi
5757 echo "$as_me:5757: result: $ac_cv_type_time_t" >&5
5758 echo "${ECHO_T}$ac_cv_type_time_t" >&6
5759 if test "$ac_cv_type_time_t" = yes; then
5760 :
5761 else
5762
5763 cat >>confdefs.h <<EOF
5764 #define time_t long
5765 EOF
5766
5767 fi
5768
5769 echo "$as_me:5769: checking for cc_t in <termios.h> or <termio.h>" >&5
5770 echo $ECHO_N "checking for cc_t in <termios.h> or <termio.h>... $ECHO_C" >&6
5771 if test "${cf_cv_type_cc_t+set}" = set; then
5772 echo $ECHO_N "(cached) $ECHO_C" >&6
5773 else
5774
5775 cat >"conftest.$ac_ext" <<_ACEOF
5776 #line 5776 "configure"
5777 #include "confdefs.h"
5778
5779 #include <sys/types.h>
5780 #if defined(HAVE_TERMIOS_H)
5781 #include <termios.h>
5782 #else
5783 #include <termio.h>
5784 #include <sys/ioctl.h>
5785 #endif
5786
5787 int
5788 main (void)
5789 {
5790 cc_t x; (void)x
5791 ;
5792 return 0;
5793 }
5794 _ACEOF
5795 rm -f "conftest.$ac_objext"
5796 if { (eval echo "$as_me:5796: \"$ac_compile\"") >&5
5797 (eval $ac_compile) 2>&5
5798 ac_status=$?
5799 echo "$as_me:5799: \$? = $ac_status" >&5
5800 (exit "$ac_status"); } &&
5801 { ac_try='test -s "conftest.$ac_objext"'
5802 { (eval echo "$as_me:5802: \"$ac_try\"") >&5
5803 (eval $ac_try) 2>&5
5804 ac_status=$?
5805 echo "$as_me:5805: \$? = $ac_status" >&5
5806 (exit "$ac_status"); }; }; then
5807 cf_cv_type_cc_t=yes
5808 else
5809 echo "$as_me: failed program was:" >&5
5810 cat "conftest.$ac_ext" >&5
5811 cf_cv_type_cc_t=no
5812 fi
5813 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5814
5815 fi
5816
5817 echo "$as_me:5817: result: $cf_cv_type_cc_t" >&5
5818 echo "${ECHO_T}$cf_cv_type_cc_t" >&6
5819 test $cf_cv_type_cc_t = no &&
5820 cat >>confdefs.h <<\EOF
5821 #define cc_t unsigned char
5822 EOF
5823
5824 echo "$as_me:5824: checking for nfds_t in <poll.h>" >&5
5825 echo $ECHO_N "checking for nfds_t in <poll.h>... $ECHO_C" >&6
5826 if test "${cf_cv_type_nfds_t+set}" = set; then
5827 echo $ECHO_N "(cached) $ECHO_C" >&6
5828 else
5829
5830 cat >"conftest.$ac_ext" <<_ACEOF
5831 #line 5831 "configure"
5832 #include "confdefs.h"
5833
5834 $ac_includes_default
5835 #include <poll.h>
5836
5837 int
5838 main (void)
5839 {
5840 nfds_t x; (void)x
5841 ;
5842 return 0;
5843 }
5844 _ACEOF
5845 rm -f "conftest.$ac_objext"
5846 if { (eval echo "$as_me:5846: \"$ac_compile\"") >&5
5847 (eval $ac_compile) 2>&5
5848 ac_status=$?
5849 echo "$as_me:5849: \$? = $ac_status" >&5
5850 (exit "$ac_status"); } &&
5851 { ac_try='test -s "conftest.$ac_objext"'
5852 { (eval echo "$as_me:5852: \"$ac_try\"") >&5
5853 (eval $ac_try) 2>&5
5854 ac_status=$?
5855 echo "$as_me:5855: \$? = $ac_status" >&5
5856 (exit "$ac_status"); }; }; then
5857 cf_cv_type_nfds_t=yes
5858 else
5859 echo "$as_me: failed program was:" >&5
5860 cat "conftest.$ac_ext" >&5
5861 cf_cv_type_nfds_t=no
5862 fi
5863 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5864
5865 fi
5866
5867 echo "$as_me:5867: result: $cf_cv_type_nfds_t" >&5
5868 echo "${ECHO_T}$cf_cv_type_nfds_t" >&6
5869 test $cf_cv_type_nfds_t = no &&
5870 cat >>confdefs.h <<\EOF
5871 #define nfds_t unsigned
5872 EOF
5873
5874 echo "$as_me:5874: checking for mode_t" >&5
5875 echo $ECHO_N "checking for mode_t... $ECHO_C" >&6
5876 if test "${ac_cv_type_mode_t+set}" = set; then
5877 echo $ECHO_N "(cached) $ECHO_C" >&6
5878 else
5879 cat >"conftest.$ac_ext" <<_ACEOF
5880 #line 5880 "configure"
5881 #include "confdefs.h"
5882 $ac_includes_default
5883 int
5884 main (void)
5885 {
5886 if ((mode_t *) 0)
5887 return 0;
5888 if (sizeof (mode_t))
5889 return 0;
5890 ;
5891 return 0;
5892 }
5893 _ACEOF
5894 rm -f "conftest.$ac_objext"
5895 if { (eval echo "$as_me:5895: \"$ac_compile\"") >&5
5896 (eval $ac_compile) 2>&5
5897 ac_status=$?
5898 echo "$as_me:5898: \$? = $ac_status" >&5
5899 (exit "$ac_status"); } &&
5900 { ac_try='test -s "conftest.$ac_objext"'
5901 { (eval echo "$as_me:5901: \"$ac_try\"") >&5
5902 (eval $ac_try) 2>&5
5903 ac_status=$?
5904 echo "$as_me:5904: \$? = $ac_status" >&5
5905 (exit "$ac_status"); }; }; then
5906 ac_cv_type_mode_t=yes
5907 else
5908 echo "$as_me: failed program was:" >&5
5909 cat "conftest.$ac_ext" >&5
5910 ac_cv_type_mode_t=no
5911 fi
5912 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5913 fi
5914 echo "$as_me:5914: result: $ac_cv_type_mode_t" >&5
5915 echo "${ECHO_T}$ac_cv_type_mode_t" >&6
5916 if test "$ac_cv_type_mode_t" = yes; then
5917 :
5918 else
5919
5920 cat >>confdefs.h <<EOF
5921 #define mode_t int
5922 EOF
5923
5924 fi
5925
5926 echo "$as_me:5926: checking for pid_t" >&5
5927 echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
5928 if test "${ac_cv_type_pid_t+set}" = set; then
5929 echo $ECHO_N "(cached) $ECHO_C" >&6
5930 else
5931 cat >"conftest.$ac_ext" <<_ACEOF
5932 #line 5932 "configure"
5933 #include "confdefs.h"
5934 $ac_includes_default
5935 int
5936 main (void)
5937 {
5938 if ((pid_t *) 0)
5939 return 0;
5940 if (sizeof (pid_t))
5941 return 0;
5942 ;
5943 return 0;
5944 }
5945 _ACEOF
5946 rm -f "conftest.$ac_objext"
5947 if { (eval echo "$as_me:5947: \"$ac_compile\"") >&5
5948 (eval $ac_compile) 2>&5
5949 ac_status=$?
5950 echo "$as_me:5950: \$? = $ac_status" >&5
5951 (exit "$ac_status"); } &&
5952 { ac_try='test -s "conftest.$ac_objext"'
5953 { (eval echo "$as_me:5953: \"$ac_try\"") >&5
5954 (eval $ac_try) 2>&5
5955 ac_status=$?
5956 echo "$as_me:5956: \$? = $ac_status" >&5
5957 (exit "$ac_status"); }; }; then
5958 ac_cv_type_pid_t=yes
5959 else
5960 echo "$as_me: failed program was:" >&5
5961 cat "conftest.$ac_ext" >&5
5962 ac_cv_type_pid_t=no
5963 fi
5964 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
5965 fi
5966 echo "$as_me:5966: result: $ac_cv_type_pid_t" >&5
5967 echo "${ECHO_T}$ac_cv_type_pid_t" >&6
5968 if test "$ac_cv_type_pid_t" = yes; then
5969 :
5970 else
5971
5972 cat >>confdefs.h <<EOF
5973 #define pid_t int
5974 EOF
5975
5976 fi
5977
5978 echo "$as_me:5978: checking for uid_t in sys/types.h" >&5
5979 echo $ECHO_N "checking for uid_t in sys/types.h... $ECHO_C" >&6
5980 if test "${ac_cv_type_uid_t+set}" = set; then
5981 echo $ECHO_N "(cached) $ECHO_C" >&6
5982 else
5983 cat >"conftest.$ac_ext" <<_ACEOF
5984 #line 5984 "configure"
5985 #include "confdefs.h"
5986 #include <sys/types.h>
5987
5988 _ACEOF
5989 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5990 $EGREP "uid_t" >/dev/null 2>&1; then
5991 ac_cv_type_uid_t=yes
5992 else
5993 ac_cv_type_uid_t=no
5994 fi
5995 rm -rf conftest*
5996
5997 fi
5998 echo "$as_me:5998: result: $ac_cv_type_uid_t" >&5
5999 echo "${ECHO_T}$ac_cv_type_uid_t" >&6
6000 if test $ac_cv_type_uid_t = no; then
6001
6002 cat >>confdefs.h <<\EOF
6003 #define uid_t int
6004 EOF
6005
6006 cat >>confdefs.h <<\EOF
6007 #define gid_t int
6008 EOF
6009
6010 fi
6011
6012 echo "$as_me:6012: checking for off_t" >&5
6013 echo $ECHO_N "checking for off_t... $ECHO_C" >&6
6014 if test "${ac_cv_type_off_t+set}" = set; then
6015 echo $ECHO_N "(cached) $ECHO_C" >&6
6016 else
6017 cat >"conftest.$ac_ext" <<_ACEOF
6018 #line 6018 "configure"
6019 #include "confdefs.h"
6020 $ac_includes_default
6021 int
6022 main (void)
6023 {
6024 if ((off_t *) 0)
6025 return 0;
6026 if (sizeof (off_t))
6027 return 0;
6028 ;
6029 return 0;
6030 }
6031 _ACEOF
6032 rm -f "conftest.$ac_objext"
6033 if { (eval echo "$as_me:6033: \"$ac_compile\"") >&5
6034 (eval $ac_compile) 2>&5
6035 ac_status=$?
6036 echo "$as_me:6036: \$? = $ac_status" >&5
6037 (exit "$ac_status"); } &&
6038 { ac_try='test -s "conftest.$ac_objext"'
6039 { (eval echo "$as_me:6039: \"$ac_try\"") >&5
6040 (eval $ac_try) 2>&5
6041 ac_status=$?
6042 echo "$as_me:6042: \$? = $ac_status" >&5
6043 (exit "$ac_status"); }; }; then
6044 ac_cv_type_off_t=yes
6045 else
6046 echo "$as_me: failed program was:" >&5
6047 cat "conftest.$ac_ext" >&5
6048 ac_cv_type_off_t=no
6049 fi
6050 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6051 fi
6052 echo "$as_me:6052: result: $ac_cv_type_off_t" >&5
6053 echo "${ECHO_T}$ac_cv_type_off_t" >&6
6054 if test "$ac_cv_type_off_t" = yes; then
6055 :
6056 else
6057
6058 cat >>confdefs.h <<EOF
6059 #define off_t long
6060 EOF
6061
6062 fi
6063
6064 ### checks for library functions
6065
6066 for ac_func in \
6067 gethostname \
6068 getusershell \
6069 endusershell \
6070 getlogin \
6071 initgroups \
6072 mkdtemp \
6073 putenv \
6074 unsetenv \
6075 sched_yield \
6076 setpgid \
6077 setsid \
6078 tcgetattr \
6079 waitpid \
6080 wcswidth \
6081 wcwidth
6082 do
6083 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
6084 echo "$as_me:6084: checking for $ac_func" >&5
6085 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
6086 if eval "test \"\${$as_ac_var+set}\" = set"; then
6087 echo $ECHO_N "(cached) $ECHO_C" >&6
6088 else
6089 cat >"conftest.$ac_ext" <<_ACEOF
6090 #line 6090 "configure"
6091 #include "confdefs.h"
6092 #define $ac_func autoconf_temporary
6093 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
6094 #undef $ac_func
6095
6096 #ifdef __cplusplus
6097 extern "C"
6098 #endif
6099
6100 /* We use char because int might match the return type of a gcc2
6101 builtin and then its argument prototype would still apply. */
6102 char $ac_func (void);
6103
6104 int
6105 main (void)
6106 {
6107
6108 /* The GNU C library defines stubs for functions which it implements
6109 to always fail with ENOSYS. Some functions are actually named
6110 something starting with __ and the normal name is an alias. */
6111 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6112 #error found stub for $ac_func
6113 #endif
6114
6115 return $ac_func ();
6116 ;
6117 return 0;
6118 }
6119 _ACEOF
6120 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6121 if { (eval echo "$as_me:6121: \"$ac_link\"") >&5
6122 (eval $ac_link) 2>&5
6123 ac_status=$?
6124 echo "$as_me:6124: \$? = $ac_status" >&5
6125 (exit "$ac_status"); } &&
6126 { ac_try='test -s "conftest$ac_exeext"'
6127 { (eval echo "$as_me:6127: \"$ac_try\"") >&5
6128 (eval $ac_try) 2>&5
6129 ac_status=$?
6130 echo "$as_me:6130: \$? = $ac_status" >&5
6131 (exit "$ac_status"); }; }; then
6132 eval "$as_ac_var=yes"
6133 else
6134 echo "$as_me: failed program was:" >&5
6135 cat "conftest.$ac_ext" >&5
6136 eval "$as_ac_var=no"
6137 fi
6138 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6139 fi
6140 echo "$as_me:6140: result: `eval echo '${'"$as_ac_var"'}'`" >&5
6141 echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
6142 if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
6143 cat >>confdefs.h <<EOF
6144 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
6145 EOF
6146
6147 fi
6148 done
6149
6150 cf_save_libs="$LIBS"
6151 echo "$as_me:6151: checking for clock_gettime" >&5
6152 echo $ECHO_N "checking for clock_gettime... $ECHO_C" >&6
6153 if test "${ac_cv_func_clock_gettime+set}" = set; then
6154 echo $ECHO_N "(cached) $ECHO_C" >&6
6155 else
6156 cat >"conftest.$ac_ext" <<_ACEOF
6157 #line 6157 "configure"
6158 #include "confdefs.h"
6159 #define clock_gettime autoconf_temporary
6160 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
6161 #undef clock_gettime
6162
6163 #ifdef __cplusplus
6164 extern "C"
6165 #endif
6166
6167 /* We use char because int might match the return type of a gcc2
6168 builtin and then its argument prototype would still apply. */
6169 char clock_gettime (void);
6170
6171 int
6172 main (void)
6173 {
6174
6175 /* The GNU C library defines stubs for functions which it implements
6176 to always fail with ENOSYS. Some functions are actually named
6177 something starting with __ and the normal name is an alias. */
6178 #if defined (__stub_clock_gettime) || defined (__stub___clock_gettime)
6179 #error found stub for clock_gettime
6180 #endif
6181
6182 return clock_gettime ();
6183 ;
6184 return 0;
6185 }
6186 _ACEOF
6187 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6188 if { (eval echo "$as_me:6188: \"$ac_link\"") >&5
6189 (eval $ac_link) 2>&5
6190 ac_status=$?
6191 echo "$as_me:6191: \$? = $ac_status" >&5
6192 (exit "$ac_status"); } &&
6193 { ac_try='test -s "conftest$ac_exeext"'
6194 { (eval echo "$as_me:6194: \"$ac_try\"") >&5
6195 (eval $ac_try) 2>&5
6196 ac_status=$?
6197 echo "$as_me:6197: \$? = $ac_status" >&5
6198 (exit "$ac_status"); }; }; then
6199 ac_cv_func_clock_gettime=yes
6200 else
6201 echo "$as_me: failed program was:" >&5
6202 cat "conftest.$ac_ext" >&5
6203 ac_cv_func_clock_gettime=no
6204 fi
6205 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6206 fi
6207 echo "$as_me:6207: result: $ac_cv_func_clock_gettime" >&5
6208 echo "${ECHO_T}$ac_cv_func_clock_gettime" >&6
6209 if test "$ac_cv_func_clock_gettime" = yes; then
6210 cf_cv_test_clock_gettime=yes
6211 else
6212 echo "$as_me:6212: checking for clock_gettime in -lrt" >&5
6213 echo $ECHO_N "checking for clock_gettime in -lrt... $ECHO_C" >&6
6214 if test "${ac_cv_lib_rt_clock_gettime+set}" = set; then
6215 echo $ECHO_N "(cached) $ECHO_C" >&6
6216 else
6217 ac_check_lib_save_LIBS=$LIBS
6218 LIBS="-lrt $LIBS"
6219 cat >"conftest.$ac_ext" <<_ACEOF
6220 #line 6220 "configure"
6221 #include "confdefs.h"
6222
6223 /* Override any gcc2 internal prototype to avoid an error. */
6224 #ifdef __cplusplus
6225 extern "C"
6226 #endif
6227 /* We use char because int might match the return type of a gcc2
6228 builtin and then its argument prototype would still apply. */
6229 char clock_gettime (void);
6230 int
6231 main (void)
6232 {
6233 clock_gettime ();
6234 ;
6235 return 0;
6236 }
6237 _ACEOF
6238 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6239 if { (eval echo "$as_me:6239: \"$ac_link\"") >&5
6240 (eval $ac_link) 2>&5
6241 ac_status=$?
6242 echo "$as_me:6242: \$? = $ac_status" >&5
6243 (exit "$ac_status"); } &&
6244 { ac_try='test -s "conftest$ac_exeext"'
6245 { (eval echo "$as_me:6245: \"$ac_try\"") >&5
6246 (eval $ac_try) 2>&5
6247 ac_status=$?
6248 echo "$as_me:6248: \$? = $ac_status" >&5
6249 (exit "$ac_status"); }; }; then
6250 ac_cv_lib_rt_clock_gettime=yes
6251 else
6252 echo "$as_me: failed program was:" >&5
6253 cat "conftest.$ac_ext" >&5
6254 ac_cv_lib_rt_clock_gettime=no
6255 fi
6256 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6257 LIBS=$ac_check_lib_save_LIBS
6258 fi
6259 echo "$as_me:6259: result: $ac_cv_lib_rt_clock_gettime" >&5
6260 echo "${ECHO_T}$ac_cv_lib_rt_clock_gettime" >&6
6261 if test "$ac_cv_lib_rt_clock_gettime" = yes; then
6262 LIBS="-lrt $LIBS"
6263 cf_cv_test_clock_gettime=yes
6264 else
6265 cf_cv_test_clock_gettime=no
6266 fi
6267
6268 fi
6269
6270 if test "$cf_cv_test_clock_gettime" = yes ; then
6271 echo "$as_me:6271: checking if clock_gettime links" >&5
6272 echo $ECHO_N "checking if clock_gettime links... $ECHO_C" >&6
6273 if test "${cf_cv_func_clock_gettime+set}" = set; then
6274 echo $ECHO_N "(cached) $ECHO_C" >&6
6275 else
6276
6277 cat >"conftest.$ac_ext" <<_ACEOF
6278 #line 6278 "configure"
6279 #include "confdefs.h"
6280
6281 $ac_includes_default
6282 #include <time.h>
6283
6284 int
6285 main (void)
6286 {
6287 struct timespec ts;
6288 int rc = clock_gettime(CLOCK_REALTIME, &ts)
6289 + clock_gettime(CLOCK_MONOTONIC, &ts);
6290 (void) rc; (void)ts
6291 ;
6292 return 0;
6293 }
6294 _ACEOF
6295 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6296 if { (eval echo "$as_me:6296: \"$ac_link\"") >&5
6297 (eval $ac_link) 2>&5
6298 ac_status=$?
6299 echo "$as_me:6299: \$? = $ac_status" >&5
6300 (exit "$ac_status"); } &&
6301 { ac_try='test -s "conftest$ac_exeext"'
6302 { (eval echo "$as_me:6302: \"$ac_try\"") >&5
6303 (eval $ac_try) 2>&5
6304 ac_status=$?
6305 echo "$as_me:6305: \$? = $ac_status" >&5
6306 (exit "$ac_status"); }; }; then
6307 cf_cv_func_clock_gettime=yes
6308 else
6309 echo "$as_me: failed program was:" >&5
6310 cat "conftest.$ac_ext" >&5
6311 cf_cv_func_clock_gettime=no
6312 fi
6313 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6314
6315 fi
6316 echo "$as_me:6316: result: $cf_cv_func_clock_gettime" >&5
6317 echo "${ECHO_T}$cf_cv_func_clock_gettime" >&6
6318 else
6319 cf_cv_func_clock_gettime=no
6320 fi
6321
6322 if test "$cf_cv_func_clock_gettime" = yes
6323 then
6324
6325 cat >>confdefs.h <<\EOF
6326 #define HAVE_CLOCK_GETTIME 1
6327 EOF
6328
6329 else
6330 echo "$as_me:6330: checking for gettimeofday" >&5
6331 echo $ECHO_N "checking for gettimeofday... $ECHO_C" >&6
6332 if test "${ac_cv_func_gettimeofday+set}" = set; then
6333 echo $ECHO_N "(cached) $ECHO_C" >&6
6334 else
6335 cat >"conftest.$ac_ext" <<_ACEOF
6336 #line 6336 "configure"
6337 #include "confdefs.h"
6338 #define gettimeofday autoconf_temporary
6339 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
6340 #undef gettimeofday
6341
6342 #ifdef __cplusplus
6343 extern "C"
6344 #endif
6345
6346 /* We use char because int might match the return type of a gcc2
6347 builtin and then its argument prototype would still apply. */
6348 char gettimeofday (void);
6349
6350 int
6351 main (void)
6352 {
6353
6354 /* The GNU C library defines stubs for functions which it implements
6355 to always fail with ENOSYS. Some functions are actually named
6356 something starting with __ and the normal name is an alias. */
6357 #if defined (__stub_gettimeofday) || defined (__stub___gettimeofday)
6358 #error found stub for gettimeofday
6359 #endif
6360
6361 return gettimeofday ();
6362 ;
6363 return 0;
6364 }
6365 _ACEOF
6366 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6367 if { (eval echo "$as_me:6367: \"$ac_link\"") >&5
6368 (eval $ac_link) 2>&5
6369 ac_status=$?
6370 echo "$as_me:6370: \$? = $ac_status" >&5
6371 (exit "$ac_status"); } &&
6372 { ac_try='test -s "conftest$ac_exeext"'
6373 { (eval echo "$as_me:6373: \"$ac_try\"") >&5
6374 (eval $ac_try) 2>&5
6375 ac_status=$?
6376 echo "$as_me:6376: \$? = $ac_status" >&5
6377 (exit "$ac_status"); }; }; then
6378 ac_cv_func_gettimeofday=yes
6379 else
6380 echo "$as_me: failed program was:" >&5
6381 cat "conftest.$ac_ext" >&5
6382 ac_cv_func_gettimeofday=no
6383 fi
6384 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6385 fi
6386 echo "$as_me:6386: result: $ac_cv_func_gettimeofday" >&5
6387 echo "${ECHO_T}$ac_cv_func_gettimeofday" >&6
6388 if test "$ac_cv_func_gettimeofday" = yes; then
6389
6390 cat >>confdefs.h <<\EOF
6391 #define HAVE_GETTIMEOFDAY 1
6392 EOF
6393
6394 else
6395
6396 echo "$as_me:6396: checking for gettimeofday in -lbsd" >&5
6397 echo $ECHO_N "checking for gettimeofday in -lbsd... $ECHO_C" >&6
6398 if test "${ac_cv_lib_bsd_gettimeofday+set}" = set; then
6399 echo $ECHO_N "(cached) $ECHO_C" >&6
6400 else
6401 ac_check_lib_save_LIBS=$LIBS
6402 LIBS="-lbsd $LIBS"
6403 cat >"conftest.$ac_ext" <<_ACEOF
6404 #line 6404 "configure"
6405 #include "confdefs.h"
6406
6407 /* Override any gcc2 internal prototype to avoid an error. */
6408 #ifdef __cplusplus
6409 extern "C"
6410 #endif
6411 /* We use char because int might match the return type of a gcc2
6412 builtin and then its argument prototype would still apply. */
6413 char gettimeofday (void);
6414 int
6415 main (void)
6416 {
6417 gettimeofday ();
6418 ;
6419 return 0;
6420 }
6421 _ACEOF
6422 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6423 if { (eval echo "$as_me:6423: \"$ac_link\"") >&5
6424 (eval $ac_link) 2>&5
6425 ac_status=$?
6426 echo "$as_me:6426: \$? = $ac_status" >&5
6427 (exit "$ac_status"); } &&
6428 { ac_try='test -s "conftest$ac_exeext"'
6429 { (eval echo "$as_me:6429: \"$ac_try\"") >&5
6430 (eval $ac_try) 2>&5
6431 ac_status=$?
6432 echo "$as_me:6432: \$? = $ac_status" >&5
6433 (exit "$ac_status"); }; }; then
6434 ac_cv_lib_bsd_gettimeofday=yes
6435 else
6436 echo "$as_me: failed program was:" >&5
6437 cat "conftest.$ac_ext" >&5
6438 ac_cv_lib_bsd_gettimeofday=no
6439 fi
6440 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6441 LIBS=$ac_check_lib_save_LIBS
6442 fi
6443 echo "$as_me:6443: result: $ac_cv_lib_bsd_gettimeofday" >&5
6444 echo "${ECHO_T}$ac_cv_lib_bsd_gettimeofday" >&6
6445 if test "$ac_cv_lib_bsd_gettimeofday" = yes; then
6446
6447 cat >>confdefs.h <<\EOF
6448 #define HAVE_GETTIMEOFDAY 1
6449 EOF
6450
6451 cf_add_libs="$LIBS"
6452 # reverse order
6453 cf_add_0lib=
6454 for cf_add_1lib in -lbsd; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
6455 # filter duplicates
6456 for cf_add_1lib in $cf_add_0lib; do
6457 for cf_add_2lib in $cf_add_libs; do
6458 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
6459 cf_add_1lib=
6460 break
6461 fi
6462 done
6463 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
6464 done
6465 LIBS="$cf_add_libs"
6466
6467 fi
6468
6469 fi
6470 fi
6471
6472 echo "$as_me:6472: checking for strftime function" >&5
6473 echo $ECHO_N "checking for strftime function... $ECHO_C" >&6
6474 if test "${cf_cv_func_strftime+set}" = set; then
6475 echo $ECHO_N "(cached) $ECHO_C" >&6
6476 else
6477
6478 cat >"conftest.$ac_ext" <<_ACEOF
6479 #line 6479 "configure"
6480 #include "confdefs.h"
6481
6482 $ac_includes_default
6483 #include <time.h>
6484
6485 int
6486 main (void)
6487 {
6488
6489 time_t now = time((time_t*)0);
6490 struct tm *tm = localtime(&now);
6491 char buffer[80];
6492 size_t result = strftime(buffer, sizeof(buffer), "%c", tm);
6493
6494 (void)result;
6495 (void)buffer;
6496
6497 ;
6498 return 0;
6499 }
6500 _ACEOF
6501 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6502 if { (eval echo "$as_me:6502: \"$ac_link\"") >&5
6503 (eval $ac_link) 2>&5
6504 ac_status=$?
6505 echo "$as_me:6505: \$? = $ac_status" >&5
6506 (exit "$ac_status"); } &&
6507 { ac_try='test -s "conftest$ac_exeext"'
6508 { (eval echo "$as_me:6508: \"$ac_try\"") >&5
6509 (eval $ac_try) 2>&5
6510 ac_status=$?
6511 echo "$as_me:6511: \$? = $ac_status" >&5
6512 (exit "$ac_status"); }; }; then
6513 cf_cv_func_strftime=yes
6514 else
6515 echo "$as_me: failed program was:" >&5
6516 cat "conftest.$ac_ext" >&5
6517 cf_cv_func_strftime=no
6518 fi
6519 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6520
6521 fi
6522 echo "$as_me:6522: result: $cf_cv_func_strftime" >&5
6523 echo "${ECHO_T}$cf_cv_func_strftime" >&6
6524
6525 test "$cf_cv_func_strftime" = yes &&
6526 cat >>confdefs.h <<\EOF
6527 #define HAVE_STRFTIME 1
6528 EOF
6529
6530 for ac_header in \
6531 unistd.h \
6532
6533 do
6534 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6535 echo "$as_me:6535: checking for $ac_header" >&5
6536 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6537 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6538 echo $ECHO_N "(cached) $ECHO_C" >&6
6539 else
6540 cat >"conftest.$ac_ext" <<_ACEOF
6541 #line 6541 "configure"
6542 #include "confdefs.h"
6543 #include <$ac_header>
6544 _ACEOF
6545 if { (eval echo "$as_me:6545: \"$ac_cpp "conftest.$ac_ext"\"") >&5
6546 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
6547 ac_status=$?
6548 $EGREP -v '^ *\+' conftest.er1 >conftest.err
6549 rm -f conftest.er1
6550 cat conftest.err >&5
6551 echo "$as_me:6551: \$? = $ac_status" >&5
6552 (exit "$ac_status"); } >/dev/null; then
6553 if test -s conftest.err; then
6554 ac_cpp_err=$ac_c_preproc_warn_flag
6555 else
6556 ac_cpp_err=
6557 fi
6558 else
6559 ac_cpp_err=yes
6560 fi
6561 if test -z "$ac_cpp_err"; then
6562 eval "$as_ac_Header=yes"
6563 else
6564 echo "$as_me: failed program was:" >&5
6565 cat "conftest.$ac_ext" >&5
6566 eval "$as_ac_Header=no"
6567 fi
6568 rm -f conftest.err "conftest.$ac_ext"
6569 fi
6570 echo "$as_me:6570: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
6571 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
6572 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
6573 cat >>confdefs.h <<EOF
6574 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6575 EOF
6576
6577 fi
6578 done
6579
6580 echo "$as_me:6580: checking for working mkstemp" >&5
6581 echo $ECHO_N "checking for working mkstemp... $ECHO_C" >&6
6582 if test "${cf_cv_func_mkstemp+set}" = set; then
6583 echo $ECHO_N "(cached) $ECHO_C" >&6
6584 else
6585
6586 rm -rf ./conftest*
6587 if test "$cross_compiling" = yes; then
6588 cf_cv_func_mkstemp=maybe
6589 else
6590 cat >"conftest.$ac_ext" <<_ACEOF
6591 #line 6591 "configure"
6592 #include "confdefs.h"
6593
6594 $ac_includes_default
6595
6596 int main(void)
6597 {
6598 static char tmpl[] = "conftestXXXXXX";
6599 char name[2][80];
6600 int n;
6601 int result = 0;
6602 int fd;
6603 struct stat sb;
6604
6605 umask(077);
6606 for (n = 0; n < 2; ++n) {
6607 strcpy(name[n], tmpl);
6608 if ((fd = mkstemp(name[n])) >= 0) {
6609 if (!strcmp(name[n], tmpl)
6610 || stat(name[n], &sb) != 0
6611 || (sb.st_mode & S_IFMT) != S_IFREG
6612 || (sb.st_mode & 077) != 0) {
6613 result = 1;
6614 }
6615 close(fd);
6616 }
6617 }
6618 if (result == 0
6619 && !strcmp(name[0], name[1]))
6620 result = 1;
6621 ${cf_cv_main_return:-return}(result);
6622 }
6623
6624 _ACEOF
6625 rm -f "conftest$ac_exeext"
6626 if { (eval echo "$as_me:6626: \"$ac_link\"") >&5
6627 (eval $ac_link) 2>&5
6628 ac_status=$?
6629 echo "$as_me:6629: \$? = $ac_status" >&5
6630 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
6631 { (eval echo "$as_me:6631: \"$ac_try\"") >&5
6632 (eval $ac_try) 2>&5
6633 ac_status=$?
6634 echo "$as_me:6634: \$? = $ac_status" >&5
6635 (exit "$ac_status"); }; }; then
6636 cf_cv_func_mkstemp=yes
6637
6638 else
6639 echo "$as_me: program exited with status $ac_status" >&5
6640 echo "$as_me: failed program was:" >&5
6641 cat "conftest.$ac_ext" >&5
6642 cf_cv_func_mkstemp=no
6643
6644 fi
6645 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
6646 fi
6647
6648 fi
6649 echo "$as_me:6649: result: $cf_cv_func_mkstemp" >&5
6650 echo "${ECHO_T}$cf_cv_func_mkstemp" >&6
6651 if test "x$cf_cv_func_mkstemp" = xmaybe ; then
6652 echo "$as_me:6652: checking for mkstemp" >&5
6653 echo $ECHO_N "checking for mkstemp... $ECHO_C" >&6
6654 if test "${ac_cv_func_mkstemp+set}" = set; then
6655 echo $ECHO_N "(cached) $ECHO_C" >&6
6656 else
6657 cat >"conftest.$ac_ext" <<_ACEOF
6658 #line 6658 "configure"
6659 #include "confdefs.h"
6660 #define mkstemp autoconf_temporary
6661 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
6662 #undef mkstemp
6663
6664 #ifdef __cplusplus
6665 extern "C"
6666 #endif
6667
6668 /* We use char because int might match the return type of a gcc2
6669 builtin and then its argument prototype would still apply. */
6670 char mkstemp (void);
6671
6672 int
6673 main (void)
6674 {
6675
6676 /* The GNU C library defines stubs for functions which it implements
6677 to always fail with ENOSYS. Some functions are actually named
6678 something starting with __ and the normal name is an alias. */
6679 #if defined (__stub_mkstemp) || defined (__stub___mkstemp)
6680 #error found stub for mkstemp
6681 #endif
6682
6683 return mkstemp ();
6684 ;
6685 return 0;
6686 }
6687 _ACEOF
6688 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
6689 if { (eval echo "$as_me:6689: \"$ac_link\"") >&5
6690 (eval $ac_link) 2>&5
6691 ac_status=$?
6692 echo "$as_me:6692: \$? = $ac_status" >&5
6693 (exit "$ac_status"); } &&
6694 { ac_try='test -s "conftest$ac_exeext"'
6695 { (eval echo "$as_me:6695: \"$ac_try\"") >&5
6696 (eval $ac_try) 2>&5
6697 ac_status=$?
6698 echo "$as_me:6698: \$? = $ac_status" >&5
6699 (exit "$ac_status"); }; }; then
6700 ac_cv_func_mkstemp=yes
6701 else
6702 echo "$as_me: failed program was:" >&5
6703 cat "conftest.$ac_ext" >&5
6704 ac_cv_func_mkstemp=no
6705 fi
6706 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
6707 fi
6708 echo "$as_me:6708: result: $ac_cv_func_mkstemp" >&5
6709 echo "${ECHO_T}$ac_cv_func_mkstemp" >&6
6710
6711 fi
6712 if test "x$cf_cv_func_mkstemp" = xyes || test "x$ac_cv_func_mkstemp" = xyes ; then
6713
6714 cat >>confdefs.h <<\EOF
6715 #define HAVE_MKSTEMP 1
6716 EOF
6717
6718 fi
6719
6720 echo "$as_me:6720: checking if setitimer is available" >&5
6721 echo $ECHO_N "checking if setitimer is available... $ECHO_C" >&6
6722 if test "${cf_cv_func_setitimer+set}" = set; then
6723 echo $ECHO_N "(cached) $ECHO_C" >&6
6724 else
6725
6726 cat >"conftest.$ac_ext" <<_ACEOF
6727 #line 6727 "configure"
6728 #include "confdefs.h"
6729
6730 $ac_includes_default
6731 #include <sys/time.h>
6732
6733 int
6734 main (void)
6735 {
6736
6737 struct itimerval it;
6738 memset(&it, 0, sizeof(struct itimerval));
6739 it.it_value.tv_sec = 1;
6740 setitimer(ITIMER_REAL, &it, NULL);
6741
6742 ;
6743 return 0;
6744 }
6745 _ACEOF
6746 rm -f "conftest.$ac_objext"
6747 if { (eval echo "$as_me:6747: \"$ac_compile\"") >&5
6748 (eval $ac_compile) 2>&5
6749 ac_status=$?
6750 echo "$as_me:6750: \$? = $ac_status" >&5
6751 (exit "$ac_status"); } &&
6752 { ac_try='test -s "conftest.$ac_objext"'
6753 { (eval echo "$as_me:6753: \"$ac_try\"") >&5
6754 (eval $ac_try) 2>&5
6755 ac_status=$?
6756 echo "$as_me:6756: \$? = $ac_status" >&5
6757 (exit "$ac_status"); }; }; then
6758 cf_cv_func_setitimer=yes
6759 else
6760 echo "$as_me: failed program was:" >&5
6761 cat "conftest.$ac_ext" >&5
6762 cf_cv_func_setitimer=no
6763 fi
6764 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6765
6766 fi
6767 echo "$as_me:6767: result: $cf_cv_func_setitimer" >&5
6768 echo "${ECHO_T}$cf_cv_func_setitimer" >&6
6769 test "$cf_cv_func_setitimer" != no &&
6770 cat >>confdefs.h <<\EOF
6771 #define HAVE_SETITIMER 1
6772 EOF
6773
6774 for ac_header in lastlog.h paths.h
6775 do
6776 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6777 echo "$as_me:6777: checking for $ac_header" >&5
6778 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6779 if eval "test \"\${$as_ac_Header+set}\" = set"; then
6780 echo $ECHO_N "(cached) $ECHO_C" >&6
6781 else
6782 cat >"conftest.$ac_ext" <<_ACEOF
6783 #line 6783 "configure"
6784 #include "confdefs.h"
6785 #include <$ac_header>
6786 _ACEOF
6787 if { (eval echo "$as_me:6787: \"$ac_cpp "conftest.$ac_ext"\"") >&5
6788 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
6789 ac_status=$?
6790 $EGREP -v '^ *\+' conftest.er1 >conftest.err
6791 rm -f conftest.er1
6792 cat conftest.err >&5
6793 echo "$as_me:6793: \$? = $ac_status" >&5
6794 (exit "$ac_status"); } >/dev/null; then
6795 if test -s conftest.err; then
6796 ac_cpp_err=$ac_c_preproc_warn_flag
6797 else
6798 ac_cpp_err=
6799 fi
6800 else
6801 ac_cpp_err=yes
6802 fi
6803 if test -z "$ac_cpp_err"; then
6804 eval "$as_ac_Header=yes"
6805 else
6806 echo "$as_me: failed program was:" >&5
6807 cat "conftest.$ac_ext" >&5
6808 eval "$as_ac_Header=no"
6809 fi
6810 rm -f conftest.err "conftest.$ac_ext"
6811 fi
6812 echo "$as_me:6812: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
6813 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
6814 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
6815 cat >>confdefs.h <<EOF
6816 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6817 EOF
6818
6819 fi
6820 done
6821
6822 echo "$as_me:6822: checking for lastlog path" >&5
6823 echo $ECHO_N "checking for lastlog path... $ECHO_C" >&6
6824 if test "${cf_cv_path_lastlog+set}" = set; then
6825 echo $ECHO_N "(cached) $ECHO_C" >&6
6826 else
6827
6828 cat >"conftest.$ac_ext" <<_ACEOF
6829 #line 6829 "configure"
6830 #include "confdefs.h"
6831
6832 #include <sys/types.h>
6833 #ifdef HAVE_LASTLOG_H
6834 #include <lastlog.h>
6835 #else
6836 #ifdef HAVE_PATHS_H
6837 #include <paths.h>
6838 #endif
6839 #endif
6840 int
6841 main (void)
6842 {
6843 static char path[] = _PATH_LASTLOG; (void)path
6844 ;
6845 return 0;
6846 }
6847 _ACEOF
6848 rm -f "conftest.$ac_objext"
6849 if { (eval echo "$as_me:6849: \"$ac_compile\"") >&5
6850 (eval $ac_compile) 2>&5
6851 ac_status=$?
6852 echo "$as_me:6852: \$? = $ac_status" >&5
6853 (exit "$ac_status"); } &&
6854 { ac_try='test -s "conftest.$ac_objext"'
6855 { (eval echo "$as_me:6855: \"$ac_try\"") >&5
6856 (eval $ac_try) 2>&5
6857 ac_status=$?
6858 echo "$as_me:6858: \$? = $ac_status" >&5
6859 (exit "$ac_status"); }; }; then
6860 cf_cv_path_lastlog="_PATH_LASTLOG"
6861 else
6862 echo "$as_me: failed program was:" >&5
6863 cat "conftest.$ac_ext" >&5
6864 if test -f /usr/adm/lastlog ; then
6865 cf_cv_path_lastlog=/usr/adm/lastlog
6866 else
6867 cf_cv_path_lastlog=no
6868 fi
6869 fi
6870 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6871
6872 fi
6873 echo "$as_me:6873: result: $cf_cv_path_lastlog" >&5
6874 echo "${ECHO_T}$cf_cv_path_lastlog" >&6
6875 test "$cf_cv_path_lastlog" != no &&
6876 cat >>confdefs.h <<\EOF
6877 #define USE_LASTLOG 1
6878 EOF
6879
6880 echo "$as_me:6880: checking for utmp implementation" >&5
6881 echo $ECHO_N "checking for utmp implementation... $ECHO_C" >&6
6882 if test "${cf_cv_have_utmp+set}" = set; then
6883 echo $ECHO_N "(cached) $ECHO_C" >&6
6884 else
6885
6886 cf_cv_have_utmp=no
6887 for cf_header in utmpx utmp ; do
6888 cf_utmp_includes="
6889 #include <sys/types.h>
6890 #include <${cf_header}.h>
6891 #define getutent getutxent
6892 #ifdef USE_LASTLOG
6893 #include <lastlog.h> /* may conflict with utmpx.h on Linux */
6894 #endif
6895 "
6896 cat >"conftest.$ac_ext" <<_ACEOF
6897 #line 6897 "configure"
6898 #include "confdefs.h"
6899 $cf_utmp_includes
6900 int
6901 main (void)
6902 {
6903 struct $cf_header x;
6904 char *name = x.ut_name; /* utmp.h and compatible definitions */
6905 (void)x;
6906 (void)name;
6907
6908 ;
6909 return 0;
6910 }
6911 _ACEOF
6912 rm -f "conftest.$ac_objext"
6913 if { (eval echo "$as_me:6913: \"$ac_compile\"") >&5
6914 (eval $ac_compile) 2>&5
6915 ac_status=$?
6916 echo "$as_me:6916: \$? = $ac_status" >&5
6917 (exit "$ac_status"); } &&
6918 { ac_try='test -s "conftest.$ac_objext"'
6919 { (eval echo "$as_me:6919: \"$ac_try\"") >&5
6920 (eval $ac_try) 2>&5
6921 ac_status=$?
6922 echo "$as_me:6922: \$? = $ac_status" >&5
6923 (exit "$ac_status"); }; }; then
6924 cf_cv_have_utmp=$cf_header
6925 break
6926 else
6927 echo "$as_me: failed program was:" >&5
6928 cat "conftest.$ac_ext" >&5
6929
6930 cat >"conftest.$ac_ext" <<_ACEOF
6931 #line 6931 "configure"
6932 #include "confdefs.h"
6933 $cf_utmp_includes
6934 int
6935 main (void)
6936 {
6937 struct $cf_header x;
6938 char *name = x.ut_user; /* utmpx.h must declare this */
6939 (void)x;
6940 (void)name;
6941
6942 ;
6943 return 0;
6944 }
6945 _ACEOF
6946 rm -f "conftest.$ac_objext"
6947 if { (eval echo "$as_me:6947: \"$ac_compile\"") >&5
6948 (eval $ac_compile) 2>&5
6949 ac_status=$?
6950 echo "$as_me:6950: \$? = $ac_status" >&5
6951 (exit "$ac_status"); } &&
6952 { ac_try='test -s "conftest.$ac_objext"'
6953 { (eval echo "$as_me:6953: \"$ac_try\"") >&5
6954 (eval $ac_try) 2>&5
6955 ac_status=$?
6956 echo "$as_me:6956: \$? = $ac_status" >&5
6957 (exit "$ac_status"); }; }; then
6958 cf_cv_have_utmp=$cf_header
6959 break
6960
6961 else
6962 echo "$as_me: failed program was:" >&5
6963 cat "conftest.$ac_ext" >&5
6964 fi
6965 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6966 fi
6967 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
6968 done
6969
6970 fi
6971 echo "$as_me:6971: result: $cf_cv_have_utmp" >&5
6972 echo "${ECHO_T}$cf_cv_have_utmp" >&6
6973
6974 if test "$cf_cv_have_utmp" != no ; then
6975
6976 cat >>confdefs.h <<\EOF
6977 #define HAVE_UTMP 1
6978 EOF
6979
6980 test "$cf_cv_have_utmp" = utmpx &&
6981 cat >>confdefs.h <<\EOF
6982 #define UTMPX_FOR_UTMP 1
6983 EOF
6984
6985 if test "$cf_cv_have_utmp" != no ; then
6986 echo "$as_me:6986: checking if ${cf_cv_have_utmp}.ut_host is declared" >&5
6987 echo $ECHO_N "checking if ${cf_cv_have_utmp}.ut_host is declared... $ECHO_C" >&6
6988 if test "${cf_cv_have_utmp_ut_host+set}" = set; then
6989 echo $ECHO_N "(cached) $ECHO_C" >&6
6990 else
6991
6992 cat >"conftest.$ac_ext" <<_ACEOF
6993 #line 6993 "configure"
6994 #include "confdefs.h"
6995
6996 #include <sys/types.h>
6997 #include <${cf_cv_have_utmp}.h>
6998 int
6999 main (void)
7000 {
7001 struct $cf_cv_have_utmp x;
7002 char *y = &x.ut_host[0];
7003 (void)x;
7004 (void)y
7005 ;
7006 return 0;
7007 }
7008 _ACEOF
7009 rm -f "conftest.$ac_objext"
7010 if { (eval echo "$as_me:7010: \"$ac_compile\"") >&5
7011 (eval $ac_compile) 2>&5
7012 ac_status=$?
7013 echo "$as_me:7013: \$? = $ac_status" >&5
7014 (exit "$ac_status"); } &&
7015 { ac_try='test -s "conftest.$ac_objext"'
7016 { (eval echo "$as_me:7016: \"$ac_try\"") >&5
7017 (eval $ac_try) 2>&5
7018 ac_status=$?
7019 echo "$as_me:7019: \$? = $ac_status" >&5
7020 (exit "$ac_status"); }; }; then
7021 cf_cv_have_utmp_ut_host=yes
7022 else
7023 echo "$as_me: failed program was:" >&5
7024 cat "conftest.$ac_ext" >&5
7025 cf_cv_have_utmp_ut_host=no
7026 fi
7027 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
7028
7029 fi
7030
7031 echo "$as_me:7031: result: $cf_cv_have_utmp_ut_host" >&5
7032 echo "${ECHO_T}$cf_cv_have_utmp_ut_host" >&6
7033 test "$cf_cv_have_utmp_ut_host" != no &&
7034 cat >>confdefs.h <<\EOF
7035 #define HAVE_UTMP_UT_HOST 1
7036 EOF
7037
7038 fi
7039
7040 if test "$cf_cv_have_utmp" != no ; then
7041 echo "$as_me:7041: checking if ${cf_cv_have_utmp}.ut_syslen is declared" >&5
7042 echo $ECHO_N "checking if ${cf_cv_have_utmp}.ut_syslen is declared... $ECHO_C" >&6
7043 if test "${cf_cv_have_utmp_ut_syslen+set}" = set; then
7044 echo $ECHO_N "(cached) $ECHO_C" >&6
7045 else
7046
7047 cat >"conftest.$ac_ext" <<_ACEOF
7048 #line 7048 "configure"
7049 #include "confdefs.h"
7050
7051 #include <sys/types.h>
7052 #include <${cf_cv_have_utmp}.h>
7053 int
7054 main (void)
7055 {
7056 struct $cf_cv_have_utmp x;
7057 int y = x.ut_syslen;
7058 (void)x;
7059 (void)y
7060 ;
7061 return 0;
7062 }
7063 _ACEOF
7064 rm -f "conftest.$ac_objext"
7065 if { (eval echo "$as_me:7065: \"$ac_compile\"") >&5
7066 (eval $ac_compile) 2>&5
7067 ac_status=$?
7068 echo "$as_me:7068: \$? = $ac_status" >&5
7069 (exit "$ac_status"); } &&
7070 { ac_try='test -s "conftest.$ac_objext"'
7071 { (eval echo "$as_me:7071: \"$ac_try\"") >&5
7072 (eval $ac_try) 2>&5
7073 ac_status=$?
7074 echo "$as_me:7074: \$? = $ac_status" >&5
7075 (exit "$ac_status"); }; }; then
7076 cf_cv_have_utmp_ut_syslen=yes
7077 else
7078 echo "$as_me: failed program was:" >&5
7079 cat "conftest.$ac_ext" >&5
7080 cf_cv_have_utmp_ut_syslen=no
7081 fi
7082 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
7083
7084 fi
7085
7086 echo "$as_me:7086: result: $cf_cv_have_utmp_ut_syslen" >&5
7087 echo "${ECHO_T}$cf_cv_have_utmp_ut_syslen" >&6
7088 test "$cf_cv_have_utmp_ut_syslen" != no &&
7089 cat >>confdefs.h <<\EOF
7090 #define HAVE_UTMP_UT_SYSLEN 1
7091 EOF
7092
7093 fi
7094
7095 if test "$cf_cv_have_utmp" != no ; then
7096 echo "$as_me:7096: checking if ${cf_cv_have_utmp}.ut_name is declared" >&5
7097 echo $ECHO_N "checking if ${cf_cv_have_utmp}.ut_name is declared... $ECHO_C" >&6
7098 if test "${cf_cv_have_utmp_ut_name+set}" = set; then
7099 echo $ECHO_N "(cached) $ECHO_C" >&6
7100 else
7101
7102 cf_cv_have_utmp_ut_name=no
7103 cf_utmp_includes="
7104 #include <sys/types.h>
7105 #include <${cf_cv_have_utmp}.h>
7106 #define getutent getutxent
7107 #ifdef USE_LASTLOG
7108 #include <lastlog.h> /* may conflict with utmpx.h on Linux */
7109 #endif
7110 "
7111 for cf_header in ut_name ut_user ; do
7112 cat >"conftest.$ac_ext" <<_ACEOF
7113 #line 7113 "configure"
7114 #include "confdefs.h"
7115 $cf_utmp_includes
7116 int
7117 main (void)
7118 {
7119 struct $cf_cv_have_utmp x;
7120 char *name = x.$cf_header;
7121 (void)x;
7122 (void)name;
7123
7124 ;
7125 return 0;
7126 }
7127 _ACEOF
7128 rm -f "conftest.$ac_objext"
7129 if { (eval echo "$as_me:7129: \"$ac_compile\"") >&5
7130 (eval $ac_compile) 2>&5
7131 ac_status=$?
7132 echo "$as_me:7132: \$? = $ac_status" >&5
7133 (exit "$ac_status"); } &&
7134 { ac_try='test -s "conftest.$ac_objext"'
7135 { (eval echo "$as_me:7135: \"$ac_try\"") >&5
7136 (eval $ac_try) 2>&5
7137 ac_status=$?
7138 echo "$as_me:7138: \$? = $ac_status" >&5
7139 (exit "$ac_status"); }; }; then
7140 cf_cv_have_utmp_ut_name=$cf_header
7141 break
7142 else
7143 echo "$as_me: failed program was:" >&5
7144 cat "conftest.$ac_ext" >&5
7145 fi
7146 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
7147 done
7148
7149 fi
7150 echo "$as_me:7150: result: $cf_cv_have_utmp_ut_name" >&5
7151 echo "${ECHO_T}$cf_cv_have_utmp_ut_name" >&6
7152
7153 case "$cf_cv_have_utmp_ut_name" in
7154 (no)
7155 { { echo "$as_me:7155: error: Cannot find declaration for ut.ut_name" >&5
7156 echo "$as_me: error: Cannot find declaration for ut.ut_name" >&2;}
7157 { (exit 1); exit 1; }; }
7158 ;;
7159 (ut_user)
7160
7161 cat >>confdefs.h <<\EOF
7162 #define ut_name ut_user
7163 EOF
7164
7165 ;;
7166 esac
7167 fi
7168
7169 if test "$cf_cv_have_utmp" != no ; then
7170 echo "$as_me:7170: checking for exit-status in $cf_cv_have_utmp" >&5
7171 echo $ECHO_N "checking for exit-status in $cf_cv_have_utmp... $ECHO_C" >&6
7172 if test "${cf_cv_have_utmp_ut_xstatus+set}" = set; then
7173 echo $ECHO_N "(cached) $ECHO_C" >&6
7174 else
7175
7176 for cf_result in \
7177 ut_exit.__e_exit \
7178 ut_exit.e_exit \
7179 ut_exit.ut_e_exit \
7180 ut_exit.ut_exit
7181 do
7182 cat >"conftest.$ac_ext" <<_ACEOF
7183 #line 7183 "configure"
7184 #include "confdefs.h"
7185
7186 #include <sys/types.h>
7187 #include <${cf_cv_have_utmp}.h>
7188 int
7189 main (void)
7190 {
7191 struct $cf_cv_have_utmp x;
7192 long y = x.$cf_result = 0;
7193 (void)x;
7194 (void)y
7195 ;
7196 return 0;
7197 }
7198 _ACEOF
7199 rm -f "conftest.$ac_objext"
7200 if { (eval echo "$as_me:7200: \"$ac_compile\"") >&5
7201 (eval $ac_compile) 2>&5
7202 ac_status=$?
7203 echo "$as_me:7203: \$? = $ac_status" >&5
7204 (exit "$ac_status"); } &&
7205 { ac_try='test -s "conftest.$ac_objext"'
7206 { (eval echo "$as_me:7206: \"$ac_try\"") >&5
7207 (eval $ac_try) 2>&5
7208 ac_status=$?
7209 echo "$as_me:7209: \$? = $ac_status" >&5
7210 (exit "$ac_status"); }; }; then
7211 cf_cv_have_utmp_ut_xstatus=$cf_result
7212 break
7213 else
7214 echo "$as_me: failed program was:" >&5
7215 cat "conftest.$ac_ext" >&5
7216 cf_cv_have_utmp_ut_xstatus=no
7217 fi
7218 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
7219 done
7220
7221 fi
7222 echo "$as_me:7222: result: $cf_cv_have_utmp_ut_xstatus" >&5
7223 echo "${ECHO_T}$cf_cv_have_utmp_ut_xstatus" >&6
7224 if test "$cf_cv_have_utmp_ut_xstatus" != no ; then
7225
7226 cat >>confdefs.h <<\EOF
7227 #define HAVE_UTMP_UT_XSTATUS 1
7228 EOF
7229
7230 cat >>confdefs.h <<EOF
7231 #define ut_xstatus $cf_cv_have_utmp_ut_xstatus
7232 EOF
7233
7234 fi
7235 fi
7236
7237 if test "$cf_cv_have_utmp" != no ; then
7238 echo "$as_me:7238: checking if ${cf_cv_have_utmp}.ut_xtime is declared" >&5
7239 echo $ECHO_N "checking if ${cf_cv_have_utmp}.ut_xtime is declared... $ECHO_C" >&6
7240 if test "${cf_cv_have_utmp_ut_xtime+set}" = set; then
7241 echo $ECHO_N "(cached) $ECHO_C" >&6
7242 else
7243
7244 cat >"conftest.$ac_ext" <<_ACEOF
7245 #line 7245 "configure"
7246 #include "confdefs.h"
7247
7248 #include <sys/types.h>
7249 #include <${cf_cv_have_utmp}.h>
7250 int
7251 main (void)
7252 {
7253 struct $cf_cv_have_utmp x;
7254 long y = x.ut_xtime = 0;
7255 (void)x;
7256 (void)y
7257 ;
7258 return 0;
7259 }
7260 _ACEOF
7261 rm -f "conftest.$ac_objext"
7262 if { (eval echo "$as_me:7262: \"$ac_compile\"") >&5
7263 (eval $ac_compile) 2>&5
7264 ac_status=$?
7265 echo "$as_me:7265: \$? = $ac_status" >&5
7266 (exit "$ac_status"); } &&
7267 { ac_try='test -s "conftest.$ac_objext"'
7268 { (eval echo "$as_me:7268: \"$ac_try\"") >&5
7269 (eval $ac_try) 2>&5
7270 ac_status=$?
7271 echo "$as_me:7271: \$? = $ac_status" >&5
7272 (exit "$ac_status"); }; }; then
7273 cf_cv_have_utmp_ut_xtime=yes
7274 else
7275 echo "$as_me: failed program was:" >&5
7276 cat "conftest.$ac_ext" >&5
7277 cat >"conftest.$ac_ext" <<_ACEOF
7278 #line 7278 "configure"
7279 #include "confdefs.h"
7280
7281 #include <sys/types.h>
7282 #include <${cf_cv_have_utmp}.h>
7283 int
7284 main (void)
7285 {
7286 struct $cf_cv_have_utmp x;
7287 long y = x.ut_tv.tv_sec;
7288 (void)x;
7289 (void)y
7290 ;
7291 return 0;
7292 }
7293 _ACEOF
7294 rm -f "conftest.$ac_objext"
7295 if { (eval echo "$as_me:7295: \"$ac_compile\"") >&5
7296 (eval $ac_compile) 2>&5
7297 ac_status=$?
7298 echo "$as_me:7298: \$? = $ac_status" >&5
7299 (exit "$ac_status"); } &&
7300 { ac_try='test -s "conftest.$ac_objext"'
7301 { (eval echo "$as_me:7301: \"$ac_try\"") >&5
7302 (eval $ac_try) 2>&5
7303 ac_status=$?
7304 echo "$as_me:7304: \$? = $ac_status" >&5
7305 (exit "$ac_status"); }; }; then
7306 cf_cv_have_utmp_ut_xtime=define
7307 else
7308 echo "$as_me: failed program was:" >&5
7309 cat "conftest.$ac_ext" >&5
7310 cf_cv_have_utmp_ut_xtime=no
7311 fi
7312 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
7313
7314 fi
7315 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
7316
7317 fi
7318 echo "$as_me:7318: result: $cf_cv_have_utmp_ut_xtime" >&5
7319 echo "${ECHO_T}$cf_cv_have_utmp_ut_xtime" >&6
7320 if test "$cf_cv_have_utmp_ut_xtime" != no ; then
7321
7322 cat >>confdefs.h <<\EOF
7323 #define HAVE_UTMP_UT_XTIME 1
7324 EOF
7325
7326 if test "$cf_cv_have_utmp_ut_xtime" = define ; then
7327
7328 cat >>confdefs.h <<\EOF
7329 #define ut_xtime ut_tv.tv_sec
7330 EOF
7331
7332 fi
7333 fi
7334 fi
7335
7336 if test "$cf_cv_have_utmp" != no ; then
7337 echo "$as_me:7337: checking if ${cf_cv_have_utmp}.ut_session is declared" >&5
7338 echo $ECHO_N "checking if ${cf_cv_have_utmp}.ut_session is declared... $ECHO_C" >&6
7339 if test "${cf_cv_have_utmp_ut_session+set}" = set; then
7340 echo $ECHO_N "(cached) $ECHO_C" >&6
7341 else
7342
7343 cat >"conftest.$ac_ext" <<_ACEOF
7344 #line 7344 "configure"
7345 #include "confdefs.h"
7346
7347 #include <sys/types.h>
7348 #include <${cf_cv_have_utmp}.h>
7349 int
7350 main (void)
7351 {
7352 static struct $cf_cv_have_utmp x;
7353 long y = x.ut_session;
7354 (void)x;
7355 (void)y
7356 ;
7357 return 0;
7358 }
7359 _ACEOF
7360 rm -f "conftest.$ac_objext"
7361 if { (eval echo "$as_me:7361: \"$ac_compile\"") >&5
7362 (eval $ac_compile) 2>&5
7363 ac_status=$?
7364 echo "$as_me:7364: \$? = $ac_status" >&5
7365 (exit "$ac_status"); } &&
7366 { ac_try='test -s "conftest.$ac_objext"'
7367 { (eval echo "$as_me:7367: \"$ac_try\"") >&5
7368 (eval $ac_try) 2>&5
7369 ac_status=$?
7370 echo "$as_me:7370: \$? = $ac_status" >&5
7371 (exit "$ac_status"); }; }; then
7372 cf_cv_have_utmp_ut_session=yes
7373 else
7374 echo "$as_me: failed program was:" >&5
7375 cat "conftest.$ac_ext" >&5
7376 cf_cv_have_utmp_ut_session=no
7377 fi
7378 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
7379
7380 fi
7381 echo "$as_me:7381: result: $cf_cv_have_utmp_ut_session" >&5
7382 echo "${ECHO_T}$cf_cv_have_utmp_ut_session" >&6
7383 if test "$cf_cv_have_utmp_ut_session" != no ; then
7384
7385 cat >>confdefs.h <<\EOF
7386 #define HAVE_UTMP_UT_SESSION 1
7387 EOF
7388
7389 fi
7390 fi
7391
7392 echo "$as_me:7392: checking if $cf_cv_have_utmp is SYSV flavor" >&5
7393 echo $ECHO_N "checking if $cf_cv_have_utmp is SYSV flavor... $ECHO_C" >&6
7394 if test "${cf_cv_sysv_utmp+set}" = set; then
7395 echo $ECHO_N "(cached) $ECHO_C" >&6
7396 else
7397
7398 test "$cf_cv_have_utmp" = "utmp" && cf_prefix="ut" || cf_prefix="utx"
7399 cat >"conftest.$ac_ext" <<_ACEOF
7400 #line 7400 "configure"
7401 #include "confdefs.h"
7402
7403 #include <sys/types.h>
7404 #include <${cf_cv_have_utmp}.h>
7405 int
7406 main (void)
7407 {
7408
7409 struct $cf_cv_have_utmp x;
7410 set${cf_prefix}ent ();
7411 get${cf_prefix}id(&x);
7412 put${cf_prefix}line(&x);
7413 end${cf_prefix}ent();
7414 ;
7415 return 0;
7416 }
7417 _ACEOF
7418 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7419 if { (eval echo "$as_me:7419: \"$ac_link\"") >&5
7420 (eval $ac_link) 2>&5
7421 ac_status=$?
7422 echo "$as_me:7422: \$? = $ac_status" >&5
7423 (exit "$ac_status"); } &&
7424 { ac_try='test -s "conftest$ac_exeext"'
7425 { (eval echo "$as_me:7425: \"$ac_try\"") >&5
7426 (eval $ac_try) 2>&5
7427 ac_status=$?
7428 echo "$as_me:7428: \$? = $ac_status" >&5
7429 (exit "$ac_status"); }; }; then
7430 cf_cv_sysv_utmp=yes
7431 else
7432 echo "$as_me: failed program was:" >&5
7433 cat "conftest.$ac_ext" >&5
7434 cf_cv_sysv_utmp=no
7435 fi
7436 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7437
7438 fi
7439 echo "$as_me:7439: result: $cf_cv_sysv_utmp" >&5
7440 echo "${ECHO_T}$cf_cv_sysv_utmp" >&6
7441 test "$cf_cv_sysv_utmp" = yes &&
7442 cat >>confdefs.h <<\EOF
7443 #define USE_SYSV_UTMP 1
7444 EOF
7445
7446 fi
7447
7448 for ac_header in lastlog.h
7449 do
7450 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7451 echo "$as_me:7451: checking for $ac_header" >&5
7452 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7453 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7454 echo $ECHO_N "(cached) $ECHO_C" >&6
7455 else
7456 cat >"conftest.$ac_ext" <<_ACEOF
7457 #line 7457 "configure"
7458 #include "confdefs.h"
7459 #include <$ac_header>
7460 _ACEOF
7461 if { (eval echo "$as_me:7461: \"$ac_cpp "conftest.$ac_ext"\"") >&5
7462 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
7463 ac_status=$?
7464 $EGREP -v '^ *\+' conftest.er1 >conftest.err
7465 rm -f conftest.er1
7466 cat conftest.err >&5
7467 echo "$as_me:7467: \$? = $ac_status" >&5
7468 (exit "$ac_status"); } >/dev/null; then
7469 if test -s conftest.err; then
7470 ac_cpp_err=$ac_c_preproc_warn_flag
7471 else
7472 ac_cpp_err=
7473 fi
7474 else
7475 ac_cpp_err=yes
7476 fi
7477 if test -z "$ac_cpp_err"; then
7478 eval "$as_ac_Header=yes"
7479 else
7480 echo "$as_me: failed program was:" >&5
7481 cat "conftest.$ac_ext" >&5
7482 eval "$as_ac_Header=no"
7483 fi
7484 rm -f conftest.err "conftest.$ac_ext"
7485 fi
7486 echo "$as_me:7486: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
7487 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
7488 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
7489 cat >>confdefs.h <<EOF
7490 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7491 EOF
7492
7493 fi
7494 done
7495
7496 echo "$as_me:7496: checking for struct lastlog" >&5
7497 echo $ECHO_N "checking for struct lastlog... $ECHO_C" >&6
7498 if test "${cf_cv_struct_lastlog+set}" = set; then
7499 echo $ECHO_N "(cached) $ECHO_C" >&6
7500 else
7501
7502 if test "$cross_compiling" = yes; then
7503
7504 cf_cv_struct_lastlog=unknown
7505 else
7506 cat >"conftest.$ac_ext" <<_ACEOF
7507 #line 7507 "configure"
7508 #include "confdefs.h"
7509
7510 $ac_includes_default
7511
7512 #include <time.h>
7513 #include <lastlog.h>
7514
7515 int main(void)
7516 {
7517 struct lastlog data;
7518 return (sizeof(data.ll_time) != sizeof(time_t));
7519 }
7520 _ACEOF
7521 rm -f "conftest$ac_exeext"
7522 if { (eval echo "$as_me:7522: \"$ac_link\"") >&5
7523 (eval $ac_link) 2>&5
7524 ac_status=$?
7525 echo "$as_me:7525: \$? = $ac_status" >&5
7526 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
7527 { (eval echo "$as_me:7527: \"$ac_try\"") >&5
7528 (eval $ac_try) 2>&5
7529 ac_status=$?
7530 echo "$as_me:7530: \$? = $ac_status" >&5
7531 (exit "$ac_status"); }; }; then
7532
7533 cf_cv_struct_lastlog=yes
7534 else
7535 echo "$as_me: program exited with status $ac_status" >&5
7536 echo "$as_me: failed program was:" >&5
7537 cat "conftest.$ac_ext" >&5
7538
7539 cf_cv_struct_lastlog=no
7540 fi
7541 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
7542 fi
7543 fi
7544 echo "$as_me:7544: result: $cf_cv_struct_lastlog" >&5
7545 echo "${ECHO_T}$cf_cv_struct_lastlog" >&6
7546
7547 test $cf_cv_struct_lastlog != no &&
7548 cat >>confdefs.h <<\EOF
7549 #define USE_STRUCT_LASTLOG 1
7550 EOF
7551
7552 for ac_header in \
7553 sys/param.h \
7554
7555 do
7556 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7557 echo "$as_me:7557: checking for $ac_header" >&5
7558 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7559 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7560 echo $ECHO_N "(cached) $ECHO_C" >&6
7561 else
7562 cat >"conftest.$ac_ext" <<_ACEOF
7563 #line 7563 "configure"
7564 #include "confdefs.h"
7565 #include <$ac_header>
7566 _ACEOF
7567 if { (eval echo "$as_me:7567: \"$ac_cpp "conftest.$ac_ext"\"") >&5
7568 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
7569 ac_status=$?
7570 $EGREP -v '^ *\+' conftest.er1 >conftest.err
7571 rm -f conftest.er1
7572 cat conftest.err >&5
7573 echo "$as_me:7573: \$? = $ac_status" >&5
7574 (exit "$ac_status"); } >/dev/null; then
7575 if test -s conftest.err; then
7576 ac_cpp_err=$ac_c_preproc_warn_flag
7577 else
7578 ac_cpp_err=
7579 fi
7580 else
7581 ac_cpp_err=yes
7582 fi
7583 if test -z "$ac_cpp_err"; then
7584 eval "$as_ac_Header=yes"
7585 else
7586 echo "$as_me: failed program was:" >&5
7587 cat "conftest.$ac_ext" >&5
7588 eval "$as_ac_Header=no"
7589 fi
7590 rm -f conftest.err "conftest.$ac_ext"
7591 fi
7592 echo "$as_me:7592: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
7593 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
7594 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
7595 cat >>confdefs.h <<EOF
7596 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7597 EOF
7598
7599 fi
7600 done
7601
7602 echo "$as_me:7602: checking if POSIX saved-ids are supported" >&5
7603 echo $ECHO_N "checking if POSIX saved-ids are supported... $ECHO_C" >&6
7604 if test "${cf_cv_posix_saved_ids+set}" = set; then
7605 echo $ECHO_N "(cached) $ECHO_C" >&6
7606 else
7607
7608 cat >"conftest.$ac_ext" <<_ACEOF
7609 #line 7609 "configure"
7610 #include "confdefs.h"
7611
7612 #include <unistd.h>
7613 #ifdef HAVE_SYS_PARAM_H
7614 #include <sys/param.h> /* this may define "BSD" */
7615 #endif
7616
7617 int
7618 main (void)
7619 {
7620
7621 #if defined(_POSIX_SAVED_IDS) && (_POSIX_SAVED_IDS > 0)
7622 int (*my_seteuid)(uid_t) = seteuid;
7623 int x = my_seteuid(geteuid());
7624 (void)x;
7625 #elif defined(BSD) && (BSD >= 199103)
7626 /* The BSD's may implement the runtime check - and it fails.
7627 * However, saved-ids work almost like POSIX (close enough for most uses).
7628 */
7629 #else
7630 #error no saved-ids found
7631 #endif
7632
7633 ;
7634 return 0;
7635 }
7636 _ACEOF
7637 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7638 if { (eval echo "$as_me:7638: \"$ac_link\"") >&5
7639 (eval $ac_link) 2>&5
7640 ac_status=$?
7641 echo "$as_me:7641: \$? = $ac_status" >&5
7642 (exit "$ac_status"); } &&
7643 { ac_try='test -s "conftest$ac_exeext"'
7644 { (eval echo "$as_me:7644: \"$ac_try\"") >&5
7645 (eval $ac_try) 2>&5
7646 ac_status=$?
7647 echo "$as_me:7647: \$? = $ac_status" >&5
7648 (exit "$ac_status"); }; }; then
7649 cf_cv_posix_saved_ids=yes
7650
7651 else
7652 echo "$as_me: failed program was:" >&5
7653 cat "conftest.$ac_ext" >&5
7654
7655 if test "$cross_compiling" = yes; then
7656 cf_cv_posix_saved_ids=unknown
7657 else
7658 cat >"conftest.$ac_ext" <<_ACEOF
7659 #line 7659 "configure"
7660 #include "confdefs.h"
7661
7662 $ac_includes_default
7663
7664 int main(void)
7665 {
7666 void *p = (void *) seteuid;
7667 long code = sysconf(_SC_SAVED_IDS);
7668 (void)p;
7669 ${cf_cv_main_return:-return} ((code > 0) ? 0 : 1);
7670 }
7671 _ACEOF
7672 rm -f "conftest$ac_exeext"
7673 if { (eval echo "$as_me:7673: \"$ac_link\"") >&5
7674 (eval $ac_link) 2>&5
7675 ac_status=$?
7676 echo "$as_me:7676: \$? = $ac_status" >&5
7677 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
7678 { (eval echo "$as_me:7678: \"$ac_try\"") >&5
7679 (eval $ac_try) 2>&5
7680 ac_status=$?
7681 echo "$as_me:7681: \$? = $ac_status" >&5
7682 (exit "$ac_status"); }; }; then
7683 cf_cv_posix_saved_ids=yes
7684 else
7685 echo "$as_me: program exited with status $ac_status" >&5
7686 echo "$as_me: failed program was:" >&5
7687 cat "conftest.$ac_ext" >&5
7688 cf_cv_posix_saved_ids=no
7689 fi
7690 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
7691 fi
7692
7693 fi
7694 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
7695
7696 fi
7697 echo "$as_me:7697: result: $cf_cv_posix_saved_ids" >&5
7698 echo "${ECHO_T}$cf_cv_posix_saved_ids" >&6
7699
7700 test "$cf_cv_posix_saved_ids" = yes &&
7701 cat >>confdefs.h <<\EOF
7702 #define HAVE_POSIX_SAVED_IDS 1
7703 EOF
7704
7705 # compute a reasonable value for $TERM to give tgetent(), since we may be
7706 # running in 'screen', which sets $TERMCAP to a specific entry that is not
7707 # necessarily in /etc/termcap - unsetenv is not portable, so we cannot simply
7708 # discard $TERMCAP.
7709 cf_TERMVAR=vt100
7710 if test -n "$TERMCAP"
7711 then
7712 cf_TERMCAP=`echo "$TERMCAP" | tr '\n' ' ' | sed -e 's/^..|//' -e 's/|.*//'`
7713 case "$cf_TERMCAP" in
7714 (screen*.*)
7715 ;;
7716 (*)
7717 cf_TERMVAR="$cf_TERMCAP"
7718 ;;
7719 esac
7720 fi
7721 test -z "$cf_TERMVAR" && cf_TERMVAR=vt100
7722
7723 # BSD termcap used no header file
7724 # SVr4 provided termcap prototypes as a legacy feature in term.h
7725 # GNU termcap provided termcap prototypes in termcap.h
7726 # ncurses provides termcap prototypes in both term.h and termcap.h
7727 #
7728 # The terminfo-based termcap interfaces do not provide a full tgetent (i.e., do
7729 # not return the text of the termcap entry in the buffer), but as a special
7730 # case, FreeBSD provides ncurses' termcap.h with a modified termcap reader that
7731 # returns the termcap text.
7732
7733 for ac_header in termcap.h
7734 do
7735 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7736 echo "$as_me:7736: checking for $ac_header" >&5
7737 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7738 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7739 echo $ECHO_N "(cached) $ECHO_C" >&6
7740 else
7741 cat >"conftest.$ac_ext" <<_ACEOF
7742 #line 7742 "configure"
7743 #include "confdefs.h"
7744 #include <$ac_header>
7745 _ACEOF
7746 if { (eval echo "$as_me:7746: \"$ac_cpp "conftest.$ac_ext"\"") >&5
7747 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
7748 ac_status=$?
7749 $EGREP -v '^ *\+' conftest.er1 >conftest.err
7750 rm -f conftest.er1
7751 cat conftest.err >&5
7752 echo "$as_me:7752: \$? = $ac_status" >&5
7753 (exit "$ac_status"); } >/dev/null; then
7754 if test -s conftest.err; then
7755 ac_cpp_err=$ac_c_preproc_warn_flag
7756 else
7757 ac_cpp_err=
7758 fi
7759 else
7760 ac_cpp_err=yes
7761 fi
7762 if test -z "$ac_cpp_err"; then
7763 eval "$as_ac_Header=yes"
7764 else
7765 echo "$as_me: failed program was:" >&5
7766 cat "conftest.$ac_ext" >&5
7767 eval "$as_ac_Header=no"
7768 fi
7769 rm -f conftest.err "conftest.$ac_ext"
7770 fi
7771 echo "$as_me:7771: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
7772 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
7773 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
7774 cat >>confdefs.h <<EOF
7775 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7776 EOF
7777
7778 fi
7779 done
7780
7781 cf_termcap_h="\
7782 #ifdef HAVE_TERMCAP_H
7783 #include <termcap.h>
7784 #else
7785 extern int tgetent(char *, const char *);
7786 #endif"
7787
7788 echo "$as_me:7788: checking if we want full tgetent function" >&5
7789 echo $ECHO_N "checking if we want full tgetent function... $ECHO_C" >&6
7790
7791 # Check whether --enable-full-tgetent or --disable-full-tgetent was given.
7792 if test "${enable_full_tgetent+set}" = set; then
7793 enableval="$enable_full_tgetent"
7794 test "$enableval" != no && enableval=yes
7795 if test "$enableval" != "yes" ; then
7796 cf_full_tgetent=no
7797 else
7798 cf_full_tgetent=yes
7799 fi
7800 else
7801 enableval=yes
7802 cf_full_tgetent=yes
7803
7804 fi;
7805 echo "$as_me:7805: result: $cf_full_tgetent" >&5
7806 echo "${ECHO_T}$cf_full_tgetent" >&6
7807
7808 if test "$cf_full_tgetent" = yes ; then
7809 cf_test_message="full tgetent"
7810 else
7811 cf_test_message="tgetent"
7812 fi
7813
7814 echo "$as_me:7814: checking for $cf_test_message function" >&5
7815 echo $ECHO_N "checking for $cf_test_message function... $ECHO_C" >&6
7816 if test "${cf_cv_lib_tgetent+set}" = set; then
7817 echo $ECHO_N "(cached) $ECHO_C" >&6
7818 else
7819
7820 cf_save_LIBS="$LIBS"
7821 cf_cv_lib_tgetent=no
7822 cf_TERMLIB="termlib ncursesw ncurses curses"
7823 if test "$cf_full_tgetent" = yes ; then
7824 cf_TERMLIB="otermcap termcap $cf_TERMLIB"
7825 cf_TERMTST="buffer[0] == 0"
7826 else
7827 cf_TERMLIB="tinfow tinfo $cf_TERMLIB"
7828 cf_TERMTST="0"
7829 fi
7830 for cf_termlib in '' $cf_TERMLIB ; do
7831 LIBS="$cf_save_LIBS"
7832 test -n "$cf_termlib" && {
7833 cf_add_libs="$LIBS"
7834 # reverse order
7835 cf_add_0lib=
7836 for cf_add_1lib in -l$cf_termlib; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7837 # filter duplicates
7838 for cf_add_1lib in $cf_add_0lib; do
7839 for cf_add_2lib in $cf_add_libs; do
7840 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7841 cf_add_1lib=
7842 break
7843 fi
7844 done
7845 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7846 done
7847 LIBS="$cf_add_libs"
7848 }
7849 if test "$cross_compiling" = yes; then
7850 echo "cross-compiling, cannot verify if a termcap/tgetent is present in $cf_termlib" 1>&5
7851 else
7852 cat >"conftest.$ac_ext" <<_ACEOF
7853 #line 7853 "configure"
7854 #include "confdefs.h"
7855
7856 $cf_termcap_h
7857
7858 /* terminfo implementations ignore the buffer argument, making it useless for
7859 * the xterm application, which uses this information to make a new TERMCAP
7860 * environment variable.
7861 */
7862 int main(void)
7863 {
7864 char buffer[1024];
7865 buffer[0] = 0;
7866 tgetent(buffer, "$cf_TERMVAR");
7867 ${cf_cv_main_return:-return} ($cf_TERMTST); }
7868 _ACEOF
7869 rm -f "conftest$ac_exeext"
7870 if { (eval echo "$as_me:7870: \"$ac_link\"") >&5
7871 (eval $ac_link) 2>&5
7872 ac_status=$?
7873 echo "$as_me:7873: \$? = $ac_status" >&5
7874 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
7875 { (eval echo "$as_me:7875: \"$ac_try\"") >&5
7876 (eval $ac_try) 2>&5
7877 ac_status=$?
7878 echo "$as_me:7878: \$? = $ac_status" >&5
7879 (exit "$ac_status"); }; }; then
7880 echo "yes, there is a termcap/tgetent in $cf_termlib" 1>&5
7881 if test -n "$cf_termlib" ; then
7882 cf_cv_lib_tgetent="-l$cf_termlib"
7883 else
7884 cf_cv_lib_tgetent=yes
7885 fi
7886 break
7887 else
7888 echo "$as_me: program exited with status $ac_status" >&5
7889 echo "$as_me: failed program was:" >&5
7890 cat "conftest.$ac_ext" >&5
7891 echo "no, there is no termcap/tgetent in $cf_termlib" 1>&5
7892 fi
7893 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
7894 fi
7895 done
7896 LIBS="$cf_save_LIBS"
7897
7898 fi
7899 echo "$as_me:7899: result: $cf_cv_lib_tgetent" >&5
7900 echo "${ECHO_T}$cf_cv_lib_tgetent" >&6
7901
7902 # If we found a working tgetent(), set LIBS and check for termcap.h.
7903 # (LIBS cannot be set inside AC_CACHE_CHECK; the commands there should
7904 # not have side effects other than setting the cache variable, because
7905 # they are not executed when a cached value exists.)
7906 if test "x$cf_cv_lib_tgetent" != xno ; then
7907 test "x$cf_cv_lib_tgetent" != xyes && {
7908 cf_add_libs="$LIBS"
7909 # reverse order
7910 cf_add_0lib=
7911 for cf_add_1lib in $cf_cv_lib_tgetent; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
7912 # filter duplicates
7913 for cf_add_1lib in $cf_add_0lib; do
7914 for cf_add_2lib in $cf_add_libs; do
7915 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
7916 cf_add_1lib=
7917 break
7918 fi
7919 done
7920 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
7921 done
7922 LIBS="$cf_add_libs"
7923 }
7924
7925 cat >>confdefs.h <<\EOF
7926 #define USE_TERMCAP 1
7927 EOF
7928
7929 if test "$cf_full_tgetent" = no ; then
7930 cat >"conftest.$ac_ext" <<_ACEOF
7931 #line 7931 "configure"
7932 #include "confdefs.h"
7933
7934 #include <termcap.h>
7935 int
7936 main (void)
7937 {
7938
7939 #ifdef NCURSES_VERSION
7940 #error do not use ncurses termcap.h
7941 #endif
7942 ;
7943 return 0;
7944 }
7945 _ACEOF
7946 rm -f "conftest.$ac_objext"
7947 if { (eval echo "$as_me:7947: \"$ac_compile\"") >&5
7948 (eval $ac_compile) 2>&5
7949 ac_status=$?
7950 echo "$as_me:7950: \$? = $ac_status" >&5
7951 (exit "$ac_status"); } &&
7952 { ac_try='test -s "conftest.$ac_objext"'
7953 { (eval echo "$as_me:7953: \"$ac_try\"") >&5
7954 (eval $ac_try) 2>&5
7955 ac_status=$?
7956 echo "$as_me:7956: \$? = $ac_status" >&5
7957 (exit "$ac_status"); }; }; then
7958 cat >>confdefs.h <<\EOF
7959 #define HAVE_TERMCAP_H 1
7960 EOF
7961
7962 else
7963 echo "$as_me: failed program was:" >&5
7964 cat "conftest.$ac_ext" >&5
7965 fi
7966 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
7967 fi
7968 else
7969 # If we didn't find a tgetent() that supports the buffer
7970 # argument, look again to see whether we can find even
7971 # a crippled one. A crippled tgetent() is still useful to
7972 # validate values for the TERM environment variable given to
7973 # child processes.
7974 echo "$as_me:7974: checking for partial tgetent function" >&5
7975 echo $ECHO_N "checking for partial tgetent function... $ECHO_C" >&6
7976 if test "${cf_cv_lib_part_tgetent+set}" = set; then
7977 echo $ECHO_N "(cached) $ECHO_C" >&6
7978 else
7979
7980 cf_cv_lib_part_tgetent=no
7981 for cf_termlib in $cf_TERMLIB ; do
7982 LIBS="$cf_save_LIBS -l$cf_termlib"
7983 cat >"conftest.$ac_ext" <<_ACEOF
7984 #line 7984 "configure"
7985 #include "confdefs.h"
7986 $cf_termcap_h
7987 int
7988 main (void)
7989 {
7990 tgetent((char*)0, "$cf_TERMVAR")
7991 ;
7992 return 0;
7993 }
7994 _ACEOF
7995 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
7996 if { (eval echo "$as_me:7996: \"$ac_link\"") >&5
7997 (eval $ac_link) 2>&5
7998 ac_status=$?
7999 echo "$as_me:7999: \$? = $ac_status" >&5
8000 (exit "$ac_status"); } &&
8001 { ac_try='test -s "conftest$ac_exeext"'
8002 { (eval echo "$as_me:8002: \"$ac_try\"") >&5
8003 (eval $ac_try) 2>&5
8004 ac_status=$?
8005 echo "$as_me:8005: \$? = $ac_status" >&5
8006 (exit "$ac_status"); }; }; then
8007 echo "there is a terminfo/tgetent in $cf_termlib" 1>&5
8008 cf_cv_lib_part_tgetent="-l$cf_termlib"
8009 break
8010 else
8011 echo "$as_me: failed program was:" >&5
8012 cat "conftest.$ac_ext" >&5
8013 fi
8014 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
8015 done
8016 LIBS="$cf_save_LIBS"
8017
8018 fi
8019 echo "$as_me:8019: result: $cf_cv_lib_part_tgetent" >&5
8020 echo "${ECHO_T}$cf_cv_lib_part_tgetent" >&6
8021
8022 if test "$cf_cv_lib_part_tgetent" != no ; then
8023
8024 cf_add_libs="$LIBS"
8025 # reverse order
8026 cf_add_0lib=
8027 for cf_add_1lib in $cf_cv_lib_part_tgetent; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
8028 # filter duplicates
8029 for cf_add_1lib in $cf_add_0lib; do
8030 for cf_add_2lib in $cf_add_libs; do
8031 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
8032 cf_add_1lib=
8033 break
8034 fi
8035 done
8036 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
8037 done
8038 LIBS="$cf_add_libs"
8039
8040 # If this is linking against ncurses, we'll trigger the
8041 # ifdef in resize.c that turns the termcap stuff back off.
8042
8043 cat >>confdefs.h <<\EOF
8044 #define USE_TERMINFO 1
8045 EOF
8046
8047 fi
8048 fi
8049
8050 echo "$as_me:8050: checking for X applications class" >&5
8051 echo $ECHO_N "checking for X applications class... $ECHO_C" >&6
8052
8053 # Check whether --with-app-class or --without-app-class was given.
8054 if test "${with_app_class+set}" = set; then
8055 withval="$with_app_class"
8056 APP_CLASS=$withval
8057 else
8058 APP_CLASS=XTerm
8059 fi;
8060
8061 case x$APP_CLASS in
8062 (*[/@,%]*)
8063 { echo "$as_me:8063: WARNING: X applications class cannot contain punctuation" >&5
8064 echo "$as_me: WARNING: X applications class cannot contain punctuation" >&2;}
8065 APP_CLASS=XTerm
8066 ;;
8067 (x[A-Z]*)
8068 ;;
8069 (*)
8070 { echo "$as_me:8070: WARNING: X applications class must start with capital, ignoring $APP_CLASS" >&5
8071 echo "$as_me: WARNING: X applications class must start with capital, ignoring $APP_CLASS" >&2;}
8072 APP_CLASS=XTerm
8073 ;;
8074 esac
8075
8076 echo "$as_me:8076: result: $APP_CLASS" >&5
8077 echo "${ECHO_T}$APP_CLASS" >&6
8078
8079 echo "$as_me:8079: checking for directory to install resource files" >&5
8080 echo $ECHO_N "checking for directory to install resource files... $ECHO_C" >&6
8081
8082 # Check whether --with-app-defaults or --without-app-defaults was given.
8083 if test "${with_app_defaults+set}" = set; then
8084 withval="$with_app_defaults"
8085 APPSDIR=$withval
8086 else
8087 APPSDIR='${exec_prefix}/lib/X11/app-defaults'
8088 fi;
8089
8090 if test "x$APPSDIR" = xauto
8091 then
8092 APPSDIR='${exec_prefix}/lib/X11/app-defaults'
8093 for cf_path in \
8094 /opt/local/share/X11/app-defaults \
8095 /opt/X11/share/X11/app-defaults \
8096 /usr/share/X11/app-defaults \
8097 /usr/X11/share/X11/app-defaults \
8098 /usr/X11/lib/X11/app-defaults \
8099 /usr/lib/X11/app-defaults \
8100 /etc/X11/app-defaults \
8101 /usr/pkg/lib/X11/app-defaults \
8102 /usr/X11R7/lib/X11/app-defaults \
8103 /usr/X11R6/lib/X11/app-defaults \
8104 /usr/X11R5/lib/X11/app-defaults \
8105 /usr/X11R4/lib/X11/app-defaults \
8106 /usr/local/lib/X11/app-defaults \
8107 /usr/local/share/X11/app-defaults \
8108 /usr/lib64/X11/app-defaults
8109 do
8110 if test -d "$cf_path" ; then
8111 APPSDIR="$cf_path"
8112 break
8113 fi
8114 done
8115 else
8116 cf_path=$APPSDIR
8117
8118 if test "x$prefix" != xNONE; then
8119 cf_path_syntax="$prefix"
8120 else
8121 cf_path_syntax="$ac_default_prefix"
8122 fi
8123
8124 case "x$cf_path" in
8125 (x\$\(*\)*|x\'*\'*)
8126 ;;
8127 (x.|x$GLOB_FULLPATH_POSIX|x$GLOB_FULLPATH_OTHER)
8128 ;;
8129 (x\$\{*prefix\}*|x\$\{*dir\}*)
8130 eval cf_path="$cf_path"
8131 case "x$cf_path" in
8132 (xNONE/*)
8133 cf_path=`echo "$cf_path" | sed -e s%NONE%$cf_path_syntax%`
8134 ;;
8135 esac
8136 ;;
8137 (xno|xNONE/*)
8138 cf_path=`echo "$cf_path" | sed -e s%NONE%$cf_path_syntax%`
8139 ;;
8140 (*)
8141 { { echo "$as_me:8141: error: expected a pathname, not \"$cf_path\"" >&5
8142 echo "$as_me: error: expected a pathname, not \"$cf_path\"" >&2;}
8143 { (exit 1); exit 1; }; }
8144 ;;
8145 esac
8146
8147 fi
8148
8149 echo "$as_me:8149: result: $APPSDIR" >&5
8150 echo "${ECHO_T}$APPSDIR" >&6
8151
8152 no_appsdir=
8153 if test "$APPSDIR" = no
8154 then
8155 no_appsdir="#"
8156 else
8157 EXTRA_INSTALL_DIRS="$EXTRA_INSTALL_DIRS \$(APPSDIR)"
8158 fi
8159
8160 echo "$as_me:8160: checking for the icon name" >&5
8161 echo $ECHO_N "checking for the icon name... $ECHO_C" >&6
8162
8163 # Check whether --with-icon-name or --without-icon-name was given.
8164 if test "${with_icon_name+set}" = set; then
8165 withval="$with_icon_name"
8166 ICON_NAME="$withval"
8167 else
8168 ICON_NAME=mini.xterm
8169 fi;
8170 case "x$ICON_NAME" in
8171 (xyes|xno|x)
8172 ICON_NAME=mini.xterm
8173 ;;
8174 esac
8175
8176 echo "$as_me:8176: result: $ICON_NAME" >&5
8177 echo "${ECHO_T}$ICON_NAME" >&6
8178
8179 echo "$as_me:8179: checking for icon symlink to use" >&5
8180 echo $ECHO_N "checking for icon symlink to use... $ECHO_C" >&6
8181
8182 # Check whether --with-icon-symlink or --without-icon-symlink was given.
8183 if test "${with_icon_symlink+set}" = set; then
8184 withval="$with_icon_symlink"
8185 ICON_SYMLINK="$withval"
8186 else
8187 ICON_SYMLINK=NONE
8188 fi;
8189 case "x$ICON_SYMLINK" in
8190 (xyes)
8191 ICON_SYMLINK=xterm
8192 ;;
8193 (xno|x)
8194 ICON_SYMLINK=NONE
8195 ;;
8196 esac
8197
8198 echo "$as_me:8198: result: $ICON_SYMLINK" >&5
8199 echo "${ECHO_T}$ICON_SYMLINK" >&6
8200
8201 # Install all icons except for the overused "terminal".
8202 cf_cv_icon_list=
8203 for my_item in $srcdir/icons/*.svg
8204 do
8205 test -f "$my_item" || continue
8206 cf_icon_name=`echo "$my_item" |sed -e "s,.svg,," -e "s,^$srcdir/,,"`
8207 case $cf_icon_name in
8208 (*_48x48)
8209 continue
8210 ;;
8211 esac
8212 test -n "$verbose" && echo " adding $cf_icon_name to icon-list" 1>&6
8213
8214 echo "${as_me:-configure}:8214: testing adding $cf_icon_name to icon-list ..." 1>&5
8215
8216 cf_cv_icon_list="$cf_cv_icon_list $cf_icon_name"
8217 if test -f "${cf_icon_name}_48x48.png"
8218 then
8219 test -n "$verbose" && echo " adding ${cf_icon_name}_48x48 to icon-list" 1>&6
8220
8221 echo "${as_me:-configure}:8221: testing adding ${cf_icon_name}_48x48 to icon-list ..." 1>&5
8222
8223 cf_cv_icon_list="$cf_cv_icon_list ${cf_icon_name}_48x48"
8224 fi
8225 done
8226
8227 echo "$as_me:8227: checking for directory to install pixmaps" >&5
8228 echo $ECHO_N "checking for directory to install pixmaps... $ECHO_C" >&6
8229
8230 # Check whether --with-pixmapdir or --without-pixmapdir was given.
8231 if test "${with_pixmapdir+set}" = set; then
8232 withval="$with_pixmapdir"
8233 PIXMAPDIR=$withval
8234 else
8235 test -z "$PIXMAPDIR" && PIXMAPDIR='${datadir}/pixmaps'
8236 fi;
8237
8238 if test "x$PIXMAPDIR" = xauto
8239 then
8240 PIXMAPDIR='${datadir}/pixmaps'
8241 for cf_path in \
8242 /usr/share/pixmaps \
8243 /usr/X11R6/share/pixmaps
8244 do
8245 if test -d "$cf_path" ; then
8246 PIXMAPDIR="$cf_path"
8247 break
8248 fi
8249 done
8250 else
8251 cf_path=$PIXMAPDIR
8252
8253 if test "x$prefix" != xNONE; then
8254 cf_path_syntax="$prefix"
8255 else
8256 cf_path_syntax="$ac_default_prefix"
8257 fi
8258
8259 case "x$cf_path" in
8260 (x\$\(*\)*|x\'*\'*)
8261 ;;
8262 (x.|x$GLOB_FULLPATH_POSIX|x$GLOB_FULLPATH_OTHER)
8263 ;;
8264 (x\$\{*prefix\}*|x\$\{*dir\}*)
8265 eval cf_path="$cf_path"
8266 case "x$cf_path" in
8267 (xNONE/*)
8268 cf_path=`echo "$cf_path" | sed -e s%NONE%$cf_path_syntax%`
8269 ;;
8270 esac
8271 ;;
8272 (xno|xNONE/*)
8273 cf_path=`echo "$cf_path" | sed -e s%NONE%$cf_path_syntax%`
8274 ;;
8275 (*)
8276 { { echo "$as_me:8276: error: expected a pathname, not \"$cf_path\"" >&5
8277 echo "$as_me: error: expected a pathname, not \"$cf_path\"" >&2;}
8278 { (exit 1); exit 1; }; }
8279 ;;
8280 esac
8281
8282 fi
8283 echo "$as_me:8283: result: $PIXMAPDIR" >&5
8284 echo "${ECHO_T}$PIXMAPDIR" >&6
8285
8286 no_pixmapdir=
8287 if test "$PIXMAPDIR" = no
8288 then
8289 no_pixmapdir="#"
8290 else
8291 EXTRA_INSTALL_DIRS="$EXTRA_INSTALL_DIRS \$(PIXMAPDIR)"
8292 fi
8293
8294 echo "$as_me:8294: checking for directory to install icons" >&5
8295 echo $ECHO_N "checking for directory to install icons... $ECHO_C" >&6
8296
8297 # Check whether --with-icondir or --without-icondir was given.
8298 if test "${with_icondir+set}" = set; then
8299 withval="$with_icondir"
8300 ICONDIR=$withval
8301 else
8302 test -z "$ICONDIR" && ICONDIR=no
8303 fi;
8304
8305 if test "x$ICONDIR" = xauto
8306 then
8307 ICONDIR='${datadir}/icons'
8308 for cf_path in \
8309 /usr/share/icons \
8310 /usr/X11R6/share/icons
8311 do
8312 if test -d "$cf_path" ; then
8313 ICONDIR="$cf_path"
8314 break
8315 fi
8316 done
8317 else
8318 cf_path=$ICONDIR
8319
8320 if test "x$prefix" != xNONE; then
8321 cf_path_syntax="$prefix"
8322 else
8323 cf_path_syntax="$ac_default_prefix"
8324 fi
8325
8326 case "x$cf_path" in
8327 (x\$\(*\)*|x\'*\'*)
8328 ;;
8329 (x.|x$GLOB_FULLPATH_POSIX|x$GLOB_FULLPATH_OTHER)
8330 ;;
8331 (x\$\{*prefix\}*|x\$\{*dir\}*)
8332 eval cf_path="$cf_path"
8333 case "x$cf_path" in
8334 (xNONE/*)
8335 cf_path=`echo "$cf_path" | sed -e s%NONE%$cf_path_syntax%`
8336 ;;
8337 esac
8338 ;;
8339 (xno|xNONE/*)
8340 cf_path=`echo "$cf_path" | sed -e s%NONE%$cf_path_syntax%`
8341 ;;
8342 (*)
8343 { { echo "$as_me:8343: error: expected a pathname, not \"$cf_path\"" >&5
8344 echo "$as_me: error: expected a pathname, not \"$cf_path\"" >&2;}
8345 { (exit 1); exit 1; }; }
8346 ;;
8347 esac
8348
8349 fi
8350 echo "$as_me:8350: result: $ICONDIR" >&5
8351 echo "${ECHO_T}$ICONDIR" >&6
8352
8353 no_icondir=
8354 if test "$ICONDIR" = no
8355 then
8356 no_icondir="#"
8357 else
8358 EXTRA_INSTALL_DIRS="$EXTRA_INSTALL_DIRS \$(ICONDIR)"
8359 fi
8360
8361 echo "$as_me:8361: checking if icon theme should be used" >&5
8362 echo $ECHO_N "checking if icon theme should be used... $ECHO_C" >&6
8363
8364 # Check whether --with-icon-theme or --without-icon-theme was given.
8365 if test "${with_icon_theme+set}" = set; then
8366 withval="$with_icon_theme"
8367 ICON_THEME=$withval
8368 else
8369 ICON_THEME=no
8370 fi;
8371
8372 case "x$ICON_THEME" in
8373 (xno)
8374 ;;
8375 (x|xyes)
8376 ICON_THEME=hicolor
8377 ;;
8378 esac
8379 echo "$as_me:8379: result: $ICON_THEME" >&5
8380 echo "${ECHO_T}$ICON_THEME" >&6
8381
8382 if test "x$ICON_THEME" = xno
8383 then
8384 if test "x$ICONDIR" != xno
8385 then
8386 test -n "$verbose" && echo " ignoring icondir without theme" 1>&6
8387
8388 echo "${as_me:-configure}:8388: testing ignoring icondir without theme ..." 1>&5
8389
8390 no_icondir="#"
8391 fi
8392 else
8393 if test "x$ICONDIR" = xno
8394 then
8395 { { echo "$as_me:8395: error: icondir must be set for icon theme" >&5
8396 echo "$as_me: error: icondir must be set for icon theme" >&2;}
8397 { (exit 1); exit 1; }; }
8398 fi
8399 fi
8400
8401 : ${ICON_FORMAT:=".svg .png .xpm"}
8402
8403 ICON_LIST=
8404
8405 if test "x$ICON_THEME" != xno
8406 then
8407 cf_icon_list="$cf_cv_icon_list"
8408 else
8409 cf_icon_list="icons/${ICON_NAME}_48x48"
8410 fi
8411
8412 echo "$as_me:8412: checking for icon(s) to install" >&5
8413 echo $ECHO_N "checking for icon(s) to install... $ECHO_C" >&6
8414 for cf_name in $cf_icon_list
8415 do
8416 test -n "$verbose" && echo " using $ICON_FORMAT" 1>&6
8417
8418 echo "${as_me:-configure}:8418: testing using $ICON_FORMAT ..." 1>&5
8419
8420 for cf_suffix in $ICON_FORMAT
8421 do
8422 cf_icon="${cf_name}${cf_suffix}"
8423 cf_left=`echo "$cf_icon" | sed -e 's/:.*//'`
8424 if test ! -f "${cf_left}"
8425 then
8426 if test "x$srcdir" != "x."
8427 then
8428 cf_icon="${srcdir}/${cf_left}"
8429 cf_left=`echo "$cf_icon" | sed -e 's/:.*//'`
8430 if test ! -f "${cf_left}"
8431 then
8432 continue
8433 fi
8434 else
8435 continue
8436 fi
8437 fi
8438 if test "x$ICON_THEME" != xno
8439 then
8440 cf_base=`basename "$cf_left"`
8441 cf_trim=`echo "$cf_base" | sed -e 's/_[0-9][0-9]x[0-9][0-9]\././'`
8442 case "x${cf_base}" in
8443 (*:*)
8444 cf_next=$cf_base
8445 # user-defined mapping
8446 ;;
8447 (*.png)
8448 cf_size=`file "$cf_left"|sed -e 's/^[^:]*://' -e 's/^.*[^0-9]\([0-9][0-9]* x [0-9][0-9]*\)[^0-9].*$/\1/' -e 's/ //g'`
8449 if test -z "$cf_size"
8450 then
8451 { echo "$as_me:8451: WARNING: cannot determine size of $cf_left" >&5
8452 echo "$as_me: WARNING: cannot determine size of $cf_left" >&2;}
8453 continue
8454 fi
8455 cf_next="$cf_size/apps/$cf_trim"
8456 ;;
8457 (*.svg)
8458 cf_next="scalable/apps/$cf_trim"
8459 ;;
8460 (*.xpm)
8461 test -n "$verbose" && echo " ignored XPM file in icon theme" 1>&6
8462
8463 echo "${as_me:-configure}:8463: testing ignored XPM file in icon theme ..." 1>&5
8464
8465 continue
8466 ;;
8467 (*_[0-9][0-9]*x[0-9][0-9]*.*)
8468 cf_size=`echo "$cf_left"|sed -e 's/^.*_\([0-9][0-9]*x[0-9][0-9]*\)\..*$/\1/'`
8469 cf_left=`echo "$cf_left"|sed -e 's/^\(.*\)_\([0-9][0-9]*x[0-9][0-9]*\)\(\..*\)$/\1\3/'`
8470 cf_next="$cf_size/apps/$cf_base"
8471 ;;
8472 esac
8473 test -n "$verbose" && echo " adding $cf_next" 1>&6
8474
8475 echo "${as_me:-configure}:8475: testing adding $cf_next ..." 1>&5
8476
8477 cf_icon="${cf_icon}:${cf_next}"
8478 fi
8479 test -n "$ICON_LIST" && ICON_LIST="$ICON_LIST "
8480 ICON_LIST="$ICON_LIST${cf_icon}"
8481 if test -z "$ICON_NAME"
8482 then
8483 ICON_NAME=`basename "$cf_icon" | sed -e 's/[.:].*//'`
8484 fi
8485 done
8486 done
8487
8488 if test -n "$verbose"
8489 then
8490 echo "$as_me:8490: checking result" >&5
8491 echo $ECHO_N "checking result... $ECHO_C" >&6
8492 fi
8493 echo "$as_me:8493: result: $ICON_LIST" >&5
8494 echo "${ECHO_T}$ICON_LIST" >&6
8495
8496 if test -z "$ICON_LIST"
8497 then
8498 { { echo "$as_me:8498: error: no icons found" >&5
8499 echo "$as_me: error: no icons found" >&2;}
8500 { (exit 1); exit 1; }; }
8501 fi
8502
8503 echo "$as_me:8503: checking for icon name" >&5
8504 echo $ECHO_N "checking for icon name... $ECHO_C" >&6
8505 echo "$as_me:8505: result: $ICON_NAME" >&5
8506 echo "${ECHO_T}$ICON_NAME" >&6
8507
8508 # Comment-out the install-desktop rule if the desktop-utils are not found.
8509 echo "$as_me:8509: checking if you want to install desktop files" >&5
8510 echo $ECHO_N "checking if you want to install desktop files... $ECHO_C" >&6
8511
8512 # Check whether --enable-desktop or --disable-desktop was given.
8513 if test "${enable_desktop+set}" = set; then
8514 enableval="$enable_desktop"
8515 test "$enableval" != no && enableval=yes
8516 if test "$enableval" != "yes" ; then
8517 enable_desktop=$enableval
8518 else
8519 enable_desktop=$enableval
8520 fi
8521 else
8522 enableval=yes
8523 enable_desktop=$enableval
8524
8525 fi;
8526 echo "$as_me:8526: result: $enable_desktop" >&5
8527 echo "${ECHO_T}$enable_desktop" >&6
8528
8529 desktop_utils=
8530 if test "$enable_desktop" = yes ; then
8531 # Extract the first word of "desktop-file-install", so it can be a program name with args.
8532 set dummy desktop-file-install; ac_word=$2
8533 echo "$as_me:8533: checking for $ac_word" >&5
8534 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8535 if test "${ac_cv_prog_desktop_utils+set}" = set; then
8536 echo $ECHO_N "(cached) $ECHO_C" >&6
8537 else
8538 if test -n "$desktop_utils"; then
8539 ac_cv_prog_desktop_utils="$desktop_utils" # Let the user override the test.
8540 else
8541 ac_save_IFS=$IFS; IFS=$ac_path_separator
8542 ac_dummy="$PATH"
8543 for ac_dir in $ac_dummy; do
8544 IFS=$ac_save_IFS
8545 test -z "$ac_dir" && ac_dir=.
8546 $as_executable_p "$ac_dir/$ac_word" || continue
8547 ac_cv_prog_desktop_utils="yes"
8548 echo "$as_me:8548: found $ac_dir/$ac_word" >&5
8549 break
8550 done
8551
8552 test -z "$ac_cv_prog_desktop_utils" && ac_cv_prog_desktop_utils="no"
8553 fi
8554 fi
8555 desktop_utils=$ac_cv_prog_desktop_utils
8556 if test -n "$desktop_utils"; then
8557 echo "$as_me:8557: result: $desktop_utils" >&5
8558 echo "${ECHO_T}$desktop_utils" >&6
8559 else
8560 echo "$as_me:8560: result: no" >&5
8561 echo "${ECHO_T}no" >&6
8562 fi
8563
8564 fi
8565
8566 test "$desktop_utils" = yes && desktop_utils= || desktop_utils="#"
8567
8568 if test -z "$desktop_utils"
8569 then
8570 echo "$as_me:8570: checking for requested desktop-category" >&5
8571 echo $ECHO_N "checking for requested desktop-category... $ECHO_C" >&6
8572
8573 # Check whether --with-desktop-category or --without-desktop-category was given.
8574 if test "${with_desktop_category+set}" = set; then
8575 withval="$with_desktop_category"
8576 cf_desktop_want=$withval
8577 else
8578 cf_desktop_want=auto
8579 fi;
8580 echo "$as_me:8580: result: $cf_desktop_want" >&5
8581 echo "${ECHO_T}$cf_desktop_want" >&6
8582
8583 if test "$cf_desktop_want" = auto
8584 then
8585 rm -rf conftest*
8586 cf_desktop_also=
8587 for cf_desktop_dir in \
8588 /usr/share/app-install \
8589 /usr/share/applications
8590 do
8591 if test -d $cf_desktop_dir
8592 then
8593 find $cf_desktop_dir -name '*.desktop' | \
8594 while true
8595 do
8596 read cf_desktop_path
8597 test -z "$cf_desktop_path" && break
8598 cf_desktop_name=`basename "$cf_desktop_path" .desktop`
8599 case $cf_desktop_name in
8600 (xterm|*-xterm|*rxvt*|*konsole|*[Tt]erminal)
8601 test -n "$verbose" && echo " inspect $cf_desktop_path" 1>&6
8602
8603 echo "${as_me:-configure}:8603: testing inspect $cf_desktop_path ..." 1>&5
8604
8605 ${EGREP-egrep} '^Categories=' "$cf_desktop_path" | \
8606 tr ';' '\n' | \
8607 sed -e 's%^.*=%%' -e '/^$/d' >>conftest.1
8608 ;;
8609 esac
8610 done
8611 fi
8612 done
8613 if test -s conftest.1
8614 then
8615 cf_desktop_last=
8616 sort conftest.1 | \
8617 while true
8618 do
8619 read cf_desktop_this
8620 test -z "$cf_desktop_this" && break
8621 if test -s conftest.2
8622 then
8623 grep -w "$cf_desktop_this" conftest.2 >/dev/null && continue
8624 elif test -s conftest.3
8625 then
8626 grep -w "$cf_desktop_this" conftest.3 >/dev/null && continue
8627 fi
8628 case "$cf_desktop_this" in
8629 (-*)
8630 ;;
8631 (Qt*|*Xfce*|*[ABCDEFGHIJKLMNOPQRSTUVWXYZ][ABCDEFGHIJKLMNOPQRSTUVWXYZ]*)
8632 test -n "$verbose" && echo " ignored $cf_desktop_this" 1>&6
8633
8634 echo "${as_me:-configure}:8634: testing ignored $cf_desktop_this ..." 1>&5
8635
8636 echo "$cf_desktop_this" >> conftest.3
8637 ;;
8638 (System|TerminalEmulator|*)
8639 test -n "$verbose" && echo " applied $cf_desktop_this" 1>&6
8640
8641 echo "${as_me:-configure}:8641: testing applied $cf_desktop_this ..." 1>&5
8642
8643 test "x$cf_desktop_last" != "x$cf_desktop_this" && echo "$cf_desktop_this" >>conftest.2
8644 ;;
8645 esac
8646 cf_desktop_last=$cf_desktop_this
8647 done
8648 cf_desktop_want="`tr '\n' ';' < conftest.2`"
8649 fi
8650 if test -n "$cf_desktop_want"
8651 then
8652 if test "$cf_desktop_want" = auto
8653 then
8654 cf_desktop_want=
8655 else
8656 # do a sanity check on the semicolon-separated list, ignore on failure
8657 cf_desktop_test=`echo "$cf_desktop_want" | sed -e 's/[^;]//g'`
8658 test -z "$cf_desktop_test" && cf_desktop_want=
8659 cf_desktop_test=`echo "$cf_desktop_want" | sed -e 's/^.*;$/./g'`
8660 test -z "$cf_desktop_test" && cf_desktop_want=
8661 fi
8662 fi
8663 if test -z "$cf_desktop_want"
8664 then
8665 cf_desktop_want="`echo "System|TerminalEmulator|*" | sed -e 's/\*//g' -e 's/|/;/g' -e 's/;*$/;/g'`"
8666 test -n "$verbose" && echo " no usable value found for desktop category" 1>&6
8667
8668 echo "${as_me:-configure}:8668: testing no usable value found for desktop category ..." 1>&5
8669
8670 fi
8671 fi
8672 DESKTOP_CATEGORY=`echo "$cf_desktop_want" | sed -e 's/[ ,]/;/g'`
8673 test -n "$verbose" && echo " will use Categories=$DESKTOP_CATEGORY" 1>&6
8674
8675 echo "${as_me:-configure}:8675: testing will use Categories=$DESKTOP_CATEGORY ..." 1>&5
8676
8677 fi
8678
8679 echo "$as_me:8679: checking for install-permissions reference" >&5
8680 echo $ECHO_N "checking for install-permissions reference... $ECHO_C" >&6
8681
8682 # Check whether --with-reference or --without-reference was given.
8683 if test "${with_reference+set}" = set; then
8684 withval="$with_reference"
8685 with_reference=$withval
8686 else
8687 with_reference=xterm
8688 fi;
8689 echo "$as_me:8689: result: $with_reference" >&5
8690 echo "${ECHO_T}$with_reference" >&6
8691
8692 with_full_paths=yes
8693
8694 echo "$as_me:8694: checking for PATH separator" >&5
8695 echo $ECHO_N "checking for PATH separator... $ECHO_C" >&6
8696 case "$cf_cv_system_name" in
8697 (os2*) PATH_SEPARATOR=';' ;;
8698 (*) ${PATH_SEPARATOR:=':'} ;;
8699 esac
8700
8701 echo "$as_me:8701: result: $PATH_SEPARATOR" >&5
8702 echo "${ECHO_T}$PATH_SEPARATOR" >&6
8703
8704 test -z "$XTERM_PATH" && XTERM_PATH="$with_reference"
8705 for ac_prog in $XTERM_PATH $with_reference
8706 do
8707 # Extract the first word of "$ac_prog", so it can be a program name with args.
8708 set dummy $ac_prog; ac_word=$2
8709 echo "$as_me:8709: checking for $ac_word" >&5
8710 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
8711 if test "${ac_cv_path_XTERM_PATH+set}" = set; then
8712 echo $ECHO_N "(cached) $ECHO_C" >&6
8713 else
8714 case $XTERM_PATH in
8715 [\\/]* | ?:[\\/]*)
8716 ac_cv_path_XTERM_PATH="$XTERM_PATH" # Let the user override the test with a path.
8717 ;;
8718 *)
8719 ac_save_IFS=$IFS; IFS=$ac_path_separator
8720 ac_dummy="$PATH"
8721 for ac_dir in $ac_dummy; do
8722 IFS=$ac_save_IFS
8723 test -z "$ac_dir" && ac_dir=.
8724 if $as_executable_p "$ac_dir/$ac_word"; then
8725 ac_cv_path_XTERM_PATH="$ac_dir/$ac_word"
8726 echo "$as_me:8726: found $ac_dir/$ac_word" >&5
8727 break
8728 fi
8729 done
8730
8731 ;;
8732 esac
8733 fi
8734 XTERM_PATH=$ac_cv_path_XTERM_PATH
8735
8736 if test -n "$XTERM_PATH"; then
8737 echo "$as_me:8737: result: $XTERM_PATH" >&5
8738 echo "${ECHO_T}$XTERM_PATH" >&6
8739 else
8740 echo "$as_me:8740: result: no" >&5
8741 echo "${ECHO_T}no" >&6
8742 fi
8743
8744 test -n "$XTERM_PATH" && break
8745 done
8746 test -n "$XTERM_PATH" || XTERM_PATH="$XTERM_PATH"
8747
8748 cf_path_prog=""
8749 cf_path_args=""
8750 IFS="${IFS:- }"; cf_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR"
8751 for cf_temp in $ac_cv_path_XTERM_PATH
8752 do
8753 if test -z "$cf_path_prog" ; then
8754 if test "$with_full_paths" = yes ; then
8755
8756 if test "x$prefix" != xNONE; then
8757 cf_path_syntax="$prefix"
8758 else
8759 cf_path_syntax="$ac_default_prefix"
8760 fi
8761
8762 case "x$cf_temp" in
8763 (x\$\(*\)*|x\'*\'*)
8764 ;;
8765 (x.|x$GLOB_FULLPATH_POSIX|x$GLOB_FULLPATH_OTHER)
8766 ;;
8767 (x\$\{*prefix\}*|x\$\{*dir\}*)
8768 eval cf_temp="$cf_temp"
8769 case "x$cf_temp" in
8770 (xNONE/*)
8771 cf_temp=`echo "$cf_temp" | sed -e s%NONE%$cf_path_syntax%`
8772 ;;
8773 esac
8774 ;;
8775 (xno|xNONE/*)
8776 cf_temp=`echo "$cf_temp" | sed -e s%NONE%$cf_path_syntax%`
8777 ;;
8778 (*)
8779 break
8780 ;;
8781 esac
8782
8783 cf_path_prog="$cf_temp"
8784 else
8785 cf_path_prog="`basename "$cf_temp"`"
8786 fi
8787 elif test -z "$cf_path_args" ; then
8788 cf_path_args="$cf_temp"
8789 else
8790 cf_path_args="$cf_path_args $cf_temp"
8791 fi
8792 done
8793 IFS="$cf_save_ifs"
8794
8795 if test -n "$cf_path_prog" ; then
8796
8797 echo "${as_me:-configure}:8797: testing defining path for ${cf_path_prog} ..." 1>&5
8798
8799 cat >>confdefs.h <<EOF
8800 #define XTERM_PATH_PATH "$cf_path_prog"
8801 EOF
8802
8803 test -n "$cf_path_args" &&
8804 cat >>confdefs.h <<EOF
8805 #define XTERM_PATH_ARGS "$cf_path_args"
8806 EOF
8807
8808 fi
8809
8810 # If any of --program-prefix, --program-suffix or --program-transform-name is
8811 # given, accept an option tell the makefile to create a symbolic link, e.g.,
8812 # to "xterm" on install.
8813 XTERM_SYMLINK=NONE
8814
8815 if test "$program_transform_name" != "'s,,,'" ; then
8816 cf_name=`echo "$program_transform_name" | sed -e 's,\\$\\$,$,g'`
8817 cf_name=`echo xterm |sed -e "$cf_name"`
8818 echo "$as_me:8818: checking for symbolic link to create to $cf_name" >&5
8819 echo $ECHO_N "checking for symbolic link to create to $cf_name... $ECHO_C" >&6
8820
8821 # Check whether --with-xterm-symlink or --without-xterm-symlink was given.
8822 if test "${with_xterm_symlink+set}" = set; then
8823 withval="$with_xterm_symlink"
8824 with_symlink=$withval
8825 else
8826 with_symlink=xterm
8827 fi;
8828 echo "$as_me:8828: result: $with_symlink" >&5
8829 echo "${ECHO_T}$with_symlink" >&6
8830 test "$with_symlink" = yes && with_symlink=xterm
8831 test -n "$with_symlink" && \
8832 test "$with_symlink" != no && \
8833 test "$with_symlink" != "$cf_name" && \
8834 XTERM_SYMLINK="$with_symlink"
8835 fi
8836
8837 echo "$as_me:8837: checking if you want to disable openpty" >&5
8838 echo $ECHO_N "checking if you want to disable openpty... $ECHO_C" >&6
8839
8840 # Check whether --enable-openpty or --disable-openpty was given.
8841 if test "${enable_openpty+set}" = set; then
8842 enableval="$enable_openpty"
8843 test "$enableval" != no && enableval=yes
8844 if test "$enableval" != "yes" ; then
8845 disable_openpty=yes
8846 else
8847 disable_openpty=no
8848 fi
8849 else
8850 enableval=yes
8851 disable_openpty=no
8852
8853 fi;
8854 echo "$as_me:8854: result: $disable_openpty" >&5
8855 echo "${ECHO_T}$disable_openpty" >&6
8856
8857 echo "$as_me:8857: checking if you want to disable setuid" >&5
8858 echo $ECHO_N "checking if you want to disable setuid... $ECHO_C" >&6
8859
8860 # Check whether --enable-setuid or --disable-setuid was given.
8861 if test "${enable_setuid+set}" = set; then
8862 enableval="$enable_setuid"
8863 test "$enableval" != no && enableval=yes
8864 if test "$enableval" != "yes" ; then
8865 disable_setuid=yes
8866 else
8867 disable_setuid=no
8868 fi
8869 else
8870 enableval=yes
8871 disable_setuid=no
8872
8873 fi;
8874 echo "$as_me:8874: result: $disable_setuid" >&5
8875 echo "${ECHO_T}$disable_setuid" >&6
8876
8877 echo "$as_me:8877: checking if you want to disable setgid" >&5
8878 echo $ECHO_N "checking if you want to disable setgid... $ECHO_C" >&6
8879
8880 # Check whether --enable-setgid or --disable-setgid was given.
8881 if test "${enable_setgid+set}" = set; then
8882 enableval="$enable_setgid"
8883 test "$enableval" != no && enableval=yes
8884 if test "$enableval" != "yes" ; then
8885 disable_setgid=yes
8886 else
8887 disable_setgid=no
8888 fi
8889 else
8890 enableval=yes
8891 disable_setgid=no
8892
8893 fi;
8894 echo "$as_me:8894: result: $disable_setgid" >&5
8895 echo "${ECHO_T}$disable_setgid" >&6
8896
8897 echo "$as_me:8897: checking if you want to run xterm setuid to a given user" >&5
8898 echo $ECHO_N "checking if you want to run xterm setuid to a given user... $ECHO_C" >&6
8899
8900 # Check whether --with-setuid or --without-setuid was given.
8901 if test "${with_setuid+set}" = set; then
8902 withval="$with_setuid"
8903 use_given_setuid=$withval
8904 else
8905 use_given_setuid=no
8906 fi;
8907 echo "$as_me:8907: result: $use_given_setuid" >&5
8908 echo "${ECHO_T}$use_given_setuid" >&6
8909
8910 if test "$use_given_setuid" != no ; then
8911 if test "$use_given_setuid" = yes ; then
8912 cf_cv_given_setuid=root
8913 else
8914 cf_cv_given_setuid=$use_given_setuid
8915 fi
8916 # inherit SINSTALL_OPTS from environment to allow packager to customize it.
8917 SINSTALL_OPTS="$SINSTALL_OPTS u+s -u $cf_cv_given_setuid"
8918 fi
8919
8920 echo "$as_me:8920: checking if you want to run xterm setgid to match utmp/utmpx file" >&5
8921 echo $ECHO_N "checking if you want to run xterm setgid to match utmp/utmpx file... $ECHO_C" >&6
8922
8923 # Check whether --with-utmp-setgid or --without-utmp-setgid was given.
8924 if test "${with_utmp_setgid+set}" = set; then
8925 withval="$with_utmp_setgid"
8926 use_utmp_setgid=$withval
8927 else
8928 use_utmp_setgid=no
8929 fi;
8930 echo "$as_me:8930: result: $use_utmp_setgid" >&5
8931 echo "${ECHO_T}$use_utmp_setgid" >&6
8932
8933 if test "$use_utmp_setgid" != no ; then
8934 if test "$use_utmp_setgid" = yes ; then
8935
8936 if test $cf_cv_have_utmp != no ; then
8937 echo "$as_me:8937: checking for utmp/utmpx group" >&5
8938 echo $ECHO_N "checking for utmp/utmpx group... $ECHO_C" >&6
8939 if test "${cf_cv_utmp_group+set}" = set; then
8940 echo $ECHO_N "(cached) $ECHO_C" >&6
8941 else
8942
8943 for cf_utmp_path in /var/adm /var/run
8944 do
8945 for cf_utmp_file in utmpx utmp
8946 do
8947 if test -f $cf_utmp_path/$cf_utmp_file
8948 then
8949 cf_cv_utmp_group=root
8950
8951 cf_option="-lL"
8952
8953 # Expect listing to have fields like this:
8954 #-r--r--r-- 1 user group 34293 Jul 18 16:29 pathname
8955 ls "$cf_option" "$cf_utmp_path/$cf_utmp_file" >conftest
8956 read cf_mode cf_links cf_usr cf_grp cf_size cf_date1 cf_date2 cf_date3 cf_rest <conftest
8957 if test -z "$cf_rest" ; then
8958 cf_option="${cf_option}g"
8959 ls "$cf_option" "$cf_utmp_path/$cf_utmp_file" >conftest
8960 read cf_mode cf_links cf_usr cf_grp cf_size cf_date1 cf_date2 cf_date3 cf_rest <conftest
8961 fi
8962 rm -f conftest
8963
8964 # If we have a pathname, and the date fields look right, assume we've
8965 # captured the group as well.
8966 if test -n "$cf_rest" ; then
8967 cf_test=`echo "${cf_date2}${cf_date3}" | sed -e 's/[0-9:]//g'`
8968 if test -z "$cf_test" ; then
8969 cf_cv_utmp_group=$cf_grp;
8970 fi
8971 fi
8972 break
8973 fi
8974 done
8975 test -n "$cf_cv_utmp_group" && break
8976 done
8977
8978 fi
8979 echo "$as_me:8979: result: $cf_cv_utmp_group" >&5
8980 echo "${ECHO_T}$cf_cv_utmp_group" >&6
8981 else
8982 { { echo "$as_me:8982: error: cannot find utmp group" >&5
8983 echo "$as_me: error: cannot find utmp group" >&2;}
8984 { (exit 1); exit 1; }; }
8985 fi
8986
8987 else
8988 cf_cv_utmp_group=$use_utmp_setgid
8989 fi
8990 if test "$cf_cv_posix_saved_ids" != yes ; then
8991 { { echo "$as_me:8991: error: Your system does not support POSIX saved-ids" >&5
8992 echo "$as_me: error: Your system does not support POSIX saved-ids" >&2;}
8993 { (exit 1); exit 1; }; }
8994 fi
8995
8996 cat >>confdefs.h <<\EOF
8997 #define USE_UTMP_SETGID 1
8998 EOF
8999
9000 SINSTALL_OPTS="$SINSTALL_OPTS g+s -g $cf_cv_utmp_group"
9001 fi
9002
9003 echo "$as_me:9003: checking if you want to link with utempter" >&5
9004 echo $ECHO_N "checking if you want to link with utempter... $ECHO_C" >&6
9005
9006 # Check whether --with-utempter or --without-utempter was given.
9007 if test "${with_utempter+set}" = set; then
9008 withval="$with_utempter"
9009 use_utempter=$withval
9010 else
9011 use_utempter=no
9012 fi;
9013 echo "$as_me:9013: result: $use_utempter" >&5
9014 echo "${ECHO_T}$use_utempter" >&6
9015
9016 if test "$use_utempter" = yes ; then
9017
9018 echo "$as_me:9018: checking if we can link with utempter library" >&5
9019 echo $ECHO_N "checking if we can link with utempter library... $ECHO_C" >&6
9020 if test "${cf_cv_have_utempter+set}" = set; then
9021 echo $ECHO_N "(cached) $ECHO_C" >&6
9022 else
9023
9024 cf_save_LIBS="$LIBS"
9025
9026 cf_add_libs="$LIBS"
9027 # reverse order
9028 cf_add_0lib=
9029 for cf_add_1lib in -lutempter; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
9030 # filter duplicates
9031 for cf_add_1lib in $cf_add_0lib; do
9032 for cf_add_2lib in $cf_add_libs; do
9033 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
9034 cf_add_1lib=
9035 break
9036 fi
9037 done
9038 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
9039 done
9040 LIBS="$cf_add_libs"
9041
9042 cat >"conftest.$ac_ext" <<_ACEOF
9043 #line 9043 "configure"
9044 #include "confdefs.h"
9045
9046 #include <utempter.h>
9047
9048 int
9049 main (void)
9050 {
9051
9052 utempter_add_record(0, (void*)0);
9053 utempter_remove_added_record();
9054
9055 ;
9056 return 0;
9057 }
9058 _ACEOF
9059 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
9060 if { (eval echo "$as_me:9060: \"$ac_link\"") >&5
9061 (eval $ac_link) 2>&5
9062 ac_status=$?
9063 echo "$as_me:9063: \$? = $ac_status" >&5
9064 (exit "$ac_status"); } &&
9065 { ac_try='test -s "conftest$ac_exeext"'
9066 { (eval echo "$as_me:9066: \"$ac_try\"") >&5
9067 (eval $ac_try) 2>&5
9068 ac_status=$?
9069 echo "$as_me:9069: \$? = $ac_status" >&5
9070 (exit "$ac_status"); }; }; then
9071
9072 cf_cv_have_utempter=yes
9073 else
9074 echo "$as_me: failed program was:" >&5
9075 cat "conftest.$ac_ext" >&5
9076
9077 cf_cv_have_utempter=no
9078 fi
9079 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
9080 LIBS="$cf_save_LIBS"
9081
9082 fi
9083 echo "$as_me:9083: result: $cf_cv_have_utempter" >&5
9084 echo "${ECHO_T}$cf_cv_have_utempter" >&6
9085 if test "$cf_cv_have_utempter" = yes ; then
9086
9087 cat >>confdefs.h <<\EOF
9088 #define USE_UTEMPTER 1
9089 EOF
9090
9091 cf_add_libs="$LIBS"
9092 # reverse order
9093 cf_add_0lib=
9094 for cf_add_1lib in -lutempter; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
9095 # filter duplicates
9096 for cf_add_1lib in $cf_add_0lib; do
9097 for cf_add_2lib in $cf_add_libs; do
9098 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
9099 cf_add_1lib=
9100 break
9101 fi
9102 done
9103 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
9104 done
9105 LIBS="$cf_add_libs"
9106
9107 fi
9108
9109 test "$cf_cv_have_utempter" != yes && use_utempter=no
9110 else
9111 use_utempter=no
9112 fi
9113
9114 # Some configurations permit (or require) either setuid or setgid mode.
9115 # Let the user decide.
9116 if test "$use_utempter" = yes ; then
9117 if test "${enable_setuid+set}" != set ; then
9118 disable_setuid=yes
9119 test -n "$verbose" && echo " No --disable-setuid option given, force to yes" 1>&6
9120
9121 echo "${as_me:-configure}:9121: testing No --disable-setuid option given, force to yes ..." 1>&5
9122
9123 fi
9124 fi
9125
9126 # We use these for the manpage:
9127
9128 # Check whether --with-utmp-path or --without-utmp-path was given.
9129 if test "${with_utmp_path+set}" = set; then
9130 withval="$with_utmp_path"
9131 cf_utmp_path=$withval
9132 else
9133 cf_utmp_path=auto
9134 fi;
9135 if test "$cf_utmp_path" = auto ; then
9136 for cf_utmp_path in /etc/utmp /var/adm/utmp /var/log/utmp /var/run/utmp
9137 do
9138 if test -f ${cf_utmp_path}x ; then
9139 cf_utmp_path=${cf_utmp_path}x
9140 break
9141 elif test -f $cf_utmp_path ; then
9142 break
9143 fi
9144 done
9145 else
9146
9147 if test "x$prefix" != xNONE; then
9148 cf_path_syntax="$prefix"
9149 else
9150 cf_path_syntax="$ac_default_prefix"
9151 fi
9152
9153 case "x$cf_utmp_path" in
9154 (x\$\(*\)*|x\'*\'*)
9155 ;;
9156 (x.|x$GLOB_FULLPATH_POSIX|x$GLOB_FULLPATH_OTHER)
9157 ;;
9158 (x\$\{*prefix\}*|x\$\{*dir\}*)
9159 eval cf_utmp_path="$cf_utmp_path"
9160 case "x$cf_utmp_path" in
9161 (xNONE/*)
9162 cf_utmp_path=`echo "$cf_utmp_path" | sed -e s%NONE%$cf_path_syntax%`
9163 ;;
9164 esac
9165 ;;
9166 (xno|xNONE/*)
9167 cf_utmp_path=`echo "$cf_utmp_path" | sed -e s%NONE%$cf_path_syntax%`
9168 ;;
9169 (*)
9170 { { echo "$as_me:9170: error: expected a pathname, not \"$cf_utmp_path\"" >&5
9171 echo "$as_me: error: expected a pathname, not \"$cf_utmp_path\"" >&2;}
9172 { (exit 1); exit 1; }; }
9173 ;;
9174 esac
9175
9176 fi
9177 UTMP_PATH=$cf_utmp_path
9178 UTMP_NAME=`echo "$cf_utmp_path" | sed -e 's,^.*/,,'`
9179
9180 # Check whether --with-wtmp-path or --without-wtmp-path was given.
9181 if test "${with_wtmp_path+set}" = set; then
9182 withval="$with_wtmp_path"
9183 cf_wtmp_path=$withval
9184 else
9185 cf_wtmp_path=auto
9186 fi;
9187 if test "$cf_wtmp_path" = auto ; then
9188 for cf_wtmp_path in /etc/wtmp /var/adm/wtmp /var/run/wtmp /var/log/wtmp
9189 do
9190 if test -f ${cf_wtmp_path}x ; then
9191 cf_wtmp_path=${cf_wtmp_path}x
9192 break
9193 elif test -f $cf_wtmp_path/wtmp ; then
9194 break
9195 fi
9196 done
9197 else
9198
9199 if test "x$prefix" != xNONE; then
9200 cf_path_syntax="$prefix"
9201 else
9202 cf_path_syntax="$ac_default_prefix"
9203 fi
9204
9205 case "x$cf_wtmp_path" in
9206 (x\$\(*\)*|x\'*\'*)
9207 ;;
9208 (x.|x$GLOB_FULLPATH_POSIX|x$GLOB_FULLPATH_OTHER)
9209 ;;
9210 (x\$\{*prefix\}*|x\$\{*dir\}*)
9211 eval cf_wtmp_path="$cf_wtmp_path"
9212 case "x$cf_wtmp_path" in
9213 (xNONE/*)
9214 cf_wtmp_path=`echo "$cf_wtmp_path" | sed -e s%NONE%$cf_path_syntax%`
9215 ;;
9216 esac
9217 ;;
9218 (xno|xNONE/*)
9219 cf_wtmp_path=`echo "$cf_wtmp_path" | sed -e s%NONE%$cf_path_syntax%`
9220 ;;
9221 (*)
9222 { { echo "$as_me:9222: error: expected a pathname, not \"$cf_wtmp_path\"" >&5
9223 echo "$as_me: error: expected a pathname, not \"$cf_wtmp_path\"" >&2;}
9224 { (exit 1); exit 1; }; }
9225 ;;
9226 esac
9227
9228 fi
9229 WTMP_PATH=$cf_wtmp_path
9230 WTMP_NAME=`echo "$cf_wtmp_path" | sed -e 's,^.*/,,'`
9231
9232 ### checks for external data
9233
9234 echo "$as_me:9234: checking if external errno is declared" >&5
9235 echo $ECHO_N "checking if external errno is declared... $ECHO_C" >&6
9236 if test "${cf_cv_dcl_errno+set}" = set; then
9237 echo $ECHO_N "(cached) $ECHO_C" >&6
9238 else
9239
9240 cat >"conftest.$ac_ext" <<_ACEOF
9241 #line 9241 "configure"
9242 #include "confdefs.h"
9243
9244 $ac_includes_default
9245 #include <errno.h>
9246 int
9247 main (void)
9248 {
9249 int x = (int) errno; (void)x
9250 ;
9251 return 0;
9252 }
9253 _ACEOF
9254 rm -f "conftest.$ac_objext"
9255 if { (eval echo "$as_me:9255: \"$ac_compile\"") >&5
9256 (eval $ac_compile) 2>&5
9257 ac_status=$?
9258 echo "$as_me:9258: \$? = $ac_status" >&5
9259 (exit "$ac_status"); } &&
9260 { ac_try='test -s "conftest.$ac_objext"'
9261 { (eval echo "$as_me:9261: \"$ac_try\"") >&5
9262 (eval $ac_try) 2>&5
9263 ac_status=$?
9264 echo "$as_me:9264: \$? = $ac_status" >&5
9265 (exit "$ac_status"); }; }; then
9266 cf_cv_dcl_errno=yes
9267 else
9268 echo "$as_me: failed program was:" >&5
9269 cat "conftest.$ac_ext" >&5
9270 cf_cv_dcl_errno=no
9271 fi
9272 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
9273
9274 fi
9275 echo "$as_me:9275: result: $cf_cv_dcl_errno" >&5
9276 echo "${ECHO_T}$cf_cv_dcl_errno" >&6
9277
9278 if test "$cf_cv_dcl_errno" = no ; then
9279
9280 cf_result=`echo "decl_errno" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9281
9282 cat >>confdefs.h <<EOF
9283 #define $cf_result 1
9284 EOF
9285
9286 fi
9287
9288 # It's possible (for near-UNIX clones) that the data doesn't exist
9289
9290 echo "$as_me:9290: checking if external errno exists" >&5
9291 echo $ECHO_N "checking if external errno exists... $ECHO_C" >&6
9292 if test "${cf_cv_have_errno+set}" = set; then
9293 echo $ECHO_N "(cached) $ECHO_C" >&6
9294 else
9295
9296 cat >"conftest.$ac_ext" <<_ACEOF
9297 #line 9297 "configure"
9298 #include "confdefs.h"
9299
9300 #undef errno
9301 extern int errno;
9302
9303 int
9304 main (void)
9305 {
9306 errno = 2
9307 ;
9308 return 0;
9309 }
9310 _ACEOF
9311 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
9312 if { (eval echo "$as_me:9312: \"$ac_link\"") >&5
9313 (eval $ac_link) 2>&5
9314 ac_status=$?
9315 echo "$as_me:9315: \$? = $ac_status" >&5
9316 (exit "$ac_status"); } &&
9317 { ac_try='test -s "conftest$ac_exeext"'
9318 { (eval echo "$as_me:9318: \"$ac_try\"") >&5
9319 (eval $ac_try) 2>&5
9320 ac_status=$?
9321 echo "$as_me:9321: \$? = $ac_status" >&5
9322 (exit "$ac_status"); }; }; then
9323 cf_cv_have_errno=yes
9324 else
9325 echo "$as_me: failed program was:" >&5
9326 cat "conftest.$ac_ext" >&5
9327 cf_cv_have_errno=no
9328 fi
9329 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
9330
9331 fi
9332 echo "$as_me:9332: result: $cf_cv_have_errno" >&5
9333 echo "${ECHO_T}$cf_cv_have_errno" >&6
9334
9335 if test "$cf_cv_have_errno" = yes ; then
9336
9337 cf_result=`echo "have_errno" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
9338
9339 cat >>confdefs.h <<EOF
9340 #define $cf_result 1
9341 EOF
9342
9343 fi
9344
9345 echo "$as_me:9345: checking for explicit tty group name" >&5
9346 echo $ECHO_N "checking for explicit tty group name... $ECHO_C" >&6
9347
9348 # Check whether --with-tty-group or --without-tty-group was given.
9349 if test "${with_tty_group+set}" = set; then
9350 withval="$with_tty_group"
9351 cf_tty_group=$withval
9352 else
9353 cf_tty_group=auto...
9354 fi;
9355 test -z "$cf_tty_group" && cf_tty_group=auto...
9356 test "$cf_tty_group" = yes && cf_tty_group=auto...
9357 echo "$as_me:9357: result: $cf_tty_group" >&5
9358 echo "${ECHO_T}$cf_tty_group" >&6
9359
9360 if test "$cf_tty_group" = "auto..." ; then
9361 echo "$as_me:9361: checking for tty group name" >&5
9362 echo $ECHO_N "checking for tty group name... $ECHO_C" >&6
9363 if test "${cf_cv_tty_group_name+set}" = set; then
9364 echo $ECHO_N "(cached) $ECHO_C" >&6
9365 else
9366
9367 # If we are configuring as root, it is hard to get a clue about the tty group.
9368 # But we'll guess based on how our connection is set up - assuming it is done
9369 # properly.
9370
9371 cf_uid="`id | sed -e 's/^^=*=//' -e 's/(.*$//'`"
9372 # )vi
9373 if test "$cf_uid" != 0 ; then
9374 cf_cv_tty_group_name=
9375 cf_tty_name="`tty`"
9376 test "$cf_tty_name" = "not a tty" && cf_tty_name=/dev/tty
9377 test -z "$cf_tty_name" && cf_tty_name=/dev/tty
9378 if test -c "$cf_tty_name"
9379 then
9380 cf_option="-lL"
9381
9382 # Expect listing to have fields like this:
9383 #-rwxrwxrwx 1 user group 34293 Jul 18 16:29 pathname
9384 ls $cf_option "$cf_tty_name" >conftest.out
9385 read cf_mode cf_links cf_usr cf_grp cf_size cf_date1 cf_date2 cf_date3 cf_rest <conftest.out
9386 if test -z "$cf_rest" ; then
9387 cf_option="${cf_option}g"
9388 ls "$cf_option" "$cf_tty_name" >conftest.out
9389 read cf_mode cf_links cf_usr cf_grp cf_size cf_date1 cf_date2 cf_date3 cf_rest <conftest.out
9390 fi
9391 rm -f conftest.out
9392 cf_cv_tty_group_name=$cf_grp
9393 fi
9394 fi
9395
9396 # If we cannot deduce the tty group, fall back on hardcoded cases
9397
9398 if test -z "$cf_cv_tty_group_name"
9399 then
9400 case $host_os in
9401 (osf*)
9402 cf_cv_tty_group_name="terminal"
9403 ;;
9404 (*)
9405 cf_cv_tty_group_name="unknown"
9406 if ( ${EGREP-egrep} '^tty:' /etc/group 2>/dev/null 1>/dev/null ) then
9407 cf_cv_tty_group_name="tty"
9408 fi
9409 ;;
9410 esac
9411 fi
9412
9413 fi
9414 echo "$as_me:9414: result: $cf_cv_tty_group_name" >&5
9415 echo "${ECHO_T}$cf_cv_tty_group_name" >&6
9416 cf_tty_group="$cf_cv_tty_group_name"
9417 else
9418 # if configure option, always do this
9419
9420 cat >>confdefs.h <<\EOF
9421 #define USE_TTY_GROUP 1
9422 EOF
9423
9424 fi
9425
9426 cat >>confdefs.h <<EOF
9427 #define TTY_GROUP_NAME "$cf_tty_group"
9428 EOF
9429
9430 # This is only a double-check that the group-name we obtained above really
9431 # does apply to the device. We cannot perform this test if we are in batch
9432 # mode, or if we are cross-compiling.
9433
9434 echo "$as_me:9434: checking if we may use the $cf_tty_group group" >&5
9435 echo $ECHO_N "checking if we may use the $cf_tty_group group... $ECHO_C" >&6
9436 if test "${cf_cv_tty_group+set}" = set; then
9437 echo $ECHO_N "(cached) $ECHO_C" >&6
9438 else
9439
9440 cf_tty_name="`tty`"
9441 if test "$cf_tty_name" != "not a tty"
9442 then
9443 if test "$cross_compiling" = yes; then
9444 cf_cv_tty_group=unknown
9445 else
9446 cat >"conftest.$ac_ext" <<_ACEOF
9447 #line 9447 "configure"
9448 #include "confdefs.h"
9449
9450 $ac_includes_default
9451
9452 #include <grp.h>
9453
9454 int main(void)
9455 {
9456 static char default_tty[] = "/dev/tty";
9457 struct stat sb;
9458 struct group *ttygrp;
9459 int fd;
9460 char *name;
9461
9462 for (fd = 0; fd < 3; ++fd) {
9463 if ((name = ttyname(fd)) != NULL)
9464 break;
9465 }
9466 if (name == NULL)
9467 name = default_tty;
9468
9469 ttygrp = getgrnam(TTY_GROUP_NAME);
9470 endgrent();
9471
9472 if (ttygrp != NULL
9473 && name != NULL
9474 && stat(name, &sb) == 0
9475 && sb.st_gid != getgid()
9476 && sb.st_gid == ttygrp->gr_gid) {
9477 ${cf_cv_main_return:-return} (0);
9478 }
9479 ${cf_cv_main_return:-return} (1);
9480 }
9481
9482 _ACEOF
9483 rm -f "conftest$ac_exeext"
9484 if { (eval echo "$as_me:9484: \"$ac_link\"") >&5
9485 (eval $ac_link) 2>&5
9486 ac_status=$?
9487 echo "$as_me:9487: \$? = $ac_status" >&5
9488 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
9489 { (eval echo "$as_me:9489: \"$ac_try\"") >&5
9490 (eval $ac_try) 2>&5
9491 ac_status=$?
9492 echo "$as_me:9492: \$? = $ac_status" >&5
9493 (exit "$ac_status"); }; }; then
9494 cf_cv_tty_group=yes
9495 else
9496 echo "$as_me: program exited with status $ac_status" >&5
9497 echo "$as_me: failed program was:" >&5
9498 cat "conftest.$ac_ext" >&5
9499 cf_cv_tty_group=no
9500 fi
9501 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
9502 fi
9503 elif test "$cross_compiling" = yes; then
9504 cf_cv_tty_group=unknown
9505 else
9506 cf_cv_tty_group=yes
9507 fi
9508
9509 fi
9510 echo "$as_me:9510: result: $cf_cv_tty_group" >&5
9511 echo "${ECHO_T}$cf_cv_tty_group" >&6
9512
9513 if test $cf_cv_tty_group = no ; then
9514 { echo "$as_me:9514: WARNING: Cannot use $cf_tty_group group" >&5
9515 echo "$as_me: WARNING: Cannot use $cf_tty_group group" >&2;}
9516 else
9517 cat >>confdefs.h <<\EOF
9518 #define USE_TTY_GROUP 1
9519 EOF
9520
9521 fi
9522
9523 ### checks for system services and user specified options
9524
9525 echo "$as_me:9525: checking for X" >&5
9526 echo $ECHO_N "checking for X... $ECHO_C" >&6
9527
9528 # Check whether --with-x or --without-x was given.
9529 if test "${with_x+set}" = set; then
9530 withval="$with_x"
9531
9532 fi;
9533 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9534 if test "x$with_x" = xno; then
9535 # The user explicitly disabled X.
9536 have_x=disabled
9537 else
9538 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
9539 # Both variables are already set.
9540 have_x=yes
9541 else
9542 if test "${ac_cv_have_x+set}" = set; then
9543 echo $ECHO_N "(cached) $ECHO_C" >&6
9544 else
9545 # One or both of the vars are not set, and there is no cached value.
9546 ac_x_includes=no ac_x_libraries=no
9547 rm -fr conftest.dir
9548 if mkdir conftest.dir; then
9549 cd conftest.dir
9550 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
9551 cat >Imakefile <<'EOF'
9552 acfindx:
9553 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
9554 EOF
9555 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
9556 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9557 eval "`${MAKE-make} acfindx 2>/dev/null | grep -v make`"
9558 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9559 for ac_extension in a so sl dylib dll; do
9560 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9561 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9562 ac_im_usrlibdir=$ac_im_libdir; break
9563 fi
9564 done
9565 # Screen out bogus values from the imake configuration. They are
9566 # bogus both because they are the default anyway, and because
9567 # using them would break gcc on systems where it needs fixed includes.
9568 case $ac_im_incroot in
9569 /usr/include) ;;
9570 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9571 esac
9572 case $ac_im_usrlibdir in
9573 /usr/lib | /lib) ;;
9574 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9575 esac
9576 fi
9577 cd ..
9578 rm -fr conftest.dir
9579 fi
9580
9581 # Standard set of common directories for X headers.
9582 # Check X11 before X11Rn because it is often a symlink to the current release.
9583 ac_x_header_dirs='
9584 /usr/X11/include
9585 /usr/X11R7/include
9586 /usr/X11R6/include
9587 /usr/X11R5/include
9588 /usr/X11R4/include
9589
9590 /opt/local/include
9591 /opt/X11/include
9592
9593 /usr/include/X11
9594 /usr/include/X11R7
9595 /usr/include/X11R6
9596 /usr/include/X11R5
9597 /usr/include/X11R4
9598
9599 /usr/local/X11/include
9600 /usr/local/X11R7/include
9601 /usr/local/X11R6/include
9602 /usr/local/X11R5/include
9603 /usr/local/X11R4/include
9604
9605 /usr/local/include/X11
9606 /usr/local/include/X11R7
9607 /usr/local/include/X11R6
9608 /usr/local/include/X11R5
9609 /usr/local/include/X11R4
9610
9611 /usr/X386/include
9612 /usr/x386/include
9613 /usr/XFree86/include/X11
9614
9615 /usr/include
9616 /usr/local/include
9617 /usr/unsupported/include
9618 /usr/athena/include
9619 /usr/local/x11r5/include
9620 /usr/lpp/Xamples/include
9621
9622 /usr/openwin/include
9623 /usr/openwin/share/include'
9624
9625 if test "$ac_x_includes" = no; then
9626 # Guess where to find include files, by looking for Intrinsic.h.
9627 # First, try using that file with no special directory specified.
9628 cat >"conftest.$ac_ext" <<_ACEOF
9629 #line 9629 "configure"
9630 #include "confdefs.h"
9631 #include <X11/Intrinsic.h>
9632 _ACEOF
9633 if { (eval echo "$as_me:9633: \"$ac_cpp "conftest.$ac_ext"\"") >&5
9634 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
9635 ac_status=$?
9636 $EGREP -v '^ *\+' conftest.er1 >conftest.err
9637 rm -f conftest.er1
9638 cat conftest.err >&5
9639 echo "$as_me:9639: \$? = $ac_status" >&5
9640 (exit "$ac_status"); } >/dev/null; then
9641 if test -s conftest.err; then
9642 ac_cpp_err=$ac_c_preproc_warn_flag
9643 else
9644 ac_cpp_err=
9645 fi
9646 else
9647 ac_cpp_err=yes
9648 fi
9649 if test -z "$ac_cpp_err"; then
9650 # We can compile using X headers with no special include directory.
9651 ac_x_includes=
9652 else
9653 echo "$as_me: failed program was:" >&5
9654 cat "conftest.$ac_ext" >&5
9655 for ac_dir in $ac_x_header_dirs; do
9656 if test -r "$ac_dir/X11/Intrinsic.h"; then
9657 ac_x_includes=$ac_dir
9658 break
9659 fi
9660 done
9661 fi
9662 rm -f conftest.err "conftest.$ac_ext"
9663 fi # $ac_x_includes = no
9664
9665 if test "$ac_x_libraries" = no; then
9666 # Check for the libraries.
9667 # See if we find them without any special options.
9668 # Don't add to $LIBS permanently.
9669 ac_save_LIBS=$LIBS
9670 LIBS="-lXt $LIBS"
9671 cat >"conftest.$ac_ext" <<_ACEOF
9672 #line 9672 "configure"
9673 #include "confdefs.h"
9674 #include <X11/Intrinsic.h>
9675 int
9676 main (void)
9677 {
9678 XtMalloc (0)
9679 ;
9680 return 0;
9681 }
9682 _ACEOF
9683 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
9684 if { (eval echo "$as_me:9684: \"$ac_link\"") >&5
9685 (eval $ac_link) 2>&5
9686 ac_status=$?
9687 echo "$as_me:9687: \$? = $ac_status" >&5
9688 (exit "$ac_status"); } &&
9689 { ac_try='test -s "conftest$ac_exeext"'
9690 { (eval echo "$as_me:9690: \"$ac_try\"") >&5
9691 (eval $ac_try) 2>&5
9692 ac_status=$?
9693 echo "$as_me:9693: \$? = $ac_status" >&5
9694 (exit "$ac_status"); }; }; then
9695 LIBS=$ac_save_LIBS
9696 # We can link X programs with no special library path.
9697 ac_x_libraries=
9698 else
9699 echo "$as_me: failed program was:" >&5
9700 cat "conftest.$ac_ext" >&5
9701 LIBS=$ac_save_LIBS
9702 for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9703 do
9704 # Don't even attempt the hair of trying to link an X program!
9705 for ac_extension in a so sl dylib dll; do
9706 if test -r "$ac_dir/libXt.$ac_extension"; then
9707 ac_x_libraries=$ac_dir
9708 break 2
9709 fi
9710 done
9711 done
9712 fi
9713 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
9714 fi # $ac_x_libraries = no
9715
9716 if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
9717 # Didn't find X anywhere. Cache the known absence of X.
9718 ac_cv_have_x="have_x=no"
9719 else
9720 # Record where we found X for the cache.
9721 ac_cv_have_x="have_x=yes \
9722 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
9723 fi
9724 fi
9725
9726 fi
9727 eval "$ac_cv_have_x"
9728 fi # $with_x != no
9729
9730 if test "$have_x" != yes; then
9731 echo "$as_me:9731: result: $have_x" >&5
9732 echo "${ECHO_T}$have_x" >&6
9733 no_x=yes
9734 else
9735 # If each of the values was on the command line, it overrides each guess.
9736 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9737 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9738 # Update the cache value to reflect the command line values.
9739 ac_cv_have_x="have_x=yes \
9740 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
9741 echo "$as_me:9741: result: libraries $x_libraries, headers $x_includes" >&5
9742 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
9743 fi
9744
9745 if test "$no_x" = yes; then
9746 # Not all programs may use this symbol, but it does not hurt to define it.
9747
9748 cat >>confdefs.h <<\EOF
9749 #define X_DISPLAY_MISSING 1
9750 EOF
9751
9752 X_CFLAGS=
9753 X_PRE_LIBS=
9754 X_LIBS=
9755 X_EXTRA_LIBS=
9756 else
9757 if test -n "$x_includes"; then
9758 X_CFLAGS="$X_CFLAGS -I$x_includes"
9759 fi
9760
9761 # It would also be nice to do this for all -L options, not just this one.
9762 if test -n "$x_libraries"; then
9763 X_LIBS="$X_LIBS -L$x_libraries"
9764 # For Solaris; some versions of Sun CC require a space after -R and
9765 # others require no space. Words are not sufficient . . . .
9766 case `(uname -sr) 2>/dev/null` in
9767 "SunOS 5"*)
9768 echo "$as_me:9768: checking whether -R must be followed by a space" >&5
9769 echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
9770 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
9771 cat >"conftest.$ac_ext" <<_ACEOF
9772 #line 9772 "configure"
9773 #include "confdefs.h"
9774
9775 int
9776 main (void)
9777 {
9778
9779 ;
9780 return 0;
9781 }
9782 _ACEOF
9783 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
9784 if { (eval echo "$as_me:9784: \"$ac_link\"") >&5
9785 (eval $ac_link) 2>&5
9786 ac_status=$?
9787 echo "$as_me:9787: \$? = $ac_status" >&5
9788 (exit "$ac_status"); } &&
9789 { ac_try='test -s "conftest$ac_exeext"'
9790 { (eval echo "$as_me:9790: \"$ac_try\"") >&5
9791 (eval $ac_try) 2>&5
9792 ac_status=$?
9793 echo "$as_me:9793: \$? = $ac_status" >&5
9794 (exit "$ac_status"); }; }; then
9795 ac_R_nospace=yes
9796 else
9797 echo "$as_me: failed program was:" >&5
9798 cat "conftest.$ac_ext" >&5
9799 ac_R_nospace=no
9800 fi
9801 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
9802 if test $ac_R_nospace = yes; then
9803 echo "$as_me:9803: result: no" >&5
9804 echo "${ECHO_T}no" >&6
9805 X_LIBS="$X_LIBS -R$x_libraries"
9806 else
9807 LIBS="$ac_xsave_LIBS -R $x_libraries"
9808 cat >"conftest.$ac_ext" <<_ACEOF
9809 #line 9809 "configure"
9810 #include "confdefs.h"
9811
9812 int
9813 main (void)
9814 {
9815
9816 ;
9817 return 0;
9818 }
9819 _ACEOF
9820 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
9821 if { (eval echo "$as_me:9821: \"$ac_link\"") >&5
9822 (eval $ac_link) 2>&5
9823 ac_status=$?
9824 echo "$as_me:9824: \$? = $ac_status" >&5
9825 (exit "$ac_status"); } &&
9826 { ac_try='test -s "conftest$ac_exeext"'
9827 { (eval echo "$as_me:9827: \"$ac_try\"") >&5
9828 (eval $ac_try) 2>&5
9829 ac_status=$?
9830 echo "$as_me:9830: \$? = $ac_status" >&5
9831 (exit "$ac_status"); }; }; then
9832 ac_R_space=yes
9833 else
9834 echo "$as_me: failed program was:" >&5
9835 cat "conftest.$ac_ext" >&5
9836 ac_R_space=no
9837 fi
9838 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
9839 if test $ac_R_space = yes; then
9840 echo "$as_me:9840: result: yes" >&5
9841 echo "${ECHO_T}yes" >&6
9842 X_LIBS="$X_LIBS -R $x_libraries"
9843 else
9844 echo "$as_me:9844: result: neither works" >&5
9845 echo "${ECHO_T}neither works" >&6
9846 fi
9847 fi
9848 LIBS=$ac_xsave_LIBS
9849 esac
9850 fi
9851
9852 # Check for system-dependent libraries X programs must link with.
9853 # Do this before checking for the system-independent R6 libraries
9854 # (-lICE), since we may need -lsocket or whatever for X linking.
9855
9856 if test "$ISC" = yes; then
9857 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
9858 else
9859 # Martyn Johnson says this is needed for Ultrix, if the X
9860 # libraries were built with DECnet support. And Karl Berry says
9861 # the Alpha needs dnet_stub (dnet does not exist).
9862 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
9863 cat >"conftest.$ac_ext" <<_ACEOF
9864 #line 9864 "configure"
9865 #include "confdefs.h"
9866
9867 /* Override any gcc2 internal prototype to avoid an error. */
9868 #ifdef __cplusplus
9869 extern "C"
9870 #endif
9871 /* We use char because int might match the return type of a gcc2
9872 builtin and then its argument prototype would still apply. */
9873 char XOpenDisplay (void);
9874 int
9875 main (void)
9876 {
9877 XOpenDisplay ();
9878 ;
9879 return 0;
9880 }
9881 _ACEOF
9882 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
9883 if { (eval echo "$as_me:9883: \"$ac_link\"") >&5
9884 (eval $ac_link) 2>&5
9885 ac_status=$?
9886 echo "$as_me:9886: \$? = $ac_status" >&5
9887 (exit "$ac_status"); } &&
9888 { ac_try='test -s "conftest$ac_exeext"'
9889 { (eval echo "$as_me:9889: \"$ac_try\"") >&5
9890 (eval $ac_try) 2>&5
9891 ac_status=$?
9892 echo "$as_me:9892: \$? = $ac_status" >&5
9893 (exit "$ac_status"); }; }; then
9894 :
9895 else
9896 echo "$as_me: failed program was:" >&5
9897 cat "conftest.$ac_ext" >&5
9898 echo "$as_me:9898: checking for dnet_ntoa in -ldnet" >&5
9899 echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
9900 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
9901 echo $ECHO_N "(cached) $ECHO_C" >&6
9902 else
9903 ac_check_lib_save_LIBS=$LIBS
9904 LIBS="-ldnet $LIBS"
9905 cat >"conftest.$ac_ext" <<_ACEOF
9906 #line 9906 "configure"
9907 #include "confdefs.h"
9908
9909 /* Override any gcc2 internal prototype to avoid an error. */
9910 #ifdef __cplusplus
9911 extern "C"
9912 #endif
9913 /* We use char because int might match the return type of a gcc2
9914 builtin and then its argument prototype would still apply. */
9915 char dnet_ntoa (void);
9916 int
9917 main (void)
9918 {
9919 dnet_ntoa ();
9920 ;
9921 return 0;
9922 }
9923 _ACEOF
9924 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
9925 if { (eval echo "$as_me:9925: \"$ac_link\"") >&5
9926 (eval $ac_link) 2>&5
9927 ac_status=$?
9928 echo "$as_me:9928: \$? = $ac_status" >&5
9929 (exit "$ac_status"); } &&
9930 { ac_try='test -s "conftest$ac_exeext"'
9931 { (eval echo "$as_me:9931: \"$ac_try\"") >&5
9932 (eval $ac_try) 2>&5
9933 ac_status=$?
9934 echo "$as_me:9934: \$? = $ac_status" >&5
9935 (exit "$ac_status"); }; }; then
9936 ac_cv_lib_dnet_dnet_ntoa=yes
9937 else
9938 echo "$as_me: failed program was:" >&5
9939 cat "conftest.$ac_ext" >&5
9940 ac_cv_lib_dnet_dnet_ntoa=no
9941 fi
9942 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
9943 LIBS=$ac_check_lib_save_LIBS
9944 fi
9945 echo "$as_me:9945: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
9946 echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
9947 if test "$ac_cv_lib_dnet_dnet_ntoa" = yes; then
9948 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
9949 fi
9950
9951 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
9952 echo "$as_me:9952: checking for dnet_ntoa in -ldnet_stub" >&5
9953 echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
9954 if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
9955 echo $ECHO_N "(cached) $ECHO_C" >&6
9956 else
9957 ac_check_lib_save_LIBS=$LIBS
9958 LIBS="-ldnet_stub $LIBS"
9959 cat >"conftest.$ac_ext" <<_ACEOF
9960 #line 9960 "configure"
9961 #include "confdefs.h"
9962
9963 /* Override any gcc2 internal prototype to avoid an error. */
9964 #ifdef __cplusplus
9965 extern "C"
9966 #endif
9967 /* We use char because int might match the return type of a gcc2
9968 builtin and then its argument prototype would still apply. */
9969 char dnet_ntoa (void);
9970 int
9971 main (void)
9972 {
9973 dnet_ntoa ();
9974 ;
9975 return 0;
9976 }
9977 _ACEOF
9978 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
9979 if { (eval echo "$as_me:9979: \"$ac_link\"") >&5
9980 (eval $ac_link) 2>&5
9981 ac_status=$?
9982 echo "$as_me:9982: \$? = $ac_status" >&5
9983 (exit "$ac_status"); } &&
9984 { ac_try='test -s "conftest$ac_exeext"'
9985 { (eval echo "$as_me:9985: \"$ac_try\"") >&5
9986 (eval $ac_try) 2>&5
9987 ac_status=$?
9988 echo "$as_me:9988: \$? = $ac_status" >&5
9989 (exit "$ac_status"); }; }; then
9990 ac_cv_lib_dnet_stub_dnet_ntoa=yes
9991 else
9992 echo "$as_me: failed program was:" >&5
9993 cat "conftest.$ac_ext" >&5
9994 ac_cv_lib_dnet_stub_dnet_ntoa=no
9995 fi
9996 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
9997 LIBS=$ac_check_lib_save_LIBS
9998 fi
9999 echo "$as_me:9999: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
10000 echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
10001 if test "$ac_cv_lib_dnet_stub_dnet_ntoa" = yes; then
10002 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
10003 fi
10004
10005 fi
10006 fi
10007 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10008 LIBS="$ac_xsave_LIBS"
10009
10010 # [email protected] says -lnsl (and -lsocket) are needed for his 386/AT,
10011 # to get the SysV transport functions.
10012 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
10013 # needs -lnsl.
10014 # The nsl library prevents programs from opening the X display
10015 # on Irix 5.2, according to T.E. Dickey.
10016 # The functions gethostbyname, getservbyname, and inet_addr are
10017 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
10018 echo "$as_me:10018: checking for gethostbyname" >&5
10019 echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
10020 if test "${ac_cv_func_gethostbyname+set}" = set; then
10021 echo $ECHO_N "(cached) $ECHO_C" >&6
10022 else
10023 cat >"conftest.$ac_ext" <<_ACEOF
10024 #line 10024 "configure"
10025 #include "confdefs.h"
10026 #define gethostbyname autoconf_temporary
10027 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
10028 #undef gethostbyname
10029
10030 #ifdef __cplusplus
10031 extern "C"
10032 #endif
10033
10034 /* We use char because int might match the return type of a gcc2
10035 builtin and then its argument prototype would still apply. */
10036 char gethostbyname (void);
10037
10038 int
10039 main (void)
10040 {
10041
10042 /* The GNU C library defines stubs for functions which it implements
10043 to always fail with ENOSYS. Some functions are actually named
10044 something starting with __ and the normal name is an alias. */
10045 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
10046 #error found stub for gethostbyname
10047 #endif
10048
10049 return gethostbyname ();
10050 ;
10051 return 0;
10052 }
10053 _ACEOF
10054 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10055 if { (eval echo "$as_me:10055: \"$ac_link\"") >&5
10056 (eval $ac_link) 2>&5
10057 ac_status=$?
10058 echo "$as_me:10058: \$? = $ac_status" >&5
10059 (exit "$ac_status"); } &&
10060 { ac_try='test -s "conftest$ac_exeext"'
10061 { (eval echo "$as_me:10061: \"$ac_try\"") >&5
10062 (eval $ac_try) 2>&5
10063 ac_status=$?
10064 echo "$as_me:10064: \$? = $ac_status" >&5
10065 (exit "$ac_status"); }; }; then
10066 ac_cv_func_gethostbyname=yes
10067 else
10068 echo "$as_me: failed program was:" >&5
10069 cat "conftest.$ac_ext" >&5
10070 ac_cv_func_gethostbyname=no
10071 fi
10072 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10073 fi
10074 echo "$as_me:10074: result: $ac_cv_func_gethostbyname" >&5
10075 echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
10076
10077 if test $ac_cv_func_gethostbyname = no; then
10078 echo "$as_me:10078: checking for gethostbyname in -lnsl" >&5
10079 echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
10080 if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
10081 echo $ECHO_N "(cached) $ECHO_C" >&6
10082 else
10083 ac_check_lib_save_LIBS=$LIBS
10084 LIBS="-lnsl $LIBS"
10085 cat >"conftest.$ac_ext" <<_ACEOF
10086 #line 10086 "configure"
10087 #include "confdefs.h"
10088
10089 /* Override any gcc2 internal prototype to avoid an error. */
10090 #ifdef __cplusplus
10091 extern "C"
10092 #endif
10093 /* We use char because int might match the return type of a gcc2
10094 builtin and then its argument prototype would still apply. */
10095 char gethostbyname (void);
10096 int
10097 main (void)
10098 {
10099 gethostbyname ();
10100 ;
10101 return 0;
10102 }
10103 _ACEOF
10104 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10105 if { (eval echo "$as_me:10105: \"$ac_link\"") >&5
10106 (eval $ac_link) 2>&5
10107 ac_status=$?
10108 echo "$as_me:10108: \$? = $ac_status" >&5
10109 (exit "$ac_status"); } &&
10110 { ac_try='test -s "conftest$ac_exeext"'
10111 { (eval echo "$as_me:10111: \"$ac_try\"") >&5
10112 (eval $ac_try) 2>&5
10113 ac_status=$?
10114 echo "$as_me:10114: \$? = $ac_status" >&5
10115 (exit "$ac_status"); }; }; then
10116 ac_cv_lib_nsl_gethostbyname=yes
10117 else
10118 echo "$as_me: failed program was:" >&5
10119 cat "conftest.$ac_ext" >&5
10120 ac_cv_lib_nsl_gethostbyname=no
10121 fi
10122 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10123 LIBS=$ac_check_lib_save_LIBS
10124 fi
10125 echo "$as_me:10125: result: $ac_cv_lib_nsl_gethostbyname" >&5
10126 echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
10127 if test "$ac_cv_lib_nsl_gethostbyname" = yes; then
10128 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
10129 fi
10130
10131 if test $ac_cv_lib_nsl_gethostbyname = no; then
10132 echo "$as_me:10132: checking for gethostbyname in -lbsd" >&5
10133 echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
10134 if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
10135 echo $ECHO_N "(cached) $ECHO_C" >&6
10136 else
10137 ac_check_lib_save_LIBS=$LIBS
10138 LIBS="-lbsd $LIBS"
10139 cat >"conftest.$ac_ext" <<_ACEOF
10140 #line 10140 "configure"
10141 #include "confdefs.h"
10142
10143 /* Override any gcc2 internal prototype to avoid an error. */
10144 #ifdef __cplusplus
10145 extern "C"
10146 #endif
10147 /* We use char because int might match the return type of a gcc2
10148 builtin and then its argument prototype would still apply. */
10149 char gethostbyname (void);
10150 int
10151 main (void)
10152 {
10153 gethostbyname ();
10154 ;
10155 return 0;
10156 }
10157 _ACEOF
10158 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10159 if { (eval echo "$as_me:10159: \"$ac_link\"") >&5
10160 (eval $ac_link) 2>&5
10161 ac_status=$?
10162 echo "$as_me:10162: \$? = $ac_status" >&5
10163 (exit "$ac_status"); } &&
10164 { ac_try='test -s "conftest$ac_exeext"'
10165 { (eval echo "$as_me:10165: \"$ac_try\"") >&5
10166 (eval $ac_try) 2>&5
10167 ac_status=$?
10168 echo "$as_me:10168: \$? = $ac_status" >&5
10169 (exit "$ac_status"); }; }; then
10170 ac_cv_lib_bsd_gethostbyname=yes
10171 else
10172 echo "$as_me: failed program was:" >&5
10173 cat "conftest.$ac_ext" >&5
10174 ac_cv_lib_bsd_gethostbyname=no
10175 fi
10176 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10177 LIBS=$ac_check_lib_save_LIBS
10178 fi
10179 echo "$as_me:10179: result: $ac_cv_lib_bsd_gethostbyname" >&5
10180 echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
10181 if test "$ac_cv_lib_bsd_gethostbyname" = yes; then
10182 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
10183 fi
10184
10185 fi
10186 fi
10187
10188 # [email protected] says without -lsocket,
10189 # socket/setsockopt and other routines are undefined under SCO ODT
10190 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
10191 # on later versions), says Simon Leinen: it contains gethostby*
10192 # variants that don't use the nameserver (or something). -lsocket
10193 # must be given before -lnsl if both are needed. We assume that
10194 # if connect needs -lnsl, so does gethostbyname.
10195 echo "$as_me:10195: checking for connect" >&5
10196 echo $ECHO_N "checking for connect... $ECHO_C" >&6
10197 if test "${ac_cv_func_connect+set}" = set; then
10198 echo $ECHO_N "(cached) $ECHO_C" >&6
10199 else
10200 cat >"conftest.$ac_ext" <<_ACEOF
10201 #line 10201 "configure"
10202 #include "confdefs.h"
10203 #define connect autoconf_temporary
10204 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
10205 #undef connect
10206
10207 #ifdef __cplusplus
10208 extern "C"
10209 #endif
10210
10211 /* We use char because int might match the return type of a gcc2
10212 builtin and then its argument prototype would still apply. */
10213 char connect (void);
10214
10215 int
10216 main (void)
10217 {
10218
10219 /* The GNU C library defines stubs for functions which it implements
10220 to always fail with ENOSYS. Some functions are actually named
10221 something starting with __ and the normal name is an alias. */
10222 #if defined (__stub_connect) || defined (__stub___connect)
10223 #error found stub for connect
10224 #endif
10225
10226 return connect ();
10227 ;
10228 return 0;
10229 }
10230 _ACEOF
10231 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10232 if { (eval echo "$as_me:10232: \"$ac_link\"") >&5
10233 (eval $ac_link) 2>&5
10234 ac_status=$?
10235 echo "$as_me:10235: \$? = $ac_status" >&5
10236 (exit "$ac_status"); } &&
10237 { ac_try='test -s "conftest$ac_exeext"'
10238 { (eval echo "$as_me:10238: \"$ac_try\"") >&5
10239 (eval $ac_try) 2>&5
10240 ac_status=$?
10241 echo "$as_me:10241: \$? = $ac_status" >&5
10242 (exit "$ac_status"); }; }; then
10243 ac_cv_func_connect=yes
10244 else
10245 echo "$as_me: failed program was:" >&5
10246 cat "conftest.$ac_ext" >&5
10247 ac_cv_func_connect=no
10248 fi
10249 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10250 fi
10251 echo "$as_me:10251: result: $ac_cv_func_connect" >&5
10252 echo "${ECHO_T}$ac_cv_func_connect" >&6
10253
10254 if test $ac_cv_func_connect = no; then
10255 echo "$as_me:10255: checking for connect in -lsocket" >&5
10256 echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
10257 if test "${ac_cv_lib_socket_connect+set}" = set; then
10258 echo $ECHO_N "(cached) $ECHO_C" >&6
10259 else
10260 ac_check_lib_save_LIBS=$LIBS
10261 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
10262 cat >"conftest.$ac_ext" <<_ACEOF
10263 #line 10263 "configure"
10264 #include "confdefs.h"
10265
10266 /* Override any gcc2 internal prototype to avoid an error. */
10267 #ifdef __cplusplus
10268 extern "C"
10269 #endif
10270 /* We use char because int might match the return type of a gcc2
10271 builtin and then its argument prototype would still apply. */
10272 char connect (void);
10273 int
10274 main (void)
10275 {
10276 connect ();
10277 ;
10278 return 0;
10279 }
10280 _ACEOF
10281 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10282 if { (eval echo "$as_me:10282: \"$ac_link\"") >&5
10283 (eval $ac_link) 2>&5
10284 ac_status=$?
10285 echo "$as_me:10285: \$? = $ac_status" >&5
10286 (exit "$ac_status"); } &&
10287 { ac_try='test -s "conftest$ac_exeext"'
10288 { (eval echo "$as_me:10288: \"$ac_try\"") >&5
10289 (eval $ac_try) 2>&5
10290 ac_status=$?
10291 echo "$as_me:10291: \$? = $ac_status" >&5
10292 (exit "$ac_status"); }; }; then
10293 ac_cv_lib_socket_connect=yes
10294 else
10295 echo "$as_me: failed program was:" >&5
10296 cat "conftest.$ac_ext" >&5
10297 ac_cv_lib_socket_connect=no
10298 fi
10299 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10300 LIBS=$ac_check_lib_save_LIBS
10301 fi
10302 echo "$as_me:10302: result: $ac_cv_lib_socket_connect" >&5
10303 echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
10304 if test "$ac_cv_lib_socket_connect" = yes; then
10305 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
10306 fi
10307
10308 fi
10309
10310 # Guillermo Gomez says -lposix is necessary on A/UX.
10311 echo "$as_me:10311: checking for remove" >&5
10312 echo $ECHO_N "checking for remove... $ECHO_C" >&6
10313 if test "${ac_cv_func_remove+set}" = set; then
10314 echo $ECHO_N "(cached) $ECHO_C" >&6
10315 else
10316 cat >"conftest.$ac_ext" <<_ACEOF
10317 #line 10317 "configure"
10318 #include "confdefs.h"
10319 #define remove autoconf_temporary
10320 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
10321 #undef remove
10322
10323 #ifdef __cplusplus
10324 extern "C"
10325 #endif
10326
10327 /* We use char because int might match the return type of a gcc2
10328 builtin and then its argument prototype would still apply. */
10329 char remove (void);
10330
10331 int
10332 main (void)
10333 {
10334
10335 /* The GNU C library defines stubs for functions which it implements
10336 to always fail with ENOSYS. Some functions are actually named
10337 something starting with __ and the normal name is an alias. */
10338 #if defined (__stub_remove) || defined (__stub___remove)
10339 #error found stub for remove
10340 #endif
10341
10342 return remove ();
10343 ;
10344 return 0;
10345 }
10346 _ACEOF
10347 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10348 if { (eval echo "$as_me:10348: \"$ac_link\"") >&5
10349 (eval $ac_link) 2>&5
10350 ac_status=$?
10351 echo "$as_me:10351: \$? = $ac_status" >&5
10352 (exit "$ac_status"); } &&
10353 { ac_try='test -s "conftest$ac_exeext"'
10354 { (eval echo "$as_me:10354: \"$ac_try\"") >&5
10355 (eval $ac_try) 2>&5
10356 ac_status=$?
10357 echo "$as_me:10357: \$? = $ac_status" >&5
10358 (exit "$ac_status"); }; }; then
10359 ac_cv_func_remove=yes
10360 else
10361 echo "$as_me: failed program was:" >&5
10362 cat "conftest.$ac_ext" >&5
10363 ac_cv_func_remove=no
10364 fi
10365 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10366 fi
10367 echo "$as_me:10367: result: $ac_cv_func_remove" >&5
10368 echo "${ECHO_T}$ac_cv_func_remove" >&6
10369
10370 if test $ac_cv_func_remove = no; then
10371 echo "$as_me:10371: checking for remove in -lposix" >&5
10372 echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
10373 if test "${ac_cv_lib_posix_remove+set}" = set; then
10374 echo $ECHO_N "(cached) $ECHO_C" >&6
10375 else
10376 ac_check_lib_save_LIBS=$LIBS
10377 LIBS="-lposix $LIBS"
10378 cat >"conftest.$ac_ext" <<_ACEOF
10379 #line 10379 "configure"
10380 #include "confdefs.h"
10381
10382 /* Override any gcc2 internal prototype to avoid an error. */
10383 #ifdef __cplusplus
10384 extern "C"
10385 #endif
10386 /* We use char because int might match the return type of a gcc2
10387 builtin and then its argument prototype would still apply. */
10388 char remove (void);
10389 int
10390 main (void)
10391 {
10392 remove ();
10393 ;
10394 return 0;
10395 }
10396 _ACEOF
10397 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10398 if { (eval echo "$as_me:10398: \"$ac_link\"") >&5
10399 (eval $ac_link) 2>&5
10400 ac_status=$?
10401 echo "$as_me:10401: \$? = $ac_status" >&5
10402 (exit "$ac_status"); } &&
10403 { ac_try='test -s "conftest$ac_exeext"'
10404 { (eval echo "$as_me:10404: \"$ac_try\"") >&5
10405 (eval $ac_try) 2>&5
10406 ac_status=$?
10407 echo "$as_me:10407: \$? = $ac_status" >&5
10408 (exit "$ac_status"); }; }; then
10409 ac_cv_lib_posix_remove=yes
10410 else
10411 echo "$as_me: failed program was:" >&5
10412 cat "conftest.$ac_ext" >&5
10413 ac_cv_lib_posix_remove=no
10414 fi
10415 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10416 LIBS=$ac_check_lib_save_LIBS
10417 fi
10418 echo "$as_me:10418: result: $ac_cv_lib_posix_remove" >&5
10419 echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
10420 if test "$ac_cv_lib_posix_remove" = yes; then
10421 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
10422 fi
10423
10424 fi
10425
10426 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
10427 echo "$as_me:10427: checking for shmat" >&5
10428 echo $ECHO_N "checking for shmat... $ECHO_C" >&6
10429 if test "${ac_cv_func_shmat+set}" = set; then
10430 echo $ECHO_N "(cached) $ECHO_C" >&6
10431 else
10432 cat >"conftest.$ac_ext" <<_ACEOF
10433 #line 10433 "configure"
10434 #include "confdefs.h"
10435 #define shmat autoconf_temporary
10436 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
10437 #undef shmat
10438
10439 #ifdef __cplusplus
10440 extern "C"
10441 #endif
10442
10443 /* We use char because int might match the return type of a gcc2
10444 builtin and then its argument prototype would still apply. */
10445 char shmat (void);
10446
10447 int
10448 main (void)
10449 {
10450
10451 /* The GNU C library defines stubs for functions which it implements
10452 to always fail with ENOSYS. Some functions are actually named
10453 something starting with __ and the normal name is an alias. */
10454 #if defined (__stub_shmat) || defined (__stub___shmat)
10455 #error found stub for shmat
10456 #endif
10457
10458 return shmat ();
10459 ;
10460 return 0;
10461 }
10462 _ACEOF
10463 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10464 if { (eval echo "$as_me:10464: \"$ac_link\"") >&5
10465 (eval $ac_link) 2>&5
10466 ac_status=$?
10467 echo "$as_me:10467: \$? = $ac_status" >&5
10468 (exit "$ac_status"); } &&
10469 { ac_try='test -s "conftest$ac_exeext"'
10470 { (eval echo "$as_me:10470: \"$ac_try\"") >&5
10471 (eval $ac_try) 2>&5
10472 ac_status=$?
10473 echo "$as_me:10473: \$? = $ac_status" >&5
10474 (exit "$ac_status"); }; }; then
10475 ac_cv_func_shmat=yes
10476 else
10477 echo "$as_me: failed program was:" >&5
10478 cat "conftest.$ac_ext" >&5
10479 ac_cv_func_shmat=no
10480 fi
10481 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10482 fi
10483 echo "$as_me:10483: result: $ac_cv_func_shmat" >&5
10484 echo "${ECHO_T}$ac_cv_func_shmat" >&6
10485
10486 if test $ac_cv_func_shmat = no; then
10487 echo "$as_me:10487: checking for shmat in -lipc" >&5
10488 echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
10489 if test "${ac_cv_lib_ipc_shmat+set}" = set; then
10490 echo $ECHO_N "(cached) $ECHO_C" >&6
10491 else
10492 ac_check_lib_save_LIBS=$LIBS
10493 LIBS="-lipc $LIBS"
10494 cat >"conftest.$ac_ext" <<_ACEOF
10495 #line 10495 "configure"
10496 #include "confdefs.h"
10497
10498 /* Override any gcc2 internal prototype to avoid an error. */
10499 #ifdef __cplusplus
10500 extern "C"
10501 #endif
10502 /* We use char because int might match the return type of a gcc2
10503 builtin and then its argument prototype would still apply. */
10504 char shmat (void);
10505 int
10506 main (void)
10507 {
10508 shmat ();
10509 ;
10510 return 0;
10511 }
10512 _ACEOF
10513 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10514 if { (eval echo "$as_me:10514: \"$ac_link\"") >&5
10515 (eval $ac_link) 2>&5
10516 ac_status=$?
10517 echo "$as_me:10517: \$? = $ac_status" >&5
10518 (exit "$ac_status"); } &&
10519 { ac_try='test -s "conftest$ac_exeext"'
10520 { (eval echo "$as_me:10520: \"$ac_try\"") >&5
10521 (eval $ac_try) 2>&5
10522 ac_status=$?
10523 echo "$as_me:10523: \$? = $ac_status" >&5
10524 (exit "$ac_status"); }; }; then
10525 ac_cv_lib_ipc_shmat=yes
10526 else
10527 echo "$as_me: failed program was:" >&5
10528 cat "conftest.$ac_ext" >&5
10529 ac_cv_lib_ipc_shmat=no
10530 fi
10531 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10532 LIBS=$ac_check_lib_save_LIBS
10533 fi
10534 echo "$as_me:10534: result: $ac_cv_lib_ipc_shmat" >&5
10535 echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
10536 if test "$ac_cv_lib_ipc_shmat" = yes; then
10537 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
10538 fi
10539
10540 fi
10541 fi
10542
10543 # Check for libraries that X11R6 Xt/Xaw programs need.
10544 ac_save_LDFLAGS=$LDFLAGS
10545 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
10546 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
10547 # check for ICE first), but we must link in the order -lSM -lICE or
10548 # we get undefined symbols. So assume we have SM if we have ICE.
10549 # These have to be linked with before -lX11, unlike the other
10550 # libraries we check for below, so use a different variable.
10551 # John Interrante, Karl Berry
10552 echo "$as_me:10552: checking for IceConnectionNumber in -lICE" >&5
10553 echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
10554 if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
10555 echo $ECHO_N "(cached) $ECHO_C" >&6
10556 else
10557 ac_check_lib_save_LIBS=$LIBS
10558 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
10559 cat >"conftest.$ac_ext" <<_ACEOF
10560 #line 10560 "configure"
10561 #include "confdefs.h"
10562
10563 /* Override any gcc2 internal prototype to avoid an error. */
10564 #ifdef __cplusplus
10565 extern "C"
10566 #endif
10567 /* We use char because int might match the return type of a gcc2
10568 builtin and then its argument prototype would still apply. */
10569 char IceConnectionNumber (void);
10570 int
10571 main (void)
10572 {
10573 IceConnectionNumber ();
10574 ;
10575 return 0;
10576 }
10577 _ACEOF
10578 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10579 if { (eval echo "$as_me:10579: \"$ac_link\"") >&5
10580 (eval $ac_link) 2>&5
10581 ac_status=$?
10582 echo "$as_me:10582: \$? = $ac_status" >&5
10583 (exit "$ac_status"); } &&
10584 { ac_try='test -s "conftest$ac_exeext"'
10585 { (eval echo "$as_me:10585: \"$ac_try\"") >&5
10586 (eval $ac_try) 2>&5
10587 ac_status=$?
10588 echo "$as_me:10588: \$? = $ac_status" >&5
10589 (exit "$ac_status"); }; }; then
10590 ac_cv_lib_ICE_IceConnectionNumber=yes
10591 else
10592 echo "$as_me: failed program was:" >&5
10593 cat "conftest.$ac_ext" >&5
10594 ac_cv_lib_ICE_IceConnectionNumber=no
10595 fi
10596 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10597 LIBS=$ac_check_lib_save_LIBS
10598 fi
10599 echo "$as_me:10599: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
10600 echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
10601 if test "$ac_cv_lib_ICE_IceConnectionNumber" = yes; then
10602 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
10603 fi
10604
10605 LDFLAGS=$ac_save_LDFLAGS
10606
10607 fi
10608
10609 echo "$as_me:10609: checking for sys/wait.h that is POSIX.1 compatible" >&5
10610 echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
10611 if test "${ac_cv_header_sys_wait_h+set}" = set; then
10612 echo $ECHO_N "(cached) $ECHO_C" >&6
10613 else
10614 cat >"conftest.$ac_ext" <<_ACEOF
10615 #line 10615 "configure"
10616 #include "confdefs.h"
10617 #include <sys/types.h>
10618 #include <sys/wait.h>
10619 #ifndef WEXITSTATUS
10620 # define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
10621 #endif
10622 #ifndef WIFEXITED
10623 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
10624 #endif
10625
10626 int
10627 main (void)
10628 {
10629 int s;
10630 wait (&s);
10631 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
10632 ;
10633 return 0;
10634 }
10635 _ACEOF
10636 rm -f "conftest.$ac_objext"
10637 if { (eval echo "$as_me:10637: \"$ac_compile\"") >&5
10638 (eval $ac_compile) 2>&5
10639 ac_status=$?
10640 echo "$as_me:10640: \$? = $ac_status" >&5
10641 (exit "$ac_status"); } &&
10642 { ac_try='test -s "conftest.$ac_objext"'
10643 { (eval echo "$as_me:10643: \"$ac_try\"") >&5
10644 (eval $ac_try) 2>&5
10645 ac_status=$?
10646 echo "$as_me:10646: \$? = $ac_status" >&5
10647 (exit "$ac_status"); }; }; then
10648 ac_cv_header_sys_wait_h=yes
10649 else
10650 echo "$as_me: failed program was:" >&5
10651 cat "conftest.$ac_ext" >&5
10652 ac_cv_header_sys_wait_h=no
10653 fi
10654 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10655 fi
10656 echo "$as_me:10656: result: $ac_cv_header_sys_wait_h" >&5
10657 echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
10658 if test $ac_cv_header_sys_wait_h = yes; then
10659
10660 cat >>confdefs.h <<\EOF
10661 #define HAVE_SYS_WAIT_H 1
10662 EOF
10663
10664 fi
10665
10666 echo "$as_me:10666: checking for POSIX wait functions" >&5
10667 echo $ECHO_N "checking for POSIX wait functions... $ECHO_C" >&6
10668 if test "${cf_cv_posix_wait+set}" = set; then
10669 echo $ECHO_N "(cached) $ECHO_C" >&6
10670 else
10671
10672 cat >"conftest.$ac_ext" <<_ACEOF
10673 #line 10673 "configure"
10674 #include "confdefs.h"
10675
10676 $ac_includes_default
10677
10678 #ifdef HAVE_SYS_WAIT_H
10679 #include <sys/wait.h>
10680 #endif
10681
10682 int
10683 main (void)
10684 {
10685
10686 int stat_loc;
10687 pid_t pid = waitpid(-1, &stat_loc, WNOHANG|WUNTRACED);
10688 pid_t pid2 = wait(&stat_loc);
10689 (void)pid;
10690 (void)pid2;
10691
10692 ;
10693 return 0;
10694 }
10695 _ACEOF
10696 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10697 if { (eval echo "$as_me:10697: \"$ac_link\"") >&5
10698 (eval $ac_link) 2>&5
10699 ac_status=$?
10700 echo "$as_me:10700: \$? = $ac_status" >&5
10701 (exit "$ac_status"); } &&
10702 { ac_try='test -s "conftest$ac_exeext"'
10703 { (eval echo "$as_me:10703: \"$ac_try\"") >&5
10704 (eval $ac_try) 2>&5
10705 ac_status=$?
10706 echo "$as_me:10706: \$? = $ac_status" >&5
10707 (exit "$ac_status"); }; }; then
10708 cf_cv_posix_wait=yes
10709 else
10710 echo "$as_me: failed program was:" >&5
10711 cat "conftest.$ac_ext" >&5
10712 cf_cv_posix_wait=no
10713 fi
10714 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10715
10716 fi
10717 echo "$as_me:10717: result: $cf_cv_posix_wait" >&5
10718 echo "${ECHO_T}$cf_cv_posix_wait" >&6
10719 test "$cf_cv_posix_wait" = yes &&
10720 cat >>confdefs.h <<\EOF
10721 #define USE_POSIX_WAIT 1
10722 EOF
10723
10724 echo "$as_me:10724: checking if external sys_nerr is declared" >&5
10725 echo $ECHO_N "checking if external sys_nerr is declared... $ECHO_C" >&6
10726 if test "${cf_cv_dcl_sys_nerr+set}" = set; then
10727 echo $ECHO_N "(cached) $ECHO_C" >&6
10728 else
10729
10730 cat >"conftest.$ac_ext" <<_ACEOF
10731 #line 10731 "configure"
10732 #include "confdefs.h"
10733
10734 $ac_includes_default
10735 #include <errno.h>
10736 int
10737 main (void)
10738 {
10739 int x = (int) sys_nerr; (void)x
10740 ;
10741 return 0;
10742 }
10743 _ACEOF
10744 rm -f "conftest.$ac_objext"
10745 if { (eval echo "$as_me:10745: \"$ac_compile\"") >&5
10746 (eval $ac_compile) 2>&5
10747 ac_status=$?
10748 echo "$as_me:10748: \$? = $ac_status" >&5
10749 (exit "$ac_status"); } &&
10750 { ac_try='test -s "conftest.$ac_objext"'
10751 { (eval echo "$as_me:10751: \"$ac_try\"") >&5
10752 (eval $ac_try) 2>&5
10753 ac_status=$?
10754 echo "$as_me:10754: \$? = $ac_status" >&5
10755 (exit "$ac_status"); }; }; then
10756 cf_cv_dcl_sys_nerr=yes
10757 else
10758 echo "$as_me: failed program was:" >&5
10759 cat "conftest.$ac_ext" >&5
10760 cf_cv_dcl_sys_nerr=no
10761 fi
10762 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10763
10764 fi
10765 echo "$as_me:10765: result: $cf_cv_dcl_sys_nerr" >&5
10766 echo "${ECHO_T}$cf_cv_dcl_sys_nerr" >&6
10767
10768 if test "$cf_cv_dcl_sys_nerr" = no ; then
10769
10770 cf_result=`echo "decl_sys_nerr" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
10771
10772 cat >>confdefs.h <<EOF
10773 #define $cf_result 1
10774 EOF
10775
10776 fi
10777
10778 # It's possible (for near-UNIX clones) that the data doesn't exist
10779
10780 echo "$as_me:10780: checking if external sys_nerr exists" >&5
10781 echo $ECHO_N "checking if external sys_nerr exists... $ECHO_C" >&6
10782 if test "${cf_cv_have_sys_nerr+set}" = set; then
10783 echo $ECHO_N "(cached) $ECHO_C" >&6
10784 else
10785
10786 cat >"conftest.$ac_ext" <<_ACEOF
10787 #line 10787 "configure"
10788 #include "confdefs.h"
10789
10790 #undef sys_nerr
10791 extern int sys_nerr;
10792
10793 int
10794 main (void)
10795 {
10796 sys_nerr = 2
10797 ;
10798 return 0;
10799 }
10800 _ACEOF
10801 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10802 if { (eval echo "$as_me:10802: \"$ac_link\"") >&5
10803 (eval $ac_link) 2>&5
10804 ac_status=$?
10805 echo "$as_me:10805: \$? = $ac_status" >&5
10806 (exit "$ac_status"); } &&
10807 { ac_try='test -s "conftest$ac_exeext"'
10808 { (eval echo "$as_me:10808: \"$ac_try\"") >&5
10809 (eval $ac_try) 2>&5
10810 ac_status=$?
10811 echo "$as_me:10811: \$? = $ac_status" >&5
10812 (exit "$ac_status"); }; }; then
10813 cf_cv_have_sys_nerr=yes
10814 else
10815 echo "$as_me: failed program was:" >&5
10816 cat "conftest.$ac_ext" >&5
10817 cf_cv_have_sys_nerr=no
10818 fi
10819 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10820
10821 fi
10822 echo "$as_me:10822: result: $cf_cv_have_sys_nerr" >&5
10823 echo "${ECHO_T}$cf_cv_have_sys_nerr" >&6
10824
10825 if test "$cf_cv_have_sys_nerr" = yes ; then
10826
10827 cf_result=`echo "have_sys_nerr" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
10828
10829 cat >>confdefs.h <<EOF
10830 #define $cf_result 1
10831 EOF
10832
10833 fi
10834
10835 echo "$as_me:10835: checking if external sys_errlist is declared" >&5
10836 echo $ECHO_N "checking if external sys_errlist is declared... $ECHO_C" >&6
10837 if test "${cf_cv_dcl_sys_errlist+set}" = set; then
10838 echo $ECHO_N "(cached) $ECHO_C" >&6
10839 else
10840
10841 cat >"conftest.$ac_ext" <<_ACEOF
10842 #line 10842 "configure"
10843 #include "confdefs.h"
10844
10845 $ac_includes_default
10846 #include <errno.h>
10847 int
10848 main (void)
10849 {
10850 int x = (int) sys_errlist; (void)x
10851 ;
10852 return 0;
10853 }
10854 _ACEOF
10855 rm -f "conftest.$ac_objext"
10856 if { (eval echo "$as_me:10856: \"$ac_compile\"") >&5
10857 (eval $ac_compile) 2>&5
10858 ac_status=$?
10859 echo "$as_me:10859: \$? = $ac_status" >&5
10860 (exit "$ac_status"); } &&
10861 { ac_try='test -s "conftest.$ac_objext"'
10862 { (eval echo "$as_me:10862: \"$ac_try\"") >&5
10863 (eval $ac_try) 2>&5
10864 ac_status=$?
10865 echo "$as_me:10865: \$? = $ac_status" >&5
10866 (exit "$ac_status"); }; }; then
10867 cf_cv_dcl_sys_errlist=yes
10868 else
10869 echo "$as_me: failed program was:" >&5
10870 cat "conftest.$ac_ext" >&5
10871 cf_cv_dcl_sys_errlist=no
10872 fi
10873 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
10874
10875 fi
10876 echo "$as_me:10876: result: $cf_cv_dcl_sys_errlist" >&5
10877 echo "${ECHO_T}$cf_cv_dcl_sys_errlist" >&6
10878
10879 if test "$cf_cv_dcl_sys_errlist" = no ; then
10880
10881 cf_result=`echo "decl_sys_errlist" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
10882
10883 cat >>confdefs.h <<EOF
10884 #define $cf_result 1
10885 EOF
10886
10887 fi
10888
10889 # It's possible (for near-UNIX clones) that the data doesn't exist
10890
10891 echo "$as_me:10891: checking if external sys_errlist exists" >&5
10892 echo $ECHO_N "checking if external sys_errlist exists... $ECHO_C" >&6
10893 if test "${cf_cv_have_sys_errlist+set}" = set; then
10894 echo $ECHO_N "(cached) $ECHO_C" >&6
10895 else
10896
10897 cat >"conftest.$ac_ext" <<_ACEOF
10898 #line 10898 "configure"
10899 #include "confdefs.h"
10900
10901 #undef sys_errlist
10902 extern int sys_errlist;
10903
10904 int
10905 main (void)
10906 {
10907 sys_errlist = 2
10908 ;
10909 return 0;
10910 }
10911 _ACEOF
10912 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
10913 if { (eval echo "$as_me:10913: \"$ac_link\"") >&5
10914 (eval $ac_link) 2>&5
10915 ac_status=$?
10916 echo "$as_me:10916: \$? = $ac_status" >&5
10917 (exit "$ac_status"); } &&
10918 { ac_try='test -s "conftest$ac_exeext"'
10919 { (eval echo "$as_me:10919: \"$ac_try\"") >&5
10920 (eval $ac_try) 2>&5
10921 ac_status=$?
10922 echo "$as_me:10922: \$? = $ac_status" >&5
10923 (exit "$ac_status"); }; }; then
10924 cf_cv_have_sys_errlist=yes
10925 else
10926 echo "$as_me: failed program was:" >&5
10927 cat "conftest.$ac_ext" >&5
10928 cf_cv_have_sys_errlist=no
10929 fi
10930 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
10931
10932 fi
10933 echo "$as_me:10933: result: $cf_cv_have_sys_errlist" >&5
10934 echo "${ECHO_T}$cf_cv_have_sys_errlist" >&6
10935
10936 if test "$cf_cv_have_sys_errlist" = yes ; then
10937
10938 cf_result=`echo "have_sys_errlist" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
10939
10940 cat >>confdefs.h <<EOF
10941 #define $cf_result 1
10942 EOF
10943
10944 fi
10945
10946 cf_save_LIBS_CF_SYSV="$LIBS"
10947 cf_save_CFLAGS_CF_SYSV="$CFLAGS"
10948 cf_save_CPPFLAGS_CF_SYSV="$CPPFLAGS"
10949 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
10950 for cf_X_CFLAGS in $X_CFLAGS
10951 do
10952 case "x$cf_X_CFLAGS" in
10953 x-[IUD]*)
10954 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
10955 ;;
10956 *)
10957 CFLAGS="$CFLAGS $cf_X_CFLAGS"
10958 ;;
10959 esac
10960 done
10961
10962 for ac_header in \
10963 termios.h \
10964 stdlib.h \
10965 X11/Intrinsic.h \
10966
10967 do
10968 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10969 echo "$as_me:10969: checking for $ac_header" >&5
10970 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10971 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10972 echo $ECHO_N "(cached) $ECHO_C" >&6
10973 else
10974 cat >"conftest.$ac_ext" <<_ACEOF
10975 #line 10975 "configure"
10976 #include "confdefs.h"
10977 #include <$ac_header>
10978 _ACEOF
10979 if { (eval echo "$as_me:10979: \"$ac_cpp "conftest.$ac_ext"\"") >&5
10980 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
10981 ac_status=$?
10982 $EGREP -v '^ *\+' conftest.er1 >conftest.err
10983 rm -f conftest.er1
10984 cat conftest.err >&5
10985 echo "$as_me:10985: \$? = $ac_status" >&5
10986 (exit "$ac_status"); } >/dev/null; then
10987 if test -s conftest.err; then
10988 ac_cpp_err=$ac_c_preproc_warn_flag
10989 else
10990 ac_cpp_err=
10991 fi
10992 else
10993 ac_cpp_err=yes
10994 fi
10995 if test -z "$ac_cpp_err"; then
10996 eval "$as_ac_Header=yes"
10997 else
10998 echo "$as_me: failed program was:" >&5
10999 cat "conftest.$ac_ext" >&5
11000 eval "$as_ac_Header=no"
11001 fi
11002 rm -f conftest.err "conftest.$ac_ext"
11003 fi
11004 echo "$as_me:11004: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
11005 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
11006 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
11007 cat >>confdefs.h <<EOF
11008 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
11009 EOF
11010
11011 fi
11012 done
11013
11014 echo "$as_me:11014: checking if we should define SYSV" >&5
11015 echo $ECHO_N "checking if we should define SYSV... $ECHO_C" >&6
11016 if test "${cf_cv_sysv+set}" = set; then
11017 echo $ECHO_N "(cached) $ECHO_C" >&6
11018 else
11019
11020 cat >"conftest.$ac_ext" <<_ACEOF
11021 #line 11021 "configure"
11022 #include "confdefs.h"
11023
11024 #undef SYSV
11025 #define SYSV 1 /* get Xos.h to declare sys_errlist[] */
11026 #ifdef HAVE_STDLIB_H
11027 #include <stdlib.h> /* look for wchar_t */
11028 #endif
11029 #ifdef HAVE_X11_INTRINSIC_H
11030 #include <X11/Intrinsic.h> /* Intrinsic.h has other traps... */
11031 #endif
11032 #ifdef HAVE_TERMIOS_H /* needed for HPUX 10.20 */
11033 #include <termios.h>
11034 #define STRUCT_TERMIOS struct termios
11035 #else
11036 #define STRUCT_TERMIOS struct termio
11037 #endif
11038 #include <curses.h>
11039 #include <term.h> /* eliminate most BSD hacks */
11040 #include <errno.h> /* declare sys_errlist on older systems */
11041 #include <sys/termio.h> /* eliminate most of the remaining ones */
11042
11043 int
11044 main (void)
11045 {
11046
11047 static STRUCT_TERMIOS d_tio;
11048 d_tio.c_cc[VINTR] = 0;
11049 d_tio.c_cc[VQUIT] = 0;
11050 d_tio.c_cc[VERASE] = 0;
11051 d_tio.c_cc[VKILL] = 0;
11052 d_tio.c_cc[VEOF] = 0;
11053 d_tio.c_cc[VEOL] = 0;
11054 d_tio.c_cc[VMIN] = 0;
11055 d_tio.c_cc[VTIME] = 0;
11056 #if defined(HAVE_SYS_ERRLIST) && !defined(DECL_SYS_ERRLIST)
11057 sys_errlist[0] = ""; /* Cygwin mis-declares this */
11058 #endif
11059
11060 ;
11061 return 0;
11062 }
11063 _ACEOF
11064 rm -f "conftest.$ac_objext"
11065 if { (eval echo "$as_me:11065: \"$ac_compile\"") >&5
11066 (eval $ac_compile) 2>&5
11067 ac_status=$?
11068 echo "$as_me:11068: \$? = $ac_status" >&5
11069 (exit "$ac_status"); } &&
11070 { ac_try='test -s "conftest.$ac_objext"'
11071 { (eval echo "$as_me:11071: \"$ac_try\"") >&5
11072 (eval $ac_try) 2>&5
11073 ac_status=$?
11074 echo "$as_me:11074: \$? = $ac_status" >&5
11075 (exit "$ac_status"); }; }; then
11076 cf_cv_sysv=yes
11077 else
11078 echo "$as_me: failed program was:" >&5
11079 cat "conftest.$ac_ext" >&5
11080 cf_cv_sysv=no
11081 fi
11082 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
11083
11084 fi
11085 echo "$as_me:11085: result: $cf_cv_sysv" >&5
11086 echo "${ECHO_T}$cf_cv_sysv" >&6
11087 test "$cf_cv_sysv" = yes &&
11088 cat >>confdefs.h <<\EOF
11089 #define SYSV 1
11090 EOF
11091
11092 LIBS="$cf_save_LIBS_CF_SYSV"
11093 CFLAGS="$cf_save_CFLAGS_CF_SYSV"
11094 CPPFLAGS="$cf_save_CPPFLAGS_CF_SYSV"
11095
11096 echo "$as_me:11096: checking for elf_begin in -lelf" >&5
11097 echo $ECHO_N "checking for elf_begin in -lelf... $ECHO_C" >&6
11098 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then
11099 echo $ECHO_N "(cached) $ECHO_C" >&6
11100 else
11101 ac_check_lib_save_LIBS=$LIBS
11102 LIBS="-lelf $LIBS"
11103 cat >"conftest.$ac_ext" <<_ACEOF
11104 #line 11104 "configure"
11105 #include "confdefs.h"
11106
11107 /* Override any gcc2 internal prototype to avoid an error. */
11108 #ifdef __cplusplus
11109 extern "C"
11110 #endif
11111 /* We use char because int might match the return type of a gcc2
11112 builtin and then its argument prototype would still apply. */
11113 char elf_begin (void);
11114 int
11115 main (void)
11116 {
11117 elf_begin ();
11118 ;
11119 return 0;
11120 }
11121 _ACEOF
11122 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
11123 if { (eval echo "$as_me:11123: \"$ac_link\"") >&5
11124 (eval $ac_link) 2>&5
11125 ac_status=$?
11126 echo "$as_me:11126: \$? = $ac_status" >&5
11127 (exit "$ac_status"); } &&
11128 { ac_try='test -s "conftest$ac_exeext"'
11129 { (eval echo "$as_me:11129: \"$ac_try\"") >&5
11130 (eval $ac_try) 2>&5
11131 ac_status=$?
11132 echo "$as_me:11132: \$? = $ac_status" >&5
11133 (exit "$ac_status"); }; }; then
11134 ac_cv_lib_elf_elf_begin=yes
11135 else
11136 echo "$as_me: failed program was:" >&5
11137 cat "conftest.$ac_ext" >&5
11138 ac_cv_lib_elf_elf_begin=no
11139 fi
11140 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
11141 LIBS=$ac_check_lib_save_LIBS
11142 fi
11143 echo "$as_me:11143: result: $ac_cv_lib_elf_elf_begin" >&5
11144 echo "${ECHO_T}$ac_cv_lib_elf_elf_begin" >&6
11145 if test "$ac_cv_lib_elf_elf_begin" = yes; then
11146
11147 echo "$as_me:11147: checking if this is an SVR4 system" >&5
11148 echo $ECHO_N "checking if this is an SVR4 system... $ECHO_C" >&6
11149 if test "${cf_cv_svr4+set}" = set; then
11150 echo $ECHO_N "(cached) $ECHO_C" >&6
11151 else
11152
11153 cat >"conftest.$ac_ext" <<_ACEOF
11154 #line 11154 "configure"
11155 #include "confdefs.h"
11156
11157 #if defined(__CYGWIN__)
11158 #error Cygwin is not SVr4
11159 #endif
11160 #include <elf.h>
11161 #include <sys/termio.h>
11162
11163 int
11164 main (void)
11165 {
11166
11167 static struct termio d_tio;
11168 d_tio.c_cc[VINTR] = 0;
11169 d_tio.c_cc[VQUIT] = 0;
11170 d_tio.c_cc[VERASE] = 0;
11171 d_tio.c_cc[VKILL] = 0;
11172 d_tio.c_cc[VEOF] = 0;
11173 d_tio.c_cc[VEOL] = 0;
11174 d_tio.c_cc[VMIN] = 0;
11175 d_tio.c_cc[VTIME] = 0;
11176 d_tio.c_cc[VLNEXT] = 0;
11177
11178 ;
11179 return 0;
11180 }
11181 _ACEOF
11182 rm -f "conftest.$ac_objext"
11183 if { (eval echo "$as_me:11183: \"$ac_compile\"") >&5
11184 (eval $ac_compile) 2>&5
11185 ac_status=$?
11186 echo "$as_me:11186: \$? = $ac_status" >&5
11187 (exit "$ac_status"); } &&
11188 { ac_try='test -s "conftest.$ac_objext"'
11189 { (eval echo "$as_me:11189: \"$ac_try\"") >&5
11190 (eval $ac_try) 2>&5
11191 ac_status=$?
11192 echo "$as_me:11192: \$? = $ac_status" >&5
11193 (exit "$ac_status"); }; }; then
11194 cf_cv_svr4=yes
11195 else
11196 echo "$as_me: failed program was:" >&5
11197 cat "conftest.$ac_ext" >&5
11198 cf_cv_svr4=no
11199 fi
11200 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
11201
11202 fi
11203 echo "$as_me:11203: result: $cf_cv_svr4" >&5
11204 echo "${ECHO_T}$cf_cv_svr4" >&6
11205
11206 fi
11207
11208 test "$cf_cv_svr4" = yes &&
11209 cat >>confdefs.h <<\EOF
11210 #define SVR4 1
11211 EOF
11212
11213 echo "$as_me:11213: checking if you want to use pkg-config" >&5
11214 echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
11215
11216 # Check whether --with-pkg-config or --without-pkg-config was given.
11217 if test "${with_pkg_config+set}" = set; then
11218 withval="$with_pkg_config"
11219 cf_pkg_config=$withval
11220 else
11221 cf_pkg_config=yes
11222 fi;
11223 echo "$as_me:11223: result: $cf_pkg_config" >&5
11224 echo "${ECHO_T}$cf_pkg_config" >&6
11225
11226 case "$cf_pkg_config" in
11227 (no)
11228 PKG_CONFIG=none
11229 ;;
11230 (yes)
11231
11232 if test -n "$ac_tool_prefix"; then
11233 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
11234 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
11235 echo "$as_me:11235: checking for $ac_word" >&5
11236 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11237 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
11238 echo $ECHO_N "(cached) $ECHO_C" >&6
11239 else
11240 case $PKG_CONFIG in
11241 [\\/]* | ?:[\\/]*)
11242 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11243 ;;
11244 *)
11245 ac_save_IFS=$IFS; IFS=$ac_path_separator
11246 ac_dummy="$PATH"
11247 for ac_dir in $ac_dummy; do
11248 IFS=$ac_save_IFS
11249 test -z "$ac_dir" && ac_dir=.
11250 if $as_executable_p "$ac_dir/$ac_word"; then
11251 ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
11252 echo "$as_me:11252: found $ac_dir/$ac_word" >&5
11253 break
11254 fi
11255 done
11256
11257 ;;
11258 esac
11259 fi
11260 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11261
11262 if test -n "$PKG_CONFIG"; then
11263 echo "$as_me:11263: result: $PKG_CONFIG" >&5
11264 echo "${ECHO_T}$PKG_CONFIG" >&6
11265 else
11266 echo "$as_me:11266: result: no" >&5
11267 echo "${ECHO_T}no" >&6
11268 fi
11269
11270 fi
11271 if test -z "$ac_cv_path_PKG_CONFIG"; then
11272 ac_pt_PKG_CONFIG=$PKG_CONFIG
11273 # Extract the first word of "pkg-config", so it can be a program name with args.
11274 set dummy pkg-config; ac_word=$2
11275 echo "$as_me:11275: checking for $ac_word" >&5
11276 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
11277 if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
11278 echo $ECHO_N "(cached) $ECHO_C" >&6
11279 else
11280 case $ac_pt_PKG_CONFIG in
11281 [\\/]* | ?:[\\/]*)
11282 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
11283 ;;
11284 *)
11285 ac_save_IFS=$IFS; IFS=$ac_path_separator
11286 ac_dummy="$PATH"
11287 for ac_dir in $ac_dummy; do
11288 IFS=$ac_save_IFS
11289 test -z "$ac_dir" && ac_dir=.
11290 if $as_executable_p "$ac_dir/$ac_word"; then
11291 ac_cv_path_ac_pt_PKG_CONFIG="$ac_dir/$ac_word"
11292 echo "$as_me:11292: found $ac_dir/$ac_word" >&5
11293 break
11294 fi
11295 done
11296
11297 test -z "$ac_cv_path_ac_pt_PKG_CONFIG" && ac_cv_path_ac_pt_PKG_CONFIG="none"
11298 ;;
11299 esac
11300 fi
11301 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
11302
11303 if test -n "$ac_pt_PKG_CONFIG"; then
11304 echo "$as_me:11304: result: $ac_pt_PKG_CONFIG" >&5
11305 echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6
11306 else
11307 echo "$as_me:11307: result: no" >&5
11308 echo "${ECHO_T}no" >&6
11309 fi
11310
11311 PKG_CONFIG=$ac_pt_PKG_CONFIG
11312 else
11313 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
11314 fi
11315
11316 ;;
11317 (*)
11318 PKG_CONFIG=$withval
11319 ;;
11320 esac
11321
11322 test -z "$PKG_CONFIG" && PKG_CONFIG=none
11323 if test "$PKG_CONFIG" != none ; then
11324
11325 if test "x$prefix" != xNONE; then
11326 cf_path_syntax="$prefix"
11327 else
11328 cf_path_syntax="$ac_default_prefix"
11329 fi
11330
11331 case "x$PKG_CONFIG" in
11332 (x\$\(*\)*|x\'*\'*)
11333 ;;
11334 (x.|x$GLOB_FULLPATH_POSIX|x$GLOB_FULLPATH_OTHER)
11335 ;;
11336 (x\$\{*prefix\}*|x\$\{*dir\}*)
11337 eval PKG_CONFIG="$PKG_CONFIG"
11338 case "x$PKG_CONFIG" in
11339 (xNONE/*)
11340 PKG_CONFIG=`echo "$PKG_CONFIG" | sed -e s%NONE%$cf_path_syntax%`
11341 ;;
11342 esac
11343 ;;
11344 (xno|xNONE/*)
11345 PKG_CONFIG=`echo "$PKG_CONFIG" | sed -e s%NONE%$cf_path_syntax%`
11346 ;;
11347 (*)
11348 { { echo "$as_me:11348: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
11349 echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
11350 { (exit 1); exit 1; }; }
11351 ;;
11352 esac
11353
11354 elif test "x$cf_pkg_config" != xno ; then
11355 { echo "$as_me:11355: WARNING: pkg-config is not installed" >&5
11356 echo "$as_me: WARNING: pkg-config is not installed" >&2;}
11357 fi
11358
11359 # OSX is schizoid about who owns /usr/X11 (old) versus /opt/X11 (new) (and
11360 # in some cases has installed dummy files in the former, other cases replaced
11361 # it with a link to the new location). This complicates the configure script.
11362 # Check for that pitfall, and recover using pkg-config
11363 #
11364 # If none of these are set, the configuration is almost certainly broken.
11365 if test -z "${X_CFLAGS}${X_PRE_LIBS}${X_LIBS}${X_EXTRA_LIBS}"
11366 then
11367
11368 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "x11"; then
11369 test -n "$verbose" && echo " found package x11" 1>&6
11370
11371 echo "${as_me:-configure}:11371: testing found package x11 ..." 1>&5
11372
11373 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "x11" 2>/dev/null`"
11374 cf_pkgconfig_libs="`$PKG_CONFIG --libs "x11" 2>/dev/null`"
11375 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
11376
11377 echo "${as_me:-configure}:11377: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11378
11379 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
11380
11381 echo "${as_me:-configure}:11381: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
11382
11383 for cf_required in x11
11384 do
11385 # check for duplicates
11386 for cf_require_pkg in $REQUIRE_PKG
11387 do
11388 if test "$cf_required" = "$cf_require_pkg"
11389 then
11390 cf_required=
11391 break
11392 fi
11393 done
11394 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
11395 done
11396
11397 cf_fix_cppflags=no
11398 cf_new_cflags=
11399 cf_new_cppflags=
11400 cf_new_extra_cppflags=
11401
11402 for cf_add_cflags in $cf_pkgconfig_incs
11403 do
11404 case "$cf_fix_cppflags" in
11405 (no)
11406 case "$cf_add_cflags" in
11407 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
11408 case "$cf_add_cflags" in
11409 (-D*)
11410 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11411
11412 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11413 && test -z "${cf_tst_cflags}" \
11414 && cf_fix_cppflags=yes
11415
11416 if test "$cf_fix_cppflags" = yes ; then
11417
11418 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11419 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11420
11421 continue
11422 elif test "${cf_tst_cflags}" = "\"'" ; then
11423
11424 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11425 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11426
11427 continue
11428 fi
11429 ;;
11430 esac
11431 case "$CPPFLAGS" in
11432 (*$cf_add_cflags)
11433 ;;
11434 (*)
11435 case "$cf_add_cflags" in
11436 (-D*)
11437 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11438
11439 CPPFLAGS=`echo "$CPPFLAGS" | \
11440 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11441 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11442
11443 ;;
11444 esac
11445
11446 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
11447 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
11448
11449 ;;
11450 esac
11451 ;;
11452 (*)
11453
11454 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
11455 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
11456
11457 ;;
11458 esac
11459 ;;
11460 (yes)
11461
11462 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11463 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11464
11465 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
11466
11467 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11468 && test -z "${cf_tst_cflags}" \
11469 && cf_fix_cppflags=no
11470 ;;
11471 esac
11472 done
11473
11474 if test -n "$cf_new_cflags" ; then
11475
11476 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
11477 CFLAGS="${CFLAGS}$cf_new_cflags"
11478
11479 fi
11480
11481 if test -n "$cf_new_cppflags" ; then
11482
11483 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11484 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
11485
11486 fi
11487
11488 if test -n "$cf_new_extra_cppflags" ; then
11489
11490 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
11491 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
11492
11493 fi
11494
11495 cf_add_libs="$LIBS"
11496 # reverse order
11497 cf_add_0lib=
11498 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
11499 # filter duplicates
11500 for cf_add_1lib in $cf_add_0lib; do
11501 for cf_add_2lib in $cf_add_libs; do
11502 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
11503 cf_add_1lib=
11504 break
11505 fi
11506 done
11507 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
11508 done
11509 LIBS="$cf_add_libs"
11510
11511 :
11512 else
11513 cf_pkgconfig_incs=
11514 cf_pkgconfig_libs=
11515 { echo "$as_me:11515: WARNING: unable to find X11 library" >&5
11516 echo "$as_me: WARNING: unable to find X11 library" >&2;}
11517 fi
11518
11519 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "ice"; then
11520 test -n "$verbose" && echo " found package ice" 1>&6
11521
11522 echo "${as_me:-configure}:11522: testing found package ice ..." 1>&5
11523
11524 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "ice" 2>/dev/null`"
11525 cf_pkgconfig_libs="`$PKG_CONFIG --libs "ice" 2>/dev/null`"
11526 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
11527
11528 echo "${as_me:-configure}:11528: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11529
11530 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
11531
11532 echo "${as_me:-configure}:11532: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
11533
11534 for cf_required in ice
11535 do
11536 # check for duplicates
11537 for cf_require_pkg in $REQUIRE_PKG
11538 do
11539 if test "$cf_required" = "$cf_require_pkg"
11540 then
11541 cf_required=
11542 break
11543 fi
11544 done
11545 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
11546 done
11547
11548 cf_fix_cppflags=no
11549 cf_new_cflags=
11550 cf_new_cppflags=
11551 cf_new_extra_cppflags=
11552
11553 for cf_add_cflags in $cf_pkgconfig_incs
11554 do
11555 case "$cf_fix_cppflags" in
11556 (no)
11557 case "$cf_add_cflags" in
11558 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
11559 case "$cf_add_cflags" in
11560 (-D*)
11561 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11562
11563 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11564 && test -z "${cf_tst_cflags}" \
11565 && cf_fix_cppflags=yes
11566
11567 if test "$cf_fix_cppflags" = yes ; then
11568
11569 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11570 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11571
11572 continue
11573 elif test "${cf_tst_cflags}" = "\"'" ; then
11574
11575 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11576 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11577
11578 continue
11579 fi
11580 ;;
11581 esac
11582 case "$CPPFLAGS" in
11583 (*$cf_add_cflags)
11584 ;;
11585 (*)
11586 case "$cf_add_cflags" in
11587 (-D*)
11588 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11589
11590 CPPFLAGS=`echo "$CPPFLAGS" | \
11591 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11592 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11593
11594 ;;
11595 esac
11596
11597 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
11598 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
11599
11600 ;;
11601 esac
11602 ;;
11603 (*)
11604
11605 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
11606 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
11607
11608 ;;
11609 esac
11610 ;;
11611 (yes)
11612
11613 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11614 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11615
11616 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
11617
11618 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11619 && test -z "${cf_tst_cflags}" \
11620 && cf_fix_cppflags=no
11621 ;;
11622 esac
11623 done
11624
11625 if test -n "$cf_new_cflags" ; then
11626
11627 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
11628 CFLAGS="${CFLAGS}$cf_new_cflags"
11629
11630 fi
11631
11632 if test -n "$cf_new_cppflags" ; then
11633
11634 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11635 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
11636
11637 fi
11638
11639 if test -n "$cf_new_extra_cppflags" ; then
11640
11641 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
11642 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
11643
11644 fi
11645
11646 cf_add_libs="$LIBS"
11647 # reverse order
11648 cf_add_0lib=
11649 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
11650 # filter duplicates
11651 for cf_add_1lib in $cf_add_0lib; do
11652 for cf_add_2lib in $cf_add_libs; do
11653 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
11654 cf_add_1lib=
11655 break
11656 fi
11657 done
11658 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
11659 done
11660 LIBS="$cf_add_libs"
11661
11662 :
11663 else
11664 cf_pkgconfig_incs=
11665 cf_pkgconfig_libs=
11666 { echo "$as_me:11666: WARNING: unable to find ICE library" >&5
11667 echo "$as_me: WARNING: unable to find ICE library" >&2;}
11668 fi
11669
11670 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "sm"; then
11671 test -n "$verbose" && echo " found package sm" 1>&6
11672
11673 echo "${as_me:-configure}:11673: testing found package sm ..." 1>&5
11674
11675 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "sm" 2>/dev/null`"
11676 cf_pkgconfig_libs="`$PKG_CONFIG --libs "sm" 2>/dev/null`"
11677 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
11678
11679 echo "${as_me:-configure}:11679: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11680
11681 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
11682
11683 echo "${as_me:-configure}:11683: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
11684
11685 for cf_required in sm
11686 do
11687 # check for duplicates
11688 for cf_require_pkg in $REQUIRE_PKG
11689 do
11690 if test "$cf_required" = "$cf_require_pkg"
11691 then
11692 cf_required=
11693 break
11694 fi
11695 done
11696 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
11697 done
11698
11699 cf_fix_cppflags=no
11700 cf_new_cflags=
11701 cf_new_cppflags=
11702 cf_new_extra_cppflags=
11703
11704 for cf_add_cflags in $cf_pkgconfig_incs
11705 do
11706 case "$cf_fix_cppflags" in
11707 (no)
11708 case "$cf_add_cflags" in
11709 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
11710 case "$cf_add_cflags" in
11711 (-D*)
11712 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11713
11714 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11715 && test -z "${cf_tst_cflags}" \
11716 && cf_fix_cppflags=yes
11717
11718 if test "$cf_fix_cppflags" = yes ; then
11719
11720 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11721 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11722
11723 continue
11724 elif test "${cf_tst_cflags}" = "\"'" ; then
11725
11726 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11727 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11728
11729 continue
11730 fi
11731 ;;
11732 esac
11733 case "$CPPFLAGS" in
11734 (*$cf_add_cflags)
11735 ;;
11736 (*)
11737 case "$cf_add_cflags" in
11738 (-D*)
11739 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11740
11741 CPPFLAGS=`echo "$CPPFLAGS" | \
11742 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11743 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11744
11745 ;;
11746 esac
11747
11748 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
11749 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
11750
11751 ;;
11752 esac
11753 ;;
11754 (*)
11755
11756 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
11757 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
11758
11759 ;;
11760 esac
11761 ;;
11762 (yes)
11763
11764 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11765 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11766
11767 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
11768
11769 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11770 && test -z "${cf_tst_cflags}" \
11771 && cf_fix_cppflags=no
11772 ;;
11773 esac
11774 done
11775
11776 if test -n "$cf_new_cflags" ; then
11777
11778 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
11779 CFLAGS="${CFLAGS}$cf_new_cflags"
11780
11781 fi
11782
11783 if test -n "$cf_new_cppflags" ; then
11784
11785 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11786 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
11787
11788 fi
11789
11790 if test -n "$cf_new_extra_cppflags" ; then
11791
11792 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
11793 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
11794
11795 fi
11796
11797 cf_add_libs="$LIBS"
11798 # reverse order
11799 cf_add_0lib=
11800 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
11801 # filter duplicates
11802 for cf_add_1lib in $cf_add_0lib; do
11803 for cf_add_2lib in $cf_add_libs; do
11804 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
11805 cf_add_1lib=
11806 break
11807 fi
11808 done
11809 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
11810 done
11811 LIBS="$cf_add_libs"
11812
11813 :
11814 else
11815 cf_pkgconfig_incs=
11816 cf_pkgconfig_libs=
11817 { echo "$as_me:11817: WARNING: unable to find SM library" >&5
11818 echo "$as_me: WARNING: unable to find SM library" >&2;}
11819 fi
11820
11821 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "xt"; then
11822 test -n "$verbose" && echo " found package xt" 1>&6
11823
11824 echo "${as_me:-configure}:11824: testing found package xt ..." 1>&5
11825
11826 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "xt" 2>/dev/null`"
11827 cf_pkgconfig_libs="`$PKG_CONFIG --libs "xt" 2>/dev/null`"
11828 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
11829
11830 echo "${as_me:-configure}:11830: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11831
11832 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
11833
11834 echo "${as_me:-configure}:11834: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
11835
11836 for cf_required in xt
11837 do
11838 # check for duplicates
11839 for cf_require_pkg in $REQUIRE_PKG
11840 do
11841 if test "$cf_required" = "$cf_require_pkg"
11842 then
11843 cf_required=
11844 break
11845 fi
11846 done
11847 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
11848 done
11849
11850 cf_fix_cppflags=no
11851 cf_new_cflags=
11852 cf_new_cppflags=
11853 cf_new_extra_cppflags=
11854
11855 for cf_add_cflags in $cf_pkgconfig_incs
11856 do
11857 case "$cf_fix_cppflags" in
11858 (no)
11859 case "$cf_add_cflags" in
11860 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
11861 case "$cf_add_cflags" in
11862 (-D*)
11863 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
11864
11865 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11866 && test -z "${cf_tst_cflags}" \
11867 && cf_fix_cppflags=yes
11868
11869 if test "$cf_fix_cppflags" = yes ; then
11870
11871 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11872 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11873
11874 continue
11875 elif test "${cf_tst_cflags}" = "\"'" ; then
11876
11877 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11878 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11879
11880 continue
11881 fi
11882 ;;
11883 esac
11884 case "$CPPFLAGS" in
11885 (*$cf_add_cflags)
11886 ;;
11887 (*)
11888 case "$cf_add_cflags" in
11889 (-D*)
11890 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
11891
11892 CPPFLAGS=`echo "$CPPFLAGS" | \
11893 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
11894 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
11895
11896 ;;
11897 esac
11898
11899 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
11900 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
11901
11902 ;;
11903 esac
11904 ;;
11905 (*)
11906
11907 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
11908 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
11909
11910 ;;
11911 esac
11912 ;;
11913 (yes)
11914
11915 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
11916 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
11917
11918 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
11919
11920 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
11921 && test -z "${cf_tst_cflags}" \
11922 && cf_fix_cppflags=no
11923 ;;
11924 esac
11925 done
11926
11927 if test -n "$cf_new_cflags" ; then
11928
11929 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
11930 CFLAGS="${CFLAGS}$cf_new_cflags"
11931
11932 fi
11933
11934 if test -n "$cf_new_cppflags" ; then
11935
11936 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
11937 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
11938
11939 fi
11940
11941 if test -n "$cf_new_extra_cppflags" ; then
11942
11943 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
11944 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
11945
11946 fi
11947
11948 cf_add_libs="$LIBS"
11949 # reverse order
11950 cf_add_0lib=
11951 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
11952 # filter duplicates
11953 for cf_add_1lib in $cf_add_0lib; do
11954 for cf_add_2lib in $cf_add_libs; do
11955 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
11956 cf_add_1lib=
11957 break
11958 fi
11959 done
11960 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
11961 done
11962 LIBS="$cf_add_libs"
11963
11964 :
11965 else
11966 cf_pkgconfig_incs=
11967 cf_pkgconfig_libs=
11968 { echo "$as_me:11968: WARNING: unable to find Xt library" >&5
11969 echo "$as_me: WARNING: unable to find Xt library" >&2;}
11970 fi
11971
11972 else
11973 LIBS="$X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
11974 fi
11975
11976 cf_have_X_LIBS=no
11977
11978 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "xt"; then
11979 test -n "$verbose" && echo " found package xt" 1>&6
11980
11981 echo "${as_me:-configure}:11981: testing found package xt ..." 1>&5
11982
11983 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "xt" 2>/dev/null`"
11984 cf_pkgconfig_libs="`$PKG_CONFIG --libs "xt" 2>/dev/null`"
11985 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
11986
11987 echo "${as_me:-configure}:11987: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
11988
11989 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
11990
11991 echo "${as_me:-configure}:11991: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
11992
11993 for cf_required in xt
11994 do
11995 # check for duplicates
11996 for cf_require_pkg in $REQUIRE_PKG
11997 do
11998 if test "$cf_required" = "$cf_require_pkg"
11999 then
12000 cf_required=
12001 break
12002 fi
12003 done
12004 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
12005 done
12006
12007 cf_fix_cppflags=no
12008 cf_new_cflags=
12009 cf_new_cppflags=
12010 cf_new_extra_cppflags=
12011
12012 for cf_add_cflags in $cf_pkgconfig_incs
12013 do
12014 case "$cf_fix_cppflags" in
12015 (no)
12016 case "$cf_add_cflags" in
12017 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12018 case "$cf_add_cflags" in
12019 (-D*)
12020 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12021
12022 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12023 && test -z "${cf_tst_cflags}" \
12024 && cf_fix_cppflags=yes
12025
12026 if test "$cf_fix_cppflags" = yes ; then
12027
12028 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12029 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12030
12031 continue
12032 elif test "${cf_tst_cflags}" = "\"'" ; then
12033
12034 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12035 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12036
12037 continue
12038 fi
12039 ;;
12040 esac
12041 case "$CPPFLAGS" in
12042 (*$cf_add_cflags)
12043 ;;
12044 (*)
12045 case "$cf_add_cflags" in
12046 (-D*)
12047 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12048
12049 CPPFLAGS=`echo "$CPPFLAGS" | \
12050 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12051 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12052
12053 ;;
12054 esac
12055
12056 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12057 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12058
12059 ;;
12060 esac
12061 ;;
12062 (*)
12063
12064 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12065 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12066
12067 ;;
12068 esac
12069 ;;
12070 (yes)
12071
12072 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12073 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12074
12075 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
12076
12077 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12078 && test -z "${cf_tst_cflags}" \
12079 && cf_fix_cppflags=no
12080 ;;
12081 esac
12082 done
12083
12084 if test -n "$cf_new_cflags" ; then
12085
12086 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12087 CFLAGS="${CFLAGS}$cf_new_cflags"
12088
12089 fi
12090
12091 if test -n "$cf_new_cppflags" ; then
12092
12093 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12094 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12095
12096 fi
12097
12098 if test -n "$cf_new_extra_cppflags" ; then
12099
12100 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12101 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12102
12103 fi
12104
12105 cf_add_libs="$LIBS"
12106 # reverse order
12107 cf_add_0lib=
12108 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
12109 # filter duplicates
12110 for cf_add_1lib in $cf_add_0lib; do
12111 for cf_add_2lib in $cf_add_libs; do
12112 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
12113 cf_add_1lib=
12114 break
12115 fi
12116 done
12117 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
12118 done
12119 LIBS="$cf_add_libs"
12120
12121 case "x$LIBS" in
12122 (*-lX11*)
12123 ;;
12124 (*)
12125 # we have an "xt" package, but it may omit Xt's dependency on X11
12126 echo "$as_me:12126: checking for usable X dependency" >&5
12127 echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6
12128 if test "${cf_cv_xt_x11_compat+set}" = set; then
12129 echo $ECHO_N "(cached) $ECHO_C" >&6
12130 else
12131
12132 cat >"conftest.$ac_ext" <<_ACEOF
12133 #line 12133 "configure"
12134 #include "confdefs.h"
12135
12136 $ac_includes_default
12137 #include <X11/Xlib.h>
12138
12139 int
12140 main (void)
12141 {
12142
12143 int rc1 = XDrawLine((Display*) 0, (Drawable) 0, (GC) 0, 0, 0, 0, 0);
12144 int rc2 = XClearWindow((Display*) 0, (Window) 0);
12145 int rc3 = XMoveWindow((Display*) 0, (Window) 0, 0, 0);
12146 int rc4 = XMoveResizeWindow((Display*)0, (Window)0, 0, 0, 0, 0);
12147
12148 ;
12149 return 0;
12150 }
12151 _ACEOF
12152 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12153 if { (eval echo "$as_me:12153: \"$ac_link\"") >&5
12154 (eval $ac_link) 2>&5
12155 ac_status=$?
12156 echo "$as_me:12156: \$? = $ac_status" >&5
12157 (exit "$ac_status"); } &&
12158 { ac_try='test -s "conftest$ac_exeext"'
12159 { (eval echo "$as_me:12159: \"$ac_try\"") >&5
12160 (eval $ac_try) 2>&5
12161 ac_status=$?
12162 echo "$as_me:12162: \$? = $ac_status" >&5
12163 (exit "$ac_status"); }; }; then
12164 cf_cv_xt_x11_compat=yes
12165 else
12166 echo "$as_me: failed program was:" >&5
12167 cat "conftest.$ac_ext" >&5
12168 cf_cv_xt_x11_compat=no
12169 fi
12170 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
12171 fi
12172 echo "$as_me:12172: result: $cf_cv_xt_x11_compat" >&5
12173 echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6
12174 if test "$cf_cv_xt_x11_compat" = no
12175 then
12176 test -n "$verbose" && echo " work around broken X11 dependency" 1>&6
12177
12178 echo "${as_me:-configure}:12178: testing work around broken X11 dependency ..." 1>&5
12179
12180 # 2010/11/19 - good enough until a working Xt on Xcb is delivered.
12181
12182 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "x11"; then
12183 test -n "$verbose" && echo " found package x11" 1>&6
12184
12185 echo "${as_me:-configure}:12185: testing found package x11 ..." 1>&5
12186
12187 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "x11" 2>/dev/null`"
12188 cf_pkgconfig_libs="`$PKG_CONFIG --libs "x11" 2>/dev/null`"
12189 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
12190
12191 echo "${as_me:-configure}:12191: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
12192
12193 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
12194
12195 echo "${as_me:-configure}:12195: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
12196
12197 for cf_required in x11
12198 do
12199 # check for duplicates
12200 for cf_require_pkg in $REQUIRE_PKG
12201 do
12202 if test "$cf_required" = "$cf_require_pkg"
12203 then
12204 cf_required=
12205 break
12206 fi
12207 done
12208 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
12209 done
12210
12211 cf_fix_cppflags=no
12212 cf_new_cflags=
12213 cf_new_cppflags=
12214 cf_new_extra_cppflags=
12215
12216 for cf_add_cflags in $cf_pkgconfig_incs
12217 do
12218 case "$cf_fix_cppflags" in
12219 (no)
12220 case "$cf_add_cflags" in
12221 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12222 case "$cf_add_cflags" in
12223 (-D*)
12224 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12225
12226 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12227 && test -z "${cf_tst_cflags}" \
12228 && cf_fix_cppflags=yes
12229
12230 if test "$cf_fix_cppflags" = yes ; then
12231
12232 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12233 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12234
12235 continue
12236 elif test "${cf_tst_cflags}" = "\"'" ; then
12237
12238 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12239 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12240
12241 continue
12242 fi
12243 ;;
12244 esac
12245 case "$CPPFLAGS" in
12246 (*$cf_add_cflags)
12247 ;;
12248 (*)
12249 case "$cf_add_cflags" in
12250 (-D*)
12251 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12252
12253 CPPFLAGS=`echo "$CPPFLAGS" | \
12254 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12255 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12256
12257 ;;
12258 esac
12259
12260 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12261 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12262
12263 ;;
12264 esac
12265 ;;
12266 (*)
12267
12268 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12269 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12270
12271 ;;
12272 esac
12273 ;;
12274 (yes)
12275
12276 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12277 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12278
12279 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
12280
12281 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12282 && test -z "${cf_tst_cflags}" \
12283 && cf_fix_cppflags=no
12284 ;;
12285 esac
12286 done
12287
12288 if test -n "$cf_new_cflags" ; then
12289
12290 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12291 CFLAGS="${CFLAGS}$cf_new_cflags"
12292
12293 fi
12294
12295 if test -n "$cf_new_cppflags" ; then
12296
12297 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12298 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12299
12300 fi
12301
12302 if test -n "$cf_new_extra_cppflags" ; then
12303
12304 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12305 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12306
12307 fi
12308
12309 cf_add_libs="$LIBS"
12310 # reverse order
12311 cf_add_0lib=
12312 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
12313 # filter duplicates
12314 for cf_add_1lib in $cf_add_0lib; do
12315 for cf_add_2lib in $cf_add_libs; do
12316 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
12317 cf_add_1lib=
12318 break
12319 fi
12320 done
12321 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
12322 done
12323 LIBS="$cf_add_libs"
12324
12325 :
12326 else
12327 cf_pkgconfig_incs=
12328 cf_pkgconfig_libs=
12329
12330 cf_add_libs="$LIBS"
12331 test -n "$verbose" && echo " ...before $cf_add_libs" 1>&6
12332
12333 echo "${as_me:-configure}:12333: testing ...before $cf_add_libs ..." 1>&5
12334
12335 for cf_add_1lib in -lX11; do
12336 # filter duplicates
12337 cf_found_2lib=no
12338 for cf_add_2lib in $cf_add_libs; do
12339 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
12340 cf_found_2lib=yes
12341 break
12342 fi
12343 done
12344 # if not a duplicate, find the dependent library
12345 if test "$cf_found_2lib" = no
12346 then
12347 cf_found_2lib=no
12348 cf_add_2libs=
12349 for cf_add_2lib in $cf_add_libs
12350 do
12351 test -n "$cf_add_2libs" && cf_add_2libs="$cf_add_2libs "
12352 cf_add_2libs="$cf_add_2libs$cf_add_2lib"
12353 if test "x$cf_add_2lib" = "x-lXt"
12354 then
12355 cf_found_2lib=yes
12356 cf_add_2libs="$cf_add_2libs $cf_add_1lib"
12357 fi
12358 done
12359 if test "$cf_found_2lib" = yes
12360 then
12361 cf_add_libs="$cf_add_2libs"
12362 else
12363 test -n "$verbose" && echo " ...missed -lXt" 1>&6
12364
12365 echo "${as_me:-configure}:12365: testing ...missed -lXt ..." 1>&5
12366
12367 fi
12368 fi
12369 done
12370 test -n "$verbose" && echo " ...after $cf_add_libs" 1>&6
12371
12372 echo "${as_me:-configure}:12372: testing ...after $cf_add_libs ..." 1>&5
12373
12374 LIBS="$cf_add_libs"
12375
12376 fi
12377
12378 fi
12379 ;;
12380 esac
12381
12382 echo "$as_me:12382: checking for usable X Toolkit package" >&5
12383 echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6
12384 if test "${cf_cv_xt_ice_compat+set}" = set; then
12385 echo $ECHO_N "(cached) $ECHO_C" >&6
12386 else
12387
12388 cat >"conftest.$ac_ext" <<_ACEOF
12389 #line 12389 "configure"
12390 #include "confdefs.h"
12391
12392 $ac_includes_default
12393 #include <X11/Shell.h>
12394
12395 int
12396 main (void)
12397 {
12398 int num = IceConnectionNumber(NULL); (void) num
12399
12400 ;
12401 return 0;
12402 }
12403 _ACEOF
12404 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12405 if { (eval echo "$as_me:12405: \"$ac_link\"") >&5
12406 (eval $ac_link) 2>&5
12407 ac_status=$?
12408 echo "$as_me:12408: \$? = $ac_status" >&5
12409 (exit "$ac_status"); } &&
12410 { ac_try='test -s "conftest$ac_exeext"'
12411 { (eval echo "$as_me:12411: \"$ac_try\"") >&5
12412 (eval $ac_try) 2>&5
12413 ac_status=$?
12414 echo "$as_me:12414: \$? = $ac_status" >&5
12415 (exit "$ac_status"); }; }; then
12416 cf_cv_xt_ice_compat=yes
12417 else
12418 echo "$as_me: failed program was:" >&5
12419 cat "conftest.$ac_ext" >&5
12420 cf_cv_xt_ice_compat=no
12421 fi
12422 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
12423 fi
12424 echo "$as_me:12424: result: $cf_cv_xt_ice_compat" >&5
12425 echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6
12426
12427 if test "$cf_cv_xt_ice_compat" = no
12428 then
12429 # workaround for broken ".pc" files used for X Toolkit.
12430 case "x$X_PRE_LIBS" in
12431 (*-lICE*)
12432 case "x$LIBS" in
12433 (*-lICE*)
12434 ;;
12435 (*)
12436 test -n "$verbose" && echo " work around broken ICE dependency" 1>&6
12437
12438 echo "${as_me:-configure}:12438: testing work around broken ICE dependency ..." 1>&5
12439
12440 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "ice"; then
12441 test -n "$verbose" && echo " found package ice" 1>&6
12442
12443 echo "${as_me:-configure}:12443: testing found package ice ..." 1>&5
12444
12445 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "ice" 2>/dev/null`"
12446 cf_pkgconfig_libs="`$PKG_CONFIG --libs "ice" 2>/dev/null`"
12447 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
12448
12449 echo "${as_me:-configure}:12449: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
12450
12451 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
12452
12453 echo "${as_me:-configure}:12453: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
12454
12455 for cf_required in ice
12456 do
12457 # check for duplicates
12458 for cf_require_pkg in $REQUIRE_PKG
12459 do
12460 if test "$cf_required" = "$cf_require_pkg"
12461 then
12462 cf_required=
12463 break
12464 fi
12465 done
12466 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
12467 done
12468
12469 cf_fix_cppflags=no
12470 cf_new_cflags=
12471 cf_new_cppflags=
12472 cf_new_extra_cppflags=
12473
12474 for cf_add_cflags in $cf_pkgconfig_incs
12475 do
12476 case "$cf_fix_cppflags" in
12477 (no)
12478 case "$cf_add_cflags" in
12479 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12480 case "$cf_add_cflags" in
12481 (-D*)
12482 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12483
12484 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12485 && test -z "${cf_tst_cflags}" \
12486 && cf_fix_cppflags=yes
12487
12488 if test "$cf_fix_cppflags" = yes ; then
12489
12490 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12491 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12492
12493 continue
12494 elif test "${cf_tst_cflags}" = "\"'" ; then
12495
12496 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12497 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12498
12499 continue
12500 fi
12501 ;;
12502 esac
12503 case "$CPPFLAGS" in
12504 (*$cf_add_cflags)
12505 ;;
12506 (*)
12507 case "$cf_add_cflags" in
12508 (-D*)
12509 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12510
12511 CPPFLAGS=`echo "$CPPFLAGS" | \
12512 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12513 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12514
12515 ;;
12516 esac
12517
12518 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12519 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12520
12521 ;;
12522 esac
12523 ;;
12524 (*)
12525
12526 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12527 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12528
12529 ;;
12530 esac
12531 ;;
12532 (yes)
12533
12534 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12535 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12536
12537 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
12538
12539 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12540 && test -z "${cf_tst_cflags}" \
12541 && cf_fix_cppflags=no
12542 ;;
12543 esac
12544 done
12545
12546 if test -n "$cf_new_cflags" ; then
12547
12548 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12549 CFLAGS="${CFLAGS}$cf_new_cflags"
12550
12551 fi
12552
12553 if test -n "$cf_new_cppflags" ; then
12554
12555 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12556 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12557
12558 fi
12559
12560 if test -n "$cf_new_extra_cppflags" ; then
12561
12562 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12563 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12564
12565 fi
12566
12567 cf_add_libs="$LIBS"
12568 # reverse order
12569 cf_add_0lib=
12570 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
12571 # filter duplicates
12572 for cf_add_1lib in $cf_add_0lib; do
12573 for cf_add_2lib in $cf_add_libs; do
12574 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
12575 cf_add_1lib=
12576 break
12577 fi
12578 done
12579 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
12580 done
12581 LIBS="$cf_add_libs"
12582
12583 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "sm"; then
12584 test -n "$verbose" && echo " found package sm" 1>&6
12585
12586 echo "${as_me:-configure}:12586: testing found package sm ..." 1>&5
12587
12588 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "sm" 2>/dev/null`"
12589 cf_pkgconfig_libs="`$PKG_CONFIG --libs "sm" 2>/dev/null`"
12590 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
12591
12592 echo "${as_me:-configure}:12592: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
12593
12594 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
12595
12596 echo "${as_me:-configure}:12596: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
12597
12598 for cf_required in sm
12599 do
12600 # check for duplicates
12601 for cf_require_pkg in $REQUIRE_PKG
12602 do
12603 if test "$cf_required" = "$cf_require_pkg"
12604 then
12605 cf_required=
12606 break
12607 fi
12608 done
12609 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
12610 done
12611
12612 cf_fix_cppflags=no
12613 cf_new_cflags=
12614 cf_new_cppflags=
12615 cf_new_extra_cppflags=
12616
12617 for cf_add_cflags in $cf_pkgconfig_incs
12618 do
12619 case "$cf_fix_cppflags" in
12620 (no)
12621 case "$cf_add_cflags" in
12622 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12623 case "$cf_add_cflags" in
12624 (-D*)
12625 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12626
12627 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12628 && test -z "${cf_tst_cflags}" \
12629 && cf_fix_cppflags=yes
12630
12631 if test "$cf_fix_cppflags" = yes ; then
12632
12633 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12634 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12635
12636 continue
12637 elif test "${cf_tst_cflags}" = "\"'" ; then
12638
12639 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12640 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12641
12642 continue
12643 fi
12644 ;;
12645 esac
12646 case "$CPPFLAGS" in
12647 (*$cf_add_cflags)
12648 ;;
12649 (*)
12650 case "$cf_add_cflags" in
12651 (-D*)
12652 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12653
12654 CPPFLAGS=`echo "$CPPFLAGS" | \
12655 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12656 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12657
12658 ;;
12659 esac
12660
12661 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12662 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12663
12664 ;;
12665 esac
12666 ;;
12667 (*)
12668
12669 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12670 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12671
12672 ;;
12673 esac
12674 ;;
12675 (yes)
12676
12677 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12678 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12679
12680 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
12681
12682 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12683 && test -z "${cf_tst_cflags}" \
12684 && cf_fix_cppflags=no
12685 ;;
12686 esac
12687 done
12688
12689 if test -n "$cf_new_cflags" ; then
12690
12691 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12692 CFLAGS="${CFLAGS}$cf_new_cflags"
12693
12694 fi
12695
12696 if test -n "$cf_new_cppflags" ; then
12697
12698 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12699 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12700
12701 fi
12702
12703 if test -n "$cf_new_extra_cppflags" ; then
12704
12705 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12706 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12707
12708 fi
12709
12710 cf_add_libs="$LIBS"
12711 # reverse order
12712 cf_add_0lib=
12713 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
12714 # filter duplicates
12715 for cf_add_1lib in $cf_add_0lib; do
12716 for cf_add_2lib in $cf_add_libs; do
12717 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
12718 cf_add_1lib=
12719 break
12720 fi
12721 done
12722 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
12723 done
12724 LIBS="$cf_add_libs"
12725
12726 :
12727 else
12728 cf_pkgconfig_incs=
12729 cf_pkgconfig_libs=
12730 :
12731 fi
12732
12733 else
12734 cf_pkgconfig_incs=
12735 cf_pkgconfig_libs=
12736
12737 cf_add_libs="$LIBS"
12738 test -n "$verbose" && echo " ...before $cf_add_libs" 1>&6
12739
12740 echo "${as_me:-configure}:12740: testing ...before $cf_add_libs ..." 1>&5
12741
12742 for cf_add_1lib in $X_PRE_LIBS; do
12743 # filter duplicates
12744 cf_found_2lib=no
12745 for cf_add_2lib in $cf_add_libs; do
12746 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
12747 cf_found_2lib=yes
12748 break
12749 fi
12750 done
12751 # if not a duplicate, find the dependent library
12752 if test "$cf_found_2lib" = no
12753 then
12754 cf_found_2lib=no
12755 cf_add_2libs=
12756 for cf_add_2lib in $cf_add_libs
12757 do
12758 test -n "$cf_add_2libs" && cf_add_2libs="$cf_add_2libs "
12759 cf_add_2libs="$cf_add_2libs$cf_add_2lib"
12760 if test "x$cf_add_2lib" = "x-lXt"
12761 then
12762 cf_found_2lib=yes
12763 cf_add_2libs="$cf_add_2libs $cf_add_1lib"
12764 fi
12765 done
12766 if test "$cf_found_2lib" = yes
12767 then
12768 cf_add_libs="$cf_add_2libs"
12769 else
12770 test -n "$verbose" && echo " ...missed -lXt" 1>&6
12771
12772 echo "${as_me:-configure}:12772: testing ...missed -lXt ..." 1>&5
12773
12774 fi
12775 fi
12776 done
12777 test -n "$verbose" && echo " ...after $cf_add_libs" 1>&6
12778
12779 echo "${as_me:-configure}:12779: testing ...after $cf_add_libs ..." 1>&5
12780
12781 LIBS="$cf_add_libs"
12782
12783 fi
12784
12785 ;;
12786 esac
12787 ;;
12788 esac
12789 fi
12790
12791 cf_have_X_LIBS=yes
12792
12793 else
12794 cf_pkgconfig_incs=
12795 cf_pkgconfig_libs=
12796
12797 LDFLAGS="$X_LIBS $LDFLAGS"
12798
12799 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
12800
12801 echo "${as_me:-configure}:12801: testing checking additions to CFLAGS ..." 1>&5
12802
12803 cf_check_cflags="$CFLAGS"
12804 cf_check_cppflags="$CPPFLAGS"
12805
12806 cf_fix_cppflags=no
12807 cf_new_cflags=
12808 cf_new_cppflags=
12809 cf_new_extra_cppflags=
12810
12811 for cf_add_cflags in $X_CFLAGS
12812 do
12813 case "$cf_fix_cppflags" in
12814 (no)
12815 case "$cf_add_cflags" in
12816 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
12817 case "$cf_add_cflags" in
12818 (-D*)
12819 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
12820
12821 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12822 && test -z "${cf_tst_cflags}" \
12823 && cf_fix_cppflags=yes
12824
12825 if test "$cf_fix_cppflags" = yes ; then
12826
12827 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12828 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12829
12830 continue
12831 elif test "${cf_tst_cflags}" = "\"'" ; then
12832
12833 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12834 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12835
12836 continue
12837 fi
12838 ;;
12839 esac
12840 case "$CPPFLAGS" in
12841 (*$cf_add_cflags)
12842 ;;
12843 (*)
12844 case "$cf_add_cflags" in
12845 (-D*)
12846 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
12847
12848 CPPFLAGS=`echo "$CPPFLAGS" | \
12849 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
12850 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
12851
12852 ;;
12853 esac
12854
12855 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
12856 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
12857
12858 ;;
12859 esac
12860 ;;
12861 (*)
12862
12863 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
12864 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
12865
12866 ;;
12867 esac
12868 ;;
12869 (yes)
12870
12871 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
12872 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
12873
12874 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
12875
12876 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
12877 && test -z "${cf_tst_cflags}" \
12878 && cf_fix_cppflags=no
12879 ;;
12880 esac
12881 done
12882
12883 if test -n "$cf_new_cflags" ; then
12884 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
12885
12886 echo "${as_me:-configure}:12886: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
12887
12888 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
12889 CFLAGS="${CFLAGS}$cf_new_cflags"
12890
12891 fi
12892
12893 if test -n "$cf_new_cppflags" ; then
12894 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
12895
12896 echo "${as_me:-configure}:12896: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
12897
12898 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
12899 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
12900
12901 fi
12902
12903 if test -n "$cf_new_extra_cppflags" ; then
12904 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
12905
12906 echo "${as_me:-configure}:12906: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
12907
12908 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
12909 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
12910
12911 fi
12912
12913 if test "x$cf_check_cflags" != "x$CFLAGS" ; then
12914 cat >"conftest.$ac_ext" <<_ACEOF
12915 #line 12915 "configure"
12916 #include "confdefs.h"
12917 #include <stdio.h>
12918 int
12919 main (void)
12920 {
12921 printf("Hello world");
12922 ;
12923 return 0;
12924 }
12925 _ACEOF
12926 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12927 if { (eval echo "$as_me:12927: \"$ac_link\"") >&5
12928 (eval $ac_link) 2>&5
12929 ac_status=$?
12930 echo "$as_me:12930: \$? = $ac_status" >&5
12931 (exit "$ac_status"); } &&
12932 { ac_try='test -s "conftest$ac_exeext"'
12933 { (eval echo "$as_me:12933: \"$ac_try\"") >&5
12934 (eval $ac_try) 2>&5
12935 ac_status=$?
12936 echo "$as_me:12936: \$? = $ac_status" >&5
12937 (exit "$ac_status"); }; }; then
12938 :
12939 else
12940 echo "$as_me: failed program was:" >&5
12941 cat "conftest.$ac_ext" >&5
12942 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
12943
12944 echo "${as_me:-configure}:12944: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
12945
12946 if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then
12947 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
12948
12949 echo "${as_me:-configure}:12949: testing but keeping change to \$CPPFLAGS ..." 1>&5
12950
12951 fi
12952 CFLAGS="$cf_check_cflags"
12953 fi
12954 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
12955 fi
12956
12957 echo "$as_me:12957: checking for XOpenDisplay" >&5
12958 echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6
12959 if test "${ac_cv_func_XOpenDisplay+set}" = set; then
12960 echo $ECHO_N "(cached) $ECHO_C" >&6
12961 else
12962 cat >"conftest.$ac_ext" <<_ACEOF
12963 #line 12963 "configure"
12964 #include "confdefs.h"
12965 #define XOpenDisplay autoconf_temporary
12966 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
12967 #undef XOpenDisplay
12968
12969 #ifdef __cplusplus
12970 extern "C"
12971 #endif
12972
12973 /* We use char because int might match the return type of a gcc2
12974 builtin and then its argument prototype would still apply. */
12975 char XOpenDisplay (void);
12976
12977 int
12978 main (void)
12979 {
12980
12981 /* The GNU C library defines stubs for functions which it implements
12982 to always fail with ENOSYS. Some functions are actually named
12983 something starting with __ and the normal name is an alias. */
12984 #if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay)
12985 #error found stub for XOpenDisplay
12986 #endif
12987
12988 return XOpenDisplay ();
12989 ;
12990 return 0;
12991 }
12992 _ACEOF
12993 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
12994 if { (eval echo "$as_me:12994: \"$ac_link\"") >&5
12995 (eval $ac_link) 2>&5
12996 ac_status=$?
12997 echo "$as_me:12997: \$? = $ac_status" >&5
12998 (exit "$ac_status"); } &&
12999 { ac_try='test -s "conftest$ac_exeext"'
13000 { (eval echo "$as_me:13000: \"$ac_try\"") >&5
13001 (eval $ac_try) 2>&5
13002 ac_status=$?
13003 echo "$as_me:13003: \$? = $ac_status" >&5
13004 (exit "$ac_status"); }; }; then
13005 ac_cv_func_XOpenDisplay=yes
13006 else
13007 echo "$as_me: failed program was:" >&5
13008 cat "conftest.$ac_ext" >&5
13009 ac_cv_func_XOpenDisplay=no
13010 fi
13011 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13012 fi
13013 echo "$as_me:13013: result: $ac_cv_func_XOpenDisplay" >&5
13014 echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6
13015 if test "$ac_cv_func_XOpenDisplay" = yes; then
13016 :
13017 else
13018
13019 echo "$as_me:13019: checking for XOpenDisplay in -lX11" >&5
13020 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
13021 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
13022 echo $ECHO_N "(cached) $ECHO_C" >&6
13023 else
13024 ac_check_lib_save_LIBS=$LIBS
13025 LIBS="-lX11 $LIBS"
13026 cat >"conftest.$ac_ext" <<_ACEOF
13027 #line 13027 "configure"
13028 #include "confdefs.h"
13029
13030 /* Override any gcc2 internal prototype to avoid an error. */
13031 #ifdef __cplusplus
13032 extern "C"
13033 #endif
13034 /* We use char because int might match the return type of a gcc2
13035 builtin and then its argument prototype would still apply. */
13036 char XOpenDisplay (void);
13037 int
13038 main (void)
13039 {
13040 XOpenDisplay ();
13041 ;
13042 return 0;
13043 }
13044 _ACEOF
13045 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13046 if { (eval echo "$as_me:13046: \"$ac_link\"") >&5
13047 (eval $ac_link) 2>&5
13048 ac_status=$?
13049 echo "$as_me:13049: \$? = $ac_status" >&5
13050 (exit "$ac_status"); } &&
13051 { ac_try='test -s "conftest$ac_exeext"'
13052 { (eval echo "$as_me:13052: \"$ac_try\"") >&5
13053 (eval $ac_try) 2>&5
13054 ac_status=$?
13055 echo "$as_me:13055: \$? = $ac_status" >&5
13056 (exit "$ac_status"); }; }; then
13057 ac_cv_lib_X11_XOpenDisplay=yes
13058 else
13059 echo "$as_me: failed program was:" >&5
13060 cat "conftest.$ac_ext" >&5
13061 ac_cv_lib_X11_XOpenDisplay=no
13062 fi
13063 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13064 LIBS=$ac_check_lib_save_LIBS
13065 fi
13066 echo "$as_me:13066: result: $ac_cv_lib_X11_XOpenDisplay" >&5
13067 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
13068 if test "$ac_cv_lib_X11_XOpenDisplay" = yes; then
13069
13070 cf_add_libs="$LIBS"
13071 # reverse order
13072 cf_add_0lib=
13073 for cf_add_1lib in -lX11; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13074 # filter duplicates
13075 for cf_add_1lib in $cf_add_0lib; do
13076 for cf_add_2lib in $cf_add_libs; do
13077 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13078 cf_add_1lib=
13079 break
13080 fi
13081 done
13082 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13083 done
13084 LIBS="$cf_add_libs"
13085
13086 fi
13087
13088 fi
13089
13090 echo "$as_me:13090: checking for XtAppInitialize" >&5
13091 echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6
13092 if test "${ac_cv_func_XtAppInitialize+set}" = set; then
13093 echo $ECHO_N "(cached) $ECHO_C" >&6
13094 else
13095 cat >"conftest.$ac_ext" <<_ACEOF
13096 #line 13096 "configure"
13097 #include "confdefs.h"
13098 #define XtAppInitialize autoconf_temporary
13099 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
13100 #undef XtAppInitialize
13101
13102 #ifdef __cplusplus
13103 extern "C"
13104 #endif
13105
13106 /* We use char because int might match the return type of a gcc2
13107 builtin and then its argument prototype would still apply. */
13108 char XtAppInitialize (void);
13109
13110 int
13111 main (void)
13112 {
13113
13114 /* The GNU C library defines stubs for functions which it implements
13115 to always fail with ENOSYS. Some functions are actually named
13116 something starting with __ and the normal name is an alias. */
13117 #if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize)
13118 #error found stub for XtAppInitialize
13119 #endif
13120
13121 return XtAppInitialize ();
13122 ;
13123 return 0;
13124 }
13125 _ACEOF
13126 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13127 if { (eval echo "$as_me:13127: \"$ac_link\"") >&5
13128 (eval $ac_link) 2>&5
13129 ac_status=$?
13130 echo "$as_me:13130: \$? = $ac_status" >&5
13131 (exit "$ac_status"); } &&
13132 { ac_try='test -s "conftest$ac_exeext"'
13133 { (eval echo "$as_me:13133: \"$ac_try\"") >&5
13134 (eval $ac_try) 2>&5
13135 ac_status=$?
13136 echo "$as_me:13136: \$? = $ac_status" >&5
13137 (exit "$ac_status"); }; }; then
13138 ac_cv_func_XtAppInitialize=yes
13139 else
13140 echo "$as_me: failed program was:" >&5
13141 cat "conftest.$ac_ext" >&5
13142 ac_cv_func_XtAppInitialize=no
13143 fi
13144 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13145 fi
13146 echo "$as_me:13146: result: $ac_cv_func_XtAppInitialize" >&5
13147 echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6
13148 if test "$ac_cv_func_XtAppInitialize" = yes; then
13149 :
13150 else
13151
13152 echo "$as_me:13152: checking for XtAppInitialize in -lXt" >&5
13153 echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6
13154 if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then
13155 echo $ECHO_N "(cached) $ECHO_C" >&6
13156 else
13157 ac_check_lib_save_LIBS=$LIBS
13158 LIBS="-lXt $LIBS"
13159 cat >"conftest.$ac_ext" <<_ACEOF
13160 #line 13160 "configure"
13161 #include "confdefs.h"
13162
13163 /* Override any gcc2 internal prototype to avoid an error. */
13164 #ifdef __cplusplus
13165 extern "C"
13166 #endif
13167 /* We use char because int might match the return type of a gcc2
13168 builtin and then its argument prototype would still apply. */
13169 char XtAppInitialize (void);
13170 int
13171 main (void)
13172 {
13173 XtAppInitialize ();
13174 ;
13175 return 0;
13176 }
13177 _ACEOF
13178 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13179 if { (eval echo "$as_me:13179: \"$ac_link\"") >&5
13180 (eval $ac_link) 2>&5
13181 ac_status=$?
13182 echo "$as_me:13182: \$? = $ac_status" >&5
13183 (exit "$ac_status"); } &&
13184 { ac_try='test -s "conftest$ac_exeext"'
13185 { (eval echo "$as_me:13185: \"$ac_try\"") >&5
13186 (eval $ac_try) 2>&5
13187 ac_status=$?
13188 echo "$as_me:13188: \$? = $ac_status" >&5
13189 (exit "$ac_status"); }; }; then
13190 ac_cv_lib_Xt_XtAppInitialize=yes
13191 else
13192 echo "$as_me: failed program was:" >&5
13193 cat "conftest.$ac_ext" >&5
13194 ac_cv_lib_Xt_XtAppInitialize=no
13195 fi
13196 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13197 LIBS=$ac_check_lib_save_LIBS
13198 fi
13199 echo "$as_me:13199: result: $ac_cv_lib_Xt_XtAppInitialize" >&5
13200 echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6
13201 if test "$ac_cv_lib_Xt_XtAppInitialize" = yes; then
13202
13203 cat >>confdefs.h <<\EOF
13204 #define HAVE_LIBXT 1
13205 EOF
13206
13207 cf_have_X_LIBS=Xt
13208 LIBS="-lXt $LIBS"
13209 fi
13210
13211 fi
13212
13213 fi
13214
13215 if test "$cf_have_X_LIBS" = no ; then
13216 { echo "$as_me:13216: WARNING: Unable to successfully link X Toolkit library (-lXt) with
13217 test program. You will have to check and add the proper libraries by hand
13218 to makefile." >&5
13219 echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with
13220 test program. You will have to check and add the proper libraries by hand
13221 to makefile." >&2;}
13222 fi
13223
13224 for ac_header in \
13225 X11/DECkeysym.h \
13226 X11/Sunkeysym.h \
13227 X11/XF86keysym.h \
13228 X11/XKBlib.h \
13229 X11/TranslateI.h \
13230 X11/Xpoll.h \
13231 X11/extensions/XKB.h \
13232
13233 do
13234 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13235 echo "$as_me:13235: checking for $ac_header" >&5
13236 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13237 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13238 echo $ECHO_N "(cached) $ECHO_C" >&6
13239 else
13240 cat >"conftest.$ac_ext" <<_ACEOF
13241 #line 13241 "configure"
13242 #include "confdefs.h"
13243 #include <$ac_header>
13244 _ACEOF
13245 if { (eval echo "$as_me:13245: \"$ac_cpp "conftest.$ac_ext"\"") >&5
13246 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
13247 ac_status=$?
13248 $EGREP -v '^ *\+' conftest.er1 >conftest.err
13249 rm -f conftest.er1
13250 cat conftest.err >&5
13251 echo "$as_me:13251: \$? = $ac_status" >&5
13252 (exit "$ac_status"); } >/dev/null; then
13253 if test -s conftest.err; then
13254 ac_cpp_err=$ac_c_preproc_warn_flag
13255 else
13256 ac_cpp_err=
13257 fi
13258 else
13259 ac_cpp_err=yes
13260 fi
13261 if test -z "$ac_cpp_err"; then
13262 eval "$as_ac_Header=yes"
13263 else
13264 echo "$as_me: failed program was:" >&5
13265 cat "conftest.$ac_ext" >&5
13266 eval "$as_ac_Header=no"
13267 fi
13268 rm -f conftest.err "conftest.$ac_ext"
13269 fi
13270 echo "$as_me:13270: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
13271 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
13272 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
13273 cat >>confdefs.h <<EOF
13274 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13275 EOF
13276
13277 fi
13278 done
13279
13280 ICON_SUFFIX=.xbm
13281
13282 cf_save_cppflags="${CPPFLAGS}"
13283 cf_save_ldflags="${LDFLAGS}"
13284
13285 echo "$as_me:13285: checking if you want to use the Xpm library for colored icon" >&5
13286 echo $ECHO_N "checking if you want to use the Xpm library for colored icon... $ECHO_C" >&6
13287
13288 # Check whether --with-xpm or --without-xpm was given.
13289 if test "${with_xpm+set}" = set; then
13290 withval="$with_xpm"
13291 cf_Xpm_library="$withval"
13292 else
13293 cf_Xpm_library=yes
13294 fi;
13295 echo "$as_me:13295: result: $cf_Xpm_library" >&5
13296 echo "${ECHO_T}$cf_Xpm_library" >&6
13297
13298 if test "$cf_Xpm_library" != no ; then
13299 if test "$cf_Xpm_library" != yes ; then
13300 CPPFLAGS="$CPPFLAGS -I$withval/include"
13301 LDFLAGS="$LDFLAGS -L$withval/lib"
13302 fi
13303 echo "$as_me:13303: checking for X11/xpm.h" >&5
13304 echo $ECHO_N "checking for X11/xpm.h... $ECHO_C" >&6
13305 if test "${ac_cv_header_X11_xpm_h+set}" = set; then
13306 echo $ECHO_N "(cached) $ECHO_C" >&6
13307 else
13308 cat >"conftest.$ac_ext" <<_ACEOF
13309 #line 13309 "configure"
13310 #include "confdefs.h"
13311 #include <X11/xpm.h>
13312 _ACEOF
13313 if { (eval echo "$as_me:13313: \"$ac_cpp "conftest.$ac_ext"\"") >&5
13314 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
13315 ac_status=$?
13316 $EGREP -v '^ *\+' conftest.er1 >conftest.err
13317 rm -f conftest.er1
13318 cat conftest.err >&5
13319 echo "$as_me:13319: \$? = $ac_status" >&5
13320 (exit "$ac_status"); } >/dev/null; then
13321 if test -s conftest.err; then
13322 ac_cpp_err=$ac_c_preproc_warn_flag
13323 else
13324 ac_cpp_err=
13325 fi
13326 else
13327 ac_cpp_err=yes
13328 fi
13329 if test -z "$ac_cpp_err"; then
13330 ac_cv_header_X11_xpm_h=yes
13331 else
13332 echo "$as_me: failed program was:" >&5
13333 cat "conftest.$ac_ext" >&5
13334 ac_cv_header_X11_xpm_h=no
13335 fi
13336 rm -f conftest.err "conftest.$ac_ext"
13337 fi
13338 echo "$as_me:13338: result: $ac_cv_header_X11_xpm_h" >&5
13339 echo "${ECHO_T}$ac_cv_header_X11_xpm_h" >&6
13340 if test "$ac_cv_header_X11_xpm_h" = yes; then
13341
13342 echo "$as_me:13342: checking for XpmCreatePixmapFromData in -lXpm" >&5
13343 echo $ECHO_N "checking for XpmCreatePixmapFromData in -lXpm... $ECHO_C" >&6
13344 if test "${ac_cv_lib_Xpm_XpmCreatePixmapFromData+set}" = set; then
13345 echo $ECHO_N "(cached) $ECHO_C" >&6
13346 else
13347 ac_check_lib_save_LIBS=$LIBS
13348 LIBS="-lXpm -lX11 $X_LIBS $LIBS"
13349 cat >"conftest.$ac_ext" <<_ACEOF
13350 #line 13350 "configure"
13351 #include "confdefs.h"
13352
13353 /* Override any gcc2 internal prototype to avoid an error. */
13354 #ifdef __cplusplus
13355 extern "C"
13356 #endif
13357 /* We use char because int might match the return type of a gcc2
13358 builtin and then its argument prototype would still apply. */
13359 char XpmCreatePixmapFromData (void);
13360 int
13361 main (void)
13362 {
13363 XpmCreatePixmapFromData ();
13364 ;
13365 return 0;
13366 }
13367 _ACEOF
13368 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13369 if { (eval echo "$as_me:13369: \"$ac_link\"") >&5
13370 (eval $ac_link) 2>&5
13371 ac_status=$?
13372 echo "$as_me:13372: \$? = $ac_status" >&5
13373 (exit "$ac_status"); } &&
13374 { ac_try='test -s "conftest$ac_exeext"'
13375 { (eval echo "$as_me:13375: \"$ac_try\"") >&5
13376 (eval $ac_try) 2>&5
13377 ac_status=$?
13378 echo "$as_me:13378: \$? = $ac_status" >&5
13379 (exit "$ac_status"); }; }; then
13380 ac_cv_lib_Xpm_XpmCreatePixmapFromData=yes
13381 else
13382 echo "$as_me: failed program was:" >&5
13383 cat "conftest.$ac_ext" >&5
13384 ac_cv_lib_Xpm_XpmCreatePixmapFromData=no
13385 fi
13386 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13387 LIBS=$ac_check_lib_save_LIBS
13388 fi
13389 echo "$as_me:13389: result: $ac_cv_lib_Xpm_XpmCreatePixmapFromData" >&5
13390 echo "${ECHO_T}$ac_cv_lib_Xpm_XpmCreatePixmapFromData" >&6
13391 if test "$ac_cv_lib_Xpm_XpmCreatePixmapFromData" = yes; then
13392
13393 cat >>confdefs.h <<\EOF
13394 #define HAVE_LIBXPM 1
13395 EOF
13396
13397 ICON_SUFFIX=.xpm
13398 LIBS="-lXpm $LIBS"
13399 else
13400 CPPFLAGS="${cf_save_cppflags}" LDFLAGS="${cf_save_ldflags}"
13401 fi
13402
13403 else
13404 CPPFLAGS="${cf_save_cppflags}" LDFLAGS="${cf_save_ldflags}"
13405 fi
13406
13407 fi
13408
13409 echo "$as_me:13409: checking if you want to use the Xinerama extension" >&5
13410 echo $ECHO_N "checking if you want to use the Xinerama extension... $ECHO_C" >&6
13411
13412 # Check whether --with-xinerama or --without-xinerama was given.
13413 if test "${with_xinerama+set}" = set; then
13414 withval="$with_xinerama"
13415 cf_with_xinerama="$withval"
13416 else
13417 cf_with_xinerama=yes
13418 fi;
13419 echo "$as_me:13419: result: $cf_with_xinerama" >&5
13420 echo "${ECHO_T}$cf_with_xinerama" >&6
13421 if test "$cf_with_xinerama" = yes; then
13422
13423 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "xinerama"; then
13424 test -n "$verbose" && echo " found package xinerama" 1>&6
13425
13426 echo "${as_me:-configure}:13426: testing found package xinerama ..." 1>&5
13427
13428 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "xinerama" 2>/dev/null`"
13429 cf_pkgconfig_libs="`$PKG_CONFIG --libs "xinerama" 2>/dev/null`"
13430 test -n "$verbose" && echo " package xinerama CFLAGS: $cf_pkgconfig_incs" 1>&6
13431
13432 echo "${as_me:-configure}:13432: testing package xinerama CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13433
13434 test -n "$verbose" && echo " package xinerama LIBS: $cf_pkgconfig_libs" 1>&6
13435
13436 echo "${as_me:-configure}:13436: testing package xinerama LIBS: $cf_pkgconfig_libs ..." 1>&5
13437
13438 for cf_required in xinerama
13439 do
13440 # check for duplicates
13441 for cf_require_pkg in $REQUIRE_PKG
13442 do
13443 if test "$cf_required" = "$cf_require_pkg"
13444 then
13445 cf_required=
13446 break
13447 fi
13448 done
13449 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
13450 done
13451
13452 cf_fix_cppflags=no
13453 cf_new_cflags=
13454 cf_new_cppflags=
13455 cf_new_extra_cppflags=
13456
13457 for cf_add_cflags in $cf_pkgconfig_incs
13458 do
13459 case "$cf_fix_cppflags" in
13460 (no)
13461 case "$cf_add_cflags" in
13462 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13463 case "$cf_add_cflags" in
13464 (-D*)
13465 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13466
13467 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13468 && test -z "${cf_tst_cflags}" \
13469 && cf_fix_cppflags=yes
13470
13471 if test "$cf_fix_cppflags" = yes ; then
13472
13473 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13474 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13475
13476 continue
13477 elif test "${cf_tst_cflags}" = "\"'" ; then
13478
13479 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13480 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13481
13482 continue
13483 fi
13484 ;;
13485 esac
13486 case "$CPPFLAGS" in
13487 (*$cf_add_cflags)
13488 ;;
13489 (*)
13490 case "$cf_add_cflags" in
13491 (-D*)
13492 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13493
13494 CPPFLAGS=`echo "$CPPFLAGS" | \
13495 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13496 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13497
13498 ;;
13499 esac
13500
13501 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13502 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13503
13504 ;;
13505 esac
13506 ;;
13507 (*)
13508
13509 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13510 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13511
13512 ;;
13513 esac
13514 ;;
13515 (yes)
13516
13517 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13518 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13519
13520 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
13521
13522 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13523 && test -z "${cf_tst_cflags}" \
13524 && cf_fix_cppflags=no
13525 ;;
13526 esac
13527 done
13528
13529 if test -n "$cf_new_cflags" ; then
13530
13531 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13532 CFLAGS="${CFLAGS}$cf_new_cflags"
13533
13534 fi
13535
13536 if test -n "$cf_new_cppflags" ; then
13537
13538 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13539 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13540
13541 fi
13542
13543 if test -n "$cf_new_extra_cppflags" ; then
13544
13545 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13546 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13547
13548 fi
13549
13550 cf_add_libs="$LIBS"
13551 # reverse order
13552 cf_add_0lib=
13553 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13554 # filter duplicates
13555 for cf_add_1lib in $cf_add_0lib; do
13556 for cf_add_2lib in $cf_add_libs; do
13557 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13558 cf_add_1lib=
13559 break
13560 fi
13561 done
13562 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13563 done
13564 LIBS="$cf_add_libs"
13565
13566 cat >>confdefs.h <<\EOF
13567 #define HAVE_X11_EXTENSIONS_XINERAMA_H 1
13568 EOF
13569
13570 else
13571 cf_pkgconfig_incs=
13572 cf_pkgconfig_libs=
13573
13574 echo "$as_me:13574: checking for XineramaQueryScreens in -lXinerama" >&5
13575 echo $ECHO_N "checking for XineramaQueryScreens in -lXinerama... $ECHO_C" >&6
13576 if test "${ac_cv_lib_Xinerama_XineramaQueryScreens+set}" = set; then
13577 echo $ECHO_N "(cached) $ECHO_C" >&6
13578 else
13579 ac_check_lib_save_LIBS=$LIBS
13580 LIBS="-lXinerama $LIBS"
13581 cat >"conftest.$ac_ext" <<_ACEOF
13582 #line 13582 "configure"
13583 #include "confdefs.h"
13584
13585 /* Override any gcc2 internal prototype to avoid an error. */
13586 #ifdef __cplusplus
13587 extern "C"
13588 #endif
13589 /* We use char because int might match the return type of a gcc2
13590 builtin and then its argument prototype would still apply. */
13591 char XineramaQueryScreens (void);
13592 int
13593 main (void)
13594 {
13595 XineramaQueryScreens ();
13596 ;
13597 return 0;
13598 }
13599 _ACEOF
13600 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13601 if { (eval echo "$as_me:13601: \"$ac_link\"") >&5
13602 (eval $ac_link) 2>&5
13603 ac_status=$?
13604 echo "$as_me:13604: \$? = $ac_status" >&5
13605 (exit "$ac_status"); } &&
13606 { ac_try='test -s "conftest$ac_exeext"'
13607 { (eval echo "$as_me:13607: \"$ac_try\"") >&5
13608 (eval $ac_try) 2>&5
13609 ac_status=$?
13610 echo "$as_me:13610: \$? = $ac_status" >&5
13611 (exit "$ac_status"); }; }; then
13612 ac_cv_lib_Xinerama_XineramaQueryScreens=yes
13613 else
13614 echo "$as_me: failed program was:" >&5
13615 cat "conftest.$ac_ext" >&5
13616 ac_cv_lib_Xinerama_XineramaQueryScreens=no
13617 fi
13618 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13619 LIBS=$ac_check_lib_save_LIBS
13620 fi
13621 echo "$as_me:13621: result: $ac_cv_lib_Xinerama_XineramaQueryScreens" >&5
13622 echo "${ECHO_T}$ac_cv_lib_Xinerama_XineramaQueryScreens" >&6
13623 if test "$ac_cv_lib_Xinerama_XineramaQueryScreens" = yes; then
13624
13625 cf_add_libs="$LIBS"
13626 # reverse order
13627 cf_add_0lib=
13628 for cf_add_1lib in -lXinerama; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13629 # filter duplicates
13630 for cf_add_1lib in $cf_add_0lib; do
13631 for cf_add_2lib in $cf_add_libs; do
13632 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13633 cf_add_1lib=
13634 break
13635 fi
13636 done
13637 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13638 done
13639 LIBS="$cf_add_libs"
13640
13641 for ac_header in \
13642 X11/extensions/Xinerama.h \
13643
13644 do
13645 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13646 echo "$as_me:13646: checking for $ac_header" >&5
13647 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
13648 if eval "test \"\${$as_ac_Header+set}\" = set"; then
13649 echo $ECHO_N "(cached) $ECHO_C" >&6
13650 else
13651 cat >"conftest.$ac_ext" <<_ACEOF
13652 #line 13652 "configure"
13653 #include "confdefs.h"
13654 #include <$ac_header>
13655 _ACEOF
13656 if { (eval echo "$as_me:13656: \"$ac_cpp "conftest.$ac_ext"\"") >&5
13657 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
13658 ac_status=$?
13659 $EGREP -v '^ *\+' conftest.er1 >conftest.err
13660 rm -f conftest.er1
13661 cat conftest.err >&5
13662 echo "$as_me:13662: \$? = $ac_status" >&5
13663 (exit "$ac_status"); } >/dev/null; then
13664 if test -s conftest.err; then
13665 ac_cpp_err=$ac_c_preproc_warn_flag
13666 else
13667 ac_cpp_err=
13668 fi
13669 else
13670 ac_cpp_err=yes
13671 fi
13672 if test -z "$ac_cpp_err"; then
13673 eval "$as_ac_Header=yes"
13674 else
13675 echo "$as_me: failed program was:" >&5
13676 cat "conftest.$ac_ext" >&5
13677 eval "$as_ac_Header=no"
13678 fi
13679 rm -f conftest.err "conftest.$ac_ext"
13680 fi
13681 echo "$as_me:13681: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
13682 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
13683 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
13684 cat >>confdefs.h <<EOF
13685 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13686 EOF
13687
13688 fi
13689 done
13690
13691 fi
13692
13693 fi
13694
13695 fi
13696
13697 cf_x_athena=${cf_x_athena:-Xaw}
13698
13699 echo "$as_me:13699: checking if you want to link with Xaw 3d library" >&5
13700 echo $ECHO_N "checking if you want to link with Xaw 3d library... $ECHO_C" >&6
13701 withval=
13702
13703 # Check whether --with-Xaw3d or --without-Xaw3d was given.
13704 if test "${with_Xaw3d+set}" = set; then
13705 withval="$with_Xaw3d"
13706
13707 fi;
13708 if test "$withval" = yes ; then
13709 cf_x_athena=Xaw3d
13710 echo "$as_me:13710: result: yes" >&5
13711 echo "${ECHO_T}yes" >&6
13712 else
13713 echo "$as_me:13713: result: no" >&5
13714 echo "${ECHO_T}no" >&6
13715 fi
13716
13717 echo "$as_me:13717: checking if you want to link with Xaw 3d xft library" >&5
13718 echo $ECHO_N "checking if you want to link with Xaw 3d xft library... $ECHO_C" >&6
13719 withval=
13720
13721 # Check whether --with-Xaw3dxft or --without-Xaw3dxft was given.
13722 if test "${with_Xaw3dxft+set}" = set; then
13723 withval="$with_Xaw3dxft"
13724
13725 fi;
13726 if test "$withval" = yes ; then
13727 cf_x_athena=Xaw3dxft
13728 echo "$as_me:13728: result: yes" >&5
13729 echo "${ECHO_T}yes" >&6
13730 else
13731 echo "$as_me:13731: result: no" >&5
13732 echo "${ECHO_T}no" >&6
13733 fi
13734
13735 echo "$as_me:13735: checking if you want to link with neXT Athena library" >&5
13736 echo $ECHO_N "checking if you want to link with neXT Athena library... $ECHO_C" >&6
13737 withval=
13738
13739 # Check whether --with-neXtaw or --without-neXtaw was given.
13740 if test "${with_neXtaw+set}" = set; then
13741 withval="$with_neXtaw"
13742
13743 fi;
13744 if test "$withval" = yes ; then
13745 cf_x_athena=neXtaw
13746 echo "$as_me:13746: result: yes" >&5
13747 echo "${ECHO_T}yes" >&6
13748 else
13749 echo "$as_me:13749: result: no" >&5
13750 echo "${ECHO_T}no" >&6
13751 fi
13752
13753 echo "$as_me:13753: checking if you want to link with Athena-Plus library" >&5
13754 echo $ECHO_N "checking if you want to link with Athena-Plus library... $ECHO_C" >&6
13755 withval=
13756
13757 # Check whether --with-XawPlus or --without-XawPlus was given.
13758 if test "${with_XawPlus+set}" = set; then
13759 withval="$with_XawPlus"
13760
13761 fi;
13762 if test "$withval" = yes ; then
13763 cf_x_athena=XawPlus
13764 echo "$as_me:13764: result: yes" >&5
13765 echo "${ECHO_T}yes" >&6
13766 else
13767 echo "$as_me:13767: result: no" >&5
13768 echo "${ECHO_T}no" >&6
13769 fi
13770
13771 cf_x_athena_lib=""
13772
13773 if test "$PKG_CONFIG" != none ; then
13774 cf_athena_list=
13775 test "$cf_x_athena" = Xaw && cf_athena_list="xaw8 xaw7 xaw6"
13776 for cf_athena_pkg in \
13777 $cf_athena_list \
13778 ${cf_x_athena} \
13779 ${cf_x_athena}-devel \
13780 lib${cf_x_athena} \
13781 lib${cf_x_athena}-devel
13782 do
13783
13784 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "$cf_athena_pkg"; then
13785 test -n "$verbose" && echo " found package $cf_athena_pkg" 1>&6
13786
13787 echo "${as_me:-configure}:13787: testing found package $cf_athena_pkg ..." 1>&5
13788
13789 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "$cf_athena_pkg" 2>/dev/null`"
13790 cf_pkgconfig_libs="`$PKG_CONFIG --libs "$cf_athena_pkg" 2>/dev/null`"
13791 test -n "$verbose" && echo " package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs" 1>&6
13792
13793 echo "${as_me:-configure}:13793: testing package $cf_athena_pkg CFLAGS: $cf_pkgconfig_incs ..." 1>&5
13794
13795 test -n "$verbose" && echo " package $cf_athena_pkg LIBS: $cf_pkgconfig_libs" 1>&6
13796
13797 echo "${as_me:-configure}:13797: testing package $cf_athena_pkg LIBS: $cf_pkgconfig_libs ..." 1>&5
13798
13799 for cf_required in $cf_athena_pkg
13800 do
13801 # check for duplicates
13802 for cf_require_pkg in $REQUIRE_PKG
13803 do
13804 if test "$cf_required" = "$cf_require_pkg"
13805 then
13806 cf_required=
13807 break
13808 fi
13809 done
13810 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
13811 done
13812
13813 cf_fix_cppflags=no
13814 cf_new_cflags=
13815 cf_new_cppflags=
13816 cf_new_extra_cppflags=
13817
13818 for cf_add_cflags in $cf_pkgconfig_incs
13819 do
13820 case "$cf_fix_cppflags" in
13821 (no)
13822 case "$cf_add_cflags" in
13823 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
13824 case "$cf_add_cflags" in
13825 (-D*)
13826 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
13827
13828 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13829 && test -z "${cf_tst_cflags}" \
13830 && cf_fix_cppflags=yes
13831
13832 if test "$cf_fix_cppflags" = yes ; then
13833
13834 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13835 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13836
13837 continue
13838 elif test "${cf_tst_cflags}" = "\"'" ; then
13839
13840 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13841 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13842
13843 continue
13844 fi
13845 ;;
13846 esac
13847 case "$CPPFLAGS" in
13848 (*$cf_add_cflags)
13849 ;;
13850 (*)
13851 case "$cf_add_cflags" in
13852 (-D*)
13853 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
13854
13855 CPPFLAGS=`echo "$CPPFLAGS" | \
13856 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
13857 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
13858
13859 ;;
13860 esac
13861
13862 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
13863 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
13864
13865 ;;
13866 esac
13867 ;;
13868 (*)
13869
13870 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
13871 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
13872
13873 ;;
13874 esac
13875 ;;
13876 (yes)
13877
13878 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
13879 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
13880
13881 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
13882
13883 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
13884 && test -z "${cf_tst_cflags}" \
13885 && cf_fix_cppflags=no
13886 ;;
13887 esac
13888 done
13889
13890 if test -n "$cf_new_cflags" ; then
13891
13892 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
13893 CFLAGS="${CFLAGS}$cf_new_cflags"
13894
13895 fi
13896
13897 if test -n "$cf_new_cppflags" ; then
13898
13899 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
13900 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
13901
13902 fi
13903
13904 if test -n "$cf_new_extra_cppflags" ; then
13905
13906 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
13907 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
13908
13909 fi
13910
13911 cf_add_libs="$LIBS"
13912 # reverse order
13913 cf_add_0lib=
13914 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
13915 # filter duplicates
13916 for cf_add_1lib in $cf_add_0lib; do
13917 for cf_add_2lib in $cf_add_libs; do
13918 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
13919 cf_add_1lib=
13920 break
13921 fi
13922 done
13923 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
13924 done
13925 LIBS="$cf_add_libs"
13926
13927 cf_x_athena_lib="$cf_pkgconfig_libs"
13928
13929 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
13930
13931 cat >>confdefs.h <<EOF
13932 #define $cf_x_athena_LIBS 1
13933 EOF
13934
13935 echo "$as_me:13935: checking for usable $cf_x_athena/Xmu package" >&5
13936 echo $ECHO_N "checking for usable $cf_x_athena/Xmu package... $ECHO_C" >&6
13937 if test "${cf_cv_xaw_compat+set}" = set; then
13938 echo $ECHO_N "(cached) $ECHO_C" >&6
13939 else
13940
13941 cat >"conftest.$ac_ext" <<_ACEOF
13942 #line 13942 "configure"
13943 #include "confdefs.h"
13944
13945 $ac_includes_default
13946 #include <X11/Xmu/CharSet.h>
13947
13948 int
13949 main (void)
13950 {
13951
13952 int check = XmuCompareISOLatin1("big", "small");
13953 (void)check;
13954
13955 ;
13956 return 0;
13957 }
13958 _ACEOF
13959 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
13960 if { (eval echo "$as_me:13960: \"$ac_link\"") >&5
13961 (eval $ac_link) 2>&5
13962 ac_status=$?
13963 echo "$as_me:13963: \$? = $ac_status" >&5
13964 (exit "$ac_status"); } &&
13965 { ac_try='test -s "conftest$ac_exeext"'
13966 { (eval echo "$as_me:13966: \"$ac_try\"") >&5
13967 (eval $ac_try) 2>&5
13968 ac_status=$?
13969 echo "$as_me:13969: \$? = $ac_status" >&5
13970 (exit "$ac_status"); }; }; then
13971 cf_cv_xaw_compat=yes
13972 else
13973 echo "$as_me: failed program was:" >&5
13974 cat "conftest.$ac_ext" >&5
13975 cf_cv_xaw_compat=no
13976 fi
13977 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
13978 fi
13979 echo "$as_me:13979: result: $cf_cv_xaw_compat" >&5
13980 echo "${ECHO_T}$cf_cv_xaw_compat" >&6
13981
13982 if test "$cf_cv_xaw_compat" = no
13983 then
13984 # workaround for broken ".pc" files...
13985 case "$cf_x_athena_lib" in
13986 (*-lXmu*)
13987 ;;
13988 (*)
13989 test -n "$verbose" && echo " work around broken package" 1>&6
13990
13991 echo "${as_me:-configure}:13991: testing work around broken package ..." 1>&5
13992
13993 cf_save_xmu="$LIBS"
13994 cf_first_lib=`echo "$cf_save_xmu" | sed -e 's/^ *//' -e 's/ .*//'`
13995
13996 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "xmu"; then
13997 test -n "$verbose" && echo " found package xmu" 1>&6
13998
13999 echo "${as_me:-configure}:13999: testing found package xmu ..." 1>&5
14000
14001 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "xmu" 2>/dev/null`"
14002 cf_pkgconfig_libs="`$PKG_CONFIG --libs "xmu" 2>/dev/null`"
14003 test -n "$verbose" && echo " package xmu CFLAGS: $cf_pkgconfig_incs" 1>&6
14004
14005 echo "${as_me:-configure}:14005: testing package xmu CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14006
14007 test -n "$verbose" && echo " package xmu LIBS: $cf_pkgconfig_libs" 1>&6
14008
14009 echo "${as_me:-configure}:14009: testing package xmu LIBS: $cf_pkgconfig_libs ..." 1>&5
14010
14011 for cf_required in xmu
14012 do
14013 # check for duplicates
14014 for cf_require_pkg in $REQUIRE_PKG
14015 do
14016 if test "$cf_required" = "$cf_require_pkg"
14017 then
14018 cf_required=
14019 break
14020 fi
14021 done
14022 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
14023 done
14024
14025 cf_fix_cppflags=no
14026 cf_new_cflags=
14027 cf_new_cppflags=
14028 cf_new_extra_cppflags=
14029
14030 for cf_add_cflags in $cf_pkgconfig_incs
14031 do
14032 case "$cf_fix_cppflags" in
14033 (no)
14034 case "$cf_add_cflags" in
14035 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14036 case "$cf_add_cflags" in
14037 (-D*)
14038 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14039
14040 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14041 && test -z "${cf_tst_cflags}" \
14042 && cf_fix_cppflags=yes
14043
14044 if test "$cf_fix_cppflags" = yes ; then
14045
14046 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14047 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14048
14049 continue
14050 elif test "${cf_tst_cflags}" = "\"'" ; then
14051
14052 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14053 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14054
14055 continue
14056 fi
14057 ;;
14058 esac
14059 case "$CPPFLAGS" in
14060 (*$cf_add_cflags)
14061 ;;
14062 (*)
14063 case "$cf_add_cflags" in
14064 (-D*)
14065 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14066
14067 CPPFLAGS=`echo "$CPPFLAGS" | \
14068 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14069 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14070
14071 ;;
14072 esac
14073
14074 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14075 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14076
14077 ;;
14078 esac
14079 ;;
14080 (*)
14081
14082 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14083 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14084
14085 ;;
14086 esac
14087 ;;
14088 (yes)
14089
14090 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14091 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14092
14093 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
14094
14095 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14096 && test -z "${cf_tst_cflags}" \
14097 && cf_fix_cppflags=no
14098 ;;
14099 esac
14100 done
14101
14102 if test -n "$cf_new_cflags" ; then
14103
14104 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14105 CFLAGS="${CFLAGS}$cf_new_cflags"
14106
14107 fi
14108
14109 if test -n "$cf_new_cppflags" ; then
14110
14111 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14112 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14113
14114 fi
14115
14116 if test -n "$cf_new_extra_cppflags" ; then
14117
14118 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14119 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14120
14121 fi
14122
14123 cf_add_libs="$LIBS"
14124 # reverse order
14125 cf_add_0lib=
14126 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14127 # filter duplicates
14128 for cf_add_1lib in $cf_add_0lib; do
14129 for cf_add_2lib in $cf_add_libs; do
14130 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14131 cf_add_1lib=
14132 break
14133 fi
14134 done
14135 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14136 done
14137 LIBS="$cf_add_libs"
14138
14139 LIBS="$cf_save_xmu"
14140
14141 cf_add_libs="$LIBS"
14142 test -n "$verbose" && echo " ...before $cf_add_libs" 1>&6
14143
14144 echo "${as_me:-configure}:14144: testing ...before $cf_add_libs ..." 1>&5
14145
14146 for cf_add_1lib in $cf_pkgconfig_libs; do
14147 # filter duplicates
14148 cf_found_2lib=no
14149 for cf_add_2lib in $cf_add_libs; do
14150 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14151 cf_found_2lib=yes
14152 break
14153 fi
14154 done
14155 # if not a duplicate, find the dependent library
14156 if test "$cf_found_2lib" = no
14157 then
14158 cf_found_2lib=no
14159 cf_add_2libs=
14160 for cf_add_2lib in $cf_add_libs
14161 do
14162 test -n "$cf_add_2libs" && cf_add_2libs="$cf_add_2libs "
14163 cf_add_2libs="$cf_add_2libs$cf_add_2lib"
14164 if test "x$cf_add_2lib" = "x$cf_first_lib"
14165 then
14166 cf_found_2lib=yes
14167 cf_add_2libs="$cf_add_2libs $cf_add_1lib"
14168 fi
14169 done
14170 if test "$cf_found_2lib" = yes
14171 then
14172 cf_add_libs="$cf_add_2libs"
14173 else
14174 test -n "$verbose" && echo " ...missed $cf_first_lib" 1>&6
14175
14176 echo "${as_me:-configure}:14176: testing ...missed $cf_first_lib ..." 1>&5
14177
14178 fi
14179 fi
14180 done
14181 test -n "$verbose" && echo " ...after $cf_add_libs" 1>&6
14182
14183 echo "${as_me:-configure}:14183: testing ...after $cf_add_libs ..." 1>&5
14184
14185 LIBS="$cf_add_libs"
14186
14187 else
14188 cf_pkgconfig_incs=
14189 cf_pkgconfig_libs=
14190
14191 cf_add_libs="$LIBS"
14192 test -n "$verbose" && echo " ...before $cf_add_libs" 1>&6
14193
14194 echo "${as_me:-configure}:14194: testing ...before $cf_add_libs ..." 1>&5
14195
14196 for cf_add_1lib in -lXmu; do
14197 # filter duplicates
14198 cf_found_2lib=no
14199 for cf_add_2lib in $cf_add_libs; do
14200 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14201 cf_found_2lib=yes
14202 break
14203 fi
14204 done
14205 # if not a duplicate, find the dependent library
14206 if test "$cf_found_2lib" = no
14207 then
14208 cf_found_2lib=no
14209 cf_add_2libs=
14210 for cf_add_2lib in $cf_add_libs
14211 do
14212 test -n "$cf_add_2libs" && cf_add_2libs="$cf_add_2libs "
14213 cf_add_2libs="$cf_add_2libs$cf_add_2lib"
14214 if test "x$cf_add_2lib" = "x$cf_first_lib"
14215 then
14216 cf_found_2lib=yes
14217 cf_add_2libs="$cf_add_2libs $cf_add_1lib"
14218 fi
14219 done
14220 if test "$cf_found_2lib" = yes
14221 then
14222 cf_add_libs="$cf_add_2libs"
14223 else
14224 test -n "$verbose" && echo " ...missed $cf_first_lib" 1>&6
14225
14226 echo "${as_me:-configure}:14226: testing ...missed $cf_first_lib ..." 1>&5
14227
14228 fi
14229 fi
14230 done
14231 test -n "$verbose" && echo " ...after $cf_add_libs" 1>&6
14232
14233 echo "${as_me:-configure}:14233: testing ...after $cf_add_libs ..." 1>&5
14234
14235 LIBS="$cf_add_libs"
14236
14237 fi
14238
14239 ;;
14240 esac
14241 fi
14242
14243 break
14244 else
14245 cf_pkgconfig_incs=
14246 cf_pkgconfig_libs=
14247 :
14248 fi
14249
14250 done
14251 fi
14252
14253 if test -z "$cf_x_athena_lib" ; then
14254
14255 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "Xext"; then
14256 test -n "$verbose" && echo " found package Xext" 1>&6
14257
14258 echo "${as_me:-configure}:14258: testing found package Xext ..." 1>&5
14259
14260 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "Xext" 2>/dev/null`"
14261 cf_pkgconfig_libs="`$PKG_CONFIG --libs "Xext" 2>/dev/null`"
14262 test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6
14263
14264 echo "${as_me:-configure}:14264: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14265
14266 test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6
14267
14268 echo "${as_me:-configure}:14268: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5
14269
14270 for cf_required in Xext
14271 do
14272 # check for duplicates
14273 for cf_require_pkg in $REQUIRE_PKG
14274 do
14275 if test "$cf_required" = "$cf_require_pkg"
14276 then
14277 cf_required=
14278 break
14279 fi
14280 done
14281 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
14282 done
14283
14284 cf_fix_cppflags=no
14285 cf_new_cflags=
14286 cf_new_cppflags=
14287 cf_new_extra_cppflags=
14288
14289 for cf_add_cflags in $cf_pkgconfig_incs
14290 do
14291 case "$cf_fix_cppflags" in
14292 (no)
14293 case "$cf_add_cflags" in
14294 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14295 case "$cf_add_cflags" in
14296 (-D*)
14297 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14298
14299 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14300 && test -z "${cf_tst_cflags}" \
14301 && cf_fix_cppflags=yes
14302
14303 if test "$cf_fix_cppflags" = yes ; then
14304
14305 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14306 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14307
14308 continue
14309 elif test "${cf_tst_cflags}" = "\"'" ; then
14310
14311 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14312 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14313
14314 continue
14315 fi
14316 ;;
14317 esac
14318 case "$CPPFLAGS" in
14319 (*$cf_add_cflags)
14320 ;;
14321 (*)
14322 case "$cf_add_cflags" in
14323 (-D*)
14324 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14325
14326 CPPFLAGS=`echo "$CPPFLAGS" | \
14327 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14328 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14329
14330 ;;
14331 esac
14332
14333 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14334 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14335
14336 ;;
14337 esac
14338 ;;
14339 (*)
14340
14341 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14342 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14343
14344 ;;
14345 esac
14346 ;;
14347 (yes)
14348
14349 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14350 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14351
14352 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
14353
14354 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14355 && test -z "${cf_tst_cflags}" \
14356 && cf_fix_cppflags=no
14357 ;;
14358 esac
14359 done
14360
14361 if test -n "$cf_new_cflags" ; then
14362
14363 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14364 CFLAGS="${CFLAGS}$cf_new_cflags"
14365
14366 fi
14367
14368 if test -n "$cf_new_cppflags" ; then
14369
14370 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14371 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14372
14373 fi
14374
14375 if test -n "$cf_new_extra_cppflags" ; then
14376
14377 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14378 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14379
14380 fi
14381
14382 cf_add_libs="$LIBS"
14383 # reverse order
14384 cf_add_0lib=
14385 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14386 # filter duplicates
14387 for cf_add_1lib in $cf_add_0lib; do
14388 for cf_add_2lib in $cf_add_libs; do
14389 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14390 cf_add_1lib=
14391 break
14392 fi
14393 done
14394 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14395 done
14396 LIBS="$cf_add_libs"
14397
14398 :
14399 else
14400 cf_pkgconfig_incs=
14401 cf_pkgconfig_libs=
14402
14403 echo "$as_me:14403: checking for XextCreateExtension in -lXext" >&5
14404 echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6
14405 if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then
14406 echo $ECHO_N "(cached) $ECHO_C" >&6
14407 else
14408 ac_check_lib_save_LIBS=$LIBS
14409 LIBS="-lXext $LIBS"
14410 cat >"conftest.$ac_ext" <<_ACEOF
14411 #line 14411 "configure"
14412 #include "confdefs.h"
14413
14414 /* Override any gcc2 internal prototype to avoid an error. */
14415 #ifdef __cplusplus
14416 extern "C"
14417 #endif
14418 /* We use char because int might match the return type of a gcc2
14419 builtin and then its argument prototype would still apply. */
14420 char XextCreateExtension (void);
14421 int
14422 main (void)
14423 {
14424 XextCreateExtension ();
14425 ;
14426 return 0;
14427 }
14428 _ACEOF
14429 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
14430 if { (eval echo "$as_me:14430: \"$ac_link\"") >&5
14431 (eval $ac_link) 2>&5
14432 ac_status=$?
14433 echo "$as_me:14433: \$? = $ac_status" >&5
14434 (exit "$ac_status"); } &&
14435 { ac_try='test -s "conftest$ac_exeext"'
14436 { (eval echo "$as_me:14436: \"$ac_try\"") >&5
14437 (eval $ac_try) 2>&5
14438 ac_status=$?
14439 echo "$as_me:14439: \$? = $ac_status" >&5
14440 (exit "$ac_status"); }; }; then
14441 ac_cv_lib_Xext_XextCreateExtension=yes
14442 else
14443 echo "$as_me: failed program was:" >&5
14444 cat "conftest.$ac_ext" >&5
14445 ac_cv_lib_Xext_XextCreateExtension=no
14446 fi
14447 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
14448 LIBS=$ac_check_lib_save_LIBS
14449 fi
14450 echo "$as_me:14450: result: $ac_cv_lib_Xext_XextCreateExtension" >&5
14451 echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6
14452 if test "$ac_cv_lib_Xext_XextCreateExtension" = yes; then
14453
14454 cf_add_libs="$LIBS"
14455 # reverse order
14456 cf_add_0lib=
14457 for cf_add_1lib in -lXext; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14458 # filter duplicates
14459 for cf_add_1lib in $cf_add_0lib; do
14460 for cf_add_2lib in $cf_add_libs; do
14461 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14462 cf_add_1lib=
14463 break
14464 fi
14465 done
14466 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14467 done
14468 LIBS="$cf_add_libs"
14469
14470 fi
14471
14472 fi
14473
14474 # OSX is schizoid about who owns /usr/X11 (old) versus /opt/X11 (new) (and
14475 # in some cases has installed dummy files in the former, other cases replaced
14476 # it with a link to the new location). This complicates the configure script.
14477 # Check for that pitfall, and recover using pkg-config
14478 #
14479 # If none of these are set, the configuration is almost certainly broken.
14480 if test -z "${X_CFLAGS}${X_PRE_LIBS}${X_LIBS}${X_EXTRA_LIBS}"
14481 then
14482
14483 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "x11"; then
14484 test -n "$verbose" && echo " found package x11" 1>&6
14485
14486 echo "${as_me:-configure}:14486: testing found package x11 ..." 1>&5
14487
14488 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "x11" 2>/dev/null`"
14489 cf_pkgconfig_libs="`$PKG_CONFIG --libs "x11" 2>/dev/null`"
14490 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
14491
14492 echo "${as_me:-configure}:14492: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14493
14494 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
14495
14496 echo "${as_me:-configure}:14496: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
14497
14498 for cf_required in x11
14499 do
14500 # check for duplicates
14501 for cf_require_pkg in $REQUIRE_PKG
14502 do
14503 if test "$cf_required" = "$cf_require_pkg"
14504 then
14505 cf_required=
14506 break
14507 fi
14508 done
14509 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
14510 done
14511
14512 cf_fix_cppflags=no
14513 cf_new_cflags=
14514 cf_new_cppflags=
14515 cf_new_extra_cppflags=
14516
14517 for cf_add_cflags in $cf_pkgconfig_incs
14518 do
14519 case "$cf_fix_cppflags" in
14520 (no)
14521 case "$cf_add_cflags" in
14522 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14523 case "$cf_add_cflags" in
14524 (-D*)
14525 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14526
14527 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14528 && test -z "${cf_tst_cflags}" \
14529 && cf_fix_cppflags=yes
14530
14531 if test "$cf_fix_cppflags" = yes ; then
14532
14533 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14534 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14535
14536 continue
14537 elif test "${cf_tst_cflags}" = "\"'" ; then
14538
14539 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14540 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14541
14542 continue
14543 fi
14544 ;;
14545 esac
14546 case "$CPPFLAGS" in
14547 (*$cf_add_cflags)
14548 ;;
14549 (*)
14550 case "$cf_add_cflags" in
14551 (-D*)
14552 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14553
14554 CPPFLAGS=`echo "$CPPFLAGS" | \
14555 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14556 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14557
14558 ;;
14559 esac
14560
14561 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14562 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14563
14564 ;;
14565 esac
14566 ;;
14567 (*)
14568
14569 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14570 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14571
14572 ;;
14573 esac
14574 ;;
14575 (yes)
14576
14577 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14578 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14579
14580 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
14581
14582 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14583 && test -z "${cf_tst_cflags}" \
14584 && cf_fix_cppflags=no
14585 ;;
14586 esac
14587 done
14588
14589 if test -n "$cf_new_cflags" ; then
14590
14591 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14592 CFLAGS="${CFLAGS}$cf_new_cflags"
14593
14594 fi
14595
14596 if test -n "$cf_new_cppflags" ; then
14597
14598 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14599 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14600
14601 fi
14602
14603 if test -n "$cf_new_extra_cppflags" ; then
14604
14605 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14606 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14607
14608 fi
14609
14610 cf_add_libs="$LIBS"
14611 # reverse order
14612 cf_add_0lib=
14613 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14614 # filter duplicates
14615 for cf_add_1lib in $cf_add_0lib; do
14616 for cf_add_2lib in $cf_add_libs; do
14617 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14618 cf_add_1lib=
14619 break
14620 fi
14621 done
14622 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14623 done
14624 LIBS="$cf_add_libs"
14625
14626 :
14627 else
14628 cf_pkgconfig_incs=
14629 cf_pkgconfig_libs=
14630 { echo "$as_me:14630: WARNING: unable to find X11 library" >&5
14631 echo "$as_me: WARNING: unable to find X11 library" >&2;}
14632 fi
14633
14634 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "ice"; then
14635 test -n "$verbose" && echo " found package ice" 1>&6
14636
14637 echo "${as_me:-configure}:14637: testing found package ice ..." 1>&5
14638
14639 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "ice" 2>/dev/null`"
14640 cf_pkgconfig_libs="`$PKG_CONFIG --libs "ice" 2>/dev/null`"
14641 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
14642
14643 echo "${as_me:-configure}:14643: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14644
14645 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
14646
14647 echo "${as_me:-configure}:14647: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
14648
14649 for cf_required in ice
14650 do
14651 # check for duplicates
14652 for cf_require_pkg in $REQUIRE_PKG
14653 do
14654 if test "$cf_required" = "$cf_require_pkg"
14655 then
14656 cf_required=
14657 break
14658 fi
14659 done
14660 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
14661 done
14662
14663 cf_fix_cppflags=no
14664 cf_new_cflags=
14665 cf_new_cppflags=
14666 cf_new_extra_cppflags=
14667
14668 for cf_add_cflags in $cf_pkgconfig_incs
14669 do
14670 case "$cf_fix_cppflags" in
14671 (no)
14672 case "$cf_add_cflags" in
14673 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14674 case "$cf_add_cflags" in
14675 (-D*)
14676 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14677
14678 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14679 && test -z "${cf_tst_cflags}" \
14680 && cf_fix_cppflags=yes
14681
14682 if test "$cf_fix_cppflags" = yes ; then
14683
14684 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14685 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14686
14687 continue
14688 elif test "${cf_tst_cflags}" = "\"'" ; then
14689
14690 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14691 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14692
14693 continue
14694 fi
14695 ;;
14696 esac
14697 case "$CPPFLAGS" in
14698 (*$cf_add_cflags)
14699 ;;
14700 (*)
14701 case "$cf_add_cflags" in
14702 (-D*)
14703 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14704
14705 CPPFLAGS=`echo "$CPPFLAGS" | \
14706 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14707 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14708
14709 ;;
14710 esac
14711
14712 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14713 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14714
14715 ;;
14716 esac
14717 ;;
14718 (*)
14719
14720 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14721 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14722
14723 ;;
14724 esac
14725 ;;
14726 (yes)
14727
14728 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14729 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14730
14731 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
14732
14733 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14734 && test -z "${cf_tst_cflags}" \
14735 && cf_fix_cppflags=no
14736 ;;
14737 esac
14738 done
14739
14740 if test -n "$cf_new_cflags" ; then
14741
14742 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14743 CFLAGS="${CFLAGS}$cf_new_cflags"
14744
14745 fi
14746
14747 if test -n "$cf_new_cppflags" ; then
14748
14749 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14750 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14751
14752 fi
14753
14754 if test -n "$cf_new_extra_cppflags" ; then
14755
14756 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14757 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14758
14759 fi
14760
14761 cf_add_libs="$LIBS"
14762 # reverse order
14763 cf_add_0lib=
14764 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14765 # filter duplicates
14766 for cf_add_1lib in $cf_add_0lib; do
14767 for cf_add_2lib in $cf_add_libs; do
14768 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14769 cf_add_1lib=
14770 break
14771 fi
14772 done
14773 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14774 done
14775 LIBS="$cf_add_libs"
14776
14777 :
14778 else
14779 cf_pkgconfig_incs=
14780 cf_pkgconfig_libs=
14781 { echo "$as_me:14781: WARNING: unable to find ICE library" >&5
14782 echo "$as_me: WARNING: unable to find ICE library" >&2;}
14783 fi
14784
14785 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "sm"; then
14786 test -n "$verbose" && echo " found package sm" 1>&6
14787
14788 echo "${as_me:-configure}:14788: testing found package sm ..." 1>&5
14789
14790 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "sm" 2>/dev/null`"
14791 cf_pkgconfig_libs="`$PKG_CONFIG --libs "sm" 2>/dev/null`"
14792 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
14793
14794 echo "${as_me:-configure}:14794: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14795
14796 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
14797
14798 echo "${as_me:-configure}:14798: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
14799
14800 for cf_required in sm
14801 do
14802 # check for duplicates
14803 for cf_require_pkg in $REQUIRE_PKG
14804 do
14805 if test "$cf_required" = "$cf_require_pkg"
14806 then
14807 cf_required=
14808 break
14809 fi
14810 done
14811 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
14812 done
14813
14814 cf_fix_cppflags=no
14815 cf_new_cflags=
14816 cf_new_cppflags=
14817 cf_new_extra_cppflags=
14818
14819 for cf_add_cflags in $cf_pkgconfig_incs
14820 do
14821 case "$cf_fix_cppflags" in
14822 (no)
14823 case "$cf_add_cflags" in
14824 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14825 case "$cf_add_cflags" in
14826 (-D*)
14827 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14828
14829 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14830 && test -z "${cf_tst_cflags}" \
14831 && cf_fix_cppflags=yes
14832
14833 if test "$cf_fix_cppflags" = yes ; then
14834
14835 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14836 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14837
14838 continue
14839 elif test "${cf_tst_cflags}" = "\"'" ; then
14840
14841 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14842 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14843
14844 continue
14845 fi
14846 ;;
14847 esac
14848 case "$CPPFLAGS" in
14849 (*$cf_add_cflags)
14850 ;;
14851 (*)
14852 case "$cf_add_cflags" in
14853 (-D*)
14854 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
14855
14856 CPPFLAGS=`echo "$CPPFLAGS" | \
14857 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
14858 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
14859
14860 ;;
14861 esac
14862
14863 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
14864 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
14865
14866 ;;
14867 esac
14868 ;;
14869 (*)
14870
14871 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
14872 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
14873
14874 ;;
14875 esac
14876 ;;
14877 (yes)
14878
14879 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14880 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14881
14882 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
14883
14884 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14885 && test -z "${cf_tst_cflags}" \
14886 && cf_fix_cppflags=no
14887 ;;
14888 esac
14889 done
14890
14891 if test -n "$cf_new_cflags" ; then
14892
14893 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
14894 CFLAGS="${CFLAGS}$cf_new_cflags"
14895
14896 fi
14897
14898 if test -n "$cf_new_cppflags" ; then
14899
14900 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
14901 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
14902
14903 fi
14904
14905 if test -n "$cf_new_extra_cppflags" ; then
14906
14907 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
14908 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
14909
14910 fi
14911
14912 cf_add_libs="$LIBS"
14913 # reverse order
14914 cf_add_0lib=
14915 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
14916 # filter duplicates
14917 for cf_add_1lib in $cf_add_0lib; do
14918 for cf_add_2lib in $cf_add_libs; do
14919 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
14920 cf_add_1lib=
14921 break
14922 fi
14923 done
14924 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
14925 done
14926 LIBS="$cf_add_libs"
14927
14928 :
14929 else
14930 cf_pkgconfig_incs=
14931 cf_pkgconfig_libs=
14932 { echo "$as_me:14932: WARNING: unable to find SM library" >&5
14933 echo "$as_me: WARNING: unable to find SM library" >&2;}
14934 fi
14935
14936 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "xt"; then
14937 test -n "$verbose" && echo " found package xt" 1>&6
14938
14939 echo "${as_me:-configure}:14939: testing found package xt ..." 1>&5
14940
14941 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "xt" 2>/dev/null`"
14942 cf_pkgconfig_libs="`$PKG_CONFIG --libs "xt" 2>/dev/null`"
14943 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
14944
14945 echo "${as_me:-configure}:14945: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
14946
14947 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
14948
14949 echo "${as_me:-configure}:14949: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
14950
14951 for cf_required in xt
14952 do
14953 # check for duplicates
14954 for cf_require_pkg in $REQUIRE_PKG
14955 do
14956 if test "$cf_required" = "$cf_require_pkg"
14957 then
14958 cf_required=
14959 break
14960 fi
14961 done
14962 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
14963 done
14964
14965 cf_fix_cppflags=no
14966 cf_new_cflags=
14967 cf_new_cppflags=
14968 cf_new_extra_cppflags=
14969
14970 for cf_add_cflags in $cf_pkgconfig_incs
14971 do
14972 case "$cf_fix_cppflags" in
14973 (no)
14974 case "$cf_add_cflags" in
14975 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
14976 case "$cf_add_cflags" in
14977 (-D*)
14978 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
14979
14980 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
14981 && test -z "${cf_tst_cflags}" \
14982 && cf_fix_cppflags=yes
14983
14984 if test "$cf_fix_cppflags" = yes ; then
14985
14986 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14987 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14988
14989 continue
14990 elif test "${cf_tst_cflags}" = "\"'" ; then
14991
14992 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
14993 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
14994
14995 continue
14996 fi
14997 ;;
14998 esac
14999 case "$CPPFLAGS" in
15000 (*$cf_add_cflags)
15001 ;;
15002 (*)
15003 case "$cf_add_cflags" in
15004 (-D*)
15005 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15006
15007 CPPFLAGS=`echo "$CPPFLAGS" | \
15008 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15009 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15010
15011 ;;
15012 esac
15013
15014 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15015 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15016
15017 ;;
15018 esac
15019 ;;
15020 (*)
15021
15022 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15023 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15024
15025 ;;
15026 esac
15027 ;;
15028 (yes)
15029
15030 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15031 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15032
15033 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
15034
15035 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15036 && test -z "${cf_tst_cflags}" \
15037 && cf_fix_cppflags=no
15038 ;;
15039 esac
15040 done
15041
15042 if test -n "$cf_new_cflags" ; then
15043
15044 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15045 CFLAGS="${CFLAGS}$cf_new_cflags"
15046
15047 fi
15048
15049 if test -n "$cf_new_cppflags" ; then
15050
15051 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15052 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15053
15054 fi
15055
15056 if test -n "$cf_new_extra_cppflags" ; then
15057
15058 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15059 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15060
15061 fi
15062
15063 cf_add_libs="$LIBS"
15064 # reverse order
15065 cf_add_0lib=
15066 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15067 # filter duplicates
15068 for cf_add_1lib in $cf_add_0lib; do
15069 for cf_add_2lib in $cf_add_libs; do
15070 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15071 cf_add_1lib=
15072 break
15073 fi
15074 done
15075 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15076 done
15077 LIBS="$cf_add_libs"
15078
15079 :
15080 else
15081 cf_pkgconfig_incs=
15082 cf_pkgconfig_libs=
15083 { echo "$as_me:15083: WARNING: unable to find Xt library" >&5
15084 echo "$as_me: WARNING: unable to find Xt library" >&2;}
15085 fi
15086
15087 else
15088 LIBS="$X_PRE_LIBS $LIBS $X_EXTRA_LIBS"
15089 fi
15090
15091 cf_have_X_LIBS=no
15092
15093 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "xt"; then
15094 test -n "$verbose" && echo " found package xt" 1>&6
15095
15096 echo "${as_me:-configure}:15096: testing found package xt ..." 1>&5
15097
15098 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "xt" 2>/dev/null`"
15099 cf_pkgconfig_libs="`$PKG_CONFIG --libs "xt" 2>/dev/null`"
15100 test -n "$verbose" && echo " package xt CFLAGS: $cf_pkgconfig_incs" 1>&6
15101
15102 echo "${as_me:-configure}:15102: testing package xt CFLAGS: $cf_pkgconfig_incs ..." 1>&5
15103
15104 test -n "$verbose" && echo " package xt LIBS: $cf_pkgconfig_libs" 1>&6
15105
15106 echo "${as_me:-configure}:15106: testing package xt LIBS: $cf_pkgconfig_libs ..." 1>&5
15107
15108 for cf_required in xt
15109 do
15110 # check for duplicates
15111 for cf_require_pkg in $REQUIRE_PKG
15112 do
15113 if test "$cf_required" = "$cf_require_pkg"
15114 then
15115 cf_required=
15116 break
15117 fi
15118 done
15119 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
15120 done
15121
15122 cf_fix_cppflags=no
15123 cf_new_cflags=
15124 cf_new_cppflags=
15125 cf_new_extra_cppflags=
15126
15127 for cf_add_cflags in $cf_pkgconfig_incs
15128 do
15129 case "$cf_fix_cppflags" in
15130 (no)
15131 case "$cf_add_cflags" in
15132 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15133 case "$cf_add_cflags" in
15134 (-D*)
15135 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15136
15137 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15138 && test -z "${cf_tst_cflags}" \
15139 && cf_fix_cppflags=yes
15140
15141 if test "$cf_fix_cppflags" = yes ; then
15142
15143 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15144 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15145
15146 continue
15147 elif test "${cf_tst_cflags}" = "\"'" ; then
15148
15149 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15150 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15151
15152 continue
15153 fi
15154 ;;
15155 esac
15156 case "$CPPFLAGS" in
15157 (*$cf_add_cflags)
15158 ;;
15159 (*)
15160 case "$cf_add_cflags" in
15161 (-D*)
15162 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15163
15164 CPPFLAGS=`echo "$CPPFLAGS" | \
15165 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15166 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15167
15168 ;;
15169 esac
15170
15171 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15172 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15173
15174 ;;
15175 esac
15176 ;;
15177 (*)
15178
15179 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15180 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15181
15182 ;;
15183 esac
15184 ;;
15185 (yes)
15186
15187 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15188 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15189
15190 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
15191
15192 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15193 && test -z "${cf_tst_cflags}" \
15194 && cf_fix_cppflags=no
15195 ;;
15196 esac
15197 done
15198
15199 if test -n "$cf_new_cflags" ; then
15200
15201 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15202 CFLAGS="${CFLAGS}$cf_new_cflags"
15203
15204 fi
15205
15206 if test -n "$cf_new_cppflags" ; then
15207
15208 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15209 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15210
15211 fi
15212
15213 if test -n "$cf_new_extra_cppflags" ; then
15214
15215 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15216 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15217
15218 fi
15219
15220 cf_add_libs="$LIBS"
15221 # reverse order
15222 cf_add_0lib=
15223 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15224 # filter duplicates
15225 for cf_add_1lib in $cf_add_0lib; do
15226 for cf_add_2lib in $cf_add_libs; do
15227 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15228 cf_add_1lib=
15229 break
15230 fi
15231 done
15232 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15233 done
15234 LIBS="$cf_add_libs"
15235
15236 case "x$LIBS" in
15237 (*-lX11*)
15238 ;;
15239 (*)
15240 # we have an "xt" package, but it may omit Xt's dependency on X11
15241 echo "$as_me:15241: checking for usable X dependency" >&5
15242 echo $ECHO_N "checking for usable X dependency... $ECHO_C" >&6
15243 if test "${cf_cv_xt_x11_compat+set}" = set; then
15244 echo $ECHO_N "(cached) $ECHO_C" >&6
15245 else
15246
15247 cat >"conftest.$ac_ext" <<_ACEOF
15248 #line 15248 "configure"
15249 #include "confdefs.h"
15250
15251 $ac_includes_default
15252 #include <X11/Xlib.h>
15253
15254 int
15255 main (void)
15256 {
15257
15258 int rc1 = XDrawLine((Display*) 0, (Drawable) 0, (GC) 0, 0, 0, 0, 0);
15259 int rc2 = XClearWindow((Display*) 0, (Window) 0);
15260 int rc3 = XMoveWindow((Display*) 0, (Window) 0, 0, 0);
15261 int rc4 = XMoveResizeWindow((Display*)0, (Window)0, 0, 0, 0, 0);
15262
15263 ;
15264 return 0;
15265 }
15266 _ACEOF
15267 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
15268 if { (eval echo "$as_me:15268: \"$ac_link\"") >&5
15269 (eval $ac_link) 2>&5
15270 ac_status=$?
15271 echo "$as_me:15271: \$? = $ac_status" >&5
15272 (exit "$ac_status"); } &&
15273 { ac_try='test -s "conftest$ac_exeext"'
15274 { (eval echo "$as_me:15274: \"$ac_try\"") >&5
15275 (eval $ac_try) 2>&5
15276 ac_status=$?
15277 echo "$as_me:15277: \$? = $ac_status" >&5
15278 (exit "$ac_status"); }; }; then
15279 cf_cv_xt_x11_compat=yes
15280 else
15281 echo "$as_me: failed program was:" >&5
15282 cat "conftest.$ac_ext" >&5
15283 cf_cv_xt_x11_compat=no
15284 fi
15285 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
15286 fi
15287 echo "$as_me:15287: result: $cf_cv_xt_x11_compat" >&5
15288 echo "${ECHO_T}$cf_cv_xt_x11_compat" >&6
15289 if test "$cf_cv_xt_x11_compat" = no
15290 then
15291 test -n "$verbose" && echo " work around broken X11 dependency" 1>&6
15292
15293 echo "${as_me:-configure}:15293: testing work around broken X11 dependency ..." 1>&5
15294
15295 # 2010/11/19 - good enough until a working Xt on Xcb is delivered.
15296
15297 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "x11"; then
15298 test -n "$verbose" && echo " found package x11" 1>&6
15299
15300 echo "${as_me:-configure}:15300: testing found package x11 ..." 1>&5
15301
15302 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "x11" 2>/dev/null`"
15303 cf_pkgconfig_libs="`$PKG_CONFIG --libs "x11" 2>/dev/null`"
15304 test -n "$verbose" && echo " package x11 CFLAGS: $cf_pkgconfig_incs" 1>&6
15305
15306 echo "${as_me:-configure}:15306: testing package x11 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
15307
15308 test -n "$verbose" && echo " package x11 LIBS: $cf_pkgconfig_libs" 1>&6
15309
15310 echo "${as_me:-configure}:15310: testing package x11 LIBS: $cf_pkgconfig_libs ..." 1>&5
15311
15312 for cf_required in x11
15313 do
15314 # check for duplicates
15315 for cf_require_pkg in $REQUIRE_PKG
15316 do
15317 if test "$cf_required" = "$cf_require_pkg"
15318 then
15319 cf_required=
15320 break
15321 fi
15322 done
15323 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
15324 done
15325
15326 cf_fix_cppflags=no
15327 cf_new_cflags=
15328 cf_new_cppflags=
15329 cf_new_extra_cppflags=
15330
15331 for cf_add_cflags in $cf_pkgconfig_incs
15332 do
15333 case "$cf_fix_cppflags" in
15334 (no)
15335 case "$cf_add_cflags" in
15336 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15337 case "$cf_add_cflags" in
15338 (-D*)
15339 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15340
15341 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15342 && test -z "${cf_tst_cflags}" \
15343 && cf_fix_cppflags=yes
15344
15345 if test "$cf_fix_cppflags" = yes ; then
15346
15347 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15348 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15349
15350 continue
15351 elif test "${cf_tst_cflags}" = "\"'" ; then
15352
15353 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15354 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15355
15356 continue
15357 fi
15358 ;;
15359 esac
15360 case "$CPPFLAGS" in
15361 (*$cf_add_cflags)
15362 ;;
15363 (*)
15364 case "$cf_add_cflags" in
15365 (-D*)
15366 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15367
15368 CPPFLAGS=`echo "$CPPFLAGS" | \
15369 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15370 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15371
15372 ;;
15373 esac
15374
15375 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15376 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15377
15378 ;;
15379 esac
15380 ;;
15381 (*)
15382
15383 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15384 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15385
15386 ;;
15387 esac
15388 ;;
15389 (yes)
15390
15391 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15392 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15393
15394 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
15395
15396 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15397 && test -z "${cf_tst_cflags}" \
15398 && cf_fix_cppflags=no
15399 ;;
15400 esac
15401 done
15402
15403 if test -n "$cf_new_cflags" ; then
15404
15405 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15406 CFLAGS="${CFLAGS}$cf_new_cflags"
15407
15408 fi
15409
15410 if test -n "$cf_new_cppflags" ; then
15411
15412 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15413 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15414
15415 fi
15416
15417 if test -n "$cf_new_extra_cppflags" ; then
15418
15419 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15420 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15421
15422 fi
15423
15424 cf_add_libs="$LIBS"
15425 # reverse order
15426 cf_add_0lib=
15427 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15428 # filter duplicates
15429 for cf_add_1lib in $cf_add_0lib; do
15430 for cf_add_2lib in $cf_add_libs; do
15431 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15432 cf_add_1lib=
15433 break
15434 fi
15435 done
15436 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15437 done
15438 LIBS="$cf_add_libs"
15439
15440 :
15441 else
15442 cf_pkgconfig_incs=
15443 cf_pkgconfig_libs=
15444
15445 cf_add_libs="$LIBS"
15446 test -n "$verbose" && echo " ...before $cf_add_libs" 1>&6
15447
15448 echo "${as_me:-configure}:15448: testing ...before $cf_add_libs ..." 1>&5
15449
15450 for cf_add_1lib in -lX11; do
15451 # filter duplicates
15452 cf_found_2lib=no
15453 for cf_add_2lib in $cf_add_libs; do
15454 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15455 cf_found_2lib=yes
15456 break
15457 fi
15458 done
15459 # if not a duplicate, find the dependent library
15460 if test "$cf_found_2lib" = no
15461 then
15462 cf_found_2lib=no
15463 cf_add_2libs=
15464 for cf_add_2lib in $cf_add_libs
15465 do
15466 test -n "$cf_add_2libs" && cf_add_2libs="$cf_add_2libs "
15467 cf_add_2libs="$cf_add_2libs$cf_add_2lib"
15468 if test "x$cf_add_2lib" = "x-lXt"
15469 then
15470 cf_found_2lib=yes
15471 cf_add_2libs="$cf_add_2libs $cf_add_1lib"
15472 fi
15473 done
15474 if test "$cf_found_2lib" = yes
15475 then
15476 cf_add_libs="$cf_add_2libs"
15477 else
15478 test -n "$verbose" && echo " ...missed -lXt" 1>&6
15479
15480 echo "${as_me:-configure}:15480: testing ...missed -lXt ..." 1>&5
15481
15482 fi
15483 fi
15484 done
15485 test -n "$verbose" && echo " ...after $cf_add_libs" 1>&6
15486
15487 echo "${as_me:-configure}:15487: testing ...after $cf_add_libs ..." 1>&5
15488
15489 LIBS="$cf_add_libs"
15490
15491 fi
15492
15493 fi
15494 ;;
15495 esac
15496
15497 echo "$as_me:15497: checking for usable X Toolkit package" >&5
15498 echo $ECHO_N "checking for usable X Toolkit package... $ECHO_C" >&6
15499 if test "${cf_cv_xt_ice_compat+set}" = set; then
15500 echo $ECHO_N "(cached) $ECHO_C" >&6
15501 else
15502
15503 cat >"conftest.$ac_ext" <<_ACEOF
15504 #line 15504 "configure"
15505 #include "confdefs.h"
15506
15507 $ac_includes_default
15508 #include <X11/Shell.h>
15509
15510 int
15511 main (void)
15512 {
15513 int num = IceConnectionNumber(NULL); (void) num
15514
15515 ;
15516 return 0;
15517 }
15518 _ACEOF
15519 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
15520 if { (eval echo "$as_me:15520: \"$ac_link\"") >&5
15521 (eval $ac_link) 2>&5
15522 ac_status=$?
15523 echo "$as_me:15523: \$? = $ac_status" >&5
15524 (exit "$ac_status"); } &&
15525 { ac_try='test -s "conftest$ac_exeext"'
15526 { (eval echo "$as_me:15526: \"$ac_try\"") >&5
15527 (eval $ac_try) 2>&5
15528 ac_status=$?
15529 echo "$as_me:15529: \$? = $ac_status" >&5
15530 (exit "$ac_status"); }; }; then
15531 cf_cv_xt_ice_compat=yes
15532 else
15533 echo "$as_me: failed program was:" >&5
15534 cat "conftest.$ac_ext" >&5
15535 cf_cv_xt_ice_compat=no
15536 fi
15537 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
15538 fi
15539 echo "$as_me:15539: result: $cf_cv_xt_ice_compat" >&5
15540 echo "${ECHO_T}$cf_cv_xt_ice_compat" >&6
15541
15542 if test "$cf_cv_xt_ice_compat" = no
15543 then
15544 # workaround for broken ".pc" files used for X Toolkit.
15545 case "x$X_PRE_LIBS" in
15546 (*-lICE*)
15547 case "x$LIBS" in
15548 (*-lICE*)
15549 ;;
15550 (*)
15551 test -n "$verbose" && echo " work around broken ICE dependency" 1>&6
15552
15553 echo "${as_me:-configure}:15553: testing work around broken ICE dependency ..." 1>&5
15554
15555 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "ice"; then
15556 test -n "$verbose" && echo " found package ice" 1>&6
15557
15558 echo "${as_me:-configure}:15558: testing found package ice ..." 1>&5
15559
15560 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "ice" 2>/dev/null`"
15561 cf_pkgconfig_libs="`$PKG_CONFIG --libs "ice" 2>/dev/null`"
15562 test -n "$verbose" && echo " package ice CFLAGS: $cf_pkgconfig_incs" 1>&6
15563
15564 echo "${as_me:-configure}:15564: testing package ice CFLAGS: $cf_pkgconfig_incs ..." 1>&5
15565
15566 test -n "$verbose" && echo " package ice LIBS: $cf_pkgconfig_libs" 1>&6
15567
15568 echo "${as_me:-configure}:15568: testing package ice LIBS: $cf_pkgconfig_libs ..." 1>&5
15569
15570 for cf_required in ice
15571 do
15572 # check for duplicates
15573 for cf_require_pkg in $REQUIRE_PKG
15574 do
15575 if test "$cf_required" = "$cf_require_pkg"
15576 then
15577 cf_required=
15578 break
15579 fi
15580 done
15581 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
15582 done
15583
15584 cf_fix_cppflags=no
15585 cf_new_cflags=
15586 cf_new_cppflags=
15587 cf_new_extra_cppflags=
15588
15589 for cf_add_cflags in $cf_pkgconfig_incs
15590 do
15591 case "$cf_fix_cppflags" in
15592 (no)
15593 case "$cf_add_cflags" in
15594 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15595 case "$cf_add_cflags" in
15596 (-D*)
15597 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15598
15599 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15600 && test -z "${cf_tst_cflags}" \
15601 && cf_fix_cppflags=yes
15602
15603 if test "$cf_fix_cppflags" = yes ; then
15604
15605 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15606 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15607
15608 continue
15609 elif test "${cf_tst_cflags}" = "\"'" ; then
15610
15611 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15612 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15613
15614 continue
15615 fi
15616 ;;
15617 esac
15618 case "$CPPFLAGS" in
15619 (*$cf_add_cflags)
15620 ;;
15621 (*)
15622 case "$cf_add_cflags" in
15623 (-D*)
15624 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15625
15626 CPPFLAGS=`echo "$CPPFLAGS" | \
15627 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15628 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15629
15630 ;;
15631 esac
15632
15633 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15634 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15635
15636 ;;
15637 esac
15638 ;;
15639 (*)
15640
15641 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15642 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15643
15644 ;;
15645 esac
15646 ;;
15647 (yes)
15648
15649 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15650 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15651
15652 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
15653
15654 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15655 && test -z "${cf_tst_cflags}" \
15656 && cf_fix_cppflags=no
15657 ;;
15658 esac
15659 done
15660
15661 if test -n "$cf_new_cflags" ; then
15662
15663 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15664 CFLAGS="${CFLAGS}$cf_new_cflags"
15665
15666 fi
15667
15668 if test -n "$cf_new_cppflags" ; then
15669
15670 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15671 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15672
15673 fi
15674
15675 if test -n "$cf_new_extra_cppflags" ; then
15676
15677 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15678 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15679
15680 fi
15681
15682 cf_add_libs="$LIBS"
15683 # reverse order
15684 cf_add_0lib=
15685 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15686 # filter duplicates
15687 for cf_add_1lib in $cf_add_0lib; do
15688 for cf_add_2lib in $cf_add_libs; do
15689 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15690 cf_add_1lib=
15691 break
15692 fi
15693 done
15694 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15695 done
15696 LIBS="$cf_add_libs"
15697
15698 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "sm"; then
15699 test -n "$verbose" && echo " found package sm" 1>&6
15700
15701 echo "${as_me:-configure}:15701: testing found package sm ..." 1>&5
15702
15703 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "sm" 2>/dev/null`"
15704 cf_pkgconfig_libs="`$PKG_CONFIG --libs "sm" 2>/dev/null`"
15705 test -n "$verbose" && echo " package sm CFLAGS: $cf_pkgconfig_incs" 1>&6
15706
15707 echo "${as_me:-configure}:15707: testing package sm CFLAGS: $cf_pkgconfig_incs ..." 1>&5
15708
15709 test -n "$verbose" && echo " package sm LIBS: $cf_pkgconfig_libs" 1>&6
15710
15711 echo "${as_me:-configure}:15711: testing package sm LIBS: $cf_pkgconfig_libs ..." 1>&5
15712
15713 for cf_required in sm
15714 do
15715 # check for duplicates
15716 for cf_require_pkg in $REQUIRE_PKG
15717 do
15718 if test "$cf_required" = "$cf_require_pkg"
15719 then
15720 cf_required=
15721 break
15722 fi
15723 done
15724 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
15725 done
15726
15727 cf_fix_cppflags=no
15728 cf_new_cflags=
15729 cf_new_cppflags=
15730 cf_new_extra_cppflags=
15731
15732 for cf_add_cflags in $cf_pkgconfig_incs
15733 do
15734 case "$cf_fix_cppflags" in
15735 (no)
15736 case "$cf_add_cflags" in
15737 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15738 case "$cf_add_cflags" in
15739 (-D*)
15740 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15741
15742 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15743 && test -z "${cf_tst_cflags}" \
15744 && cf_fix_cppflags=yes
15745
15746 if test "$cf_fix_cppflags" = yes ; then
15747
15748 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15749 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15750
15751 continue
15752 elif test "${cf_tst_cflags}" = "\"'" ; then
15753
15754 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15755 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15756
15757 continue
15758 fi
15759 ;;
15760 esac
15761 case "$CPPFLAGS" in
15762 (*$cf_add_cflags)
15763 ;;
15764 (*)
15765 case "$cf_add_cflags" in
15766 (-D*)
15767 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15768
15769 CPPFLAGS=`echo "$CPPFLAGS" | \
15770 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15771 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15772
15773 ;;
15774 esac
15775
15776 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15777 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15778
15779 ;;
15780 esac
15781 ;;
15782 (*)
15783
15784 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15785 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15786
15787 ;;
15788 esac
15789 ;;
15790 (yes)
15791
15792 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15793 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15794
15795 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
15796
15797 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15798 && test -z "${cf_tst_cflags}" \
15799 && cf_fix_cppflags=no
15800 ;;
15801 esac
15802 done
15803
15804 if test -n "$cf_new_cflags" ; then
15805
15806 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
15807 CFLAGS="${CFLAGS}$cf_new_cflags"
15808
15809 fi
15810
15811 if test -n "$cf_new_cppflags" ; then
15812
15813 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
15814 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
15815
15816 fi
15817
15818 if test -n "$cf_new_extra_cppflags" ; then
15819
15820 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
15821 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
15822
15823 fi
15824
15825 cf_add_libs="$LIBS"
15826 # reverse order
15827 cf_add_0lib=
15828 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
15829 # filter duplicates
15830 for cf_add_1lib in $cf_add_0lib; do
15831 for cf_add_2lib in $cf_add_libs; do
15832 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15833 cf_add_1lib=
15834 break
15835 fi
15836 done
15837 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
15838 done
15839 LIBS="$cf_add_libs"
15840
15841 :
15842 else
15843 cf_pkgconfig_incs=
15844 cf_pkgconfig_libs=
15845 :
15846 fi
15847
15848 else
15849 cf_pkgconfig_incs=
15850 cf_pkgconfig_libs=
15851
15852 cf_add_libs="$LIBS"
15853 test -n "$verbose" && echo " ...before $cf_add_libs" 1>&6
15854
15855 echo "${as_me:-configure}:15855: testing ...before $cf_add_libs ..." 1>&5
15856
15857 for cf_add_1lib in $X_PRE_LIBS; do
15858 # filter duplicates
15859 cf_found_2lib=no
15860 for cf_add_2lib in $cf_add_libs; do
15861 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
15862 cf_found_2lib=yes
15863 break
15864 fi
15865 done
15866 # if not a duplicate, find the dependent library
15867 if test "$cf_found_2lib" = no
15868 then
15869 cf_found_2lib=no
15870 cf_add_2libs=
15871 for cf_add_2lib in $cf_add_libs
15872 do
15873 test -n "$cf_add_2libs" && cf_add_2libs="$cf_add_2libs "
15874 cf_add_2libs="$cf_add_2libs$cf_add_2lib"
15875 if test "x$cf_add_2lib" = "x-lXt"
15876 then
15877 cf_found_2lib=yes
15878 cf_add_2libs="$cf_add_2libs $cf_add_1lib"
15879 fi
15880 done
15881 if test "$cf_found_2lib" = yes
15882 then
15883 cf_add_libs="$cf_add_2libs"
15884 else
15885 test -n "$verbose" && echo " ...missed -lXt" 1>&6
15886
15887 echo "${as_me:-configure}:15887: testing ...missed -lXt ..." 1>&5
15888
15889 fi
15890 fi
15891 done
15892 test -n "$verbose" && echo " ...after $cf_add_libs" 1>&6
15893
15894 echo "${as_me:-configure}:15894: testing ...after $cf_add_libs ..." 1>&5
15895
15896 LIBS="$cf_add_libs"
15897
15898 fi
15899
15900 ;;
15901 esac
15902 ;;
15903 esac
15904 fi
15905
15906 cf_have_X_LIBS=yes
15907
15908 else
15909 cf_pkgconfig_incs=
15910 cf_pkgconfig_libs=
15911
15912 LDFLAGS="$X_LIBS $LDFLAGS"
15913
15914 test -n "$verbose" && echo " checking additions to CFLAGS" 1>&6
15915
15916 echo "${as_me:-configure}:15916: testing checking additions to CFLAGS ..." 1>&5
15917
15918 cf_check_cflags="$CFLAGS"
15919 cf_check_cppflags="$CPPFLAGS"
15920
15921 cf_fix_cppflags=no
15922 cf_new_cflags=
15923 cf_new_cppflags=
15924 cf_new_extra_cppflags=
15925
15926 for cf_add_cflags in $X_CFLAGS
15927 do
15928 case "$cf_fix_cppflags" in
15929 (no)
15930 case "$cf_add_cflags" in
15931 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
15932 case "$cf_add_cflags" in
15933 (-D*)
15934 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
15935
15936 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15937 && test -z "${cf_tst_cflags}" \
15938 && cf_fix_cppflags=yes
15939
15940 if test "$cf_fix_cppflags" = yes ; then
15941
15942 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15943 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15944
15945 continue
15946 elif test "${cf_tst_cflags}" = "\"'" ; then
15947
15948 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15949 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15950
15951 continue
15952 fi
15953 ;;
15954 esac
15955 case "$CPPFLAGS" in
15956 (*$cf_add_cflags)
15957 ;;
15958 (*)
15959 case "$cf_add_cflags" in
15960 (-D*)
15961 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
15962
15963 CPPFLAGS=`echo "$CPPFLAGS" | \
15964 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
15965 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
15966
15967 ;;
15968 esac
15969
15970 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
15971 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
15972
15973 ;;
15974 esac
15975 ;;
15976 (*)
15977
15978 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
15979 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
15980
15981 ;;
15982 esac
15983 ;;
15984 (yes)
15985
15986 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
15987 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
15988
15989 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
15990
15991 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
15992 && test -z "${cf_tst_cflags}" \
15993 && cf_fix_cppflags=no
15994 ;;
15995 esac
15996 done
15997
15998 if test -n "$cf_new_cflags" ; then
15999 test -n "$verbose" && echo " add to \$CFLAGS $cf_new_cflags" 1>&6
16000
16001 echo "${as_me:-configure}:16001: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
16002
16003 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
16004 CFLAGS="${CFLAGS}$cf_new_cflags"
16005
16006 fi
16007
16008 if test -n "$cf_new_cppflags" ; then
16009 test -n "$verbose" && echo " add to \$CPPFLAGS $cf_new_cppflags" 1>&6
16010
16011 echo "${as_me:-configure}:16011: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
16012
16013 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
16014 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
16015
16016 fi
16017
16018 if test -n "$cf_new_extra_cppflags" ; then
16019 test -n "$verbose" && echo " add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
16020
16021 echo "${as_me:-configure}:16021: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
16022
16023 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
16024 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
16025
16026 fi
16027
16028 if test "x$cf_check_cflags" != "x$CFLAGS" ; then
16029 cat >"conftest.$ac_ext" <<_ACEOF
16030 #line 16030 "configure"
16031 #include "confdefs.h"
16032 #include <stdio.h>
16033 int
16034 main (void)
16035 {
16036 printf("Hello world");
16037 ;
16038 return 0;
16039 }
16040 _ACEOF
16041 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
16042 if { (eval echo "$as_me:16042: \"$ac_link\"") >&5
16043 (eval $ac_link) 2>&5
16044 ac_status=$?
16045 echo "$as_me:16045: \$? = $ac_status" >&5
16046 (exit "$ac_status"); } &&
16047 { ac_try='test -s "conftest$ac_exeext"'
16048 { (eval echo "$as_me:16048: \"$ac_try\"") >&5
16049 (eval $ac_try) 2>&5
16050 ac_status=$?
16051 echo "$as_me:16051: \$? = $ac_status" >&5
16052 (exit "$ac_status"); }; }; then
16053 :
16054 else
16055 echo "$as_me: failed program was:" >&5
16056 cat "conftest.$ac_ext" >&5
16057 test -n "$verbose" && echo " test-compile failed. Undoing change to \$CFLAGS" 1>&6
16058
16059 echo "${as_me:-configure}:16059: testing test-compile failed. Undoing change to \$CFLAGS ..." 1>&5
16060
16061 if test "x$cf_check_cppflags" != "x$CPPFLAGS" ; then
16062 test -n "$verbose" && echo " but keeping change to \$CPPFLAGS" 1>&6
16063
16064 echo "${as_me:-configure}:16064: testing but keeping change to \$CPPFLAGS ..." 1>&5
16065
16066 fi
16067 CFLAGS="$cf_check_cflags"
16068 fi
16069 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
16070 fi
16071
16072 echo "$as_me:16072: checking for XOpenDisplay" >&5
16073 echo $ECHO_N "checking for XOpenDisplay... $ECHO_C" >&6
16074 if test "${ac_cv_func_XOpenDisplay+set}" = set; then
16075 echo $ECHO_N "(cached) $ECHO_C" >&6
16076 else
16077 cat >"conftest.$ac_ext" <<_ACEOF
16078 #line 16078 "configure"
16079 #include "confdefs.h"
16080 #define XOpenDisplay autoconf_temporary
16081 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
16082 #undef XOpenDisplay
16083
16084 #ifdef __cplusplus
16085 extern "C"
16086 #endif
16087
16088 /* We use char because int might match the return type of a gcc2
16089 builtin and then its argument prototype would still apply. */
16090 char XOpenDisplay (void);
16091
16092 int
16093 main (void)
16094 {
16095
16096 /* The GNU C library defines stubs for functions which it implements
16097 to always fail with ENOSYS. Some functions are actually named
16098 something starting with __ and the normal name is an alias. */
16099 #if defined (__stub_XOpenDisplay) || defined (__stub___XOpenDisplay)
16100 #error found stub for XOpenDisplay
16101 #endif
16102
16103 return XOpenDisplay ();
16104 ;
16105 return 0;
16106 }
16107 _ACEOF
16108 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
16109 if { (eval echo "$as_me:16109: \"$ac_link\"") >&5
16110 (eval $ac_link) 2>&5
16111 ac_status=$?
16112 echo "$as_me:16112: \$? = $ac_status" >&5
16113 (exit "$ac_status"); } &&
16114 { ac_try='test -s "conftest$ac_exeext"'
16115 { (eval echo "$as_me:16115: \"$ac_try\"") >&5
16116 (eval $ac_try) 2>&5
16117 ac_status=$?
16118 echo "$as_me:16118: \$? = $ac_status" >&5
16119 (exit "$ac_status"); }; }; then
16120 ac_cv_func_XOpenDisplay=yes
16121 else
16122 echo "$as_me: failed program was:" >&5
16123 cat "conftest.$ac_ext" >&5
16124 ac_cv_func_XOpenDisplay=no
16125 fi
16126 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
16127 fi
16128 echo "$as_me:16128: result: $ac_cv_func_XOpenDisplay" >&5
16129 echo "${ECHO_T}$ac_cv_func_XOpenDisplay" >&6
16130 if test "$ac_cv_func_XOpenDisplay" = yes; then
16131 :
16132 else
16133
16134 echo "$as_me:16134: checking for XOpenDisplay in -lX11" >&5
16135 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
16136 if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
16137 echo $ECHO_N "(cached) $ECHO_C" >&6
16138 else
16139 ac_check_lib_save_LIBS=$LIBS
16140 LIBS="-lX11 $LIBS"
16141 cat >"conftest.$ac_ext" <<_ACEOF
16142 #line 16142 "configure"
16143 #include "confdefs.h"
16144
16145 /* Override any gcc2 internal prototype to avoid an error. */
16146 #ifdef __cplusplus
16147 extern "C"
16148 #endif
16149 /* We use char because int might match the return type of a gcc2
16150 builtin and then its argument prototype would still apply. */
16151 char XOpenDisplay (void);
16152 int
16153 main (void)
16154 {
16155 XOpenDisplay ();
16156 ;
16157 return 0;
16158 }
16159 _ACEOF
16160 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
16161 if { (eval echo "$as_me:16161: \"$ac_link\"") >&5
16162 (eval $ac_link) 2>&5
16163 ac_status=$?
16164 echo "$as_me:16164: \$? = $ac_status" >&5
16165 (exit "$ac_status"); } &&
16166 { ac_try='test -s "conftest$ac_exeext"'
16167 { (eval echo "$as_me:16167: \"$ac_try\"") >&5
16168 (eval $ac_try) 2>&5
16169 ac_status=$?
16170 echo "$as_me:16170: \$? = $ac_status" >&5
16171 (exit "$ac_status"); }; }; then
16172 ac_cv_lib_X11_XOpenDisplay=yes
16173 else
16174 echo "$as_me: failed program was:" >&5
16175 cat "conftest.$ac_ext" >&5
16176 ac_cv_lib_X11_XOpenDisplay=no
16177 fi
16178 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
16179 LIBS=$ac_check_lib_save_LIBS
16180 fi
16181 echo "$as_me:16181: result: $ac_cv_lib_X11_XOpenDisplay" >&5
16182 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
16183 if test "$ac_cv_lib_X11_XOpenDisplay" = yes; then
16184
16185 cf_add_libs="$LIBS"
16186 # reverse order
16187 cf_add_0lib=
16188 for cf_add_1lib in -lX11; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
16189 # filter duplicates
16190 for cf_add_1lib in $cf_add_0lib; do
16191 for cf_add_2lib in $cf_add_libs; do
16192 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16193 cf_add_1lib=
16194 break
16195 fi
16196 done
16197 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16198 done
16199 LIBS="$cf_add_libs"
16200
16201 fi
16202
16203 fi
16204
16205 echo "$as_me:16205: checking for XtAppInitialize" >&5
16206 echo $ECHO_N "checking for XtAppInitialize... $ECHO_C" >&6
16207 if test "${ac_cv_func_XtAppInitialize+set}" = set; then
16208 echo $ECHO_N "(cached) $ECHO_C" >&6
16209 else
16210 cat >"conftest.$ac_ext" <<_ACEOF
16211 #line 16211 "configure"
16212 #include "confdefs.h"
16213 #define XtAppInitialize autoconf_temporary
16214 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
16215 #undef XtAppInitialize
16216
16217 #ifdef __cplusplus
16218 extern "C"
16219 #endif
16220
16221 /* We use char because int might match the return type of a gcc2
16222 builtin and then its argument prototype would still apply. */
16223 char XtAppInitialize (void);
16224
16225 int
16226 main (void)
16227 {
16228
16229 /* The GNU C library defines stubs for functions which it implements
16230 to always fail with ENOSYS. Some functions are actually named
16231 something starting with __ and the normal name is an alias. */
16232 #if defined (__stub_XtAppInitialize) || defined (__stub___XtAppInitialize)
16233 #error found stub for XtAppInitialize
16234 #endif
16235
16236 return XtAppInitialize ();
16237 ;
16238 return 0;
16239 }
16240 _ACEOF
16241 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
16242 if { (eval echo "$as_me:16242: \"$ac_link\"") >&5
16243 (eval $ac_link) 2>&5
16244 ac_status=$?
16245 echo "$as_me:16245: \$? = $ac_status" >&5
16246 (exit "$ac_status"); } &&
16247 { ac_try='test -s "conftest$ac_exeext"'
16248 { (eval echo "$as_me:16248: \"$ac_try\"") >&5
16249 (eval $ac_try) 2>&5
16250 ac_status=$?
16251 echo "$as_me:16251: \$? = $ac_status" >&5
16252 (exit "$ac_status"); }; }; then
16253 ac_cv_func_XtAppInitialize=yes
16254 else
16255 echo "$as_me: failed program was:" >&5
16256 cat "conftest.$ac_ext" >&5
16257 ac_cv_func_XtAppInitialize=no
16258 fi
16259 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
16260 fi
16261 echo "$as_me:16261: result: $ac_cv_func_XtAppInitialize" >&5
16262 echo "${ECHO_T}$ac_cv_func_XtAppInitialize" >&6
16263 if test "$ac_cv_func_XtAppInitialize" = yes; then
16264 :
16265 else
16266
16267 echo "$as_me:16267: checking for XtAppInitialize in -lXt" >&5
16268 echo $ECHO_N "checking for XtAppInitialize in -lXt... $ECHO_C" >&6
16269 if test "${ac_cv_lib_Xt_XtAppInitialize+set}" = set; then
16270 echo $ECHO_N "(cached) $ECHO_C" >&6
16271 else
16272 ac_check_lib_save_LIBS=$LIBS
16273 LIBS="-lXt $LIBS"
16274 cat >"conftest.$ac_ext" <<_ACEOF
16275 #line 16275 "configure"
16276 #include "confdefs.h"
16277
16278 /* Override any gcc2 internal prototype to avoid an error. */
16279 #ifdef __cplusplus
16280 extern "C"
16281 #endif
16282 /* We use char because int might match the return type of a gcc2
16283 builtin and then its argument prototype would still apply. */
16284 char XtAppInitialize (void);
16285 int
16286 main (void)
16287 {
16288 XtAppInitialize ();
16289 ;
16290 return 0;
16291 }
16292 _ACEOF
16293 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
16294 if { (eval echo "$as_me:16294: \"$ac_link\"") >&5
16295 (eval $ac_link) 2>&5
16296 ac_status=$?
16297 echo "$as_me:16297: \$? = $ac_status" >&5
16298 (exit "$ac_status"); } &&
16299 { ac_try='test -s "conftest$ac_exeext"'
16300 { (eval echo "$as_me:16300: \"$ac_try\"") >&5
16301 (eval $ac_try) 2>&5
16302 ac_status=$?
16303 echo "$as_me:16303: \$? = $ac_status" >&5
16304 (exit "$ac_status"); }; }; then
16305 ac_cv_lib_Xt_XtAppInitialize=yes
16306 else
16307 echo "$as_me: failed program was:" >&5
16308 cat "conftest.$ac_ext" >&5
16309 ac_cv_lib_Xt_XtAppInitialize=no
16310 fi
16311 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
16312 LIBS=$ac_check_lib_save_LIBS
16313 fi
16314 echo "$as_me:16314: result: $ac_cv_lib_Xt_XtAppInitialize" >&5
16315 echo "${ECHO_T}$ac_cv_lib_Xt_XtAppInitialize" >&6
16316 if test "$ac_cv_lib_Xt_XtAppInitialize" = yes; then
16317
16318 cat >>confdefs.h <<\EOF
16319 #define HAVE_LIBXT 1
16320 EOF
16321
16322 cf_have_X_LIBS=Xt
16323 LIBS="-lXt $LIBS"
16324 fi
16325
16326 fi
16327
16328 fi
16329
16330 if test "$cf_have_X_LIBS" = no ; then
16331 { echo "$as_me:16331: WARNING: Unable to successfully link X Toolkit library (-lXt) with
16332 test program. You will have to check and add the proper libraries by hand
16333 to makefile." >&5
16334 echo "$as_me: WARNING: Unable to successfully link X Toolkit library (-lXt) with
16335 test program. You will have to check and add the proper libraries by hand
16336 to makefile." >&2;}
16337 fi
16338
16339 cf_x_athena_root=$cf_x_athena
16340 cf_x_athena_inc=""
16341
16342 for cf_path in default \
16343 /usr/contrib/X11R6 \
16344 /usr/contrib/X11R5 \
16345 /usr/lib/X11R5 \
16346 /usr/local
16347 do
16348 if test -z "$cf_x_athena_inc" ; then
16349
16350 cf_save_LIBS_CF_X_ATHENA_CPPFLAGS="$LIBS"
16351 cf_save_CFLAGS_CF_X_ATHENA_CPPFLAGS="$CFLAGS"
16352 cf_save_CPPFLAGS_CF_X_ATHENA_CPPFLAGS="$CPPFLAGS"
16353 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
16354 for cf_X_CFLAGS in $X_CFLAGS
16355 do
16356 case "x$cf_X_CFLAGS" in
16357 x-[IUD]*)
16358 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
16359 ;;
16360 *)
16361 CFLAGS="$CFLAGS $cf_X_CFLAGS"
16362 ;;
16363 esac
16364 done
16365
16366 cf_test=X11/$cf_x_athena_root/SimpleMenu.h
16367 if test "$cf_path" != default ; then
16368
16369 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
16370 CPPFLAGS="${CPPFLAGS}-I$cf_path/include"
16371
16372 echo "$as_me:16372: checking for $cf_test in $cf_path" >&5
16373 echo $ECHO_N "checking for $cf_test in $cf_path... $ECHO_C" >&6
16374 else
16375 echo "$as_me:16375: checking for $cf_test" >&5
16376 echo $ECHO_N "checking for $cf_test... $ECHO_C" >&6
16377 fi
16378 cat >"conftest.$ac_ext" <<_ACEOF
16379 #line 16379 "configure"
16380 #include "confdefs.h"
16381
16382 #include <X11/Intrinsic.h>
16383 #include <$cf_test>
16384 int
16385 main (void)
16386 {
16387
16388 ;
16389 return 0;
16390 }
16391 _ACEOF
16392 rm -f "conftest.$ac_objext"
16393 if { (eval echo "$as_me:16393: \"$ac_compile\"") >&5
16394 (eval $ac_compile) 2>&5
16395 ac_status=$?
16396 echo "$as_me:16396: \$? = $ac_status" >&5
16397 (exit "$ac_status"); } &&
16398 { ac_try='test -s "conftest.$ac_objext"'
16399 { (eval echo "$as_me:16399: \"$ac_try\"") >&5
16400 (eval $ac_try) 2>&5
16401 ac_status=$?
16402 echo "$as_me:16402: \$? = $ac_status" >&5
16403 (exit "$ac_status"); }; }; then
16404 cf_result=yes
16405 else
16406 echo "$as_me: failed program was:" >&5
16407 cat "conftest.$ac_ext" >&5
16408 cf_result=no
16409 fi
16410 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16411 echo "$as_me:16411: result: $cf_result" >&5
16412 echo "${ECHO_T}$cf_result" >&6
16413
16414 LIBS="$cf_save_LIBS_CF_X_ATHENA_CPPFLAGS"
16415 CFLAGS="$cf_save_CFLAGS_CF_X_ATHENA_CPPFLAGS"
16416 CPPFLAGS="$cf_save_CPPFLAGS_CF_X_ATHENA_CPPFLAGS"
16417
16418 if test "$cf_result" = yes ; then
16419 test "$cf_path" = default && cf_x_athena_inc=default
16420 test "$cf_path" != default && cf_x_athena_inc="$cf_path/include"
16421 break
16422 fi
16423 fi
16424 done
16425
16426 if test -z "$cf_x_athena_inc" ; then
16427 { echo "$as_me:16427: WARNING: Unable to find Athena header files" >&5
16428 echo "$as_me: WARNING: Unable to find Athena header files" >&2;}
16429 elif test "$cf_x_athena_inc" != default ; then
16430
16431 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
16432 CPPFLAGS="${CPPFLAGS}-I$cf_x_athena_inc"
16433
16434 fi
16435
16436 cf_x_athena_root=$cf_x_athena
16437 cf_x_athena_lib=""
16438
16439 for cf_path in default \
16440 /usr/contrib/X11R6 \
16441 /usr/contrib/X11R5 \
16442 /usr/lib/X11R5 \
16443 /usr/local
16444 do
16445 for cf_lib in \
16446 ${cf_x_athena_root} \
16447 ${cf_x_athena_root}7 \
16448 ${cf_x_athena_root}6
16449 do
16450 for cf_libs in \
16451 "-l$cf_lib -lXmu" \
16452 "-l$cf_lib -lXpm -lXmu" \
16453 "-l${cf_lib}_s -lXmu_s"
16454 do
16455 test -n "$cf_x_athena_lib" && break
16456
16457 cf_save_LIBS_CF_X_ATHENA_LIBS="$LIBS"
16458 cf_save_CFLAGS_CF_X_ATHENA_LIBS="$CFLAGS"
16459 cf_save_CPPFLAGS_CF_X_ATHENA_LIBS="$CPPFLAGS"
16460 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
16461 for cf_X_CFLAGS in $X_CFLAGS
16462 do
16463 case "x$cf_X_CFLAGS" in
16464 x-[IUD]*)
16465 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
16466 ;;
16467 *)
16468 CFLAGS="$CFLAGS $cf_X_CFLAGS"
16469 ;;
16470 esac
16471 done
16472
16473 cf_test=XawSimpleMenuAddGlobalActions
16474 test "$cf_path" != default && cf_libs="-L$cf_path/lib $cf_libs"
16475
16476 cf_add_libs="$LIBS"
16477 # reverse order
16478 cf_add_0lib=
16479 for cf_add_1lib in $cf_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
16480 # filter duplicates
16481 for cf_add_1lib in $cf_add_0lib; do
16482 for cf_add_2lib in $cf_add_libs; do
16483 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16484 cf_add_1lib=
16485 break
16486 fi
16487 done
16488 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16489 done
16490 LIBS="$cf_add_libs"
16491
16492 echo "$as_me:16492: checking for $cf_test in $cf_libs" >&5
16493 echo $ECHO_N "checking for $cf_test in $cf_libs... $ECHO_C" >&6
16494 cat >"conftest.$ac_ext" <<_ACEOF
16495 #line 16495 "configure"
16496 #include "confdefs.h"
16497
16498 $ac_includes_default
16499 #include <X11/Intrinsic.h>
16500 #include <X11/$cf_x_athena_root/SimpleMenu.h>
16501
16502 int
16503 main (void)
16504 {
16505
16506 $cf_test((XtAppContext) 0)
16507 ;
16508 return 0;
16509 }
16510 _ACEOF
16511 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
16512 if { (eval echo "$as_me:16512: \"$ac_link\"") >&5
16513 (eval $ac_link) 2>&5
16514 ac_status=$?
16515 echo "$as_me:16515: \$? = $ac_status" >&5
16516 (exit "$ac_status"); } &&
16517 { ac_try='test -s "conftest$ac_exeext"'
16518 { (eval echo "$as_me:16518: \"$ac_try\"") >&5
16519 (eval $ac_try) 2>&5
16520 ac_status=$?
16521 echo "$as_me:16521: \$? = $ac_status" >&5
16522 (exit "$ac_status"); }; }; then
16523 cf_result=yes
16524 else
16525 echo "$as_me: failed program was:" >&5
16526 cat "conftest.$ac_ext" >&5
16527 cf_result=no
16528 fi
16529 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
16530 echo "$as_me:16530: result: $cf_result" >&5
16531 echo "${ECHO_T}$cf_result" >&6
16532
16533 LIBS="$cf_save_LIBS_CF_X_ATHENA_LIBS"
16534 CFLAGS="$cf_save_CFLAGS_CF_X_ATHENA_LIBS"
16535 CPPFLAGS="$cf_save_CPPFLAGS_CF_X_ATHENA_LIBS"
16536
16537 if test "$cf_result" = yes ; then
16538 cf_x_athena_lib="$cf_libs"
16539 break
16540 fi
16541 done # cf_libs
16542 test -n "$cf_x_athena_lib" && break
16543 done # cf_lib
16544 done
16545
16546 if test -z "$cf_x_athena_lib" ; then
16547 { { echo "$as_me:16547: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&5
16548 echo "$as_me: error: Unable to successfully link Athena library (-l$cf_x_athena_root) with test program" >&2;}
16549 { (exit 1); exit 1; }; }
16550 fi
16551
16552 cf_add_libs="$LIBS"
16553 # reverse order
16554 cf_add_0lib=
16555 for cf_add_1lib in $cf_x_athena_lib; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
16556 # filter duplicates
16557 for cf_add_1lib in $cf_add_0lib; do
16558 for cf_add_2lib in $cf_add_libs; do
16559 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
16560 cf_add_1lib=
16561 break
16562 fi
16563 done
16564 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
16565 done
16566 LIBS="$cf_add_libs"
16567
16568 cf_x_athena_LIBS=`echo "HAVE_LIB_$cf_x_athena" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
16569
16570 cat >>confdefs.h <<EOF
16571 #define $cf_x_athena_LIBS 1
16572 EOF
16573
16574 fi
16575
16576 for ac_header in X11/Xpoll.h
16577 do
16578 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
16579 echo "$as_me:16579: checking for $ac_header" >&5
16580 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
16581 if eval "test \"\${$as_ac_Header+set}\" = set"; then
16582 echo $ECHO_N "(cached) $ECHO_C" >&6
16583 else
16584 cat >"conftest.$ac_ext" <<_ACEOF
16585 #line 16585 "configure"
16586 #include "confdefs.h"
16587 #include <$ac_header>
16588 _ACEOF
16589 if { (eval echo "$as_me:16589: \"$ac_cpp "conftest.$ac_ext"\"") >&5
16590 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
16591 ac_status=$?
16592 $EGREP -v '^ *\+' conftest.er1 >conftest.err
16593 rm -f conftest.er1
16594 cat conftest.err >&5
16595 echo "$as_me:16595: \$? = $ac_status" >&5
16596 (exit "$ac_status"); } >/dev/null; then
16597 if test -s conftest.err; then
16598 ac_cpp_err=$ac_c_preproc_warn_flag
16599 else
16600 ac_cpp_err=
16601 fi
16602 else
16603 ac_cpp_err=yes
16604 fi
16605 if test -z "$ac_cpp_err"; then
16606 eval "$as_ac_Header=yes"
16607 else
16608 echo "$as_me: failed program was:" >&5
16609 cat "conftest.$ac_ext" >&5
16610 eval "$as_ac_Header=no"
16611 fi
16612 rm -f conftest.err "conftest.$ac_ext"
16613 fi
16614 echo "$as_me:16614: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
16615 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
16616 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
16617 cat >>confdefs.h <<EOF
16618 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16619 EOF
16620
16621 fi
16622 done
16623
16624 echo "$as_me:16624: checking for declaration of fd_set" >&5
16625 echo $ECHO_N "checking for declaration of fd_set... $ECHO_C" >&6
16626 if test "${cf_cv_type_fd_set+set}" = set; then
16627 echo $ECHO_N "(cached) $ECHO_C" >&6
16628 else
16629
16630 echo "${as_me:-configure}:16630: testing sys/types alone ..." 1>&5
16631
16632 cat >"conftest.$ac_ext" <<_ACEOF
16633 #line 16633 "configure"
16634 #include "confdefs.h"
16635
16636 #include <sys/types.h>
16637 int
16638 main (void)
16639 {
16640 fd_set x; (void)x
16641 ;
16642 return 0;
16643 }
16644 _ACEOF
16645 rm -f "conftest.$ac_objext"
16646 if { (eval echo "$as_me:16646: \"$ac_compile\"") >&5
16647 (eval $ac_compile) 2>&5
16648 ac_status=$?
16649 echo "$as_me:16649: \$? = $ac_status" >&5
16650 (exit "$ac_status"); } &&
16651 { ac_try='test -s "conftest.$ac_objext"'
16652 { (eval echo "$as_me:16652: \"$ac_try\"") >&5
16653 (eval $ac_try) 2>&5
16654 ac_status=$?
16655 echo "$as_me:16655: \$? = $ac_status" >&5
16656 (exit "$ac_status"); }; }; then
16657 cf_cv_type_fd_set=sys/types.h
16658 else
16659 echo "$as_me: failed program was:" >&5
16660 cat "conftest.$ac_ext" >&5
16661
16662 echo "${as_me:-configure}:16662: testing X11/Xpoll.h ..." 1>&5
16663
16664 cat >"conftest.$ac_ext" <<_ACEOF
16665 #line 16665 "configure"
16666 #include "confdefs.h"
16667
16668 #ifdef HAVE_X11_XPOLL_H
16669 #include <X11/Xpoll.h>
16670 #endif
16671 int
16672 main (void)
16673 {
16674 fd_set x; (void)x
16675 ;
16676 return 0;
16677 }
16678 _ACEOF
16679 rm -f "conftest.$ac_objext"
16680 if { (eval echo "$as_me:16680: \"$ac_compile\"") >&5
16681 (eval $ac_compile) 2>&5
16682 ac_status=$?
16683 echo "$as_me:16683: \$? = $ac_status" >&5
16684 (exit "$ac_status"); } &&
16685 { ac_try='test -s "conftest.$ac_objext"'
16686 { (eval echo "$as_me:16686: \"$ac_try\"") >&5
16687 (eval $ac_try) 2>&5
16688 ac_status=$?
16689 echo "$as_me:16689: \$? = $ac_status" >&5
16690 (exit "$ac_status"); }; }; then
16691 cf_cv_type_fd_set=X11/Xpoll.h
16692 else
16693 echo "$as_me: failed program was:" >&5
16694 cat "conftest.$ac_ext" >&5
16695
16696 echo "${as_me:-configure}:16696: testing sys/select.h ..." 1>&5
16697
16698 cat >"conftest.$ac_ext" <<_ACEOF
16699 #line 16699 "configure"
16700 #include "confdefs.h"
16701
16702 #include <sys/types.h>
16703 #include <sys/select.h>
16704 int
16705 main (void)
16706 {
16707 fd_set x; (void)x
16708 ;
16709 return 0;
16710 }
16711 _ACEOF
16712 rm -f "conftest.$ac_objext"
16713 if { (eval echo "$as_me:16713: \"$ac_compile\"") >&5
16714 (eval $ac_compile) 2>&5
16715 ac_status=$?
16716 echo "$as_me:16716: \$? = $ac_status" >&5
16717 (exit "$ac_status"); } &&
16718 { ac_try='test -s "conftest.$ac_objext"'
16719 { (eval echo "$as_me:16719: \"$ac_try\"") >&5
16720 (eval $ac_try) 2>&5
16721 ac_status=$?
16722 echo "$as_me:16722: \$? = $ac_status" >&5
16723 (exit "$ac_status"); }; }; then
16724 cf_cv_type_fd_set=sys/select.h
16725 else
16726 echo "$as_me: failed program was:" >&5
16727 cat "conftest.$ac_ext" >&5
16728 cf_cv_type_fd_set=unknown
16729 fi
16730 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16731 fi
16732 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16733 fi
16734 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16735 fi
16736 echo "$as_me:16736: result: $cf_cv_type_fd_set" >&5
16737 echo "${ECHO_T}$cf_cv_type_fd_set" >&6
16738 if test $cf_cv_type_fd_set = sys/select.h ; then
16739
16740 cat >>confdefs.h <<\EOF
16741 #define USE_SYS_SELECT_H 1
16742 EOF
16743
16744 fi
16745
16746 echo "$as_me:16746: checking for declaration of fd_mask" >&5
16747 echo $ECHO_N "checking for declaration of fd_mask... $ECHO_C" >&6
16748 if test "${cf_cv_type_fd_mask+set}" = set; then
16749 echo $ECHO_N "(cached) $ECHO_C" >&6
16750 else
16751
16752 if test x$cf_cv_type_fd_set = xX11/Xpoll.h ; then
16753 cat >"conftest.$ac_ext" <<_ACEOF
16754 #line 16754 "configure"
16755 #include "confdefs.h"
16756
16757 #include <X11/Xpoll.h>
16758 int
16759 main (void)
16760 {
16761 fd_mask x
16762 ;
16763 return 0;
16764 }
16765 _ACEOF
16766 rm -f "conftest.$ac_objext"
16767 if { (eval echo "$as_me:16767: \"$ac_compile\"") >&5
16768 (eval $ac_compile) 2>&5
16769 ac_status=$?
16770 echo "$as_me:16770: \$? = $ac_status" >&5
16771 (exit "$ac_status"); } &&
16772 { ac_try='test -s "conftest.$ac_objext"'
16773 { (eval echo "$as_me:16773: \"$ac_try\"") >&5
16774 (eval $ac_try) 2>&5
16775 ac_status=$?
16776 echo "$as_me:16776: \$? = $ac_status" >&5
16777 (exit "$ac_status"); }; }; then
16778 :
16779 else
16780 echo "$as_me: failed program was:" >&5
16781 cat "conftest.$ac_ext" >&5
16782
16783 echo "${as_me:-configure}:16783: testing if we must define CSRG_BASED ..." 1>&5
16784
16785 # Xosdefs.h on Mac OS X may not define this (but it should).
16786 cat >"conftest.$ac_ext" <<_ACEOF
16787 #line 16787 "configure"
16788 #include "confdefs.h"
16789
16790 #define CSRG_BASED
16791 #include <X11/Xpoll.h>
16792 int
16793 main (void)
16794 {
16795 fd_mask x
16796 ;
16797 return 0;
16798 }
16799 _ACEOF
16800 rm -f "conftest.$ac_objext"
16801 if { (eval echo "$as_me:16801: \"$ac_compile\"") >&5
16802 (eval $ac_compile) 2>&5
16803 ac_status=$?
16804 echo "$as_me:16804: \$? = $ac_status" >&5
16805 (exit "$ac_status"); } &&
16806 { ac_try='test -s "conftest.$ac_objext"'
16807 { (eval echo "$as_me:16807: \"$ac_try\"") >&5
16808 (eval $ac_try) 2>&5
16809 ac_status=$?
16810 echo "$as_me:16810: \$? = $ac_status" >&5
16811 (exit "$ac_status"); }; }; then
16812 cf_cv_type_fd_mask=CSRG_BASED
16813 else
16814 echo "$as_me: failed program was:" >&5
16815 cat "conftest.$ac_ext" >&5
16816 fi
16817 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16818 fi
16819 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16820 else
16821 cf_cv_type_fd_mask=$cf_cv_type_fd_set
16822 fi
16823
16824 fi
16825 echo "$as_me:16825: result: $cf_cv_type_fd_mask" >&5
16826 echo "${ECHO_T}$cf_cv_type_fd_mask" >&6
16827 if test x$cf_cv_type_fd_mask = xCSRG_BASED ; then
16828
16829 cat >>confdefs.h <<\EOF
16830 #define CSRG_BASED 1
16831 EOF
16832
16833 fi
16834
16835 echo "$as_me:16835: checking for IRIX 6.5 baud-rate redefinitions" >&5
16836 echo $ECHO_N "checking for IRIX 6.5 baud-rate redefinitions... $ECHO_C" >&6
16837 if test "${cf_cv_termio_c_ispeed+set}" = set; then
16838 echo $ECHO_N "(cached) $ECHO_C" >&6
16839 else
16840
16841 cat >"conftest.$ac_ext" <<_ACEOF
16842 #line 16842 "configure"
16843 #include "confdefs.h"
16844
16845 #include <sys/types.h>
16846 #include <sys/termio.h>
16847 int
16848 main (void)
16849 {
16850
16851 struct termio foo;
16852 foo.c_ispeed = B38400;
16853 foo.c_ospeed = B9600;
16854 (void)foo;
16855
16856 ;
16857 return 0;
16858 }
16859 _ACEOF
16860 rm -f "conftest.$ac_objext"
16861 if { (eval echo "$as_me:16861: \"$ac_compile\"") >&5
16862 (eval $ac_compile) 2>&5
16863 ac_status=$?
16864 echo "$as_me:16864: \$? = $ac_status" >&5
16865 (exit "$ac_status"); } &&
16866 { ac_try='test -s "conftest.$ac_objext"'
16867 { (eval echo "$as_me:16867: \"$ac_try\"") >&5
16868 (eval $ac_try) 2>&5
16869 ac_status=$?
16870 echo "$as_me:16870: \$? = $ac_status" >&5
16871 (exit "$ac_status"); }; }; then
16872 cf_cv_termio_c_ispeed=yes
16873
16874 else
16875 echo "$as_me: failed program was:" >&5
16876 cat "conftest.$ac_ext" >&5
16877 cf_cv_termio_c_ispeed=no
16878 fi
16879 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16880
16881 fi
16882 echo "$as_me:16882: result: $cf_cv_termio_c_ispeed" >&5
16883 echo "${ECHO_T}$cf_cv_termio_c_ispeed" >&6
16884 test "$cf_cv_termio_c_ispeed" = yes &&
16885 cat >>confdefs.h <<\EOF
16886 #define HAVE_TERMIO_C_ISPEED 1
16887 EOF
16888
16889 echo "$as_me:16889: checking for termios type tcflag_t" >&5
16890 echo $ECHO_N "checking for termios type tcflag_t... $ECHO_C" >&6
16891 if test "${cf_cv_havetype_tcflag_t+set}" = set; then
16892 echo $ECHO_N "(cached) $ECHO_C" >&6
16893 else
16894
16895 cat >"conftest.$ac_ext" <<_ACEOF
16896 #line 16896 "configure"
16897 #include "confdefs.h"
16898 #include <termios.h>
16899 int
16900 main (void)
16901 {
16902
16903 tcflag_t x = 0; (void)x
16904 ;
16905 return 0;
16906 }
16907 _ACEOF
16908 rm -f "conftest.$ac_objext"
16909 if { (eval echo "$as_me:16909: \"$ac_compile\"") >&5
16910 (eval $ac_compile) 2>&5
16911 ac_status=$?
16912 echo "$as_me:16912: \$? = $ac_status" >&5
16913 (exit "$ac_status"); } &&
16914 { ac_try='test -s "conftest.$ac_objext"'
16915 { (eval echo "$as_me:16915: \"$ac_try\"") >&5
16916 (eval $ac_try) 2>&5
16917 ac_status=$?
16918 echo "$as_me:16918: \$? = $ac_status" >&5
16919 (exit "$ac_status"); }; }; then
16920 cf_cv_havetype_tcflag_t=yes
16921 else
16922 echo "$as_me: failed program was:" >&5
16923 cat "conftest.$ac_ext" >&5
16924 cf_cv_havetype_tcflag_t=no
16925 fi
16926 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16927
16928 fi
16929 echo "$as_me:16929: result: $cf_cv_havetype_tcflag_t" >&5
16930 echo "${ECHO_T}$cf_cv_havetype_tcflag_t" >&6
16931 test "$cf_cv_havetype_tcflag_t" = no &&
16932 cat >>confdefs.h <<\EOF
16933 #define tcflag_t unsigned long
16934 EOF
16935
16936 echo "$as_me:16936: checking for termios type speed_t" >&5
16937 echo $ECHO_N "checking for termios type speed_t... $ECHO_C" >&6
16938 if test "${cf_cv_havetype_speed_t+set}" = set; then
16939 echo $ECHO_N "(cached) $ECHO_C" >&6
16940 else
16941
16942 cat >"conftest.$ac_ext" <<_ACEOF
16943 #line 16943 "configure"
16944 #include "confdefs.h"
16945 #include <termios.h>
16946 int
16947 main (void)
16948 {
16949
16950 speed_t x = 0; (void)x
16951 ;
16952 return 0;
16953 }
16954 _ACEOF
16955 rm -f "conftest.$ac_objext"
16956 if { (eval echo "$as_me:16956: \"$ac_compile\"") >&5
16957 (eval $ac_compile) 2>&5
16958 ac_status=$?
16959 echo "$as_me:16959: \$? = $ac_status" >&5
16960 (exit "$ac_status"); } &&
16961 { ac_try='test -s "conftest.$ac_objext"'
16962 { (eval echo "$as_me:16962: \"$ac_try\"") >&5
16963 (eval $ac_try) 2>&5
16964 ac_status=$?
16965 echo "$as_me:16965: \$? = $ac_status" >&5
16966 (exit "$ac_status"); }; }; then
16967 cf_cv_havetype_speed_t=yes
16968 else
16969 echo "$as_me: failed program was:" >&5
16970 cat "conftest.$ac_ext" >&5
16971 cf_cv_havetype_speed_t=no
16972 fi
16973 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
16974
16975 fi
16976 echo "$as_me:16976: result: $cf_cv_havetype_speed_t" >&5
16977 echo "${ECHO_T}$cf_cv_havetype_speed_t" >&6
16978 test "$cf_cv_havetype_speed_t" = no &&
16979 cat >>confdefs.h <<\EOF
16980 #define speed_t unsigned short
16981 EOF
16982
16983 echo "$as_me:16983: checking for termios type cc_t" >&5
16984 echo $ECHO_N "checking for termios type cc_t... $ECHO_C" >&6
16985 if test "${cf_cv_havetype_cc_t+set}" = set; then
16986 echo $ECHO_N "(cached) $ECHO_C" >&6
16987 else
16988
16989 cat >"conftest.$ac_ext" <<_ACEOF
16990 #line 16990 "configure"
16991 #include "confdefs.h"
16992 #include <termios.h>
16993 int
16994 main (void)
16995 {
16996
16997 cc_t x = 0; (void)x
16998 ;
16999 return 0;
17000 }
17001 _ACEOF
17002 rm -f "conftest.$ac_objext"
17003 if { (eval echo "$as_me:17003: \"$ac_compile\"") >&5
17004 (eval $ac_compile) 2>&5
17005 ac_status=$?
17006 echo "$as_me:17006: \$? = $ac_status" >&5
17007 (exit "$ac_status"); } &&
17008 { ac_try='test -s "conftest.$ac_objext"'
17009 { (eval echo "$as_me:17009: \"$ac_try\"") >&5
17010 (eval $ac_try) 2>&5
17011 ac_status=$?
17012 echo "$as_me:17012: \$? = $ac_status" >&5
17013 (exit "$ac_status"); }; }; then
17014 cf_cv_havetype_cc_t=yes
17015 else
17016 echo "$as_me: failed program was:" >&5
17017 cat "conftest.$ac_ext" >&5
17018 cf_cv_havetype_cc_t=no
17019 fi
17020 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
17021
17022 fi
17023 echo "$as_me:17023: result: $cf_cv_havetype_cc_t" >&5
17024 echo "${ECHO_T}$cf_cv_havetype_cc_t" >&6
17025 test "$cf_cv_havetype_cc_t" = no &&
17026 cat >>confdefs.h <<\EOF
17027 #define cc_t unsigned char
17028 EOF
17029
17030 # The Xcursor library is normally (weakly) linked via the X11 library rather
17031 # than directly to applications. xterm can select a cursor theme; users can
17032 # also use environment variables to select cursor size. We would only notice
17033 # the library if there are development files for it. Provide a way to disable
17034 # the feature if it is unwanted.
17035 echo "$as_me:17035: checking if we expect to use the Xcursor library" >&5
17036 echo $ECHO_N "checking if we expect to use the Xcursor library... $ECHO_C" >&6
17037
17038 # Check whether --enable-xcursor or --disable-xcursor was given.
17039 if test "${enable_xcursor+set}" = set; then
17040 enableval="$enable_xcursor"
17041 test "$enableval" != no && enableval=yes
17042 if test "$enableval" != "yes" ; then
17043 enable_xcursor=no
17044 else
17045 enable_xcursor=yes
17046 fi
17047 else
17048 enableval=yes
17049 enable_xcursor=yes
17050
17051 fi;
17052 echo "$as_me:17052: result: $enable_xcursor" >&5
17053 echo "${ECHO_T}$enable_xcursor" >&6
17054 if test "$enable_xcursor" = yes; then
17055
17056 cat >>confdefs.h <<\EOF
17057 #define HAVE_LIB_XCURSOR 1
17058 EOF
17059
17060 fi
17061
17062 LIBS="$LIBS $X_EXTRA_LIBS"
17063
17064 for ac_header in \
17065 stropts.h \
17066
17067 do
17068 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17069 echo "$as_me:17069: checking for $ac_header" >&5
17070 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17071 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17072 echo $ECHO_N "(cached) $ECHO_C" >&6
17073 else
17074 cat >"conftest.$ac_ext" <<_ACEOF
17075 #line 17075 "configure"
17076 #include "confdefs.h"
17077 #include <$ac_header>
17078 _ACEOF
17079 if { (eval echo "$as_me:17079: \"$ac_cpp "conftest.$ac_ext"\"") >&5
17080 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
17081 ac_status=$?
17082 $EGREP -v '^ *\+' conftest.er1 >conftest.err
17083 rm -f conftest.er1
17084 cat conftest.err >&5
17085 echo "$as_me:17085: \$? = $ac_status" >&5
17086 (exit "$ac_status"); } >/dev/null; then
17087 if test -s conftest.err; then
17088 ac_cpp_err=$ac_c_preproc_warn_flag
17089 else
17090 ac_cpp_err=
17091 fi
17092 else
17093 ac_cpp_err=yes
17094 fi
17095 if test -z "$ac_cpp_err"; then
17096 eval "$as_ac_Header=yes"
17097 else
17098 echo "$as_me: failed program was:" >&5
17099 cat "conftest.$ac_ext" >&5
17100 eval "$as_ac_Header=no"
17101 fi
17102 rm -f conftest.err "conftest.$ac_ext"
17103 fi
17104 echo "$as_me:17104: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
17105 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
17106 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
17107 cat >>confdefs.h <<EOF
17108 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17109 EOF
17110
17111 fi
17112 done
17113
17114 cf_func_grantpt="grantpt ptsname"
17115 cf_prefer_openpt=no
17116 case $host_os in
17117 (darwin[0-9].*)
17118 ;;
17119 (openbsd[0-9].*)
17120 # The POSIX entrypoints exist, but have never worked.
17121 ;;
17122 (linux*)
17123 cf_func_grantpt="$cf_func_grantpt posix_openpt"
17124 cf_prefer_openpt=yes
17125 ;;
17126 (*)
17127 cf_func_grantpt="$cf_func_grantpt posix_openpt"
17128 ;;
17129 esac
17130
17131 for ac_func in $cf_func_grantpt
17132 do
17133 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17134 echo "$as_me:17134: checking for $ac_func" >&5
17135 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17136 if eval "test \"\${$as_ac_var+set}\" = set"; then
17137 echo $ECHO_N "(cached) $ECHO_C" >&6
17138 else
17139 cat >"conftest.$ac_ext" <<_ACEOF
17140 #line 17140 "configure"
17141 #include "confdefs.h"
17142 #define $ac_func autoconf_temporary
17143 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
17144 #undef $ac_func
17145
17146 #ifdef __cplusplus
17147 extern "C"
17148 #endif
17149
17150 /* We use char because int might match the return type of a gcc2
17151 builtin and then its argument prototype would still apply. */
17152 char $ac_func (void);
17153
17154 int
17155 main (void)
17156 {
17157
17158 /* The GNU C library defines stubs for functions which it implements
17159 to always fail with ENOSYS. Some functions are actually named
17160 something starting with __ and the normal name is an alias. */
17161 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
17162 #error found stub for $ac_func
17163 #endif
17164
17165 return $ac_func ();
17166 ;
17167 return 0;
17168 }
17169 _ACEOF
17170 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
17171 if { (eval echo "$as_me:17171: \"$ac_link\"") >&5
17172 (eval $ac_link) 2>&5
17173 ac_status=$?
17174 echo "$as_me:17174: \$? = $ac_status" >&5
17175 (exit "$ac_status"); } &&
17176 { ac_try='test -s "conftest$ac_exeext"'
17177 { (eval echo "$as_me:17177: \"$ac_try\"") >&5
17178 (eval $ac_try) 2>&5
17179 ac_status=$?
17180 echo "$as_me:17180: \$? = $ac_status" >&5
17181 (exit "$ac_status"); }; }; then
17182 eval "$as_ac_var=yes"
17183 else
17184 echo "$as_me: failed program was:" >&5
17185 cat "conftest.$ac_ext" >&5
17186 eval "$as_ac_var=no"
17187 fi
17188 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
17189 fi
17190 echo "$as_me:17190: result: `eval echo '${'"$as_ac_var"'}'`" >&5
17191 echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
17192 if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
17193 cat >>confdefs.h <<EOF
17194 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17195 EOF
17196
17197 fi
17198 done
17199
17200 cf_grantpt_opts=
17201 if test "x$ac_cv_func_grantpt" = "xyes" ; then
17202 echo "$as_me:17202: checking if grantpt really works" >&5
17203 echo $ECHO_N "checking if grantpt really works... $ECHO_C" >&6
17204 cat >"conftest.$ac_ext" <<_ACEOF
17205 #line 17205 "configure"
17206 #include "confdefs.h"
17207
17208 #include <stdlib.h>
17209 #include <stdio.h>
17210 #include <termios.h>
17211 #include <unistd.h>
17212 #include <signal.h>
17213 #include <fcntl.h>
17214 #include <errno.h>
17215
17216 #ifndef HAVE_POSIX_OPENPT
17217 #undef posix_openpt
17218 #define posix_openpt(mode) open("/dev/ptmx", mode)
17219 #endif
17220
17221 #ifdef HAVE_STROPTS_H
17222 #include <stropts.h>
17223 #endif
17224
17225 static void failed(int code)
17226 {
17227 perror("conftest");
17228 exit(code);
17229 }
17230
17231 static void my_timeout(int sig)
17232 {
17233 (void)sig;
17234 _exit(99);
17235 }
17236
17237 int
17238 main (void)
17239 {
17240
17241 int code = 0;
17242 int pty;
17243 int tty;
17244 char *slave;
17245 struct termios tio;
17246
17247 (void)tio;
17248 signal(SIGALRM, my_timeout);
17249
17250 if (alarm(2) == 9)
17251 failed(9);
17252 else if ((pty = posix_openpt(O_RDWR)) < 0)
17253 failed(1);
17254 else if (grantpt(pty) < 0)
17255 failed(2);
17256 else if (unlockpt(pty) < 0)
17257 failed(3);
17258 else if ((slave = ptsname(pty)) == NULL)
17259 failed(4);
17260 #if (CONFTEST == 3) || defined(CONFTEST_isatty)
17261 else if (!isatty(pty))
17262 failed(4);
17263 #endif
17264 #if CONFTEST >= 4
17265 else if (tcgetattr(pty, &tio) < 0)
17266 failed(20);
17267 else if (tcsetattr(pty, TCSAFLUSH, &tio) < 0)
17268 failed(21);
17269 #endif
17270 /* BSD posix_openpt does not treat pty as a terminal until slave is opened.
17271 * Linux does treat it that way.
17272 */
17273 else if ((tty = open(slave, O_RDWR)) < 0)
17274 failed(5);
17275 #ifdef CONFTEST
17276 #ifdef I_PUSH
17277 #if (CONFTEST == 0) || defined(CONFTEST_ptem)
17278 else if (ioctl(tty, I_PUSH, "ptem") < 0)
17279 failed(10);
17280 #endif
17281 #if (CONFTEST == 1) || defined(CONFTEST_ldterm)
17282 else if (ioctl(tty, I_PUSH, "ldterm") < 0)
17283 failed(11);
17284 #endif
17285 #if (CONFTEST == 2) || defined(CONFTEST_ttcompat)
17286 else if (ioctl(tty, I_PUSH, "ttcompat") < 0)
17287 failed(12);
17288 #endif
17289 #endif /* I_PUSH */
17290 #if CONFTEST >= 5
17291 else if (tcgetattr(tty, &tio) < 0)
17292 failed(30);
17293 else if (tcsetattr(tty, TCSAFLUSH, &tio) < 0)
17294 failed(31);
17295 #endif
17296 #endif /* CONFTEST */
17297 (void) tty;
17298 ${cf_cv_main_return:-return}(code);
17299
17300 ;
17301 return 0;
17302 }
17303 _ACEOF
17304 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
17305 if { (eval echo "$as_me:17305: \"$ac_link\"") >&5
17306 (eval $ac_link) 2>&5
17307 ac_status=$?
17308 echo "$as_me:17308: \$? = $ac_status" >&5
17309 (exit "$ac_status"); } &&
17310 { ac_try='test -s "conftest$ac_exeext"'
17311 { (eval echo "$as_me:17311: \"$ac_try\"") >&5
17312 (eval $ac_try) 2>&5
17313 ac_status=$?
17314 echo "$as_me:17314: \$? = $ac_status" >&5
17315 (exit "$ac_status"); }; }; then
17316
17317 if test "$cross_compiling" = yes; then
17318 ac_cv_func_grantpt=maybe
17319 else
17320 cat >"conftest.$ac_ext" <<_ACEOF
17321 #line 17321 "configure"
17322 #include "confdefs.h"
17323
17324 #include <stdlib.h>
17325 #include <stdio.h>
17326 #include <termios.h>
17327 #include <unistd.h>
17328 #include <signal.h>
17329 #include <fcntl.h>
17330 #include <errno.h>
17331
17332 #ifndef HAVE_POSIX_OPENPT
17333 #undef posix_openpt
17334 #define posix_openpt(mode) open("/dev/ptmx", mode)
17335 #endif
17336
17337 #ifdef HAVE_STROPTS_H
17338 #include <stropts.h>
17339 #endif
17340
17341 static void failed(int code)
17342 {
17343 perror("conftest");
17344 exit(code);
17345 }
17346
17347 static void my_timeout(int sig)
17348 {
17349 (void)sig;
17350 _exit(99);
17351 }
17352
17353 int main(void)
17354 {
17355
17356 int code = 0;
17357 int pty;
17358 int tty;
17359 char *slave;
17360 struct termios tio;
17361
17362 (void)tio;
17363 signal(SIGALRM, my_timeout);
17364
17365 if (alarm(2) == 9)
17366 failed(9);
17367 else if ((pty = posix_openpt(O_RDWR)) < 0)
17368 failed(1);
17369 else if (grantpt(pty) < 0)
17370 failed(2);
17371 else if (unlockpt(pty) < 0)
17372 failed(3);
17373 else if ((slave = ptsname(pty)) == NULL)
17374 failed(4);
17375 #if (CONFTEST == 3) || defined(CONFTEST_isatty)
17376 else if (!isatty(pty))
17377 failed(4);
17378 #endif
17379 #if CONFTEST >= 4
17380 else if (tcgetattr(pty, &tio) < 0)
17381 failed(20);
17382 else if (tcsetattr(pty, TCSAFLUSH, &tio) < 0)
17383 failed(21);
17384 #endif
17385 /* BSD posix_openpt does not treat pty as a terminal until slave is opened.
17386 * Linux does treat it that way.
17387 */
17388 else if ((tty = open(slave, O_RDWR)) < 0)
17389 failed(5);
17390 #ifdef CONFTEST
17391 #ifdef I_PUSH
17392 #if (CONFTEST == 0) || defined(CONFTEST_ptem)
17393 else if (ioctl(tty, I_PUSH, "ptem") < 0)
17394 failed(10);
17395 #endif
17396 #if (CONFTEST == 1) || defined(CONFTEST_ldterm)
17397 else if (ioctl(tty, I_PUSH, "ldterm") < 0)
17398 failed(11);
17399 #endif
17400 #if (CONFTEST == 2) || defined(CONFTEST_ttcompat)
17401 else if (ioctl(tty, I_PUSH, "ttcompat") < 0)
17402 failed(12);
17403 #endif
17404 #endif /* I_PUSH */
17405 #if CONFTEST >= 5
17406 else if (tcgetattr(tty, &tio) < 0)
17407 failed(30);
17408 else if (tcsetattr(tty, TCSAFLUSH, &tio) < 0)
17409 failed(31);
17410 #endif
17411 #endif /* CONFTEST */
17412 (void) tty;
17413 ${cf_cv_main_return:-return}(code);
17414
17415 }
17416
17417 _ACEOF
17418 rm -f "conftest$ac_exeext"
17419 if { (eval echo "$as_me:17419: \"$ac_link\"") >&5
17420 (eval $ac_link) 2>&5
17421 ac_status=$?
17422 echo "$as_me:17422: \$? = $ac_status" >&5
17423 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
17424 { (eval echo "$as_me:17424: \"$ac_try\"") >&5
17425 (eval $ac_try) 2>&5
17426 ac_status=$?
17427 echo "$as_me:17427: \$? = $ac_status" >&5
17428 (exit "$ac_status"); }; }; then
17429 :
17430 else
17431 echo "$as_me: program exited with status $ac_status" >&5
17432 echo "$as_me: failed program was:" >&5
17433 cat "conftest.$ac_ext" >&5
17434 ac_cv_func_grantpt=no
17435
17436 fi
17437 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
17438 fi
17439
17440 else
17441 echo "$as_me: failed program was:" >&5
17442 cat "conftest.$ac_ext" >&5
17443 ac_cv_func_grantpt=no
17444 fi
17445 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
17446 echo "$as_me:17446: result: $ac_cv_func_grantpt" >&5
17447 echo "${ECHO_T}$ac_cv_func_grantpt" >&6
17448
17449 if test "x$ac_cv_func_grantpt" != "xno" ; then
17450
17451 if test "x$ac_cv_func_grantpt" = "xyes" ; then
17452 echo "$as_me:17452: checking for pty features" >&5
17453 echo $ECHO_N "checking for pty features... $ECHO_C" >&6
17454 if test "x$ac_cv_header_stropts_h" = xyes
17455 then
17456 cf_pty_this=0
17457 else
17458 cf_pty_this=3
17459 fi
17460
17461 cf_pty_defines=
17462 while test $cf_pty_this != 6
17463 do
17464
17465 cf_pty_feature=
17466 cf_pty_next="`expr $cf_pty_this + 1`"
17467
17468 echo "${as_me:-configure}:17468: testing pty feature test $cf_pty_next:5 ..." 1>&5
17469
17470 if test "$cross_compiling" = yes; then
17471 { { echo "$as_me:17471: error: cannot run test program while cross compiling" >&5
17472 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
17473 { (exit 1); exit 1; }; }
17474 else
17475 cat >"conftest.$ac_ext" <<_ACEOF
17476 #line 17476 "configure"
17477 #include "confdefs.h"
17478 #define CONFTEST $cf_pty_this
17479 $cf_pty_defines
17480
17481 #include <stdlib.h>
17482 #include <stdio.h>
17483 #include <termios.h>
17484 #include <unistd.h>
17485 #include <signal.h>
17486 #include <fcntl.h>
17487 #include <errno.h>
17488
17489 #ifndef HAVE_POSIX_OPENPT
17490 #undef posix_openpt
17491 #define posix_openpt(mode) open("/dev/ptmx", mode)
17492 #endif
17493
17494 #ifdef HAVE_STROPTS_H
17495 #include <stropts.h>
17496 #endif
17497
17498 static void failed(int code)
17499 {
17500 perror("conftest");
17501 exit(code);
17502 }
17503
17504 static void my_timeout(int sig)
17505 {
17506 (void)sig;
17507 _exit(99);
17508 }
17509
17510 int main(void)
17511 {
17512
17513 int code = 0;
17514 int pty;
17515 int tty;
17516 char *slave;
17517 struct termios tio;
17518
17519 (void)tio;
17520 signal(SIGALRM, my_timeout);
17521
17522 if (alarm(2) == 9)
17523 failed(9);
17524 else if ((pty = posix_openpt(O_RDWR)) < 0)
17525 failed(1);
17526 else if (grantpt(pty) < 0)
17527 failed(2);
17528 else if (unlockpt(pty) < 0)
17529 failed(3);
17530 else if ((slave = ptsname(pty)) == NULL)
17531 failed(4);
17532 #if (CONFTEST == 3) || defined(CONFTEST_isatty)
17533 else if (!isatty(pty))
17534 failed(4);
17535 #endif
17536 #if CONFTEST >= 4
17537 else if (tcgetattr(pty, &tio) < 0)
17538 failed(20);
17539 else if (tcsetattr(pty, TCSAFLUSH, &tio) < 0)
17540 failed(21);
17541 #endif
17542 /* BSD posix_openpt does not treat pty as a terminal until slave is opened.
17543 * Linux does treat it that way.
17544 */
17545 else if ((tty = open(slave, O_RDWR)) < 0)
17546 failed(5);
17547 #ifdef CONFTEST
17548 #ifdef I_PUSH
17549 #if (CONFTEST == 0) || defined(CONFTEST_ptem)
17550 else if (ioctl(tty, I_PUSH, "ptem") < 0)
17551 failed(10);
17552 #endif
17553 #if (CONFTEST == 1) || defined(CONFTEST_ldterm)
17554 else if (ioctl(tty, I_PUSH, "ldterm") < 0)
17555 failed(11);
17556 #endif
17557 #if (CONFTEST == 2) || defined(CONFTEST_ttcompat)
17558 else if (ioctl(tty, I_PUSH, "ttcompat") < 0)
17559 failed(12);
17560 #endif
17561 #endif /* I_PUSH */
17562 #if CONFTEST >= 5
17563 else if (tcgetattr(tty, &tio) < 0)
17564 failed(30);
17565 else if (tcsetattr(tty, TCSAFLUSH, &tio) < 0)
17566 failed(31);
17567 #endif
17568 #endif /* CONFTEST */
17569 (void) tty;
17570 ${cf_cv_main_return:-return}(code);
17571
17572 }
17573
17574 _ACEOF
17575 rm -f "conftest$ac_exeext"
17576 if { (eval echo "$as_me:17576: \"$ac_link\"") >&5
17577 (eval $ac_link) 2>&5
17578 ac_status=$?
17579 echo "$as_me:17579: \$? = $ac_status" >&5
17580 (exit "$ac_status"); } && { ac_try='"./conftest$ac_exeext"'
17581 { (eval echo "$as_me:17581: \"$ac_try\"") >&5
17582 (eval $ac_try) 2>&5
17583 ac_status=$?
17584 echo "$as_me:17584: \$? = $ac_status" >&5
17585 (exit "$ac_status"); }; }; then
17586
17587 case $cf_pty_next in
17588 (1) # - streams
17589 cf_pty_feature=ptem
17590 ;;
17591 (2) # - streams
17592 cf_pty_feature=ldterm
17593 ;;
17594 (3) # - streams
17595 cf_pty_feature=ttcompat
17596 ;;
17597 (4)
17598 cf_pty_feature=pty_isatty
17599 ;;
17600 (5)
17601 cf_pty_feature=pty_tcsetattr
17602 ;;
17603 (6)
17604 cf_pty_feature=tty_tcsetattr
17605 ;;
17606 esac
17607
17608 else
17609 echo "$as_me: program exited with status $ac_status" >&5
17610 echo "$as_me: failed program was:" >&5
17611 cat "conftest.$ac_ext" >&5
17612
17613 case $cf_pty_next in
17614 (1|2|3)
17615
17616 echo "${as_me:-configure}:17616: testing skipping remaining streams features $cf_pty_this..2 ..." 1>&5
17617
17618 cf_pty_next=3
17619 ;;
17620 esac
17621
17622 fi
17623 rm -f core ./core.* ./*.core "conftest$ac_exeext" "conftest.$ac_objext" "conftest.$ac_ext"
17624 fi
17625 if test -n "$cf_pty_feature"
17626 then
17627 cf_pty_defines="$cf_pty_defines
17628 #define CONFTEST_$cf_pty_feature 1
17629 "
17630 cf_grantpt_opts="$cf_grantpt_opts $cf_pty_feature"
17631 fi
17632
17633 cf_pty_this=$cf_pty_next
17634 done
17635 echo "$as_me:17635: result: $cf_grantpt_opts" >&5
17636 echo "${ECHO_T}$cf_grantpt_opts" >&6
17637 cf_grantpt_opts=`echo "$cf_grantpt_opts" | sed -e 's/ isatty//'`
17638 fi
17639 fi
17640 fi
17641
17642 if test "x$cf_prefer_posix_openpt" = "xyes" && test "x$ac_cv_func_posix_openpt" = "xyes" ; then
17643 test -n "$verbose" && echo " prefer posix_openpt over openpty" 1>&6
17644
17645 echo "${as_me:-configure}:17645: testing prefer posix_openpt over openpty ..." 1>&5
17646
17647 elif test "x$disable_openpty" != "xyes" || test -z "$cf_grantpt_opts" ; then
17648 echo "$as_me:17648: checking for openpty in -lutil" >&5
17649 echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6
17650 if test "${ac_cv_lib_util_openpty+set}" = set; then
17651 echo $ECHO_N "(cached) $ECHO_C" >&6
17652 else
17653 ac_check_lib_save_LIBS=$LIBS
17654 LIBS="-lutil $LIBS"
17655 cat >"conftest.$ac_ext" <<_ACEOF
17656 #line 17656 "configure"
17657 #include "confdefs.h"
17658
17659 /* Override any gcc2 internal prototype to avoid an error. */
17660 #ifdef __cplusplus
17661 extern "C"
17662 #endif
17663 /* We use char because int might match the return type of a gcc2
17664 builtin and then its argument prototype would still apply. */
17665 char openpty (void);
17666 int
17667 main (void)
17668 {
17669 openpty ();
17670 ;
17671 return 0;
17672 }
17673 _ACEOF
17674 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
17675 if { (eval echo "$as_me:17675: \"$ac_link\"") >&5
17676 (eval $ac_link) 2>&5
17677 ac_status=$?
17678 echo "$as_me:17678: \$? = $ac_status" >&5
17679 (exit "$ac_status"); } &&
17680 { ac_try='test -s "conftest$ac_exeext"'
17681 { (eval echo "$as_me:17681: \"$ac_try\"") >&5
17682 (eval $ac_try) 2>&5
17683 ac_status=$?
17684 echo "$as_me:17684: \$? = $ac_status" >&5
17685 (exit "$ac_status"); }; }; then
17686 ac_cv_lib_util_openpty=yes
17687 else
17688 echo "$as_me: failed program was:" >&5
17689 cat "conftest.$ac_ext" >&5
17690 ac_cv_lib_util_openpty=no
17691 fi
17692 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
17693 LIBS=$ac_check_lib_save_LIBS
17694 fi
17695 echo "$as_me:17695: result: $ac_cv_lib_util_openpty" >&5
17696 echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6
17697 if test "$ac_cv_lib_util_openpty" = yes; then
17698 cf_have_openpty=yes
17699 else
17700 cf_have_openpty=no
17701 fi
17702
17703 if test "$cf_have_openpty" = yes ; then
17704 ac_cv_func_grantpt=no
17705 LIBS="-lutil $LIBS"
17706
17707 cat >>confdefs.h <<\EOF
17708 #define HAVE_OPENPTY 1
17709 EOF
17710
17711 for ac_header in \
17712 util.h \
17713 libutil.h \
17714 pty.h \
17715
17716 do
17717 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
17718 echo "$as_me:17718: checking for $ac_header" >&5
17719 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
17720 if eval "test \"\${$as_ac_Header+set}\" = set"; then
17721 echo $ECHO_N "(cached) $ECHO_C" >&6
17722 else
17723 cat >"conftest.$ac_ext" <<_ACEOF
17724 #line 17724 "configure"
17725 #include "confdefs.h"
17726 #include <$ac_header>
17727 _ACEOF
17728 if { (eval echo "$as_me:17728: \"$ac_cpp "conftest.$ac_ext"\"") >&5
17729 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
17730 ac_status=$?
17731 $EGREP -v '^ *\+' conftest.er1 >conftest.err
17732 rm -f conftest.er1
17733 cat conftest.err >&5
17734 echo "$as_me:17734: \$? = $ac_status" >&5
17735 (exit "$ac_status"); } >/dev/null; then
17736 if test -s conftest.err; then
17737 ac_cpp_err=$ac_c_preproc_warn_flag
17738 else
17739 ac_cpp_err=
17740 fi
17741 else
17742 ac_cpp_err=yes
17743 fi
17744 if test -z "$ac_cpp_err"; then
17745 eval "$as_ac_Header=yes"
17746 else
17747 echo "$as_me: failed program was:" >&5
17748 cat "conftest.$ac_ext" >&5
17749 eval "$as_ac_Header=no"
17750 fi
17751 rm -f conftest.err "conftest.$ac_ext"
17752 fi
17753 echo "$as_me:17753: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
17754 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
17755 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
17756 cat >>confdefs.h <<EOF
17757 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
17758 EOF
17759
17760 fi
17761 done
17762
17763 fi
17764 fi
17765
17766 if test "x$ac_cv_func_grantpt" != xno
17767 then
17768 test -n "$verbose" && echo " will rely upon grantpt" 1>&6
17769
17770 echo "${as_me:-configure}:17770: testing will rely upon grantpt ..." 1>&5
17771
17772 cat >>confdefs.h <<\EOF
17773 #define HAVE_WORKING_GRANTPT 1
17774 EOF
17775
17776 for cf_feature in $cf_grantpt_opts
17777 do
17778 cf_feature=`echo "$cf_feature" | sed -e 's/ //g'`
17779
17780 cf_FEATURE=`echo "$cf_feature" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
17781
17782 cat >>confdefs.h <<EOF
17783 #define HAVE_GRANTPT_$cf_FEATURE 1
17784 EOF
17785
17786 done
17787 elif test "x$cf_have_openpty" = xno
17788 then
17789 test -n "$verbose" && echo " will rely upon BSD-pseudoterminals" 1>&6
17790
17791 echo "${as_me:-configure}:17791: testing will rely upon BSD-pseudoterminals ..." 1>&5
17792
17793 else
17794 test -n "$verbose" && echo " will rely upon openpty" 1>&6
17795
17796 echo "${as_me:-configure}:17796: testing will rely upon openpty ..." 1>&5
17797
17798 fi
17799
17800 echo "$as_me:17800: checking if we can use XkbQueryExtension" >&5
17801 echo $ECHO_N "checking if we can use XkbQueryExtension... $ECHO_C" >&6
17802 if test "${cf_cv_xkb_query_extension+set}" = set; then
17803 echo $ECHO_N "(cached) $ECHO_C" >&6
17804 else
17805
17806 cat >"conftest.$ac_ext" <<_ACEOF
17807 #line 17807 "configure"
17808 #include "confdefs.h"
17809
17810 #include <X11/Xlib.h>
17811 #include <X11/extensions/XKB.h>
17812 #include <X11/XKBlib.h>
17813
17814 int
17815 main (void)
17816 {
17817
17818 int xkbmajor = XkbMajorVersion;
17819 int xkbminor = XkbMinorVersion;
17820 int xkbopcode, xkbevent, xkberror;
17821
17822 if (XkbLibraryVersion(&xkbmajor, &xkbminor)
17823 && XkbQueryExtension((Display *)0,
17824 &xkbopcode,
17825 &xkbevent,
17826 &xkberror,
17827 &xkbmajor,
17828 &xkbminor))
17829 return 0;
17830
17831 ;
17832 return 0;
17833 }
17834 _ACEOF
17835 rm -f "conftest.$ac_objext"
17836 if { (eval echo "$as_me:17836: \"$ac_compile\"") >&5
17837 (eval $ac_compile) 2>&5
17838 ac_status=$?
17839 echo "$as_me:17839: \$? = $ac_status" >&5
17840 (exit "$ac_status"); } &&
17841 { ac_try='test -s "conftest.$ac_objext"'
17842 { (eval echo "$as_me:17842: \"$ac_try\"") >&5
17843 (eval $ac_try) 2>&5
17844 ac_status=$?
17845 echo "$as_me:17845: \$? = $ac_status" >&5
17846 (exit "$ac_status"); }; }; then
17847
17848 cf_cv_xkb_query_extension=yes
17849
17850 else
17851 echo "$as_me: failed program was:" >&5
17852 cat "conftest.$ac_ext" >&5
17853
17854 cf_cv_xkb_query_extension=no
17855
17856 fi
17857 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
17858
17859 fi
17860 echo "$as_me:17860: result: $cf_cv_xkb_query_extension" >&5
17861 echo "${ECHO_T}$cf_cv_xkb_query_extension" >&6
17862
17863 if test $cf_cv_xkb_query_extension = yes
17864 then
17865
17866 for ac_func in XkbQueryExtension
17867 do
17868 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17869 echo "$as_me:17869: checking for $ac_func" >&5
17870 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17871 if eval "test \"\${$as_ac_var+set}\" = set"; then
17872 echo $ECHO_N "(cached) $ECHO_C" >&6
17873 else
17874 cat >"conftest.$ac_ext" <<_ACEOF
17875 #line 17875 "configure"
17876 #include "confdefs.h"
17877 #define $ac_func autoconf_temporary
17878 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
17879 #undef $ac_func
17880
17881 #ifdef __cplusplus
17882 extern "C"
17883 #endif
17884
17885 /* We use char because int might match the return type of a gcc2
17886 builtin and then its argument prototype would still apply. */
17887 char $ac_func (void);
17888
17889 int
17890 main (void)
17891 {
17892
17893 /* The GNU C library defines stubs for functions which it implements
17894 to always fail with ENOSYS. Some functions are actually named
17895 something starting with __ and the normal name is an alias. */
17896 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
17897 #error found stub for $ac_func
17898 #endif
17899
17900 return $ac_func ();
17901 ;
17902 return 0;
17903 }
17904 _ACEOF
17905 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
17906 if { (eval echo "$as_me:17906: \"$ac_link\"") >&5
17907 (eval $ac_link) 2>&5
17908 ac_status=$?
17909 echo "$as_me:17909: \$? = $ac_status" >&5
17910 (exit "$ac_status"); } &&
17911 { ac_try='test -s "conftest$ac_exeext"'
17912 { (eval echo "$as_me:17912: \"$ac_try\"") >&5
17913 (eval $ac_try) 2>&5
17914 ac_status=$?
17915 echo "$as_me:17915: \$? = $ac_status" >&5
17916 (exit "$ac_status"); }; }; then
17917 eval "$as_ac_var=yes"
17918 else
17919 echo "$as_me: failed program was:" >&5
17920 cat "conftest.$ac_ext" >&5
17921 eval "$as_ac_var=no"
17922 fi
17923 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
17924 fi
17925 echo "$as_me:17925: result: `eval echo '${'"$as_ac_var"'}'`" >&5
17926 echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
17927 if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
17928 cat >>confdefs.h <<EOF
17929 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17930 EOF
17931
17932 fi
17933 done
17934
17935 fi
17936
17937 echo "$as_me:17937: checking if we can use XkbKeycodeToKeysym" >&5
17938 echo $ECHO_N "checking if we can use XkbKeycodeToKeysym... $ECHO_C" >&6
17939 if test "${cf_cv_xkb_keycode_to_keysym+set}" = set; then
17940 echo $ECHO_N "(cached) $ECHO_C" >&6
17941 else
17942
17943 cat >"conftest.$ac_ext" <<_ACEOF
17944 #line 17944 "configure"
17945 #include "confdefs.h"
17946
17947 #include <X11/Xlib.h>
17948 #include <X11/XKBlib.h>
17949
17950 int
17951 main (void)
17952 {
17953
17954 KeySym keysym = XkbKeycodeToKeysym((Display *)0, 0, 0, 0);
17955 (void)keysym;
17956
17957 ;
17958 return 0;
17959 }
17960 _ACEOF
17961 rm -f "conftest.$ac_objext"
17962 if { (eval echo "$as_me:17962: \"$ac_compile\"") >&5
17963 (eval $ac_compile) 2>&5
17964 ac_status=$?
17965 echo "$as_me:17965: \$? = $ac_status" >&5
17966 (exit "$ac_status"); } &&
17967 { ac_try='test -s "conftest.$ac_objext"'
17968 { (eval echo "$as_me:17968: \"$ac_try\"") >&5
17969 (eval $ac_try) 2>&5
17970 ac_status=$?
17971 echo "$as_me:17971: \$? = $ac_status" >&5
17972 (exit "$ac_status"); }; }; then
17973
17974 cf_cv_xkb_keycode_to_keysym=yes
17975
17976 else
17977 echo "$as_me: failed program was:" >&5
17978 cat "conftest.$ac_ext" >&5
17979
17980 cf_cv_xkb_keycode_to_keysym=no
17981
17982 fi
17983 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
17984
17985 fi
17986 echo "$as_me:17986: result: $cf_cv_xkb_keycode_to_keysym" >&5
17987 echo "${ECHO_T}$cf_cv_xkb_keycode_to_keysym" >&6
17988
17989 if test $cf_cv_xkb_keycode_to_keysym = yes
17990 then
17991
17992 for ac_func in XkbKeycodeToKeysym
17993 do
17994 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17995 echo "$as_me:17995: checking for $ac_func" >&5
17996 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
17997 if eval "test \"\${$as_ac_var+set}\" = set"; then
17998 echo $ECHO_N "(cached) $ECHO_C" >&6
17999 else
18000 cat >"conftest.$ac_ext" <<_ACEOF
18001 #line 18001 "configure"
18002 #include "confdefs.h"
18003 #define $ac_func autoconf_temporary
18004 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
18005 #undef $ac_func
18006
18007 #ifdef __cplusplus
18008 extern "C"
18009 #endif
18010
18011 /* We use char because int might match the return type of a gcc2
18012 builtin and then its argument prototype would still apply. */
18013 char $ac_func (void);
18014
18015 int
18016 main (void)
18017 {
18018
18019 /* The GNU C library defines stubs for functions which it implements
18020 to always fail with ENOSYS. Some functions are actually named
18021 something starting with __ and the normal name is an alias. */
18022 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
18023 #error found stub for $ac_func
18024 #endif
18025
18026 return $ac_func ();
18027 ;
18028 return 0;
18029 }
18030 _ACEOF
18031 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
18032 if { (eval echo "$as_me:18032: \"$ac_link\"") >&5
18033 (eval $ac_link) 2>&5
18034 ac_status=$?
18035 echo "$as_me:18035: \$? = $ac_status" >&5
18036 (exit "$ac_status"); } &&
18037 { ac_try='test -s "conftest$ac_exeext"'
18038 { (eval echo "$as_me:18038: \"$ac_try\"") >&5
18039 (eval $ac_try) 2>&5
18040 ac_status=$?
18041 echo "$as_me:18041: \$? = $ac_status" >&5
18042 (exit "$ac_status"); }; }; then
18043 eval "$as_ac_var=yes"
18044 else
18045 echo "$as_me: failed program was:" >&5
18046 cat "conftest.$ac_ext" >&5
18047 eval "$as_ac_var=no"
18048 fi
18049 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
18050 fi
18051 echo "$as_me:18051: result: `eval echo '${'"$as_ac_var"'}'`" >&5
18052 echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
18053 if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
18054 cat >>confdefs.h <<EOF
18055 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18056 EOF
18057
18058 fi
18059 done
18060
18061 fi
18062
18063 cf_save_LIBS_CF_XKB_BELL_EXT="$LIBS"
18064 cf_save_CFLAGS_CF_XKB_BELL_EXT="$CFLAGS"
18065 cf_save_CPPFLAGS_CF_XKB_BELL_EXT="$CPPFLAGS"
18066 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
18067 for cf_X_CFLAGS in $X_CFLAGS
18068 do
18069 case "x$cf_X_CFLAGS" in
18070 x-[IUD]*)
18071 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
18072 ;;
18073 *)
18074 CFLAGS="$CFLAGS $cf_X_CFLAGS"
18075 ;;
18076 esac
18077 done
18078
18079 echo "$as_me:18079: checking for XKB Bell extension" >&5
18080 echo $ECHO_N "checking for XKB Bell extension... $ECHO_C" >&6
18081 if test "${cf_cv_xkb_bell_ext+set}" = set; then
18082 echo $ECHO_N "(cached) $ECHO_C" >&6
18083 else
18084
18085 cat >"conftest.$ac_ext" <<_ACEOF
18086 #line 18086 "configure"
18087 #include "confdefs.h"
18088
18089 #include <X11/Intrinsic.h>
18090 #include <X11/XKBlib.h> /* has the prototype */
18091 #include <X11/extensions/XKBbells.h> /* has the XkbBI_xxx definitions */
18092
18093 int
18094 main (void)
18095 {
18096
18097 int x = (XkbBI_Info |XkbBI_MinorError |XkbBI_MajorError |XkbBI_TerminalBell |XkbBI_MarginBell);
18098 Atom y = 0;
18099 (void)x;
18100 XkbBell((Display *)0, (Window)0, 0, y);
18101
18102 ;
18103 return 0;
18104 }
18105 _ACEOF
18106 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
18107 if { (eval echo "$as_me:18107: \"$ac_link\"") >&5
18108 (eval $ac_link) 2>&5
18109 ac_status=$?
18110 echo "$as_me:18110: \$? = $ac_status" >&5
18111 (exit "$ac_status"); } &&
18112 { ac_try='test -s "conftest$ac_exeext"'
18113 { (eval echo "$as_me:18113: \"$ac_try\"") >&5
18114 (eval $ac_try) 2>&5
18115 ac_status=$?
18116 echo "$as_me:18116: \$? = $ac_status" >&5
18117 (exit "$ac_status"); }; }; then
18118 cf_cv_xkb_bell_ext=yes
18119 else
18120 echo "$as_me: failed program was:" >&5
18121 cat "conftest.$ac_ext" >&5
18122 cf_cv_xkb_bell_ext=no
18123 fi
18124 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
18125
18126 fi
18127 echo "$as_me:18127: result: $cf_cv_xkb_bell_ext" >&5
18128 echo "${ECHO_T}$cf_cv_xkb_bell_ext" >&6
18129 test "$cf_cv_xkb_bell_ext" = yes &&
18130 cat >>confdefs.h <<\EOF
18131 #define HAVE_XKB_BELL_EXT 1
18132 EOF
18133
18134 LIBS="$cf_save_LIBS_CF_XKB_BELL_EXT"
18135 CFLAGS="$cf_save_CFLAGS_CF_XKB_BELL_EXT"
18136 CPPFLAGS="$cf_save_CPPFLAGS_CF_XKB_BELL_EXT"
18137
18138 for ac_func in Xutf8LookupString
18139 do
18140 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18141 echo "$as_me:18141: checking for $ac_func" >&5
18142 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
18143 if eval "test \"\${$as_ac_var+set}\" = set"; then
18144 echo $ECHO_N "(cached) $ECHO_C" >&6
18145 else
18146 cat >"conftest.$ac_ext" <<_ACEOF
18147 #line 18147 "configure"
18148 #include "confdefs.h"
18149 #define $ac_func autoconf_temporary
18150 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
18151 #undef $ac_func
18152
18153 #ifdef __cplusplus
18154 extern "C"
18155 #endif
18156
18157 /* We use char because int might match the return type of a gcc2
18158 builtin and then its argument prototype would still apply. */
18159 char $ac_func (void);
18160
18161 int
18162 main (void)
18163 {
18164
18165 /* The GNU C library defines stubs for functions which it implements
18166 to always fail with ENOSYS. Some functions are actually named
18167 something starting with __ and the normal name is an alias. */
18168 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
18169 #error found stub for $ac_func
18170 #endif
18171
18172 return $ac_func ();
18173 ;
18174 return 0;
18175 }
18176 _ACEOF
18177 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
18178 if { (eval echo "$as_me:18178: \"$ac_link\"") >&5
18179 (eval $ac_link) 2>&5
18180 ac_status=$?
18181 echo "$as_me:18181: \$? = $ac_status" >&5
18182 (exit "$ac_status"); } &&
18183 { ac_try='test -s "conftest$ac_exeext"'
18184 { (eval echo "$as_me:18184: \"$ac_try\"") >&5
18185 (eval $ac_try) 2>&5
18186 ac_status=$?
18187 echo "$as_me:18187: \$? = $ac_status" >&5
18188 (exit "$ac_status"); }; }; then
18189 eval "$as_ac_var=yes"
18190 else
18191 echo "$as_me: failed program was:" >&5
18192 cat "conftest.$ac_ext" >&5
18193 eval "$as_ac_var=no"
18194 fi
18195 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
18196 fi
18197 echo "$as_me:18197: result: `eval echo '${'"$as_ac_var"'}'`" >&5
18198 echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
18199 if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
18200 cat >>confdefs.h <<EOF
18201 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18202 EOF
18203
18204 else
18205
18206 EXTRAHDRS="$EXTRAHDRS xutf8.h"
18207 EXTRASRCS="$EXTRASRCS xutf8.c"
18208 EXTRAOBJS="$EXTRAOBJS xutf8.o"
18209
18210 fi
18211 done
18212
18213 echo "$as_me:18213: checking if you want narrow prototypes for X libraries" >&5
18214 echo $ECHO_N "checking if you want narrow prototypes for X libraries... $ECHO_C" >&6
18215
18216 case `$ac_config_guess` in
18217 (*freebsd*|*gnu*|*irix5*|*irix6*|*netbsd*|*openbsd*|*qnx*|*sco*|*sgi*)
18218 cf_default_narrowproto=yes
18219 ;;
18220 (*)
18221 cf_default_narrowproto=no
18222 ;;
18223 esac
18224
18225 # Check whether --enable-narrowproto or --disable-narrowproto was given.
18226 if test "${enable_narrowproto+set}" = set; then
18227 enableval="$enable_narrowproto"
18228 test "$enableval" != no && enableval=yes
18229 if test "$enableval" != "$cf_default_narrowproto" ; then
18230 enable_narrowproto=$enableval
18231 else
18232 enable_narrowproto=$cf_default_narrowproto
18233 fi
18234 else
18235 enableval=$cf_default_narrowproto
18236 enable_narrowproto=$cf_default_narrowproto
18237
18238 fi;
18239 echo "$as_me:18239: result: $enable_narrowproto" >&5
18240 echo "${ECHO_T}$enable_narrowproto" >&6
18241
18242 echo "$as_me:18242: checking if we should use imake to help" >&5
18243 echo $ECHO_N "checking if we should use imake to help... $ECHO_C" >&6
18244
18245 # Check whether --enable-imake or --disable-imake was given.
18246 if test "${enable_imake+set}" = set; then
18247 enableval="$enable_imake"
18248 test "$enableval" != yes && enableval=no
18249 if test "$enableval" != "no" ; then
18250 enable_imake=yes
18251 else
18252 enable_imake=no
18253 fi
18254 else
18255 enableval=no
18256 enable_imake=no
18257
18258 fi;
18259 echo "$as_me:18259: result: $enable_imake" >&5
18260 echo "${ECHO_T}$enable_imake" >&6
18261
18262 if test "$enable_imake" = yes ; then
18263
18264 for ac_prog in xmkmf imake
18265 do
18266 # Extract the first word of "$ac_prog", so it can be a program name with args.
18267 set dummy $ac_prog; ac_word=$2
18268 echo "$as_me:18268: checking for $ac_word" >&5
18269 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18270 if test "${ac_cv_path_IMAKE+set}" = set; then
18271 echo $ECHO_N "(cached) $ECHO_C" >&6
18272 else
18273 case $IMAKE in
18274 [\\/]* | ?:[\\/]*)
18275 ac_cv_path_IMAKE="$IMAKE" # Let the user override the test with a path.
18276 ;;
18277 *)
18278 ac_save_IFS=$IFS; IFS=$ac_path_separator
18279 ac_dummy="$PATH"
18280 for ac_dir in $ac_dummy; do
18281 IFS=$ac_save_IFS
18282 test -z "$ac_dir" && ac_dir=.
18283 if $as_executable_p "$ac_dir/$ac_word"; then
18284 ac_cv_path_IMAKE="$ac_dir/$ac_word"
18285 echo "$as_me:18285: found $ac_dir/$ac_word" >&5
18286 break
18287 fi
18288 done
18289
18290 ;;
18291 esac
18292 fi
18293 IMAKE=$ac_cv_path_IMAKE
18294
18295 if test -n "$IMAKE"; then
18296 echo "$as_me:18296: result: $IMAKE" >&5
18297 echo "${ECHO_T}$IMAKE" >&6
18298 else
18299 echo "$as_me:18299: result: no" >&5
18300 echo "${ECHO_T}no" >&6
18301 fi
18302
18303 test -n "$IMAKE" && break
18304 done
18305
18306 if test -n "$IMAKE" ; then
18307
18308 case $IMAKE in
18309 (*/imake)
18310 cf_imake_opts="-DUseInstalled=YES"
18311 ;;
18312 (*/util/xmkmf)
18313 # A single parameter tells xmkmf where the config-files are:
18314 cf_imake_opts="`echo "$IMAKE"|sed -e s,/config/util/xmkmf,,`"
18315 ;;
18316 (*)
18317 cf_imake_opts=
18318 ;;
18319 esac
18320
18321 # If it's installed properly, imake (or its wrapper, xmkmf) will point to the
18322 # config directory.
18323 if mkdir conftestdir; then
18324 CDPATH=; export CDPATH
18325 cf_makefile=`cd "$srcdir" || exit;pwd`/Imakefile
18326 cd conftestdir
18327
18328 cat >fix_cflags.sed <<'CF_EOF'
18329 s/\\//g
18330 s/[ ][ ]*/ /g
18331 s/"//g
18332 :pack
18333 s/\(=[^ ][^ ]*\) \([^-]\)/\1 \2/g
18334 t pack
18335 s/\(-D[a-zA-Z0-9_][a-zA-Z0-9_]*\)=\([^\'0-9 ][^ ]*\)/\1='\\"\2\\"'/g
18336 s/^IMAKE[ ]/IMAKE_CFLAGS="/
18337 s/ / /g
18338 s/$/"/
18339 CF_EOF
18340
18341 cat >fix_lflags.sed <<'CF_EOF'
18342 s/^IMAKE[ ]*/IMAKE_LOADFLAGS="/
18343 s/$/"/
18344 CF_EOF
18345
18346 echo >./Imakefile
18347 test -f "$cf_makefile" && cat "$cf_makefile" >>./Imakefile
18348
18349 cat >> ./Imakefile <<'CF_EOF'
18350 findstddefs:
18351 @echo IMAKE ${ALLDEFINES} $(MAIN_DEFINES) $(VENDORMANDEFS) | sed -f fix_cflags.sed
18352 @echo IMAKE ${EXTRA_LOAD_FLAGS} | sed -f fix_lflags.sed
18353 CF_EOF
18354
18355 if ( $IMAKE "$cf_imake_opts" 1>/dev/null 2>&5 && test -f Makefile)
18356 then
18357 test -n "$verbose" && echo " Using $IMAKE $cf_imake_opts" 1>&6
18358
18359 echo "${as_me:-configure}:18359: testing Using $IMAKE $cf_imake_opts ..." 1>&5
18360
18361 else
18362 # sometimes imake doesn't have the config path compiled in. Find it.
18363 cf_config=
18364 for cf_libpath in $X_LIBS $LIBS ; do
18365 case "$cf_libpath" in
18366 (-L*)
18367 cf_libpath=`echo ".$cf_libpath" | sed -e 's/^...//'`
18368 cf_libpath="$cf_libpath/X11/config"
18369 if test -d "$cf_libpath" ; then
18370 cf_config="$cf_libpath"
18371 break
18372 fi
18373 ;;
18374 esac
18375 done
18376 if test -z "$cf_config" ; then
18377 { echo "$as_me:18377: WARNING: Could not find imake config-directory" >&5
18378 echo "$as_me: WARNING: Could not find imake config-directory" >&2;}
18379 else
18380 cf_imake_opts="$cf_imake_opts -I$cf_config"
18381 if ( "$IMAKE" -v "$cf_imake_opts" 2>&5)
18382 then
18383 test -n "$verbose" && echo " Using $IMAKE $cf_config" 1>&6
18384
18385 echo "${as_me:-configure}:18385: testing Using $IMAKE $cf_config ..." 1>&5
18386
18387 else
18388 { echo "$as_me:18388: WARNING: Cannot run $IMAKE" >&5
18389 echo "$as_me: WARNING: Cannot run $IMAKE" >&2;}
18390 fi
18391 fi
18392 fi
18393
18394 # GNU make sometimes prints "make[1]: Entering...", which
18395 # would confuse us.
18396 eval "`make findstddefs 2>/dev/null | grep -v make`"
18397
18398 cd ..
18399 rm -rf conftestdir
18400
18401 # We use ${ALLDEFINES} rather than ${STD_DEFINES} because the former
18402 # declares XTFUNCPROTO there. However, some vendors (e.g., SGI) have
18403 # modified it to support site.cf, adding a kludge for the /usr/include
18404 # directory. Try to filter that out, otherwise gcc won't find its
18405 # headers.
18406 if test -n "$GCC" ; then
18407 if test -n "$IMAKE_CFLAGS" ; then
18408 cf_nostdinc=""
18409 cf_std_incl=""
18410 cf_cpp_opts=""
18411 for cf_opt in $IMAKE_CFLAGS
18412 do
18413 case "$cf_opt" in
18414 (-nostdinc)
18415 cf_nostdinc="$cf_opt"
18416 ;;
18417 (-I/usr/include)
18418 cf_std_incl="$cf_opt"
18419 ;;
18420 (*)
18421 cf_cpp_opts="$cf_cpp_opts $cf_opt"
18422 ;;
18423 esac
18424 done
18425 if test -z "$cf_nostdinc" ; then
18426 IMAKE_CFLAGS="$cf_cpp_opts $cf_std_incl"
18427 elif test -z "$cf_std_incl" ; then
18428 IMAKE_CFLAGS="$cf_cpp_opts $cf_nostdinc"
18429 else
18430 test -n "$verbose" && echo " suppressed \"$cf_nostdinc\" and \"$cf_std_incl\"" 1>&6
18431
18432 echo "${as_me:-configure}:18432: testing suppressed \"$cf_nostdinc\" and \"$cf_std_incl\" ..." 1>&5
18433
18434 IMAKE_CFLAGS="$cf_cpp_opts"
18435 fi
18436 fi
18437 fi
18438 fi
18439
18440 # Some imake configurations define PROJECTROOT with an empty value. Remove
18441 # the empty definition.
18442 case $IMAKE_CFLAGS in
18443 (*-DPROJECTROOT=/*)
18444 ;;
18445 (*)
18446 IMAKE_CFLAGS=`echo "$IMAKE_CFLAGS" |sed -e "s,-DPROJECTROOT=[ ], ,"`
18447 ;;
18448 esac
18449
18450 fi
18451
18452 test -n "$verbose" && echo " IMAKE_CFLAGS $IMAKE_CFLAGS" 1>&6
18453
18454 echo "${as_me:-configure}:18454: testing IMAKE_CFLAGS $IMAKE_CFLAGS ..." 1>&5
18455
18456 test -n "$verbose" && echo " IMAKE_LOADFLAGS $IMAKE_LOADFLAGS" 1>&6
18457
18458 echo "${as_me:-configure}:18458: testing IMAKE_LOADFLAGS $IMAKE_LOADFLAGS ..." 1>&5
18459
18460 fi
18461
18462 if test -n "$IMAKE" && test -n "$IMAKE_CFLAGS" ; then
18463
18464 cf_fix_cppflags=no
18465 cf_new_cflags=
18466 cf_new_cppflags=
18467 cf_new_extra_cppflags=
18468
18469 for cf_add_cflags in $IMAKE_CFLAGS
18470 do
18471 case "$cf_fix_cppflags" in
18472 (no)
18473 case "$cf_add_cflags" in
18474 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
18475 case "$cf_add_cflags" in
18476 (-D*)
18477 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
18478
18479 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
18480 && test -z "${cf_tst_cflags}" \
18481 && cf_fix_cppflags=yes
18482
18483 if test "$cf_fix_cppflags" = yes ; then
18484
18485 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
18486 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
18487
18488 continue
18489 elif test "${cf_tst_cflags}" = "\"'" ; then
18490
18491 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
18492 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
18493
18494 continue
18495 fi
18496 ;;
18497 esac
18498 case "$CPPFLAGS" in
18499 (*$cf_add_cflags)
18500 ;;
18501 (*)
18502 case "$cf_add_cflags" in
18503 (-D*)
18504 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
18505
18506 CPPFLAGS=`echo "$CPPFLAGS" | \
18507 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
18508 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
18509
18510 ;;
18511 esac
18512
18513 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
18514 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
18515
18516 ;;
18517 esac
18518 ;;
18519 (*)
18520
18521 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
18522 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
18523
18524 ;;
18525 esac
18526 ;;
18527 (yes)
18528
18529 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
18530 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
18531
18532 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
18533
18534 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
18535 && test -z "${cf_tst_cflags}" \
18536 && cf_fix_cppflags=no
18537 ;;
18538 esac
18539 done
18540
18541 if test -n "$cf_new_cflags" ; then
18542
18543 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
18544 CFLAGS="${CFLAGS}$cf_new_cflags"
18545
18546 fi
18547
18548 if test -n "$cf_new_cppflags" ; then
18549
18550 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
18551 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
18552
18553 fi
18554
18555 if test -n "$cf_new_extra_cppflags" ; then
18556
18557 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
18558 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
18559
18560 fi
18561
18562 else
18563 IMAKE_CFLAGS=
18564 IMAKE_LOADFLAGS=
18565 test -n "$verbose" && echo " make fallback definitions" 1>&6
18566
18567 echo "${as_me:-configure}:18567: testing make fallback definitions ..." 1>&5
18568
18569 # We prefer config.guess' values when we can get them, to avoid
18570 # inconsistent results with uname (AIX for instance). However,
18571 # config.guess is not always consistent either.
18572 case $host_os in
18573 (*[0-9].[0-9]*)
18574 UNAME_RELEASE="$host_os"
18575 ;;
18576 (*)
18577 UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown
18578 ;;
18579 esac
18580
18581 case .$UNAME_RELEASE in
18582 (*[0-9].[0-9]*)
18583 OSMAJORVERSION=`echo "$UNAME_RELEASE" |sed -e 's/^[^0-9]*//' -e 's/\..*//'`
18584 OSMINORVERSION=`echo "$UNAME_RELEASE" |sed -e 's/^[^0-9]*//' -e 's/^[^.]*\.//' -e 's/\..*//' -e 's/[^0-9].*//' `
18585 test -z "$OSMAJORVERSION" && OSMAJORVERSION=1
18586 test -z "$OSMINORVERSION" && OSMINORVERSION=0
18587 IMAKE_CFLAGS="-DOSMAJORVERSION=$OSMAJORVERSION -DOSMINORVERSION=$OSMINORVERSION $IMAKE_CFLAGS"
18588 ;;
18589 esac
18590
18591 # FUNCPROTO is standard with X11R6, but XFree86 drops it, leaving some
18592 # fallback/fragments for NeedPrototypes, etc.
18593 IMAKE_CFLAGS="-DFUNCPROTO=15 $IMAKE_CFLAGS"
18594
18595 # If this is not set properly, Xaw's scrollbars will not work
18596 if test "$enable_narrowproto" = yes ; then
18597 IMAKE_CFLAGS="-DNARROWPROTO=1 $IMAKE_CFLAGS"
18598 fi
18599
18600 # Other special definitions:
18601 case $host_os in
18602 (aix*)
18603 # imake on AIX 5.1 defines AIXV3. really.
18604 IMAKE_CFLAGS="-DAIXV3 -DAIXV4 $IMAKE_CFLAGS"
18605 ;;
18606 (irix[56].*)
18607 # these are needed to make SIGWINCH work in xterm
18608 IMAKE_CFLAGS="-DSYSV -DSVR4 $IMAKE_CFLAGS"
18609 ;;
18610 esac
18611
18612 # "modern" systems install X applications in /usr/bin. Other systems may
18613 # use one of the X release-based directories.
18614 case "$CFLAGS $CPPFLAGS $IMAKE_CFLAGS" in
18615 (*-DPROJECTROOT*)
18616 ;;
18617 (*)
18618 for cf_dir in /usr/X11R7 /usr/X11R6 /usr/X11R5
18619 do
18620 if test -d "$cf_dir/bin"
18621 then
18622 IMAKE_CFLAGS="$IMAKE_CFLAGS -DPROJECTROOT=\\\"$cf_dir\\\""
18623 break
18624 fi
18625 done
18626 ;;
18627 esac
18628
18629 cf_fix_cppflags=no
18630 cf_new_cflags=
18631 cf_new_cppflags=
18632 cf_new_extra_cppflags=
18633
18634 for cf_add_cflags in $IMAKE_CFLAGS
18635 do
18636 case "$cf_fix_cppflags" in
18637 (no)
18638 case "$cf_add_cflags" in
18639 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
18640 case "$cf_add_cflags" in
18641 (-D*)
18642 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
18643
18644 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
18645 && test -z "${cf_tst_cflags}" \
18646 && cf_fix_cppflags=yes
18647
18648 if test "$cf_fix_cppflags" = yes ; then
18649
18650 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
18651 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
18652
18653 continue
18654 elif test "${cf_tst_cflags}" = "\"'" ; then
18655
18656 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
18657 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
18658
18659 continue
18660 fi
18661 ;;
18662 esac
18663 case "$CPPFLAGS" in
18664 (*$cf_add_cflags)
18665 ;;
18666 (*)
18667 case "$cf_add_cflags" in
18668 (-D*)
18669 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
18670
18671 CPPFLAGS=`echo "$CPPFLAGS" | \
18672 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
18673 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
18674
18675 ;;
18676 esac
18677
18678 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
18679 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
18680
18681 ;;
18682 esac
18683 ;;
18684 (*)
18685
18686 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
18687 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
18688
18689 ;;
18690 esac
18691 ;;
18692 (yes)
18693
18694 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
18695 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
18696
18697 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
18698
18699 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
18700 && test -z "${cf_tst_cflags}" \
18701 && cf_fix_cppflags=no
18702 ;;
18703 esac
18704 done
18705
18706 if test -n "$cf_new_cflags" ; then
18707
18708 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
18709 CFLAGS="${CFLAGS}$cf_new_cflags"
18710
18711 fi
18712
18713 if test -n "$cf_new_cppflags" ; then
18714
18715 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
18716 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
18717
18718 fi
18719
18720 if test -n "$cf_new_extra_cppflags" ; then
18721
18722 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
18723 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
18724
18725 fi
18726
18727 fi
18728
18729 # Extract the first word of "groff", so it can be a program name with args.
18730 set dummy groff; ac_word=$2
18731 echo "$as_me:18731: checking for $ac_word" >&5
18732 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18733 if test "${ac_cv_path_GROFF_PATH+set}" = set; then
18734 echo $ECHO_N "(cached) $ECHO_C" >&6
18735 else
18736 case $GROFF_PATH in
18737 [\\/]* | ?:[\\/]*)
18738 ac_cv_path_GROFF_PATH="$GROFF_PATH" # Let the user override the test with a path.
18739 ;;
18740 *)
18741 ac_save_IFS=$IFS; IFS=$ac_path_separator
18742 ac_dummy="$PATH"
18743 for ac_dir in $ac_dummy; do
18744 IFS=$ac_save_IFS
18745 test -z "$ac_dir" && ac_dir=.
18746 if $as_executable_p "$ac_dir/$ac_word"; then
18747 ac_cv_path_GROFF_PATH="$ac_dir/$ac_word"
18748 echo "$as_me:18748: found $ac_dir/$ac_word" >&5
18749 break
18750 fi
18751 done
18752
18753 test -z "$ac_cv_path_GROFF_PATH" && ac_cv_path_GROFF_PATH="no"
18754 ;;
18755 esac
18756 fi
18757 GROFF_PATH=$ac_cv_path_GROFF_PATH
18758
18759 if test -n "$GROFF_PATH"; then
18760 echo "$as_me:18760: result: $GROFF_PATH" >&5
18761 echo "${ECHO_T}$GROFF_PATH" >&6
18762 else
18763 echo "$as_me:18763: result: no" >&5
18764 echo "${ECHO_T}no" >&6
18765 fi
18766
18767 for ac_prog in nroff mandoc
18768 do
18769 # Extract the first word of "$ac_prog", so it can be a program name with args.
18770 set dummy $ac_prog; ac_word=$2
18771 echo "$as_me:18771: checking for $ac_word" >&5
18772 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18773 if test "${ac_cv_path_NROFF_PATH+set}" = set; then
18774 echo $ECHO_N "(cached) $ECHO_C" >&6
18775 else
18776 case $NROFF_PATH in
18777 [\\/]* | ?:[\\/]*)
18778 ac_cv_path_NROFF_PATH="$NROFF_PATH" # Let the user override the test with a path.
18779 ;;
18780 *)
18781 ac_save_IFS=$IFS; IFS=$ac_path_separator
18782 ac_dummy="$PATH"
18783 for ac_dir in $ac_dummy; do
18784 IFS=$ac_save_IFS
18785 test -z "$ac_dir" && ac_dir=.
18786 if $as_executable_p "$ac_dir/$ac_word"; then
18787 ac_cv_path_NROFF_PATH="$ac_dir/$ac_word"
18788 echo "$as_me:18788: found $ac_dir/$ac_word" >&5
18789 break
18790 fi
18791 done
18792
18793 ;;
18794 esac
18795 fi
18796 NROFF_PATH=$ac_cv_path_NROFF_PATH
18797
18798 if test -n "$NROFF_PATH"; then
18799 echo "$as_me:18799: result: $NROFF_PATH" >&5
18800 echo "${ECHO_T}$NROFF_PATH" >&6
18801 else
18802 echo "$as_me:18802: result: no" >&5
18803 echo "${ECHO_T}no" >&6
18804 fi
18805
18806 test -n "$NROFF_PATH" && break
18807 done
18808 test -n "$NROFF_PATH" || NROFF_PATH="no"
18809
18810 # Extract the first word of "tbl", so it can be a program name with args.
18811 set dummy tbl; ac_word=$2
18812 echo "$as_me:18812: checking for $ac_word" >&5
18813 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18814 if test "${ac_cv_path_TBL_PATH+set}" = set; then
18815 echo $ECHO_N "(cached) $ECHO_C" >&6
18816 else
18817 case $TBL_PATH in
18818 [\\/]* | ?:[\\/]*)
18819 ac_cv_path_TBL_PATH="$TBL_PATH" # Let the user override the test with a path.
18820 ;;
18821 *)
18822 ac_save_IFS=$IFS; IFS=$ac_path_separator
18823 ac_dummy="$PATH"
18824 for ac_dir in $ac_dummy; do
18825 IFS=$ac_save_IFS
18826 test -z "$ac_dir" && ac_dir=.
18827 if $as_executable_p "$ac_dir/$ac_word"; then
18828 ac_cv_path_TBL_PATH="$ac_dir/$ac_word"
18829 echo "$as_me:18829: found $ac_dir/$ac_word" >&5
18830 break
18831 fi
18832 done
18833
18834 test -z "$ac_cv_path_TBL_PATH" && ac_cv_path_TBL_PATH="cat"
18835 ;;
18836 esac
18837 fi
18838 TBL_PATH=$ac_cv_path_TBL_PATH
18839
18840 if test -n "$TBL_PATH"; then
18841 echo "$as_me:18841: result: $TBL_PATH" >&5
18842 echo "${ECHO_T}$TBL_PATH" >&6
18843 else
18844 echo "$as_me:18844: result: no" >&5
18845 echo "${ECHO_T}no" >&6
18846 fi
18847
18848 if test "x$GROFF_PATH" = xno
18849 then
18850 NROFF_NOTE=
18851 GROFF_NOTE="#"
18852 else
18853 NROFF_NOTE="#"
18854 GROFF_NOTE=
18855 fi
18856
18857 echo "$as_me:18857: checking for fgrep" >&5
18858 echo $ECHO_N "checking for fgrep... $ECHO_C" >&6
18859 if test "${ac_cv_path_FGREP+set}" = set; then
18860 echo $ECHO_N "(cached) $ECHO_C" >&6
18861 else
18862 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
18863 then ac_cv_path_FGREP="$GREP -F"
18864 else
18865 for ac_prog in gfgrep fgrep
18866 do
18867 # Extract the first word of "$ac_prog", so it can be a program name with args.
18868 set dummy $ac_prog; ac_word=$2
18869 echo "$as_me:18869: checking for $ac_word" >&5
18870 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18871 if test "${ac_cv_path_FGREP+set}" = set; then
18872 echo $ECHO_N "(cached) $ECHO_C" >&6
18873 else
18874 case $FGREP in
18875 [\\/]* | ?:[\\/]*)
18876 ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path.
18877 ;;
18878 *)
18879 ac_save_IFS=$IFS; IFS=$ac_path_separator
18880 ac_dummy="$PATH"
18881 for ac_dir in $ac_dummy; do
18882 IFS=$ac_save_IFS
18883 test -z "$ac_dir" && ac_dir=.
18884 if $as_executable_p "$ac_dir/$ac_word"; then
18885 ac_cv_path_FGREP="$ac_dir/$ac_word"
18886 echo "$as_me:18886: found $ac_dir/$ac_word" >&5
18887 break
18888 fi
18889 done
18890
18891 ;;
18892 esac
18893 fi
18894 FGREP=$ac_cv_path_FGREP
18895
18896 if test -n "$FGREP"; then
18897 echo "$as_me:18897: result: $FGREP" >&5
18898 echo "${ECHO_T}$FGREP" >&6
18899 else
18900 echo "$as_me:18900: result: no" >&5
18901 echo "${ECHO_T}no" >&6
18902 fi
18903
18904 test -n "$FGREP" && break
18905 done
18906 test -n "$FGREP" || FGREP=": "
18907
18908 test "x$ac_cv_path_FGREP" = "x:" && { { echo "$as_me:18908: error: cannot find workable fgrep" >&5
18909 echo "$as_me: error: cannot find workable fgrep" >&2;}
18910 { (exit 1); exit 1; }; }
18911 fi
18912 fi
18913 echo "$as_me:18913: result: $ac_cv_path_FGREP" >&5
18914 echo "${ECHO_T}$ac_cv_path_FGREP" >&6
18915 FGREP="$ac_cv_path_FGREP"
18916
18917 case "x${with_man2html}" in
18918 (xno)
18919 cf_man2html=no
18920 ;;
18921 (x|xyes)
18922 # Extract the first word of "man2html", so it can be a program name with args.
18923 set dummy man2html; ac_word=$2
18924 echo "$as_me:18924: checking for $ac_word" >&5
18925 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18926 if test "${ac_cv_path_cf_man2html+set}" = set; then
18927 echo $ECHO_N "(cached) $ECHO_C" >&6
18928 else
18929 case $cf_man2html in
18930 [\\/]* | ?:[\\/]*)
18931 ac_cv_path_cf_man2html="$cf_man2html" # Let the user override the test with a path.
18932 ;;
18933 *)
18934 ac_save_IFS=$IFS; IFS=$ac_path_separator
18935 ac_dummy="$PATH"
18936 for ac_dir in $ac_dummy; do
18937 IFS=$ac_save_IFS
18938 test -z "$ac_dir" && ac_dir=.
18939 if $as_executable_p "$ac_dir/$ac_word"; then
18940 ac_cv_path_cf_man2html="$ac_dir/$ac_word"
18941 echo "$as_me:18941: found $ac_dir/$ac_word" >&5
18942 break
18943 fi
18944 done
18945
18946 test -z "$ac_cv_path_cf_man2html" && ac_cv_path_cf_man2html="no"
18947 ;;
18948 esac
18949 fi
18950 cf_man2html=$ac_cv_path_cf_man2html
18951
18952 if test -n "$cf_man2html"; then
18953 echo "$as_me:18953: result: $cf_man2html" >&5
18954 echo "${ECHO_T}$cf_man2html" >&6
18955 else
18956 echo "$as_me:18956: result: no" >&5
18957 echo "${ECHO_T}no" >&6
18958 fi
18959
18960 case "x$cf_man2html" in
18961 (x/*)
18962 echo "$as_me:18962: checking for the modified Earl Hood script" >&5
18963 echo $ECHO_N "checking for the modified Earl Hood script... $ECHO_C" >&6
18964 if ( $cf_man2html -help 2>&1 | grep 'Make an index of headers at the end' >/dev/null )
18965 then
18966 cf_man2html_ok=yes
18967 else
18968 cf_man2html=no
18969 cf_man2html_ok=no
18970 fi
18971 echo "$as_me:18971: result: $cf_man2html_ok" >&5
18972 echo "${ECHO_T}$cf_man2html_ok" >&6
18973 ;;
18974 (*)
18975 cf_man2html=no
18976 ;;
18977 esac
18978 esac
18979
18980 echo "$as_me:18980: checking for program to convert manpage to html" >&5
18981 echo $ECHO_N "checking for program to convert manpage to html... $ECHO_C" >&6
18982
18983 # Check whether --with-man2html or --without-man2html was given.
18984 if test "${with_man2html+set}" = set; then
18985 withval="$with_man2html"
18986 cf_man2html=$withval
18987 else
18988 cf_man2html=$cf_man2html
18989 fi;
18990
18991 cf_with_groff=no
18992
18993 case $cf_man2html in
18994 (yes)
18995 echo "$as_me:18995: result: man2html" >&5
18996 echo "${ECHO_T}man2html" >&6
18997 # Extract the first word of "man2html", so it can be a program name with args.
18998 set dummy man2html; ac_word=$2
18999 echo "$as_me:18999: checking for $ac_word" >&5
19000 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
19001 if test "${ac_cv_path_cf_man2html+set}" = set; then
19002 echo $ECHO_N "(cached) $ECHO_C" >&6
19003 else
19004 case $cf_man2html in
19005 [\\/]* | ?:[\\/]*)
19006 ac_cv_path_cf_man2html="$cf_man2html" # Let the user override the test with a path.
19007 ;;
19008 *)
19009 ac_save_IFS=$IFS; IFS=$ac_path_separator
19010 ac_dummy="$PATH"
19011 for ac_dir in $ac_dummy; do
19012 IFS=$ac_save_IFS
19013 test -z "$ac_dir" && ac_dir=.
19014 if $as_executable_p "$ac_dir/$ac_word"; then
19015 ac_cv_path_cf_man2html="$ac_dir/$ac_word"
19016 echo "$as_me:19016: found $ac_dir/$ac_word" >&5
19017 break
19018 fi
19019 done
19020
19021 test -z "$ac_cv_path_cf_man2html" && ac_cv_path_cf_man2html="no"
19022 ;;
19023 esac
19024 fi
19025 cf_man2html=$ac_cv_path_cf_man2html
19026
19027 if test -n "$cf_man2html"; then
19028 echo "$as_me:19028: result: $cf_man2html" >&5
19029 echo "${ECHO_T}$cf_man2html" >&6
19030 else
19031 echo "$as_me:19031: result: no" >&5
19032 echo "${ECHO_T}no" >&6
19033 fi
19034
19035 ;;
19036 (no|groff|*/groff*)
19037 cf_with_groff=yes
19038 cf_man2html=$GROFF_PATH
19039 echo "$as_me:19039: result: $cf_man2html" >&5
19040 echo "${ECHO_T}$cf_man2html" >&6
19041 ;;
19042 (*)
19043 echo "$as_me:19043: result: $cf_man2html" >&5
19044 echo "${ECHO_T}$cf_man2html" >&6
19045 ;;
19046 esac
19047
19048 MAN2HTML_TEMP="man2html.tmp"
19049 cat >$MAN2HTML_TEMP <<CF_EOF
19050 #!$SHELL
19051 # Temporary script generated by CF_WITH_MAN2HTML
19052 # Convert inputs to html, sending result to standard output.
19053 #
19054 # Parameters:
19055 # \${1} = rootname of file to convert
19056 # \${2} = suffix of file to convert, e.g., "1"
19057 # \${3} = macros to use, e.g., "man"
19058 #
19059 ROOT=\$1
19060 TYPE=\$2
19061 MACS=\$3
19062
19063 unset LANG
19064 unset LC_ALL
19065 unset LC_CTYPE
19066 unset LANGUAGE
19067 GROFF_NO_SGR=stupid
19068 export GROFF_NO_SGR
19069
19070 CF_EOF
19071
19072 NROFF_OPTS=
19073 if test "x$cf_with_groff" = xyes
19074 then
19075 MAN2HTML_NOTE="$GROFF_NOTE"
19076 MAN2HTML_PATH="$GROFF_PATH"
19077 cat >>$MAN2HTML_TEMP <<CF_EOF
19078 $SHELL -c "$TBL_PATH \${ROOT}.\${TYPE} | $GROFF_PATH -P -o0 -I\${ROOT}_ -Thtml -\${MACS}"
19079 CF_EOF
19080 else
19081 # disable hyphenation if this is groff
19082 if test "x$GROFF_PATH" != xno
19083 then
19084 echo "$as_me:19084: checking if nroff is really groff" >&5
19085 echo $ECHO_N "checking if nroff is really groff... $ECHO_C" >&6
19086 cf_check_groff="`$NROFF_PATH --version 2>/dev/null | grep groff`"
19087 test -n "$cf_check_groff" && cf_check_groff=yes
19088 test -n "$cf_check_groff" || cf_check_groff=no
19089 echo "$as_me:19089: result: $cf_check_groff" >&5
19090 echo "${ECHO_T}$cf_check_groff" >&6
19091 test "x$cf_check_groff" = xyes && NROFF_OPTS="-rHY=0"
19092 fi
19093 MAN2HTML_NOTE=""
19094
19095 if test "x$prefix" != xNONE; then
19096 cf_path_syntax="$prefix"
19097 else
19098 cf_path_syntax="$ac_default_prefix"
19099 fi
19100
19101 case "x$cf_man2html" in
19102 (x\$\(*\)*|x\'*\'*)
19103 ;;
19104 (x.|x$GLOB_FULLPATH_POSIX|x$GLOB_FULLPATH_OTHER)
19105 ;;
19106 (x\$\{*prefix\}*|x\$\{*dir\}*)
19107 eval cf_man2html="$cf_man2html"
19108 case "x$cf_man2html" in
19109 (xNONE/*)
19110 cf_man2html=`echo "$cf_man2html" | sed -e s%NONE%$cf_path_syntax%`
19111 ;;
19112 esac
19113 ;;
19114 (xno|xNONE/*)
19115 cf_man2html=`echo "$cf_man2html" | sed -e s%NONE%$cf_path_syntax%`
19116 ;;
19117 (*)
19118 { { echo "$as_me:19118: error: expected a pathname, not \"$cf_man2html\"" >&5
19119 echo "$as_me: error: expected a pathname, not \"$cf_man2html\"" >&2;}
19120 { (exit 1); exit 1; }; }
19121 ;;
19122 esac
19123
19124 MAN2HTML_PATH="$cf_man2html"
19125 echo "$as_me:19125: checking for $cf_man2html top/bottom margins" >&5
19126 echo $ECHO_N "checking for $cf_man2html top/bottom margins... $ECHO_C" >&6
19127
19128 # for this example, expect 3 lines of content, the remainder is head/foot
19129 cat >conftest.in <<CF_EOF
19130 .TH HEAD1 HEAD2 HEAD3 HEAD4 HEAD5
19131 .SH SECTION
19132 MARKER
19133 CF_EOF
19134
19135 LC_ALL=C LC_CTYPE=C LANG=C LANGUAGE=C $NROFF_PATH -man conftest.in >conftest.out
19136
19137 cf_man2html_1st="`${FGREP-fgrep} -n MARKER conftest.out |sed -e 's/^[^0-9]*://' -e 's/:.*//'`"
19138 cf_man2html_top=`expr "$cf_man2html_1st" - 2`
19139 cf_man2html_bot="`wc -l conftest.out |sed -e 's/[^0-9]//g'`"
19140 cf_man2html_bot=`expr "$cf_man2html_bot" - 2 - "$cf_man2html_top"`
19141 cf_man2html_top_bot="-topm=$cf_man2html_top -botm=$cf_man2html_bot"
19142
19143 echo "$as_me:19143: result: $cf_man2html_top_bot" >&5
19144 echo "${ECHO_T}$cf_man2html_top_bot" >&6
19145
19146 echo "$as_me:19146: checking for pagesize to use" >&5
19147 echo $ECHO_N "checking for pagesize to use... $ECHO_C" >&6
19148 for cf_block in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
19149 do
19150 cat >>conftest.in <<CF_EOF
19151 .nf
19152 0
19153 1
19154 2
19155 3
19156 4
19157 5
19158 6
19159 7
19160 8
19161 9
19162 CF_EOF
19163 done
19164
19165 LC_ALL=C LC_CTYPE=C LANG=C LANGUAGE=C $NROFF_PATH -man conftest.in >conftest.out
19166 cf_man2html_page="`${FGREP-fgrep} -n HEAD1 conftest.out |sed -n '$p' |sed -e 's/^[^0-9]*://' -e 's/:.*//'`"
19167 test -z "$cf_man2html_page" && cf_man2html_page=99999
19168 test "$cf_man2html_page" -gt 100 && cf_man2html_page=99999
19169
19170 rm -rf conftest*
19171 echo "$as_me:19171: result: $cf_man2html_page" >&5
19172 echo "${ECHO_T}$cf_man2html_page" >&6
19173
19174 cat >>$MAN2HTML_TEMP <<CF_EOF
19175 : \${MAN2HTML_PATH=$MAN2HTML_PATH}
19176 MAN2HTML_OPTS="\$MAN2HTML_OPTS -index -title=\"\$ROOT(\$TYPE)\" -compress -pgsize $cf_man2html_page"
19177 case \${TYPE} in
19178 (ms)
19179 $TBL_PATH \${ROOT}.\${TYPE} | $NROFF_PATH $NROFF_OPTS -\${MACS} | \$MAN2HTML_PATH -topm=0 -botm=0 \$MAN2HTML_OPTS
19180 ;;
19181 (*)
19182 $TBL_PATH \${ROOT}.\${TYPE} | $NROFF_PATH $NROFF_OPTS -\${MACS} | \$MAN2HTML_PATH $cf_man2html_top_bot \$MAN2HTML_OPTS
19183 ;;
19184 esac
19185 CF_EOF
19186 fi
19187
19188 chmod 700 $MAN2HTML_TEMP
19189
19190 # If we have already established that there is a full termcap implementation,
19191 # suppress the definitions for terminfo that we make have imported from the
19192 # imake-file.
19193 if test "x$cf_cv_lib_tgetent" != xno || test "x$cf_cv_lib_part_tgetent" != xno ; then
19194 case "$IMAKE_CFLAGS" in
19195 (*-DUSE_TERMINFO\ -DHAVE_TIGETSTR*)
19196
19197 test -n "$verbose" && echo " removing terminfo flags from IMAKE_CFLAGS" 1>&6
19198
19199 echo "${as_me:-configure}:19199: testing removing terminfo flags from IMAKE_CFLAGS ..." 1>&5
19200
19201 IMAKE_CFLAGS=`echo "$IMAKE_CFLAGS" | sed -e 's/-DUSE_TERMINFO[ ]*-DHAVE_TIGETSTR[ ]*//'`
19202 test -n "$verbose" && echo " ...result $IMAKE_CFLAGS" 1>&6
19203
19204 echo "${as_me:-configure}:19204: testing ...result $IMAKE_CFLAGS ..." 1>&5
19205
19206 test -n "$verbose" && echo " removing terminfo flags from CPPFLAGS" 1>&6
19207
19208 echo "${as_me:-configure}:19208: testing removing terminfo flags from CPPFLAGS ..." 1>&5
19209
19210 CPPFLAGS=`echo "$CPPFLAGS" | sed -e 's/-DUSE_TERMINFO[ ]*-DHAVE_TIGETSTR[ ]*//'`
19211 test -n "$verbose" && echo " ...result $CPPFLAGS" 1>&6
19212
19213 echo "${as_me:-configure}:19213: testing ...result $CPPFLAGS ..." 1>&5
19214
19215 ;;
19216 esac
19217 fi
19218
19219 ###############################################################################
19220
19221 echo "$as_me:19221: checking for default terminal-id" >&5
19222 echo $ECHO_N "checking for default terminal-id... $ECHO_C" >&6
19223
19224 # Check whether --with-terminal-id or --without-terminal-id was given.
19225 if test "${with_terminal_id+set}" = set; then
19226 withval="$with_terminal_id"
19227 default_termid=$withval
19228 else
19229 default_termid=vt420
19230 fi;
19231 echo "$as_me:19231: result: $default_termid" >&5
19232 echo "${ECHO_T}$default_termid" >&6
19233 case $default_termid in
19234 (vt*) default_termid=`echo $default_termid | sed -e 's/^..//'`
19235 ;;
19236 ([1-9][0-9][0-9]|[1-9][0-9])
19237 ;;
19238 (*)
19239 { { echo "$as_me:19239: error: expected a number, not $default_termid" >&5
19240 echo "$as_me: error: expected a number, not $default_termid" >&2;}
19241 { (exit 1); exit 1; }; }
19242 ;;
19243 esac
19244
19245 cat >>confdefs.h <<EOF
19246 #define DFT_DECID "$default_termid"
19247 EOF
19248
19249 echo "$as_me:19249: checking for default terminal-type" >&5
19250 echo $ECHO_N "checking for default terminal-type... $ECHO_C" >&6
19251
19252 # Check whether --with-terminal-type or --without-terminal-type was given.
19253 if test "${with_terminal_type+set}" = set; then
19254 withval="$with_terminal_type"
19255 default_TERM=$withval
19256 else
19257 default_TERM=xterm
19258 fi;
19259 echo "$as_me:19259: result: $default_TERM" >&5
19260 echo "${ECHO_T}$default_TERM" >&6
19261
19262 cat >>confdefs.h <<EOF
19263 #define DFT_TERMTYPE "$default_TERM"
19264 EOF
19265
19266 ###############################################################################
19267
19268 case $host_os in
19269 (linux*gnu*|uclinux*|gnu*|mint*|k*bsd*-gnu|cygwin|msys|mingw*|linux*uclibc|linux*musl|openbsd*|darwin*)
19270 want_xterm_kbs=DEL
19271 ;;
19272 (*)
19273 want_xterm_kbs=BS
19274 ;;
19275 esac
19276
19277 echo "$as_me:19277: checking if xterm backspace-key sends BS or DEL" >&5
19278 echo $ECHO_N "checking if xterm backspace-key sends BS or DEL... $ECHO_C" >&6
19279
19280 # Check whether --with-xterm-kbs or --without-xterm-kbs was given.
19281 if test "${with_xterm_kbs+set}" = set; then
19282 withval="$with_xterm_kbs"
19283 with_xterm_kbs=$withval
19284 else
19285 with_xterm_kbs=auto
19286 fi;
19287 case x$with_xterm_kbs in
19288 (xyes|xno|xBS|xbs|x8)
19289 with_xterm_kbs=BS
19290 ;;
19291 (xDEL|xdel|x127)
19292 with_xterm_kbs=DEL
19293 ;;
19294 (xauto)
19295 with_xterm_kbs=$want_xterm_kbs
19296 ;;
19297 (*)
19298 with_xterm_kbs=$withval
19299 ;;
19300 esac
19301 echo "$as_me:19301: result: $with_xterm_kbs" >&5
19302 echo "${ECHO_T}$with_xterm_kbs" >&6
19303 XTERM_KBS=$with_xterm_kbs
19304
19305 if test "x$with_xterm_kbs" != "x$want_xterm_kbs"
19306 then
19307 { echo "$as_me:19307: WARNING: expected --with-xterm-kbs=$want_xterm_kbs for $host_os, have $with_xterm_kbs" >&5
19308 echo "$as_me: WARNING: expected --with-xterm-kbs=$want_xterm_kbs for $host_os, have $with_xterm_kbs" >&2;}
19309 fi
19310
19311 cat >>confdefs.h <<EOF
19312 #define XTERM_ERASE ANSI_$with_xterm_kbs
19313 EOF
19314
19315 echo "$as_me:19315: checking if backarrow-key should be BS" >&5
19316 echo $ECHO_N "checking if backarrow-key should be BS... $ECHO_C" >&6
19317
19318 # Check whether --enable-backarrow-key or --disable-backarrow-key was given.
19319 if test "${enable_backarrow_key+set}" = set; then
19320 enableval="$enable_backarrow_key"
19321 test "$enableval" != no && enableval=yes
19322 if test "$enableval" != "yes" ; then
19323 backarrow_is_bs=$enableval
19324 else
19325 backarrow_is_bs=yes
19326 fi
19327 else
19328 enableval=yes
19329 backarrow_is_bs=yes
19330
19331 fi;
19332
19333 echo "$as_me:19333: result: $backarrow_is_bs" >&5
19334 echo "${ECHO_T}$backarrow_is_bs" >&6
19335 case $backarrow_is_bs in
19336 (yes)
19337 backarrow_is_bs=true
19338 ;;
19339 (no)
19340 backarrow_is_bs=false
19341 ;;
19342 esac
19343 cf_xbool1=`echo "$backarrow_is_bs"|sed -e 's/^\(.\).*/\1/'`
19344
19345 cf_xbool1=`echo "$cf_xbool1" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19346
19347 cf_xbool2=`echo "$backarrow_is_bs"|sed -e 's/^.//'`
19348 backarrow_is_bs=${cf_xbool1}${cf_xbool2}
19349
19350 cat >>confdefs.h <<EOF
19351 #define DEF_BACKARO_BS $backarrow_is_bs
19352 EOF
19353
19354 echo "$as_me:19354: checking if backarrow-key should be treated as erase" >&5
19355 echo $ECHO_N "checking if backarrow-key should be treated as erase... $ECHO_C" >&6
19356
19357 # Check whether --enable-backarrow-is-erase or --disable-backarrow-is-erase was given.
19358 if test "${enable_backarrow_is_erase+set}" = set; then
19359 enableval="$enable_backarrow_is_erase"
19360 test "$enableval" != yes && enableval=no
19361 if test "$enableval" != "no" ; then
19362 backarrow_is_erase=$enableval
19363 else
19364 backarrow_is_erase=no
19365 fi
19366 else
19367 enableval=no
19368 backarrow_is_erase=no
19369
19370 fi;
19371
19372 echo "$as_me:19372: result: $backarrow_is_erase" >&5
19373 echo "${ECHO_T}$backarrow_is_erase" >&6
19374 case $backarrow_is_erase in
19375 (yes)
19376 backarrow_is_erase=true
19377 ;;
19378 (no)
19379 backarrow_is_erase=false
19380 ;;
19381 esac
19382 cf_xbool1=`echo "$backarrow_is_erase"|sed -e 's/^\(.\).*/\1/'`
19383
19384 cf_xbool1=`echo "$cf_xbool1" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19385
19386 cf_xbool2=`echo "$backarrow_is_erase"|sed -e 's/^.//'`
19387 backarrow_is_erase=${cf_xbool1}${cf_xbool2}
19388
19389 cat >>confdefs.h <<EOF
19390 #define DEF_BACKARO_ERASE $backarrow_is_erase
19391 EOF
19392
19393 echo "$as_me:19393: checking for default backspace/DEL setting" >&5
19394 echo $ECHO_N "checking for default backspace/DEL setting... $ECHO_C" >&6
19395
19396 # Check whether --enable-delete-is-del or --disable-delete-is-del was given.
19397 if test "${enable_delete_is_del+set}" = set; then
19398 enableval="$enable_delete_is_del"
19399 delete_is_del=$enableval
19400 else
19401 delete_is_del=maybe
19402 fi;
19403
19404 echo "$as_me:19404: result: $delete_is_del" >&5
19405 echo "${ECHO_T}$delete_is_del" >&6
19406 case $delete_is_del in
19407 (yes)
19408 delete_is_del=true
19409 ;;
19410 (no)
19411 delete_is_del=false
19412 ;;
19413 esac
19414 cf_xbool1=`echo "$delete_is_del"|sed -e 's/^\(.\).*/\1/'`
19415
19416 cf_xbool1=`echo "$cf_xbool1" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19417
19418 cf_xbool2=`echo "$delete_is_del"|sed -e 's/^.//'`
19419 delete_is_del=${cf_xbool1}${cf_xbool2}
19420
19421 cat >>confdefs.h <<EOF
19422 #define DEFDELETE_DEL $delete_is_del
19423 EOF
19424
19425 echo "$as_me:19425: checking for default pty initial erase setting" >&5
19426 echo $ECHO_N "checking for default pty initial erase setting... $ECHO_C" >&6
19427
19428 # Check whether --enable-pty-erase or --disable-pty-erase was given.
19429 if test "${enable_pty_erase+set}" = set; then
19430 enableval="$enable_pty_erase"
19431 initial_erase=$enableval
19432 else
19433 initial_erase=False
19434 fi;
19435
19436 echo "$as_me:19436: result: $initial_erase" >&5
19437 echo "${ECHO_T}$initial_erase" >&6
19438 case $initial_erase in
19439 (yes)
19440 initial_erase=true
19441 ;;
19442 (no)
19443 initial_erase=false
19444 ;;
19445 esac
19446 cf_xbool1=`echo "$initial_erase"|sed -e 's/^\(.\).*/\1/'`
19447
19448 cf_xbool1=`echo "$cf_xbool1" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19449
19450 cf_xbool2=`echo "$initial_erase"|sed -e 's/^.//'`
19451 initial_erase=${cf_xbool1}${cf_xbool2}
19452
19453 cat >>confdefs.h <<EOF
19454 #define DEF_INITIAL_ERASE $initial_erase
19455 EOF
19456
19457 echo "$as_me:19457: checking if alt should send ESC" >&5
19458 echo $ECHO_N "checking if alt should send ESC... $ECHO_C" >&6
19459
19460 # Check whether --enable-alt-sends-esc or --disable-alt-sends-esc was given.
19461 if test "${enable_alt_sends_esc+set}" = set; then
19462 enableval="$enable_alt_sends_esc"
19463 test "$enableval" != yes && enableval=no
19464 if test "$enableval" != "no" ; then
19465 alt_sends_esc=$enableval
19466 else
19467 alt_sends_esc=no
19468 fi
19469 else
19470 enableval=no
19471 alt_sends_esc=no
19472
19473 fi;
19474
19475 echo "$as_me:19475: result: $alt_sends_esc" >&5
19476 echo "${ECHO_T}$alt_sends_esc" >&6
19477 case $alt_sends_esc in
19478 (yes)
19479 alt_sends_esc=true
19480 ;;
19481 (no)
19482 alt_sends_esc=false
19483 ;;
19484 esac
19485 cf_xbool1=`echo "$alt_sends_esc"|sed -e 's/^\(.\).*/\1/'`
19486
19487 cf_xbool1=`echo "$cf_xbool1" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19488
19489 cf_xbool2=`echo "$alt_sends_esc"|sed -e 's/^.//'`
19490 alt_sends_esc=${cf_xbool1}${cf_xbool2}
19491
19492 cat >>confdefs.h <<EOF
19493 #define DEF_ALT_SENDS_ESC $alt_sends_esc
19494 EOF
19495
19496 echo "$as_me:19496: checking if meta should send ESC" >&5
19497 echo $ECHO_N "checking if meta should send ESC... $ECHO_C" >&6
19498
19499 # Check whether --enable-meta-sends-esc or --disable-meta-sends-esc was given.
19500 if test "${enable_meta_sends_esc+set}" = set; then
19501 enableval="$enable_meta_sends_esc"
19502 test "$enableval" != yes && enableval=no
19503 if test "$enableval" != "no" ; then
19504 meta_sends_esc=$enableval
19505 else
19506 meta_sends_esc=no
19507 fi
19508 else
19509 enableval=no
19510 meta_sends_esc=no
19511
19512 fi;
19513
19514 echo "$as_me:19514: result: $meta_sends_esc" >&5
19515 echo "${ECHO_T}$meta_sends_esc" >&6
19516 case $meta_sends_esc in
19517 (yes)
19518 meta_sends_esc=true
19519 ;;
19520 (no)
19521 meta_sends_esc=false
19522 ;;
19523 esac
19524 cf_xbool1=`echo "$meta_sends_esc"|sed -e 's/^\(.\).*/\1/'`
19525
19526 cf_xbool1=`echo "$cf_xbool1" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
19527
19528 cf_xbool2=`echo "$meta_sends_esc"|sed -e 's/^.//'`
19529 meta_sends_esc=${cf_xbool1}${cf_xbool2}
19530
19531 cat >>confdefs.h <<EOF
19532 #define DEF_META_SENDS_ESC $meta_sends_esc
19533 EOF
19534
19535 ###############################################################################
19536 # Extract the first word of "tic", so it can be a program name with args.
19537 set dummy tic; ac_word=$2
19538 echo "$as_me:19538: checking for $ac_word" >&5
19539 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
19540 if test "${ac_cv_prog_cf_tic_prog+set}" = set; then
19541 echo $ECHO_N "(cached) $ECHO_C" >&6
19542 else
19543 if test -n "$cf_tic_prog"; then
19544 ac_cv_prog_cf_tic_prog="$cf_tic_prog" # Let the user override the test.
19545 else
19546 ac_save_IFS=$IFS; IFS=$ac_path_separator
19547 ac_dummy="$PATH"
19548 for ac_dir in $ac_dummy; do
19549 IFS=$ac_save_IFS
19550 test -z "$ac_dir" && ac_dir=.
19551 $as_executable_p "$ac_dir/$ac_word" || continue
19552 ac_cv_prog_cf_tic_prog="yes"
19553 echo "$as_me:19553: found $ac_dir/$ac_word" >&5
19554 break
19555 done
19556
19557 test -z "$ac_cv_prog_cf_tic_prog" && ac_cv_prog_cf_tic_prog="no"
19558 fi
19559 fi
19560 cf_tic_prog=$ac_cv_prog_cf_tic_prog
19561 if test -n "$cf_tic_prog"; then
19562 echo "$as_me:19562: result: $cf_tic_prog" >&5
19563 echo "${ECHO_T}$cf_tic_prog" >&6
19564 else
19565 echo "$as_me:19565: result: no" >&5
19566 echo "${ECHO_T}no" >&6
19567 fi
19568
19569 if test "$cf_tic_prog" = yes ; then
19570 if test -n "$TERMINFO"
19571 then
19572 case "$TERMINFO" in
19573 (/*)
19574 test -d "$TERMINFO" || unset TERMINFO
19575 ;;
19576 (*)
19577 unset TERMINFO
19578 ;;
19579 esac
19580 fi
19581 echo "$as_me:19581: checking for private terminfo-directory" >&5
19582 echo $ECHO_N "checking for private terminfo-directory... $ECHO_C" >&6
19583
19584 # Check whether --with-own-terminfo or --without-own-terminfo was given.
19585 if test "${with_own_terminfo+set}" = set; then
19586 withval="$with_own_terminfo"
19587 TERMINFO_DIR=$withval
19588 else
19589 TERMINFO_DIR=${TERMINFO-none}
19590 fi;
19591 echo "$as_me:19591: result: $TERMINFO_DIR" >&5
19592 echo "${ECHO_T}$TERMINFO_DIR" >&6
19593 if test "$TERMINFO_DIR" = yes ; then
19594 { echo "$as_me:19594: WARNING: no value given" >&5
19595 echo "$as_me: WARNING: no value given" >&2;}
19596 elif test "$TERMINFO_DIR" != none ; then
19597 if test -d "$TERMINFO_DIR" ; then
19598
19599 cat >>confdefs.h <<EOF
19600 #define OWN_TERMINFO_DIR "$TERMINFO_DIR"
19601 EOF
19602
19603 echo "$as_me:19603: checking if \$TERMINFO should also be set" >&5
19604 echo $ECHO_N "checking if \$TERMINFO should also be set... $ECHO_C" >&6
19605
19606 # Check whether --enable-env-terminfo or --disable-env-terminfo was given.
19607 if test "${enable_env_terminfo+set}" = set; then
19608 enableval="$enable_env_terminfo"
19609 cf_env_terminfo=yes
19610 else
19611 cf_env_terminfo=no
19612 fi;
19613 echo "$as_me:19613: result: $cf_env_terminfo" >&5
19614 echo "${ECHO_T}$cf_env_terminfo" >&6
19615 test $cf_env_terminfo = yes &&
19616
19617 cat >>confdefs.h <<\EOF
19618 #define OWN_TERMINFO_ENV 1
19619 EOF
19620
19621 else
19622 { echo "$as_me:19622: WARNING: not a directory" >&5
19623 echo "$as_me: WARNING: not a directory" >&2;}
19624 fi
19625 elif test "$prefix" != NONE ; then
19626 TERMINFO_DIR='${prefix}/lib/terminfo'
19627 elif test -d /usr/lib/terminfo ; then
19628 TERMINFO_DIR=/usr/lib/terminfo
19629 else
19630 TERMINFO_DIR=
19631 fi
19632 SET_TERMINFO=
19633 if test -n "$TERMINFO_DIR" ; then
19634 TERMINFO_DIR='${DESTDIR}'$TERMINFO_DIR
19635 SET_TERMINFO='TERMINFO=${TERMINFO_DIR}'
19636 fi
19637 no_ticprog=
19638 else
19639 no_ticprog="#"
19640 TERMINFO_DIR=
19641 SET_TERMINFO=
19642 fi
19643
19644 ###############################################################################
19645
19646 echo "$as_me:19646: checking if you want active-icons" >&5
19647 echo $ECHO_N "checking if you want active-icons... $ECHO_C" >&6
19648
19649 # Check whether --enable-active-icon or --disable-active-icon was given.
19650 if test "${enable_active_icon+set}" = set; then
19651 enableval="$enable_active_icon"
19652 test "$enableval" != no && enableval=yes
19653 if test "$enableval" != "yes" ; then
19654 enable_active_icon=no
19655 else
19656 enable_active_icon=yes
19657 fi
19658 else
19659 enableval=yes
19660 enable_active_icon=yes
19661
19662 fi;
19663 echo "$as_me:19663: result: $enable_active_icon" >&5
19664 echo "${ECHO_T}$enable_active_icon" >&6
19665 if test "$enable_active_icon" = no ; then
19666
19667 cat >>confdefs.h <<\EOF
19668 #define NO_ACTIVE_ICON 1
19669 EOF
19670
19671 fi
19672
19673 echo "$as_me:19673: checking if you want ANSI color" >&5
19674 echo $ECHO_N "checking if you want ANSI color... $ECHO_C" >&6
19675
19676 # Check whether --enable-ansi-color or --disable-ansi-color was given.
19677 if test "${enable_ansi_color+set}" = set; then
19678 enableval="$enable_ansi_color"
19679 test "$enableval" != no && enableval=yes
19680 if test "$enableval" != "yes" ; then
19681 enable_ansi_color=no
19682 else
19683 enable_ansi_color=yes
19684 fi
19685 else
19686 enableval=yes
19687 enable_ansi_color=yes
19688
19689 fi;
19690 echo "$as_me:19690: result: $enable_ansi_color" >&5
19691 echo "${ECHO_T}$enable_ansi_color" >&6
19692 test "$enable_ansi_color" = no &&
19693 cat >>confdefs.h <<\EOF
19694 #define OPT_ISO_COLORS 0
19695 EOF
19696
19697 if test "$enable_ansi_color" = yes ; then
19698
19699 echo "$as_me:19699: checking if you want 16 colors like aixterm" >&5
19700 echo $ECHO_N "checking if you want 16 colors like aixterm... $ECHO_C" >&6
19701
19702 # Check whether --enable-16-color or --disable-16-color was given.
19703 if test "${enable_16_color+set}" = set; then
19704 enableval="$enable_16_color"
19705 test "$enableval" != no && enableval=yes
19706 if test "$enableval" != "yes" ; then
19707 enable_16_color=no
19708 else
19709 enable_16_color=yes
19710 fi
19711 else
19712 enableval=yes
19713 enable_16_color=yes
19714
19715 fi;
19716 echo "$as_me:19716: result: $enable_16_color" >&5
19717 echo "${ECHO_T}$enable_16_color" >&6
19718 test "$enable_16_color" = no &&
19719 cat >>confdefs.h <<\EOF
19720 #define OPT_AIX_COLORS 0
19721 EOF
19722
19723 echo "$as_me:19723: checking if you want 256 colors" >&5
19724 echo $ECHO_N "checking if you want 256 colors... $ECHO_C" >&6
19725
19726 # Check whether --enable-256-color or --disable-256-color was given.
19727 if test "${enable_256_color+set}" = set; then
19728 enableval="$enable_256_color"
19729 test "$enableval" != no && enableval=yes
19730 if test "$enableval" != "yes" ; then
19731 enable_256_color=no
19732 else
19733 enable_256_color=yes
19734 fi
19735 else
19736 enableval=yes
19737 enable_256_color=yes
19738
19739 fi;
19740 echo "$as_me:19740: result: $enable_256_color" >&5
19741 echo "${ECHO_T}$enable_256_color" >&6
19742
19743 if test "$enable_256_color" = yes ; then
19744
19745 CHARPROC_DEPS="$CHARPROC_DEPS 256colres.h"
19746 EXTRAHDRS="$EXTRAHDRS 256colres.h"
19747
19748 cat >>confdefs.h <<\EOF
19749 #define OPT_256_COLORS 1
19750 EOF
19751
19752 echo "$as_me:19752: checking if you want direct-color support" >&5
19753 echo $ECHO_N "checking if you want direct-color support... $ECHO_C" >&6
19754
19755 # Check whether --enable-direct-color or --disable-direct-color was given.
19756 if test "${enable_direct_color+set}" = set; then
19757 enableval="$enable_direct_color"
19758 test "$enableval" != no && enableval=yes
19759 if test "$enableval" != "yes" ; then
19760 enable_direct_color=no
19761 else
19762 enable_direct_color=yes
19763 fi
19764 else
19765 enableval=yes
19766 enable_direct_color=yes
19767
19768 fi;
19769 echo "$as_me:19769: result: $enable_direct_color" >&5
19770 echo "${ECHO_T}$enable_direct_color" >&6
19771 if test "$enable_direct_color" = yes ; then
19772
19773 cat >>confdefs.h <<\EOF
19774 #define OPT_DIRECT_COLOR 1
19775 EOF
19776
19777 fi
19778
19779 else
19780
19781 echo "$as_me:19781: checking if you want 88 colors" >&5
19782 echo $ECHO_N "checking if you want 88 colors... $ECHO_C" >&6
19783
19784 # Check whether --enable-88-color or --disable-88-color was given.
19785 if test "${enable_88_color+set}" = set; then
19786 enableval="$enable_88_color"
19787 test "$enableval" != no && enableval=yes
19788 if test "$enableval" != "yes" ; then
19789 enable_88_color=no
19790 else
19791 enable_88_color=yes
19792 fi
19793 else
19794 enableval=yes
19795 enable_88_color=yes
19796
19797 fi;
19798 echo "$as_me:19798: result: $enable_88_color" >&5
19799 echo "${ECHO_T}$enable_88_color" >&6
19800 if test "$enable_88_color" = yes ; then
19801 CHARPROC_DEPS="$CHARPROC_DEPS 88colres.h"
19802 EXTRAHDRS="$EXTRAHDRS 88colres.h"
19803
19804 cat >>confdefs.h <<\EOF
19805 #define OPT_88_COLORS 1
19806 EOF
19807
19808 fi
19809
19810 fi
19811
19812 fi
19813
19814 echo "$as_me:19814: checking if you want blinking cursor" >&5
19815 echo $ECHO_N "checking if you want blinking cursor... $ECHO_C" >&6
19816
19817 # Check whether --enable-blink-cursor or --disable-blink-cursor was given.
19818 if test "${enable_blink_cursor+set}" = set; then
19819 enableval="$enable_blink_cursor"
19820 test "$enableval" != no && enableval=yes
19821 if test "$enableval" != "yes" ; then
19822 enable_blink_curs=no
19823 else
19824 enable_blink_curs=yes
19825 fi
19826 else
19827 enableval=yes
19828 enable_blink_curs=yes
19829
19830 fi;
19831 echo "$as_me:19831: result: $enable_blink_curs" >&5
19832 echo "${ECHO_T}$enable_blink_curs" >&6
19833 test "$enable_blink_curs" = no &&
19834 cat >>confdefs.h <<\EOF
19835 #define OPT_BLINK_CURS 0
19836 EOF
19837
19838 echo "$as_me:19838: checking if you want support for block-selection" >&5
19839 echo $ECHO_N "checking if you want support for block-selection... $ECHO_C" >&6
19840
19841 # Check whether --enable-block-select or --disable-block-select was given.
19842 if test "${enable_block_select+set}" = set; then
19843 enableval="$enable_block_select"
19844 test "$enableval" != yes && enableval=no
19845 if test "$enableval" != "no" ; then
19846 enable_block_select=yes
19847 else
19848 enable_block_select=no
19849 fi
19850 else
19851 enableval=no
19852 enable_block_select=no
19853
19854 fi;
19855 echo "$as_me:19855: result: $enable_block_select" >&5
19856 echo "${ECHO_T}$enable_block_select" >&6
19857 if test "$enable_block_select" = yes ; then
19858
19859 cat >>confdefs.h <<\EOF
19860 #define OPT_BLOCK_SELECT 1
19861 EOF
19862
19863 else
19864
19865 cat >>confdefs.h <<\EOF
19866 #define OPT_BLOCK_SELECT 0
19867 EOF
19868
19869 fi
19870
19871 echo "$as_me:19871: checking if you want to ignore Linux's broken palette-strings" >&5
19872 echo $ECHO_N "checking if you want to ignore Linux's broken palette-strings... $ECHO_C" >&6
19873
19874 case $host_os in
19875 (linux*)
19876 assume_broken_osc=yes ;;
19877 (*)
19878 assume_broken_osc=no ;;
19879 esac
19880
19881 # Check whether --enable-broken-osc or --disable-broken-osc was given.
19882 if test "${enable_broken_osc+set}" = set; then
19883 enableval="$enable_broken_osc"
19884 test "$enableval" != no && enableval=yes
19885 if test "$enableval" != "$assume_broken_osc" ; then
19886 enable_broken_osc=$enableval
19887 else
19888 enable_broken_osc=$enableval
19889 fi
19890 else
19891 enableval=$assume_broken_osc
19892 enable_broken_osc=$enableval
19893
19894 fi;
19895 echo "$as_me:19895: result: $enable_broken_osc" >&5
19896 echo "${ECHO_T}$enable_broken_osc" >&6
19897 if test "$enable_broken_osc" = yes ; then
19898
19899 cat >>confdefs.h <<\EOF
19900 #define OPT_BROKEN_OSC 1
19901 EOF
19902
19903 else
19904
19905 cat >>confdefs.h <<\EOF
19906 #define OPT_BROKEN_OSC 0
19907 EOF
19908
19909 fi
19910
19911 echo "$as_me:19911: checking if you want to allow broken string-terminators" >&5
19912 echo $ECHO_N "checking if you want to allow broken string-terminators... $ECHO_C" >&6
19913
19914 # Check whether --enable-broken-st or --disable-broken-st was given.
19915 if test "${enable_broken_st+set}" = set; then
19916 enableval="$enable_broken_st"
19917 test "$enableval" != yes && enableval=no
19918 if test "$enableval" != "no" ; then
19919 enable_broken_st=no
19920 else
19921 enable_broken_st=yes
19922 fi
19923 else
19924 enableval=no
19925 enable_broken_st=yes
19926
19927 fi;
19928 echo "$as_me:19928: result: $enable_broken_st" >&5
19929 echo "${ECHO_T}$enable_broken_st" >&6
19930 test "$enable_broken_st" = no &&
19931 cat >>confdefs.h <<\EOF
19932 #define OPT_BROKEN_ST 0
19933 EOF
19934
19935 echo "$as_me:19935: checking if you want to compile-in icon data" >&5
19936 echo $ECHO_N "checking if you want to compile-in icon data... $ECHO_C" >&6
19937
19938 # Check whether --enable-builtin-xpms or --disable-builtin-xpms was given.
19939 if test "${enable_builtin_xpms+set}" = set; then
19940 enableval="$enable_builtin_xpms"
19941 test "$enableval" != yes && enableval=no
19942 if test "$enableval" != "no" ; then
19943 enable_builtin_xpms=yes
19944 else
19945 enable_builtin_xpms=no
19946 fi
19947 else
19948 enableval=no
19949 enable_builtin_xpms=no
19950
19951 fi;
19952 echo "$as_me:19952: result: $enable_builtin_xpms" >&5
19953 echo "${ECHO_T}$enable_builtin_xpms" >&6
19954 test "$enable_builtin_xpms" = yes &&
19955 cat >>confdefs.h <<\EOF
19956 #define OPT_BUILTIN_XPMS 1
19957 EOF
19958
19959 echo "$as_me:19959: checking if you want printable 128-159" >&5
19960 echo $ECHO_N "checking if you want printable 128-159... $ECHO_C" >&6
19961
19962 # Check whether --enable-c1-print or --disable-c1-print was given.
19963 if test "${enable_c1_print+set}" = set; then
19964 enableval="$enable_c1_print"
19965 test "$enableval" != no && enableval=yes
19966 if test "$enableval" != "yes" ; then
19967 enable_c1_print=no
19968 else
19969 enable_c1_print=yes
19970 fi
19971 else
19972 enableval=yes
19973 enable_c1_print=yes
19974
19975 fi;
19976 echo "$as_me:19976: result: $enable_c1_print" >&5
19977 echo "${ECHO_T}$enable_c1_print" >&6
19978 test "$enable_c1_print" = no &&
19979 cat >>confdefs.h <<\EOF
19980 #define OPT_C1_PRINT 0
19981 EOF
19982
19983 if test "$enable_ansi_color" = yes ; then
19984
19985 echo "$as_me:19985: checking if you want bold colors mapped like IBM PC" >&5
19986 echo $ECHO_N "checking if you want bold colors mapped like IBM PC... $ECHO_C" >&6
19987
19988 # Check whether --enable-bold-color or --disable-bold-color was given.
19989 if test "${enable_bold_color+set}" = set; then
19990 enableval="$enable_bold_color"
19991 test "$enableval" != no && enableval=yes
19992 if test "$enableval" != "yes" ; then
19993 enable_pc_color=no
19994 else
19995 enable_pc_color=yes
19996 fi
19997 else
19998 enableval=yes
19999 enable_pc_color=yes
20000
20001 fi;
20002 echo "$as_me:20002: result: $enable_pc_color" >&5
20003 echo "${ECHO_T}$enable_pc_color" >&6
20004 test "$enable_pc_color" = no &&
20005 cat >>confdefs.h <<\EOF
20006 #define OPT_PC_COLORS 0
20007 EOF
20008
20009 echo "$as_me:20009: checking if you want separate color-classes" >&5
20010 echo $ECHO_N "checking if you want separate color-classes... $ECHO_C" >&6
20011
20012 # Check whether --enable-color-class or --disable-color-class was given.
20013 if test "${enable_color_class+set}" = set; then
20014 enableval="$enable_color_class"
20015 test "$enableval" != no && enableval=yes
20016 if test "$enableval" != "yes" ; then
20017 enable_color_class=no
20018 else
20019 enable_color_class=yes
20020 fi
20021 else
20022 enableval=yes
20023 enable_color_class=yes
20024
20025 fi;
20026 echo "$as_me:20026: result: $enable_color_class" >&5
20027 echo "${ECHO_T}$enable_color_class" >&6
20028 test "$enable_color_class" = no &&
20029 cat >>confdefs.h <<\EOF
20030 #define OPT_COLOR_CLASS 0
20031 EOF
20032
20033 echo "$as_me:20033: checking if you want color-mode enabled by default" >&5
20034 echo $ECHO_N "checking if you want color-mode enabled by default... $ECHO_C" >&6
20035
20036 # Check whether --enable-color-mode or --disable-color-mode was given.
20037 if test "${enable_color_mode+set}" = set; then
20038 enableval="$enable_color_mode"
20039 test "$enableval" != no && enableval=yes
20040 if test "$enableval" != "yes" ; then
20041 default_colormode=no
20042 else
20043 default_colormode=yes
20044 fi
20045 else
20046 enableval=yes
20047 default_colormode=yes
20048
20049 fi;
20050 echo "$as_me:20050: result: $default_colormode" >&5
20051 echo "${ECHO_T}$default_colormode" >&6
20052 test "$default_colormode" = no &&
20053 cat >>confdefs.h <<\EOF
20054 #define DFT_COLORMODE 0
20055 EOF
20056
20057 fi
20058
20059 echo "$as_me:20059: checking if you want support for color highlighting" >&5
20060 echo $ECHO_N "checking if you want support for color highlighting... $ECHO_C" >&6
20061
20062 # Check whether --enable-highlighting or --disable-highlighting was given.
20063 if test "${enable_highlighting+set}" = set; then
20064 enableval="$enable_highlighting"
20065 test "$enableval" != no && enableval=yes
20066 if test "$enableval" != "yes" ; then
20067 default_highlight=no
20068 else
20069 default_highlight=yes
20070 fi
20071 else
20072 enableval=yes
20073 default_highlight=yes
20074
20075 fi;
20076 echo "$as_me:20076: result: $default_highlight" >&5
20077 echo "${ECHO_T}$default_highlight" >&6
20078 test "$default_highlight" = no &&
20079 cat >>confdefs.h <<\EOF
20080 #define OPT_HIGHLIGHT_COLOR 0
20081 EOF
20082
20083 echo "$as_me:20083: checking if you want support for doublesize characters" >&5
20084 echo $ECHO_N "checking if you want support for doublesize characters... $ECHO_C" >&6
20085
20086 # Check whether --enable-doublechars or --disable-doublechars was given.
20087 if test "${enable_doublechars+set}" = set; then
20088 enableval="$enable_doublechars"
20089 test "$enableval" != no && enableval=yes
20090 if test "$enableval" != "yes" ; then
20091 enable_doublechars=no
20092 else
20093 enable_doublechars=yes
20094 fi
20095 else
20096 enableval=yes
20097 enable_doublechars=yes
20098
20099 fi;
20100 echo "$as_me:20100: result: $enable_doublechars" >&5
20101 echo "${ECHO_T}$enable_doublechars" >&6
20102 test "$enable_doublechars" = no &&
20103 cat >>confdefs.h <<\EOF
20104 #define OPT_DEC_CHRSET 0
20105 EOF
20106
20107 echo "$as_me:20107: checking if you want fallback-support for box characters" >&5
20108 echo $ECHO_N "checking if you want fallback-support for box characters... $ECHO_C" >&6
20109
20110 # Check whether --enable-boxchars or --disable-boxchars was given.
20111 if test "${enable_boxchars+set}" = set; then
20112 enableval="$enable_boxchars"
20113 test "$enableval" != no && enableval=yes
20114 if test "$enableval" != "yes" ; then
20115 enable_boxchars=no
20116 else
20117 enable_boxchars=yes
20118 fi
20119 else
20120 enableval=yes
20121 enable_boxchars=yes
20122
20123 fi;
20124 echo "$as_me:20124: result: $enable_boxchars" >&5
20125 echo "${ECHO_T}$enable_boxchars" >&6
20126 test "$enable_boxchars" = no &&
20127 cat >>confdefs.h <<\EOF
20128 #define OPT_BOX_CHARS 0
20129 EOF
20130
20131 echo "$as_me:20131: checking if you want to allow spawning commands to process selections" >&5
20132 echo $ECHO_N "checking if you want to allow spawning commands to process selections... $ECHO_C" >&6
20133
20134 # Check whether --enable-exec-selection or --disable-exec-selection was given.
20135 if test "${enable_exec_selection+set}" = set; then
20136 enableval="$enable_exec_selection"
20137 test "$enableval" != no && enableval=yes
20138 if test "$enableval" != "yes" ; then
20139 enable_exec_selection=no
20140 else
20141 enable_exec_selection=yes
20142 fi
20143 else
20144 enableval=yes
20145 enable_exec_selection=yes
20146
20147 fi;
20148 echo "$as_me:20148: result: $enable_exec_selection" >&5
20149 echo "${ECHO_T}$enable_exec_selection" >&6
20150 if test "$enable_exec_selection" = no ; then
20151
20152 cat >>confdefs.h <<\EOF
20153 #define OPT_EXEC_SELECTION 0
20154 EOF
20155
20156 fi
20157
20158 echo "$as_me:20158: checking if you want to allow spawning new xterms" >&5
20159 echo $ECHO_N "checking if you want to allow spawning new xterms... $ECHO_C" >&6
20160
20161 # Check whether --enable-exec-xterm or --disable-exec-xterm was given.
20162 if test "${enable_exec_xterm+set}" = set; then
20163 enableval="$enable_exec_xterm"
20164 test "$enableval" != yes && enableval=no
20165 if test "$enableval" != "no" ; then
20166 enable_exec_xterm=yes
20167 else
20168 enable_exec_xterm=no
20169 fi
20170 else
20171 enableval=no
20172 enable_exec_xterm=no
20173
20174 fi;
20175 echo "$as_me:20175: result: $enable_exec_xterm" >&5
20176 echo "${ECHO_T}$enable_exec_xterm" >&6
20177 if test "$enable_exec_xterm" = yes ; then
20178
20179 echo "$as_me:20179: checking for proc tree with cwd-support" >&5
20180 echo $ECHO_N "checking for proc tree with cwd-support... $ECHO_C" >&6
20181 if test "${cf_cv_procfs_cwd+set}" = set; then
20182 echo $ECHO_N "(cached) $ECHO_C" >&6
20183 else
20184
20185 cf_cv_procfs_cwd=no
20186 for cf_path in /proc /compat/linux/proc /usr/compat/linux/proc
20187 do
20188 if test -d "$cf_path" && \
20189 test -d "$cf_path"/$$ && \
20190 { test -d "$cf_path"/$$/cwd || \
20191 test -L "$cf_path"/$$/cwd; }; then
20192 cf_cv_procfs_cwd="$cf_path"
20193 break
20194 fi
20195 done
20196
20197 fi
20198 echo "$as_me:20198: result: $cf_cv_procfs_cwd" >&5
20199 echo "${ECHO_T}$cf_cv_procfs_cwd" >&6
20200
20201 if test "$cf_cv_procfs_cwd" = no ; then
20202 { echo "$as_me:20202: WARNING: no suitable proc filesystem found" >&5
20203 echo "$as_me: WARNING: no suitable proc filesystem found" >&2;}
20204 else
20205
20206 cat >>confdefs.h <<EOF
20207 #define PROCFS_ROOT "$cf_cv_procfs_cwd"
20208 EOF
20209
20210 cat >>confdefs.h <<\EOF
20211 #define OPT_EXEC_XTERM 1
20212 EOF
20213
20214 fi
20215 fi
20216
20217 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "Xext"; then
20218 test -n "$verbose" && echo " found package Xext" 1>&6
20219
20220 echo "${as_me:-configure}:20220: testing found package Xext ..." 1>&5
20221
20222 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "Xext" 2>/dev/null`"
20223 cf_pkgconfig_libs="`$PKG_CONFIG --libs "Xext" 2>/dev/null`"
20224 test -n "$verbose" && echo " package Xext CFLAGS: $cf_pkgconfig_incs" 1>&6
20225
20226 echo "${as_me:-configure}:20226: testing package Xext CFLAGS: $cf_pkgconfig_incs ..." 1>&5
20227
20228 test -n "$verbose" && echo " package Xext LIBS: $cf_pkgconfig_libs" 1>&6
20229
20230 echo "${as_me:-configure}:20230: testing package Xext LIBS: $cf_pkgconfig_libs ..." 1>&5
20231
20232 for cf_required in Xext
20233 do
20234 # check for duplicates
20235 for cf_require_pkg in $REQUIRE_PKG
20236 do
20237 if test "$cf_required" = "$cf_require_pkg"
20238 then
20239 cf_required=
20240 break
20241 fi
20242 done
20243 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
20244 done
20245
20246 cf_fix_cppflags=no
20247 cf_new_cflags=
20248 cf_new_cppflags=
20249 cf_new_extra_cppflags=
20250
20251 for cf_add_cflags in $cf_pkgconfig_incs
20252 do
20253 case "$cf_fix_cppflags" in
20254 (no)
20255 case "$cf_add_cflags" in
20256 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
20257 case "$cf_add_cflags" in
20258 (-D*)
20259 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
20260
20261 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
20262 && test -z "${cf_tst_cflags}" \
20263 && cf_fix_cppflags=yes
20264
20265 if test "$cf_fix_cppflags" = yes ; then
20266
20267 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
20268 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
20269
20270 continue
20271 elif test "${cf_tst_cflags}" = "\"'" ; then
20272
20273 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
20274 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
20275
20276 continue
20277 fi
20278 ;;
20279 esac
20280 case "$CPPFLAGS" in
20281 (*$cf_add_cflags)
20282 ;;
20283 (*)
20284 case "$cf_add_cflags" in
20285 (-D*)
20286 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
20287
20288 CPPFLAGS=`echo "$CPPFLAGS" | \
20289 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
20290 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
20291
20292 ;;
20293 esac
20294
20295 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
20296 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
20297
20298 ;;
20299 esac
20300 ;;
20301 (*)
20302
20303 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
20304 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
20305
20306 ;;
20307 esac
20308 ;;
20309 (yes)
20310
20311 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
20312 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
20313
20314 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
20315
20316 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
20317 && test -z "${cf_tst_cflags}" \
20318 && cf_fix_cppflags=no
20319 ;;
20320 esac
20321 done
20322
20323 if test -n "$cf_new_cflags" ; then
20324
20325 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
20326 CFLAGS="${CFLAGS}$cf_new_cflags"
20327
20328 fi
20329
20330 if test -n "$cf_new_cppflags" ; then
20331
20332 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
20333 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
20334
20335 fi
20336
20337 if test -n "$cf_new_extra_cppflags" ; then
20338
20339 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
20340 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
20341
20342 fi
20343
20344 cf_add_libs="$LIBS"
20345 # reverse order
20346 cf_add_0lib=
20347 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
20348 # filter duplicates
20349 for cf_add_1lib in $cf_add_0lib; do
20350 for cf_add_2lib in $cf_add_libs; do
20351 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
20352 cf_add_1lib=
20353 break
20354 fi
20355 done
20356 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
20357 done
20358 LIBS="$cf_add_libs"
20359
20360 :
20361 else
20362 cf_pkgconfig_incs=
20363 cf_pkgconfig_libs=
20364
20365 echo "$as_me:20365: checking for XextCreateExtension in -lXext" >&5
20366 echo $ECHO_N "checking for XextCreateExtension in -lXext... $ECHO_C" >&6
20367 if test "${ac_cv_lib_Xext_XextCreateExtension+set}" = set; then
20368 echo $ECHO_N "(cached) $ECHO_C" >&6
20369 else
20370 ac_check_lib_save_LIBS=$LIBS
20371 LIBS="-lXext $LIBS"
20372 cat >"conftest.$ac_ext" <<_ACEOF
20373 #line 20373 "configure"
20374 #include "confdefs.h"
20375
20376 /* Override any gcc2 internal prototype to avoid an error. */
20377 #ifdef __cplusplus
20378 extern "C"
20379 #endif
20380 /* We use char because int might match the return type of a gcc2
20381 builtin and then its argument prototype would still apply. */
20382 char XextCreateExtension (void);
20383 int
20384 main (void)
20385 {
20386 XextCreateExtension ();
20387 ;
20388 return 0;
20389 }
20390 _ACEOF
20391 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
20392 if { (eval echo "$as_me:20392: \"$ac_link\"") >&5
20393 (eval $ac_link) 2>&5
20394 ac_status=$?
20395 echo "$as_me:20395: \$? = $ac_status" >&5
20396 (exit "$ac_status"); } &&
20397 { ac_try='test -s "conftest$ac_exeext"'
20398 { (eval echo "$as_me:20398: \"$ac_try\"") >&5
20399 (eval $ac_try) 2>&5
20400 ac_status=$?
20401 echo "$as_me:20401: \$? = $ac_status" >&5
20402 (exit "$ac_status"); }; }; then
20403 ac_cv_lib_Xext_XextCreateExtension=yes
20404 else
20405 echo "$as_me: failed program was:" >&5
20406 cat "conftest.$ac_ext" >&5
20407 ac_cv_lib_Xext_XextCreateExtension=no
20408 fi
20409 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
20410 LIBS=$ac_check_lib_save_LIBS
20411 fi
20412 echo "$as_me:20412: result: $ac_cv_lib_Xext_XextCreateExtension" >&5
20413 echo "${ECHO_T}$ac_cv_lib_Xext_XextCreateExtension" >&6
20414 if test "$ac_cv_lib_Xext_XextCreateExtension" = yes; then
20415
20416 cf_add_libs="$LIBS"
20417 # reverse order
20418 cf_add_0lib=
20419 for cf_add_1lib in -lXext; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
20420 # filter duplicates
20421 for cf_add_1lib in $cf_add_0lib; do
20422 for cf_add_2lib in $cf_add_libs; do
20423 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
20424 cf_add_1lib=
20425 break
20426 fi
20427 done
20428 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
20429 done
20430 LIBS="$cf_add_libs"
20431
20432 fi
20433
20434 fi
20435
20436 echo "$as_me:20436: checking for X11/extensions/Xdbe.h" >&5
20437 echo $ECHO_N "checking for X11/extensions/Xdbe.h... $ECHO_C" >&6
20438 if test "${ac_cv_header_X11_extensions_Xdbe_h+set}" = set; then
20439 echo $ECHO_N "(cached) $ECHO_C" >&6
20440 else
20441 cat >"conftest.$ac_ext" <<_ACEOF
20442 #line 20442 "configure"
20443 #include "confdefs.h"
20444 #include <X11/extensions/Xdbe.h>
20445 _ACEOF
20446 if { (eval echo "$as_me:20446: \"$ac_cpp "conftest.$ac_ext"\"") >&5
20447 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
20448 ac_status=$?
20449 $EGREP -v '^ *\+' conftest.er1 >conftest.err
20450 rm -f conftest.er1
20451 cat conftest.err >&5
20452 echo "$as_me:20452: \$? = $ac_status" >&5
20453 (exit "$ac_status"); } >/dev/null; then
20454 if test -s conftest.err; then
20455 ac_cpp_err=$ac_c_preproc_warn_flag
20456 else
20457 ac_cpp_err=
20458 fi
20459 else
20460 ac_cpp_err=yes
20461 fi
20462 if test -z "$ac_cpp_err"; then
20463 ac_cv_header_X11_extensions_Xdbe_h=yes
20464 else
20465 echo "$as_me: failed program was:" >&5
20466 cat "conftest.$ac_ext" >&5
20467 ac_cv_header_X11_extensions_Xdbe_h=no
20468 fi
20469 rm -f conftest.err "conftest.$ac_ext"
20470 fi
20471 echo "$as_me:20471: result: $ac_cv_header_X11_extensions_Xdbe_h" >&5
20472 echo "${ECHO_T}$ac_cv_header_X11_extensions_Xdbe_h" >&6
20473 if test "$ac_cv_header_X11_extensions_Xdbe_h" = yes; then
20474
20475 cat >>confdefs.h <<\EOF
20476 #define HAVE_X11_EXTENSIONS_XDBE_H 1
20477 EOF
20478
20479 echo "$as_me:20479: checking for XdbeSwapBuffers" >&5
20480 echo $ECHO_N "checking for XdbeSwapBuffers... $ECHO_C" >&6
20481 if test "${ac_cv_func_XdbeSwapBuffers+set}" = set; then
20482 echo $ECHO_N "(cached) $ECHO_C" >&6
20483 else
20484 cat >"conftest.$ac_ext" <<_ACEOF
20485 #line 20485 "configure"
20486 #include "confdefs.h"
20487 #define XdbeSwapBuffers autoconf_temporary
20488 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
20489 #undef XdbeSwapBuffers
20490
20491 #ifdef __cplusplus
20492 extern "C"
20493 #endif
20494
20495 /* We use char because int might match the return type of a gcc2
20496 builtin and then its argument prototype would still apply. */
20497 char XdbeSwapBuffers (void);
20498
20499 int
20500 main (void)
20501 {
20502
20503 /* The GNU C library defines stubs for functions which it implements
20504 to always fail with ENOSYS. Some functions are actually named
20505 something starting with __ and the normal name is an alias. */
20506 #if defined (__stub_XdbeSwapBuffers) || defined (__stub___XdbeSwapBuffers)
20507 #error found stub for XdbeSwapBuffers
20508 #endif
20509
20510 return XdbeSwapBuffers ();
20511 ;
20512 return 0;
20513 }
20514 _ACEOF
20515 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
20516 if { (eval echo "$as_me:20516: \"$ac_link\"") >&5
20517 (eval $ac_link) 2>&5
20518 ac_status=$?
20519 echo "$as_me:20519: \$? = $ac_status" >&5
20520 (exit "$ac_status"); } &&
20521 { ac_try='test -s "conftest$ac_exeext"'
20522 { (eval echo "$as_me:20522: \"$ac_try\"") >&5
20523 (eval $ac_try) 2>&5
20524 ac_status=$?
20525 echo "$as_me:20525: \$? = $ac_status" >&5
20526 (exit "$ac_status"); }; }; then
20527 ac_cv_func_XdbeSwapBuffers=yes
20528 else
20529 echo "$as_me: failed program was:" >&5
20530 cat "conftest.$ac_ext" >&5
20531 ac_cv_func_XdbeSwapBuffers=no
20532 fi
20533 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
20534 fi
20535 echo "$as_me:20535: result: $ac_cv_func_XdbeSwapBuffers" >&5
20536 echo "${ECHO_T}$ac_cv_func_XdbeSwapBuffers" >&6
20537 if test "$ac_cv_func_XdbeSwapBuffers" = yes; then
20538
20539 cat >>confdefs.h <<\EOF
20540 #define HAVE_XDBESWAPBUFFERS 1
20541 EOF
20542
20543 cf_x_ext_double_buffer=yes
20544 fi
20545
20546 fi
20547
20548 double_buffer=False
20549 if test "$cf_x_ext_double_buffer" = yes ; then
20550 echo "$as_me:20550: checking if you want to enable double-buffering in default resources" >&5
20551 echo $ECHO_N "checking if you want to enable double-buffering in default resources... $ECHO_C" >&6
20552
20553 # Check whether --enable-double-buffer or --disable-double-buffer was given.
20554 if test "${enable_double_buffer+set}" = set; then
20555 enableval="$enable_double_buffer"
20556 test "$enableval" != yes && enableval=no
20557 if test "$enableval" != "no" ; then
20558 enable_double_bfr=yes
20559 else
20560 enable_double_bfr=no
20561 fi
20562 else
20563 enableval=no
20564 enable_double_bfr=no
20565
20566 fi;
20567 echo "$as_me:20567: result: $enable_double_bfr" >&5
20568 echo "${ECHO_T}$enable_double_bfr" >&6
20569 if test "$enable_double_bfr" = yes ; then
20570
20571 cat >>confdefs.h <<\EOF
20572 #define OPT_DOUBLE_BUFFER 1
20573 EOF
20574
20575 double_buffer=True
20576 fi
20577 fi
20578
20579 echo "$as_me:20579: checking if you want to use FreeType library" >&5
20580 echo $ECHO_N "checking if you want to use FreeType library... $ECHO_C" >&6
20581
20582 # Check whether --enable-freetype or --disable-freetype was given.
20583 if test "${enable_freetype+set}" = set; then
20584 enableval="$enable_freetype"
20585 test "$enableval" != no && enableval=yes
20586 if test "$enableval" != "yes" ; then
20587 enable_freetype=no
20588 else
20589 enable_freetype=yes
20590 fi
20591 else
20592 enableval=yes
20593 enable_freetype=yes
20594
20595 fi;
20596 echo "$as_me:20596: result: $enable_freetype" >&5
20597 echo "${ECHO_T}$enable_freetype" >&6
20598 if test "$enable_freetype" = yes ; then
20599
20600 cf_cv_x_freetype_incs=no
20601 cf_cv_x_freetype_libs=no
20602 cf_extra_freetype_libs=
20603 FREETYPE_CONFIG=none
20604 FREETYPE_PARAMS=
20605
20606 echo "$as_me:20606: checking for FreeType configuration script" >&5
20607 echo $ECHO_N "checking for FreeType configuration script... $ECHO_C" >&6
20608
20609 # Check whether --with-freetype-config or --without-freetype-config was given.
20610 if test "${with_freetype_config+set}" = set; then
20611 withval="$with_freetype_config"
20612 cf_cv_x_freetype_cfgs="$withval"
20613 else
20614 cf_cv_x_freetype_cfgs=auto
20615 fi;
20616 test -z $cf_cv_x_freetype_cfgs && cf_cv_x_freetype_cfgs=auto
20617 test $cf_cv_x_freetype_cfgs = no && cf_cv_x_freetype_cfgs=none
20618 echo "$as_me:20618: result: $cf_cv_x_freetype_cfgs" >&5
20619 echo "${ECHO_T}$cf_cv_x_freetype_cfgs" >&6
20620
20621 case $cf_cv_x_freetype_cfgs in
20622 (none)
20623 echo "$as_me:20623: checking if you specified -D/-I options for FreeType" >&5
20624 echo $ECHO_N "checking if you specified -D/-I options for FreeType... $ECHO_C" >&6
20625
20626 # Check whether --with-freetype-cflags or --without-freetype-cflags was given.
20627 if test "${with_freetype_cflags+set}" = set; then
20628 withval="$with_freetype_cflags"
20629 cf_cv_x_freetype_incs="$with_freetype_cflags"
20630 else
20631 cf_cv_x_freetype_incs=no
20632 fi;
20633 echo "$as_me:20633: result: $cf_cv_x_freetype_incs" >&5
20634 echo "${ECHO_T}$cf_cv_x_freetype_incs" >&6
20635
20636 echo "$as_me:20636: checking if you specified -L/-l options for FreeType" >&5
20637 echo $ECHO_N "checking if you specified -L/-l options for FreeType... $ECHO_C" >&6
20638
20639 # Check whether --with-freetype-libs or --without-freetype-libs was given.
20640 if test "${with_freetype_libs+set}" = set; then
20641 withval="$with_freetype_libs"
20642 cf_cv_x_freetype_libs="$with_freetype_libs"
20643 else
20644 cf_cv_x_freetype_libs=no
20645 fi;
20646 echo "$as_me:20646: result: $cf_cv_x_freetype_libs" >&5
20647 echo "${ECHO_T}$cf_cv_x_freetype_libs" >&6
20648 ;;
20649 (auto)
20650 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists freetype2; then
20651 FREETYPE_CONFIG=$PKG_CONFIG
20652 FREETYPE_PARAMS=freetype2
20653 else
20654 # Extract the first word of "freetype-config", so it can be a program name with args.
20655 set dummy freetype-config; ac_word=$2
20656 echo "$as_me:20656: checking for $ac_word" >&5
20657 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
20658 if test "${ac_cv_path_FREETYPE_CONFIG+set}" = set; then
20659 echo $ECHO_N "(cached) $ECHO_C" >&6
20660 else
20661 case $FREETYPE_CONFIG in
20662 [\\/]* | ?:[\\/]*)
20663 ac_cv_path_FREETYPE_CONFIG="$FREETYPE_CONFIG" # Let the user override the test with a path.
20664 ;;
20665 *)
20666 ac_save_IFS=$IFS; IFS=$ac_path_separator
20667 ac_dummy="$PATH"
20668 for ac_dir in $ac_dummy; do
20669 IFS=$ac_save_IFS
20670 test -z "$ac_dir" && ac_dir=.
20671 if $as_executable_p "$ac_dir/$ac_word"; then
20672 ac_cv_path_FREETYPE_CONFIG="$ac_dir/$ac_word"
20673 echo "$as_me:20673: found $ac_dir/$ac_word" >&5
20674 break
20675 fi
20676 done
20677
20678 test -z "$ac_cv_path_FREETYPE_CONFIG" && ac_cv_path_FREETYPE_CONFIG="none"
20679 ;;
20680 esac
20681 fi
20682 FREETYPE_CONFIG=$ac_cv_path_FREETYPE_CONFIG
20683
20684 if test -n "$FREETYPE_CONFIG"; then
20685 echo "$as_me:20685: result: $FREETYPE_CONFIG" >&5
20686 echo "${ECHO_T}$FREETYPE_CONFIG" >&6
20687 else
20688 echo "$as_me:20688: result: no" >&5
20689 echo "${ECHO_T}no" >&6
20690 fi
20691
20692 if test "$FREETYPE_CONFIG" != none; then
20693 cf_extra_freetype_libs="-lfreetype2"
20694 else
20695 # Extract the first word of "xft-config", so it can be a program name with args.
20696 set dummy xft-config; ac_word=$2
20697 echo "$as_me:20697: checking for $ac_word" >&5
20698 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
20699 if test "${ac_cv_path_FREETYPE_OLD_CONFIG+set}" = set; then
20700 echo $ECHO_N "(cached) $ECHO_C" >&6
20701 else
20702 case $FREETYPE_OLD_CONFIG in
20703 [\\/]* | ?:[\\/]*)
20704 ac_cv_path_FREETYPE_OLD_CONFIG="$FREETYPE_OLD_CONFIG" # Let the user override the test with a path.
20705 ;;
20706 *)
20707 ac_save_IFS=$IFS; IFS=$ac_path_separator
20708 ac_dummy="$PATH"
20709 for ac_dir in $ac_dummy; do
20710 IFS=$ac_save_IFS
20711 test -z "$ac_dir" && ac_dir=.
20712 if $as_executable_p "$ac_dir/$ac_word"; then
20713 ac_cv_path_FREETYPE_OLD_CONFIG="$ac_dir/$ac_word"
20714 echo "$as_me:20714: found $ac_dir/$ac_word" >&5
20715 break
20716 fi
20717 done
20718
20719 test -z "$ac_cv_path_FREETYPE_OLD_CONFIG" && ac_cv_path_FREETYPE_OLD_CONFIG="none"
20720 ;;
20721 esac
20722 fi
20723 FREETYPE_OLD_CONFIG=$ac_cv_path_FREETYPE_OLD_CONFIG
20724
20725 if test -n "$FREETYPE_OLD_CONFIG"; then
20726 echo "$as_me:20726: result: $FREETYPE_OLD_CONFIG" >&5
20727 echo "${ECHO_T}$FREETYPE_OLD_CONFIG" >&6
20728 else
20729 echo "$as_me:20729: result: no" >&5
20730 echo "${ECHO_T}no" >&6
20731 fi
20732
20733 if test "$FREETYPE_OLD_CONFIG" != none; then
20734 FREETYPE_CONFIG=$FREETYPE_OLD_CONFIG
20735 fi
20736 fi
20737 fi
20738 ;;
20739 (pkg*)
20740 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists freetype2; then
20741 FREETYPE_CONFIG=$cf_cv_x_freetype_cfgs
20742 FREETYPE_PARAMS=freetype2
20743 else
20744 { echo "$as_me:20744: WARNING: cannot find pkg-config for freetype2" >&5
20745 echo "$as_me: WARNING: cannot find pkg-config for freetype2" >&2;}
20746 fi
20747 ;;
20748 (*)
20749 # Extract the first word of "$cf_cv_x_freetype_cfgs", so it can be a program name with args.
20750 set dummy $cf_cv_x_freetype_cfgs; ac_word=$2
20751 echo "$as_me:20751: checking for $ac_word" >&5
20752 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
20753 if test "${ac_cv_path_FREETYPE_XFT_CONFIG+set}" = set; then
20754 echo $ECHO_N "(cached) $ECHO_C" >&6
20755 else
20756 case $FREETYPE_XFT_CONFIG in
20757 [\\/]* | ?:[\\/]*)
20758 ac_cv_path_FREETYPE_XFT_CONFIG="$FREETYPE_XFT_CONFIG" # Let the user override the test with a path.
20759 ;;
20760 *)
20761 ac_save_IFS=$IFS; IFS=$ac_path_separator
20762 ac_dummy="$PATH"
20763 for ac_dir in $ac_dummy; do
20764 IFS=$ac_save_IFS
20765 test -z "$ac_dir" && ac_dir=.
20766 if $as_executable_p "$ac_dir/$ac_word"; then
20767 ac_cv_path_FREETYPE_XFT_CONFIG="$ac_dir/$ac_word"
20768 echo "$as_me:20768: found $ac_dir/$ac_word" >&5
20769 break
20770 fi
20771 done
20772
20773 test -z "$ac_cv_path_FREETYPE_XFT_CONFIG" && ac_cv_path_FREETYPE_XFT_CONFIG="none"
20774 ;;
20775 esac
20776 fi
20777 FREETYPE_XFT_CONFIG=$ac_cv_path_FREETYPE_XFT_CONFIG
20778
20779 if test -n "$FREETYPE_XFT_CONFIG"; then
20780 echo "$as_me:20780: result: $FREETYPE_XFT_CONFIG" >&5
20781 echo "${ECHO_T}$FREETYPE_XFT_CONFIG" >&6
20782 else
20783 echo "$as_me:20783: result: no" >&5
20784 echo "${ECHO_T}no" >&6
20785 fi
20786
20787 if test "$FREETYPE_XFT_CONFIG" != none; then
20788 FREETYPE_CONFIG=$FREETYPE_XFT_CONFIG
20789 else
20790 { echo "$as_me:20790: WARNING: cannot find config script for freetype2" >&5
20791 echo "$as_me: WARNING: cannot find config script for freetype2" >&2;}
20792 fi
20793 ;;
20794 esac
20795
20796 if test "$FREETYPE_CONFIG" != none ; then
20797 echo "$as_me:20797: checking for FreeType config" >&5
20798 echo $ECHO_N "checking for FreeType config... $ECHO_C" >&6
20799 echo "$as_me:20799: result: $FREETYPE_CONFIG $FREETYPE_PARAMS" >&5
20800 echo "${ECHO_T}$FREETYPE_CONFIG $FREETYPE_PARAMS" >&6
20801
20802 if test "$cf_cv_x_freetype_incs" = no ; then
20803 echo "$as_me:20803: checking for $FREETYPE_CONFIG cflags" >&5
20804 echo $ECHO_N "checking for $FREETYPE_CONFIG cflags... $ECHO_C" >&6
20805 cf_cv_x_freetype_incs="`$FREETYPE_CONFIG $FREETYPE_PARAMS --cflags 2>/dev/null`"
20806 echo "$as_me:20806: result: $cf_cv_x_freetype_incs" >&5
20807 echo "${ECHO_T}$cf_cv_x_freetype_incs" >&6
20808 fi
20809
20810 if test "$cf_cv_x_freetype_libs" = no ; then
20811 echo "$as_me:20811: checking for $FREETYPE_CONFIG libs" >&5
20812 echo $ECHO_N "checking for $FREETYPE_CONFIG libs... $ECHO_C" >&6
20813 cf_cv_x_freetype_libs="$cf_extra_freetype_libs `$FREETYPE_CONFIG $FREETYPE_PARAMS --libs 2>/dev/null`"
20814 echo "$as_me:20814: result: $cf_cv_x_freetype_libs" >&5
20815 echo "${ECHO_T}$cf_cv_x_freetype_libs" >&6
20816 fi
20817 fi
20818
20819 if test "$cf_cv_x_freetype_incs" = no ; then
20820 cf_cv_x_freetype_incs=
20821 fi
20822
20823 if test "$cf_cv_x_freetype_libs" = no ; then
20824 cf_cv_x_freetype_libs=-lfreetype2
20825 fi
20826
20827 echo "$as_me:20827: checking if we can link with FreeType library" >&5
20828 echo $ECHO_N "checking if we can link with FreeType library... $ECHO_C" >&6
20829
20830 cf_save_ft_LIBS="$LIBS"
20831 cf_save_ft_INCS="$CPPFLAGS"
20832
20833 cf_add_libs="$LIBS"
20834 # reverse order
20835 cf_add_0lib=
20836 for cf_add_1lib in $cf_cv_x_freetype_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
20837 # filter duplicates
20838 for cf_add_1lib in $cf_add_0lib; do
20839 for cf_add_2lib in $cf_add_libs; do
20840 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
20841 cf_add_1lib=
20842 break
20843 fi
20844 done
20845 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
20846 done
20847 LIBS="$cf_add_libs"
20848
20849 cf_fix_cppflags=no
20850 cf_new_cflags=
20851 cf_new_cppflags=
20852 cf_new_extra_cppflags=
20853
20854 for cf_add_cflags in $cf_cv_x_freetype_incs
20855 do
20856 case "$cf_fix_cppflags" in
20857 (no)
20858 case "$cf_add_cflags" in
20859 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
20860 case "$cf_add_cflags" in
20861 (-D*)
20862 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
20863
20864 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
20865 && test -z "${cf_tst_cflags}" \
20866 && cf_fix_cppflags=yes
20867
20868 if test "$cf_fix_cppflags" = yes ; then
20869
20870 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
20871 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
20872
20873 continue
20874 elif test "${cf_tst_cflags}" = "\"'" ; then
20875
20876 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
20877 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
20878
20879 continue
20880 fi
20881 ;;
20882 esac
20883 case "$CPPFLAGS" in
20884 (*$cf_add_cflags)
20885 ;;
20886 (*)
20887 case "$cf_add_cflags" in
20888 (-D*)
20889 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
20890
20891 CPPFLAGS=`echo "$CPPFLAGS" | \
20892 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
20893 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
20894
20895 ;;
20896 esac
20897
20898 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
20899 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
20900
20901 ;;
20902 esac
20903 ;;
20904 (*)
20905
20906 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
20907 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
20908
20909 ;;
20910 esac
20911 ;;
20912 (yes)
20913
20914 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
20915 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
20916
20917 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
20918
20919 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
20920 && test -z "${cf_tst_cflags}" \
20921 && cf_fix_cppflags=no
20922 ;;
20923 esac
20924 done
20925
20926 if test -n "$cf_new_cflags" ; then
20927
20928 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
20929 CFLAGS="${CFLAGS}$cf_new_cflags"
20930
20931 fi
20932
20933 if test -n "$cf_new_cppflags" ; then
20934
20935 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
20936 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
20937
20938 fi
20939
20940 if test -n "$cf_new_extra_cppflags" ; then
20941
20942 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
20943 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
20944
20945 fi
20946
20947 cat >"conftest.$ac_ext" <<_ACEOF
20948 #line 20948 "configure"
20949 #include "confdefs.h"
20950
20951 #include <ft2build.h>
20952 #include FT_FREETYPE_H
20953
20954 int
20955 main (void)
20956 {
20957
20958 FT_Library alibrary;
20959 FT_Init_FreeType( &alibrary );
20960 ;
20961 return 0;
20962 }
20963 _ACEOF
20964 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
20965 if { (eval echo "$as_me:20965: \"$ac_link\"") >&5
20966 (eval $ac_link) 2>&5
20967 ac_status=$?
20968 echo "$as_me:20968: \$? = $ac_status" >&5
20969 (exit "$ac_status"); } &&
20970 { ac_try='test -s "conftest$ac_exeext"'
20971 { (eval echo "$as_me:20971: \"$ac_try\"") >&5
20972 (eval $ac_try) 2>&5
20973 ac_status=$?
20974 echo "$as_me:20974: \$? = $ac_status" >&5
20975 (exit "$ac_status"); }; }; then
20976 cf_cv_found_freetype=yes
20977 else
20978 echo "$as_me: failed program was:" >&5
20979 cat "conftest.$ac_ext" >&5
20980 cf_cv_found_freetype=no
20981 fi
20982 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
20983 echo "$as_me:20983: result: $cf_cv_found_freetype" >&5
20984 echo "${ECHO_T}$cf_cv_found_freetype" >&6
20985
20986 if test "$cf_cv_found_freetype" = no ; then
20987 { echo "$as_me:20987: WARNING: No libraries found for FreeType" >&5
20988 echo "$as_me: WARNING: No libraries found for FreeType" >&2;}
20989 LIBS="$cf_save_ft_LIBS"
20990 CPPFLAGS="$cf_save_ft_INCS"
20991 fi
20992
20993 if test "$cf_cv_found_freetype" = yes
20994 then
20995
20996 cf_save_xft_LIBS="$LIBS"
20997 cf_save_xft_INCS="$CPPFLAGS"
20998
20999 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "xft"; then
21000 test -n "$verbose" && echo " found package xft" 1>&6
21001
21002 echo "${as_me:-configure}:21002: testing found package xft ..." 1>&5
21003
21004 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "xft" 2>/dev/null`"
21005 cf_pkgconfig_libs="`$PKG_CONFIG --libs "xft" 2>/dev/null`"
21006 test -n "$verbose" && echo " package xft CFLAGS: $cf_pkgconfig_incs" 1>&6
21007
21008 echo "${as_me:-configure}:21008: testing package xft CFLAGS: $cf_pkgconfig_incs ..." 1>&5
21009
21010 test -n "$verbose" && echo " package xft LIBS: $cf_pkgconfig_libs" 1>&6
21011
21012 echo "${as_me:-configure}:21012: testing package xft LIBS: $cf_pkgconfig_libs ..." 1>&5
21013
21014 for cf_required in xft
21015 do
21016 # check for duplicates
21017 for cf_require_pkg in $REQUIRE_PKG
21018 do
21019 if test "$cf_required" = "$cf_require_pkg"
21020 then
21021 cf_required=
21022 break
21023 fi
21024 done
21025 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
21026 done
21027
21028 cf_fix_cppflags=no
21029 cf_new_cflags=
21030 cf_new_cppflags=
21031 cf_new_extra_cppflags=
21032
21033 for cf_add_cflags in $cf_pkgconfig_incs
21034 do
21035 case "$cf_fix_cppflags" in
21036 (no)
21037 case "$cf_add_cflags" in
21038 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
21039 case "$cf_add_cflags" in
21040 (-D*)
21041 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
21042
21043 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
21044 && test -z "${cf_tst_cflags}" \
21045 && cf_fix_cppflags=yes
21046
21047 if test "$cf_fix_cppflags" = yes ; then
21048
21049 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21050 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21051
21052 continue
21053 elif test "${cf_tst_cflags}" = "\"'" ; then
21054
21055 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21056 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21057
21058 continue
21059 fi
21060 ;;
21061 esac
21062 case "$CPPFLAGS" in
21063 (*$cf_add_cflags)
21064 ;;
21065 (*)
21066 case "$cf_add_cflags" in
21067 (-D*)
21068 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
21069
21070 CPPFLAGS=`echo "$CPPFLAGS" | \
21071 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
21072 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
21073
21074 ;;
21075 esac
21076
21077 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
21078 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
21079
21080 ;;
21081 esac
21082 ;;
21083 (*)
21084
21085 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
21086 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
21087
21088 ;;
21089 esac
21090 ;;
21091 (yes)
21092
21093 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21094 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21095
21096 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
21097
21098 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
21099 && test -z "${cf_tst_cflags}" \
21100 && cf_fix_cppflags=no
21101 ;;
21102 esac
21103 done
21104
21105 if test -n "$cf_new_cflags" ; then
21106
21107 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
21108 CFLAGS="${CFLAGS}$cf_new_cflags"
21109
21110 fi
21111
21112 if test -n "$cf_new_cppflags" ; then
21113
21114 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
21115 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
21116
21117 fi
21118
21119 if test -n "$cf_new_extra_cppflags" ; then
21120
21121 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
21122 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
21123
21124 fi
21125
21126 cf_add_libs="$LIBS"
21127 # reverse order
21128 cf_add_0lib=
21129 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
21130 # filter duplicates
21131 for cf_add_1lib in $cf_add_0lib; do
21132 for cf_add_2lib in $cf_add_libs; do
21133 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
21134 cf_add_1lib=
21135 break
21136 fi
21137 done
21138 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
21139 done
21140 LIBS="$cf_add_libs"
21141
21142 :
21143 else
21144 cf_pkgconfig_incs=
21145 cf_pkgconfig_libs=
21146 { echo "$as_me:21146: WARNING: unable to find Xft library with $PKG_CONFIG" >&5
21147 echo "$as_me: WARNING: unable to find Xft library with $PKG_CONFIG" >&2;}
21148 fi
21149
21150 if test -z "$cf_pkgconfig_libs"
21151 then
21152 echo "$as_me:21152: checking for XftNameParse in -lXft" >&5
21153 echo $ECHO_N "checking for XftNameParse in -lXft... $ECHO_C" >&6
21154 if test "${ac_cv_lib_Xft_XftNameParse+set}" = set; then
21155 echo $ECHO_N "(cached) $ECHO_C" >&6
21156 else
21157 ac_check_lib_save_LIBS=$LIBS
21158 LIBS="-lXft $LIBS"
21159 cat >"conftest.$ac_ext" <<_ACEOF
21160 #line 21160 "configure"
21161 #include "confdefs.h"
21162
21163 /* Override any gcc2 internal prototype to avoid an error. */
21164 #ifdef __cplusplus
21165 extern "C"
21166 #endif
21167 /* We use char because int might match the return type of a gcc2
21168 builtin and then its argument prototype would still apply. */
21169 char XftNameParse (void);
21170 int
21171 main (void)
21172 {
21173 XftNameParse ();
21174 ;
21175 return 0;
21176 }
21177 _ACEOF
21178 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
21179 if { (eval echo "$as_me:21179: \"$ac_link\"") >&5
21180 (eval $ac_link) 2>&5
21181 ac_status=$?
21182 echo "$as_me:21182: \$? = $ac_status" >&5
21183 (exit "$ac_status"); } &&
21184 { ac_try='test -s "conftest$ac_exeext"'
21185 { (eval echo "$as_me:21185: \"$ac_try\"") >&5
21186 (eval $ac_try) 2>&5
21187 ac_status=$?
21188 echo "$as_me:21188: \$? = $ac_status" >&5
21189 (exit "$ac_status"); }; }; then
21190 ac_cv_lib_Xft_XftNameParse=yes
21191 else
21192 echo "$as_me: failed program was:" >&5
21193 cat "conftest.$ac_ext" >&5
21194 ac_cv_lib_Xft_XftNameParse=no
21195 fi
21196 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
21197 LIBS=$ac_check_lib_save_LIBS
21198 fi
21199 echo "$as_me:21199: result: $ac_cv_lib_Xft_XftNameParse" >&5
21200 echo "${ECHO_T}$ac_cv_lib_Xft_XftNameParse" >&6
21201 if test "$ac_cv_lib_Xft_XftNameParse" = yes; then
21202 LIBS="-lXft $LIBS"
21203 fi
21204
21205 fi
21206
21207 echo "$as_me:21207: checking if we can link with Xft and FreeType libraries" >&5
21208 echo $ECHO_N "checking if we can link with Xft and FreeType libraries... $ECHO_C" >&6
21209 cat >"conftest.$ac_ext" <<_ACEOF
21210 #line 21210 "configure"
21211 #include "confdefs.h"
21212
21213 #include <X11/Xlib.h>
21214 #include <X11/extensions/Xrender.h>
21215 #include <X11/Xft/Xft.h>
21216 int
21217 main (void)
21218 {
21219
21220 XftPattern *pat = XftNameParse ("name"); (void)pat
21221 ;
21222 return 0;
21223 }
21224 _ACEOF
21225 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
21226 if { (eval echo "$as_me:21226: \"$ac_link\"") >&5
21227 (eval $ac_link) 2>&5
21228 ac_status=$?
21229 echo "$as_me:21229: \$? = $ac_status" >&5
21230 (exit "$ac_status"); } &&
21231 { ac_try='test -s "conftest$ac_exeext"'
21232 { (eval echo "$as_me:21232: \"$ac_try\"") >&5
21233 (eval $ac_try) 2>&5
21234 ac_status=$?
21235 echo "$as_me:21235: \$? = $ac_status" >&5
21236 (exit "$ac_status"); }; }; then
21237 cf_cv_found_xft_libraries=yes
21238 else
21239 echo "$as_me: failed program was:" >&5
21240 cat "conftest.$ac_ext" >&5
21241 cf_cv_found_xft_libraries=no
21242 fi
21243 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
21244 echo "$as_me:21244: result: $cf_cv_found_xft_libraries" >&5
21245 echo "${ECHO_T}$cf_cv_found_xft_libraries" >&6
21246
21247 if test "$cf_cv_found_xft_libraries" = yes ; then
21248
21249 cat >>confdefs.h <<\EOF
21250 #define XRENDERFONT 1
21251 EOF
21252
21253 for ac_func in \
21254 XftDrawCharSpec \
21255 XftDrawSetClip \
21256 XftDrawSetClipRectangles
21257 do
21258 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
21259 echo "$as_me:21259: checking for $ac_func" >&5
21260 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
21261 if eval "test \"\${$as_ac_var+set}\" = set"; then
21262 echo $ECHO_N "(cached) $ECHO_C" >&6
21263 else
21264 cat >"conftest.$ac_ext" <<_ACEOF
21265 #line 21265 "configure"
21266 #include "confdefs.h"
21267 #define $ac_func autoconf_temporary
21268 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
21269 #undef $ac_func
21270
21271 #ifdef __cplusplus
21272 extern "C"
21273 #endif
21274
21275 /* We use char because int might match the return type of a gcc2
21276 builtin and then its argument prototype would still apply. */
21277 char $ac_func (void);
21278
21279 int
21280 main (void)
21281 {
21282
21283 /* The GNU C library defines stubs for functions which it implements
21284 to always fail with ENOSYS. Some functions are actually named
21285 something starting with __ and the normal name is an alias. */
21286 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
21287 #error found stub for $ac_func
21288 #endif
21289
21290 return $ac_func ();
21291 ;
21292 return 0;
21293 }
21294 _ACEOF
21295 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
21296 if { (eval echo "$as_me:21296: \"$ac_link\"") >&5
21297 (eval $ac_link) 2>&5
21298 ac_status=$?
21299 echo "$as_me:21299: \$? = $ac_status" >&5
21300 (exit "$ac_status"); } &&
21301 { ac_try='test -s "conftest$ac_exeext"'
21302 { (eval echo "$as_me:21302: \"$ac_try\"") >&5
21303 (eval $ac_try) 2>&5
21304 ac_status=$?
21305 echo "$as_me:21305: \$? = $ac_status" >&5
21306 (exit "$ac_status"); }; }; then
21307 eval "$as_ac_var=yes"
21308 else
21309 echo "$as_me: failed program was:" >&5
21310 cat "conftest.$ac_ext" >&5
21311 eval "$as_ac_var=no"
21312 fi
21313 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
21314 fi
21315 echo "$as_me:21315: result: `eval echo '${'"$as_ac_var"'}'`" >&5
21316 echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
21317 if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
21318 cat >>confdefs.h <<EOF
21319 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
21320 EOF
21321
21322 fi
21323 done
21324
21325 else
21326 LIBS="$cf_save_xft_LIBS"
21327 CPPFLAGS="$cf_save_xft_INCS"
21328 fi
21329
21330 # FIXME: revisit this if needed
21331
21332 fi
21333
21334 if test "$cf_cv_found_freetype" = yes ; then
21335 echo "$as_me:21335: checking for usable Xft/fontconfig package" >&5
21336 echo $ECHO_N "checking for usable Xft/fontconfig package... $ECHO_C" >&6
21337 if test "${cf_cv_xft_compat+set}" = set; then
21338 echo $ECHO_N "(cached) $ECHO_C" >&6
21339 else
21340
21341 cat >"conftest.$ac_ext" <<_ACEOF
21342 #line 21342 "configure"
21343 #include "confdefs.h"
21344
21345 #include <X11/Xlib.h>
21346 #include <X11/Xft/Xft.h>
21347
21348 int
21349 main (void)
21350 {
21351
21352 XftPattern *pat = NULL;
21353 XftPatternBuild(pat,
21354 XFT_FAMILY, XftTypeString, "mono",
21355 (void *) 0);
21356
21357 ;
21358 return 0;
21359 }
21360 _ACEOF
21361 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
21362 if { (eval echo "$as_me:21362: \"$ac_link\"") >&5
21363 (eval $ac_link) 2>&5
21364 ac_status=$?
21365 echo "$as_me:21365: \$? = $ac_status" >&5
21366 (exit "$ac_status"); } &&
21367 { ac_try='test -s "conftest$ac_exeext"'
21368 { (eval echo "$as_me:21368: \"$ac_try\"") >&5
21369 (eval $ac_try) 2>&5
21370 ac_status=$?
21371 echo "$as_me:21371: \$? = $ac_status" >&5
21372 (exit "$ac_status"); }; }; then
21373 cf_cv_xft_compat=yes
21374 else
21375 echo "$as_me: failed program was:" >&5
21376 cat "conftest.$ac_ext" >&5
21377 cf_cv_xft_compat=no
21378 fi
21379 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
21380
21381 fi
21382 echo "$as_me:21382: result: $cf_cv_xft_compat" >&5
21383 echo "${ECHO_T}$cf_cv_xft_compat" >&6
21384
21385 if test "$cf_cv_xft_compat" = no
21386 then
21387 # workaround for broken ".pc" files used for Xft.
21388 case "$cf_cv_x_freetype_libs" in
21389 (*-lfontconfig*)
21390 ;;
21391 (*)
21392 test -n "$verbose" && echo " work around broken package" 1>&6
21393
21394 echo "${as_me:-configure}:21394: testing work around broken package ..." 1>&5
21395
21396 cf_save_fontconfig="$LIBS"
21397
21398 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "fontconfig"; then
21399 test -n "$verbose" && echo " found package fontconfig" 1>&6
21400
21401 echo "${as_me:-configure}:21401: testing found package fontconfig ..." 1>&5
21402
21403 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "fontconfig" 2>/dev/null`"
21404 cf_pkgconfig_libs="`$PKG_CONFIG --libs "fontconfig" 2>/dev/null`"
21405 test -n "$verbose" && echo " package fontconfig CFLAGS: $cf_pkgconfig_incs" 1>&6
21406
21407 echo "${as_me:-configure}:21407: testing package fontconfig CFLAGS: $cf_pkgconfig_incs ..." 1>&5
21408
21409 test -n "$verbose" && echo " package fontconfig LIBS: $cf_pkgconfig_libs" 1>&6
21410
21411 echo "${as_me:-configure}:21411: testing package fontconfig LIBS: $cf_pkgconfig_libs ..." 1>&5
21412
21413 for cf_required in fontconfig
21414 do
21415 # check for duplicates
21416 for cf_require_pkg in $REQUIRE_PKG
21417 do
21418 if test "$cf_required" = "$cf_require_pkg"
21419 then
21420 cf_required=
21421 break
21422 fi
21423 done
21424 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
21425 done
21426
21427 cf_fix_cppflags=no
21428 cf_new_cflags=
21429 cf_new_cppflags=
21430 cf_new_extra_cppflags=
21431
21432 for cf_add_cflags in $cf_pkgconfig_incs
21433 do
21434 case "$cf_fix_cppflags" in
21435 (no)
21436 case "$cf_add_cflags" in
21437 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
21438 case "$cf_add_cflags" in
21439 (-D*)
21440 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
21441
21442 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
21443 && test -z "${cf_tst_cflags}" \
21444 && cf_fix_cppflags=yes
21445
21446 if test "$cf_fix_cppflags" = yes ; then
21447
21448 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21449 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21450
21451 continue
21452 elif test "${cf_tst_cflags}" = "\"'" ; then
21453
21454 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21455 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21456
21457 continue
21458 fi
21459 ;;
21460 esac
21461 case "$CPPFLAGS" in
21462 (*$cf_add_cflags)
21463 ;;
21464 (*)
21465 case "$cf_add_cflags" in
21466 (-D*)
21467 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
21468
21469 CPPFLAGS=`echo "$CPPFLAGS" | \
21470 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
21471 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
21472
21473 ;;
21474 esac
21475
21476 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
21477 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
21478
21479 ;;
21480 esac
21481 ;;
21482 (*)
21483
21484 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
21485 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
21486
21487 ;;
21488 esac
21489 ;;
21490 (yes)
21491
21492 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21493 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21494
21495 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
21496
21497 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
21498 && test -z "${cf_tst_cflags}" \
21499 && cf_fix_cppflags=no
21500 ;;
21501 esac
21502 done
21503
21504 if test -n "$cf_new_cflags" ; then
21505
21506 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
21507 CFLAGS="${CFLAGS}$cf_new_cflags"
21508
21509 fi
21510
21511 if test -n "$cf_new_cppflags" ; then
21512
21513 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
21514 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
21515
21516 fi
21517
21518 if test -n "$cf_new_extra_cppflags" ; then
21519
21520 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
21521 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
21522
21523 fi
21524
21525 cf_add_libs="$LIBS"
21526 # reverse order
21527 cf_add_0lib=
21528 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
21529 # filter duplicates
21530 for cf_add_1lib in $cf_add_0lib; do
21531 for cf_add_2lib in $cf_add_libs; do
21532 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
21533 cf_add_1lib=
21534 break
21535 fi
21536 done
21537 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
21538 done
21539 LIBS="$cf_add_libs"
21540
21541 cf_fix_cppflags=no
21542 cf_new_cflags=
21543 cf_new_cppflags=
21544 cf_new_extra_cppflags=
21545
21546 for cf_add_cflags in $cf_pkgconfig_incs
21547 do
21548 case "$cf_fix_cppflags" in
21549 (no)
21550 case "$cf_add_cflags" in
21551 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
21552 case "$cf_add_cflags" in
21553 (-D*)
21554 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
21555
21556 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
21557 && test -z "${cf_tst_cflags}" \
21558 && cf_fix_cppflags=yes
21559
21560 if test "$cf_fix_cppflags" = yes ; then
21561
21562 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21563 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21564
21565 continue
21566 elif test "${cf_tst_cflags}" = "\"'" ; then
21567
21568 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21569 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21570
21571 continue
21572 fi
21573 ;;
21574 esac
21575 case "$CPPFLAGS" in
21576 (*$cf_add_cflags)
21577 ;;
21578 (*)
21579 case "$cf_add_cflags" in
21580 (-D*)
21581 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
21582
21583 CPPFLAGS=`echo "$CPPFLAGS" | \
21584 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
21585 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
21586
21587 ;;
21588 esac
21589
21590 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
21591 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
21592
21593 ;;
21594 esac
21595 ;;
21596 (*)
21597
21598 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
21599 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
21600
21601 ;;
21602 esac
21603 ;;
21604 (yes)
21605
21606 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
21607 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
21608
21609 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
21610
21611 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
21612 && test -z "${cf_tst_cflags}" \
21613 && cf_fix_cppflags=no
21614 ;;
21615 esac
21616 done
21617
21618 if test -n "$cf_new_cflags" ; then
21619
21620 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
21621 CFLAGS="${CFLAGS}$cf_new_cflags"
21622
21623 fi
21624
21625 if test -n "$cf_new_cppflags" ; then
21626
21627 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
21628 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
21629
21630 fi
21631
21632 if test -n "$cf_new_extra_cppflags" ; then
21633
21634 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
21635 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
21636
21637 fi
21638
21639 LIBS="$cf_save_fontconfig"
21640
21641 cf_add_libs="$LIBS"
21642 test -n "$verbose" && echo " ...before $cf_add_libs" 1>&6
21643
21644 echo "${as_me:-configure}:21644: testing ...before $cf_add_libs ..." 1>&5
21645
21646 for cf_add_1lib in $cf_pkgconfig_libs; do
21647 # filter duplicates
21648 cf_found_2lib=no
21649 for cf_add_2lib in $cf_add_libs; do
21650 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
21651 cf_found_2lib=yes
21652 break
21653 fi
21654 done
21655 # if not a duplicate, find the dependent library
21656 if test "$cf_found_2lib" = no
21657 then
21658 cf_found_2lib=no
21659 cf_add_2libs=
21660 for cf_add_2lib in $cf_add_libs
21661 do
21662 test -n "$cf_add_2libs" && cf_add_2libs="$cf_add_2libs "
21663 cf_add_2libs="$cf_add_2libs$cf_add_2lib"
21664 if test "x$cf_add_2lib" = "x-lXft"
21665 then
21666 cf_found_2lib=yes
21667 cf_add_2libs="$cf_add_2libs $cf_add_1lib"
21668 fi
21669 done
21670 if test "$cf_found_2lib" = yes
21671 then
21672 cf_add_libs="$cf_add_2libs"
21673 else
21674 test -n "$verbose" && echo " ...missed -lXft" 1>&6
21675
21676 echo "${as_me:-configure}:21676: testing ...missed -lXft ..." 1>&5
21677
21678 fi
21679 fi
21680 done
21681 test -n "$verbose" && echo " ...after $cf_add_libs" 1>&6
21682
21683 echo "${as_me:-configure}:21683: testing ...after $cf_add_libs ..." 1>&5
21684
21685 LIBS="$cf_add_libs"
21686
21687 else
21688 cf_pkgconfig_incs=
21689 cf_pkgconfig_libs=
21690
21691 cf_add_libs="$LIBS"
21692 test -n "$verbose" && echo " ...before $cf_add_libs" 1>&6
21693
21694 echo "${as_me:-configure}:21694: testing ...before $cf_add_libs ..." 1>&5
21695
21696 for cf_add_1lib in -lfontconfig; do
21697 # filter duplicates
21698 cf_found_2lib=no
21699 for cf_add_2lib in $cf_add_libs; do
21700 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
21701 cf_found_2lib=yes
21702 break
21703 fi
21704 done
21705 # if not a duplicate, find the dependent library
21706 if test "$cf_found_2lib" = no
21707 then
21708 cf_found_2lib=no
21709 cf_add_2libs=
21710 for cf_add_2lib in $cf_add_libs
21711 do
21712 test -n "$cf_add_2libs" && cf_add_2libs="$cf_add_2libs "
21713 cf_add_2libs="$cf_add_2libs$cf_add_2lib"
21714 if test "x$cf_add_2lib" = "x-lXft"
21715 then
21716 cf_found_2lib=yes
21717 cf_add_2libs="$cf_add_2libs $cf_add_1lib"
21718 fi
21719 done
21720 if test "$cf_found_2lib" = yes
21721 then
21722 cf_add_libs="$cf_add_2libs"
21723 else
21724 test -n "$verbose" && echo " ...missed -lXft" 1>&6
21725
21726 echo "${as_me:-configure}:21726: testing ...missed -lXft ..." 1>&5
21727
21728 fi
21729 fi
21730 done
21731 test -n "$verbose" && echo " ...after $cf_add_libs" 1>&6
21732
21733 echo "${as_me:-configure}:21733: testing ...after $cf_add_libs ..." 1>&5
21734
21735 LIBS="$cf_add_libs"
21736
21737 fi
21738
21739 ;;
21740 esac
21741 fi
21742 fi
21743
21744 else
21745 CPPFLAGS=`echo "$CPPFLAGS" | sed -e s/-DXRENDERFONT//`
21746 fi
21747
21748 echo "$as_me:21748: checking if you want support for HP-style function keys" >&5
21749 echo $ECHO_N "checking if you want support for HP-style function keys... $ECHO_C" >&6
21750
21751 # Check whether --enable-hp-fkeys or --disable-hp-fkeys was given.
21752 if test "${enable_hp_fkeys+set}" = set; then
21753 enableval="$enable_hp_fkeys"
21754 test "$enableval" != yes && enableval=no
21755 if test "$enableval" != "no" ; then
21756 enable_hp_fkeys=yes
21757 else
21758 enable_hp_fkeys=no
21759 fi
21760 else
21761 enableval=no
21762 enable_hp_fkeys=no
21763
21764 fi;
21765 echo "$as_me:21765: result: $enable_hp_fkeys" >&5
21766 echo "${ECHO_T}$enable_hp_fkeys" >&6
21767 if test "$enable_hp_fkeys" = yes ; then
21768
21769 cat >>confdefs.h <<\EOF
21770 #define OPT_HP_FUNC_KEYS 1
21771 EOF
21772
21773 fi
21774
21775 echo "$as_me:21775: checking if you want support for SCO-style function keys" >&5
21776 echo $ECHO_N "checking if you want support for SCO-style function keys... $ECHO_C" >&6
21777
21778 # Check whether --enable-sco-fkeys or --disable-sco-fkeys was given.
21779 if test "${enable_sco_fkeys+set}" = set; then
21780 enableval="$enable_sco_fkeys"
21781 test "$enableval" != yes && enableval=no
21782 if test "$enableval" != "no" ; then
21783 enable_sco_fkeys=yes
21784 else
21785 enable_sco_fkeys=no
21786 fi
21787 else
21788 enableval=no
21789 enable_sco_fkeys=no
21790
21791 fi;
21792 echo "$as_me:21792: result: $enable_sco_fkeys" >&5
21793 echo "${ECHO_T}$enable_sco_fkeys" >&6
21794 if test "$enable_sco_fkeys" = yes ; then
21795
21796 cat >>confdefs.h <<\EOF
21797 #define OPT_SCO_FUNC_KEYS 1
21798 EOF
21799
21800 fi
21801
21802 echo "$as_me:21802: checking if you want support for Sun-style function keys" >&5
21803 echo $ECHO_N "checking if you want support for Sun-style function keys... $ECHO_C" >&6
21804
21805 # Check whether --enable-sun-fkeys or --disable-sun-fkeys was given.
21806 if test "${enable_sun_fkeys+set}" = set; then
21807 enableval="$enable_sun_fkeys"
21808 test "$enableval" != no && enableval=yes
21809 if test "$enableval" != "yes" ; then
21810 enable_sun_fkeys=no
21811 else
21812 enable_sun_fkeys=yes
21813 fi
21814 else
21815 enableval=yes
21816 enable_sun_fkeys=yes
21817
21818 fi;
21819 echo "$as_me:21819: result: $enable_sun_fkeys" >&5
21820 echo "${ECHO_T}$enable_sun_fkeys" >&6
21821 if test "$enable_sun_fkeys" = no ; then
21822
21823 cat >>confdefs.h <<\EOF
21824 #define OPT_SUN_FUNC_KEYS 0
21825 EOF
21826
21827 fi
21828
21829 echo "$as_me:21829: checking if you want saved-lines stored as a FIFO" >&5
21830 echo $ECHO_N "checking if you want saved-lines stored as a FIFO... $ECHO_C" >&6
21831
21832 # Check whether --enable-fifo-lines or --disable-fifo-lines was given.
21833 if test "${enable_fifo_lines+set}" = set; then
21834 enableval="$enable_fifo_lines"
21835 test "$enableval" != no && enableval=yes
21836 if test "$enableval" != "yes" ; then
21837 enable_fifo_lines=no
21838 else
21839 enable_fifo_lines=yes
21840 fi
21841 else
21842 enableval=yes
21843 enable_fifo_lines=yes
21844
21845 fi;
21846 echo "$as_me:21846: result: $enable_fifo_lines" >&5
21847 echo "${ECHO_T}$enable_fifo_lines" >&6
21848 if test "$enable_fifo_lines" != yes ; then
21849 { echo "$as_me:21849: WARNING: this option has been deprecated" >&5
21850 echo "$as_me: WARNING: this option has been deprecated" >&2;}
21851 fi
21852
21853 echo "$as_me:21853: checking if you want support for internationalization" >&5
21854 echo $ECHO_N "checking if you want support for internationalization... $ECHO_C" >&6
21855
21856 # Check whether --enable-i18n or --disable-i18n was given.
21857 if test "${enable_i18n+set}" = set; then
21858 enableval="$enable_i18n"
21859 test "$enableval" != no && enableval=yes
21860 if test "$enableval" != "yes" ; then
21861 enable_i18n=no
21862 else
21863 enable_i18n=yes
21864 fi
21865 else
21866 enableval=yes
21867 enable_i18n=yes
21868
21869 fi;
21870 echo "$as_me:21870: result: $enable_i18n" >&5
21871 echo "${ECHO_T}$enable_i18n" >&6
21872 if test "$enable_i18n" = no ; then
21873
21874 cat >>confdefs.h <<\EOF
21875 #define OPT_I18N_SUPPORT 0
21876 EOF
21877
21878 fi
21879
21880 echo "$as_me:21880: checking if you want support for initial-erase setup" >&5
21881 echo $ECHO_N "checking if you want support for initial-erase setup... $ECHO_C" >&6
21882
21883 # Check whether --enable-initial-erase or --disable-initial-erase was given.
21884 if test "${enable_initial_erase+set}" = set; then
21885 enableval="$enable_initial_erase"
21886 test "$enableval" != no && enableval=yes
21887 if test "$enableval" != "yes" ; then
21888 enable_ie=no
21889 else
21890 enable_ie=yes
21891 fi
21892 else
21893 enableval=yes
21894 enable_ie=yes
21895
21896 fi;
21897 echo "$as_me:21897: result: $enable_ie" >&5
21898 echo "${ECHO_T}$enable_ie" >&6
21899 if test "$enable_ie" = no ; then
21900
21901 cat >>confdefs.h <<\EOF
21902 #define OPT_INITIAL_ERASE 0
21903 EOF
21904
21905 fi
21906
21907 echo "$as_me:21907: checking if you want support for input-method" >&5
21908 echo $ECHO_N "checking if you want support for input-method... $ECHO_C" >&6
21909
21910 # Check whether --enable-input-method or --disable-input-method was given.
21911 if test "${enable_input_method+set}" = set; then
21912 enableval="$enable_input_method"
21913 test "$enableval" != no && enableval=yes
21914 if test "$enableval" != "yes" ; then
21915 enable_ximp=no
21916 else
21917 enable_ximp=$enable_i18n
21918 fi
21919 else
21920 enableval=yes
21921 enable_ximp=$enable_i18n
21922
21923 fi;
21924 echo "$as_me:21924: result: $enable_ximp" >&5
21925 echo "${ECHO_T}$enable_ximp" >&6
21926
21927 echo "$as_me:21927: checking if X libraries support input-method" >&5
21928 echo $ECHO_N "checking if X libraries support input-method... $ECHO_C" >&6
21929 if test "${cf_cv_input_method+set}" = set; then
21930 echo $ECHO_N "(cached) $ECHO_C" >&6
21931 else
21932
21933 cat >"conftest.$ac_ext" <<_ACEOF
21934 #line 21934 "configure"
21935 #include "confdefs.h"
21936
21937 #include <X11/IntrinsicP.h>
21938 #include <X11/Xatom.h>
21939 #include <X11/Xutil.h>
21940 #include <X11/Xmu/Atoms.h>
21941 #include <X11/Xmu/Converters.h>
21942 #include <X11/Xaw/XawImP.h>
21943
21944 int
21945 main (void)
21946 {
21947
21948 {
21949 XIM xim;
21950 XIMStyles *xim_styles = NULL;
21951 XIMStyle input_style;
21952 Widget w = XtCreateWidget("none", (WidgetClass)0, NULL, (ArgList)0, 0);
21953
21954 XSetLocaleModifiers("@im=none");
21955 xim = XOpenIM(XtDisplay(w), NULL, NULL, NULL);
21956 XGetIMValues(xim, XNQueryInputStyle, &xim_styles, NULL);
21957 XCloseIM(xim);
21958 input_style = (XIMPreeditNothing | XIMStatusNothing);
21959 (void)xim_styles;
21960 (void)input_style;
21961 }
21962
21963 ;
21964 return 0;
21965 }
21966 _ACEOF
21967 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
21968 if { (eval echo "$as_me:21968: \"$ac_link\"") >&5
21969 (eval $ac_link) 2>&5
21970 ac_status=$?
21971 echo "$as_me:21971: \$? = $ac_status" >&5
21972 (exit "$ac_status"); } &&
21973 { ac_try='test -s "conftest$ac_exeext"'
21974 { (eval echo "$as_me:21974: \"$ac_try\"") >&5
21975 (eval $ac_try) 2>&5
21976 ac_status=$?
21977 echo "$as_me:21977: \$? = $ac_status" >&5
21978 (exit "$ac_status"); }; }; then
21979 cf_cv_input_method=yes
21980 else
21981 echo "$as_me: failed program was:" >&5
21982 cat "conftest.$ac_ext" >&5
21983 cf_cv_input_method=no
21984 fi
21985 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
21986 fi
21987 echo "$as_me:21987: result: $cf_cv_input_method" >&5
21988 echo "${ECHO_T}$cf_cv_input_method" >&6
21989
21990 test "$cf_cv_input_method" = no && enable_ximp=no
21991 if test "$enable_ximp" != no ; then
21992 if test "$enable_i18n" = no ; then
21993 { echo "$as_me:21993: WARNING: input-method relies upon internationalization" >&5
21994 echo "$as_me: WARNING: input-method relies upon internationalization" >&2;}
21995 enable_ximp=no
21996 fi
21997 fi
21998 if test "$enable_ximp" = no ; then
21999
22000 cat >>confdefs.h <<\EOF
22001 #define OPT_INPUT_METHOD 0
22002 EOF
22003
22004 fi
22005
22006 echo "$as_me:22006: checking if you want support for load-vt-fonts" >&5
22007 echo $ECHO_N "checking if you want support for load-vt-fonts... $ECHO_C" >&6
22008
22009 # Check whether --enable-load-vt-fonts or --disable-load-vt-fonts was given.
22010 if test "${enable_load_vt_fonts+set}" = set; then
22011 enableval="$enable_load_vt_fonts"
22012 test "$enableval" != yes && enableval=no
22013 if test "$enableval" != "no" ; then
22014 enable_load_vt_fonts=yes
22015 else
22016 enable_load_vt_fonts=no
22017 fi
22018 else
22019 enableval=no
22020 enable_load_vt_fonts=no
22021
22022 fi;
22023 echo "$as_me:22023: result: $enable_load_vt_fonts" >&5
22024 echo "${ECHO_T}$enable_load_vt_fonts" >&6
22025 if test "$enable_load_vt_fonts" = yes ; then
22026
22027 cat >>confdefs.h <<\EOF
22028 #define OPT_LOAD_VTFONTS 1
22029 EOF
22030
22031 fi
22032
22033 echo "$as_me:22033: checking if you want support for logging" >&5
22034 echo $ECHO_N "checking if you want support for logging... $ECHO_C" >&6
22035
22036 # Check whether --enable-logging or --disable-logging was given.
22037 if test "${enable_logging+set}" = set; then
22038 enableval="$enable_logging"
22039 test "$enableval" != yes && enableval=no
22040 if test "$enableval" != "no" ; then
22041 enable_logging=yes
22042 else
22043 enable_logging=no
22044 fi
22045 else
22046 enableval=no
22047 enable_logging=no
22048
22049 fi;
22050 echo "$as_me:22050: result: $enable_logging" >&5
22051 echo "${ECHO_T}$enable_logging" >&6
22052 if test "$enable_logging" = yes ; then
22053
22054 cat >>confdefs.h <<\EOF
22055 #define ALLOWLOGGING 1
22056 EOF
22057
22058 echo "$as_me:22058: checking if you want to allow logging via a pipe" >&5
22059 echo $ECHO_N "checking if you want to allow logging via a pipe... $ECHO_C" >&6
22060
22061 # Check whether --enable-logfile-exec or --disable-logfile-exec was given.
22062 if test "${enable_logfile_exec+set}" = set; then
22063 enableval="$enable_logfile_exec"
22064 test "$enableval" != yes && enableval=no
22065 if test "$enableval" != "no" ; then
22066 enable_log_exec=yes
22067 else
22068 enable_log_exec=no
22069 fi
22070 else
22071 enableval=no
22072 enable_log_exec=no
22073
22074 fi;
22075 echo "$as_me:22075: result: $enable_log_exec" >&5
22076 echo "${ECHO_T}$enable_log_exec" >&6
22077 if test "$enable_log_exec" = yes ; then
22078
22079 cat >>confdefs.h <<\EOF
22080 #define ALLOWLOGFILEEXEC 1
22081 EOF
22082
22083 fi
22084 fi
22085
22086 echo "$as_me:22086: checking if you want support for iconify/maximize translations" >&5
22087 echo $ECHO_N "checking if you want support for iconify/maximize translations... $ECHO_C" >&6
22088
22089 # Check whether --enable-maximize or --disable-maximize was given.
22090 if test "${enable_maximize+set}" = set; then
22091 enableval="$enable_maximize"
22092 test "$enableval" != no && enableval=yes
22093 if test "$enableval" != "yes" ; then
22094 enable_maximize=no
22095 else
22096 enable_maximize=yes
22097 fi
22098 else
22099 enableval=yes
22100 enable_maximize=yes
22101
22102 fi;
22103 echo "$as_me:22103: result: $enable_maximize" >&5
22104 echo "${ECHO_T}$enable_maximize" >&6
22105 test "$enable_maximize" = no &&
22106 cat >>confdefs.h <<\EOF
22107 #define OPT_MAXIMIZE 0
22108 EOF
22109
22110 echo "$as_me:22110: checking if you want NumLock to override keyboard tables" >&5
22111 echo $ECHO_N "checking if you want NumLock to override keyboard tables... $ECHO_C" >&6
22112
22113 # Check whether --enable-num-lock or --disable-num-lock was given.
22114 if test "${enable_num_lock+set}" = set; then
22115 enableval="$enable_num_lock"
22116 test "$enableval" != no && enableval=yes
22117 if test "$enableval" != "yes" ; then
22118 enable_numlock=no
22119 else
22120 enable_numlock=yes
22121 fi
22122 else
22123 enableval=yes
22124 enable_numlock=yes
22125
22126 fi;
22127 echo "$as_me:22127: result: $enable_numlock" >&5
22128 echo "${ECHO_T}$enable_numlock" >&6
22129 test "$enable_numlock" = no &&
22130 cat >>confdefs.h <<\EOF
22131 #define OPT_NUM_LOCK 0
22132 EOF
22133
22134 echo "$as_me:22134: checking if you want support for get/set of base64 selection data" >&5
22135 echo $ECHO_N "checking if you want support for get/set of base64 selection data... $ECHO_C" >&6
22136
22137 # Check whether --enable-paste64 or --disable-paste64 was given.
22138 if test "${enable_paste64+set}" = set; then
22139 enableval="$enable_paste64"
22140 test "$enableval" != no && enableval=yes
22141 if test "$enableval" != "yes" ; then
22142 enable_paste64=no
22143 else
22144 enable_paste64=yes
22145 fi
22146 else
22147 enableval=yes
22148 enable_paste64=yes
22149
22150 fi;
22151 echo "$as_me:22151: result: $enable_paste64" >&5
22152 echo "${ECHO_T}$enable_paste64" >&6
22153 if test "$enable_paste64" = yes ; then
22154
22155 cat >>confdefs.h <<\EOF
22156 #define OPT_PASTE64 1
22157 EOF
22158
22159 else
22160
22161 cat >>confdefs.h <<\EOF
22162 #define OPT_PASTE64 0
22163 EOF
22164
22165 fi
22166
22167 echo "$as_me:22167: checking if you want support for pty-handshaking" >&5
22168 echo $ECHO_N "checking if you want support for pty-handshaking... $ECHO_C" >&6
22169
22170 # Check whether --enable-pty-handshake or --disable-pty-handshake was given.
22171 if test "${enable_pty_handshake+set}" = set; then
22172 enableval="$enable_pty_handshake"
22173 test "$enableval" != no && enableval=yes
22174 if test "$enableval" != "yes" ; then
22175 enable_pty_handshake=no
22176 else
22177 enable_pty_handshake=yes
22178 fi
22179 else
22180 enableval=yes
22181 enable_pty_handshake=yes
22182
22183 fi;
22184 echo "$as_me:22184: result: $enable_pty_handshake" >&5
22185 echo "${ECHO_T}$enable_pty_handshake" >&6
22186 if test "$enable_pty_handshake" = yes ; then
22187
22188 cat >>confdefs.h <<\EOF
22189 #define OPT_PTY_HANDSHAKE 1
22190 EOF
22191
22192 else
22193
22194 cat >>confdefs.h <<\EOF
22195 #define OPT_PTY_HANDSHAKE 0
22196 EOF
22197
22198 fi
22199
22200 echo "$as_me:22200: checking if you want support for mouse in readline applications" >&5
22201 echo $ECHO_N "checking if you want support for mouse in readline applications... $ECHO_C" >&6
22202
22203 # Check whether --enable-readline-mouse or --disable-readline-mouse was given.
22204 if test "${enable_readline_mouse+set}" = set; then
22205 enableval="$enable_readline_mouse"
22206 test "$enableval" != no && enableval=yes
22207 if test "$enableval" != "yes" ; then
22208 enable_readline_mouse=no
22209 else
22210 enable_readline_mouse=yes
22211 fi
22212 else
22213 enableval=yes
22214 enable_readline_mouse=yes
22215
22216 fi;
22217 echo "$as_me:22217: result: $enable_readline_mouse" >&5
22218 echo "${ECHO_T}$enable_readline_mouse" >&6
22219 if test "$enable_readline_mouse" = yes ; then
22220
22221 cat >>confdefs.h <<\EOF
22222 #define OPT_READLINE 1
22223 EOF
22224
22225 fi
22226
22227 echo "$as_me:22227: checking if you want support for regular-expression selections" >&5
22228 echo $ECHO_N "checking if you want support for regular-expression selections... $ECHO_C" >&6
22229
22230 # Check whether --enable-regex or --disable-regex was given.
22231 if test "${enable_regex+set}" = set; then
22232 enableval="$enable_regex"
22233 test "$enableval" != no && enableval=yes
22234 if test "$enableval" != "yes" ; then
22235 enable_regex=no
22236 else
22237 enable_regex=yes
22238 fi
22239 else
22240 enableval=yes
22241 enable_regex=yes
22242
22243 fi;
22244 echo "$as_me:22244: result: $enable_regex" >&5
22245 echo "${ECHO_T}$enable_regex" >&6
22246 if test "$enable_regex" = yes ; then
22247
22248 echo "$as_me:22248: checking if you want to use PCRE2 for regular-expressions" >&5
22249 echo $ECHO_N "checking if you want to use PCRE2 for regular-expressions... $ECHO_C" >&6
22250
22251 # Check whether --with-pcre2 or --without-pcre2 was given.
22252 if test "${with_pcre2+set}" = set; then
22253 withval="$with_pcre2"
22254
22255 fi;
22256 test -z "$with_pcre2" && with_pcre2=no
22257 echo "$as_me:22257: result: $with_pcre2" >&5
22258 echo "${ECHO_T}$with_pcre2" >&6
22259
22260 if test "x$with_pcre2" != xno ; then
22261 cf_list_pcre2="libpcre2 libpcre2-posix libpcre"
22262 test "x$with_pcre2" != xyes && cf_list_pcre2="$with_pcre2 $cf_lib_pcre2"
22263 cf_with_pcre2_ok=no
22264 for cf_with_pcre2 in $cf_list_pcre2
22265 do
22266
22267 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "$cf_with_pcre2"; then
22268 test -n "$verbose" && echo " found package $cf_with_pcre2" 1>&6
22269
22270 echo "${as_me:-configure}:22270: testing found package $cf_with_pcre2 ..." 1>&5
22271
22272 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "$cf_with_pcre2" 2>/dev/null`"
22273 cf_pkgconfig_libs="`$PKG_CONFIG --libs "$cf_with_pcre2" 2>/dev/null`"
22274 test -n "$verbose" && echo " package $cf_with_pcre2 CFLAGS: $cf_pkgconfig_incs" 1>&6
22275
22276 echo "${as_me:-configure}:22276: testing package $cf_with_pcre2 CFLAGS: $cf_pkgconfig_incs ..." 1>&5
22277
22278 test -n "$verbose" && echo " package $cf_with_pcre2 LIBS: $cf_pkgconfig_libs" 1>&6
22279
22280 echo "${as_me:-configure}:22280: testing package $cf_with_pcre2 LIBS: $cf_pkgconfig_libs ..." 1>&5
22281
22282 for cf_required in $cf_with_pcre2
22283 do
22284 # check for duplicates
22285 for cf_require_pkg in $REQUIRE_PKG
22286 do
22287 if test "$cf_required" = "$cf_require_pkg"
22288 then
22289 cf_required=
22290 break
22291 fi
22292 done
22293 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
22294 done
22295
22296 cf_fix_cppflags=no
22297 cf_new_cflags=
22298 cf_new_cppflags=
22299 cf_new_extra_cppflags=
22300
22301 for cf_add_cflags in $cf_pkgconfig_incs
22302 do
22303 case "$cf_fix_cppflags" in
22304 (no)
22305 case "$cf_add_cflags" in
22306 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
22307 case "$cf_add_cflags" in
22308 (-D*)
22309 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
22310
22311 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
22312 && test -z "${cf_tst_cflags}" \
22313 && cf_fix_cppflags=yes
22314
22315 if test "$cf_fix_cppflags" = yes ; then
22316
22317 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
22318 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
22319
22320 continue
22321 elif test "${cf_tst_cflags}" = "\"'" ; then
22322
22323 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
22324 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
22325
22326 continue
22327 fi
22328 ;;
22329 esac
22330 case "$CPPFLAGS" in
22331 (*$cf_add_cflags)
22332 ;;
22333 (*)
22334 case "$cf_add_cflags" in
22335 (-D*)
22336 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
22337
22338 CPPFLAGS=`echo "$CPPFLAGS" | \
22339 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
22340 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
22341
22342 ;;
22343 esac
22344
22345 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
22346 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
22347
22348 ;;
22349 esac
22350 ;;
22351 (*)
22352
22353 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
22354 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
22355
22356 ;;
22357 esac
22358 ;;
22359 (yes)
22360
22361 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
22362 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
22363
22364 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
22365
22366 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
22367 && test -z "${cf_tst_cflags}" \
22368 && cf_fix_cppflags=no
22369 ;;
22370 esac
22371 done
22372
22373 if test -n "$cf_new_cflags" ; then
22374
22375 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
22376 CFLAGS="${CFLAGS}$cf_new_cflags"
22377
22378 fi
22379
22380 if test -n "$cf_new_cppflags" ; then
22381
22382 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
22383 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
22384
22385 fi
22386
22387 if test -n "$cf_new_extra_cppflags" ; then
22388
22389 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
22390 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
22391
22392 fi
22393
22394 cf_add_libs="$LIBS"
22395 # reverse order
22396 cf_add_0lib=
22397 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
22398 # filter duplicates
22399 for cf_add_1lib in $cf_add_0lib; do
22400 for cf_add_2lib in $cf_add_libs; do
22401 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
22402 cf_add_1lib=
22403 break
22404 fi
22405 done
22406 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
22407 done
22408 LIBS="$cf_add_libs"
22409
22410 cf_with_pcre2_ok=yes; break
22411 else
22412 cf_pkgconfig_incs=
22413 cf_pkgconfig_libs=
22414 :
22415 fi
22416
22417 done
22418 cf_with_pcre2_ok=yes || { { echo "$as_me:22418: error: Cannot find PCRE2 library" >&5
22419 echo "$as_me: error: Cannot find PCRE2 library" >&2;}
22420 { (exit 1); exit 1; }; }
22421
22422 cat >>confdefs.h <<\EOF
22423 #define HAVE_LIB_PCRE2 1
22424 EOF
22425
22426 # if pkgconfig gave no results, look for the libraries directly
22427 case "$LIBS" in
22428 (*pcre2-posix*|*pcreposix*)
22429 ;;
22430 (*)
22431 echo "$as_me:22431: checking for regcomp in -lpcre2-posix" >&5
22432 echo $ECHO_N "checking for regcomp in -lpcre2-posix... $ECHO_C" >&6
22433 if test "${ac_cv_lib_pcre2_posix_regcomp+set}" = set; then
22434 echo $ECHO_N "(cached) $ECHO_C" >&6
22435 else
22436 ac_check_lib_save_LIBS=$LIBS
22437 LIBS="-lpcre2-posix $LIBS"
22438 cat >"conftest.$ac_ext" <<_ACEOF
22439 #line 22439 "configure"
22440 #include "confdefs.h"
22441
22442 /* Override any gcc2 internal prototype to avoid an error. */
22443 #ifdef __cplusplus
22444 extern "C"
22445 #endif
22446 /* We use char because int might match the return type of a gcc2
22447 builtin and then its argument prototype would still apply. */
22448 char regcomp (void);
22449 int
22450 main (void)
22451 {
22452 regcomp ();
22453 ;
22454 return 0;
22455 }
22456 _ACEOF
22457 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
22458 if { (eval echo "$as_me:22458: \"$ac_link\"") >&5
22459 (eval $ac_link) 2>&5
22460 ac_status=$?
22461 echo "$as_me:22461: \$? = $ac_status" >&5
22462 (exit "$ac_status"); } &&
22463 { ac_try='test -s "conftest$ac_exeext"'
22464 { (eval echo "$as_me:22464: \"$ac_try\"") >&5
22465 (eval $ac_try) 2>&5
22466 ac_status=$?
22467 echo "$as_me:22467: \$? = $ac_status" >&5
22468 (exit "$ac_status"); }; }; then
22469 ac_cv_lib_pcre2_posix_regcomp=yes
22470 else
22471 echo "$as_me: failed program was:" >&5
22472 cat "conftest.$ac_ext" >&5
22473 ac_cv_lib_pcre2_posix_regcomp=no
22474 fi
22475 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
22476 LIBS=$ac_check_lib_save_LIBS
22477 fi
22478 echo "$as_me:22478: result: $ac_cv_lib_pcre2_posix_regcomp" >&5
22479 echo "${ECHO_T}$ac_cv_lib_pcre2_posix_regcomp" >&6
22480 if test "$ac_cv_lib_pcre2_posix_regcomp" = yes; then
22481
22482 cf_add_libs="$LIBS"
22483 # reverse order
22484 cf_add_0lib=
22485 for cf_add_1lib in -lpcre2-posix; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
22486 # filter duplicates
22487 for cf_add_1lib in $cf_add_0lib; do
22488 for cf_add_2lib in $cf_add_libs; do
22489 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
22490 cf_add_1lib=
22491 break
22492 fi
22493 done
22494 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
22495 done
22496 LIBS="$cf_add_libs"
22497
22498 else
22499 echo "$as_me:22499: checking for regcomp in -lpcreposix" >&5
22500 echo $ECHO_N "checking for regcomp in -lpcreposix... $ECHO_C" >&6
22501 if test "${ac_cv_lib_pcreposix_regcomp+set}" = set; then
22502 echo $ECHO_N "(cached) $ECHO_C" >&6
22503 else
22504 ac_check_lib_save_LIBS=$LIBS
22505 LIBS="-lpcreposix $LIBS"
22506 cat >"conftest.$ac_ext" <<_ACEOF
22507 #line 22507 "configure"
22508 #include "confdefs.h"
22509
22510 /* Override any gcc2 internal prototype to avoid an error. */
22511 #ifdef __cplusplus
22512 extern "C"
22513 #endif
22514 /* We use char because int might match the return type of a gcc2
22515 builtin and then its argument prototype would still apply. */
22516 char regcomp (void);
22517 int
22518 main (void)
22519 {
22520 regcomp ();
22521 ;
22522 return 0;
22523 }
22524 _ACEOF
22525 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
22526 if { (eval echo "$as_me:22526: \"$ac_link\"") >&5
22527 (eval $ac_link) 2>&5
22528 ac_status=$?
22529 echo "$as_me:22529: \$? = $ac_status" >&5
22530 (exit "$ac_status"); } &&
22531 { ac_try='test -s "conftest$ac_exeext"'
22532 { (eval echo "$as_me:22532: \"$ac_try\"") >&5
22533 (eval $ac_try) 2>&5
22534 ac_status=$?
22535 echo "$as_me:22535: \$? = $ac_status" >&5
22536 (exit "$ac_status"); }; }; then
22537 ac_cv_lib_pcreposix_regcomp=yes
22538 else
22539 echo "$as_me: failed program was:" >&5
22540 cat "conftest.$ac_ext" >&5
22541 ac_cv_lib_pcreposix_regcomp=no
22542 fi
22543 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
22544 LIBS=$ac_check_lib_save_LIBS
22545 fi
22546 echo "$as_me:22546: result: $ac_cv_lib_pcreposix_regcomp" >&5
22547 echo "${ECHO_T}$ac_cv_lib_pcreposix_regcomp" >&6
22548 if test "$ac_cv_lib_pcreposix_regcomp" = yes; then
22549
22550 cf_add_libs="$LIBS"
22551 # reverse order
22552 cf_add_0lib=
22553 for cf_add_1lib in -lpcreposix; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
22554 # filter duplicates
22555 for cf_add_1lib in $cf_add_0lib; do
22556 for cf_add_2lib in $cf_add_libs; do
22557 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
22558 cf_add_1lib=
22559 break
22560 fi
22561 done
22562 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
22563 done
22564 LIBS="$cf_add_libs"
22565
22566 else
22567 { { echo "$as_me:22567: error: Cannot find PCRE2 POSIX library" >&5
22568 echo "$as_me: error: Cannot find PCRE2 POSIX library" >&2;}
22569 { (exit 1); exit 1; }; }
22570 fi
22571
22572 fi
22573
22574 ;;
22575 esac
22576
22577 # either way, check for the library header files
22578
22579 for ac_header in pcre2posix.h pcreposix.h
22580 do
22581 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
22582 echo "$as_me:22582: checking for $ac_header" >&5
22583 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
22584 if eval "test \"\${$as_ac_Header+set}\" = set"; then
22585 echo $ECHO_N "(cached) $ECHO_C" >&6
22586 else
22587 cat >"conftest.$ac_ext" <<_ACEOF
22588 #line 22588 "configure"
22589 #include "confdefs.h"
22590 #include <$ac_header>
22591 _ACEOF
22592 if { (eval echo "$as_me:22592: \"$ac_cpp "conftest.$ac_ext"\"") >&5
22593 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
22594 ac_status=$?
22595 $EGREP -v '^ *\+' conftest.er1 >conftest.err
22596 rm -f conftest.er1
22597 cat conftest.err >&5
22598 echo "$as_me:22598: \$? = $ac_status" >&5
22599 (exit "$ac_status"); } >/dev/null; then
22600 if test -s conftest.err; then
22601 ac_cpp_err=$ac_c_preproc_warn_flag
22602 else
22603 ac_cpp_err=
22604 fi
22605 else
22606 ac_cpp_err=yes
22607 fi
22608 if test -z "$ac_cpp_err"; then
22609 eval "$as_ac_Header=yes"
22610 else
22611 echo "$as_me: failed program was:" >&5
22612 cat "conftest.$ac_ext" >&5
22613 eval "$as_ac_Header=no"
22614 fi
22615 rm -f conftest.err "conftest.$ac_ext"
22616 fi
22617 echo "$as_me:22617: result: `eval echo '${'"$as_ac_Header"'}'`" >&5
22618 echo "${ECHO_T}`eval echo '${'"$as_ac_Header"'}'`" >&6
22619 if test "`eval echo '${'"$as_ac_Header"'}'`" = yes; then
22620 cat >>confdefs.h <<EOF
22621 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
22622 EOF
22623
22624 fi
22625 done
22626
22627 for ac_func in PCRE2regcomp
22628 do
22629 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
22630 echo "$as_me:22630: checking for $ac_func" >&5
22631 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
22632 if eval "test \"\${$as_ac_var+set}\" = set"; then
22633 echo $ECHO_N "(cached) $ECHO_C" >&6
22634 else
22635 cat >"conftest.$ac_ext" <<_ACEOF
22636 #line 22636 "configure"
22637 #include "confdefs.h"
22638 #define $ac_func autoconf_temporary
22639 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
22640 #undef $ac_func
22641
22642 #ifdef __cplusplus
22643 extern "C"
22644 #endif
22645
22646 /* We use char because int might match the return type of a gcc2
22647 builtin and then its argument prototype would still apply. */
22648 char $ac_func (void);
22649
22650 int
22651 main (void)
22652 {
22653
22654 /* The GNU C library defines stubs for functions which it implements
22655 to always fail with ENOSYS. Some functions are actually named
22656 something starting with __ and the normal name is an alias. */
22657 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
22658 #error found stub for $ac_func
22659 #endif
22660
22661 return $ac_func ();
22662 ;
22663 return 0;
22664 }
22665 _ACEOF
22666 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
22667 if { (eval echo "$as_me:22667: \"$ac_link\"") >&5
22668 (eval $ac_link) 2>&5
22669 ac_status=$?
22670 echo "$as_me:22670: \$? = $ac_status" >&5
22671 (exit "$ac_status"); } &&
22672 { ac_try='test -s "conftest$ac_exeext"'
22673 { (eval echo "$as_me:22673: \"$ac_try\"") >&5
22674 (eval $ac_try) 2>&5
22675 ac_status=$?
22676 echo "$as_me:22676: \$? = $ac_status" >&5
22677 (exit "$ac_status"); }; }; then
22678 eval "$as_ac_var=yes"
22679 else
22680 echo "$as_me: failed program was:" >&5
22681 cat "conftest.$ac_ext" >&5
22682 eval "$as_ac_var=no"
22683 fi
22684 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
22685 fi
22686 echo "$as_me:22686: result: `eval echo '${'"$as_ac_var"'}'`" >&5
22687 echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
22688 if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
22689 cat >>confdefs.h <<EOF
22690 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
22691 EOF
22692
22693 fi
22694 done
22695
22696 fi
22697
22698 if test "$with_pcre2" = no ; then
22699
22700 echo "$as_me:22700: checking if you want to use PCRE for regular-expressions" >&5
22701 echo $ECHO_N "checking if you want to use PCRE for regular-expressions... $ECHO_C" >&6
22702
22703 # Check whether --with-pcre or --without-pcre was given.
22704 if test "${with_pcre+set}" = set; then
22705 withval="$with_pcre"
22706
22707 fi;
22708 test -z "$with_pcre" && with_pcre=no
22709 echo "$as_me:22709: result: $with_pcre" >&5
22710 echo "${ECHO_T}$with_pcre" >&6
22711
22712 if test "$with_pcre" != no ; then
22713
22714 if test "$PKG_CONFIG" != none && "$PKG_CONFIG" --exists "libpcre"; then
22715 test -n "$verbose" && echo " found package libpcre" 1>&6
22716
22717 echo "${as_me:-configure}:22717: testing found package libpcre ..." 1>&5
22718
22719 cf_pkgconfig_incs="`$PKG_CONFIG --cflags "libpcre" 2>/dev/null`"
22720 cf_pkgconfig_libs="`$PKG_CONFIG --libs "libpcre" 2>/dev/null`"
22721 test -n "$verbose" && echo " package libpcre CFLAGS: $cf_pkgconfig_incs" 1>&6
22722
22723 echo "${as_me:-configure}:22723: testing package libpcre CFLAGS: $cf_pkgconfig_incs ..." 1>&5
22724
22725 test -n "$verbose" && echo " package libpcre LIBS: $cf_pkgconfig_libs" 1>&6
22726
22727 echo "${as_me:-configure}:22727: testing package libpcre LIBS: $cf_pkgconfig_libs ..." 1>&5
22728
22729 for cf_required in libpcre
22730 do
22731 # check for duplicates
22732 for cf_require_pkg in $REQUIRE_PKG
22733 do
22734 if test "$cf_required" = "$cf_require_pkg"
22735 then
22736 cf_required=
22737 break
22738 fi
22739 done
22740 test -n "$cf_required" && REQUIRE_PKG="$REQUIRE_PKG $cf_required"
22741 done
22742
22743 cf_fix_cppflags=no
22744 cf_new_cflags=
22745 cf_new_cppflags=
22746 cf_new_extra_cppflags=
22747
22748 for cf_add_cflags in $cf_pkgconfig_incs
22749 do
22750 case "$cf_fix_cppflags" in
22751 (no)
22752 case "$cf_add_cflags" in
22753 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
22754 case "$cf_add_cflags" in
22755 (-D*)
22756 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
22757
22758 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
22759 && test -z "${cf_tst_cflags}" \
22760 && cf_fix_cppflags=yes
22761
22762 if test "$cf_fix_cppflags" = yes ; then
22763
22764 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
22765 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
22766
22767 continue
22768 elif test "${cf_tst_cflags}" = "\"'" ; then
22769
22770 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
22771 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
22772
22773 continue
22774 fi
22775 ;;
22776 esac
22777 case "$CPPFLAGS" in
22778 (*$cf_add_cflags)
22779 ;;
22780 (*)
22781 case "$cf_add_cflags" in
22782 (-D*)
22783 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
22784
22785 CPPFLAGS=`echo "$CPPFLAGS" | \
22786 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
22787 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
22788
22789 ;;
22790 esac
22791
22792 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
22793 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
22794
22795 ;;
22796 esac
22797 ;;
22798 (*)
22799
22800 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
22801 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
22802
22803 ;;
22804 esac
22805 ;;
22806 (yes)
22807
22808 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
22809 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
22810
22811 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
22812
22813 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
22814 && test -z "${cf_tst_cflags}" \
22815 && cf_fix_cppflags=no
22816 ;;
22817 esac
22818 done
22819
22820 if test -n "$cf_new_cflags" ; then
22821
22822 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
22823 CFLAGS="${CFLAGS}$cf_new_cflags"
22824
22825 fi
22826
22827 if test -n "$cf_new_cppflags" ; then
22828
22829 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
22830 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
22831
22832 fi
22833
22834 if test -n "$cf_new_extra_cppflags" ; then
22835
22836 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
22837 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
22838
22839 fi
22840
22841 cf_add_libs="$LIBS"
22842 # reverse order
22843 cf_add_0lib=
22844 for cf_add_1lib in $cf_pkgconfig_libs; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
22845 # filter duplicates
22846 for cf_add_1lib in $cf_add_0lib; do
22847 for cf_add_2lib in $cf_add_libs; do
22848 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
22849 cf_add_1lib=
22850 break
22851 fi
22852 done
22853 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
22854 done
22855 LIBS="$cf_add_libs"
22856
22857 :
22858 else
22859 cf_pkgconfig_incs=
22860 cf_pkgconfig_libs=
22861
22862 echo "$as_me:22862: checking for pcre_compile in -lpcre" >&5
22863 echo $ECHO_N "checking for pcre_compile in -lpcre... $ECHO_C" >&6
22864 if test "${ac_cv_lib_pcre_pcre_compile+set}" = set; then
22865 echo $ECHO_N "(cached) $ECHO_C" >&6
22866 else
22867 ac_check_lib_save_LIBS=$LIBS
22868 LIBS="-lpcre $LIBS"
22869 cat >"conftest.$ac_ext" <<_ACEOF
22870 #line 22870 "configure"
22871 #include "confdefs.h"
22872
22873 /* Override any gcc2 internal prototype to avoid an error. */
22874 #ifdef __cplusplus
22875 extern "C"
22876 #endif
22877 /* We use char because int might match the return type of a gcc2
22878 builtin and then its argument prototype would still apply. */
22879 char pcre_compile (void);
22880 int
22881 main (void)
22882 {
22883 pcre_compile ();
22884 ;
22885 return 0;
22886 }
22887 _ACEOF
22888 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
22889 if { (eval echo "$as_me:22889: \"$ac_link\"") >&5
22890 (eval $ac_link) 2>&5
22891 ac_status=$?
22892 echo "$as_me:22892: \$? = $ac_status" >&5
22893 (exit "$ac_status"); } &&
22894 { ac_try='test -s "conftest$ac_exeext"'
22895 { (eval echo "$as_me:22895: \"$ac_try\"") >&5
22896 (eval $ac_try) 2>&5
22897 ac_status=$?
22898 echo "$as_me:22898: \$? = $ac_status" >&5
22899 (exit "$ac_status"); }; }; then
22900 ac_cv_lib_pcre_pcre_compile=yes
22901 else
22902 echo "$as_me: failed program was:" >&5
22903 cat "conftest.$ac_ext" >&5
22904 ac_cv_lib_pcre_pcre_compile=no
22905 fi
22906 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
22907 LIBS=$ac_check_lib_save_LIBS
22908 fi
22909 echo "$as_me:22909: result: $ac_cv_lib_pcre_pcre_compile" >&5
22910 echo "${ECHO_T}$ac_cv_lib_pcre_pcre_compile" >&6
22911 if test "$ac_cv_lib_pcre_pcre_compile" = yes; then
22912 cat >>confdefs.h <<EOF
22913 #define HAVE_LIBPCRE 1
22914 EOF
22915
22916 LIBS="-lpcre $LIBS"
22917
22918 else
22919 { { echo "$as_me:22919: error: Cannot find PCRE library" >&5
22920 echo "$as_me: error: Cannot find PCRE library" >&2;}
22921 { (exit 1); exit 1; }; }
22922 fi
22923
22924 fi
22925
22926 cat >>confdefs.h <<\EOF
22927 #define HAVE_LIB_PCRE 1
22928 EOF
22929
22930 case $LIBS in
22931 (*pcreposix*)
22932 ;;
22933 (*)
22934 echo "$as_me:22934: checking for pcreposix_regcomp in -lpcreposix" >&5
22935 echo $ECHO_N "checking for pcreposix_regcomp in -lpcreposix... $ECHO_C" >&6
22936 if test "${ac_cv_lib_pcreposix_pcreposix_regcomp+set}" = set; then
22937 echo $ECHO_N "(cached) $ECHO_C" >&6
22938 else
22939 ac_check_lib_save_LIBS=$LIBS
22940 LIBS="-lpcreposix $LIBS"
22941 cat >"conftest.$ac_ext" <<_ACEOF
22942 #line 22942 "configure"
22943 #include "confdefs.h"
22944
22945 /* Override any gcc2 internal prototype to avoid an error. */
22946 #ifdef __cplusplus
22947 extern "C"
22948 #endif
22949 /* We use char because int might match the return type of a gcc2
22950 builtin and then its argument prototype would still apply. */
22951 char pcreposix_regcomp (void);
22952 int
22953 main (void)
22954 {
22955 pcreposix_regcomp ();
22956 ;
22957 return 0;
22958 }
22959 _ACEOF
22960 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
22961 if { (eval echo "$as_me:22961: \"$ac_link\"") >&5
22962 (eval $ac_link) 2>&5
22963 ac_status=$?
22964 echo "$as_me:22964: \$? = $ac_status" >&5
22965 (exit "$ac_status"); } &&
22966 { ac_try='test -s "conftest$ac_exeext"'
22967 { (eval echo "$as_me:22967: \"$ac_try\"") >&5
22968 (eval $ac_try) 2>&5
22969 ac_status=$?
22970 echo "$as_me:22970: \$? = $ac_status" >&5
22971 (exit "$ac_status"); }; }; then
22972 ac_cv_lib_pcreposix_pcreposix_regcomp=yes
22973 else
22974 echo "$as_me: failed program was:" >&5
22975 cat "conftest.$ac_ext" >&5
22976 ac_cv_lib_pcreposix_pcreposix_regcomp=no
22977 fi
22978 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
22979 LIBS=$ac_check_lib_save_LIBS
22980 fi
22981 echo "$as_me:22981: result: $ac_cv_lib_pcreposix_pcreposix_regcomp" >&5
22982 echo "${ECHO_T}$ac_cv_lib_pcreposix_pcreposix_regcomp" >&6
22983 if test "$ac_cv_lib_pcreposix_pcreposix_regcomp" = yes; then
22984
22985 cat >>confdefs.h <<\EOF
22986 #define HAVE_PCREPOSIX_H 1
22987 EOF
22988
22989 cf_add_libs="$LIBS"
22990 # reverse order
22991 cf_add_0lib=
22992 for cf_add_1lib in -lpcreposix; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
22993 # filter duplicates
22994 for cf_add_1lib in $cf_add_0lib; do
22995 for cf_add_2lib in $cf_add_libs; do
22996 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
22997 cf_add_1lib=
22998 break
22999 fi
23000 done
23001 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
23002 done
23003 LIBS="$cf_add_libs"
23004
23005 else
23006 echo "$as_me:23006: checking for regcomp in -lpcreposix" >&5
23007 echo $ECHO_N "checking for regcomp in -lpcreposix... $ECHO_C" >&6
23008 if test "${ac_cv_lib_pcreposix_regcomp+set}" = set; then
23009 echo $ECHO_N "(cached) $ECHO_C" >&6
23010 else
23011 ac_check_lib_save_LIBS=$LIBS
23012 LIBS="-lpcreposix $LIBS"
23013 cat >"conftest.$ac_ext" <<_ACEOF
23014 #line 23014 "configure"
23015 #include "confdefs.h"
23016
23017 /* Override any gcc2 internal prototype to avoid an error. */
23018 #ifdef __cplusplus
23019 extern "C"
23020 #endif
23021 /* We use char because int might match the return type of a gcc2
23022 builtin and then its argument prototype would still apply. */
23023 char regcomp (void);
23024 int
23025 main (void)
23026 {
23027 regcomp ();
23028 ;
23029 return 0;
23030 }
23031 _ACEOF
23032 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
23033 if { (eval echo "$as_me:23033: \"$ac_link\"") >&5
23034 (eval $ac_link) 2>&5
23035 ac_status=$?
23036 echo "$as_me:23036: \$? = $ac_status" >&5
23037 (exit "$ac_status"); } &&
23038 { ac_try='test -s "conftest$ac_exeext"'
23039 { (eval echo "$as_me:23039: \"$ac_try\"") >&5
23040 (eval $ac_try) 2>&5
23041 ac_status=$?
23042 echo "$as_me:23042: \$? = $ac_status" >&5
23043 (exit "$ac_status"); }; }; then
23044 ac_cv_lib_pcreposix_regcomp=yes
23045 else
23046 echo "$as_me: failed program was:" >&5
23047 cat "conftest.$ac_ext" >&5
23048 ac_cv_lib_pcreposix_regcomp=no
23049 fi
23050 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
23051 LIBS=$ac_check_lib_save_LIBS
23052 fi
23053 echo "$as_me:23053: result: $ac_cv_lib_pcreposix_regcomp" >&5
23054 echo "${ECHO_T}$ac_cv_lib_pcreposix_regcomp" >&6
23055 if test "$ac_cv_lib_pcreposix_regcomp" = yes; then
23056
23057 cat >>confdefs.h <<\EOF
23058 #define HAVE_PCREPOSIX_H 1
23059 EOF
23060
23061 cf_add_libs="$LIBS"
23062 # reverse order
23063 cf_add_0lib=
23064 for cf_add_1lib in -lpcreposix; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
23065 # filter duplicates
23066 for cf_add_1lib in $cf_add_0lib; do
23067 for cf_add_2lib in $cf_add_libs; do
23068 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
23069 cf_add_1lib=
23070 break
23071 fi
23072 done
23073 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
23074 done
23075 LIBS="$cf_add_libs"
23076
23077 else
23078 { { echo "$as_me:23078: error: Cannot find PCRE POSIX library" >&5
23079 echo "$as_me: error: Cannot find PCRE POSIX library" >&2;}
23080 { (exit 1); exit 1; }; }
23081 fi
23082
23083 fi
23084
23085 ;;
23086 esac
23087 fi
23088
23089 if test "$with_pcre" = no ; then
23090
23091 cf_regex_func=no
23092 cf_regex_libs=
23093 case "$host_os" in
23094 (mingw*)
23095 echo "$as_me:23095: checking for regcomp" >&5
23096 echo $ECHO_N "checking for regcomp... $ECHO_C" >&6
23097 if test "${ac_cv_func_regcomp+set}" = set; then
23098 echo $ECHO_N "(cached) $ECHO_C" >&6
23099 else
23100 cat >"conftest.$ac_ext" <<_ACEOF
23101 #line 23101 "configure"
23102 #include "confdefs.h"
23103 #define regcomp autoconf_temporary
23104 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
23105 #undef regcomp
23106
23107 #ifdef __cplusplus
23108 extern "C"
23109 #endif
23110
23111 /* We use char because int might match the return type of a gcc2
23112 builtin and then its argument prototype would still apply. */
23113 char regcomp (void);
23114
23115 int
23116 main (void)
23117 {
23118
23119 /* The GNU C library defines stubs for functions which it implements
23120 to always fail with ENOSYS. Some functions are actually named
23121 something starting with __ and the normal name is an alias. */
23122 #if defined (__stub_regcomp) || defined (__stub___regcomp)
23123 #error found stub for regcomp
23124 #endif
23125
23126 return regcomp ();
23127 ;
23128 return 0;
23129 }
23130 _ACEOF
23131 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
23132 if { (eval echo "$as_me:23132: \"$ac_link\"") >&5
23133 (eval $ac_link) 2>&5
23134 ac_status=$?
23135 echo "$as_me:23135: \$? = $ac_status" >&5
23136 (exit "$ac_status"); } &&
23137 { ac_try='test -s "conftest$ac_exeext"'
23138 { (eval echo "$as_me:23138: \"$ac_try\"") >&5
23139 (eval $ac_try) 2>&5
23140 ac_status=$?
23141 echo "$as_me:23141: \$? = $ac_status" >&5
23142 (exit "$ac_status"); }; }; then
23143 ac_cv_func_regcomp=yes
23144 else
23145 echo "$as_me: failed program was:" >&5
23146 cat "conftest.$ac_ext" >&5
23147 ac_cv_func_regcomp=no
23148 fi
23149 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
23150 fi
23151 echo "$as_me:23151: result: $ac_cv_func_regcomp" >&5
23152 echo "${ECHO_T}$ac_cv_func_regcomp" >&6
23153 if test "$ac_cv_func_regcomp" = yes; then
23154 cf_regex_func=regcomp
23155 else
23156
23157 cf_regex_libs="systre gnurx"
23158 for cf_regex_lib in $cf_regex_libs
23159 do
23160 as_ac_Lib=`echo "ac_cv_lib_$cf_regex_lib''_regcomp" | $as_tr_sh`
23161 echo "$as_me:23161: checking for regcomp in -l$cf_regex_lib" >&5
23162 echo $ECHO_N "checking for regcomp in -l$cf_regex_lib... $ECHO_C" >&6
23163 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
23164 echo $ECHO_N "(cached) $ECHO_C" >&6
23165 else
23166 ac_check_lib_save_LIBS=$LIBS
23167 LIBS="-l$cf_regex_lib $LIBS"
23168 cat >"conftest.$ac_ext" <<_ACEOF
23169 #line 23169 "configure"
23170 #include "confdefs.h"
23171
23172 /* Override any gcc2 internal prototype to avoid an error. */
23173 #ifdef __cplusplus
23174 extern "C"
23175 #endif
23176 /* We use char because int might match the return type of a gcc2
23177 builtin and then its argument prototype would still apply. */
23178 char regcomp (void);
23179 int
23180 main (void)
23181 {
23182 regcomp ();
23183 ;
23184 return 0;
23185 }
23186 _ACEOF
23187 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
23188 if { (eval echo "$as_me:23188: \"$ac_link\"") >&5
23189 (eval $ac_link) 2>&5
23190 ac_status=$?
23191 echo "$as_me:23191: \$? = $ac_status" >&5
23192 (exit "$ac_status"); } &&
23193 { ac_try='test -s "conftest$ac_exeext"'
23194 { (eval echo "$as_me:23194: \"$ac_try\"") >&5
23195 (eval $ac_try) 2>&5
23196 ac_status=$?
23197 echo "$as_me:23197: \$? = $ac_status" >&5
23198 (exit "$ac_status"); }; }; then
23199 eval "$as_ac_Lib=yes"
23200 else
23201 echo "$as_me: failed program was:" >&5
23202 cat "conftest.$ac_ext" >&5
23203 eval "$as_ac_Lib=no"
23204 fi
23205 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
23206 LIBS=$ac_check_lib_save_LIBS
23207 fi
23208 echo "$as_me:23208: result: `eval echo '${'"$as_ac_Lib"'}'`" >&5
23209 echo "${ECHO_T}`eval echo '${'"$as_ac_Lib"'}'`" >&6
23210 if test "`eval echo '${'"$as_ac_Lib"'}'`" = yes; then
23211 cf_regex_func=regcomp; break
23212 fi
23213
23214 done
23215 if test $cf_regex_func != no; then
23216 case "$cf_regex_lib" in
23217 (systre)
23218 # -lsystre -ltre -lintl -liconv
23219 echo "$as_me:23219: checking for libiconv_open in -liconv" >&5
23220 echo $ECHO_N "checking for libiconv_open in -liconv... $ECHO_C" >&6
23221 if test "${ac_cv_lib_iconv_libiconv_open+set}" = set; then
23222 echo $ECHO_N "(cached) $ECHO_C" >&6
23223 else
23224 ac_check_lib_save_LIBS=$LIBS
23225 LIBS="-liconv $LIBS"
23226 cat >"conftest.$ac_ext" <<_ACEOF
23227 #line 23227 "configure"
23228 #include "confdefs.h"
23229
23230 /* Override any gcc2 internal prototype to avoid an error. */
23231 #ifdef __cplusplus
23232 extern "C"
23233 #endif
23234 /* We use char because int might match the return type of a gcc2
23235 builtin and then its argument prototype would still apply. */
23236 char libiconv_open (void);
23237 int
23238 main (void)
23239 {
23240 libiconv_open ();
23241 ;
23242 return 0;
23243 }
23244 _ACEOF
23245 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
23246 if { (eval echo "$as_me:23246: \"$ac_link\"") >&5
23247 (eval $ac_link) 2>&5
23248 ac_status=$?
23249 echo "$as_me:23249: \$? = $ac_status" >&5
23250 (exit "$ac_status"); } &&
23251 { ac_try='test -s "conftest$ac_exeext"'
23252 { (eval echo "$as_me:23252: \"$ac_try\"") >&5
23253 (eval $ac_try) 2>&5
23254 ac_status=$?
23255 echo "$as_me:23255: \$? = $ac_status" >&5
23256 (exit "$ac_status"); }; }; then
23257 ac_cv_lib_iconv_libiconv_open=yes
23258 else
23259 echo "$as_me: failed program was:" >&5
23260 cat "conftest.$ac_ext" >&5
23261 ac_cv_lib_iconv_libiconv_open=no
23262 fi
23263 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
23264 LIBS=$ac_check_lib_save_LIBS
23265 fi
23266 echo "$as_me:23266: result: $ac_cv_lib_iconv_libiconv_open" >&5
23267 echo "${ECHO_T}$ac_cv_lib_iconv_libiconv_open" >&6
23268 if test "$ac_cv_lib_iconv_libiconv_open" = yes; then
23269
23270 cf_add_libs="$LIBS"
23271 # reverse order
23272 cf_add_0lib=
23273 for cf_add_1lib in -liconv; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
23274 # filter duplicates
23275 for cf_add_1lib in $cf_add_0lib; do
23276 for cf_add_2lib in $cf_add_libs; do
23277 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
23278 cf_add_1lib=
23279 break
23280 fi
23281 done
23282 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
23283 done
23284 LIBS="$cf_add_libs"
23285
23286 fi
23287
23288 echo "$as_me:23288: checking for libintl_gettext in -lintl" >&5
23289 echo $ECHO_N "checking for libintl_gettext in -lintl... $ECHO_C" >&6
23290 if test "${ac_cv_lib_intl_libintl_gettext+set}" = set; then
23291 echo $ECHO_N "(cached) $ECHO_C" >&6
23292 else
23293 ac_check_lib_save_LIBS=$LIBS
23294 LIBS="-lintl $LIBS"
23295 cat >"conftest.$ac_ext" <<_ACEOF
23296 #line 23296 "configure"
23297 #include "confdefs.h"
23298
23299 /* Override any gcc2 internal prototype to avoid an error. */
23300 #ifdef __cplusplus
23301 extern "C"
23302 #endif
23303 /* We use char because int might match the return type of a gcc2
23304 builtin and then its argument prototype would still apply. */
23305 char libintl_gettext (void);
23306 int
23307 main (void)
23308 {
23309 libintl_gettext ();
23310 ;
23311 return 0;
23312 }
23313 _ACEOF
23314 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
23315 if { (eval echo "$as_me:23315: \"$ac_link\"") >&5
23316 (eval $ac_link) 2>&5
23317 ac_status=$?
23318 echo "$as_me:23318: \$? = $ac_status" >&5
23319 (exit "$ac_status"); } &&
23320 { ac_try='test -s "conftest$ac_exeext"'
23321 { (eval echo "$as_me:23321: \"$ac_try\"") >&5
23322 (eval $ac_try) 2>&5
23323 ac_status=$?
23324 echo "$as_me:23324: \$? = $ac_status" >&5
23325 (exit "$ac_status"); }; }; then
23326 ac_cv_lib_intl_libintl_gettext=yes
23327 else
23328 echo "$as_me: failed program was:" >&5
23329 cat "conftest.$ac_ext" >&5
23330 ac_cv_lib_intl_libintl_gettext=no
23331 fi
23332 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
23333 LIBS=$ac_check_lib_save_LIBS
23334 fi
23335 echo "$as_me:23335: result: $ac_cv_lib_intl_libintl_gettext" >&5
23336 echo "${ECHO_T}$ac_cv_lib_intl_libintl_gettext" >&6
23337 if test "$ac_cv_lib_intl_libintl_gettext" = yes; then
23338
23339 cf_add_libs="$LIBS"
23340 # reverse order
23341 cf_add_0lib=
23342 for cf_add_1lib in -lintl; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
23343 # filter duplicates
23344 for cf_add_1lib in $cf_add_0lib; do
23345 for cf_add_2lib in $cf_add_libs; do
23346 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
23347 cf_add_1lib=
23348 break
23349 fi
23350 done
23351 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
23352 done
23353 LIBS="$cf_add_libs"
23354
23355 fi
23356
23357 echo "$as_me:23357: checking for tre_regcomp in -ltre" >&5
23358 echo $ECHO_N "checking for tre_regcomp in -ltre... $ECHO_C" >&6
23359 if test "${ac_cv_lib_tre_tre_regcomp+set}" = set; then
23360 echo $ECHO_N "(cached) $ECHO_C" >&6
23361 else
23362 ac_check_lib_save_LIBS=$LIBS
23363 LIBS="-ltre $LIBS"
23364 cat >"conftest.$ac_ext" <<_ACEOF
23365 #line 23365 "configure"
23366 #include "confdefs.h"
23367
23368 /* Override any gcc2 internal prototype to avoid an error. */
23369 #ifdef __cplusplus
23370 extern "C"
23371 #endif
23372 /* We use char because int might match the return type of a gcc2
23373 builtin and then its argument prototype would still apply. */
23374 char tre_regcomp (void);
23375 int
23376 main (void)
23377 {
23378 tre_regcomp ();
23379 ;
23380 return 0;
23381 }
23382 _ACEOF
23383 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
23384 if { (eval echo "$as_me:23384: \"$ac_link\"") >&5
23385 (eval $ac_link) 2>&5
23386 ac_status=$?
23387 echo "$as_me:23387: \$? = $ac_status" >&5
23388 (exit "$ac_status"); } &&
23389 { ac_try='test -s "conftest$ac_exeext"'
23390 { (eval echo "$as_me:23390: \"$ac_try\"") >&5
23391 (eval $ac_try) 2>&5
23392 ac_status=$?
23393 echo "$as_me:23393: \$? = $ac_status" >&5
23394 (exit "$ac_status"); }; }; then
23395 ac_cv_lib_tre_tre_regcomp=yes
23396 else
23397 echo "$as_me: failed program was:" >&5
23398 cat "conftest.$ac_ext" >&5
23399 ac_cv_lib_tre_tre_regcomp=no
23400 fi
23401 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
23402 LIBS=$ac_check_lib_save_LIBS
23403 fi
23404 echo "$as_me:23404: result: $ac_cv_lib_tre_tre_regcomp" >&5
23405 echo "${ECHO_T}$ac_cv_lib_tre_tre_regcomp" >&6
23406 if test "$ac_cv_lib_tre_tre_regcomp" = yes; then
23407
23408 cf_add_libs="$LIBS"
23409 # reverse order
23410 cf_add_0lib=
23411 for cf_add_1lib in -ltre; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
23412 # filter duplicates
23413 for cf_add_1lib in $cf_add_0lib; do
23414 for cf_add_2lib in $cf_add_libs; do
23415 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
23416 cf_add_1lib=
23417 break
23418 fi
23419 done
23420 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
23421 done
23422 LIBS="$cf_add_libs"
23423
23424 fi
23425
23426 ;;
23427 esac
23428
23429 cf_add_libs="$LIBS"
23430 # reverse order
23431 cf_add_0lib=
23432 for cf_add_1lib in -l$cf_regex_lib; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
23433 # filter duplicates
23434 for cf_add_1lib in $cf_add_0lib; do
23435 for cf_add_2lib in $cf_add_libs; do
23436 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
23437 cf_add_1lib=
23438 break
23439 fi
23440 done
23441 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
23442 done
23443 LIBS="$cf_add_libs"
23444
23445 fi
23446
23447 fi
23448
23449 ;;
23450 (*)
23451 cf_regex_libs="regex re"
23452 echo "$as_me:23452: checking for regcomp" >&5
23453 echo $ECHO_N "checking for regcomp... $ECHO_C" >&6
23454 if test "${ac_cv_func_regcomp+set}" = set; then
23455 echo $ECHO_N "(cached) $ECHO_C" >&6
23456 else
23457 cat >"conftest.$ac_ext" <<_ACEOF
23458 #line 23458 "configure"
23459 #include "confdefs.h"
23460 #define regcomp autoconf_temporary
23461 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
23462 #undef regcomp
23463
23464 #ifdef __cplusplus
23465 extern "C"
23466 #endif
23467
23468 /* We use char because int might match the return type of a gcc2
23469 builtin and then its argument prototype would still apply. */
23470 char regcomp (void);
23471
23472 int
23473 main (void)
23474 {
23475
23476 /* The GNU C library defines stubs for functions which it implements
23477 to always fail with ENOSYS. Some functions are actually named
23478 something starting with __ and the normal name is an alias. */
23479 #if defined (__stub_regcomp) || defined (__stub___regcomp)
23480 #error found stub for regcomp
23481 #endif
23482
23483 return regcomp ();
23484 ;
23485 return 0;
23486 }
23487 _ACEOF
23488 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
23489 if { (eval echo "$as_me:23489: \"$ac_link\"") >&5
23490 (eval $ac_link) 2>&5
23491 ac_status=$?
23492 echo "$as_me:23492: \$? = $ac_status" >&5
23493 (exit "$ac_status"); } &&
23494 { ac_try='test -s "conftest$ac_exeext"'
23495 { (eval echo "$as_me:23495: \"$ac_try\"") >&5
23496 (eval $ac_try) 2>&5
23497 ac_status=$?
23498 echo "$as_me:23498: \$? = $ac_status" >&5
23499 (exit "$ac_status"); }; }; then
23500 ac_cv_func_regcomp=yes
23501 else
23502 echo "$as_me: failed program was:" >&5
23503 cat "conftest.$ac_ext" >&5
23504 ac_cv_func_regcomp=no
23505 fi
23506 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
23507 fi
23508 echo "$as_me:23508: result: $ac_cv_func_regcomp" >&5
23509 echo "${ECHO_T}$ac_cv_func_regcomp" >&6
23510 if test "$ac_cv_func_regcomp" = yes; then
23511 cf_regex_func=regcomp
23512 else
23513
23514 for cf_regex_lib in $cf_regex_libs
23515 do
23516 as_ac_Lib=`echo "ac_cv_lib_$cf_regex_lib''_regcomp" | $as_tr_sh`
23517 echo "$as_me:23517: checking for regcomp in -l$cf_regex_lib" >&5
23518 echo $ECHO_N "checking for regcomp in -l$cf_regex_lib... $ECHO_C" >&6
23519 if eval "test \"\${$as_ac_Lib+set}\" = set"; then
23520 echo $ECHO_N "(cached) $ECHO_C" >&6
23521 else
23522 ac_check_lib_save_LIBS=$LIBS
23523 LIBS="-l$cf_regex_lib $LIBS"
23524 cat >"conftest.$ac_ext" <<_ACEOF
23525 #line 23525 "configure"
23526 #include "confdefs.h"
23527
23528 /* Override any gcc2 internal prototype to avoid an error. */
23529 #ifdef __cplusplus
23530 extern "C"
23531 #endif
23532 /* We use char because int might match the return type of a gcc2
23533 builtin and then its argument prototype would still apply. */
23534 char regcomp (void);
23535 int
23536 main (void)
23537 {
23538 regcomp ();
23539 ;
23540 return 0;
23541 }
23542 _ACEOF
23543 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
23544 if { (eval echo "$as_me:23544: \"$ac_link\"") >&5
23545 (eval $ac_link) 2>&5
23546 ac_status=$?
23547 echo "$as_me:23547: \$? = $ac_status" >&5
23548 (exit "$ac_status"); } &&
23549 { ac_try='test -s "conftest$ac_exeext"'
23550 { (eval echo "$as_me:23550: \"$ac_try\"") >&5
23551 (eval $ac_try) 2>&5
23552 ac_status=$?
23553 echo "$as_me:23553: \$? = $ac_status" >&5
23554 (exit "$ac_status"); }; }; then
23555 eval "$as_ac_Lib=yes"
23556 else
23557 echo "$as_me: failed program was:" >&5
23558 cat "conftest.$ac_ext" >&5
23559 eval "$as_ac_Lib=no"
23560 fi
23561 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
23562 LIBS=$ac_check_lib_save_LIBS
23563 fi
23564 echo "$as_me:23564: result: `eval echo '${'"$as_ac_Lib"'}'`" >&5
23565 echo "${ECHO_T}`eval echo '${'"$as_ac_Lib"'}'`" >&6
23566 if test "`eval echo '${'"$as_ac_Lib"'}'`" = yes; then
23567
23568 cf_add_libs="$LIBS"
23569 # reverse order
23570 cf_add_0lib=
23571 for cf_add_1lib in -l$cf_regex_lib; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
23572 # filter duplicates
23573 for cf_add_1lib in $cf_add_0lib; do
23574 for cf_add_2lib in $cf_add_libs; do
23575 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
23576 cf_add_1lib=
23577 break
23578 fi
23579 done
23580 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
23581 done
23582 LIBS="$cf_add_libs"
23583
23584 cf_regex_func=regcomp
23585 break
23586 fi
23587
23588 done
23589
23590 fi
23591
23592 ;;
23593 esac
23594
23595 if test "$cf_regex_func" = no ; then
23596 echo "$as_me:23596: checking for compile" >&5
23597 echo $ECHO_N "checking for compile... $ECHO_C" >&6
23598 if test "${ac_cv_func_compile+set}" = set; then
23599 echo $ECHO_N "(cached) $ECHO_C" >&6
23600 else
23601 cat >"conftest.$ac_ext" <<_ACEOF
23602 #line 23602 "configure"
23603 #include "confdefs.h"
23604 #define compile autoconf_temporary
23605 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
23606 #undef compile
23607
23608 #ifdef __cplusplus
23609 extern "C"
23610 #endif
23611
23612 /* We use char because int might match the return type of a gcc2
23613 builtin and then its argument prototype would still apply. */
23614 char compile (void);
23615
23616 int
23617 main (void)
23618 {
23619
23620 /* The GNU C library defines stubs for functions which it implements
23621 to always fail with ENOSYS. Some functions are actually named
23622 something starting with __ and the normal name is an alias. */
23623 #if defined (__stub_compile) || defined (__stub___compile)
23624 #error found stub for compile
23625 #endif
23626
23627 return compile ();
23628 ;
23629 return 0;
23630 }
23631 _ACEOF
23632 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
23633 if { (eval echo "$as_me:23633: \"$ac_link\"") >&5
23634 (eval $ac_link) 2>&5
23635 ac_status=$?
23636 echo "$as_me:23636: \$? = $ac_status" >&5
23637 (exit "$ac_status"); } &&
23638 { ac_try='test -s "conftest$ac_exeext"'
23639 { (eval echo "$as_me:23639: \"$ac_try\"") >&5
23640 (eval $ac_try) 2>&5
23641 ac_status=$?
23642 echo "$as_me:23642: \$? = $ac_status" >&5
23643 (exit "$ac_status"); }; }; then
23644 ac_cv_func_compile=yes
23645 else
23646 echo "$as_me: failed program was:" >&5
23647 cat "conftest.$ac_ext" >&5
23648 ac_cv_func_compile=no
23649 fi
23650 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
23651 fi
23652 echo "$as_me:23652: result: $ac_cv_func_compile" >&5
23653 echo "${ECHO_T}$ac_cv_func_compile" >&6
23654 if test "$ac_cv_func_compile" = yes; then
23655 cf_regex_func=compile
23656 else
23657
23658 echo "$as_me:23658: checking for compile in -lgen" >&5
23659 echo $ECHO_N "checking for compile in -lgen... $ECHO_C" >&6
23660 if test "${ac_cv_lib_gen_compile+set}" = set; then
23661 echo $ECHO_N "(cached) $ECHO_C" >&6
23662 else
23663 ac_check_lib_save_LIBS=$LIBS
23664 LIBS="-lgen $LIBS"
23665 cat >"conftest.$ac_ext" <<_ACEOF
23666 #line 23666 "configure"
23667 #include "confdefs.h"
23668
23669 /* Override any gcc2 internal prototype to avoid an error. */
23670 #ifdef __cplusplus
23671 extern "C"
23672 #endif
23673 /* We use char because int might match the return type of a gcc2
23674 builtin and then its argument prototype would still apply. */
23675 char compile (void);
23676 int
23677 main (void)
23678 {
23679 compile ();
23680 ;
23681 return 0;
23682 }
23683 _ACEOF
23684 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
23685 if { (eval echo "$as_me:23685: \"$ac_link\"") >&5
23686 (eval $ac_link) 2>&5
23687 ac_status=$?
23688 echo "$as_me:23688: \$? = $ac_status" >&5
23689 (exit "$ac_status"); } &&
23690 { ac_try='test -s "conftest$ac_exeext"'
23691 { (eval echo "$as_me:23691: \"$ac_try\"") >&5
23692 (eval $ac_try) 2>&5
23693 ac_status=$?
23694 echo "$as_me:23694: \$? = $ac_status" >&5
23695 (exit "$ac_status"); }; }; then
23696 ac_cv_lib_gen_compile=yes
23697 else
23698 echo "$as_me: failed program was:" >&5
23699 cat "conftest.$ac_ext" >&5
23700 ac_cv_lib_gen_compile=no
23701 fi
23702 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
23703 LIBS=$ac_check_lib_save_LIBS
23704 fi
23705 echo "$as_me:23705: result: $ac_cv_lib_gen_compile" >&5
23706 echo "${ECHO_T}$ac_cv_lib_gen_compile" >&6
23707 if test "$ac_cv_lib_gen_compile" = yes; then
23708
23709 cf_add_libs="$LIBS"
23710 # reverse order
23711 cf_add_0lib=
23712 for cf_add_1lib in -lgen; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
23713 # filter duplicates
23714 for cf_add_1lib in $cf_add_0lib; do
23715 for cf_add_2lib in $cf_add_libs; do
23716 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
23717 cf_add_1lib=
23718 break
23719 fi
23720 done
23721 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
23722 done
23723 LIBS="$cf_add_libs"
23724
23725 cf_regex_func=compile
23726 fi
23727
23728 fi
23729
23730 fi
23731
23732 if test "$cf_regex_func" = no ; then
23733 { echo "$as_me:23733: WARNING: cannot find regular expression library" >&5
23734 echo "$as_me: WARNING: cannot find regular expression library" >&2;}
23735 fi
23736
23737 echo "$as_me:23737: checking for regular-expression headers" >&5
23738 echo $ECHO_N "checking for regular-expression headers... $ECHO_C" >&6
23739 if test "${cf_cv_regex_hdrs+set}" = set; then
23740 echo $ECHO_N "(cached) $ECHO_C" >&6
23741 else
23742
23743 cf_cv_regex_hdrs=no
23744 case "$cf_regex_func" in
23745 (compile)
23746 for cf_regex_hdr in regexp.h regexpr.h
23747 do
23748 cat >"conftest.$ac_ext" <<_ACEOF
23749 #line 23749 "configure"
23750 #include "confdefs.h"
23751 #include <$cf_regex_hdr>
23752 int
23753 main (void)
23754 {
23755
23756 char *p = compile("", "", "", 0);
23757 int x = step("", "");
23758 (void)p;
23759 (void)x;
23760
23761 ;
23762 return 0;
23763 }
23764 _ACEOF
23765 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
23766 if { (eval echo "$as_me:23766: \"$ac_link\"") >&5
23767 (eval $ac_link) 2>&5
23768 ac_status=$?
23769 echo "$as_me:23769: \$? = $ac_status" >&5
23770 (exit "$ac_status"); } &&
23771 { ac_try='test -s "conftest$ac_exeext"'
23772 { (eval echo "$as_me:23772: \"$ac_try\"") >&5
23773 (eval $ac_try) 2>&5
23774 ac_status=$?
23775 echo "$as_me:23775: \$? = $ac_status" >&5
23776 (exit "$ac_status"); }; }; then
23777
23778 cf_cv_regex_hdrs=$cf_regex_hdr
23779 break
23780
23781 else
23782 echo "$as_me: failed program was:" >&5
23783 cat "conftest.$ac_ext" >&5
23784 fi
23785 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
23786 done
23787 ;;
23788 (*)
23789 for cf_regex_hdr in regex.h
23790 do
23791 cat >"conftest.$ac_ext" <<_ACEOF
23792 #line 23792 "configure"
23793 #include "confdefs.h"
23794 #include <sys/types.h>
23795 #include <stdio.h>
23796 #include <$cf_regex_hdr>
23797 int
23798 main (void)
23799 {
23800
23801 regex_t *p = NULL;
23802 int x = regcomp(p, "", 0);
23803 int y = regexec(p, "", 0, NULL, 0);
23804 (void)x;
23805 (void)y;
23806 regfree(p);
23807
23808 ;
23809 return 0;
23810 }
23811 _ACEOF
23812 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
23813 if { (eval echo "$as_me:23813: \"$ac_link\"") >&5
23814 (eval $ac_link) 2>&5
23815 ac_status=$?
23816 echo "$as_me:23816: \$? = $ac_status" >&5
23817 (exit "$ac_status"); } &&
23818 { ac_try='test -s "conftest$ac_exeext"'
23819 { (eval echo "$as_me:23819: \"$ac_try\"") >&5
23820 (eval $ac_try) 2>&5
23821 ac_status=$?
23822 echo "$as_me:23822: \$? = $ac_status" >&5
23823 (exit "$ac_status"); }; }; then
23824
23825 cf_cv_regex_hdrs=$cf_regex_hdr
23826 break
23827
23828 else
23829 echo "$as_me: failed program was:" >&5
23830 cat "conftest.$ac_ext" >&5
23831 fi
23832 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
23833 done
23834 ;;
23835 esac
23836
23837 fi
23838 echo "$as_me:23838: result: $cf_cv_regex_hdrs" >&5
23839 echo "${ECHO_T}$cf_cv_regex_hdrs" >&6
23840
23841 case "$cf_cv_regex_hdrs" in
23842 (no) { echo "$as_me:23842: WARNING: no regular expression header found" >&5
23843 echo "$as_me: WARNING: no regular expression header found" >&2;} ;;
23844 (regex.h)
23845 cat >>confdefs.h <<\EOF
23846 #define HAVE_REGEX_H_FUNCS 1
23847 EOF
23848 ;;
23849 (regexp.h)
23850 cat >>confdefs.h <<\EOF
23851 #define HAVE_REGEXP_H_FUNCS 1
23852 EOF
23853 ;;
23854 (regexpr.h)
23855 cat >>confdefs.h <<\EOF
23856 #define HAVE_REGEXPR_H_FUNCS 1
23857 EOF
23858 ;;
23859 esac
23860
23861 if test "X$cf_cv_regex_hdrs" != "Xregex.h" ; then
23862 { { echo "$as_me:23862: error: Only POSIX, PCRE, or PCRE2 regular expressions are supported" >&5
23863 echo "$as_me: error: Only POSIX, PCRE, or PCRE2 regular expressions are supported" >&2;}
23864 { (exit 1); exit 1; }; }
23865 fi
23866 fi
23867 fi
23868
23869 cat >>confdefs.h <<\EOF
23870 #define OPT_SELECT_REGEX 1
23871 EOF
23872
23873 fi
23874
23875 echo "$as_me:23875: checking if you want support for right-scrollbar" >&5
23876 echo $ECHO_N "checking if you want support for right-scrollbar... $ECHO_C" >&6
23877
23878 # Check whether --enable-rightbar or --disable-rightbar was given.
23879 if test "${enable_rightbar+set}" = set; then
23880 enableval="$enable_rightbar"
23881 test "$enableval" != no && enableval=yes
23882 if test "$enableval" != "yes" ; then
23883 enable_rightbar=no
23884 else
23885 enable_rightbar=yes
23886 fi
23887 else
23888 enableval=yes
23889 enable_rightbar=yes
23890
23891 fi;
23892 echo "$as_me:23892: result: $enable_rightbar" >&5
23893 echo "${ECHO_T}$enable_rightbar" >&6
23894 if test "$enable_rightbar" = yes ; then
23895
23896 cat >>confdefs.h <<\EOF
23897 #define SCROLLBAR_RIGHT 1
23898 EOF
23899
23900 fi
23901
23902 echo "$as_me:23902: checking if you want check for redundant name-change" >&5
23903 echo $ECHO_N "checking if you want check for redundant name-change... $ECHO_C" >&6
23904
23905 # Check whether --enable-samename or --disable-samename was given.
23906 if test "${enable_samename+set}" = set; then
23907 enableval="$enable_samename"
23908 test "$enableval" != no && enableval=yes
23909 if test "$enableval" != "yes" ; then
23910 enable_samename=no
23911 else
23912 enable_samename=yes
23913 fi
23914 else
23915 enableval=yes
23916 enable_samename=yes
23917
23918 fi;
23919 echo "$as_me:23919: result: $enable_samename" >&5
23920 echo "${ECHO_T}$enable_samename" >&6
23921 test "$enable_samename" = no &&
23922 cat >>confdefs.h <<\EOF
23923 #define OPT_SAME_NAME 0
23924 EOF
23925
23926 echo "$as_me:23926: checking if you want support for selection-actions" >&5
23927 echo $ECHO_N "checking if you want support for selection-actions... $ECHO_C" >&6
23928
23929 # Check whether --enable-selection-ops or --disable-selection-ops was given.
23930 if test "${enable_selection_ops+set}" = set; then
23931 enableval="$enable_selection_ops"
23932 test "$enableval" != no && enableval=yes
23933 if test "$enableval" != "yes" ; then
23934 enable_selection_ops=no
23935 else
23936 enable_selection_ops=yes
23937 fi
23938 else
23939 enableval=yes
23940 enable_selection_ops=yes
23941
23942 fi;
23943 echo "$as_me:23943: result: $enable_selection_ops" >&5
23944 echo "${ECHO_T}$enable_selection_ops" >&6
23945 test "$enable_selection_ops" = no &&
23946 cat >>confdefs.h <<\EOF
23947 #define OPT_SELECTION_OPS 0
23948 EOF
23949
23950 echo "$as_me:23950: checking if you want support for session management" >&5
23951 echo $ECHO_N "checking if you want support for session management... $ECHO_C" >&6
23952
23953 # Check whether --enable-session-mgt or --disable-session-mgt was given.
23954 if test "${enable_session_mgt+set}" = set; then
23955 enableval="$enable_session_mgt"
23956 test "$enableval" != no && enableval=yes
23957 if test "$enableval" != "yes" ; then
23958 enable_session_mgt=no
23959 else
23960 enable_session_mgt=yes
23961 fi
23962 else
23963 enableval=yes
23964 enable_session_mgt=yes
23965
23966 fi;
23967 echo "$as_me:23967: result: $enable_session_mgt" >&5
23968 echo "${ECHO_T}$enable_session_mgt" >&6
23969 test "$enable_session_mgt" = no &&
23970 cat >>confdefs.h <<\EOF
23971 #define OPT_SESSION_MGT 0
23972 EOF
23973
23974 echo "$as_me:23974: checking if you want support for status-line" >&5
23975 echo $ECHO_N "checking if you want support for status-line... $ECHO_C" >&6
23976
23977 # Check whether --enable-status-line or --disable-status-line was given.
23978 if test "${enable_status_line+set}" = set; then
23979 enableval="$enable_status_line"
23980 test "$enableval" != yes && enableval=no
23981 if test "$enableval" != "no" ; then
23982 enable_status_line=yes
23983 else
23984 enable_status_line=no
23985 fi
23986 else
23987 enableval=no
23988 enable_status_line=no
23989
23990 fi;
23991 echo "$as_me:23991: result: $enable_status_line" >&5
23992 echo "${ECHO_T}$enable_status_line" >&6
23993 test "$enable_status_line" = yes &&
23994 cat >>confdefs.h <<\EOF
23995 #define OPT_STATUS_LINE 1
23996 EOF
23997
23998 echo "$as_me:23998: checking if you want to use termcap function-keys" >&5
23999 echo $ECHO_N "checking if you want to use termcap function-keys... $ECHO_C" >&6
24000
24001 # Check whether --enable-tcap-fkeys or --disable-tcap-fkeys was given.
24002 if test "${enable_tcap_fkeys+set}" = set; then
24003 enableval="$enable_tcap_fkeys"
24004 test "$enableval" != no && enableval=yes
24005 if test "$enableval" != "yes" ; then
24006 enable_tcap_fkeys=no
24007 else
24008 enable_tcap_fkeys=yes
24009 fi
24010 else
24011 enableval=yes
24012 enable_tcap_fkeys=yes
24013
24014 fi;
24015 echo "$as_me:24015: result: $enable_tcap_fkeys" >&5
24016 echo "${ECHO_T}$enable_tcap_fkeys" >&6
24017 test "$enable_tcap_fkeys" = no &&
24018 cat >>confdefs.h <<\EOF
24019 #define OPT_TCAP_FKEYS 0
24020 EOF
24021
24022 echo "$as_me:24022: checking if you want to use termcap-query/report" >&5
24023 echo $ECHO_N "checking if you want to use termcap-query/report... $ECHO_C" >&6
24024
24025 # Check whether --enable-tcap-query or --disable-tcap-query was given.
24026 if test "${enable_tcap_query+set}" = set; then
24027 enableval="$enable_tcap_query"
24028 test "$enableval" != no && enableval=yes
24029 if test "$enableval" != "yes" ; then
24030 enable_tcap_query=no
24031 else
24032 enable_tcap_query=yes
24033 fi
24034 else
24035 enableval=yes
24036 enable_tcap_query=yes
24037
24038 fi;
24039 echo "$as_me:24039: result: $enable_tcap_query" >&5
24040 echo "${ECHO_T}$enable_tcap_query" >&6
24041 test "$enable_tcap_query" = no &&
24042 cat >>confdefs.h <<\EOF
24043 #define OPT_TCAP_QUERY 0
24044 EOF
24045
24046 echo "$as_me:24046: checking if you want support for tek4014" >&5
24047 echo $ECHO_N "checking if you want support for tek4014... $ECHO_C" >&6
24048
24049 # Check whether --enable-tek4014 or --disable-tek4014 was given.
24050 if test "${enable_tek4014+set}" = set; then
24051 enableval="$enable_tek4014"
24052 test "$enableval" != no && enableval=yes
24053 if test "$enableval" != "yes" ; then
24054 enable_tek4014=no
24055 else
24056 enable_tek4014=yes
24057 fi
24058 else
24059 enableval=yes
24060 enable_tek4014=yes
24061
24062 fi;
24063 echo "$as_me:24063: result: $enable_tek4014" >&5
24064 echo "${ECHO_T}$enable_tek4014" >&6
24065 if test "$enable_tek4014" = no ; then
24066
24067 cat >>confdefs.h <<\EOF
24068 #define OPT_TEK4014 0
24069 EOF
24070
24071 else
24072 EXTRAHDRS="$EXTRAHDRS Tekparse.h"
24073 EXTRASRCS="$EXTRASRCS TekPrsTbl.c Tekproc.c"
24074 EXTRAOBJS="$EXTRAOBJS TekPrsTbl.o Tekproc.o"
24075 fi
24076
24077 echo "$as_me:24077: checking if you want pulldown menus with a toolbar" >&5
24078 echo $ECHO_N "checking if you want pulldown menus with a toolbar... $ECHO_C" >&6
24079
24080 # Check whether --enable-toolbar or --disable-toolbar was given.
24081 if test "${enable_toolbar+set}" = set; then
24082 enableval="$enable_toolbar"
24083 test "$enableval" != yes && enableval=no
24084 if test "$enableval" != "no" ; then
24085 enable_toolbar=yes
24086 else
24087 enable_toolbar=no
24088 fi
24089 else
24090 enableval=no
24091 enable_toolbar=no
24092
24093 fi;
24094 echo "$as_me:24094: result: $enable_toolbar" >&5
24095 echo "${ECHO_T}$enable_toolbar" >&6
24096 if test "$enable_toolbar" = yes ; then
24097
24098 cat >>confdefs.h <<\EOF
24099 #define OPT_TOOLBAR 1
24100 EOF
24101
24102 fi
24103
24104 echo "$as_me:24104: checking if you want VT52 emulation" >&5
24105 echo $ECHO_N "checking if you want VT52 emulation... $ECHO_C" >&6
24106
24107 # Check whether --enable-vt52 or --disable-vt52 was given.
24108 if test "${enable_vt52+set}" = set; then
24109 enableval="$enable_vt52"
24110 test "$enableval" != no && enableval=yes
24111 if test "$enableval" != "yes" ; then
24112 enable_vt52=no
24113 else
24114 enable_vt52=yes
24115 fi
24116 else
24117 enableval=yes
24118 enable_vt52=yes
24119
24120 fi;
24121 echo "$as_me:24121: result: $enable_vt52" >&5
24122 echo "${ECHO_T}$enable_vt52" >&6
24123 test "$enable_vt52" = no &&
24124 cat >>confdefs.h <<\EOF
24125 #define OPT_VT52_MODE 0
24126 EOF
24127
24128 echo "$as_me:24128: checking if you want wide-attribute support" >&5
24129 echo $ECHO_N "checking if you want wide-attribute support... $ECHO_C" >&6
24130
24131 # Check whether --enable-wide-attrs or --disable-wide-attrs was given.
24132 if test "${enable_wide_attrs+set}" = set; then
24133 enableval="$enable_wide_attrs"
24134 test "$enableval" != no && enableval=yes
24135 if test "$enableval" != "yes" ; then
24136 enable_wattr=no
24137 else
24138 enable_wattr=yes
24139 fi
24140 else
24141 enableval=yes
24142 enable_wattr=yes
24143
24144 fi;
24145 echo "$as_me:24145: result: $enable_wattr" >&5
24146 echo "${ECHO_T}$enable_wattr" >&6
24147
24148 if test x$enable_wattr = xno && test x$enable_direct_color = xyes ; then
24149 { echo "$as_me:24149: WARNING: overriding wide-attributes to support direct color" >&5
24150 echo "$as_me: WARNING: overriding wide-attributes to support direct color" >&2;}
24151 enable_wattr=yes
24152 fi
24153
24154 echo "$as_me:24154: checking if you want wide-character support" >&5
24155 echo $ECHO_N "checking if you want wide-character support... $ECHO_C" >&6
24156
24157 # Check whether --enable-wide-chars or --disable-wide-chars was given.
24158 if test "${enable_wide_chars+set}" = set; then
24159 enableval="$enable_wide_chars"
24160 test "$enableval" != no && enableval=yes
24161 if test "$enableval" != "yes" ; then
24162 enable_wchar=no
24163 else
24164 enable_wchar=yes
24165 fi
24166 else
24167 enableval=yes
24168 enable_wchar=yes
24169
24170 fi;
24171 echo "$as_me:24171: result: $enable_wchar" >&5
24172 echo "${ECHO_T}$enable_wchar" >&6
24173 test "x$enable_wattr" = xno &&
24174 cat >>confdefs.h <<\EOF
24175 #define OPT_WIDE_ATTRS 0
24176 EOF
24177
24178 echo "$as_me:24178: checking if you want only 16-bit character support" >&5
24179 echo $ECHO_N "checking if you want only 16-bit character support... $ECHO_C" >&6
24180
24181 # Check whether --enable-16bit-chars or --disable-16bit-chars was given.
24182 if test "${enable_16bit_chars+set}" = set; then
24183 enableval="$enable_16bit_chars"
24184 test "$enableval" != yes && enableval=no
24185 if test "$enableval" != "no" ; then
24186 enable_16bit_chars=yes
24187 else
24188 enable_16bit_chars=no
24189 fi
24190 else
24191 enableval=no
24192 enable_16bit_chars=no
24193
24194 fi;
24195 echo "$as_me:24195: result: $enable_16bit_chars" >&5
24196 echo "${ECHO_T}$enable_16bit_chars" >&6
24197
24198 if test "$enable_16bit_chars" = yes ; then
24199
24200 cat >>confdefs.h <<\EOF
24201 #define OPT_WIDER_ICHAR 0
24202 EOF
24203
24204 enable_wchar=yes
24205 fi
24206
24207 if test "$enable_wchar" = yes ; then
24208
24209 echo "$as_me:24209: checking if you want to use mini-luit/Latin9 built-in support" >&5
24210 echo $ECHO_N "checking if you want to use mini-luit/Latin9 built-in support... $ECHO_C" >&6
24211
24212 # Check whether --enable-mini-luit or --disable-mini-luit was given.
24213 if test "${enable_mini_luit+set}" = set; then
24214 enableval="$enable_mini_luit"
24215 test "$enableval" != yes && enableval=no
24216 if test "$enableval" != "no" ; then
24217 enable_mini_luit=yes
24218 else
24219 enable_mini_luit=no
24220 fi
24221 else
24222 enableval=no
24223 enable_mini_luit=no
24224
24225 fi;
24226 echo "$as_me:24226: result: $enable_mini_luit" >&5
24227 echo "${ECHO_T}$enable_mini_luit" >&6
24228 if test "$enable_mini_luit" = yes ; then
24229
24230 cat >>confdefs.h <<\EOF
24231 #define OPT_MINI_LUIT 1
24232 EOF
24233
24234 fi
24235
24236 echo "$as_me:24236: checking if you want to use luit" >&5
24237 echo $ECHO_N "checking if you want to use luit... $ECHO_C" >&6
24238
24239 # Check whether --enable-luit or --disable-luit was given.
24240 if test "${enable_luit+set}" = set; then
24241 enableval="$enable_luit"
24242 test "$enableval" != no && enableval=yes
24243 if test "$enableval" != "yes" ; then
24244 enable_luit=no
24245 else
24246 enable_luit=yes
24247 fi
24248 else
24249 enableval=yes
24250 enable_luit=yes
24251
24252 fi;
24253 echo "$as_me:24253: result: $enable_luit" >&5
24254 echo "${ECHO_T}$enable_luit" >&6
24255 if test "$enable_luit" = yes ; then
24256
24257 cat >>confdefs.h <<\EOF
24258 #define OPT_LUIT_PROG 1
24259 EOF
24260
24261 test -z "$LUIT" && LUIT="xterm-filter"
24262 for ac_prog in $LUIT xterm-filter bluit luit
24263 do
24264 # Extract the first word of "$ac_prog", so it can be a program name with args.
24265 set dummy $ac_prog; ac_word=$2
24266 echo "$as_me:24266: checking for $ac_word" >&5
24267 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
24268 if test "${ac_cv_path_LUIT+set}" = set; then
24269 echo $ECHO_N "(cached) $ECHO_C" >&6
24270 else
24271 case $LUIT in
24272 [\\/]* | ?:[\\/]*)
24273 ac_cv_path_LUIT="$LUIT" # Let the user override the test with a path.
24274 ;;
24275 *)
24276 ac_save_IFS=$IFS; IFS=$ac_path_separator
24277 ac_dummy="$PATH"
24278 for ac_dir in $ac_dummy; do
24279 IFS=$ac_save_IFS
24280 test -z "$ac_dir" && ac_dir=.
24281 if $as_executable_p "$ac_dir/$ac_word"; then
24282 ac_cv_path_LUIT="$ac_dir/$ac_word"
24283 echo "$as_me:24283: found $ac_dir/$ac_word" >&5
24284 break
24285 fi
24286 done
24287
24288 ;;
24289 esac
24290 fi
24291 LUIT=$ac_cv_path_LUIT
24292
24293 if test -n "$LUIT"; then
24294 echo "$as_me:24294: result: $LUIT" >&5
24295 echo "${ECHO_T}$LUIT" >&6
24296 else
24297 echo "$as_me:24297: result: no" >&5
24298 echo "${ECHO_T}no" >&6
24299 fi
24300
24301 test -n "$LUIT" && break
24302 done
24303 test -n "$LUIT" || LUIT="$LUIT"
24304
24305 cf_path_prog=""
24306 cf_path_args=""
24307 IFS="${IFS:- }"; cf_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR"
24308 for cf_temp in $ac_cv_path_LUIT
24309 do
24310 if test -z "$cf_path_prog" ; then
24311 if test "$with_full_paths" = yes ; then
24312
24313 if test "x$prefix" != xNONE; then
24314 cf_path_syntax="$prefix"
24315 else
24316 cf_path_syntax="$ac_default_prefix"
24317 fi
24318
24319 case "x$cf_temp" in
24320 (x\$\(*\)*|x\'*\'*)
24321 ;;
24322 (x.|x$GLOB_FULLPATH_POSIX|x$GLOB_FULLPATH_OTHER)
24323 ;;
24324 (x\$\{*prefix\}*|x\$\{*dir\}*)
24325 eval cf_temp="$cf_temp"
24326 case "x$cf_temp" in
24327 (xNONE/*)
24328 cf_temp=`echo "$cf_temp" | sed -e s%NONE%$cf_path_syntax%`
24329 ;;
24330 esac
24331 ;;
24332 (xno|xNONE/*)
24333 cf_temp=`echo "$cf_temp" | sed -e s%NONE%$cf_path_syntax%`
24334 ;;
24335 (*)
24336 break
24337 ;;
24338 esac
24339
24340 cf_path_prog="$cf_temp"
24341 else
24342 cf_path_prog="`basename "$cf_temp"`"
24343 fi
24344 elif test -z "$cf_path_args" ; then
24345 cf_path_args="$cf_temp"
24346 else
24347 cf_path_args="$cf_path_args $cf_temp"
24348 fi
24349 done
24350 IFS="$cf_save_ifs"
24351
24352 if test -n "$cf_path_prog" ; then
24353
24354 echo "${as_me:-configure}:24354: testing defining path for ${cf_path_prog} ..." 1>&5
24355
24356 cat >>confdefs.h <<EOF
24357 #define LUIT_PATH "$cf_path_prog"
24358 EOF
24359
24360 test -n "$cf_path_args" &&
24361 cat >>confdefs.h <<EOF
24362 #define LUIT_ARGS "$cf_path_args"
24363 EOF
24364
24365 fi
24366
24367 fi
24368
24369 cat >>confdefs.h <<\EOF
24370 #define OPT_WIDE_CHARS 1
24371 EOF
24372
24373 EXTRAHDRS="$EXTRAHDRS charclass.h precompose.h wcwidth.h"
24374 EXTRASRCS="$EXTRASRCS charclass.c precompose.c wcwidth.c"
24375 EXTRAOBJS="$EXTRAOBJS charclass.o precompose.o wcwidth.o"
24376 fi
24377
24378 echo "$as_me:24378: checking if you want dynamic-abbreviation support" >&5
24379 echo $ECHO_N "checking if you want dynamic-abbreviation support... $ECHO_C" >&6
24380
24381 # Check whether --enable-dabbrev or --disable-dabbrev was given.
24382 if test "${enable_dabbrev+set}" = set; then
24383 enableval="$enable_dabbrev"
24384 test "$enableval" != yes && enableval=no
24385 if test "$enableval" != "no" ; then
24386 enable_dabbrev=yes
24387 else
24388 enable_dabbrev=no
24389 fi
24390 else
24391 enableval=no
24392 enable_dabbrev=no
24393
24394 fi;
24395 echo "$as_me:24395: result: $enable_dabbrev" >&5
24396 echo "${ECHO_T}$enable_dabbrev" >&6
24397 if test "$enable_dabbrev" = yes ; then
24398
24399 cat >>confdefs.h <<\EOF
24400 #define OPT_DABBREV 1
24401 EOF
24402
24403 fi
24404
24405 echo "$as_me:24405: checking if you want DECterm Locator support" >&5
24406 echo $ECHO_N "checking if you want DECterm Locator support... $ECHO_C" >&6
24407
24408 # Check whether --enable-dec-locator or --disable-dec-locator was given.
24409 if test "${enable_dec_locator+set}" = set; then
24410 enableval="$enable_dec_locator"
24411 test "$enableval" != yes && enableval=no
24412 if test "$enableval" != "no" ; then
24413 enable_dec_locator=yes
24414 else
24415 enable_dec_locator=no
24416 fi
24417 else
24418 enableval=no
24419 enable_dec_locator=no
24420
24421 fi;
24422 echo "$as_me:24422: result: $enable_dec_locator" >&5
24423 echo "${ECHO_T}$enable_dec_locator" >&6
24424 if test "$enable_dec_locator" = yes ; then
24425
24426 cat >>confdefs.h <<\EOF
24427 #define OPT_DEC_LOCATOR 1
24428 EOF
24429
24430 fi
24431
24432 echo "$as_me:24432: checking if you want XHTML and SVG screen dump support" >&5
24433 echo $ECHO_N "checking if you want XHTML and SVG screen dump support... $ECHO_C" >&6
24434
24435 # Check whether --enable-screen-dumps or --disable-screen-dumps was given.
24436 if test "${enable_screen_dumps+set}" = set; then
24437 enableval="$enable_screen_dumps"
24438 test "$enableval" != no && enableval=yes
24439 if test "$enableval" != "yes" ; then
24440 enable_screen_dumps=no
24441 else
24442 enable_screen_dumps=yes
24443 fi
24444 else
24445 enableval=yes
24446 enable_screen_dumps=yes
24447
24448 fi;
24449 echo "$as_me:24449: result: $enable_screen_dumps" >&5
24450 echo "${ECHO_T}$enable_screen_dumps" >&6
24451 if test "$enable_screen_dumps" = yes ; then
24452 EXTRASRCS="$EXTRASRCS html.c svg.c"
24453 EXTRAOBJS="$EXTRAOBJS html.o svg.o"
24454 else
24455
24456 cat >>confdefs.h <<\EOF
24457 #define OPT_SCREEN_DUMPS 0
24458 EOF
24459
24460 fi
24461
24462 echo "$as_me:24462: checking if you want ReGIS graphics support" >&5
24463 echo $ECHO_N "checking if you want ReGIS graphics support... $ECHO_C" >&6
24464
24465 # Check whether --enable-regis-graphics or --disable-regis-graphics was given.
24466 if test "${enable_regis_graphics+set}" = set; then
24467 enableval="$enable_regis_graphics"
24468 test "$enableval" != yes && enableval=no
24469 if test "$enableval" != "no" ; then
24470 enable_regis_graphics=yes
24471 else
24472 enable_regis_graphics=no
24473 fi
24474 else
24475 enableval=no
24476 enable_regis_graphics=no
24477
24478 fi;
24479 echo "$as_me:24479: result: $enable_regis_graphics" >&5
24480 echo "${ECHO_T}$enable_regis_graphics" >&6
24481 if test "$enable_regis_graphics" = yes ; then
24482
24483 cat >>confdefs.h <<\EOF
24484 #define OPT_REGIS_GRAPHICS 1
24485 EOF
24486
24487 EXTRAHDRS="$EXTRAHDRS graphics_regis.h"
24488 EXTRASRCS="$EXTRASRCS graphics_regis.c"
24489 EXTRAOBJS="$EXTRAOBJS graphics_regis.o"
24490
24491 echo "$as_me:24491: checking if -lm needed for math functions" >&5
24492 echo $ECHO_N "checking if -lm needed for math functions... $ECHO_C" >&6
24493 if test "${cf_cv_need_libm+set}" = set; then
24494 echo $ECHO_N "(cached) $ECHO_C" >&6
24495 else
24496
24497 cat >"conftest.$ac_ext" <<_ACEOF
24498 #line 24498 "configure"
24499 #include "confdefs.h"
24500
24501 #include <stdio.h>
24502 #include <stdlib.h>
24503 #include <math.h>
24504
24505 int
24506 main (void)
24507 {
24508 double x = rand(); printf("result = %g\\n", sin(x))
24509 ;
24510 return 0;
24511 }
24512 _ACEOF
24513 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
24514 if { (eval echo "$as_me:24514: \"$ac_link\"") >&5
24515 (eval $ac_link) 2>&5
24516 ac_status=$?
24517 echo "$as_me:24517: \$? = $ac_status" >&5
24518 (exit "$ac_status"); } &&
24519 { ac_try='test -s "conftest$ac_exeext"'
24520 { (eval echo "$as_me:24520: \"$ac_try\"") >&5
24521 (eval $ac_try) 2>&5
24522 ac_status=$?
24523 echo "$as_me:24523: \$? = $ac_status" >&5
24524 (exit "$ac_status"); }; }; then
24525 cf_cv_need_libm=no
24526 else
24527 echo "$as_me: failed program was:" >&5
24528 cat "conftest.$ac_ext" >&5
24529 cf_cv_need_libm=yes
24530 fi
24531 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
24532 fi
24533 echo "$as_me:24533: result: $cf_cv_need_libm" >&5
24534 echo "${ECHO_T}$cf_cv_need_libm" >&6
24535
24536 if test "$cf_cv_need_libm" = yes
24537 then
24538
24539 cf_save_LIBS="$LIBS"
24540 LIBS="$LIBS -lm"
24541 echo "$as_me:24541: checking if -lm is available for math functions" >&5
24542 echo $ECHO_N "checking if -lm is available for math functions... $ECHO_C" >&6
24543 if test "${cf_cv_have_libm+set}" = set; then
24544 echo $ECHO_N "(cached) $ECHO_C" >&6
24545 else
24546
24547 cat >"conftest.$ac_ext" <<_ACEOF
24548 #line 24548 "configure"
24549 #include "confdefs.h"
24550
24551 #include <stdio.h>
24552 #include <stdlib.h>
24553 #include <math.h>
24554
24555 int
24556 main (void)
24557 {
24558 double x = rand(); printf("result = %g\\n", sin(x))
24559 ;
24560 return 0;
24561 }
24562 _ACEOF
24563 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
24564 if { (eval echo "$as_me:24564: \"$ac_link\"") >&5
24565 (eval $ac_link) 2>&5
24566 ac_status=$?
24567 echo "$as_me:24567: \$? = $ac_status" >&5
24568 (exit "$ac_status"); } &&
24569 { ac_try='test -s "conftest$ac_exeext"'
24570 { (eval echo "$as_me:24570: \"$ac_try\"") >&5
24571 (eval $ac_try) 2>&5
24572 ac_status=$?
24573 echo "$as_me:24573: \$? = $ac_status" >&5
24574 (exit "$ac_status"); }; }; then
24575 cf_cv_have_libm=yes
24576 else
24577 echo "$as_me: failed program was:" >&5
24578 cat "conftest.$ac_ext" >&5
24579 cf_cv_have_libm=no
24580 fi
24581 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
24582 fi
24583 echo "$as_me:24583: result: $cf_cv_have_libm" >&5
24584 echo "${ECHO_T}$cf_cv_have_libm" >&6
24585 LIBS="$cf_save_LIBS"
24586
24587 if test "$cf_cv_have_libm" = yes
24588 then
24589
24590 cf_add_libs="$LIBS"
24591 # reverse order
24592 cf_add_0lib=
24593 for cf_add_1lib in -lm; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
24594 # filter duplicates
24595 for cf_add_1lib in $cf_add_0lib; do
24596 for cf_add_2lib in $cf_add_libs; do
24597 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
24598 cf_add_1lib=
24599 break
24600 fi
24601 done
24602 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
24603 done
24604 LIBS="$cf_add_libs"
24605
24606 fi
24607 else
24608 cf_cv_have_libm=yes
24609 fi
24610
24611 if test "$cf_cv_have_libm" = yes
24612 then
24613
24614 cat >>confdefs.h <<\EOF
24615 #define HAVE_MATH_FUNCS 1
24616 EOF
24617
24618 fi
24619
24620 fi
24621
24622 echo "$as_me:24622: checking if you want sixel graphics support" >&5
24623 echo $ECHO_N "checking if you want sixel graphics support... $ECHO_C" >&6
24624
24625 # Check whether --enable-sixel-graphics or --disable-sixel-graphics was given.
24626 if test "${enable_sixel_graphics+set}" = set; then
24627 enableval="$enable_sixel_graphics"
24628 test "$enableval" != no && enableval=yes
24629 if test "$enableval" != "yes" ; then
24630 enable_sixel_graphics=no
24631 else
24632 enable_sixel_graphics=yes
24633 fi
24634 else
24635 enableval=yes
24636 enable_sixel_graphics=yes
24637
24638 fi;
24639 echo "$as_me:24639: result: $enable_sixel_graphics" >&5
24640 echo "${ECHO_T}$enable_sixel_graphics" >&6
24641 if test "$enable_sixel_graphics" = yes ; then
24642
24643 cat >>confdefs.h <<\EOF
24644 #define OPT_SIXEL_GRAPHICS 1
24645 EOF
24646
24647 EXTRAHDRS="$EXTRAHDRS graphics_sixel.h"
24648 EXTRASRCS="$EXTRASRCS graphics_sixel.c"
24649 EXTRAOBJS="$EXTRAOBJS graphics_sixel.o"
24650 fi
24651
24652 if test "$enable_regis_graphics" = yes || test "$enable_sixel_graphics" = yes ; then
24653
24654 cat >>confdefs.h <<\EOF
24655 #define OPT_GRAPHICS 1
24656 EOF
24657
24658 EXTRAHDRS="$EXTRAHDRS graphics.h"
24659 EXTRASRCS="$EXTRASRCS graphics.c"
24660 EXTRAOBJS="$EXTRAOBJS graphics.o"
24661 STRINGS_MAX=600000
24662 else
24663 STRINGS_MAX=20000
24664 fi
24665
24666 echo "$as_me:24666: checking if you want sixel screen dump support" >&5
24667 echo $ECHO_N "checking if you want sixel screen dump support... $ECHO_C" >&6
24668
24669 # Check whether --enable-print-graphics or --disable-print-graphics was given.
24670 if test "${enable_print_graphics+set}" = set; then
24671 enableval="$enable_print_graphics"
24672 test "$enableval" != no && enableval=yes
24673 if test "$enableval" != "yes" ; then
24674 enable_print_graphics=no
24675 else
24676 enable_print_graphics=$enable_regis_graphics
24677 fi
24678 else
24679 enableval=yes
24680 enable_print_graphics=$enable_regis_graphics
24681
24682 fi;
24683 echo "$as_me:24683: result: $enable_print_graphics" >&5
24684 echo "${ECHO_T}$enable_print_graphics" >&6
24685 if test "$enable_print_graphics" = yes ; then
24686
24687 cat >>confdefs.h <<\EOF
24688 #define OPT_PRINT_GRAPHICS 1
24689 EOF
24690
24691 fi
24692
24693 echo "$as_me:24693: checking if you want VT420 rectangle support" >&5
24694 echo $ECHO_N "checking if you want VT420 rectangle support... $ECHO_C" >&6
24695
24696 # Check whether --enable-rectangles or --disable-rectangles was given.
24697 if test "${enable_rectangles+set}" = set; then
24698 enableval="$enable_rectangles"
24699 test "$enableval" != no && enableval=yes
24700 if test "$enableval" != "yes" ; then
24701 enable_rectangles=no
24702 else
24703 enable_rectangles=yes
24704 fi
24705 else
24706 enableval=yes
24707 enable_rectangles=yes
24708
24709 fi;
24710 echo "$as_me:24710: result: $enable_rectangles" >&5
24711 echo "${ECHO_T}$enable_rectangles" >&6
24712 if test "$enable_rectangles" = no ; then
24713
24714 cat >>confdefs.h <<\EOF
24715 #define OPT_DEC_RECTOPS 0
24716 EOF
24717
24718 fi
24719
24720 echo "$as_me:24720: checking if you want resize/cursor-adjust feature" >&5
24721 echo $ECHO_N "checking if you want resize/cursor-adjust feature... $ECHO_C" >&6
24722
24723 # Check whether --enable-resize-adjust or --disable-resize-adjust was given.
24724 if test "${enable_resize_adjust+set}" = set; then
24725 enableval="$enable_resize_adjust"
24726 test "$enableval" != no && enableval=yes
24727 if test "$enableval" != "yes" ; then
24728 enable_resize_adjust=no
24729 else
24730 enable_resize_adjust=yes
24731 fi
24732 else
24733 enableval=yes
24734 enable_resize_adjust=yes
24735
24736 fi;
24737 echo "$as_me:24737: result: $enable_resize_adjust" >&5
24738 echo "${ECHO_T}$enable_resize_adjust" >&6
24739 if test "$enable_resize_adjust" = yes ; then
24740
24741 cat >>confdefs.h <<\EOF
24742 #define OPT_RESIZE_ADJUST 1
24743 EOF
24744
24745 fi
24746
24747 echo "$as_me:24747: checking if you want -ziconbeep option" >&5
24748 echo $ECHO_N "checking if you want -ziconbeep option... $ECHO_C" >&6
24749
24750 # Check whether --enable-ziconbeep or --disable-ziconbeep was given.
24751 if test "${enable_ziconbeep+set}" = set; then
24752 enableval="$enable_ziconbeep"
24753 test "$enableval" != no && enableval=yes
24754 if test "$enableval" != "yes" ; then
24755 enable_ziconbeep=no
24756 else
24757 enable_ziconbeep=yes
24758 fi
24759 else
24760 enableval=yes
24761 enable_ziconbeep=yes
24762
24763 fi;
24764 echo "$as_me:24764: result: $enable_ziconbeep" >&5
24765 echo "${ECHO_T}$enable_ziconbeep" >&6
24766 test "$enable_ziconbeep" = no &&
24767 cat >>confdefs.h <<\EOF
24768 #define OPT_ZICONBEEP 0
24769 EOF
24770
24771 ###############################################################################
24772
24773 echo "$as_me:24773: checking if you want debugging traces" >&5
24774 echo $ECHO_N "checking if you want debugging traces... $ECHO_C" >&6
24775
24776 # Check whether --enable-trace or --disable-trace was given.
24777 if test "${enable_trace+set}" = set; then
24778 enableval="$enable_trace"
24779 test "$enableval" != yes && enableval=no
24780 if test "$enableval" != "no" ; then
24781 enable_trace=yes
24782 else
24783 enable_trace=no
24784 fi
24785 else
24786 enableval=no
24787 enable_trace=no
24788
24789 fi;
24790 echo "$as_me:24790: result: $enable_trace" >&5
24791 echo "${ECHO_T}$enable_trace" >&6
24792 if test "$enable_trace" = yes ; then
24793
24794 cat >>confdefs.h <<\EOF
24795 #define OPT_TRACE 1
24796 EOF
24797
24798 EXTRASRCS="$EXTRASRCS trace.c"
24799 EXTRAOBJS="$EXTRAOBJS trace.o"
24800 fi
24801
24802 echo "$as_me:24802: checking if you want to use dmalloc for testing" >&5
24803 echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6
24804
24805 # Check whether --with-dmalloc or --without-dmalloc was given.
24806 if test "${with_dmalloc+set}" = set; then
24807 withval="$with_dmalloc"
24808 case "x$withval" in
24809 (x|xno) ;;
24810 (*)
24811 : "${with_cflags:=-g}"
24812 : "${enable_leaks:=no}"
24813 with_dmalloc=yes
24814
24815 cat >>confdefs.h <<EOF
24816 #define USE_DMALLOC 1
24817 EOF
24818
24819 ;;
24820 esac
24821 else
24822 with_dmalloc=
24823 fi;
24824 echo "$as_me:24824: result: ${with_dmalloc:-no}" >&5
24825 echo "${ECHO_T}${with_dmalloc:-no}" >&6
24826
24827 case ".$with_cflags" in
24828 (.*-g*)
24829 case .$CFLAGS in
24830 (.*-g*)
24831 ;;
24832 (*)
24833
24834 cf_fix_cppflags=no
24835 cf_new_cflags=
24836 cf_new_cppflags=
24837 cf_new_extra_cppflags=
24838
24839 for cf_add_cflags in -g
24840 do
24841 case "$cf_fix_cppflags" in
24842 (no)
24843 case "$cf_add_cflags" in
24844 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
24845 case "$cf_add_cflags" in
24846 (-D*)
24847 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
24848
24849 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
24850 && test -z "${cf_tst_cflags}" \
24851 && cf_fix_cppflags=yes
24852
24853 if test "$cf_fix_cppflags" = yes ; then
24854
24855 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
24856 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
24857
24858 continue
24859 elif test "${cf_tst_cflags}" = "\"'" ; then
24860
24861 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
24862 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
24863
24864 continue
24865 fi
24866 ;;
24867 esac
24868 case "$CPPFLAGS" in
24869 (*$cf_add_cflags)
24870 ;;
24871 (*)
24872 case "$cf_add_cflags" in
24873 (-D*)
24874 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
24875
24876 CPPFLAGS=`echo "$CPPFLAGS" | \
24877 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
24878 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
24879
24880 ;;
24881 esac
24882
24883 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
24884 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
24885
24886 ;;
24887 esac
24888 ;;
24889 (*)
24890
24891 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
24892 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
24893
24894 ;;
24895 esac
24896 ;;
24897 (yes)
24898
24899 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
24900 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
24901
24902 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
24903
24904 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
24905 && test -z "${cf_tst_cflags}" \
24906 && cf_fix_cppflags=no
24907 ;;
24908 esac
24909 done
24910
24911 if test -n "$cf_new_cflags" ; then
24912
24913 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
24914 CFLAGS="${CFLAGS}$cf_new_cflags"
24915
24916 fi
24917
24918 if test -n "$cf_new_cppflags" ; then
24919
24920 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
24921 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
24922
24923 fi
24924
24925 if test -n "$cf_new_extra_cppflags" ; then
24926
24927 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
24928 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
24929
24930 fi
24931
24932 ;;
24933 esac
24934 ;;
24935 esac
24936
24937 if test "$with_dmalloc" = yes ; then
24938 echo "$as_me:24938: checking for dmalloc.h" >&5
24939 echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6
24940 if test "${ac_cv_header_dmalloc_h+set}" = set; then
24941 echo $ECHO_N "(cached) $ECHO_C" >&6
24942 else
24943 cat >"conftest.$ac_ext" <<_ACEOF
24944 #line 24944 "configure"
24945 #include "confdefs.h"
24946 #include <dmalloc.h>
24947 _ACEOF
24948 if { (eval echo "$as_me:24948: \"$ac_cpp "conftest.$ac_ext"\"") >&5
24949 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
24950 ac_status=$?
24951 $EGREP -v '^ *\+' conftest.er1 >conftest.err
24952 rm -f conftest.er1
24953 cat conftest.err >&5
24954 echo "$as_me:24954: \$? = $ac_status" >&5
24955 (exit "$ac_status"); } >/dev/null; then
24956 if test -s conftest.err; then
24957 ac_cpp_err=$ac_c_preproc_warn_flag
24958 else
24959 ac_cpp_err=
24960 fi
24961 else
24962 ac_cpp_err=yes
24963 fi
24964 if test -z "$ac_cpp_err"; then
24965 ac_cv_header_dmalloc_h=yes
24966 else
24967 echo "$as_me: failed program was:" >&5
24968 cat "conftest.$ac_ext" >&5
24969 ac_cv_header_dmalloc_h=no
24970 fi
24971 rm -f conftest.err "conftest.$ac_ext"
24972 fi
24973 echo "$as_me:24973: result: $ac_cv_header_dmalloc_h" >&5
24974 echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6
24975 if test "$ac_cv_header_dmalloc_h" = yes; then
24976
24977 echo "$as_me:24977: checking for dmalloc_debug in -ldmalloc" >&5
24978 echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6
24979 if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then
24980 echo $ECHO_N "(cached) $ECHO_C" >&6
24981 else
24982 ac_check_lib_save_LIBS=$LIBS
24983 LIBS="-ldmalloc $LIBS"
24984 cat >"conftest.$ac_ext" <<_ACEOF
24985 #line 24985 "configure"
24986 #include "confdefs.h"
24987
24988 /* Override any gcc2 internal prototype to avoid an error. */
24989 #ifdef __cplusplus
24990 extern "C"
24991 #endif
24992 /* We use char because int might match the return type of a gcc2
24993 builtin and then its argument prototype would still apply. */
24994 char dmalloc_debug (void);
24995 int
24996 main (void)
24997 {
24998 dmalloc_debug ();
24999 ;
25000 return 0;
25001 }
25002 _ACEOF
25003 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
25004 if { (eval echo "$as_me:25004: \"$ac_link\"") >&5
25005 (eval $ac_link) 2>&5
25006 ac_status=$?
25007 echo "$as_me:25007: \$? = $ac_status" >&5
25008 (exit "$ac_status"); } &&
25009 { ac_try='test -s "conftest$ac_exeext"'
25010 { (eval echo "$as_me:25010: \"$ac_try\"") >&5
25011 (eval $ac_try) 2>&5
25012 ac_status=$?
25013 echo "$as_me:25013: \$? = $ac_status" >&5
25014 (exit "$ac_status"); }; }; then
25015 ac_cv_lib_dmalloc_dmalloc_debug=yes
25016 else
25017 echo "$as_me: failed program was:" >&5
25018 cat "conftest.$ac_ext" >&5
25019 ac_cv_lib_dmalloc_dmalloc_debug=no
25020 fi
25021 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
25022 LIBS=$ac_check_lib_save_LIBS
25023 fi
25024 echo "$as_me:25024: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
25025 echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6
25026 if test "$ac_cv_lib_dmalloc_dmalloc_debug" = yes; then
25027 cat >>confdefs.h <<EOF
25028 #define HAVE_LIBDMALLOC 1
25029 EOF
25030
25031 LIBS="-ldmalloc $LIBS"
25032
25033 fi
25034
25035 fi
25036
25037 fi
25038
25039 echo "$as_me:25039: checking if you want to use dbmalloc for testing" >&5
25040 echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6
25041
25042 # Check whether --with-dbmalloc or --without-dbmalloc was given.
25043 if test "${with_dbmalloc+set}" = set; then
25044 withval="$with_dbmalloc"
25045 case "x$withval" in
25046 (x|xno) ;;
25047 (*)
25048 : "${with_cflags:=-g}"
25049 : "${enable_leaks:=no}"
25050 with_dbmalloc=yes
25051
25052 cat >>confdefs.h <<EOF
25053 #define USE_DBMALLOC 1
25054 EOF
25055
25056 ;;
25057 esac
25058 else
25059 with_dbmalloc=
25060 fi;
25061 echo "$as_me:25061: result: ${with_dbmalloc:-no}" >&5
25062 echo "${ECHO_T}${with_dbmalloc:-no}" >&6
25063
25064 case ".$with_cflags" in
25065 (.*-g*)
25066 case .$CFLAGS in
25067 (.*-g*)
25068 ;;
25069 (*)
25070
25071 cf_fix_cppflags=no
25072 cf_new_cflags=
25073 cf_new_cppflags=
25074 cf_new_extra_cppflags=
25075
25076 for cf_add_cflags in -g
25077 do
25078 case "$cf_fix_cppflags" in
25079 (no)
25080 case "$cf_add_cflags" in
25081 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
25082 case "$cf_add_cflags" in
25083 (-D*)
25084 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
25085
25086 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
25087 && test -z "${cf_tst_cflags}" \
25088 && cf_fix_cppflags=yes
25089
25090 if test "$cf_fix_cppflags" = yes ; then
25091
25092 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
25093 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
25094
25095 continue
25096 elif test "${cf_tst_cflags}" = "\"'" ; then
25097
25098 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
25099 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
25100
25101 continue
25102 fi
25103 ;;
25104 esac
25105 case "$CPPFLAGS" in
25106 (*$cf_add_cflags)
25107 ;;
25108 (*)
25109 case "$cf_add_cflags" in
25110 (-D*)
25111 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
25112
25113 CPPFLAGS=`echo "$CPPFLAGS" | \
25114 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
25115 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
25116
25117 ;;
25118 esac
25119
25120 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
25121 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
25122
25123 ;;
25124 esac
25125 ;;
25126 (*)
25127
25128 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
25129 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
25130
25131 ;;
25132 esac
25133 ;;
25134 (yes)
25135
25136 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
25137 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
25138
25139 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
25140
25141 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
25142 && test -z "${cf_tst_cflags}" \
25143 && cf_fix_cppflags=no
25144 ;;
25145 esac
25146 done
25147
25148 if test -n "$cf_new_cflags" ; then
25149
25150 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
25151 CFLAGS="${CFLAGS}$cf_new_cflags"
25152
25153 fi
25154
25155 if test -n "$cf_new_cppflags" ; then
25156
25157 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
25158 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
25159
25160 fi
25161
25162 if test -n "$cf_new_extra_cppflags" ; then
25163
25164 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
25165 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
25166
25167 fi
25168
25169 ;;
25170 esac
25171 ;;
25172 esac
25173
25174 if test "$with_dbmalloc" = yes ; then
25175 echo "$as_me:25175: checking for dbmalloc.h" >&5
25176 echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6
25177 if test "${ac_cv_header_dbmalloc_h+set}" = set; then
25178 echo $ECHO_N "(cached) $ECHO_C" >&6
25179 else
25180 cat >"conftest.$ac_ext" <<_ACEOF
25181 #line 25181 "configure"
25182 #include "confdefs.h"
25183 #include <dbmalloc.h>
25184 _ACEOF
25185 if { (eval echo "$as_me:25185: \"$ac_cpp "conftest.$ac_ext"\"") >&5
25186 (eval $ac_cpp "conftest.$ac_ext") 2>conftest.er1
25187 ac_status=$?
25188 $EGREP -v '^ *\+' conftest.er1 >conftest.err
25189 rm -f conftest.er1
25190 cat conftest.err >&5
25191 echo "$as_me:25191: \$? = $ac_status" >&5
25192 (exit "$ac_status"); } >/dev/null; then
25193 if test -s conftest.err; then
25194 ac_cpp_err=$ac_c_preproc_warn_flag
25195 else
25196 ac_cpp_err=
25197 fi
25198 else
25199 ac_cpp_err=yes
25200 fi
25201 if test -z "$ac_cpp_err"; then
25202 ac_cv_header_dbmalloc_h=yes
25203 else
25204 echo "$as_me: failed program was:" >&5
25205 cat "conftest.$ac_ext" >&5
25206 ac_cv_header_dbmalloc_h=no
25207 fi
25208 rm -f conftest.err "conftest.$ac_ext"
25209 fi
25210 echo "$as_me:25210: result: $ac_cv_header_dbmalloc_h" >&5
25211 echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6
25212 if test "$ac_cv_header_dbmalloc_h" = yes; then
25213
25214 echo "$as_me:25214: checking for debug_malloc in -ldbmalloc" >&5
25215 echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6
25216 if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then
25217 echo $ECHO_N "(cached) $ECHO_C" >&6
25218 else
25219 ac_check_lib_save_LIBS=$LIBS
25220 LIBS="-ldbmalloc $LIBS"
25221 cat >"conftest.$ac_ext" <<_ACEOF
25222 #line 25222 "configure"
25223 #include "confdefs.h"
25224
25225 /* Override any gcc2 internal prototype to avoid an error. */
25226 #ifdef __cplusplus
25227 extern "C"
25228 #endif
25229 /* We use char because int might match the return type of a gcc2
25230 builtin and then its argument prototype would still apply. */
25231 char debug_malloc (void);
25232 int
25233 main (void)
25234 {
25235 debug_malloc ();
25236 ;
25237 return 0;
25238 }
25239 _ACEOF
25240 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
25241 if { (eval echo "$as_me:25241: \"$ac_link\"") >&5
25242 (eval $ac_link) 2>&5
25243 ac_status=$?
25244 echo "$as_me:25244: \$? = $ac_status" >&5
25245 (exit "$ac_status"); } &&
25246 { ac_try='test -s "conftest$ac_exeext"'
25247 { (eval echo "$as_me:25247: \"$ac_try\"") >&5
25248 (eval $ac_try) 2>&5
25249 ac_status=$?
25250 echo "$as_me:25250: \$? = $ac_status" >&5
25251 (exit "$ac_status"); }; }; then
25252 ac_cv_lib_dbmalloc_debug_malloc=yes
25253 else
25254 echo "$as_me: failed program was:" >&5
25255 cat "conftest.$ac_ext" >&5
25256 ac_cv_lib_dbmalloc_debug_malloc=no
25257 fi
25258 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
25259 LIBS=$ac_check_lib_save_LIBS
25260 fi
25261 echo "$as_me:25261: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
25262 echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6
25263 if test "$ac_cv_lib_dbmalloc_debug_malloc" = yes; then
25264 cat >>confdefs.h <<EOF
25265 #define HAVE_LIBDBMALLOC 1
25266 EOF
25267
25268 LIBS="-ldbmalloc $LIBS"
25269
25270 fi
25271
25272 fi
25273
25274 fi
25275
25276 echo "$as_me:25276: checking if you want to use valgrind for testing" >&5
25277 echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6
25278
25279 # Check whether --with-valgrind or --without-valgrind was given.
25280 if test "${with_valgrind+set}" = set; then
25281 withval="$with_valgrind"
25282 case "x$withval" in
25283 (x|xno) ;;
25284 (*)
25285 : "${with_cflags:=-g}"
25286 : "${enable_leaks:=no}"
25287 with_valgrind=yes
25288
25289 cat >>confdefs.h <<EOF
25290 #define USE_VALGRIND 1
25291 EOF
25292
25293 ;;
25294 esac
25295 else
25296 with_valgrind=
25297 fi;
25298 echo "$as_me:25298: result: ${with_valgrind:-no}" >&5
25299 echo "${ECHO_T}${with_valgrind:-no}" >&6
25300
25301 case ".$with_cflags" in
25302 (.*-g*)
25303 case .$CFLAGS in
25304 (.*-g*)
25305 ;;
25306 (*)
25307
25308 cf_fix_cppflags=no
25309 cf_new_cflags=
25310 cf_new_cppflags=
25311 cf_new_extra_cppflags=
25312
25313 for cf_add_cflags in -g
25314 do
25315 case "$cf_fix_cppflags" in
25316 (no)
25317 case "$cf_add_cflags" in
25318 (-undef|-nostdinc*|-I*|-D*|-U*|-E|-P|-C)
25319 case "$cf_add_cflags" in
25320 (-D*)
25321 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^-D[^=]*='\''\"[^"]*//'`
25322
25323 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
25324 && test -z "${cf_tst_cflags}" \
25325 && cf_fix_cppflags=yes
25326
25327 if test "$cf_fix_cppflags" = yes ; then
25328
25329 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
25330 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
25331
25332 continue
25333 elif test "${cf_tst_cflags}" = "\"'" ; then
25334
25335 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
25336 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
25337
25338 continue
25339 fi
25340 ;;
25341 esac
25342 case "$CPPFLAGS" in
25343 (*$cf_add_cflags)
25344 ;;
25345 (*)
25346 case "$cf_add_cflags" in
25347 (-D*)
25348 cf_tst_cppflags=`echo "x$cf_add_cflags" | sed -e 's/^...//' -e 's/=.*//'`
25349
25350 CPPFLAGS=`echo "$CPPFLAGS" | \
25351 sed -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?[ ]/ /g' \
25352 -e 's/-[UD]'"$cf_tst_cppflags"'\(=[^ ]*\)\?$//g'`
25353
25354 ;;
25355 esac
25356
25357 test -n "$cf_new_cppflags" && cf_new_cppflags="$cf_new_cppflags "
25358 cf_new_cppflags="${cf_new_cppflags}$cf_add_cflags"
25359
25360 ;;
25361 esac
25362 ;;
25363 (*)
25364
25365 test -n "$cf_new_cflags" && cf_new_cflags="$cf_new_cflags "
25366 cf_new_cflags="${cf_new_cflags}$cf_add_cflags"
25367
25368 ;;
25369 esac
25370 ;;
25371 (yes)
25372
25373 test -n "$cf_new_extra_cppflags" && cf_new_extra_cppflags="$cf_new_extra_cppflags "
25374 cf_new_extra_cppflags="${cf_new_extra_cppflags}$cf_add_cflags"
25375
25376 cf_tst_cflags=`echo "${cf_add_cflags}" |sed -e 's/^[^"]*"'\''//'`
25377
25378 test "x${cf_add_cflags}" != "x${cf_tst_cflags}" \
25379 && test -z "${cf_tst_cflags}" \
25380 && cf_fix_cppflags=no
25381 ;;
25382 esac
25383 done
25384
25385 if test -n "$cf_new_cflags" ; then
25386
25387 test -n "$CFLAGS" && CFLAGS="$CFLAGS "
25388 CFLAGS="${CFLAGS}$cf_new_cflags"
25389
25390 fi
25391
25392 if test -n "$cf_new_cppflags" ; then
25393
25394 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
25395 CPPFLAGS="${CPPFLAGS}$cf_new_cppflags"
25396
25397 fi
25398
25399 if test -n "$cf_new_extra_cppflags" ; then
25400
25401 test -n "$EXTRA_CPPFLAGS" && EXTRA_CPPFLAGS="$EXTRA_CPPFLAGS "
25402 EXTRA_CPPFLAGS="${EXTRA_CPPFLAGS}$cf_new_extra_cppflags"
25403
25404 fi
25405
25406 ;;
25407 esac
25408 ;;
25409 esac
25410
25411 echo "$as_me:25411: checking if you want to perform memory-leak testing" >&5
25412 echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6
25413
25414 # Check whether --enable-leaks or --disable-leaks was given.
25415 if test "${enable_leaks+set}" = set; then
25416 enableval="$enable_leaks"
25417 enable_leaks=$enableval
25418 else
25419 enable_leaks=yes
25420 fi;
25421 if test "x$enable_leaks" = xno; then with_no_leaks=yes; else with_no_leaks=no; fi
25422 echo "$as_me:25422: result: $with_no_leaks" >&5
25423 echo "${ECHO_T}$with_no_leaks" >&6
25424
25425 if test "$enable_leaks" = no ; then
25426
25427 cat >>confdefs.h <<\EOF
25428 #define NO_LEAKS 1
25429 EOF
25430
25431 cat >>confdefs.h <<\EOF
25432 #define YY_NO_LEAKS 1
25433 EOF
25434
25435 fi
25436
25437 echo "$as_me:25437: checking if you want to see long compiling messages" >&5
25438 echo $ECHO_N "checking if you want to see long compiling messages... $ECHO_C" >&6
25439
25440 # Check whether --enable-echo or --disable-echo was given.
25441 if test "${enable_echo+set}" = set; then
25442 enableval="$enable_echo"
25443 test "$enableval" != no && enableval=yes
25444 if test "$enableval" != "yes" ; then
25445
25446 ECHO_LT='--silent'
25447 ECHO_LD='@echo linking $@;'
25448 RULE_CC='@echo compiling $<'
25449 SHOW_CC='@echo compiling $@'
25450 ECHO_CC='@'
25451
25452 else
25453
25454 ECHO_LT=''
25455 ECHO_LD=''
25456 RULE_CC=''
25457 SHOW_CC=''
25458 ECHO_CC=''
25459
25460 fi
25461 else
25462 enableval=yes
25463
25464 ECHO_LT=''
25465 ECHO_LD=''
25466 RULE_CC=''
25467 SHOW_CC=''
25468 ECHO_CC=''
25469
25470 fi;
25471 echo "$as_me:25471: result: $enableval" >&5
25472 echo "${ECHO_T}$enableval" >&6
25473
25474 echo "$as_me:25474: checking if you want magic cookie emulation" >&5
25475 echo $ECHO_N "checking if you want magic cookie emulation... $ECHO_C" >&6
25476
25477 # Check whether --enable-xmc-glitch or --disable-xmc-glitch was given.
25478 if test "${enable_xmc_glitch+set}" = set; then
25479 enableval="$enable_xmc_glitch"
25480 test "$enableval" != yes && enableval=no
25481 if test "$enableval" != "no" ; then
25482 enable_xmc=yes
25483 else
25484 enable_xmc=no
25485 fi
25486 else
25487 enableval=no
25488 enable_xmc=no
25489
25490 fi;
25491 echo "$as_me:25491: result: $enable_xmc" >&5
25492 echo "${ECHO_T}$enable_xmc" >&6
25493 if test "$enable_xmc" = yes ; then
25494
25495 cat >>confdefs.h <<\EOF
25496 #define EXP_XMC_GLITCH 1
25497 EOF
25498
25499 EXTRASRCS="$EXTRASRCS testxmc.c"
25500 EXTRAOBJS="$EXTRAOBJS testxmc.o"
25501 fi
25502
25503 for ac_func in tigetstr
25504 do
25505 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
25506 echo "$as_me:25506: checking for $ac_func" >&5
25507 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
25508 if eval "test \"\${$as_ac_var+set}\" = set"; then
25509 echo $ECHO_N "(cached) $ECHO_C" >&6
25510 else
25511 cat >"conftest.$ac_ext" <<_ACEOF
25512 #line 25512 "configure"
25513 #include "confdefs.h"
25514 #define $ac_func autoconf_temporary
25515 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
25516 #undef $ac_func
25517
25518 #ifdef __cplusplus
25519 extern "C"
25520 #endif
25521
25522 /* We use char because int might match the return type of a gcc2
25523 builtin and then its argument prototype would still apply. */
25524 char $ac_func (void);
25525
25526 int
25527 main (void)
25528 {
25529
25530 /* The GNU C library defines stubs for functions which it implements
25531 to always fail with ENOSYS. Some functions are actually named
25532 something starting with __ and the normal name is an alias. */
25533 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
25534 #error found stub for $ac_func
25535 #endif
25536
25537 return $ac_func ();
25538 ;
25539 return 0;
25540 }
25541 _ACEOF
25542 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
25543 if { (eval echo "$as_me:25543: \"$ac_link\"") >&5
25544 (eval $ac_link) 2>&5
25545 ac_status=$?
25546 echo "$as_me:25546: \$? = $ac_status" >&5
25547 (exit "$ac_status"); } &&
25548 { ac_try='test -s "conftest$ac_exeext"'
25549 { (eval echo "$as_me:25549: \"$ac_try\"") >&5
25550 (eval $ac_try) 2>&5
25551 ac_status=$?
25552 echo "$as_me:25552: \$? = $ac_status" >&5
25553 (exit "$ac_status"); }; }; then
25554 eval "$as_ac_var=yes"
25555 else
25556 echo "$as_me: failed program was:" >&5
25557 cat "conftest.$ac_ext" >&5
25558 eval "$as_ac_var=no"
25559 fi
25560 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
25561 fi
25562 echo "$as_me:25562: result: `eval echo '${'"$as_ac_var"'}'`" >&5
25563 echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
25564 if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
25565 cat >>confdefs.h <<EOF
25566 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
25567 EOF
25568
25569 fi
25570 done
25571
25572 if test -n "$cf_cv_lib_part_tgetent"; then
25573
25574 for ac_func in use_extended_names
25575 do
25576 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
25577 echo "$as_me:25577: checking for $ac_func" >&5
25578 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
25579 if eval "test \"\${$as_ac_var+set}\" = set"; then
25580 echo $ECHO_N "(cached) $ECHO_C" >&6
25581 else
25582 cat >"conftest.$ac_ext" <<_ACEOF
25583 #line 25583 "configure"
25584 #include "confdefs.h"
25585 #define $ac_func autoconf_temporary
25586 #include <limits.h> /* least-intrusive standard header which defines gcc2 __stub macros */
25587 #undef $ac_func
25588
25589 #ifdef __cplusplus
25590 extern "C"
25591 #endif
25592
25593 /* We use char because int might match the return type of a gcc2
25594 builtin and then its argument prototype would still apply. */
25595 char $ac_func (void);
25596
25597 int
25598 main (void)
25599 {
25600
25601 /* The GNU C library defines stubs for functions which it implements
25602 to always fail with ENOSYS. Some functions are actually named
25603 something starting with __ and the normal name is an alias. */
25604 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
25605 #error found stub for $ac_func
25606 #endif
25607
25608 return $ac_func ();
25609 ;
25610 return 0;
25611 }
25612 _ACEOF
25613 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
25614 if { (eval echo "$as_me:25614: \"$ac_link\"") >&5
25615 (eval $ac_link) 2>&5
25616 ac_status=$?
25617 echo "$as_me:25617: \$? = $ac_status" >&5
25618 (exit "$ac_status"); } &&
25619 { ac_try='test -s "conftest$ac_exeext"'
25620 { (eval echo "$as_me:25620: \"$ac_try\"") >&5
25621 (eval $ac_try) 2>&5
25622 ac_status=$?
25623 echo "$as_me:25623: \$? = $ac_status" >&5
25624 (exit "$ac_status"); }; }; then
25625 eval "$as_ac_var=yes"
25626 else
25627 echo "$as_me: failed program was:" >&5
25628 cat "conftest.$ac_ext" >&5
25629 eval "$as_ac_var=no"
25630 fi
25631 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
25632 fi
25633 echo "$as_me:25633: result: `eval echo '${'"$as_ac_var"'}'`" >&5
25634 echo "${ECHO_T}`eval echo '${'"$as_ac_var"'}'`" >&6
25635 if test "`eval echo '${'"$as_ac_var"'}'`" = yes; then
25636 cat >>confdefs.h <<EOF
25637 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
25638 EOF
25639
25640 fi
25641 done
25642
25643 fi
25644
25645 echo "$as_me:25645: checking if you want to use C11 _Noreturn feature" >&5
25646 echo $ECHO_N "checking if you want to use C11 _Noreturn feature... $ECHO_C" >&6
25647
25648 # Check whether --enable-stdnoreturn or --disable-stdnoreturn was given.
25649 if test "${enable_stdnoreturn+set}" = set; then
25650 enableval="$enable_stdnoreturn"
25651 test "$enableval" != yes && enableval=no
25652 if test "$enableval" != "no" ; then
25653 enable_stdnoreturn=yes
25654 else
25655 enable_stdnoreturn=no
25656 fi
25657 else
25658 enableval=no
25659 enable_stdnoreturn=no
25660
25661 fi;
25662 echo "$as_me:25662: result: $enable_stdnoreturn" >&5
25663 echo "${ECHO_T}$enable_stdnoreturn" >&6
25664
25665 if test $enable_stdnoreturn = yes; then
25666 echo "$as_me:25666: checking for C11 _Noreturn feature" >&5
25667 echo $ECHO_N "checking for C11 _Noreturn feature... $ECHO_C" >&6
25668 if test "${cf_cv_c11_noreturn+set}" = set; then
25669 echo $ECHO_N "(cached) $ECHO_C" >&6
25670 else
25671 cat >"conftest.$ac_ext" <<_ACEOF
25672 #line 25672 "configure"
25673 #include "confdefs.h"
25674
25675 $ac_includes_default
25676 #include <stdnoreturn.h>
25677 static _Noreturn void giveup(void) { exit(0); }
25678
25679 int
25680 main (void)
25681 {
25682 if (feof(stdin)) giveup()
25683 ;
25684 return 0;
25685 }
25686 _ACEOF
25687 rm -f "conftest.$ac_objext"
25688 if { (eval echo "$as_me:25688: \"$ac_compile\"") >&5
25689 (eval $ac_compile) 2>&5
25690 ac_status=$?
25691 echo "$as_me:25691: \$? = $ac_status" >&5
25692 (exit "$ac_status"); } &&
25693 { ac_try='test -s "conftest.$ac_objext"'
25694 { (eval echo "$as_me:25694: \"$ac_try\"") >&5
25695 (eval $ac_try) 2>&5
25696 ac_status=$?
25697 echo "$as_me:25697: \$? = $ac_status" >&5
25698 (exit "$ac_status"); }; }; then
25699 cf_cv_c11_noreturn=yes
25700 else
25701 echo "$as_me: failed program was:" >&5
25702 cat "conftest.$ac_ext" >&5
25703 cf_cv_c11_noreturn=no
25704 fi
25705 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
25706
25707 fi
25708 echo "$as_me:25708: result: $cf_cv_c11_noreturn" >&5
25709 echo "${ECHO_T}$cf_cv_c11_noreturn" >&6
25710 else
25711 cf_cv_c11_noreturn=no,
25712 fi
25713
25714 if test "$cf_cv_c11_noreturn" = yes; then
25715
25716 cat >>confdefs.h <<\EOF
25717 #define HAVE_STDNORETURN_H 1
25718 EOF
25719
25720 cat >>confdefs.h <<EOF
25721 #define STDC_NORETURN _Noreturn
25722 EOF
25723
25724 HAVE_STDNORETURN_H=1
25725 else
25726 HAVE_STDNORETURN_H=0
25727 fi
25728
25729 if test "$GCC" = yes || test "$GXX" = yes
25730 then
25731
25732 if test "$GCC" = yes || test "$GXX" = yes
25733 then
25734 case $CFLAGS in
25735 (*-Werror=*)
25736 cf_temp_flags=
25737 for cf_temp_scan in $CFLAGS
25738 do
25739 case "x$cf_temp_scan" in
25740 (x-Werror=format*)
25741
25742 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
25743 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
25744
25745 ;;
25746 (x-Werror=*)
25747
25748 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
25749 EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
25750
25751 ;;
25752 (*)
25753
25754 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
25755 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
25756
25757 ;;
25758 esac
25759 done
25760 if test "x$CFLAGS" != "x$cf_temp_flags"
25761 then
25762 test -n "$verbose" && echo " repairing CFLAGS: $CFLAGS" 1>&6
25763
25764 echo "${as_me:-configure}:25764: testing repairing CFLAGS: $CFLAGS ..." 1>&5
25765
25766 CFLAGS="$cf_temp_flags"
25767 test -n "$verbose" && echo " ... fixed $CFLAGS" 1>&6
25768
25769 echo "${as_me:-configure}:25769: testing ... fixed $CFLAGS ..." 1>&5
25770
25771 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
25772
25773 echo "${as_me:-configure}:25773: testing ... extra $EXTRA_CFLAGS ..." 1>&5
25774
25775 fi
25776 ;;
25777 esac
25778 fi
25779
25780 if test "$GCC" = yes || test "$GXX" = yes
25781 then
25782 case $CPPFLAGS in
25783 (*-Werror=*)
25784 cf_temp_flags=
25785 for cf_temp_scan in $CPPFLAGS
25786 do
25787 case "x$cf_temp_scan" in
25788 (x-Werror=format*)
25789
25790 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
25791 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
25792
25793 ;;
25794 (x-Werror=*)
25795
25796 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
25797 EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
25798
25799 ;;
25800 (*)
25801
25802 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
25803 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
25804
25805 ;;
25806 esac
25807 done
25808 if test "x$CPPFLAGS" != "x$cf_temp_flags"
25809 then
25810 test -n "$verbose" && echo " repairing CPPFLAGS: $CPPFLAGS" 1>&6
25811
25812 echo "${as_me:-configure}:25812: testing repairing CPPFLAGS: $CPPFLAGS ..." 1>&5
25813
25814 CPPFLAGS="$cf_temp_flags"
25815 test -n "$verbose" && echo " ... fixed $CPPFLAGS" 1>&6
25816
25817 echo "${as_me:-configure}:25817: testing ... fixed $CPPFLAGS ..." 1>&5
25818
25819 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
25820
25821 echo "${as_me:-configure}:25821: testing ... extra $EXTRA_CFLAGS ..." 1>&5
25822
25823 fi
25824 ;;
25825 esac
25826 fi
25827
25828 if test "$GCC" = yes || test "$GXX" = yes
25829 then
25830 case $LDFLAGS in
25831 (*-Werror=*)
25832 cf_temp_flags=
25833 for cf_temp_scan in $LDFLAGS
25834 do
25835 case "x$cf_temp_scan" in
25836 (x-Werror=format*)
25837
25838 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
25839 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
25840
25841 ;;
25842 (x-Werror=*)
25843
25844 test -n "$EXTRA_CFLAGS" && EXTRA_CFLAGS="$EXTRA_CFLAGS "
25845 EXTRA_CFLAGS="${EXTRA_CFLAGS}$cf_temp_scan"
25846
25847 ;;
25848 (*)
25849
25850 test -n "$cf_temp_flags" && cf_temp_flags="$cf_temp_flags "
25851 cf_temp_flags="${cf_temp_flags}$cf_temp_scan"
25852
25853 ;;
25854 esac
25855 done
25856 if test "x$LDFLAGS" != "x$cf_temp_flags"
25857 then
25858 test -n "$verbose" && echo " repairing LDFLAGS: $LDFLAGS" 1>&6
25859
25860 echo "${as_me:-configure}:25860: testing repairing LDFLAGS: $LDFLAGS ..." 1>&5
25861
25862 LDFLAGS="$cf_temp_flags"
25863 test -n "$verbose" && echo " ... fixed $LDFLAGS" 1>&6
25864
25865 echo "${as_me:-configure}:25865: testing ... fixed $LDFLAGS ..." 1>&5
25866
25867 test -n "$verbose" && echo " ... extra $EXTRA_CFLAGS" 1>&6
25868
25869 echo "${as_me:-configure}:25869: testing ... extra $EXTRA_CFLAGS ..." 1>&5
25870
25871 fi
25872 ;;
25873 esac
25874 fi
25875
25876 echo "$as_me:25876: checking if you want to turn on gcc warnings" >&5
25877 echo $ECHO_N "checking if you want to turn on gcc warnings... $ECHO_C" >&6
25878
25879 # Check whether --enable-warnings or --disable-warnings was given.
25880 if test "${enable_warnings+set}" = set; then
25881 enableval="$enable_warnings"
25882 test "$enableval" != yes && enableval=no
25883 if test "$enableval" != "no" ; then
25884 enable_warnings=yes
25885 else
25886 enable_warnings=no
25887 fi
25888 else
25889 enableval=no
25890 enable_warnings=no
25891
25892 fi;
25893 echo "$as_me:25893: result: $enable_warnings" >&5
25894 echo "${ECHO_T}$enable_warnings" >&6
25895 if test "$enable_warnings" = "yes"
25896 then
25897
25898 if test "x$have_x" = xyes; then
25899
25900 cf_save_LIBS_CF_CONST_X_STRING="$LIBS"
25901 cf_save_CFLAGS_CF_CONST_X_STRING="$CFLAGS"
25902 cf_save_CPPFLAGS_CF_CONST_X_STRING="$CPPFLAGS"
25903 LIBS="$LIBS ${X_PRE_LIBS} ${X_LIBS} ${X_EXTRA_LIBS}"
25904 for cf_X_CFLAGS in $X_CFLAGS
25905 do
25906 case "x$cf_X_CFLAGS" in
25907 x-[IUD]*)
25908 CPPFLAGS="$CPPFLAGS $cf_X_CFLAGS"
25909 ;;
25910 *)
25911 CFLAGS="$CFLAGS $cf_X_CFLAGS"
25912 ;;
25913 esac
25914 done
25915
25916 cat >"conftest.$ac_ext" <<_ACEOF
25917 #line 25917 "configure"
25918 #include "confdefs.h"
25919
25920 $ac_includes_default
25921 #include <X11/Intrinsic.h>
25922
25923 int
25924 main (void)
25925 {
25926 String foo = malloc(1); free((void*)foo)
25927 ;
25928 return 0;
25929 }
25930 _ACEOF
25931 rm -f "conftest.$ac_objext"
25932 if { (eval echo "$as_me:25932: \"$ac_compile\"") >&5
25933 (eval $ac_compile) 2>&5
25934 ac_status=$?
25935 echo "$as_me:25935: \$? = $ac_status" >&5
25936 (exit "$ac_status"); } &&
25937 { ac_try='test -s "conftest.$ac_objext"'
25938 { (eval echo "$as_me:25938: \"$ac_try\"") >&5
25939 (eval $ac_try) 2>&5
25940 ac_status=$?
25941 echo "$as_me:25941: \$? = $ac_status" >&5
25942 (exit "$ac_status"); }; }; then
25943
25944 echo "$as_me:25944: checking for X11/Xt const-feature" >&5
25945 echo $ECHO_N "checking for X11/Xt const-feature... $ECHO_C" >&6
25946 if test "${cf_cv_const_x_string+set}" = set; then
25947 echo $ECHO_N "(cached) $ECHO_C" >&6
25948 else
25949
25950 cat >"conftest.$ac_ext" <<_ACEOF
25951 #line 25951 "configure"
25952 #include "confdefs.h"
25953
25954 #undef _CONST_X_STRING
25955 #define _CONST_X_STRING /* X11R7.8 (perhaps) */
25956 #undef XTSTRINGDEFINES /* X11R5 and later */
25957 $ac_includes_default
25958 #include <X11/Intrinsic.h>
25959
25960 int
25961 main (void)
25962 {
25963 String foo = malloc(1); *foo = 0
25964 ;
25965 return 0;
25966 }
25967 _ACEOF
25968 rm -f "conftest.$ac_objext"
25969 if { (eval echo "$as_me:25969: \"$ac_compile\"") >&5
25970 (eval $ac_compile) 2>&5
25971 ac_status=$?
25972 echo "$as_me:25972: \$? = $ac_status" >&5
25973 (exit "$ac_status"); } &&
25974 { ac_try='test -s "conftest.$ac_objext"'
25975 { (eval echo "$as_me:25975: \"$ac_try\"") >&5
25976 (eval $ac_try) 2>&5
25977 ac_status=$?
25978 echo "$as_me:25978: \$? = $ac_status" >&5
25979 (exit "$ac_status"); }; }; then
25980
25981 cf_cv_const_x_string=no
25982
25983 else
25984 echo "$as_me: failed program was:" >&5
25985 cat "conftest.$ac_ext" >&5
25986
25987 cf_cv_const_x_string=yes
25988
25989 fi
25990 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
25991
25992 fi
25993 echo "$as_me:25993: result: $cf_cv_const_x_string" >&5
25994 echo "${ECHO_T}$cf_cv_const_x_string" >&6
25995
25996 LIBS="$cf_save_LIBS_CF_CONST_X_STRING"
25997 CFLAGS="$cf_save_CFLAGS_CF_CONST_X_STRING"
25998 CPPFLAGS="$cf_save_CPPFLAGS_CF_CONST_X_STRING"
25999
26000 case "$cf_cv_const_x_string" in
26001 (no)
26002
26003 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
26004 CPPFLAGS="${CPPFLAGS}-DXTSTRINGDEFINES"
26005
26006 ;;
26007 (*)
26008
26009 test -n "$CPPFLAGS" && CPPFLAGS="$CPPFLAGS "
26010 CPPFLAGS="${CPPFLAGS}-D_CONST_X_STRING"
26011
26012 ;;
26013 esac
26014
26015 else
26016 echo "$as_me: failed program was:" >&5
26017 cat "conftest.$ac_ext" >&5
26018 fi
26019 rm -f "conftest.$ac_objext" "conftest.$ac_ext"
26020 fi
26021 cat > "conftest.$ac_ext" <<EOF
26022 #line 26022 "${as_me:-configure}"
26023 int main(int argc, char *argv[]) { return (argv[argc-1] == (char*)0) ; }
26024 EOF
26025 if test "$INTEL_COMPILER" = yes
26026 then
26027 # The "-wdXXX" options suppress warnings:
26028 # remark #1419: external declaration in primary source file
26029 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
26030 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
26031 # remark #193: zero used for undefined preprocessing identifier
26032 # remark #593: variable "curs_sb_left_arrow" was set but never used
26033 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
26034 # remark #869: parameter "tw" was never referenced
26035 # remark #981: operands are evaluated in unspecified order
26036 # warning #279: controlling expression is constant
26037
26038 echo "$as_me:26038: checking for $CC warning options" >&5
26039 echo $ECHO_N "checking for $CC warning options... $ECHO_C" >&6
26040 test -n "$verbose" && echo "$as_me:26040: result: " >&5
26041 echo "${ECHO_T}" >&6
26042 cf_save_CFLAGS="$CFLAGS"
26043 EXTRA_CFLAGS="$EXTRA_CFLAGS -Wall"
26044 for cf_opt in \
26045 wd1419 \
26046 wd1683 \
26047 wd1684 \
26048 wd193 \
26049 wd593 \
26050 wd279 \
26051 wd810 \
26052 wd869 \
26053 wd981
26054 do
26055 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
26056 if { (eval echo "$as_me:26056: \"$ac_compile\"") >&5
26057 (eval $ac_compile) 2>&5
26058 ac_status=$?
26059 echo "$as_me:26059: \$? = $ac_status" >&5
26060 (exit "$ac_status"); }; then
26061 test -n "$verbose" && echo "$as_me:26061: result: ... -$cf_opt" >&5
26062 echo "${ECHO_T}... -$cf_opt" >&6
26063 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
26064 fi
26065 done
26066 CFLAGS="$cf_save_CFLAGS"
26067 elif test "$GCC" = yes && test "$GCC_VERSION" != "unknown"
26068 then
26069 echo "$as_me:26069: checking for $CC warning options" >&5
26070 echo $ECHO_N "checking for $CC warning options... $ECHO_C" >&6
26071 test -n "$verbose" && echo "$as_me:26071: result: " >&5
26072 echo "${ECHO_T}" >&6
26073 cf_save_CFLAGS="$CFLAGS"
26074 cf_warn_CONST=""
26075 test "$with_ext_const" = yes && cf_warn_CONST="Wwrite-strings"
26076 cf_gcc_warnings="Wignored-qualifiers Wlogical-op Wvarargs"
26077 test "x$CLANG_COMPILER" = xyes && cf_gcc_warnings=
26078 for cf_opt in W Wall \
26079 Wbad-function-cast \
26080 Wcast-align \
26081 Wcast-qual \
26082 Wdeclaration-after-statement \
26083 Wextra \
26084 Winline \
26085 Wmissing-declarations \
26086 Wmissing-prototypes \
26087 Wnested-externs \
26088 Wpointer-arith \
26089 Wshadow \
26090 Wstrict-prototypes \
26091 Wundef Wno-inline $cf_gcc_warnings $cf_warn_CONST Wdeclaration-after-statement Wextra Wno-unknown-pragmas Wswitch-enum Wno-cast-qual
26092 do
26093 CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
26094 if { (eval echo "$as_me:26094: \"$ac_compile\"") >&5
26095 (eval $ac_compile) 2>&5
26096 ac_status=$?
26097 echo "$as_me:26097: \$? = $ac_status" >&5
26098 (exit "$ac_status"); }; then
26099 test -n "$verbose" && echo "$as_me:26099: result: ... -$cf_opt" >&5
26100 echo "${ECHO_T}... -$cf_opt" >&6
26101 case "$cf_opt" in
26102 (Winline)
26103 case "$GCC_VERSION" in
26104 ([34].*)
26105 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
26106
26107 echo "${as_me:-configure}:26107: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
26108
26109 continue;;
26110 esac
26111 ;;
26112 (Wpointer-arith)
26113 case "$GCC_VERSION" in
26114 ([12].*)
26115 test -n "$verbose" && echo " feature is broken in gcc $GCC_VERSION" 1>&6
26116
26117 echo "${as_me:-configure}:26117: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
26118
26119 continue;;
26120 esac
26121 ;;
26122 esac
26123 EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
26124 fi
26125 done
26126 CFLAGS="$cf_save_CFLAGS"
26127 fi
26128 rm -rf ./conftest*
26129
26130 fi
26131
26132 if test "$GCC" = yes || test "$GXX" = yes
26133 then
26134 cat > conftest.i <<EOF
26135 #ifndef GCC_PRINTF
26136 #define GCC_PRINTF 0
26137 #endif
26138 #ifndef GCC_SCANF
26139 #define GCC_SCANF 0
26140 #endif
26141 #ifndef GCC_NORETURN
26142 #define GCC_NORETURN /* nothing */
26143 #endif
26144 #ifndef GCC_UNUSED
26145 #define GCC_UNUSED /* nothing */
26146 #endif
26147 EOF
26148 if test "$GCC" = yes
26149 then
26150 echo "$as_me:26150: checking for $CC __attribute__ directives" >&5
26151 echo $ECHO_N "checking for $CC __attribute__ directives... $ECHO_C" >&6
26152 test -n "$verbose" && echo "$as_me:26152: result: " >&5
26153 echo "${ECHO_T}" >&6
26154 cat > "conftest.$ac_ext" <<EOF
26155 #line 26155 "${as_me:-configure}"
26156 #include <stdio.h>
26157 #include "confdefs.h"
26158 #include "conftest.h"
26159 #include "conftest.i"
26160 #if GCC_PRINTF
26161 #define GCC_PRINTFLIKE(fmt,var) __attribute__((format(printf,fmt,var)))
26162 #else
26163 #define GCC_PRINTFLIKE(fmt,var) /*nothing*/
26164 #endif
26165 #if GCC_SCANF
26166 #define GCC_SCANFLIKE(fmt,var) __attribute__((format(scanf,fmt,var)))
26167 #else
26168 #define GCC_SCANFLIKE(fmt,var) /*nothing*/
26169 #endif
26170 extern void wow(char *,...) GCC_SCANFLIKE(1,2);
26171 extern GCC_NORETURN void oops(char *,...) GCC_PRINTFLIKE(1,2);
26172 extern GCC_NORETURN void foo(void);
26173 int main(int argc GCC_UNUSED, char *argv[] GCC_UNUSED) { (void)argc; (void)argv; return 0; }
26174 EOF
26175 cf_printf_attribute=no
26176 cf_scanf_attribute=no
26177 for cf_attribute in scanf printf unused noreturn
26178 do
26179
26180 cf_ATTRIBUTE=`echo "$cf_attribute" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
26181
26182 cf_directive="__attribute__(($cf_attribute))"
26183 echo "checking for $CC $cf_directive" 1>&5
26184
26185 case "$cf_attribute" in
26186 (printf)
26187 cf_printf_attribute=yes
26188 cat >conftest.h <<EOF
26189 #define GCC_$cf_ATTRIBUTE 1
26190 EOF
26191 ;;
26192 (scanf)
26193 cf_scanf_attribute=yes
26194 cat >conftest.h <<EOF
26195 #define GCC_$cf_ATTRIBUTE 1
26196 EOF
26197 ;;
26198 (*)
26199 cat >conftest.h <<EOF
26200 #define GCC_$cf_ATTRIBUTE $cf_directive
26201 EOF
26202 ;;
26203 esac
26204
26205 if { (eval echo "$as_me:26205: \"$ac_compile\"") >&5
26206 (eval $ac_compile) 2>&5
26207 ac_status=$?
26208 echo "$as_me:26208: \$? = $ac_status" >&5
26209 (exit "$ac_status"); }; then
26210 test -n "$verbose" && echo "$as_me:26210: result: ... $cf_attribute" >&5
26211 echo "${ECHO_T}... $cf_attribute" >&6
26212 cat conftest.h >>confdefs.h
26213 case "$cf_attribute" in
26214 (noreturn)
26215
26216 cat >>confdefs.h <<EOF
26217 #define GCC_NORETURN $cf_directive
26218 EOF
26219
26220 ;;
26221 (printf)
26222 cf_value='/* nothing */'
26223 if test "$cf_printf_attribute" != no ; then
26224 cf_value='__attribute__((format(printf,fmt,var)))'
26225
26226 cat >>confdefs.h <<\EOF
26227 #define GCC_PRINTF 1
26228 EOF
26229
26230 fi
26231
26232 cat >>confdefs.h <<EOF
26233 #define GCC_PRINTFLIKE(fmt,var) $cf_value
26234 EOF
26235
26236 ;;
26237 (scanf)
26238 cf_value='/* nothing */'
26239 if test "$cf_scanf_attribute" != no ; then
26240 cf_value='__attribute__((format(scanf,fmt,var)))'
26241
26242 cat >>confdefs.h <<\EOF
26243 #define GCC_SCANF 1
26244 EOF
26245
26246 fi
26247
26248 cat >>confdefs.h <<EOF
26249 #define GCC_SCANFLIKE(fmt,var) $cf_value
26250 EOF
26251
26252 ;;
26253 (unused)
26254
26255 cat >>confdefs.h <<EOF
26256 #define GCC_UNUSED $cf_directive
26257 EOF
26258
26259 ;;
26260 esac
26261 fi
26262 done
26263 else
26264 ${FGREP-fgrep} define conftest.i >>confdefs.h
26265 fi
26266 rm -rf ./conftest*
26267 fi
26268
26269 fi
26270
26271 test "$disable_setuid" = yes &&
26272 cat >>confdefs.h <<\EOF
26273 #define DISABLE_SETUID 1
26274 EOF
26275
26276 test "$disable_setgid" = yes &&
26277 cat >>confdefs.h <<\EOF
26278 #define DISABLE_SETGID 1
26279 EOF
26280
26281 if test $disable_setuid = yes ; then
26282 MAY_SETUID="#"
26283 NOT_SETUID=
26284 elif test $disable_setgid = yes ; then
26285 MAY_SETUID="#"
26286 NOT_SETUID=
26287 else
26288 MAY_SETUID=
26289 NOT_SETUID="#"
26290 fi
26291
26292 ### remove from CPPFLAGS the optional features we define in xtermcfg.h
26293 ### or other conflicting symbols that may be defined via imake:
26294 for cf_def in \
26295 __STDC__ \
26296 ALLOWLOGGING \
26297 ALLOWLOGFILEEXEC \
26298 OPT_LUIT_PROG \
26299 OPT_WIDE_CHARS \
26300 SCROLLBAR_RIGHT \
26301 USE_TTY_GROUP \
26302 USE_UTEMPTER \
26303 XRENDERFONT
26304 do
26305 CPPFLAGS=`echo "$CPPFLAGS" | sed -e s/-D$cf_def//`
26306 done
26307
26308 echo "$as_me:26308: checking if filesystem supports mixed-case filenames" >&5
26309 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
26310 if test "${cf_cv_mixedcase+set}" = set; then
26311 echo $ECHO_N "(cached) $ECHO_C" >&6
26312 else
26313
26314 if test "$cross_compiling" = yes ; then
26315 case "$target_alias" in
26316 (*-os2-emx*|*-msdosdjgpp*|*-cygwin*|*-msys*|*-mingw*|*-uwin*|darwin*)
26317 cf_cv_mixedcase=no
26318 ;;
26319 (*)
26320 cf_cv_mixedcase=yes
26321 ;;
26322 esac
26323 else
26324 rm -f conftest CONFTEST
26325 echo test >conftest
26326 if test -f CONFTEST ; then
26327 cf_cv_mixedcase=no
26328 else
26329 cf_cv_mixedcase=yes
26330 fi
26331 rm -f conftest CONFTEST
26332 fi
26333
26334 fi
26335 echo "$as_me:26335: result: $cf_cv_mixedcase" >&5
26336 echo "${ECHO_T}$cf_cv_mixedcase" >&6
26337 test "$cf_cv_mixedcase" = yes &&
26338 cat >>confdefs.h <<\EOF
26339 #define MIXEDCASE_FILENAMES 1
26340 EOF
26341
26342 for ac_prog in exctags ctags
26343 do
26344 # Extract the first word of "$ac_prog", so it can be a program name with args.
26345 set dummy $ac_prog; ac_word=$2
26346 echo "$as_me:26346: checking for $ac_word" >&5
26347 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
26348 if test "${ac_cv_prog_CTAGS+set}" = set; then
26349 echo $ECHO_N "(cached) $ECHO_C" >&6
26350 else
26351 if test -n "$CTAGS"; then
26352 ac_cv_prog_CTAGS="$CTAGS" # Let the user override the test.
26353 else
26354 ac_save_IFS=$IFS; IFS=$ac_path_separator
26355 ac_dummy="$PATH"
26356 for ac_dir in $ac_dummy; do
26357 IFS=$ac_save_IFS
26358 test -z "$ac_dir" && ac_dir=.
26359 $as_executable_p "$ac_dir/$ac_word" || continue
26360 ac_cv_prog_CTAGS="$ac_prog"
26361 echo "$as_me:26361: found $ac_dir/$ac_word" >&5
26362 break
26363 done
26364
26365 fi
26366 fi
26367 CTAGS=$ac_cv_prog_CTAGS
26368 if test -n "$CTAGS"; then
26369 echo "$as_me:26369: result: $CTAGS" >&5
26370 echo "${ECHO_T}$CTAGS" >&6
26371 else
26372 echo "$as_me:26372: result: no" >&5
26373 echo "${ECHO_T}no" >&6
26374 fi
26375
26376 test -n "$CTAGS" && break
26377 done
26378
26379 for ac_prog in exetags etags
26380 do
26381 # Extract the first word of "$ac_prog", so it can be a program name with args.
26382 set dummy $ac_prog; ac_word=$2
26383 echo "$as_me:26383: checking for $ac_word" >&5
26384 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
26385 if test "${ac_cv_prog_ETAGS+set}" = set; then
26386 echo $ECHO_N "(cached) $ECHO_C" >&6
26387 else
26388 if test -n "$ETAGS"; then
26389 ac_cv_prog_ETAGS="$ETAGS" # Let the user override the test.
26390 else
26391 ac_save_IFS=$IFS; IFS=$ac_path_separator
26392 ac_dummy="$PATH"
26393 for ac_dir in $ac_dummy; do
26394 IFS=$ac_save_IFS
26395 test -z "$ac_dir" && ac_dir=.
26396 $as_executable_p "$ac_dir/$ac_word" || continue
26397 ac_cv_prog_ETAGS="$ac_prog"
26398 echo "$as_me:26398: found $ac_dir/$ac_word" >&5
26399 break
26400 done
26401
26402 fi
26403 fi
26404 ETAGS=$ac_cv_prog_ETAGS
26405 if test -n "$ETAGS"; then
26406 echo "$as_me:26406: result: $ETAGS" >&5
26407 echo "${ECHO_T}$ETAGS" >&6
26408 else
26409 echo "$as_me:26409: result: no" >&5
26410 echo "${ECHO_T}no" >&6
26411 fi
26412
26413 test -n "$ETAGS" && break
26414 done
26415
26416 # Extract the first word of "${CTAGS:-ctags}", so it can be a program name with args.
26417 set dummy ${CTAGS:-ctags}; ac_word=$2
26418 echo "$as_me:26418: checking for $ac_word" >&5
26419 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
26420 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
26421 echo $ECHO_N "(cached) $ECHO_C" >&6
26422 else
26423 if test -n "$MAKE_LOWER_TAGS"; then
26424 ac_cv_prog_MAKE_LOWER_TAGS="$MAKE_LOWER_TAGS" # Let the user override the test.
26425 else
26426 ac_save_IFS=$IFS; IFS=$ac_path_separator
26427 ac_dummy="$PATH"
26428 for ac_dir in $ac_dummy; do
26429 IFS=$ac_save_IFS
26430 test -z "$ac_dir" && ac_dir=.
26431 $as_executable_p "$ac_dir/$ac_word" || continue
26432 ac_cv_prog_MAKE_LOWER_TAGS="yes"
26433 echo "$as_me:26433: found $ac_dir/$ac_word" >&5
26434 break
26435 done
26436
26437 test -z "$ac_cv_prog_MAKE_LOWER_TAGS" && ac_cv_prog_MAKE_LOWER_TAGS="no"
26438 fi
26439 fi
26440 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
26441 if test -n "$MAKE_LOWER_TAGS"; then
26442 echo "$as_me:26442: result: $MAKE_LOWER_TAGS" >&5
26443 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
26444 else
26445 echo "$as_me:26445: result: no" >&5
26446 echo "${ECHO_T}no" >&6
26447 fi
26448
26449 if test "$cf_cv_mixedcase" = yes ; then
26450 # Extract the first word of "${ETAGS:-etags}", so it can be a program name with args.
26451 set dummy ${ETAGS:-etags}; ac_word=$2
26452 echo "$as_me:26452: checking for $ac_word" >&5
26453 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
26454 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
26455 echo $ECHO_N "(cached) $ECHO_C" >&6
26456 else
26457 if test -n "$MAKE_UPPER_TAGS"; then
26458 ac_cv_prog_MAKE_UPPER_TAGS="$MAKE_UPPER_TAGS" # Let the user override the test.
26459 else
26460 ac_save_IFS=$IFS; IFS=$ac_path_separator
26461 ac_dummy="$PATH"
26462 for ac_dir in $ac_dummy; do
26463 IFS=$ac_save_IFS
26464 test -z "$ac_dir" && ac_dir=.
26465 $as_executable_p "$ac_dir/$ac_word" || continue
26466 ac_cv_prog_MAKE_UPPER_TAGS="yes"
26467 echo "$as_me:26467: found $ac_dir/$ac_word" >&5
26468 break
26469 done
26470
26471 test -z "$ac_cv_prog_MAKE_UPPER_TAGS" && ac_cv_prog_MAKE_UPPER_TAGS="no"
26472 fi
26473 fi
26474 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
26475 if test -n "$MAKE_UPPER_TAGS"; then
26476 echo "$as_me:26476: result: $MAKE_UPPER_TAGS" >&5
26477 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
26478 else
26479 echo "$as_me:26479: result: no" >&5
26480 echo "${ECHO_T}no" >&6
26481 fi
26482
26483 else
26484 MAKE_UPPER_TAGS=no
26485 fi
26486
26487 if test "$MAKE_UPPER_TAGS" = yes ; then
26488 MAKE_UPPER_TAGS=
26489 else
26490 MAKE_UPPER_TAGS="#"
26491 fi
26492
26493 if test "$MAKE_LOWER_TAGS" = yes ; then
26494 MAKE_LOWER_TAGS=
26495 else
26496 MAKE_LOWER_TAGS="#"
26497 fi
26498
26499 LD_RPATH_OPT=
26500 if test "x$cf_cv_enable_rpath" != xno
26501 then
26502 echo "$as_me:26502: checking for an rpath option" >&5
26503 echo $ECHO_N "checking for an rpath option... $ECHO_C" >&6
26504 case "$cf_cv_system_name" in
26505 (irix*)
26506 if test "$GCC" = yes; then
26507 LD_RPATH_OPT="-Wl,-rpath,"
26508 else
26509 LD_RPATH_OPT="-rpath "
26510 fi
26511 ;;
26512 (linux*|gnu*|k*bsd*-gnu|freebsd*)
26513 LD_RPATH_OPT="-Wl,-rpath,"
26514 ;;
26515 (openbsd[2-9].*|mirbsd*)
26516 LD_RPATH_OPT="-Wl,-rpath,"
26517 ;;
26518 (dragonfly*)
26519 LD_RPATH_OPT="-rpath "
26520 ;;
26521 (netbsd*)
26522 LD_RPATH_OPT="-Wl,-rpath,"
26523 ;;
26524 (osf*|mls+*)
26525 LD_RPATH_OPT="-rpath "
26526 ;;
26527 (solaris2*)
26528 LD_RPATH_OPT="-R"
26529 ;;
26530 (*)
26531 ;;
26532 esac
26533 echo "$as_me:26533: result: $LD_RPATH_OPT" >&5
26534 echo "${ECHO_T}$LD_RPATH_OPT" >&6
26535
26536 case "x$LD_RPATH_OPT" in
26537 (x-R*)
26538 echo "$as_me:26538: checking if we need a space after rpath option" >&5
26539 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
26540 cf_save_LIBS="$LIBS"
26541
26542 cf_add_libs="$LIBS"
26543 # reverse order
26544 cf_add_0lib=
26545 for cf_add_1lib in ${LD_RPATH_OPT}$libdir; do cf_add_0lib="$cf_add_1lib $cf_add_0lib"; done
26546 # filter duplicates
26547 for cf_add_1lib in $cf_add_0lib; do
26548 for cf_add_2lib in $cf_add_libs; do
26549 if test "x$cf_add_1lib" = "x$cf_add_2lib"; then
26550 cf_add_1lib=
26551 break
26552 fi
26553 done
26554 test -n "$cf_add_1lib" && cf_add_libs="$cf_add_1lib $cf_add_libs"
26555 done
26556 LIBS="$cf_add_libs"
26557
26558 cat >"conftest.$ac_ext" <<_ACEOF
26559 #line 26559 "configure"
26560 #include "confdefs.h"
26561
26562 int
26563 main (void)
26564 {
26565
26566 ;
26567 return 0;
26568 }
26569 _ACEOF
26570 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
26571 if { (eval echo "$as_me:26571: \"$ac_link\"") >&5
26572 (eval $ac_link) 2>&5
26573 ac_status=$?
26574 echo "$as_me:26574: \$? = $ac_status" >&5
26575 (exit "$ac_status"); } &&
26576 { ac_try='test -s "conftest$ac_exeext"'
26577 { (eval echo "$as_me:26577: \"$ac_try\"") >&5
26578 (eval $ac_try) 2>&5
26579 ac_status=$?
26580 echo "$as_me:26580: \$? = $ac_status" >&5
26581 (exit "$ac_status"); }; }; then
26582 cf_rpath_space=no
26583 else
26584 echo "$as_me: failed program was:" >&5
26585 cat "conftest.$ac_ext" >&5
26586 cf_rpath_space=yes
26587 fi
26588 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
26589 LIBS="$cf_save_LIBS"
26590 echo "$as_me:26590: result: $cf_rpath_space" >&5
26591 echo "${ECHO_T}$cf_rpath_space" >&6
26592 test "$cf_rpath_space" = yes && LD_RPATH_OPT="$LD_RPATH_OPT "
26593 ;;
26594 esac
26595 fi
26596
26597 echo "$as_me:26597: checking if rpath-hack should be disabled" >&5
26598 echo $ECHO_N "checking if rpath-hack should be disabled... $ECHO_C" >&6
26599
26600 # Check whether --enable-rpath-hack or --disable-rpath-hack was given.
26601 if test "${enable_rpath_hack+set}" = set; then
26602 enableval="$enable_rpath_hack"
26603 test "$enableval" != no && enableval=yes
26604 if test "$enableval" != "yes" ; then
26605 enable_rpath_hack=no
26606 else
26607 enable_rpath_hack=yes
26608 fi
26609 else
26610 enableval=yes
26611 enable_rpath_hack=yes
26612
26613 fi;
26614 if test "x$enable_rpath_hack" = xno; then cf_disable_rpath_hack=yes; else cf_disable_rpath_hack=no; fi
26615 echo "$as_me:26615: result: $cf_disable_rpath_hack" >&5
26616 echo "${ECHO_T}$cf_disable_rpath_hack" >&6
26617
26618 if test "$enable_rpath_hack" = yes ; then
26619
26620 echo "$as_me:26620: checking for updated LDFLAGS" >&5
26621 echo $ECHO_N "checking for updated LDFLAGS... $ECHO_C" >&6
26622 if test -n "$LD_RPATH_OPT" ; then
26623 echo "$as_me:26623: result: maybe" >&5
26624 echo "${ECHO_T}maybe" >&6
26625
26626 for ac_prog in ldd
26627 do
26628 # Extract the first word of "$ac_prog", so it can be a program name with args.
26629 set dummy $ac_prog; ac_word=$2
26630 echo "$as_me:26630: checking for $ac_word" >&5
26631 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
26632 if test "${ac_cv_prog_cf_ldd_prog+set}" = set; then
26633 echo $ECHO_N "(cached) $ECHO_C" >&6
26634 else
26635 if test -n "$cf_ldd_prog"; then
26636 ac_cv_prog_cf_ldd_prog="$cf_ldd_prog" # Let the user override the test.
26637 else
26638 ac_save_IFS=$IFS; IFS=$ac_path_separator
26639 ac_dummy="$PATH"
26640 for ac_dir in $ac_dummy; do
26641 IFS=$ac_save_IFS
26642 test -z "$ac_dir" && ac_dir=.
26643 $as_executable_p "$ac_dir/$ac_word" || continue
26644 ac_cv_prog_cf_ldd_prog="$ac_prog"
26645 echo "$as_me:26645: found $ac_dir/$ac_word" >&5
26646 break
26647 done
26648
26649 fi
26650 fi
26651 cf_ldd_prog=$ac_cv_prog_cf_ldd_prog
26652 if test -n "$cf_ldd_prog"; then
26653 echo "$as_me:26653: result: $cf_ldd_prog" >&5
26654 echo "${ECHO_T}$cf_ldd_prog" >&6
26655 else
26656 echo "$as_me:26656: result: no" >&5
26657 echo "${ECHO_T}no" >&6
26658 fi
26659
26660 test -n "$cf_ldd_prog" && break
26661 done
26662 test -n "$cf_ldd_prog" || cf_ldd_prog="no"
26663
26664 cf_rpath_list="/usr/lib /lib"
26665 if test "$cf_ldd_prog" != no
26666 then
26667 cf_rpath_oops=
26668
26669 cat >"conftest.$ac_ext" <<_ACEOF
26670 #line 26670 "configure"
26671 #include "confdefs.h"
26672 #include <stdio.h>
26673 int
26674 main (void)
26675 {
26676 printf("Hello");
26677 ;
26678 return 0;
26679 }
26680 _ACEOF
26681 rm -f "conftest.$ac_objext" "conftest$ac_exeext"
26682 if { (eval echo "$as_me:26682: \"$ac_link\"") >&5
26683 (eval $ac_link) 2>&5
26684 ac_status=$?
26685 echo "$as_me:26685: \$? = $ac_status" >&5
26686 (exit "$ac_status"); } &&
26687 { ac_try='test -s "conftest$ac_exeext"'
26688 { (eval echo "$as_me:26688: \"$ac_try\"") >&5
26689 (eval $ac_try) 2>&5
26690 ac_status=$?
26691 echo "$as_me:26691: \$? = $ac_status" >&5
26692 (exit "$ac_status"); }; }; then
26693 cf_rpath_oops=`"$cf_ldd_prog" "conftest$ac_exeext" | ${FGREP-fgrep} ' not found' | sed -e 's% =>.*$%%' |sort | uniq`
26694 cf_rpath_list=`"$cf_ldd_prog" "conftest$ac_exeext" | ${FGREP-fgrep} / | sed -e 's%^.*[ ]/%/%' -e 's%/[^/][^/]*$%%' |sort | uniq`
26695 else
26696 echo "$as_me: failed program was:" >&5
26697 cat "conftest.$ac_ext" >&5
26698 fi
26699 rm -f "conftest.$ac_objext" "conftest$ac_exeext" "conftest.$ac_ext"
26700
26701 # If we passed the link-test, but get a "not found" on a given library,
26702 # this could be due to inept reconfiguration of gcc to make it only
26703 # partly honor /usr/local/lib (or whatever). Sometimes this behavior
26704 # is intentional, e.g., installing gcc in /usr/bin and suppressing the
26705 # /usr/local libraries.
26706 if test -n "$cf_rpath_oops"
26707 then
26708 for cf_rpath_src in $cf_rpath_oops
26709 do
26710 for cf_rpath_dir in \
26711 /usr/local \
26712 /usr/pkg \
26713 /opt/sfw
26714 do
26715 if test -f "$cf_rpath_dir/lib/$cf_rpath_src"
26716 then
26717 test -n "$verbose" && echo " ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src" 1>&6
26718
26719 echo "${as_me:-configure}:26719: testing ...adding -L$cf_rpath_dir/lib to LDFLAGS for $cf_rpath_src ..." 1>&5
26720
26721 LDFLAGS="$LDFLAGS -L$cf_rpath_dir/lib"
26722 break
26723 fi
26724 done
26725 done
26726 fi
26727 fi
26728
26729 test -n "$verbose" && echo " ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
26730
26731 echo "${as_me:-configure}:26731: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
26732
26733 test -n "$verbose" && echo " ...checking LDFLAGS $LDFLAGS" 1>&6
26734
26735 echo "${as_me:-configure}:26735: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5
26736
26737 cf_rpath_dst=
26738 for cf_rpath_src in $LDFLAGS
26739 do
26740 case "$cf_rpath_src" in
26741 (-L*)
26742
26743 # check if this refers to a directory which we will ignore
26744 cf_rpath_skip=no
26745 if test -n "$cf_rpath_list"
26746 then
26747 for cf_rpath_item in $cf_rpath_list
26748 do
26749 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
26750 then
26751 cf_rpath_skip=yes
26752 break
26753 fi
26754 done
26755 fi
26756
26757 if test "$cf_rpath_skip" = no
26758 then
26759 # transform the option
26760 if test "$LD_RPATH_OPT" = "-R " ; then
26761 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
26762 else
26763 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
26764 fi
26765
26766 # if we have not already added this, add it now
26767 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
26768 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
26769 then
26770 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
26771
26772 echo "${as_me:-configure}:26772: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
26773
26774 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
26775 fi
26776 fi
26777 ;;
26778 esac
26779 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
26780 done
26781 LDFLAGS=$cf_rpath_dst
26782
26783 test -n "$verbose" && echo " ...checked LDFLAGS $LDFLAGS" 1>&6
26784
26785 echo "${as_me:-configure}:26785: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5
26786
26787 test -n "$verbose" && echo " ...checking LIBS $LIBS" 1>&6
26788
26789 echo "${as_me:-configure}:26789: testing ...checking LIBS $LIBS ..." 1>&5
26790
26791 cf_rpath_dst=
26792 for cf_rpath_src in $LIBS
26793 do
26794 case "$cf_rpath_src" in
26795 (-L*)
26796
26797 # check if this refers to a directory which we will ignore
26798 cf_rpath_skip=no
26799 if test -n "$cf_rpath_list"
26800 then
26801 for cf_rpath_item in $cf_rpath_list
26802 do
26803 if test "x$cf_rpath_src" = "x-L$cf_rpath_item"
26804 then
26805 cf_rpath_skip=yes
26806 break
26807 fi
26808 done
26809 fi
26810
26811 if test "$cf_rpath_skip" = no
26812 then
26813 # transform the option
26814 if test "$LD_RPATH_OPT" = "-R " ; then
26815 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%-R %"`
26816 else
26817 cf_rpath_tmp=`echo "$cf_rpath_src" |sed -e "s%-L%$LD_RPATH_OPT%"`
26818 fi
26819
26820 # if we have not already added this, add it now
26821 cf_rpath_tst=`echo "$EXTRA_LDFLAGS" | sed -e "s%$cf_rpath_tmp %%"`
26822 if test "x$cf_rpath_tst" = "x$EXTRA_LDFLAGS"
26823 then
26824 test -n "$verbose" && echo " ...Filter $cf_rpath_src ->$cf_rpath_tmp" 1>&6
26825
26826 echo "${as_me:-configure}:26826: testing ...Filter $cf_rpath_src ->$cf_rpath_tmp ..." 1>&5
26827
26828 EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
26829 fi
26830 fi
26831 ;;
26832 esac
26833 cf_rpath_dst="$cf_rpath_dst $cf_rpath_src"
26834 done
26835 LIBS=$cf_rpath_dst
26836
26837 test -n "$verbose" && echo " ...checked LIBS $LIBS" 1>&6
26838
26839 echo "${as_me:-configure}:26839: testing ...checked LIBS $LIBS ..." 1>&5
26840
26841 test -n "$verbose" && echo " ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
26842
26843 echo "${as_me:-configure}:26843: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
26844
26845 else
26846 echo "$as_me:26846: result: no" >&5
26847 echo "${ECHO_T}no" >&6
26848 fi
26849
26850 fi
26851
26852 # Force plink.sh to not trim pcre's libraries, which have the same symbol
26853 # names as the system regexp.
26854 if test "$with_pcre" != no
26855 then
26856 LIBS=`echo "$LIBS" | sed -e 's/-lpcre/-kpcre/g'`
26857 fi
26858
26859 ### output xtermcfg.h, etc
26860 ac_config_files="$ac_config_files Makefile df-install minstall:minstall.in run-tic.sh:run-tic.in"
26861
26862 cat >confcache <<\_ACEOF
26863 # This file is a shell script that caches the results of configure
26864 # tests run on this system so they can be shared between configure
26865 # scripts and configure runs, see configure's option --config-cache.
26866 # It is not useful on other systems. If it contains results you don't
26867 # want to keep, you may remove or edit it.
26868 #
26869 # config.status only pays attention to the cache file if you give it
26870 # the --recheck option to rerun configure.
26871 #
26872 # `ac_cv_env_foo' variables (set or unset) will be overridden when
26873 # loading this file, other *unset* `ac_cv_foo' will be assigned the
26874 # following values.
26875
26876 _ACEOF
26877
26878 # The following way of writing the cache mishandles newlines in values,
26879 # but we know of no workaround that is simple, portable, and efficient.
26880 # So, don't put newlines in cache variables' values.
26881 # Ultrix sh set writes to stderr and can't be redirected directly,
26882 # and sets the high bit in the cache file unless we assign to the vars.
26883 {
26884 (set) 2>&1 |
26885 case `(ac_space=' '; set | grep ac_space) 2>&1` in
26886 *ac_space=\ *)
26887 # `set' does not quote correctly, so add quotes (double-quote
26888 # substitution turns \\\\ into \\, and sed turns \\ into \).
26889 sed -n \
26890 "s/'/'\\\\''/g;
26891 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
26892 ;;
26893 *)
26894 # `set' quotes correctly as required by POSIX, so do not add quotes.
26895 sed -n \
26896 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
26897 ;;
26898 esac;
26899 } |
26900 sed '
26901 t clear
26902 : clear
26903 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
26904 t end
26905 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
26906 : end' >>confcache
26907 if cmp -s $cache_file confcache; then :; else
26908 if test -w $cache_file; then
26909 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
26910 cat confcache >$cache_file
26911 else
26912 echo "not updating unwritable cache $cache_file"
26913 fi
26914 fi
26915 rm -f confcache
26916
26917 test "x$prefix" = xNONE && prefix=$ac_default_prefix
26918 # Let make expand exec_prefix.
26919 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
26920
26921 # VPATH may cause trouble with some makes, so we remove $(srcdir),
26922 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
26923 # trailing colons and then remove the whole line if VPATH becomes empty
26924 # (actually we leave an empty line to preserve line numbers).
26925 if test "x$srcdir" = x.; then
26926 ac_vpsub='/^[ ]*VPATH[ ]*=/{
26927 s/:*\$(srcdir):*/:/;
26928 s/:*\${srcdir}:*/:/;
26929 s/:*@srcdir@:*/:/;
26930 s/^\([^=]*=[ ]*\):*/\1/;
26931 s/:*$//;
26932 s/^[^=]*=[ ]*$//;
26933 }'
26934 fi
26935
26936 DEFS=-DHAVE_CONFIG_H
26937
26938 : "${CONFIG_STATUS=./config.status}"
26939 ac_clean_files_save=$ac_clean_files
26940 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
26941 { echo "$as_me:26941: creating $CONFIG_STATUS" >&5
26942 echo "$as_me: creating $CONFIG_STATUS" >&6;}
26943 cat >"$CONFIG_STATUS" <<_ACEOF
26944 #! $SHELL
26945 # Generated automatically by configure.
26946 # Run this file to recreate the current configuration.
26947 # Compiler output produced by configure, useful for debugging
26948 # configure, is in config.log if it exists.
26949
26950 me=\`echo "\$0" | sed -e 's,.*\\/,,'\`
26951
26952 debug=false
26953 SHELL=\${CONFIG_SHELL-$SHELL}
26954 ac_cs_invocation="\$0 \$@"
26955
26956 CLICOLOR_FORCE= GREP_OPTIONS=
26957 unset CLICOLOR_FORCE GREP_OPTIONS
26958 _ACEOF
26959
26960 cat >>"$CONFIG_STATUS" <<\_ACEOF
26961 # Be Bourne compatible
26962 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
26963 emulate sh
26964 NULLCMD=:
26965 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
26966 set -o posix
26967 fi
26968
26969 # Name of the executable.
26970 as_me=`echo "$0" |sed 's,.*[\\/],,'`
26971
26972 if expr a : '\(a\)' >/dev/null 2>&1; then
26973 as_expr="expr"
26974 else
26975 as_expr="false"
26976 fi
26977
26978 rm -f conf$$ conf$$.exe conf$$.file
26979 echo >conf$$.file
26980 if ln -s conf$$.file conf$$ 2>/dev/null; then
26981 # We could just check for DJGPP; but this test a) works b) is more generic
26982 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
26983 if test -f conf$$.exe; then
26984 # Don't use ln at all; we don't have any links
26985 as_ln_s='cp -p'
26986 else
26987 as_ln_s='ln -s'
26988 fi
26989 elif ln conf$$.file conf$$ 2>/dev/null; then
26990 as_ln_s='ln'
26991 else
26992 as_ln_s='cp -p'
26993 fi
26994 rm -f conf$$ conf$$.exe conf$$.file
26995
26996 as_executable_p="test -f"
26997
26998 # Support unset when possible.
26999 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
27000 as_unset="unset"
27001 else
27002 as_unset="false"
27003 fi
27004
27005 # NLS nuisances.
27006 $as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
27007 $as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
27008 $as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
27009 $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
27010 $as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
27011 $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
27012 $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
27013 $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
27014
27015 # IFS
27016 # We need space, tab and new line, in precisely that order.
27017 as_nl='
27018 '
27019 IFS=" $as_nl"
27020
27021 # CDPATH.
27022 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
27023
27024 exec 6>&1
27025
27026 _ACEOF
27027
27028 # Files that config.status was made for.
27029 if test -n "$ac_config_files"; then
27030 echo "config_files=\"$ac_config_files\"" >>"$CONFIG_STATUS"
27031 fi
27032
27033 if test -n "$ac_config_headers"; then
27034 echo "config_headers=\"$ac_config_headers\"" >>"$CONFIG_STATUS"
27035 fi
27036
27037 if test -n "$ac_config_links"; then
27038 echo "config_links=\"$ac_config_links\"" >>"$CONFIG_STATUS"
27039 fi
27040
27041 if test -n "$ac_config_commands"; then
27042 echo "config_commands=\"$ac_config_commands\"" >>"$CONFIG_STATUS"
27043 fi
27044
27045 cat >>"$CONFIG_STATUS" <<\EOF
27046
27047 ac_cs_usage="\
27048 \`$as_me' instantiates files from templates according to the
27049 current configuration.
27050
27051 Usage: $0 [OPTIONS] [FILE]...
27052
27053 -h, --help print this help, then exit
27054 -V, --version print version number, then exit
27055 -d, --debug don't remove temporary files
27056 --recheck update $as_me by reconfiguring in the same conditions
27057 --file=FILE[:TEMPLATE]
27058 instantiate the configuration file FILE
27059 --header=FILE[:TEMPLATE]
27060 instantiate the configuration header FILE
27061
27062 Configuration files:
27063 $config_files
27064
27065 Configuration headers:
27066 $config_headers
27067
27068 Report bugs to <[email protected]>."
27069 EOF
27070
27071 cat >>"$CONFIG_STATUS" <<EOF
27072 ac_cs_version="\\
27073 config.status
27074 configured by $0, generated by GNU Autoconf 2.52.20260412,
27075 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
27076
27077 Copyright 2003-2023,2025 Thomas E. Dickey
27078 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
27079 Free Software Foundation, Inc.
27080 This config.status script is free software; the Free Software Foundation
27081 gives unlimited permission to copy, distribute and modify it."
27082 srcdir="$srcdir"
27083 INSTALL="$INSTALL"
27084 EOF
27085
27086 cat >>"$CONFIG_STATUS" <<\EOF
27087 # If no file are specified by the user, then we need to provide default
27088 # value. By we need to know if files were specified by the user.
27089 ac_need_defaults=:
27090 while test $# != 0
27091 do
27092 case $1 in
27093 --*=*)
27094 ac_option=`expr "x$1" : 'x\([^=]*\)='`
27095 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
27096 shift
27097 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
27098 shift
27099 ;;
27100 -*);;
27101 *) # This is not an option, so the user has probably given explicit
27102 # arguments.
27103 ac_need_defaults=false;;
27104 esac
27105
27106 case $1 in
27107 # Handling of the options.
27108 EOF
27109 cat >>"$CONFIG_STATUS" <<EOF
27110 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
27111 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
27112 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
27113 EOF
27114 cat >>"$CONFIG_STATUS" <<\EOF
27115 --version | --vers* | -V )
27116 echo "$ac_cs_version"; exit 0 ;;
27117 --he | --h)
27118 # Conflict between --help and --header
27119 { { echo "$as_me:27119: error: ambiguous option: $1
27120 Try \`$0 --help' for more information." >&5
27121 echo "$as_me: error: ambiguous option: $1
27122 Try \`$0 --help' for more information." >&2;}
27123 { (exit 1); exit 1; }; };;
27124 --help | --hel | -h )
27125 echo "$ac_cs_usage"; exit 0 ;;
27126 --debug | --d* | -d )
27127 debug=: ;;
27128 --file | --fil | --fi | --f )
27129 shift
27130 CONFIG_FILES="$CONFIG_FILES $1"
27131 ac_need_defaults=false;;
27132 --header | --heade | --head | --hea )
27133 shift
27134 CONFIG_HEADERS="$CONFIG_HEADERS $1"
27135 ac_need_defaults=false;;
27136
27137 # This is an error.
27138 -*) { { echo "$as_me:27138: error: unrecognized option: $1
27139 Try \`$0 --help' for more information." >&5
27140 echo "$as_me: error: unrecognized option: $1
27141 Try \`$0 --help' for more information." >&2;}
27142 { (exit 1); exit 1; }; } ;;
27143
27144 *) ac_config_targets="$ac_config_targets $1" ;;
27145
27146 esac
27147 shift
27148 done
27149
27150 exec 5>>config.log
27151 cat >&5 << _ACEOF
27152
27153 ## ----------------------- ##
27154 ## Running config.status. ##
27155 ## ----------------------- ##
27156
27157 This file was extended by $as_me 2.52.20260412, executed with
27158 CONFIG_FILES = $CONFIG_FILES
27159 CONFIG_HEADERS = $CONFIG_HEADERS
27160 CONFIG_LINKS = $CONFIG_LINKS
27161 CONFIG_COMMANDS = $CONFIG_COMMANDS
27162 > "$ac_cs_invocation"
27163 on `(hostname || uname -n) 2>/dev/null | sed 1q`
27164
27165 _ACEOF
27166 EOF
27167
27168 cat >>"$CONFIG_STATUS" <<\EOF
27169 for ac_config_target in $ac_config_targets
27170 do
27171 case "$ac_config_target" in
27172 # Handling of arguments.
27173 "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
27174 "df-install" ) CONFIG_FILES="$CONFIG_FILES df-install" ;;
27175 "minstall" ) CONFIG_FILES="$CONFIG_FILES minstall:minstall.in" ;;
27176 "run-tic.sh" ) CONFIG_FILES="$CONFIG_FILES run-tic.sh:run-tic.in" ;;
27177 "xtermcfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS xtermcfg.h:xtermcfg.hin" ;;
27178 *) { { echo "$as_me:27178: error: invalid argument: $ac_config_target" >&5
27179 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
27180 { (exit 1); exit 1; }; };;
27181 esac
27182 done
27183
27184 # If the user did not use the arguments to specify the items to instantiate,
27185 # then the envvar interface is used. Set only those that are not.
27186 # We use the long form for the default assignment because of an extremely
27187 # bizarre bug on SunOS 4.1.3.
27188 if "$ac_need_defaults"; then
27189 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
27190 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
27191 fi
27192
27193 # Create a temporary directory, and hook for its removal unless debugging.
27194 $debug ||
27195 {
27196 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
27197 trap '{ (exit 1); exit 1; }' 1 2 13 15
27198 }
27199
27200 # Create a (secure) tmp directory for tmp files.
27201 : "${TMPDIR=/tmp}"
27202 {
27203 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
27204 test -n "$tmp" && test -d "$tmp"
27205 } ||
27206 {
27207 tmp=$TMPDIR/cs$$-$RANDOM
27208 (umask 077 && mkdir "$tmp")
27209 } ||
27210 {
27211 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
27212 { (exit 1); exit 1; }
27213 }
27214
27215 EOF
27216
27217 cat >>"$CONFIG_STATUS" <<EOF
27218
27219 #
27220 # CONFIG_FILES section.
27221 #
27222
27223 # No need to generate the scripts if there are no CONFIG_FILES.
27224 # This happens for instance when ./config.status config.h
27225 if test -n "\$CONFIG_FILES"; then
27226 # Protect against being on the right side of a sed subst in config.status.
27227 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
27228 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >"\$tmp"/subs.sed <<\\CEOF
27229 s,@SHELL@,$SHELL,;t t
27230 s,@exec_prefix@,$exec_prefix,;t t
27231 s,@prefix@,$prefix,;t t
27232 s,@program_transform_name@,$program_transform_name,;t t
27233 s,@bindir@,$bindir,;t t
27234 s,@sbindir@,$sbindir,;t t
27235 s,@libexecdir@,$libexecdir,;t t
27236 s,@datarootdir@,$datarootdir,;t t
27237 s,@datadir@,$datadir,;t t
27238 s,@sysconfdir@,$sysconfdir,;t t
27239 s,@sharedstatedir@,$sharedstatedir,;t t
27240 s,@localstatedir@,$localstatedir,;t t
27241 s,@runstatedir@,$runstatedir,;t t
27242 s,@libdir@,$libdir,;t t
27243 s,@includedir@,$includedir,;t t
27244 s,@oldincludedir@,$oldincludedir,;t t
27245 s,@infodir@,$infodir,;t t
27246 s,@mandir@,$mandir,;t t
27247 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
27248 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
27249 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
27250 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
27251 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
27252 s,@build_alias@,$build_alias,;t t
27253 s,@host_alias@,$host_alias,;t t
27254 s,@target_alias@,$target_alias,;t t
27255 s,@ECHO_C@,$ECHO_C,;t t
27256 s,@ECHO_N@,$ECHO_N,;t t
27257 s,@ECHO_T@,$ECHO_T,;t t
27258 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
27259 s,@DEFS@,$DEFS,;t t
27260 s,@LIBS@,$LIBS,;t t
27261 s,@build@,$build,;t t
27262 s,@build_cpu@,$build_cpu,;t t
27263 s,@build_vendor@,$build_vendor,;t t
27264 s,@build_os@,$build_os,;t t
27265 s,@host@,$host,;t t
27266 s,@host_cpu@,$host_cpu,;t t
27267 s,@host_vendor@,$host_vendor,;t t
27268 s,@host_os@,$host_os,;t t
27269 s,@CC@,$CC,;t t
27270 s,@CFLAGS@,$CFLAGS,;t t
27271 s,@LDFLAGS@,$LDFLAGS,;t t
27272 s,@CPPFLAGS@,$CPPFLAGS,;t t
27273 s,@ac_ct_CC@,$ac_ct_CC,;t t
27274 s,@EXEEXT@,$EXEEXT,;t t
27275 s,@OBJEXT@,$OBJEXT,;t t
27276 s,@EXTRA_CPPFLAGS@,$EXTRA_CPPFLAGS,;t t
27277 s,@CPP@,$CPP,;t t
27278 s,@GREP@,$GREP,;t t
27279 s,@EGREP@,$EGREP,;t t
27280 s,@AWK@,$AWK,;t t
27281 s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
27282 s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
27283 s,@INSTALL_DATA@,$INSTALL_DATA,;t t
27284 s,@target@,$target,;t t
27285 s,@target_cpu@,$target_cpu,;t t
27286 s,@target_vendor@,$target_vendor,;t t
27287 s,@target_os@,$target_os,;t t
27288 s,@GLOB_FULLPATH_POSIX@,$GLOB_FULLPATH_POSIX,;t t
27289 s,@GLOB_FULLPATH_OTHER@,$GLOB_FULLPATH_OTHER,;t t
27290 s,@LN_S@,$LN_S,;t t
27291 s,@LINT@,$LINT,;t t
27292 s,@LINT_OPTS@,$LINT_OPTS,;t t
27293 s,@LINT_LIBS@,$LINT_LIBS,;t t
27294 s,@MAKE_NO_PHONY@,$MAKE_NO_PHONY,;t t
27295 s,@MAKE_PHONY@,$MAKE_PHONY,;t t
27296 s,@APP_CLASS@,$APP_CLASS,;t t
27297 s,@APPSDIR@,$APPSDIR,;t t
27298 s,@no_appsdir@,$no_appsdir,;t t
27299 s,@ICON_NAME@,$ICON_NAME,;t t
27300 s,@ICON_SYMLINK@,$ICON_SYMLINK,;t t
27301 s,@PIXMAPDIR@,$PIXMAPDIR,;t t
27302 s,@no_pixmapdir@,$no_pixmapdir,;t t
27303 s,@ICONDIR@,$ICONDIR,;t t
27304 s,@no_icondir@,$no_icondir,;t t
27305 s,@ICON_FORMAT@,$ICON_FORMAT,;t t
27306 s,@ICON_THEME@,$ICON_THEME,;t t
27307 s,@ICON_LIST@,$ICON_LIST,;t t
27308 s,@desktop_utils@,$desktop_utils,;t t
27309 s,@DESKTOP_FLAGS@,$DESKTOP_FLAGS,;t t
27310 s,@DESKTOP_CATEGORY@,$DESKTOP_CATEGORY,;t t
27311 s,@XTERM_PATH@,$XTERM_PATH,;t t
27312 s,@XTERM_SYMLINK@,$XTERM_SYMLINK,;t t
27313 s,@SINSTALL_OPTS@,$SINSTALL_OPTS,;t t
27314 s,@UTMP_NAME@,$UTMP_NAME,;t t
27315 s,@UTMP_PATH@,$UTMP_PATH,;t t
27316 s,@WTMP_NAME@,$WTMP_NAME,;t t
27317 s,@WTMP_PATH@,$WTMP_PATH,;t t
27318 s,@X_CFLAGS@,$X_CFLAGS,;t t
27319 s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
27320 s,@X_LIBS@,$X_LIBS,;t t
27321 s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
27322 s,@PKG_CONFIG@,$PKG_CONFIG,;t t
27323 s,@ac_pt_PKG_CONFIG@,$ac_pt_PKG_CONFIG,;t t
27324 s,@REQUIRE_PKG@,$REQUIRE_PKG,;t t
27325 s,@ICON_SUFFIX@,$ICON_SUFFIX,;t t
27326 s,@IMAKE@,$IMAKE,;t t
27327 s,@IMAKE_CFLAGS@,$IMAKE_CFLAGS,;t t
27328 s,@IMAKE_LOADFLAGS@,$IMAKE_LOADFLAGS,;t t
27329 s,@GROFF_PATH@,$GROFF_PATH,;t t
27330 s,@NROFF_PATH@,$NROFF_PATH,;t t
27331 s,@TBL_PATH@,$TBL_PATH,;t t
27332 s,@GROFF_NOTE@,$GROFF_NOTE,;t t
27333 s,@NROFF_NOTE@,$NROFF_NOTE,;t t
27334 s,@FGREP@,$FGREP,;t t
27335 s,@cf_man2html@,$cf_man2html,;t t
27336 s,@MAN2HTML_NOTE@,$MAN2HTML_NOTE,;t t
27337 s,@MAN2HTML_PATH@,$MAN2HTML_PATH,;t t
27338 s,@MAN2HTML_TEMP@,$MAN2HTML_TEMP,;t t
27339 s,@default_termid@,$default_termid,;t t
27340 s,@default_TERM@,$default_TERM,;t t
27341 s,@XTERM_KBS@,$XTERM_KBS,;t t
27342 s,@backarrow_is_bs@,$backarrow_is_bs,;t t
27343 s,@backarrow_is_erase@,$backarrow_is_erase,;t t
27344 s,@delete_is_del@,$delete_is_del,;t t
27345 s,@initial_erase@,$initial_erase,;t t
27346 s,@alt_sends_esc@,$alt_sends_esc,;t t
27347 s,@meta_sends_esc@,$meta_sends_esc,;t t
27348 s,@cf_tic_prog@,$cf_tic_prog,;t t
27349 s,@no_ticprog@,$no_ticprog,;t t
27350 s,@TERMINFO_DIR@,$TERMINFO_DIR,;t t
27351 s,@SET_TERMINFO@,$SET_TERMINFO,;t t
27352 s,@double_buffer@,$double_buffer,;t t
27353 s,@FREETYPE_CONFIG@,$FREETYPE_CONFIG,;t t
27354 s,@FREETYPE_OLD_CONFIG@,$FREETYPE_OLD_CONFIG,;t t
27355 s,@FREETYPE_XFT_CONFIG@,$FREETYPE_XFT_CONFIG,;t t
27356 s,@HAVE_TYPE_FCCHAR32@,$HAVE_TYPE_FCCHAR32,;t t
27357 s,@HAVE_TYPE_XFTCHARSPEC@,$HAVE_TYPE_XFTCHARSPEC,;t t
27358 s,@LUIT@,$LUIT,;t t
27359 s,@STRINGS_MAX@,$STRINGS_MAX,;t t
27360 s,@ECHO_LT@,$ECHO_LT,;t t
27361 s,@ECHO_LD@,$ECHO_LD,;t t
27362 s,@RULE_CC@,$RULE_CC,;t t
27363 s,@SHOW_CC@,$SHOW_CC,;t t
27364 s,@ECHO_CC@,$ECHO_CC,;t t
27365 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
27366 s,@HAVE_STDNORETURN_H@,$HAVE_STDNORETURN_H,;t t
27367 s,@STDC_NORETURN@,$STDC_NORETURN,;t t
27368 s,@CHARPROC_DEPS@,$CHARPROC_DEPS,;t t
27369 s,@EXTRAHDRS@,$EXTRAHDRS,;t t
27370 s,@EXTRASRCS@,$EXTRASRCS,;t t
27371 s,@EXTRAOBJS@,$EXTRAOBJS,;t t
27372 s,@MAY_SETUID@,$MAY_SETUID,;t t
27373 s,@NOT_SETUID@,$NOT_SETUID,;t t
27374 s,@CTAGS@,$CTAGS,;t t
27375 s,@ETAGS@,$ETAGS,;t t
27376 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
27377 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
27378 s,@cf_ldd_prog@,$cf_ldd_prog,;t t
27379 s,@EXTRA_LDFLAGS@,$EXTRA_LDFLAGS,;t t
27380 CEOF
27381
27382 EOF
27383
27384 cat >>"$CONFIG_STATUS" <<\EOF
27385 # Split the substitutions into bite-sized pieces for seds with
27386 # small command number limits, like on Digital OSF/1 and HP-UX.
27387 ac_max_sed_lines=48
27388 ac_sed_frag=1 # Number of current file.
27389 ac_beg=1 # First line for current file.
27390 ac_end=$ac_max_sed_lines # Line after last line for current file.
27391 ac_more_lines=:
27392 ac_sed_cmds=
27393 while "$ac_more_lines"; do
27394 if test "$ac_beg" -gt 1; then
27395 sed "1,${ac_beg}d; ${ac_end}q" "$tmp"/subs.sed >"$tmp"/subs.frag
27396 else
27397 sed "${ac_end}q" "$tmp"/subs.sed >"$tmp"/subs.frag
27398 fi
27399 if test ! -s "$tmp"/subs.frag; then
27400 ac_more_lines=false
27401 else
27402 # The purpose of the label and of the branching condition is to
27403 # speed up the sed processing (if there are no `@' at all, there
27404 # is no need to browse any of the substitutions).
27405 # These are the two extra sed commands mentioned above.
27406 (echo ':t
27407 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && sed -e 's/\\\\*$//g' -e 's/$/\\/' -e 's/;t t\\/;t t/' -e 't' -e '3,'$ac_max_sed_lines's/$/\\/' "$tmp"/subs.frag) >"$tmp"/subs-$ac_sed_frag.sed
27408 # It is possible to make a multiline substitution using escaped newlines.
27409 # Ensure that we do not split the substitution between script fragments.
27410 ac_BEG=$ac_end
27411 ac_END=`expr "$ac_end" + "$ac_max_sed_lines"`
27412 sed "1,${ac_BEG}d; ${ac_END}p; q" "$tmp"/subs.sed >"$tmp"/subs.next
27413 if test -s "$tmp"/subs.next; then
27414 grep '^s,@[^@,][^@,]*@,.*$' "$tmp"/subs.next | grep -v '^s,@.*;t t$' >"$tmp"/subs.edit
27415 if test ! -s "$tmp"/subs.edit; then
27416 grep "^s,@[^@,][^@,]*@,.*,;t t$" "$tmp"/subs.next >"$tmp"/subs.edit
27417 if test ! -s "$tmp"/subs.edit; then
27418 if test "$ac_beg" -gt 1; then
27419 ac_end=`expr "$ac_end" - 1`
27420 continue
27421 fi
27422 fi
27423 fi
27424 fi
27425
27426 if test -z "$ac_sed_cmds"; then
27427 ac_sed_cmds="sed -f \"$tmp\"/subs-$ac_sed_frag.sed"
27428 else
27429 ac_sed_cmds="$ac_sed_cmds | sed -f \"$tmp\"/subs-$ac_sed_frag.sed"
27430 fi
27431 ac_sed_frag=`expr "$ac_sed_frag" + 1`
27432 ac_beg=$ac_end
27433 ac_end=`expr "$ac_end" + "$ac_max_sed_lines"`
27434 fi
27435 done
27436 if test -z "$ac_sed_cmds"; then
27437 ac_sed_cmds="cat"
27438 fi
27439 fi # test -n "$CONFIG_FILES"
27440
27441 EOF
27442 cat >>"$CONFIG_STATUS" <<\EOF
27443 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
27444 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
27445 case "$ac_file" in
27446 - | *:- | *:-:* ) # input from stdin
27447 cat >"$tmp"/stdin
27448 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
27449 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
27450 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
27451 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
27452 * ) ac_file_in=$ac_file.in ;;
27453 esac
27454
27455 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
27456 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
27457 X"$ac_file" : 'X\(//\)[^/]' \| \
27458 X"$ac_file" : 'X\(//\)$' \| \
27459 X"$ac_file" : 'X\(/\)' \| \
27460 . : '\(.\)' 2>/dev/null ||
27461 echo X"$ac_file" |
27462 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
27463 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
27464 /^X\(\/\/\)$/{ s//\1/; q; }
27465 /^X\(\/\).*/{ s//\1/; q; }
27466 s/.*/./; q'`
27467 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
27468 { case "$ac_dir" in
27469 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
27470 *) as_incr_dir=.;;
27471 esac
27472 as_dummy="$ac_dir"
27473 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
27474 case $as_mkdir_dir in
27475 # Skip DOS drivespec
27476 ?:) as_incr_dir=$as_mkdir_dir ;;
27477 *)
27478 as_incr_dir=$as_incr_dir/$as_mkdir_dir
27479 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
27480 ;;
27481 esac
27482 done; }
27483
27484 ac_dir_suffix="/`echo "$ac_dir"|sed 's,^\./,,'`"
27485 # A "../" for each directory in $ac_dir_suffix.
27486 ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
27487 else
27488 ac_dir_suffix= ac_dots=
27489 fi
27490
27491 case "$srcdir" in
27492 .) ac_srcdir=.
27493 if test -z "$ac_dots"; then
27494 ac_top_srcdir=.
27495 else
27496 ac_top_srcdir=`echo "$ac_dots" | sed 's,/$,,'`
27497 fi ;;
27498 [\\/]* | ?:[\\/]* )
27499 ac_srcdir="$srcdir$ac_dir_suffix";
27500 ac_top_srcdir="$srcdir" ;;
27501 *) # Relative path.
27502 ac_srcdir="$ac_dots$srcdir$ac_dir_suffix"
27503 ac_top_srcdir="$ac_dots$srcdir" ;;
27504 esac
27505
27506 case $INSTALL in
27507 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
27508 *) ac_INSTALL=$ac_dots$INSTALL ;;
27509 esac
27510
27511 if test x"$ac_file" != x-; then
27512 { echo "$as_me:27512: creating $ac_file" >&5
27513 echo "$as_me: creating $ac_file" >&6;}
27514 rm -f "$ac_file"
27515 fi
27516 # Let's still pretend it is `configure' which instantiates (i.e., don't
27517 # use $as_me), people would be surprised to read:
27518 # /* config.h. Generated automatically by config.status. */
27519 configure_input="Generated automatically from `echo $ac_file_in |
27520 sed 's,.*/,,'` by configure."
27521
27522 # First look for the input files in the build tree, otherwise in the
27523 # src tree.
27524 ac_file_inputs=`IFS=:
27525 for f in $ac_file_in; do
27526 case $f in
27527 -) echo "$tmp"/stdin ;;
27528 [\\/$]*)
27529 # Absolute (can't be DOS-style, as IFS=:)
27530 test -f "$f" || { { echo "$as_me:27530: error: cannot find input file: $f" >&5
27531 echo "$as_me: error: cannot find input file: $f" >&2;}
27532 { (exit 1); exit 1; }; }
27533 echo "$f";;
27534 *) # Relative
27535 if test -f "$f"; then
27536 # Build tree
27537 echo "$f"
27538 elif test -f "$srcdir/$f"; then
27539 # Source tree
27540 echo "$srcdir/$f"
27541 else
27542 # /dev/null tree
27543 { { echo "$as_me:27543: error: cannot find input file: $f" >&5
27544 echo "$as_me: error: cannot find input file: $f" >&2;}
27545 { (exit 1); exit 1; }; }
27546 fi;;
27547 esac
27548 done` || { (exit 1); exit 1; }
27549 EOF
27550 cat >>"$CONFIG_STATUS" <<\EOF
27551 ac_warn_datarootdir=no
27552 if test x"$ac_file" != x-; then
27553 for ac_item in $ac_file_inputs
27554 do
27555 ac_seen=`grep '@\(datadir\|mandir\|infodir\)@' "$ac_item"`
27556 if test -n "$ac_seen"; then
27557 ac_used=`grep '@datarootdir@' "$ac_item"`
27558 if test -z "$ac_used"; then
27559 { echo "$as_me:27559: WARNING: datarootdir was used implicitly but not set:
27560 $ac_seen" >&5
27561 echo "$as_me: WARNING: datarootdir was used implicitly but not set:
27562 $ac_seen" >&2;}
27563 ac_warn_datarootdir=yes
27564 fi
27565 fi
27566 ac_seen=`grep '${datarootdir}' "$ac_item"`
27567 if test -n "$ac_seen"; then
27568 { echo "$as_me:27568: WARNING: datarootdir was used explicitly but not set:
27569 $ac_seen" >&5
27570 echo "$as_me: WARNING: datarootdir was used explicitly but not set:
27571 $ac_seen" >&2;}
27572 ac_warn_datarootdir=yes
27573 fi
27574 done
27575 fi
27576
27577 if test "x$ac_warn_datarootdir" = xyes; then
27578 ac_sed_cmds="$ac_sed_cmds | sed -e 's,@datarootdir@,\${prefix}/share,g' -e 's,\${datarootdir},\${prefix}/share,g'"
27579 fi
27580
27581 EOF
27582 cat >>"$CONFIG_STATUS" <<EOF
27583 sed "$ac_vpsub
27584 $extrasub
27585 EOF
27586 cat >>"$CONFIG_STATUS" <<\EOF
27587 :t
27588 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
27589 s,@configure_input@,$configure_input,;t t
27590 s,@srcdir@,$ac_srcdir,;t t
27591 s,@top_srcdir@,$ac_top_srcdir,;t t
27592 s,@INSTALL@,$ac_INSTALL,;t t
27593 " $ac_file_inputs | (eval "$ac_sed_cmds") >"$tmp"/out
27594 rm -f "$tmp"/stdin
27595 EOF
27596 test -n "${FGREP}" || FGREP="grep -F"
27597 test -n "${EGREP}" || EGREP="grep -E"
27598 cat >>"$CONFIG_STATUS" <<EOF
27599 test -n "\${FGREP}" || FGREP="$FGREP"
27600 test -n "\${EGREP}" || EGREP="$EGREP"
27601 EOF
27602 cat >>"$CONFIG_STATUS" <<\EOF
27603 if test x"$ac_file" != x-; then
27604 cp "$tmp/out" "$ac_file"
27605
27606 for ac_name in prefix exec_prefix datarootdir
27607 do
27608 ac_seen=`$FGREP -n '${'$ac_name'[:=].*}' "$ac_file"`
27609 if test -n "$ac_seen"; then
27610 ac_init=`$EGREP '[ ]*'$ac_name'[ ]*=' "$ac_file"`
27611 if test -z "$ac_init"; then
27612 ac_seen=`echo "$ac_seen" |sed -e 's,^,'"$ac_file"':,'`
27613 { echo "$as_me:27613: WARNING: Variable $ac_name is used but was not set:
27614 $ac_seen" >&5
27615 echo "$as_me: WARNING: Variable $ac_name is used but was not set:
27616 $ac_seen" >&2;}
27617 fi
27618 fi
27619 done
27620 $EGREP -n '@[a-z_][a-z_0-9]+@' "$ac_file" >"$tmp"/out
27621 $EGREP -n '@[A-Z_][A-Z_0-9]+@' "$ac_file" >>"$tmp"/out
27622 if test -s "$tmp"/out; then
27623 ac_seen=`sed -e 's,^,'"$ac_file"':,' < "$tmp"/out`
27624 { echo "$as_me:27624: WARNING: Some variables may not be substituted:
27625 $ac_seen" >&5
27626 echo "$as_me: WARNING: Some variables may not be substituted:
27627 $ac_seen" >&2;}
27628 fi
27629 else
27630 cat "$tmp"/out
27631 fi
27632 rm -f "$tmp"/out
27633
27634 done
27635 EOF
27636 cat >>"$CONFIG_STATUS" <<\EOF
27637
27638 #
27639 # CONFIG_HEADER section.
27640 #
27641
27642 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
27643 # NAME is the cpp macro being defined and VALUE is the value it is being given.
27644 #
27645 # ac_d sets the value in "#define NAME VALUE" lines.
27646 ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
27647 ac_dB='[ ].*$,\1#\2'
27648 ac_dC=' '
27649 ac_dD=',;t'
27650 # ac_i turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
27651 ac_iA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
27652 ac_iB='\([ ]\),\1#\2define\3'
27653 ac_iC=' '
27654 ac_iD='\4,;t'
27655 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
27656 ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
27657 ac_uB='$,\1#\2define\3'
27658 ac_uC=' '
27659 ac_uD=',;t'
27660
27661 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
27662 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
27663 case "$ac_file" in
27664 - | *:- | *:-:* ) # input from stdin
27665 cat >"$tmp"/stdin
27666 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
27667 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
27668 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
27669 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
27670 * ) ac_file_in=$ac_file.in ;;
27671 esac
27672
27673 test x"$ac_file" != x- && { echo "$as_me:27673: creating $ac_file" >&5
27674 echo "$as_me: creating $ac_file" >&6;}
27675
27676 # First look for the input files in the build tree, otherwise in the
27677 # src tree.
27678 ac_file_inputs=`IFS=:
27679 for f in $ac_file_in; do
27680 case $f in
27681 -) echo "$tmp"/stdin ;;
27682 [\\/$]*)
27683 # Absolute (can't be DOS-style, as IFS=:)
27684 test -f "$f" || { { echo "$as_me:27684: error: cannot find input file: $f" >&5
27685 echo "$as_me: error: cannot find input file: $f" >&2;}
27686 { (exit 1); exit 1; }; }
27687 echo $f;;
27688 *) # Relative
27689 if test -f "$f"; then
27690 # Build tree
27691 echo $f
27692 elif test -f "$srcdir/$f"; then
27693 # Source tree
27694 echo "$srcdir/$f"
27695 else
27696 # /dev/null tree
27697 { { echo "$as_me:27697: error: cannot find input file: $f" >&5
27698 echo "$as_me: error: cannot find input file: $f" >&2;}
27699 { (exit 1); exit 1; }; }
27700 fi;;
27701 esac
27702 done` || { (exit 1); exit 1; }
27703 # Remove the trailing spaces.
27704 sed 's/[ ]*$//' $ac_file_inputs >"$tmp"/in
27705
27706 EOF
27707
27708 # Transform confdefs.h into two sed scripts, `conftest.defines' and
27709 # `conftest.undefs', that substitutes the proper values into
27710 # config.h.in to produce config.h. The first handles `#define'
27711 # templates, and the second `#undef' templates.
27712 # And first: Protect against being on the right side of a sed subst in
27713 # config.status. Protect against being in an unquoted here document
27714 # in config.status.
27715 rm -f conftest.defines conftest.undefs
27716 # Using a here document instead of a string reduces the quoting nightmare.
27717 # Putting comments in sed scripts is not portable.
27718 #
27719 # `end' is used to avoid that the second main sed command (meant for
27720 # 0-ary CPP macros) applies to n-ary macro definitions.
27721 # See the Autoconf documentation for `clear'.
27722 cat >confdef2sed.sed <<\EOF
27723 s/[\\&,]/\\&/g
27724 s,[\\$`],\\&,g
27725 t clear
27726 : clear
27727 s,^[ ]*#[ ]*define[ ][ ]*\(\([^ (][^ (]*\)([^)]*)\)[ ]*\(.*\)$,${ac_dA}\2${ac_dB}\1${ac_dC}\3${ac_dD},gp
27728 t end
27729 s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
27730 : end
27731 EOF
27732 # If some macros were called several times there might be several times
27733 # the same #defines, which is useless. Nevertheless, we may not want to
27734 # sort them, since we want the *last* AC-DEFINE to be honored.
27735 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
27736 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
27737 sed 's/ac_d/ac_i/g' conftest.defines >>conftest.undefs
27738 rm -f confdef2sed.sed
27739
27740 # This sed command replaces #undef with comments. This is necessary, for
27741 # example, in the case of _POSIX_SOURCE, which is predefined and required
27742 # on some systems where configure will not decide to define it.
27743 cat >>conftest.undefs <<\EOF
27744 s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
27745 EOF
27746
27747 # Break up conftest.defines because some shells have a limit on the size
27748 # of here documents, and old seds have small limits too (100 cmds).
27749 echo ' # Handle all the #define templates only if necessary.' >>"$CONFIG_STATUS"
27750 echo ' test -n "${EGREP}" || EGREP="grep -E"' >>"$CONFIG_STATUS"
27751 echo ' if ${EGREP} "^[ ]*#[ ]*define" "$tmp"/in >/dev/null; then' >>"$CONFIG_STATUS"
27752 echo ' # If there are no defines, we may have an empty if/fi' >>"$CONFIG_STATUS"
27753 echo ' :' >>"$CONFIG_STATUS"
27754 rm -f conftest.tail
27755 while grep . conftest.defines >/dev/null
27756 do
27757 # Write a limited-size here document to "$tmp"/defines.sed.
27758 echo ' cat >"$tmp"/defines.sed <<CEOF' >>"$CONFIG_STATUS"
27759 # Speed up: don't consider the non `#define' lines.
27760 echo '/^[ ]*#[ ]*define/!b' >>"$CONFIG_STATUS"
27761 # Work around the forget-to-reset-the-flag bug.
27762 echo 't clr' >>"$CONFIG_STATUS"
27763 echo ': clr' >>"$CONFIG_STATUS"
27764 sed "${ac_max_here_lines}q" conftest.defines >>"$CONFIG_STATUS"
27765 echo 'CEOF
27766 sed -f "$tmp"/defines.sed "$tmp"/in >"$tmp"/out
27767 rm -f "$tmp"/in
27768 mv "$tmp"/out "$tmp"/in
27769 ' >>"$CONFIG_STATUS"
27770 sed "1,${ac_max_here_lines}d" conftest.defines >conftest.tail
27771 rm -f conftest.defines
27772 mv conftest.tail conftest.defines
27773 done
27774 rm -f conftest.defines
27775 echo ' fi # grep' >>"$CONFIG_STATUS"
27776 echo >>"$CONFIG_STATUS"
27777
27778 # Break up conftest.undefs because some shells have a limit on the size
27779 # of here documents, and old seds have small limits too (100 cmds).
27780 echo ' # Handle all the #undef templates' >>"$CONFIG_STATUS"
27781 rm -f conftest.tail
27782 while grep . conftest.undefs >/dev/null
27783 do
27784 # Write a limited-size here document to "$tmp"/undefs.sed.
27785 echo ' cat >"$tmp"/undefs.sed <<CEOF' >>"$CONFIG_STATUS"
27786 # Speed up: don't consider the non `#undef'
27787 echo '/^[ ]*#[ ]*undef/!b' >>"$CONFIG_STATUS"
27788 # Work around the forget-to-reset-the-flag bug.
27789 echo 't clr' >>"$CONFIG_STATUS"
27790 echo ': clr' >>"$CONFIG_STATUS"
27791 sed "${ac_max_here_lines}q" conftest.undefs >>"$CONFIG_STATUS"
27792 echo 'CEOF
27793 sed -f "$tmp"/undefs.sed "$tmp"/in >"$tmp"/out
27794 rm -f "$tmp"/in
27795 mv "$tmp"/out "$tmp"/in
27796 ' >>"$CONFIG_STATUS"
27797 sed "1,${ac_max_here_lines}d" conftest.undefs >conftest.tail
27798 rm -f conftest.undefs
27799 mv conftest.tail conftest.undefs
27800 done
27801 rm -f conftest.undefs
27802
27803 cat >>"$CONFIG_STATUS" <<\EOF
27804 # Let's still pretend it is `configure' which instantiates (i.e., don't
27805 # use $as_me), people would be surprised to read:
27806 # /* config.h. Generated automatically by config.status. */
27807 if test x"$ac_file" = x-; then
27808 echo "/* Generated automatically by configure. */" >"$tmp"/config.h
27809 else
27810 echo "/* $ac_file. Generated automatically by configure. */" >"$tmp"/config.h
27811 fi
27812 cat "$tmp"/in >>"$tmp"/config.h
27813 rm -f "$tmp"/in
27814 if test x"$ac_file" != x-; then
27815 if cmp -s "$ac_file" "$tmp/config.h" 2>/dev/null; then
27816 { echo "$as_me:27816: $ac_file is unchanged" >&5
27817 echo "$as_me: $ac_file is unchanged" >&6;}
27818 else
27819 ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
27820 X"$ac_file" : 'X\(//\)[^/]' \| \
27821 X"$ac_file" : 'X\(//\)$' \| \
27822 X"$ac_file" : 'X\(/\)' \| \
27823 . : '\(.\)' 2>/dev/null ||
27824 echo X"$ac_file" |
27825 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
27826 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
27827 /^X\(\/\/\)$/{ s//\1/; q; }
27828 /^X\(\/\).*/{ s//\1/; q; }
27829 s/.*/./; q'`
27830 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
27831 { case "$ac_dir" in
27832 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
27833 *) as_incr_dir=.;;
27834 esac
27835 as_dummy="$ac_dir"
27836 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
27837 case $as_mkdir_dir in
27838 # Skip DOS drivespec
27839 ?:) as_incr_dir=$as_mkdir_dir ;;
27840 *)
27841 as_incr_dir=$as_incr_dir/$as_mkdir_dir
27842 test -d "$as_incr_dir" || mkdir "$as_incr_dir"
27843 ;;
27844 esac
27845 done; }
27846
27847 fi
27848 rm -f "$ac_file"
27849 mv "$tmp/config.h" "$ac_file"
27850 fi
27851 else
27852 cat "$tmp"/config.h
27853 rm -f "$tmp"/config.h
27854 fi
27855 done
27856 EOF
27857
27858 cat >>"$CONFIG_STATUS" <<\EOF
27859
27860 { (exit 0); exit 0; }
27861 EOF
27862 chmod +x "$CONFIG_STATUS"
27863 ac_clean_files=$ac_clean_files_save
27864
27865 # configure is writing to config.log, and then calls config.status.
27866 # config.status does its own redirection, appending to config.log.
27867 # Unfortunately, on DOS this fails, as config.log is still kept open
27868 # by configure, so config.status won't be able to write to it; its
27869 # output is simply discarded. So we exec the FD to /dev/null,
27870 # effectively closing config.log, so it can be properly (re)opened and
27871 # appended to by config.status. When coming back to configure, we
27872 # need to make the FD available again.
27873 if test "$no_create" != yes; then
27874 ac_cs_success=:
27875 exec 5>/dev/null
27876 $SHELL "$CONFIG_STATUS" || ac_cs_success=false
27877 exec 5>>config.log
27878 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
27879 # would make configure fail if this is the last instruction.
27880 "$ac_cs_success" || { (exit 1); exit 1; }
27881 fi
27882