3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated automatically using autoconf version 2.12
5 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
12 ac_default_prefix=/usr/local
13 # Any additions from configure.in:
17 --enable-subdir=DIR Put the demo programs in a subdirectory of \`bindir',
18 instead of putting them in bindir itself. You can
19 specify the name of the subdirectory. For example,
20 --exec-prefix=/usr/local/bin --enable-subdir=demos
21 would put xscreensaver in /usr/local/bin/, and would
22 put the demos in /usr/local/bin/demos/. (If DIR
23 begins with /, then bindir will not be prepended.)
25 --disable-subdir Just put the demos in \`bindir' (this is the default.)
29 Except where noted, all of the --with options below can also take a
30 directory argument: for example, --with-motif=/opt/Motif. That would
31 cause /opt/Motif/include/ to be added to the -I list, and /opt/Motif/lib/
32 to be added to the -L list, assuming those directories exist.
34 X Server Extension options:
36 --with-sgi-ext Include support for the SGI SCREEN_SAVER
37 server extension, if possible (this is the default).
38 --without-sgi-ext Do not compile in support for this extension."
40 --with-mit-ext Include support for the MIT-SCREEN-SAVER
41 server extension, if possible (this is the default).
42 --without-mit-ext Do not compile in support for this extension."
44 --with-xidle-ext Include support for the XIDLE server extension,
45 if possible (this is the default).
46 --without-xidle-ext Do not compile in support for this extension."
48 --with-xshm-ext Include support for the XSHM (Shared Memory) server
49 extension, if possible (this is the default).
50 --without-xshm-ext Do not compile in support for this extension."
52 --with-sgivc-ext Include support for the SGI-VIDEO-CONTROL server
53 extension, if possible (this is the default).
54 --without-sgivc-ext Do not compile in support for this extension."
56 --with-dpms-ext Include support for the DPMS server extension,
57 if possible (this is the default).
58 --without-dpms-ext Do not compile in support for this extension."
61 X Client Toolkit options:
63 --with-motif Use the Motif toolkit for the user interface, if
64 possible (this is the default).
65 --without-motif Do not use Motif."
67 --with-athena Use the Athena toolkit for the user interface, if
68 possible (this is the default if Motif isn't used.)
69 --without-athena Do not use Athena."
72 Graphics Demo options:
74 --with-xpm Include support for XPM files in some demos,
75 if possible (this is the default).
76 --without-xpm Do not compile in support for XPM files."
78 --with-gl Build those demos which depend on OpenGL,
79 if possible (this is the default).
80 --without-gl Do not build the OpenGL demos."
82 --with-readdisplay Include support for the XReadDisplay server
83 extension if possible (this is the default).
84 --without-readdisplay Do not compile in support for this extension."
86 --with-sgivideo Include support for SGI's Iris Video Library
87 if possible (this is the default).
88 --without-sgivideo Do not compile in support for this library."
90 --with-zippy=PROGRAM Some demos are able to run an external program and
91 display its text; this names the program to use by
92 default (though it can be overridden with X
93 resources.) If you don't specify this, the default
94 is to use \"yow\" from the Emacs distribution (if you
95 have it) or else to use \"fortune\"."
98 Screen Locking options:
100 --enable-locking Compile in support for locking the display
101 (this is the default.)
102 --disable-locking Do not allow locking at all."
105 --with-kerberos Include support for Kerberos authentication,
106 if possible (this is the default.)
107 --without-kerberos Do not compile in support for Kerberos."
109 --with-shadow Include support for shadow password authentication,
110 if possible (this is the default, if no Kerberos.)
111 --without-shadow Do not compile in support for shadow passwords.
114 # Initialize some variables set by options.
115 # The variables have the same names as the options, with
116 # dashes changed to underlines.
118 cache_file=./config.cache
127 program_transform_name=s,x,x,
135 bindir='${exec_prefix}/bin'
136 sbindir='${exec_prefix}/sbin'
137 libexecdir='${exec_prefix}/libexec'
138 datadir='${prefix}/share'
139 sysconfdir='${prefix}/etc'
140 sharedstatedir='${prefix}/com'
141 localstatedir='${prefix}/var'
142 libdir='${exec_prefix}/lib'
143 includedir='${prefix}/include'
144 oldincludedir='/usr/include'
145 infodir='${prefix}/info'
146 mandir='${prefix}/man'
148 # Initialize some other variables.
151 # Maximum number of lines to put in a shell here document.
158 # If the previous option needs an argument, assign it.
159 if test -n "$ac_prev"; then
160 eval "$ac_prev=\$ac_option"
166 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
170 # Accept the important Cygnus configure options, so we can diagnose typos.
174 -bindir | --bindir | --bindi | --bind | --bin | --bi)
176 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
177 bindir="$ac_optarg" ;;
179 -build | --build | --buil | --bui | --bu)
181 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
182 build="$ac_optarg" ;;
184 -cache-file | --cache-file | --cache-fil | --cache-fi \
185 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
186 ac_prev=cache_file ;;
187 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
188 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
189 cache_file="$ac_optarg" ;;
191 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
193 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
195 datadir="$ac_optarg" ;;
197 -disable-* | --disable-*)
198 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
199 # Reject names that are not valid shell variable names.
200 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
201 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
203 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
204 eval "enable_${ac_feature}=no" ;;
206 -enable-* | --enable-*)
207 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
208 # Reject names that are not valid shell variable names.
209 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
210 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
212 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
217 eval "enable_${ac_feature}='$ac_optarg'" ;;
219 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
220 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
221 | --exec | --exe | --ex)
222 ac_prev=exec_prefix ;;
223 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
224 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
225 | --exec=* | --exe=* | --ex=*)
226 exec_prefix="$ac_optarg" ;;
228 -gas | --gas | --ga | --g)
229 # Obsolete; use --with-gas.
232 -help | --help | --hel | --he)
233 # Omit some internal or obsolete options to make the list less imposing.
234 # This message is too long to be a string in the A/UX 3.1 sh.
236 Usage: configure [options] [host]
237 Options: [defaults in brackets after descriptions]
241 --cache-file=FILE cache test results in FILE
242 --help print this message
243 --no-create do not create output files
244 --quiet, --silent do not print \`checking...' messages
245 --version print the version of autoconf that created configure
247 Directory and file names:
249 --prefix=PREFIX install architecture-independent files in PREFIX
251 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
253 --bindir=DIR user executables in DIR [EPREFIX/bin]
254 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
255 --includedir=DIR C header files in DIR [PREFIX/include]
256 --x-includes=DIR X include files are in DIR
257 --x-libraries=DIR X library files are in DIR
258 --mandir=DIR man documentation in DIR [PREFIX/man]
259 --srcdir=DIR find the sources in DIR [configure dir or ..]
260 --program-prefix=PREFIX prepend PREFIX to installed program names
261 --program-suffix=SUFFIX append SUFFIX to installed program names
262 --program-transform-name=PROGRAM
263 run sed PROGRAM on installed program names
269 --build=BUILD configure for building on BUILD [BUILD=HOST]
270 --host=HOST configure for HOST [guessed]
271 --target=TARGET configure for TARGET [TARGET=HOST]
273 if test -n "$ac_help"; then
278 -host | --host | --hos | --ho)
280 -host=* | --host=* | --hos=* | --ho=*)
283 -includedir | --includedir | --includedi | --included | --include \
284 | --includ | --inclu | --incl | --inc)
285 ac_prev=includedir ;;
286 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
287 | --includ=* | --inclu=* | --incl=* | --inc=*)
288 includedir="$ac_optarg" ;;
290 -infodir | --infodir | --infodi | --infod | --info | --inf)
292 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
293 infodir="$ac_optarg" ;;
295 -libdir | --libdir | --libdi | --libd)
297 -libdir=* | --libdir=* | --libdi=* | --libd=*)
298 libdir="$ac_optarg" ;;
300 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
301 | --libexe | --libex | --libe)
302 ac_prev=libexecdir ;;
303 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
304 | --libexe=* | --libex=* | --libe=*)
305 libexecdir="$ac_optarg" ;;
307 -localstatedir | --localstatedir | --localstatedi | --localstated \
308 | --localstate | --localstat | --localsta | --localst \
309 | --locals | --local | --loca | --loc | --lo)
310 ac_prev=localstatedir ;;
311 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
312 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
313 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
314 localstatedir="$ac_optarg" ;;
316 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
318 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
319 mandir="$ac_optarg" ;;
322 # Obsolete; use --without-fp.
325 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
329 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
330 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
333 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
334 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
335 | --oldin | --oldi | --old | --ol | --o)
336 ac_prev=oldincludedir ;;
337 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
338 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
339 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
340 oldincludedir="$ac_optarg" ;;
342 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
344 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
345 prefix="$ac_optarg" ;;
347 -program-prefix | --program-prefix | --program-prefi | --program-pref \
348 | --program-pre | --program-pr | --program-p)
349 ac_prev=program_prefix ;;
350 -program-prefix=* | --program-prefix=* | --program-prefi=* \
351 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
352 program_prefix="$ac_optarg" ;;
354 -program-suffix | --program-suffix | --program-suffi | --program-suff \
355 | --program-suf | --program-su | --program-s)
356 ac_prev=program_suffix ;;
357 -program-suffix=* | --program-suffix=* | --program-suffi=* \
358 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
359 program_suffix="$ac_optarg" ;;
361 -program-transform-name | --program-transform-name \
362 | --program-transform-nam | --program-transform-na \
363 | --program-transform-n | --program-transform- \
364 | --program-transform | --program-transfor \
365 | --program-transfo | --program-transf \
366 | --program-trans | --program-tran \
367 | --progr-tra | --program-tr | --program-t)
368 ac_prev=program_transform_name ;;
369 -program-transform-name=* | --program-transform-name=* \
370 | --program-transform-nam=* | --program-transform-na=* \
371 | --program-transform-n=* | --program-transform-=* \
372 | --program-transform=* | --program-transfor=* \
373 | --program-transfo=* | --program-transf=* \
374 | --program-trans=* | --program-tran=* \
375 | --progr-tra=* | --program-tr=* | --program-t=*)
376 program_transform_name="$ac_optarg" ;;
378 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
379 | -silent | --silent | --silen | --sile | --sil)
382 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
384 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
386 sbindir="$ac_optarg" ;;
388 -sharedstatedir | --sharedstatedir | --sharedstatedi \
389 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
390 | --sharedst | --shareds | --shared | --share | --shar \
392 ac_prev=sharedstatedir ;;
393 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
394 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
395 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
397 sharedstatedir="$ac_optarg" ;;
399 -site | --site | --sit)
401 -site=* | --site=* | --sit=*)
404 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
406 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
407 srcdir="$ac_optarg" ;;
409 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
410 | --syscon | --sysco | --sysc | --sys | --sy)
411 ac_prev=sysconfdir ;;
412 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
413 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
414 sysconfdir="$ac_optarg" ;;
416 -target | --target | --targe | --targ | --tar | --ta | --t)
418 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
419 target="$ac_optarg" ;;
421 -v | -verbose | --verbose | --verbos | --verbo | --verb)
424 -version | --version | --versio | --versi | --vers)
425 echo "configure generated by autoconf version 2.12"
429 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
430 # Reject names that are not valid shell variable names.
431 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
432 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
434 ac_package=`echo $ac_package| sed 's/-/_/g'`
439 eval "with_${ac_package}='$ac_optarg'" ;;
441 -without-* | --without-*)
442 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
443 # Reject names that are not valid shell variable names.
444 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
445 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
447 ac_package=`echo $ac_package| sed 's/-/_/g'`
448 eval "with_${ac_package}=no" ;;
451 # Obsolete; use --with-x.
454 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
455 | --x-incl | --x-inc | --x-in | --x-i)
456 ac_prev=x_includes ;;
457 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
458 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
459 x_includes="$ac_optarg" ;;
461 -x-libraries | --x-libraries | --x-librarie | --x-librari \
462 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
463 ac_prev=x_libraries ;;
464 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
465 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
466 x_libraries="$ac_optarg" ;;
468 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
472 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
473 echo "configure: warning: $ac_option: invalid host type" 1>&2
475 if test "x$nonopt" != xNONE; then
476 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
484 if test -n "$ac_prev"; then
485 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
488 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
490 # File descriptor usage:
493 # 2 errors and warnings
494 # 3 some systems may open it to /dev/tty
495 # 4 used on the Kubota Titan
496 # 6 checking for... messages and results
497 # 5 compiler messages saved in config.log
498 if test "$silent" = yes; then
506 This file contains any messages produced by compilers while
507 running configure, to aid debugging if configure makes a mistake.
510 # Strip out --no-create and --no-recursion so they do not pile up.
511 # Also quote any args containing shell metacharacters.
516 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
517 | --no-cr | --no-c) ;;
518 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
519 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
520 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
521 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
522 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
527 # Only set these to C if already set. These must not be set unconditionally
528 # because not all systems understand e.g. LANG=C (notably SCO).
529 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
530 # Non-C LC_CTYPE values break the ctype check.
531 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
532 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
533 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
534 if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
536 # confdefs.h avoids OS command line length limits that DEFS can exceed.
537 rm -rf conftest* confdefs.h
538 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
541 # A filename unique to this package, relative to the directory that
542 # configure is in, which we can look for to find out if srcdir is correct.
543 ac_unique_file=driver/subprocs.c
545 # Find the source files, if location was not specified.
546 if test -z "$srcdir"; then
547 ac_srcdir_defaulted=yes
548 # Try the directory containing this script, then its parent.
550 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
551 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
553 if test ! -r $srcdir/$ac_unique_file; then
557 ac_srcdir_defaulted=no
559 if test ! -r $srcdir/$ac_unique_file; then
560 if test "$ac_srcdir_defaulted" = yes; then
561 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
563 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
566 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
568 # Prefer explicitly selected file to automatically selected ones.
569 if test -z "$CONFIG_SITE"; then
570 if test "x$prefix" != xNONE; then
571 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
573 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
576 for ac_site_file in $CONFIG_SITE; do
577 if test -r "$ac_site_file"; then
578 echo "loading site script $ac_site_file"
583 if test -r "$cache_file"; then
584 echo "loading cache $cache_file"
587 echo "creating cache $cache_file"
592 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
593 ac_cpp='$CPP $CPPFLAGS'
594 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
595 ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
596 cross_compiling=$ac_cv_prog_cc_cross
598 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
599 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
600 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
607 ac_n= ac_c='\c' ac_t=
613 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
614 if test -f $ac_dir/install-sh; then
616 ac_install_sh="$ac_aux_dir/install-sh -c"
618 elif test -f $ac_dir/install.sh; then
620 ac_install_sh="$ac_aux_dir/install.sh -c"
624 if test -z "$ac_aux_dir"; then
625 { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
627 ac_config_guess=$ac_aux_dir/config.guess
628 ac_config_sub=$ac_aux_dir/config.sub
629 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
632 # Make sure we can run config.sub.
633 if $ac_config_sub sun4 >/dev/null 2>&1; then :
634 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
637 echo $ac_n "checking host system type""... $ac_c" 1>&6
638 echo "configure:650: checking host system type" >&5
641 case "$host_alias" in
645 if host_alias=`$ac_config_guess`; then :
646 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
648 *) host_alias=$nonopt ;;
652 host=`$ac_config_sub $host_alias`
653 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
654 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
655 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
656 echo "$ac_t""$host" 1>&6
659 # Extract the first word of "gcc", so it can be a program name with args.
660 set dummy gcc; ac_word=$2
661 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
662 echo "configure:674: checking for $ac_word" >&5
663 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
664 echo $ac_n "(cached) $ac_c" 1>&6
666 if test -n "$CC"; then
667 ac_cv_prog_CC="$CC" # Let the user override the test.
669 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
670 for ac_dir in $PATH; do
671 test -z "$ac_dir" && ac_dir=.
672 if test -f $ac_dir/$ac_word; then
681 if test -n "$CC"; then
682 echo "$ac_t""$CC" 1>&6
684 echo "$ac_t""no" 1>&6
687 if test -z "$CC"; then
688 # Extract the first word of "cc", so it can be a program name with args.
689 set dummy cc; ac_word=$2
690 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
691 echo "configure:703: checking for $ac_word" >&5
692 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
693 echo $ac_n "(cached) $ac_c" 1>&6
695 if test -n "$CC"; then
696 ac_cv_prog_CC="$CC" # Let the user override the test.
698 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
700 for ac_dir in $PATH; do
701 test -z "$ac_dir" && ac_dir=.
702 if test -f $ac_dir/$ac_word; then
703 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
712 if test $ac_prog_rejected = yes; then
713 # We found a bogon in the path, so make sure we never use it.
714 set dummy $ac_cv_prog_CC
716 if test $# -gt 0; then
717 # We chose a different compiler from the bogus one.
718 # However, it has the same basename, so the bogon will be chosen
719 # first if we set CC to just the basename; use the full file name.
721 set dummy "$ac_dir/$ac_word" "$@"
729 if test -n "$CC"; then
730 echo "$ac_t""$CC" 1>&6
732 echo "$ac_t""no" 1>&6
735 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
738 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
739 echo "configure:751: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
742 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
743 ac_cpp='$CPP $CPPFLAGS'
744 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
745 ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
746 cross_compiling=$ac_cv_prog_cc_cross
748 cat > conftest.$ac_ext <<EOF
749 #line 761 "configure"
750 #include "confdefs.h"
753 if { (eval echo configure:765: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
754 ac_cv_prog_cc_works=yes
755 # If we can't run a trivial program, we are probably using a cross compiler.
756 if (./conftest; exit) 2>/dev/null; then
757 ac_cv_prog_cc_cross=no
759 ac_cv_prog_cc_cross=yes
762 echo "configure: failed program was:" >&5
763 cat conftest.$ac_ext >&5
764 ac_cv_prog_cc_works=no
768 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
769 if test $ac_cv_prog_cc_works = no; then
770 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
772 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
773 echo "configure:785: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
774 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
775 cross_compiling=$ac_cv_prog_cc_cross
777 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
778 echo "configure:790: checking whether we are using GNU C" >&5
779 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
780 echo $ac_n "(cached) $ac_c" 1>&6
782 cat > conftest.c <<EOF
787 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:799: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
794 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
796 if test $ac_cv_prog_gcc = yes; then
798 ac_test_CFLAGS="${CFLAGS+set}"
799 ac_save_CFLAGS="$CFLAGS"
801 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
802 echo "configure:814: checking whether ${CC-cc} accepts -g" >&5
803 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
804 echo $ac_n "(cached) $ac_c" 1>&6
806 echo 'void f(){}' > conftest.c
807 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
816 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
817 if test "$ac_test_CFLAGS" = set; then
818 CFLAGS="$ac_save_CFLAGS"
819 elif test $ac_cv_prog_cc_g = yes; then
826 test "${CFLAGS+set}" = set || CFLAGS="-g"
830 if test -z "$GCC"; then
831 echo $ac_n "checking how to request ANSI compilation""... $ac_c" 1>&6
832 echo "configure:844: checking how to request ANSI compilation" >&5
835 echo "$ac_t""HPUX: adding -Ae" 1>&6
839 echo "$ac_t""AIX: adding -qlanglvl=ansi -qhalt=e" 1>&6
840 CC="$CC -qlanglvl=ansi -qhalt=e"
844 echo "$ac_t""DEC: adding -std1" 1>&6
849 echo "$ac_t""no idea" 1>&6
855 echo $ac_n "checking whether the compiler works on ANSI C""... $ac_c" 1>&6
856 echo "configure:868: checking whether the compiler works on ANSI C" >&5
857 if test "$cross_compiling" = yes; then
858 { echo "configure: error: Couldn't build even a trivial ANSI C program: check CC." 1>&2; exit 1; }
860 cat > conftest.$ac_ext <<EOF
861 #line 873 "configure"
862 #include "confdefs.h"
863 main(int ac, char **av) { return 0; }
865 if { (eval echo configure:877: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
867 echo "$ac_t""yes" 1>&6
869 echo "configure: failed program was:" >&5
870 cat conftest.$ac_ext >&5
872 echo "$ac_t""no" 1>&6
873 { echo "configure: error: Couldn't build even a trivial ANSI C program: check CC." 1>&2; exit 1; }
881 if test -n "$GCC"; then
882 echo "$ac_t""Turning on gcc compiler warnings." 1>&6
883 CC="$CC -Wall -Wstrict-prototypes -Wnested-externs -Wno-format"
886 echo "$ac_t""Turning on SGI compiler warnings." 1>&6
887 CC="$CC -fullwarn -use_readonly_const -rdata_shared -g3"
892 echo "$ac_t""Turning on gcc compiler warnings." 1>&6
893 CC="$CC -Wall -Wstrict-prototypes -Wnested-externs -Wno-format"
897 # if test -z "$GCC"; then
898 # AC_MSG_RESULT(Turning on DEC C compiler warnings.)
899 # CC="$CC -migrate -w0 -verbose -warnprotos"
906 # Try and determine whether ${INSTALL} can create intermediate directories,
907 # and if not, whether "mkdir -p" works instead. This sets ${INSTALL_DIRS}.
908 # (But autoconf should earn its keep and do this for us!)
913 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
914 echo "configure:926: checking how to run the C preprocessor" >&5
915 # On Suns, sometimes $CPP names a directory.
916 if test -n "$CPP" && test -d "$CPP"; then
919 if test -z "$CPP"; then
920 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
921 echo $ac_n "(cached) $ac_c" 1>&6
923 # This must be in double quotes, not single quotes, because CPP may get
924 # substituted into the Makefile and "${CC-cc}" will confuse make.
926 # On the NeXT, cc -E runs the code through the compiler's parser,
927 # not just through cpp.
928 cat > conftest.$ac_ext <<EOF
929 #line 941 "configure"
930 #include "confdefs.h"
934 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
935 { (eval echo configure:947: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
936 ac_err=`grep -v '^ *+' conftest.out`
937 if test -z "$ac_err"; then
941 echo "configure: failed program was:" >&5
942 cat conftest.$ac_ext >&5
944 CPP="${CC-cc} -E -traditional-cpp"
945 cat > conftest.$ac_ext <<EOF
946 #line 958 "configure"
947 #include "confdefs.h"
951 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
952 { (eval echo configure:964: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
953 ac_err=`grep -v '^ *+' conftest.out`
954 if test -z "$ac_err"; then
958 echo "configure: failed program was:" >&5
959 cat conftest.$ac_ext >&5
966 ac_cv_prog_CPP="$CPP"
968 CPP="$ac_cv_prog_CPP"
970 ac_cv_prog_CPP="$CPP"
972 echo "$ac_t""$CPP" 1>&6
974 # Find a good install program. We prefer a C program (faster),
975 # so one script is as good as another. But avoid the broken or
976 # incompatible versions:
977 # SysV /etc/install, /usr/sbin/install
978 # SunOS /usr/etc/install
981 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
982 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
983 # ./install, which can be erroneously created by make from ./install.sh.
984 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
985 echo "configure:997: checking for a BSD compatible install" >&5
986 if test -z "$INSTALL"; then
987 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
988 echo $ac_n "(cached) $ac_c" 1>&6
990 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="${IFS}:"
991 for ac_dir in $PATH; do
992 # Account for people who put trailing slashes in PATH elements.
994 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
996 # OSF1 and SCO ODT 3.0 have their own names for install.
997 for ac_prog in ginstall installbsd scoinst install; do
998 if test -f $ac_dir/$ac_prog; then
999 if test $ac_prog = install &&
1000 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1001 # AIX install. It has an incompatible calling convention.
1002 # OSF/1 installbsd also uses dspmsg, but is usable.
1005 ac_cv_path_install="$ac_dir/$ac_prog -c"
1016 if test "${ac_cv_path_install+set}" = set; then
1017 INSTALL="$ac_cv_path_install"
1019 # As a last resort, use the slow shell script. We don't cache a
1020 # path for INSTALL within a source directory, because that will
1021 # break other packages using the cache if that directory is
1022 # removed, or if the path is relative.
1023 INSTALL="$ac_install_sh"
1026 echo "$ac_t""$INSTALL" 1>&6
1028 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1029 # It thinks the first close brace ends the variable substitution.
1030 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1032 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1034 INSTALL_DIRS='${INSTALL} -d'
1035 echo $ac_n "checking whether \"\${INSTALL} -d\" creates intermediate directories""... $ac_c" 1>&6
1036 echo "configure:1048: checking whether \"\${INSTALL} -d\" creates intermediate directories" >&5
1038 if mkdir conftestdir; then
1041 ${INSTALL} -d `pwd`/dir1/dir2 >&- 2>&-
1042 if test -d dir1/dir2 ; then
1043 echo "$ac_t""yes" 1>&6
1045 echo "$ac_t""no" 1>&6
1046 echo $ac_n "checking whether \"mkdir -p\" creates intermediate directories""... $ac_c" 1>&6
1047 echo "configure:1059: checking whether \"mkdir -p\" creates intermediate directories" >&5
1049 mkdir -p dir1/dir2 >&- 2>&-
1050 if test -d dir1/dir2/. ; then
1051 echo "$ac_t""yes" 1>&6
1052 INSTALL_DIRS='mkdir -p'
1054 echo "$ac_t""no" 1>&6
1061 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
1062 echo "configure:1074: checking whether ${MAKE-make} sets \${MAKE}" >&5
1063 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
1064 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
1065 echo $ac_n "(cached) $ac_c" 1>&6
1067 cat > conftestmake <<\EOF
1069 @echo 'ac_maketemp="${MAKE}"'
1071 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1072 eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
1073 if test -n "$ac_maketemp"; then
1074 eval ac_cv_prog_make_${ac_make}_set=yes
1076 eval ac_cv_prog_make_${ac_make}_set=no
1080 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1081 echo "$ac_t""yes" 1>&6
1084 echo "$ac_t""no" 1>&6
1085 SET_MAKE="MAKE=${MAKE-make}"
1089 echo $ac_n "checking for working const""... $ac_c" 1>&6
1090 echo "configure:1102: checking for working const" >&5
1091 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
1092 echo $ac_n "(cached) $ac_c" 1>&6
1094 cat > conftest.$ac_ext <<EOF
1095 #line 1107 "configure"
1096 #include "confdefs.h"
1100 /* Ultrix mips cc rejects this. */
1101 typedef int charset[2]; const charset x;
1102 /* SunOS 4.1.1 cc rejects this. */
1103 char const *const *ccp;
1105 /* NEC SVR4.0.2 mips cc rejects this. */
1106 struct point {int x, y;};
1107 static struct point const zero = {0,0};
1108 /* AIX XL C 1.02.0.0 rejects this.
1109 It does not let you subtract one const X* pointer from another in an arm
1110 of an if-expression whose if-part is not a constant expression */
1111 const char *g = "string";
1112 ccp = &g + (g ? g-g : 0);
1113 /* HPUX 7.0 cc rejects these. */
1116 ccp = (char const *const *) p;
1117 { /* SCO 3.2v4 cc rejects this. */
1119 char const *s = 0 ? (char *) 0 : (char const *) 0;
1123 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
1125 const int *foo = &x[0];
1128 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
1129 typedef const int *iptr;
1133 { /* AIX XL C 1.02.0.0 rejects this saying
1134 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
1135 struct s { int j; const int *ap[3]; };
1136 struct s *b; b->j = 5;
1138 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
1144 if { (eval echo configure:1156: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1148 echo "configure: failed program was:" >&5
1149 cat conftest.$ac_ext >&5
1156 echo "$ac_t""$ac_cv_c_const" 1>&6
1157 if test $ac_cv_c_const = no; then
1158 cat >> confdefs.h <<\EOF
1164 echo $ac_n "checking for inline""... $ac_c" 1>&6
1165 echo "configure:1177: checking for inline" >&5
1166 if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
1167 echo $ac_n "(cached) $ac_c" 1>&6
1170 for ac_kw in inline __inline__ __inline; do
1171 cat > conftest.$ac_ext <<EOF
1172 #line 1184 "configure"
1173 #include "confdefs.h"
1179 if { (eval echo configure:1191: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1181 ac_cv_c_inline=$ac_kw; break
1183 echo "configure: failed program was:" >&5
1184 cat conftest.$ac_ext >&5
1191 echo "$ac_t""$ac_cv_c_inline" 1>&6
1192 case "$ac_cv_c_inline" in
1194 no) cat >> confdefs.h <<\EOF
1198 *) cat >> confdefs.h <<EOF
1199 #define inline $ac_cv_c_inline
1205 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
1206 echo "configure:1218: checking for ANSI C header files" >&5
1207 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1208 echo $ac_n "(cached) $ac_c" 1>&6
1210 cat > conftest.$ac_ext <<EOF
1211 #line 1223 "configure"
1212 #include "confdefs.h"
1218 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1219 { (eval echo configure:1231: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1220 ac_err=`grep -v '^ *+' conftest.out`
1221 if test -z "$ac_err"; then
1223 ac_cv_header_stdc=yes
1226 echo "configure: failed program was:" >&5
1227 cat conftest.$ac_ext >&5
1229 ac_cv_header_stdc=no
1233 if test $ac_cv_header_stdc = yes; then
1234 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1235 cat > conftest.$ac_ext <<EOF
1236 #line 1248 "configure"
1237 #include "confdefs.h"
1240 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1241 egrep "memchr" >/dev/null 2>&1; then
1245 ac_cv_header_stdc=no
1251 if test $ac_cv_header_stdc = yes; then
1252 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1253 cat > conftest.$ac_ext <<EOF
1254 #line 1266 "configure"
1255 #include "confdefs.h"
1258 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1259 egrep "free" >/dev/null 2>&1; then
1263 ac_cv_header_stdc=no
1269 if test $ac_cv_header_stdc = yes; then
1270 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1271 if test "$cross_compiling" = yes; then
1274 cat > conftest.$ac_ext <<EOF
1275 #line 1287 "configure"
1276 #include "confdefs.h"
1278 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1279 #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1280 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1281 int main () { int i; for (i = 0; i < 256; i++)
1282 if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1286 if { (eval echo configure:1298: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
1290 echo "configure: failed program was:" >&5
1291 cat conftest.$ac_ext >&5
1293 ac_cv_header_stdc=no
1301 echo "$ac_t""$ac_cv_header_stdc" 1>&6
1302 if test $ac_cv_header_stdc = yes; then
1303 cat >> confdefs.h <<\EOF
1304 #define STDC_HEADERS 1
1309 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
1310 echo "configure:1322: checking whether time.h and sys/time.h may both be included" >&5
1311 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
1312 echo $ac_n "(cached) $ac_c" 1>&6
1314 cat > conftest.$ac_ext <<EOF
1315 #line 1327 "configure"
1316 #include "confdefs.h"
1317 #include <sys/types.h>
1318 #include <sys/time.h>
1324 if { (eval echo configure:1336: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1326 ac_cv_header_time=yes
1328 echo "configure: failed program was:" >&5
1329 cat conftest.$ac_ext >&5
1331 ac_cv_header_time=no
1336 echo "$ac_t""$ac_cv_header_time" 1>&6
1337 if test $ac_cv_header_time = yes; then
1338 cat >> confdefs.h <<\EOF
1339 #define TIME_WITH_SYS_TIME 1
1344 echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
1345 echo "configure:1357: checking for sys/wait.h that is POSIX.1 compatible" >&5
1346 if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then
1347 echo $ac_n "(cached) $ac_c" 1>&6
1349 cat > conftest.$ac_ext <<EOF
1350 #line 1362 "configure"
1351 #include "confdefs.h"
1352 #include <sys/types.h>
1353 #include <sys/wait.h>
1355 #define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
1358 #define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
1363 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
1366 if { (eval echo configure:1378: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1368 ac_cv_header_sys_wait_h=yes
1370 echo "configure: failed program was:" >&5
1371 cat conftest.$ac_ext >&5
1373 ac_cv_header_sys_wait_h=no
1378 echo "$ac_t""$ac_cv_header_sys_wait_h" 1>&6
1379 if test $ac_cv_header_sys_wait_h = yes; then
1380 cat >> confdefs.h <<\EOF
1381 #define HAVE_SYS_WAIT_H 1
1387 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
1389 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1390 echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
1391 echo "configure:1403: checking for $ac_hdr that defines DIR" >&5
1392 if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
1393 echo $ac_n "(cached) $ac_c" 1>&6
1395 cat > conftest.$ac_ext <<EOF
1396 #line 1408 "configure"
1397 #include "confdefs.h"
1398 #include <sys/types.h>
1404 if { (eval echo configure:1416: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1406 eval "ac_cv_header_dirent_$ac_safe=yes"
1408 echo "configure: failed program was:" >&5
1409 cat conftest.$ac_ext >&5
1411 eval "ac_cv_header_dirent_$ac_safe=no"
1415 if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
1416 echo "$ac_t""yes" 1>&6
1417 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1418 cat >> confdefs.h <<EOF
1419 #define $ac_tr_hdr 1
1421 ac_header_dirent=$ac_hdr; break
1423 echo "$ac_t""no" 1>&6
1426 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
1427 if test $ac_header_dirent = dirent.h; then
1428 echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
1429 echo "configure:1441: checking for opendir in -ldir" >&5
1430 ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
1431 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1432 echo $ac_n "(cached) $ac_c" 1>&6
1434 ac_save_LIBS="$LIBS"
1436 cat > conftest.$ac_ext <<EOF
1437 #line 1449 "configure"
1438 #include "confdefs.h"
1439 /* Override any gcc2 internal prototype to avoid an error. */
1440 /* We use char because int might match the return type of a gcc2
1441 builtin and then its argument prototype would still apply. */
1448 if { (eval echo configure:1460: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1450 eval "ac_cv_lib_$ac_lib_var=yes"
1452 echo "configure: failed program was:" >&5
1453 cat conftest.$ac_ext >&5
1455 eval "ac_cv_lib_$ac_lib_var=no"
1458 LIBS="$ac_save_LIBS"
1461 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1462 echo "$ac_t""yes" 1>&6
1465 echo "$ac_t""no" 1>&6
1469 echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
1470 echo "configure:1482: checking for opendir in -lx" >&5
1471 ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
1472 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1473 echo $ac_n "(cached) $ac_c" 1>&6
1475 ac_save_LIBS="$LIBS"
1477 cat > conftest.$ac_ext <<EOF
1478 #line 1490 "configure"
1479 #include "confdefs.h"
1480 /* Override any gcc2 internal prototype to avoid an error. */
1481 /* We use char because int might match the return type of a gcc2
1482 builtin and then its argument prototype would still apply. */
1489 if { (eval echo configure:1501: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1491 eval "ac_cv_lib_$ac_lib_var=yes"
1493 echo "configure: failed program was:" >&5
1494 cat conftest.$ac_ext >&5
1496 eval "ac_cv_lib_$ac_lib_var=no"
1499 LIBS="$ac_save_LIBS"
1502 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1503 echo "$ac_t""yes" 1>&6
1506 echo "$ac_t""no" 1>&6
1512 echo $ac_n "checking for mode_t""... $ac_c" 1>&6
1513 echo "configure:1525: checking for mode_t" >&5
1514 if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then
1515 echo $ac_n "(cached) $ac_c" 1>&6
1517 cat > conftest.$ac_ext <<EOF
1518 #line 1530 "configure"
1519 #include "confdefs.h"
1520 #include <sys/types.h>
1526 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1527 egrep "mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
1529 ac_cv_type_mode_t=yes
1532 ac_cv_type_mode_t=no
1537 echo "$ac_t""$ac_cv_type_mode_t" 1>&6
1538 if test $ac_cv_type_mode_t = no; then
1539 cat >> confdefs.h <<\EOF
1545 echo $ac_n "checking for pid_t""... $ac_c" 1>&6
1546 echo "configure:1558: checking for pid_t" >&5
1547 if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
1548 echo $ac_n "(cached) $ac_c" 1>&6
1550 cat > conftest.$ac_ext <<EOF
1551 #line 1563 "configure"
1552 #include "confdefs.h"
1553 #include <sys/types.h>
1559 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1560 egrep "pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
1562 ac_cv_type_pid_t=yes
1570 echo "$ac_t""$ac_cv_type_pid_t" 1>&6
1571 if test $ac_cv_type_pid_t = no; then
1572 cat >> confdefs.h <<\EOF
1578 echo $ac_n "checking for size_t""... $ac_c" 1>&6
1579 echo "configure:1591: checking for size_t" >&5
1580 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
1581 echo $ac_n "(cached) $ac_c" 1>&6
1583 cat > conftest.$ac_ext <<EOF
1584 #line 1596 "configure"
1585 #include "confdefs.h"
1586 #include <sys/types.h>
1592 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1593 egrep "size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
1595 ac_cv_type_size_t=yes
1598 ac_cv_type_size_t=no
1603 echo "$ac_t""$ac_cv_type_size_t" 1>&6
1604 if test $ac_cv_type_size_t = no; then
1605 cat >> confdefs.h <<\EOF
1606 #define size_t unsigned
1611 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
1612 echo "configure:1624: checking return type of signal handlers" >&5
1613 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
1614 echo $ac_n "(cached) $ac_c" 1>&6
1616 cat > conftest.$ac_ext <<EOF
1617 #line 1629 "configure"
1618 #include "confdefs.h"
1619 #include <sys/types.h>
1625 extern "C" void (*signal (int, void (*)(int)))(int);
1627 void (*signal ()) ();
1634 if { (eval echo configure:1646: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1636 ac_cv_type_signal=void
1638 echo "configure: failed program was:" >&5
1639 cat conftest.$ac_ext >&5
1641 ac_cv_type_signal=int
1646 echo "$ac_t""$ac_cv_type_signal" 1>&6
1647 cat >> confdefs.h <<EOF
1648 #define RETSIGTYPE $ac_cv_type_signal
1653 echo $ac_n "checking how to call gettimeofday""... $ac_c" 1>&6
1654 echo "configure:1666: checking how to call gettimeofday" >&5
1655 if eval "test \"`echo '$''{'ac_cv_gettimeofday_args'+set}'`\" = set"; then
1656 echo $ac_n "(cached) $ac_c" 1>&6
1658 cat > conftest.$ac_ext <<EOF
1659 #line 1671 "configure"
1660 #include "confdefs.h"
1662 #include <sys/time.h>
1664 struct timeval tv; struct timezone tzp;
1665 gettimeofday(&tv, &tzp);
1668 if { (eval echo configure:1680: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1670 ac_gettimeofday_args=2
1672 echo "configure: failed program was:" >&5
1673 cat conftest.$ac_ext >&5
1675 cat > conftest.$ac_ext <<EOF
1676 #line 1688 "configure"
1677 #include "confdefs.h"
1679 #include <sys/time.h>
1681 struct timeval tv; gettimeofday(&tv);
1684 if { (eval echo configure:1696: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1686 ac_gettimeofday_args=1
1688 echo "configure: failed program was:" >&5
1689 cat conftest.$ac_ext >&5
1691 ac_gettimeofday_args=0
1696 ac_cv_gettimeofday_args=$ac_gettimeofday_args
1699 ac_gettimeofday_args=$ac_cv_gettimeofday_args
1700 if test $ac_gettimeofday_args = 1 ; then
1701 cat >> confdefs.h <<\EOF
1702 #define HAVE_GETTIMEOFDAY 1
1705 echo "$ac_t""one argument" 1>&6
1706 elif test $ac_gettimeofday_args = 2 ; then
1707 cat >> confdefs.h <<\EOF
1708 #define HAVE_GETTIMEOFDAY 1
1711 cat >> confdefs.h <<\EOF
1712 #define GETTIMEOFDAY_TWO_ARGS 1
1715 echo "$ac_t""two arguments" 1>&6
1717 echo "$ac_t""unknown" 1>&6
1721 for ac_func in select fcntl uname nice setpriority getcwd getwd putenv
1723 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1724 echo "configure:1736: checking for $ac_func" >&5
1725 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1726 echo $ac_n "(cached) $ac_c" 1>&6
1728 cat > conftest.$ac_ext <<EOF
1729 #line 1741 "configure"
1730 #include "confdefs.h"
1731 /* System header to define __stub macros and hopefully few prototypes,
1732 which can conflict with char $ac_func(); below. */
1734 /* Override any gcc2 internal prototype to avoid an error. */
1735 /* We use char because int might match the return type of a gcc2
1736 builtin and then its argument prototype would still apply. */
1741 /* The GNU C library defines this for functions which it implements
1742 to always fail with ENOSYS. Some functions are actually named
1743 something starting with __ and the normal name is an alias. */
1744 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1752 if { (eval echo configure:1764: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1754 eval "ac_cv_func_$ac_func=yes"
1756 echo "configure: failed program was:" >&5
1757 cat conftest.$ac_ext >&5
1759 eval "ac_cv_func_$ac_func=no"
1764 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1765 echo "$ac_t""yes" 1>&6
1766 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1767 cat >> confdefs.h <<EOF
1768 #define $ac_tr_func 1
1772 echo "$ac_t""no" 1>&6
1776 for ac_func in sigaction
1778 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1779 echo "configure:1791: checking for $ac_func" >&5
1780 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1781 echo $ac_n "(cached) $ac_c" 1>&6
1783 cat > conftest.$ac_ext <<EOF
1784 #line 1796 "configure"
1785 #include "confdefs.h"
1786 /* System header to define __stub macros and hopefully few prototypes,
1787 which can conflict with char $ac_func(); below. */
1789 /* Override any gcc2 internal prototype to avoid an error. */
1790 /* We use char because int might match the return type of a gcc2
1791 builtin and then its argument prototype would still apply. */
1796 /* The GNU C library defines this for functions which it implements
1797 to always fail with ENOSYS. Some functions are actually named
1798 something starting with __ and the normal name is an alias. */
1799 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1807 if { (eval echo configure:1819: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1809 eval "ac_cv_func_$ac_func=yes"
1811 echo "configure: failed program was:" >&5
1812 cat conftest.$ac_ext >&5
1814 eval "ac_cv_func_$ac_func=no"
1819 if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1820 echo "$ac_t""yes" 1>&6
1821 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1822 cat >> confdefs.h <<EOF
1823 #define $ac_tr_func 1
1827 echo "$ac_t""no" 1>&6
1832 for ac_hdr in unistd.h
1834 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1835 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1836 echo "configure:1848: checking for $ac_hdr" >&5
1837 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1838 echo $ac_n "(cached) $ac_c" 1>&6
1840 cat > conftest.$ac_ext <<EOF
1841 #line 1853 "configure"
1842 #include "confdefs.h"
1845 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1846 { (eval echo configure:1858: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1847 ac_err=`grep -v '^ *+' conftest.out`
1848 if test -z "$ac_err"; then
1850 eval "ac_cv_header_$ac_safe=yes"
1853 echo "configure: failed program was:" >&5
1854 cat conftest.$ac_ext >&5
1856 eval "ac_cv_header_$ac_safe=no"
1860 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1861 echo "$ac_t""yes" 1>&6
1862 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1863 cat >> confdefs.h <<EOF
1864 #define $ac_tr_hdr 1
1868 echo "$ac_t""no" 1>&6
1875 # Check whether --enable-subdir or --disable-subdir was given.
1876 if test "${enable_subdir+set}" = set; then
1877 enableval="$enable_subdir"
1878 enable_subdir="$enableval"
1883 if test x"$enable_subdir" = xno; then
1885 elif test x"$enable_subdir" = xyes -o x"$enable_subdir" = x ; then
1886 echo "error: must be a subdirectory name: --enable-subdir=$enable_subdir"
1889 # there must be a better way than this...
1890 if test -z "`echo $enable_subdir | sed 's@^/.*@@'`" ; then
1892 HACKDIR=$enable_subdir
1895 HACKDIR='${bindir}/'$enable_subdir
1900 # If we find X, set shell vars x_includes and x_libraries to the
1901 # paths, otherwise set no_x=yes.
1902 # Uses ac_ vars as temps to allow command line to override cache and checks.
1903 # --without-x overrides everything else, but does not touch the cache.
1904 echo $ac_n "checking for X""... $ac_c" 1>&6
1905 echo "configure:1917: checking for X" >&5
1907 # Check whether --with-x or --without-x was given.
1908 if test "${with_x+set}" = set; then
1913 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
1914 if test "x$with_x" = xno; then
1915 # The user explicitly disabled X.
1918 if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
1919 # Both variables are already set.
1922 if eval "test \"`echo '$''{'ac_cv_have_x'+set}'`\" = set"; then
1923 echo $ac_n "(cached) $ac_c" 1>&6
1925 # One or both of the vars are not set, and there is no cached value.
1926 ac_x_includes=NO ac_x_libraries=NO
1928 if mkdir conftestdir; then
1930 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
1931 cat > Imakefile <<'EOF'
1933 @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
1935 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
1936 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1937 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
1938 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
1939 for ac_extension in a so sl; do
1940 if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
1941 test -f $ac_im_libdir/libX11.$ac_extension; then
1942 ac_im_usrlibdir=$ac_im_libdir; break
1945 # Screen out bogus values from the imake configuration. They are
1946 # bogus both because they are the default anyway, and because
1947 # using them would break gcc on systems where it needs fixed includes.
1948 case "$ac_im_incroot" in
1950 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;;
1952 case "$ac_im_usrlibdir" in
1954 *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;;
1961 if test "$ac_x_includes" = NO; then
1962 # Guess where to find include files, by looking for this one X11 .h file.
1963 test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h
1965 # First, try using that file with no special directory specified.
1966 cat > conftest.$ac_ext <<EOF
1967 #line 1979 "configure"
1968 #include "confdefs.h"
1969 #include <$x_direct_test_include>
1971 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1972 { (eval echo configure:1984: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1973 ac_err=`grep -v '^ *+' conftest.out`
1974 if test -z "$ac_err"; then
1976 # We can compile using X headers with no special include directory.
1980 echo "configure: failed program was:" >&5
1981 cat conftest.$ac_ext >&5
1983 # Look for the header file in a standard set of common directories.
1984 # Check X11 before X11Rn because it is often a symlink to the current release.
1987 /usr/X11R6/include \
1988 /usr/X11R5/include \
1989 /usr/X11R4/include \
1992 /usr/include/X11R6 \
1993 /usr/include/X11R5 \
1994 /usr/include/X11R4 \
1996 /usr/local/X11/include \
1997 /usr/local/X11R6/include \
1998 /usr/local/X11R5/include \
1999 /usr/local/X11R4/include \
2001 /usr/local/include/X11 \
2002 /usr/local/include/X11R6 \
2003 /usr/local/include/X11R5 \
2004 /usr/local/include/X11R4 \
2008 /usr/XFree86/include/X11 \
2011 /usr/local/include \
2012 /usr/unsupported/include \
2013 /usr/athena/include \
2014 /usr/local/x11r5/include \
2015 /usr/lpp/Xamples/include \
2017 /usr/openwin/include \
2018 /usr/openwin/share/include \
2021 if test -r "$ac_dir/$x_direct_test_include"; then
2022 ac_x_includes=$ac_dir
2028 fi # $ac_x_includes = NO
2030 if test "$ac_x_libraries" = NO; then
2031 # Check for the libraries.
2033 test -z "$x_direct_test_library" && x_direct_test_library=Xt
2034 test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc
2036 # See if we find them without any special options.
2037 # Don't add to $LIBS permanently.
2038 ac_save_LIBS="$LIBS"
2039 LIBS="-l$x_direct_test_library $LIBS"
2040 cat > conftest.$ac_ext <<EOF
2041 #line 2053 "configure"
2042 #include "confdefs.h"
2045 ${x_direct_test_function}()
2048 if { (eval echo configure:2060: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2050 LIBS="$ac_save_LIBS"
2051 # We can link X programs with no special library path.
2054 echo "configure: failed program was:" >&5
2055 cat conftest.$ac_ext >&5
2057 LIBS="$ac_save_LIBS"
2058 # First see if replacing the include by lib works.
2059 # Check X11 before X11Rn because it is often a symlink to the current release.
2060 for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \
2071 /usr/local/X11/lib \
2072 /usr/local/X11R6/lib \
2073 /usr/local/X11R5/lib \
2074 /usr/local/X11R4/lib \
2076 /usr/local/lib/X11 \
2077 /usr/local/lib/X11R6 \
2078 /usr/local/lib/X11R5 \
2079 /usr/local/lib/X11R4 \
2083 /usr/XFree86/lib/X11 \
2087 /usr/unsupported/lib \
2089 /usr/local/x11r5/lib \
2090 /usr/lpp/Xamples/lib \
2094 /usr/openwin/share/lib \
2097 for ac_extension in a so sl; do
2098 if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then
2099 ac_x_libraries=$ac_dir
2106 fi # $ac_x_libraries = NO
2108 if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then
2109 # Didn't find X anywhere. Cache the known absence of X.
2110 ac_cv_have_x="have_x=no"
2112 # Record where we found X for the cache.
2113 ac_cv_have_x="have_x=yes \
2114 ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
2118 eval "$ac_cv_have_x"
2121 if test "$have_x" != yes; then
2122 echo "$ac_t""$have_x" 1>&6
2125 # If each of the values was on the command line, it overrides each guess.
2126 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
2127 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
2128 # Update the cache value to reflect the command line values.
2129 ac_cv_have_x="have_x=yes \
2130 ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
2131 echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6
2134 if test "$no_x" = yes; then
2135 # Not all programs may use this symbol, but it does not hurt to define it.
2136 cat >> confdefs.h <<\EOF
2137 #define X_DISPLAY_MISSING 1
2140 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
2142 if test -n "$x_includes"; then
2143 X_CFLAGS="$X_CFLAGS -I$x_includes"
2146 # It would also be nice to do this for all -L options, not just this one.
2147 if test -n "$x_libraries"; then
2148 X_LIBS="$X_LIBS -L$x_libraries"
2149 # For Solaris; some versions of Sun CC require a space after -R and
2150 # others require no space. Words are not sufficient . . . .
2151 case "`(uname -sr) 2>/dev/null`" in
2153 echo $ac_n "checking whether -R must be followed by a space""... $ac_c" 1>&6
2154 echo "configure:2166: checking whether -R must be followed by a space" >&5
2155 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS -R$x_libraries"
2156 cat > conftest.$ac_ext <<EOF
2157 #line 2169 "configure"
2158 #include "confdefs.h"
2164 if { (eval echo configure:2176: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2168 echo "configure: failed program was:" >&5
2169 cat conftest.$ac_ext >&5
2174 if test $ac_R_nospace = yes; then
2175 echo "$ac_t""no" 1>&6
2176 X_LIBS="$X_LIBS -R$x_libraries"
2178 LIBS="$ac_xsave_LIBS -R $x_libraries"
2179 cat > conftest.$ac_ext <<EOF
2180 #line 2192 "configure"
2181 #include "confdefs.h"
2187 if { (eval echo configure:2199: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2191 echo "configure: failed program was:" >&5
2192 cat conftest.$ac_ext >&5
2197 if test $ac_R_space = yes; then
2198 echo "$ac_t""yes" 1>&6
2199 X_LIBS="$X_LIBS -R $x_libraries"
2201 echo "$ac_t""neither works" 1>&6
2204 LIBS="$ac_xsave_LIBS"
2208 # Check for system-dependent libraries X programs must link with.
2209 # Do this before checking for the system-independent R6 libraries
2210 # (-lICE), since we may need -lsocket or whatever for X linking.
2212 if test "$ISC" = yes; then
2213 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
2215 # Martyn.Johnson@cl.cam.ac.uk says this is needed for Ultrix, if the X
2216 # libraries were built with DECnet support. And karl@cs.umb.edu says
2217 # the Alpha needs dnet_stub (dnet does not exist).
2218 echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6
2219 echo "configure:2231: checking for dnet_ntoa in -ldnet" >&5
2220 ac_lib_var=`echo dnet'_'dnet_ntoa | sed 'y%./+-%__p_%'`
2221 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2222 echo $ac_n "(cached) $ac_c" 1>&6
2224 ac_save_LIBS="$LIBS"
2226 cat > conftest.$ac_ext <<EOF
2227 #line 2239 "configure"
2228 #include "confdefs.h"
2229 /* Override any gcc2 internal prototype to avoid an error. */
2230 /* We use char because int might match the return type of a gcc2
2231 builtin and then its argument prototype would still apply. */
2238 if { (eval echo configure:2250: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2240 eval "ac_cv_lib_$ac_lib_var=yes"
2242 echo "configure: failed program was:" >&5
2243 cat conftest.$ac_ext >&5
2245 eval "ac_cv_lib_$ac_lib_var=no"
2248 LIBS="$ac_save_LIBS"
2251 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2252 echo "$ac_t""yes" 1>&6
2253 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
2255 echo "$ac_t""no" 1>&6
2258 if test $ac_cv_lib_dnet_dnet_ntoa = no; then
2259 echo $ac_n "checking for dnet_ntoa in -ldnet_stub""... $ac_c" 1>&6
2260 echo "configure:2272: checking for dnet_ntoa in -ldnet_stub" >&5
2261 ac_lib_var=`echo dnet_stub'_'dnet_ntoa | sed 'y%./+-%__p_%'`
2262 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2263 echo $ac_n "(cached) $ac_c" 1>&6
2265 ac_save_LIBS="$LIBS"
2266 LIBS="-ldnet_stub $LIBS"
2267 cat > conftest.$ac_ext <<EOF
2268 #line 2280 "configure"
2269 #include "confdefs.h"
2270 /* Override any gcc2 internal prototype to avoid an error. */
2271 /* We use char because int might match the return type of a gcc2
2272 builtin and then its argument prototype would still apply. */
2279 if { (eval echo configure:2291: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2281 eval "ac_cv_lib_$ac_lib_var=yes"
2283 echo "configure: failed program was:" >&5
2284 cat conftest.$ac_ext >&5
2286 eval "ac_cv_lib_$ac_lib_var=no"
2289 LIBS="$ac_save_LIBS"
2292 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2293 echo "$ac_t""yes" 1>&6
2294 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
2296 echo "$ac_t""no" 1>&6
2301 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
2302 # to get the SysV transport functions.
2303 # chad@anasazi.com says the Pyramis MIS-ES running DC/OSx (SVR4)
2305 # The nsl library prevents programs from opening the X display
2306 # on Irix 5.2, according to dickey@clark.net.
2307 echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
2308 echo "configure:2320: checking for gethostbyname" >&5
2309 if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
2310 echo $ac_n "(cached) $ac_c" 1>&6
2312 cat > conftest.$ac_ext <<EOF
2313 #line 2325 "configure"
2314 #include "confdefs.h"
2315 /* System header to define __stub macros and hopefully few prototypes,
2316 which can conflict with char gethostbyname(); below. */
2318 /* Override any gcc2 internal prototype to avoid an error. */
2319 /* We use char because int might match the return type of a gcc2
2320 builtin and then its argument prototype would still apply. */
2321 char gethostbyname();
2325 /* The GNU C library defines this for functions which it implements
2326 to always fail with ENOSYS. Some functions are actually named
2327 something starting with __ and the normal name is an alias. */
2328 #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
2336 if { (eval echo configure:2348: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2338 eval "ac_cv_func_gethostbyname=yes"
2340 echo "configure: failed program was:" >&5
2341 cat conftest.$ac_ext >&5
2343 eval "ac_cv_func_gethostbyname=no"
2348 if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
2349 echo "$ac_t""yes" 1>&6
2352 echo "$ac_t""no" 1>&6
2355 if test $ac_cv_func_gethostbyname = no; then
2356 echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
2357 echo "configure:2369: checking for gethostbyname in -lnsl" >&5
2358 ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
2359 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2360 echo $ac_n "(cached) $ac_c" 1>&6
2362 ac_save_LIBS="$LIBS"
2364 cat > conftest.$ac_ext <<EOF
2365 #line 2377 "configure"
2366 #include "confdefs.h"
2367 /* Override any gcc2 internal prototype to avoid an error. */
2368 /* We use char because int might match the return type of a gcc2
2369 builtin and then its argument prototype would still apply. */
2370 char gethostbyname();
2376 if { (eval echo configure:2388: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2378 eval "ac_cv_lib_$ac_lib_var=yes"
2380 echo "configure: failed program was:" >&5
2381 cat conftest.$ac_ext >&5
2383 eval "ac_cv_lib_$ac_lib_var=no"
2386 LIBS="$ac_save_LIBS"
2389 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2390 echo "$ac_t""yes" 1>&6
2391 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
2393 echo "$ac_t""no" 1>&6
2398 # lieder@skyler.mavd.honeywell.com says without -lsocket,
2399 # socket/setsockopt and other routines are undefined under SCO ODT
2400 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
2401 # on later versions), says simon@lia.di.epfl.ch: it contains
2402 # gethostby* variants that don't use the nameserver (or something).
2403 # -lsocket must be given before -lnsl if both are needed.
2404 # We assume that if connect needs -lnsl, so does gethostbyname.
2405 echo $ac_n "checking for connect""... $ac_c" 1>&6
2406 echo "configure:2418: checking for connect" >&5
2407 if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then
2408 echo $ac_n "(cached) $ac_c" 1>&6
2410 cat > conftest.$ac_ext <<EOF
2411 #line 2423 "configure"
2412 #include "confdefs.h"
2413 /* System header to define __stub macros and hopefully few prototypes,
2414 which can conflict with char connect(); below. */
2416 /* Override any gcc2 internal prototype to avoid an error. */
2417 /* We use char because int might match the return type of a gcc2
2418 builtin and then its argument prototype would still apply. */
2423 /* The GNU C library defines this for functions which it implements
2424 to always fail with ENOSYS. Some functions are actually named
2425 something starting with __ and the normal name is an alias. */
2426 #if defined (__stub_connect) || defined (__stub___connect)
2434 if { (eval echo configure:2446: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2436 eval "ac_cv_func_connect=yes"
2438 echo "configure: failed program was:" >&5
2439 cat conftest.$ac_ext >&5
2441 eval "ac_cv_func_connect=no"
2446 if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then
2447 echo "$ac_t""yes" 1>&6
2450 echo "$ac_t""no" 1>&6
2453 if test $ac_cv_func_connect = no; then
2454 echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
2455 echo "configure:2467: checking for connect in -lsocket" >&5
2456 ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
2457 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2458 echo $ac_n "(cached) $ac_c" 1>&6
2460 ac_save_LIBS="$LIBS"
2461 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
2462 cat > conftest.$ac_ext <<EOF
2463 #line 2475 "configure"
2464 #include "confdefs.h"
2465 /* Override any gcc2 internal prototype to avoid an error. */
2466 /* We use char because int might match the return type of a gcc2
2467 builtin and then its argument prototype would still apply. */
2474 if { (eval echo configure:2486: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2476 eval "ac_cv_lib_$ac_lib_var=yes"
2478 echo "configure: failed program was:" >&5
2479 cat conftest.$ac_ext >&5
2481 eval "ac_cv_lib_$ac_lib_var=no"
2484 LIBS="$ac_save_LIBS"
2487 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2488 echo "$ac_t""yes" 1>&6
2489 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
2491 echo "$ac_t""no" 1>&6
2496 # gomez@mi.uni-erlangen.de says -lposix is necessary on A/UX.
2497 echo $ac_n "checking for remove""... $ac_c" 1>&6
2498 echo "configure:2510: checking for remove" >&5
2499 if eval "test \"`echo '$''{'ac_cv_func_remove'+set}'`\" = set"; then
2500 echo $ac_n "(cached) $ac_c" 1>&6
2502 cat > conftest.$ac_ext <<EOF
2503 #line 2515 "configure"
2504 #include "confdefs.h"
2505 /* System header to define __stub macros and hopefully few prototypes,
2506 which can conflict with char remove(); below. */
2508 /* Override any gcc2 internal prototype to avoid an error. */
2509 /* We use char because int might match the return type of a gcc2
2510 builtin and then its argument prototype would still apply. */
2515 /* The GNU C library defines this for functions which it implements
2516 to always fail with ENOSYS. Some functions are actually named
2517 something starting with __ and the normal name is an alias. */
2518 #if defined (__stub_remove) || defined (__stub___remove)
2526 if { (eval echo configure:2538: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2528 eval "ac_cv_func_remove=yes"
2530 echo "configure: failed program was:" >&5
2531 cat conftest.$ac_ext >&5
2533 eval "ac_cv_func_remove=no"
2538 if eval "test \"`echo '$ac_cv_func_'remove`\" = yes"; then
2539 echo "$ac_t""yes" 1>&6
2542 echo "$ac_t""no" 1>&6
2545 if test $ac_cv_func_remove = no; then
2546 echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6
2547 echo "configure:2559: checking for remove in -lposix" >&5
2548 ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'`
2549 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2550 echo $ac_n "(cached) $ac_c" 1>&6
2552 ac_save_LIBS="$LIBS"
2553 LIBS="-lposix $LIBS"
2554 cat > conftest.$ac_ext <<EOF
2555 #line 2567 "configure"
2556 #include "confdefs.h"
2557 /* Override any gcc2 internal prototype to avoid an error. */
2558 /* We use char because int might match the return type of a gcc2
2559 builtin and then its argument prototype would still apply. */
2566 if { (eval echo configure:2578: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2568 eval "ac_cv_lib_$ac_lib_var=yes"
2570 echo "configure: failed program was:" >&5
2571 cat conftest.$ac_ext >&5
2573 eval "ac_cv_lib_$ac_lib_var=no"
2576 LIBS="$ac_save_LIBS"
2579 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2580 echo "$ac_t""yes" 1>&6
2581 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
2583 echo "$ac_t""no" 1>&6
2588 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
2589 echo $ac_n "checking for shmat""... $ac_c" 1>&6
2590 echo "configure:2602: checking for shmat" >&5
2591 if eval "test \"`echo '$''{'ac_cv_func_shmat'+set}'`\" = set"; then
2592 echo $ac_n "(cached) $ac_c" 1>&6
2594 cat > conftest.$ac_ext <<EOF
2595 #line 2607 "configure"
2596 #include "confdefs.h"
2597 /* System header to define __stub macros and hopefully few prototypes,
2598 which can conflict with char shmat(); below. */
2600 /* Override any gcc2 internal prototype to avoid an error. */
2601 /* We use char because int might match the return type of a gcc2
2602 builtin and then its argument prototype would still apply. */
2607 /* The GNU C library defines this for functions which it implements
2608 to always fail with ENOSYS. Some functions are actually named
2609 something starting with __ and the normal name is an alias. */
2610 #if defined (__stub_shmat) || defined (__stub___shmat)
2618 if { (eval echo configure:2630: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2620 eval "ac_cv_func_shmat=yes"
2622 echo "configure: failed program was:" >&5
2623 cat conftest.$ac_ext >&5
2625 eval "ac_cv_func_shmat=no"
2630 if eval "test \"`echo '$ac_cv_func_'shmat`\" = yes"; then
2631 echo "$ac_t""yes" 1>&6
2634 echo "$ac_t""no" 1>&6
2637 if test $ac_cv_func_shmat = no; then
2638 echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6
2639 echo "configure:2651: checking for shmat in -lipc" >&5
2640 ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'`
2641 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2642 echo $ac_n "(cached) $ac_c" 1>&6
2644 ac_save_LIBS="$LIBS"
2646 cat > conftest.$ac_ext <<EOF
2647 #line 2659 "configure"
2648 #include "confdefs.h"
2649 /* Override any gcc2 internal prototype to avoid an error. */
2650 /* We use char because int might match the return type of a gcc2
2651 builtin and then its argument prototype would still apply. */
2658 if { (eval echo configure:2670: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2660 eval "ac_cv_lib_$ac_lib_var=yes"
2662 echo "configure: failed program was:" >&5
2663 cat conftest.$ac_ext >&5
2665 eval "ac_cv_lib_$ac_lib_var=no"
2668 LIBS="$ac_save_LIBS"
2671 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2672 echo "$ac_t""yes" 1>&6
2673 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
2675 echo "$ac_t""no" 1>&6
2681 # Check for libraries that X11R6 Xt/Xaw programs need.
2682 ac_save_LDFLAGS="$LDFLAGS"
2683 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
2684 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
2685 # check for ICE first), but we must link in the order -lSM -lICE or
2686 # we get undefined symbols. So assume we have SM if we have ICE.
2687 # These have to be linked with before -lX11, unlike the other
2688 # libraries we check for below, so use a different variable.
2689 # --interran@uluru.Stanford.EDU, kb@cs.umb.edu.
2690 echo $ac_n "checking for IceConnectionNumber in -lICE""... $ac_c" 1>&6
2691 echo "configure:2703: checking for IceConnectionNumber in -lICE" >&5
2692 ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'`
2693 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2694 echo $ac_n "(cached) $ac_c" 1>&6
2696 ac_save_LIBS="$LIBS"
2698 cat > conftest.$ac_ext <<EOF
2699 #line 2711 "configure"
2700 #include "confdefs.h"
2701 /* Override any gcc2 internal prototype to avoid an error. */
2702 /* We use char because int might match the return type of a gcc2
2703 builtin and then its argument prototype would still apply. */
2704 char IceConnectionNumber();
2707 IceConnectionNumber()
2710 if { (eval echo configure:2722: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2712 eval "ac_cv_lib_$ac_lib_var=yes"
2714 echo "configure: failed program was:" >&5
2715 cat conftest.$ac_ext >&5
2717 eval "ac_cv_lib_$ac_lib_var=no"
2720 LIBS="$ac_save_LIBS"
2723 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2724 echo "$ac_t""yes" 1>&6
2725 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
2727 echo "$ac_t""no" 1>&6
2730 LDFLAGS="$ac_save_LDFLAGS"
2735 # Try and find the app-defaults directory.
2736 # It sucks that autoconf doesn't do this already...
2746 echo $ac_n "checking for X app-defaults directory""... $ac_c" 1>&6
2747 echo "configure:2759: checking for X app-defaults directory" >&5
2748 if eval "test \"`echo '$''{'ac_cv_x_app_defaults'+set}'`\" = set"; then
2749 echo $ac_n "(cached) $ac_c" 1>&6
2753 if mkdir conftestdir; then
2755 # Make sure to not put "make" in the Imakefile rules, since we grep it out.
2756 cat > Imakefile <<'EOF'
2758 @echo 'ac_x_app_defaults="${XAPPLOADDIR}"'
2760 if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
2761 # GNU make sometimes prints "make[1]: Entering...", which'd confuse us.
2762 eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
2767 if test x"$ac_x_app_defaults" = x; then
2769 # Look for the directory under a standard set of common directories.
2770 # Check X11 before X11Rn because it's often a symlink to the current release.
2772 /usr/X11/lib/app-defaults \
2773 /usr/X11R6/lib/app-defaults \
2774 /usr/X11R6/lib/X11/app-defaults \
2775 /usr/X11R5/lib/app-defaults \
2776 /usr/X11R5/lib/X11/app-defaults \
2777 /usr/X11R4/lib/app-defaults \
2778 /usr/X11R4/lib/X11/app-defaults \
2780 /usr/lib/X11/app-defaults \
2781 /usr/lib/X11R6/app-defaults \
2782 /usr/lib/X11R5/app-defaults \
2783 /usr/lib/X11R4/app-defaults \
2785 /usr/local/X11/lib/app-defaults \
2786 /usr/local/X11R6/lib/app-defaults \
2787 /usr/local/X11R5/lib/app-defaults \
2788 /usr/local/X11R4/lib/app-defaults \
2790 /usr/local/lib/X11/app-defaults \
2791 /usr/local/lib/X11R6/app-defaults \
2792 /usr/local/lib/X11R6/X11/app-defaults \
2793 /usr/local/lib/X11R5/app-defaults \
2794 /usr/local/lib/X11R5/X11/app-defaults \
2795 /usr/local/lib/X11R4/app-defaults \
2796 /usr/local/lib/X11R4/X11/app-defaults \
2798 /usr/X386/lib/X11/app-defaults \
2799 /usr/x386/lib/X11/app-defaults \
2800 /usr/XFree86/lib/X11/app-defaults \
2802 /usr/lib/X11/app-defaults \
2803 /usr/local/lib/X11/app-defaults \
2804 /usr/unsupported/lib/X11/app-defaults \
2805 /usr/athena/lib/X11/app-defaults \
2806 /usr/local/x11r5/lib/X11/app-defaults \
2807 /usr/lpp/Xamples/lib/X11/app-defaults \
2808 /lib/usr/lib/X11/app-defaults \
2810 /usr/openwin/lib/app-defaults \
2811 /usr/openwin/lib/X11/app-defaults \
2812 /usr/openwin/share/lib/app-defaults \
2813 /usr/openwin/share/lib/X11/app-defaults \
2815 /X11R6/lib/app-defaults \
2816 /X11R5/lib/app-defaults \
2817 /X11R4/lib/app-defaults \
2820 if test -d "$ac_dir"; then
2821 ac_x_app_defaults=$ac_dir
2827 if test x"$ac_x_app_defaults" = x; then
2828 ac_cv_x_app_defaults="/usr/lib/X11/app-defaults"
2830 # Record where we found app-defaults for the cache.
2831 ac_cv_x_app_defaults="$ac_x_app_defaults"
2835 echo "$ac_t""$ac_cv_x_app_defaults" 1>&6
2836 eval ac_x_app_defaults="$ac_cv_x_app_defaults"
2838 APPDEFAULTS=$ac_x_app_defaults
2841 # Like AC_CHECK_HEADER, but it uses the already-computed -I directories.
2845 # Like AC_EGREP_HEADER, but it uses the already-computed -I directories.
2849 # Like AC_TRY_COMPILE, but it uses the already-computed -I directories.
2854 # Like AC_CHECK_LIB, but it uses the already-computed -I and -L directories.
2855 # Use this sparingly; it probably doesn't work very well on X programs.
2859 # Like AC_TRY_RUN, but it uses the already-computed -I directories.
2860 # (But not the -L directories!)
2866 # Usage: HANDLE_X_PATH_ARG([variable_name],
2867 # [--command-line-option],
2868 # [descriptive string])
2870 # All of the --with options take three forms:
2872 # --with-foo (or --with-foo=yes)
2873 # --without-foo (or --with-foo=no)
2876 # This function, HANDLE_X_PATH_ARG, deals with the /DIR case. When it sees
2877 # a directory (string beginning with a slash) it checks to see whether
2878 # /DIR/include and /DIR/lib exist, and adds them to $X_CFLAGS and $X_LIBS
2885 # check for the HP XHPDisableReset server extension headers.
2888 ac_save_CPPFLAGS="$CPPFLAGS"
2889 if test \! -z "$includedir" ; then
2890 CPPFLAGS="$CPPFLAGS -I$includedir"
2892 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
2893 cat > conftest.$ac_ext <<EOF
2894 #line 2906 "configure"
2895 #include "confdefs.h"
2896 #include <X11/XHPlib.h>
2898 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2899 egrep "XHPDisableReset" >/dev/null 2>&1; then
2901 cat >> confdefs.h <<\EOF
2902 #define HAVE_XHPDISABLERESET 1
2905 SAVER_LIBS="-lXhp11 $SAVER_LIBS"
2909 CPPFLAGS="$ac_save_CPPFLAGS"
2912 # Check for the availability of the XPointer typedef, and define it otherwise.
2914 echo $ac_n "checking for XPointer""... $ac_c" 1>&6
2915 echo "configure:2927: checking for XPointer" >&5
2916 if eval "test \"`echo '$''{'ac_cv_xpointer'+set}'`\" = set"; then
2917 echo $ac_n "(cached) $ac_c" 1>&6
2920 ac_save_CPPFLAGS="$CPPFLAGS"
2921 if test \! -z "$includedir" ; then
2922 CPPFLAGS="$CPPFLAGS -I$includedir"
2924 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
2925 cat > conftest.$ac_ext <<EOF
2926 #line 2938 "configure"
2927 #include "confdefs.h"
2928 #include <X11/Xlib.h>
2930 XPointer foo = (XPointer) 0;
2933 if { (eval echo configure:2945: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2937 echo "configure: failed program was:" >&5
2938 cat conftest.$ac_ext >&5
2943 CPPFLAGS="$ac_save_CPPFLAGS"
2946 echo "$ac_t""$ac_cv_xpointer" 1>&6
2947 if test $ac_cv_xpointer != yes; then
2948 cat >> confdefs.h <<\EOF
2949 #define XPointer char*
2955 # Random special-cases for certain pathological OSes. You know who you are.
2960 # The following arcana was gleaned from conversations with
2961 # Eric Schwartz <erics@col.hp.com>:
2963 # On HPUX 10.x, the parts of X that HP considers "standard" live in
2964 # /usr/{include,lib}/X11R6/. The parts that HP doesn't consider
2965 # "standard", notably, Xaw and Xmu, live in /usr/contrib/X11R6/.
2966 # Also, there are symlinks from /usr/include/ and /usr/lib/ into
2967 # /usr/{include,lib}/X11R6/, so that (if you don't use Xmu at all)
2968 # you don't need any -I or -L arguments.
2970 # On HPUX 9.x, /usr/{include,lib}/X11R5/ and /usr/contrib/X11R5/
2971 # are the same division as 10.x. However, there are no symlinks to
2972 # the X stuff from /usr/include/ and /usr/lib/, so -I and -L
2973 # arguments are always necessary.
2975 # However, X11R6 was available on HPUX 9.x as a patch: if that
2976 # patch was installed, then all of X11R6 went in to
2977 # /usr/contrib/X11R6/ (there was no /usr/{include,lib}/X11R6/.)
2979 # HPUX 8.x was the same as 9.x, but was X11R4 instead (I don't know
2980 # whether R5 was available as a patch; R6 undoubtedly was not.)
2982 # So. We try and use the highest numbered pair of
2983 # /usr/{include,lib}/X11R?/ and /usr/contrib/X11R?/{include,lib}/
2984 # that are available. We do not mix and match different versions
2987 # Questions I still don't know the answers to: (do you?)
2989 # * Does HPUX 10.x come with /usr/contrib/X11R6/ standard?
2990 # Or does that need to be installed separately?
2992 # * On HPUX 9.x, where /usr/include/X11R5/ was standard, and
2993 # /usr/contrib/X11R6/ could be installed as a patch, what was in
2994 # that contrib directory? Did it contain so-called "standard"
2995 # X11R6, or did it include Xaw and Xmu as well? If the former,
2996 # where did one find Xaw and Xmu on 9.x R6 systems? Would this
2997 # be a situation where one had to reach into the R5 headers and
2998 # libs to find Xmu? That is, must both R6 and R5 directories
2999 # be on the -I and -L lists in that case?
3001 for version in X11R6 X11R5 X11R4 ; do
3002 # if either pair of directories exists...
3003 if test -d /usr/lib/$version || test -d /usr/contrib/$version/lib ; then
3004 # if contrib exists, use it...
3005 if test -d /usr/contrib/$version/lib ; then
3006 X_CFLAGS="$X_CFLAGS -I/usr/contrib/$version/include"
3007 X_LIBS="$X_LIBS -L/usr/contrib/$version/lib"
3009 # if the "standard" one exists, use it.
3010 if test -d /usr/lib/$version ; then
3011 X_CFLAGS="$X_CFLAGS -I/usr/include/$version"
3012 X_LIBS="$X_LIBS -L/usr/lib/$version"
3014 # since at least one of the pair exists, go no farther.
3019 # Now find Motif. Thanks for not making xmkmf find this by
3020 # default, you losers.
3022 if test -d /usr/lib/Motif1.2 ; then
3023 X_CFLAGS="$X_CFLAGS -I/usr/include/Motif1.2"
3024 X_LIBS="$X_LIBS -L/usr/lib/Motif1.2"
3025 elif test -d /usr/lib/Motif1.1 ; then
3026 X_CFLAGS="$X_CFLAGS -I/usr/include/Motif1.1"
3027 X_LIBS="$X_LIBS -L/usr/lib/Motif1.1"
3030 # Now let's check for the pseudo-standard locations for OpenGL and XPM.
3032 if test -d /opt/Mesa/lib ; then
3033 X_CFLAGS="-I/opt/Mesa/include $X_CFLAGS"
3034 X_LIBS="-L/opt/Mesa/lib $X_LIBS"
3037 if test -d /opt/xpm/lib/X11 ; then
3038 X_CFLAGS="-I/opt/xpm/include $X_CFLAGS"
3039 X_LIBS="-L/opt/xpm/lib/X11 $X_LIBS"
3042 # On HPUX, default to installing in /opt/xscreensaver/ instead of
3043 # in /usr/local/, unless there is already an xscreensaver in
3044 # /usr/local/bin/. This can be overridden with the --prefix arg
3045 # to configure. I'm not sure this is the right thing to do, but
3046 # Richard Lloyd says so...
3048 if test \! -x /usr/local/bin/xscreensaver ; then
3049 ac_default_prefix=/opt/xscreensaver
3055 # Thanks for not making xmkmf find this by default, pinheads.
3056 # And thanks for moving things around again, too. Is this
3057 # really the standard location now? What happened to the
3058 # joke that this kind of thing went in /opt?
3059 # cthomp says "answer: CDE (Common Disorganized Environment)"
3061 if test -f /usr/dt/include/Xm/Xm.h ; then
3062 X_CFLAGS="$X_CFLAGS -I/usr/dt/include"
3063 X_LIBS="$X_LIBS -L/usr/dt/lib -R:/usr/dt/lib"
3065 # Some versions of Slowlaris Motif require -lgen. But not all. Why?
3066 echo $ac_n "checking for regcmp in -lgen""... $ac_c" 1>&6
3067 echo "configure:3079: checking for regcmp in -lgen" >&5
3068 ac_lib_var=`echo gen'_'regcmp | sed 'y%./+-%__p_%'`
3069 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3070 echo $ac_n "(cached) $ac_c" 1>&6
3072 ac_save_LIBS="$LIBS"
3074 cat > conftest.$ac_ext <<EOF
3075 #line 3087 "configure"
3076 #include "confdefs.h"
3077 /* Override any gcc2 internal prototype to avoid an error. */
3078 /* We use char because int might match the return type of a gcc2
3079 builtin and then its argument prototype would still apply. */
3086 if { (eval echo configure:3098: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
3088 eval "ac_cv_lib_$ac_lib_var=yes"
3090 echo "configure: failed program was:" >&5
3091 cat conftest.$ac_ext >&5
3093 eval "ac_cv_lib_$ac_lib_var=no"
3096 LIBS="$ac_save_LIBS"
3099 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3100 echo "$ac_t""yes" 1>&6
3101 X_LIBS="$X_LIBS -lgen"
3103 echo "$ac_t""no" 1>&6
3112 # Check for Xmu (some fucked up vendors don't ship it...)
3116 ac_save_CPPFLAGS="$CPPFLAGS"
3117 if test \! -z "$includedir" ; then
3118 CPPFLAGS="$CPPFLAGS -I$includedir"
3120 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
3121 ac_safe=`echo "X11/Xmu/Error.h" | sed 'y%./+-%__p_%'`
3122 echo $ac_n "checking for X11/Xmu/Error.h""... $ac_c" 1>&6
3123 echo "configure:3135: checking for X11/Xmu/Error.h" >&5
3124 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3125 echo $ac_n "(cached) $ac_c" 1>&6
3127 cat > conftest.$ac_ext <<EOF
3128 #line 3140 "configure"
3129 #include "confdefs.h"
3130 #include <X11/Xmu/Error.h>
3132 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3133 { (eval echo configure:3145: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3134 ac_err=`grep -v '^ *+' conftest.out`
3135 if test -z "$ac_err"; then
3137 eval "ac_cv_header_$ac_safe=yes"
3140 echo "configure: failed program was:" >&5
3141 cat conftest.$ac_ext >&5
3143 eval "ac_cv_header_$ac_safe=no"
3147 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3148 echo "$ac_t""yes" 1>&6
3151 echo "$ac_t""no" 1>&6
3154 CPPFLAGS="$ac_save_CPPFLAGS"
3155 if test $have_xmu = no ; then
3156 XMU_SRCS='$(UTILS_SRC)/xmu.c'
3157 XMU_OBJS='$(UTILS_BIN)/xmu.o'
3161 SAVER_LIBS="-lXmu $SAVER_LIBS"
3162 HACK_LIBS="-lXmu $HACK_LIBS"
3163 cat >> confdefs.h <<\EOF
3170 # See comp.windows.x FAQ question 124 about _get_wmShellWidgetClass on 4.1.x.
3171 # The right fix is to get OpenWindows 3.0 patches 100512-02 and 100573-03.
3173 if test $have_xmu = yes ; then
3176 echo $ac_n "checking for the SunOS 4.1.x _get_wmShellWidgetClass bug""... $ac_c" 1>&6
3177 echo "configure:3189: checking for the SunOS 4.1.x _get_wmShellWidgetClass bug" >&5
3178 if eval "test \"`echo '$''{'ac_cv_sunos_xmu_bug'+set}'`\" = set"; then
3179 echo $ac_n "(cached) $ac_c" 1>&6
3181 ac_save_LDFLAGS="$LDFLAGS"
3182 if test \! -z "$x_libraries" ; then
3183 LDFLAGS="$LDFLAGS -L$x_libraries"
3185 # Note: this trick never works! (Generally.)
3186 # We're only getting away with using AC_TRY_LINK
3187 # with X libraries because we know it's SunOS.
3188 LDFLAGS="$LDFLAGS -lXmu -lXt -lX11 -lXext -lm"
3189 cat > conftest.$ac_ext <<EOF
3190 #line 3202 "configure"
3191 #include "confdefs.h"
3197 if { (eval echo configure:3209: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
3199 ac_cv_sunos_xmu_bug=no
3201 echo "configure: failed program was:" >&5
3202 cat conftest.$ac_ext >&5
3204 ac_cv_sunos_xmu_bug=yes
3207 LDFLAGS="$ac_save_LDFLAGS"
3210 echo "$ac_t""$ac_cv_sunos_xmu_bug" 1>&6
3211 if test $ac_cv_sunos_xmu_bug = yes ; then
3212 echo $ac_n "checking whether the compiler understands -static""... $ac_c" 1>&6
3213 echo "configure:3225: checking whether the compiler understands -static" >&5
3214 if eval "test \"`echo '$''{'ac_cv_ld_static'+set}'`\" = set"; then
3215 echo $ac_n "(cached) $ac_c" 1>&6
3217 ac_save_LDFLAGS="$LDFLAGS"
3218 LDFLAGS="$LDFLAGS -static"
3219 cat > conftest.$ac_ext <<EOF
3220 #line 3232 "configure"
3221 #include "confdefs.h"
3227 if { (eval echo configure:3239: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
3231 echo "configure: failed program was:" >&5
3232 cat conftest.$ac_ext >&5
3237 LDFLAGS="$ac_save_LDFLAGS"
3240 echo "$ac_t""$ac_cv_ld_static" 1>&6
3241 if test $ac_cv_ld_static = yes ; then
3242 LDFLAGS="$LDFLAGS -static"
3244 LDFLAGS="$LDFLAGS -Bstatic"
3252 # Check for the SGI SCREEN_SAVER server extension header.
3255 with_sgi_req=unspecified
3256 # Check whether --with-sgi-ext or --without-sgi-ext was given.
3257 if test "${with_sgi_ext+set}" = set; then
3258 withval="$with_sgi_ext"
3259 with_sgi="$withval"; with_sgi_req="$withval"
3271 echo $ac_n "checking for SGI SCREEN_SAVER headers""... $ac_c" 1>&6
3272 echo "configure:3284: checking for SGI SCREEN_SAVER headers" >&5
3275 X_CFLAGS="-I$d $X_CFLAGS"
3276 echo "$ac_t""$d" 1>&6
3278 echo "$ac_t""not found ($d: no such directory)" 1>&6
3281 echo $ac_n "checking for SGI SCREEN_SAVER libs""... $ac_c" 1>&6
3282 echo "configure:3294: checking for SGI SCREEN_SAVER libs" >&5
3285 X_LIBS="-L$d $X_LIBS"
3286 echo "$ac_t""$d" 1>&6
3288 echo "$ac_t""not found ($d: no such directory)" 1>&6
3291 # replace the directory string with "yes".
3293 with_sgi=$with_sgi_req
3298 echo "error: argument to --with-sgi-ext must be \"yes\", \"no\", or a directory."
3299 echo " If it is a directory, then \`DIR/include' will be added to"
3300 echo " the -I list, and \`DIR/lib' will be added to the -L list."
3305 # why is this necessary?
3306 # if we don't do this, then "./configure --with-motif=/usr/local/lesstif"
3307 # behaves as if "--with-zippy=/usr/local/lesstif" was also present!
3311 if test $with_sgi = yes; then
3313 ac_save_CPPFLAGS="$CPPFLAGS"
3314 if test \! -z "$includedir" ; then
3315 CPPFLAGS="$CPPFLAGS -I$includedir"
3317 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
3318 ac_safe=`echo "X11/extensions/XScreenSaver.h" | sed 'y%./+-%__p_%'`
3319 echo $ac_n "checking for X11/extensions/XScreenSaver.h""... $ac_c" 1>&6
3320 echo "configure:3332: checking for X11/extensions/XScreenSaver.h" >&5
3321 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3322 echo $ac_n "(cached) $ac_c" 1>&6
3324 cat > conftest.$ac_ext <<EOF
3325 #line 3337 "configure"
3326 #include "confdefs.h"
3327 #include <X11/extensions/XScreenSaver.h>
3329 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3330 { (eval echo configure:3342: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3331 ac_err=`grep -v '^ *+' conftest.out`
3332 if test -z "$ac_err"; then
3334 eval "ac_cv_header_$ac_safe=yes"
3337 echo "configure: failed program was:" >&5
3338 cat conftest.$ac_ext >&5
3340 eval "ac_cv_header_$ac_safe=no"
3344 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3345 echo "$ac_t""yes" 1>&6
3347 cat >> confdefs.h <<\EOF
3348 #define HAVE_SGI_SAVER_EXTENSION 1
3352 echo "$ac_t""no" 1>&6
3355 CPPFLAGS="$ac_save_CPPFLAGS"
3357 elif test $with_sgi != no; then
3358 echo "error: must be yes or no: --with-sgi-ext=$with_sgi"
3362 # Check for the MIT-SCREEN-SAVER server extension header,
3363 # unless the SGI extension has already been found.
3366 with_mit_req=unspecified
3367 # Check whether --with-mit-ext or --without-mit-ext was given.
3368 if test "${with_mit_ext+set}" = set; then
3369 withval="$with_mit_ext"
3370 with_mit="$withval"; with_mit_req="$withval"
3382 echo $ac_n "checking for MIT-SCREEN-SAVER headers""... $ac_c" 1>&6
3383 echo "configure:3395: checking for MIT-SCREEN-SAVER headers" >&5
3386 X_CFLAGS="-I$d $X_CFLAGS"
3387 echo "$ac_t""$d" 1>&6
3389 echo "$ac_t""not found ($d: no such directory)" 1>&6
3392 echo $ac_n "checking for MIT-SCREEN-SAVER libs""... $ac_c" 1>&6
3393 echo "configure:3405: checking for MIT-SCREEN-SAVER libs" >&5
3396 X_LIBS="-L$d $X_LIBS"
3397 echo "$ac_t""$d" 1>&6
3399 echo "$ac_t""not found ($d: no such directory)" 1>&6
3402 # replace the directory string with "yes".
3404 with_mit=$with_mit_req
3409 echo "error: argument to --with-mit-ext must be \"yes\", \"no\", or a directory."
3410 echo " If it is a directory, then \`DIR/include' will be added to"
3411 echo " the -I list, and \`DIR/lib' will be added to the -L list."
3416 # why is this necessary?
3417 # if we don't do this, then "./configure --with-motif=/usr/local/lesstif"
3418 # behaves as if "--with-zippy=/usr/local/lesstif" was also present!
3422 if test $have_sgi != yes; then
3423 if test $with_mit = yes; then
3425 ac_save_CPPFLAGS="$CPPFLAGS"
3426 if test \! -z "$includedir" ; then
3427 CPPFLAGS="$CPPFLAGS -I$includedir"
3429 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
3430 ac_safe=`echo "X11/extensions/scrnsaver.h" | sed 'y%./+-%__p_%'`
3431 echo $ac_n "checking for X11/extensions/scrnsaver.h""... $ac_c" 1>&6
3432 echo "configure:3444: checking for X11/extensions/scrnsaver.h" >&5
3433 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3434 echo $ac_n "(cached) $ac_c" 1>&6
3436 cat > conftest.$ac_ext <<EOF
3437 #line 3449 "configure"
3438 #include "confdefs.h"
3439 #include <X11/extensions/scrnsaver.h>
3441 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3442 { (eval echo configure:3454: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3443 ac_err=`grep -v '^ *+' conftest.out`
3444 if test -z "$ac_err"; then
3446 eval "ac_cv_header_$ac_safe=yes"
3449 echo "configure: failed program was:" >&5
3450 cat conftest.$ac_ext >&5
3452 eval "ac_cv_header_$ac_safe=no"
3456 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3457 echo "$ac_t""yes" 1>&6
3460 echo "$ac_t""no" 1>&6
3463 CPPFLAGS="$ac_save_CPPFLAGS"
3465 # Now check to see if it's really in the library; XF86Free-3.3 ships
3466 # scrnsaver.h, but doesn't include the code in libXext.a, the idiots!
3468 if test $have_mit = yes; then
3470 ac_save_CPPFLAGS="$CPPFLAGS"
3471 ac_save_LDFLAGS="$LDFLAGS"
3472 if test \! -z "$includedir" ; then
3473 CPPFLAGS="$CPPFLAGS -I$includedir"
3475 if test \! -z "$includedir" ; then
3476 CPPFLAGS="$CPPFLAGS -I$includedir"
3478 if test \! -z "$libdir" ; then
3479 LDFLAGS="$LDFLAGS -L$libdir"
3481 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
3482 if test \! -z "$x_libraries" ; then
3483 LDFLAGS="$LDFLAGS -L$x_libraries"
3485 echo $ac_n "checking for XScreenSaverRegister in -lXext""... $ac_c" 1>&6
3486 echo "configure:3498: checking for XScreenSaverRegister in -lXext" >&5
3487 ac_lib_var=`echo Xext'_'XScreenSaverRegister | sed 'y%./+-%__p_%'`
3488 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3489 echo $ac_n "(cached) $ac_c" 1>&6
3491 ac_save_LIBS="$LIBS"
3492 LIBS="-lXext -lm $LIBS"
3493 cat > conftest.$ac_ext <<EOF
3494 #line 3506 "configure"
3495 #include "confdefs.h"
3496 /* Override any gcc2 internal prototype to avoid an error. */
3497 /* We use char because int might match the return type of a gcc2
3498 builtin and then its argument prototype would still apply. */
3499 char XScreenSaverRegister();
3502 XScreenSaverRegister()
3505 if { (eval echo configure:3517: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
3507 eval "ac_cv_lib_$ac_lib_var=yes"
3509 echo "configure: failed program was:" >&5
3510 cat conftest.$ac_ext >&5
3512 eval "ac_cv_lib_$ac_lib_var=no"
3515 LIBS="$ac_save_LIBS"
3518 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3519 echo "$ac_t""yes" 1>&6
3520 ac_tr_lib=HAVE_LIB`echo Xext | sed -e 's/[^a-zA-Z0-9_]/_/g' \
3521 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
3522 cat >> confdefs.h <<EOF
3523 #define $ac_tr_lib 1
3529 echo "$ac_t""no" 1>&6
3533 CPPFLAGS="$ac_save_CPPFLAGS"
3534 LDFLAGS="$ac_save_LDFLAGS"
3536 if test $have_mit = no; then
3537 # Fuck! Looks like XF86Free-3.3 actually puts it in XExExt instead
3538 # of in Xext. Thank you master, may I have another.
3540 ac_save_CPPFLAGS="$CPPFLAGS"
3541 ac_save_LDFLAGS="$LDFLAGS"
3542 if test \! -z "$includedir" ; then
3543 CPPFLAGS="$CPPFLAGS -I$includedir"
3545 if test \! -z "$includedir" ; then
3546 CPPFLAGS="$CPPFLAGS -I$includedir"
3548 if test \! -z "$libdir" ; then
3549 LDFLAGS="$LDFLAGS -L$libdir"
3551 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
3552 if test \! -z "$x_libraries" ; then
3553 LDFLAGS="$LDFLAGS -L$x_libraries"
3555 echo $ac_n "checking for XScreenSaverRegister in -lXExExt""... $ac_c" 1>&6
3556 echo "configure:3568: checking for XScreenSaverRegister in -lXExExt" >&5
3557 ac_lib_var=`echo XExExt'_'XScreenSaverRegister | sed 'y%./+-%__p_%'`
3558 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3559 echo $ac_n "(cached) $ac_c" 1>&6
3561 ac_save_LIBS="$LIBS"
3562 LIBS="-lXExExt -lX11 -lXext -lm $LIBS"
3563 cat > conftest.$ac_ext <<EOF
3564 #line 3576 "configure"
3565 #include "confdefs.h"
3566 /* Override any gcc2 internal prototype to avoid an error. */
3567 /* We use char because int might match the return type of a gcc2
3568 builtin and then its argument prototype would still apply. */
3569 char XScreenSaverRegister();
3572 XScreenSaverRegister()
3575 if { (eval echo configure:3587: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
3577 eval "ac_cv_lib_$ac_lib_var=yes"
3579 echo "configure: failed program was:" >&5
3580 cat conftest.$ac_ext >&5
3582 eval "ac_cv_lib_$ac_lib_var=no"
3585 LIBS="$ac_save_LIBS"
3588 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3589 echo "$ac_t""yes" 1>&6
3590 have_mit=yes; SAVER_LIBS="$SAVER_LIBS -lXExExt"
3592 echo "$ac_t""no" 1>&6
3595 CPPFLAGS="$ac_save_CPPFLAGS"
3596 LDFLAGS="$ac_save_LDFLAGS"
3599 if test $have_mit = no; then
3600 # Double fuck! Looks like some versions of XFree86 (whichever version
3601 # it is that comes with RedHat Linux 2.0 -- I can't find a version
3602 # number) put this garbage in Xss instead of Xext. Thank you master,
3603 # may I have another.
3605 ac_save_CPPFLAGS="$CPPFLAGS"
3606 ac_save_LDFLAGS="$LDFLAGS"
3607 if test \! -z "$includedir" ; then
3608 CPPFLAGS="$CPPFLAGS -I$includedir"
3610 if test \! -z "$includedir" ; then
3611 CPPFLAGS="$CPPFLAGS -I$includedir"
3613 if test \! -z "$libdir" ; then
3614 LDFLAGS="$LDFLAGS -L$libdir"
3616 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
3617 if test \! -z "$x_libraries" ; then
3618 LDFLAGS="$LDFLAGS -L$x_libraries"
3620 echo $ac_n "checking for XScreenSaverRegister in -lXss""... $ac_c" 1>&6
3621 echo "configure:3633: checking for XScreenSaverRegister in -lXss" >&5
3622 ac_lib_var=`echo Xss'_'XScreenSaverRegister | sed 'y%./+-%__p_%'`
3623 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3624 echo $ac_n "(cached) $ac_c" 1>&6
3626 ac_save_LIBS="$LIBS"
3627 LIBS="-lXss -lX11 -lXext -lm $LIBS"
3628 cat > conftest.$ac_ext <<EOF
3629 #line 3641 "configure"
3630 #include "confdefs.h"
3631 /* Override any gcc2 internal prototype to avoid an error. */
3632 /* We use char because int might match the return type of a gcc2
3633 builtin and then its argument prototype would still apply. */
3634 char XScreenSaverRegister();
3637 XScreenSaverRegister()
3640 if { (eval echo configure:3652: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
3642 eval "ac_cv_lib_$ac_lib_var=yes"
3644 echo "configure: failed program was:" >&5
3645 cat conftest.$ac_ext >&5
3647 eval "ac_cv_lib_$ac_lib_var=no"
3650 LIBS="$ac_save_LIBS"
3653 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3654 echo "$ac_t""yes" 1>&6
3655 have_mit=yes; SAVER_LIBS="$SAVER_LIBS -lXss"
3657 echo "$ac_t""no" 1>&6
3660 CPPFLAGS="$ac_save_CPPFLAGS"
3661 LDFLAGS="$ac_save_LDFLAGS"
3664 if test $have_mit = yes; then
3665 cat >> confdefs.h <<\EOF
3666 #define HAVE_MIT_SAVER_EXTENSION 1
3673 elif test $with_mit != no; then
3674 echo "error: must be yes or no: --with-mit-ext=$with_mit"
3680 # Check for the XIDLE server extension header.
3683 with_xidle_req=unspecified
3684 # Check whether --with-xidle-ext or --without-xidle-ext was given.
3685 if test "${with_xidle_ext+set}" = set; then
3686 withval="$with_xidle_ext"
3687 with_xidle="$withval"; with_xidle_req="$withval"
3694 case "$with_xidle" in
3699 echo $ac_n "checking for XIDLE headers""... $ac_c" 1>&6
3700 echo "configure:3712: checking for XIDLE headers" >&5
3701 d=$with_xidle/include
3703 X_CFLAGS="-I$d $X_CFLAGS"
3704 echo "$ac_t""$d" 1>&6
3706 echo "$ac_t""not found ($d: no such directory)" 1>&6
3709 echo $ac_n "checking for XIDLE libs""... $ac_c" 1>&6
3710 echo "configure:3722: checking for XIDLE libs" >&5
3713 X_LIBS="-L$d $X_LIBS"
3714 echo "$ac_t""$d" 1>&6
3716 echo "$ac_t""not found ($d: no such directory)" 1>&6
3719 # replace the directory string with "yes".
3720 with_xidle_req="yes"
3721 with_xidle=$with_xidle_req
3726 echo "error: argument to --with-xidle-ext must be \"yes\", \"no\", or a directory."
3727 echo " If it is a directory, then \`DIR/include' will be added to"
3728 echo " the -I list, and \`DIR/lib' will be added to the -L list."
3733 # why is this necessary?
3734 # if we don't do this, then "./configure --with-motif=/usr/local/lesstif"
3735 # behaves as if "--with-zippy=/usr/local/lesstif" was also present!
3739 if test $with_xidle = yes; then
3741 ac_save_CPPFLAGS="$CPPFLAGS"
3742 if test \! -z "$includedir" ; then
3743 CPPFLAGS="$CPPFLAGS -I$includedir"
3745 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
3746 ac_safe=`echo "X11/extensions/xidle.h" | sed 'y%./+-%__p_%'`
3747 echo $ac_n "checking for X11/extensions/xidle.h""... $ac_c" 1>&6
3748 echo "configure:3760: checking for X11/extensions/xidle.h" >&5
3749 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3750 echo $ac_n "(cached) $ac_c" 1>&6
3752 cat > conftest.$ac_ext <<EOF
3753 #line 3765 "configure"
3754 #include "confdefs.h"
3755 #include <X11/extensions/xidle.h>
3757 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3758 { (eval echo configure:3770: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3759 ac_err=`grep -v '^ *+' conftest.out`
3760 if test -z "$ac_err"; then
3762 eval "ac_cv_header_$ac_safe=yes"
3765 echo "configure: failed program was:" >&5
3766 cat conftest.$ac_ext >&5
3768 eval "ac_cv_header_$ac_safe=no"
3772 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3773 echo "$ac_t""yes" 1>&6
3775 cat >> confdefs.h <<\EOF
3776 #define HAVE_XIDLE_EXTENSION 1
3780 echo "$ac_t""no" 1>&6
3783 CPPFLAGS="$ac_save_CPPFLAGS"
3784 elif test $with_xidle != no; then
3785 echo "error: must be yes or no: --with-xidle-ext=$with_xidle"
3790 # Check for the XSHM server extension header.
3793 with_xshm_req=unspecified
3794 # Check whether --with-xshm-ext or --without-xshm-ext was given.
3795 if test "${with_xshm_ext+set}" = set; then
3796 withval="$with_xshm_ext"
3797 with_xshm="$withval"; with_xshm_req="$withval"
3804 case "$with_xshm" in
3809 echo $ac_n "checking for XSHM headers""... $ac_c" 1>&6
3810 echo "configure:3822: checking for XSHM headers" >&5
3811 d=$with_xshm/include
3813 X_CFLAGS="-I$d $X_CFLAGS"
3814 echo "$ac_t""$d" 1>&6
3816 echo "$ac_t""not found ($d: no such directory)" 1>&6
3819 echo $ac_n "checking for XSHM libs""... $ac_c" 1>&6
3820 echo "configure:3832: checking for XSHM libs" >&5
3823 X_LIBS="-L$d $X_LIBS"
3824 echo "$ac_t""$d" 1>&6
3826 echo "$ac_t""not found ($d: no such directory)" 1>&6
3829 # replace the directory string with "yes".
3831 with_xshm=$with_xshm_req
3836 echo "error: argument to --with-xshm-ext must be \"yes\", \"no\", or a directory."
3837 echo " If it is a directory, then \`DIR/include' will be added to"
3838 echo " the -I list, and \`DIR/lib' will be added to the -L list."
3843 # why is this necessary?
3844 # if we don't do this, then "./configure --with-motif=/usr/local/lesstif"
3845 # behaves as if "--with-zippy=/usr/local/lesstif" was also present!
3849 if test $with_xshm = yes; then
3851 # first check for Xshm.h.
3853 ac_save_CPPFLAGS="$CPPFLAGS"
3854 if test \! -z "$includedir" ; then
3855 CPPFLAGS="$CPPFLAGS -I$includedir"
3857 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
3858 ac_safe=`echo "X11/extensions/XShm.h" | sed 'y%./+-%__p_%'`
3859 echo $ac_n "checking for X11/extensions/XShm.h""... $ac_c" 1>&6
3860 echo "configure:3872: checking for X11/extensions/XShm.h" >&5
3861 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3862 echo $ac_n "(cached) $ac_c" 1>&6
3864 cat > conftest.$ac_ext <<EOF
3865 #line 3877 "configure"
3866 #include "confdefs.h"
3867 #include <X11/extensions/XShm.h>
3869 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3870 { (eval echo configure:3882: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3871 ac_err=`grep -v '^ *+' conftest.out`
3872 if test -z "$ac_err"; then
3874 eval "ac_cv_header_$ac_safe=yes"
3877 echo "configure: failed program was:" >&5
3878 cat conftest.$ac_ext >&5
3880 eval "ac_cv_header_$ac_safe=no"
3884 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3885 echo "$ac_t""yes" 1>&6
3888 echo "$ac_t""no" 1>&6
3891 CPPFLAGS="$ac_save_CPPFLAGS"
3893 # if that succeeded, then check for sys/ipc.h.
3894 if test $have_xshm = yes; then
3897 ac_save_CPPFLAGS="$CPPFLAGS"
3898 if test \! -z "$includedir" ; then
3899 CPPFLAGS="$CPPFLAGS -I$includedir"
3901 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
3902 ac_safe=`echo "sys/ipc.h" | sed 'y%./+-%__p_%'`
3903 echo $ac_n "checking for sys/ipc.h""... $ac_c" 1>&6
3904 echo "configure:3916: checking for sys/ipc.h" >&5
3905 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3906 echo $ac_n "(cached) $ac_c" 1>&6
3908 cat > conftest.$ac_ext <<EOF
3909 #line 3921 "configure"
3910 #include "confdefs.h"
3911 #include <sys/ipc.h>
3913 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3914 { (eval echo configure:3926: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3915 ac_err=`grep -v '^ *+' conftest.out`
3916 if test -z "$ac_err"; then
3918 eval "ac_cv_header_$ac_safe=yes"
3921 echo "configure: failed program was:" >&5
3922 cat conftest.$ac_ext >&5
3924 eval "ac_cv_header_$ac_safe=no"
3928 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3929 echo "$ac_t""yes" 1>&6
3932 echo "$ac_t""no" 1>&6
3935 CPPFLAGS="$ac_save_CPPFLAGS"
3938 # if that succeeded, then check for sys/shm.h.
3939 if test $have_xshm = yes; then
3942 ac_save_CPPFLAGS="$CPPFLAGS"
3943 if test \! -z "$includedir" ; then
3944 CPPFLAGS="$CPPFLAGS -I$includedir"
3946 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
3947 ac_safe=`echo "sys/shm.h" | sed 'y%./+-%__p_%'`
3948 echo $ac_n "checking for sys/shm.h""... $ac_c" 1>&6
3949 echo "configure:3961: checking for sys/shm.h" >&5
3950 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3951 echo $ac_n "(cached) $ac_c" 1>&6
3953 cat > conftest.$ac_ext <<EOF
3954 #line 3966 "configure"
3955 #include "confdefs.h"
3956 #include <sys/shm.h>
3958 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3959 { (eval echo configure:3971: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3960 ac_err=`grep -v '^ *+' conftest.out`
3961 if test -z "$ac_err"; then
3963 eval "ac_cv_header_$ac_safe=yes"
3966 echo "configure: failed program was:" >&5
3967 cat conftest.$ac_ext >&5
3969 eval "ac_cv_header_$ac_safe=no"
3973 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3974 echo "$ac_t""yes" 1>&6
3977 echo "$ac_t""no" 1>&6
3980 CPPFLAGS="$ac_save_CPPFLAGS"
3983 # AIX is pathological, as usual: apparently it's normal for the Xshm headers
3984 # to exist, but the library code to not exist. And even better, the library
3985 # code is in its own library: libXextSam.a. So, if we're on AIX, and that
3986 # lib doesn't exist, give up.
3992 ac_save_CPPFLAGS="$CPPFLAGS"
3993 ac_save_LDFLAGS="$LDFLAGS"
3994 if test \! -z "$includedir" ; then
3995 CPPFLAGS="$CPPFLAGS -I$includedir"
3997 if test \! -z "$includedir" ; then
3998 CPPFLAGS="$CPPFLAGS -I$includedir"
4000 if test \! -z "$libdir" ; then
4001 LDFLAGS="$LDFLAGS -L$libdir"
4003 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
4004 if test \! -z "$x_libraries" ; then
4005 LDFLAGS="$LDFLAGS -L$x_libraries"
4007 echo $ac_n "checking for XShmQueryExtension in -lXextSam""... $ac_c" 1>&6
4008 echo "configure:4020: checking for XShmQueryExtension in -lXextSam" >&5
4009 ac_lib_var=`echo XextSam'_'XShmQueryExtension | sed 'y%./+-%__p_%'`
4010 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4011 echo $ac_n "(cached) $ac_c" 1>&6
4013 ac_save_LIBS="$LIBS"
4014 LIBS="-lXextSam -lX11 -lXext -lm $LIBS"
4015 cat > conftest.$ac_ext <<EOF
4016 #line 4028 "configure"
4017 #include "confdefs.h"
4018 /* Override any gcc2 internal prototype to avoid an error. */
4019 /* We use char because int might match the return type of a gcc2
4020 builtin and then its argument prototype would still apply. */
4021 char XShmQueryExtension();
4024 XShmQueryExtension()
4027 if { (eval echo configure:4039: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
4029 eval "ac_cv_lib_$ac_lib_var=yes"
4031 echo "configure: failed program was:" >&5
4032 cat conftest.$ac_ext >&5
4034 eval "ac_cv_lib_$ac_lib_var=no"
4037 LIBS="$ac_save_LIBS"
4040 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4041 echo "$ac_t""yes" 1>&6
4042 have_xshm=yes; SAVER_LIBS="$SAVER_LIBS -lXextSam"
4044 echo "$ac_t""no" 1>&6
4047 CPPFLAGS="$ac_save_CPPFLAGS"
4048 LDFLAGS="$ac_save_LDFLAGS"
4052 # if that succeeded, then we've really got it.
4053 if test $have_xshm = yes; then
4054 cat >> confdefs.h <<\EOF
4055 #define HAVE_XSHM_EXTENSION 1
4060 elif test $with_xshm != no; then
4061 echo "error: must be yes or no: --with-xshm-ext=$with_xshm"
4066 # Check for the SGI-VIDEO-CONTROL server extension header.
4069 with_sgivc_req=unspecified
4070 # Check whether --with-sgivc-ext or --without-sgivc-ext was given.
4071 if test "${with_sgivc_ext+set}" = set; then
4072 withval="$with_sgivc_ext"
4073 with_sgivc="$withval"; with_sgivc_req="$withval"
4080 case "$with_sgivc" in
4085 echo $ac_n "checking for SGI-VIDEO-CONTROL headers""... $ac_c" 1>&6
4086 echo "configure:4098: checking for SGI-VIDEO-CONTROL headers" >&5
4087 d=$with_sgivc/include
4089 X_CFLAGS="-I$d $X_CFLAGS"
4090 echo "$ac_t""$d" 1>&6
4092 echo "$ac_t""not found ($d: no such directory)" 1>&6
4095 echo $ac_n "checking for SGI-VIDEO-CONTROL libs""... $ac_c" 1>&6
4096 echo "configure:4108: checking for SGI-VIDEO-CONTROL libs" >&5
4099 X_LIBS="-L$d $X_LIBS"
4100 echo "$ac_t""$d" 1>&6
4102 echo "$ac_t""not found ($d: no such directory)" 1>&6
4105 # replace the directory string with "yes".
4106 with_sgivc_req="yes"
4107 with_sgivc=$with_sgivc_req
4112 echo "error: argument to --with-sgivc-ext must be \"yes\", \"no\", or a directory."
4113 echo " If it is a directory, then \`DIR/include' will be added to"
4114 echo " the -I list, and \`DIR/lib' will be added to the -L list."
4119 # why is this necessary?
4120 # if we don't do this, then "./configure --with-motif=/usr/local/lesstif"
4121 # behaves as if "--with-zippy=/usr/local/lesstif" was also present!
4125 if test $with_sgivc = yes; then
4127 # first check for XSGIvc.h
4129 ac_save_CPPFLAGS="$CPPFLAGS"
4130 if test \! -z "$includedir" ; then
4131 CPPFLAGS="$CPPFLAGS -I$includedir"
4133 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
4134 ac_safe=`echo "X11/extensions/XSGIvc.h" | sed 'y%./+-%__p_%'`
4135 echo $ac_n "checking for X11/extensions/XSGIvc.h""... $ac_c" 1>&6
4136 echo "configure:4148: checking for X11/extensions/XSGIvc.h" >&5
4137 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4138 echo $ac_n "(cached) $ac_c" 1>&6
4140 cat > conftest.$ac_ext <<EOF
4141 #line 4153 "configure"
4142 #include "confdefs.h"
4143 #include <X11/extensions/XSGIvc.h>
4145 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4146 { (eval echo configure:4158: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4147 ac_err=`grep -v '^ *+' conftest.out`
4148 if test -z "$ac_err"; then
4150 eval "ac_cv_header_$ac_safe=yes"
4153 echo "configure: failed program was:" >&5
4154 cat conftest.$ac_ext >&5
4156 eval "ac_cv_header_$ac_safe=no"
4160 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4161 echo "$ac_t""yes" 1>&6
4164 echo "$ac_t""no" 1>&6
4167 CPPFLAGS="$ac_save_CPPFLAGS"
4169 # if that succeeded, then check for the -lXsgivc
4170 if test $have_sgivc = yes; then
4173 ac_save_CPPFLAGS="$CPPFLAGS"
4174 ac_save_LDFLAGS="$LDFLAGS"
4175 if test \! -z "$includedir" ; then
4176 CPPFLAGS="$CPPFLAGS -I$includedir"
4178 if test \! -z "$includedir" ; then
4179 CPPFLAGS="$CPPFLAGS -I$includedir"
4181 if test \! -z "$libdir" ; then
4182 LDFLAGS="$LDFLAGS -L$libdir"
4184 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
4185 if test \! -z "$x_libraries" ; then
4186 LDFLAGS="$LDFLAGS -L$x_libraries"
4188 echo $ac_n "checking for XSGIvcQueryGammaMap in -lXsgivc""... $ac_c" 1>&6
4189 echo "configure:4201: checking for XSGIvcQueryGammaMap in -lXsgivc" >&5
4190 ac_lib_var=`echo Xsgivc'_'XSGIvcQueryGammaMap | sed 'y%./+-%__p_%'`
4191 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4192 echo $ac_n "(cached) $ac_c" 1>&6
4194 ac_save_LIBS="$LIBS"
4195 LIBS="-lXsgivc -lXext -lX11 $LIBS"
4196 cat > conftest.$ac_ext <<EOF
4197 #line 4209 "configure"
4198 #include "confdefs.h"
4199 /* Override any gcc2 internal prototype to avoid an error. */
4200 /* We use char because int might match the return type of a gcc2
4201 builtin and then its argument prototype would still apply. */
4202 char XSGIvcQueryGammaMap();
4205 XSGIvcQueryGammaMap()
4208 if { (eval echo configure:4220: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
4210 eval "ac_cv_lib_$ac_lib_var=yes"
4212 echo "configure: failed program was:" >&5
4213 cat conftest.$ac_ext >&5
4215 eval "ac_cv_lib_$ac_lib_var=no"
4218 LIBS="$ac_save_LIBS"
4221 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4222 echo "$ac_t""yes" 1>&6
4223 have_sgivc=yes; SAVER_LIBS="$SAVER_LIBS -lXsgivc"
4225 echo "$ac_t""no" 1>&6
4228 CPPFLAGS="$ac_save_CPPFLAGS"
4229 LDFLAGS="$ac_save_LDFLAGS"
4232 # if that succeeded, then we've really got it.
4233 if test $have_sgivc = yes; then
4234 cat >> confdefs.h <<\EOF
4235 #define HAVE_SGI_VC_EXTENSION 1
4240 elif test $with_sgivc != no; then
4241 echo "error: must be yes or no: --with-sgivc-ext=$with_sgivc"
4246 # Check for the DPMS server extension header.
4249 with_dpms_req=unspecified
4250 # Check whether --with-dpms-ext or --without-dpms-ext was given.
4251 if test "${with_dpms_ext+set}" = set; then
4252 withval="$with_dpms_ext"
4253 with_dpms="$withval"; with_dpms_req="$withval"
4260 case "$with_dpms" in
4265 echo $ac_n "checking for DPMS headers""... $ac_c" 1>&6
4266 echo "configure:4278: checking for DPMS headers" >&5
4267 d=$with_dpms/include
4269 X_CFLAGS="-I$d $X_CFLAGS"
4270 echo "$ac_t""$d" 1>&6
4272 echo "$ac_t""not found ($d: no such directory)" 1>&6
4275 echo $ac_n "checking for DPMS libs""... $ac_c" 1>&6
4276 echo "configure:4288: checking for DPMS libs" >&5
4279 X_LIBS="-L$d $X_LIBS"
4280 echo "$ac_t""$d" 1>&6
4282 echo "$ac_t""not found ($d: no such directory)" 1>&6
4285 # replace the directory string with "yes".
4287 with_dpms=$with_dpms_req
4292 echo "error: argument to --with-dpms-ext must be \"yes\", \"no\", or a directory."
4293 echo " If it is a directory, then \`DIR/include' will be added to"
4294 echo " the -I list, and \`DIR/lib' will be added to the -L list."
4299 # why is this necessary?
4300 # if we don't do this, then "./configure --with-motif=/usr/local/lesstif"
4301 # behaves as if "--with-zippy=/usr/local/lesstif" was also present!
4305 if test $with_dpms = yes; then
4307 # first check for dpms.h
4309 ac_save_CPPFLAGS="$CPPFLAGS"
4310 if test \! -z "$includedir" ; then
4311 CPPFLAGS="$CPPFLAGS -I$includedir"
4313 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
4314 ac_safe=`echo "X11/extensions/dpms.h" | sed 'y%./+-%__p_%'`
4315 echo $ac_n "checking for X11/extensions/dpms.h""... $ac_c" 1>&6
4316 echo "configure:4328: checking for X11/extensions/dpms.h" >&5
4317 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4318 echo $ac_n "(cached) $ac_c" 1>&6
4320 cat > conftest.$ac_ext <<EOF
4321 #line 4333 "configure"
4322 #include "confdefs.h"
4323 #include <X11/extensions/dpms.h>
4325 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4326 { (eval echo configure:4338: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4327 ac_err=`grep -v '^ *+' conftest.out`
4328 if test -z "$ac_err"; then
4330 eval "ac_cv_header_$ac_safe=yes"
4333 echo "configure: failed program was:" >&5
4334 cat conftest.$ac_ext >&5
4336 eval "ac_cv_header_$ac_safe=no"
4340 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4341 echo "$ac_t""yes" 1>&6
4344 echo "$ac_t""no" 1>&6
4347 CPPFLAGS="$ac_save_CPPFLAGS"
4349 # if that succeeded, then check for the -lXdpms
4350 if test $have_dpms = yes; then
4353 ac_save_CPPFLAGS="$CPPFLAGS"
4354 ac_save_LDFLAGS="$LDFLAGS"
4355 if test \! -z "$includedir" ; then
4356 CPPFLAGS="$CPPFLAGS -I$includedir"
4358 if test \! -z "$includedir" ; then
4359 CPPFLAGS="$CPPFLAGS -I$includedir"
4361 if test \! -z "$libdir" ; then
4362 LDFLAGS="$LDFLAGS -L$libdir"
4364 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
4365 if test \! -z "$x_libraries" ; then
4366 LDFLAGS="$LDFLAGS -L$x_libraries"
4368 echo $ac_n "checking for DPMSInfo in -lXdpms""... $ac_c" 1>&6
4369 echo "configure:4381: checking for DPMSInfo in -lXdpms" >&5
4370 ac_lib_var=`echo Xdpms'_'DPMSInfo | sed 'y%./+-%__p_%'`
4371 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4372 echo $ac_n "(cached) $ac_c" 1>&6
4374 ac_save_LIBS="$LIBS"
4375 LIBS="-lXdpms -lXext -lX11 $LIBS"
4376 cat > conftest.$ac_ext <<EOF
4377 #line 4389 "configure"
4378 #include "confdefs.h"
4379 /* Override any gcc2 internal prototype to avoid an error. */
4380 /* We use char because int might match the return type of a gcc2
4381 builtin and then its argument prototype would still apply. */
4388 if { (eval echo configure:4400: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
4390 eval "ac_cv_lib_$ac_lib_var=yes"
4392 echo "configure: failed program was:" >&5
4393 cat conftest.$ac_ext >&5
4395 eval "ac_cv_lib_$ac_lib_var=no"
4398 LIBS="$ac_save_LIBS"
4401 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4402 echo "$ac_t""yes" 1>&6
4403 have_dpms=yes; SAVER_LIBS="$SAVER_LIBS -lXdpms"
4405 echo "$ac_t""no" 1>&6
4408 CPPFLAGS="$ac_save_CPPFLAGS"
4409 LDFLAGS="$ac_save_LDFLAGS"
4412 # if that succeeded, then we've really got it.
4413 if test $have_dpms = yes; then
4414 cat >> confdefs.h <<\EOF
4415 #define HAVE_DPMS_EXTENSION 1
4420 elif test $with_dpms != no; then
4421 echo "error: must be yes or no: --with-dpms-ext=$with_dpms"
4427 # Check for Motif and Athena --with and --without arguments.
4432 with_motif_req=unspecified
4433 with_athena_req=unspecified
4435 # Check whether --with-motif or --without-motif was given.
4436 if test "${with_motif+set}" = set; then
4437 withval="$with_motif"
4438 with_motif="$withval"; with_motif_req="$withval"
4445 case "$with_motif" in
4450 echo $ac_n "checking for Motif headers""... $ac_c" 1>&6
4451 echo "configure:4463: checking for Motif headers" >&5
4452 d=$with_motif/include
4454 X_CFLAGS="-I$d $X_CFLAGS"
4455 echo "$ac_t""$d" 1>&6
4457 echo "$ac_t""not found ($d: no such directory)" 1>&6
4460 echo $ac_n "checking for Motif libs""... $ac_c" 1>&6
4461 echo "configure:4473: checking for Motif libs" >&5
4464 X_LIBS="-L$d $X_LIBS"
4465 echo "$ac_t""$d" 1>&6
4467 echo "$ac_t""not found ($d: no such directory)" 1>&6
4470 # replace the directory string with "yes".
4471 with_motif_req="yes"
4472 with_motif=$with_motif_req
4477 echo "error: argument to --with-motif must be \"yes\", \"no\", or a directory."
4478 echo " If it is a directory, then \`DIR/include' will be added to"
4479 echo " the -I list, and \`DIR/lib' will be added to the -L list."
4484 # why is this necessary?
4485 # if we don't do this, then "./configure --with-motif=/usr/local/lesstif"
4486 # behaves as if "--with-zippy=/usr/local/lesstif" was also present!
4490 # Check whether --with-athena or --without-athena was given.
4491 if test "${with_athena+set}" = set; then
4492 withval="$with_athena"
4493 with_athena="$withval"; with_athena_req="$withval"
4500 case "$with_athena" in
4505 echo $ac_n "checking for Athena headers""... $ac_c" 1>&6
4506 echo "configure:4518: checking for Athena headers" >&5
4507 d=$with_athena/include
4509 X_CFLAGS="-I$d $X_CFLAGS"
4510 echo "$ac_t""$d" 1>&6
4512 echo "$ac_t""not found ($d: no such directory)" 1>&6
4515 echo $ac_n "checking for Athena libs""... $ac_c" 1>&6
4516 echo "configure:4528: checking for Athena libs" >&5
4519 X_LIBS="-L$d $X_LIBS"
4520 echo "$ac_t""$d" 1>&6
4522 echo "$ac_t""not found ($d: no such directory)" 1>&6
4525 # replace the directory string with "yes".
4526 with_athena_req="yes"
4527 with_athena=$with_athena_req
4532 echo "error: argument to --with-athena must be \"yes\", \"no\", or a directory."
4533 echo " If it is a directory, then \`DIR/include' will be added to"
4534 echo " the -I list, and \`DIR/lib' will be added to the -L list."
4539 # why is this necessary?
4540 # if we don't do this, then "./configure --with-motif=/usr/local/lesstif"
4541 # behaves as if "--with-zippy=/usr/local/lesstif" was also present!
4545 if test $with_motif != yes -a $with_motif != no ; then
4546 echo "error: must be yes or no: --with-motif=$with_motif"
4550 if test $with_athena != yes -a $with_athena != no ; then
4551 echo "error: must be yes or no: --with-athena=$with_athena"
4556 # Saying --without-motif is the same as saying --with-athena.
4557 if test $with_motif_req = no ; then
4562 # Saying --without-athena is the same as saying --with-motif.
4563 if test $with_athena_req = no ; then
4568 # Check for Motif and Athena headers.
4572 ac_save_CPPFLAGS="$CPPFLAGS"
4573 if test \! -z "$includedir" ; then
4574 CPPFLAGS="$CPPFLAGS -I$includedir"
4576 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
4577 ac_safe=`echo "Xm/Xm.h" | sed 'y%./+-%__p_%'`
4578 echo $ac_n "checking for Xm/Xm.h""... $ac_c" 1>&6
4579 echo "configure:4591: checking for Xm/Xm.h" >&5
4580 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4581 echo $ac_n "(cached) $ac_c" 1>&6
4583 cat > conftest.$ac_ext <<EOF
4584 #line 4596 "configure"
4585 #include "confdefs.h"
4588 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4589 { (eval echo configure:4601: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4590 ac_err=`grep -v '^ *+' conftest.out`
4591 if test -z "$ac_err"; then
4593 eval "ac_cv_header_$ac_safe=yes"
4596 echo "configure: failed program was:" >&5
4597 cat conftest.$ac_ext >&5
4599 eval "ac_cv_header_$ac_safe=no"
4603 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4604 echo "$ac_t""yes" 1>&6
4606 cat >> confdefs.h <<\EOF
4607 #define HAVE_MOTIF 1
4610 SAVER_LIBS="-lXm $SAVER_LIBS"
4612 echo "$ac_t""no" 1>&6
4615 CPPFLAGS="$ac_save_CPPFLAGS"
4622 ac_save_CPPFLAGS="$CPPFLAGS"
4623 if test \! -z "$includedir" ; then
4624 CPPFLAGS="$CPPFLAGS -I$includedir"
4626 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
4627 ac_safe=`echo "X11/Xaw/Dialog.h" | sed 'y%./+-%__p_%'`
4628 echo $ac_n "checking for X11/Xaw/Dialog.h""... $ac_c" 1>&6
4629 echo "configure:4641: checking for X11/Xaw/Dialog.h" >&5
4630 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4631 echo $ac_n "(cached) $ac_c" 1>&6
4633 cat > conftest.$ac_ext <<EOF
4634 #line 4646 "configure"
4635 #include "confdefs.h"
4636 #include <X11/Xaw/Dialog.h>
4638 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4639 { (eval echo configure:4651: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4640 ac_err=`grep -v '^ *+' conftest.out`
4641 if test -z "$ac_err"; then
4643 eval "ac_cv_header_$ac_safe=yes"
4646 echo "configure: failed program was:" >&5
4647 cat conftest.$ac_ext >&5
4649 eval "ac_cv_header_$ac_safe=no"
4653 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4654 echo "$ac_t""yes" 1>&6
4657 echo "$ac_t""no" 1>&6
4660 CPPFLAGS="$ac_save_CPPFLAGS"
4662 ac_save_CPPFLAGS="$CPPFLAGS"
4663 ac_save_LDFLAGS="$LDFLAGS"
4664 if test \! -z "$includedir" ; then
4665 CPPFLAGS="$CPPFLAGS -I$includedir"
4667 if test \! -z "$includedir" ; then
4668 CPPFLAGS="$CPPFLAGS -I$includedir"
4670 if test \! -z "$libdir" ; then
4671 LDFLAGS="$LDFLAGS -L$libdir"
4673 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
4674 if test \! -z "$x_libraries" ; then
4675 LDFLAGS="$LDFLAGS -L$x_libraries"
4677 echo $ac_n "checking for Xaw3dComputeTopShadowRGB in -lXaw3d""... $ac_c" 1>&6
4678 echo "configure:4690: checking for Xaw3dComputeTopShadowRGB in -lXaw3d" >&5
4679 ac_lib_var=`echo Xaw3d'_'Xaw3dComputeTopShadowRGB | sed 'y%./+-%__p_%'`
4680 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4681 echo $ac_n "(cached) $ac_c" 1>&6
4683 ac_save_LIBS="$LIBS"
4684 LIBS="-lXaw3d -lXt -lXmu -lXext -lX11 $LIBS"
4685 cat > conftest.$ac_ext <<EOF
4686 #line 4698 "configure"
4687 #include "confdefs.h"
4688 /* Override any gcc2 internal prototype to avoid an error. */
4689 /* We use char because int might match the return type of a gcc2
4690 builtin and then its argument prototype would still apply. */
4691 char Xaw3dComputeTopShadowRGB();
4694 Xaw3dComputeTopShadowRGB()
4697 if { (eval echo configure:4709: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
4699 eval "ac_cv_lib_$ac_lib_var=yes"
4701 echo "configure: failed program was:" >&5
4702 cat conftest.$ac_ext >&5
4704 eval "ac_cv_lib_$ac_lib_var=no"
4707 LIBS="$ac_save_LIBS"
4710 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4711 echo "$ac_t""yes" 1>&6
4712 have_athena=yes; have_athena3d=yes
4714 echo "$ac_t""no" 1>&6
4717 CPPFLAGS="$ac_save_CPPFLAGS"
4718 LDFLAGS="$ac_save_LDFLAGS"
4720 if test $have_athena3d = yes; then
4721 SAVER_LIBS="-lXaw3d $SAVER_LIBS"
4722 elif test $have_athena = yes; then
4723 SAVER_LIBS="-lXaw $SAVER_LIBS"
4728 # If they asked for both motif and athena, check motif then athena.
4729 # If they asked for only motif, check motif then athena.
4730 # If they asked for only athena, check athena then motif.
4731 # If they asked for neither, check motif then athena.
4733 proselytize_motif=yes
4734 if test $with_motif = yes; then
4735 # asked for both, or for motif only
4737 if test $have_motif = yes; then
4744 elif test $with_athena = yes; then
4745 # asked for athena only
4747 if test $have_athena = yes; then
4749 proselytize_motif=no
4757 if test $have_motif = yes; then
4765 if test $have_motif = yes; then
4766 proselytize_motif=no
4769 # If we have Athena, check whether it's a version that includes
4770 # XawViewportSetCoordinates in Viewport.h (R3 (or R4?) don't.)
4771 if test $have_athena = yes ; then
4772 echo $ac_n "checking for XawViewportSetCoordinates in Viewport.h""... $ac_c" 1>&6
4773 echo "configure:4785: checking for XawViewportSetCoordinates in Viewport.h" >&5
4774 if eval "test \"`echo '$''{'ac_cv_have_XawViewportSetCoordinates'+set}'`\" = set"; then
4775 echo $ac_n "(cached) $ac_c" 1>&6
4777 ac_cv_have_XawViewportSetCoordinates=no
4779 ac_save_CPPFLAGS="$CPPFLAGS"
4780 if test \! -z "$includedir" ; then
4781 CPPFLAGS="$CPPFLAGS -I$includedir"
4783 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
4784 cat > conftest.$ac_ext <<EOF
4785 #line 4797 "configure"
4786 #include "confdefs.h"
4787 #include <X11/Xaw/Viewport.h>
4789 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4790 egrep "XawViewportSetCoordinates" >/dev/null 2>&1; then
4792 ac_cv_have_XawViewportSetCoordinates=yes
4796 CPPFLAGS="$ac_save_CPPFLAGS"
4799 echo "$ac_t""$ac_cv_have_XawViewportSetCoordinates" 1>&6
4800 if test $ac_cv_have_XawViewportSetCoordinates = yes ; then
4801 cat >> confdefs.h <<\EOF
4802 #define HAVE_XawViewportSetCoordinates 1
4809 # If we have Motif, check whether it's really LessTif.
4812 if test $have_motif = yes ; then
4813 echo $ac_n "checking whether Motif is really LessTif""... $ac_c" 1>&6
4814 echo "configure:4826: checking whether Motif is really LessTif" >&5
4815 if eval "test \"`echo '$''{'ac_cv_have_lesstif'+set}'`\" = set"; then
4816 echo $ac_n "(cached) $ac_c" 1>&6
4819 ac_save_CPPFLAGS="$CPPFLAGS"
4820 if test \! -z "$includedir" ; then
4821 CPPFLAGS="$CPPFLAGS -I$includedir"
4823 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
4824 cat > conftest.$ac_ext <<EOF
4825 #line 4837 "configure"
4826 #include "confdefs.h"
4829 long vers = LesstifVersion;
4832 if { (eval echo configure:4844: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4834 ac_cv_have_lesstif=yes
4836 echo "configure: failed program was:" >&5
4837 cat conftest.$ac_ext >&5
4839 ac_cv_have_lesstif=no
4842 CPPFLAGS="$ac_save_CPPFLAGS"
4845 echo "$ac_t""$ac_cv_have_lesstif" 1>&6
4846 have_lesstif=$ac_cv_have_lesstif
4850 unset ac_cv_lesstif_version
4851 unset ac_cv_lesstif_version_string
4853 lesstif_version=unknown
4854 lesstif_version_string=unknown
4856 if test $have_lesstif = yes ; then
4858 echo unknown > conftest-lt
4859 echo $ac_n "checking LessTif version number""... $ac_c" 1>&6
4860 echo "configure:4872: checking LessTif version number" >&5
4861 if eval "test \"`echo '$''{'ac_cv_lesstif_version_string'+set}'`\" = set"; then
4862 echo $ac_n "(cached) $ac_c" 1>&6
4865 ac_save_CPPFLAGS="$CPPFLAGS"
4866 if test \! -z "$includedir" ; then
4867 CPPFLAGS="$CPPFLAGS -I$includedir"
4869 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
4870 if test "$cross_compiling" = yes; then
4871 ac_cv_lesstif_version=unknown
4872 ac_cv_lesstif_version_string=unknown
4874 cat > conftest.$ac_ext <<EOF
4875 #line 4887 "configure"
4876 #include "confdefs.h"
4880 FILE *f = fopen("conftest-lt", "w");
4882 fprintf(f, "%d %d.%d\n", LesstifVersion,
4883 LESSTIF_VERSION, LESSTIF_REVISION);
4888 if { (eval echo configure:4900: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
4890 ltv=`cat conftest-lt`
4891 ac_cv_lesstif_version=`echo $ltv | sed 's/ .*//'`
4892 ac_cv_lesstif_version_string=`echo $ltv | sed 's/.* //'`
4894 echo "configure: failed program was:" >&5
4895 cat conftest.$ac_ext >&5
4897 ac_cv_lesstif_version=unknown
4898 ac_cv_lesstif_version_string=unknown
4903 CPPFLAGS="$ac_save_CPPFLAGS"
4906 echo "$ac_t""$ac_cv_lesstif_version_string" 1>&6
4908 lesstif_version=$ac_cv_lesstif_version
4909 lesstif_version_string=$ac_cv_lesstif_version_string
4914 # Some versions of Motif (2.1.0, at least) require -lXp, the "X Printing
4915 # Extension". Why this extension isn't in -lXext with all the others,
4919 if test $have_motif = yes ; then
4922 ac_save_CPPFLAGS="$CPPFLAGS"
4923 ac_save_LDFLAGS="$LDFLAGS"
4924 if test \! -z "$includedir" ; then
4925 CPPFLAGS="$CPPFLAGS -I$includedir"
4927 if test \! -z "$includedir" ; then
4928 CPPFLAGS="$CPPFLAGS -I$includedir"
4930 if test \! -z "$libdir" ; then
4931 LDFLAGS="$LDFLAGS -L$libdir"
4933 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
4934 if test \! -z "$x_libraries" ; then
4935 LDFLAGS="$LDFLAGS -L$x_libraries"
4937 echo $ac_n "checking for XpQueryExtension in -lXp""... $ac_c" 1>&6
4938 echo "configure:4950: checking for XpQueryExtension in -lXp" >&5
4939 ac_lib_var=`echo Xp'_'XpQueryExtension | sed 'y%./+-%__p_%'`
4940 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4941 echo $ac_n "(cached) $ac_c" 1>&6
4943 ac_save_LIBS="$LIBS"
4944 LIBS="-lXp -lX11 -lXext -lm $LIBS"
4945 cat > conftest.$ac_ext <<EOF
4946 #line 4958 "configure"
4947 #include "confdefs.h"
4948 /* Override any gcc2 internal prototype to avoid an error. */
4949 /* We use char because int might match the return type of a gcc2
4950 builtin and then its argument prototype would still apply. */
4951 char XpQueryExtension();
4957 if { (eval echo configure:4969: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
4959 eval "ac_cv_lib_$ac_lib_var=yes"
4961 echo "configure: failed program was:" >&5
4962 cat conftest.$ac_ext >&5
4964 eval "ac_cv_lib_$ac_lib_var=no"
4967 LIBS="$ac_save_LIBS"
4970 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4971 echo "$ac_t""yes" 1>&6
4972 have_xp_ext=yes; SAVER_LIBS="$SAVER_LIBS -lXp"
4974 echo "$ac_t""no" 1>&6
4977 CPPFLAGS="$ac_save_CPPFLAGS"
4978 LDFLAGS="$ac_save_LDFLAGS"
4982 # check for XPM header.
4985 with_xpm_req=unspecified
4986 # Check whether --with-xpm or --without-xpm was given.
4987 if test "${with_xpm+set}" = set; then
4989 with_xpm="$withval"; with_xpm_req="$withval"
5001 echo $ac_n "checking for XPM headers""... $ac_c" 1>&6
5002 echo "configure:5014: checking for XPM headers" >&5
5005 X_CFLAGS="-I$d $X_CFLAGS"
5006 echo "$ac_t""$d" 1>&6
5008 echo "$ac_t""not found ($d: no such directory)" 1>&6
5011 echo $ac_n "checking for XPM libs""... $ac_c" 1>&6
5012 echo "configure:5024: checking for XPM libs" >&5
5015 X_LIBS="-L$d $X_LIBS"
5016 echo "$ac_t""$d" 1>&6
5018 echo "$ac_t""not found ($d: no such directory)" 1>&6
5021 # replace the directory string with "yes".
5023 with_xpm=$with_xpm_req
5028 echo "error: argument to --with-xpm must be \"yes\", \"no\", or a directory."
5029 echo " If it is a directory, then \`DIR/include' will be added to"
5030 echo " the -I list, and \`DIR/lib' will be added to the -L list."
5035 # why is this necessary?
5036 # if we don't do this, then "./configure --with-motif=/usr/local/lesstif"
5037 # behaves as if "--with-zippy=/usr/local/lesstif" was also present!
5041 if test $with_xpm = yes; then
5043 ac_save_CPPFLAGS="$CPPFLAGS"
5044 if test \! -z "$includedir" ; then
5045 CPPFLAGS="$CPPFLAGS -I$includedir"
5047 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
5048 ac_safe=`echo "X11/xpm.h" | sed 'y%./+-%__p_%'`
5049 echo $ac_n "checking for X11/xpm.h""... $ac_c" 1>&6
5050 echo "configure:5062: checking for X11/xpm.h" >&5
5051 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5052 echo $ac_n "(cached) $ac_c" 1>&6
5054 cat > conftest.$ac_ext <<EOF
5055 #line 5067 "configure"
5056 #include "confdefs.h"
5057 #include <X11/xpm.h>
5059 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5060 { (eval echo configure:5072: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5061 ac_err=`grep -v '^ *+' conftest.out`
5062 if test -z "$ac_err"; then
5064 eval "ac_cv_header_$ac_safe=yes"
5067 echo "configure: failed program was:" >&5
5068 cat conftest.$ac_ext >&5
5070 eval "ac_cv_header_$ac_safe=no"
5074 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5075 echo "$ac_t""yes" 1>&6
5077 cat >> confdefs.h <<\EOF
5083 echo "$ac_t""no" 1>&6
5086 CPPFLAGS="$ac_save_CPPFLAGS"
5087 elif test $with_xpm != no; then
5088 echo "error: must be yes or no: --with-xpm=$with_xpm"
5093 # check for the GL header
5096 with_gl_req=unspecified
5097 # Check whether --with-gl or --without-gl was given.
5098 if test "${with_gl+set}" = set; then
5100 with_gl="$withval"; with_gl_req="$withval"
5112 echo $ac_n "checking for GL headers""... $ac_c" 1>&6
5113 echo "configure:5125: checking for GL headers" >&5
5116 X_CFLAGS="-I$d $X_CFLAGS"
5117 echo "$ac_t""$d" 1>&6
5119 echo "$ac_t""not found ($d: no such directory)" 1>&6
5122 echo $ac_n "checking for GL libs""... $ac_c" 1>&6
5123 echo "configure:5135: checking for GL libs" >&5
5126 X_LIBS="-L$d $X_LIBS"
5127 echo "$ac_t""$d" 1>&6
5129 echo "$ac_t""not found ($d: no such directory)" 1>&6
5132 # replace the directory string with "yes".
5134 with_gl=$with_gl_req
5139 echo "error: argument to --with-gl must be \"yes\", \"no\", or a directory."
5140 echo " If it is a directory, then \`DIR/include' will be added to"
5141 echo " the -I list, and \`DIR/lib' will be added to the -L list."
5146 # why is this necessary?
5147 # if we don't do this, then "./configure --with-motif=/usr/local/lesstif"
5148 # behaves as if "--with-zippy=/usr/local/lesstif" was also present!
5152 ac_mesagl_version=unknown
5153 ac_mesagl_version_string=unknown
5155 if test $with_gl = yes; then
5157 ac_save_CPPFLAGS="$CPPFLAGS"
5158 if test \! -z "$includedir" ; then
5159 CPPFLAGS="$CPPFLAGS -I$includedir"
5161 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
5162 ac_safe=`echo "GL/gl.h" | sed 'y%./+-%__p_%'`
5163 echo $ac_n "checking for GL/gl.h""... $ac_c" 1>&6
5164 echo "configure:5176: checking for GL/gl.h" >&5
5165 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5166 echo $ac_n "(cached) $ac_c" 1>&6
5168 cat > conftest.$ac_ext <<EOF
5169 #line 5181 "configure"
5170 #include "confdefs.h"
5173 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5174 { (eval echo configure:5186: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5175 ac_err=`grep -v '^ *+' conftest.out`
5176 if test -z "$ac_err"; then
5178 eval "ac_cv_header_$ac_safe=yes"
5181 echo "configure: failed program was:" >&5
5182 cat conftest.$ac_ext >&5
5184 eval "ac_cv_header_$ac_safe=no"
5188 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5189 echo "$ac_t""yes" 1>&6
5192 echo "$ac_t""no" 1>&6
5195 CPPFLAGS="$ac_save_CPPFLAGS"
5196 if test $have_gl = yes ; then
5198 ac_save_CPPFLAGS="$CPPFLAGS"
5199 if test \! -z "$includedir" ; then
5200 CPPFLAGS="$CPPFLAGS -I$includedir"
5202 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
5203 ac_safe=`echo "GL/glx.h" | sed 'y%./+-%__p_%'`
5204 echo $ac_n "checking for GL/glx.h""... $ac_c" 1>&6
5205 echo "configure:5217: checking for GL/glx.h" >&5
5206 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5207 echo $ac_n "(cached) $ac_c" 1>&6
5209 cat > conftest.$ac_ext <<EOF
5210 #line 5222 "configure"
5211 #include "confdefs.h"
5214 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5215 { (eval echo configure:5227: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5216 ac_err=`grep -v '^ *+' conftest.out`
5217 if test -z "$ac_err"; then
5219 eval "ac_cv_header_$ac_safe=yes"
5222 echo "configure: failed program was:" >&5
5223 cat conftest.$ac_ext >&5
5225 eval "ac_cv_header_$ac_safe=no"
5229 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5230 echo "$ac_t""yes" 1>&6
5233 echo "$ac_t""no" 1>&6
5236 CPPFLAGS="$ac_save_CPPFLAGS"
5239 # If we have the headers, try and figure out which vendor it's from.
5241 if test $have_gl = yes ; then
5243 cat >> confdefs.h <<\EOF
5248 # We need to know whether it's MesaGL so that we know which libraries
5251 echo $ac_n "checking whether GL is really MesaGL""... $ac_c" 1>&6
5252 echo "configure:5264: checking whether GL is really MesaGL" >&5
5253 if eval "test \"`echo '$''{'ac_cv_have_mesa_gl'+set}'`\" = set"; then
5254 echo $ac_n "(cached) $ac_c" 1>&6
5256 ac_cv_have_mesa_gl=no
5258 ac_save_CPPFLAGS="$CPPFLAGS"
5259 if test \! -z "$includedir" ; then
5260 CPPFLAGS="$CPPFLAGS -I$includedir"
5262 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
5263 cat > conftest.$ac_ext <<EOF
5264 #line 5276 "configure"
5265 #include "confdefs.h"
5268 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5269 egrep "Mesa" >/dev/null 2>&1; then
5271 ac_cv_have_mesa_gl=yes
5275 CPPFLAGS="$ac_save_CPPFLAGS"
5279 ac_have_mesa_gl=$ac_cv_have_mesa_gl
5280 echo "$ac_t""$ac_have_mesa_gl" 1>&6
5282 if test $ac_have_mesa_gl = no ; then
5284 GL_LIBS="-lGL -lGLU"
5286 cat >> confdefs.h <<\EOF
5287 #define HAVE_MESA_GL 1
5291 GL_LIBS="-lMesaGL -lMesaGLU"
5295 # If it's MesaGL, we'd like to issue a warning if the version number
5296 # is less than or equal to 2.6, because that version had a security bug.
5298 if test $ac_have_mesa_gl = yes; then
5300 # don't cache these.
5301 unset ac_cv_mesagl_version
5302 unset ac_cv_mesagl_version_string
5304 echo $ac_n "checking MesaGL version number""... $ac_c" 1>&6
5305 echo "configure:5317: checking MesaGL version number" >&5
5306 if eval "test \"`echo '$''{'ac_cv_mesagl_version_string'+set}'`\" = set"; then
5307 echo $ac_n "(cached) $ac_c" 1>&6
5309 cat > conftest.$ac_ext <<EOF
5310 #line 5322 "configure"
5311 #include "confdefs.h"
5313 #configure: MESA_MAJOR_VERSION MESA_MINOR_VERSION
5316 mglv=`(eval "$ac_cpp conftest.$ac_ext") 2>&5 | sed -n \
5317 's/^#configure:.*\([0-9][0-9]*\).*\([0-9][0-9]*\).*$/\1.\2/p'`
5318 if test "$mglv" = ""; then
5319 ac_mesagl_version=unknown
5320 ac_mesagl_version_string=unknown
5322 ac_mesagl_version_string=$mglv
5323 maj=`echo $mglv | sed -n 's/\..*//p'`
5324 min=`echo $mglv | sed -n 's/.*\.//p'`
5325 ac_mesagl_version=`echo "$maj * 1000 + $min" | bc`
5327 ac_cv_mesagl_version=$ac_mesagl_version
5328 ac_cv_mesagl_version_string=$ac_mesagl_version_string
5332 ac_mesagl_version=$ac_cv_mesagl_version
5333 ac_mesagl_version_string=$ac_cv_mesagl_version_string
5334 echo "$ac_t""$ac_cv_mesagl_version_string" 1>&6
5338 # Check for OpenGL 1.1 features.
5341 ac_save_CPPFLAGS="$CPPFLAGS"
5342 ac_save_LDFLAGS="$LDFLAGS"
5343 if test \! -z "$includedir" ; then
5344 CPPFLAGS="$CPPFLAGS -I$includedir"
5346 if test \! -z "$includedir" ; then
5347 CPPFLAGS="$CPPFLAGS -I$includedir"
5349 if test \! -z "$libdir" ; then
5350 LDFLAGS="$LDFLAGS -L$libdir"
5352 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
5353 if test \! -z "$x_libraries" ; then
5354 LDFLAGS="$LDFLAGS -L$x_libraries"
5356 echo $ac_n "checking for glBindTexture in -l$gl_lib_1""... $ac_c" 1>&6
5357 echo "configure:5369: checking for glBindTexture in -l$gl_lib_1" >&5
5358 ac_lib_var=`echo $gl_lib_1'_'glBindTexture | sed 'y%./+-%__p_%'`
5359 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5360 echo $ac_n "(cached) $ac_c" 1>&6
5362 ac_save_LIBS="$LIBS"
5363 LIBS="-l$gl_lib_1 $GL_LIBS -lX11 -lXext -lm $LIBS"
5364 cat > conftest.$ac_ext <<EOF
5365 #line 5377 "configure"
5366 #include "confdefs.h"
5367 /* Override any gcc2 internal prototype to avoid an error. */
5368 /* We use char because int might match the return type of a gcc2
5369 builtin and then its argument prototype would still apply. */
5370 char glBindTexture();
5376 if { (eval echo configure:5388: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
5378 eval "ac_cv_lib_$ac_lib_var=yes"
5380 echo "configure: failed program was:" >&5
5381 cat conftest.$ac_ext >&5
5383 eval "ac_cv_lib_$ac_lib_var=no"
5386 LIBS="$ac_save_LIBS"
5389 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5390 echo "$ac_t""yes" 1>&6
5391 cat >> confdefs.h <<\EOF
5392 #define HAVE_GLBINDTEXTURE 1
5396 echo "$ac_t""no" 1>&6
5399 CPPFLAGS="$ac_save_CPPFLAGS"
5400 LDFLAGS="$ac_save_LDFLAGS"
5404 elif test $with_gl != no; then
5405 echo "error: must be yes or no: --with-gl=$with_gl"
5410 # check for SGI XReadDisplay server extension header.
5413 with_readdisplay_req=unspecified
5414 # Check whether --with-readdisplay or --without-readdisplay was given.
5415 if test "${with_readdisplay+set}" = set; then
5416 withval="$with_readdisplay"
5417 with_readdisplay="$withval"; with_readdisplay_req="$withval"
5419 with_readdisplay=yes
5424 case "$with_readdisplay" in
5429 echo $ac_n "checking for XReadDisplay headers""... $ac_c" 1>&6
5430 echo "configure:5442: checking for XReadDisplay headers" >&5
5431 d=$with_readdisplay/include
5433 X_CFLAGS="-I$d $X_CFLAGS"
5434 echo "$ac_t""$d" 1>&6
5436 echo "$ac_t""not found ($d: no such directory)" 1>&6
5439 echo $ac_n "checking for XReadDisplay libs""... $ac_c" 1>&6
5440 echo "configure:5452: checking for XReadDisplay libs" >&5
5441 d=$with_readdisplay/lib
5443 X_LIBS="-L$d $X_LIBS"
5444 echo "$ac_t""$d" 1>&6
5446 echo "$ac_t""not found ($d: no such directory)" 1>&6
5449 # replace the directory string with "yes".
5450 with_readdisplay_req="yes"
5451 with_readdisplay=$with_readdisplay_req
5456 echo "error: argument to --with-readdisplay must be \"yes\", \"no\", or a directory."
5457 echo " If it is a directory, then \`DIR/include' will be added to"
5458 echo " the -I list, and \`DIR/lib' will be added to the -L list."
5463 # why is this necessary?
5464 # if we don't do this, then "./configure --with-motif=/usr/local/lesstif"
5465 # behaves as if "--with-zippy=/usr/local/lesstif" was also present!
5469 if test $with_readdisplay = yes; then
5471 ac_save_CPPFLAGS="$CPPFLAGS"
5472 if test \! -z "$includedir" ; then
5473 CPPFLAGS="$CPPFLAGS -I$includedir"
5475 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
5476 ac_safe=`echo "X11/extensions/readdisplay.h" | sed 'y%./+-%__p_%'`
5477 echo $ac_n "checking for X11/extensions/readdisplay.h""... $ac_c" 1>&6
5478 echo "configure:5490: checking for X11/extensions/readdisplay.h" >&5
5479 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5480 echo $ac_n "(cached) $ac_c" 1>&6
5482 cat > conftest.$ac_ext <<EOF
5483 #line 5495 "configure"
5484 #include "confdefs.h"
5485 #include <X11/extensions/readdisplay.h>
5487 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5488 { (eval echo configure:5500: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5489 ac_err=`grep -v '^ *+' conftest.out`
5490 if test -z "$ac_err"; then
5492 eval "ac_cv_header_$ac_safe=yes"
5495 echo "configure: failed program was:" >&5
5496 cat conftest.$ac_ext >&5
5498 eval "ac_cv_header_$ac_safe=no"
5502 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5503 echo "$ac_t""yes" 1>&6
5504 cat >> confdefs.h <<\EOF
5505 #define HAVE_READ_DISPLAY_EXTENSION 1
5509 echo "$ac_t""no" 1>&6
5512 CPPFLAGS="$ac_save_CPPFLAGS"
5513 elif test $with_readdisplay != no; then
5514 echo "error: must be yes or no: --with-readdisplay=$with_readdisplay"
5519 # check for SGI's Iris Video Library header.
5522 with_sgivideo_req=unspecified
5523 # Check whether --with-sgivideo or --without-sgivideo was given.
5524 if test "${with_sgivideo+set}" = set; then
5525 withval="$with_sgivideo"
5526 with_sgivideo="$withval"; with_sgivideo_req="$withval"
5533 case "$with_sgivideo" in
5538 echo $ac_n "checking for Iris Video headers""... $ac_c" 1>&6
5539 echo "configure:5551: checking for Iris Video headers" >&5
5540 d=$with_sgivideo/include
5542 X_CFLAGS="-I$d $X_CFLAGS"
5543 echo "$ac_t""$d" 1>&6
5545 echo "$ac_t""not found ($d: no such directory)" 1>&6
5548 echo $ac_n "checking for Iris Video libs""... $ac_c" 1>&6
5549 echo "configure:5561: checking for Iris Video libs" >&5
5550 d=$with_sgivideo/lib
5552 X_LIBS="-L$d $X_LIBS"
5553 echo "$ac_t""$d" 1>&6
5555 echo "$ac_t""not found ($d: no such directory)" 1>&6
5558 # replace the directory string with "yes".
5559 with_sgivideo_req="yes"
5560 with_sgivideo=$with_sgivideo_req
5565 echo "error: argument to --with-sgivideo must be \"yes\", \"no\", or a directory."
5566 echo " If it is a directory, then \`DIR/include' will be added to"
5567 echo " the -I list, and \`DIR/lib' will be added to the -L list."
5572 # why is this necessary?
5573 # if we don't do this, then "./configure --with-motif=/usr/local/lesstif"
5574 # behaves as if "--with-zippy=/usr/local/lesstif" was also present!
5578 if test $with_sgivideo = yes; then
5580 ac_save_CPPFLAGS="$CPPFLAGS"
5581 if test \! -z "$includedir" ; then
5582 CPPFLAGS="$CPPFLAGS -I$includedir"
5584 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
5585 ac_safe=`echo "dmedia/vl.h" | sed 'y%./+-%__p_%'`
5586 echo $ac_n "checking for dmedia/vl.h""... $ac_c" 1>&6
5587 echo "configure:5599: checking for dmedia/vl.h" >&5
5588 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
5589 echo $ac_n "(cached) $ac_c" 1>&6
5591 cat > conftest.$ac_ext <<EOF
5592 #line 5604 "configure"
5593 #include "confdefs.h"
5594 #include <dmedia/vl.h>
5596 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5597 { (eval echo configure:5609: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5598 ac_err=`grep -v '^ *+' conftest.out`
5599 if test -z "$ac_err"; then
5601 eval "ac_cv_header_$ac_safe=yes"
5604 echo "configure: failed program was:" >&5
5605 cat conftest.$ac_ext >&5
5607 eval "ac_cv_header_$ac_safe=no"
5611 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
5612 echo "$ac_t""yes" 1>&6
5615 echo "$ac_t""no" 1>&6
5618 CPPFLAGS="$ac_save_CPPFLAGS"
5619 if test $have_sgivideo = yes; then
5621 echo $ac_n "checking for vlOpenVideo in -lvl""... $ac_c" 1>&6
5622 echo "configure:5634: checking for vlOpenVideo in -lvl" >&5
5623 ac_lib_var=`echo vl'_'vlOpenVideo | sed 'y%./+-%__p_%'`
5624 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
5625 echo $ac_n "(cached) $ac_c" 1>&6
5627 ac_save_LIBS="$LIBS"
5629 cat > conftest.$ac_ext <<EOF
5630 #line 5642 "configure"
5631 #include "confdefs.h"
5632 /* Override any gcc2 internal prototype to avoid an error. */
5633 /* We use char because int might match the return type of a gcc2
5634 builtin and then its argument prototype would still apply. */
5641 if { (eval echo configure:5653: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
5643 eval "ac_cv_lib_$ac_lib_var=yes"
5645 echo "configure: failed program was:" >&5
5646 cat conftest.$ac_ext >&5
5648 eval "ac_cv_lib_$ac_lib_var=no"
5651 LIBS="$ac_save_LIBS"
5654 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
5655 echo "$ac_t""yes" 1>&6
5658 echo "$ac_t""no" 1>&6
5661 if test $have_sgivideo = yes; then
5662 SGI_VIDEO_OBJS="$(UTILS_BIN)/sgivideo.o"
5663 SGI_VIDEO_LIBS="-lvl"
5664 cat >> confdefs.h <<\EOF
5665 #define HAVE_SGI_VIDEO 1
5670 elif test $with_sgivideo != no; then
5671 echo "error: must be yes or no: --with-sgivideo=$with_sgivideo"
5677 # Try to find a program to generate random text.
5679 # Zippy is funnier than the idiocy generally spat out by `fortune',
5680 # so try to find that, by invoking Emacs and asking it where its
5681 # libexec directory is ("yow" lives in there.)
5683 # If that doesn't work, see if fortune, zippy, or yow are on $PATH,
5684 # and if so, use them.
5686 # If that doesn't work, look in /usr/games, and if it's there, use
5687 # the full pathname.
5690 # Check whether --with-zippy or --without-zippy was given.
5691 if test "${with_zippy+set}" = set; then
5692 withval="$with_zippy"
5693 with_zippy_req="$withval"; with_zippy="$withval"
5695 with_zippy_req="$withval"; with_zippy="$withval"
5699 if test "$with_zippy" = no || test "$with_zippy" = yes ; then
5704 if test -n "$with_zippy_req" ; then
5705 ac_cv_zippy_program=""
5706 case "$with_zippy_req" in
5708 echo $ac_n "checking for $with_zippy_req""... $ac_c" 1>&6
5709 echo "configure:5721: checking for $with_zippy_req" >&5
5710 if test -x "$with_zippy_req" ; then
5711 echo "$ac_t""yes" 1>&6
5713 echo "$ac_t""no" 1>&6
5719 unset ac_cv_path_zip2
5720 # Extract the first word of "$with_zippy_req", so it can be a program name with args.
5721 set dummy $with_zippy_req; ac_word=$2
5722 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5723 echo "configure:5735: checking for $ac_word" >&5
5724 if eval "test \"`echo '$''{'ac_cv_path_zip2'+set}'`\" = set"; then
5725 echo $ac_n "(cached) $ac_c" 1>&6
5729 ac_cv_path_zip2="$zip2" # Let the user override the test with a path.
5732 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
5733 for ac_dir in $PATH; do
5734 test -z "$ac_dir" && ac_dir=.
5735 if test -f $ac_dir/$ac_word; then
5736 ac_cv_path_zip2="$ac_dir/$ac_word"
5744 zip2="$ac_cv_path_zip2"
5745 if test -n "$zip2"; then
5746 echo "$ac_t""$zip2" 1>&6
5748 echo "$ac_t""no" 1>&6
5751 if test "$zip2" = ""; then
5756 ac_cv_zippy_program="$with_zippy"
5758 elif test -n "$ac_cv_zippy_program"; then
5759 echo "$ac_t""checking for zippy... (cached) $ac_cv_zippy_program" 1>&6
5762 if test ! -n "$ac_cv_zippy_program"; then
5764 for ac_prog in emacs
5766 # Extract the first word of "$ac_prog", so it can be a program name with args.
5767 set dummy $ac_prog; ac_word=$2
5768 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5769 echo "configure:5781: checking for $ac_word" >&5
5770 if eval "test \"`echo '$''{'ac_cv_prog_emacs_exe'+set}'`\" = set"; then
5771 echo $ac_n "(cached) $ac_c" 1>&6
5773 if test -n "$emacs_exe"; then
5774 ac_cv_prog_emacs_exe="$emacs_exe" # Let the user override the test.
5776 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
5777 for ac_dir in $PATH; do
5778 test -z "$ac_dir" && ac_dir=.
5779 if test -f $ac_dir/$ac_word; then
5780 ac_cv_prog_emacs_exe="$ac_prog"
5787 emacs_exe="$ac_cv_prog_emacs_exe"
5788 if test -n "$emacs_exe"; then
5789 echo "$ac_t""$emacs_exe" 1>&6
5791 echo "$ac_t""no" 1>&6
5794 test -n "$emacs_exe" && break
5797 for ac_prog in xemacs
5799 # Extract the first word of "$ac_prog", so it can be a program name with args.
5800 set dummy $ac_prog; ac_word=$2
5801 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5802 echo "configure:5814: checking for $ac_word" >&5
5803 if eval "test \"`echo '$''{'ac_cv_prog_xemacs_exe'+set}'`\" = set"; then
5804 echo $ac_n "(cached) $ac_c" 1>&6
5806 if test -n "$xemacs_exe"; then
5807 ac_cv_prog_xemacs_exe="$xemacs_exe" # Let the user override the test.
5809 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
5810 for ac_dir in $PATH; do
5811 test -z "$ac_dir" && ac_dir=.
5812 if test -f $ac_dir/$ac_word; then
5813 ac_cv_prog_xemacs_exe="$ac_prog"
5820 xemacs_exe="$ac_cv_prog_xemacs_exe"
5821 if test -n "$xemacs_exe"; then
5822 echo "$ac_t""$xemacs_exe" 1>&6
5824 echo "$ac_t""no" 1>&6
5827 test -n "$xemacs_exe" && break
5831 ac_cv_zippy_program=""
5832 eargs='-batch -q -nw --eval'
5834 if test -n "$emacs_exe" ; then
5835 echo $ac_n "checking for emacs yow""... $ac_c" 1>&6
5836 echo "configure:5848: checking for emacs yow" >&5
5838 # get emacs to tell us where the libexec directory is.
5840 dir=`$emacs_exe $eargs '(princ (concat exec-directory "\n"))' \
5841 2>/dev/null | tail -1`
5842 dir=`echo "$dir" | sed 's@///*@/@g;s@/$@@'`
5844 # try running libexec/yow and see if it exits without error.
5846 if test x"$dir" != x -a -x $dir/yow ; then
5847 if $dir/yow >&- 2>&- ; then
5848 ac_cv_zippy_program="$dir/yow"
5849 echo "$ac_t""$ac_cv_zippy_program" 1>&6
5851 echo "$ac_t""no" 1>&6
5856 if test -z "$ac_cv_zippy_program" ; then
5857 echo $ac_n "checking for xemacs yow""... $ac_c" 1>&6
5858 echo "configure:5870: checking for xemacs yow" >&5
5859 if test -n "$xemacs_exe" ; then
5861 # get xemacs to tell us where the libexec directory is.
5863 dir=`$xemacs_exe $eargs '(princ (concat exec-directory "\n"))' \
5864 2>/dev/null | tail -1`
5865 dir=`echo "$dir" | sed 's@///*@/@g;s@/$@@'`
5867 # try running libexec/yow and see if it exits without error.
5869 if test x"$dir" != x -a -x $dir/yow ; then
5870 if $dir/yow >&- 2>&- ; then
5871 ac_cv_zippy_program="$dir/yow"
5872 echo "$ac_t""$ac_cv_zippy_program" 1>&6
5875 # in some xemacs installations, the pathname of the yow.lines file
5876 # isn't hardcoded into the yow executable, and must be passed on
5877 # the command line. See if it's in libexec/../etc/.
5881 dir_up=`echo "$dir" | sed 's@/[^/]*$@@'`
5884 yow="yow -f $dir_up/etc/yow.lines"
5885 if $dir/$yow >&- 2>&- ; then
5886 ac_cv_zippy_program="$dir/$yow"
5887 echo "$ac_t""$ac_cv_zippy_program" 1>&6
5889 echo "$ac_t""no" 1>&6
5896 # if that didn't work, try for some other programs...
5897 if test -z "$ac_cv_zippy_program" ; then
5899 for ac_prog in fortune zippy yow
5901 # Extract the first word of "$ac_prog", so it can be a program name with args.
5902 set dummy $ac_prog; ac_word=$2
5903 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5904 echo "configure:5916: checking for $ac_word" >&5
5905 if eval "test \"`echo '$''{'ac_cv_prog_fortune'+set}'`\" = set"; then
5906 echo $ac_n "(cached) $ac_c" 1>&6
5908 if test -n "$fortune"; then
5909 ac_cv_prog_fortune="$fortune" # Let the user override the test.
5911 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
5912 for ac_dir in $PATH; do
5913 test -z "$ac_dir" && ac_dir=.
5914 if test -f $ac_dir/$ac_word; then
5915 ac_cv_prog_fortune="$ac_prog"
5922 fortune="$ac_cv_prog_fortune"
5923 if test -n "$fortune"; then
5924 echo "$ac_t""$fortune" 1>&6
5926 echo "$ac_t""no" 1>&6
5929 test -n "$fortune" && break
5932 # if that didn't work, try for those programs in /usr/games...
5933 if test -z "$fortune" ; then
5934 for ac_prog in fortune zippy yow
5936 # Extract the first word of "$ac_prog", so it can be a program name with args.
5937 set dummy $ac_prog; ac_word=$2
5938 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
5939 echo "configure:5951: checking for $ac_word" >&5
5940 if eval "test \"`echo '$''{'ac_cv_path_fortune'+set}'`\" = set"; then
5941 echo $ac_n "(cached) $ac_c" 1>&6
5945 ac_cv_path_fortune="$fortune" # Let the user override the test with a path.
5948 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
5949 for ac_dir in /usr/games:/usr/local/games$ac_dummy; do
5950 test -z "$ac_dir" && ac_dir=.
5951 if test -f $ac_dir/$ac_word; then
5952 ac_cv_path_fortune="$ac_dir/$ac_word"
5960 fortune="$ac_cv_path_fortune"
5961 if test -n "$fortune"; then
5962 echo "$ac_t""$fortune" 1>&6
5964 echo "$ac_t""no" 1>&6
5967 test -n "$fortune" && break
5969 test -n "$fortune" || fortune="fortune"
5975 if test -z "$ac_cv_zippy_program" ; then
5976 ac_cv_zippy_program=fortune
5979 cat >> confdefs.h <<EOF
5980 #define ZIPPY_PROGRAM "$ac_cv_zippy_program"
5987 # Allow locking to be disabled at compile-time.
5991 with_kerberos_req=unspecified
5993 with_shadow_req=unspecified
5996 # Check whether --enable-locking or --disable-locking was given.
5997 if test "${enable_locking+set}" = set; then
5998 enableval="$enable_locking"
5999 enable_locking="$enableval"
6004 if test $enable_locking = yes; then
6006 # Check for Kerberos.
6008 # Check whether --with-kerberos or --without-kerberos was given.
6009 if test "${with_kerberos+set}" = set; then
6010 withval="$with_kerberos"
6011 with_kerberos="$withval"; with_kerberos_req="$withval"
6018 case "$with_kerberos" in
6023 echo $ac_n "checking for Kerberos headers""... $ac_c" 1>&6
6024 echo "configure:6036: checking for Kerberos headers" >&5
6025 d=$with_kerberos/include
6027 X_CFLAGS="-I$d $X_CFLAGS"
6028 echo "$ac_t""$d" 1>&6
6030 echo "$ac_t""not found ($d: no such directory)" 1>&6
6033 echo $ac_n "checking for Kerberos libs""... $ac_c" 1>&6
6034 echo "configure:6046: checking for Kerberos libs" >&5
6035 d=$with_kerberos/lib
6037 X_LIBS="-L$d $X_LIBS"
6038 echo "$ac_t""$d" 1>&6
6040 echo "$ac_t""not found ($d: no such directory)" 1>&6
6043 # replace the directory string with "yes".
6044 with_kerberos_req="yes"
6045 with_kerberos=$with_kerberos_req
6050 echo "error: argument to --with-kerberos must be \"yes\", \"no\", or a directory."
6051 echo " If it is a directory, then \`DIR/include' will be added to"
6052 echo " the -I list, and \`DIR/lib' will be added to the -L list."
6057 # why is this necessary?
6058 # if we don't do this, then "./configure --with-motif=/usr/local/lesstif"
6059 # behaves as if "--with-zippy=/usr/local/lesstif" was also present!
6063 if test $with_kerberos = yes; then
6064 echo $ac_n "checking for Kerberos""... $ac_c" 1>&6
6065 echo "configure:6077: checking for Kerberos" >&5
6066 if eval "test \"`echo '$''{'ac_cv_kerberos'+set}'`\" = set"; then
6067 echo $ac_n "(cached) $ac_c" 1>&6
6070 ac_save_CPPFLAGS="$CPPFLAGS"
6071 if test \! -z "$includedir" ; then
6072 CPPFLAGS="$CPPFLAGS -I$includedir"
6074 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
6075 cat > conftest.$ac_ext <<EOF
6076 #line 6088 "configure"
6077 #include "confdefs.h"
6083 if { (eval echo configure:6095: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6087 echo "configure: failed program was:" >&5
6088 cat conftest.$ac_ext >&5
6093 CPPFLAGS="$ac_save_CPPFLAGS"
6096 echo "$ac_t""$ac_cv_kerberos" 1>&6
6097 if test $ac_cv_kerberos = yes ; then
6099 cat >> confdefs.h <<\EOF
6100 #define HAVE_KERBEROS 1
6104 # from Tim Showalter <tjs+@andrew.cmu.edu>
6105 PASSWD_LIBS="$PASSWD_LIBS -lkrb -ldes"
6106 echo $ac_n "checking for res_search""... $ac_c" 1>&6
6107 echo "configure:6119: checking for res_search" >&5
6108 if eval "test \"`echo '$''{'ac_cv_func_res_search'+set}'`\" = set"; then
6109 echo $ac_n "(cached) $ac_c" 1>&6
6111 cat > conftest.$ac_ext <<EOF
6112 #line 6124 "configure"
6113 #include "confdefs.h"
6114 /* System header to define __stub macros and hopefully few prototypes,
6115 which can conflict with char res_search(); below. */
6117 /* Override any gcc2 internal prototype to avoid an error. */
6118 /* We use char because int might match the return type of a gcc2
6119 builtin and then its argument prototype would still apply. */
6124 /* The GNU C library defines this for functions which it implements
6125 to always fail with ENOSYS. Some functions are actually named
6126 something starting with __ and the normal name is an alias. */
6127 #if defined (__stub_res_search) || defined (__stub___res_search)
6135 if { (eval echo configure:6147: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
6137 eval "ac_cv_func_res_search=yes"
6139 echo "configure: failed program was:" >&5
6140 cat conftest.$ac_ext >&5
6142 eval "ac_cv_func_res_search=no"
6147 if eval "test \"`echo '$ac_cv_func_'res_search`\" = yes"; then
6148 echo "$ac_t""yes" 1>&6
6151 echo "$ac_t""no" 1>&6
6152 echo $ac_n "checking for res_search in -lresolv""... $ac_c" 1>&6
6153 echo "configure:6165: checking for res_search in -lresolv" >&5
6154 ac_lib_var=`echo resolv'_'res_search | sed 'y%./+-%__p_%'`
6155 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
6156 echo $ac_n "(cached) $ac_c" 1>&6
6158 ac_save_LIBS="$LIBS"
6159 LIBS="-lresolv $LIBS"
6160 cat > conftest.$ac_ext <<EOF
6161 #line 6173 "configure"
6162 #include "confdefs.h"
6163 /* Override any gcc2 internal prototype to avoid an error. */
6164 /* We use char because int might match the return type of a gcc2
6165 builtin and then its argument prototype would still apply. */
6172 if { (eval echo configure:6184: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
6174 eval "ac_cv_lib_$ac_lib_var=yes"
6176 echo "configure: failed program was:" >&5
6177 cat conftest.$ac_ext >&5
6179 eval "ac_cv_lib_$ac_lib_var=no"
6182 LIBS="$ac_save_LIBS"
6185 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6186 echo "$ac_t""yes" 1>&6
6187 PASSWD_LIBS="${PASSWD_LIBS} -lresolv"
6189 echo "$ac_t""no" 1>&6
6190 echo "configure: warning: Can't find DNS resolver libraries needed for Kerberos" 1>&2
6198 elif test $with_kerberos != no; then
6199 echo "error: must be yes or no: --with-kerberos=$with_kerberos"
6203 # Next, check for the nine billion variants of shadow passwords...
6205 passwd_cruft_done=no
6206 # Check whether --with-shadow or --without-shadow was given.
6207 if test "${with_shadow+set}" = set; then
6208 withval="$with_shadow"
6209 with_shadow="$withval"; with_shadow_req="$withval"
6216 case "$with_shadow" in
6221 echo $ac_n "checking for shadow password headers""... $ac_c" 1>&6
6222 echo "configure:6234: checking for shadow password headers" >&5
6223 d=$with_shadow/include
6225 X_CFLAGS="-I$d $X_CFLAGS"
6226 echo "$ac_t""$d" 1>&6
6228 echo "$ac_t""not found ($d: no such directory)" 1>&6
6231 echo $ac_n "checking for shadow password libs""... $ac_c" 1>&6
6232 echo "configure:6244: checking for shadow password libs" >&5
6235 X_LIBS="-L$d $X_LIBS"
6236 echo "$ac_t""$d" 1>&6
6238 echo "$ac_t""not found ($d: no such directory)" 1>&6
6241 # replace the directory string with "yes".
6242 with_shadow_req="yes"
6243 with_shadow=$with_shadow_req
6248 echo "error: argument to --with-shadow must be \"yes\", \"no\", or a directory."
6249 echo " If it is a directory, then \`DIR/include' will be added to"
6250 echo " the -I list, and \`DIR/lib' will be added to the -L list."
6255 # why is this necessary?
6256 # if we don't do this, then "./configure --with-motif=/usr/local/lesstif"
6257 # behaves as if "--with-zippy=/usr/local/lesstif" was also present!
6261 if test $with_shadow = no; then
6262 passwd_cruft_done=yes
6263 elif test $with_shadow != yes; then
6264 echo "error: must be yes or no: --with-shadow=$with_shadow"
6269 # Sun's "adjunct" passwords.
6271 if test $passwd_cruft_done = no ; then
6272 echo $ac_n "checking for Sun-style shadow passwords""... $ac_c" 1>&6
6273 echo "configure:6285: checking for Sun-style shadow passwords" >&5
6274 if eval "test \"`echo '$''{'ac_cv_sun_adjunct'+set}'`\" = set"; then
6275 echo $ac_n "(cached) $ac_c" 1>&6
6278 ac_save_CPPFLAGS="$CPPFLAGS"
6279 if test \! -z "$includedir" ; then
6280 CPPFLAGS="$CPPFLAGS -I$includedir"
6282 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
6283 cat > conftest.$ac_ext <<EOF
6284 #line 6296 "configure"
6285 #include "confdefs.h"
6288 #include <sys/types.h>
6289 #include <sys/label.h>
6290 #include <sys/audit.h>
6293 struct passwd_adjunct *p = getpwanam("nobody");
6294 const char *pw = p->pwa_passwd;
6297 if { (eval echo configure:6309: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6299 ac_cv_sun_adjunct=yes
6301 echo "configure: failed program was:" >&5
6302 cat conftest.$ac_ext >&5
6304 ac_cv_sun_adjunct=no
6307 CPPFLAGS="$ac_save_CPPFLAGS"
6310 echo "$ac_t""$ac_cv_sun_adjunct" 1>&6
6311 if test $ac_cv_sun_adjunct = yes; then
6314 passwd_cruft_done=yes
6315 cat >> confdefs.h <<\EOF
6316 #define HAVE_ADJUNCT_PASSWD 1
6322 # DEC and SCO so-called "enhanced" security.
6324 if test $passwd_cruft_done = no ; then
6325 echo $ac_n "checking for DEC-style shadow passwords""... $ac_c" 1>&6
6326 echo "configure:6338: checking for DEC-style shadow passwords" >&5
6327 if eval "test \"`echo '$''{'ac_cv_enhanced_passwd'+set}'`\" = set"; then
6328 echo $ac_n "(cached) $ac_c" 1>&6
6331 ac_save_CPPFLAGS="$CPPFLAGS"
6332 if test \! -z "$includedir" ; then
6333 CPPFLAGS="$CPPFLAGS -I$includedir"
6335 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
6336 cat > conftest.$ac_ext <<EOF
6337 #line 6349 "configure"
6338 #include "confdefs.h"
6341 #include <sys/types.h>
6343 #include <sys/security.h>
6346 struct pr_passwd *p;
6348 set_auth_parameters(0, 0);
6349 check_auth_parameters();
6350 p = getprpwnam("nobody");
6351 pw = p->ufld.fd_encrypt;
6354 if { (eval echo configure:6366: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6356 ac_cv_enhanced_passwd=yes
6358 echo "configure: failed program was:" >&5
6359 cat conftest.$ac_ext >&5
6361 ac_cv_enhanced_passwd=no
6364 CPPFLAGS="$ac_save_CPPFLAGS"
6367 echo "$ac_t""$ac_cv_enhanced_passwd" 1>&6
6368 if test $ac_cv_enhanced_passwd = yes; then
6371 passwd_cruft_done=yes
6372 cat >> confdefs.h <<\EOF
6373 #define HAVE_ENHANCED_PASSWD 1
6377 # On SCO, getprpwnam() is in -lprot (which uses nap() from -lx)
6378 # (I'm told it needs -lcurses too, but I don't understand why.)
6379 echo $ac_n "checking for getprpwnam in -lprot""... $ac_c" 1>&6
6380 echo "configure:6392: checking for getprpwnam in -lprot" >&5
6381 ac_lib_var=`echo prot'_'getprpwnam | sed 'y%./+-%__p_%'`
6382 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
6383 echo $ac_n "(cached) $ac_c" 1>&6
6385 ac_save_LIBS="$LIBS"
6386 LIBS="-lprot -lx $LIBS"
6387 cat > conftest.$ac_ext <<EOF
6388 #line 6400 "configure"
6389 #include "confdefs.h"
6390 /* Override any gcc2 internal prototype to avoid an error. */
6391 /* We use char because int might match the return type of a gcc2
6392 builtin and then its argument prototype would still apply. */
6399 if { (eval echo configure:6411: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
6401 eval "ac_cv_lib_$ac_lib_var=yes"
6403 echo "configure: failed program was:" >&5
6404 cat conftest.$ac_ext >&5
6406 eval "ac_cv_lib_$ac_lib_var=no"
6409 LIBS="$ac_save_LIBS"
6412 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6413 echo "$ac_t""yes" 1>&6
6414 PASSWD_LIBS="$PASSWD_LIBS -lprot -lcurses -lx"
6416 echo "$ac_t""no" 1>&6
6417 # On DEC, getprpwnam() is in -lsecurity
6418 echo $ac_n "checking for getprpwnam in -lsecurity""... $ac_c" 1>&6
6419 echo "configure:6431: checking for getprpwnam in -lsecurity" >&5
6420 ac_lib_var=`echo security'_'getprpwnam | sed 'y%./+-%__p_%'`
6421 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
6422 echo $ac_n "(cached) $ac_c" 1>&6
6424 ac_save_LIBS="$LIBS"
6425 LIBS="-lsecurity $LIBS"
6426 cat > conftest.$ac_ext <<EOF
6427 #line 6439 "configure"
6428 #include "confdefs.h"
6429 /* Override any gcc2 internal prototype to avoid an error. */
6430 /* We use char because int might match the return type of a gcc2
6431 builtin and then its argument prototype would still apply. */
6438 if { (eval echo configure:6450: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
6440 eval "ac_cv_lib_$ac_lib_var=yes"
6442 echo "configure: failed program was:" >&5
6443 cat conftest.$ac_ext >&5
6445 eval "ac_cv_lib_$ac_lib_var=no"
6448 LIBS="$ac_save_LIBS"
6451 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6452 echo "$ac_t""yes" 1>&6
6453 PASSWD_LIBS="$PASSWD_LIBS -lsecurity"
6455 echo "$ac_t""no" 1>&6
6463 # HP's entry in the "Not Invented Here" Sweepstakes.
6465 if test $passwd_cruft_done = no ; then
6466 echo $ac_n "checking for HP-style shadow passwords""... $ac_c" 1>&6
6467 echo "configure:6479: checking for HP-style shadow passwords" >&5
6468 if eval "test \"`echo '$''{'ac_cv_hpux_passwd'+set}'`\" = set"; then
6469 echo $ac_n "(cached) $ac_c" 1>&6
6472 ac_save_CPPFLAGS="$CPPFLAGS"
6473 if test \! -z "$includedir" ; then
6474 CPPFLAGS="$CPPFLAGS -I$includedir"
6476 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
6477 cat > conftest.$ac_ext <<EOF
6478 #line 6490 "configure"
6479 #include "confdefs.h"
6482 #include <sys/types.h>
6484 #include <hpsecurity.h>
6487 struct s_passwd *p = getspwnam("nobody");
6488 const char *pw = p->pw_passwd;
6491 if { (eval echo configure:6503: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6493 ac_cv_hpux_passwd=yes
6495 echo "configure: failed program was:" >&5
6496 cat conftest.$ac_ext >&5
6498 ac_cv_hpux_passwd=no
6501 CPPFLAGS="$ac_save_CPPFLAGS"
6504 echo "$ac_t""$ac_cv_hpux_passwd" 1>&6
6505 if test $ac_cv_hpux_passwd = yes; then
6508 passwd_cruft_done=yes
6509 cat >> confdefs.h <<\EOF
6510 #define HAVE_HPUX_PASSWD 1
6514 # on HPUX, bigcrypt is in -lsec
6515 echo $ac_n "checking for bigcrypt in -lsec""... $ac_c" 1>&6
6516 echo "configure:6528: checking for bigcrypt in -lsec" >&5
6517 ac_lib_var=`echo sec'_'bigcrypt | sed 'y%./+-%__p_%'`
6518 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
6519 echo $ac_n "(cached) $ac_c" 1>&6
6521 ac_save_LIBS="$LIBS"
6523 cat > conftest.$ac_ext <<EOF
6524 #line 6536 "configure"
6525 #include "confdefs.h"
6526 /* Override any gcc2 internal prototype to avoid an error. */
6527 /* We use char because int might match the return type of a gcc2
6528 builtin and then its argument prototype would still apply. */
6535 if { (eval echo configure:6547: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
6537 eval "ac_cv_lib_$ac_lib_var=yes"
6539 echo "configure: failed program was:" >&5
6540 cat conftest.$ac_ext >&5
6542 eval "ac_cv_lib_$ac_lib_var=no"
6545 LIBS="$ac_save_LIBS"
6548 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6549 echo "$ac_t""yes" 1>&6
6550 PASSWD_LIBS="$PASSWD_LIBS -lsec"
6552 echo "$ac_t""no" 1>&6
6558 # Traditional (ha!) shadow passwords.
6560 if test $passwd_cruft_done = no ; then
6561 echo $ac_n "checking for generic shadow passwords""... $ac_c" 1>&6
6562 echo "configure:6574: checking for generic shadow passwords" >&5
6563 if eval "test \"`echo '$''{'ac_cv_shadow'+set}'`\" = set"; then
6564 echo $ac_n "(cached) $ac_c" 1>&6
6567 ac_save_CPPFLAGS="$CPPFLAGS"
6568 if test \! -z "$includedir" ; then
6569 CPPFLAGS="$CPPFLAGS -I$includedir"
6571 CPPFLAGS="$CPPFLAGS $X_CFLAGS"
6572 cat > conftest.$ac_ext <<EOF
6573 #line 6585 "configure"
6574 #include "confdefs.h"
6577 #include <sys/types.h>
6581 struct spwd *p = getspnam("nobody");
6582 const char *pw = p->sp_pwdp;
6585 if { (eval echo configure:6597: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6589 echo "configure: failed program was:" >&5
6590 cat conftest.$ac_ext >&5
6595 CPPFLAGS="$ac_save_CPPFLAGS"
6598 echo "$ac_t""$ac_cv_shadow" 1>&6
6599 if test $ac_cv_shadow = yes; then
6602 passwd_cruft_done=yes
6603 cat >> confdefs.h <<\EOF
6604 #define HAVE_SHADOW_PASSWD 1
6608 # On some systems (UnixWare 2.1), getspnam() is in -lgen instead of -lc.
6610 echo $ac_n "checking for getspnam in -lc""... $ac_c" 1>&6
6611 echo "configure:6623: checking for getspnam in -lc" >&5
6612 ac_lib_var=`echo c'_'getspnam | sed 'y%./+-%__p_%'`
6613 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
6614 echo $ac_n "(cached) $ac_c" 1>&6
6616 ac_save_LIBS="$LIBS"
6618 cat > conftest.$ac_ext <<EOF
6619 #line 6631 "configure"
6620 #include "confdefs.h"
6621 /* Override any gcc2 internal prototype to avoid an error. */
6622 /* We use char because int might match the return type of a gcc2
6623 builtin and then its argument prototype would still apply. */
6630 if { (eval echo configure:6642: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
6632 eval "ac_cv_lib_$ac_lib_var=yes"
6634 echo "configure: failed program was:" >&5
6635 cat conftest.$ac_ext >&5
6637 eval "ac_cv_lib_$ac_lib_var=no"
6640 LIBS="$ac_save_LIBS"
6643 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6644 echo "$ac_t""yes" 1>&6
6647 echo "$ac_t""no" 1>&6
6650 if test $have_getspnam = no ; then
6651 echo $ac_n "checking for getspnam in -lgen""... $ac_c" 1>&6
6652 echo "configure:6664: checking for getspnam in -lgen" >&5
6653 ac_lib_var=`echo gen'_'getspnam | sed 'y%./+-%__p_%'`
6654 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
6655 echo $ac_n "(cached) $ac_c" 1>&6
6657 ac_save_LIBS="$LIBS"
6659 cat > conftest.$ac_ext <<EOF
6660 #line 6672 "configure"
6661 #include "confdefs.h"
6662 /* Override any gcc2 internal prototype to avoid an error. */
6663 /* We use char because int might match the return type of a gcc2
6664 builtin and then its argument prototype would still apply. */
6671 if { (eval echo configure:6683: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
6673 eval "ac_cv_lib_$ac_lib_var=yes"
6675 echo "configure: failed program was:" >&5
6676 cat conftest.$ac_ext >&5
6678 eval "ac_cv_lib_$ac_lib_var=no"
6681 LIBS="$ac_save_LIBS"
6684 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6685 echo "$ac_t""yes" 1>&6
6686 have_getspnam=yes; PASSWD_LIBS="$PASSWD_LIBS -lgen"
6688 echo "$ac_t""no" 1>&6
6695 # On FreeBSD, getpwnam() and friends work just like on non-shadow-password
6696 # systems -- except you only get stuff in the pw_passwd field if the running
6697 # program is setuid. So, guess that we've got this lossage to contend with
6698 # if /etc/master.passwd exists, and default to a setuid installation.
6700 if test $passwd_cruft_done = no ; then
6701 echo $ac_n "checking for FreeBSD-style shadow passwords""... $ac_c" 1>&6
6702 echo "configure:6714: checking for FreeBSD-style shadow passwords" >&5
6703 if eval "test \"`echo '$''{'ac_cv_master_passwd'+set}'`\" = set"; then
6704 echo $ac_n "(cached) $ac_c" 1>&6
6706 if test -f /etc/master.passwd ; then
6707 ac_cv_master_passwd=yes
6709 ac_cv_master_passwd=no
6713 echo "$ac_t""$ac_cv_master_passwd" 1>&6
6714 if test $ac_cv_master_passwd = yes; then
6716 passwd_cruft_done=yes
6720 # On some systems (UnixWare 2.1), crypt() is in -lcrypt instead of -lc.
6722 echo $ac_n "checking for crypt in -lc""... $ac_c" 1>&6
6723 echo "configure:6735: checking for crypt in -lc" >&5
6724 ac_lib_var=`echo c'_'crypt | sed 'y%./+-%__p_%'`
6725 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
6726 echo $ac_n "(cached) $ac_c" 1>&6
6728 ac_save_LIBS="$LIBS"
6730 cat > conftest.$ac_ext <<EOF
6731 #line 6743 "configure"
6732 #include "confdefs.h"
6733 /* Override any gcc2 internal prototype to avoid an error. */
6734 /* We use char because int might match the return type of a gcc2
6735 builtin and then its argument prototype would still apply. */
6742 if { (eval echo configure:6754: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
6744 eval "ac_cv_lib_$ac_lib_var=yes"
6746 echo "configure: failed program was:" >&5
6747 cat conftest.$ac_ext >&5
6749 eval "ac_cv_lib_$ac_lib_var=no"
6752 LIBS="$ac_save_LIBS"
6755 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6756 echo "$ac_t""yes" 1>&6
6759 echo "$ac_t""no" 1>&6
6762 if test $have_crypt = no ; then
6763 echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6
6764 echo "configure:6776: checking for crypt in -lcrypt" >&5
6765 ac_lib_var=`echo crypt'_'crypt | sed 'y%./+-%__p_%'`
6766 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
6767 echo $ac_n "(cached) $ac_c" 1>&6
6769 ac_save_LIBS="$LIBS"
6770 LIBS="-lcrypt $LIBS"
6771 cat > conftest.$ac_ext <<EOF
6772 #line 6784 "configure"
6773 #include "confdefs.h"
6774 /* Override any gcc2 internal prototype to avoid an error. */
6775 /* We use char because int might match the return type of a gcc2
6776 builtin and then its argument prototype would still apply. */
6783 if { (eval echo configure:6795: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
6785 eval "ac_cv_lib_$ac_lib_var=yes"
6787 echo "configure: failed program was:" >&5
6788 cat conftest.$ac_ext >&5
6790 eval "ac_cv_lib_$ac_lib_var=no"
6793 LIBS="$ac_save_LIBS"
6796 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
6797 echo "$ac_t""yes" 1>&6
6798 have_crypt=yes; PASSWD_LIBS="$PASSWD_LIBS -lcrypt"
6800 echo "$ac_t""no" 1>&6
6806 # Most of the above shadow mechanisms will have set need_setuid to yes,
6807 # if they were found. But, on some systems, we need setuid even when
6808 # using plain old vanilla passwords.
6810 if test $need_setuid = no ; then
6812 *-hpux* | *-aix* | *-netbsd* | *-freebsd* | *-openbsd* )
6818 elif test $enable_locking = no; then
6819 cat >> confdefs.h <<\EOF
6820 #define NO_LOCKING 1
6824 echo "error: must be yes or no: --enable-locking=$enable_locking"
6830 if test \! -z "$includedir" ; then
6831 INCLUDES="-I$includedir"
6834 if test \! -z "$libdir" ; then
6835 LDFLAGS="$LDFLAGS -L$libdir"
6839 ##### should have options to override the DEPEND crap, I guess...
6845 # Done testing things -- now substitute in some stuff for the Makefiles.
6847 if test $have_motif = yes; then
6848 cat >> confdefs.h <<\EOF
6849 #define HAVE_MOTIF 1
6852 DIALOG_SRCS='$(MOTIF_SRCS)'
6853 DIALOG_OBJS='$(MOTIF_OBJS)'
6854 elif test $have_athena = yes; then
6855 cat >> confdefs.h <<\EOF
6856 #define HAVE_ATHENA 1
6859 DIALOG_SRCS='$(ATHENA_SRCS)'
6860 DIALOG_OBJS='$(ATHENA_OBJS)'
6866 if test $have_kerberos = yes; then
6867 PASSWD_SRCS='$(KERBEROS_SRCS)'
6868 PASSWD_OBJS='$(KERBEROS_OBJS)'
6870 PASSWD_SRCS='$(PWENT_SRCS)'
6871 PASSWD_OBJS='$(PWENT_OBJS)'
6874 if test $enable_locking = yes; then
6875 LOCK_SRCS='$(LOCK_SRCS_1) $(PASSWD_SRCS)'
6876 LOCK_OBJS='$(LOCK_OBJS_1) $(PASSWD_OBJS)'
6882 if test $need_setuid = yes; then
6884 INSTALL_SETUID='$(INSTALL) $(SUID_FLAGS)'
6887 INSTALL_SETUID='$(INSTALL_PROGRAM)'
6891 if test $have_gl = yes; then
6892 GL_EXES='$(GL_EXES)'
6893 GL_KLUDGE_1=${tab}${tab}${tab}${tab}${tab}${tab}${tab}${tab}${tab}' \'
6896 GL_KLUDGE_1=${tab}${tab}${tab}${tab}${tab}${tab}${tab}${tab}${tab}'\n'
6897 GL_KLUDGE_2='!'${tab}
6931 # Print some warnings before emitting the Makefiles.
6933 warn_prefix_1=" Warning:"
6934 warn_prefix_2=" Note:"
6935 warn_prefix="$warn_prefix_1"
6938 warnsep=' #################################################################'
6941 if test $warning = no ; then
6942 echo '' ; echo "$warnsep" ; echo ''
6949 if test $warning = long ; then echo '' ; fi
6951 echo "$warn_prefix $@"
6958 if test $was != no ; then echo '' ; fi
6959 echo "$warn_prefix $@"
6968 warn_prefix="$warn_prefix_2"
6970 warn_prefix="$warn_prefix_1"
6974 warn_prefix="$warn_prefix_2"
6976 warn_prefix="$warn_prefix_1"
6980 if test $with_sgi_req = yes -a $have_sgi = no ; then
6981 warn 'The SGI saver extension was requested, but was not found.'
6984 if test $with_mit_req = yes -a $have_mit = no ; then
6985 warn 'The MIT saver extension was requested, but was not found.'
6988 if test $with_xidle_req = yes -a $have_xidle = no ; then
6989 warn 'The XIdle extension was requested, but was not found.'
6992 if test $with_xshm_req = yes -a $have_xshm = no ; then
6993 warn 'The XSHM extension was requested, but was not found.'
6996 if test $with_sgivc_req = yes -a $have_sgivc = no ; then
6997 warn 'The SGI-VIDEO-CONTROL extension was requested, but was not found.'
7000 if test $with_dpms_req = yes -a $have_dpms = no ; then
7001 warn 'The DPMS extension was requested, but was not found.'
7004 if test $have_motif = no -a $have_athena = no ; then
7005 warnL "Neither Motif nor Athena widgets seem to be available;"
7006 warn2 "one or the other is required."
7007 proselytize_motif=no
7009 elif test $with_motif_req = yes -a $have_motif = no ; then
7010 warnL "Use of Motif was requested, but it wasn't found;"
7011 warn2 "Athena will be used instead."
7013 elif test $with_athena_req = yes -a $have_athena = no ; then
7014 warnL "Use of Athena was requested, but it wasn't found;"
7015 warn2 "Motif will be used instead."
7018 if test $have_motif = yes -a $have_lesstif = yes ; then
7020 preferred_lesstif=0.87
7022 if test $lesstif_version = unknown; then
7023 warnL "Unable to determine the LessTif version number!"
7024 warn2 "Make sure you are using version $preferred_lesstif or newer."
7025 warn2 "See <http://www.lesstif.org/>."
7027 elif test \! $lesstif_version -gt 82; then
7028 warnL "LessTif version $lesstif_version_string is being used."
7029 warn2 "LessTif versions 0.82 and earlier are too buggy to"
7030 warn2 "use with XScreenSaver; it is strongly recommended"
7031 warn2 "that you upgrade to at least version $preferred_lesstif!"
7032 warn2 "See <http://www.lesstif.org/>."
7034 elif test \! $lesstif_version -gt 86; then
7035 warnL "LessTif version $lesstif_version_string is being used."
7036 warn2 "LessTif versions 0.86 and earlier have a bug that"
7037 warn2 "can cause a security problem with xscreensaver."
7038 warn2 "If you want to use xscreensaver as a screen locker,"
7039 warn2 "it is strongly recommended that you upgrade to at"
7040 warn2 "least version $preferred_lesstif. See <http://www.lesstif.org/>."
7044 if test $proselytize_motif = yes ; then
7045 warnL "Athena widgets are being used instead of Motif."
7046 warn2 "XScreenSaver looks much better with Motif, and has"
7047 warn2 "a few extra features as well. Wouldn't you rather"
7048 warn2 "be using Motif? It is shipped by every commercial"
7049 warn2 "Unix vendor; and there is a free implementation"
7050 warn2 "available as well: see <http://www.lesstif.org/>."
7054 if test $have_gl = yes -a $ac_have_mesa_gl = yes ; then
7055 preferred_mesagl=2.7
7057 if test $ac_mesagl_version = unknown; then
7058 warnL "Unable to determine the MesaGL version number!"
7059 warn2 "Make sure you are using version $preferred_mesagl or newer."
7061 elif test \! $ac_mesagl_version -gt 2006; then
7062 warnL "MesaGL version $ac_mesagl_version_string is being used."
7063 warn2 "MesaGL versions 2.6 and earlier have a security bug."
7064 warn2 "It is strongly recommended that you upgrade to at"
7065 warn2 "least version $preferred_mesagl."
7070 if test $have_xpm = no ; then
7071 if test $with_xpm_req = yes ; then
7072 warnL 'Use of XPM was requested, but it was not found.'
7073 elif test $with_xpm_req = no ; then
7074 noteL 'The XPM library is not being used.'
7076 noteL 'The XPM library was not found.'
7080 warn2 'Some of the demos will not be as colorful as they'
7081 warn2 'could be. You might want to consider installing XPM'
7082 warn2 'and re-running configure. (Remember to delete the'
7083 warn2 'config.cache file first.) You can find XPM at most'
7084 warn2 'X11 archive sites, such as <http://sunsite.unc.edu/>.'
7087 if test $have_gl = no ; then
7088 if test $with_gl_req = yes ; then
7089 warnL 'Use of GL was requested, but it was not found.'
7090 elif test $with_gl_req = no ; then
7091 noteL 'The OpenGL 3D library is not being used.'
7093 noteL 'The OpenGL 3D library was not found.'
7097 warn2 'Those demos which use 3D will not be built or installed.'
7098 warn2 'You might want to consider installing OpenGL and'
7099 warn2 're-running configure. (Remember to delete the'
7100 warn2 "config.cache file first.) If your vendor doesn't ship"
7101 warn2 'their own implementation of OpenGL, you can get a free'
7102 warn2 'version at <http://www.ssec.wisc.edu/~brianp/Mesa.html>.'
7103 warn2 'For general OpenGL info, see <http://www.opengl.org/>.'
7107 if test $with_readdisplay_req = yes -a $have_readdisplay = no ; then
7108 warn 'Use of XReadDisplay was requested, but it was not found.'
7111 if test $with_sgivideo_req = yes -a $have_sgivideo = no ; then
7112 warn 'Use of the Iris Video Library was requested, but it was not found.'
7115 if test $with_kerberos_req = yes -a $have_kerberos = no ; then
7116 warn 'Use of Kerberos was requested, but it was not found.'
7119 if test $with_shadow_req = yes -a $have_shadow = no ; then
7120 warn 'Use of shadow passwords was requested, but they were not found.'
7123 if test -n "$with_zippy_req"; then
7124 if test "$with_zippy_req" != "$ac_cv_zippy_program" ; then
7125 warnL "$with_zippy_req was requested as the Zippy program,"
7126 warn2 "but was not found. The default will be used instead."
7130 if test $warning != no; then
7131 echo '' ; echo "$warnsep" ; echo ''
7136 cat > confcache <<\EOF
7137 # This file is a shell script that caches the results of configure
7138 # tests run on this system so they can be shared between configure
7139 # scripts and configure runs. It is not useful on other systems.
7140 # If it contains results you don't want to keep, you may remove or edit it.
7142 # By default, configure uses ./config.cache as the cache file,
7143 # creating it if it does not exist already. You can give configure
7144 # the --cache-file=FILE option to use a different cache file; that is
7145 # what configure does when it calls configure scripts in
7146 # subdirectories, so they share the cache.
7147 # Giving --cache-file=/dev/null disables caching, for debugging configure.
7148 # config.status only pays attention to the cache file if you give it the
7149 # --recheck option to rerun configure.
7152 # The following way of writing the cache mishandles newlines in values,
7153 # but we know of no workaround that is simple, portable, and efficient.
7154 # So, don't put newlines in cache variables' values.
7155 # Ultrix sh set writes to stderr and can't be redirected directly,
7156 # and sets the high bit in the cache file unless we assign to the vars.
7158 case `(ac_space=' '; set) 2>&1` in
7160 # `set' does not quote correctly, so add quotes (double-quote substitution
7161 # turns \\\\ into \\, and sed turns \\ into \).
7163 -e "s/'/'\\\\''/g" \
7164 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
7167 # `set' quotes correctly as required by POSIX, so do not add quotes.
7168 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
7171 if cmp -s $cache_file confcache; then
7174 if test -w $cache_file; then
7175 echo "updating cache $cache_file"
7176 cat confcache > $cache_file
7178 echo "not updating unwritable cache $cache_file"
7183 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
7185 test "x$prefix" = xNONE && prefix=$ac_default_prefix
7186 # Let make expand exec_prefix.
7187 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
7189 # Any assignment to VPATH causes Sun make to only execute
7190 # the first set of double-colon rules, so remove it if not needed.
7191 # If there is a colon in the path, we need to keep it.
7192 if test "x$srcdir" = x.; then
7193 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
7196 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
7198 DEFS=-DHAVE_CONFIG_H
7200 # Without the "./", some shells look in PATH for config.status.
7201 : ${CONFIG_STATUS=./config.status}
7203 echo creating $CONFIG_STATUS
7204 rm -f $CONFIG_STATUS
7205 cat > $CONFIG_STATUS <<EOF
7207 # Generated automatically by configure.
7208 # Run this file to recreate the current configuration.
7209 # This directory was configured as follows,
7210 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
7212 # $0 $ac_configure_args
7214 # Compiler output produced by configure, useful for debugging
7215 # configure, is in ./config.log if it exists.
7217 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
7220 case "\$ac_option" in
7221 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
7222 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
7223 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
7224 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
7225 echo "$CONFIG_STATUS generated by autoconf version 2.12"
7227 -help | --help | --hel | --he | --h)
7228 echo "\$ac_cs_usage"; exit 0 ;;
7229 *) echo "\$ac_cs_usage"; exit 1 ;;
7233 ac_given_srcdir=$srcdir
7234 ac_given_INSTALL="$INSTALL"
7236 trap 'rm -fr `echo "Makefile
7241 driver/XScreenSaver.ad config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
7243 cat >> $CONFIG_STATUS <<EOF
7245 # Protect against being on the right side of a sed subst in config.status.
7246 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
7247 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
7250 s%@CFLAGS@%$CFLAGS%g
7251 s%@CPPFLAGS@%$CPPFLAGS%g
7252 s%@CXXFLAGS@%$CXXFLAGS%g
7254 s%@LDFLAGS@%$LDFLAGS%g
7256 s%@exec_prefix@%$exec_prefix%g
7257 s%@prefix@%$prefix%g
7258 s%@program_transform_name@%$program_transform_name%g
7259 s%@bindir@%$bindir%g
7260 s%@sbindir@%$sbindir%g
7261 s%@libexecdir@%$libexecdir%g
7262 s%@datadir@%$datadir%g
7263 s%@sysconfdir@%$sysconfdir%g
7264 s%@sharedstatedir@%$sharedstatedir%g
7265 s%@localstatedir@%$localstatedir%g
7266 s%@libdir@%$libdir%g
7267 s%@includedir@%$includedir%g
7268 s%@oldincludedir@%$oldincludedir%g
7269 s%@infodir@%$infodir%g
7270 s%@mandir@%$mandir%g
7272 s%@host_alias@%$host_alias%g
7273 s%@host_cpu@%$host_cpu%g
7274 s%@host_vendor@%$host_vendor%g
7275 s%@host_os@%$host_os%g
7278 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
7279 s%@INSTALL_DATA@%$INSTALL_DATA%g
7280 s%@SET_MAKE@%$SET_MAKE%g
7281 s%@X_CFLAGS@%$X_CFLAGS%g
7282 s%@X_PRE_LIBS@%$X_PRE_LIBS%g
7283 s%@X_LIBS@%$X_LIBS%g
7284 s%@X_EXTRA_LIBS@%$X_EXTRA_LIBS%g
7286 s%@emacs_exe@%$emacs_exe%g
7287 s%@xemacs_exe@%$xemacs_exe%g
7288 s%@fortune@%$fortune%g
7289 s%@INCLUDES@%$INCLUDES%g
7290 s%@SAVER_LIBS@%$SAVER_LIBS%g
7291 s%@HACK_LIBS@%$HACK_LIBS%g
7292 s%@XPM_LIBS@%$XPM_LIBS%g
7293 s%@GL_LIBS@%$GL_LIBS%g
7294 s%@PASSWD_LIBS@%$PASSWD_LIBS%g
7295 s%@INSTALL_SETUID@%$INSTALL_SETUID%g
7296 s%@INSTALL_DIRS@%$INSTALL_DIRS%g
7297 s%@NEED_SETUID@%$NEED_SETUID%g
7298 s%@SGI_VIDEO_OBJS@%$SGI_VIDEO_OBJS%g
7299 s%@SGI_VIDEO_LIBS@%$SGI_VIDEO_LIBS%g
7300 s%@DIALOG_SRCS@%$DIALOG_SRCS%g
7301 s%@DIALOG_OBJS@%$DIALOG_OBJS%g
7302 s%@PASSWD_SRCS@%$PASSWD_SRCS%g
7303 s%@PASSWD_OBJS@%$PASSWD_OBJS%g
7304 s%@XMU_SRCS@%$XMU_SRCS%g
7305 s%@XMU_OBJS@%$XMU_OBJS%g
7306 s%@LOCK_SRCS@%$LOCK_SRCS%g
7307 s%@LOCK_OBJS@%$LOCK_OBJS%g
7308 s%@GL_EXES@%$GL_EXES%g
7309 s%@GL_KLUDGE_1@%$GL_KLUDGE_1%g
7310 s%@GL_KLUDGE_2@%$GL_KLUDGE_2%g
7311 s%@HACKDIR@%$HACKDIR%g
7312 s%@APPDEFAULTS@%$APPDEFAULTS%g
7313 s%@DEPEND@%$DEPEND%g
7314 s%@DEPEND_FLAGS@%$DEPEND_FLAGS%g
7315 s%@DEPEND_DEFINES@%$DEPEND_DEFINES%g
7320 cat >> $CONFIG_STATUS <<\EOF
7322 # Split the substitutions into bite-sized pieces for seds with
7323 # small command number limits, like on Digital OSF/1 and HP-UX.
7324 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
7325 ac_file=1 # Number of current file.
7326 ac_beg=1 # First line for current file.
7327 ac_end=$ac_max_sed_cmds # Line after last line for current file.
7330 while $ac_more_lines; do
7331 if test $ac_beg -gt 1; then
7332 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
7334 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
7336 if test ! -s conftest.s$ac_file; then
7338 rm -f conftest.s$ac_file
7340 if test -z "$ac_sed_cmds"; then
7341 ac_sed_cmds="sed -f conftest.s$ac_file"
7343 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
7345 ac_file=`expr $ac_file + 1`
7347 ac_end=`expr $ac_end + $ac_max_sed_cmds`
7350 if test -z "$ac_sed_cmds"; then
7355 cat >> $CONFIG_STATUS <<EOF
7357 CONFIG_FILES=\${CONFIG_FILES-"Makefile
7362 driver/XScreenSaver.ad"}
7364 cat >> $CONFIG_STATUS <<\EOF
7365 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
7366 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
7368 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
7369 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
7370 *) ac_file_in="${ac_file}.in" ;;
7373 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
7375 # Remove last slash and all that follows it. Not all systems have dirname.
7376 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
7377 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
7378 # The file is in a subdirectory.
7379 test ! -d "$ac_dir" && mkdir "$ac_dir"
7380 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
7381 # A "../" for each directory in $ac_dir_suffix.
7382 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
7384 ac_dir_suffix= ac_dots=
7387 case "$ac_given_srcdir" in
7389 if test -z "$ac_dots"; then top_srcdir=.
7390 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
7391 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
7393 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
7394 top_srcdir="$ac_dots$ac_given_srcdir" ;;
7397 case "$ac_given_INSTALL" in
7398 [/$]*) INSTALL="$ac_given_INSTALL" ;;
7399 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
7402 echo creating "$ac_file"
7404 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
7406 *Makefile*) ac_comsub="1i\\
7407 # $configure_input" ;;
7411 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
7413 s%@configure_input@%$configure_input%g
7414 s%@srcdir@%$srcdir%g
7415 s%@top_srcdir@%$top_srcdir%g
7416 s%@INSTALL@%$INSTALL%g
7417 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
7421 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
7422 # NAME is the cpp macro being defined and VALUE is the value it is being given.
7424 # ac_d sets the value in "#define NAME VALUE" lines.
7425 ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
7426 ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
7429 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
7430 ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
7431 ac_uB='\([ ]\)%\1#\2define\3'
7434 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
7435 ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
7436 ac_eB='$%\1#\2define\3'
7440 if test "${CONFIG_HEADERS+set}" != set; then
7442 cat >> $CONFIG_STATUS <<EOF
7443 CONFIG_HEADERS="config.h"
7445 cat >> $CONFIG_STATUS <<\EOF
7447 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
7448 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
7450 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
7451 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
7452 *) ac_file_in="${ac_file}.in" ;;
7455 echo creating $ac_file
7457 rm -f conftest.frag conftest.in conftest.out
7458 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
7459 cat $ac_file_inputs > conftest.in
7463 # Transform confdefs.h into a sed script conftest.vals that substitutes
7464 # the proper values into config.h.in to produce config.h. And first:
7465 # Protect against being on the right side of a sed subst in config.status.
7466 # Protect against being in an unquoted here document in config.status.
7468 cat > conftest.hdr <<\EOF
7471 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
7475 sed -n -f conftest.hdr confdefs.h > conftest.vals
7478 # This sed command replaces #undef with comments. This is necessary, for
7479 # example, in the case of _POSIX_SOURCE, which is predefined and required
7480 # on some systems where configure will not decide to define it.
7481 cat >> conftest.vals <<\EOF
7482 s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
7485 # Break up conftest.vals because some shells have a limit on
7486 # the size of here documents, and old seds have small limits too.
7491 ac_lines=`grep -c . conftest.vals`
7492 # grep -c gives empty output for an empty file on some AIX systems.
7493 if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
7494 # Write a limited-size here document to conftest.frag.
7495 echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
7496 sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
7498 sed -f conftest.frag conftest.in > conftest.out
7500 mv conftest.out conftest.in
7502 sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
7504 mv conftest.tail conftest.vals
7508 cat >> $CONFIG_STATUS <<\EOF
7509 rm -f conftest.frag conftest.h
7510 echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
7511 cat conftest.in >> conftest.h
7513 if cmp -s $ac_file conftest.h 2>/dev/null; then
7514 echo "$ac_file is unchanged"
7517 # Remove last slash and all that follows it. Not all systems have dirname.
7518 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
7519 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
7520 # The file is in a subdirectory.
7521 test ! -d "$ac_dir" && mkdir "$ac_dir"
7524 mv conftest.h $ac_file
7529 cat >> $CONFIG_STATUS <<EOF
7532 cat >> $CONFIG_STATUS <<\EOF
7536 chmod +x $CONFIG_STATUS
7537 rm -fr confdefs* $ac_clean_files
7538 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
7541 # You are in a twisty maze of namespaces and syntaxes, all alike.
7542 # Fuck the skull of Unix.
7544 eval bindir=${bindir}
7545 eval bindir=${bindir}
7546 eval bindir=${bindir}
7547 eval bindir=${bindir}
7548 eval bindir=${bindir}
7549 eval bindir=${bindir}
7550 eval HACKDIR=${HACKDIR}
7551 eval HACKDIR=${HACKDIR}
7552 eval HACKDIR=${HACKDIR}
7553 eval HACKDIR=${HACKDIR}
7554 eval HACKDIR=${HACKDIR}
7555 eval HACKDIR=${HACKDIR}
7560 echo ' When you run "make install", the "xscreensaver" and'
7561 echo ' "xscreensaver-command" executables will be installed in'
7564 echo " The various graphics demos (80+ different executables) will"
7565 echo " be installed in ${HACKDIR}."
7567 echo " If you would prefer the demos to be installed elsewhere"
7568 echo " (for example, in a dedicated directory) you should re-run"
7569 echo " configure with the --enable-subdir=DIR option. For more"
7570 echo " information, run $0 --help."