Import filemode module from gnulib.
[bpt/emacs.git] / configure
CommitLineData
067d23c9
KY
1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
d6974efa 3# Generated by GNU Autoconf 2.68 for emacs 24.0.50.
067d23c9
KY
4#
5#
6# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
2018939f
AS
7# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software
8# Foundation, Inc.
067d23c9
KY
9#
10#
11# This configure script is free software; the Free Software Foundation
12# gives unlimited permission to copy, distribute and modify it.
13## -------------------- ##
14## M4sh Initialization. ##
15## -------------------- ##
16
17# Be more Bourne compatible
18DUALCASE=1; export DUALCASE # for MKS sh
19if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
20 emulate sh
21 NULLCMD=:
22 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23 # is contrary to our usage. Disable this feature.
24 alias -g '${1+"$@"}'='"$@"'
25 setopt NO_GLOB_SUBST
26else
27 case `(set -o) 2>/dev/null` in #(
28 *posix*) :
29 set -o posix ;; #(
30 *) :
31 ;;
32esac
33fi
34
35
36as_nl='
37'
38export as_nl
39# Printing a long string crashes Solaris 7 /usr/bin/printf.
40as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
43# Prefer a ksh shell builtin over an external printf program on Solaris,
44# but without wasting forks for bash or zsh.
45if test -z "$BASH_VERSION$ZSH_VERSION" \
46 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
47 as_echo='print -r --'
48 as_echo_n='print -rn --'
49elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
50 as_echo='printf %s\n'
51 as_echo_n='printf %s'
52else
53 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
54 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
55 as_echo_n='/usr/ucb/echo -n'
56 else
57 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
58 as_echo_n_body='eval
59 arg=$1;
60 case $arg in #(
61 *"$as_nl"*)
62 expr "X$arg" : "X\\(.*\\)$as_nl";
63 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
64 esac;
65 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
66 '
67 export as_echo_n_body
68 as_echo_n='sh -c $as_echo_n_body as_echo'
69 fi
70 export as_echo_body
71 as_echo='sh -c $as_echo_body as_echo'
72fi
73
74# The user is always right.
75if test "${PATH_SEPARATOR+set}" != set; then
76 PATH_SEPARATOR=:
77 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
78 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
79 PATH_SEPARATOR=';'
80 }
81fi
82
83
84# IFS
85# We need space, tab and new line, in precisely that order. Quoting is
86# there to prevent editors from complaining about space-tab.
87# (If _AS_PATH_WALK were called with IFS unset, it would disable word
88# splitting by setting IFS to empty value.)
89IFS=" "" $as_nl"
90
91# Find who we are. Look in the path if we contain no directory separator.
d6974efa 92as_myself=
067d23c9
KY
93case $0 in #((
94 *[\\/]* ) as_myself=$0 ;;
95 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
96for as_dir in $PATH
97do
98 IFS=$as_save_IFS
99 test -z "$as_dir" && as_dir=.
100 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
101 done
102IFS=$as_save_IFS
103
104 ;;
105esac
106# We did not find ourselves, most probably we were run as `sh COMMAND'
107# in which case we are not to be found in the path.
108if test "x$as_myself" = x; then
109 as_myself=$0
110fi
111if test ! -f "$as_myself"; then
112 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
113 exit 1
114fi
115
116# Unset variables that we do not need and which cause bugs (e.g. in
117# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
118# suppresses any "Segmentation fault" message there. '((' could
119# trigger a bug in pdksh 5.2.14.
120for as_var in BASH_ENV ENV MAIL MAILPATH
121do eval test x\${$as_var+set} = xset \
122 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
123done
124PS1='$ '
125PS2='> '
126PS4='+ '
127
128# NLS nuisances.
129LC_ALL=C
130export LC_ALL
131LANGUAGE=C
132export LANGUAGE
133
134# CDPATH.
135(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
136
137if test "x$CONFIG_SHELL" = x; then
138 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
139 emulate sh
140 NULLCMD=:
141 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
142 # is contrary to our usage. Disable this feature.
143 alias -g '\${1+\"\$@\"}'='\"\$@\"'
144 setopt NO_GLOB_SUBST
145else
146 case \`(set -o) 2>/dev/null\` in #(
147 *posix*) :
148 set -o posix ;; #(
149 *) :
150 ;;
151esac
152fi
153"
154 as_required="as_fn_return () { (exit \$1); }
155as_fn_success () { as_fn_return 0; }
156as_fn_failure () { as_fn_return 1; }
157as_fn_ret_success () { return 0; }
158as_fn_ret_failure () { return 1; }
159
160exitcode=0
161as_fn_success || { exitcode=1; echo as_fn_success failed.; }
162as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
163as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
164as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
165if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
166
167else
168 exitcode=1; echo positional parameters were not saved.
169fi
170test x\$exitcode = x0 || exit 1"
171 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
172 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
173 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
174 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
175test \$(( 1 + 1 )) = 2 || exit 1"
176 if (eval "$as_required") 2>/dev/null; then :
177 as_have_required=yes
178else
179 as_have_required=no
180fi
181 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
182
183else
184 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
185as_found=false
186for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
187do
188 IFS=$as_save_IFS
189 test -z "$as_dir" && as_dir=.
190 as_found=:
191 case $as_dir in #(
192 /*)
193 for as_base in sh bash ksh sh5; do
194 # Try only shells that exist, to save several forks.
195 as_shell=$as_dir/$as_base
196 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
197 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
198 CONFIG_SHELL=$as_shell as_have_required=yes
199 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
200 break 2
201fi
202fi
203 done;;
204 esac
205 as_found=false
206done
207$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
208 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
209 CONFIG_SHELL=$SHELL as_have_required=yes
210fi; }
211IFS=$as_save_IFS
212
213
214 if test "x$CONFIG_SHELL" != x; then :
215 # We cannot yet assume a decent shell, so we have to provide a
216 # neutralization value for shells without unset; and this also
217 # works around shells that cannot unset nonexistent variables.
d6974efa 218 # Preserve -v and -x to the replacement shell.
067d23c9
KY
219 BASH_ENV=/dev/null
220 ENV=/dev/null
221 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
222 export CONFIG_SHELL
d6974efa
PE
223 case $- in # ((((
224 *v*x* | *x*v* ) as_opts=-vx ;;
225 *v* ) as_opts=-v ;;
226 *x* ) as_opts=-x ;;
227 * ) as_opts= ;;
228 esac
229 exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"}
067d23c9
KY
230fi
231
232 if test x$as_have_required = xno; then :
233 $as_echo "$0: This script requires a shell more modern than all"
234 $as_echo "$0: the shells that I found on your system."
235 if test x${ZSH_VERSION+set} = xset ; then
236 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
237 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
238 else
239 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
240$0: including any error possibly output before this
241$0: message. Then install a modern shell, or manually run
242$0: the script under such a shell if you do have one."
243 fi
244 exit 1
245fi
246fi
247fi
248SHELL=${CONFIG_SHELL-/bin/sh}
249export SHELL
250# Unset more variables known to interfere with behavior of common tools.
251CLICOLOR_FORCE= GREP_OPTIONS=
252unset CLICOLOR_FORCE GREP_OPTIONS
253
254## --------------------- ##
255## M4sh Shell Functions. ##
256## --------------------- ##
257# as_fn_unset VAR
258# ---------------
259# Portably unset VAR.
260as_fn_unset ()
261{
262 { eval $1=; unset $1;}
263}
264as_unset=as_fn_unset
265
266# as_fn_set_status STATUS
267# -----------------------
268# Set $? to STATUS, without forking.
269as_fn_set_status ()
270{
271 return $1
272} # as_fn_set_status
273
274# as_fn_exit STATUS
275# -----------------
276# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
277as_fn_exit ()
278{
279 set +e
280 as_fn_set_status $1
281 exit $1
282} # as_fn_exit
283
284# as_fn_mkdir_p
285# -------------
286# Create "$as_dir" as a directory, including parents if necessary.
287as_fn_mkdir_p ()
288{
289
290 case $as_dir in #(
291 -*) as_dir=./$as_dir;;
292 esac
293 test -d "$as_dir" || eval $as_mkdir_p || {
294 as_dirs=
295 while :; do
296 case $as_dir in #(
297 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
298 *) as_qdir=$as_dir;;
299 esac
300 as_dirs="'$as_qdir' $as_dirs"
301 as_dir=`$as_dirname -- "$as_dir" ||
302$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
303 X"$as_dir" : 'X\(//\)[^/]' \| \
304 X"$as_dir" : 'X\(//\)$' \| \
305 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
306$as_echo X"$as_dir" |
307 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
308 s//\1/
309 q
310 }
311 /^X\(\/\/\)[^/].*/{
312 s//\1/
313 q
314 }
315 /^X\(\/\/\)$/{
316 s//\1/
317 q
318 }
319 /^X\(\/\).*/{
320 s//\1/
321 q
322 }
323 s/.*/./; q'`
324 test -d "$as_dir" && break
325 done
326 test -z "$as_dirs" || eval "mkdir $as_dirs"
2018939f 327 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
067d23c9
KY
328
329
330} # as_fn_mkdir_p
331# as_fn_append VAR VALUE
332# ----------------------
333# Append the text in VALUE to the end of the definition contained in VAR. Take
334# advantage of any shell optimizations that allow amortized linear growth over
335# repeated appends, instead of the typical quadratic growth present in naive
336# implementations.
337if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
338 eval 'as_fn_append ()
339 {
340 eval $1+=\$2
341 }'
342else
343 as_fn_append ()
344 {
345 eval $1=\$$1\$2
346 }
347fi # as_fn_append
348
349# as_fn_arith ARG...
350# ------------------
351# Perform arithmetic evaluation on the ARGs, and store the result in the
352# global $as_val. Take advantage of shells that can avoid forks. The arguments
353# must be portable across $(()) and expr.
354if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
355 eval 'as_fn_arith ()
356 {
357 as_val=$(( $* ))
358 }'
359else
360 as_fn_arith ()
361 {
362 as_val=`expr "$@" || test $? -eq 1`
363 }
364fi # as_fn_arith
365
366
2018939f
AS
367# as_fn_error STATUS ERROR [LINENO LOG_FD]
368# ----------------------------------------
067d23c9
KY
369# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
370# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
2018939f 371# script with STATUS, using 1 if that was 0.
067d23c9
KY
372as_fn_error ()
373{
2018939f
AS
374 as_status=$1; test $as_status -eq 0 && as_status=1
375 if test "$4"; then
376 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
377 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
067d23c9 378 fi
2018939f 379 $as_echo "$as_me: error: $2" >&2
067d23c9
KY
380 as_fn_exit $as_status
381} # as_fn_error
382
383if expr a : '\(a\)' >/dev/null 2>&1 &&
384 test "X`expr 00001 : '.*\(...\)'`" = X001; then
385 as_expr=expr
386else
387 as_expr=false
388fi
389
390if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
391 as_basename=basename
392else
393 as_basename=false
394fi
395
396if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
397 as_dirname=dirname
398else
399 as_dirname=false
400fi
401
402as_me=`$as_basename -- "$0" ||
403$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
404 X"$0" : 'X\(//\)$' \| \
405 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
406$as_echo X/"$0" |
407 sed '/^.*\/\([^/][^/]*\)\/*$/{
408 s//\1/
409 q
410 }
411 /^X\/\(\/\/\)$/{
412 s//\1/
413 q
414 }
415 /^X\/\(\/\).*/{
416 s//\1/
417 q
418 }
419 s/.*/./; q'`
420
421# Avoid depending upon Character Ranges.
422as_cr_letters='abcdefghijklmnopqrstuvwxyz'
423as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
424as_cr_Letters=$as_cr_letters$as_cr_LETTERS
425as_cr_digits='0123456789'
426as_cr_alnum=$as_cr_Letters$as_cr_digits
427
428
429 as_lineno_1=$LINENO as_lineno_1a=$LINENO
430 as_lineno_2=$LINENO as_lineno_2a=$LINENO
431 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
432 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
433 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
434 sed -n '
435 p
436 /[$]LINENO/=
437 ' <$as_myself |
438 sed '
439 s/[$]LINENO.*/&-/
440 t lineno
441 b
442 :lineno
443 N
444 :loop
445 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
446 t loop
447 s/-\n.*//
448 ' >$as_me.lineno &&
449 chmod +x "$as_me.lineno" ||
450 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
451
452 # Don't try to exec as it changes $[0], causing all sort of problems
453 # (the dirname of $[0] is not the place where we might find the
454 # original and so on. Autoconf is especially sensitive to this).
455 . "./$as_me.lineno"
456 # Exit status is that of the last command.
457 exit
458}
459
460ECHO_C= ECHO_N= ECHO_T=
461case `echo -n x` in #(((((
462-n*)
463 case `echo 'xy\c'` in
464 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
465 xy) ECHO_C='\c';;
466 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
467 ECHO_T=' ';;
468 esac;;
469*)
470 ECHO_N='-n';;
471esac
472
473rm -f conf$$ conf$$.exe conf$$.file
474if test -d conf$$.dir; then
475 rm -f conf$$.dir/conf$$.file
476else
477 rm -f conf$$.dir
478 mkdir conf$$.dir 2>/dev/null
479fi
480if (echo >conf$$.file) 2>/dev/null; then
481 if ln -s conf$$.file conf$$ 2>/dev/null; then
482 as_ln_s='ln -s'
483 # ... but there are two gotchas:
484 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
485 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
486 # In both cases, we have to default to `cp -p'.
487 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
488 as_ln_s='cp -p'
489 elif ln conf$$.file conf$$ 2>/dev/null; then
490 as_ln_s=ln
491 else
492 as_ln_s='cp -p'
493 fi
494else
495 as_ln_s='cp -p'
496fi
497rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
498rmdir conf$$.dir 2>/dev/null
499
500if mkdir -p . 2>/dev/null; then
501 as_mkdir_p='mkdir -p "$as_dir"'
502else
503 test -d ./-p && rmdir ./-p
504 as_mkdir_p=false
505fi
506
507if test -x / >/dev/null 2>&1; then
508 as_test_x='test -x'
509else
510 if ls -dL / >/dev/null 2>&1; then
511 as_ls_L_option=L
512 else
513 as_ls_L_option=
514 fi
515 as_test_x='
516 eval sh -c '\''
517 if test -d "$1"; then
518 test -d "$1/.";
519 else
520 case $1 in #(
521 -*)set "./$1";;
522 esac;
523 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
524 ???[sx]*):;;*)false;;esac;fi
525 '\'' sh
526 '
527fi
528as_executable_p=$as_test_x
529
530# Sed expression to map a string onto a valid CPP name.
531as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
532
533# Sed expression to map a string onto a valid variable name.
534as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
535
536
537test -n "$DJDIR" || exec 7<&0 </dev/null
538exec 6>&1
539
540# Name of the host.
2018939f 541# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
067d23c9
KY
542# so uname gets run too.
543ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
544
545#
546# Initializations.
547#
548ac_default_prefix=/usr/local
549ac_clean_files=
550ac_config_libobj_dir=.
551LIBOBJS=
552cross_compiling=no
553subdirs=
554MFLAGS=
555MAKEFLAGS=
556
557# Identity of this package.
558PACKAGE_NAME='emacs'
559PACKAGE_TARNAME='emacs'
560PACKAGE_VERSION='24.0.50'
561PACKAGE_STRING='emacs 24.0.50'
562PACKAGE_BUGREPORT=''
563PACKAGE_URL=''
564
565ac_unique_file="src/lisp.h"
566# Factoring default headers for most tests.
567ac_includes_default="\
568#include <stdio.h>
569#ifdef HAVE_SYS_TYPES_H
570# include <sys/types.h>
571#endif
572#ifdef HAVE_SYS_STAT_H
573# include <sys/stat.h>
574#endif
575#ifdef STDC_HEADERS
576# include <stdlib.h>
577# include <stddef.h>
578#else
579# ifdef HAVE_STDLIB_H
580# include <stdlib.h>
581# endif
582#endif
583#ifdef HAVE_STRING_H
584# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
585# include <memory.h>
586# endif
587# include <string.h>
588#endif
589#ifdef HAVE_STRINGS_H
590# include <strings.h>
591#endif
592#ifdef HAVE_INTTYPES_H
593# include <inttypes.h>
594#endif
595#ifdef HAVE_STDINT_H
596# include <stdint.h>
597#endif
598#ifdef HAVE_UNISTD_H
599# include <unistd.h>
600#endif"
601
067d23c9 602ac_header_list=
e275c824
PE
603gl_getopt_required=POSIX
604gl_getopt_required=POSIX
067d23c9 605ac_func_list=
743c80a7
PE
606ac_subst_vars='gltests_LTLIBOBJS
607gltests_LIBOBJS
608gl_LTLIBOBJS
609gl_LIBOBJS
610am__EXEEXT_FALSE
611am__EXEEXT_TRUE
612LTLIBOBJS
1f5d53eb 613LIBOBJS
067d23c9
KY
614WINDOW_SUPPORT
615TOOLTIP_SUPPORT
616MOUSE_SUPPORT
617LIB_GCC
618LD_FIRSTFLAG
619LD_SWITCH_SYSTEM_TEMACS
620POST_ALLOC_OBJ
621PRE_ALLOC_OBJ
622CYGWIN_OBJ
623RALLOC_OBJ
624OLDXMENU_DEPS
625LIBX_OTHER
626LIBXMENU
627OLDXMENU
628OLDXMENU_TARGET
629LIBXT_OTHER
630TOOLKIT_LIBW
631WIDGET_OBJ
632XOBJ
633XMENU_OBJ
634FONT_OBJ
635OTHER_FILES
636GNU_OBJC_CFLAGS
637ns_appsrc
638ns_appresdir
639ns_appbindir
640ns_appdir
d6a003a8
AS
641S_FILE
642M_FILE
067d23c9
KY
643X_TOOLKIT_TYPE
644C_SWITCH_X_SYSTEM
645C_SWITCH_X_SITE
646LD_SWITCH_X_SITE
647gameuser
648gamedir
649bitmapdir
650archlibdir
651etcdir
652x_default_search_path
653lisppath
654locallisppath
655lispdir
656srcdir
657canonical
658configuration
659version
660KRB4LIB
661DESLIB
662KRB5LIB
663CRYPTOLIB
664COM_ERRLIB
665LIBRESOLV
666LIBHESIOD
667TERMCAP_OBJ
668LIBS_TERMCAP
743c80a7
PE
669LIBGNU_LTLIBDEPS
670LIBGNU_LIBDEPS
671gltests_WITNESS
e275c824
PE
672HAVE_UNISTD_H
673NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
674NEXT_UNISTD_H
1fd182f0
PE
675PTHREAD_H_DEFINES_STRUCT_TIMESPEC
676SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
677TIME_H_DEFINES_STRUCT_TIMESPEC
678NEXT_AS_FIRST_DIRECTIVE_TIME_H
679NEXT_TIME_H
5fa4ac76
PE
680NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
681NEXT_SYS_STAT_H
682REPLACE_UTIMENSAT
683REPLACE_STAT
684REPLACE_MKNOD
685REPLACE_MKFIFO
686REPLACE_MKDIR
687REPLACE_LSTAT
688REPLACE_FUTIMENS
689REPLACE_FSTATAT
690REPLACE_FSTAT
691HAVE_UTIMENSAT
692HAVE_MKNODAT
693HAVE_MKNOD
694HAVE_MKFIFOAT
695HAVE_MKFIFO
696HAVE_MKDIRAT
697HAVE_LSTAT
698HAVE_LCHMOD
699HAVE_FUTIMENS
700HAVE_FSTATAT
701HAVE_FCHMODAT
702GNULIB_UTIMENSAT
703GNULIB_STAT
704GNULIB_MKNODAT
705GNULIB_MKNOD
706GNULIB_MKFIFOAT
707GNULIB_MKFIFO
708GNULIB_MKDIRAT
709GNULIB_LSTAT
710GNULIB_LCHMOD
711GNULIB_FUTIMENS
712GNULIB_FSTATAT
713GNULIB_FCHMODAT
1f5d53eb
PE
714NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
715NEXT_STDLIB_H
5f90be1b
PE
716STDINT_H
717WINT_T_SUFFIX
718WCHAR_T_SUFFIX
719SIG_ATOMIC_T_SUFFIX
720SIZE_T_SUFFIX
721PTRDIFF_T_SUFFIX
722HAVE_SIGNED_WINT_T
723HAVE_SIGNED_WCHAR_T
724HAVE_SIGNED_SIG_ATOMIC_T
725BITSIZEOF_WINT_T
726BITSIZEOF_WCHAR_T
727BITSIZEOF_SIG_ATOMIC_T
728BITSIZEOF_SIZE_T
729BITSIZEOF_PTRDIFF_T
730HAVE_SYS_BITYPES_H
731HAVE_SYS_INTTYPES_H
732HAVE_STDINT_H
733NEXT_AS_FIRST_DIRECTIVE_STDINT_H
734NEXT_STDINT_H
735HAVE_SYS_TYPES_H
736HAVE_INTTYPES_H
737HAVE_WCHAR_H
738HAVE_UNSIGNED_LONG_LONG_INT
739HAVE_LONG_LONG_INT
1fd182f0
PE
740NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
741NEXT_STDDEF_H
1fd182f0
PE
742STDDEF_H
743HAVE_WCHAR_T
744REPLACE_NULL
16c3e636
PE
745HAVE__BOOL
746STDBOOL_H
1fd182f0
PE
747APPLE_UNIVERSAL_BUILD
748REPLACE_TIMEGM
749REPLACE_NANOSLEEP
750REPLACE_MKTIME
751REPLACE_LOCALTIME_R
752HAVE_TIMEGM
753HAVE_STRPTIME
754HAVE_NANOSLEEP
755HAVE_DECL_LOCALTIME_R
756GNULIB_TIME_R
757GNULIB_TIMEGM
758GNULIB_STRPTIME
759GNULIB_NANOSLEEP
760GNULIB_MKTIME
e275c824
PE
761LTLIBINTL
762LIBINTL
763GETOPT_H
764HAVE_GETOPT_H
765NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
766NEXT_GETOPT_H
767PRAGMA_COLUMNS
768PRAGMA_SYSTEM_HEADER
769INCLUDE_NEXT_AS_FIRST_DIRECTIVE
770INCLUDE_NEXT
771UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
772UNISTD_H_HAVE_WINSOCK2_H
773REPLACE_WRITE
774REPLACE_USLEEP
775REPLACE_UNLINKAT
776REPLACE_UNLINK
777REPLACE_TTYNAME_R
778REPLACE_SYMLINK
779REPLACE_SLEEP
780REPLACE_RMDIR
781REPLACE_READLINK
782REPLACE_PWRITE
783REPLACE_PREAD
784REPLACE_LSEEK
785REPLACE_LINKAT
786REPLACE_LINK
787REPLACE_LCHOWN
788REPLACE_GETPAGESIZE
789REPLACE_GETGROUPS
790REPLACE_GETLOGIN_R
791REPLACE_GETDOMAINNAME
792REPLACE_GETCWD
793REPLACE_FCHOWNAT
794REPLACE_DUP2
795REPLACE_DUP
796REPLACE_CLOSE
797REPLACE_CHOWN
798HAVE_SYS_PARAM_H
799HAVE_OS_H
800HAVE_DECL_TTYNAME_R
801HAVE_DECL_GETUSERSHELL
802HAVE_DECL_GETPAGESIZE
803HAVE_DECL_GETLOGIN_R
804HAVE_DECL_GETDOMAINNAME
805HAVE_DECL_FCHDIR
806HAVE_DECL_ENVIRON
807HAVE_USLEEP
808HAVE_UNLINKAT
809HAVE_SYMLINKAT
810HAVE_SYMLINK
811HAVE_SLEEP
812HAVE_READLINKAT
813HAVE_READLINK
814HAVE_PWRITE
815HAVE_PREAD
816HAVE_PIPE2
817HAVE_PIPE
818HAVE_LINKAT
819HAVE_LINK
820HAVE_LCHOWN
821HAVE_GETPAGESIZE
822HAVE_GETLOGIN
823HAVE_GETHOSTNAME
824HAVE_GETGROUPS
825HAVE_GETDTABLESIZE
826HAVE_FTRUNCATE
827HAVE_FSYNC
828HAVE_FCHOWNAT
829HAVE_FCHDIR
830HAVE_FACCESSAT
831HAVE_EUIDACCESS
832HAVE_DUP3
833HAVE_DUP2
834HAVE_CHOWN
835GNULIB_WRITE
836GNULIB_USLEEP
837GNULIB_UNLINKAT
838GNULIB_UNLINK
839GNULIB_UNISTD_H_SIGPIPE
840GNULIB_UNISTD_H_GETOPT
841GNULIB_TTYNAME_R
842GNULIB_SYMLINKAT
843GNULIB_SYMLINK
844GNULIB_SLEEP
845GNULIB_RMDIR
846GNULIB_READLINKAT
847GNULIB_READLINK
848GNULIB_PWRITE
849GNULIB_PREAD
850GNULIB_PIPE2
851GNULIB_PIPE
852GNULIB_LSEEK
853GNULIB_LINKAT
854GNULIB_LINK
855GNULIB_LCHOWN
856GNULIB_GETUSERSHELL
857GNULIB_GETPAGESIZE
858GNULIB_GETLOGIN_R
859GNULIB_GETLOGIN
860GNULIB_GETHOSTNAME
861GNULIB_GETGROUPS
862GNULIB_GETDTABLESIZE
863GNULIB_GETDOMAINNAME
864GNULIB_GETCWD
865GNULIB_FTRUNCATE
866GNULIB_FSYNC
867GNULIB_FCHOWNAT
868GNULIB_FCHDIR
869GNULIB_FACCESSAT
870GNULIB_EUIDACCESS
871GNULIB_ENVIRON
872GNULIB_DUP3
873GNULIB_DUP2
874GNULIB_CLOSE
875GNULIB_CHOWN
1f5d53eb
PE
876GETLOADAVG_LIBS
877REPLACE_UNSETENV
878REPLACE_STRTOD
879REPLACE_SETENV
880REPLACE_REALPATH
881REPLACE_REALLOC
882REPLACE_PUTENV
883REPLACE_MKSTEMP
884REPLACE_MALLOC
885REPLACE_CANONICALIZE_FILE_NAME
886REPLACE_CALLOC
887HAVE_DECL_UNSETENV
888HAVE_UNLOCKPT
889HAVE_SYS_LOADAVG_H
890HAVE_STRUCT_RANDOM_DATA
891HAVE_STRTOULL
892HAVE_STRTOLL
893HAVE_STRTOD
894HAVE_DECL_SETENV
895HAVE_SETENV
896HAVE_RPMATCH
897HAVE_REALPATH
898HAVE_RANDOM_R
899HAVE_RANDOM_H
900HAVE_PTSNAME
901HAVE_MKSTEMPS
902HAVE_MKSTEMP
903HAVE_MKOSTEMPS
904HAVE_MKOSTEMP
905HAVE_MKDTEMP
906HAVE_GRANTPT
907HAVE_GETSUBOPT
908HAVE_DECL_GETLOADAVG
909HAVE_CANONICALIZE_FILE_NAME
910HAVE_ATOLL
911HAVE__EXIT
912GNULIB_UNSETENV
913GNULIB_UNLOCKPT
914GNULIB_SYSTEM_POSIX
915GNULIB_STRTOULL
916GNULIB_STRTOLL
917GNULIB_STRTOD
918GNULIB_SETENV
919GNULIB_RPMATCH
920GNULIB_REALPATH
921GNULIB_REALLOC_POSIX
922GNULIB_RANDOM_R
923GNULIB_PUTENV
924GNULIB_PTSNAME
925GNULIB_MKSTEMPS
926GNULIB_MKSTEMP
927GNULIB_MKOSTEMPS
928GNULIB_MKOSTEMP
929GNULIB_MKDTEMP
930GNULIB_MALLOC_POSIX
931GNULIB_GRANTPT
932GNULIB_GETSUBOPT
933GNULIB_GETLOADAVG
934GNULIB_CANONICALIZE_FILE_NAME
935GNULIB_CALLOC_POSIX
936GNULIB_ATOLL
937GNULIB__EXIT
743c80a7
PE
938GL_COND_LIBTOOL_FALSE
939GL_COND_LIBTOOL_TRUE
067d23c9
KY
940BLESSMAIL_TARGET
941LIBS_MAIL
942liblockfile
943ALLOCA
944LIBXML2_LIBS
945LIBXML2_CFLAGS
946LIBXSM
947LIBGPM
948LIBGIF
949LIBTIFF
950LIBPNG
951LIBJPEG
952LIBXPM
953FREETYPE_LIBS
954FREETYPE_CFLAGS
955M17N_FLT_LIBS
956M17N_FLT_CFLAGS
957LIBOTF_LIBS
958LIBOTF_CFLAGS
959XFT_LIBS
960XFT_CFLAGS
961FONTCONFIG_LIBS
962FONTCONFIG_CFLAGS
963LIBXMU
964LIBXTR6
965LIBGNUTLS_LIBS
966LIBGNUTLS_CFLAGS
967LIBSELINUX_LIBS
968GCONF_LIBS
969GCONF_CFLAGS
970DBUS_OBJ
971DBUS_LIBS
972DBUS_CFLAGS
973GTK_OBJ
974GTK_LIBS
975GTK_CFLAGS
976IMAGEMAGICK_LIBS
977IMAGEMAGICK_CFLAGS
978RSVG_LIBS
979RSVG_CFLAGS
980VMLIMIT_OBJ
981GMALLOC_OBJ
982HAVE_XSERVER
983LIB_STANDARD
984NS_SUPPORT
00b3c7ac 985NS_OBJC_OBJ
067d23c9
KY
986NS_OBJ
987TEMACS_LDFLAGS2
988LD_SWITCH_X_SITE_AUX_RPATH
989LD_SWITCH_X_SITE_AUX
990XMKMF
991DEPFLAGS
992MKDEPDIR
067d23c9
KY
993CFLAGS_SOUND
994ALSA_LIBS
995ALSA_CFLAGS
996PKG_CONFIG
997LIBSOUND
998START_FILES
999LIB_MATH
1000CRT_DIR
1001LIBS_SYSTEM
1002C_SWITCH_SYSTEM
1003UNEXEC_OBJ
1004C_SWITCH_MACHINE
1005LD_SWITCH_SYSTEM
1006CANNOT_DUMP
96f129d5 1007HAVE_MAKEINFO
067d23c9
KY
1008GZIP_PROG
1009INSTALL_INFO
067d23c9
KY
1010C_WARNINGS_SWITCH
1011EGREP
1012GREP
1013CPP
743c80a7
PE
1014RANLIB
1015am__fastdepCC_FALSE
1016am__fastdepCC_TRUE
1017CCDEPMODE
1018AMDEPBACKSLASH
1019AMDEP_FALSE
1020AMDEP_TRUE
1021am__quote
1022am__include
1023DEPDIR
067d23c9
KY
1024OBJEXT
1025EXEEXT
1026ac_ct_CC
1027CPPFLAGS
1028LDFLAGS
1029CFLAGS
1030CC
1031host_os
1032host_vendor
1033host_cpu
1034host
1035build_os
1036build_vendor
1037build_cpu
1038build
1039PROFILING_CFLAGS
1040MAINT
1041GZIP_INFO
743c80a7
PE
1042am__untar
1043am__tar
1044AMTAR
1045am__leading_dot
1046SET_MAKE
1047AWK
1048mkdir_p
1049MKDIR_P
1050INSTALL_STRIP_PROGRAM
1051STRIP
1052install_sh
1053MAKEINFO
1054AUTOHEADER
1055AUTOMAKE
1056AUTOCONF
1057ACLOCAL
1058VERSION
1059PACKAGE
1060CYGPATH_W
1061am__isrc
1062INSTALL_DATA
1063INSTALL_SCRIPT
1064INSTALL_PROGRAM
067d23c9
KY
1065target_alias
1066host_alias
1067build_alias
1068LIBS
1069ECHO_T
1070ECHO_N
1071ECHO_C
1072DEFS
1073mandir
1074localedir
1075libdir
1076psdir
1077pdfdir
1078dvidir
1079htmldir
1080infodir
1081docdir
1082oldincludedir
1083includedir
1084localstatedir
1085sharedstatedir
1086sysconfdir
1087datadir
1088datarootdir
1089libexecdir
1090sbindir
1091bindir
1092program_transform_name
1093prefix
1094exec_prefix
1095PACKAGE_URL
1096PACKAGE_BUGREPORT
1097PACKAGE_STRING
1098PACKAGE_VERSION
1099PACKAGE_TARNAME
1100PACKAGE_NAME
1101PATH_SEPARATOR
1102SHELL'
1103ac_subst_files='deps_frag
1104ns_frag'
1105ac_user_opts='
1106enable_option_checking
1107with_pop
1108with_kerberos
1109with_kerberos5
1110with_hesiod
1111with_mmdf
1112with_mail_unlink
1113with_mailhost
1114with_sound
1115with_sync_input
1116with_x_toolkit
1117with_xpm
1118with_jpeg
1119with_tiff
1120with_gif
1121with_png
1122with_rsvg
1123with_xml2
1124with_imagemagick
1125with_xft
1126with_libotf
1127with_m17n_flt
1128with_toolkit_scroll_bars
1129with_xaw3d
1130with_xim
1131with_ns
1132with_gpm
1133with_dbus
1134with_gconf
1135with_selinux
1136with_gnutls
1137with_makeinfo
1138with_compress_info
1139with_pkg_config_prog
1140with_crt_dir
4fc5868a 1141with_gameuser
067d23c9
KY
1142with_gnustep_conf
1143enable_ns_self_contained
1144enable_asserts
1145enable_maintainer_mode
1146enable_locallisppath
1147enable_checking
1148enable_use_lisp_union_type
1149enable_profiling
1150enable_autodepend
743c80a7 1151enable_dependency_tracking
067d23c9
KY
1152enable_largefile
1153with_x
1154'
1155 ac_precious_vars='build_alias
1156host_alias
1157target_alias
1158CC
1159CFLAGS
1160LDFLAGS
1161LIBS
1162CPPFLAGS
1163CPP
1f5d53eb
PE
1164CPPFLAGS
1165CPP
1166CPPFLAGS
067d23c9
KY
1167XMKMF'
1168
1169
1170# Initialize some variables set by options.
1171ac_init_help=
1172ac_init_version=false
1173ac_unrecognized_opts=
1174ac_unrecognized_sep=
1175# The variables have the same names as the options, with
1176# dashes changed to underlines.
1177cache_file=/dev/null
1178exec_prefix=NONE
1179no_create=
1180no_recursion=
1181prefix=NONE
1182program_prefix=NONE
1183program_suffix=NONE
1184program_transform_name=s,x,x,
1185silent=
1186site=
1187srcdir=
1188verbose=
1189x_includes=NONE
1190x_libraries=NONE
1191
1192# Installation directory options.
1193# These are left unexpanded so users can "make install exec_prefix=/foo"
1194# and all the variables that are supposed to be based on exec_prefix
1195# by default will actually change.
1196# Use braces instead of parens because sh, perl, etc. also accept them.
1197# (The list follows the same order as the GNU Coding Standards.)
1198bindir='${exec_prefix}/bin'
1199sbindir='${exec_prefix}/sbin'
1200libexecdir='${exec_prefix}/libexec'
1201datarootdir='${prefix}/share'
1202datadir='${datarootdir}'
1203sysconfdir='${prefix}/etc'
1204sharedstatedir='${prefix}/com'
1205localstatedir='${prefix}/var'
1206includedir='${prefix}/include'
1207oldincludedir='/usr/include'
1208docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1209infodir='${datarootdir}/info'
1210htmldir='${docdir}'
1211dvidir='${docdir}'
1212pdfdir='${docdir}'
1213psdir='${docdir}'
1214libdir='${exec_prefix}/lib'
1215localedir='${datarootdir}/locale'
1216mandir='${datarootdir}/man'
1217
1218ac_prev=
1219ac_dashdash=
1220for ac_option
1221do
1222 # If the previous option needs an argument, assign it.
1223 if test -n "$ac_prev"; then
1224 eval $ac_prev=\$ac_option
1225 ac_prev=
1226 continue
1227 fi
1228
1229 case $ac_option in
2018939f
AS
1230 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1231 *=) ac_optarg= ;;
1232 *) ac_optarg=yes ;;
067d23c9
KY
1233 esac
1234
1235 # Accept the important Cygnus configure options, so we can diagnose typos.
1236
1237 case $ac_dashdash$ac_option in
1238 --)
1239 ac_dashdash=yes ;;
1240
1241 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1242 ac_prev=bindir ;;
1243 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1244 bindir=$ac_optarg ;;
1245
1246 -build | --build | --buil | --bui | --bu)
1247 ac_prev=build_alias ;;
1248 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1249 build_alias=$ac_optarg ;;
1250
1251 -cache-file | --cache-file | --cache-fil | --cache-fi \
1252 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1253 ac_prev=cache_file ;;
1254 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1255 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1256 cache_file=$ac_optarg ;;
1257
1258 --config-cache | -C)
1259 cache_file=config.cache ;;
1260
1261 -datadir | --datadir | --datadi | --datad)
1262 ac_prev=datadir ;;
1263 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1264 datadir=$ac_optarg ;;
1265
1266 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1267 | --dataroo | --dataro | --datar)
1268 ac_prev=datarootdir ;;
1269 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1270 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1271 datarootdir=$ac_optarg ;;
1272
1273 -disable-* | --disable-*)
1274 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1275 # Reject names that are not valid shell variable names.
1276 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
2018939f 1277 as_fn_error $? "invalid feature name: $ac_useropt"
067d23c9
KY
1278 ac_useropt_orig=$ac_useropt
1279 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1280 case $ac_user_opts in
1281 *"
1282"enable_$ac_useropt"
1283"*) ;;
1284 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1285 ac_unrecognized_sep=', ';;
1286 esac
1287 eval enable_$ac_useropt=no ;;
1288
1289 -docdir | --docdir | --docdi | --doc | --do)
1290 ac_prev=docdir ;;
1291 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1292 docdir=$ac_optarg ;;
1293
1294 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1295 ac_prev=dvidir ;;
1296 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1297 dvidir=$ac_optarg ;;
1298
1299 -enable-* | --enable-*)
1300 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1301 # Reject names that are not valid shell variable names.
1302 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
2018939f 1303 as_fn_error $? "invalid feature name: $ac_useropt"
067d23c9
KY
1304 ac_useropt_orig=$ac_useropt
1305 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1306 case $ac_user_opts in
1307 *"
1308"enable_$ac_useropt"
1309"*) ;;
1310 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1311 ac_unrecognized_sep=', ';;
1312 esac
1313 eval enable_$ac_useropt=\$ac_optarg ;;
1314
1315 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1316 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1317 | --exec | --exe | --ex)
1318 ac_prev=exec_prefix ;;
1319 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1320 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1321 | --exec=* | --exe=* | --ex=*)
1322 exec_prefix=$ac_optarg ;;
1323
1324 -gas | --gas | --ga | --g)
1325 # Obsolete; use --with-gas.
1326 with_gas=yes ;;
1327
1328 -help | --help | --hel | --he | -h)
1329 ac_init_help=long ;;
1330 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1331 ac_init_help=recursive ;;
1332 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1333 ac_init_help=short ;;
1334
1335 -host | --host | --hos | --ho)
1336 ac_prev=host_alias ;;
1337 -host=* | --host=* | --hos=* | --ho=*)
1338 host_alias=$ac_optarg ;;
1339
1340 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1341 ac_prev=htmldir ;;
1342 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1343 | --ht=*)
1344 htmldir=$ac_optarg ;;
1345
1346 -includedir | --includedir | --includedi | --included | --include \
1347 | --includ | --inclu | --incl | --inc)
1348 ac_prev=includedir ;;
1349 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1350 | --includ=* | --inclu=* | --incl=* | --inc=*)
1351 includedir=$ac_optarg ;;
1352
1353 -infodir | --infodir | --infodi | --infod | --info | --inf)
1354 ac_prev=infodir ;;
1355 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1356 infodir=$ac_optarg ;;
1357
1358 -libdir | --libdir | --libdi | --libd)
1359 ac_prev=libdir ;;
1360 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1361 libdir=$ac_optarg ;;
1362
1363 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1364 | --libexe | --libex | --libe)
1365 ac_prev=libexecdir ;;
1366 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1367 | --libexe=* | --libex=* | --libe=*)
1368 libexecdir=$ac_optarg ;;
1369
1370 -localedir | --localedir | --localedi | --localed | --locale)
1371 ac_prev=localedir ;;
1372 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1373 localedir=$ac_optarg ;;
1374
1375 -localstatedir | --localstatedir | --localstatedi | --localstated \
1376 | --localstate | --localstat | --localsta | --localst | --locals)
1377 ac_prev=localstatedir ;;
1378 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1379 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1380 localstatedir=$ac_optarg ;;
1381
1382 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1383 ac_prev=mandir ;;
1384 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1385 mandir=$ac_optarg ;;
1386
1387 -nfp | --nfp | --nf)
1388 # Obsolete; use --without-fp.
1389 with_fp=no ;;
1390
1391 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1392 | --no-cr | --no-c | -n)
1393 no_create=yes ;;
1394
1395 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1396 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1397 no_recursion=yes ;;
1398
1399 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1400 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1401 | --oldin | --oldi | --old | --ol | --o)
1402 ac_prev=oldincludedir ;;
1403 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1404 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1405 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1406 oldincludedir=$ac_optarg ;;
1407
1408 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1409 ac_prev=prefix ;;
1410 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1411 prefix=$ac_optarg ;;
1412
1413 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1414 | --program-pre | --program-pr | --program-p)
1415 ac_prev=program_prefix ;;
1416 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1417 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1418 program_prefix=$ac_optarg ;;
1419
1420 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1421 | --program-suf | --program-su | --program-s)
1422 ac_prev=program_suffix ;;
1423 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1424 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1425 program_suffix=$ac_optarg ;;
1426
1427 -program-transform-name | --program-transform-name \
1428 | --program-transform-nam | --program-transform-na \
1429 | --program-transform-n | --program-transform- \
1430 | --program-transform | --program-transfor \
1431 | --program-transfo | --program-transf \
1432 | --program-trans | --program-tran \
1433 | --progr-tra | --program-tr | --program-t)
1434 ac_prev=program_transform_name ;;
1435 -program-transform-name=* | --program-transform-name=* \
1436 | --program-transform-nam=* | --program-transform-na=* \
1437 | --program-transform-n=* | --program-transform-=* \
1438 | --program-transform=* | --program-transfor=* \
1439 | --program-transfo=* | --program-transf=* \
1440 | --program-trans=* | --program-tran=* \
1441 | --progr-tra=* | --program-tr=* | --program-t=*)
1442 program_transform_name=$ac_optarg ;;
1443
1444 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1445 ac_prev=pdfdir ;;
1446 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1447 pdfdir=$ac_optarg ;;
1448
1449 -psdir | --psdir | --psdi | --psd | --ps)
1450 ac_prev=psdir ;;
1451 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1452 psdir=$ac_optarg ;;
1453
1454 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1455 | -silent | --silent | --silen | --sile | --sil)
1456 silent=yes ;;
1457
1458 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1459 ac_prev=sbindir ;;
1460 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1461 | --sbi=* | --sb=*)
1462 sbindir=$ac_optarg ;;
1463
1464 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1465 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1466 | --sharedst | --shareds | --shared | --share | --shar \
1467 | --sha | --sh)
1468 ac_prev=sharedstatedir ;;
1469 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1470 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1471 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1472 | --sha=* | --sh=*)
1473 sharedstatedir=$ac_optarg ;;
1474
1475 -site | --site | --sit)
1476 ac_prev=site ;;
1477 -site=* | --site=* | --sit=*)
1478 site=$ac_optarg ;;
1479
1480 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1481 ac_prev=srcdir ;;
1482 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1483 srcdir=$ac_optarg ;;
1484
1485 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1486 | --syscon | --sysco | --sysc | --sys | --sy)
1487 ac_prev=sysconfdir ;;
1488 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1489 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1490 sysconfdir=$ac_optarg ;;
1491
1492 -target | --target | --targe | --targ | --tar | --ta | --t)
1493 ac_prev=target_alias ;;
1494 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1495 target_alias=$ac_optarg ;;
1496
1497 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1498 verbose=yes ;;
1499
1500 -version | --version | --versio | --versi | --vers | -V)
1501 ac_init_version=: ;;
1502
1503 -with-* | --with-*)
1504 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1505 # Reject names that are not valid shell variable names.
1506 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
2018939f 1507 as_fn_error $? "invalid package name: $ac_useropt"
067d23c9
KY
1508 ac_useropt_orig=$ac_useropt
1509 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1510 case $ac_user_opts in
1511 *"
1512"with_$ac_useropt"
1513"*) ;;
1514 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1515 ac_unrecognized_sep=', ';;
1516 esac
1517 eval with_$ac_useropt=\$ac_optarg ;;
1518
1519 -without-* | --without-*)
1520 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1521 # Reject names that are not valid shell variable names.
1522 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
2018939f 1523 as_fn_error $? "invalid package name: $ac_useropt"
067d23c9
KY
1524 ac_useropt_orig=$ac_useropt
1525 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1526 case $ac_user_opts in
1527 *"
1528"with_$ac_useropt"
1529"*) ;;
1530 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1531 ac_unrecognized_sep=', ';;
1532 esac
1533 eval with_$ac_useropt=no ;;
1534
1535 --x)
1536 # Obsolete; use --with-x.
1537 with_x=yes ;;
1538
1539 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1540 | --x-incl | --x-inc | --x-in | --x-i)
1541 ac_prev=x_includes ;;
1542 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1543 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1544 x_includes=$ac_optarg ;;
1545
1546 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1547 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1548 ac_prev=x_libraries ;;
1549 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1550 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1551 x_libraries=$ac_optarg ;;
1552
2018939f
AS
1553 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1554Try \`$0 --help' for more information"
067d23c9
KY
1555 ;;
1556
1557 *=*)
1558 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1559 # Reject names that are not valid shell variable names.
1560 case $ac_envvar in #(
1561 '' | [0-9]* | *[!_$as_cr_alnum]* )
2018939f 1562 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
067d23c9
KY
1563 esac
1564 eval $ac_envvar=\$ac_optarg
1565 export $ac_envvar ;;
1566
1567 *)
1568 # FIXME: should be removed in autoconf 3.0.
1569 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1570 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1571 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
d6974efa 1572 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
067d23c9
KY
1573 ;;
1574
1575 esac
1576done
1577
1578if test -n "$ac_prev"; then
1579 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
2018939f 1580 as_fn_error $? "missing argument to $ac_option"
067d23c9
KY
1581fi
1582
1583if test -n "$ac_unrecognized_opts"; then
1584 case $enable_option_checking in
1585 no) ;;
2018939f 1586 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
067d23c9
KY
1587 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1588 esac
1589fi
1590
1591# Check all directory arguments for consistency.
1592for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1593 datadir sysconfdir sharedstatedir localstatedir includedir \
1594 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1595 libdir localedir mandir
1596do
1597 eval ac_val=\$$ac_var
1598 # Remove trailing slashes.
1599 case $ac_val in
1600 */ )
1601 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1602 eval $ac_var=\$ac_val;;
1603 esac
1604 # Be sure to have absolute directory names.
1605 case $ac_val in
1606 [\\/$]* | ?:[\\/]* ) continue;;
1607 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1608 esac
2018939f 1609 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
067d23c9
KY
1610done
1611
1612# There might be people who depend on the old broken behavior: `$host'
1613# used to hold the argument of --host etc.
1614# FIXME: To remove some day.
1615build=$build_alias
1616host=$host_alias
1617target=$target_alias
1618
1619# FIXME: To remove some day.
1620if test "x$host_alias" != x; then
1621 if test "x$build_alias" = x; then
1622 cross_compiling=maybe
2018939f
AS
1623 $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host.
1624 If a cross compiler is detected then cross compile mode will be used" >&2
067d23c9
KY
1625 elif test "x$build_alias" != "x$host_alias"; then
1626 cross_compiling=yes
1627 fi
1628fi
1629
1630ac_tool_prefix=
1631test -n "$host_alias" && ac_tool_prefix=$host_alias-
1632
1633test "$silent" = yes && exec 6>/dev/null
1634
1635
1636ac_pwd=`pwd` && test -n "$ac_pwd" &&
1637ac_ls_di=`ls -di .` &&
1638ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
2018939f 1639 as_fn_error $? "working directory cannot be determined"
067d23c9 1640test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
2018939f 1641 as_fn_error $? "pwd does not report name of working directory"
067d23c9
KY
1642
1643
1644# Find the source files, if location was not specified.
1645if test -z "$srcdir"; then
1646 ac_srcdir_defaulted=yes
1647 # Try the directory containing this script, then the parent directory.
1648 ac_confdir=`$as_dirname -- "$as_myself" ||
1649$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1650 X"$as_myself" : 'X\(//\)[^/]' \| \
1651 X"$as_myself" : 'X\(//\)$' \| \
1652 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1653$as_echo X"$as_myself" |
1654 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1655 s//\1/
1656 q
1657 }
1658 /^X\(\/\/\)[^/].*/{
1659 s//\1/
1660 q
1661 }
1662 /^X\(\/\/\)$/{
1663 s//\1/
1664 q
1665 }
1666 /^X\(\/\).*/{
1667 s//\1/
1668 q
1669 }
1670 s/.*/./; q'`
1671 srcdir=$ac_confdir
1672 if test ! -r "$srcdir/$ac_unique_file"; then
1673 srcdir=..
1674 fi
1675else
1676 ac_srcdir_defaulted=no
1677fi
1678if test ! -r "$srcdir/$ac_unique_file"; then
1679 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
2018939f 1680 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
067d23c9
KY
1681fi
1682ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1683ac_abs_confdir=`(
2018939f 1684 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
067d23c9
KY
1685 pwd)`
1686# When building in place, set srcdir=.
1687if test "$ac_abs_confdir" = "$ac_pwd"; then
1688 srcdir=.
1689fi
1690# Remove unnecessary trailing slashes from srcdir.
1691# Double slashes in file names in object file debugging info
1692# mess up M-x gdb in Emacs.
1693case $srcdir in
1694*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1695esac
1696for ac_var in $ac_precious_vars; do
1697 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1698 eval ac_env_${ac_var}_value=\$${ac_var}
1699 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1700 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1701done
1702
1703#
1704# Report the --help message.
1705#
1706if test "$ac_init_help" = "long"; then
1707 # Omit some internal or obsolete options to make the list less imposing.
1708 # This message is too long to be a string in the A/UX 3.1 sh.
1709 cat <<_ACEOF
1710\`configure' configures emacs 24.0.50 to adapt to many kinds of systems.
1711
1712Usage: $0 [OPTION]... [VAR=VALUE]...
1713
1714To assign environment variables (e.g., CC, CFLAGS...), specify them as
1715VAR=VALUE. See below for descriptions of some of the useful variables.
1716
1717Defaults for the options are specified in brackets.
1718
1719Configuration:
1720 -h, --help display this help and exit
1721 --help=short display options specific to this package
1722 --help=recursive display the short help of all the included packages
1723 -V, --version display version information and exit
2018939f 1724 -q, --quiet, --silent do not print \`checking ...' messages
067d23c9
KY
1725 --cache-file=FILE cache test results in FILE [disabled]
1726 -C, --config-cache alias for \`--cache-file=config.cache'
1727 -n, --no-create do not create output files
1728 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1729
1730Installation directories:
1731 --prefix=PREFIX install architecture-independent files in PREFIX
1732 [$ac_default_prefix]
1733 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1734 [PREFIX]
1735
1736By default, \`make install' will install all the files in
1737\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1738an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1739for instance \`--prefix=\$HOME'.
1740
1741For better control, use the options below.
1742
1743Fine tuning of the installation directories:
1744 --bindir=DIR user executables [EPREFIX/bin]
1745 --sbindir=DIR system admin executables [EPREFIX/sbin]
1746 --libexecdir=DIR program executables [EPREFIX/libexec]
1747 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1748 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1749 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1750 --libdir=DIR object code libraries [EPREFIX/lib]
1751 --includedir=DIR C header files [PREFIX/include]
1752 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1753 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1754 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1755 --infodir=DIR info documentation [DATAROOTDIR/info]
1756 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1757 --mandir=DIR man documentation [DATAROOTDIR/man]
1758 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
1759 --htmldir=DIR html documentation [DOCDIR]
1760 --dvidir=DIR dvi documentation [DOCDIR]
1761 --pdfdir=DIR pdf documentation [DOCDIR]
1762 --psdir=DIR ps documentation [DOCDIR]
1763_ACEOF
1764
1765 cat <<\_ACEOF
1766
1767Program names:
1768 --program-prefix=PREFIX prepend PREFIX to installed program names
1769 --program-suffix=SUFFIX append SUFFIX to installed program names
1770 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1771
1772X features:
1773 --x-includes=DIR X include files are in DIR
1774 --x-libraries=DIR X library files are in DIR
1775
1776System types:
1777 --build=BUILD configure for building on BUILD [guessed]
1778 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1779_ACEOF
1780fi
1781
1782if test -n "$ac_init_help"; then
1783 case $ac_init_help in
1784 short | recursive ) echo "Configuration of emacs 24.0.50:";;
1785 esac
1786 cat <<\_ACEOF
1787
1788Optional Features:
1789 --disable-option-checking ignore unrecognized --enable/--with options
1790 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1791 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1792 --disable-ns-self-contained
1793 disable self contained build under NeXTstep
1794 --enable-asserts compile code with asserts enabled
1795 --enable-maintainer-mode
1796 enable make rules and dependencies not useful (and
1797 sometimes confusing) to the casual installer
1798 --enable-locallisppath=PATH
1799 directories Emacs should search for lisp files
1800 specific to this site
1801 --enable-checking[=LIST]
1802 enable expensive run-time checks. With LIST, enable
1803 only specific categories of checks. Categories are:
1804 all,yes,no. Flags are: stringbytes, stringoverrun,
1805 stringfreelist, xmallocoverrun, conslist
1806 --enable-use-lisp-union-type
1807 use a union for the Lisp_Object data type. This is
1808 only useful for development for catching certain
1809 types of bugs.
1810 --enable-profiling build emacs with profiling support. This might not
1811 work on all platforms
1812 --enable-autodepend automatically generate dependencies to .h-files.
1813 Requires GNU Make and Gcc. Enabled if GNU Make and
1814 Gcc is found
743c80a7
PE
1815 --disable-dependency-tracking speeds up one-time build
1816 --enable-dependency-tracking do not reject slow dependency extractors
067d23c9
KY
1817 --disable-largefile omit support for large files
1818
1819Optional Packages:
1820 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1821 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1822 --without-pop don't support POP mail retrieval with movemail
1823 --with-kerberos support Kerberos-authenticated POP
1824 --with-kerberos5 support Kerberos version 5 authenticated POP
1825 --with-hesiod support Hesiod to get the POP server host
1826 --with-mmdf support MMDF mailboxes
1827 --with-mail-unlink unlink, rather than empty, mail spool after reading
1828 --with-mailhost=HOSTNAME
1829 string giving default POP mail host
1830 --without-sound don't compile with sound support
1831 --without-sync-input process async input synchronously
1832 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk3,
1833 lucid or athena, motif, no)
1834 --without-xpm don't compile with XPM image support
1835 --without-jpeg don't compile with JPEG image support
1836 --without-tiff don't compile with TIFF image support
1837 --without-gif don't compile with GIF image support
1838 --without-png don't compile with PNG image support
1839 --without-rsvg don't compile with SVG image support
1840 --without-xml2 don't compile with XML parsing support
1841 --without-imagemagick don't compile with ImageMagick image support
1842 --without-xft don't use XFT for anti aliased fonts
1843 --without-libotf don't use libotf for OpenType font support
1844 --without-m17n-flt don't use m17n-flt for text shaping
1845 --without-toolkit-scroll-bars
1846 don't use Motif or Xaw3d scroll bars
1847 --without-xaw3d don't use Xaw3d
1848 --without-xim don't use X11 XIM
1849 --with-ns use nextstep (Cocoa or GNUstep) windowing system
1850 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
1851 console
1852 --without-dbus don't compile with D-Bus support
1853 --without-gconf don't compile with GConf support
1854 --without-selinux don't compile with SELinux support
1855 --without-gnutls don't use -lgnutls for SSL/TLS support
1856 --without-makeinfo don't require makeinfo for building manuals
1857 --without-compress-info don't compress the installed Info pages
1858 --with-pkg-config-prog=PATH
1859 path to pkg-config for finding GTK and librsvg
1860 --with-crt-dir=DIR directory containing crtn.o etc. The default is
1861 /usr/lib, or /usr/lib64 on some platforms.
4fc5868a 1862 --with-gameuser=USER user for shared game score files
067d23c9
KY
1863 --with-gnustep-conf=PATH
1864 path to GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
1865 or /etc/GNUstep/GNUstep.conf
1866 --with-x use the X Window System
1867
1868Some influential environment variables:
1869 CC C compiler command
1870 CFLAGS C compiler flags
1871 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1872 nonstandard directory <lib dir>
1873 LIBS libraries to pass to the linker, e.g. -l<library>
1874 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1875 you have headers in a nonstandard directory <include dir>
1876 CPP C preprocessor
1877 XMKMF Path to xmkmf, Makefile generator for X Window System
1878
1879Use these variables to override the choices made by `configure' or to help
1880it to find libraries and programs with nonstandard names/locations.
1881
1882Report bugs to the package provider.
1883_ACEOF
1884ac_status=$?
1885fi
1886
1887if test "$ac_init_help" = "recursive"; then
1888 # If there are subdirs, report their specific --help.
1889 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1890 test -d "$ac_dir" ||
1891 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1892 continue
1893 ac_builddir=.
1894
1895case "$ac_dir" in
1896.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1897*)
1898 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1899 # A ".." for each directory in $ac_dir_suffix.
1900 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1901 case $ac_top_builddir_sub in
1902 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1903 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1904 esac ;;
1905esac
1906ac_abs_top_builddir=$ac_pwd
1907ac_abs_builddir=$ac_pwd$ac_dir_suffix
1908# for backward compatibility:
1909ac_top_builddir=$ac_top_build_prefix
1910
1911case $srcdir in
1912 .) # We are building in place.
1913 ac_srcdir=.
1914 ac_top_srcdir=$ac_top_builddir_sub
1915 ac_abs_top_srcdir=$ac_pwd ;;
1916 [\\/]* | ?:[\\/]* ) # Absolute name.
1917 ac_srcdir=$srcdir$ac_dir_suffix;
1918 ac_top_srcdir=$srcdir
1919 ac_abs_top_srcdir=$srcdir ;;
1920 *) # Relative name.
1921 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1922 ac_top_srcdir=$ac_top_build_prefix$srcdir
1923 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1924esac
1925ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1926
1927 cd "$ac_dir" || { ac_status=$?; continue; }
1928 # Check for guested configure.
1929 if test -f "$ac_srcdir/configure.gnu"; then
1930 echo &&
1931 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1932 elif test -f "$ac_srcdir/configure"; then
1933 echo &&
1934 $SHELL "$ac_srcdir/configure" --help=recursive
1935 else
1936 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1937 fi || ac_status=$?
1938 cd "$ac_pwd" || { ac_status=$?; break; }
1939 done
1940fi
1941
1942test -n "$ac_init_help" && exit $ac_status
1943if $ac_init_version; then
1944 cat <<\_ACEOF
1945emacs configure 24.0.50
d6974efa 1946generated by GNU Autoconf 2.68
067d23c9 1947
2018939f 1948Copyright (C) 2010 Free Software Foundation, Inc.
067d23c9
KY
1949This configure script is free software; the Free Software Foundation
1950gives unlimited permission to copy, distribute and modify it.
1951_ACEOF
1952 exit
1953fi
1954
1955## ------------------------ ##
1956## Autoconf initialization. ##
1957## ------------------------ ##
1958
1959# ac_fn_c_try_compile LINENO
1960# --------------------------
1961# Try to compile conftest.$ac_ext, and return whether this succeeded.
1962ac_fn_c_try_compile ()
1963{
1964 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1965 rm -f conftest.$ac_objext
1966 if { { ac_try="$ac_compile"
1967case "(($ac_try" in
1968 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1969 *) ac_try_echo=$ac_try;;
1970esac
1971eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1972$as_echo "$ac_try_echo"; } >&5
1973 (eval "$ac_compile") 2>conftest.err
1974 ac_status=$?
1975 if test -s conftest.err; then
1976 grep -v '^ *+' conftest.err >conftest.er1
1977 cat conftest.er1 >&5
1978 mv -f conftest.er1 conftest.err
1979 fi
1980 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1981 test $ac_status = 0; } && {
1982 test -z "$ac_c_werror_flag" ||
1983 test ! -s conftest.err
1984 } && test -s conftest.$ac_objext; then :
1985 ac_retval=0
1986else
1987 $as_echo "$as_me: failed program was:" >&5
1988sed 's/^/| /' conftest.$ac_ext >&5
1989
1990 ac_retval=1
1991fi
d6974efa 1992 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
067d23c9
KY
1993 as_fn_set_status $ac_retval
1994
1995} # ac_fn_c_try_compile
1996
067d23c9
KY
1997# ac_fn_c_try_cpp LINENO
1998# ----------------------
1999# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2000ac_fn_c_try_cpp ()
2001{
2002 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2003 if { { ac_try="$ac_cpp conftest.$ac_ext"
2004case "(($ac_try" in
2005 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2006 *) ac_try_echo=$ac_try;;
2007esac
2008eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2009$as_echo "$ac_try_echo"; } >&5
2010 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2011 ac_status=$?
2012 if test -s conftest.err; then
2013 grep -v '^ *+' conftest.err >conftest.er1
2014 cat conftest.er1 >&5
2015 mv -f conftest.er1 conftest.err
2016 fi
2017 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2018939f 2018 test $ac_status = 0; } > conftest.i && {
067d23c9
KY
2019 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2020 test ! -s conftest.err
2021 }; then :
2022 ac_retval=0
2023else
2024 $as_echo "$as_me: failed program was:" >&5
2025sed 's/^/| /' conftest.$ac_ext >&5
2026
2027 ac_retval=1
2028fi
d6974efa 2029 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
067d23c9
KY
2030 as_fn_set_status $ac_retval
2031
2032} # ac_fn_c_try_cpp
2033
2034# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2035# -------------------------------------------------------
2036# Tests whether HEADER exists, giving a warning if it cannot be compiled using
2037# the include files in INCLUDES and setting the cache variable VAR
2038# accordingly.
2039ac_fn_c_check_header_mongrel ()
2040{
2041 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
d6974efa 2042 if eval \${$3+:} false; then :
067d23c9
KY
2043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2044$as_echo_n "checking for $2... " >&6; }
d6974efa 2045if eval \${$3+:} false; then :
067d23c9
KY
2046 $as_echo_n "(cached) " >&6
2047fi
2048eval ac_res=\$$3
2049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2050$as_echo "$ac_res" >&6; }
2051else
2052 # Is the header compilable?
2053{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2054$as_echo_n "checking $2 usability... " >&6; }
2055cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2056/* end confdefs.h. */
2057$4
2058#include <$2>
2059_ACEOF
2060if ac_fn_c_try_compile "$LINENO"; then :
2061 ac_header_compiler=yes
2062else
2063 ac_header_compiler=no
2064fi
2065rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2066{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2067$as_echo "$ac_header_compiler" >&6; }
2068
2069# Is the header present?
2070{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2071$as_echo_n "checking $2 presence... " >&6; }
2072cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2073/* end confdefs.h. */
2074#include <$2>
2075_ACEOF
2076if ac_fn_c_try_cpp "$LINENO"; then :
2077 ac_header_preproc=yes
2078else
2079 ac_header_preproc=no
2080fi
2018939f 2081rm -f conftest.err conftest.i conftest.$ac_ext
067d23c9
KY
2082{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2083$as_echo "$ac_header_preproc" >&6; }
2084
2085# So? What about this header?
2086case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2087 yes:no: )
2088 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2089$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2090 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2091$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2092 ;;
2093 no:yes:* )
2094 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2095$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2096 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2097$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2098 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2099$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2100 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2101$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2102 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2103$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2104 ;;
2105esac
2106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2107$as_echo_n "checking for $2... " >&6; }
d6974efa 2108if eval \${$3+:} false; then :
067d23c9
KY
2109 $as_echo_n "(cached) " >&6
2110else
2111 eval "$3=\$ac_header_compiler"
2112fi
2113eval ac_res=\$$3
2114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2115$as_echo "$ac_res" >&6; }
2116fi
d6974efa 2117 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
067d23c9
KY
2118
2119} # ac_fn_c_check_header_mongrel
2120
2121# ac_fn_c_try_run LINENO
2122# ----------------------
2123# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2124# that executables *can* be run.
2125ac_fn_c_try_run ()
2126{
2127 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2128 if { { ac_try="$ac_link"
2129case "(($ac_try" in
2130 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2131 *) ac_try_echo=$ac_try;;
2132esac
2133eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2134$as_echo "$ac_try_echo"; } >&5
2135 (eval "$ac_link") 2>&5
2136 ac_status=$?
2137 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2138 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2139 { { case "(($ac_try" in
2140 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2141 *) ac_try_echo=$ac_try;;
2142esac
2143eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2144$as_echo "$ac_try_echo"; } >&5
2145 (eval "$ac_try") 2>&5
2146 ac_status=$?
2147 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2148 test $ac_status = 0; }; }; then :
2149 ac_retval=0
2150else
2151 $as_echo "$as_me: program exited with status $ac_status" >&5
2152 $as_echo "$as_me: failed program was:" >&5
2153sed 's/^/| /' conftest.$ac_ext >&5
2154
2155 ac_retval=$ac_status
2156fi
2157 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
d6974efa 2158 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
067d23c9
KY
2159 as_fn_set_status $ac_retval
2160
2161} # ac_fn_c_try_run
2162
2163# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2164# -------------------------------------------------------
2165# Tests whether HEADER exists and can be compiled using the include files in
2166# INCLUDES, setting the cache variable VAR accordingly.
2167ac_fn_c_check_header_compile ()
2168{
2169 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2170 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2171$as_echo_n "checking for $2... " >&6; }
d6974efa 2172if eval \${$3+:} false; then :
067d23c9
KY
2173 $as_echo_n "(cached) " >&6
2174else
2175 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2176/* end confdefs.h. */
2177$4
2178#include <$2>
2179_ACEOF
2180if ac_fn_c_try_compile "$LINENO"; then :
2181 eval "$3=yes"
2182else
2183 eval "$3=no"
2184fi
2185rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2186fi
2187eval ac_res=\$$3
2188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2189$as_echo "$ac_res" >&6; }
d6974efa 2190 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
067d23c9
KY
2191
2192} # ac_fn_c_check_header_compile
2193
1fd182f0
PE
2194# ac_fn_c_try_link LINENO
2195# -----------------------
2196# Try to link conftest.$ac_ext, and return whether this succeeded.
2197ac_fn_c_try_link ()
2198{
2199 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2200 rm -f conftest.$ac_objext conftest$ac_exeext
2201 if { { ac_try="$ac_link"
2202case "(($ac_try" in
2203 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2204 *) ac_try_echo=$ac_try;;
2205esac
2206eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2207$as_echo "$ac_try_echo"; } >&5
2208 (eval "$ac_link") 2>conftest.err
2209 ac_status=$?
2210 if test -s conftest.err; then
2211 grep -v '^ *+' conftest.err >conftest.er1
2212 cat conftest.er1 >&5
2213 mv -f conftest.er1 conftest.err
2214 fi
2215 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2216 test $ac_status = 0; } && {
2217 test -z "$ac_c_werror_flag" ||
2218 test ! -s conftest.err
2219 } && test -s conftest$ac_exeext && {
2220 test "$cross_compiling" = yes ||
2221 $as_test_x conftest$ac_exeext
2222 }; then :
2223 ac_retval=0
2224else
2225 $as_echo "$as_me: failed program was:" >&5
2226sed 's/^/| /' conftest.$ac_ext >&5
2227
2228 ac_retval=1
2229fi
2230 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2231 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2232 # interfere with the next link command; also delete a directory that is
2233 # left behind by Apple's compiler. We do this before executing the actions.
2234 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
d6974efa 2235 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1fd182f0
PE
2236 as_fn_set_status $ac_retval
2237
2238} # ac_fn_c_try_link
2239
2018939f
AS
2240# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2241# ---------------------------------------------
2242# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2243# accordingly.
067d23c9
KY
2244ac_fn_c_check_decl ()
2245{
2246 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2018939f
AS
2247 as_decl_name=`echo $2|sed 's/ *(.*//'`
2248 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2250$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
d6974efa 2251if eval \${$3+:} false; then :
067d23c9
KY
2252 $as_echo_n "(cached) " >&6
2253else
2254 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2255/* end confdefs.h. */
2256$4
2257int
2258main ()
2259{
2018939f
AS
2260#ifndef $as_decl_name
2261#ifdef __cplusplus
2262 (void) $as_decl_use;
2263#else
2264 (void) $as_decl_name;
2265#endif
067d23c9
KY
2266#endif
2267
2268 ;
2269 return 0;
2270}
2271_ACEOF
2272if ac_fn_c_try_compile "$LINENO"; then :
2273 eval "$3=yes"
2274else
2275 eval "$3=no"
2276fi
2277rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2278fi
2279eval ac_res=\$$3
2280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2281$as_echo "$ac_res" >&6; }
d6974efa 2282 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
067d23c9
KY
2283
2284} # ac_fn_c_check_decl
2285
2286# ac_fn_c_check_header_preproc LINENO HEADER VAR
2287# ----------------------------------------------
2288# Tests whether HEADER is present, setting the cache variable VAR accordingly.
2289ac_fn_c_check_header_preproc ()
2290{
2291 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2293$as_echo_n "checking for $2... " >&6; }
d6974efa 2294if eval \${$3+:} false; then :
067d23c9
KY
2295 $as_echo_n "(cached) " >&6
2296else
2297 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2298/* end confdefs.h. */
2299#include <$2>
2300_ACEOF
2301if ac_fn_c_try_cpp "$LINENO"; then :
2302 eval "$3=yes"
2303else
2304 eval "$3=no"
2305fi
2018939f 2306rm -f conftest.err conftest.i conftest.$ac_ext
067d23c9
KY
2307fi
2308eval ac_res=\$$3
2309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2310$as_echo "$ac_res" >&6; }
d6974efa 2311 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
067d23c9
KY
2312
2313} # ac_fn_c_check_header_preproc
2314
2315# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2316# ----------------------------------------------------
2317# Tries to find if the field MEMBER exists in type AGGR, after including
2318# INCLUDES, setting cache variable VAR accordingly.
2319ac_fn_c_check_member ()
2320{
2321 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2323$as_echo_n "checking for $2.$3... " >&6; }
d6974efa 2324if eval \${$4+:} false; then :
067d23c9
KY
2325 $as_echo_n "(cached) " >&6
2326else
2327 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2328/* end confdefs.h. */
2329$5
2330int
2331main ()
2332{
2333static $2 ac_aggr;
2334if (ac_aggr.$3)
2335return 0;
2336 ;
2337 return 0;
2338}
2339_ACEOF
2340if ac_fn_c_try_compile "$LINENO"; then :
2341 eval "$4=yes"
2342else
2343 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2344/* end confdefs.h. */
2345$5
2346int
2347main ()
2348{
2349static $2 ac_aggr;
2350if (sizeof ac_aggr.$3)
2351return 0;
2352 ;
2353 return 0;
2354}
2355_ACEOF
2356if ac_fn_c_try_compile "$LINENO"; then :
2357 eval "$4=yes"
2358else
2359 eval "$4=no"
2360fi
2361rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2362fi
2363rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2364fi
2365eval ac_res=\$$4
2366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2367$as_echo "$ac_res" >&6; }
d6974efa 2368 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
067d23c9
KY
2369
2370} # ac_fn_c_check_member
2371
2372# ac_fn_c_check_func LINENO FUNC VAR
2373# ----------------------------------
2374# Tests whether FUNC exists, setting the cache variable VAR accordingly
2375ac_fn_c_check_func ()
2376{
2377 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2379$as_echo_n "checking for $2... " >&6; }
d6974efa 2380if eval \${$3+:} false; then :
067d23c9
KY
2381 $as_echo_n "(cached) " >&6
2382else
2383 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2384/* end confdefs.h. */
2385/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2386 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2387#define $2 innocuous_$2
2388
2389/* System header to define __stub macros and hopefully few prototypes,
2390 which can conflict with char $2 (); below.
2391 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2392 <limits.h> exists even on freestanding compilers. */
2393
2394#ifdef __STDC__
2395# include <limits.h>
2396#else
2397# include <assert.h>
2398#endif
2399
2400#undef $2
2401
2402/* Override any GCC internal prototype to avoid an error.
2403 Use char because int might match the return type of a GCC
2404 builtin and then its argument prototype would still apply. */
2405#ifdef __cplusplus
2406extern "C"
2407#endif
2408char $2 ();
2409/* The GNU C library defines this for functions which it implements
2410 to always fail with ENOSYS. Some functions are actually named
2411 something starting with __ and the normal name is an alias. */
2412#if defined __stub_$2 || defined __stub___$2
2413choke me
2414#endif
2415
2416int
2417main ()
2418{
2419return $2 ();
2420 ;
2421 return 0;
2422}
2423_ACEOF
2424if ac_fn_c_try_link "$LINENO"; then :
2425 eval "$3=yes"
2426else
2427 eval "$3=no"
2428fi
2429rm -f core conftest.err conftest.$ac_objext \
2430 conftest$ac_exeext conftest.$ac_ext
2431fi
2432eval ac_res=\$$3
2433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2434$as_echo "$ac_res" >&6; }
d6974efa 2435 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
067d23c9
KY
2436
2437} # ac_fn_c_check_func
2438
2439# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2440# -------------------------------------------
2441# Tests whether TYPE exists after having included INCLUDES, setting cache
2442# variable VAR accordingly.
2443ac_fn_c_check_type ()
2444{
2445 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2447$as_echo_n "checking for $2... " >&6; }
d6974efa 2448if eval \${$3+:} false; then :
067d23c9
KY
2449 $as_echo_n "(cached) " >&6
2450else
2451 eval "$3=no"
2452 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2453/* end confdefs.h. */
2454$4
2455int
2456main ()
2457{
2458if (sizeof ($2))
2459 return 0;
2460 ;
2461 return 0;
2462}
2463_ACEOF
2464if ac_fn_c_try_compile "$LINENO"; then :
2465 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2466/* end confdefs.h. */
2467$4
2468int
2469main ()
2470{
2471if (sizeof (($2)))
2472 return 0;
2473 ;
2474 return 0;
2475}
2476_ACEOF
2477if ac_fn_c_try_compile "$LINENO"; then :
2478
2479else
2480 eval "$3=yes"
2481fi
2482rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2483fi
2484rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2485fi
2486eval ac_res=\$$3
2487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2488$as_echo "$ac_res" >&6; }
d6974efa 2489 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
067d23c9
KY
2490
2491} # ac_fn_c_check_type
5f90be1b
PE
2492
2493# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2494# --------------------------------------------
2495# Tries to find the compile-time value of EXPR in a program that includes
2496# INCLUDES, setting VAR accordingly. Returns whether the value could be
2497# computed
2498ac_fn_c_compute_int ()
2499{
2500 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2501 if test "$cross_compiling" = yes; then
2502 # Depending upon the size, compute the lo and hi bounds.
2503cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2504/* end confdefs.h. */
2505$4
2506int
2507main ()
2508{
2509static int test_array [1 - 2 * !(($2) >= 0)];
2510test_array [0] = 0
2511
2512 ;
2513 return 0;
2514}
2515_ACEOF
2516if ac_fn_c_try_compile "$LINENO"; then :
2517 ac_lo=0 ac_mid=0
2518 while :; do
2519 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2520/* end confdefs.h. */
2521$4
2522int
2523main ()
2524{
2525static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2526test_array [0] = 0
2527
2528 ;
2529 return 0;
2530}
2531_ACEOF
2532if ac_fn_c_try_compile "$LINENO"; then :
2533 ac_hi=$ac_mid; break
2534else
2535 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2536 if test $ac_lo -le $ac_mid; then
2537 ac_lo= ac_hi=
2538 break
2539 fi
2540 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2541fi
2542rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2543 done
2544else
2545 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2546/* end confdefs.h. */
2547$4
2548int
2549main ()
2550{
2551static int test_array [1 - 2 * !(($2) < 0)];
2552test_array [0] = 0
2553
2554 ;
2555 return 0;
2556}
2557_ACEOF
2558if ac_fn_c_try_compile "$LINENO"; then :
2559 ac_hi=-1 ac_mid=-1
2560 while :; do
2561 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2562/* end confdefs.h. */
2563$4
2564int
2565main ()
2566{
2567static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2568test_array [0] = 0
2569
2570 ;
2571 return 0;
2572}
2573_ACEOF
2574if ac_fn_c_try_compile "$LINENO"; then :
2575 ac_lo=$ac_mid; break
2576else
2577 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2578 if test $ac_mid -le $ac_hi; then
2579 ac_lo= ac_hi=
2580 break
2581 fi
2582 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2583fi
2584rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2585 done
2586else
2587 ac_lo= ac_hi=
2588fi
2589rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2590fi
2591rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2592# Binary search between lo and hi bounds.
2593while test "x$ac_lo" != "x$ac_hi"; do
2594 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2596/* end confdefs.h. */
2597$4
2598int
2599main ()
2600{
2601static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2602test_array [0] = 0
2603
2604 ;
2605 return 0;
2606}
2607_ACEOF
2608if ac_fn_c_try_compile "$LINENO"; then :
2609 ac_hi=$ac_mid
2610else
2611 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2612fi
2613rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2614done
2615case $ac_lo in #((
2616?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2617'') ac_retval=1 ;;
2618esac
2619 else
2620 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2621/* end confdefs.h. */
2622$4
2623static long int longval () { return $2; }
2624static unsigned long int ulongval () { return $2; }
2625#include <stdio.h>
2626#include <stdlib.h>
2627int
2628main ()
2629{
2630
2631 FILE *f = fopen ("conftest.val", "w");
2632 if (! f)
2633 return 1;
2634 if (($2) < 0)
2635 {
2636 long int i = longval ();
2637 if (i != ($2))
2638 return 1;
2639 fprintf (f, "%ld", i);
2640 }
2641 else
2642 {
2643 unsigned long int i = ulongval ();
2644 if (i != ($2))
2645 return 1;
2646 fprintf (f, "%lu", i);
2647 }
2648 /* Do not output a trailing newline, as this causes \r\n confusion
2649 on some platforms. */
2650 return ferror (f) || fclose (f) != 0;
2651
2652 ;
2653 return 0;
2654}
2655_ACEOF
2656if ac_fn_c_try_run "$LINENO"; then :
2657 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2658else
2659 ac_retval=1
2660fi
2661rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2662 conftest.$ac_objext conftest.beam conftest.$ac_ext
2663rm -f conftest.val
2664
2665 fi
2666 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2667 as_fn_set_status $ac_retval
2668
2669} # ac_fn_c_compute_int
067d23c9
KY
2670cat >config.log <<_ACEOF
2671This file contains any messages produced by compilers while
2672running configure, to aid debugging if configure makes a mistake.
2673
2674It was created by emacs $as_me 24.0.50, which was
d6974efa 2675generated by GNU Autoconf 2.68. Invocation command line was
067d23c9
KY
2676
2677 $ $0 $@
2678
2679_ACEOF
2680exec 5>>config.log
2681{
2682cat <<_ASUNAME
2683## --------- ##
2684## Platform. ##
2685## --------- ##
2686
2687hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2688uname -m = `(uname -m) 2>/dev/null || echo unknown`
2689uname -r = `(uname -r) 2>/dev/null || echo unknown`
2690uname -s = `(uname -s) 2>/dev/null || echo unknown`
2691uname -v = `(uname -v) 2>/dev/null || echo unknown`
2692
2693/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2694/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2695
2696/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2697/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2698/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2699/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2700/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2701/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2702/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2703
2704_ASUNAME
2705
2706as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2707for as_dir in $PATH
2708do
2709 IFS=$as_save_IFS
2710 test -z "$as_dir" && as_dir=.
2711 $as_echo "PATH: $as_dir"
2712 done
2713IFS=$as_save_IFS
2714
2715} >&5
2716
2717cat >&5 <<_ACEOF
2718
2719
2720## ----------- ##
2721## Core tests. ##
2722## ----------- ##
2723
2724_ACEOF
2725
2726
2727# Keep a trace of the command line.
2728# Strip out --no-create and --no-recursion so they do not pile up.
2729# Strip out --silent because we don't want to record it for future runs.
2730# Also quote any args containing shell meta-characters.
2731# Make two passes to allow for proper duplicate-argument suppression.
2732ac_configure_args=
2733ac_configure_args0=
2734ac_configure_args1=
2735ac_must_keep_next=false
2736for ac_pass in 1 2
2737do
2738 for ac_arg
2739 do
2740 case $ac_arg in
2741 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2742 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2743 | -silent | --silent | --silen | --sile | --sil)
2744 continue ;;
2745 *\'*)
2746 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2747 esac
2748 case $ac_pass in
2749 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2750 2)
2751 as_fn_append ac_configure_args1 " '$ac_arg'"
2752 if test $ac_must_keep_next = true; then
2753 ac_must_keep_next=false # Got value, back to normal.
2754 else
2755 case $ac_arg in
2756 *=* | --config-cache | -C | -disable-* | --disable-* \
2757 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2758 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2759 | -with-* | --with-* | -without-* | --without-* | --x)
2760 case "$ac_configure_args0 " in
2761 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2762 esac
2763 ;;
2764 -* ) ac_must_keep_next=true ;;
2765 esac
2766 fi
2767 as_fn_append ac_configure_args " '$ac_arg'"
2768 ;;
2769 esac
2770 done
2771done
2772{ ac_configure_args0=; unset ac_configure_args0;}
2773{ ac_configure_args1=; unset ac_configure_args1;}
2774
2775# When interrupted or exit'd, cleanup temporary files, and complete
2776# config.log. We remove comments because anyway the quotes in there
2777# would cause problems or look ugly.
2778# WARNING: Use '\'' to represent an apostrophe within the trap.
2779# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2780trap 'exit_status=$?
2781 # Save into config.log some information that might help in debugging.
2782 {
2783 echo
2784
2018939f 2785 $as_echo "## ---------------- ##
067d23c9 2786## Cache variables. ##
2018939f 2787## ---------------- ##"
067d23c9
KY
2788 echo
2789 # The following way of writing the cache mishandles newlines in values,
2790(
2791 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2792 eval ac_val=\$$ac_var
2793 case $ac_val in #(
2794 *${as_nl}*)
2795 case $ac_var in #(
2796 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2797$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2798 esac
2799 case $ac_var in #(
2800 _ | IFS | as_nl) ;; #(
2801 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2802 *) { eval $ac_var=; unset $ac_var;} ;;
2803 esac ;;
2804 esac
2805 done
2806 (set) 2>&1 |
2807 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2808 *${as_nl}ac_space=\ *)
2809 sed -n \
2810 "s/'\''/'\''\\\\'\'''\''/g;
2811 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2812 ;; #(
2813 *)
2814 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2815 ;;
2816 esac |
2817 sort
2818)
2819 echo
2820
2018939f 2821 $as_echo "## ----------------- ##
067d23c9 2822## Output variables. ##
2018939f 2823## ----------------- ##"
067d23c9
KY
2824 echo
2825 for ac_var in $ac_subst_vars
2826 do
2827 eval ac_val=\$$ac_var
2828 case $ac_val in
2829 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2830 esac
2831 $as_echo "$ac_var='\''$ac_val'\''"
2832 done | sort
2833 echo
2834
2835 if test -n "$ac_subst_files"; then
2018939f 2836 $as_echo "## ------------------- ##
067d23c9 2837## File substitutions. ##
2018939f 2838## ------------------- ##"
067d23c9
KY
2839 echo
2840 for ac_var in $ac_subst_files
2841 do
2842 eval ac_val=\$$ac_var
2843 case $ac_val in
2844 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2845 esac
2846 $as_echo "$ac_var='\''$ac_val'\''"
2847 done | sort
2848 echo
2849 fi
2850
2851 if test -s confdefs.h; then
2018939f 2852 $as_echo "## ----------- ##
067d23c9 2853## confdefs.h. ##
2018939f 2854## ----------- ##"
067d23c9
KY
2855 echo
2856 cat confdefs.h
2857 echo
2858 fi
2859 test "$ac_signal" != 0 &&
2860 $as_echo "$as_me: caught signal $ac_signal"
2861 $as_echo "$as_me: exit $exit_status"
2862 } >&5
2863 rm -f core *.core core.conftest.* &&
2864 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2865 exit $exit_status
2866' 0
2867for ac_signal in 1 2 13 15; do
2868 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2869done
2870ac_signal=0
2871
2872# confdefs.h avoids OS command line length limits that DEFS can exceed.
2873rm -f -r conftest* confdefs.h
2874
2875$as_echo "/* confdefs.h */" > confdefs.h
2876
2877# Predefined preprocessor variables.
2878
2879cat >>confdefs.h <<_ACEOF
2880#define PACKAGE_NAME "$PACKAGE_NAME"
2881_ACEOF
2882
2883cat >>confdefs.h <<_ACEOF
2884#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2885_ACEOF
2886
2887cat >>confdefs.h <<_ACEOF
2888#define PACKAGE_VERSION "$PACKAGE_VERSION"
2889_ACEOF
2890
2891cat >>confdefs.h <<_ACEOF
2892#define PACKAGE_STRING "$PACKAGE_STRING"
2893_ACEOF
2894
2895cat >>confdefs.h <<_ACEOF
2896#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2897_ACEOF
2898
2899cat >>confdefs.h <<_ACEOF
2900#define PACKAGE_URL "$PACKAGE_URL"
2901_ACEOF
2902
2903
2904# Let the site file select an alternate cache file if it wants to.
2905# Prefer an explicitly selected file to automatically selected ones.
2906ac_site_file1=NONE
2907ac_site_file2=NONE
2908if test -n "$CONFIG_SITE"; then
2018939f
AS
2909 # We do not want a PATH search for config.site.
2910 case $CONFIG_SITE in #((
2911 -*) ac_site_file1=./$CONFIG_SITE;;
2912 */*) ac_site_file1=$CONFIG_SITE;;
2913 *) ac_site_file1=./$CONFIG_SITE;;
2914 esac
067d23c9
KY
2915elif test "x$prefix" != xNONE; then
2916 ac_site_file1=$prefix/share/config.site
2917 ac_site_file2=$prefix/etc/config.site
2918else
2919 ac_site_file1=$ac_default_prefix/share/config.site
2920 ac_site_file2=$ac_default_prefix/etc/config.site
2921fi
2922for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2923do
2924 test "x$ac_site_file" = xNONE && continue
2925 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2926 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2927$as_echo "$as_me: loading site script $ac_site_file" >&6;}
2928 sed 's/^/| /' "$ac_site_file" >&5
2018939f
AS
2929 . "$ac_site_file" \
2930 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2931$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2932as_fn_error $? "failed to load site script $ac_site_file
d6974efa 2933See \`config.log' for more details" "$LINENO" 5; }
067d23c9
KY
2934 fi
2935done
2936
2937if test -r "$cache_file"; then
2938 # Some versions of bash will fail to source /dev/null (special files
2939 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2940 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2941 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2942$as_echo "$as_me: loading cache $cache_file" >&6;}
2943 case $cache_file in
2944 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2945 *) . "./$cache_file";;
2946 esac
2947 fi
2948else
2949 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2950$as_echo "$as_me: creating cache $cache_file" >&6;}
2951 >$cache_file
2952fi
2953
2954as_fn_append ac_header_list " stdlib.h"
2955as_fn_append ac_header_list " unistd.h"
2956as_fn_append ac_header_list " sys/param.h"
e275c824
PE
2957gl_getopt_required=GNU
2958as_fn_append ac_header_list " getopt.h"
067d23c9 2959as_fn_append ac_func_list " alarm"
5f90be1b
PE
2960as_fn_append ac_header_list " wchar.h"
2961as_fn_append ac_header_list " stdint.h"
16c3e636 2962as_fn_append ac_func_list " tzset"
5fa4ac76 2963as_fn_append ac_header_list " sys/stat.h"
1fd182f0
PE
2964as_fn_append ac_header_list " sys/time.h"
2965as_fn_append ac_func_list " localtime_r"
067d23c9
KY
2966# Check that the precious variables saved in the cache have kept the same
2967# value.
2968ac_cache_corrupted=false
2969for ac_var in $ac_precious_vars; do
2970 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2971 eval ac_new_set=\$ac_env_${ac_var}_set
2972 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2973 eval ac_new_val=\$ac_env_${ac_var}_value
2974 case $ac_old_set,$ac_new_set in
2975 set,)
2976 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2977$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2978 ac_cache_corrupted=: ;;
2979 ,set)
2980 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2981$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2982 ac_cache_corrupted=: ;;
2983 ,);;
2984 *)
2985 if test "x$ac_old_val" != "x$ac_new_val"; then
2986 # differences in whitespace do not lead to failure.
2987 ac_old_val_w=`echo x $ac_old_val`
2988 ac_new_val_w=`echo x $ac_new_val`
2989 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2990 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2991$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2992 ac_cache_corrupted=:
2993 else
2994 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2995$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2996 eval $ac_var=\$ac_old_val
2997 fi
2998 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2999$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3000 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3001$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3002 fi;;
3003 esac
3004 # Pass precious variables to config.status.
3005 if test "$ac_new_set" = set; then
3006 case $ac_new_val in
3007 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3008 *) ac_arg=$ac_var=$ac_new_val ;;
3009 esac
3010 case " $ac_configure_args " in
3011 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3012 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3013 esac
3014 fi
3015done
3016if $ac_cache_corrupted; then
3017 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3018$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3019 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3020$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2018939f 3021 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
067d23c9
KY
3022fi
3023## -------------------- ##
3024## Main body of script. ##
3025## -------------------- ##
3026
3027ac_ext=c
3028ac_cpp='$CPP $CPPFLAGS'
3029ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3030ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3031ac_compiler_gnu=$ac_cv_c_compiler_gnu
3032
3033
3034ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3035
3036
743c80a7 3037am__api_version='1.11'
067d23c9 3038
743c80a7
PE
3039ac_aux_dir=
3040for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
3041 if test -f "$ac_dir/install-sh"; then
3042 ac_aux_dir=$ac_dir
3043 ac_install_sh="$ac_aux_dir/install-sh -c"
3044 break
3045 elif test -f "$ac_dir/install.sh"; then
3046 ac_aux_dir=$ac_dir
3047 ac_install_sh="$ac_aux_dir/install.sh -c"
3048 break
3049 elif test -f "$ac_dir/shtool"; then
3050 ac_aux_dir=$ac_dir
3051 ac_install_sh="$ac_aux_dir/shtool install -c"
3052 break
3053 fi
3054done
3055if test -z "$ac_aux_dir"; then
3056 as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
3057fi
067d23c9 3058
743c80a7
PE
3059# These three variables are undocumented and unsupported,
3060# and are intended to be withdrawn in a future Autoconf release.
3061# They can cause serious problems if a builder's source tree is in a directory
3062# whose full name contains unusual characters.
3063ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3064ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3065ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
067d23c9 3066
067d23c9 3067
743c80a7
PE
3068# Find a good install program. We prefer a C program (faster),
3069# so one script is as good as another. But avoid the broken or
3070# incompatible versions:
3071# SysV /etc/install, /usr/sbin/install
3072# SunOS /usr/etc/install
3073# IRIX /sbin/install
3074# AIX /bin/install
3075# AmigaOS /C/install, which installs bootblocks on floppy discs
3076# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3077# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3078# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3079# OS/2's system install, which has a completely different semantic
3080# ./install, which can be erroneously created by make from ./install.sh.
3081# Reject install programs that cannot install multiple files.
3082{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3083$as_echo_n "checking for a BSD-compatible install... " >&6; }
3084if test -z "$INSTALL"; then
d6974efa 3085if ${ac_cv_path_install+:} false; then :
743c80a7
PE
3086 $as_echo_n "(cached) " >&6
3087else
3088 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3089for as_dir in $PATH
3090do
3091 IFS=$as_save_IFS
3092 test -z "$as_dir" && as_dir=.
3093 # Account for people who put trailing slashes in PATH elements.
3094case $as_dir/ in #((
3095 ./ | .// | /[cC]/* | \
3096 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3097 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3098 /usr/ucb/* ) ;;
3099 *)
3100 # OSF1 and SCO ODT 3.0 have their own names for install.
3101 # Don't use installbsd from OSF since it installs stuff as root
3102 # by default.
3103 for ac_prog in ginstall scoinst install; do
3104 for ac_exec_ext in '' $ac_executable_extensions; do
3105 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3106 if test $ac_prog = install &&
3107 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3108 # AIX install. It has an incompatible calling convention.
3109 :
3110 elif test $ac_prog = install &&
3111 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3112 # program-specific install script used by HP pwplus--don't use.
3113 :
3114 else
3115 rm -rf conftest.one conftest.two conftest.dir
3116 echo one > conftest.one
3117 echo two > conftest.two
3118 mkdir conftest.dir
3119 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3120 test -s conftest.one && test -s conftest.two &&
3121 test -s conftest.dir/conftest.one &&
3122 test -s conftest.dir/conftest.two
3123 then
3124 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3125 break 3
3126 fi
3127 fi
3128 fi
3129 done
3130 done
3131 ;;
3132esac
067d23c9 3133
743c80a7
PE
3134 done
3135IFS=$as_save_IFS
067d23c9 3136
743c80a7 3137rm -rf conftest.one conftest.two conftest.dir
067d23c9 3138
067d23c9 3139fi
743c80a7
PE
3140 if test "${ac_cv_path_install+set}" = set; then
3141 INSTALL=$ac_cv_path_install
3142 else
3143 # As a last resort, use the slow shell script. Don't cache a
3144 # value for INSTALL within a source directory, because that will
3145 # break other packages using the cache if that directory is
3146 # removed, or if the value is a relative name.
3147 INSTALL=$ac_install_sh
3148 fi
067d23c9 3149fi
743c80a7
PE
3150{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3151$as_echo "$INSTALL" >&6; }
067d23c9 3152
743c80a7
PE
3153# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3154# It thinks the first close brace ends the variable substitution.
3155test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
067d23c9 3156
743c80a7 3157test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
067d23c9 3158
743c80a7 3159test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
067d23c9 3160
743c80a7
PE
3161{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3162$as_echo_n "checking whether build environment is sane... " >&6; }
3163# Just in case
3164sleep 1
3165echo timestamp > conftest.file
3166# Reject unsafe characters in $srcdir or the absolute working directory
3167# name. Accept space and tab only in the latter.
3168am_lf='
3169'
3170case `pwd` in
3171 *[\\\"\#\$\&\'\`$am_lf]*)
d6974efa 3172 as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
743c80a7
PE
3173esac
3174case $srcdir in
3175 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
d6974efa 3176 as_fn_error $? "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
743c80a7 3177esac
067d23c9 3178
743c80a7
PE
3179# Do `set' in a subshell so we don't clobber the current shell's
3180# arguments. Must try -L first in case configure is actually a
3181# symlink; some systems play weird games with the mod time of symlinks
3182# (eg FreeBSD returns the mod time of the symlink's containing
3183# directory).
3184if (
3185 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3186 if test "$*" = "X"; then
3187 # -L didn't work.
3188 set X `ls -t "$srcdir/configure" conftest.file`
3189 fi
3190 rm -f conftest.file
3191 if test "$*" != "X $srcdir/configure conftest.file" \
3192 && test "$*" != "X conftest.file $srcdir/configure"; then
3193
3194 # If neither matched, then we have a broken ls. This can happen
3195 # if, for instance, CONFIG_SHELL is bash and it inherits a
3196 # broken ls alias from the environment. This has actually
3197 # happened. Such a system could not be considered "sane".
3198 as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
3199alias in your environment" "$LINENO" 5
3200 fi
067d23c9 3201
743c80a7
PE
3202 test "$2" = conftest.file
3203 )
3204then
3205 # Ok.
3206 :
067d23c9 3207else
743c80a7
PE
3208 as_fn_error $? "newly created file is older than distributed files!
3209Check your system clock" "$LINENO" 5
067d23c9 3210fi
743c80a7
PE
3211{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3212$as_echo "yes" >&6; }
3213test "$program_prefix" != NONE &&
3214 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3215# Use a double $ so make ignores it.
3216test "$program_suffix" != NONE &&
3217 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3218# Double any \ or $.
3219# By default was `s,x,x', remove it if useless.
3220ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3221program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
067d23c9 3222
743c80a7
PE
3223# expand $ac_aux_dir to an absolute path
3224am_aux_dir=`cd $ac_aux_dir && pwd`
067d23c9 3225
743c80a7
PE
3226if test x"${MISSING+set}" != xset; then
3227 case $am_aux_dir in
3228 *\ * | *\ *)
3229 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3230 *)
3231 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3232 esac
067d23c9 3233fi
743c80a7
PE
3234# Use eval to expand $SHELL
3235if eval "$MISSING --run true"; then
3236 am_missing_run="$MISSING --run "
067d23c9 3237else
743c80a7
PE
3238 am_missing_run=
3239 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3240$as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
067d23c9
KY
3241fi
3242
743c80a7
PE
3243if test x"${install_sh}" != xset; then
3244 case $am_aux_dir in
3245 *\ * | *\ *)
3246 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3247 *)
3248 install_sh="\${SHELL} $am_aux_dir/install-sh"
3249 esac
067d23c9
KY
3250fi
3251
743c80a7
PE
3252# Installed binaries are usually stripped using `strip' when the user
3253# run `make install-strip'. However `strip' might not be the right
3254# tool to use in cross-compilation environments, therefore Automake
3255# will honor the `STRIP' environment variable to overrule this program.
3256if test "$cross_compiling" != no; then
3257 if test -n "$ac_tool_prefix"; then
3258 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3259set dummy ${ac_tool_prefix}strip; ac_word=$2
3260{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3261$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 3262if ${ac_cv_prog_STRIP+:} false; then :
743c80a7 3263 $as_echo_n "(cached) " >&6
067d23c9 3264else
743c80a7
PE
3265 if test -n "$STRIP"; then
3266 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3267else
3268as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3269for as_dir in $PATH
3270do
3271 IFS=$as_save_IFS
3272 test -z "$as_dir" && as_dir=.
3273 for ac_exec_ext in '' $ac_executable_extensions; do
3274 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3275 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3276 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3277 break 2
3278 fi
3279done
3280 done
3281IFS=$as_save_IFS
067d23c9
KY
3282
3283fi
067d23c9 3284fi
743c80a7
PE
3285STRIP=$ac_cv_prog_STRIP
3286if test -n "$STRIP"; then
3287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3288$as_echo "$STRIP" >&6; }
3289else
3290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3291$as_echo "no" >&6; }
067d23c9
KY
3292fi
3293
3294
067d23c9 3295fi
743c80a7
PE
3296if test -z "$ac_cv_prog_STRIP"; then
3297 ac_ct_STRIP=$STRIP
3298 # Extract the first word of "strip", so it can be a program name with args.
3299set dummy strip; ac_word=$2
3300{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3301$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 3302if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
743c80a7
PE
3303 $as_echo_n "(cached) " >&6
3304else
3305 if test -n "$ac_ct_STRIP"; then
3306 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3307else
3308as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3309for as_dir in $PATH
3310do
3311 IFS=$as_save_IFS
3312 test -z "$as_dir" && as_dir=.
3313 for ac_exec_ext in '' $ac_executable_extensions; do
3314 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3315 ac_cv_prog_ac_ct_STRIP="strip"
3316 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3317 break 2
3318 fi
3319done
3320 done
3321IFS=$as_save_IFS
3322
3323fi
3324fi
3325ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3326if test -n "$ac_ct_STRIP"; then
3327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3328$as_echo "$ac_ct_STRIP" >&6; }
3329else
3330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3331$as_echo "no" >&6; }
3332fi
3333
3334 if test "x$ac_ct_STRIP" = x; then
3335 STRIP=":"
3336 else
3337 case $cross_compiling:$ac_tool_warned in
3338yes:)
3339{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3340$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3341ac_tool_warned=yes ;;
3342esac
3343 STRIP=$ac_ct_STRIP
3344 fi
3345else
3346 STRIP="$ac_cv_prog_STRIP"
3347fi
3348
3349fi
3350INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3351
3352{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3353$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3354if test -z "$MKDIR_P"; then
d6974efa 3355 if ${ac_cv_path_mkdir+:} false; then :
743c80a7
PE
3356 $as_echo_n "(cached) " >&6
3357else
3358 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3359for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3360do
3361 IFS=$as_save_IFS
3362 test -z "$as_dir" && as_dir=.
3363 for ac_prog in mkdir gmkdir; do
3364 for ac_exec_ext in '' $ac_executable_extensions; do
3365 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3366 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3367 'mkdir (GNU coreutils) '* | \
3368 'mkdir (coreutils) '* | \
3369 'mkdir (fileutils) '4.1*)
3370 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3371 break 3;;
3372 esac
3373 done
3374 done
3375 done
3376IFS=$as_save_IFS
3377
3378fi
3379
3380 test -d ./--version && rmdir ./--version
3381 if test "${ac_cv_path_mkdir+set}" = set; then
3382 MKDIR_P="$ac_cv_path_mkdir -p"
3383 else
3384 # As a last resort, use the slow shell script. Don't cache a
3385 # value for MKDIR_P within a source directory, because that will
3386 # break other packages using the cache if that directory is
3387 # removed, or if the value is a relative name.
3388 MKDIR_P="$ac_install_sh -d"
3389 fi
3390fi
3391{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3392$as_echo "$MKDIR_P" >&6; }
3393
a451f14b 3394
743c80a7
PE
3395mkdir_p="$MKDIR_P"
3396case $mkdir_p in
3397 [\\/$]* | ?:[\\/]*) ;;
3398 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3399esac
3400
3401for ac_prog in gawk mawk nawk awk
3402do
3403 # Extract the first word of "$ac_prog", so it can be a program name with args.
3404set dummy $ac_prog; ac_word=$2
3405{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3406$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 3407if ${ac_cv_prog_AWK+:} false; then :
743c80a7
PE
3408 $as_echo_n "(cached) " >&6
3409else
3410 if test -n "$AWK"; then
3411 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3412else
3413as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3414for as_dir in $PATH
3415do
3416 IFS=$as_save_IFS
3417 test -z "$as_dir" && as_dir=.
3418 for ac_exec_ext in '' $ac_executable_extensions; do
3419 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3420 ac_cv_prog_AWK="$ac_prog"
3421 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3422 break 2
3423 fi
3424done
3425 done
3426IFS=$as_save_IFS
3427
3428fi
3429fi
3430AWK=$ac_cv_prog_AWK
3431if test -n "$AWK"; then
3432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3433$as_echo "$AWK" >&6; }
3434else
3435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3436$as_echo "no" >&6; }
3437fi
3438
3439
3440 test -n "$AWK" && break
3441done
3442
3443{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3444$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3445set x ${MAKE-make}
3446ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
d6974efa 3447if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
743c80a7
PE
3448 $as_echo_n "(cached) " >&6
3449else
3450 cat >conftest.make <<\_ACEOF
3451SHELL = /bin/sh
3452all:
3453 @echo '@@@%%%=$(MAKE)=@@@%%%'
3454_ACEOF
3455# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
3456case `${MAKE-make} -f conftest.make 2>/dev/null` in
3457 *@@@%%%=?*=@@@%%%*)
3458 eval ac_cv_prog_make_${ac_make}_set=yes;;
3459 *)
3460 eval ac_cv_prog_make_${ac_make}_set=no;;
3461esac
3462rm -f conftest.make
3463fi
3464if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3466$as_echo "yes" >&6; }
3467 SET_MAKE=
3468else
3469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3470$as_echo "no" >&6; }
3471 SET_MAKE="MAKE=${MAKE-make}"
3472fi
3473
3474rm -rf .tst 2>/dev/null
3475mkdir .tst 2>/dev/null
3476if test -d .tst; then
3477 am__leading_dot=.
3478else
3479 am__leading_dot=_
3480fi
3481rmdir .tst 2>/dev/null
3482
3483if test "`cd $srcdir && pwd`" != "`pwd`"; then
3484 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3485 # is not polluted with repeated "-I."
3486 am__isrc=' -I$(srcdir)'
3487 # test to see if srcdir already configured
3488 if test -f $srcdir/config.status; then
3489 as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3490 fi
3491fi
3492
3493# test whether we have cygpath
3494if test -z "$CYGPATH_W"; then
3495 if (cygpath --version) >/dev/null 2>/dev/null; then
3496 CYGPATH_W='cygpath -w'
3497 else
3498 CYGPATH_W=echo
3499 fi
3500fi
3501
3502
3503# Define the identity of the package.
3504 PACKAGE='emacs'
3505 VERSION='24.0.50'
3506
3507
3508cat >>confdefs.h <<_ACEOF
3509#define PACKAGE "$PACKAGE"
3510_ACEOF
3511
3512
3513cat >>confdefs.h <<_ACEOF
3514#define VERSION "$VERSION"
3515_ACEOF
3516
3517# Some tools Automake needs.
3518
3519ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3520
3521
3522AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3523
3524
3525AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3526
3527
3528AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3529
3530
3531MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3532
3533# We need awk for the "check" target. The system "awk" is bad on
3534# some platforms.
3535# Always define AMTAR for backward compatibility.
3536
3537AMTAR=${AMTAR-"${am_missing_run}tar"}
3538
3539am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3540
3541
3542
3543
3544
3545
3546
3547
3548lispdir='${datadir}/emacs/${version}/lisp'
3549locallisppath='${datadir}/emacs/${version}/site-lisp:'\
3550'${datadir}/emacs/site-lisp'
3551lisppath='${locallisppath}:${lispdir}:${datadir}/emacs/${version}/leim'
3552etcdir='${datadir}/emacs/${version}/etc'
3553archlibdir='${libexecdir}/emacs/${version}/${configuration}'
3554docdir='${datadir}/emacs/${version}/etc'
3555gamedir='${localstatedir}/games/emacs'
3556
3557
3558
3559
3560# Check whether --with-pop was given.
3561if test "${with_pop+set}" = set; then :
3562 withval=$with_pop;
3563else
3564 with_pop=yes
3565fi
3566
3567if test "$with_pop" = yes; then
3568 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
3569
3570fi
3571
3572
3573# Check whether --with-kerberos was given.
3574if test "${with_kerberos+set}" = set; then :
3575 withval=$with_kerberos;
3576else
3577 with_kerberos=no
3578fi
3579
3580if test "$with_kerberos" != no; then
3581 $as_echo "#define KERBEROS 1" >>confdefs.h
3582
3583fi
3584
3585
3586# Check whether --with-kerberos5 was given.
3587if test "${with_kerberos5+set}" = set; then :
3588 withval=$with_kerberos5;
3589else
3590 with_kerberos5=no
3591fi
3592
3593if test "${with_kerberos5}" != no; then
3594 if test "${with_kerberos}" = no; then
3595 with_kerberos=yes
3596 $as_echo "#define KERBEROS 1" >>confdefs.h
3597
3598 fi
3599
3600$as_echo "#define KERBEROS5 1" >>confdefs.h
3601
3602fi
3603
3604
3605# Check whether --with-hesiod was given.
3606if test "${with_hesiod+set}" = set; then :
3607 withval=$with_hesiod;
3608else
3609 with_hesiod=no
3610fi
3611
3612if test "$with_hesiod" != no; then
3613
3614$as_echo "#define HESIOD 1" >>confdefs.h
3615
3616fi
3617
3618
3619# Check whether --with-mmdf was given.
3620if test "${with_mmdf+set}" = set; then :
3621 withval=$with_mmdf;
3622else
3623 with_mmdf=no
3624fi
3625
3626if test "$with_mmdf" != no; then
3627
3628$as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
3629
3630fi
3631
3632
3633# Check whether --with-mail-unlink was given.
3634if test "${with_mail_unlink+set}" = set; then :
3635 withval=$with_mail_unlink;
3636else
3637 with_mail_unlink=no
3638fi
3639
3640if test "$with_mail_unlink" != no; then
3641
3642$as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
3643
3644fi
3645
3646
3647# Check whether --with-mailhost was given.
3648if test "${with_mailhost+set}" = set; then :
3649 withval=$with_mailhost;
3650cat >>confdefs.h <<_ACEOF
3651#define MAILHOST "$withval"
3652_ACEOF
3653
3654fi
3655
3656
3657
067d23c9
KY
3658# Check whether --with-sound was given.
3659if test "${with_sound+set}" = set; then :
3660 withval=$with_sound;
3661else
3662 with_sound=yes
3663fi
3664
3665
3666
3667# Check whether --with-sync-input was given.
3668if test "${with_sync_input+set}" = set; then :
3669 withval=$with_sync_input;
3670else
3671 with_sync_input=yes
3672fi
3673
3674if test "$with_sync_input" = yes; then
3675
3676$as_echo "#define SYNC_INPUT 1" >>confdefs.h
3677
3678fi
3679
3680
3681# Check whether --with-x-toolkit was given.
3682if test "${with_x_toolkit+set}" = set; then :
3683 withval=$with_x_toolkit; case "${withval}" in
3684 y | ye | yes ) val=gtk ;;
3685 n | no ) val=no ;;
3686 l | lu | luc | luci | lucid ) val=lucid ;;
3687 a | at | ath | athe | athen | athena ) val=athena ;;
3688 m | mo | mot | moti | motif ) val=motif ;;
3689 g | gt | gtk ) val=gtk ;;
3690 gtk3 ) val=gtk3 ;;
3691 * )
2018939f 3692as_fn_error $? "\`--with-x-toolkit=$withval' is invalid;
067d23c9
KY
3693this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk' or
3694\`gtk3'. \`yes' and \`gtk' are synonyms. \`athena' and \`lucid' are synonyms." "$LINENO" 5
3695 ;;
3696 esac
3697 with_x_toolkit=$val
3698
3699fi
3700
3701
3702
3703# Check whether --with-xpm was given.
3704if test "${with_xpm+set}" = set; then :
3705 withval=$with_xpm;
3706else
3707 with_xpm=yes
3708fi
3709
3710
3711# Check whether --with-jpeg was given.
3712if test "${with_jpeg+set}" = set; then :
3713 withval=$with_jpeg;
3714else
3715 with_jpeg=yes
3716fi
3717
3718
3719# Check whether --with-tiff was given.
3720if test "${with_tiff+set}" = set; then :
3721 withval=$with_tiff;
3722else
3723 with_tiff=yes
3724fi
3725
3726
3727# Check whether --with-gif was given.
3728if test "${with_gif+set}" = set; then :
3729 withval=$with_gif;
3730else
3731 with_gif=yes
3732fi
3733
3734
3735# Check whether --with-png was given.
3736if test "${with_png+set}" = set; then :
3737 withval=$with_png;
3738else
3739 with_png=yes
3740fi
3741
3742
3743# Check whether --with-rsvg was given.
3744if test "${with_rsvg+set}" = set; then :
3745 withval=$with_rsvg;
3746else
3747 with_rsvg=yes
3748fi
3749
3750
3751# Check whether --with-xml2 was given.
3752if test "${with_xml2+set}" = set; then :
3753 withval=$with_xml2;
3754else
3755 with_xml2=yes
3756fi
3757
3758
3759# Check whether --with-imagemagick was given.
3760if test "${with_imagemagick+set}" = set; then :
3761 withval=$with_imagemagick;
3762else
3763 with_imagemagick=yes
3764fi
3765
3766
3767
3768# Check whether --with-xft was given.
3769if test "${with_xft+set}" = set; then :
3770 withval=$with_xft;
3771else
3772 with_xft=yes
3773fi
3774
3775
3776# Check whether --with-libotf was given.
3777if test "${with_libotf+set}" = set; then :
3778 withval=$with_libotf;
3779else
3780 with_libotf=yes
3781fi
3782
3783
3784# Check whether --with-m17n-flt was given.
3785if test "${with_m17n_flt+set}" = set; then :
3786 withval=$with_m17n_flt;
3787else
3788 with_m17n_flt=yes
3789fi
3790
3791
3792
3793# Check whether --with-toolkit-scroll-bars was given.
3794if test "${with_toolkit_scroll_bars+set}" = set; then :
3795 withval=$with_toolkit_scroll_bars;
3796else
3797 with_toolkit_scroll_bars=yes
3798fi
3799
3800
3801# Check whether --with-xaw3d was given.
3802if test "${with_xaw3d+set}" = set; then :
3803 withval=$with_xaw3d;
3804else
3805 with_xaw3d=yes
3806fi
3807
3808
3809# Check whether --with-xim was given.
3810if test "${with_xim+set}" = set; then :
3811 withval=$with_xim;
3812else
3813 with_xim=yes
3814fi
3815
3816
3817# Check whether --with-ns was given.
3818if test "${with_ns+set}" = set; then :
3819 withval=$with_ns;
3820else
3821 with_ns=no
3822fi
3823
3824
3825
3826# Check whether --with-gpm was given.
3827if test "${with_gpm+set}" = set; then :
3828 withval=$with_gpm;
3829else
3830 with_gpm=yes
3831fi
3832
3833
3834# Check whether --with-dbus was given.
3835if test "${with_dbus+set}" = set; then :
3836 withval=$with_dbus;
3837else
3838 with_dbus=yes
3839fi
3840
3841
3842# Check whether --with-gconf was given.
3843if test "${with_gconf+set}" = set; then :
3844 withval=$with_gconf;
3845else
3846 with_gconf=yes
3847fi
3848
3849
3850# Check whether --with-selinux was given.
3851if test "${with_selinux+set}" = set; then :
3852 withval=$with_selinux;
3853else
3854 with_selinux=yes
3855fi
3856
3857
3858# Check whether --with-gnutls was given.
3859if test "${with_gnutls+set}" = set; then :
3860 withval=$with_gnutls;
3861else
3862 with_gnutls=yes
3863fi
3864
3865
3866## For the times when you want to build Emacs but don't have
3867## a suitable makeinfo, and can live without the manuals.
3868
3869# Check whether --with-makeinfo was given.
3870if test "${with_makeinfo+set}" = set; then :
3871 withval=$with_makeinfo;
3872else
3873 with_makeinfo=yes
3874fi
3875
3876
3877## This is an option because I do not know if all info/man support
3878## compressed files, nor how to test if they do so.
3879
3880# Check whether --with-compress-info was given.
3881if test "${with_compress_info+set}" = set; then :
3882 withval=$with_compress_info;
3883else
3884 with_compress_info=yes
3885fi
3886
3887if test $with_compress_info = yes; then
3888 GZIP_INFO=yes
3889else
3890 GZIP_INFO=
3891fi
3892
3893
3894
3895# Check whether --with-pkg-config-prog was given.
3896if test "${with_pkg_config_prog+set}" = set; then :
3897 withval=$with_pkg_config_prog;
3898fi
3899
3900if test "X${with_pkg_config_prog}" != X; then
3901 if test "${with_pkg_config_prog}" != yes; then
3902 PKG_CONFIG="${with_pkg_config_prog}"
3903 fi
3904fi
3905
3906CRT_DIR=
3907
3908# Check whether --with-crt-dir was given.
3909if test "${with_crt_dir+set}" = set; then :
3910 withval=$with_crt_dir;
3911fi
3912
3913CRT_DIR="${with_crt_dir}"
3914
3915
4fc5868a
UM
3916# Check whether --with-gameuser was given.
3917if test "${with_gameuser+set}" = set; then :
3918 withval=$with_gameuser;
3919fi
3920
3921test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
3922 && gameuser="${with_gameuser}"
3923test "X$gameuser" = X && gameuser=games
3924
3925
067d23c9
KY
3926# Check whether --with-gnustep-conf was given.
3927if test "${with_gnustep_conf+set}" = set; then :
3928 withval=$with_gnustep_conf;
3929fi
3930
3931test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
3932 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
3933test "X$GNUSTEP_CONFIG_FILE" = "X" && \
3934 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
3935
3936# Check whether --enable-ns-self-contained was given.
3937if test "${enable_ns_self_contained+set}" = set; then :
3938 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
3939else
3940 EN_NS_SELF_CONTAINED=yes
3941fi
3942
3943
3944# Check whether --enable-asserts was given.
3945if test "${enable_asserts+set}" = set; then :
3946 enableval=$enable_asserts; USE_XASSERTS=$enableval
3947else
3948 USE_XASSERTS=no
3949fi
3950
3951
3952# Check whether --enable-maintainer-mode was given.
3953if test "${enable_maintainer_mode+set}" = set; then :
3954 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
3955else
3956 USE_MAINTAINER_MODE=no
3957fi
3958
3959if test $USE_MAINTAINER_MODE = yes; then
3960 MAINT=
3961else
3962 MAINT=#
3963fi
3964
3965
3966# Check whether --enable-locallisppath was given.
3967if test "${enable_locallisppath+set}" = set; then :
3968 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
3969 locallisppath=
3970elif test "${enableval}" != "yes"; then
3971 locallisppath=${enableval}
3972fi
3973fi
3974
3975
3976# Check whether --enable-checking was given.
3977if test "${enable_checking+set}" = set; then :
3978 enableval=$enable_checking; ac_checking_flags="${enableval}"
3979fi
3980
3981IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
3982for check in $ac_checking_flags
3983do
3984 case $check in
3985 # these set all the flags to specific states
3986 yes) ac_enable_checking=1 ;;
3987 no) ac_enable_checking= ;
3988 ac_gc_check_stringbytes= ;
3989 ac_gc_check_string_overrun= ;
3990 ac_gc_check_string_free_list= ;
3991 ac_xmalloc_overrun= ;
3992 ac_gc_check_cons_list= ;;
3993 all) ac_enable_checking=1 ;
3994 ac_gc_check_stringbytes=1 ;
3995 ac_gc_check_string_overrun=1 ;
3996 ac_gc_check_string_free_list=1 ;
3997 ac_xmalloc_overrun=1 ;
3998 ac_gc_check_cons_list=1 ;;
3999 # these enable particular checks
4000 stringbytes) ac_gc_check_stringbytes=1 ;;
4001 stringoverrun) ac_gc_check_string_overrun=1 ;;
4002 stringfreelist) ac_gc_check_string_free_list=1 ;;
4003 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4004 conslist) ac_gc_check_cons_list=1 ;;
d6974efa 4005 *) as_fn_error $? "unknown check category $check" "$LINENO" 5 ;;
067d23c9
KY
4006 esac
4007done
4008IFS="$ac_save_IFS"
4009
4010if test x$ac_enable_checking != x ; then
4011
4012$as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4013
4014fi
4015if test x$ac_gc_check_stringbytes != x ; then
4016
4017$as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4018
4019fi
4020if test x$ac_gc_check_stringoverrun != x ; then
4021
4022$as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4023
4024fi
4025if test x$ac_gc_check_string_free_list != x ; then
4026
4027$as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4028
4029fi
4030if test x$ac_xmalloc_overrun != x ; then
4031
4032$as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4033
4034fi
4035if test x$ac_gc_check_cons_list != x ; then
4036
4037$as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4038
4039fi
4040
4041# Check whether --enable-use-lisp-union-type was given.
4042if test "${enable_use_lisp_union_type+set}" = set; then :
4043 enableval=$enable_use_lisp_union_type; if test "${enableval}" != "no"; then
4044
4045$as_echo "#define USE_LISP_UNION_TYPE 1" >>confdefs.h
4046
4047fi
4048fi
4049
4050
4051
4052# Check whether --enable-profiling was given.
4053if test "${enable_profiling+set}" = set; then :
4054 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4055fi
4056
4057if test x$ac_enable_profiling != x ; then
4058 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4059else
4060 PROFILING_CFLAGS=
4061fi
4062
4063
4064# Check whether --enable-autodepend was given.
4065if test "${enable_autodepend+set}" = set; then :
4066 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4067else
4068 ac_enable_autodepend=yes
4069fi
4070
4071
4072#### Make srcdir absolute, if it isn't already. It's important to
4073#### avoid running the path through pwd unnecessarily, since pwd can
4074#### give you automounter prefixes, which can go away. We do all this
4075#### so Emacs can find its files when run uninstalled.
4076## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4077unset CDPATH
4078case "${srcdir}" in
4079 /* ) ;;
4080 . )
4081 ## We may be able to use the $PWD environment variable to make this
4082 ## absolute. But sometimes PWD is inaccurate.
4083 ## Note: we used to use ${PWD} at the end instead of `pwd`,
4084 ## but that tested only for a well-formed and valid PWD,
4085 ## it did not object when PWD was well-formed and valid but just wrong.
4086 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
4087 then
4088 srcdir="$PWD"
4089 else
4090 srcdir="`(cd ${srcdir}; pwd)`"
4091 fi
4092 ;;
4093 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
4094esac
4095
4096#### Check if the source directory already has a configured system in it.
4097if test `pwd` != `(cd ${srcdir} && pwd)` \
4098 && test -f "${srcdir}/src/config.h" ; then
4099 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The directory tree \`${srcdir}' is being used
4100 as a build directory right now; it has been configured in its own
4101 right. To configure in another directory as well, you MUST
4102 use GNU make. If you do not have GNU make, then you must
4103 now do \`make distclean' in ${srcdir},
4104 and then run $0 again." >&5
4105$as_echo "$as_me: WARNING: The directory tree \`${srcdir}' is being used
4106 as a build directory right now; it has been configured in its own
4107 right. To configure in another directory as well, you MUST
4108 use GNU make. If you do not have GNU make, then you must
4109 now do \`make distclean' in ${srcdir},
4110 and then run $0 again." >&2;}
4111fi
4112
4113#### Given the configuration name, set machfile and opsysfile to the
4114#### names of the m/*.h and s/*.h files we should use.
4115
4116### Canonicalize the configuration name.
4117
067d23c9
KY
4118# Make sure we can run config.sub.
4119$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2018939f 4120 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
067d23c9
KY
4121
4122{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4123$as_echo_n "checking build system type... " >&6; }
d6974efa 4124if ${ac_cv_build+:} false; then :
067d23c9
KY
4125 $as_echo_n "(cached) " >&6
4126else
4127 ac_build_alias=$build_alias
4128test "x$ac_build_alias" = x &&
4129 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4130test "x$ac_build_alias" = x &&
2018939f 4131 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
067d23c9 4132ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2018939f 4133 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
067d23c9
KY
4134
4135fi
4136{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4137$as_echo "$ac_cv_build" >&6; }
4138case $ac_cv_build in
4139*-*-*) ;;
d6974efa 4140*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
067d23c9
KY
4141esac
4142build=$ac_cv_build
4143ac_save_IFS=$IFS; IFS='-'
4144set x $ac_cv_build
4145shift
4146build_cpu=$1
4147build_vendor=$2
4148shift; shift
4149# Remember, the first character of IFS is used to create $*,
4150# except with old shells:
4151build_os=$*
4152IFS=$ac_save_IFS
4153case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4154
4155
4156{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4157$as_echo_n "checking host system type... " >&6; }
d6974efa 4158if ${ac_cv_host+:} false; then :
067d23c9
KY
4159 $as_echo_n "(cached) " >&6
4160else
4161 if test "x$host_alias" = x; then
4162 ac_cv_host=$ac_cv_build
4163else
4164 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2018939f 4165 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
067d23c9
KY
4166fi
4167
4168fi
4169{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4170$as_echo "$ac_cv_host" >&6; }
4171case $ac_cv_host in
4172*-*-*) ;;
d6974efa 4173*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
067d23c9
KY
4174esac
4175host=$ac_cv_host
4176ac_save_IFS=$IFS; IFS='-'
4177set x $ac_cv_host
4178shift
4179host_cpu=$1
4180host_vendor=$2
4181shift; shift
4182# Remember, the first character of IFS is used to create $*,
4183# except with old shells:
4184host_os=$*
4185IFS=$ac_save_IFS
4186case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4187
4188
4189canonical=$host
4190configuration=${host_alias-${build_alias-$host}}
4191
4192
4193
4194### If you add support for a new configuration, add code to this
4195### switch statement to recognize your configuration name and select
4196### the appropriate operating system and machine description files.
4197
4198### You would hope that you could choose an m/*.h file pretty much
4199### based on the machine portion of the configuration name, and an s/*.h
4200### file based on the operating system portion. However, it turns out
4201### that each m/*.h file is pretty manufacturer-specific - for
4202### example mips.h is MIPS
4203### So we basically have to have a special case for each
4204### configuration name.
4205###
4206### As far as handling version numbers on operating systems is
4207### concerned, make sure things will fail in a fixable way. If
4208### /etc/MACHINES doesn't say anything about version numbers, be
4209### prepared to handle anything reasonably. If version numbers
4210### matter, be sure /etc/MACHINES says something about it.
4211
4212machine='' opsys='' unported=no
4213case "${canonical}" in
4214
d6a003a8
AS
4215 ## GNU/Linux ports
4216 *-*-linux-gnu*)
4217 opsys=gnu-linux
4218 case ${canonical} in
4219 alpha*) machine=alpha ;;
4220 s390-*) machine=ibms390 ;;
4221 s390x-*) machine=ibms390x ;;
4222 powerpc*) machine=macppc ;;
4223 sparc*) machine=sparc ;;
4224 ia64*) machine=ia64 ;;
4225 m68k*) machine=m68k ;;
4226 x86_64*) machine=amdx86-64 ;;
4227 esac
4228 ;;
4229
067d23c9
KY
4230 ## FreeBSD ports
4231 *-*-freebsd* )
4232 opsys=freebsd
4233 case "${canonical}" in
4234 alpha*) machine=alpha ;;
4235 amd64-*|x86_64-*) machine=amdx86-64 ;;
067d23c9
KY
4236 ia64-*) machine=ia64 ;;
4237 i[3456]86-*) machine=intel386 ;;
4238 powerpc-*) machine=macppc ;;
4239 sparc-*) machine=sparc ;;
4240 sparc64-*) machine=sparc ;;
4241 esac
4242 ;;
4243
4244 ## FreeBSD kernel + glibc based userland
4245 *-*-kfreebsd*gnu* )
4246 opsys=gnu-kfreebsd
4247 case "${canonical}" in
4248 alpha*) machine=alpha ;;
4249 amd64-*|x86_64-*) machine=amdx86-64 ;;
4250 ia64-*) machine=ia64 ;;
4251 i[3456]86-*) machine=intel386 ;;
4252 powerpc-*) machine=macppc ;;
4253 sparc-*) machine=sparc ;;
4254 sparc64-*) machine=sparc ;;
4255 esac
4256 ;;
4257
4258 ## NetBSD ports
4259 *-*-netbsd* )
4260 opsys=netbsd
4261 case "${canonical}" in
4262 alpha*) machine=alpha ;;
4263 x86_64-*) machine=amdx86-64 ;;
067d23c9
KY
4264 i[3456]86-*) machine=intel386 ;;
4265 m68k-*) machine=m68k ;;
4266 powerpc-*) machine=macppc ;;
067d23c9
KY
4267 sparc*-) machine=sparc ;;
4268 vax-*) machine=vax ;;
4269 esac
4270 ;;
4271
4272 ## OpenBSD ports
4273 *-*-openbsd* )
4274 opsys=openbsd
4275 case "${canonical}" in
4276 alpha*) machine=alpha ;;
4277 x86_64-*) machine=amdx86-64 ;;
067d23c9
KY
4278 i386-*) machine=intel386 ;;
4279 powerpc-*) machine=macppc ;;
4280 sparc*) machine=sparc ;;
4281 vax-*) machine=vax ;;
4282 esac
4283 ;;
4284
067d23c9
KY
4285 ## Apple Darwin / Mac OS X
4286 *-apple-darwin* )
4287 case "${canonical}" in
4288 i[3456]86-* ) machine=intel386 ;;
4289 powerpc-* ) machine=macppc ;;
4290 x86_64-* ) machine=amdx86-64 ;;
4291 * ) unported=yes ;;
4292 esac
4293 opsys=darwin
4294 # Define CPP as follows to make autoconf work correctly.
4295 CPP="${CC-cc} -E -no-cpp-precomp"
4296 # Use fink packages if available.
4297 if test -d /sw/include && test -d /sw/lib; then
4298 GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4299 CPP="${CPP} ${GCC_TEST_OPTIONS}"
4300 NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4301 fi
4302 ;;
4303
4304 ## HP 9000 series 700 and 800, running HP/UX
4305 hppa*-hp-hpux10.2* )
d6a003a8 4306 opsys=hpux10-20
067d23c9
KY
4307 ;;
4308 hppa*-hp-hpux1[1-9]* )
d6a003a8 4309 opsys=hpux11
067d23c9
KY
4310 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4311 ;;
4312
125c3718
PE
4313 ia64*-hp-hpux1[1-9]* )
4314 machine=hp800 opsys=hpux11
4315 ## FIXME. Peter O'Gorman reports that dumping using unexelf.o doesn't
4316 ## work either: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=6811
4317 CANNOT_DUMP=yes
4318 ;;
4319
4320 hppa*-*-linux-gnu* )
4321 machine=hp800 opsys=gnu-linux
4322 ;;
4323
067d23c9 4324 ## IBM machines
067d23c9
KY
4325 rs6000-ibm-aix4.[23]* )
4326 machine=ibmrs6000 opsys=aix4-2
4327 ;;
4328 powerpc-ibm-aix4.[23]* )
4329 machine=ibmrs6000 opsys=aix4-2
4330 ;;
4331 rs6000-ibm-aix[56]* )
4332 machine=ibmrs6000 opsys=aix4-2
4333 ;;
4334 powerpc-ibm-aix[56]* )
4335 machine=ibmrs6000 opsys=aix4-2
4336 ;;
4337
067d23c9
KY
4338 ## Silicon Graphics machines
4339 ## Iris 4D
4340 mips-sgi-irix6.5 )
4341 machine=iris4d opsys=irix6-5
4342 # Without defining _LANGUAGE_C, things get masked out in the headers
4343 # so that, for instance, grepping for `free' in stdlib.h fails and
4344 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4345 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
4346 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4347 ;;
4348
4349 ## Suns
067d23c9
KY
4350 *-sun-solaris* \
4351 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4352 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4353 case "${canonical}" in
4354 i[3456]86-*-* ) machine=intel386 ;;
4355 amd64-*-*|x86_64-*-*) machine=amdx86-64 ;;
4356 sparc* ) machine=sparc ;;
4357 * ) unported=yes ;;
4358 esac
4359 case "${canonical}" in
4360 *-sunos5.6* | *-solaris2.6* )
4361 opsys=sol2-6
4362 NON_GNU_CPP=/usr/ccs/lib/cpp
4363 RANLIB="ar -ts"
4364 ;;
4365 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4366 opsys=sol2-6
4367 emacs_check_sunpro_c=yes
4368 NON_GNU_CPP=/usr/ccs/lib/cpp
4369 ;;
4370 *-sunos5* | *-solaris* )
4371 opsys=sol2-10
4372 emacs_check_sunpro_c=yes
4373 NON_GNU_CPP=/usr/ccs/lib/cpp
4374 ;;
4375 esac
4376 ## Watch out for a compiler that we know will not work.
4377 case "${canonical}" in
4378 *-solaris* | *-sunos5* )
4379 if [ "x$CC" = x/usr/ucb/cc ]; then
4380 ## /usr/ucb/cc doesn't work;
4381 ## we should find some other compiler that does work.
4382 unset CC
4383 fi
4384 ;;
4385 *) ;;
4386 esac
4387 ;;
4388
067d23c9
KY
4389 ## Intel 386 machines where we don't care about the manufacturer.
4390 i[3456]86-*-* )
4391 machine=intel386
4392 case "${canonical}" in
4393 *-cygwin ) opsys=cygwin ;;
4394 *-darwin* ) opsys=darwin
4395 CPP="${CC-cc} -E -no-cpp-precomp"
4396 ;;
067d23c9
KY
4397 *-sysv4.2uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
4398 *-sysv5uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
4399 *-sysv5OpenUNIX* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
4400 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4401 esac
4402 ;;
4403
067d23c9
KY
4404 * )
4405 unported=yes
4406 ;;
4407esac
4408
4409### If the code above didn't choose an operating system, just choose
4410### an operating system based on the configuration name. You really
4411### only want to use this when you have no idea what the right
4412### operating system is; if you know what operating systems a machine
4413### runs, it's cleaner to make it explicit in the case statement
4414### above.
4415if test x"${opsys}" = x; then
4416 case "${canonical}" in
4417 *-gnu* ) opsys=gnu ;;
4418 * )
4419 unported=yes
4420 ;;
4421 esac
4422fi
4423
4424
4425
4426if test $unported = yes; then
2018939f 4427 as_fn_error $? "Emacs hasn't been ported to \`${canonical}' systems.
067d23c9
KY
4428Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4429fi
4430
d6a003a8
AS
4431if test -n "$machine"; then
4432 machfile="m/${machine}.h"
4433else
4434 machfile=
4435fi
067d23c9
KY
4436opsysfile="s/${opsys}.h"
4437
4438
4439#### Choose a compiler.
4440test -n "$CC" && cc_specified=yes
4441
4442# Save the value of CFLAGS that the user specified.
4443SPECIFIED_CFLAGS="$CFLAGS"
4444
4445ac_ext=c
4446ac_cpp='$CPP $CPPFLAGS'
4447ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4448ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4449ac_compiler_gnu=$ac_cv_c_compiler_gnu
4450if test -n "$ac_tool_prefix"; then
4451 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4452set dummy ${ac_tool_prefix}gcc; ac_word=$2
4453{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4454$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 4455if ${ac_cv_prog_CC+:} false; then :
067d23c9
KY
4456 $as_echo_n "(cached) " >&6
4457else
4458 if test -n "$CC"; then
4459 ac_cv_prog_CC="$CC" # Let the user override the test.
4460else
4461as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4462for as_dir in $PATH
4463do
4464 IFS=$as_save_IFS
4465 test -z "$as_dir" && as_dir=.
4466 for ac_exec_ext in '' $ac_executable_extensions; do
4467 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4468 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4469 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4470 break 2
4471 fi
4472done
4473 done
4474IFS=$as_save_IFS
4475
4476fi
4477fi
4478CC=$ac_cv_prog_CC
4479if test -n "$CC"; then
4480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4481$as_echo "$CC" >&6; }
4482else
4483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4484$as_echo "no" >&6; }
4485fi
4486
4487
4488fi
4489if test -z "$ac_cv_prog_CC"; then
4490 ac_ct_CC=$CC
4491 # Extract the first word of "gcc", so it can be a program name with args.
4492set dummy gcc; ac_word=$2
4493{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4494$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 4495if ${ac_cv_prog_ac_ct_CC+:} false; then :
067d23c9
KY
4496 $as_echo_n "(cached) " >&6
4497else
4498 if test -n "$ac_ct_CC"; then
4499 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4500else
4501as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4502for as_dir in $PATH
4503do
4504 IFS=$as_save_IFS
4505 test -z "$as_dir" && as_dir=.
4506 for ac_exec_ext in '' $ac_executable_extensions; do
4507 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4508 ac_cv_prog_ac_ct_CC="gcc"
4509 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4510 break 2
4511 fi
4512done
4513 done
4514IFS=$as_save_IFS
4515
4516fi
4517fi
4518ac_ct_CC=$ac_cv_prog_ac_ct_CC
4519if test -n "$ac_ct_CC"; then
4520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4521$as_echo "$ac_ct_CC" >&6; }
4522else
4523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4524$as_echo "no" >&6; }
4525fi
4526
4527 if test "x$ac_ct_CC" = x; then
4528 CC=""
4529 else
4530 case $cross_compiling:$ac_tool_warned in
4531yes:)
4532{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4533$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4534ac_tool_warned=yes ;;
4535esac
4536 CC=$ac_ct_CC
4537 fi
4538else
4539 CC="$ac_cv_prog_CC"
4540fi
4541
4542if test -z "$CC"; then
4543 if test -n "$ac_tool_prefix"; then
4544 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4545set dummy ${ac_tool_prefix}cc; ac_word=$2
4546{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4547$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 4548if ${ac_cv_prog_CC+:} false; then :
067d23c9
KY
4549 $as_echo_n "(cached) " >&6
4550else
4551 if test -n "$CC"; then
4552 ac_cv_prog_CC="$CC" # Let the user override the test.
4553else
4554as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4555for as_dir in $PATH
4556do
4557 IFS=$as_save_IFS
4558 test -z "$as_dir" && as_dir=.
4559 for ac_exec_ext in '' $ac_executable_extensions; do
4560 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4561 ac_cv_prog_CC="${ac_tool_prefix}cc"
4562 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4563 break 2
4564 fi
4565done
4566 done
4567IFS=$as_save_IFS
4568
4569fi
4570fi
4571CC=$ac_cv_prog_CC
4572if test -n "$CC"; then
4573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4574$as_echo "$CC" >&6; }
4575else
4576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4577$as_echo "no" >&6; }
4578fi
4579
4580
4581 fi
4582fi
4583if test -z "$CC"; then
4584 # Extract the first word of "cc", so it can be a program name with args.
4585set dummy cc; ac_word=$2
4586{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4587$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 4588if ${ac_cv_prog_CC+:} false; then :
067d23c9
KY
4589 $as_echo_n "(cached) " >&6
4590else
4591 if test -n "$CC"; then
4592 ac_cv_prog_CC="$CC" # Let the user override the test.
4593else
4594 ac_prog_rejected=no
4595as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4596for as_dir in $PATH
4597do
4598 IFS=$as_save_IFS
4599 test -z "$as_dir" && as_dir=.
4600 for ac_exec_ext in '' $ac_executable_extensions; do
4601 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4602 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4603 ac_prog_rejected=yes
4604 continue
4605 fi
4606 ac_cv_prog_CC="cc"
4607 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4608 break 2
4609 fi
4610done
4611 done
4612IFS=$as_save_IFS
4613
4614if test $ac_prog_rejected = yes; then
4615 # We found a bogon in the path, so make sure we never use it.
4616 set dummy $ac_cv_prog_CC
4617 shift
4618 if test $# != 0; then
4619 # We chose a different compiler from the bogus one.
4620 # However, it has the same basename, so the bogon will be chosen
4621 # first if we set CC to just the basename; use the full file name.
4622 shift
4623 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4624 fi
4625fi
4626fi
4627fi
4628CC=$ac_cv_prog_CC
4629if test -n "$CC"; then
4630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4631$as_echo "$CC" >&6; }
4632else
4633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4634$as_echo "no" >&6; }
4635fi
4636
4637
4638fi
4639if test -z "$CC"; then
4640 if test -n "$ac_tool_prefix"; then
4641 for ac_prog in cl.exe
4642 do
4643 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4644set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4645{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4646$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 4647if ${ac_cv_prog_CC+:} false; then :
067d23c9
KY
4648 $as_echo_n "(cached) " >&6
4649else
4650 if test -n "$CC"; then
4651 ac_cv_prog_CC="$CC" # Let the user override the test.
4652else
4653as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4654for as_dir in $PATH
4655do
4656 IFS=$as_save_IFS
4657 test -z "$as_dir" && as_dir=.
4658 for ac_exec_ext in '' $ac_executable_extensions; do
4659 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4660 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4661 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4662 break 2
4663 fi
4664done
4665 done
4666IFS=$as_save_IFS
4667
4668fi
4669fi
4670CC=$ac_cv_prog_CC
4671if test -n "$CC"; then
4672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4673$as_echo "$CC" >&6; }
4674else
4675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4676$as_echo "no" >&6; }
4677fi
4678
4679
4680 test -n "$CC" && break
4681 done
4682fi
4683if test -z "$CC"; then
4684 ac_ct_CC=$CC
4685 for ac_prog in cl.exe
4686do
4687 # Extract the first word of "$ac_prog", so it can be a program name with args.
4688set dummy $ac_prog; ac_word=$2
4689{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4690$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 4691if ${ac_cv_prog_ac_ct_CC+:} false; then :
067d23c9
KY
4692 $as_echo_n "(cached) " >&6
4693else
4694 if test -n "$ac_ct_CC"; then
4695 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4696else
4697as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4698for as_dir in $PATH
4699do
4700 IFS=$as_save_IFS
4701 test -z "$as_dir" && as_dir=.
4702 for ac_exec_ext in '' $ac_executable_extensions; do
4703 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4704 ac_cv_prog_ac_ct_CC="$ac_prog"
4705 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4706 break 2
4707 fi
4708done
4709 done
4710IFS=$as_save_IFS
4711
4712fi
4713fi
4714ac_ct_CC=$ac_cv_prog_ac_ct_CC
4715if test -n "$ac_ct_CC"; then
4716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4717$as_echo "$ac_ct_CC" >&6; }
4718else
4719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4720$as_echo "no" >&6; }
4721fi
4722
4723
4724 test -n "$ac_ct_CC" && break
4725done
4726
4727 if test "x$ac_ct_CC" = x; then
4728 CC=""
4729 else
4730 case $cross_compiling:$ac_tool_warned in
4731yes:)
4732{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4733$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4734ac_tool_warned=yes ;;
4735esac
4736 CC=$ac_ct_CC
4737 fi
4738fi
4739
4740fi
4741
4742
4743test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4744$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2018939f 4745as_fn_error $? "no acceptable C compiler found in \$PATH
d6974efa 4746See \`config.log' for more details" "$LINENO" 5; }
067d23c9
KY
4747
4748# Provide some information about the compiler.
4749$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4750set X $ac_compile
4751ac_compiler=$2
4752for ac_option in --version -v -V -qversion; do
4753 { { ac_try="$ac_compiler $ac_option >&5"
4754case "(($ac_try" in
4755 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4756 *) ac_try_echo=$ac_try;;
4757esac
4758eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4759$as_echo "$ac_try_echo"; } >&5
4760 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4761 ac_status=$?
4762 if test -s conftest.err; then
4763 sed '10a\
4764... rest of stderr output deleted ...
4765 10q' conftest.err >conftest.er1
4766 cat conftest.er1 >&5
4767 fi
4768 rm -f conftest.er1 conftest.err
4769 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4770 test $ac_status = 0; }
4771done
4772
4773cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4774/* end confdefs.h. */
4775
4776int
4777main ()
4778{
4779
4780 ;
4781 return 0;
4782}
4783_ACEOF
4784ac_clean_files_save=$ac_clean_files
4785ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4786# Try to create an executable without -o first, disregard a.out.
4787# It will help us diagnose broken compilers, and finding out an intuition
4788# of exeext.
4789{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4790$as_echo_n "checking whether the C compiler works... " >&6; }
4791ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4792
4793# The possible output files:
4794ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4795
4796ac_rmfiles=
4797for ac_file in $ac_files
4798do
4799 case $ac_file in
4800 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4801 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4802 esac
4803done
4804rm -f $ac_rmfiles
4805
4806if { { ac_try="$ac_link_default"
4807case "(($ac_try" in
4808 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4809 *) ac_try_echo=$ac_try;;
4810esac
4811eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4812$as_echo "$ac_try_echo"; } >&5
4813 (eval "$ac_link_default") 2>&5
4814 ac_status=$?
4815 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4816 test $ac_status = 0; }; then :
4817 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4818# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4819# in a Makefile. We should not override ac_cv_exeext if it was cached,
4820# so that the user can short-circuit this test for compilers unknown to
4821# Autoconf.
4822for ac_file in $ac_files ''
4823do
4824 test -f "$ac_file" || continue
4825 case $ac_file in
4826 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4827 ;;
4828 [ab].out )
4829 # We found the default executable, but exeext='' is most
4830 # certainly right.
4831 break;;
4832 *.* )
4833 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4834 then :; else
4835 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4836 fi
4837 # We set ac_cv_exeext here because the later test for it is not
4838 # safe: cross compilers may not add the suffix if given an `-o'
4839 # argument, so we may need to know it at that point already.
4840 # Even if this section looks crufty: it has the advantage of
4841 # actually working.
4842 break;;
4843 * )
4844 break;;
4845 esac
4846done
4847test "$ac_cv_exeext" = no && ac_cv_exeext=
4848
4849else
4850 ac_file=''
4851fi
4852if test -z "$ac_file"; then :
4853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4854$as_echo "no" >&6; }
4855$as_echo "$as_me: failed program was:" >&5
4856sed 's/^/| /' conftest.$ac_ext >&5
4857
4858{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4859$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2018939f 4860as_fn_error 77 "C compiler cannot create executables
d6974efa 4861See \`config.log' for more details" "$LINENO" 5; }
067d23c9
KY
4862else
4863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4864$as_echo "yes" >&6; }
4865fi
4866{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4867$as_echo_n "checking for C compiler default output file name... " >&6; }
4868{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4869$as_echo "$ac_file" >&6; }
4870ac_exeext=$ac_cv_exeext
4871
4872rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
4873ac_clean_files=$ac_clean_files_save
4874{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4875$as_echo_n "checking for suffix of executables... " >&6; }
4876if { { ac_try="$ac_link"
4877case "(($ac_try" in
4878 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4879 *) ac_try_echo=$ac_try;;
4880esac
4881eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4882$as_echo "$ac_try_echo"; } >&5
4883 (eval "$ac_link") 2>&5
4884 ac_status=$?
4885 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4886 test $ac_status = 0; }; then :
4887 # If both `conftest.exe' and `conftest' are `present' (well, observable)
4888# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
4889# work properly (i.e., refer to `conftest.exe'), while it won't with
4890# `rm'.
4891for ac_file in conftest.exe conftest conftest.*; do
4892 test -f "$ac_file" || continue
4893 case $ac_file in
4894 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4895 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4896 break;;
4897 * ) break;;
4898 esac
4899done
4900else
4901 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4902$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2018939f 4903as_fn_error $? "cannot compute suffix of executables: cannot compile and link
d6974efa 4904See \`config.log' for more details" "$LINENO" 5; }
067d23c9
KY
4905fi
4906rm -f conftest conftest$ac_cv_exeext
4907{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4908$as_echo "$ac_cv_exeext" >&6; }
4909
4910rm -f conftest.$ac_ext
4911EXEEXT=$ac_cv_exeext
4912ac_exeext=$EXEEXT
4913cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4914/* end confdefs.h. */
4915#include <stdio.h>
4916int
4917main ()
4918{
4919FILE *f = fopen ("conftest.out", "w");
4920 return ferror (f) || fclose (f) != 0;
4921
4922 ;
4923 return 0;
4924}
4925_ACEOF
4926ac_clean_files="$ac_clean_files conftest.out"
4927# Check that the compiler produces executables we can run. If not, either
4928# the compiler is broken, or we cross compile.
4929{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4930$as_echo_n "checking whether we are cross compiling... " >&6; }
4931if test "$cross_compiling" != yes; then
4932 { { ac_try="$ac_link"
4933case "(($ac_try" in
4934 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4935 *) ac_try_echo=$ac_try;;
4936esac
4937eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4938$as_echo "$ac_try_echo"; } >&5
4939 (eval "$ac_link") 2>&5
4940 ac_status=$?
4941 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4942 test $ac_status = 0; }
4943 if { ac_try='./conftest$ac_cv_exeext'
4944 { { case "(($ac_try" in
4945 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4946 *) ac_try_echo=$ac_try;;
4947esac
4948eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4949$as_echo "$ac_try_echo"; } >&5
4950 (eval "$ac_try") 2>&5
4951 ac_status=$?
4952 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4953 test $ac_status = 0; }; }; then
4954 cross_compiling=no
4955 else
4956 if test "$cross_compiling" = maybe; then
4957 cross_compiling=yes
4958 else
4959 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4960$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2018939f 4961as_fn_error $? "cannot run C compiled programs.
067d23c9 4962If you meant to cross compile, use \`--host'.
d6974efa 4963See \`config.log' for more details" "$LINENO" 5; }
067d23c9
KY
4964 fi
4965 fi
4966fi
4967{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4968$as_echo "$cross_compiling" >&6; }
4969
4970rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4971ac_clean_files=$ac_clean_files_save
4972{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4973$as_echo_n "checking for suffix of object files... " >&6; }
d6974efa 4974if ${ac_cv_objext+:} false; then :
067d23c9
KY
4975 $as_echo_n "(cached) " >&6
4976else
4977 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4978/* end confdefs.h. */
4979
4980int
4981main ()
4982{
4983
4984 ;
4985 return 0;
4986}
4987_ACEOF
4988rm -f conftest.o conftest.obj
4989if { { ac_try="$ac_compile"
4990case "(($ac_try" in
4991 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4992 *) ac_try_echo=$ac_try;;
4993esac
4994eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4995$as_echo "$ac_try_echo"; } >&5
4996 (eval "$ac_compile") 2>&5
4997 ac_status=$?
4998 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4999 test $ac_status = 0; }; then :
5000 for ac_file in conftest.o conftest.obj conftest.*; do
5001 test -f "$ac_file" || continue;
5002 case $ac_file in
5003 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5004 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5005 break;;
5006 esac
5007done
5008else
5009 $as_echo "$as_me: failed program was:" >&5
5010sed 's/^/| /' conftest.$ac_ext >&5
5011
5012{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5013$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2018939f 5014as_fn_error $? "cannot compute suffix of object files: cannot compile
d6974efa 5015See \`config.log' for more details" "$LINENO" 5; }
067d23c9
KY
5016fi
5017rm -f conftest.$ac_cv_objext conftest.$ac_ext
5018fi
5019{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5020$as_echo "$ac_cv_objext" >&6; }
5021OBJEXT=$ac_cv_objext
5022ac_objext=$OBJEXT
5023{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5024$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
d6974efa 5025if ${ac_cv_c_compiler_gnu+:} false; then :
067d23c9
KY
5026 $as_echo_n "(cached) " >&6
5027else
5028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5029/* end confdefs.h. */
5030
5031int
5032main ()
5033{
5034#ifndef __GNUC__
5035 choke me
5036#endif
5037
5038 ;
5039 return 0;
5040}
5041_ACEOF
5042if ac_fn_c_try_compile "$LINENO"; then :
5043 ac_compiler_gnu=yes
5044else
5045 ac_compiler_gnu=no
5046fi
5047rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5048ac_cv_c_compiler_gnu=$ac_compiler_gnu
5049
5050fi
5051{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5052$as_echo "$ac_cv_c_compiler_gnu" >&6; }
5053if test $ac_compiler_gnu = yes; then
5054 GCC=yes
5055else
5056 GCC=
5057fi
5058ac_test_CFLAGS=${CFLAGS+set}
5059ac_save_CFLAGS=$CFLAGS
5060{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5061$as_echo_n "checking whether $CC accepts -g... " >&6; }
d6974efa 5062if ${ac_cv_prog_cc_g+:} false; then :
067d23c9
KY
5063 $as_echo_n "(cached) " >&6
5064else
5065 ac_save_c_werror_flag=$ac_c_werror_flag
5066 ac_c_werror_flag=yes
5067 ac_cv_prog_cc_g=no
5068 CFLAGS="-g"
5069 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5070/* end confdefs.h. */
5071
5072int
5073main ()
5074{
5075
5076 ;
5077 return 0;
5078}
5079_ACEOF
5080if ac_fn_c_try_compile "$LINENO"; then :
5081 ac_cv_prog_cc_g=yes
5082else
5083 CFLAGS=""
5084 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5085/* end confdefs.h. */
5086
5087int
5088main ()
5089{
5090
5091 ;
5092 return 0;
5093}
5094_ACEOF
5095if ac_fn_c_try_compile "$LINENO"; then :
5096
5097else
5098 ac_c_werror_flag=$ac_save_c_werror_flag
5099 CFLAGS="-g"
5100 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5101/* end confdefs.h. */
5102
5103int
5104main ()
5105{
5106
5107 ;
5108 return 0;
5109}
5110_ACEOF
5111if ac_fn_c_try_compile "$LINENO"; then :
5112 ac_cv_prog_cc_g=yes
5113fi
5114rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5115fi
5116rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5117fi
5118rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5119 ac_c_werror_flag=$ac_save_c_werror_flag
5120fi
5121{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5122$as_echo "$ac_cv_prog_cc_g" >&6; }
5123if test "$ac_test_CFLAGS" = set; then
5124 CFLAGS=$ac_save_CFLAGS
5125elif test $ac_cv_prog_cc_g = yes; then
5126 if test "$GCC" = yes; then
5127 CFLAGS="-g -O2"
5128 else
5129 CFLAGS="-g"
5130 fi
5131else
5132 if test "$GCC" = yes; then
5133 CFLAGS="-O2"
5134 else
5135 CFLAGS=
5136 fi
5137fi
5138{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5139$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
d6974efa 5140if ${ac_cv_prog_cc_c89+:} false; then :
067d23c9
KY
5141 $as_echo_n "(cached) " >&6
5142else
5143 ac_cv_prog_cc_c89=no
5144ac_save_CC=$CC
5145cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5146/* end confdefs.h. */
5147#include <stdarg.h>
5148#include <stdio.h>
5149#include <sys/types.h>
5150#include <sys/stat.h>
5151/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5152struct buf { int x; };
5153FILE * (*rcsopen) (struct buf *, struct stat *, int);
5154static char *e (p, i)
5155 char **p;
5156 int i;
5157{
5158 return p[i];
5159}
5160static char *f (char * (*g) (char **, int), char **p, ...)
5161{
5162 char *s;
5163 va_list v;
5164 va_start (v,p);
5165 s = g (p, va_arg (v,int));
5166 va_end (v);
5167 return s;
5168}
5169
5170/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5171 function prototypes and stuff, but not '\xHH' hex character constants.
5172 These don't provoke an error unfortunately, instead are silently treated
5173 as 'x'. The following induces an error, until -std is added to get
5174 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5175 array size at least. It's necessary to write '\x00'==0 to get something
5176 that's true only with -std. */
5177int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5178
5179/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5180 inside strings and character constants. */
5181#define FOO(x) 'x'
5182int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5183
5184int test (int i, double x);
5185struct s1 {int (*f) (int a);};
5186struct s2 {int (*f) (double a);};
5187int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5188int argc;
5189char **argv;
5190int
5191main ()
5192{
5193return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5194 ;
5195 return 0;
5196}
5197_ACEOF
5198for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5199 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5200do
5201 CC="$ac_save_CC $ac_arg"
5202 if ac_fn_c_try_compile "$LINENO"; then :
5203 ac_cv_prog_cc_c89=$ac_arg
5204fi
5205rm -f core conftest.err conftest.$ac_objext
5206 test "x$ac_cv_prog_cc_c89" != "xno" && break
5207done
743c80a7
PE
5208rm -f conftest.$ac_ext
5209CC=$ac_save_CC
5210
5211fi
5212# AC_CACHE_VAL
5213case "x$ac_cv_prog_cc_c89" in
5214 x)
5215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5216$as_echo "none needed" >&6; } ;;
5217 xno)
5218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5219$as_echo "unsupported" >&6; } ;;
5220 *)
5221 CC="$CC $ac_cv_prog_cc_c89"
5222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5223$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5224esac
5225if test "x$ac_cv_prog_cc_c89" != xno; then :
5226
5227fi
5228
5229ac_ext=c
5230ac_cpp='$CPP $CPPFLAGS'
5231ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5232ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5233ac_compiler_gnu=$ac_cv_c_compiler_gnu
5234DEPDIR="${am__leading_dot}deps"
5235
5236ac_config_commands="$ac_config_commands depfiles"
5237
5238
5239am_make=${MAKE-make}
5240cat > confinc << 'END'
5241am__doit:
5242 @echo this is the am__doit target
5243.PHONY: am__doit
5244END
5245# If we don't find an include directive, just comment out the code.
5246{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5247$as_echo_n "checking for style of include used by $am_make... " >&6; }
5248am__include="#"
5249am__quote=
5250_am_result=none
5251# First try GNU make style include.
5252echo "include confinc" > confmf
5253# Ignore all kinds of additional output from `make'.
5254case `$am_make -s -f confmf 2> /dev/null` in #(
5255*the\ am__doit\ target*)
5256 am__include=include
5257 am__quote=
5258 _am_result=GNU
5259 ;;
5260esac
5261# Now try BSD make style include.
5262if test "$am__include" = "#"; then
5263 echo '.include "confinc"' > confmf
5264 case `$am_make -s -f confmf 2> /dev/null` in #(
5265 *the\ am__doit\ target*)
5266 am__include=.include
5267 am__quote="\""
5268 _am_result=BSD
5269 ;;
5270 esac
5271fi
5272
5273
5274{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5275$as_echo "$_am_result" >&6; }
5276rm -f confinc confmf
5277
5278# Check whether --enable-dependency-tracking was given.
5279if test "${enable_dependency_tracking+set}" = set; then :
5280 enableval=$enable_dependency_tracking;
5281fi
5282
5283if test "x$enable_dependency_tracking" != xno; then
5284 am_depcomp="$ac_aux_dir/depcomp"
5285 AMDEPBACKSLASH='\'
5286fi
5287 if test "x$enable_dependency_tracking" != xno; then
5288 AMDEP_TRUE=
5289 AMDEP_FALSE='#'
5290else
5291 AMDEP_TRUE='#'
5292 AMDEP_FALSE=
5293fi
5294
5295
5296
5297depcc="$CC" am_compiler_list=
5298
5299{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5300$as_echo_n "checking dependency style of $depcc... " >&6; }
d6974efa 5301if ${am_cv_CC_dependencies_compiler_type+:} false; then :
743c80a7
PE
5302 $as_echo_n "(cached) " >&6
5303else
5304 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5305 # We make a subdir and do the tests there. Otherwise we can end up
5306 # making bogus files that we don't know about and never remove. For
5307 # instance it was reported that on HP-UX the gcc test will end up
5308 # making a dummy file named `D' -- because `-MD' means `put the output
5309 # in D'.
5310 mkdir conftest.dir
5311 # Copy depcomp to subdir because otherwise we won't find it if we're
5312 # using a relative directory.
5313 cp "$am_depcomp" conftest.dir
5314 cd conftest.dir
5315 # We will build objects and dependencies in a subdirectory because
5316 # it helps to detect inapplicable dependency modes. For instance
5317 # both Tru64's cc and ICC support -MD to output dependencies as a
5318 # side effect of compilation, but ICC will put the dependencies in
5319 # the current directory while Tru64 will put them in the object
5320 # directory.
5321 mkdir sub
5322
5323 am_cv_CC_dependencies_compiler_type=none
5324 if test "$am_compiler_list" = ""; then
5325 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5326 fi
5327 am__universal=false
5328 case " $depcc " in #(
5329 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5330 esac
5331
5332 for depmode in $am_compiler_list; do
5333 # Setup a source with many dependencies, because some compilers
5334 # like to wrap large dependency lists on column 80 (with \), and
5335 # we should not choose a depcomp mode which is confused by this.
5336 #
5337 # We need to recreate these files for each test, as the compiler may
5338 # overwrite some of them when testing with obscure command lines.
5339 # This happens at least with the AIX C compiler.
5340 : > sub/conftest.c
5341 for i in 1 2 3 4 5 6; do
5342 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5343 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5344 # Solaris 8's {/usr,}/bin/sh.
5345 touch sub/conftst$i.h
5346 done
5347 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5348
5349 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5350 # mode. It turns out that the SunPro C++ compiler does not properly
5351 # handle `-M -o', and we need to detect this. Also, some Intel
5352 # versions had trouble with output in subdirs
5353 am__obj=sub/conftest.${OBJEXT-o}
5354 am__minus_obj="-o $am__obj"
5355 case $depmode in
5356 gcc)
5357 # This depmode causes a compiler race in universal mode.
5358 test "$am__universal" = false || continue
5359 ;;
5360 nosideeffect)
5361 # after this tag, mechanisms are not by side-effect, so they'll
5362 # only be used when explicitly requested
5363 if test "x$enable_dependency_tracking" = xyes; then
5364 continue
5365 else
5366 break
5367 fi
5368 ;;
5369 msvisualcpp | msvcmsys)
5370 # This compiler won't grok `-c -o', but also, the minuso test has
5371 # not run yet. These depmodes are late enough in the game, and
5372 # so weak that their functioning should not be impacted.
5373 am__obj=conftest.${OBJEXT-o}
5374 am__minus_obj=
5375 ;;
5376 none) break ;;
5377 esac
5378 if depmode=$depmode \
5379 source=sub/conftest.c object=$am__obj \
5380 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5381 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5382 >/dev/null 2>conftest.err &&
5383 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5384 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5385 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5386 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5387 # icc doesn't choke on unknown options, it will just issue warnings
5388 # or remarks (even with -Werror). So we grep stderr for any message
5389 # that says an option was ignored or not supported.
5390 # When given -MP, icc 7.0 and 7.1 complain thusly:
5391 # icc: Command line warning: ignoring option '-M'; no argument required
5392 # The diagnosis changed in icc 8.0:
5393 # icc: Command line remark: option '-MP' not supported
5394 if (grep 'ignoring option' conftest.err ||
5395 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5396 am_cv_CC_dependencies_compiler_type=$depmode
5397 break
5398 fi
5399 fi
5400 done
5401
5402 cd ..
5403 rm -rf conftest.dir
5404else
5405 am_cv_CC_dependencies_compiler_type=none
5406fi
5407
5408fi
5409{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5410$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5411CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5412
5413 if
5414 test "x$enable_dependency_tracking" != xno \
5415 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5416 am__fastdepCC_TRUE=
5417 am__fastdepCC_FALSE='#'
5418else
5419 am__fastdepCC_TRUE='#'
5420 am__fastdepCC_FALSE=
5421fi
5422
5423
5424if test "x$CC" != xcc; then
5425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5426$as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5427else
5428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5429$as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5430fi
5431set dummy $CC; ac_cc=`$as_echo "$2" |
5432 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
d6974efa 5433if eval \${ac_cv_prog_cc_${ac_cc}_c_o+:} false; then :
743c80a7
PE
5434 $as_echo_n "(cached) " >&6
5435else
5436 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5437/* end confdefs.h. */
5438
5439int
5440main ()
5441{
5442
5443 ;
5444 return 0;
5445}
5446_ACEOF
5447# Make sure it works both with $CC and with simple cc.
5448# We do the test twice because some compilers refuse to overwrite an
5449# existing .o file with -o, though they will create one.
5450ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5451rm -f conftest2.*
5452if { { case "(($ac_try" in
5453 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5454 *) ac_try_echo=$ac_try;;
5455esac
5456eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5457$as_echo "$ac_try_echo"; } >&5
5458 (eval "$ac_try") 2>&5
5459 ac_status=$?
5460 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5461 test $ac_status = 0; } &&
5462 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5463 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5464 *) ac_try_echo=$ac_try;;
5465esac
5466eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5467$as_echo "$ac_try_echo"; } >&5
5468 (eval "$ac_try") 2>&5
5469 ac_status=$?
5470 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5471 test $ac_status = 0; };
5472then
5473 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5474 if test "x$CC" != xcc; then
5475 # Test first that cc exists at all.
5476 if { ac_try='cc -c conftest.$ac_ext >&5'
5477 { { case "(($ac_try" in
5478 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5479 *) ac_try_echo=$ac_try;;
5480esac
5481eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5482$as_echo "$ac_try_echo"; } >&5
5483 (eval "$ac_try") 2>&5
5484 ac_status=$?
5485 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5486 test $ac_status = 0; }; }; then
5487 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5488 rm -f conftest2.*
5489 if { { case "(($ac_try" in
5490 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5491 *) ac_try_echo=$ac_try;;
5492esac
5493eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5494$as_echo "$ac_try_echo"; } >&5
5495 (eval "$ac_try") 2>&5
5496 ac_status=$?
5497 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5498 test $ac_status = 0; } &&
5499 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5500 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5501 *) ac_try_echo=$ac_try;;
5502esac
5503eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5504$as_echo "$ac_try_echo"; } >&5
5505 (eval "$ac_try") 2>&5
5506 ac_status=$?
5507 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5508 test $ac_status = 0; };
5509 then
5510 # cc works too.
5511 :
5512 else
5513 # cc exists but doesn't like -o.
5514 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5515 fi
5516 fi
5517 fi
5518else
5519 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5520fi
5521rm -f core conftest*
5522
5523fi
5524if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5526$as_echo "yes" >&6; }
5527else
5528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5529$as_echo "no" >&6; }
5530
5531$as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5532
5533fi
5534
5535# FIXME: we rely on the cache variable name because
5536# there is no other way.
5537set dummy $CC
5538am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5539eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5540if test "$am_t" != yes; then
5541 # Losing compiler, so override with the script.
5542 # FIXME: It is wrong to rewrite CC.
5543 # But if we don't then we get into trouble of one sort or another.
5544 # A longer-term fix would be to have automake use am__CC in this case,
5545 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5546 CC="$am_aux_dir/compile $CC"
5547fi
5548
5549
5550
5551# Initialize gnulib right after verifying that the C compiler works.
5552if test -n "$ac_tool_prefix"; then
5553 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5554set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5555{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5556$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 5557if ${ac_cv_prog_RANLIB+:} false; then :
743c80a7
PE
5558 $as_echo_n "(cached) " >&6
5559else
5560 if test -n "$RANLIB"; then
5561 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5562else
5563as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5564for as_dir in $PATH
5565do
5566 IFS=$as_save_IFS
5567 test -z "$as_dir" && as_dir=.
5568 for ac_exec_ext in '' $ac_executable_extensions; do
5569 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5570 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5571 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5572 break 2
5573 fi
5574done
5575 done
5576IFS=$as_save_IFS
5577
5578fi
5579fi
5580RANLIB=$ac_cv_prog_RANLIB
5581if test -n "$RANLIB"; then
5582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
5583$as_echo "$RANLIB" >&6; }
5584else
5585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5586$as_echo "no" >&6; }
5587fi
5588
5589
5590fi
5591if test -z "$ac_cv_prog_RANLIB"; then
5592 ac_ct_RANLIB=$RANLIB
5593 # Extract the first word of "ranlib", so it can be a program name with args.
5594set dummy ranlib; ac_word=$2
5595{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5596$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 5597if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
743c80a7
PE
5598 $as_echo_n "(cached) " >&6
5599else
5600 if test -n "$ac_ct_RANLIB"; then
5601 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5602else
5603as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5604for as_dir in $PATH
5605do
5606 IFS=$as_save_IFS
5607 test -z "$as_dir" && as_dir=.
5608 for ac_exec_ext in '' $ac_executable_extensions; do
5609 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5610 ac_cv_prog_ac_ct_RANLIB="ranlib"
5611 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5612 break 2
5613 fi
5614done
5615 done
5616IFS=$as_save_IFS
067d23c9
KY
5617
5618fi
743c80a7
PE
5619fi
5620ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5621if test -n "$ac_ct_RANLIB"; then
5622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
5623$as_echo "$ac_ct_RANLIB" >&6; }
5624else
5625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5626$as_echo "no" >&6; }
5627fi
067d23c9 5628
743c80a7
PE
5629 if test "x$ac_ct_RANLIB" = x; then
5630 RANLIB=":"
5631 else
5632 case $cross_compiling:$ac_tool_warned in
5633yes:)
5634{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5635$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5636ac_tool_warned=yes ;;
5637esac
5638 RANLIB=$ac_ct_RANLIB
5639 fi
5640else
5641 RANLIB="$ac_cv_prog_RANLIB"
067d23c9
KY
5642fi
5643
743c80a7 5644
067d23c9
KY
5645ac_ext=c
5646ac_cpp='$CPP $CPPFLAGS'
5647ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5648ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5649ac_compiler_gnu=$ac_cv_c_compiler_gnu
5650{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5651$as_echo_n "checking how to run the C preprocessor... " >&6; }
5652# On Suns, sometimes $CPP names a directory.
5653if test -n "$CPP" && test -d "$CPP"; then
5654 CPP=
5655fi
5656if test -z "$CPP"; then
d6974efa 5657 if ${ac_cv_prog_CPP+:} false; then :
067d23c9
KY
5658 $as_echo_n "(cached) " >&6
5659else
5660 # Double quotes because CPP needs to be expanded
5661 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5662 do
5663 ac_preproc_ok=false
5664for ac_c_preproc_warn_flag in '' yes
5665do
5666 # Use a header file that comes with gcc, so configuring glibc
5667 # with a fresh cross-compiler works.
5668 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5669 # <limits.h> exists even on freestanding compilers.
5670 # On the NeXT, cc -E runs the code through the compiler's parser,
5671 # not just through cpp. "Syntax error" is here to catch this case.
5672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5673/* end confdefs.h. */
5674#ifdef __STDC__
5675# include <limits.h>
5676#else
5677# include <assert.h>
5678#endif
5679 Syntax error
5680_ACEOF
5681if ac_fn_c_try_cpp "$LINENO"; then :
5682
5683else
5684 # Broken: fails on valid input.
5685continue
5686fi
2018939f 5687rm -f conftest.err conftest.i conftest.$ac_ext
067d23c9
KY
5688
5689 # OK, works on sane cases. Now check whether nonexistent headers
5690 # can be detected and how.
5691 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5692/* end confdefs.h. */
5693#include <ac_nonexistent.h>
5694_ACEOF
5695if ac_fn_c_try_cpp "$LINENO"; then :
5696 # Broken: success on invalid input.
5697continue
5698else
5699 # Passes both tests.
5700ac_preproc_ok=:
5701break
5702fi
2018939f 5703rm -f conftest.err conftest.i conftest.$ac_ext
067d23c9
KY
5704
5705done
5706# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2018939f 5707rm -f conftest.i conftest.err conftest.$ac_ext
067d23c9
KY
5708if $ac_preproc_ok; then :
5709 break
5710fi
5711
5712 done
5713 ac_cv_prog_CPP=$CPP
5714
5715fi
5716 CPP=$ac_cv_prog_CPP
5717else
5718 ac_cv_prog_CPP=$CPP
5719fi
5720{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5721$as_echo "$CPP" >&6; }
5722ac_preproc_ok=false
5723for ac_c_preproc_warn_flag in '' yes
5724do
5725 # Use a header file that comes with gcc, so configuring glibc
5726 # with a fresh cross-compiler works.
5727 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5728 # <limits.h> exists even on freestanding compilers.
5729 # On the NeXT, cc -E runs the code through the compiler's parser,
5730 # not just through cpp. "Syntax error" is here to catch this case.
5731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5732/* end confdefs.h. */
5733#ifdef __STDC__
5734# include <limits.h>
5735#else
5736# include <assert.h>
5737#endif
5738 Syntax error
5739_ACEOF
5740if ac_fn_c_try_cpp "$LINENO"; then :
5741
5742else
5743 # Broken: fails on valid input.
5744continue
5745fi
2018939f 5746rm -f conftest.err conftest.i conftest.$ac_ext
067d23c9
KY
5747
5748 # OK, works on sane cases. Now check whether nonexistent headers
5749 # can be detected and how.
5750 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5751/* end confdefs.h. */
5752#include <ac_nonexistent.h>
5753_ACEOF
5754if ac_fn_c_try_cpp "$LINENO"; then :
5755 # Broken: success on invalid input.
5756continue
5757else
5758 # Passes both tests.
5759ac_preproc_ok=:
5760break
5761fi
2018939f 5762rm -f conftest.err conftest.i conftest.$ac_ext
067d23c9
KY
5763
5764done
5765# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2018939f 5766rm -f conftest.i conftest.err conftest.$ac_ext
067d23c9
KY
5767if $ac_preproc_ok; then :
5768
5769else
5770 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5771$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2018939f 5772as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
d6974efa 5773See \`config.log' for more details" "$LINENO" 5; }
067d23c9
KY
5774fi
5775
5776ac_ext=c
5777ac_cpp='$CPP $CPPFLAGS'
5778ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5779ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5780ac_compiler_gnu=$ac_cv_c_compiler_gnu
5781
5782
5783{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5784$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
d6974efa 5785if ${ac_cv_path_GREP+:} false; then :
067d23c9
KY
5786 $as_echo_n "(cached) " >&6
5787else
5788 if test -z "$GREP"; then
5789 ac_path_GREP_found=false
5790 # Loop through the user's path and test for each of PROGNAME-LIST
5791 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5792for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5793do
5794 IFS=$as_save_IFS
5795 test -z "$as_dir" && as_dir=.
5796 for ac_prog in grep ggrep; do
5797 for ac_exec_ext in '' $ac_executable_extensions; do
5798 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5799 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5800# Check for GNU ac_path_GREP and select it if it is found.
5801 # Check for GNU $ac_path_GREP
5802case `"$ac_path_GREP" --version 2>&1` in
5803*GNU*)
5804 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5805*)
5806 ac_count=0
5807 $as_echo_n 0123456789 >"conftest.in"
5808 while :
5809 do
5810 cat "conftest.in" "conftest.in" >"conftest.tmp"
5811 mv "conftest.tmp" "conftest.in"
5812 cp "conftest.in" "conftest.nl"
5813 $as_echo 'GREP' >> "conftest.nl"
5814 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5815 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5816 as_fn_arith $ac_count + 1 && ac_count=$as_val
5817 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5818 # Best one so far, save it but keep looking for a better one
5819 ac_cv_path_GREP="$ac_path_GREP"
5820 ac_path_GREP_max=$ac_count
5821 fi
5822 # 10*(2^10) chars as input seems more than enough
5823 test $ac_count -gt 10 && break
5824 done
5825 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5826esac
5827
5828 $ac_path_GREP_found && break 3
5829 done
5830 done
5831 done
5832IFS=$as_save_IFS
5833 if test -z "$ac_cv_path_GREP"; then
2018939f 5834 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
067d23c9
KY
5835 fi
5836else
5837 ac_cv_path_GREP=$GREP
5838fi
5839
5840fi
5841{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5842$as_echo "$ac_cv_path_GREP" >&6; }
5843 GREP="$ac_cv_path_GREP"
5844
5845
5846{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5847$as_echo_n "checking for egrep... " >&6; }
d6974efa 5848if ${ac_cv_path_EGREP+:} false; then :
067d23c9
KY
5849 $as_echo_n "(cached) " >&6
5850else
5851 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5852 then ac_cv_path_EGREP="$GREP -E"
5853 else
5854 if test -z "$EGREP"; then
5855 ac_path_EGREP_found=false
5856 # Loop through the user's path and test for each of PROGNAME-LIST
5857 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5858for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5859do
5860 IFS=$as_save_IFS
5861 test -z "$as_dir" && as_dir=.
5862 for ac_prog in egrep; do
5863 for ac_exec_ext in '' $ac_executable_extensions; do
5864 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5865 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5866# Check for GNU ac_path_EGREP and select it if it is found.
5867 # Check for GNU $ac_path_EGREP
5868case `"$ac_path_EGREP" --version 2>&1` in
5869*GNU*)
5870 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5871*)
5872 ac_count=0
5873 $as_echo_n 0123456789 >"conftest.in"
5874 while :
5875 do
5876 cat "conftest.in" "conftest.in" >"conftest.tmp"
5877 mv "conftest.tmp" "conftest.in"
5878 cp "conftest.in" "conftest.nl"
5879 $as_echo 'EGREP' >> "conftest.nl"
5880 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5881 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5882 as_fn_arith $ac_count + 1 && ac_count=$as_val
5883 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5884 # Best one so far, save it but keep looking for a better one
5885 ac_cv_path_EGREP="$ac_path_EGREP"
5886 ac_path_EGREP_max=$ac_count
5887 fi
5888 # 10*(2^10) chars as input seems more than enough
5889 test $ac_count -gt 10 && break
5890 done
5891 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5892esac
5893
5894 $ac_path_EGREP_found && break 3
5895 done
5896 done
5897 done
5898IFS=$as_save_IFS
5899 if test -z "$ac_cv_path_EGREP"; then
2018939f 5900 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
067d23c9
KY
5901 fi
5902else
5903 ac_cv_path_EGREP=$EGREP
5904fi
5905
5906 fi
5907fi
5908{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
5909$as_echo "$ac_cv_path_EGREP" >&6; }
5910 EGREP="$ac_cv_path_EGREP"
5911
5912
5913{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
5914$as_echo_n "checking for ANSI C header files... " >&6; }
d6974efa 5915if ${ac_cv_header_stdc+:} false; then :
067d23c9
KY
5916 $as_echo_n "(cached) " >&6
5917else
5918 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5919/* end confdefs.h. */
5920#include <stdlib.h>
5921#include <stdarg.h>
5922#include <string.h>
5923#include <float.h>
5924
5925int
5926main ()
5927{
5928
5929 ;
5930 return 0;
5931}
5932_ACEOF
5933if ac_fn_c_try_compile "$LINENO"; then :
5934 ac_cv_header_stdc=yes
5935else
5936 ac_cv_header_stdc=no
5937fi
5938rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5939
5940if test $ac_cv_header_stdc = yes; then
5941 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5942 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5943/* end confdefs.h. */
5944#include <string.h>
5945
5946_ACEOF
5947if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5948 $EGREP "memchr" >/dev/null 2>&1; then :
5949
5950else
5951 ac_cv_header_stdc=no
5952fi
5953rm -f conftest*
5954
5955fi
5956
5957if test $ac_cv_header_stdc = yes; then
5958 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5959 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5960/* end confdefs.h. */
5961#include <stdlib.h>
5962
5963_ACEOF
5964if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5965 $EGREP "free" >/dev/null 2>&1; then :
5966
5967else
5968 ac_cv_header_stdc=no
5969fi
5970rm -f conftest*
5971
5972fi
5973
5974if test $ac_cv_header_stdc = yes; then
5975 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5976 if test "$cross_compiling" = yes; then :
5977 :
5978else
5979 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5980/* end confdefs.h. */
5981#include <ctype.h>
5982#include <stdlib.h>
5983#if ((' ' & 0x0FF) == 0x020)
5984# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5985# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5986#else
5987# define ISLOWER(c) \
5988 (('a' <= (c) && (c) <= 'i') \
5989 || ('j' <= (c) && (c) <= 'r') \
5990 || ('s' <= (c) && (c) <= 'z'))
5991# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5992#endif
5993
5994#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
5995int
5996main ()
5997{
5998 int i;
5999 for (i = 0; i < 256; i++)
6000 if (XOR (islower (i), ISLOWER (i))
6001 || toupper (i) != TOUPPER (i))
6002 return 2;
6003 return 0;
6004}
6005_ACEOF
6006if ac_fn_c_try_run "$LINENO"; then :
6007
6008else
6009 ac_cv_header_stdc=no
6010fi
6011rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6012 conftest.$ac_objext conftest.beam conftest.$ac_ext
6013fi
6014
6015fi
6016fi
6017{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6018$as_echo "$ac_cv_header_stdc" >&6; }
6019if test $ac_cv_header_stdc = yes; then
6020
6021$as_echo "#define STDC_HEADERS 1" >>confdefs.h
6022
6023fi
6024
6025# On IRIX 5.3, sys/types and inttypes.h are conflicting.
6026for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6027 inttypes.h stdint.h unistd.h
6028do :
6029 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6030ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6031"
2018939f 6032if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
067d23c9
KY
6033 cat >>confdefs.h <<_ACEOF
6034#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6035_ACEOF
6036
6037fi
6038
6039done
6040
6041
6042
1fd182f0
PE
6043
6044
067d23c9 6045 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
d6974efa 6046if test "x$ac_cv_header_minix_config_h" = xyes; then :
067d23c9
KY
6047 MINIX=yes
6048else
6049 MINIX=
6050fi
6051
6052
6053 if test "$MINIX" = yes; then
6054
6055$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6056
6057
6058$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6059
6060
6061$as_echo "#define _MINIX 1" >>confdefs.h
6062
6063 fi
6064
1fd182f0
PE
6065 case "$host_os" in
6066 hpux*)
6067
6068$as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6069
6070 ;;
6071 esac
6072
067d23c9
KY
6073
6074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6075$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
d6974efa 6076if ${ac_cv_safe_to_define___extensions__+:} false; then :
067d23c9
KY
6077 $as_echo_n "(cached) " >&6
6078else
6079 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6080/* end confdefs.h. */
6081
1fd182f0
PE
6082# define __EXTENSIONS__ 1
6083 $ac_includes_default
067d23c9
KY
6084int
6085main ()
6086{
6087
6088 ;
6089 return 0;
6090}
6091_ACEOF
6092if ac_fn_c_try_compile "$LINENO"; then :
6093 ac_cv_safe_to_define___extensions__=yes
6094else
6095 ac_cv_safe_to_define___extensions__=no
6096fi
6097rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6098fi
6099{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6100$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6101 test $ac_cv_safe_to_define___extensions__ = yes &&
6102 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6103
6104 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6105
6106 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6107
6108 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6109
6110 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6111
6112
6113
1fd182f0
PE
6114
6115
6116
6117
6118
6119
6120
6121 # Code from module arg-nonnull:
6122 # Code from module c++defs:
942f733f 6123 # Code from module crypto/md5:
f737437b 6124 # Code from module dtoastr:
1fd182f0
PE
6125 # Code from module extensions:
6126
5fa4ac76 6127 # Code from module filemode:
1f5d53eb 6128 # Code from module getloadavg:
e275c824
PE
6129 # Code from module getopt-gnu:
6130 # Code from module getopt-posix:
6131 # Code from module gettext-h:
67342916 6132 # Code from module ignore-value:
1fd182f0
PE
6133 # Code from module include_next:
6134 # Code from module intprops:
6135 # Code from module mktime:
6136 # Code from module multiarch:
16c3e636 6137 # Code from module stdbool:
1fd182f0 6138 # Code from module stddef:
5f90be1b 6139 # Code from module stdint:
1f5d53eb 6140 # Code from module stdlib:
16c3e636 6141 # Code from module strftime:
5fa4ac76 6142 # Code from module sys_stat:
1fd182f0
PE
6143 # Code from module time:
6144 # Code from module time_r:
e275c824 6145 # Code from module unistd:
1fd182f0
PE
6146 # Code from module warn-on-use:
6147
6148
6149# On Suns, sometimes $CPP names a directory.
6150if test -n "$CPP" && test -d "$CPP"; then
6151 CPP=
6152fi
6153
6154## If not using gcc, and on Solaris, and no CPP specified, see if
6155## using a Sun compiler, which needs -Xs to prevent whitespace.
6156if test x"$GCC" != xyes && test x"$emacs_check_sunpro_c" = xyes && \
6157 test x"$CPP" = x; then
6158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using a Sun C compiler" >&5
6159$as_echo_n "checking whether we are using a Sun C compiler... " >&6; }
d6974efa 6160 if ${emacs_cv_sunpro_c+:} false; then :
1fd182f0
PE
6161 $as_echo_n "(cached) " >&6
6162else
6163 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6164/* end confdefs.h. */
6165
6166int
6167main ()
6168{
6169#ifndef __SUNPRO_C
6170fail;
6171#endif
6172
6173 ;
6174 return 0;
6175}
6176_ACEOF
6177if ac_fn_c_try_link "$LINENO"; then :
6178 emacs_cv_sunpro_c=yes
6179else
6180 emacs_cv_sunpro_c=no
6181fi
6182rm -f core conftest.err conftest.$ac_objext \
6183 conftest$ac_exeext conftest.$ac_ext
6184fi
6185
6186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_sunpro_c" >&5
6187$as_echo "$emacs_cv_sunpro_c" >&6; }
6188
6189 if test x"$emacs_cv_sunpro_c" = xyes; then
6190 NON_GNU_CPP="$CC -E -Xs"
6191 fi
6192fi
6193
6194#### Some systems specify a CPP to use unless we are using GCC.
6195#### Now that we know whether we are using GCC, we can decide whether
6196#### to use that one.
6197if test "x$NON_GNU_CPP" != x && test x$GCC != xyes && test "x$CPP" = x
6198then
6199 CPP="$NON_GNU_CPP"
6200fi
6201
6202#### Some systems specify a CC to use unless we are using GCC.
6203#### Now that we know whether we are using GCC, we can decide whether
6204#### to use that one.
6205if test "x$NON_GNU_CC" != x && test x$GCC != xyes &&
6206 test x$cc_specified != xyes
6207then
6208 CC="$NON_GNU_CC"
6209fi
6210
6211if test x$GCC = xyes; then
6212 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
6213else
6214 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
6215fi
6216
067d23c9
KY
6217### Use -Wno-pointer-sign if the compiler supports it
6218{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wno-pointer-sign" >&5
6219$as_echo_n "checking whether gcc understands -Wno-pointer-sign... " >&6; }
6220SAVE_CFLAGS="$CFLAGS"
6221CFLAGS="$CFLAGS -Wno-pointer-sign"
6222cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6223/* end confdefs.h. */
6224
6225int
6226main ()
6227{
6228
6229 ;
6230 return 0;
6231}
6232_ACEOF
6233if ac_fn_c_try_compile "$LINENO"; then :
6234 has_option=yes
6235else
6236 has_option=no
6237fi
6238rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6239if test $has_option = yes; then
6240 C_WARNINGS_SWITCH="-Wno-pointer-sign $C_WARNINGS_SWITCH"
6241fi
6242{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
6243$as_echo "$has_option" >&6; }
6244CFLAGS="$SAVE_CFLAGS"
6245unset has_option
6246unset SAVE_CFLAGS
6247
6248### Use -Wdeclaration-after-statement if the compiler supports it
6249{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wdeclaration-after-statement" >&5
6250$as_echo_n "checking whether gcc understands -Wdeclaration-after-statement... " >&6; }
6251SAVE_CFLAGS="$CFLAGS"
6252CFLAGS="$CFLAGS -Wdeclaration-after-statement"
6253cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6254/* end confdefs.h. */
6255
6256int
6257main ()
6258{
6259
6260 ;
6261 return 0;
6262}
6263_ACEOF
6264if ac_fn_c_try_compile "$LINENO"; then :
6265 has_option=yes
6266else
6267 has_option=no
6268fi
6269rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6270if test $has_option = yes; then
6271 C_WARNINGS_SWITCH="-Wdeclaration-after-statement $C_WARNINGS_SWITCH"
6272fi
6273{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
6274$as_echo "$has_option" >&6; }
6275CFLAGS="$SAVE_CFLAGS"
6276unset has_option
6277unset SAVE_CFLAGS
6278
6279### Use -Wold-style-definition if the compiler supports it
6280# This can be removed when conversion to standard C is finished.
6281{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wold-style-definition" >&5
6282$as_echo_n "checking whether gcc understands -Wold-style-definition... " >&6; }
6283SAVE_CFLAGS="$CFLAGS"
6284CFLAGS="$CFLAGS -Wold-style-definition"
6285cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6286/* end confdefs.h. */
6287
6288int
6289main ()
6290{
6291
6292 ;
6293 return 0;
6294}
6295_ACEOF
6296if ac_fn_c_try_compile "$LINENO"; then :
6297 has_option=yes
6298else
6299 has_option=no
6300fi
6301rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6302if test $has_option = yes; then
6303 C_WARNINGS_SWITCH="-Wold-style-definition $C_WARNINGS_SWITCH"
6304fi
6305{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
6306$as_echo "$has_option" >&6; }
6307CFLAGS="$SAVE_CFLAGS"
6308unset has_option
6309unset SAVE_CFLAGS
6310
6311### Use -Wimplicit-function-declaration if the compiler supports it
6312{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wimplicit-function-declaration" >&5
6313$as_echo_n "checking whether gcc understands -Wimplicit-function-declaration... " >&6; }
6314SAVE_CFLAGS="$CFLAGS"
6315CFLAGS="$CFLAGS -Wimplicit-function-declaration"
6316cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6317/* end confdefs.h. */
6318
6319int
6320main ()
6321{
6322
6323 ;
6324 return 0;
6325}
6326_ACEOF
6327if ac_fn_c_try_compile "$LINENO"; then :
6328 has_option=yes
6329else
6330 has_option=no
6331fi
6332rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6333if test $has_option = yes; then
6334 C_WARNINGS_SWITCH="-Wimplicit-function-declaration $C_WARNINGS_SWITCH"
6335fi
6336{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
6337$as_echo "$has_option" >&6; }
6338CFLAGS="$SAVE_CFLAGS"
6339unset has_option
6340unset SAVE_CFLAGS
6341
6342
6343
6344
6345#### Some other nice autoconf tests.
6346
6347ac_ext=c
6348ac_cpp='$CPP $CPPFLAGS'
6349ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6350ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6351ac_compiler_gnu=$ac_cv_c_compiler_gnu
6352{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
6353$as_echo_n "checking how to run the C preprocessor... " >&6; }
6354# On Suns, sometimes $CPP names a directory.
6355if test -n "$CPP" && test -d "$CPP"; then
6356 CPP=
6357fi
6358if test -z "$CPP"; then
d6974efa 6359 if ${ac_cv_prog_CPP+:} false; then :
067d23c9
KY
6360 $as_echo_n "(cached) " >&6
6361else
6362 # Double quotes because CPP needs to be expanded
6363 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6364 do
6365 ac_preproc_ok=false
6366for ac_c_preproc_warn_flag in '' yes
6367do
6368 # Use a header file that comes with gcc, so configuring glibc
6369 # with a fresh cross-compiler works.
6370 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6371 # <limits.h> exists even on freestanding compilers.
6372 # On the NeXT, cc -E runs the code through the compiler's parser,
6373 # not just through cpp. "Syntax error" is here to catch this case.
6374 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6375/* end confdefs.h. */
6376#ifdef __STDC__
6377# include <limits.h>
6378#else
6379# include <assert.h>
6380#endif
6381 Syntax error
6382_ACEOF
6383if ac_fn_c_try_cpp "$LINENO"; then :
6384
6385else
6386 # Broken: fails on valid input.
6387continue
6388fi
2018939f 6389rm -f conftest.err conftest.i conftest.$ac_ext
067d23c9
KY
6390
6391 # OK, works on sane cases. Now check whether nonexistent headers
6392 # can be detected and how.
6393 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6394/* end confdefs.h. */
6395#include <ac_nonexistent.h>
6396_ACEOF
6397if ac_fn_c_try_cpp "$LINENO"; then :
6398 # Broken: success on invalid input.
6399continue
6400else
6401 # Passes both tests.
6402ac_preproc_ok=:
6403break
6404fi
2018939f 6405rm -f conftest.err conftest.i conftest.$ac_ext
067d23c9
KY
6406
6407done
6408# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2018939f 6409rm -f conftest.i conftest.err conftest.$ac_ext
067d23c9
KY
6410if $ac_preproc_ok; then :
6411 break
6412fi
6413
6414 done
6415 ac_cv_prog_CPP=$CPP
6416
6417fi
6418 CPP=$ac_cv_prog_CPP
6419else
6420 ac_cv_prog_CPP=$CPP
6421fi
6422{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
6423$as_echo "$CPP" >&6; }
6424ac_preproc_ok=false
6425for ac_c_preproc_warn_flag in '' yes
6426do
6427 # Use a header file that comes with gcc, so configuring glibc
6428 # with a fresh cross-compiler works.
6429 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6430 # <limits.h> exists even on freestanding compilers.
6431 # On the NeXT, cc -E runs the code through the compiler's parser,
6432 # not just through cpp. "Syntax error" is here to catch this case.
6433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6434/* end confdefs.h. */
6435#ifdef __STDC__
6436# include <limits.h>
6437#else
6438# include <assert.h>
6439#endif
6440 Syntax error
6441_ACEOF
6442if ac_fn_c_try_cpp "$LINENO"; then :
6443
6444else
6445 # Broken: fails on valid input.
6446continue
6447fi
2018939f 6448rm -f conftest.err conftest.i conftest.$ac_ext
067d23c9
KY
6449
6450 # OK, works on sane cases. Now check whether nonexistent headers
6451 # can be detected and how.
6452 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6453/* end confdefs.h. */
6454#include <ac_nonexistent.h>
6455_ACEOF
6456if ac_fn_c_try_cpp "$LINENO"; then :
6457 # Broken: success on invalid input.
6458continue
6459else
6460 # Passes both tests.
6461ac_preproc_ok=:
6462break
6463fi
2018939f 6464rm -f conftest.err conftest.i conftest.$ac_ext
067d23c9
KY
6465
6466done
6467# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2018939f 6468rm -f conftest.i conftest.err conftest.$ac_ext
067d23c9
KY
6469if $ac_preproc_ok; then :
6470
6471else
6472 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6473$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2018939f 6474as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
d6974efa 6475See \`config.log' for more details" "$LINENO" 5; }
067d23c9
KY
6476fi
6477
6478ac_ext=c
6479ac_cpp='$CPP $CPPFLAGS'
6480ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6481ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6482ac_compiler_gnu=$ac_cv_c_compiler_gnu
6483
067d23c9
KY
6484
6485if test "x$RANLIB" = x; then
6486 if test -n "$ac_tool_prefix"; then
6487 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6488set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6489{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6490$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 6491if ${ac_cv_prog_RANLIB+:} false; then :
067d23c9
KY
6492 $as_echo_n "(cached) " >&6
6493else
6494 if test -n "$RANLIB"; then
6495 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6496else
6497as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6498for as_dir in $PATH
6499do
6500 IFS=$as_save_IFS
6501 test -z "$as_dir" && as_dir=.
6502 for ac_exec_ext in '' $ac_executable_extensions; do
6503 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6504 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6505 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6506 break 2
6507 fi
6508done
6509 done
6510IFS=$as_save_IFS
6511
6512fi
6513fi
6514RANLIB=$ac_cv_prog_RANLIB
6515if test -n "$RANLIB"; then
6516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6517$as_echo "$RANLIB" >&6; }
6518else
6519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6520$as_echo "no" >&6; }
6521fi
6522
6523
6524fi
6525if test -z "$ac_cv_prog_RANLIB"; then
6526 ac_ct_RANLIB=$RANLIB
6527 # Extract the first word of "ranlib", so it can be a program name with args.
6528set dummy ranlib; ac_word=$2
6529{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6530$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 6531if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
067d23c9
KY
6532 $as_echo_n "(cached) " >&6
6533else
6534 if test -n "$ac_ct_RANLIB"; then
6535 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6536else
6537as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6538for as_dir in $PATH
6539do
6540 IFS=$as_save_IFS
6541 test -z "$as_dir" && as_dir=.
6542 for ac_exec_ext in '' $ac_executable_extensions; do
6543 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6544 ac_cv_prog_ac_ct_RANLIB="ranlib"
6545 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6546 break 2
6547 fi
6548done
6549 done
6550IFS=$as_save_IFS
6551
6552fi
6553fi
6554ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6555if test -n "$ac_ct_RANLIB"; then
6556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6557$as_echo "$ac_ct_RANLIB" >&6; }
6558else
6559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6560$as_echo "no" >&6; }
6561fi
6562
6563 if test "x$ac_ct_RANLIB" = x; then
6564 RANLIB=":"
6565 else
6566 case $cross_compiling:$ac_tool_warned in
6567yes:)
6568{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6569$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6570ac_tool_warned=yes ;;
6571esac
6572 RANLIB=$ac_ct_RANLIB
6573 fi
6574else
6575 RANLIB="$ac_cv_prog_RANLIB"
6576fi
6577
6578fi
6579
6580## Although we're running on an amd64 kernel, we're actually compiling for
6581## the x86 architecture. The user should probably have provided an
6582## explicit --build to `configure', but if everything else than the kernel
6583## is running in i386 mode, we can help them out.
6584if test "$machine" = "amdx86-64"; then
6585 ac_fn_c_check_decl "$LINENO" "i386" "ac_cv_have_decl_i386" "$ac_includes_default"
d6974efa 6586if test "x$ac_cv_have_decl_i386" = xyes; then :
067d23c9
KY
6587
6588fi
6589
6590 if test "$ac_cv_have_decl_i386" = "yes"; then
6591 canonical=`echo "$canonical" | sed -e 's/^amd64/i386/' -e 's/^x86_64/i386/'`
6592 machine=intel386
6593 machfile="m/${machine}.h"
6594 fi
6595fi
6596
6597# Extract the first word of "install-info", so it can be a program name with args.
6598set dummy install-info; ac_word=$2
6599{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6600$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 6601if ${ac_cv_path_INSTALL_INFO+:} false; then :
067d23c9
KY
6602 $as_echo_n "(cached) " >&6
6603else
6604 case $INSTALL_INFO in
6605 [\\/]* | ?:[\\/]*)
6606 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
6607 ;;
6608 *)
6609 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6610for as_dir in $PATH
6611do
6612 IFS=$as_save_IFS
6613 test -z "$as_dir" && as_dir=.
6614 for ac_exec_ext in '' $ac_executable_extensions; do
6615 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6616 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
6617 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6618 break 2
6619 fi
6620done
6621 done
6622IFS=$as_save_IFS
6623
6624 ;;
6625esac
6626fi
6627INSTALL_INFO=$ac_cv_path_INSTALL_INFO
6628if test -n "$INSTALL_INFO"; then
6629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
6630$as_echo "$INSTALL_INFO" >&6; }
6631else
6632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6633$as_echo "no" >&6; }
6634fi
6635
6636
6637# Extract the first word of "install-info", so it can be a program name with args.
6638set dummy install-info; ac_word=$2
6639{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6640$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 6641if ${ac_cv_path_INSTALL_INFO+:} false; then :
067d23c9
KY
6642 $as_echo_n "(cached) " >&6
6643else
6644 case $INSTALL_INFO in
6645 [\\/]* | ?:[\\/]*)
6646 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
6647 ;;
6648 *)
6649 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6650for as_dir in /usr/sbin
6651do
6652 IFS=$as_save_IFS
6653 test -z "$as_dir" && as_dir=.
6654 for ac_exec_ext in '' $ac_executable_extensions; do
6655 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6656 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
6657 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6658 break 2
6659 fi
6660done
6661 done
6662IFS=$as_save_IFS
6663
6664 ;;
6665esac
6666fi
6667INSTALL_INFO=$ac_cv_path_INSTALL_INFO
6668if test -n "$INSTALL_INFO"; then
6669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
6670$as_echo "$INSTALL_INFO" >&6; }
6671else
6672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6673$as_echo "no" >&6; }
6674fi
6675
6676
6677# Extract the first word of "install-info", so it can be a program name with args.
6678set dummy install-info; ac_word=$2
6679{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6680$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 6681if ${ac_cv_path_INSTALL_INFO+:} false; then :
067d23c9
KY
6682 $as_echo_n "(cached) " >&6
6683else
6684 case $INSTALL_INFO in
6685 [\\/]* | ?:[\\/]*)
6686 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
6687 ;;
6688 *)
6689 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6690for as_dir in /sbin
6691do
6692 IFS=$as_save_IFS
6693 test -z "$as_dir" && as_dir=.
6694 for ac_exec_ext in '' $ac_executable_extensions; do
6695 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6696 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
6697 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6698 break 2
6699 fi
6700done
6701 done
6702IFS=$as_save_IFS
6703
6704 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
6705 ;;
6706esac
6707fi
6708INSTALL_INFO=$ac_cv_path_INSTALL_INFO
6709if test -n "$INSTALL_INFO"; then
6710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
6711$as_echo "$INSTALL_INFO" >&6; }
6712else
6713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6714$as_echo "no" >&6; }
6715fi
6716
6717
6718# Extract the first word of "gzip", so it can be a program name with args.
6719set dummy gzip; ac_word=$2
6720{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6721$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 6722if ${ac_cv_path_GZIP_PROG+:} false; then :
067d23c9
KY
6723 $as_echo_n "(cached) " >&6
6724else
6725 case $GZIP_PROG in
6726 [\\/]* | ?:[\\/]*)
6727 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
6728 ;;
6729 *)
6730 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6731for as_dir in $PATH
6732do
6733 IFS=$as_save_IFS
6734 test -z "$as_dir" && as_dir=.
6735 for ac_exec_ext in '' $ac_executable_extensions; do
6736 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6737 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
6738 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6739 break 2
6740 fi
6741done
6742 done
6743IFS=$as_save_IFS
6744
6745 ;;
6746esac
6747fi
6748GZIP_PROG=$ac_cv_path_GZIP_PROG
6749if test -n "$GZIP_PROG"; then
6750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
6751$as_echo "$GZIP_PROG" >&6; }
6752else
6753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6754$as_echo "no" >&6; }
6755fi
6756
6757
6758
6759
6760## Need makeinfo >= 4.6 (?) to build the manuals.
6761# Extract the first word of "makeinfo", so it can be a program name with args.
6762set dummy makeinfo; ac_word=$2
6763{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6764$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 6765if ${ac_cv_path_MAKEINFO+:} false; then :
067d23c9
KY
6766 $as_echo_n "(cached) " >&6
6767else
6768 case $MAKEINFO in
6769 [\\/]* | ?:[\\/]*)
6770 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
6771 ;;
6772 *)
6773 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6774for as_dir in $PATH
6775do
6776 IFS=$as_save_IFS
6777 test -z "$as_dir" && as_dir=.
6778 for ac_exec_ext in '' $ac_executable_extensions; do
6779 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6780 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
6781 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6782 break 2
6783 fi
6784done
6785 done
6786IFS=$as_save_IFS
6787
6788 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
6789 ;;
6790esac
6791fi
6792MAKEINFO=$ac_cv_path_MAKEINFO
6793if test -n "$MAKEINFO"; then
6794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
6795$as_echo "$MAKEINFO" >&6; }
6796else
6797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6798$as_echo "no" >&6; }
6799fi
6800
6801
6802if test "$MAKEINFO" != "no" && \
6803 test x"`$MAKEINFO --version 2> /dev/null | $EGREP 'texinfo[^0-9]*([1-4][0-9]+|[5-9]|4\.[6-9]|4\.[1-5][0-9]+)'`" = x; then
6804 MAKEINFO=no
6805fi
6806
6807## Makeinfo is unusual. For a released Emacs, the manuals are
6808## pre-built, and not deleted by the normal clean rules. makeinfo is
6809## therefore in the category of "special tools" not normally required, which
6810## configure does not have to check for (eg autoconf itself).
6811## In a Bazaar checkout on the other hand, the manuals are not included.
6812## So makeinfo is a requirement to build from Bazaar, and configure
6813## should test for it as it does for any other build requirement.
6814## We use the presence of $srcdir/info/emacs to distinguish a release,
6815## with pre-built manuals, from a Bazaar checkout.
96f129d5
GM
6816HAVE_MAKEINFO=yes
6817
067d23c9 6818if test "$MAKEINFO" = "no"; then
96f129d5 6819 MAKEINFO=makeinfo
067d23c9 6820 if test "x${with_makeinfo}" = "xno"; then
96f129d5 6821 HAVE_MAKEINFO=no
067d23c9 6822 elif test ! -e $srcdir/info/emacs; then
2018939f 6823 as_fn_error $? "You do not seem to have makeinfo >= 4.6, and your
067d23c9
KY
6824source tree does not seem to have pre-built manuals in the \`info' directory.
6825Either install a suitable version of makeinfo, or re-run configure
6826with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
6827 fi
6828fi
6829
6830
96f129d5 6831
067d23c9
KY
6832if test x$GCC = xyes; then
6833 test "x$GCC_LINK_TEST_OPTIONS" != x && \
6834 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
6835else
6836 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
6837 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
6838fi
6839
6840
6841late_LDFLAGS=$LDFLAGS
6842if test x$GCC = xyes; then
6843 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
6844else
6845 LDFLAGS="$LDFLAGS -znocombreloc"
6846fi
6847
6848{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
6849$as_echo_n "checking for -znocombreloc... " >&6; }
6850cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6851/* end confdefs.h. */
6852
6853int
6854main ()
6855{
6856
6857 ;
6858 return 0;
6859}
6860_ACEOF
6861if ac_fn_c_try_link "$LINENO"; then :
6862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6863$as_echo "yes" >&6; }
6864else
6865 LDFLAGS=$late_LDFLAGS
6866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6867$as_echo "no" >&6; }
6868fi
6869rm -f core conftest.err conftest.$ac_objext \
6870 conftest$ac_exeext conftest.$ac_ext
6871
6872
6873# The value of CPP is a quoted variable reference, so we need to do this
6874# to get its actual value...
6875CPP=`eval "echo $CPP"`
6876
6877
125c3718 6878test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
067d23c9 6879case "$opsys" in
125c3718
PE
6880 your-opsys-here) CANNOT_DUMP=yes ;;
6881esac
6882
6883test "$CANNOT_DUMP" = "yes" && \
067d23c9
KY
6884
6885$as_echo "#define CANNOT_DUMP 1" >>confdefs.h
6886
125c3718 6887
067d23c9
KY
6888
6889
6890
6891UNEXEC_OBJ=unexelf.o
6892case "$opsys" in
6893 # MSDOS uses unexcoff.o
6894 # MSWindows uses unexw32.o
6895 aix4-2)
6896 UNEXEC_OBJ=unexaix.o
6897 ;;
6898 cygwin)
6899 UNEXEC_OBJ=unexcw.o
6900 ;;
6901 darwin)
6902 UNEXEC_OBJ=unexmacosx.o
6903 ;;
6904 hpux10-20 | hpux11)
6905 UNEXEC_OBJ=unexhp9k800.o
6906 ;;
6907 sol2-10)
6908 # Use the Solaris dldump() function, called from unexsol.c, to dump
6909 # emacs, instead of the generic ELF dump code found in unexelf.c.
6910 # The resulting binary has a complete symbol table, and is better
6911 # for debugging and other observability tools (debuggers, pstack, etc).
6912 #
6913 # If you encounter a problem using dldump(), please consider sending
6914 # a message to the OpenSolaris tools-linking mailing list:
6915 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
6916 #
6917 # It is likely that dldump() works with older Solaris too, but this has
6918 # not been tested, so for now this change is for Solaris 10 or newer.
6919 UNEXEC_OBJ=unexsol.o
6920 ;;
6921esac
6922
6923LD_SWITCH_SYSTEM=
6924case "$opsys" in
6925 freebsd)
6926 ## Let `ld' find image libs and similar things in /usr/local/lib.
6927 ## The system compiler, GCC, has apparently been modified to not
6928 ## look there, contrary to what a stock GCC would do.
6929 LD_SWITCH_SYSTEM=-L/usr/local/lib
6930 ;;
6931
6932 gnu-linux)
6933 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
d6a003a8 6934 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
067d23c9
KY
6935 ;;
6936
6937 netbsd)
6938 LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
6939 ;;
6940
6941 openbsd)
6942 ## Han Boetes <han@mijncomputer.nl> says this is necessary,
6943 ## otherwise Emacs dumps core on elf systems.
6944 LD_SWITCH_SYSTEM="-Z"
6945 ;;
6946esac
6947
6948
6949ac_link="$ac_link $LD_SWITCH_SYSTEM"
6950
6951## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_AUX,
6952## which has not been defined yet. When this was handled with cpp,
6953## it was expanded to null when configure sourced the s/*.h file.
6954## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
6955## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
6956## (or somesuch), but because it is supposed to go at the _front_
6957## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
6958## Compare with the gnu-linux case below, which added to the end
6959## of LD_SWITCH_SYSTEM, and so can instead go at the front of
6960## LD_SWITCH_SYSTEM_TEMACS.
6961case "$opsys" in
6962 netbsd|openbsd)
6963 ## _AUX_RPATH is like _AUX, but uses -rpath instead of -R.
6964 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_AUX_RPATH) $LD_SWITCH_SYSTEM" ;;
6965esac
6966
6967
6968C_SWITCH_MACHINE=
6969if test "$machine" = "alpha"; then
6970 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
d6974efa 6971if test "x$ac_cv_have_decl___ELF__" = xyes; then :
067d23c9
KY
6972
6973fi
6974
6975 if test "$ac_cv_have_decl___ELF__" = "yes"; then
6976 ## With ELF, make sure that all common symbols get allocated to in the
6977 ## data section. Otherwise, the dump of temacs may miss variables in
6978 ## the shared library that have been initialized. For example, with
6979 ## GNU libc, __malloc_initialized would normally be resolved to the
6980 ## shared library's .bss section, which is fatal.
6981 if test "x$GCC" = "xyes"; then
6982 C_SWITCH_MACHINE="-fno-common"
6983 else
2018939f 6984 as_fn_error $? "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
067d23c9
KY
6985 fi
6986 else
6987 UNEXEC_OBJ=unexalpha.o
6988 fi
6989fi
6990
6991
6992
6993
6994C_SWITCH_SYSTEM=
6995## Some programs in src produce warnings saying certain subprograms
6996## are too complex and need a MAXMEM value greater than 2000 for
6997## additional optimization. --nils@exp-math.uni-essen.de
6998test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
6999 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
7000## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
7001## It is redundant in glibc2, since we define _GNU_SOURCE.
7002
7003
7004
7005LIBS_SYSTEM=
7006case "$opsys" in
7007 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
7008 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
7009
7010 freebsd) LIBS_SYSTEM="-lutil" ;;
7011
7012 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
7013
1f5d53eb 7014 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
067d23c9
KY
7015
7016 ## Motif needs -lgen.
7017 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
7018esac
7019
7020
7021
7022### Make sure subsequent tests use flags consistent with the build flags.
7023
7024if test x"${OVERRIDE_CPPFLAGS}" != x; then
7025 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
7026else
7027 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
7028fi
7029
067d23c9
KY
7030# Check whether --enable-largefile was given.
7031if test "${enable_largefile+set}" = set; then :
7032 enableval=$enable_largefile;
7033fi
7034
7035if test "$enable_largefile" != no; then
7036
7037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
7038$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
d6974efa 7039if ${ac_cv_sys_largefile_CC+:} false; then :
067d23c9
KY
7040 $as_echo_n "(cached) " >&6
7041else
7042 ac_cv_sys_largefile_CC=no
7043 if test "$GCC" != yes; then
7044 ac_save_CC=$CC
7045 while :; do
7046 # IRIX 6.2 and later do not support large files by default,
7047 # so use the C compiler's -n32 option if that helps.
7048 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7049/* end confdefs.h. */
7050#include <sys/types.h>
7051 /* Check that off_t can represent 2**63 - 1 correctly.
7052 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7053 since some C++ compilers masquerading as C compilers
7054 incorrectly reject 9223372036854775807. */
7055#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7056 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7057 && LARGE_OFF_T % 2147483647 == 1)
7058 ? 1 : -1];
7059int
7060main ()
7061{
7062
7063 ;
7064 return 0;
7065}
7066_ACEOF
7067 if ac_fn_c_try_compile "$LINENO"; then :
7068 break
7069fi
7070rm -f core conftest.err conftest.$ac_objext
7071 CC="$CC -n32"
7072 if ac_fn_c_try_compile "$LINENO"; then :
7073 ac_cv_sys_largefile_CC=' -n32'; break
7074fi
7075rm -f core conftest.err conftest.$ac_objext
7076 break
7077 done
7078 CC=$ac_save_CC
7079 rm -f conftest.$ac_ext
7080 fi
7081fi
7082{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
7083$as_echo "$ac_cv_sys_largefile_CC" >&6; }
7084 if test "$ac_cv_sys_largefile_CC" != no; then
7085 CC=$CC$ac_cv_sys_largefile_CC
7086 fi
7087
7088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
7089$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
d6974efa 7090if ${ac_cv_sys_file_offset_bits+:} false; then :
067d23c9
KY
7091 $as_echo_n "(cached) " >&6
7092else
7093 while :; do
7094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7095/* end confdefs.h. */
7096#include <sys/types.h>
7097 /* Check that off_t can represent 2**63 - 1 correctly.
7098 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7099 since some C++ compilers masquerading as C compilers
7100 incorrectly reject 9223372036854775807. */
7101#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7102 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7103 && LARGE_OFF_T % 2147483647 == 1)
7104 ? 1 : -1];
7105int
7106main ()
7107{
7108
7109 ;
7110 return 0;
7111}
7112_ACEOF
7113if ac_fn_c_try_compile "$LINENO"; then :
7114 ac_cv_sys_file_offset_bits=no; break
7115fi
7116rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7117 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7118/* end confdefs.h. */
7119#define _FILE_OFFSET_BITS 64
7120#include <sys/types.h>
7121 /* Check that off_t can represent 2**63 - 1 correctly.
7122 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7123 since some C++ compilers masquerading as C compilers
7124 incorrectly reject 9223372036854775807. */
7125#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7126 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7127 && LARGE_OFF_T % 2147483647 == 1)
7128 ? 1 : -1];
7129int
7130main ()
7131{
7132
7133 ;
7134 return 0;
7135}
7136_ACEOF
7137if ac_fn_c_try_compile "$LINENO"; then :
7138 ac_cv_sys_file_offset_bits=64; break
7139fi
7140rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7141 ac_cv_sys_file_offset_bits=unknown
7142 break
7143done
7144fi
7145{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
7146$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
7147case $ac_cv_sys_file_offset_bits in #(
7148 no | unknown) ;;
7149 *)
7150cat >>confdefs.h <<_ACEOF
7151#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
7152_ACEOF
7153;;
7154esac
7155rm -rf conftest*
7156 if test $ac_cv_sys_file_offset_bits = unknown; then
7157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
7158$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
d6974efa 7159if ${ac_cv_sys_large_files+:} false; then :
067d23c9
KY
7160 $as_echo_n "(cached) " >&6
7161else
7162 while :; do
7163 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7164/* end confdefs.h. */
7165#include <sys/types.h>
7166 /* Check that off_t can represent 2**63 - 1 correctly.
7167 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7168 since some C++ compilers masquerading as C compilers
7169 incorrectly reject 9223372036854775807. */
7170#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7171 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7172 && LARGE_OFF_T % 2147483647 == 1)
7173 ? 1 : -1];
7174int
7175main ()
7176{
7177
7178 ;
7179 return 0;
7180}
7181_ACEOF
7182if ac_fn_c_try_compile "$LINENO"; then :
7183 ac_cv_sys_large_files=no; break
7184fi
7185rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7186 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7187/* end confdefs.h. */
7188#define _LARGE_FILES 1
7189#include <sys/types.h>
7190 /* Check that off_t can represent 2**63 - 1 correctly.
7191 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7192 since some C++ compilers masquerading as C compilers
7193 incorrectly reject 9223372036854775807. */
7194#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7195 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7196 && LARGE_OFF_T % 2147483647 == 1)
7197 ? 1 : -1];
7198int
7199main ()
7200{
7201
7202 ;
7203 return 0;
7204}
7205_ACEOF
7206if ac_fn_c_try_compile "$LINENO"; then :
7207 ac_cv_sys_large_files=1; break
7208fi
7209rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7210 ac_cv_sys_large_files=unknown
7211 break
7212done
7213fi
7214{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
7215$as_echo "$ac_cv_sys_large_files" >&6; }
7216case $ac_cv_sys_large_files in #(
7217 no | unknown) ;;
7218 *)
7219cat >>confdefs.h <<_ACEOF
7220#define _LARGE_FILES $ac_cv_sys_large_files
7221_ACEOF
7222;;
7223esac
7224rm -rf conftest*
7225 fi
7226fi
7227
7228
7229
7230## If user specified a crt-dir, use that unconditionally.
7231if test "X$CRT_DIR" = "X"; then
7232
7233 case "$canonical" in
7234 x86_64-*-linux-gnu* | s390x-*-linux-gnu*)
7235 ## On x86-64 and s390x GNU/Linux distributions, the standard library
7236 ## can be in a variety of places. We only try /usr/lib64 and /usr/lib.
7237 ## For anything else (eg /usr/lib32), it is up the user to specify
7238 ## the location (bug#5655).
7239 ## Test for crtn.o, not just the directory, because sometimes the
7240 ## directory exists but does not have the relevant files (bug#1287).
7241 ## FIXME better to test for binary compatibility somehow.
7242 test -e /usr/lib64/crtn.o && CRT_DIR=/usr/lib64
7243 ;;
7244
7245 powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*) CRT_DIR=/usr/lib64 ;;
7246 esac
7247
7248 case "$opsys" in
7249 hpux10-20) CRT_DIR=/lib ;;
7250 esac
7251
7252 ## Default is /usr/lib.
7253 test "X$CRT_DIR" = "X" && CRT_DIR=/usr/lib
7254
7255else
7256
7257 ## Some platforms don't use any of these files, so it is not
7258 ## appropriate to put this test outside the if block.
7259 test -e $CRT_DIR/crtn.o || test -e $CRT_DIR/crt0.o || \
2018939f 7260 as_fn_error $? "crt*.o not found in specified location." "$LINENO" 5
067d23c9
KY
7261
7262fi
7263
7264
7265
7266LIB_MATH=-lm
7267LIB_STANDARD=
7268START_FILES=
7269
7270case $opsys in
7271 cygwin )
7272 LIB_MATH=
7273 START_FILES='pre-crt0.o'
7274 ;;
7275 darwin )
7276 ## Adding -lm confuses the dynamic linker, so omit it.
7277 LIB_MATH=
7278 START_FILES='pre-crt0.o'
7279 ;;
7280 freebsd )
7281 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
7282 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
7283 ;;
7284 gnu-linux | gnu-kfreebsd )
7285 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
7286 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
7287 ;;
7288 hpux10-20 | hpux11 )
7289 LIB_STANDARD=-lc
7290 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o'
7291 ;;
7292 netbsd | openbsd )
7293 if test -f $CRT_DIR/crti.o; then
7294 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
7295 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
7296 else
7297 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
7298 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
7299 fi
7300 ;;
7301esac
7302
7303
7304
7305
7306
7307
7308
7309if test "${with_sound}" != "no"; then
7310 # Sound support for GNU/Linux and the free BSDs.
7311 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
7312do :
7313 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7314ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
2018939f 7315if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
067d23c9
KY
7316 cat >>confdefs.h <<_ACEOF
7317#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7318_ACEOF
7319 have_sound_header=yes
7320fi
7321
7322done
7323
7324 # Emulation library used on NetBSD.
7325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
7326$as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
d6974efa 7327if ${ac_cv_lib_ossaudio__oss_ioctl+:} false; then :
067d23c9
KY
7328 $as_echo_n "(cached) " >&6
7329else
7330 ac_check_lib_save_LIBS=$LIBS
7331LIBS="-lossaudio $LIBS"
7332cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7333/* end confdefs.h. */
7334
7335/* Override any GCC internal prototype to avoid an error.
7336 Use char because int might match the return type of a GCC
7337 builtin and then its argument prototype would still apply. */
7338#ifdef __cplusplus
7339extern "C"
7340#endif
7341char _oss_ioctl ();
7342int
7343main ()
7344{
7345return _oss_ioctl ();
7346 ;
7347 return 0;
7348}
7349_ACEOF
7350if ac_fn_c_try_link "$LINENO"; then :
7351 ac_cv_lib_ossaudio__oss_ioctl=yes
7352else
7353 ac_cv_lib_ossaudio__oss_ioctl=no
7354fi
7355rm -f core conftest.err conftest.$ac_objext \
7356 conftest$ac_exeext conftest.$ac_ext
7357LIBS=$ac_check_lib_save_LIBS
7358fi
7359{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
7360$as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
d6974efa 7361if test "x$ac_cv_lib_ossaudio__oss_ioctl" = xyes; then :
067d23c9
KY
7362 LIBSOUND=-lossaudio
7363else
7364 LIBSOUND=
7365fi
7366
7367
7368
7369 ALSA_REQUIRED=1.0.0
7370 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
7371
7372 succeeded=no
7373
7374 # Extract the first word of "pkg-config", so it can be a program name with args.
7375set dummy pkg-config; ac_word=$2
7376{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7377$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 7378if ${ac_cv_path_PKG_CONFIG+:} false; then :
067d23c9
KY
7379 $as_echo_n "(cached) " >&6
7380else
7381 case $PKG_CONFIG in
7382 [\\/]* | ?:[\\/]*)
7383 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
7384 ;;
7385 *)
7386 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7387for as_dir in $PATH
7388do
7389 IFS=$as_save_IFS
7390 test -z "$as_dir" && as_dir=.
7391 for ac_exec_ext in '' $ac_executable_extensions; do
7392 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7393 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
7394 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7395 break 2
7396 fi
7397done
7398 done
7399IFS=$as_save_IFS
7400
7401 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
7402 ;;
7403esac
7404fi
7405PKG_CONFIG=$ac_cv_path_PKG_CONFIG
7406if test -n "$PKG_CONFIG"; then
7407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
7408$as_echo "$PKG_CONFIG" >&6; }
7409else
7410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7411$as_echo "no" >&6; }
7412fi
7413
7414
7415
7416 if test "$PKG_CONFIG" = "no" ; then
7417 HAVE_ALSA=no
7418 else
7419 PKG_CONFIG_MIN_VERSION=0.9.0
7420 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
7421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
7422$as_echo_n "checking for $ALSA_MODULES... " >&6; }
7423
7424 if $PKG_CONFIG --exists "$ALSA_MODULES" 2>&5; then
7425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7426$as_echo "yes" >&6; }
7427 succeeded=yes
7428
7429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking ALSA_CFLAGS" >&5
7430$as_echo_n "checking ALSA_CFLAGS... " >&6; }
7431 ALSA_CFLAGS=`$PKG_CONFIG --cflags "$ALSA_MODULES"|sed -e 's,///*,/,g'`
7432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ALSA_CFLAGS" >&5
7433$as_echo "$ALSA_CFLAGS" >&6; }
7434
7435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking ALSA_LIBS" >&5
7436$as_echo_n "checking ALSA_LIBS... " >&6; }
7437 ALSA_LIBS=`$PKG_CONFIG --libs "$ALSA_MODULES"|sed -e 's,///*,/,g'`
7438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ALSA_LIBS" >&5
7439$as_echo "$ALSA_LIBS" >&6; }
7440 else
7441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7442$as_echo "no" >&6; }
7443 ALSA_CFLAGS=""
7444 ALSA_LIBS=""
7445 ## If we have a custom action on failure, don't print errors, but
7446 ## do set a variable so people can do so.
7447 ALSA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$ALSA_MODULES"`
7448
7449 fi
7450
7451
7452
7453 else
7454 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
7455 echo "*** See http://www.freedesktop.org/software/pkgconfig"
7456 fi
7457 fi
7458
7459 if test $succeeded = yes; then
7460 HAVE_ALSA=yes
7461 else
7462 HAVE_ALSA=no
7463 fi
7464
7465 if test $HAVE_ALSA = yes; then
7466 SAVE_CFLAGS="$CFLAGS"
7467 SAVE_LDFLAGS="$LDFLAGS"
7468 CFLAGS="$ALSA_CFLAGS $CFLAGS"
7469 LDFLAGS="$ALSA_LIBS $LDFLAGS"
7470 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7471/* end confdefs.h. */
7472#include <asoundlib.h>
7473int
7474main ()
7475{
7476snd_lib_error_set_handler (0);
7477 ;
7478 return 0;
7479}
7480_ACEOF
7481if ac_fn_c_try_compile "$LINENO"; then :
7482 emacs_alsa_normal=yes
7483else
7484 emacs_alsa_normal=no
7485fi
7486rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7487 if test "$emacs_alsa_normal" != yes; then
7488 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7489/* end confdefs.h. */
7490#include <alsa/asoundlib.h>
7491int
7492main ()
7493{
7494snd_lib_error_set_handler (0);
7495 ;
7496 return 0;
7497}
7498_ACEOF
7499if ac_fn_c_try_compile "$LINENO"; then :
7500 emacs_alsa_subdir=yes
7501else
7502 emacs_alsa_subdir=no
7503fi
7504rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7505 if test "$emacs_alsa_subdir" != yes; then
2018939f 7506 as_fn_error $? "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
067d23c9
KY
7507 fi
7508 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
7509 fi
7510
7511 CFLAGS="$SAVE_CFLAGS"
7512 LDFLAGS="$SAVE_LDFLAGS"
7513 LIBSOUND="$LIBSOUND $ALSA_LIBS"
7514 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
7515
7516$as_echo "#define HAVE_ALSA 1" >>confdefs.h
7517
7518 fi
7519
7520 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
7521 case "$opsys" in
7522 gnu-linux|freebsd|netbsd)
7523
7524$as_echo "#define HAVE_SOUND 1" >>confdefs.h
7525
7526 ;;
7527 esac
7528 fi
7529
7530
7531fi
7532
7533for ac_header in sys/select.h sys/time.h unistd.h utime.h \
7534 linux/version.h sys/systeminfo.h limits.h \
7535 stdio_ext.h fcntl.h coff.h pty.h sys/mman.h \
7536 sys/vlimit.h sys/resource.h locale.h sys/_mbstate_t.h \
7537 sys/utsname.h pwd.h utmp.h dirent.h util.h
7538do :
7539 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7540ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
2018939f 7541if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
067d23c9
KY
7542 cat >>confdefs.h <<_ACEOF
7543#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7544_ACEOF
7545
7546fi
7547
7548done
7549
7550
7551{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
7552$as_echo_n "checking if personality LINUX32 can be set... " >&6; }
7553cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7554/* end confdefs.h. */
7555#include <sys/personality.h>
7556int
7557main ()
7558{
7559personality (PER_LINUX32)
7560 ;
7561 return 0;
7562}
7563_ACEOF
7564if ac_fn_c_try_compile "$LINENO"; then :
7565 emacs_cv_personality_linux32=yes
7566else
7567 emacs_cv_personality_linux32=no
7568fi
7569rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7570{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
7571$as_echo "$emacs_cv_personality_linux32" >&6; }
7572
7573if test $emacs_cv_personality_linux32 = yes; then
7574
7575$as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
7576
7577fi
7578
7579for ac_header in term.h
7580do :
7581 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
d6974efa 7582if test "x$ac_cv_header_term_h" = xyes; then :
067d23c9
KY
7583 cat >>confdefs.h <<_ACEOF
7584#define HAVE_TERM_H 1
7585_ACEOF
7586
7587fi
7588
7589done
7590
7591{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
7592$as_echo_n "checking for ANSI C header files... " >&6; }
d6974efa 7593if ${ac_cv_header_stdc+:} false; then :
067d23c9
KY
7594 $as_echo_n "(cached) " >&6
7595else
7596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7597/* end confdefs.h. */
7598#include <stdlib.h>
7599#include <stdarg.h>
7600#include <string.h>
7601#include <float.h>
7602
7603int
7604main ()
7605{
7606
7607 ;
7608 return 0;
7609}
7610_ACEOF
7611if ac_fn_c_try_compile "$LINENO"; then :
7612 ac_cv_header_stdc=yes
7613else
7614 ac_cv_header_stdc=no
7615fi
7616rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7617
7618if test $ac_cv_header_stdc = yes; then
7619 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7620 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7621/* end confdefs.h. */
7622#include <string.h>
7623
7624_ACEOF
7625if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7626 $EGREP "memchr" >/dev/null 2>&1; then :
7627
7628else
7629 ac_cv_header_stdc=no
7630fi
7631rm -f conftest*
7632
7633fi
7634
7635if test $ac_cv_header_stdc = yes; then
7636 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7637 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7638/* end confdefs.h. */
7639#include <stdlib.h>
7640
7641_ACEOF
7642if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7643 $EGREP "free" >/dev/null 2>&1; then :
7644
7645else
7646 ac_cv_header_stdc=no
7647fi
7648rm -f conftest*
7649
7650fi
7651
7652if test $ac_cv_header_stdc = yes; then
7653 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7654 if test "$cross_compiling" = yes; then :
7655 :
7656else
7657 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7658/* end confdefs.h. */
7659#include <ctype.h>
7660#include <stdlib.h>
7661#if ((' ' & 0x0FF) == 0x020)
7662# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
7663# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
7664#else
7665# define ISLOWER(c) \
7666 (('a' <= (c) && (c) <= 'i') \
7667 || ('j' <= (c) && (c) <= 'r') \
7668 || ('s' <= (c) && (c) <= 'z'))
7669# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
7670#endif
7671
7672#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
7673int
7674main ()
7675{
7676 int i;
7677 for (i = 0; i < 256; i++)
7678 if (XOR (islower (i), ISLOWER (i))
7679 || toupper (i) != TOUPPER (i))
7680 return 2;
7681 return 0;
7682}
7683_ACEOF
7684if ac_fn_c_try_run "$LINENO"; then :
7685
7686else
7687 ac_cv_header_stdc=no
7688fi
7689rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7690 conftest.$ac_objext conftest.beam conftest.$ac_ext
7691fi
7692
7693fi
7694fi
7695{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
7696$as_echo "$ac_cv_header_stdc" >&6; }
7697if test $ac_cv_header_stdc = yes; then
7698
7699$as_echo "#define STDC_HEADERS 1" >>confdefs.h
7700
7701fi
7702
7703{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
7704$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
d6974efa 7705if ${ac_cv_header_time+:} false; then :
067d23c9
KY
7706 $as_echo_n "(cached) " >&6
7707else
7708 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7709/* end confdefs.h. */
7710#include <sys/types.h>
7711#include <sys/time.h>
7712#include <time.h>
7713
7714int
7715main ()
7716{
7717if ((struct tm *) 0)
7718return 0;
7719 ;
7720 return 0;
7721}
7722_ACEOF
7723if ac_fn_c_try_compile "$LINENO"; then :
7724 ac_cv_header_time=yes
7725else
7726 ac_cv_header_time=no
7727fi
7728rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7729fi
7730{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
7731$as_echo "$ac_cv_header_time" >&6; }
7732if test $ac_cv_header_time = yes; then
7733
7734$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
7735
7736fi
7737
7738ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "$ac_includes_default"
d6974efa 7739if test "x$ac_cv_have_decl_sys_siglist" = xyes; then :
067d23c9
KY
7740 ac_have_decl=1
7741else
7742 ac_have_decl=0
7743fi
7744
7745cat >>confdefs.h <<_ACEOF
7746#define HAVE_DECL_SYS_SIGLIST $ac_have_decl
7747_ACEOF
7748
7749if test $ac_cv_have_decl_sys_siglist != yes; then
7750 # For Tru64, at least:
7751 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "$ac_includes_default"
d6974efa 7752if test "x$ac_cv_have_decl___sys_siglist" = xyes; then :
067d23c9
KY
7753 ac_have_decl=1
7754else
7755 ac_have_decl=0
7756fi
7757
7758cat >>confdefs.h <<_ACEOF
7759#define HAVE_DECL___SYS_SIGLIST $ac_have_decl
7760_ACEOF
7761
7762 if test $ac_cv_have_decl___sys_siglist = yes; then
7763
7764$as_echo "#define sys_siglist __sys_siglist" >>confdefs.h
7765
7766 fi
7767fi
7768{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
7769$as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
d6974efa 7770if ${ac_cv_header_sys_wait_h+:} false; then :
067d23c9
KY
7771 $as_echo_n "(cached) " >&6
7772else
7773 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7774/* end confdefs.h. */
7775#include <sys/types.h>
7776#include <sys/wait.h>
7777#ifndef WEXITSTATUS
7778# define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
7779#endif
7780#ifndef WIFEXITED
7781# define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
7782#endif
7783
7784int
7785main ()
7786{
7787 int s;
7788 wait (&s);
7789 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
7790 ;
7791 return 0;
7792}
7793_ACEOF
7794if ac_fn_c_try_compile "$LINENO"; then :
7795 ac_cv_header_sys_wait_h=yes
7796else
7797 ac_cv_header_sys_wait_h=no
7798fi
7799rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7800fi
7801{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
7802$as_echo "$ac_cv_header_sys_wait_h" >&6; }
7803if test $ac_cv_header_sys_wait_h = yes; then
7804
7805$as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
7806
7807fi
7808
7809
7810{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
7811$as_echo_n "checking for struct utimbuf... " >&6; }
d6974efa 7812if ${emacs_cv_struct_utimbuf+:} false; then :
067d23c9
KY
7813 $as_echo_n "(cached) " >&6
7814else
7815 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7816/* end confdefs.h. */
7817#ifdef TIME_WITH_SYS_TIME
7818#include <sys/time.h>
7819#include <time.h>
7820#else
7821#ifdef HAVE_SYS_TIME_H
7822#include <sys/time.h>
7823#else
7824#include <time.h>
7825#endif
7826#endif
7827#ifdef HAVE_UTIME_H
7828#include <utime.h>
7829#endif
7830int
7831main ()
7832{
7833static struct utimbuf x; x.actime = x.modtime;
7834 ;
7835 return 0;
7836}
7837_ACEOF
7838if ac_fn_c_try_compile "$LINENO"; then :
7839 emacs_cv_struct_utimbuf=yes
7840else
7841 emacs_cv_struct_utimbuf=no
7842fi
7843rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7844fi
7845{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_utimbuf" >&5
7846$as_echo "$emacs_cv_struct_utimbuf" >&6; }
7847if test $emacs_cv_struct_utimbuf = yes; then
7848
7849$as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
7850
7851fi
7852
7853{ $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
7854$as_echo_n "checking return type of signal handlers... " >&6; }
d6974efa 7855if ${ac_cv_type_signal+:} false; then :
067d23c9
KY
7856 $as_echo_n "(cached) " >&6
7857else
7858 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7859/* end confdefs.h. */
7860#include <sys/types.h>
7861#include <signal.h>
7862
7863int
7864main ()
7865{
7866return *(signal (0, 0)) (0) == 1;
7867 ;
7868 return 0;
7869}
7870_ACEOF
7871if ac_fn_c_try_compile "$LINENO"; then :
7872 ac_cv_type_signal=int
7873else
7874 ac_cv_type_signal=void
7875fi
7876rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7877fi
7878{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
7879$as_echo "$ac_cv_type_signal" >&6; }
7880
7881cat >>confdefs.h <<_ACEOF
7882#define RETSIGTYPE $ac_cv_type_signal
7883_ACEOF
7884
7885
7886
7887{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t" >&5
7888$as_echo_n "checking for speed_t... " >&6; }
d6974efa 7889if ${emacs_cv_speed_t+:} false; then :
067d23c9
KY
7890 $as_echo_n "(cached) " >&6
7891else
7892 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7893/* end confdefs.h. */
7894#include <termios.h>
7895int
7896main ()
7897{
7898speed_t x = 1;
7899 ;
7900 return 0;
7901}
7902_ACEOF
7903if ac_fn_c_try_compile "$LINENO"; then :
7904 emacs_cv_speed_t=yes
7905else
7906 emacs_cv_speed_t=no
7907fi
7908rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7909fi
7910{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_speed_t" >&5
7911$as_echo "$emacs_cv_speed_t" >&6; }
7912if test $emacs_cv_speed_t = yes; then
7913
7914$as_echo "#define HAVE_SPEED_T 1" >>confdefs.h
7915
7916fi
7917
7918{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
7919$as_echo_n "checking for struct timeval... " >&6; }
d6974efa 7920if ${emacs_cv_struct_timeval+:} false; then :
067d23c9
KY
7921 $as_echo_n "(cached) " >&6
7922else
7923 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7924/* end confdefs.h. */
7925#ifdef TIME_WITH_SYS_TIME
7926#include <sys/time.h>
7927#include <time.h>
7928#else
7929#ifdef HAVE_SYS_TIME_H
7930#include <sys/time.h>
7931#else
7932#include <time.h>
7933#endif
7934#endif
7935int
7936main ()
7937{
7938static struct timeval x; x.tv_sec = x.tv_usec;
7939 ;
7940 return 0;
7941}
7942_ACEOF
7943if ac_fn_c_try_compile "$LINENO"; then :
7944 emacs_cv_struct_timeval=yes
7945else
7946 emacs_cv_struct_timeval=no
7947fi
7948rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7949fi
7950{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_timeval" >&5
7951$as_echo "$emacs_cv_struct_timeval" >&6; }
7952HAVE_TIMEVAL=$emacs_cv_struct_timeval
7953if test $emacs_cv_struct_timeval = yes; then
7954
7955$as_echo "#define HAVE_TIMEVAL 1" >>confdefs.h
7956
7957fi
7958
7959{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct exception" >&5
7960$as_echo_n "checking for struct exception... " >&6; }
d6974efa 7961if ${emacs_cv_struct_exception+:} false; then :
067d23c9
KY
7962 $as_echo_n "(cached) " >&6
7963else
7964 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7965/* end confdefs.h. */
7966#include <math.h>
7967int
7968main ()
7969{
7970static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
7971 ;
7972 return 0;
7973}
7974_ACEOF
7975if ac_fn_c_try_compile "$LINENO"; then :
7976 emacs_cv_struct_exception=yes
7977else
7978 emacs_cv_struct_exception=no
7979fi
7980rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7981fi
7982{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_exception" >&5
7983$as_echo "$emacs_cv_struct_exception" >&6; }
7984HAVE_EXCEPTION=$emacs_cv_struct_exception
7985if test $emacs_cv_struct_exception != yes; then
7986
7987$as_echo "#define NO_MATHERR 1" >>confdefs.h
7988
7989fi
7990
7991for ac_header in sys/socket.h
7992do :
7993 ac_fn_c_check_header_mongrel "$LINENO" "sys/socket.h" "ac_cv_header_sys_socket_h" "$ac_includes_default"
d6974efa 7994if test "x$ac_cv_header_sys_socket_h" = xyes; then :
067d23c9
KY
7995 cat >>confdefs.h <<_ACEOF
7996#define HAVE_SYS_SOCKET_H 1
7997_ACEOF
7998
7999fi
8000
8001done
8002
8003for ac_header in net/if.h
8004do :
8005 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
8006#if HAVE_SYS_SOCKET_H
8007#include <sys/socket.h>
8008#endif
8009"
d6974efa 8010if test "x$ac_cv_header_net_if_h" = xyes; then :
067d23c9
KY
8011 cat >>confdefs.h <<_ACEOF
8012#define HAVE_NET_IF_H 1
8013_ACEOF
8014
8015fi
8016
8017done
8018
8019
8020{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
8021$as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
d6974efa 8022if ${ac_cv_struct_tm+:} false; then :
067d23c9
KY
8023 $as_echo_n "(cached) " >&6
8024else
8025 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8026/* end confdefs.h. */
8027#include <sys/types.h>
8028#include <time.h>
8029
8030int
8031main ()
8032{
8033struct tm tm;
8034 int *p = &tm.tm_sec;
8035 return !p;
8036 ;
8037 return 0;
8038}
8039_ACEOF
8040if ac_fn_c_try_compile "$LINENO"; then :
8041 ac_cv_struct_tm=time.h
8042else
8043 ac_cv_struct_tm=sys/time.h
8044fi
8045rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8046fi
8047{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
8048$as_echo "$ac_cv_struct_tm" >&6; }
8049if test $ac_cv_struct_tm = sys/time.h; then
8050
8051$as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
8052
8053fi
8054
8055ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
8056#include <$ac_cv_struct_tm>
8057
8058"
d6974efa 8059if test "x$ac_cv_member_struct_tm_tm_zone" = xyes; then :
067d23c9
KY
8060
8061cat >>confdefs.h <<_ACEOF
8062#define HAVE_STRUCT_TM_TM_ZONE 1
8063_ACEOF
8064
8065
8066fi
8067
8068if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
8069
8070$as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
8071
8072else
8073 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
8074"
d6974efa 8075if test "x$ac_cv_have_decl_tzname" = xyes; then :
067d23c9
KY
8076 ac_have_decl=1
8077else
8078 ac_have_decl=0
8079fi
8080
8081cat >>confdefs.h <<_ACEOF
8082#define HAVE_DECL_TZNAME $ac_have_decl
8083_ACEOF
8084
8085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
8086$as_echo_n "checking for tzname... " >&6; }
d6974efa 8087if ${ac_cv_var_tzname+:} false; then :
067d23c9
KY
8088 $as_echo_n "(cached) " >&6
8089else
8090 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8091/* end confdefs.h. */
8092#include <time.h>
8093#if !HAVE_DECL_TZNAME
8094extern char *tzname[];
8095#endif
8096
8097int
8098main ()
8099{
8100return tzname[0][0];
8101 ;
8102 return 0;
8103}
8104_ACEOF
8105if ac_fn_c_try_link "$LINENO"; then :
8106 ac_cv_var_tzname=yes
8107else
8108 ac_cv_var_tzname=no
8109fi
8110rm -f core conftest.err conftest.$ac_objext \
8111 conftest$ac_exeext conftest.$ac_ext
8112fi
8113{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
8114$as_echo "$ac_cv_var_tzname" >&6; }
8115 if test $ac_cv_var_tzname = yes; then
8116
8117$as_echo "#define HAVE_TZNAME 1" >>confdefs.h
8118
8119 fi
8120fi
8121
8122ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
8123"
d6974efa 8124if test "x$ac_cv_member_struct_tm_tm_gmtoff" = xyes; then :
067d23c9
KY
8125
8126$as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
8127
8128fi
8129
8130ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
8131#if HAVE_SYS_SOCKET_H
8132#include <sys/socket.h>
8133#endif
8134#if HAVE_NET_IF_H
8135#include <net/if.h>
8136#endif
8137"
d6974efa 8138if test "x$ac_cv_member_struct_ifreq_ifr_flags" = xyes; then :
067d23c9
KY
8139
8140cat >>confdefs.h <<_ACEOF
8141#define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
8142_ACEOF
8143
8144
8145fi
8146ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
8147#if HAVE_SYS_SOCKET_H
8148#include <sys/socket.h>
8149#endif
8150#if HAVE_NET_IF_H
8151#include <net/if.h>
8152#endif
8153"
d6974efa 8154if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = xyes; then :
067d23c9
KY
8155
8156cat >>confdefs.h <<_ACEOF
8157#define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
8158_ACEOF
8159
8160
8161fi
8162ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
8163#if HAVE_SYS_SOCKET_H
8164#include <sys/socket.h>
8165#endif
8166#if HAVE_NET_IF_H
8167#include <net/if.h>
8168#endif
8169"
d6974efa 8170if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = xyes; then :
067d23c9
KY
8171
8172cat >>confdefs.h <<_ACEOF
8173#define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
8174_ACEOF
8175
8176
8177fi
8178ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
8179#if HAVE_SYS_SOCKET_H
8180#include <sys/socket.h>
8181#endif
8182#if HAVE_NET_IF_H
8183#include <net/if.h>
8184#endif
8185"
d6974efa 8186if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = xyes; then :
067d23c9
KY
8187
8188cat >>confdefs.h <<_ACEOF
8189#define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
8190_ACEOF
8191
8192
8193fi
8194ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
8195#if HAVE_SYS_SOCKET_H
8196#include <sys/socket.h>
8197#endif
8198#if HAVE_NET_IF_H
8199#include <net/if.h>
8200#endif
8201"
d6974efa 8202if test "x$ac_cv_member_struct_ifreq_ifr_addr" = xyes; then :
067d23c9
KY
8203
8204cat >>confdefs.h <<_ACEOF
8205#define HAVE_STRUCT_IFREQ_IFR_ADDR 1
8206_ACEOF
8207
8208
8209fi
8210
8211
8212
8213{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for function prototypes" >&5
8214$as_echo_n "checking for function prototypes... " >&6; }
8215if test "$ac_cv_prog_cc_c89" != no; then
8216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8217$as_echo "yes" >&6; }
8218
8219$as_echo "#define PROTOTYPES 1" >>confdefs.h
8220
8221
8222$as_echo "#define __PROTOTYPES 1" >>confdefs.h
8223
8224else
8225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8226$as_echo "no" >&6; }
8227fi
8228
8229{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5
8230$as_echo_n "checking for working volatile... " >&6; }
d6974efa 8231if ${ac_cv_c_volatile+:} false; then :
067d23c9
KY
8232 $as_echo_n "(cached) " >&6
8233else
8234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8235/* end confdefs.h. */
8236
8237int
8238main ()
8239{
8240
8241volatile int x;
8242int * volatile y = (int *) 0;
8243return !x && !y;
8244 ;
8245 return 0;
8246}
8247_ACEOF
8248if ac_fn_c_try_compile "$LINENO"; then :
8249 ac_cv_c_volatile=yes
8250else
8251 ac_cv_c_volatile=no
8252fi
8253rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8254fi
8255{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5
8256$as_echo "$ac_cv_c_volatile" >&6; }
8257if test $ac_cv_c_volatile = no; then
8258
8259$as_echo "#define volatile /**/" >>confdefs.h
8260
8261fi
8262
8263{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
8264$as_echo_n "checking for an ANSI C-conforming const... " >&6; }
d6974efa 8265if ${ac_cv_c_const+:} false; then :
067d23c9
KY
8266 $as_echo_n "(cached) " >&6
8267else
8268 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8269/* end confdefs.h. */
8270
8271int
8272main ()
8273{
8274/* FIXME: Include the comments suggested by Paul. */
8275#ifndef __cplusplus
8276 /* Ultrix mips cc rejects this. */
8277 typedef int charset[2];
8278 const charset cs;
8279 /* SunOS 4.1.1 cc rejects this. */
8280 char const *const *pcpcc;
8281 char **ppc;
8282 /* NEC SVR4.0.2 mips cc rejects this. */
8283 struct point {int x, y;};
8284 static struct point const zero = {0,0};
8285 /* AIX XL C 1.02.0.0 rejects this.
8286 It does not let you subtract one const X* pointer from another in
8287 an arm of an if-expression whose if-part is not a constant
8288 expression */
8289 const char *g = "string";
8290 pcpcc = &g + (g ? g-g : 0);
8291 /* HPUX 7.0 cc rejects these. */
8292 ++pcpcc;
8293 ppc = (char**) pcpcc;
8294 pcpcc = (char const *const *) ppc;
8295 { /* SCO 3.2v4 cc rejects this. */
8296 char *t;
8297 char const *s = 0 ? (char *) 0 : (char const *) 0;
8298
8299 *t++ = 0;
8300 if (s) return 0;
8301 }
8302 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
8303 int x[] = {25, 17};
8304 const int *foo = &x[0];
8305 ++foo;
8306 }
8307 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
8308 typedef const int *iptr;
8309 iptr p = 0;
8310 ++p;
8311 }
8312 { /* AIX XL C 1.02.0.0 rejects this saying
8313 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
8314 struct s { int j; const int *ap[3]; };
8315 struct s *b; b->j = 5;
8316 }
8317 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
8318 const int foo = 10;
8319 if (!foo) return 0;
8320 }
8321 return !cs[0] && !zero.x;
8322#endif
8323
8324 ;
8325 return 0;
8326}
8327_ACEOF
8328if ac_fn_c_try_compile "$LINENO"; then :
8329 ac_cv_c_const=yes
8330else
8331 ac_cv_c_const=no
8332fi
8333rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8334fi
8335{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
8336$as_echo "$ac_cv_c_const" >&6; }
8337if test $ac_cv_c_const = no; then
8338
8339$as_echo "#define const /**/" >>confdefs.h
8340
8341fi
8342
8343{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for void * support" >&5
8344$as_echo_n "checking for void * support... " >&6; }
d6974efa 8345if ${emacs_cv_void_star+:} false; then :
067d23c9
KY
8346 $as_echo_n "(cached) " >&6
8347else
8348 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8349/* end confdefs.h. */
8350
8351int
8352main ()
8353{
8354void * foo;
8355 ;
8356 return 0;
8357}
8358_ACEOF
8359if ac_fn_c_try_compile "$LINENO"; then :
8360 emacs_cv_void_star=yes
8361else
8362 emacs_cv_void_star=no
8363fi
8364rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8365fi
8366{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_void_star" >&5
8367$as_echo "$emacs_cv_void_star" >&6; }
8368if test $emacs_cv_void_star = yes; then
8369 $as_echo "#define POINTER_TYPE void" >>confdefs.h
8370
8371else
8372 $as_echo "#define POINTER_TYPE char" >>confdefs.h
8373
8374fi
8375
8376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
8377$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
d6974efa 8378if ${ac_cv_c_bigendian+:} false; then :
067d23c9
KY
8379 $as_echo_n "(cached) " >&6
8380else
8381 ac_cv_c_bigendian=unknown
8382 # See if we're dealing with a universal compiler.
8383 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8384/* end confdefs.h. */
8385#ifndef __APPLE_CC__
8386 not a universal capable compiler
8387 #endif
8388 typedef int dummy;
8389
8390_ACEOF
8391if ac_fn_c_try_compile "$LINENO"; then :
8392
8393 # Check for potential -arch flags. It is not universal unless
8394 # there are at least two -arch flags with different values.
8395 ac_arch=
8396 ac_prev=
8397 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
8398 if test -n "$ac_prev"; then
8399 case $ac_word in
8400 i?86 | x86_64 | ppc | ppc64)
8401 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
8402 ac_arch=$ac_word
8403 else
8404 ac_cv_c_bigendian=universal
8405 break
8406 fi
8407 ;;
8408 esac
8409 ac_prev=
8410 elif test "x$ac_word" = "x-arch"; then
8411 ac_prev=arch
8412 fi
8413 done
8414fi
8415rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8416 if test $ac_cv_c_bigendian = unknown; then
8417 # See if sys/param.h defines the BYTE_ORDER macro.
8418 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8419/* end confdefs.h. */
8420#include <sys/types.h>
8421 #include <sys/param.h>
8422
8423int
8424main ()
8425{
8426#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
8427 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
8428 && LITTLE_ENDIAN)
8429 bogus endian macros
8430 #endif
8431
8432 ;
8433 return 0;
8434}
8435_ACEOF
8436if ac_fn_c_try_compile "$LINENO"; then :
8437 # It does; now see whether it defined to BIG_ENDIAN or not.
8438 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8439/* end confdefs.h. */
8440#include <sys/types.h>
8441 #include <sys/param.h>
8442
8443int
8444main ()
8445{
8446#if BYTE_ORDER != BIG_ENDIAN
8447 not big endian
8448 #endif
8449
8450 ;
8451 return 0;
8452}
8453_ACEOF
8454if ac_fn_c_try_compile "$LINENO"; then :
8455 ac_cv_c_bigendian=yes
8456else
8457 ac_cv_c_bigendian=no
8458fi
8459rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8460fi
8461rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8462 fi
8463 if test $ac_cv_c_bigendian = unknown; then
8464 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
8465 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8466/* end confdefs.h. */
8467#include <limits.h>
8468
8469int
8470main ()
8471{
8472#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
8473 bogus endian macros
8474 #endif
8475
8476 ;
8477 return 0;
8478}
8479_ACEOF
8480if ac_fn_c_try_compile "$LINENO"; then :
8481 # It does; now see whether it defined to _BIG_ENDIAN or not.
8482 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8483/* end confdefs.h. */
8484#include <limits.h>
8485
8486int
8487main ()
8488{
8489#ifndef _BIG_ENDIAN
8490 not big endian
8491 #endif
8492
8493 ;
8494 return 0;
8495}
8496_ACEOF
8497if ac_fn_c_try_compile "$LINENO"; then :
8498 ac_cv_c_bigendian=yes
8499else
8500 ac_cv_c_bigendian=no
8501fi
8502rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8503fi
8504rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8505 fi
8506 if test $ac_cv_c_bigendian = unknown; then
8507 # Compile a test program.
8508 if test "$cross_compiling" = yes; then :
8509 # Try to guess by grepping values from an object file.
8510 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8511/* end confdefs.h. */
8512short int ascii_mm[] =
8513 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
8514 short int ascii_ii[] =
8515 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
8516 int use_ascii (int i) {
8517 return ascii_mm[i] + ascii_ii[i];
8518 }
8519 short int ebcdic_ii[] =
8520 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
8521 short int ebcdic_mm[] =
8522 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
8523 int use_ebcdic (int i) {
8524 return ebcdic_mm[i] + ebcdic_ii[i];
8525 }
8526 extern int foo;
8527
8528int
8529main ()
8530{
8531return use_ascii (foo) == use_ebcdic (foo);
8532 ;
8533 return 0;
8534}
8535_ACEOF
8536if ac_fn_c_try_compile "$LINENO"; then :
8537 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
8538 ac_cv_c_bigendian=yes
8539 fi
8540 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
8541 if test "$ac_cv_c_bigendian" = unknown; then
8542 ac_cv_c_bigendian=no
8543 else
8544 # finding both strings is unlikely to happen, but who knows?
8545 ac_cv_c_bigendian=unknown
8546 fi
8547 fi
8548fi
8549rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8550else
8551 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8552/* end confdefs.h. */
8553$ac_includes_default
8554int
8555main ()
8556{
8557
8558 /* Are we little or big endian? From Harbison&Steele. */
8559 union
8560 {
8561 long int l;
8562 char c[sizeof (long int)];
8563 } u;
8564 u.l = 1;
8565 return u.c[sizeof (long int) - 1] == 1;
8566
8567 ;
8568 return 0;
8569}
8570_ACEOF
8571if ac_fn_c_try_run "$LINENO"; then :
8572 ac_cv_c_bigendian=no
8573else
8574 ac_cv_c_bigendian=yes
8575fi
8576rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8577 conftest.$ac_objext conftest.beam conftest.$ac_ext
8578fi
8579
8580 fi
8581fi
8582{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
8583$as_echo "$ac_cv_c_bigendian" >&6; }
8584 case $ac_cv_c_bigendian in #(
8585 yes)
8586 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
8587;; #(
8588 no)
8589 ;; #(
8590 universal)
8591
8592$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
8593
8594 ;; #(
8595 *)
2018939f 8596 as_fn_error $? "unknown endianness
d6974efa 8597 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
067d23c9
KY
8598 esac
8599
8600
7cae64b4
PE
8601{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __attribute__ ((__aligned__ (expr)))" >&5
8602$as_echo_n "checking for __attribute__ ((__aligned__ (expr)))... " >&6; }
d6974efa 8603if ${emacs_cv_attribute_aligned+:} false; then :
7cae64b4
PE
8604 $as_echo_n "(cached) " >&6
8605else
8606 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8607/* end confdefs.h. */
8608char __attribute__ ((__aligned__ (1 << 3))) c;
8609int
8610main ()
8611{
8612
8613 ;
8614 return 0;
8615}
8616_ACEOF
8617if ac_fn_c_try_compile "$LINENO"; then :
8618 emacs_cv_attribute_aligned=yes
8619else
8620 emacs_cv_attribute_aligned=no
8621fi
8622rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8623fi
8624{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_attribute_aligned" >&5
8625$as_echo "$emacs_cv_attribute_aligned" >&6; }
8626if test $emacs_cv_attribute_aligned = yes; then
8627
8628$as_echo "#define HAVE_ATTRIBUTE_ALIGNED 1" >>confdefs.h
8629
8630fi
8631
067d23c9
KY
8632{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
8633$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
8634set x ${MAKE-make}
8635ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
d6974efa 8636if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
067d23c9
KY
8637 $as_echo_n "(cached) " >&6
8638else
8639 cat >conftest.make <<\_ACEOF
8640SHELL = /bin/sh
8641all:
8642 @echo '@@@%%%=$(MAKE)=@@@%%%'
8643_ACEOF
2018939f 8644# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
067d23c9
KY
8645case `${MAKE-make} -f conftest.make 2>/dev/null` in
8646 *@@@%%%=?*=@@@%%%*)
8647 eval ac_cv_prog_make_${ac_make}_set=yes;;
8648 *)
8649 eval ac_cv_prog_make_${ac_make}_set=no;;
8650esac
8651rm -f conftest.make
8652fi
8653if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
8654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8655$as_echo "yes" >&6; }
8656 SET_MAKE=
8657else
8658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8659$as_echo "no" >&6; }
8660 SET_MAKE="MAKE=${MAKE-make}"
8661fi
8662
8663
8664DEPFLAGS=
8665MKDEPDIR=":"
8666deps_frag=deps.mk
8667if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
8668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
8669$as_echo_n "checking whether we are using GNU Make... " >&6; }
8670 HAVE_GNU_MAKE=no
8671 testval=`make --version 2>/dev/null | grep 'GNU Make'`
8672 if test "x$testval" != x; then
8673 HAVE_GNU_MAKE=yes
8674 else
8675 ac_enable_autodepend=no
8676 fi
8677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
8678$as_echo "$HAVE_GNU_MAKE" >&6; }
8679 if test $HAVE_GNU_MAKE = yes; then
8680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
8681$as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
8682 SAVE_CFLAGS="$CFLAGS"
8683 CFLAGS="$CFLAGS -MMD -MF deps.d"
8684 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8685/* end confdefs.h. */
8686
8687int
8688main ()
8689{
8690
8691 ;
8692 return 0;
8693}
8694_ACEOF
8695if ac_fn_c_try_compile "$LINENO"; then :
8696
8697else
8698 ac_enable_autodepend=no
8699fi
8700rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8701 CFLAGS="$SAVE_CFLAGS"
8702 test -f deps.d || ac_enable_autodepend=no
8703 rm -rf deps.d
8704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
8705$as_echo "$ac_enable_autodepend" >&6; }
8706 fi
8707 if test $ac_enable_autodepend = yes; then
8708 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d'
8709 ## In parallel builds, another make might create depdir between
8710 ## the first test and mkdir, so stick another test on the end.
8711 ## Or use mkinstalldirs? mkdir -p is not portable.
8712 MKDEPDIR='test -d ${DEPDIR} || mkdir ${DEPDIR} || test -d ${DEPDIR}'
8713 deps_frag=autodeps.mk
8714 fi
8715fi
8716deps_frag=$srcdir/src/$deps_frag
8717
8718
8719
8720
8721
8722{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
8723$as_echo_n "checking for long file names... " >&6; }
d6974efa 8724if ${ac_cv_sys_long_file_names+:} false; then :
067d23c9
KY
8725 $as_echo_n "(cached) " >&6
8726else
8727 ac_cv_sys_long_file_names=yes
8728# Test for long file names in all the places we know might matter:
8729# . the current directory, where building will happen
8730# $prefix/lib where we will be installing things
8731# $exec_prefix/lib likewise
8732# $TMPDIR if set, where it might want to write temporary files
8733# /tmp where it might want to write temporary files
8734# /var/tmp likewise
8735# /usr/tmp likewise
8736for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
8737 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
8738 # in the usual case where exec_prefix is '${prefix}'.
8739 case $ac_dir in #(
8740 . | /* | ?:[\\/]*) ;; #(
8741 *) continue;;
8742 esac
8743 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
8744 ac_xdir=$ac_dir/cf$$
8745 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
8746 ac_tf1=$ac_xdir/conftest9012345
8747 ac_tf2=$ac_xdir/conftest9012346
8748 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
8749 ac_cv_sys_long_file_names=no
8750 rm -f -r "$ac_xdir" 2>/dev/null
8751 test $ac_cv_sys_long_file_names = no && break
8752done
8753fi
8754{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
8755$as_echo "$ac_cv_sys_long_file_names" >&6; }
8756if test $ac_cv_sys_long_file_names = yes; then
8757
8758$as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
8759
8760fi
8761
8762
8763#### Choose a window system.
8764
8765{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
8766$as_echo_n "checking for X... " >&6; }
8767
8768
8769# Check whether --with-x was given.
8770if test "${with_x+set}" = set; then :
8771 withval=$with_x;
8772fi
8773
8774# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
8775if test "x$with_x" = xno; then
8776 # The user explicitly disabled X.
8777 have_x=disabled
8778else
8779 case $x_includes,$x_libraries in #(
d6974efa
PE
8780 *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #(
8781 *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then :
067d23c9
KY
8782 $as_echo_n "(cached) " >&6
8783else
8784 # One or both of the vars are not set, and there is no cached value.
8785ac_x_includes=no ac_x_libraries=no
8786rm -f -r conftest.dir
8787if mkdir conftest.dir; then
8788 cd conftest.dir
8789 cat >Imakefile <<'_ACEOF'
8790incroot:
8791 @echo incroot='${INCROOT}'
8792usrlibdir:
8793 @echo usrlibdir='${USRLIBDIR}'
8794libdir:
8795 @echo libdir='${LIBDIR}'
8796_ACEOF
8797 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
2018939f 8798 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
067d23c9
KY
8799 for ac_var in incroot usrlibdir libdir; do
8800 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
8801 done
8802 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
8803 for ac_extension in a so sl dylib la dll; do
8804 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
8805 test -f "$ac_im_libdir/libX11.$ac_extension"; then
8806 ac_im_usrlibdir=$ac_im_libdir; break
8807 fi
8808 done
8809 # Screen out bogus values from the imake configuration. They are
8810 # bogus both because they are the default anyway, and because
8811 # using them would break gcc on systems where it needs fixed includes.
8812 case $ac_im_incroot in
8813 /usr/include) ac_x_includes= ;;
8814 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
8815 esac
8816 case $ac_im_usrlibdir in
8817 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
8818 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
8819 esac
8820 fi
8821 cd ..
8822 rm -f -r conftest.dir
8823fi
8824
8825# Standard set of common directories for X headers.
8826# Check X11 before X11Rn because it is often a symlink to the current release.
8827ac_x_header_dirs='
8828/usr/X11/include
8829/usr/X11R7/include
8830/usr/X11R6/include
8831/usr/X11R5/include
8832/usr/X11R4/include
8833
8834/usr/include/X11
8835/usr/include/X11R7
8836/usr/include/X11R6
8837/usr/include/X11R5
8838/usr/include/X11R4
8839
8840/usr/local/X11/include
8841/usr/local/X11R7/include
8842/usr/local/X11R6/include
8843/usr/local/X11R5/include
8844/usr/local/X11R4/include
8845
8846/usr/local/include/X11
8847/usr/local/include/X11R7
8848/usr/local/include/X11R6
8849/usr/local/include/X11R5
8850/usr/local/include/X11R4
8851
8852/usr/X386/include
8853/usr/x386/include
8854/usr/XFree86/include/X11
8855
8856/usr/include
8857/usr/local/include
8858/usr/unsupported/include
8859/usr/athena/include
8860/usr/local/x11r5/include
8861/usr/lpp/Xamples/include
8862
8863/usr/openwin/include
8864/usr/openwin/share/include'
8865
8866if test "$ac_x_includes" = no; then
8867 # Guess where to find include files, by looking for Xlib.h.
8868 # First, try using that file with no special directory specified.
8869 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8870/* end confdefs.h. */
8871#include <X11/Xlib.h>
8872_ACEOF
8873if ac_fn_c_try_cpp "$LINENO"; then :
8874 # We can compile using X headers with no special include directory.
8875ac_x_includes=
8876else
8877 for ac_dir in $ac_x_header_dirs; do
8878 if test -r "$ac_dir/X11/Xlib.h"; then
8879 ac_x_includes=$ac_dir
8880 break
8881 fi
8882done
8883fi
2018939f 8884rm -f conftest.err conftest.i conftest.$ac_ext
067d23c9
KY
8885fi # $ac_x_includes = no
8886
8887if test "$ac_x_libraries" = no; then
8888 # Check for the libraries.
8889 # See if we find them without any special options.
8890 # Don't add to $LIBS permanently.
8891 ac_save_LIBS=$LIBS
8892 LIBS="-lX11 $LIBS"
8893 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8894/* end confdefs.h. */
8895#include <X11/Xlib.h>
8896int
8897main ()
8898{
8899XrmInitialize ()
8900 ;
8901 return 0;
8902}
8903_ACEOF
8904if ac_fn_c_try_link "$LINENO"; then :
8905 LIBS=$ac_save_LIBS
8906# We can link X programs with no special library path.
8907ac_x_libraries=
8908else
8909 LIBS=$ac_save_LIBS
8910for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
8911do
8912 # Don't even attempt the hair of trying to link an X program!
8913 for ac_extension in a so sl dylib la dll; do
8914 if test -r "$ac_dir/libX11.$ac_extension"; then
8915 ac_x_libraries=$ac_dir
8916 break 2
8917 fi
8918 done
8919done
8920fi
8921rm -f core conftest.err conftest.$ac_objext \
8922 conftest$ac_exeext conftest.$ac_ext
8923fi # $ac_x_libraries = no
8924
8925case $ac_x_includes,$ac_x_libraries in #(
8926 no,* | *,no | *\'*)
8927 # Didn't find X, or a directory has "'" in its name.
8928 ac_cv_have_x="have_x=no";; #(
8929 *)
8930 # Record where we found X for the cache.
8931 ac_cv_have_x="have_x=yes\
8932 ac_x_includes='$ac_x_includes'\
8933 ac_x_libraries='$ac_x_libraries'"
8934esac
8935fi
8936;; #(
8937 *) have_x=yes;;
8938 esac
8939 eval "$ac_cv_have_x"
8940fi # $with_x != no
8941
8942if test "$have_x" != yes; then
8943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
8944$as_echo "$have_x" >&6; }
8945 no_x=yes
8946else
8947 # If each of the values was on the command line, it overrides each guess.
8948 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
8949 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
8950 # Update the cache value to reflect the command line values.
8951 ac_cv_have_x="have_x=yes\
8952 ac_x_includes='$x_includes'\
8953 ac_x_libraries='$x_libraries'"
8954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
8955$as_echo "libraries $x_libraries, headers $x_includes" >&6; }
8956fi
8957
8958if test "$no_x" = yes; then
8959 window_system=none
8960else
8961 window_system=x11
8962fi
8963
8964## Workaround for bug in autoconf <= 2.62.
8965## http://lists.gnu.org/archive/html/emacs-devel/2008-04/msg01551.html
8966## No need to do anything special for these standard directories.
8967if test -n "${x_libraries}" && test x"${x_libraries}" != xNONE; then
8968
8969 x_libraries=`echo :${x_libraries}: | sed -e 's|:/usr/lib64:|:|g' -e 's|:/lib64:|:|g' -e 's|^:||' -e 's|:$||'`
8970
8971fi
8972
8973LD_SWITCH_X_SITE_AUX=
8974LD_SWITCH_X_SITE_AUX_RPATH=
8975if test "${x_libraries}" != NONE; then
8976 if test -n "${x_libraries}"; then
8977 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
8978 LD_SWITCH_X_SITE_AUX=-R`echo ${x_libraries} | sed -e "s/:/ -R/g"`
8979 LD_SWITCH_X_SITE_AUX_RPATH=`echo ${LD_SWITCH_X_SITE_AUX} | sed -e 's/-R/-Wl,-rpath,/'`
8980 fi
8981 x_default_search_path=""
8982 x_search_path=${x_libraries}
8983 if test -z "${x_search_path}"; then
8984 x_search_path=/usr/lib
8985 fi
8986 for x_library in `echo ${x_search_path}: | \
8987 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
8988 x_search_path="\
8989${x_library}/X11/%L/%T/%N%C%S:\
8990${x_library}/X11/%l/%T/%N%C%S:\
8991${x_library}/X11/%T/%N%C%S:\
8992${x_library}/X11/%L/%T/%N%S:\
8993${x_library}/X11/%l/%T/%N%S:\
8994${x_library}/X11/%T/%N%S"
8995 if test x"${x_default_search_path}" = x; then
8996 x_default_search_path=${x_search_path}
8997 else
8998 x_default_search_path="${x_search_path}:${x_default_search_path}"
8999 fi
9000 done
9001fi
9002
9003
9004
9005if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9006 C_SWITCH_X_SITE=-I`echo ${x_includes} | sed -e "s/:/ -I/g"`
9007fi
9008
9009if test x"${x_includes}" = x; then
9010 bitmapdir=/usr/include/X11/bitmaps
9011else
9012 # accumulate include directories that have X11 bitmap subdirectories
9013 bmd_acc="dummyval"
9014 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9015 if test -d "${bmd}/X11/bitmaps"; then
9016 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9017 fi
9018 if test -d "${bmd}/bitmaps"; then
9019 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9020 fi
9021 done
9022 if test ${bmd_acc} != "dummyval"; then
9023 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9024 fi
9025fi
9026
9027HAVE_NS=no
9028NS_IMPL_COCOA=no
9029NS_IMPL_GNUSTEP=no
9030tmp_CPPFLAGS="$CPPFLAGS"
9031tmp_CFLAGS="$CFLAGS"
9032CPPFLAGS="$CPPFLAGS -x objective-c"
9033CFLAGS="$CFLAGS -x objective-c"
9034TEMACS_LDFLAGS2="\${LDFLAGS}"
9035if test "${with_ns}" != no; then
9036 if test "${opsys}" = darwin; then
9037 NS_IMPL_COCOA=yes
9038 ns_appdir=`pwd`/nextstep/Emacs.app
9039 ns_appbindir=${ns_appdir}/Contents/MacOS/
9040 ns_appresdir=${ns_appdir}/Contents/Resources
9041 ns_appsrc=${srcdir}/nextstep/Cocoa/Emacs.base
9042 elif test -f $GNUSTEP_CONFIG_FILE; then
9043 NS_IMPL_GNUSTEP=yes
9044 ns_appdir=`pwd`/nextstep/Emacs.app
9045 ns_appbindir=${ns_appdir}/
9046 ns_appresdir=${ns_appdir}/Resources
9047 ns_appsrc=${srcdir}/nextstep/GNUstep/Emacs.base
9048 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
9049 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
9050 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
9051 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
9052 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
9053 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
9054 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
9055 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
9056 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9057 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9058 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
9059 LIB_STANDARD=
9060 START_FILES=
9061 TEMACS_LDFLAGS2=
9062 fi
9063 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
d6974efa 9064if test "x$ac_cv_header_AppKit_AppKit_h" = xyes; then :
067d23c9
KY
9065 HAVE_NS=yes
9066else
2018939f 9067 as_fn_error $? "\`--with-ns' was specified, but the include
067d23c9
KY
9068 files are missing or cannot be compiled." "$LINENO" 5
9069fi
9070
9071
9072 NS_HAVE_NSINTEGER=yes
9073 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9074/* end confdefs.h. */
9075#include <Foundation/NSObjCRuntime.h>
9076int
9077main ()
9078{
9079NSInteger i;
9080 ;
9081 return 0;
9082}
9083_ACEOF
9084if ac_fn_c_try_compile "$LINENO"; then :
9085 ns_have_nsinteger=yes
9086else
9087 ns_have_nsinteger=no
9088fi
9089rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9090 if test $ns_have_nsinteger = no; then
9091 NS_HAVE_NSINTEGER=no
9092 fi
9093fi
9094
9095
9096ns_frag=/dev/null
9097NS_OBJ=
00b3c7ac 9098NS_OBJC_OBJ=
067d23c9
KY
9099NS_SUPPORT=
9100if test "${HAVE_NS}" = yes; then
9101 window_system=nextstep
9102 with_xft=no
9103 # set up packaging dirs
9104 exec_prefix=${ns_appbindir}
9105 libexecdir=${ns_appbindir}/libexec
9106 if test "${EN_NS_SELF_CONTAINED}" = yes; then
9107 prefix=${ns_appresdir}
9108 fi
9109 ns_frag=$srcdir/src/ns.mk
00b3c7ac
TT
9110 NS_OBJ="fontset.o fringe.o image.o"
9111 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o"
067d23c9
KY
9112 NS_SUPPORT="\${lispsource}/emacs-lisp/easymenu.elc \${lispsource}/term/ns-win.elc"
9113fi
9114CFLAGS="$tmp_CFLAGS"
9115CPPFLAGS="$tmp_CPPFLAGS"
9116
9117
9118
9119
9120
00b3c7ac 9121
067d23c9
KY
9122case "${window_system}" in
9123 x11 )
9124 HAVE_X_WINDOWS=yes
9125 HAVE_X11=yes
9126 case "${with_x_toolkit}" in
9127 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
9128 motif ) USE_X_TOOLKIT=MOTIF ;;
9129 gtk ) with_gtk=yes
9130 USE_X_TOOLKIT=none ;;
9131 gtk3 ) with_gtk3=yes
9132 USE_X_TOOLKIT=none ;;
9133 no ) USE_X_TOOLKIT=none ;;
9134 * ) USE_X_TOOLKIT=maybe ;;
9135 esac
9136 ;;
9137 nextstep | none )
9138 HAVE_X_WINDOWS=no
9139 HAVE_X11=no
9140 USE_X_TOOLKIT=none
9141 ;;
9142esac
9143
9144if test "$window_system" = none && test "X$with_x" != "Xno"; then
9145 # Extract the first word of "X", so it can be a program name with args.
9146set dummy X; ac_word=$2
9147{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9148$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 9149if ${ac_cv_prog_HAVE_XSERVER+:} false; then :
067d23c9
KY
9150 $as_echo_n "(cached) " >&6
9151else
9152 if test -n "$HAVE_XSERVER"; then
9153 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
9154else
9155as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9156for as_dir in $PATH
9157do
9158 IFS=$as_save_IFS
9159 test -z "$as_dir" && as_dir=.
9160 for ac_exec_ext in '' $ac_executable_extensions; do
9161 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9162 ac_cv_prog_HAVE_XSERVER="true"
9163 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9164 break 2
9165 fi
9166done
9167 done
9168IFS=$as_save_IFS
9169
9170 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
9171fi
9172fi
9173HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
9174if test -n "$HAVE_XSERVER"; then
9175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
9176$as_echo "$HAVE_XSERVER" >&6; }
9177else
9178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9179$as_echo "no" >&6; }
9180fi
9181
9182
9183 if test "$HAVE_XSERVER" = true ||
9184 test -n "$DISPLAY" ||
9185 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
2018939f 9186 as_fn_error $? "You seem to be running X, but no X development libraries
067d23c9
KY
9187were found. You should install the relevant development files for X
9188and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
9189sure you have development files for image handling, i.e.
9190tiff, gif, jpeg, png and xpm.
9191If you are sure you want Emacs compiled without X window support, pass
9192 --without-x
9193to configure." "$LINENO" 5
9194 fi
9195fi
9196
9197### If we're using X11, we should use the X menu package.
9198HAVE_MENUS=no
9199case ${HAVE_X11} in
9200 yes ) HAVE_MENUS=yes ;;
9201esac
9202
9203# Do the opsystem or machine files prohibit the use of the GNU malloc?
9204# Assume not, until told otherwise.
9205GNU_MALLOC=yes
9206doug_lea_malloc=yes
9207ac_fn_c_check_func "$LINENO" "malloc_get_state" "ac_cv_func_malloc_get_state"
d6974efa 9208if test "x$ac_cv_func_malloc_get_state" = xyes; then :
067d23c9
KY
9209
9210else
9211 doug_lea_malloc=no
9212fi
9213
9214ac_fn_c_check_func "$LINENO" "malloc_set_state" "ac_cv_func_malloc_set_state"
d6974efa 9215if test "x$ac_cv_func_malloc_set_state" = xyes; then :
067d23c9
KY
9216
9217else
9218 doug_lea_malloc=no
9219fi
9220
9221{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __after_morecore_hook exists" >&5
9222$as_echo_n "checking whether __after_morecore_hook exists... " >&6; }
d6974efa 9223if ${emacs_cv_var___after_morecore_hook+:} false; then :
067d23c9
KY
9224 $as_echo_n "(cached) " >&6
9225else
9226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9227/* end confdefs.h. */
9228extern void (* __after_morecore_hook)();
9229int
9230main ()
9231{
9232__after_morecore_hook = 0
9233 ;
9234 return 0;
9235}
9236_ACEOF
9237if ac_fn_c_try_link "$LINENO"; then :
9238 emacs_cv_var___after_morecore_hook=yes
9239else
9240 emacs_cv_var___after_morecore_hook=no
9241fi
9242rm -f core conftest.err conftest.$ac_objext \
9243 conftest$ac_exeext conftest.$ac_ext
9244fi
9245{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var___after_morecore_hook" >&5
9246$as_echo "$emacs_cv_var___after_morecore_hook" >&6; }
9247if test $emacs_cv_var___after_morecore_hook = no; then
9248 doug_lea_malloc=no
9249fi
9250
9251
9252system_malloc=no
9253case "$opsys" in
9254 ## darwin ld insists on the use of malloc routines in the System framework.
9255 darwin|sol2-10) system_malloc=yes ;;
9256esac
9257
9258if test "${system_malloc}" = "yes"; then
9259
9260$as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
9261
9262 GNU_MALLOC=no
9263 GNU_MALLOC_reason="
9264 (The GNU allocators don't work with this system configuration.)"
9265 GMALLOC_OBJ=
9266 VMLIMIT_OBJ=
9267else
9268 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
9269 VMLIMIT_OBJ=vm-limit.o
9270fi
9271
9272
9273
9274if test "$doug_lea_malloc" = "yes" ; then
9275 if test "$GNU_MALLOC" = yes ; then
9276 GNU_MALLOC_reason="
9277 (Using Doug Lea's new malloc from the GNU C Library.)"
9278 fi
9279
9280$as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
9281
9282
9283 ## Use mmap directly for allocating larger buffers.
9284 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
9285 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
9286 ## Does the AC_FUNC_MMAP test below make this check unecessary?
9287 case "$opsys" in
9288 gnu*) REL_ALLOC=no ;;
9289 esac
9290fi
9291
9292if test x"${REL_ALLOC}" = x; then
9293 REL_ALLOC=${GNU_MALLOC}
9294fi
9295
9296use_mmap_for_buffers=no
9297case "$opsys" in
9298 freebsd|irix6-5) use_mmap_for_buffers=yes ;;
9299esac
9300
9301
9302
9303
9304 for ac_header in $ac_header_list
9305do :
9306 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9307ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
9308"
2018939f 9309if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
067d23c9
KY
9310 cat >>confdefs.h <<_ACEOF
9311#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9312_ACEOF
9313
9314fi
9315
9316done
9317
9318
9319
9320
9321
9322
9323
9324
9325for ac_func in getpagesize
9326do :
9327 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
d6974efa 9328if test "x$ac_cv_func_getpagesize" = xyes; then :
067d23c9
KY
9329 cat >>confdefs.h <<_ACEOF
9330#define HAVE_GETPAGESIZE 1
9331_ACEOF
9332
9333fi
9334done
9335
9336{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
9337$as_echo_n "checking for working mmap... " >&6; }
d6974efa 9338if ${ac_cv_func_mmap_fixed_mapped+:} false; then :
067d23c9
KY
9339 $as_echo_n "(cached) " >&6
9340else
9341 if test "$cross_compiling" = yes; then :
9342 ac_cv_func_mmap_fixed_mapped=no
9343else
9344 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9345/* end confdefs.h. */
9346$ac_includes_default
9347/* malloc might have been renamed as rpl_malloc. */
9348#undef malloc
9349
9350/* Thanks to Mike Haertel and Jim Avera for this test.
9351 Here is a matrix of mmap possibilities:
9352 mmap private not fixed
9353 mmap private fixed at somewhere currently unmapped
9354 mmap private fixed at somewhere already mapped
9355 mmap shared not fixed
9356 mmap shared fixed at somewhere currently unmapped
9357 mmap shared fixed at somewhere already mapped
9358 For private mappings, we should verify that changes cannot be read()
9359 back from the file, nor mmap's back from the file at a different
9360 address. (There have been systems where private was not correctly
9361 implemented like the infamous i386 svr4.0, and systems where the
9362 VM page cache was not coherent with the file system buffer cache
9363 like early versions of FreeBSD and possibly contemporary NetBSD.)
9364 For shared mappings, we should conversely verify that changes get
9365 propagated back to all the places they're supposed to be.
9366
9367 Grep wants private fixed already mapped.
9368 The main things grep needs to know about mmap are:
9369 * does it exist and is it safe to write into the mmap'd area
9370 * how to use it (BSD variants) */
9371
9372#include <fcntl.h>
9373#include <sys/mman.h>
9374
9375#if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
9376char *malloc ();
9377#endif
9378
9379/* This mess was copied from the GNU getpagesize.h. */
9380#ifndef HAVE_GETPAGESIZE
9381# ifdef _SC_PAGESIZE
9382# define getpagesize() sysconf(_SC_PAGESIZE)
9383# else /* no _SC_PAGESIZE */
9384# ifdef HAVE_SYS_PARAM_H
9385# include <sys/param.h>
9386# ifdef EXEC_PAGESIZE
9387# define getpagesize() EXEC_PAGESIZE
9388# else /* no EXEC_PAGESIZE */
9389# ifdef NBPG
9390# define getpagesize() NBPG * CLSIZE
9391# ifndef CLSIZE
9392# define CLSIZE 1
9393# endif /* no CLSIZE */
9394# else /* no NBPG */
9395# ifdef NBPC
9396# define getpagesize() NBPC
9397# else /* no NBPC */
9398# ifdef PAGESIZE
9399# define getpagesize() PAGESIZE
9400# endif /* PAGESIZE */
9401# endif /* no NBPC */
9402# endif /* no NBPG */
9403# endif /* no EXEC_PAGESIZE */
9404# else /* no HAVE_SYS_PARAM_H */
9405# define getpagesize() 8192 /* punt totally */
9406# endif /* no HAVE_SYS_PARAM_H */
9407# endif /* no _SC_PAGESIZE */
9408
9409#endif /* no HAVE_GETPAGESIZE */
9410
9411int
9412main ()
9413{
9414 char *data, *data2, *data3;
2018939f 9415 const char *cdata2;
067d23c9
KY
9416 int i, pagesize;
9417 int fd, fd2;
9418
9419 pagesize = getpagesize ();
9420
9421 /* First, make a file with some known garbage in it. */
9422 data = (char *) malloc (pagesize);
9423 if (!data)
9424 return 1;
9425 for (i = 0; i < pagesize; ++i)
9426 *(data + i) = rand ();
9427 umask (0);
9428 fd = creat ("conftest.mmap", 0600);
9429 if (fd < 0)
9430 return 2;
9431 if (write (fd, data, pagesize) != pagesize)
9432 return 3;
9433 close (fd);
9434
9435 /* Next, check that the tail of a page is zero-filled. File must have
9436 non-zero length, otherwise we risk SIGBUS for entire page. */
9437 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
9438 if (fd2 < 0)
9439 return 4;
2018939f
AS
9440 cdata2 = "";
9441 if (write (fd2, cdata2, 1) != 1)
067d23c9 9442 return 5;
2018939f 9443 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
067d23c9
KY
9444 if (data2 == MAP_FAILED)
9445 return 6;
9446 for (i = 0; i < pagesize; ++i)
9447 if (*(data2 + i))
9448 return 7;
9449 close (fd2);
9450 if (munmap (data2, pagesize))
9451 return 8;
9452
9453 /* Next, try to mmap the file at a fixed address which already has
9454 something else allocated at it. If we can, also make sure that
9455 we see the same garbage. */
9456 fd = open ("conftest.mmap", O_RDWR);
9457 if (fd < 0)
9458 return 9;
9459 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
9460 MAP_PRIVATE | MAP_FIXED, fd, 0L))
9461 return 10;
9462 for (i = 0; i < pagesize; ++i)
9463 if (*(data + i) != *(data2 + i))
9464 return 11;
9465
9466 /* Finally, make sure that changes to the mapped area do not
9467 percolate back to the file as seen by read(). (This is a bug on
9468 some variants of i386 svr4.0.) */
9469 for (i = 0; i < pagesize; ++i)
9470 *(data2 + i) = *(data2 + i) + 1;
9471 data3 = (char *) malloc (pagesize);
9472 if (!data3)
9473 return 12;
9474 if (read (fd, data3, pagesize) != pagesize)
9475 return 13;
9476 for (i = 0; i < pagesize; ++i)
9477 if (*(data + i) != *(data3 + i))
9478 return 14;
9479 close (fd);
9480 return 0;
9481}
9482_ACEOF
9483if ac_fn_c_try_run "$LINENO"; then :
9484 ac_cv_func_mmap_fixed_mapped=yes
9485else
9486 ac_cv_func_mmap_fixed_mapped=no
9487fi
9488rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9489 conftest.$ac_objext conftest.beam conftest.$ac_ext
9490fi
9491
9492fi
9493{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
9494$as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
9495if test $ac_cv_func_mmap_fixed_mapped = yes; then
9496
9497$as_echo "#define HAVE_MMAP 1" >>confdefs.h
9498
9499fi
9500rm -f conftest.mmap conftest.txt
9501
9502if test $use_mmap_for_buffers = yes; then
9503
9504$as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
9505
9506 REL_ALLOC=no
9507fi
9508
9509LIBS="$LIBS_SYSTEM $LIBS"
9510
9511{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
9512$as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
d6974efa 9513if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then :
067d23c9
KY
9514 $as_echo_n "(cached) " >&6
9515else
9516 ac_check_lib_save_LIBS=$LIBS
9517LIBS="-ldnet $LIBS"
9518cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9519/* end confdefs.h. */
9520
9521/* Override any GCC internal prototype to avoid an error.
9522 Use char because int might match the return type of a GCC
9523 builtin and then its argument prototype would still apply. */
9524#ifdef __cplusplus
9525extern "C"
9526#endif
9527char dnet_ntoa ();
9528int
9529main ()
9530{
9531return dnet_ntoa ();
9532 ;
9533 return 0;
9534}
9535_ACEOF
9536if ac_fn_c_try_link "$LINENO"; then :
9537 ac_cv_lib_dnet_dnet_ntoa=yes
9538else
9539 ac_cv_lib_dnet_dnet_ntoa=no
9540fi
9541rm -f core conftest.err conftest.$ac_objext \
9542 conftest$ac_exeext conftest.$ac_ext
9543LIBS=$ac_check_lib_save_LIBS
9544fi
9545{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
9546$as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
d6974efa 9547if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then :
067d23c9
KY
9548 cat >>confdefs.h <<_ACEOF
9549#define HAVE_LIBDNET 1
9550_ACEOF
9551
9552 LIBS="-ldnet $LIBS"
9553
9554fi
9555
9556
9557{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
9558$as_echo_n "checking for main in -lXbsd... " >&6; }
d6974efa 9559if ${ac_cv_lib_Xbsd_main+:} false; then :
067d23c9
KY
9560 $as_echo_n "(cached) " >&6
9561else
9562 ac_check_lib_save_LIBS=$LIBS
9563LIBS="-lXbsd $LIBS"
9564cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9565/* end confdefs.h. */
9566
9567
9568int
9569main ()
9570{
9571return main ();
9572 ;
9573 return 0;
9574}
9575_ACEOF
9576if ac_fn_c_try_link "$LINENO"; then :
9577 ac_cv_lib_Xbsd_main=yes
9578else
9579 ac_cv_lib_Xbsd_main=no
9580fi
9581rm -f core conftest.err conftest.$ac_objext \
9582 conftest$ac_exeext conftest.$ac_ext
9583LIBS=$ac_check_lib_save_LIBS
9584fi
9585{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
9586$as_echo "$ac_cv_lib_Xbsd_main" >&6; }
d6974efa 9587if test "x$ac_cv_lib_Xbsd_main" = xyes; then :
067d23c9
KY
9588 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
9589fi
9590
9591
9592{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
9593$as_echo_n "checking for cma_open in -lpthreads... " >&6; }
d6974efa 9594if ${ac_cv_lib_pthreads_cma_open+:} false; then :
067d23c9
KY
9595 $as_echo_n "(cached) " >&6
9596else
9597 ac_check_lib_save_LIBS=$LIBS
9598LIBS="-lpthreads $LIBS"
9599cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9600/* end confdefs.h. */
9601
9602/* Override any GCC internal prototype to avoid an error.
9603 Use char because int might match the return type of a GCC
9604 builtin and then its argument prototype would still apply. */
9605#ifdef __cplusplus
9606extern "C"
9607#endif
9608char cma_open ();
9609int
9610main ()
9611{
9612return cma_open ();
9613 ;
9614 return 0;
9615}
9616_ACEOF
9617if ac_fn_c_try_link "$LINENO"; then :
9618 ac_cv_lib_pthreads_cma_open=yes
9619else
9620 ac_cv_lib_pthreads_cma_open=no
9621fi
9622rm -f core conftest.err conftest.$ac_objext \
9623 conftest$ac_exeext conftest.$ac_ext
9624LIBS=$ac_check_lib_save_LIBS
9625fi
9626{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
9627$as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
d6974efa 9628if test "x$ac_cv_lib_pthreads_cma_open" = xyes; then :
067d23c9
KY
9629 cat >>confdefs.h <<_ACEOF
9630#define HAVE_LIBPTHREADS 1
9631_ACEOF
9632
9633 LIBS="-lpthreads $LIBS"
9634
9635fi
9636
9637
9638## Note: when using cpp in s/aix4.2.h, this definition depended on
9639## HAVE_LIBPTHREADS. That was not defined earlier in configure when
9640## the system file was sourced. Hence the value of LIBS_SYSTEM
9641## added to LIBS in configure would never contain the pthreads part,
9642## but the value used in Makefiles might. FIXME?
9643##
9644## -lpthreads seems to be necessary for Xlib in X11R6, and should
9645## be harmless on older versions of X where it happens to exist.
9646test "$opsys" = "aix4-2" && \
9647 test $ac_cv_lib_pthreads_cma_open = yes && \
9648 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
9649
9650
9651case ${host_os} in
9652aix*)
9653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
9654$as_echo_n "checking for -bbigtoc option... " >&6; }
d6974efa 9655if ${gdb_cv_bigtoc+:} false; then :
067d23c9
KY
9656 $as_echo_n "(cached) " >&6
9657else
9658
9659 case $GCC in
9660 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
9661 *) gdb_cv_bigtoc=-bbigtoc ;;
9662 esac
9663
9664 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
9665 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9666/* end confdefs.h. */
9667
9668int
9669main ()
9670{
9671int i;
9672 ;
9673 return 0;
9674}
9675_ACEOF
9676if ac_fn_c_try_link "$LINENO"; then :
9677
9678else
9679 gdb_cv_bigtoc=
9680fi
9681rm -f core conftest.err conftest.$ac_objext \
9682 conftest$ac_exeext conftest.$ac_ext
9683
9684fi
9685{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
9686$as_echo "$gdb_cv_bigtoc" >&6; }
9687 ;;
9688esac
9689
9690# Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
9691# used for the tests that follow. We set them back to REAL_CFLAGS and
9692# REAL_CPPFLAGS later on.
9693
9694REAL_CFLAGS="$CFLAGS"
9695REAL_CPPFLAGS="$CPPFLAGS"
9696
9697if test "${HAVE_X11}" = "yes"; then
9698 DEFS="$C_SWITCH_X_SITE $DEFS"
9699 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
9700 LIBS="-lX11 $LIBS"
9701 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
9702 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
9703
9704 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
9705 # This is handled by LD_SWITCH_X_SITE_AUX during the real build,
9706 # but it's more convenient here to set LD_RUN_PATH
9707 # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX.
9708 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
9709 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
9710 export LD_RUN_PATH
9711 fi
9712
9713 if test "${opsys}" = "gnu-linux"; then
9714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
9715$as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
9716 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9717/* end confdefs.h. */
9718
9719int
9720main ()
9721{
9722XOpenDisplay ("foo");
9723 ;
9724 return 0;
9725}
9726_ACEOF
9727if ac_fn_c_try_link "$LINENO"; then :
9728 xlinux_first_failure=no
9729else
9730 xlinux_first_failure=yes
9731fi
9732rm -f core conftest.err conftest.$ac_objext \
9733 conftest$ac_exeext conftest.$ac_ext
9734 if test "${xlinux_first_failure}" = "yes"; then
9735 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
9736 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
9737 OLD_CPPFLAGS="$CPPFLAGS"
9738 OLD_LIBS="$LIBS"
9739 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
9740 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
9741 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
9742 LIBS="$LIBS -b i486-linuxaout"
9743 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9744/* end confdefs.h. */
9745
9746int
9747main ()
9748{
9749XOpenDisplay ("foo");
9750 ;
9751 return 0;
9752}
9753_ACEOF
9754if ac_fn_c_try_link "$LINENO"; then :
9755 xlinux_second_failure=no
9756else
9757 xlinux_second_failure=yes
9758fi
9759rm -f core conftest.err conftest.$ac_objext \
9760 conftest$ac_exeext conftest.$ac_ext
9761 if test "${xlinux_second_failure}" = "yes"; then
9762 # If we get the same failure with -b, there is no use adding -b.
9763 # So take it out. This plays safe.
9764 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
9765 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
9766 CPPFLAGS="$OLD_CPPFLAGS"
9767 LIBS="$OLD_LIBS"
9768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9769$as_echo "no" >&6; }
9770 else
9771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9772$as_echo "yes" >&6; }
9773 fi
9774 else
9775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9776$as_echo "no" >&6; }
9777 fi
9778 fi
9779
9780 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
9781 # header files included from there.
9782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
9783$as_echo_n "checking for Xkb... " >&6; }
9784 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9785/* end confdefs.h. */
9786#include <X11/Xlib.h>
9787#include <X11/XKBlib.h>
9788int
9789main ()
9790{
9791XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
9792 ;
9793 return 0;
9794}
9795_ACEOF
9796if ac_fn_c_try_link "$LINENO"; then :
9797 emacs_xkb=yes
9798else
9799 emacs_xkb=no
9800fi
9801rm -f core conftest.err conftest.$ac_objext \
9802 conftest$ac_exeext conftest.$ac_ext
9803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
9804$as_echo "$emacs_xkb" >&6; }
9805 if test $emacs_xkb = yes; then
9806
9807$as_echo "#define HAVE_XKBGETKEYBOARD 1" >>confdefs.h
9808
9809 fi
9810
9811 for ac_func in XrmSetDatabase XScreenResourceString \
9812XScreenNumberOfScreen XSetWMProtocols
9813do :
9814 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9815ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
2018939f 9816if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
067d23c9
KY
9817 cat >>confdefs.h <<_ACEOF
9818#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9819_ACEOF
9820
9821fi
9822done
9823
9824fi
9825
9826if test "${window_system}" = "x11"; then
9827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
9828$as_echo_n "checking X11 version 6... " >&6; }
d6974efa 9829 if ${emacs_cv_x11_version_6+:} false; then :
067d23c9
KY
9830 $as_echo_n "(cached) " >&6
9831else
9832 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9833/* end confdefs.h. */
9834#include <X11/Xlib.h>
9835int
9836main ()
9837{
9838#if XlibSpecificationRelease < 6
9839fail;
9840#endif
9841
9842 ;
9843 return 0;
9844}
9845_ACEOF
9846if ac_fn_c_try_link "$LINENO"; then :
9847 emacs_cv_x11_version_6=yes
9848else
9849 emacs_cv_x11_version_6=no
9850fi
9851rm -f core conftest.err conftest.$ac_objext \
9852 conftest$ac_exeext conftest.$ac_ext
9853fi
9854
9855 if test $emacs_cv_x11_version_6 = yes; then
9856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
9857$as_echo "6 or newer" >&6; }
9858
9859$as_echo "#define HAVE_X11R6 1" >>confdefs.h
9860
9861
9862$as_echo "#define HAVE_X_I18N 1" >>confdefs.h
9863
9864 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
9865 ## XIM support.
9866 case "$opsys" in
9867 sol2-*) : ;;
9868 *)
9869$as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
9870
9871 ;;
9872 esac
9873 else
9874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
9875$as_echo "before 6" >&6; }
9876 fi
9877fi
9878
9879
9880### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
9881HAVE_RSVG=no
9882if test "${HAVE_X11}" = "yes" || test "${NS_IMPL_GNUSTEP}" = "yes"; then
9883 if test "${with_rsvg}" != "no"; then
9884 RSVG_REQUIRED=2.11.0
9885 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
9886
9887
9888 succeeded=no
9889
9890 # Extract the first word of "pkg-config", so it can be a program name with args.
9891set dummy pkg-config; ac_word=$2
9892{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9893$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 9894if ${ac_cv_path_PKG_CONFIG+:} false; then :
067d23c9
KY
9895 $as_echo_n "(cached) " >&6
9896else
9897 case $PKG_CONFIG in
9898 [\\/]* | ?:[\\/]*)
9899 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9900 ;;
9901 *)
9902 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9903for as_dir in $PATH
9904do
9905 IFS=$as_save_IFS
9906 test -z "$as_dir" && as_dir=.
9907 for ac_exec_ext in '' $ac_executable_extensions; do
9908 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9909 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9910 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9911 break 2
9912 fi
9913done
9914 done
9915IFS=$as_save_IFS
9916
9917 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9918 ;;
9919esac
9920fi
9921PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9922if test -n "$PKG_CONFIG"; then
9923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
9924$as_echo "$PKG_CONFIG" >&6; }
9925else
9926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9927$as_echo "no" >&6; }
9928fi
9929
9930
9931
9932 if test "$PKG_CONFIG" = "no" ; then
9933 :
9934 else
9935 PKG_CONFIG_MIN_VERSION=0.9.0
9936 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9937 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
9938$as_echo_n "checking for $RSVG_MODULE... " >&6; }
9939
9940 if $PKG_CONFIG --exists "$RSVG_MODULE" 2>&5; then
9941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9942$as_echo "yes" >&6; }
9943 succeeded=yes
9944
9945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking RSVG_CFLAGS" >&5
9946$as_echo_n "checking RSVG_CFLAGS... " >&6; }
9947 RSVG_CFLAGS=`$PKG_CONFIG --cflags "$RSVG_MODULE"|sed -e 's,///*,/,g'`
9948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RSVG_CFLAGS" >&5
9949$as_echo "$RSVG_CFLAGS" >&6; }
9950
9951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking RSVG_LIBS" >&5
9952$as_echo_n "checking RSVG_LIBS... " >&6; }
9953 RSVG_LIBS=`$PKG_CONFIG --libs "$RSVG_MODULE"|sed -e 's,///*,/,g'`
9954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RSVG_LIBS" >&5
9955$as_echo "$RSVG_LIBS" >&6; }
9956 else
9957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9958$as_echo "no" >&6; }
9959 RSVG_CFLAGS=""
9960 RSVG_LIBS=""
9961 ## If we have a custom action on failure, don't print errors, but
9962 ## do set a variable so people can do so.
9963 RSVG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$RSVG_MODULE"`
9964
9965 fi
9966
9967
9968
9969 else
9970 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9971 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9972 fi
9973 fi
9974
9975 if test $succeeded = yes; then
9976 HAVE_RSVG=yes
9977 else
9978 :
9979 fi
9980
9981
9982
9983
9984 if test $HAVE_RSVG = yes; then
9985
9986$as_echo "#define HAVE_RSVG 1" >>confdefs.h
9987
9988 CFLAGS="$CFLAGS $RSVG_CFLAGS"
9989 LIBS="$RSVG_LIBS $LIBS"
9990 fi
9991 fi
9992fi
9993
9994HAVE_IMAGEMAGICK=no
9995if test "${HAVE_X11}" = "yes"; then
9996 if test "${with_imagemagick}" != "no"; then
9997 IMAGEMAGICK_MODULE="Wand"
9998
9999 succeeded=no
10000
10001 # Extract the first word of "pkg-config", so it can be a program name with args.
10002set dummy pkg-config; ac_word=$2
10003{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10004$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 10005if ${ac_cv_path_PKG_CONFIG+:} false; then :
067d23c9
KY
10006 $as_echo_n "(cached) " >&6
10007else
10008 case $PKG_CONFIG in
10009 [\\/]* | ?:[\\/]*)
10010 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10011 ;;
10012 *)
10013 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10014for as_dir in $PATH
10015do
10016 IFS=$as_save_IFS
10017 test -z "$as_dir" && as_dir=.
10018 for ac_exec_ext in '' $ac_executable_extensions; do
10019 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10020 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10021 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10022 break 2
10023 fi
10024done
10025 done
10026IFS=$as_save_IFS
10027
10028 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10029 ;;
10030esac
10031fi
10032PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10033if test -n "$PKG_CONFIG"; then
10034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10035$as_echo "$PKG_CONFIG" >&6; }
10036else
10037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10038$as_echo "no" >&6; }
10039fi
10040
10041
10042
10043 if test "$PKG_CONFIG" = "no" ; then
10044 :
10045 else
10046 PKG_CONFIG_MIN_VERSION=0.9.0
10047 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10048 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
10049$as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
10050
10051 if $PKG_CONFIG --exists "$IMAGEMAGICK_MODULE" 2>&5; then
10052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10053$as_echo "yes" >&6; }
10054 succeeded=yes
10055
10056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking IMAGEMAGICK_CFLAGS" >&5
10057$as_echo_n "checking IMAGEMAGICK_CFLAGS... " >&6; }
10058 IMAGEMAGICK_CFLAGS=`$PKG_CONFIG --cflags "$IMAGEMAGICK_MODULE"|sed -e 's,///*,/,g'`
10059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $IMAGEMAGICK_CFLAGS" >&5
10060$as_echo "$IMAGEMAGICK_CFLAGS" >&6; }
10061
10062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking IMAGEMAGICK_LIBS" >&5
10063$as_echo_n "checking IMAGEMAGICK_LIBS... " >&6; }
10064 IMAGEMAGICK_LIBS=`$PKG_CONFIG --libs "$IMAGEMAGICK_MODULE"|sed -e 's,///*,/,g'`
10065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $IMAGEMAGICK_LIBS" >&5
10066$as_echo "$IMAGEMAGICK_LIBS" >&6; }
10067 else
10068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10069$as_echo "no" >&6; }
10070 IMAGEMAGICK_CFLAGS=""
10071 IMAGEMAGICK_LIBS=""
10072 ## If we have a custom action on failure, don't print errors, but
10073 ## do set a variable so people can do so.
10074 IMAGEMAGICK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$IMAGEMAGICK_MODULE"`
10075
10076 fi
10077
10078
10079
10080 else
10081 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10082 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10083 fi
10084 fi
10085
10086 if test $succeeded = yes; then
10087 HAVE_IMAGEMAGICK=yes
10088 else
10089 :
10090 fi
10091
10092
10093
10094
10095 if test $HAVE_IMAGEMAGICK = yes; then
10096
10097$as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
10098
10099 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
10100 LIBS="$IMAGEMAGICK_LIBS $LIBS"
10101 for ac_func in MagickExportImagePixels
10102do :
10103 ac_fn_c_check_func "$LINENO" "MagickExportImagePixels" "ac_cv_func_MagickExportImagePixels"
d6974efa 10104if test "x$ac_cv_func_MagickExportImagePixels" = xyes; then :
067d23c9
KY
10105 cat >>confdefs.h <<_ACEOF
10106#define HAVE_MAGICKEXPORTIMAGEPIXELS 1
10107_ACEOF
10108
10109fi
10110done
10111
10112 fi
10113 fi
10114fi
10115
10116
10117HAVE_GTK=no
10118if test "${with_gtk3}" = "yes"; then
10119 GLIB_REQUIRED=2.6
10120 GTK_REQUIRED=2.90
10121 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10122
10123
10124 succeeded=no
10125
10126 # Extract the first word of "pkg-config", so it can be a program name with args.
10127set dummy pkg-config; ac_word=$2
10128{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10129$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 10130if ${ac_cv_path_PKG_CONFIG+:} false; then :
067d23c9
KY
10131 $as_echo_n "(cached) " >&6
10132else
10133 case $PKG_CONFIG in
10134 [\\/]* | ?:[\\/]*)
10135 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10136 ;;
10137 *)
10138 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10139for as_dir in $PATH
10140do
10141 IFS=$as_save_IFS
10142 test -z "$as_dir" && as_dir=.
10143 for ac_exec_ext in '' $ac_executable_extensions; do
10144 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10145 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10146 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10147 break 2
10148 fi
10149done
10150 done
10151IFS=$as_save_IFS
10152
10153 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10154 ;;
10155esac
10156fi
10157PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10158if test -n "$PKG_CONFIG"; then
10159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10160$as_echo "$PKG_CONFIG" >&6; }
10161else
10162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10163$as_echo "no" >&6; }
10164fi
10165
10166
10167
10168 if test "$PKG_CONFIG" = "no" ; then
10169 pkg_check_gtk=no
10170 else
10171 PKG_CONFIG_MIN_VERSION=0.9.0
10172 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10174$as_echo_n "checking for $GTK_MODULES... " >&6; }
10175
10176 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5; then
10177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10178$as_echo "yes" >&6; }
10179 succeeded=yes
10180
10181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_CFLAGS" >&5
10182$as_echo_n "checking GTK_CFLAGS... " >&6; }
10183 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"|sed -e 's,///*,/,g'`
10184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_CFLAGS" >&5
10185$as_echo "$GTK_CFLAGS" >&6; }
10186
10187 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_LIBS" >&5
10188$as_echo_n "checking GTK_LIBS... " >&6; }
10189 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"|sed -e 's,///*,/,g'`
10190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_LIBS" >&5
10191$as_echo "$GTK_LIBS" >&6; }
10192 else
10193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10194$as_echo "no" >&6; }
10195 GTK_CFLAGS=""
10196 GTK_LIBS=""
10197 ## If we have a custom action on failure, don't print errors, but
10198 ## do set a variable so people can do so.
10199 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
10200
10201 fi
10202
10203
10204
10205 else
10206 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10207 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10208 fi
10209 fi
10210
10211 if test $succeeded = yes; then
10212 pkg_check_gtk=yes
10213 else
10214 pkg_check_gtk=no
10215 fi
10216
10217 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
2018939f 10218 as_fn_error $? "$GTK_PKG_ERRORS" "$LINENO" 5
067d23c9
KY
10219 fi
10220fi
10221
10222if test "$pkg_check_gtk" != "yes"; then
10223 HAVE_GTK=no
10224if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
10225 GLIB_REQUIRED=2.6
10226 GTK_REQUIRED=2.6
10227 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10228
10229
10230 succeeded=no
10231
10232 # Extract the first word of "pkg-config", so it can be a program name with args.
10233set dummy pkg-config; ac_word=$2
10234{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10235$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 10236if ${ac_cv_path_PKG_CONFIG+:} false; then :
067d23c9
KY
10237 $as_echo_n "(cached) " >&6
10238else
10239 case $PKG_CONFIG in
10240 [\\/]* | ?:[\\/]*)
10241 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10242 ;;
10243 *)
10244 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10245for as_dir in $PATH
10246do
10247 IFS=$as_save_IFS
10248 test -z "$as_dir" && as_dir=.
10249 for ac_exec_ext in '' $ac_executable_extensions; do
10250 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10251 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10252 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10253 break 2
10254 fi
10255done
10256 done
10257IFS=$as_save_IFS
10258
10259 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10260 ;;
10261esac
10262fi
10263PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10264if test -n "$PKG_CONFIG"; then
10265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10266$as_echo "$PKG_CONFIG" >&6; }
10267else
10268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10269$as_echo "no" >&6; }
10270fi
10271
10272
10273
10274 if test "$PKG_CONFIG" = "no" ; then
10275 pkg_check_gtk=no
10276 else
10277 PKG_CONFIG_MIN_VERSION=0.9.0
10278 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10280$as_echo_n "checking for $GTK_MODULES... " >&6; }
10281
10282 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5; then
10283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10284$as_echo "yes" >&6; }
10285 succeeded=yes
10286
10287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_CFLAGS" >&5
10288$as_echo_n "checking GTK_CFLAGS... " >&6; }
10289 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"|sed -e 's,///*,/,g'`
10290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_CFLAGS" >&5
10291$as_echo "$GTK_CFLAGS" >&6; }
10292
10293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_LIBS" >&5
10294$as_echo_n "checking GTK_LIBS... " >&6; }
10295 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"|sed -e 's,///*,/,g'`
10296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_LIBS" >&5
10297$as_echo "$GTK_LIBS" >&6; }
10298 else
10299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10300$as_echo "no" >&6; }
10301 GTK_CFLAGS=""
10302 GTK_LIBS=""
10303 ## If we have a custom action on failure, don't print errors, but
10304 ## do set a variable so people can do so.
10305 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
10306
10307 fi
10308
10309
10310
10311 else
10312 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10313 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10314 fi
10315 fi
10316
10317 if test $succeeded = yes; then
10318 pkg_check_gtk=yes
10319 else
10320 pkg_check_gtk=no
10321 fi
10322
10323 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
2018939f 10324 as_fn_error $? "$GTK_PKG_ERRORS" "$LINENO" 5
067d23c9
KY
10325 fi
10326fi
10327fi
10328
10329GTK_OBJ=
10330if test x"$pkg_check_gtk" = xyes; then
10331
10332
10333
10334 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
10335 CFLAGS="$CFLAGS $GTK_CFLAGS"
10336 LIBS="$GTK_LIBS $LIBS"
10337 GTK_COMPILES=no
10338 for ac_func in gtk_main
10339do :
10340 ac_fn_c_check_func "$LINENO" "gtk_main" "ac_cv_func_gtk_main"
d6974efa 10341if test "x$ac_cv_func_gtk_main" = xyes; then :
067d23c9
KY
10342 cat >>confdefs.h <<_ACEOF
10343#define HAVE_GTK_MAIN 1
10344_ACEOF
10345 GTK_COMPILES=yes
10346fi
10347done
10348
10349 if test "${GTK_COMPILES}" != "yes"; then
10350 if test "$USE_X_TOOLKIT" != "maybe"; then
d6974efa 10351 as_fn_error $? "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
067d23c9
KY
10352 fi
10353 else
10354 HAVE_GTK=yes
10355
10356$as_echo "#define USE_GTK 1" >>confdefs.h
10357
10358 GTK_OBJ=gtkutil.o
10359 USE_X_TOOLKIT=none
10360 if $PKG_CONFIG --atleast-version=2.10 gtk+-2.0; then
10361 :
10362 else
10363 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
10364 closing open displays. This is no problem if you just use
10365 one display, but if you use more than one and close one of them
10366 Emacs may crash." >&5
10367$as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
10368 closing open displays. This is no problem if you just use
10369 one display, but if you use more than one and close one of them
10370 Emacs may crash." >&2;}
10371 sleep 3
10372 fi
10373 fi
10374
10375fi
10376
10377
10378
10379if test "${HAVE_GTK}" = "yes"; then
10380
10381 if test "$with_toolkit_scroll_bars" != no; then
10382 with_toolkit_scroll_bars=yes
10383 fi
10384
10385 HAVE_GTK_FILE_SELECTION=no
10386 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
10387#include <gtk/gtk.h>
10388"
d6974efa 10389if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = xyes; then :
067d23c9
KY
10390 HAVE_GTK_FILE_SELECTION=yes
10391else
10392 HAVE_GTK_FILE_SELECTION=no
10393fi
10394
10395 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
10396 for ac_func in gtk_file_selection_new
10397do :
10398 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
d6974efa 10399if test "x$ac_cv_func_gtk_file_selection_new" = xyes; then :
067d23c9
KY
10400 cat >>confdefs.h <<_ACEOF
10401#define HAVE_GTK_FILE_SELECTION_NEW 1
10402_ACEOF
10403
10404fi
10405done
10406
10407 fi
10408
10409 HAVE_GTK_AND_PTHREAD=no
10410 for ac_header in pthread.h
10411do :
10412 ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
d6974efa 10413if test "x$ac_cv_header_pthread_h" = xyes; then :
067d23c9
KY
10414 cat >>confdefs.h <<_ACEOF
10415#define HAVE_PTHREAD_H 1
10416_ACEOF
10417
10418fi
10419
10420done
10421
10422 if test "$ac_cv_header_pthread_h"; then
10423 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_self in -lpthread" >&5
10424$as_echo_n "checking for pthread_self in -lpthread... " >&6; }
d6974efa 10425if ${ac_cv_lib_pthread_pthread_self+:} false; then :
067d23c9
KY
10426 $as_echo_n "(cached) " >&6
10427else
10428 ac_check_lib_save_LIBS=$LIBS
10429LIBS="-lpthread $LIBS"
10430cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10431/* end confdefs.h. */
10432
10433/* Override any GCC internal prototype to avoid an error.
10434 Use char because int might match the return type of a GCC
10435 builtin and then its argument prototype would still apply. */
10436#ifdef __cplusplus
10437extern "C"
10438#endif
10439char pthread_self ();
10440int
10441main ()
10442{
10443return pthread_self ();
10444 ;
10445 return 0;
10446}
10447_ACEOF
10448if ac_fn_c_try_link "$LINENO"; then :
10449 ac_cv_lib_pthread_pthread_self=yes
10450else
10451 ac_cv_lib_pthread_pthread_self=no
10452fi
10453rm -f core conftest.err conftest.$ac_objext \
10454 conftest$ac_exeext conftest.$ac_ext
10455LIBS=$ac_check_lib_save_LIBS
10456fi
10457{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_self" >&5
10458$as_echo "$ac_cv_lib_pthread_pthread_self" >&6; }
d6974efa 10459if test "x$ac_cv_lib_pthread_pthread_self" = xyes; then :
067d23c9
KY
10460 HAVE_GTK_AND_PTHREAD=yes
10461fi
10462
10463 fi
10464 if test "$HAVE_GTK_AND_PTHREAD" = yes; then
10465 case "${canonical}" in
10466 *-hpux*) ;;
10467 *) GTK_LIBS="$GTK_LIBS -lpthread" ;;
10468 esac
10469
10470$as_echo "#define HAVE_GTK_AND_PTHREAD 1" >>confdefs.h
10471
10472 fi
10473
10474 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
10475 gtk_dialog_get_action_area gtk_widget_get_sensitive \
10476 gtk_widget_get_mapped gtk_adjustment_get_page_size \
10477 gtk_orientable_set_orientation
10478do :
10479 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10480ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
2018939f 10481if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
067d23c9
KY
10482 cat >>confdefs.h <<_ACEOF
10483#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10484_ACEOF
10485
10486fi
10487done
10488
10489
10490fi
10491
10492HAVE_DBUS=no
10493DBUS_OBJ=
10494if test "${with_dbus}" = "yes"; then
10495
10496 succeeded=no
10497
10498 # Extract the first word of "pkg-config", so it can be a program name with args.
10499set dummy pkg-config; ac_word=$2
10500{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10501$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 10502if ${ac_cv_path_PKG_CONFIG+:} false; then :
067d23c9
KY
10503 $as_echo_n "(cached) " >&6
10504else
10505 case $PKG_CONFIG in
10506 [\\/]* | ?:[\\/]*)
10507 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10508 ;;
10509 *)
10510 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10511for as_dir in $PATH
10512do
10513 IFS=$as_save_IFS
10514 test -z "$as_dir" && as_dir=.
10515 for ac_exec_ext in '' $ac_executable_extensions; do
10516 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10517 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10518 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10519 break 2
10520 fi
10521done
10522 done
10523IFS=$as_save_IFS
10524
10525 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10526 ;;
10527esac
10528fi
10529PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10530if test -n "$PKG_CONFIG"; then
10531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10532$as_echo "$PKG_CONFIG" >&6; }
10533else
10534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10535$as_echo "no" >&6; }
10536fi
10537
10538
10539
10540 if test "$PKG_CONFIG" = "no" ; then
10541 HAVE_DBUS=no
10542 else
10543 PKG_CONFIG_MIN_VERSION=0.9.0
10544 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
10546$as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
10547
10548 if $PKG_CONFIG --exists "dbus-1 >= 1.0" 2>&5; then
10549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10550$as_echo "yes" >&6; }
10551 succeeded=yes
10552
10553 { $as_echo "$as_me:${as_lineno-$LINENO}: checking DBUS_CFLAGS" >&5
10554$as_echo_n "checking DBUS_CFLAGS... " >&6; }
10555 DBUS_CFLAGS=`$PKG_CONFIG --cflags "dbus-1 >= 1.0"|sed -e 's,///*,/,g'`
10556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBUS_CFLAGS" >&5
10557$as_echo "$DBUS_CFLAGS" >&6; }
10558
10559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking DBUS_LIBS" >&5
10560$as_echo_n "checking DBUS_LIBS... " >&6; }
10561 DBUS_LIBS=`$PKG_CONFIG --libs "dbus-1 >= 1.0"|sed -e 's,///*,/,g'`
10562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBUS_LIBS" >&5
10563$as_echo "$DBUS_LIBS" >&6; }
10564 else
10565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10566$as_echo "no" >&6; }
10567 DBUS_CFLAGS=""
10568 DBUS_LIBS=""
10569 ## If we have a custom action on failure, don't print errors, but
10570 ## do set a variable so people can do so.
10571 DBUS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "dbus-1 >= 1.0"`
10572
10573 fi
10574
10575
10576
10577 else
10578 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10579 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10580 fi
10581 fi
10582
10583 if test $succeeded = yes; then
10584 HAVE_DBUS=yes
10585 else
10586 HAVE_DBUS=no
10587 fi
10588
10589 if test "$HAVE_DBUS" = yes; then
10590 LIBS="$LIBS $DBUS_LIBS"
10591
10592$as_echo "#define HAVE_DBUS 1" >>confdefs.h
10593
10594 for ac_func in dbus_watch_get_unix_fd
10595do :
10596 ac_fn_c_check_func "$LINENO" "dbus_watch_get_unix_fd" "ac_cv_func_dbus_watch_get_unix_fd"
d6974efa 10597if test "x$ac_cv_func_dbus_watch_get_unix_fd" = xyes; then :
067d23c9
KY
10598 cat >>confdefs.h <<_ACEOF
10599#define HAVE_DBUS_WATCH_GET_UNIX_FD 1
10600_ACEOF
10601
10602fi
10603done
10604
10605 DBUS_OBJ=dbusbind.o
10606 fi
10607fi
10608
10609
10610HAVE_GCONF=no
10611if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
10612
10613 succeeded=no
10614
10615 # Extract the first word of "pkg-config", so it can be a program name with args.
10616set dummy pkg-config; ac_word=$2
10617{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10618$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 10619if ${ac_cv_path_PKG_CONFIG+:} false; then :
067d23c9
KY
10620 $as_echo_n "(cached) " >&6
10621else
10622 case $PKG_CONFIG in
10623 [\\/]* | ?:[\\/]*)
10624 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10625 ;;
10626 *)
10627 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10628for as_dir in $PATH
10629do
10630 IFS=$as_save_IFS
10631 test -z "$as_dir" && as_dir=.
10632 for ac_exec_ext in '' $ac_executable_extensions; do
10633 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10634 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10635 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10636 break 2
10637 fi
10638done
10639 done
10640IFS=$as_save_IFS
10641
10642 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10643 ;;
10644esac
10645fi
10646PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10647if test -n "$PKG_CONFIG"; then
10648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10649$as_echo "$PKG_CONFIG" >&6; }
10650else
10651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10652$as_echo "no" >&6; }
10653fi
10654
10655
10656
10657 if test "$PKG_CONFIG" = "no" ; then
10658 HAVE_GCONF=no
10659 else
10660 PKG_CONFIG_MIN_VERSION=0.9.0
10661 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
10663$as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
10664
10665 if $PKG_CONFIG --exists "gconf-2.0 >= 2.13" 2>&5; then
10666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10667$as_echo "yes" >&6; }
10668 succeeded=yes
10669
10670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GCONF_CFLAGS" >&5
10671$as_echo_n "checking GCONF_CFLAGS... " >&6; }
10672 GCONF_CFLAGS=`$PKG_CONFIG --cflags "gconf-2.0 >= 2.13"|sed -e 's,///*,/,g'`
10673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCONF_CFLAGS" >&5
10674$as_echo "$GCONF_CFLAGS" >&6; }
10675
10676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GCONF_LIBS" >&5
10677$as_echo_n "checking GCONF_LIBS... " >&6; }
10678 GCONF_LIBS=`$PKG_CONFIG --libs "gconf-2.0 >= 2.13"|sed -e 's,///*,/,g'`
10679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCONF_LIBS" >&5
10680$as_echo "$GCONF_LIBS" >&6; }
10681 else
10682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10683$as_echo "no" >&6; }
10684 GCONF_CFLAGS=""
10685 GCONF_LIBS=""
10686 ## If we have a custom action on failure, don't print errors, but
10687 ## do set a variable so people can do so.
10688 GCONF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gconf-2.0 >= 2.13"`
10689
10690 fi
10691
10692
10693
10694 else
10695 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10696 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10697 fi
10698 fi
10699
10700 if test $succeeded = yes; then
10701 HAVE_GCONF=yes
10702 else
10703 HAVE_GCONF=no
10704 fi
10705
10706 if test "$HAVE_GCONF" = yes; then
10707
10708$as_echo "#define HAVE_GCONF 1" >>confdefs.h
10709
10710 for ac_func in g_type_init
10711do :
10712 ac_fn_c_check_func "$LINENO" "g_type_init" "ac_cv_func_g_type_init"
d6974efa 10713if test "x$ac_cv_func_g_type_init" = xyes; then :
067d23c9
KY
10714 cat >>confdefs.h <<_ACEOF
10715#define HAVE_G_TYPE_INIT 1
10716_ACEOF
10717
10718fi
10719done
10720
10721 fi
10722fi
10723
10724HAVE_LIBSELINUX=no
10725LIBSELINUX_LIBS=
10726if test "${with_selinux}" = "yes"; then
10727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
10728$as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
d6974efa 10729if ${ac_cv_lib_selinux_lgetfilecon+:} false; then :
067d23c9
KY
10730 $as_echo_n "(cached) " >&6
10731else
10732 ac_check_lib_save_LIBS=$LIBS
10733LIBS="-lselinux $LIBS"
10734cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10735/* end confdefs.h. */
10736
10737/* Override any GCC internal prototype to avoid an error.
10738 Use char because int might match the return type of a GCC
10739 builtin and then its argument prototype would still apply. */
10740#ifdef __cplusplus
10741extern "C"
10742#endif
10743char lgetfilecon ();
10744int
10745main ()
10746{
10747return lgetfilecon ();
10748 ;
10749 return 0;
10750}
10751_ACEOF
10752if ac_fn_c_try_link "$LINENO"; then :
10753 ac_cv_lib_selinux_lgetfilecon=yes
10754else
10755 ac_cv_lib_selinux_lgetfilecon=no
10756fi
10757rm -f core conftest.err conftest.$ac_objext \
10758 conftest$ac_exeext conftest.$ac_ext
10759LIBS=$ac_check_lib_save_LIBS
10760fi
10761{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
10762$as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
d6974efa 10763if test "x$ac_cv_lib_selinux_lgetfilecon" = xyes; then :
067d23c9
KY
10764 HAVE_LIBSELINUX=yes
10765else
10766 HAVE_LIBSELINUX=no
10767fi
10768
10769 if test "$HAVE_LIBSELINUX" = yes; then
10770
10771$as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
10772
10773 LIBSELINUX_LIBS=-lselinux
10774 fi
10775fi
10776
10777
10778HAVE_GNUTLS=no
10779if test "${with_gnutls}" = "yes" ; then
10780
10781 succeeded=no
10782
10783 # Extract the first word of "pkg-config", so it can be a program name with args.
10784set dummy pkg-config; ac_word=$2
10785{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10786$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 10787if ${ac_cv_path_PKG_CONFIG+:} false; then :
067d23c9
KY
10788 $as_echo_n "(cached) " >&6
10789else
10790 case $PKG_CONFIG in
10791 [\\/]* | ?:[\\/]*)
10792 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10793 ;;
10794 *)
10795 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10796for as_dir in $PATH
10797do
10798 IFS=$as_save_IFS
10799 test -z "$as_dir" && as_dir=.
10800 for ac_exec_ext in '' $ac_executable_extensions; do
10801 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10802 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10803 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10804 break 2
10805 fi
10806done
10807 done
10808IFS=$as_save_IFS
10809
10810 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10811 ;;
10812esac
10813fi
10814PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10815if test -n "$PKG_CONFIG"; then
10816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10817$as_echo "$PKG_CONFIG" >&6; }
10818else
10819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10820$as_echo "no" >&6; }
10821fi
10822
10823
10824
10825 if test "$PKG_CONFIG" = "no" ; then
10826 HAVE_GNUTLS=no
10827 else
10828 PKG_CONFIG_MIN_VERSION=0.9.0
10829 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10830 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.2.4" >&5
10831$as_echo_n "checking for gnutls >= 2.2.4... " >&6; }
10832
10833 if $PKG_CONFIG --exists "gnutls >= 2.2.4" 2>&5; then
10834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10835$as_echo "yes" >&6; }
10836 succeeded=yes
10837
10838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBGNUTLS_CFLAGS" >&5
10839$as_echo_n "checking LIBGNUTLS_CFLAGS... " >&6; }
10840 LIBGNUTLS_CFLAGS=`$PKG_CONFIG --cflags "gnutls >= 2.2.4"|sed -e 's,///*,/,g'`
10841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBGNUTLS_CFLAGS" >&5
10842$as_echo "$LIBGNUTLS_CFLAGS" >&6; }
10843
10844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBGNUTLS_LIBS" >&5
10845$as_echo_n "checking LIBGNUTLS_LIBS... " >&6; }
10846 LIBGNUTLS_LIBS=`$PKG_CONFIG --libs "gnutls >= 2.2.4"|sed -e 's,///*,/,g'`
10847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBGNUTLS_LIBS" >&5
10848$as_echo "$LIBGNUTLS_LIBS" >&6; }
10849 else
10850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10851$as_echo "no" >&6; }
10852 LIBGNUTLS_CFLAGS=""
10853 LIBGNUTLS_LIBS=""
10854 ## If we have a custom action on failure, don't print errors, but
10855 ## do set a variable so people can do so.
10856 LIBGNUTLS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gnutls >= 2.2.4"`
10857
10858 fi
10859
10860
10861
10862 else
10863 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10864 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10865 fi
10866 fi
10867
10868 if test $succeeded = yes; then
10869 HAVE_GNUTLS=yes
10870 else
10871 HAVE_GNUTLS=no
10872 fi
10873
10874 if test "${HAVE_GNUTLS}" = "yes"; then
10875
10876$as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
10877
10878 fi
10879fi
10880
10881
10882
10883HAVE_XAW3D=no
10884LUCID_LIBW=
10885if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
10886 if test "$with_xaw3d" != no; then
10887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
10888$as_echo_n "checking for xaw3d... " >&6; }
d6974efa 10889 if ${emacs_cv_xaw3d+:} false; then :
067d23c9
KY
10890 $as_echo_n "(cached) " >&6
10891else
10892 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10893/* end confdefs.h. */
10894
10895#include <X11/Intrinsic.h>
10896#include <X11/Xaw3d/Simple.h>
10897int
10898main ()
10899{
10900
10901 ;
10902 return 0;
10903}
10904_ACEOF
10905if ac_fn_c_try_link "$LINENO"; then :
14beddf4
CY
10906 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
10907$as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
67342916 10908if ${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+:} false; then :
ae1362a3
AS
10909 $as_echo_n "(cached) " >&6
10910else
10911 ac_check_lib_save_LIBS=$LIBS
14beddf4 10912LIBS="-lXaw3d $LIBS"
ae1362a3
AS
10913cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10914/* end confdefs.h. */
bf89cb4d 10915
ae1362a3
AS
10916/* Override any GCC internal prototype to avoid an error.
10917 Use char because int might match the return type of a GCC
10918 builtin and then its argument prototype would still apply. */
10919#ifdef __cplusplus
10920extern "C"
10921#endif
14beddf4 10922char XawScrollbarSetThumb ();
ae1362a3
AS
10923int
10924main ()
10925{
14beddf4 10926return XawScrollbarSetThumb ();
ae1362a3
AS
10927 ;
10928 return 0;
10929}
10930_ACEOF
10931if ac_fn_c_try_link "$LINENO"; then :
14beddf4 10932 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
ae1362a3 10933else
14beddf4 10934 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
ae1362a3
AS
10935fi
10936rm -f core conftest.err conftest.$ac_objext \
10937 conftest$ac_exeext conftest.$ac_ext
10938LIBS=$ac_check_lib_save_LIBS
10939fi
14beddf4
CY
10940{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
10941$as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
67342916 10942if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = xyes; then :
067d23c9
KY
10943 emacs_cv_xaw3d=yes
10944else
10945 emacs_cv_xaw3d=no
10946fi
14beddf4
CY
10947
10948else
10949 emacs_cv_xaw3d=no
10950fi
067d23c9
KY
10951rm -f core conftest.err conftest.$ac_objext \
10952 conftest$ac_exeext conftest.$ac_ext
10953fi
10954
10955 else
10956 emacs_cv_xaw3d=no
10957 fi
10958 if test $emacs_cv_xaw3d = yes; then
10959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
10960$as_echo "yes; using Lucid toolkit" >&6; }
10961 USE_X_TOOLKIT=LUCID
10962 HAVE_XAW3D=yes
10963 LUCID_LIBW=-lXaw3d
10964
10965$as_echo "#define HAVE_XAW3D 1" >>confdefs.h
10966
10967 else
10968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10969$as_echo "no" >&6; }
10970 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
10971$as_echo_n "checking for libXaw... " >&6; }
d6974efa 10972 if ${emacs_cv_xaw+:} false; then :
067d23c9
KY
10973 $as_echo_n "(cached) " >&6
10974else
10975 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10976/* end confdefs.h. */
10977
10978#include <X11/Intrinsic.h>
10979#include <X11/Xaw/Simple.h>
10980int
10981main ()
10982{
10983
10984 ;
10985 return 0;
10986}
10987_ACEOF
10988if ac_fn_c_try_link "$LINENO"; then :
10989 emacs_cv_xaw=yes
10990else
10991 emacs_cv_xaw=no
10992fi
10993rm -f core conftest.err conftest.$ac_objext \
10994 conftest$ac_exeext conftest.$ac_ext
10995fi
10996
10997 if test $emacs_cv_xaw = yes; then
10998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
10999$as_echo "yes; using Lucid toolkit" >&6; }
11000 USE_X_TOOLKIT=LUCID
11001 LUCID_LIBW=-lXaw
11002 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
2018939f 11003 as_fn_error $? "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
067d23c9
KY
11004 else
11005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no; do not use toolkit by default" >&5
11006$as_echo "no; do not use toolkit by default" >&6; }
11007 USE_X_TOOLKIT=none
11008 fi
11009 fi
11010fi
11011
11012X_TOOLKIT_TYPE=$USE_X_TOOLKIT
11013
11014LIBXTR6=
11015if test "${USE_X_TOOLKIT}" != "none"; then
11016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
11017$as_echo_n "checking X11 toolkit version... " >&6; }
d6974efa 11018 if ${emacs_cv_x11_toolkit_version_6+:} false; then :
067d23c9
KY
11019 $as_echo_n "(cached) " >&6
11020else
11021 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11022/* end confdefs.h. */
11023#include <X11/Intrinsic.h>
11024int
11025main ()
11026{
11027#if XtSpecificationRelease < 6
11028fail;
11029#endif
11030
11031 ;
11032 return 0;
11033}
11034_ACEOF
11035if ac_fn_c_try_link "$LINENO"; then :
11036 emacs_cv_x11_toolkit_version_6=yes
11037else
11038 emacs_cv_x11_toolkit_version_6=no
11039fi
11040rm -f core conftest.err conftest.$ac_objext \
11041 conftest$ac_exeext conftest.$ac_ext
11042fi
11043
11044 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
11045 if test $emacs_cv_x11_toolkit_version_6 = yes; then
11046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11047$as_echo "6 or newer" >&6; }
11048
11049$as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
11050
11051 LIBXTR6="-lSM -lICE"
11052 case "$opsys" in
11053 ## Use libw.a along with X11R6 Xt.
11054 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
11055 esac
11056 else
11057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11058$as_echo "before 6" >&6; }
11059 fi
11060
11061 OLDLIBS="$LIBS"
11062 if test x$HAVE_X11XTR6 = xyes; then
11063 LIBS="-lXt -lSM -lICE $LIBS"
11064 else
11065 LIBS="-lXt $LIBS"
11066 fi
11067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
11068$as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
d6974efa 11069if ${ac_cv_lib_Xmu_XmuConvertStandardSelection+:} false; then :
067d23c9
KY
11070 $as_echo_n "(cached) " >&6
11071else
11072 ac_check_lib_save_LIBS=$LIBS
11073LIBS="-lXmu $LIBS"
11074cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11075/* end confdefs.h. */
11076
11077/* Override any GCC internal prototype to avoid an error.
11078 Use char because int might match the return type of a GCC
11079 builtin and then its argument prototype would still apply. */
11080#ifdef __cplusplus
11081extern "C"
11082#endif
11083char XmuConvertStandardSelection ();
11084int
11085main ()
11086{
11087return XmuConvertStandardSelection ();
11088 ;
11089 return 0;
11090}
11091_ACEOF
11092if ac_fn_c_try_link "$LINENO"; then :
11093 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
11094else
11095 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
11096fi
11097rm -f core conftest.err conftest.$ac_objext \
11098 conftest$ac_exeext conftest.$ac_ext
11099LIBS=$ac_check_lib_save_LIBS
11100fi
11101{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
11102$as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
d6974efa 11103if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = xyes; then :
067d23c9
KY
11104 cat >>confdefs.h <<_ACEOF
11105#define HAVE_LIBXMU 1
11106_ACEOF
11107
11108 LIBS="-lXmu $LIBS"
11109
11110fi
11111
11112 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
11113fi
11114
11115
11116LIBXMU=-lXmu
d6a003a8
AS
11117case $opsys in
11118 ## These systems don't supply Xmu.
067d23c9
KY
11119 hpux* | aix4-2 )
11120 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
11121 ;;
11122esac
11123
11124
11125# On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
11126if test "${HAVE_X11}" = "yes"; then
11127 if test "${USE_X_TOOLKIT}" != "none"; then
11128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
11129$as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
d6974efa 11130if ${ac_cv_lib_Xext_XShapeQueryExtension+:} false; then :
067d23c9
KY
11131 $as_echo_n "(cached) " >&6
11132else
11133 ac_check_lib_save_LIBS=$LIBS
11134LIBS="-lXext $LIBS"
11135cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11136/* end confdefs.h. */
11137
11138/* Override any GCC internal prototype to avoid an error.
11139 Use char because int might match the return type of a GCC
11140 builtin and then its argument prototype would still apply. */
11141#ifdef __cplusplus
11142extern "C"
11143#endif
11144char XShapeQueryExtension ();
11145int
11146main ()
11147{
11148return XShapeQueryExtension ();
11149 ;
11150 return 0;
11151}
11152_ACEOF
11153if ac_fn_c_try_link "$LINENO"; then :
11154 ac_cv_lib_Xext_XShapeQueryExtension=yes
11155else
11156 ac_cv_lib_Xext_XShapeQueryExtension=no
11157fi
11158rm -f core conftest.err conftest.$ac_objext \
11159 conftest$ac_exeext conftest.$ac_ext
11160LIBS=$ac_check_lib_save_LIBS
11161fi
11162{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
11163$as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
d6974efa 11164if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = xyes; then :
067d23c9
KY
11165 cat >>confdefs.h <<_ACEOF
11166#define HAVE_LIBXEXT 1
11167_ACEOF
11168
11169 LIBS="-lXext $LIBS"
11170
11171fi
11172
11173 fi
11174fi
11175
11176LIBXP=
11177if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Motif version 2.1" >&5
11179$as_echo_n "checking for Motif version 2.1... " >&6; }
d6974efa 11180if ${emacs_cv_motif_version_2_1+:} false; then :
067d23c9
KY
11181 $as_echo_n "(cached) " >&6
11182else
11183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11184/* end confdefs.h. */
11185#include <Xm/Xm.h>
11186int
11187main ()
11188{
11189#if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
11190int x = 5;
11191#else
11192Motif version prior to 2.1.
11193#endif
11194 ;
11195 return 0;
11196}
11197_ACEOF
11198if ac_fn_c_try_compile "$LINENO"; then :
11199 emacs_cv_motif_version_2_1=yes
11200else
11201 emacs_cv_motif_version_2_1=no
11202fi
11203rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11204fi
11205{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
11206$as_echo "$emacs_cv_motif_version_2_1" >&6; }
11207 if test $emacs_cv_motif_version_2_1 = yes; then
11208 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
11209$as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
d6974efa 11210if ${ac_cv_lib_Xp_XpCreateContext+:} false; then :
067d23c9
KY
11211 $as_echo_n "(cached) " >&6
11212else
11213 ac_check_lib_save_LIBS=$LIBS
11214LIBS="-lXp $LIBS"
11215cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11216/* end confdefs.h. */
11217
11218/* Override any GCC internal prototype to avoid an error.
11219 Use char because int might match the return type of a GCC
11220 builtin and then its argument prototype would still apply. */
11221#ifdef __cplusplus
11222extern "C"
11223#endif
11224char XpCreateContext ();
11225int
11226main ()
11227{
11228return XpCreateContext ();
11229 ;
11230 return 0;
11231}
11232_ACEOF
11233if ac_fn_c_try_link "$LINENO"; then :
11234 ac_cv_lib_Xp_XpCreateContext=yes
11235else
11236 ac_cv_lib_Xp_XpCreateContext=no
11237fi
11238rm -f core conftest.err conftest.$ac_objext \
11239 conftest$ac_exeext conftest.$ac_ext
11240LIBS=$ac_check_lib_save_LIBS
11241fi
11242{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
11243$as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
d6974efa 11244if test "x$ac_cv_lib_Xp_XpCreateContext" = xyes; then :
067d23c9
KY
11245 LIBXP=-lXp
11246fi
11247
11248 else
11249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
11250$as_echo_n "checking for LessTif where some systems put it... " >&6; }
d6974efa 11251if ${emacs_cv_lesstif+:} false; then :
067d23c9
KY
11252 $as_echo_n "(cached) " >&6
11253else
11254 # We put this in CFLAGS temporarily to precede other -I options
11255 # that might be in CFLAGS temporarily.
11256 # We put this in CPPFLAGS where it precedes the other -I options.
11257 OLD_CPPFLAGS=$CPPFLAGS
11258 OLD_CFLAGS=$CFLAGS
11259 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
11260 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
11261 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11262/* end confdefs.h. */
11263#include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
11264int
11265main ()
11266{
11267int x = 5;
11268 ;
11269 return 0;
11270}
11271_ACEOF
11272if ac_fn_c_try_compile "$LINENO"; then :
11273 emacs_cv_lesstif=yes
11274else
11275 emacs_cv_lesstif=no
11276fi
11277rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11278fi
11279{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
11280$as_echo "$emacs_cv_lesstif" >&6; }
11281 if test $emacs_cv_lesstif = yes; then
11282 # Make sure this -I option remains in CPPFLAGS after it is set
11283 # back to REAL_CPPFLAGS.
11284 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
11285 # have those other -I options anyway. Ultimately, having this
11286 # directory ultimately in CPPFLAGS will be enough.
11287 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
11288 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
11289 else
11290 CFLAGS=$OLD_CFLAGS
11291 CPPFLAGS=$OLD_CPPFLAGS
11292 fi
11293 fi
11294fi
11295
11296
11297USE_TOOLKIT_SCROLL_BARS=no
11298if test "${with_toolkit_scroll_bars}" != "no"; then
11299 if test "${USE_X_TOOLKIT}" != "none"; then
11300 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11301 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11302
11303 HAVE_XAW3D=no
11304 USE_TOOLKIT_SCROLL_BARS=yes
11305 elif test "${HAVE_XAW3D}" = "yes"; then
11306 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11307
11308 USE_TOOLKIT_SCROLL_BARS=yes
11309 fi
11310 elif test "${HAVE_GTK}" = "yes"; then
11311 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11312
11313 USE_TOOLKIT_SCROLL_BARS=yes
11314 elif test "${HAVE_NS}" = "yes"; then
11315 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11316
11317 USE_TOOLKIT_SCROLL_BARS=yes
11318 fi
11319fi
11320
11321cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11322/* end confdefs.h. */
11323
11324 #include <X11/Xlib.h>
11325 #include <X11/Xresource.h>
11326int
11327main ()
11328{
11329XIMProc callback;
11330 ;
11331 return 0;
11332}
11333_ACEOF
11334if ac_fn_c_try_compile "$LINENO"; then :
11335 HAVE_XIM=yes
11336
11337$as_echo "#define HAVE_XIM 1" >>confdefs.h
11338
11339else
11340 HAVE_XIM=no
11341fi
11342rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11343
11344
11345if test "${with_xim}" != "no"; then
11346
11347$as_echo "#define USE_XIM 1" >>confdefs.h
11348
11349fi
11350
11351
11352if test "${HAVE_XIM}" != "no"; then
11353 late_CFLAGS=$CFLAGS
11354 if test "$GCC" = yes; then
11355 CFLAGS="$CFLAGS --pedantic-errors"
11356 fi
11357 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11358/* end confdefs.h. */
11359
11360#include <X11/Xlib.h>
11361#include <X11/Xresource.h>
11362int
11363main ()
11364{
11365Display *display;
11366XrmDatabase db;
11367char *res_name;
11368char *res_class;
11369XIMProc callback;
11370XPointer *client_data;
11371#ifndef __GNUC__
11372/* If we're not using GCC, it's probably not XFree86, and this is
11373 probably right, but we can't use something like --pedantic-errors. */
11374extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
11375 char*, XIMProc, XPointer*);
11376#endif
11377(void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
11378 client_data);
11379 ;
11380 return 0;
11381}
11382_ACEOF
11383if ac_fn_c_try_compile "$LINENO"; then :
11384 emacs_cv_arg6_star=yes
11385fi
11386rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11387 if test "$emacs_cv_arg6_star" = yes; then
11388 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
11389
11390 else
11391 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
11392
11393 fi
11394 CFLAGS=$late_CFLAGS
11395fi
11396
11397### Start of font-backend (under any platform) section.
11398# (nothing here yet -- this is a placeholder)
11399### End of font-backend (under any platform) section.
11400
11401### Start of font-backend (under X11) section.
11402if test "${HAVE_X11}" = "yes"; then
11403
11404 succeeded=no
11405
11406 # Extract the first word of "pkg-config", so it can be a program name with args.
11407set dummy pkg-config; ac_word=$2
11408{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11409$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 11410if ${ac_cv_path_PKG_CONFIG+:} false; then :
067d23c9
KY
11411 $as_echo_n "(cached) " >&6
11412else
11413 case $PKG_CONFIG in
11414 [\\/]* | ?:[\\/]*)
11415 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11416 ;;
11417 *)
11418 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11419for as_dir in $PATH
11420do
11421 IFS=$as_save_IFS
11422 test -z "$as_dir" && as_dir=.
11423 for ac_exec_ext in '' $ac_executable_extensions; do
11424 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11425 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11426 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11427 break 2
11428 fi
11429done
11430 done
11431IFS=$as_save_IFS
11432
11433 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11434 ;;
11435esac
11436fi
11437PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11438if test -n "$PKG_CONFIG"; then
11439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11440$as_echo "$PKG_CONFIG" >&6; }
11441else
11442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11443$as_echo "no" >&6; }
11444fi
11445
11446
11447
11448 if test "$PKG_CONFIG" = "no" ; then
11449 HAVE_FC=no
11450 else
11451 PKG_CONFIG_MIN_VERSION=0.9.0
11452 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
11454$as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
11455
11456 if $PKG_CONFIG --exists "fontconfig >= 2.2.0" 2>&5; then
11457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11458$as_echo "yes" >&6; }
11459 succeeded=yes
11460
11461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking FONTCONFIG_CFLAGS" >&5
11462$as_echo_n "checking FONTCONFIG_CFLAGS... " >&6; }
11463 FONTCONFIG_CFLAGS=`$PKG_CONFIG --cflags "fontconfig >= 2.2.0"|sed -e 's,///*,/,g'`
11464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FONTCONFIG_CFLAGS" >&5
11465$as_echo "$FONTCONFIG_CFLAGS" >&6; }
11466
11467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking FONTCONFIG_LIBS" >&5
11468$as_echo_n "checking FONTCONFIG_LIBS... " >&6; }
11469 FONTCONFIG_LIBS=`$PKG_CONFIG --libs "fontconfig >= 2.2.0"|sed -e 's,///*,/,g'`
11470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FONTCONFIG_LIBS" >&5
11471$as_echo "$FONTCONFIG_LIBS" >&6; }
11472 else
11473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11474$as_echo "no" >&6; }
11475 FONTCONFIG_CFLAGS=""
11476 FONTCONFIG_LIBS=""
11477 ## If we have a custom action on failure, don't print errors, but
11478 ## do set a variable so people can do so.
11479 FONTCONFIG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "fontconfig >= 2.2.0"`
11480
11481 fi
11482
11483
11484
11485 else
11486 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11487 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11488 fi
11489 fi
11490
11491 if test $succeeded = yes; then
11492 HAVE_FC=yes
11493 else
11494 HAVE_FC=no
11495 fi
11496
11497
11498 ## Use -lXft if available, unless `--with-xft=no'.
11499 HAVE_XFT=maybe
11500 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
11501 with_xft="no";
11502 fi
11503 if test "x${with_xft}" != "xno"; then
11504
11505
11506 succeeded=no
11507
11508 # Extract the first word of "pkg-config", so it can be a program name with args.
11509set dummy pkg-config; ac_word=$2
11510{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11511$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 11512if ${ac_cv_path_PKG_CONFIG+:} false; then :
067d23c9
KY
11513 $as_echo_n "(cached) " >&6
11514else
11515 case $PKG_CONFIG in
11516 [\\/]* | ?:[\\/]*)
11517 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11518 ;;
11519 *)
11520 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11521for as_dir in $PATH
11522do
11523 IFS=$as_save_IFS
11524 test -z "$as_dir" && as_dir=.
11525 for ac_exec_ext in '' $ac_executable_extensions; do
11526 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11527 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11528 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11529 break 2
11530 fi
11531done
11532 done
11533IFS=$as_save_IFS
11534
11535 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11536 ;;
11537esac
11538fi
11539PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11540if test -n "$PKG_CONFIG"; then
11541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11542$as_echo "$PKG_CONFIG" >&6; }
11543else
11544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11545$as_echo "no" >&6; }
11546fi
11547
11548
11549
11550 if test "$PKG_CONFIG" = "no" ; then
11551 HAVE_XFT=no
11552 else
11553 PKG_CONFIG_MIN_VERSION=0.9.0
11554 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
11556$as_echo_n "checking for xft >= 0.13.0... " >&6; }
11557
11558 if $PKG_CONFIG --exists "xft >= 0.13.0" 2>&5; then
11559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11560$as_echo "yes" >&6; }
11561 succeeded=yes
11562
11563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking XFT_CFLAGS" >&5
11564$as_echo_n "checking XFT_CFLAGS... " >&6; }
11565 XFT_CFLAGS=`$PKG_CONFIG --cflags "xft >= 0.13.0"|sed -e 's,///*,/,g'`
11566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XFT_CFLAGS" >&5
11567$as_echo "$XFT_CFLAGS" >&6; }
11568
11569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking XFT_LIBS" >&5
11570$as_echo_n "checking XFT_LIBS... " >&6; }
11571 XFT_LIBS=`$PKG_CONFIG --libs "xft >= 0.13.0"|sed -e 's,///*,/,g'`
11572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XFT_LIBS" >&5
11573$as_echo "$XFT_LIBS" >&6; }
11574 else
11575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11576$as_echo "no" >&6; }
11577 XFT_CFLAGS=""
11578 XFT_LIBS=""
11579 ## If we have a custom action on failure, don't print errors, but
11580 ## do set a variable so people can do so.
11581 XFT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "xft >= 0.13.0"`
11582
11583 fi
11584
11585
11586
11587 else
11588 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11589 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11590 fi
11591 fi
11592
11593 if test $succeeded = yes; then
11594 :
11595 else
11596 HAVE_XFT=no
11597 fi
11598
11599 ## Because xftfont.c uses XRenderQueryExtension, we also
11600 ## need to link to -lXrender.
11601 HAVE_XRENDER=no
11602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
11603$as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
d6974efa 11604if ${ac_cv_lib_Xrender_XRenderQueryExtension+:} false; then :
067d23c9
KY
11605 $as_echo_n "(cached) " >&6
11606else
11607 ac_check_lib_save_LIBS=$LIBS
11608LIBS="-lXrender $LIBS"
11609cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11610/* end confdefs.h. */
11611
11612/* Override any GCC internal prototype to avoid an error.
11613 Use char because int might match the return type of a GCC
11614 builtin and then its argument prototype would still apply. */
11615#ifdef __cplusplus
11616extern "C"
11617#endif
11618char XRenderQueryExtension ();
11619int
11620main ()
11621{
11622return XRenderQueryExtension ();
11623 ;
11624 return 0;
11625}
11626_ACEOF
11627if ac_fn_c_try_link "$LINENO"; then :
11628 ac_cv_lib_Xrender_XRenderQueryExtension=yes
11629else
11630 ac_cv_lib_Xrender_XRenderQueryExtension=no
11631fi
11632rm -f core conftest.err conftest.$ac_objext \
11633 conftest$ac_exeext conftest.$ac_ext
11634LIBS=$ac_check_lib_save_LIBS
11635fi
11636{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
11637$as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
d6974efa 11638if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = xyes; then :
067d23c9
KY
11639 HAVE_XRENDER=yes
11640fi
11641
11642 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
11643 OLD_CPPFLAGS="$CPPFLAGS"
11644 OLD_CFLAGS="$CFLAGS"
11645 OLD_LIBS="$LIBS"
11646 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
11647 CFLAGS="$CFLAGS $XFT_CFLAGS"
11648 XFT_LIBS="-lXrender $XFT_LIBS"
11649 LIBS="$XFT_LIBS $LIBS"
11650 ac_fn_c_check_header_mongrel "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "$ac_includes_default"
d6974efa 11651if test "x$ac_cv_header_X11_Xft_Xft_h" = xyes; then :
067d23c9
KY
11652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
11653$as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
d6974efa 11654if ${ac_cv_lib_Xft_XftFontOpen+:} false; then :
067d23c9
KY
11655 $as_echo_n "(cached) " >&6
11656else
11657 ac_check_lib_save_LIBS=$LIBS
11658LIBS="-lXft $XFT_LIBS $LIBS"
11659cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11660/* end confdefs.h. */
11661
11662/* Override any GCC internal prototype to avoid an error.
11663 Use char because int might match the return type of a GCC
11664 builtin and then its argument prototype would still apply. */
11665#ifdef __cplusplus
11666extern "C"
11667#endif
11668char XftFontOpen ();
11669int
11670main ()
11671{
11672return XftFontOpen ();
11673 ;
11674 return 0;
11675}
11676_ACEOF
11677if ac_fn_c_try_link "$LINENO"; then :
11678 ac_cv_lib_Xft_XftFontOpen=yes
11679else
11680 ac_cv_lib_Xft_XftFontOpen=no
11681fi
11682rm -f core conftest.err conftest.$ac_objext \
11683 conftest$ac_exeext conftest.$ac_ext
11684LIBS=$ac_check_lib_save_LIBS
11685fi
11686{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
11687$as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
d6974efa 11688if test "x$ac_cv_lib_Xft_XftFontOpen" = xyes; then :
067d23c9
KY
11689 HAVE_XFT=yes
11690fi
11691
11692fi
11693
11694
11695
11696 if test "${HAVE_XFT}" = "yes"; then
11697
11698$as_echo "#define HAVE_XFT 1" >>confdefs.h
11699
11700
11701 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
11702 else
11703 CPPFLAGS="$OLD_CPPFLAGS"
11704 CFLAGS="$OLD_CFLAGS"
11705 LIBS="$OLD_LIBS"
11706 fi # "${HAVE_XFT}" = "yes"
11707 fi # "$HAVE_XFT" != no
11708 fi # "x${with_xft}" != "xno"
11709
11710 if test "$HAVE_XFT" != "yes"; then
11711 HAVE_XFT=no
11712 fi
11713
067d23c9
KY
11714 ## We used to allow building with FreeType and without Xft.
11715 ## However, the ftx font backend driver is not in good shape.
9ba41eb9 11716 HAVE_FREETYPE=$HAVE_XFT
067d23c9
KY
11717
11718 HAVE_LIBOTF=no
11719 if test "${HAVE_FREETYPE}" = "yes"; then
11720
11721$as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
11722
11723 if test "${with_libotf}" != "no"; then
11724
11725 succeeded=no
11726
11727 # Extract the first word of "pkg-config", so it can be a program name with args.
11728set dummy pkg-config; ac_word=$2
11729{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11730$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 11731if ${ac_cv_path_PKG_CONFIG+:} false; then :
067d23c9
KY
11732 $as_echo_n "(cached) " >&6
11733else
11734 case $PKG_CONFIG in
11735 [\\/]* | ?:[\\/]*)
11736 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11737 ;;
11738 *)
11739 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11740for as_dir in $PATH
11741do
11742 IFS=$as_save_IFS
11743 test -z "$as_dir" && as_dir=.
11744 for ac_exec_ext in '' $ac_executable_extensions; do
11745 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11746 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11747 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11748 break 2
11749 fi
11750done
11751 done
11752IFS=$as_save_IFS
11753
11754 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11755 ;;
11756esac
11757fi
11758PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11759if test -n "$PKG_CONFIG"; then
11760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11761$as_echo "$PKG_CONFIG" >&6; }
11762else
11763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11764$as_echo "no" >&6; }
11765fi
11766
11767
11768
11769 if test "$PKG_CONFIG" = "no" ; then
11770 HAVE_LIBOTF=no
11771 else
11772 PKG_CONFIG_MIN_VERSION=0.9.0
11773 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
11775$as_echo_n "checking for libotf... " >&6; }
11776
11777 if $PKG_CONFIG --exists "libotf" 2>&5; then
11778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11779$as_echo "yes" >&6; }
11780 succeeded=yes
11781
11782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBOTF_CFLAGS" >&5
11783$as_echo_n "checking LIBOTF_CFLAGS... " >&6; }
11784 LIBOTF_CFLAGS=`$PKG_CONFIG --cflags "libotf"|sed -e 's,///*,/,g'`
11785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBOTF_CFLAGS" >&5
11786$as_echo "$LIBOTF_CFLAGS" >&6; }
11787
11788 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBOTF_LIBS" >&5
11789$as_echo_n "checking LIBOTF_LIBS... " >&6; }
11790 LIBOTF_LIBS=`$PKG_CONFIG --libs "libotf"|sed -e 's,///*,/,g'`
11791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBOTF_LIBS" >&5
11792$as_echo "$LIBOTF_LIBS" >&6; }
11793 else
11794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11795$as_echo "no" >&6; }
11796 LIBOTF_CFLAGS=""
11797 LIBOTF_LIBS=""
11798 ## If we have a custom action on failure, don't print errors, but
11799 ## do set a variable so people can do so.
11800 LIBOTF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libotf"`
11801
11802 fi
11803
11804
11805
11806 else
11807 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11808 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11809 fi
11810 fi
11811
11812 if test $succeeded = yes; then
11813 HAVE_LIBOTF=yes
11814 else
11815 HAVE_LIBOTF=no
11816 fi
11817
11818 if test "$HAVE_LIBOTF" = "yes"; then
11819
11820$as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
11821
11822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
11823$as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
d6974efa 11824if ${ac_cv_lib_otf_OTF_get_variation_glyphs+:} false; then :
067d23c9
KY
11825 $as_echo_n "(cached) " >&6
11826else
11827 ac_check_lib_save_LIBS=$LIBS
11828LIBS="-lotf $LIBS"
11829cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11830/* end confdefs.h. */
11831
11832/* Override any GCC internal prototype to avoid an error.
11833 Use char because int might match the return type of a GCC
11834 builtin and then its argument prototype would still apply. */
11835#ifdef __cplusplus
11836extern "C"
11837#endif
11838char OTF_get_variation_glyphs ();
11839int
11840main ()
11841{
11842return OTF_get_variation_glyphs ();
11843 ;
11844 return 0;
11845}
11846_ACEOF
11847if ac_fn_c_try_link "$LINENO"; then :
11848 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
11849else
11850 ac_cv_lib_otf_OTF_get_variation_glyphs=no
11851fi
11852rm -f core conftest.err conftest.$ac_objext \
11853 conftest$ac_exeext conftest.$ac_ext
11854LIBS=$ac_check_lib_save_LIBS
11855fi
11856{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
11857$as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
d6974efa 11858if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = xyes; then :
067d23c9
KY
11859 HAVE_OTF_GET_VARIATION_GLYPHS=yes
11860else
11861 HAVE_OTF_GET_VARIATION_GLYPHS=no
11862fi
11863
11864 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
11865
11866$as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
11867
11868 fi
11869 fi
11870 fi
11871 fi
11872
11873 HAVE_M17N_FLT=no
11874 if test "${HAVE_LIBOTF}" = yes; then
11875 if test "${with_m17n_flt}" != "no"; then
11876
11877 succeeded=no
11878
11879 # Extract the first word of "pkg-config", so it can be a program name with args.
11880set dummy pkg-config; ac_word=$2
11881{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11882$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 11883if ${ac_cv_path_PKG_CONFIG+:} false; then :
067d23c9
KY
11884 $as_echo_n "(cached) " >&6
11885else
11886 case $PKG_CONFIG in
11887 [\\/]* | ?:[\\/]*)
11888 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11889 ;;
11890 *)
11891 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11892for as_dir in $PATH
11893do
11894 IFS=$as_save_IFS
11895 test -z "$as_dir" && as_dir=.
11896 for ac_exec_ext in '' $ac_executable_extensions; do
11897 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11898 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11899 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11900 break 2
11901 fi
11902done
11903 done
11904IFS=$as_save_IFS
11905
11906 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11907 ;;
11908esac
11909fi
11910PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11911if test -n "$PKG_CONFIG"; then
11912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11913$as_echo "$PKG_CONFIG" >&6; }
11914else
11915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11916$as_echo "no" >&6; }
11917fi
11918
11919
11920
11921 if test "$PKG_CONFIG" = "no" ; then
11922 HAVE_M17N_FLT=no
11923 else
11924 PKG_CONFIG_MIN_VERSION=0.9.0
11925 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11926 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
11927$as_echo_n "checking for m17n-flt... " >&6; }
11928
11929 if $PKG_CONFIG --exists "m17n-flt" 2>&5; then
11930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11931$as_echo "yes" >&6; }
11932 succeeded=yes
11933
11934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking M17N_FLT_CFLAGS" >&5
11935$as_echo_n "checking M17N_FLT_CFLAGS... " >&6; }
11936 M17N_FLT_CFLAGS=`$PKG_CONFIG --cflags "m17n-flt"|sed -e 's,///*,/,g'`
11937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $M17N_FLT_CFLAGS" >&5
11938$as_echo "$M17N_FLT_CFLAGS" >&6; }
11939
11940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking M17N_FLT_LIBS" >&5
11941$as_echo_n "checking M17N_FLT_LIBS... " >&6; }
11942 M17N_FLT_LIBS=`$PKG_CONFIG --libs "m17n-flt"|sed -e 's,///*,/,g'`
11943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $M17N_FLT_LIBS" >&5
11944$as_echo "$M17N_FLT_LIBS" >&6; }
11945 else
11946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11947$as_echo "no" >&6; }
11948 M17N_FLT_CFLAGS=""
11949 M17N_FLT_LIBS=""
11950 ## If we have a custom action on failure, don't print errors, but
11951 ## do set a variable so people can do so.
11952 M17N_FLT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "m17n-flt"`
11953
11954 fi
11955
11956
11957
11958 else
11959 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11960 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11961 fi
11962 fi
11963
11964 if test $succeeded = yes; then
11965 HAVE_M17N_FLT=yes
11966 else
11967 HAVE_M17N_FLT=no
11968 fi
11969
11970 if test "$HAVE_M17N_FLT" = "yes"; then
11971
11972$as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
11973
11974 fi
11975 fi
11976 fi
11977else
11978 HAVE_XFT=no
11979 HAVE_FREETYPE=no
11980 HAVE_LIBOTF=no
11981 HAVE_M17N_FLT=no
11982fi
11983
11984### End of font-backend (under X11) section.
11985
11986
11987
11988
11989
11990
11991
11992
11993
11994
11995### Use -lXpm if available, unless `--with-xpm=no'.
11996HAVE_XPM=no
11997LIBXPM=
11998if test "${HAVE_X11}" = "yes"; then
11999 if test "${with_xpm}" != "no"; then
12000 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
d6974efa 12001if test "x$ac_cv_header_X11_xpm_h" = xyes; then :
067d23c9
KY
12002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
12003$as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
d6974efa 12004if ${ac_cv_lib_Xpm_XpmReadFileToPixmap+:} false; then :
067d23c9
KY
12005 $as_echo_n "(cached) " >&6
12006else
12007 ac_check_lib_save_LIBS=$LIBS
12008LIBS="-lXpm -lX11 $LIBS"
12009cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12010/* end confdefs.h. */
12011
12012/* Override any GCC internal prototype to avoid an error.
12013 Use char because int might match the return type of a GCC
12014 builtin and then its argument prototype would still apply. */
12015#ifdef __cplusplus
12016extern "C"
12017#endif
12018char XpmReadFileToPixmap ();
12019int
12020main ()
12021{
12022return XpmReadFileToPixmap ();
12023 ;
12024 return 0;
12025}
12026_ACEOF
12027if ac_fn_c_try_link "$LINENO"; then :
12028 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
12029else
12030 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
12031fi
12032rm -f core conftest.err conftest.$ac_objext \
12033 conftest$ac_exeext conftest.$ac_ext
12034LIBS=$ac_check_lib_save_LIBS
12035fi
12036{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
12037$as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
d6974efa 12038if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = xyes; then :
067d23c9
KY
12039 HAVE_XPM=yes
12040fi
12041
12042fi
12043
12044
12045 if test "${HAVE_XPM}" = "yes"; then
12046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
12047$as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
12048 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12049/* end confdefs.h. */
12050#include "X11/xpm.h"
12051#ifndef XpmReturnAllocPixels
12052no_return_alloc_pixels
12053#endif
12054
12055_ACEOF
12056if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12057 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
12058 HAVE_XPM=no
12059else
12060 HAVE_XPM=yes
12061fi
12062rm -f conftest*
12063
12064
12065 if test "${HAVE_XPM}" = "yes"; then
12066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12067$as_echo "yes" >&6; }
12068 else
12069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12070$as_echo "no" >&6; }
12071 fi
12072 fi
12073 fi
12074
12075 if test "${HAVE_XPM}" = "yes"; then
12076
12077$as_echo "#define HAVE_XPM 1" >>confdefs.h
12078
12079 LIBXPM=-lXpm
12080 fi
12081fi
12082
12083
12084### Use -ljpeg if available, unless `--with-jpeg=no'.
12085HAVE_JPEG=no
12086LIBJPEG=
12087if test "${HAVE_X11}" = "yes"; then
12088 if test "${with_jpeg}" != "no"; then
12089 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
d6974efa 12090if test "x$ac_cv_header_jerror_h" = xyes; then :
067d23c9
KY
12091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
12092$as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
d6974efa 12093if ${ac_cv_lib_jpeg_jpeg_destroy_compress+:} false; then :
067d23c9
KY
12094 $as_echo_n "(cached) " >&6
12095else
12096 ac_check_lib_save_LIBS=$LIBS
12097LIBS="-ljpeg $LIBS"
12098cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12099/* end confdefs.h. */
12100
12101/* Override any GCC internal prototype to avoid an error.
12102 Use char because int might match the return type of a GCC
12103 builtin and then its argument prototype would still apply. */
12104#ifdef __cplusplus
12105extern "C"
12106#endif
12107char jpeg_destroy_compress ();
12108int
12109main ()
12110{
12111return jpeg_destroy_compress ();
12112 ;
12113 return 0;
12114}
12115_ACEOF
12116if ac_fn_c_try_link "$LINENO"; then :
12117 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
12118else
12119 ac_cv_lib_jpeg_jpeg_destroy_compress=no
12120fi
12121rm -f core conftest.err conftest.$ac_objext \
12122 conftest$ac_exeext conftest.$ac_ext
12123LIBS=$ac_check_lib_save_LIBS
12124fi
12125{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
12126$as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
d6974efa 12127if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = xyes; then :
067d23c9
KY
12128 HAVE_JPEG=yes
12129fi
12130
12131fi
12132
12133
12134 fi
12135
12136 if test "${HAVE_JPEG}" = "yes"; then
12137 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12138
12139 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12140/* end confdefs.h. */
12141#include <jpeglib.h>
12142 version=JPEG_LIB_VERSION
12143
12144_ACEOF
12145if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12146 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
12147 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12148
12149else
12150 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
12151$as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
12152 HAVE_JPEG=no
12153fi
12154rm -f conftest*
12155
12156 fi
12157 if test "${HAVE_JPEG}" = "yes"; then
12158 LIBJPEG=-ljpeg
12159 fi
12160fi
12161
12162
12163### Use -lpng if available, unless `--with-png=no'.
12164HAVE_PNG=no
12165LIBPNG=
12166if test "${HAVE_X11}" = "yes"; then
12167 if test "${with_png}" != "no"; then
12168 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
12169 # in /usr/include/libpng.
12170 for ac_header in png.h libpng/png.h
12171do :
12172 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12173ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
2018939f 12174if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
067d23c9
KY
12175 cat >>confdefs.h <<_ACEOF
12176#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12177_ACEOF
12178
12179fi
12180
12181done
12182
12183 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
12184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
12185$as_echo_n "checking for png_get_channels in -lpng... " >&6; }
d6974efa 12186if ${ac_cv_lib_png_png_get_channels+:} false; then :
067d23c9
KY
12187 $as_echo_n "(cached) " >&6
12188else
12189 ac_check_lib_save_LIBS=$LIBS
12190LIBS="-lpng -lz -lm $LIBS"
12191cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12192/* end confdefs.h. */
12193
12194/* Override any GCC internal prototype to avoid an error.
12195 Use char because int might match the return type of a GCC
12196 builtin and then its argument prototype would still apply. */
12197#ifdef __cplusplus
12198extern "C"
12199#endif
12200char png_get_channels ();
12201int
12202main ()
12203{
12204return png_get_channels ();
12205 ;
12206 return 0;
12207}
12208_ACEOF
12209if ac_fn_c_try_link "$LINENO"; then :
12210 ac_cv_lib_png_png_get_channels=yes
12211else
12212 ac_cv_lib_png_png_get_channels=no
12213fi
12214rm -f core conftest.err conftest.$ac_objext \
12215 conftest$ac_exeext conftest.$ac_ext
12216LIBS=$ac_check_lib_save_LIBS
12217fi
12218{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
12219$as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
d6974efa 12220if test "x$ac_cv_lib_png_png_get_channels" = xyes; then :
067d23c9
KY
12221 HAVE_PNG=yes
12222fi
12223
12224 fi
12225 fi
12226
12227 if test "${HAVE_PNG}" = "yes"; then
12228
12229$as_echo "#define HAVE_PNG 1" >>confdefs.h
12230
12231 LIBPNG="-lpng -lz -lm"
12232 fi
12233fi
12234
12235
12236### Use -ltiff if available, unless `--with-tiff=no'.
12237HAVE_TIFF=no
12238LIBTIFF=
12239if test "${HAVE_X11}" = "yes"; then
12240 if test "${with_tiff}" != "no"; then
12241 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
d6974efa 12242if test "x$ac_cv_header_tiffio_h" = xyes; then :
067d23c9
KY
12243 tifflibs="-lz -lm"
12244 # At least one tiff package requires the jpeg library.
12245 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
12246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
12247$as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
d6974efa 12248if ${ac_cv_lib_tiff_TIFFGetVersion+:} false; then :
067d23c9
KY
12249 $as_echo_n "(cached) " >&6
12250else
12251 ac_check_lib_save_LIBS=$LIBS
12252LIBS="-ltiff $tifflibs $LIBS"
12253cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12254/* end confdefs.h. */
12255
12256/* Override any GCC internal prototype to avoid an error.
12257 Use char because int might match the return type of a GCC
12258 builtin and then its argument prototype would still apply. */
12259#ifdef __cplusplus
12260extern "C"
12261#endif
12262char TIFFGetVersion ();
12263int
12264main ()
12265{
12266return TIFFGetVersion ();
12267 ;
12268 return 0;
12269}
12270_ACEOF
12271if ac_fn_c_try_link "$LINENO"; then :
12272 ac_cv_lib_tiff_TIFFGetVersion=yes
12273else
12274 ac_cv_lib_tiff_TIFFGetVersion=no
12275fi
12276rm -f core conftest.err conftest.$ac_objext \
12277 conftest$ac_exeext conftest.$ac_ext
12278LIBS=$ac_check_lib_save_LIBS
12279fi
12280{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
12281$as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
d6974efa 12282if test "x$ac_cv_lib_tiff_TIFFGetVersion" = xyes; then :
067d23c9
KY
12283 HAVE_TIFF=yes
12284fi
12285
12286fi
12287
12288
12289 fi
12290
12291 if test "${HAVE_TIFF}" = "yes"; then
12292
12293$as_echo "#define HAVE_TIFF 1" >>confdefs.h
12294
12295 LIBTIFF=-ltiff
12296 fi
12297fi
12298
12299
12300### Use -lgif or -lungif if available, unless `--with-gif=no'.
12301HAVE_GIF=no
12302LIBGIF=
12303if test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no"; then
12304 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
d6974efa 12305if test "x$ac_cv_header_gif_lib_h" = xyes; then :
067d23c9
KY
12306 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
12307# Earlier versions can crash Emacs.
12308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
12309$as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
d6974efa 12310if ${ac_cv_lib_gif_EGifPutExtensionLast+:} false; then :
067d23c9
KY
12311 $as_echo_n "(cached) " >&6
12312else
12313 ac_check_lib_save_LIBS=$LIBS
12314LIBS="-lgif $LIBS"
12315cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12316/* end confdefs.h. */
12317
12318/* Override any GCC internal prototype to avoid an error.
12319 Use char because int might match the return type of a GCC
12320 builtin and then its argument prototype would still apply. */
12321#ifdef __cplusplus
12322extern "C"
12323#endif
12324char EGifPutExtensionLast ();
12325int
12326main ()
12327{
12328return EGifPutExtensionLast ();
12329 ;
12330 return 0;
12331}
12332_ACEOF
12333if ac_fn_c_try_link "$LINENO"; then :
12334 ac_cv_lib_gif_EGifPutExtensionLast=yes
12335else
12336 ac_cv_lib_gif_EGifPutExtensionLast=no
12337fi
12338rm -f core conftest.err conftest.$ac_objext \
12339 conftest$ac_exeext conftest.$ac_ext
12340LIBS=$ac_check_lib_save_LIBS
12341fi
12342{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
12343$as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
d6974efa 12344if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = xyes; then :
067d23c9
KY
12345 HAVE_GIF=yes
12346else
12347 HAVE_GIF=maybe
12348fi
12349
12350fi
12351
12352
12353
12354 if test "$HAVE_GIF" = yes; then
12355 LIBGIF=-lgif
12356 elif test "$HAVE_GIF" = maybe; then
12357# If gif_lib.h but no libgif, try libungif.
12358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
12359$as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
d6974efa 12360if ${ac_cv_lib_ungif_EGifPutExtensionLast+:} false; then :
067d23c9
KY
12361 $as_echo_n "(cached) " >&6
12362else
12363 ac_check_lib_save_LIBS=$LIBS
12364LIBS="-lungif $LIBS"
12365cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12366/* end confdefs.h. */
12367
12368/* Override any GCC internal prototype to avoid an error.
12369 Use char because int might match the return type of a GCC
12370 builtin and then its argument prototype would still apply. */
12371#ifdef __cplusplus
12372extern "C"
12373#endif
12374char EGifPutExtensionLast ();
12375int
12376main ()
12377{
12378return EGifPutExtensionLast ();
12379 ;
12380 return 0;
12381}
12382_ACEOF
12383if ac_fn_c_try_link "$LINENO"; then :
12384 ac_cv_lib_ungif_EGifPutExtensionLast=yes
12385else
12386 ac_cv_lib_ungif_EGifPutExtensionLast=no
12387fi
12388rm -f core conftest.err conftest.$ac_objext \
12389 conftest$ac_exeext conftest.$ac_ext
12390LIBS=$ac_check_lib_save_LIBS
12391fi
12392{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
12393$as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
d6974efa 12394if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = xyes; then :
067d23c9
KY
12395 HAVE_GIF=yes
12396else
12397 HAVE_GIF=no
12398fi
12399
12400 test "$HAVE_GIF" = yes && LIBGIF=-lungif
12401 fi
12402
12403 if test "${HAVE_GIF}" = "yes"; then
12404
12405$as_echo "#define HAVE_GIF 1" >>confdefs.h
12406
12407 fi
12408fi
12409
12410
12411if test "${HAVE_X11}" = "yes"; then
12412 MISSING=""
12413 WITH_NO=""
12414 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
12415 MISSING="libXpm" && WITH_NO="--with-xpm=no"
12416 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
12417 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
12418 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
12419 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
12420 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
12421 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
12422 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
12423 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
12424
12425 if test "X${MISSING}" != X; then
2018939f 12426 as_fn_error $? "The following required libraries were not found:
067d23c9
KY
12427 $MISSING
12428Maybe some development libraries/packages are missing?
12429If you don't want to link with them give
12430 $WITH_NO
12431as options to configure" "$LINENO" 5
12432 fi
12433fi
12434
12435### Use -lgpm if available, unless `--with-gpm=no'.
12436HAVE_GPM=no
12437LIBGPM=
12438MOUSE_SUPPORT=
12439if test "${with_gpm}" != "no"; then
12440 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
d6974efa 12441if test "x$ac_cv_header_gpm_h" = xyes; then :
067d23c9
KY
12442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
12443$as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
d6974efa 12444if ${ac_cv_lib_gpm_Gpm_Open+:} false; then :
067d23c9
KY
12445 $as_echo_n "(cached) " >&6
12446else
12447 ac_check_lib_save_LIBS=$LIBS
12448LIBS="-lgpm $LIBS"
12449cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12450/* end confdefs.h. */
12451
12452/* Override any GCC internal prototype to avoid an error.
12453 Use char because int might match the return type of a GCC
12454 builtin and then its argument prototype would still apply. */
12455#ifdef __cplusplus
12456extern "C"
12457#endif
12458char Gpm_Open ();
12459int
12460main ()
12461{
12462return Gpm_Open ();
12463 ;
12464 return 0;
12465}
12466_ACEOF
12467if ac_fn_c_try_link "$LINENO"; then :
12468 ac_cv_lib_gpm_Gpm_Open=yes
12469else
12470 ac_cv_lib_gpm_Gpm_Open=no
12471fi
12472rm -f core conftest.err conftest.$ac_objext \
12473 conftest$ac_exeext conftest.$ac_ext
12474LIBS=$ac_check_lib_save_LIBS
12475fi
12476{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
12477$as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
d6974efa 12478if test "x$ac_cv_lib_gpm_Gpm_Open" = xyes; then :
067d23c9
KY
12479 HAVE_GPM=yes
12480fi
12481
12482fi
12483
12484
12485
12486 if test "${HAVE_GPM}" = "yes"; then
12487
12488$as_echo "#define HAVE_GPM 1" >>confdefs.h
12489
12490 LIBGPM=-lgpm
12491 ## May be reset below.
12492 MOUSE_SUPPORT="\$(GPM_MOUSE_SUPPORT)"
12493 fi
12494fi
12495
12496
12497ac_fn_c_check_header_mongrel "$LINENO" "malloc/malloc.h" "ac_cv_header_malloc_malloc_h" "$ac_includes_default"
d6974efa 12498if test "x$ac_cv_header_malloc_malloc_h" = xyes; then :
067d23c9
KY
12499
12500$as_echo "#define HAVE_MALLOC_MALLOC_H 1" >>confdefs.h
12501
12502fi
12503
12504
12505
12506C_SWITCH_X_SYSTEM=
12507### Use NeXTstep API to implement GUI.
12508if test "${HAVE_NS}" = "yes"; then
12509
12510$as_echo "#define HAVE_NS 1" >>confdefs.h
12511
12512 if test "${NS_IMPL_COCOA}" = "yes"; then
12513
12514$as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
12515
12516 GNU_OBJC_CFLAGS=
12517 fi
12518 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
12519
12520$as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
12521
12522 # See also .m.o rule in Makefile.in */
12523 # FIXME: are all these flags really needed? Document here why. */
12524 C_SWITCH_X_SYSTEM="-D_REENTRANT -fPIC -fno-strict-aliasing"
12525 GNU_OBJC_CFLAGS="-fgnu-runtime -Wno-import -fconstant-string-class=NSConstantString -DGNUSTEP_BASE_LIBRARY=1 -DGNU_GUI_LIBRARY=1 -DGNU_RUNTIME=1 -DGSWARN -DGSDIAGNOSE"
12526 fi
12527 if test "${NS_HAVE_NSINTEGER}" = "yes"; then
12528
12529$as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
12530
12531 fi
12532 # We also have mouse menus.
12533 HAVE_MENUS=yes
12534 OTHER_FILES=ns-app
12535fi
12536
12537
12538### Use session management (-lSM -lICE) if available
12539HAVE_X_SM=no
12540LIBXSM=
12541if test "${HAVE_X11}" = "yes"; then
12542 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
d6974efa 12543if test "x$ac_cv_header_X11_SM_SMlib_h" = xyes; then :
067d23c9
KY
12544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
12545$as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
d6974efa 12546if ${ac_cv_lib_SM_SmcOpenConnection+:} false; then :
067d23c9
KY
12547 $as_echo_n "(cached) " >&6
12548else
12549 ac_check_lib_save_LIBS=$LIBS
12550LIBS="-lSM -lICE $LIBS"
12551cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12552/* end confdefs.h. */
12553
12554/* Override any GCC internal prototype to avoid an error.
12555 Use char because int might match the return type of a GCC
12556 builtin and then its argument prototype would still apply. */
12557#ifdef __cplusplus
12558extern "C"
12559#endif
12560char SmcOpenConnection ();
12561int
12562main ()
12563{
12564return SmcOpenConnection ();
12565 ;
12566 return 0;
12567}
12568_ACEOF
12569if ac_fn_c_try_link "$LINENO"; then :
12570 ac_cv_lib_SM_SmcOpenConnection=yes
12571else
12572 ac_cv_lib_SM_SmcOpenConnection=no
12573fi
12574rm -f core conftest.err conftest.$ac_objext \
12575 conftest$ac_exeext conftest.$ac_ext
12576LIBS=$ac_check_lib_save_LIBS
12577fi
12578{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
12579$as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
d6974efa 12580if test "x$ac_cv_lib_SM_SmcOpenConnection" = xyes; then :
067d23c9
KY
12581 HAVE_X_SM=yes
12582fi
12583
12584fi
12585
12586
12587
12588 if test "${HAVE_X_SM}" = "yes"; then
12589
12590$as_echo "#define HAVE_X_SM 1" >>confdefs.h
12591
12592 LIBXSM="-lSM -lICE"
12593 case "$LIBS" in
12594 *-lSM*) ;;
12595 *) LIBS="$LIBXSM $LIBS" ;;
12596 esac
12597 fi
12598fi
12599
12600
12601### Use libxml (-lxml2) if available
12602if test "${with_xml2}" != "no"; then
12603 ### I'm not sure what the version number should be, so I just guessed.
12604
12605 succeeded=no
12606
12607 # Extract the first word of "pkg-config", so it can be a program name with args.
12608set dummy pkg-config; ac_word=$2
12609{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12610$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 12611if ${ac_cv_path_PKG_CONFIG+:} false; then :
067d23c9
KY
12612 $as_echo_n "(cached) " >&6
12613else
12614 case $PKG_CONFIG in
12615 [\\/]* | ?:[\\/]*)
12616 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
12617 ;;
12618 *)
12619 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12620for as_dir in $PATH
12621do
12622 IFS=$as_save_IFS
12623 test -z "$as_dir" && as_dir=.
12624 for ac_exec_ext in '' $ac_executable_extensions; do
12625 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12626 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
12627 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12628 break 2
12629 fi
12630done
12631 done
12632IFS=$as_save_IFS
12633
12634 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
12635 ;;
12636esac
12637fi
12638PKG_CONFIG=$ac_cv_path_PKG_CONFIG
12639if test -n "$PKG_CONFIG"; then
12640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
12641$as_echo "$PKG_CONFIG" >&6; }
12642else
12643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12644$as_echo "no" >&6; }
12645fi
12646
12647
12648
12649 if test "$PKG_CONFIG" = "no" ; then
12650 HAVE_LIBXML2=no
12651 else
12652 PKG_CONFIG_MIN_VERSION=0.9.0
12653 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
dab73760
CY
12654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
12655$as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
067d23c9 12656
dab73760 12657 if $PKG_CONFIG --exists "libxml-2.0 > 2.6.17" 2>&5; then
067d23c9
KY
12658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12659$as_echo "yes" >&6; }
12660 succeeded=yes
12661
12662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBXML2_CFLAGS" >&5
12663$as_echo_n "checking LIBXML2_CFLAGS... " >&6; }
dab73760 12664 LIBXML2_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 > 2.6.17"|sed -e 's,///*,/,g'`
067d23c9
KY
12665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBXML2_CFLAGS" >&5
12666$as_echo "$LIBXML2_CFLAGS" >&6; }
12667
12668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBXML2_LIBS" >&5
12669$as_echo_n "checking LIBXML2_LIBS... " >&6; }
dab73760 12670 LIBXML2_LIBS=`$PKG_CONFIG --libs "libxml-2.0 > 2.6.17"|sed -e 's,///*,/,g'`
067d23c9
KY
12671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBXML2_LIBS" >&5
12672$as_echo "$LIBXML2_LIBS" >&6; }
12673 else
12674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12675$as_echo "no" >&6; }
12676 LIBXML2_CFLAGS=""
12677 LIBXML2_LIBS=""
12678 ## If we have a custom action on failure, don't print errors, but
12679 ## do set a variable so people can do so.
dab73760 12680 LIBXML2_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libxml-2.0 > 2.6.17"`
067d23c9
KY
12681
12682 fi
12683
12684
12685
12686 else
12687 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12688 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12689 fi
12690 fi
12691
12692 if test $succeeded = yes; then
12693 HAVE_LIBXML2=yes
12694 else
12695 HAVE_LIBXML2=no
12696 fi
12697
12698 if test "${HAVE_LIBXML2}" = "yes"; then
12699 LIBS="$LIBXML2_LIBS $LIBS"
12700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
12701$as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
d6974efa 12702if ${ac_cv_lib_xml2_htmlReadMemory+:} false; then :
067d23c9
KY
12703 $as_echo_n "(cached) " >&6
12704else
12705 ac_check_lib_save_LIBS=$LIBS
12706LIBS="-lxml2 $LIBS"
12707cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12708/* end confdefs.h. */
12709
12710/* Override any GCC internal prototype to avoid an error.
12711 Use char because int might match the return type of a GCC
12712 builtin and then its argument prototype would still apply. */
12713#ifdef __cplusplus
12714extern "C"
12715#endif
12716char htmlReadMemory ();
12717int
12718main ()
12719{
12720return htmlReadMemory ();
12721 ;
12722 return 0;
12723}
12724_ACEOF
12725if ac_fn_c_try_link "$LINENO"; then :
12726 ac_cv_lib_xml2_htmlReadMemory=yes
12727else
12728 ac_cv_lib_xml2_htmlReadMemory=no
12729fi
12730rm -f core conftest.err conftest.$ac_objext \
12731 conftest$ac_exeext conftest.$ac_ext
12732LIBS=$ac_check_lib_save_LIBS
12733fi
12734{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
12735$as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
d6974efa 12736if test "x$ac_cv_lib_xml2_htmlReadMemory" = xyes; then :
067d23c9
KY
12737 HAVE_LIBXML2=yes
12738else
12739 HAVE_LIBXML2=no
12740fi
12741
12742 if test "${HAVE_LIBXML2}" = "yes"; then
12743
12744$as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
12745
12746 else
12747 LIBXML2_LIBS=""
12748 LIBXML2_CFLAGS=""
12749 fi
12750 fi
12751fi
12752
12753
12754
12755# If netdb.h doesn't declare h_errno, we must declare it by hand.
12756{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
12757$as_echo_n "checking whether netdb declares h_errno... " >&6; }
d6974efa 12758if ${emacs_cv_netdb_declares_h_errno+:} false; then :
067d23c9
KY
12759 $as_echo_n "(cached) " >&6
12760else
12761 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12762/* end confdefs.h. */
12763#include <netdb.h>
12764int
12765main ()
12766{
12767return h_errno;
12768 ;
12769 return 0;
12770}
12771_ACEOF
12772if ac_fn_c_try_link "$LINENO"; then :
12773 emacs_cv_netdb_declares_h_errno=yes
12774else
12775 emacs_cv_netdb_declares_h_errno=no
12776fi
12777rm -f core conftest.err conftest.$ac_objext \
12778 conftest$ac_exeext conftest.$ac_ext
12779fi
12780{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
12781$as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
12782if test $emacs_cv_netdb_declares_h_errno = yes; then
12783
12784$as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
12785
12786fi
12787
d6974efa
PE
12788ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
12789if test "x$ac_cv_type_size_t" = xyes; then :
12790
12791else
12792
12793cat >>confdefs.h <<_ACEOF
12794#define size_t unsigned int
12795_ACEOF
12796
12797fi
12798
067d23c9
KY
12799# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
12800# for constant arguments. Useless!
12801{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
12802$as_echo_n "checking for working alloca.h... " >&6; }
d6974efa 12803if ${ac_cv_working_alloca_h+:} false; then :
067d23c9
KY
12804 $as_echo_n "(cached) " >&6
12805else
12806 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12807/* end confdefs.h. */
12808#include <alloca.h>
12809int
12810main ()
12811{
12812char *p = (char *) alloca (2 * sizeof (int));
12813 if (p) return 0;
12814 ;
12815 return 0;
12816}
12817_ACEOF
12818if ac_fn_c_try_link "$LINENO"; then :
12819 ac_cv_working_alloca_h=yes
12820else
12821 ac_cv_working_alloca_h=no
12822fi
12823rm -f core conftest.err conftest.$ac_objext \
12824 conftest$ac_exeext conftest.$ac_ext
12825fi
12826{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
12827$as_echo "$ac_cv_working_alloca_h" >&6; }
12828if test $ac_cv_working_alloca_h = yes; then
12829
12830$as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
12831
12832fi
12833
12834{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
12835$as_echo_n "checking for alloca... " >&6; }
d6974efa 12836if ${ac_cv_func_alloca_works+:} false; then :
067d23c9
KY
12837 $as_echo_n "(cached) " >&6
12838else
12839 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12840/* end confdefs.h. */
12841#ifdef __GNUC__
12842# define alloca __builtin_alloca
12843#else
12844# ifdef _MSC_VER
12845# include <malloc.h>
12846# define alloca _alloca
12847# else
12848# ifdef HAVE_ALLOCA_H
12849# include <alloca.h>
12850# else
12851# ifdef _AIX
12852 #pragma alloca
12853# else
12854# ifndef alloca /* predefined by HP cc +Olibcalls */
d6974efa 12855void *alloca (size_t);
067d23c9
KY
12856# endif
12857# endif
12858# endif
12859# endif
12860#endif
12861
12862int
12863main ()
12864{
12865char *p = (char *) alloca (1);
12866 if (p) return 0;
12867 ;
12868 return 0;
12869}
12870_ACEOF
12871if ac_fn_c_try_link "$LINENO"; then :
12872 ac_cv_func_alloca_works=yes
12873else
12874 ac_cv_func_alloca_works=no
12875fi
12876rm -f core conftest.err conftest.$ac_objext \
12877 conftest$ac_exeext conftest.$ac_ext
12878fi
12879{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
12880$as_echo "$ac_cv_func_alloca_works" >&6; }
12881
12882if test $ac_cv_func_alloca_works = yes; then
12883
12884$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
12885
12886else
12887 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
12888# that cause trouble. Some versions do not even contain alloca or
12889# contain a buggy version. If you still want to use their alloca,
12890# use ar to extract alloca.o from them instead of compiling alloca.c.
12891
12892ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
12893
12894$as_echo "#define C_ALLOCA 1" >>confdefs.h
12895
12896
12897{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
12898$as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
d6974efa 12899if ${ac_cv_os_cray+:} false; then :
067d23c9
KY
12900 $as_echo_n "(cached) " >&6
12901else
12902 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12903/* end confdefs.h. */
12904#if defined CRAY && ! defined CRAY2
12905webecray
12906#else
12907wenotbecray
12908#endif
12909
12910_ACEOF
12911if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12912 $EGREP "webecray" >/dev/null 2>&1; then :
12913 ac_cv_os_cray=yes
12914else
12915 ac_cv_os_cray=no
12916fi
12917rm -f conftest*
12918
12919fi
12920{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
12921$as_echo "$ac_cv_os_cray" >&6; }
12922if test $ac_cv_os_cray = yes; then
12923 for ac_func in _getb67 GETB67 getb67; do
12924 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12925ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
2018939f 12926if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
067d23c9
KY
12927
12928cat >>confdefs.h <<_ACEOF
12929#define CRAY_STACKSEG_END $ac_func
12930_ACEOF
12931
12932 break
12933fi
12934
12935 done
12936fi
12937
12938{ $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
12939$as_echo_n "checking stack direction for C alloca... " >&6; }
d6974efa 12940if ${ac_cv_c_stack_direction+:} false; then :
067d23c9
KY
12941 $as_echo_n "(cached) " >&6
12942else
12943 if test "$cross_compiling" = yes; then :
12944 ac_cv_c_stack_direction=0
12945else
12946 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12947/* end confdefs.h. */
12948$ac_includes_default
12949int
12950find_stack_direction ()
12951{
12952 static char *addr = 0;
12953 auto char dummy;
12954 if (addr == 0)
12955 {
12956 addr = &dummy;
12957 return find_stack_direction ();
12958 }
12959 else
12960 return (&dummy > addr) ? 1 : -1;
12961}
12962
12963int
12964main ()
12965{
12966 return find_stack_direction () < 0;
12967}
12968_ACEOF
12969if ac_fn_c_try_run "$LINENO"; then :
12970 ac_cv_c_stack_direction=1
12971else
12972 ac_cv_c_stack_direction=-1
12973fi
12974rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12975 conftest.$ac_objext conftest.beam conftest.$ac_ext
12976fi
12977
12978fi
12979{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
12980$as_echo "$ac_cv_c_stack_direction" >&6; }
12981cat >>confdefs.h <<_ACEOF
12982#define STACK_DIRECTION $ac_cv_c_stack_direction
12983_ACEOF
12984
12985
12986fi
12987
12988
12989if test x"$ac_cv_func_alloca_works" != xyes; then
2018939f 12990 as_fn_error $? "a system implementation of alloca is required " "$LINENO" 5
067d23c9
KY
12991fi
12992
12993# fmod, logb, and frexp are found in -lm on most systems.
12994# On HPUX 9.01, -lm does not contain logb, so check for sqrt.
12995{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
12996$as_echo_n "checking for sqrt in -lm... " >&6; }
d6974efa 12997if ${ac_cv_lib_m_sqrt+:} false; then :
067d23c9
KY
12998 $as_echo_n "(cached) " >&6
12999else
13000 ac_check_lib_save_LIBS=$LIBS
13001LIBS="-lm $LIBS"
13002cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13003/* end confdefs.h. */
13004
13005/* Override any GCC internal prototype to avoid an error.
13006 Use char because int might match the return type of a GCC
13007 builtin and then its argument prototype would still apply. */
13008#ifdef __cplusplus
13009extern "C"
13010#endif
13011char sqrt ();
13012int
13013main ()
13014{
13015return sqrt ();
13016 ;
13017 return 0;
13018}
13019_ACEOF
13020if ac_fn_c_try_link "$LINENO"; then :
13021 ac_cv_lib_m_sqrt=yes
13022else
13023 ac_cv_lib_m_sqrt=no
13024fi
13025rm -f core conftest.err conftest.$ac_objext \
13026 conftest$ac_exeext conftest.$ac_ext
13027LIBS=$ac_check_lib_save_LIBS
13028fi
13029{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
13030$as_echo "$ac_cv_lib_m_sqrt" >&6; }
d6974efa 13031if test "x$ac_cv_lib_m_sqrt" = xyes; then :
067d23c9
KY
13032 cat >>confdefs.h <<_ACEOF
13033#define HAVE_LIBM 1
13034_ACEOF
13035
13036 LIBS="-lm $LIBS"
13037
13038fi
13039
13040
13041# Check for mail-locking functions in a "mail" library. Probably this should
13042# have the same check as for liblockfile below.
13043{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
13044$as_echo_n "checking for maillock in -lmail... " >&6; }
d6974efa 13045if ${ac_cv_lib_mail_maillock+:} false; then :
067d23c9
KY
13046 $as_echo_n "(cached) " >&6
13047else
13048 ac_check_lib_save_LIBS=$LIBS
13049LIBS="-lmail $LIBS"
13050cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13051/* end confdefs.h. */
13052
13053/* Override any GCC internal prototype to avoid an error.
13054 Use char because int might match the return type of a GCC
13055 builtin and then its argument prototype would still apply. */
13056#ifdef __cplusplus
13057extern "C"
13058#endif
13059char maillock ();
13060int
13061main ()
13062{
13063return maillock ();
13064 ;
13065 return 0;
13066}
13067_ACEOF
13068if ac_fn_c_try_link "$LINENO"; then :
13069 ac_cv_lib_mail_maillock=yes
13070else
13071 ac_cv_lib_mail_maillock=no
13072fi
13073rm -f core conftest.err conftest.$ac_objext \
13074 conftest$ac_exeext conftest.$ac_ext
13075LIBS=$ac_check_lib_save_LIBS
13076fi
13077{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
13078$as_echo "$ac_cv_lib_mail_maillock" >&6; }
d6974efa 13079if test "x$ac_cv_lib_mail_maillock" = xyes; then :
067d23c9
KY
13080 have_mail=yes
13081else
13082 have_mail=no
13083fi
13084
13085if test $have_mail = yes; then
13086 LIBS_MAIL=-lmail
13087 LIBS="$LIBS_MAIL $LIBS"
13088
13089$as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
13090
13091else
13092 LIBS_MAIL=
13093fi
13094{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
13095$as_echo_n "checking for maillock in -llockfile... " >&6; }
d6974efa 13096if ${ac_cv_lib_lockfile_maillock+:} false; then :
067d23c9
KY
13097 $as_echo_n "(cached) " >&6
13098else
13099 ac_check_lib_save_LIBS=$LIBS
13100LIBS="-llockfile $LIBS"
13101cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13102/* end confdefs.h. */
13103
13104/* Override any GCC internal prototype to avoid an error.
13105 Use char because int might match the return type of a GCC
13106 builtin and then its argument prototype would still apply. */
13107#ifdef __cplusplus
13108extern "C"
13109#endif
13110char maillock ();
13111int
13112main ()
13113{
13114return maillock ();
13115 ;
13116 return 0;
13117}
13118_ACEOF
13119if ac_fn_c_try_link "$LINENO"; then :
13120 ac_cv_lib_lockfile_maillock=yes
13121else
13122 ac_cv_lib_lockfile_maillock=no
13123fi
13124rm -f core conftest.err conftest.$ac_objext \
13125 conftest$ac_exeext conftest.$ac_ext
13126LIBS=$ac_check_lib_save_LIBS
13127fi
13128{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
13129$as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
d6974efa 13130if test "x$ac_cv_lib_lockfile_maillock" = xyes; then :
067d23c9
KY
13131 have_lockfile=yes
13132else
13133 have_lockfile=no
13134fi
13135
13136if test $have_lockfile = yes; then
13137 LIBS_MAIL=-llockfile
13138 LIBS="$LIBS_MAIL $LIBS"
13139
13140$as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
13141
13142else
13143# If we have the shared liblockfile, assume we must use it for mail
13144# locking (e.g. Debian). If we couldn't link against liblockfile
13145# (no liblockfile.a installed), ensure that we don't need to.
13146 # Extract the first word of "liblockfile.so", so it can be a program name with args.
13147set dummy liblockfile.so; ac_word=$2
13148{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13149$as_echo_n "checking for $ac_word... " >&6; }
d6974efa 13150if ${ac_cv_prog_liblockfile+:} false; then :
067d23c9
KY
13151 $as_echo_n "(cached) " >&6
13152else
13153 if test -n "$liblockfile"; then
13154 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
13155else
13156as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13157as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
13158for as_dir in $as_dummy
13159do
13160 IFS=$as_save_IFS
13161 test -z "$as_dir" && as_dir=.
13162 for ac_exec_ext in '' $ac_executable_extensions; do
13163 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13164 ac_cv_prog_liblockfile="yes"
13165 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13166 break 2
13167 fi
13168done
13169 done
13170IFS=$as_save_IFS
13171
13172 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
13173fi
13174fi
13175liblockfile=$ac_cv_prog_liblockfile
13176if test -n "$liblockfile"; then
13177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
13178$as_echo "$liblockfile" >&6; }
13179else
13180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13181$as_echo "no" >&6; }
13182fi
13183
13184
13185 if test $ac_cv_prog_liblockfile = yes; then
2018939f 13186 as_fn_error $? "Shared liblockfile found but can't link against it.
067d23c9
KY
13187This probably means that movemail could lose mail.
13188There may be a \`development' package to install containing liblockfile." "$LINENO" 5
13189 fi
13190fi
13191for ac_func in touchlock
13192do :
13193 ac_fn_c_check_func "$LINENO" "touchlock" "ac_cv_func_touchlock"
d6974efa 13194if test "x$ac_cv_func_touchlock" = xyes; then :
067d23c9
KY
13195 cat >>confdefs.h <<_ACEOF
13196#define HAVE_TOUCHLOCK 1
13197_ACEOF
13198
13199fi
13200done
13201
13202for ac_header in maillock.h
13203do :
13204 ac_fn_c_check_header_mongrel "$LINENO" "maillock.h" "ac_cv_header_maillock_h" "$ac_includes_default"
d6974efa 13205if test "x$ac_cv_header_maillock_h" = xyes; then :
067d23c9
KY
13206 cat >>confdefs.h <<_ACEOF
13207#define HAVE_MAILLOCK_H 1
13208_ACEOF
13209
13210fi
13211
13212done
13213
13214
13215
13216## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
13217## interlock access to the mail spool. The alternative is a lock file named
13218## /usr/spool/mail/$USER.lock.
13219mail_lock=no
13220case "$opsys" in
13221 aix4-2) mail_lock="lockf" ;;
13222
13223 gnu|freebsd|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
13224
13225 ## On GNU/Linux systems, both methods are used by various mail programs.
13226 ## I assume most people are using newer mailers that have heard of flock.
13227 ## Change this if you need to.
13228 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
13229 ## configure gets the right answers, and that means *NOT* using flock.
13230 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
13231 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
13232 ## Debian maintainer hasn't provided a clean fix for Emacs.
13233 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
13234 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
13235 ## correct logic. -- fx
13236 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
13237 ## liblockfile is a Free Software replacement for libmail, used on
13238 ## Debian systems and elsewhere. -rfr.
13239 gnu-*)
13240 mail_lock="flock"
13241 if test $have_mail = yes || test $have_lockfile = yes; then
13242 test $ac_cv_header_maillock_h = yes && mail_lock=no
13243 fi
13244 ;;
13245esac
13246
13247BLESSMAIL_TARGET=
13248case "$mail_lock" in
13249 flock)
13250$as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
13251 ;;
13252
13253 lockf)
13254$as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
13255 ;;
13256
13257 *) BLESSMAIL_TARGET="need-blessmail" ;;
13258esac
13259
13260
13261
13262for ac_func in gethostname getdomainname dup2 \
13263rename closedir mkdir rmdir sysinfo getrusage get_current_dir_name \
13264random lrand48 logb frexp fmod rint cbrt ftime setsid \
1fd182f0 13265strerror fpathconf select euidaccess getpagesize tzset setlocale \
067d23c9
KY
13266utimes getrlimit setrlimit setpgid getcwd getwd shutdown getaddrinfo \
13267__fpending mblen mbrlen mbsinit strsignal setitimer ualarm strchr strrchr \
13268sendto recvfrom getsockopt setsockopt getsockname getpeername \
13269gai_strerror mkstemp getline getdelim mremap memmove fsync sync \
13270memset memcmp difftime memcpy mempcpy mblen mbrlen posix_memalign \
13271cfmakeraw cfsetspeed isnan copysign __executable_start
13272do :
13273 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13274ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
2018939f 13275if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
067d23c9
KY
13276 cat >>confdefs.h <<_ACEOF
13277#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13278_ACEOF
13279
13280fi
13281done
13282
13283
2018939f
AS
13284{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
13285$as_echo_n "checking for __builtin_unwind_init... " >&6; }
d6974efa 13286if ${emacs_cv_func___builtin_unwind_init+:} false; then :
2018939f
AS
13287 $as_echo_n "(cached) " >&6
13288else
13289 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13290/* end confdefs.h. */
13291
13292int
13293main ()
13294{
13295__builtin_unwind_init ();
13296 ;
13297 return 0;
13298}
13299_ACEOF
13300if ac_fn_c_try_link "$LINENO"; then :
13301 emacs_cv_func___builtin_unwind_init=yes
13302else
13303 emacs_cv_func___builtin_unwind_init=no
13304fi
13305rm -f core conftest.err conftest.$ac_objext \
13306 conftest$ac_exeext conftest.$ac_ext
13307fi
13308{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
13309$as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
13310if test $emacs_cv_func___builtin_unwind_init = yes; then
13311
13312$as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
13313
13314fi
13315
067d23c9
KY
13316for ac_header in sys/un.h
13317do :
13318 ac_fn_c_check_header_mongrel "$LINENO" "sys/un.h" "ac_cv_header_sys_un_h" "$ac_includes_default"
d6974efa 13319if test "x$ac_cv_header_sys_un_h" = xyes; then :
067d23c9
KY
13320 cat >>confdefs.h <<_ACEOF
13321#define HAVE_SYS_UN_H 1
13322_ACEOF
13323
13324fi
13325
13326done
13327
13328
1f5d53eb
PE
13329{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
13330$as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
13331if ${ac_cv_sys_largefile_source+:} false; then :
067d23c9
KY
13332 $as_echo_n "(cached) " >&6
13333else
1f5d53eb
PE
13334 while :; do
13335 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
067d23c9 13336/* end confdefs.h. */
1f5d53eb
PE
13337#include <sys/types.h> /* for off_t */
13338 #include <stdio.h>
067d23c9
KY
13339int
13340main ()
13341{
1f5d53eb
PE
13342int (*fp) (FILE *, off_t, int) = fseeko;
13343 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
067d23c9
KY
13344 ;
13345 return 0;
13346}
13347_ACEOF
13348if ac_fn_c_try_link "$LINENO"; then :
1f5d53eb 13349 ac_cv_sys_largefile_source=no; break
067d23c9
KY
13350fi
13351rm -f core conftest.err conftest.$ac_objext \
13352 conftest$ac_exeext conftest.$ac_ext
1f5d53eb 13353 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
067d23c9 13354/* end confdefs.h. */
1f5d53eb
PE
13355#define _LARGEFILE_SOURCE 1
13356#include <sys/types.h> /* for off_t */
13357 #include <stdio.h>
067d23c9
KY
13358int
13359main ()
13360{
1f5d53eb
PE
13361int (*fp) (FILE *, off_t, int) = fseeko;
13362 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
067d23c9
KY
13363 ;
13364 return 0;
13365}
13366_ACEOF
13367if ac_fn_c_try_link "$LINENO"; then :
1f5d53eb 13368 ac_cv_sys_largefile_source=1; break
067d23c9
KY
13369fi
13370rm -f core conftest.err conftest.$ac_objext \
13371 conftest$ac_exeext conftest.$ac_ext
1f5d53eb
PE
13372 ac_cv_sys_largefile_source=unknown
13373 break
13374done
067d23c9 13375fi
1f5d53eb
PE
13376{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
13377$as_echo "$ac_cv_sys_largefile_source" >&6; }
13378case $ac_cv_sys_largefile_source in #(
13379 no | unknown) ;;
13380 *)
13381cat >>confdefs.h <<_ACEOF
13382#define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
13383_ACEOF
13384;;
13385esac
13386rm -rf conftest*
067d23c9 13387
1f5d53eb
PE
13388# We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
13389# in glibc 2.1.3, but that breaks too many other things.
13390# If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
13391if test $ac_cv_sys_largefile_source != unknown; then
13392
13393$as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
067d23c9 13394
067d23c9
KY
13395fi
13396
1f5d53eb
PE
13397
13398{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5
13399$as_echo_n "checking whether getpgrp requires zero arguments... " >&6; }
13400if ${ac_cv_func_getpgrp_void+:} false; then :
067d23c9
KY
13401 $as_echo_n "(cached) " >&6
13402else
1f5d53eb 13403 # Use it with a single arg.
067d23c9
KY
13404cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13405/* end confdefs.h. */
1f5d53eb 13406$ac_includes_default
067d23c9
KY
13407int
13408main ()
13409{
1f5d53eb 13410getpgrp (0);
067d23c9
KY
13411 ;
13412 return 0;
13413}
13414_ACEOF
1f5d53eb
PE
13415if ac_fn_c_try_compile "$LINENO"; then :
13416 ac_cv_func_getpgrp_void=no
067d23c9 13417else
1f5d53eb 13418 ac_cv_func_getpgrp_void=yes
067d23c9 13419fi
1f5d53eb
PE
13420rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13421
067d23c9 13422fi
1f5d53eb
PE
13423{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5
13424$as_echo "$ac_cv_func_getpgrp_void" >&6; }
13425if test $ac_cv_func_getpgrp_void = yes; then
13426
13427$as_echo "#define GETPGRP_VOID 1" >>confdefs.h
067d23c9
KY
13428
13429fi
13430
1f5d53eb
PE
13431
13432# Configure gnulib.
13433
13434
13435
13436
13437
13438
13439
13440
13441
13442
13443 LIBC_FATAL_STDERR_=1
13444 export LIBC_FATAL_STDERR_
13445
13446
942f733f
PE
13447 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
13448$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
13449if ${ac_cv_c_bigendian+:} false; then :
13450 $as_echo_n "(cached) " >&6
13451else
13452 ac_cv_c_bigendian=unknown
13453 # See if we're dealing with a universal compiler.
13454 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13455/* end confdefs.h. */
13456#ifndef __APPLE_CC__
13457 not a universal capable compiler
13458 #endif
13459 typedef int dummy;
13460
13461_ACEOF
13462if ac_fn_c_try_compile "$LINENO"; then :
13463
13464 # Check for potential -arch flags. It is not universal unless
13465 # there are at least two -arch flags with different values.
13466 ac_arch=
13467 ac_prev=
13468 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
13469 if test -n "$ac_prev"; then
13470 case $ac_word in
13471 i?86 | x86_64 | ppc | ppc64)
13472 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
13473 ac_arch=$ac_word
13474 else
13475 ac_cv_c_bigendian=universal
13476 break
13477 fi
13478 ;;
13479 esac
13480 ac_prev=
13481 elif test "x$ac_word" = "x-arch"; then
13482 ac_prev=arch
13483 fi
13484 done
13485fi
13486rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13487 if test $ac_cv_c_bigendian = unknown; then
13488 # See if sys/param.h defines the BYTE_ORDER macro.
13489 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13490/* end confdefs.h. */
13491#include <sys/types.h>
13492 #include <sys/param.h>
13493
13494int
13495main ()
13496{
13497#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
13498 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
13499 && LITTLE_ENDIAN)
13500 bogus endian macros
13501 #endif
13502
13503 ;
13504 return 0;
13505}
13506_ACEOF
13507if ac_fn_c_try_compile "$LINENO"; then :
13508 # It does; now see whether it defined to BIG_ENDIAN or not.
13509 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13510/* end confdefs.h. */
13511#include <sys/types.h>
13512 #include <sys/param.h>
13513
13514int
13515main ()
13516{
13517#if BYTE_ORDER != BIG_ENDIAN
13518 not big endian
13519 #endif
13520
13521 ;
13522 return 0;
13523}
13524_ACEOF
13525if ac_fn_c_try_compile "$LINENO"; then :
13526 ac_cv_c_bigendian=yes
13527else
13528 ac_cv_c_bigendian=no
13529fi
13530rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13531fi
13532rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13533 fi
13534 if test $ac_cv_c_bigendian = unknown; then
13535 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
13536 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13537/* end confdefs.h. */
13538#include <limits.h>
13539
13540int
13541main ()
13542{
13543#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
13544 bogus endian macros
13545 #endif
13546
13547 ;
13548 return 0;
13549}
13550_ACEOF
13551if ac_fn_c_try_compile "$LINENO"; then :
13552 # It does; now see whether it defined to _BIG_ENDIAN or not.
13553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13554/* end confdefs.h. */
13555#include <limits.h>
13556
13557int
13558main ()
13559{
13560#ifndef _BIG_ENDIAN
13561 not big endian
13562 #endif
13563
13564 ;
13565 return 0;
13566}
13567_ACEOF
13568if ac_fn_c_try_compile "$LINENO"; then :
13569 ac_cv_c_bigendian=yes
13570else
13571 ac_cv_c_bigendian=no
13572fi
13573rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13574fi
13575rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13576 fi
13577 if test $ac_cv_c_bigendian = unknown; then
13578 # Compile a test program.
13579 if test "$cross_compiling" = yes; then :
13580 # Try to guess by grepping values from an object file.
13581 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13582/* end confdefs.h. */
13583short int ascii_mm[] =
13584 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
13585 short int ascii_ii[] =
13586 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
13587 int use_ascii (int i) {
13588 return ascii_mm[i] + ascii_ii[i];
13589 }
13590 short int ebcdic_ii[] =
13591 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
13592 short int ebcdic_mm[] =
13593 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
13594 int use_ebcdic (int i) {
13595 return ebcdic_mm[i] + ebcdic_ii[i];
13596 }
13597 extern int foo;
13598
13599int
13600main ()
13601{
13602return use_ascii (foo) == use_ebcdic (foo);
13603 ;
13604 return 0;
13605}
13606_ACEOF
13607if ac_fn_c_try_compile "$LINENO"; then :
13608 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
13609 ac_cv_c_bigendian=yes
13610 fi
13611 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
13612 if test "$ac_cv_c_bigendian" = unknown; then
13613 ac_cv_c_bigendian=no
13614 else
13615 # finding both strings is unlikely to happen, but who knows?
13616 ac_cv_c_bigendian=unknown
13617 fi
13618 fi
13619fi
13620rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13621else
13622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13623/* end confdefs.h. */
13624$ac_includes_default
13625int
13626main ()
13627{
13628
13629 /* Are we little or big endian? From Harbison&Steele. */
13630 union
13631 {
13632 long int l;
13633 char c[sizeof (long int)];
13634 } u;
13635 u.l = 1;
13636 return u.c[sizeof (long int) - 1] == 1;
13637
13638 ;
13639 return 0;
13640}
13641_ACEOF
13642if ac_fn_c_try_run "$LINENO"; then :
13643 ac_cv_c_bigendian=no
13644else
13645 ac_cv_c_bigendian=yes
13646fi
13647rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13648 conftest.$ac_objext conftest.beam conftest.$ac_ext
13649fi
13650
13651 fi
13652fi
13653{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
13654$as_echo "$ac_cv_c_bigendian" >&6; }
13655 case $ac_cv_c_bigendian in #(
13656 yes)
13657 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
13658;; #(
13659 no)
13660 ;; #(
13661 universal)
13662
13663$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
13664
13665 ;; #(
13666 *)
13667 as_fn_error $? "unknown endianness
13668 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
13669 esac
13670
13671
13672{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
13673$as_echo_n "checking for inline... " >&6; }
13674if ${ac_cv_c_inline+:} false; then :
13675 $as_echo_n "(cached) " >&6
13676else
13677 ac_cv_c_inline=no
13678for ac_kw in inline __inline__ __inline; do
13679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13680/* end confdefs.h. */
13681#ifndef __cplusplus
13682typedef int foo_t;
13683static $ac_kw foo_t static_foo () {return 0; }
13684$ac_kw foo_t foo () {return 0; }
13685#endif
13686
13687_ACEOF
13688if ac_fn_c_try_compile "$LINENO"; then :
13689 ac_cv_c_inline=$ac_kw
13690fi
13691rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13692 test "$ac_cv_c_inline" != no && break
13693done
13694
13695fi
13696{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
13697$as_echo "$ac_cv_c_inline" >&6; }
13698
13699case $ac_cv_c_inline in
13700 inline | yes) ;;
13701 *)
13702 case $ac_cv_c_inline in
13703 no) ac_val=;;
13704 *) ac_val=$ac_cv_c_inline;;
13705 esac
13706 cat >>confdefs.h <<_ACEOF
13707#ifndef __cplusplus
13708#define inline $ac_val
13709#endif
13710_ACEOF
13711 ;;
13712esac
13713
13714
1f5d53eb
PE
13715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
13716$as_echo_n "checking whether strtold conforms to C99... " >&6; }
13717if ${gl_cv_func_c99_strtold+:} false; then :
067d23c9
KY
13718 $as_echo_n "(cached) " >&6
13719else
1f5d53eb 13720 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
067d23c9 13721/* end confdefs.h. */
1f5d53eb
PE
13722/* On HP-UX before 11.23, strtold returns a struct instead of
13723 long double. Reject implementations like that, by requiring
13724 compatibility with the C99 prototype. */
13725 #include <stdlib.h>
13726 static long double (*p) (char const *, char **) = strtold;
13727 static long double
13728 test (char const *nptr, char **endptr)
13729 {
13730 long double r;
13731 r = strtold (nptr, endptr);
13732 return r;
13733 }
067d23c9
KY
13734int
13735main ()
13736{
1f5d53eb 13737return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
067d23c9
KY
13738 ;
13739 return 0;
13740}
13741_ACEOF
13742if ac_fn_c_try_link "$LINENO"; then :
1f5d53eb 13743 gl_cv_func_c99_strtold=yes
067d23c9 13744else
1f5d53eb 13745 gl_cv_func_c99_strtold=no
067d23c9
KY
13746fi
13747rm -f core conftest.err conftest.$ac_objext \
13748 conftest$ac_exeext conftest.$ac_ext
067d23c9 13749fi
1f5d53eb
PE
13750{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
13751$as_echo "$gl_cv_func_c99_strtold" >&6; }
13752 if test $gl_cv_func_c99_strtold = yes; then
067d23c9 13753
1f5d53eb 13754$as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
067d23c9 13755
1f5d53eb 13756 fi
067d23c9 13757
5fa4ac76
PE
13758{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
13759$as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
13760if ${ac_cv_struct_st_dm_mode+:} false; then :
13761 $as_echo_n "(cached) " >&6
13762else
13763 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13764/* end confdefs.h. */
13765
13766#include <sys/types.h>
13767#include <sys/stat.h>
13768int
13769main ()
13770{
13771struct stat s; s.st_dm_mode;
13772 ;
13773 return 0;
13774}
13775_ACEOF
13776if ac_fn_c_try_compile "$LINENO"; then :
13777 ac_cv_struct_st_dm_mode=yes
13778else
13779 ac_cv_struct_st_dm_mode=no
13780fi
13781rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13782fi
13783{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
13784$as_echo "$ac_cv_struct_st_dm_mode" >&6; }
13785
13786 if test $ac_cv_struct_st_dm_mode = yes; then
13787
13788$as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
13789
13790 fi
13791
13792
13793ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
13794if test "x$ac_cv_have_decl_strmode" = xyes; then :
13795 ac_have_decl=1
13796else
13797 ac_have_decl=0
13798fi
13799
13800cat >>confdefs.h <<_ACEOF
13801#define HAVE_DECL_STRMODE $ac_have_decl
13802_ACEOF
13803
067d23c9 13804
1f5d53eb
PE
13805 GNULIB__EXIT=0;
13806 GNULIB_ATOLL=0;
13807 GNULIB_CALLOC_POSIX=0;
13808 GNULIB_CANONICALIZE_FILE_NAME=0;
13809 GNULIB_GETLOADAVG=0;
13810 GNULIB_GETSUBOPT=0;
13811 GNULIB_GRANTPT=0;
13812 GNULIB_MALLOC_POSIX=0;
13813 GNULIB_MKDTEMP=0;
13814 GNULIB_MKOSTEMP=0;
13815 GNULIB_MKOSTEMPS=0;
13816 GNULIB_MKSTEMP=0;
13817 GNULIB_MKSTEMPS=0;
13818 GNULIB_PTSNAME=0;
13819 GNULIB_PUTENV=0;
13820 GNULIB_RANDOM_R=0;
13821 GNULIB_REALLOC_POSIX=0;
13822 GNULIB_REALPATH=0;
13823 GNULIB_RPMATCH=0;
13824 GNULIB_SETENV=0;
13825 GNULIB_STRTOD=0;
13826 GNULIB_STRTOLL=0;
13827 GNULIB_STRTOULL=0;
13828 GNULIB_SYSTEM_POSIX=0;
13829 GNULIB_UNLOCKPT=0;
13830 GNULIB_UNSETENV=0;
13831 HAVE__EXIT=1;
13832 HAVE_ATOLL=1;
13833 HAVE_CANONICALIZE_FILE_NAME=1;
13834 HAVE_DECL_GETLOADAVG=1;
13835 HAVE_GETSUBOPT=1;
13836 HAVE_GRANTPT=1;
13837 HAVE_MKDTEMP=1;
13838 HAVE_MKOSTEMP=1;
13839 HAVE_MKOSTEMPS=1;
13840 HAVE_MKSTEMP=1;
13841 HAVE_MKSTEMPS=1;
13842 HAVE_PTSNAME=1;
13843 HAVE_RANDOM_H=1;
13844 HAVE_RANDOM_R=1;
13845 HAVE_REALPATH=1;
13846 HAVE_RPMATCH=1;
13847 HAVE_SETENV=1;
13848 HAVE_DECL_SETENV=1;
13849 HAVE_STRTOD=1;
13850 HAVE_STRTOLL=1;
13851 HAVE_STRTOULL=1;
13852 HAVE_STRUCT_RANDOM_DATA=1;
13853 HAVE_SYS_LOADAVG_H=0;
13854 HAVE_UNLOCKPT=1;
13855 HAVE_DECL_UNSETENV=1;
13856 REPLACE_CALLOC=0;
13857 REPLACE_CANONICALIZE_FILE_NAME=0;
13858 REPLACE_MALLOC=0;
13859 REPLACE_MKSTEMP=0;
13860 REPLACE_PUTENV=0;
13861 REPLACE_REALLOC=0;
13862 REPLACE_REALPATH=0;
13863 REPLACE_SETENV=0;
13864 REPLACE_STRTOD=0;
13865 REPLACE_UNSETENV=0;
067d23c9 13866
067d23c9 13867
1f5d53eb
PE
13868 GNULIB_CHOWN=0;
13869 GNULIB_CLOSE=0;
13870 GNULIB_DUP2=0;
13871 GNULIB_DUP3=0;
13872 GNULIB_ENVIRON=0;
13873 GNULIB_EUIDACCESS=0;
13874 GNULIB_FACCESSAT=0;
13875 GNULIB_FCHDIR=0;
13876 GNULIB_FCHOWNAT=0;
13877 GNULIB_FSYNC=0;
13878 GNULIB_FTRUNCATE=0;
13879 GNULIB_GETCWD=0;
13880 GNULIB_GETDOMAINNAME=0;
13881 GNULIB_GETDTABLESIZE=0;
13882 GNULIB_GETGROUPS=0;
13883 GNULIB_GETHOSTNAME=0;
13884 GNULIB_GETLOGIN=0;
13885 GNULIB_GETLOGIN_R=0;
13886 GNULIB_GETPAGESIZE=0;
13887 GNULIB_GETUSERSHELL=0;
13888 GNULIB_LCHOWN=0;
13889 GNULIB_LINK=0;
13890 GNULIB_LINKAT=0;
13891 GNULIB_LSEEK=0;
13892 GNULIB_PIPE=0;
13893 GNULIB_PIPE2=0;
13894 GNULIB_PREAD=0;
13895 GNULIB_PWRITE=0;
13896 GNULIB_READLINK=0;
13897 GNULIB_READLINKAT=0;
13898 GNULIB_RMDIR=0;
13899 GNULIB_SLEEP=0;
13900 GNULIB_SYMLINK=0;
13901 GNULIB_SYMLINKAT=0;
13902 GNULIB_TTYNAME_R=0;
13903 GNULIB_UNISTD_H_GETOPT=0;
13904 GNULIB_UNISTD_H_SIGPIPE=0;
13905 GNULIB_UNLINK=0;
13906 GNULIB_UNLINKAT=0;
13907 GNULIB_USLEEP=0;
13908 GNULIB_WRITE=0;
13909 HAVE_CHOWN=1;
13910 HAVE_DUP2=1;
13911 HAVE_DUP3=1;
13912 HAVE_EUIDACCESS=1;
13913 HAVE_FACCESSAT=1;
13914 HAVE_FCHDIR=1;
13915 HAVE_FCHOWNAT=1;
13916 HAVE_FSYNC=1;
13917 HAVE_FTRUNCATE=1;
13918 HAVE_GETDTABLESIZE=1;
13919 HAVE_GETGROUPS=1;
13920 HAVE_GETHOSTNAME=1;
13921 HAVE_GETLOGIN=1;
13922 HAVE_GETPAGESIZE=1;
13923 HAVE_LCHOWN=1;
13924 HAVE_LINK=1;
13925 HAVE_LINKAT=1;
13926 HAVE_PIPE=1;
13927 HAVE_PIPE2=1;
13928 HAVE_PREAD=1;
13929 HAVE_PWRITE=1;
13930 HAVE_READLINK=1;
13931 HAVE_READLINKAT=1;
13932 HAVE_SLEEP=1;
13933 HAVE_SYMLINK=1;
13934 HAVE_SYMLINKAT=1;
13935 HAVE_UNLINKAT=1;
13936 HAVE_USLEEP=1;
13937 HAVE_DECL_ENVIRON=1;
13938 HAVE_DECL_FCHDIR=1;
13939 HAVE_DECL_GETDOMAINNAME=1;
13940 HAVE_DECL_GETLOGIN_R=1;
13941 HAVE_DECL_GETPAGESIZE=1;
13942 HAVE_DECL_GETUSERSHELL=1;
13943 HAVE_DECL_TTYNAME_R=1;
13944 HAVE_OS_H=0;
13945 HAVE_SYS_PARAM_H=0;
13946 REPLACE_CHOWN=0;
13947 REPLACE_CLOSE=0;
13948 REPLACE_DUP=0;
13949 REPLACE_DUP2=0;
13950 REPLACE_FCHOWNAT=0;
13951 REPLACE_GETCWD=0;
13952 REPLACE_GETDOMAINNAME=0;
13953 REPLACE_GETLOGIN_R=0;
13954 REPLACE_GETGROUPS=0;
13955 REPLACE_GETPAGESIZE=0;
13956 REPLACE_LCHOWN=0;
13957 REPLACE_LINK=0;
13958 REPLACE_LINKAT=0;
13959 REPLACE_LSEEK=0;
13960 REPLACE_PREAD=0;
13961 REPLACE_PWRITE=0;
13962 REPLACE_READLINK=0;
13963 REPLACE_RMDIR=0;
13964 REPLACE_SLEEP=0;
13965 REPLACE_SYMLINK=0;
13966 REPLACE_TTYNAME_R=0;
13967 REPLACE_UNLINK=0;
13968 REPLACE_UNLINKAT=0;
13969 REPLACE_USLEEP=0;
13970 REPLACE_WRITE=0;
13971 UNISTD_H_HAVE_WINSOCK2_H=0;
13972 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
067d23c9 13973
067d23c9 13974
1f5d53eb
PE
13975
13976
13977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
13978$as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
13979if ${gl_cv_have_include_next+:} false; then :
067d23c9
KY
13980 $as_echo_n "(cached) " >&6
13981else
1f5d53eb
PE
13982 rm -rf conftestd1a conftestd1b conftestd2
13983 mkdir conftestd1a conftestd1b conftestd2
13984 cat <<EOF > conftestd1a/conftest.h
13985#define DEFINED_IN_CONFTESTD1
13986#include_next <conftest.h>
13987#ifdef DEFINED_IN_CONFTESTD2
13988int foo;
13989#else
13990#error "include_next doesn't work"
067d23c9 13991#endif
1f5d53eb
PE
13992EOF
13993 cat <<EOF > conftestd1b/conftest.h
13994#define DEFINED_IN_CONFTESTD1
13995#include <stdio.h>
13996#include_next <conftest.h>
13997#ifdef DEFINED_IN_CONFTESTD2
13998int foo;
13999#else
14000#error "include_next doesn't work"
14001#endif
14002EOF
14003 cat <<EOF > conftestd2/conftest.h
14004#ifndef DEFINED_IN_CONFTESTD1
14005#error "include_next test doesn't work"
14006#endif
14007#define DEFINED_IN_CONFTESTD2
14008EOF
14009 gl_save_CPPFLAGS="$CPPFLAGS"
14010 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
14011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14012/* end confdefs.h. */
14013#include <conftest.h>
067d23c9 14014_ACEOF
1f5d53eb
PE
14015if ac_fn_c_try_compile "$LINENO"; then :
14016 gl_cv_have_include_next=yes
067d23c9 14017else
1f5d53eb
PE
14018 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
14019 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14020/* end confdefs.h. */
14021#include <conftest.h>
067d23c9 14022_ACEOF
1f5d53eb
PE
14023if ac_fn_c_try_compile "$LINENO"; then :
14024 gl_cv_have_include_next=buggy
14025else
14026 gl_cv_have_include_next=no
067d23c9 14027fi
1f5d53eb 14028rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
067d23c9
KY
14029
14030fi
1f5d53eb
PE
14031rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14032 CPPFLAGS="$gl_save_CPPFLAGS"
14033 rm -rf conftestd1a conftestd1b conftestd2
067d23c9 14034
1f5d53eb
PE
14035fi
14036{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
14037$as_echo "$gl_cv_have_include_next" >&6; }
14038 PRAGMA_SYSTEM_HEADER=
14039 if test $gl_cv_have_include_next = yes; then
14040 INCLUDE_NEXT=include_next
14041 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
14042 if test -n "$GCC"; then
14043 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
14044 fi
14045 else
14046 if test $gl_cv_have_include_next = buggy; then
14047 INCLUDE_NEXT=include
14048 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
14049 else
14050 INCLUDE_NEXT=include
14051 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
14052 fi
14053 fi
067d23c9
KY
14054
14055
067d23c9 14056
1f5d53eb
PE
14057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
14058$as_echo_n "checking whether system header files limit the line length... " >&6; }
14059if ${gl_cv_pragma_columns+:} false; then :
14060 $as_echo_n "(cached) " >&6
14061else
14062 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14063/* end confdefs.h. */
067d23c9 14064
1f5d53eb
PE
14065#ifdef __TANDEM
14066choke me
14067#endif
067d23c9 14068
067d23c9 14069_ACEOF
1f5d53eb
PE
14070if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14071 $EGREP "choke me" >/dev/null 2>&1; then :
14072 gl_cv_pragma_columns=yes
14073else
14074 gl_cv_pragma_columns=no
067d23c9 14075fi
1f5d53eb 14076rm -f conftest*
067d23c9 14077
067d23c9
KY
14078
14079fi
1f5d53eb
PE
14080{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
14081$as_echo "$gl_cv_pragma_columns" >&6; }
14082 if test $gl_cv_pragma_columns = yes; then
14083 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
14084 else
14085 PRAGMA_COLUMNS=
14086 fi
067d23c9 14087
067d23c9 14088
067d23c9
KY
14089
14090
067d23c9 14091
067d23c9
KY
14092
14093
067d23c9 14094
067d23c9 14095
067d23c9
KY
14096
14097
067d23c9 14098
067d23c9 14099
067d23c9 14100
067d23c9 14101
067d23c9 14102
067d23c9 14103
1f5d53eb
PE
14104 if test $gl_cv_have_include_next = yes; then
14105 gl_cv_next_getopt_h='<'getopt.h'>'
14106 else
14107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
14108$as_echo_n "checking absolute name of <getopt.h>... " >&6; }
14109if ${gl_cv_next_getopt_h+:} false; then :
14110 $as_echo_n "(cached) " >&6
14111else
067d23c9 14112
1f5d53eb 14113 if test $ac_cv_header_getopt_h = yes; then
067d23c9 14114
067d23c9 14115
1f5d53eb
PE
14116 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14117/* end confdefs.h. */
14118#include <getopt.h>
14119
14120_ACEOF
14121 case "$host_os" in
14122 aix*) gl_absname_cpp="$ac_cpp -C" ;;
14123 *) gl_absname_cpp="$ac_cpp" ;;
14124 esac
14125 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
14126 sed -n '\#/getopt.h#{
14127 s#.*"\(.*/getopt.h\)".*#\1#
14128 s#^/[^/]#//&#
14129 p
14130 q
14131 }'`'"'
14132 else
14133 gl_cv_next_getopt_h='<'getopt.h'>'
14134 fi
067d23c9
KY
14135
14136
14137fi
1f5d53eb
PE
14138{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
14139$as_echo "$gl_cv_next_getopt_h" >&6; }
14140 fi
14141 NEXT_GETOPT_H=$gl_cv_next_getopt_h
067d23c9 14142
1f5d53eb
PE
14143 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
14144 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
14145 gl_next_as_first_directive='<'getopt.h'>'
14146 else
14147 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
14148 gl_next_as_first_directive=$gl_cv_next_getopt_h
14149 fi
14150 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
067d23c9 14151
067d23c9
KY
14152
14153
067d23c9 14154
1f5d53eb
PE
14155 if test $ac_cv_header_getopt_h = yes; then
14156 HAVE_GETOPT_H=1
14157 else
14158 HAVE_GETOPT_H=0
14159 fi
067d23c9 14160
1f5d53eb
PE
14161
14162 gl_replace_getopt=
14163
14164 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
14165 for ac_header in getopt.h
14166do :
14167 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
14168if test "x$ac_cv_header_getopt_h" = xyes; then :
14169 cat >>confdefs.h <<_ACEOF
14170#define HAVE_GETOPT_H 1
14171_ACEOF
067d23c9
KY
14172
14173else
1f5d53eb 14174 gl_replace_getopt=yes
067d23c9
KY
14175fi
14176
1f5d53eb
PE
14177done
14178
14179 fi
14180
14181 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
14182 for ac_func in getopt_long_only
14183do :
14184 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
14185if test "x$ac_cv_func_getopt_long_only" = xyes; then :
14186 cat >>confdefs.h <<_ACEOF
14187#define HAVE_GETOPT_LONG_ONLY 1
14188_ACEOF
067d23c9 14189
067d23c9 14190else
1f5d53eb 14191 gl_replace_getopt=yes
067d23c9 14192fi
1f5d53eb 14193done
067d23c9 14194
1f5d53eb 14195 fi
067d23c9 14196
1f5d53eb
PE
14197 if test -z "$gl_replace_getopt"; then
14198 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
14199$as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
14200if ${gl_cv_func_getopt_posix+:} false; then :
067d23c9
KY
14201 $as_echo_n "(cached) " >&6
14202else
1f5d53eb
PE
14203
14204 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
067d23c9 14205/* end confdefs.h. */
1f5d53eb 14206#include <unistd.h>
067d23c9
KY
14207int
14208main ()
14209{
1f5d53eb 14210int *p = &optreset; return optreset;
067d23c9
KY
14211 ;
14212 return 0;
14213}
14214_ACEOF
1f5d53eb
PE
14215if ac_fn_c_try_compile "$LINENO"; then :
14216 gl_optind_min=1
1fd182f0 14217else
1f5d53eb 14218 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1fd182f0 14219/* end confdefs.h. */
1f5d53eb 14220#include <getopt.h>
1fd182f0
PE
14221int
14222main ()
14223{
1f5d53eb 14224return !getopt_clip;
1fd182f0
PE
14225 ;
14226 return 0;
14227}
14228_ACEOF
14229if ac_fn_c_try_compile "$LINENO"; then :
1f5d53eb 14230 gl_optind_min=1
1fd182f0 14231else
1f5d53eb 14232 gl_optind_min=0
1fd182f0
PE
14233fi
14234rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1fd182f0 14235fi
1f5d53eb 14236rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1fd182f0 14237
1f5d53eb
PE
14238 gl_save_CPPFLAGS=$CPPFLAGS
14239 CPPFLAGS="$CPPFLAGS -DOPTIND_MIN=$gl_optind_min"
14240 if test "$cross_compiling" = yes; then :
14241 case "$host_os" in
14242 mingw*) gl_cv_func_getopt_posix="guessing no";;
14243 darwin* | aix*) gl_cv_func_getopt_posix="guessing no";;
14244 *) gl_cv_func_getopt_posix="guessing yes";;
14245 esac
1fd182f0 14246
1f5d53eb
PE
14247else
14248 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14249/* end confdefs.h. */
1fd182f0 14250
1f5d53eb
PE
14251#include <unistd.h>
14252#include <stdlib.h>
14253#include <string.h>
1fd182f0 14254
1f5d53eb
PE
14255int
14256main ()
14257{
14258 {
14259 int argc = 0;
14260 char *argv[10];
14261 int c;
1fd182f0 14262
1f5d53eb
PE
14263 argv[argc++] = "program";
14264 argv[argc++] = "-a";
14265 argv[argc++] = "foo";
14266 argv[argc++] = "bar";
14267 argv[argc] = NULL;
14268 optind = OPTIND_MIN;
14269 opterr = 0;
b06b1098 14270
1f5d53eb
PE
14271 c = getopt (argc, argv, "ab");
14272 if (!(c == 'a'))
14273 return 1;
14274 c = getopt (argc, argv, "ab");
14275 if (!(c == -1))
14276 return 2;
14277 if (!(optind == 2))
14278 return 3;
14279 }
14280 /* Some internal state exists at this point. */
14281 {
14282 int argc = 0;
14283 char *argv[10];
14284 int c;
b06b1098 14285
1f5d53eb
PE
14286 argv[argc++] = "program";
14287 argv[argc++] = "donald";
14288 argv[argc++] = "-p";
14289 argv[argc++] = "billy";
14290 argv[argc++] = "duck";
14291 argv[argc++] = "-a";
14292 argv[argc++] = "bar";
14293 argv[argc] = NULL;
14294 optind = OPTIND_MIN;
14295 opterr = 0;
b06b1098 14296
1f5d53eb
PE
14297 c = getopt (argc, argv, "+abp:q:");
14298 if (!(c == -1))
14299 return 4;
14300 if (!(strcmp (argv[0], "program") == 0))
14301 return 5;
14302 if (!(strcmp (argv[1], "donald") == 0))
14303 return 6;
14304 if (!(strcmp (argv[2], "-p") == 0))
14305 return 7;
14306 if (!(strcmp (argv[3], "billy") == 0))
14307 return 8;
14308 if (!(strcmp (argv[4], "duck") == 0))
14309 return 9;
14310 if (!(strcmp (argv[5], "-a") == 0))
14311 return 10;
14312 if (!(strcmp (argv[6], "bar") == 0))
14313 return 11;
14314 if (!(optind == 1))
14315 return 12;
14316 }
14317 /* Detect MacOS 10.5, AIX 7.1 bug. */
14318 {
14319 char *argv[3] = { "program", "-ab", NULL };
14320 optind = OPTIND_MIN;
14321 opterr = 0;
14322 if (getopt (2, argv, "ab:") != 'a')
14323 return 13;
14324 if (getopt (2, argv, "ab:") != '?')
14325 return 14;
14326 if (optopt != 'b')
14327 return 15;
14328 if (optind != 2)
14329 return 16;
14330 }
d6974efa 14331
1f5d53eb
PE
14332 return 0;
14333}
d6974efa 14334
1f5d53eb
PE
14335_ACEOF
14336if ac_fn_c_try_run "$LINENO"; then :
14337 gl_cv_func_getopt_posix=yes
14338else
14339 gl_cv_func_getopt_posix=no
14340fi
14341rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14342 conftest.$ac_objext conftest.beam conftest.$ac_ext
14343fi
d6974efa 14344
1f5d53eb 14345 CPPFLAGS=$gl_save_CPPFLAGS
1fd182f0 14346
1f5d53eb
PE
14347fi
14348{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
14349$as_echo "$gl_cv_func_getopt_posix" >&6; }
14350 case "$gl_cv_func_getopt_posix" in
14351 *no) gl_replace_getopt=yes ;;
14352 esac
14353 fi
1fd182f0 14354
1f5d53eb
PE
14355 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
14356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
14357$as_echo_n "checking for working GNU getopt function... " >&6; }
14358if ${gl_cv_func_getopt_gnu+:} false; then :
1fd182f0 14359 $as_echo_n "(cached) " >&6
1f5d53eb
PE
14360else
14361 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
14362 # optstring is necessary for programs like m4 that have POSIX-mandated
14363 # semantics for supporting options interspersed with files.
14364 # Also, since getopt_long is a GNU extension, we require optind=0.
14365 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
14366 # so take care to revert to the correct (non-)export state.
14367 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
14368 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
14369 xx) gl_had_POSIXLY_CORRECT=exported ;;
14370 x) gl_had_POSIXLY_CORRECT=yes ;;
14371 *) gl_had_POSIXLY_CORRECT= ;;
14372 esac
14373 POSIXLY_CORRECT=1
14374 export POSIXLY_CORRECT
14375 if test "$cross_compiling" = yes; then :
14376 case $host_os:$ac_cv_have_decl_optreset in
14377 *-gnu*:* | mingw*:*) gl_cv_func_getopt_gnu=no;;
14378 *:yes) gl_cv_func_getopt_gnu=no;;
14379 *) gl_cv_func_getopt_gnu=yes;;
14380 esac
14381
1fd182f0
PE
14382else
14383 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14384/* end confdefs.h. */
1f5d53eb
PE
14385#include <getopt.h>
14386 #include <stddef.h>
14387 #include <string.h>
14388
1fd182f0
PE
14389int
14390main ()
14391{
1f5d53eb
PE
14392
14393 int result = 0;
14394 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
14395 and fails on MacOS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
14396 OSF/1 5.1, Solaris 10. */
14397 {
14398 char *myargv[3];
14399 myargv[0] = "conftest";
14400 myargv[1] = "-+";
14401 myargv[2] = 0;
14402 opterr = 0;
14403 if (getopt (2, myargv, "+a") != '?')
14404 result |= 1;
14405 }
14406 /* This code succeeds on glibc 2.8, mingw,
14407 and fails on MacOS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
14408 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
14409 {
14410 char *argv[] = { "program", "-p", "foo", "bar", NULL };
14411
14412 optind = 1;
14413 if (getopt (4, argv, "p::") != 'p')
14414 result |= 2;
14415 else if (optarg != NULL)
14416 result |= 4;
14417 else if (getopt (4, argv, "p::") != -1)
14418 result |= 6;
14419 else if (optind != 2)
14420 result |= 8;
14421 }
14422 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
14423 {
14424 char *argv[] = { "program", "foo", "-p", NULL };
14425 optind = 0;
14426 if (getopt (3, argv, "-p") != 1)
14427 result |= 16;
14428 else if (getopt (3, argv, "-p") != 'p')
14429 result |= 32;
14430 }
14431 /* This code fails on glibc 2.11. */
14432 {
14433 char *argv[] = { "program", "-b", "-a", NULL };
14434 optind = opterr = 0;
14435 if (getopt (3, argv, "+:a:b") != 'b')
14436 result |= 64;
14437 else if (getopt (3, argv, "+:a:b") != ':')
14438 result |= 64;
14439 }
14440 return result;
14441
1fd182f0
PE
14442 ;
14443 return 0;
14444}
14445_ACEOF
1f5d53eb
PE
14446if ac_fn_c_try_run "$LINENO"; then :
14447 gl_cv_func_getopt_gnu=yes
1fd182f0 14448else
1f5d53eb 14449 gl_cv_func_getopt_gnu=no
1fd182f0 14450fi
1f5d53eb
PE
14451rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14452 conftest.$ac_objext conftest.beam conftest.$ac_ext
1fd182f0 14453fi
1fd182f0 14454
1f5d53eb
PE
14455 case $gl_had_POSIXLY_CORRECT in
14456 exported) ;;
14457 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
14458 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
14459 esac
1fd182f0 14460
1f5d53eb
PE
14461fi
14462{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
14463$as_echo "$gl_cv_func_getopt_gnu" >&6; }
14464 if test "$gl_cv_func_getopt_gnu" = "no"; then
14465 gl_replace_getopt=yes
14466 fi
1fd182f0
PE
14467 fi
14468
1f5d53eb
PE
14469ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
14470if test "x$ac_cv_have_decl_getenv" = xyes; then :
14471 ac_have_decl=1
14472else
14473 ac_have_decl=0
14474fi
1fd182f0 14475
1f5d53eb
PE
14476cat >>confdefs.h <<_ACEOF
14477#define HAVE_DECL_GETENV $ac_have_decl
14478_ACEOF
1fd182f0
PE
14479
14480
14481
14482
1f5d53eb
PE
14483
14484
14485 if test -n "$gl_replace_getopt"; then :
14486
14487
14488
14489 GETOPT_H=getopt.h
14490
14491$as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
14492
14493
14494
14495 GNULIB_UNISTD_H_GETOPT=1
14496
14497
14498
14499
14500
14501
14502
14503
14504 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
14505
14506
14507
14508
14509
14510
14511
14512
14513
14514 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
14515
14516
14517
14518
14519
14520
14521fi
14522
14523
1f5d53eb
PE
14524
14525 GNULIB_MKTIME=0;
14526 GNULIB_NANOSLEEP=0;
14527 GNULIB_STRPTIME=0;
14528 GNULIB_TIMEGM=0;
14529 GNULIB_TIME_R=0;
14530 HAVE_DECL_LOCALTIME_R=1;
14531 HAVE_NANOSLEEP=1;
14532 HAVE_STRPTIME=1;
14533 HAVE_TIMEGM=1;
14534 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
14535 REPLACE_MKTIME=GNULIB_PORTCHECK;
14536 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
14537 REPLACE_TIMEGM=GNULIB_PORTCHECK;
14538
14539
14540
14541
14542 for ac_func in $ac_func_list
14543do :
14544 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14545ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14546if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
14547 cat >>confdefs.h <<_ACEOF
14548#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14549_ACEOF
1fd182f0 14550
e275c824 14551fi
1f5d53eb 14552done
1fd182f0
PE
14553
14554
e275c824 14555
1fd182f0 14556
1f5d53eb
PE
14557 gl_cv_c_multiarch=no
14558 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14559/* end confdefs.h. */
14560#ifndef __APPLE_CC__
14561 not a universal capable compiler
14562 #endif
14563 typedef int dummy;
e275c824
PE
14564
14565_ACEOF
1f5d53eb 14566if ac_fn_c_try_compile "$LINENO"; then :
e275c824 14567
1f5d53eb
PE
14568 arch=
14569 prev=
14570 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
14571 if test -n "$prev"; then
14572 case $word in
14573 i?86 | x86_64 | ppc | ppc64)
14574 if test -z "$arch" || test "$arch" = "$word"; then
14575 arch="$word"
14576 else
14577 gl_cv_c_multiarch=yes
14578 fi
14579 ;;
14580 esac
14581 prev=
14582 else
14583 if test "x$word" = "x-arch"; then
14584 prev=arch
14585 fi
14586 fi
14587 done
e275c824
PE
14588
14589fi
1f5d53eb
PE
14590rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14591 if test $gl_cv_c_multiarch = yes; then
14592 APPLE_UNIVERSAL_BUILD=1
e275c824 14593 else
1f5d53eb 14594 APPLE_UNIVERSAL_BUILD=0
e275c824
PE
14595 fi
14596
14597
1f5d53eb
PE
14598{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
14599$as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
14600if ${ac_cv_header_stdbool_h+:} false; then :
14601 $as_echo_n "(cached) " >&6
14602else
14603 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14604/* end confdefs.h. */
e275c824 14605
1f5d53eb
PE
14606 #include <stdbool.h>
14607 #ifndef bool
14608 "error: bool is not defined"
14609 #endif
14610 #ifndef false
14611 "error: false is not defined"
14612 #endif
14613 #if false
14614 "error: false is not 0"
14615 #endif
14616 #ifndef true
14617 "error: true is not defined"
14618 #endif
14619 #if true != 1
14620 "error: true is not 1"
14621 #endif
14622 #ifndef __bool_true_false_are_defined
14623 "error: __bool_true_false_are_defined is not defined"
14624 #endif
e275c824 14625
1f5d53eb 14626 struct s { _Bool s: 1; _Bool t; } s;
e275c824 14627
1f5d53eb
PE
14628 char a[true == 1 ? 1 : -1];
14629 char b[false == 0 ? 1 : -1];
14630 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
14631 char d[(bool) 0.5 == true ? 1 : -1];
14632 /* See body of main program for 'e'. */
14633 char f[(_Bool) 0.0 == false ? 1 : -1];
14634 char g[true];
14635 char h[sizeof (_Bool)];
14636 char i[sizeof s.t];
14637 enum { j = false, k = true, l = false * true, m = true * 256 };
14638 /* The following fails for
14639 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
14640 _Bool n[m];
14641 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
14642 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
14643 /* Catch a bug in an HP-UX C compiler. See
14644 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
14645 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
14646 */
14647 _Bool q = true;
14648 _Bool *pq = &q;
e275c824 14649
1f5d53eb
PE
14650int
14651main ()
14652{
e275c824 14653
1f5d53eb
PE
14654 bool e = &s;
14655 *pq |= q;
14656 *pq |= ! q;
14657 /* Refer to every declared value, to avoid compiler optimizations. */
14658 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
14659 + !m + !n + !o + !p + !q + !pq);
e275c824 14660
1f5d53eb
PE
14661 ;
14662 return 0;
14663}
14664_ACEOF
14665if ac_fn_c_try_compile "$LINENO"; then :
14666 ac_cv_header_stdbool_h=yes
14667else
14668 ac_cv_header_stdbool_h=no
14669fi
14670rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14671fi
14672{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
14673$as_echo "$ac_cv_header_stdbool_h" >&6; }
14674 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
14675if test "x$ac_cv_type__Bool" = xyes; then :
e275c824 14676
1f5d53eb
PE
14677cat >>confdefs.h <<_ACEOF
14678#define HAVE__BOOL 1
14679_ACEOF
e275c824
PE
14680
14681
1f5d53eb 14682fi
e275c824
PE
14683
14684
14685
1f5d53eb
PE
14686 REPLACE_NULL=0;
14687 HAVE_WCHAR_T=1;
14688 STDDEF_H='';
b06b1098
PE
14689
14690
1f5d53eb
PE
14691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
14692$as_echo_n "checking for wchar_t... " >&6; }
14693if ${gt_cv_c_wchar_t+:} false; then :
e275c824
PE
14694 $as_echo_n "(cached) " >&6
14695else
1f5d53eb 14696 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
e275c824 14697/* end confdefs.h. */
1f5d53eb
PE
14698#include <stddef.h>
14699 wchar_t foo = (wchar_t)'\0';
14700int
14701main ()
14702{
e275c824 14703
1f5d53eb
PE
14704 ;
14705 return 0;
14706}
e275c824 14707_ACEOF
1f5d53eb
PE
14708if ac_fn_c_try_compile "$LINENO"; then :
14709 gt_cv_c_wchar_t=yes
14710else
14711 gt_cv_c_wchar_t=no
e275c824 14712fi
1f5d53eb
PE
14713rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14714fi
14715{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
14716$as_echo "$gt_cv_c_wchar_t" >&6; }
14717 if test $gt_cv_c_wchar_t = yes; then
e275c824 14718
1f5d53eb 14719$as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
e275c824 14720
e275c824
PE
14721 fi
14722
14723
5f90be1b
PE
14724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
14725$as_echo_n "checking for unsigned long long int... " >&6; }
14726if ${ac_cv_type_unsigned_long_long_int+:} false; then :
14727 $as_echo_n "(cached) " >&6
14728else
14729 ac_cv_type_unsigned_long_long_int=yes
14730 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
14731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14732/* end confdefs.h. */
14733
14734 /* For now, do not test the preprocessor; as of 2007 there are too many
14735 implementations with broken preprocessors. Perhaps this can
14736 be revisited in 2012. In the meantime, code should not expect
14737 #if to work with literals wider than 32 bits. */
14738 /* Test literals. */
14739 long long int ll = 9223372036854775807ll;
14740 long long int nll = -9223372036854775807LL;
14741 unsigned long long int ull = 18446744073709551615ULL;
14742 /* Test constant expressions. */
14743 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
14744 ? 1 : -1)];
14745 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
14746 ? 1 : -1)];
14747 int i = 63;
14748int
14749main ()
14750{
14751/* Test availability of runtime routines for shift and division. */
14752 long long int llmax = 9223372036854775807ll;
14753 unsigned long long int ullmax = 18446744073709551615ull;
14754 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
14755 | (llmax / ll) | (llmax % ll)
14756 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
14757 | (ullmax / ull) | (ullmax % ull));
14758 ;
14759 return 0;
14760}
14761
14762_ACEOF
14763if ac_fn_c_try_link "$LINENO"; then :
14764
14765else
14766 ac_cv_type_unsigned_long_long_int=no
14767fi
14768rm -f core conftest.err conftest.$ac_objext \
14769 conftest$ac_exeext conftest.$ac_ext
14770 fi
14771fi
14772{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
14773$as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
14774 if test $ac_cv_type_unsigned_long_long_int = yes; then
14775
14776$as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
14777
14778 fi
14779
14780
14781
14782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
14783$as_echo_n "checking for long long int... " >&6; }
14784if ${ac_cv_type_long_long_int+:} false; then :
14785 $as_echo_n "(cached) " >&6
14786else
14787 ac_cv_type_long_long_int=yes
14788 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
14789 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
14790 if test $ac_cv_type_long_long_int = yes; then
14791 if test "$cross_compiling" = yes; then :
14792 :
14793else
14794 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14795/* end confdefs.h. */
14796#include <limits.h>
14797 #ifndef LLONG_MAX
14798 # define HALF \
14799 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
14800 # define LLONG_MAX (HALF - 1 + HALF)
14801 #endif
14802int
14803main ()
14804{
14805long long int n = 1;
14806 int i;
14807 for (i = 0; ; i++)
14808 {
14809 long long int m = n << i;
14810 if (m >> i != n)
14811 return 1;
14812 if (LLONG_MAX / 2 < m)
14813 break;
14814 }
14815 return 0;
14816 ;
14817 return 0;
14818}
14819_ACEOF
14820if ac_fn_c_try_run "$LINENO"; then :
14821
14822else
14823 ac_cv_type_long_long_int=no
14824fi
14825rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14826 conftest.$ac_objext conftest.beam conftest.$ac_ext
14827fi
14828
14829 fi
14830 fi
14831fi
14832{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
14833$as_echo "$ac_cv_type_long_long_int" >&6; }
14834 if test $ac_cv_type_long_long_int = yes; then
14835
14836$as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
14837
14838 fi
14839
14840
14841
14842
14843
14844
1f5d53eb
PE
14845 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
14846"
14847if test "x$ac_cv_member_struct_tm_tm_gmtoff" = xyes; then :
e275c824 14848
1f5d53eb 14849$as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
e275c824 14850
e275c824
PE
14851fi
14852
e275c824 14853
e275c824 14854
e275c824 14855
5fa4ac76
PE
14856
14857 GNULIB_FCHMODAT=0;
14858 GNULIB_FSTATAT=0;
14859 GNULIB_FUTIMENS=0;
14860 GNULIB_LCHMOD=0;
14861 GNULIB_LSTAT=0;
14862 GNULIB_MKDIRAT=0;
14863 GNULIB_MKFIFO=0;
14864 GNULIB_MKFIFOAT=0;
14865 GNULIB_MKNOD=0;
14866 GNULIB_MKNODAT=0;
14867 GNULIB_STAT=0;
14868 GNULIB_UTIMENSAT=0;
14869 HAVE_FCHMODAT=1;
14870 HAVE_FSTATAT=1;
14871 HAVE_FUTIMENS=1;
14872 HAVE_LCHMOD=1;
14873 HAVE_LSTAT=1;
14874 HAVE_MKDIRAT=1;
14875 HAVE_MKFIFO=1;
14876 HAVE_MKFIFOAT=1;
14877 HAVE_MKNOD=1;
14878 HAVE_MKNODAT=1;
14879 HAVE_UTIMENSAT=1;
14880 REPLACE_FSTAT=0;
14881 REPLACE_FSTATAT=0;
14882 REPLACE_FUTIMENS=0;
14883 REPLACE_LSTAT=0;
14884 REPLACE_MKDIR=0;
14885 REPLACE_MKFIFO=0;
14886 REPLACE_MKNOD=0;
14887 REPLACE_STAT=0;
14888 REPLACE_UTIMENSAT=0;
14889
14890{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
14891$as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
14892if ${ac_cv_header_stat_broken+:} false; then :
14893 $as_echo_n "(cached) " >&6
14894else
14895 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14896/* end confdefs.h. */
14897#include <sys/types.h>
14898#include <sys/stat.h>
14899
14900#if defined S_ISBLK && defined S_IFDIR
14901extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
14902#endif
14903
14904#if defined S_ISBLK && defined S_IFCHR
14905extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
14906#endif
14907
14908#if defined S_ISLNK && defined S_IFREG
14909extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
14910#endif
14911
14912#if defined S_ISSOCK && defined S_IFREG
14913extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
14914#endif
14915
14916_ACEOF
14917if ac_fn_c_try_compile "$LINENO"; then :
14918 ac_cv_header_stat_broken=no
14919else
14920 ac_cv_header_stat_broken=yes
14921fi
14922rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14923fi
14924{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
14925$as_echo "$ac_cv_header_stat_broken" >&6; }
14926if test $ac_cv_header_stat_broken = yes; then
14927
14928$as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
14929
14930fi
14931
14932
14933
1f5d53eb
PE
14934{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
14935$as_echo_n "checking for C/C++ restrict keyword... " >&6; }
14936if ${ac_cv_c_restrict+:} false; then :
d6974efa 14937 $as_echo_n "(cached) " >&6
e275c824 14938else
1f5d53eb
PE
14939 ac_cv_c_restrict=no
14940 # The order here caters to the fact that C++ does not require restrict.
14941 for ac_kw in __restrict __restrict__ _Restrict restrict; do
14942 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
d6974efa 14943/* end confdefs.h. */
1f5d53eb
PE
14944typedef int * int_ptr;
14945 int foo (int_ptr $ac_kw ip) {
14946 return ip[0];
14947 }
d6974efa
PE
14948int
14949main ()
14950{
1f5d53eb
PE
14951int s[1];
14952 int * $ac_kw t = s;
14953 t[0] = 0;
14954 return foo(t)
d6974efa
PE
14955 ;
14956 return 0;
14957}
e275c824 14958_ACEOF
1f5d53eb
PE
14959if ac_fn_c_try_compile "$LINENO"; then :
14960 ac_cv_c_restrict=$ac_kw
14961fi
14962rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14963 test "$ac_cv_c_restrict" != no && break
14964 done
14965
14966fi
14967{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
14968$as_echo "$ac_cv_c_restrict" >&6; }
14969
14970 case $ac_cv_c_restrict in
14971 restrict) ;;
14972 no) $as_echo "#define restrict /**/" >>confdefs.h
14973 ;;
14974 *) cat >>confdefs.h <<_ACEOF
14975#define restrict $ac_cv_c_restrict
14976_ACEOF
14977 ;;
14978 esac
14979
14980
14981
14982
14983
14984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
14985$as_echo_n "checking for struct timespec in <time.h>... " >&6; }
14986if ${gl_cv_sys_struct_timespec_in_time_h+:} false; then :
14987 $as_echo_n "(cached) " >&6
e275c824 14988else
d6974efa
PE
14989 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14990/* end confdefs.h. */
1f5d53eb
PE
14991#include <time.h>
14992
d6974efa
PE
14993int
14994main ()
14995{
1f5d53eb 14996static struct timespec x; x.tv_sec = x.tv_nsec;
d6974efa
PE
14997 ;
14998 return 0;
14999}
15000_ACEOF
15001if ac_fn_c_try_compile "$LINENO"; then :
1f5d53eb 15002 gl_cv_sys_struct_timespec_in_time_h=yes
e275c824 15003else
1f5d53eb 15004 gl_cv_sys_struct_timespec_in_time_h=no
e275c824 15005fi
d6974efa 15006rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
e275c824 15007fi
1f5d53eb
PE
15008{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
15009$as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
e275c824 15010
1f5d53eb
PE
15011 TIME_H_DEFINES_STRUCT_TIMESPEC=0
15012 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
15013 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
15014 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
15015 TIME_H_DEFINES_STRUCT_TIMESPEC=1
15016 else
15017 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
15018$as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
15019if ${gl_cv_sys_struct_timespec_in_sys_time_h+:} false; then :
15020 $as_echo_n "(cached) " >&6
e275c824
PE
15021else
15022 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15023/* end confdefs.h. */
1f5d53eb 15024#include <sys/time.h>
e275c824 15025
e275c824
PE
15026int
15027main ()
15028{
1f5d53eb
PE
15029static struct timespec x; x.tv_sec = x.tv_nsec;
15030 ;
e275c824
PE
15031 return 0;
15032}
e275c824 15033_ACEOF
1f5d53eb
PE
15034if ac_fn_c_try_compile "$LINENO"; then :
15035 gl_cv_sys_struct_timespec_in_sys_time_h=yes
e275c824 15036else
1f5d53eb 15037 gl_cv_sys_struct_timespec_in_sys_time_h=no
e275c824 15038fi
1f5d53eb 15039rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
e275c824 15040fi
1f5d53eb
PE
15041{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
15042$as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
15043 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
15044 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
15045 else
15046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
15047$as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
15048if ${gl_cv_sys_struct_timespec_in_pthread_h+:} false; then :
e275c824 15049 $as_echo_n "(cached) " >&6
e275c824
PE
15050else
15051 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15052/* end confdefs.h. */
1f5d53eb 15053#include <pthread.h>
e275c824
PE
15054
15055int
15056main ()
15057{
1f5d53eb 15058static struct timespec x; x.tv_sec = x.tv_nsec;
e275c824
PE
15059 ;
15060 return 0;
15061}
15062_ACEOF
1f5d53eb
PE
15063if ac_fn_c_try_compile "$LINENO"; then :
15064 gl_cv_sys_struct_timespec_in_pthread_h=yes
e275c824 15065else
1f5d53eb 15066 gl_cv_sys_struct_timespec_in_pthread_h=no
e275c824 15067fi
1f5d53eb 15068rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
e275c824 15069fi
1f5d53eb
PE
15070{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
15071$as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
15072 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
15073 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
15074 fi
e275c824
PE
15075 fi
15076 fi
15077
e275c824 15078
e275c824 15079
e275c824
PE
15080
15081
15082
e275c824
PE
15083
15084
15085
15086
15087
15088
15089
15090
e275c824 15091
1f5d53eb
PE
15092 if test $gl_cv_have_include_next = yes; then
15093 gl_cv_next_time_h='<'time.h'>'
15094 else
15095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
15096$as_echo_n "checking absolute name of <time.h>... " >&6; }
15097if ${gl_cv_next_time_h+:} false; then :
15098 $as_echo_n "(cached) " >&6
15099else
e275c824 15100
1f5d53eb
PE
15101 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15102/* end confdefs.h. */
15103#include <time.h>
e275c824 15104
1f5d53eb
PE
15105_ACEOF
15106 case "$host_os" in
15107 aix*) gl_absname_cpp="$ac_cpp -C" ;;
15108 *) gl_absname_cpp="$ac_cpp" ;;
15109 esac
15110 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
15111 sed -n '\#/time.h#{
15112 s#.*"\(.*/time.h\)".*#\1#
15113 s#^/[^/]#//&#
15114 p
15115 q
15116 }'`'"'
e275c824
PE
15117
15118
1f5d53eb
PE
15119fi
15120{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
15121$as_echo "$gl_cv_next_time_h" >&6; }
15122 fi
15123 NEXT_TIME_H=$gl_cv_next_time_h
e275c824 15124
1f5d53eb
PE
15125 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
15126 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
15127 gl_next_as_first_directive='<'time.h'>'
15128 else
15129 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
15130 gl_next_as_first_directive=$gl_cv_next_time_h
15131 fi
15132 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
e275c824
PE
15133
15134
15135
e275c824
PE
15136
15137
15138
1f5d53eb
PE
15139ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "$ac_includes_default"
15140if test "x$ac_cv_have_decl_localtime_r" = xyes; then :
15141 ac_have_decl=1
15142else
15143 ac_have_decl=0
15144fi
e275c824 15145
1f5d53eb
PE
15146cat >>confdefs.h <<_ACEOF
15147#define HAVE_DECL_LOCALTIME_R $ac_have_decl
15148_ACEOF
e275c824
PE
15149
15150
e275c824
PE
15151
15152
1f5d53eb
PE
15153 if false; then
15154 GL_COND_LIBTOOL_TRUE=
15155 GL_COND_LIBTOOL_FALSE='#'
67342916 15156else
1f5d53eb
PE
15157 GL_COND_LIBTOOL_TRUE='#'
15158 GL_COND_LIBTOOL_FALSE=
67342916 15159fi
67342916 15160
1f5d53eb
PE
15161 gl_cond_libtool=false
15162 gl_libdeps=
15163 gl_ltlibdeps=
15164 gl_m4_base='m4'
67342916 15165
67342916 15166
e275c824 15167
e275c824
PE
15168
15169
15170
15171
e275c824 15172
e275c824 15173
1f5d53eb
PE
15174 gl_source_base='lib'
15175 # Code from module arg-nonnull:
15176 # Code from module c++defs:
942f733f
PE
15177 # Code from module crypto/md5:
15178
15179
15180
15181
15182
15183
15184
15185
15186
15187 gl_LIBOBJS="$gl_LIBOBJS md5.$ac_objext"
15188
15189
15190
15191
15192 :
15193
1f5d53eb 15194 # Code from module dtoastr:
e275c824 15195
1f5d53eb 15196 # Code from module extensions:
5fa4ac76
PE
15197 # Code from module filemode:
15198
15199
15200
15201
15202
15203
15204
15205
15206
15207
15208 gl_LIBOBJS="$gl_LIBOBJS filemode.$ac_objext"
15209
15210
15211
1f5d53eb 15212 # Code from module getloadavg:
e275c824
PE
15213
15214
1f5d53eb 15215# Persuade glibc <stdlib.h> to declare getloadavg().
e275c824 15216
e275c824 15217
1f5d53eb
PE
15218# Make sure getloadavg.c is where it belongs, at configure-time.
15219test -f "$srcdir/$gl_source_base/getloadavg.c" ||
15220 as_fn_error $? "$srcdir/$gl_source_base/getloadavg.c is missing" "$LINENO" 5
e275c824 15221
1f5d53eb 15222gl_save_LIBS=$LIBS
e275c824 15223
7d315eb6
PE
15224# getloadvg is present in libc on glibc >= 2.2, MacOS X, FreeBSD >= 2.0,
15225# NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
1f5d53eb
PE
15226ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
15227if test "x$ac_cv_func_getloadavg" = xyes; then :
e275c824 15228
1f5d53eb
PE
15229else
15230 gl_have_func=no
15231
15232 # Some systems with -lutil have (and need) -lkvm as well, some do not.
15233 # On Solaris, -lkvm requires nlist from -lelf, so check that first
15234 # to get the right answer into the cache.
15235 # For kstat on solaris, we need to test for libelf and libkvm to force the
15236 # definition of SVR4 below.
15237 if test $gl_have_func = no; then
15238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
15239$as_echo_n "checking for elf_begin in -lelf... " >&6; }
15240if ${ac_cv_lib_elf_elf_begin+:} false; then :
16c3e636
PE
15241 $as_echo_n "(cached) " >&6
15242else
1f5d53eb
PE
15243 ac_check_lib_save_LIBS=$LIBS
15244LIBS="-lelf $LIBS"
15245cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16c3e636
PE
15246/* end confdefs.h. */
15247
1f5d53eb
PE
15248/* Override any GCC internal prototype to avoid an error.
15249 Use char because int might match the return type of a GCC
15250 builtin and then its argument prototype would still apply. */
15251#ifdef __cplusplus
15252extern "C"
15253#endif
15254char elf_begin ();
15255int
15256main ()
15257{
15258return elf_begin ();
15259 ;
15260 return 0;
15261}
15262_ACEOF
15263if ac_fn_c_try_link "$LINENO"; then :
15264 ac_cv_lib_elf_elf_begin=yes
15265else
15266 ac_cv_lib_elf_elf_begin=no
15267fi
15268rm -f core conftest.err conftest.$ac_objext \
15269 conftest$ac_exeext conftest.$ac_ext
15270LIBS=$ac_check_lib_save_LIBS
15271fi
15272{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
15273$as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
15274if test "x$ac_cv_lib_elf_elf_begin" = xyes; then :
15275 LIBS="-lelf $LIBS"
15276fi
15277
15278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
15279$as_echo_n "checking for kvm_open in -lkvm... " >&6; }
15280if ${ac_cv_lib_kvm_kvm_open+:} false; then :
15281 $as_echo_n "(cached) " >&6
15282else
15283 ac_check_lib_save_LIBS=$LIBS
15284LIBS="-lkvm $LIBS"
15285cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15286/* end confdefs.h. */
16c3e636 15287
1f5d53eb
PE
15288/* Override any GCC internal prototype to avoid an error.
15289 Use char because int might match the return type of a GCC
15290 builtin and then its argument prototype would still apply. */
15291#ifdef __cplusplus
15292extern "C"
15293#endif
15294char kvm_open ();
16c3e636
PE
15295int
15296main ()
15297{
1f5d53eb 15298return kvm_open ();
16c3e636
PE
15299 ;
15300 return 0;
15301}
15302_ACEOF
1f5d53eb
PE
15303if ac_fn_c_try_link "$LINENO"; then :
15304 ac_cv_lib_kvm_kvm_open=yes
16c3e636 15305else
1f5d53eb 15306 ac_cv_lib_kvm_kvm_open=no
16c3e636 15307fi
1f5d53eb
PE
15308rm -f core conftest.err conftest.$ac_objext \
15309 conftest$ac_exeext conftest.$ac_ext
15310LIBS=$ac_check_lib_save_LIBS
16c3e636 15311fi
1f5d53eb
PE
15312{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
15313$as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
15314if test "x$ac_cv_lib_kvm_kvm_open" = xyes; then :
15315 LIBS="-lkvm $LIBS"
16c3e636
PE
15316fi
15317
1f5d53eb
PE
15318 # Check for the 4.4BSD definition of getloadavg.
15319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
15320$as_echo_n "checking for getloadavg in -lutil... " >&6; }
15321if ${ac_cv_lib_util_getloadavg+:} false; then :
1fd182f0
PE
15322 $as_echo_n "(cached) " >&6
15323else
1f5d53eb
PE
15324 ac_check_lib_save_LIBS=$LIBS
15325LIBS="-lutil $LIBS"
15326cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1fd182f0 15327/* end confdefs.h. */
1f5d53eb
PE
15328
15329/* Override any GCC internal prototype to avoid an error.
15330 Use char because int might match the return type of a GCC
15331 builtin and then its argument prototype would still apply. */
15332#ifdef __cplusplus
15333extern "C"
15334#endif
15335char getloadavg ();
1fd182f0
PE
15336int
15337main ()
15338{
1f5d53eb 15339return getloadavg ();
1fd182f0
PE
15340 ;
15341 return 0;
15342}
15343_ACEOF
1f5d53eb
PE
15344if ac_fn_c_try_link "$LINENO"; then :
15345 ac_cv_lib_util_getloadavg=yes
1fd182f0 15346else
1f5d53eb 15347 ac_cv_lib_util_getloadavg=no
1fd182f0 15348fi
1f5d53eb
PE
15349rm -f core conftest.err conftest.$ac_objext \
15350 conftest$ac_exeext conftest.$ac_ext
15351LIBS=$ac_check_lib_save_LIBS
1fd182f0 15352fi
1f5d53eb
PE
15353{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
15354$as_echo "$ac_cv_lib_util_getloadavg" >&6; }
15355if test "x$ac_cv_lib_util_getloadavg" = xyes; then :
15356 LIBS="-lutil $LIBS" gl_have_func=yes
16c3e636
PE
15357fi
15358
1f5d53eb 15359 fi
16c3e636 15360
1f5d53eb
PE
15361 if test $gl_have_func = no; then
15362 # There is a commonly available library for RS/6000 AIX.
15363 # Since it is not a standard part of AIX, it might be installed locally.
15364 gl_getloadavg_LIBS=$LIBS
15365 LIBS="-L/usr/local/lib $LIBS"
15366 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
15367$as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
15368if ${ac_cv_lib_getloadavg_getloadavg+:} false; then :
1fd182f0
PE
15369 $as_echo_n "(cached) " >&6
15370else
1f5d53eb
PE
15371 ac_check_lib_save_LIBS=$LIBS
15372LIBS="-lgetloadavg $LIBS"
15373cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1fd182f0 15374/* end confdefs.h. */
1f5d53eb
PE
15375
15376/* Override any GCC internal prototype to avoid an error.
15377 Use char because int might match the return type of a GCC
15378 builtin and then its argument prototype would still apply. */
15379#ifdef __cplusplus
15380extern "C"
15381#endif
15382char getloadavg ();
1fd182f0
PE
15383int
15384main ()
15385{
1f5d53eb 15386return getloadavg ();
1fd182f0
PE
15387 ;
15388 return 0;
15389}
15390_ACEOF
1f5d53eb
PE
15391if ac_fn_c_try_link "$LINENO"; then :
15392 ac_cv_lib_getloadavg_getloadavg=yes
15393else
15394 ac_cv_lib_getloadavg_getloadavg=no
1fd182f0 15395fi
1f5d53eb
PE
15396rm -f core conftest.err conftest.$ac_objext \
15397 conftest$ac_exeext conftest.$ac_ext
15398LIBS=$ac_check_lib_save_LIBS
15399fi
15400{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
15401$as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
15402if test "x$ac_cv_lib_getloadavg_getloadavg" = xyes; then :
15403 LIBS="-lgetloadavg $LIBS" gl_have_func=yes
15404else
15405 LIBS=$gl_getloadavg_LIBS
1fd182f0 15406fi
1fd182f0 15407
1f5d53eb 15408 fi
1fd182f0 15409
1f5d53eb
PE
15410 # Set up the replacement function if necessary.
15411 if test $gl_have_func = no; then
1fd182f0
PE
15412
15413
15414
15415
1f5d53eb
PE
15416
15417
15418
15419
15420 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
15421
15422
15423# Figure out what our getloadavg.c needs.
15424
15425# Solaris has libkstat which does not require root.
15426{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
15427$as_echo_n "checking for kstat_open in -lkstat... " >&6; }
15428if ${ac_cv_lib_kstat_kstat_open+:} false; then :
1fd182f0
PE
15429 $as_echo_n "(cached) " >&6
15430else
1f5d53eb
PE
15431 ac_check_lib_save_LIBS=$LIBS
15432LIBS="-lkstat $LIBS"
15433cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1fd182f0 15434/* end confdefs.h. */
1fd182f0 15435
1f5d53eb
PE
15436/* Override any GCC internal prototype to avoid an error.
15437 Use char because int might match the return type of a GCC
15438 builtin and then its argument prototype would still apply. */
15439#ifdef __cplusplus
15440extern "C"
15441#endif
15442char kstat_open ();
1fd182f0
PE
15443int
15444main ()
15445{
1f5d53eb 15446return kstat_open ();
1fd182f0
PE
15447 ;
15448 return 0;
15449}
15450_ACEOF
1f5d53eb
PE
15451if ac_fn_c_try_link "$LINENO"; then :
15452 ac_cv_lib_kstat_kstat_open=yes
1fd182f0 15453else
1f5d53eb 15454 ac_cv_lib_kstat_kstat_open=no
1fd182f0 15455fi
1f5d53eb
PE
15456rm -f core conftest.err conftest.$ac_objext \
15457 conftest$ac_exeext conftest.$ac_ext
15458LIBS=$ac_check_lib_save_LIBS
1fd182f0 15459fi
1f5d53eb
PE
15460{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
15461$as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
15462if test "x$ac_cv_lib_kstat_kstat_open" = xyes; then :
15463 cat >>confdefs.h <<_ACEOF
15464#define HAVE_LIBKSTAT 1
15465_ACEOF
1fd182f0 15466
1f5d53eb
PE
15467 LIBS="-lkstat $LIBS"
15468
15469fi
15470
15471test $ac_cv_lib_kstat_kstat_open = yes && gl_have_func=yes
15472
15473# On HPUX9, an unprivileged user can get load averages this way.
15474if test $gl_have_func = no; then
15475 for ac_func in pstat_getdynamic
15476do :
15477 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
15478if test "x$ac_cv_func_pstat_getdynamic" = xyes; then :
15479 cat >>confdefs.h <<_ACEOF
15480#define HAVE_PSTAT_GETDYNAMIC 1
15481_ACEOF
15482 gl_have_func=yes
15483fi
15484done
15485
15486fi
15487
15488# AIX has libperfstat which does not require root
15489if test $gl_have_func = no; then
15490 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
15491$as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
15492if ${ac_cv_lib_perfstat_perfstat_cpu_total+:} false; then :
1fd182f0
PE
15493 $as_echo_n "(cached) " >&6
15494else
1f5d53eb
PE
15495 ac_check_lib_save_LIBS=$LIBS
15496LIBS="-lperfstat $LIBS"
15497cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1fd182f0 15498/* end confdefs.h. */
1fd182f0 15499
1f5d53eb
PE
15500/* Override any GCC internal prototype to avoid an error.
15501 Use char because int might match the return type of a GCC
15502 builtin and then its argument prototype would still apply. */
15503#ifdef __cplusplus
15504extern "C"
15505#endif
15506char perfstat_cpu_total ();
1fd182f0
PE
15507int
15508main ()
15509{
1f5d53eb 15510return perfstat_cpu_total ();
1fd182f0
PE
15511 ;
15512 return 0;
15513}
15514_ACEOF
1f5d53eb
PE
15515if ac_fn_c_try_link "$LINENO"; then :
15516 ac_cv_lib_perfstat_perfstat_cpu_total=yes
1fd182f0 15517else
1f5d53eb 15518 ac_cv_lib_perfstat_perfstat_cpu_total=no
1fd182f0 15519fi
1f5d53eb
PE
15520rm -f core conftest.err conftest.$ac_objext \
15521 conftest$ac_exeext conftest.$ac_ext
15522LIBS=$ac_check_lib_save_LIBS
1fd182f0 15523fi
1f5d53eb
PE
15524{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
15525$as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
15526if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = xyes; then :
15527 cat >>confdefs.h <<_ACEOF
15528#define HAVE_LIBPERFSTAT 1
15529_ACEOF
15530
15531 LIBS="-lperfstat $LIBS"
15532
15533fi
15534
15535 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_have_func=yes
15536fi
15537
15538if test $gl_have_func = no; then
15539 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
15540if test "x$ac_cv_header_sys_dg_sys_info_h" = xyes; then :
15541 gl_have_func=yes
15542
15543$as_echo "#define DGUX 1" >>confdefs.h
15544
15545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
15546$as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
15547if ${ac_cv_lib_dgc_dg_sys_info+:} false; then :
1fd182f0
PE
15548 $as_echo_n "(cached) " >&6
15549else
1f5d53eb
PE
15550 ac_check_lib_save_LIBS=$LIBS
15551LIBS="-ldgc $LIBS"
15552cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1fd182f0 15553/* end confdefs.h. */
1fd182f0 15554
1f5d53eb
PE
15555/* Override any GCC internal prototype to avoid an error.
15556 Use char because int might match the return type of a GCC
15557 builtin and then its argument prototype would still apply. */
15558#ifdef __cplusplus
15559extern "C"
15560#endif
15561char dg_sys_info ();
1fd182f0
PE
15562int
15563main ()
15564{
1f5d53eb 15565return dg_sys_info ();
1fd182f0
PE
15566 ;
15567 return 0;
15568}
15569_ACEOF
1f5d53eb
PE
15570if ac_fn_c_try_link "$LINENO"; then :
15571 ac_cv_lib_dgc_dg_sys_info=yes
1fd182f0 15572else
1f5d53eb 15573 ac_cv_lib_dgc_dg_sys_info=no
1fd182f0 15574fi
1f5d53eb
PE
15575rm -f core conftest.err conftest.$ac_objext \
15576 conftest$ac_exeext conftest.$ac_ext
15577LIBS=$ac_check_lib_save_LIBS
1fd182f0 15578fi
1f5d53eb
PE
15579{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
15580$as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
15581if test "x$ac_cv_lib_dgc_dg_sys_info" = xyes; then :
15582 cat >>confdefs.h <<_ACEOF
15583#define HAVE_LIBDGC 1
15584_ACEOF
1fd182f0 15585
1f5d53eb 15586 LIBS="-ldgc $LIBS"
1fd182f0 15587
1f5d53eb 15588fi
1fd182f0 15589
1f5d53eb 15590fi
1fd182f0
PE
15591
15592
1f5d53eb 15593fi
1fd182f0 15594
1f5d53eb
PE
15595# We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
15596# uses stabs), but it is still SVR4. We cannot check for <elf.h> because
15597# Irix 4.0.5F has the header but not the library.
15598if test $gl_have_func = no && test "$ac_cv_lib_elf_elf_begin" = yes \
15599 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
15600 gl_have_func=yes
1fd182f0 15601
1f5d53eb 15602$as_echo "#define SVR4 1" >>confdefs.h
1fd182f0 15603
1f5d53eb 15604fi
1fd182f0 15605
1f5d53eb
PE
15606if test $gl_have_func = no; then
15607 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
15608if test "x$ac_cv_header_inq_stats_cpustats_h" = xyes; then :
15609 gl_have_func=yes
1fd182f0 15610
1f5d53eb 15611$as_echo "#define UMAX 1" >>confdefs.h
1fd182f0
PE
15612
15613
1f5d53eb 15614$as_echo "#define UMAX4_3 1" >>confdefs.h
1fd182f0 15615
1f5d53eb 15616fi
b06b1098
PE
15617
15618
1f5d53eb 15619fi
1fd182f0 15620
1f5d53eb
PE
15621if test $gl_have_func = no; then
15622 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
15623if test "x$ac_cv_header_sys_cpustats_h" = xyes; then :
15624 gl_have_func=yes; $as_echo "#define UMAX 1" >>confdefs.h
1fd182f0 15625
1f5d53eb 15626fi
b06b1098 15627
1fd182f0
PE
15628
15629fi
1fd182f0 15630
1f5d53eb
PE
15631if test $gl_have_func = no; then
15632 for ac_header in mach/mach.h
15633do :
15634 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
15635if test "x$ac_cv_header_mach_mach_h" = xyes; then :
15636 cat >>confdefs.h <<_ACEOF
15637#define HAVE_MACH_MACH_H 1
15638_ACEOF
1fd182f0 15639
1f5d53eb 15640fi
1fd182f0 15641
1f5d53eb 15642done
1fd182f0 15643
1f5d53eb 15644fi
1fd182f0 15645
1f5d53eb
PE
15646for ac_header in nlist.h
15647do :
15648 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
15649if test "x$ac_cv_header_nlist_h" = xyes; then :
15650 cat >>confdefs.h <<_ACEOF
15651#define HAVE_NLIST_H 1
15652_ACEOF
15653 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
15654"
15655if test "x$ac_cv_member_struct_nlist_n_un_n_name" = xyes; then :
15656
15657cat >>confdefs.h <<_ACEOF
15658#define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
15659_ACEOF
1fd182f0 15660
b06b1098 15661
1fd182f0
PE
15662fi
15663
1f5d53eb
PE
15664 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15665/* end confdefs.h. */
15666#include <nlist.h>
15667int
15668main ()
15669{
15670struct nlist x;
15671 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
15672 x.n_un.n_name = "";
15673 #else
15674 x.n_name = "";
15675 #endif
15676 ;
15677 return 0;
15678}
1fd182f0 15679_ACEOF
1f5d53eb
PE
15680if ac_fn_c_try_link "$LINENO"; then :
15681
15682$as_echo "#define N_NAME_POINTER 1" >>confdefs.h
15683
15684fi
15685rm -f core conftest.err conftest.$ac_objext \
15686 conftest$ac_exeext conftest.$ac_ext
1fd182f0 15687
1f5d53eb 15688fi
1fd182f0 15689
1f5d53eb 15690done
1fd182f0 15691
1f5d53eb
PE
15692 fi
15693fi
1fd182f0 15694
1f5d53eb
PE
15695
15696if test "x$gl_save_LIBS" = x; then
15697 GETLOADAVG_LIBS=$LIBS
1fd182f0 15698else
1f5d53eb 15699 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
1fd182f0 15700fi
1f5d53eb 15701LIBS=$gl_save_LIBS
1fd182f0 15702
1fd182f0 15703
1f5d53eb
PE
15704# Test whether the system declares getloadavg. Solaris has the function
15705# but declares it in <sys/loadavg.h>, not <stdlib.h>.
15706for ac_header in sys/loadavg.h
15707do :
15708 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
15709if test "x$ac_cv_header_sys_loadavg_h" = xyes; then :
15710 cat >>confdefs.h <<_ACEOF
15711#define HAVE_SYS_LOADAVG_H 1
15712_ACEOF
15713
15714fi
1fd182f0 15715
1f5d53eb 15716done
1fd182f0 15717
1f5d53eb
PE
15718if test $ac_cv_header_sys_loadavg_h = yes; then
15719 HAVE_SYS_LOADAVG_H=1
15720else
15721 HAVE_SYS_LOADAVG_H=0
15722fi
15723ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
15724 # include <sys/loadavg.h>
15725 #endif
15726 #include <stdlib.h>
15727"
15728if test "x$ac_cv_have_decl_getloadavg" = xyes; then :
1fd182f0 15729
1f5d53eb
PE
15730else
15731 HAVE_DECL_GETLOADAVG=0
15732fi
1fd182f0
PE
15733
15734
15735
15736
15737
1f5d53eb
PE
15738 GNULIB_GETLOADAVG=1
15739
15740
1fd182f0 15741
e275c824
PE
15742 # Code from module getopt-gnu:
15743
15744
15745
15746
15747
15748
e275c824
PE
15749 # Code from module getopt-posix:
15750
15751
15752
15753
15754
15755 if test -n "$gl_replace_getopt"; then :
15756
15757
15758
15759 GETOPT_H=getopt.h
15760
15761$as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
15762
15763
15764
15765 GNULIB_UNISTD_H_GETOPT=1
15766
15767
15768
15769
15770
15771
15772
15773
15774 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
15775
15776
15777
15778
15779
15780
15781
15782
15783
15784 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
15785
15786
15787
15788
15789
15790
15791fi
15792
15793
15794 # Code from module gettext-h:
15795
15796
67342916
PE
15797 # Code from module ignore-value:
15798
1fd182f0
PE
15799 # Code from module include_next:
15800 # Code from module intprops:
15801 # Code from module mktime:
15802
15803
15804
15805
15806
15807if test $APPLE_UNIVERSAL_BUILD = 1; then
15808 # A universal build on Apple MacOS X platforms.
15809 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
15810 # But we need a configuration result that is valid in both modes.
15811 ac_cv_func_working_mktime=no
15812fi
15813{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
15814$as_echo_n "checking for working mktime... " >&6; }
d6974efa 15815if ${ac_cv_func_working_mktime+:} false; then :
1fd182f0
PE
15816 $as_echo_n "(cached) " >&6
15817else
15818 if test "$cross_compiling" = yes; then :
15819 ac_cv_func_working_mktime=no
15820else
15821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15822/* end confdefs.h. */
15823/* Test program from Paul Eggert and Tony Leneis. */
15824#include <limits.h>
15825#include <stdlib.h>
15826#include <time.h>
15827
15828#ifdef HAVE_UNISTD_H
15829# include <unistd.h>
15830#endif
15831
15832#ifndef HAVE_ALARM
15833# define alarm(X) /* empty */
15834#endif
15835
15836/* Work around redefinition to rpl_putenv by other config tests. */
15837#undef putenv
15838
15839static time_t time_t_max;
15840static time_t time_t_min;
15841
15842/* Values we'll use to set the TZ environment variable. */
15843static char *tz_strings[] = {
15844 (char *) 0, "TZ=GMT0", "TZ=JST-9",
15845 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
15846};
15847#define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
15848
15849/* Return 0 if mktime fails to convert a date in the spring-forward gap.
15850 Based on a problem report from Andreas Jaeger. */
15851static int
15852spring_forward_gap ()
15853{
15854 /* glibc (up to about 1998-10-07) failed this test. */
15855 struct tm tm;
15856
15857 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
15858 instead of "TZ=America/Vancouver" in order to detect the bug even
15859 on systems that don't support the Olson extension, or don't have the
15860 full zoneinfo tables installed. */
15861 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
15862
15863 tm.tm_year = 98;
15864 tm.tm_mon = 3;
15865 tm.tm_mday = 5;
15866 tm.tm_hour = 2;
15867 tm.tm_min = 0;
15868 tm.tm_sec = 0;
15869 tm.tm_isdst = -1;
15870 return mktime (&tm) != (time_t) -1;
15871}
15872
15873static int
15874mktime_test1 (time_t now)
15875{
15876 struct tm *lt;
15877 return ! (lt = localtime (&now)) || mktime (lt) == now;
15878}
15879
15880static int
15881mktime_test (time_t now)
15882{
15883 return (mktime_test1 (now)
15884 && mktime_test1 ((time_t) (time_t_max - now))
15885 && mktime_test1 ((time_t) (time_t_min + now)));
15886}
15887
15888static int
15889irix_6_4_bug ()
15890{
15891 /* Based on code from Ariel Faigon. */
15892 struct tm tm;
15893 tm.tm_year = 96;
15894 tm.tm_mon = 3;
15895 tm.tm_mday = 0;
15896 tm.tm_hour = 0;
15897 tm.tm_min = 0;
15898 tm.tm_sec = 0;
15899 tm.tm_isdst = -1;
15900 mktime (&tm);
15901 return tm.tm_mon == 2 && tm.tm_mday == 31;
15902}
15903
15904static int
15905bigtime_test (int j)
15906{
15907 struct tm tm;
15908 time_t now;
15909 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
15910 now = mktime (&tm);
15911 if (now != (time_t) -1)
15912 {
15913 struct tm *lt = localtime (&now);
15914 if (! (lt
15915 && lt->tm_year == tm.tm_year
15916 && lt->tm_mon == tm.tm_mon
15917 && lt->tm_mday == tm.tm_mday
15918 && lt->tm_hour == tm.tm_hour
15919 && lt->tm_min == tm.tm_min
15920 && lt->tm_sec == tm.tm_sec
15921 && lt->tm_yday == tm.tm_yday
15922 && lt->tm_wday == tm.tm_wday
15923 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
15924 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
15925 return 0;
15926 }
15927 return 1;
15928}
15929
15930static int
15931year_2050_test ()
15932{
15933 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
15934 ignoring leap seconds. */
15935 unsigned long int answer = 2527315200UL;
15936
15937 struct tm tm;
15938 time_t t;
15939 tm.tm_year = 2050 - 1900;
15940 tm.tm_mon = 2 - 1;
15941 tm.tm_mday = 1;
15942 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
15943 tm.tm_isdst = -1;
15944
15945 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
15946 instead of "TZ=America/Vancouver" in order to detect the bug even
15947 on systems that don't support the Olson extension, or don't have the
15948 full zoneinfo tables installed. */
15949 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
15950
15951 t = mktime (&tm);
15952
15953 /* Check that the result is either a failure, or close enough
15954 to the correct answer that we can assume the discrepancy is
15955 due to leap seconds. */
15956 return (t == (time_t) -1
15957 || (0 < t && answer - 120 <= t && t <= answer + 120));
15958}
15959
15960int
15961main ()
15962{
15963 int result = 0;
15964 time_t t, delta;
15965 int i, j;
3de84ad9
PE
15966 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
15967 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
1fd182f0
PE
15968
15969 /* This test makes some buggy mktime implementations loop.
15970 Give up after 60 seconds; a mktime slower than that
15971 isn't worth using anyway. */
15972 alarm (60);
15973
3de84ad9
PE
15974 time_t_max = (! time_t_signed
15975 ? (time_t) -1
15976 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
15977 * 2 + 1));
15978 time_t_min = (! time_t_signed
15979 ? (time_t) 0
15980 : time_t_signed_magnitude
15981 ? ~ (time_t) 0
15982 : ~ time_t_max);
1fd182f0
PE
15983
15984 delta = time_t_max / 997; /* a suitable prime number */
15985 for (i = 0; i < N_STRINGS; i++)
15986 {
15987 if (tz_strings[i])
15988 putenv (tz_strings[i]);
15989
15990 for (t = 0; t <= time_t_max - delta; t += delta)
15991 if (! mktime_test (t))
15992 result |= 1;
15993 if (! (mktime_test ((time_t) 1)
15994 && mktime_test ((time_t) (60 * 60))
15995 && mktime_test ((time_t) (60 * 60 * 24))))
15996 result |= 2;
15997
15998 for (j = 1; ; j <<= 1)
15999 if (! bigtime_test (j))
16000 result |= 4;
16001 else if (INT_MAX / 2 < j)
16002 break;
16003 if (! bigtime_test (INT_MAX))
16004 result |= 8;
16005 }
16006 if (! irix_6_4_bug ())
16007 result |= 16;
16008 if (! spring_forward_gap ())
16009 result |= 32;
16010 if (! year_2050_test ())
16011 result |= 64;
16012 return result;
16013}
16014_ACEOF
16015if ac_fn_c_try_run "$LINENO"; then :
16016 ac_cv_func_working_mktime=yes
16017else
16018 ac_cv_func_working_mktime=no
16019fi
16020rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16021 conftest.$ac_objext conftest.beam conftest.$ac_ext
067d23c9 16022fi
067d23c9 16023
1fd182f0
PE
16024fi
16025{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_working_mktime" >&5
16026$as_echo "$ac_cv_func_working_mktime" >&6; }
16027if test $ac_cv_func_working_mktime = no; then
067d23c9 16028
067d23c9 16029
067d23c9
KY
16030
16031
067d23c9 16032
067d23c9
KY
16033
16034
16035
1fd182f0 16036 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
067d23c9 16037
1fd182f0 16038fi
067d23c9 16039
1fd182f0
PE
16040 if test $ac_cv_func_working_mktime = no; then
16041 REPLACE_MKTIME=1
067d23c9
KY
16042
16043
16044
1fd182f0
PE
16045 else
16046 REPLACE_MKTIME=0
16047 fi
067d23c9
KY
16048
16049
16050
067d23c9 16051
1fd182f0 16052 GNULIB_MKTIME=1
067d23c9
KY
16053
16054
16055
1fd182f0 16056 # Code from module multiarch:
067d23c9 16057
16c3e636
PE
16058 # Code from module stdbool:
16059
16060
16061
16062 # Define two additional variables used in the Makefile substitution.
16063
16064 if test "$ac_cv_header_stdbool_h" = yes; then
16065 STDBOOL_H=''
16066 else
16067 STDBOOL_H='stdbool.h'
16068 fi
16069
16070
16071 if test "$ac_cv_type__Bool" = yes; then
16072 HAVE__BOOL=1
16073 else
16074 HAVE__BOOL=0
16075 fi
16076
16077
1fd182f0 16078 # Code from module stddef:
067d23c9 16079
067d23c9 16080
067d23c9 16081
1fd182f0
PE
16082 if test $gt_cv_c_wchar_t = no; then
16083 HAVE_WCHAR_T=0
16084 STDDEF_H=stddef.h
067d23c9 16085 fi
1fd182f0
PE
16086 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
16087$as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
d6974efa 16088if ${gl_cv_decl_null_works+:} false; then :
067d23c9 16089 $as_echo_n "(cached) " >&6
067d23c9
KY
16090else
16091 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16092/* end confdefs.h. */
1fd182f0
PE
16093#include <stddef.h>
16094 int test[2 * (sizeof NULL == sizeof (void *)) -1];
16095
067d23c9
KY
16096int
16097main ()
16098{
16099
067d23c9
KY
16100 ;
16101 return 0;
16102}
16103_ACEOF
1fd182f0
PE
16104if ac_fn_c_try_compile "$LINENO"; then :
16105 gl_cv_decl_null_works=yes
067d23c9 16106else
1fd182f0 16107 gl_cv_decl_null_works=no
067d23c9 16108fi
1fd182f0 16109rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
067d23c9 16110fi
1fd182f0
PE
16111{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
16112$as_echo "$gl_cv_decl_null_works" >&6; }
16113 if test $gl_cv_decl_null_works = no; then
16114 REPLACE_NULL=1
16115 STDDEF_H=stddef.h
16116 fi
16117 if test -n "$STDDEF_H"; then
16118
16119
16120
16121
16122
16123
b06b1098
PE
16124
16125
1fd182f0
PE
16126 if test $gl_cv_have_include_next = yes; then
16127 gl_cv_next_stddef_h='<'stddef.h'>'
16128 else
16129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
16130$as_echo_n "checking absolute name of <stddef.h>... " >&6; }
d6974efa 16131if ${gl_cv_next_stddef_h+:} false; then :
1fd182f0
PE
16132 $as_echo_n "(cached) " >&6
16133else
16134
b06b1098 16135 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1fd182f0
PE
16136/* end confdefs.h. */
16137#include <stddef.h>
16138
16139_ACEOF
b06b1098
PE
16140 case "$host_os" in
16141 aix*) gl_absname_cpp="$ac_cpp -C" ;;
16142 *) gl_absname_cpp="$ac_cpp" ;;
16143 esac
16144 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
16145 sed -n '\#/stddef.h#{
16146 s#.*"\(.*/stddef.h\)".*#\1#
16147 s#^/[^/]#//&#
16148 p
16149 q
16150 }'`'"'
16151
067d23c9
KY
16152
16153fi
1fd182f0
PE
16154{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
16155$as_echo "$gl_cv_next_stddef_h" >&6; }
16156 fi
16157 NEXT_STDDEF_H=$gl_cv_next_stddef_h
16158
16159 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
16160 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16161 gl_next_as_first_directive='<'stddef.h'>'
16162 else
16163 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16164 gl_next_as_first_directive=$gl_cv_next_stddef_h
16165 fi
16166 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
16167
16168
16169
b06b1098 16170
067d23c9
KY
16171 fi
16172
5f90be1b
PE
16173 # Code from module stdint:
16174
16175
16176
16177 if test $ac_cv_type_long_long_int = yes; then
16178 HAVE_LONG_LONG_INT=1
16179 else
16180 HAVE_LONG_LONG_INT=0
16181 fi
16182
16183
16184 if test $ac_cv_type_unsigned_long_long_int = yes; then
16185 HAVE_UNSIGNED_LONG_LONG_INT=1
16186 else
16187 HAVE_UNSIGNED_LONG_LONG_INT=0
16188 fi
16189
16190
16191
16192 if test $ac_cv_header_wchar_h = yes; then
16193 HAVE_WCHAR_H=1
16194 else
16195 HAVE_WCHAR_H=0
16196 fi
16197
16198
16199 if test $ac_cv_header_inttypes_h = yes; then
16200 HAVE_INTTYPES_H=1
16201 else
16202 HAVE_INTTYPES_H=0
16203 fi
16204
16205
16206 if test $ac_cv_header_sys_types_h = yes; then
16207 HAVE_SYS_TYPES_H=1
16208 else
16209 HAVE_SYS_TYPES_H=0
16210 fi
16211
16212
16213
16214
16215
16216
16217
16218
16219
16220
16221
16222 if test $gl_cv_have_include_next = yes; then
16223 gl_cv_next_stdint_h='<'stdint.h'>'
16224 else
16225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
16226$as_echo_n "checking absolute name of <stdint.h>... " >&6; }
16227if ${gl_cv_next_stdint_h+:} false; then :
16228 $as_echo_n "(cached) " >&6
16229else
16230
16231 if test $ac_cv_header_stdint_h = yes; then
16232
16233
16234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16235/* end confdefs.h. */
16236#include <stdint.h>
16237
16238_ACEOF
16239 case "$host_os" in
16240 aix*) gl_absname_cpp="$ac_cpp -C" ;;
16241 *) gl_absname_cpp="$ac_cpp" ;;
16242 esac
16243 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
16244 sed -n '\#/stdint.h#{
16245 s#.*"\(.*/stdint.h\)".*#\1#
16246 s#^/[^/]#//&#
16247 p
16248 q
16249 }'`'"'
16250 else
16251 gl_cv_next_stdint_h='<'stdint.h'>'
16252 fi
16253
16254
16255fi
16256{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
16257$as_echo "$gl_cv_next_stdint_h" >&6; }
16258 fi
16259 NEXT_STDINT_H=$gl_cv_next_stdint_h
16260
16261 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
16262 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16263 gl_next_as_first_directive='<'stdint.h'>'
16264 else
16265 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16266 gl_next_as_first_directive=$gl_cv_next_stdint_h
16267 fi
16268 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
16269
16270
16271
16272
16273 if test $ac_cv_header_stdint_h = yes; then
16274 HAVE_STDINT_H=1
16275 else
16276 HAVE_STDINT_H=0
16277 fi
16278
16279
16280 if test $ac_cv_header_stdint_h = yes; then
16281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
16282$as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
16283if ${gl_cv_header_working_stdint_h+:} false; then :
16284 $as_echo_n "(cached) " >&6
16285else
16286 gl_cv_header_working_stdint_h=no
16287 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16288/* end confdefs.h. */
16289
16290
16291#define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */
16292#define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */
16293#define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
16294#include <stdint.h>
16295/* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
16296#if !(defined WCHAR_MIN && defined WCHAR_MAX)
16297#error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
16298#endif
16299
16300
16301 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
16302 included before <wchar.h>. */
16303 #include <stddef.h>
16304 #include <signal.h>
16305 #if HAVE_WCHAR_H
16306 # include <stdio.h>
16307 # include <time.h>
16308 # include <wchar.h>
16309 #endif
16310
16311
16312#ifdef INT8_MAX
16313int8_t a1 = INT8_MAX;
16314int8_t a1min = INT8_MIN;
16315#endif
16316#ifdef INT16_MAX
16317int16_t a2 = INT16_MAX;
16318int16_t a2min = INT16_MIN;
16319#endif
16320#ifdef INT32_MAX
16321int32_t a3 = INT32_MAX;
16322int32_t a3min = INT32_MIN;
16323#endif
16324#ifdef INT64_MAX
16325int64_t a4 = INT64_MAX;
16326int64_t a4min = INT64_MIN;
16327#endif
16328#ifdef UINT8_MAX
16329uint8_t b1 = UINT8_MAX;
16330#else
16331typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
16332#endif
16333#ifdef UINT16_MAX
16334uint16_t b2 = UINT16_MAX;
16335#endif
16336#ifdef UINT32_MAX
16337uint32_t b3 = UINT32_MAX;
16338#endif
16339#ifdef UINT64_MAX
16340uint64_t b4 = UINT64_MAX;
16341#endif
16342int_least8_t c1 = INT8_C (0x7f);
16343int_least8_t c1max = INT_LEAST8_MAX;
16344int_least8_t c1min = INT_LEAST8_MIN;
16345int_least16_t c2 = INT16_C (0x7fff);
16346int_least16_t c2max = INT_LEAST16_MAX;
16347int_least16_t c2min = INT_LEAST16_MIN;
16348int_least32_t c3 = INT32_C (0x7fffffff);
16349int_least32_t c3max = INT_LEAST32_MAX;
16350int_least32_t c3min = INT_LEAST32_MIN;
16351int_least64_t c4 = INT64_C (0x7fffffffffffffff);
16352int_least64_t c4max = INT_LEAST64_MAX;
16353int_least64_t c4min = INT_LEAST64_MIN;
16354uint_least8_t d1 = UINT8_C (0xff);
16355uint_least8_t d1max = UINT_LEAST8_MAX;
16356uint_least16_t d2 = UINT16_C (0xffff);
16357uint_least16_t d2max = UINT_LEAST16_MAX;
16358uint_least32_t d3 = UINT32_C (0xffffffff);
16359uint_least32_t d3max = UINT_LEAST32_MAX;
16360uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
16361uint_least64_t d4max = UINT_LEAST64_MAX;
16362int_fast8_t e1 = INT_FAST8_MAX;
16363int_fast8_t e1min = INT_FAST8_MIN;
16364int_fast16_t e2 = INT_FAST16_MAX;
16365int_fast16_t e2min = INT_FAST16_MIN;
16366int_fast32_t e3 = INT_FAST32_MAX;
16367int_fast32_t e3min = INT_FAST32_MIN;
16368int_fast64_t e4 = INT_FAST64_MAX;
16369int_fast64_t e4min = INT_FAST64_MIN;
16370uint_fast8_t f1 = UINT_FAST8_MAX;
16371uint_fast16_t f2 = UINT_FAST16_MAX;
16372uint_fast32_t f3 = UINT_FAST32_MAX;
16373uint_fast64_t f4 = UINT_FAST64_MAX;
16374#ifdef INTPTR_MAX
16375intptr_t g = INTPTR_MAX;
16376intptr_t gmin = INTPTR_MIN;
16377#endif
16378#ifdef UINTPTR_MAX
16379uintptr_t h = UINTPTR_MAX;
16380#endif
16381intmax_t i = INTMAX_MAX;
16382uintmax_t j = UINTMAX_MAX;
16383
16384#include <limits.h> /* for CHAR_BIT */
16385#define TYPE_MINIMUM(t) \
16386 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
16387#define TYPE_MAXIMUM(t) \
16388 ((t) ((t) 0 < (t) -1 \
16389 ? (t) -1 \
16390 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
16391struct s {
16392 int check_PTRDIFF:
16393 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
16394 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
16395 ? 1 : -1;
16396 /* Detect bug in FreeBSD 6.0 / ia64. */
16397 int check_SIG_ATOMIC:
16398 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
16399 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
16400 ? 1 : -1;
16401 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
16402 int check_WCHAR:
16403 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
16404 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
16405 ? 1 : -1;
16406 /* Detect bug in mingw. */
16407 int check_WINT:
16408 WINT_MIN == TYPE_MINIMUM (wint_t)
16409 && WINT_MAX == TYPE_MAXIMUM (wint_t)
16410 ? 1 : -1;
16411
16412 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
16413 int check_UINT8_C:
16414 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
16415 int check_UINT16_C:
16416 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
16417
16418 /* Detect bugs in OpenBSD 3.9 stdint.h. */
16419#ifdef UINT8_MAX
16420 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
16421#endif
16422#ifdef UINT16_MAX
16423 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
16424#endif
16425#ifdef UINT32_MAX
16426 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
16427#endif
16428#ifdef UINT64_MAX
16429 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
16430#endif
16431 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
16432 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
16433 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
16434 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
16435 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
16436 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
16437 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
16438 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
16439 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
16440 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
16441 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
16442};
16443
16444int
16445main ()
16446{
16447
16448 ;
16449 return 0;
16450}
16451_ACEOF
16452if ac_fn_c_try_compile "$LINENO"; then :
16453 if test "$cross_compiling" = yes; then :
16454 gl_cv_header_working_stdint_h=yes
16455
16456else
16457 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16458/* end confdefs.h. */
16459
16460
16461#define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */
16462#define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */
16463#define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
16464#include <stdint.h>
16465
16466
16467 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
16468 included before <wchar.h>. */
16469 #include <stddef.h>
16470 #include <signal.h>
16471 #if HAVE_WCHAR_H
16472 # include <stdio.h>
16473 # include <time.h>
16474 # include <wchar.h>
16475 #endif
16476
16477
16478#include <stdio.h>
16479#include <string.h>
16480#define MVAL(macro) MVAL1(macro)
16481#define MVAL1(expression) #expression
16482static const char *macro_values[] =
16483 {
16484#ifdef INT8_MAX
16485 MVAL (INT8_MAX),
16486#endif
16487#ifdef INT16_MAX
16488 MVAL (INT16_MAX),
16489#endif
16490#ifdef INT32_MAX
16491 MVAL (INT32_MAX),
16492#endif
16493#ifdef INT64_MAX
16494 MVAL (INT64_MAX),
16495#endif
16496#ifdef UINT8_MAX
16497 MVAL (UINT8_MAX),
16498#endif
16499#ifdef UINT16_MAX
16500 MVAL (UINT16_MAX),
16501#endif
16502#ifdef UINT32_MAX
16503 MVAL (UINT32_MAX),
16504#endif
16505#ifdef UINT64_MAX
16506 MVAL (UINT64_MAX),
16507#endif
16508 NULL
16509 };
16510
16511int
16512main ()
16513{
16514
16515 const char **mv;
16516 for (mv = macro_values; *mv != NULL; mv++)
16517 {
16518 const char *value = *mv;
16519 /* Test whether it looks like a cast expression. */
16520 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
16521 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
16522 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
16523 || strncmp (value, "((int)"/*)*/, 6) == 0
16524 || strncmp (value, "((signed short)"/*)*/, 15) == 0
16525 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
16526 return mv - macro_values + 1;
16527 }
16528 return 0;
16529
16530 ;
16531 return 0;
16532}
16533_ACEOF
16534if ac_fn_c_try_run "$LINENO"; then :
16535 gl_cv_header_working_stdint_h=yes
16536fi
16537rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16538 conftest.$ac_objext conftest.beam conftest.$ac_ext
16539fi
16540
16541
16542fi
16543rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16544
16545fi
16546{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
16547$as_echo "$gl_cv_header_working_stdint_h" >&6; }
16548 fi
16549 if test "$gl_cv_header_working_stdint_h" = yes; then
16550 STDINT_H=
16551 else
16552 for ac_header in sys/inttypes.h sys/bitypes.h
16553do :
16554 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
16555ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
16556if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
16557 cat >>confdefs.h <<_ACEOF
16558#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
16559_ACEOF
16560
16561fi
16562
16563done
16564
16565 if test $ac_cv_header_sys_inttypes_h = yes; then
16566 HAVE_SYS_INTTYPES_H=1
16567 else
16568 HAVE_SYS_INTTYPES_H=0
16569 fi
16570
16571 if test $ac_cv_header_sys_bitypes_h = yes; then
16572 HAVE_SYS_BITYPES_H=1
16573 else
16574 HAVE_SYS_BITYPES_H=0
16575 fi
16576
16577
16578
16579
16580 if test $APPLE_UNIVERSAL_BUILD = 0; then
16581
16582
16583 for gltype in ptrdiff_t size_t ; do
16584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
16585$as_echo_n "checking for bit size of $gltype... " >&6; }
16586if eval \${gl_cv_bitsizeof_${gltype}+:} false; then :
16587 $as_echo_n "(cached) " >&6
16588else
16589 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
16590 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
16591 included before <wchar.h>. */
16592 #include <stddef.h>
16593 #include <signal.h>
16594 #if HAVE_WCHAR_H
16595 # include <stdio.h>
16596 # include <time.h>
16597 # include <wchar.h>
16598 #endif
16599
16600#include <limits.h>"; then :
16601
16602else
16603 result=unknown
16604fi
16605
16606 eval gl_cv_bitsizeof_${gltype}=\$result
16607
16608fi
16609eval ac_res=\$gl_cv_bitsizeof_${gltype}
16610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
16611$as_echo "$ac_res" >&6; }
16612 eval result=\$gl_cv_bitsizeof_${gltype}
16613 if test $result = unknown; then
16614 result=0
16615 fi
16616 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
16617 cat >>confdefs.h <<_ACEOF
16618#define BITSIZEOF_${GLTYPE} $result
16619_ACEOF
16620
16621 eval BITSIZEOF_${GLTYPE}=\$result
16622 done
16623
16624
16625 fi
16626
16627
16628 for gltype in sig_atomic_t wchar_t wint_t ; do
16629 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
16630$as_echo_n "checking for bit size of $gltype... " >&6; }
16631if eval \${gl_cv_bitsizeof_${gltype}+:} false; then :
16632 $as_echo_n "(cached) " >&6
16633else
16634 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
16635 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
16636 included before <wchar.h>. */
16637 #include <stddef.h>
16638 #include <signal.h>
16639 #if HAVE_WCHAR_H
16640 # include <stdio.h>
16641 # include <time.h>
16642 # include <wchar.h>
16643 #endif
16644
16645#include <limits.h>"; then :
16646
16647else
16648 result=unknown
16649fi
16650
16651 eval gl_cv_bitsizeof_${gltype}=\$result
16652
16653fi
16654eval ac_res=\$gl_cv_bitsizeof_${gltype}
16655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
16656$as_echo "$ac_res" >&6; }
16657 eval result=\$gl_cv_bitsizeof_${gltype}
16658 if test $result = unknown; then
16659 result=0
16660 fi
16661 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
16662 cat >>confdefs.h <<_ACEOF
16663#define BITSIZEOF_${GLTYPE} $result
16664_ACEOF
16665
16666 eval BITSIZEOF_${GLTYPE}=\$result
16667 done
16668
16669
16670
16671
16672 for gltype in sig_atomic_t wchar_t wint_t ; do
16673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
16674$as_echo_n "checking whether $gltype is signed... " >&6; }
16675if eval \${gl_cv_type_${gltype}_signed+:} false; then :
16676 $as_echo_n "(cached) " >&6
16677else
16678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16679/* end confdefs.h. */
16680
16681 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
16682 included before <wchar.h>. */
16683 #include <stddef.h>
16684 #include <signal.h>
16685 #if HAVE_WCHAR_H
16686 # include <stdio.h>
16687 # include <time.h>
16688 # include <wchar.h>
16689 #endif
16690
16691 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
16692int
16693main ()
16694{
16695
16696 ;
16697 return 0;
16698}
16699_ACEOF
16700if ac_fn_c_try_compile "$LINENO"; then :
16701 result=yes
16702else
16703 result=no
16704fi
16705rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16706 eval gl_cv_type_${gltype}_signed=\$result
16707
16708fi
16709eval ac_res=\$gl_cv_type_${gltype}_signed
16710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
16711$as_echo "$ac_res" >&6; }
16712 eval result=\$gl_cv_type_${gltype}_signed
16713 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
16714 if test "$result" = yes; then
16715 cat >>confdefs.h <<_ACEOF
16716#define HAVE_SIGNED_${GLTYPE} 1
16717_ACEOF
16718
16719 eval HAVE_SIGNED_${GLTYPE}=1
16720 else
16721 eval HAVE_SIGNED_${GLTYPE}=0
16722 fi
16723 done
16724
16725
16726 gl_cv_type_ptrdiff_t_signed=yes
16727 gl_cv_type_size_t_signed=no
16728 if test $APPLE_UNIVERSAL_BUILD = 0; then
16729
16730
16731 for gltype in ptrdiff_t size_t ; do
16732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
16733$as_echo_n "checking for $gltype integer literal suffix... " >&6; }
16734if eval \${gl_cv_type_${gltype}_suffix+:} false; then :
16735 $as_echo_n "(cached) " >&6
16736else
16737 eval gl_cv_type_${gltype}_suffix=no
16738 eval result=\$gl_cv_type_${gltype}_signed
16739 if test "$result" = yes; then
16740 glsufu=
16741 else
16742 glsufu=u
16743 fi
16744 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
16745 case $glsuf in
16746 '') gltype1='int';;
16747 l) gltype1='long int';;
16748 ll) gltype1='long long int';;
16749 i64) gltype1='__int64';;
16750 u) gltype1='unsigned int';;
16751 ul) gltype1='unsigned long int';;
16752 ull) gltype1='unsigned long long int';;
16753 ui64)gltype1='unsigned __int64';;
16754 esac
16755 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16756/* end confdefs.h. */
16757
16758 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
16759 included before <wchar.h>. */
16760 #include <stddef.h>
16761 #include <signal.h>
16762 #if HAVE_WCHAR_H
16763 # include <stdio.h>
16764 # include <time.h>
16765 # include <wchar.h>
16766 #endif
16767
16768 extern $gltype foo;
16769 extern $gltype1 foo;
16770int
16771main ()
16772{
16773
16774 ;
16775 return 0;
16776}
16777_ACEOF
16778if ac_fn_c_try_compile "$LINENO"; then :
16779 eval gl_cv_type_${gltype}_suffix=\$glsuf
16780fi
16781rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16782 eval result=\$gl_cv_type_${gltype}_suffix
16783 test "$result" != no && break
16784 done
16785fi
16786eval ac_res=\$gl_cv_type_${gltype}_suffix
16787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
16788$as_echo "$ac_res" >&6; }
16789 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
16790 eval result=\$gl_cv_type_${gltype}_suffix
16791 test "$result" = no && result=
16792 eval ${GLTYPE}_SUFFIX=\$result
16793 cat >>confdefs.h <<_ACEOF
16794#define ${GLTYPE}_SUFFIX $result
16795_ACEOF
16796
16797 done
16798
16799
16800 fi
16801
16802
16803 for gltype in sig_atomic_t wchar_t wint_t ; do
16804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
16805$as_echo_n "checking for $gltype integer literal suffix... " >&6; }
16806if eval \${gl_cv_type_${gltype}_suffix+:} false; then :
16807 $as_echo_n "(cached) " >&6
16808else
16809 eval gl_cv_type_${gltype}_suffix=no
16810 eval result=\$gl_cv_type_${gltype}_signed
16811 if test "$result" = yes; then
16812 glsufu=
16813 else
16814 glsufu=u
16815 fi
16816 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
16817 case $glsuf in
16818 '') gltype1='int';;
16819 l) gltype1='long int';;
16820 ll) gltype1='long long int';;
16821 i64) gltype1='__int64';;
16822 u) gltype1='unsigned int';;
16823 ul) gltype1='unsigned long int';;
16824 ull) gltype1='unsigned long long int';;
16825 ui64)gltype1='unsigned __int64';;
16826 esac
16827 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16828/* end confdefs.h. */
16829
16830 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
16831 included before <wchar.h>. */
16832 #include <stddef.h>
16833 #include <signal.h>
16834 #if HAVE_WCHAR_H
16835 # include <stdio.h>
16836 # include <time.h>
16837 # include <wchar.h>
16838 #endif
16839
16840 extern $gltype foo;
16841 extern $gltype1 foo;
16842int
16843main ()
16844{
16845
16846 ;
16847 return 0;
16848}
16849_ACEOF
16850if ac_fn_c_try_compile "$LINENO"; then :
16851 eval gl_cv_type_${gltype}_suffix=\$glsuf
16852fi
16853rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16854 eval result=\$gl_cv_type_${gltype}_suffix
16855 test "$result" != no && break
16856 done
16857fi
16858eval ac_res=\$gl_cv_type_${gltype}_suffix
16859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
16860$as_echo "$ac_res" >&6; }
16861 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
16862 eval result=\$gl_cv_type_${gltype}_suffix
16863 test "$result" = no && result=
16864 eval ${GLTYPE}_SUFFIX=\$result
16865 cat >>confdefs.h <<_ACEOF
16866#define ${GLTYPE}_SUFFIX $result
16867_ACEOF
16868
16869 done
16870
16871
16872
16873 STDINT_H=stdint.h
16874 fi
16875
16876
1f5d53eb
PE
16877 # Code from module stdlib:
16878
16879
16880
16881
16882
16883
16884
16885
16886
16887
16888 if test $gl_cv_have_include_next = yes; then
16889 gl_cv_next_stdlib_h='<'stdlib.h'>'
16890 else
16891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
16892$as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
16893if ${gl_cv_next_stdlib_h+:} false; then :
16894 $as_echo_n "(cached) " >&6
16895else
16896
16897 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16898/* end confdefs.h. */
16899#include <stdlib.h>
16900
16901_ACEOF
16902 case "$host_os" in
16903 aix*) gl_absname_cpp="$ac_cpp -C" ;;
16904 *) gl_absname_cpp="$ac_cpp" ;;
16905 esac
16906 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
16907 sed -n '\#/stdlib.h#{
16908 s#.*"\(.*/stdlib.h\)".*#\1#
16909 s#^/[^/]#//&#
16910 p
16911 q
16912 }'`'"'
16913
16914
16915fi
16916{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
16917$as_echo "$gl_cv_next_stdlib_h" >&6; }
16918 fi
16919 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
16920
16921 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
16922 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16923 gl_next_as_first_directive='<'stdlib.h'>'
16924 else
16925 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16926 gl_next_as_first_directive=$gl_cv_next_stdlib_h
16927 fi
16928 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
16929
16930
16931
16932
16933
16934
16935
16c3e636
PE
16936 # Code from module strftime:
16937
16938
16939
16940
16941
16942
16943
16944
16945
16946
16947 gl_LIBOBJS="$gl_LIBOBJS strftime.$ac_objext"
16948
16949
16950 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
16951
16952
16953
16954
16955
16956
16957
16958$as_echo "#define my_strftime nstrftime" >>confdefs.h
16959
16960
16961
5fa4ac76
PE
16962 # Code from module sys_stat:
16963
16964
16965
16966
16967
16968
16969
16970
16971
16972
16973
16974
16975
16976
16977
16978
16979 if test $gl_cv_have_include_next = yes; then
16980 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
16981 else
16982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
16983$as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
16984if ${gl_cv_next_sys_stat_h+:} false; then :
16985 $as_echo_n "(cached) " >&6
16986else
16987
16988 if test $ac_cv_header_sys_stat_h = yes; then
16989
16990
16991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16992/* end confdefs.h. */
16993#include <sys/stat.h>
16994
16995_ACEOF
16996 case "$host_os" in
16997 aix*) gl_absname_cpp="$ac_cpp -C" ;;
16998 *) gl_absname_cpp="$ac_cpp" ;;
16999 esac
17000 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17001 sed -n '\#/sys/stat.h#{
17002 s#.*"\(.*/sys/stat.h\)".*#\1#
17003 s#^/[^/]#//&#
17004 p
17005 q
17006 }'`'"'
17007 else
17008 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
17009 fi
17010
17011
17012fi
17013{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
17014$as_echo "$gl_cv_next_sys_stat_h" >&6; }
17015 fi
17016 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
17017
17018 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17019 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17020 gl_next_as_first_directive='<'sys/stat.h'>'
17021 else
17022 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17023 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
17024 fi
17025 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
17026
17027
17028
17029
17030
17031 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
17032 #include <sys/stat.h>
17033"
17034if test "x$ac_cv_type_nlink_t" = xyes; then :
17035
17036else
17037
17038$as_echo "#define nlink_t int" >>confdefs.h
17039
17040fi
17041
17042
17043
17044
17045
1fd182f0 17046 # Code from module time:
067d23c9
KY
17047
17048
067d23c9 17049
1fd182f0 17050 # Code from module time_r:
067d23c9 17051
067d23c9 17052
067d23c9
KY
17053
17054
17055
067d23c9 17056
067d23c9 17057
1fd182f0
PE
17058 if test $ac_cv_have_decl_localtime_r = no; then
17059 HAVE_DECL_LOCALTIME_R=0
17060 fi
067d23c9
KY
17061
17062
1fd182f0
PE
17063 if test $ac_cv_func_localtime_r = yes; then
17064 HAVE_LOCALTIME_R=1
17065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
17066$as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
d6974efa 17067if ${gl_cv_time_r_posix+:} false; then :
067d23c9
KY
17068 $as_echo_n "(cached) " >&6
17069else
1fd182f0 17070 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
067d23c9 17071/* end confdefs.h. */
1fd182f0 17072#include <time.h>
067d23c9
KY
17073int
17074main ()
17075{
1fd182f0
PE
17076/* We don't need to append 'restrict's to the argument types,
17077 even though the POSIX signature has the 'restrict's,
17078 since C99 says they can't affect type compatibility. */
17079 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
17080 if (ptr) return 0;
17081 /* Check the return type is a pointer.
17082 On HP-UX 10 it is 'int'. */
17083 *localtime_r (0, 0);
067d23c9
KY
17084 ;
17085 return 0;
17086}
1fd182f0 17087
067d23c9
KY
17088_ACEOF
17089if ac_fn_c_try_compile "$LINENO"; then :
1fd182f0 17090 gl_cv_time_r_posix=yes
067d23c9 17091else
1fd182f0 17092 gl_cv_time_r_posix=no
067d23c9
KY
17093fi
17094rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17095
17096fi
1fd182f0
PE
17097{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
17098$as_echo "$gl_cv_time_r_posix" >&6; }
17099 if test $gl_cv_time_r_posix = yes; then
17100 REPLACE_LOCALTIME_R=0
17101 else
17102 REPLACE_LOCALTIME_R=1
17103 fi
17104 else
17105 HAVE_LOCALTIME_R=0
17106 fi
17107 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
067d23c9 17108
067d23c9
KY
17109
17110
743c80a7 17111
a451f14b
PE
17112
17113
17114
a451f14b 17115
1fd182f0 17116 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
a451f14b 17117
a451f14b 17118
1fd182f0 17119 :
a451f14b
PE
17120
17121 fi
17122
17123
743c80a7
PE
17124
17125
1fd182f0 17126 GNULIB_TIME_R=1
743c80a7
PE
17127
17128
17129
b06b1098 17130 # Code from module unistd:
a451f14b
PE
17131
17132
17133
e275c824
PE
17134
17135
17136
17137
17138
17139
17140
17141
17142
17143
17144 if test $gl_cv_have_include_next = yes; then
17145 gl_cv_next_unistd_h='<'unistd.h'>'
17146 else
17147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
17148$as_echo_n "checking absolute name of <unistd.h>... " >&6; }
d6974efa 17149if ${gl_cv_next_unistd_h+:} false; then :
e275c824
PE
17150 $as_echo_n "(cached) " >&6
17151else
17152
b06b1098
PE
17153 if test $ac_cv_header_unistd_h = yes; then
17154
17155
17156 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
e275c824
PE
17157/* end confdefs.h. */
17158#include <unistd.h>
17159
17160_ACEOF
b06b1098
PE
17161 case "$host_os" in
17162 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17163 *) gl_absname_cpp="$ac_cpp" ;;
17164 esac
17165 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17166 sed -n '\#/unistd.h#{
17167 s#.*"\(.*/unistd.h\)".*#\1#
17168 s#^/[^/]#//&#
17169 p
17170 q
17171 }'`'"'
e275c824 17172 else
b06b1098
PE
17173 gl_cv_next_unistd_h='<'unistd.h'>'
17174 fi
17175
e275c824
PE
17176
17177fi
17178{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
17179$as_echo "$gl_cv_next_unistd_h" >&6; }
17180 fi
17181 NEXT_UNISTD_H=$gl_cv_next_unistd_h
17182
17183 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17184 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17185 gl_next_as_first_directive='<'unistd.h'>'
17186 else
17187 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17188 gl_next_as_first_directive=$gl_cv_next_unistd_h
17189 fi
17190 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
17191
17192
17193
17194
e275c824
PE
17195 if test $ac_cv_header_unistd_h = yes; then
17196 HAVE_UNISTD_H=1
17197 else
17198 HAVE_UNISTD_H=0
17199 fi
17200
17201
17202
e275c824 17203
1fd182f0
PE
17204 # Code from module warn-on-use:
17205 # End of code from modules
a451f14b 17206
a451f14b 17207
743c80a7
PE
17208
17209
17210
17211
17212
17213
17214
17215 gltests_libdeps=
17216 gltests_ltlibdeps=
17217
17218
17219
17220
17221
a451f14b
PE
17222
17223
17224
17225
743c80a7
PE
17226 gl_source_base='tests'
17227 gltests_WITNESS=IN_`echo "${PACKAGE-$PACKAGE_TARNAME}" | LC_ALL=C tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ | LC_ALL=C sed -e 's/[^A-Z0-9_]/_/g'`_GNULIB_TESTS
17228
17229 gl_module_indicator_condition=$gltests_WITNESS
17230
17231
17232
17233
17234
17235
17236
17237
17238
17239 LIBGNU_LIBDEPS="$gl_libdeps"
17240
17241 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
17242
17243
17244
067d23c9
KY
17245# UNIX98 PTYs.
17246for ac_func in grantpt
17247do :
17248 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
d6974efa 17249if test "x$ac_cv_func_grantpt" = xyes; then :
067d23c9
KY
17250 cat >>confdefs.h <<_ACEOF
17251#define HAVE_GRANTPT 1
17252_ACEOF
17253
17254fi
17255done
17256
17257
17258# PTY-related GNU extensions.
17259for ac_func in getpt
17260do :
17261 ac_fn_c_check_func "$LINENO" "getpt" "ac_cv_func_getpt"
d6974efa 17262if test "x$ac_cv_func_getpt" = xyes; then :
067d23c9
KY
17263 cat >>confdefs.h <<_ACEOF
17264#define HAVE_GETPT 1
17265_ACEOF
17266
17267fi
17268done
17269
17270
17271# Check this now, so that we will NOT find the above functions in ncurses.
17272# That is because we have not set up to link ncurses in lib-src.
17273# It's better to believe a function is not available
17274# than to expect to find it in ncurses.
17275# Also we need tputs and friends to be able to build at all.
17276have_tputs_et_al=true
17277{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
17278$as_echo_n "checking for library containing tputs... " >&6; }
d6974efa 17279if ${ac_cv_search_tputs+:} false; then :
067d23c9
KY
17280 $as_echo_n "(cached) " >&6
17281else
17282 ac_func_search_save_LIBS=$LIBS
17283cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17284/* end confdefs.h. */
17285
17286/* Override any GCC internal prototype to avoid an error.
17287 Use char because int might match the return type of a GCC
17288 builtin and then its argument prototype would still apply. */
17289#ifdef __cplusplus
17290extern "C"
17291#endif
17292char tputs ();
17293int
17294main ()
17295{
17296return tputs ();
17297 ;
17298 return 0;
17299}
17300_ACEOF
17301for ac_lib in '' ncurses terminfo termcap; do
17302 if test -z "$ac_lib"; then
17303 ac_res="none required"
17304 else
17305 ac_res=-l$ac_lib
17306 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
17307 fi
17308 if ac_fn_c_try_link "$LINENO"; then :
17309 ac_cv_search_tputs=$ac_res
17310fi
17311rm -f core conftest.err conftest.$ac_objext \
17312 conftest$ac_exeext
d6974efa 17313 if ${ac_cv_search_tputs+:} false; then :
067d23c9
KY
17314 break
17315fi
17316done
d6974efa 17317if ${ac_cv_search_tputs+:} false; then :
067d23c9
KY
17318
17319else
17320 ac_cv_search_tputs=no
17321fi
17322rm conftest.$ac_ext
17323LIBS=$ac_func_search_save_LIBS
17324fi
17325{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_tputs" >&5
17326$as_echo "$ac_cv_search_tputs" >&6; }
17327ac_res=$ac_cv_search_tputs
17328if test "$ac_res" != no; then :
17329 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17330
17331else
17332 have_tputs_et_al=false
17333fi
17334
17335if test "$have_tputs_et_al" != true; then
2018939f 17336 as_fn_error $? "I couldn't find termcap functions (tputs and friends).
067d23c9
KY
17337Maybe some development libraries/packages are missing? Try installing
17338libncurses-dev(el), libterminfo-dev(el) or similar." "$LINENO" 5
17339fi
17340# Must define this when any termcap library is found.
17341
17342$as_echo "#define HAVE_LIBNCURSES 1" >>confdefs.h
17343
17344## FIXME This was the cpp logic, but I am not sure it is right.
17345## The above test has not necessarily found libncurses.
17346HAVE_LIBNCURSES=yes
17347
17348## Use terminfo instead of termcap?
17349## Note only system files NOT using terminfo are:
17350## freebsd < 40000, ms-w32, msdos, netbsd < 599002500, and
17351## darwin|gnu without ncurses.
17352TERMINFO=no
17353LIBS_TERMCAP=
17354case "$opsys" in
17355 ## cygwin: Fewer environment variables to go wrong, more terminal types.
17356 ## hpux10-20: Use the system provided termcap(3) library.
17357 ## openbsd: David Mazieres <dm@reeducation-labor.lcs.mit.edu> says this
17358 ## is necessary. Otherwise Emacs dumps core when run -nw.
17359 aix4-2|cygwin|hpux*|irix6-5|openbsd|sol2*|unixware) TERMINFO=yes ;;
17360
17361 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
17362 ## The ncurses library has been moved out of the System framework in
17363 ## Mac OS X 10.2. So if configure detects it, set the command-line
17364 ## option to use it.
17365 darwin|gnu*)
17366 ## (HAVE_LIBNCURSES was not always true, but is since 2010-03-18.)
17367 if test "x$HAVE_LIBNCURSES" = "xyes"; then
17368 TERMINFO=yes
17369 LIBS_TERMCAP="-lncurses"
17370 fi
17371 ;;
17372
17373 freebsd)
17374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
17375$as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
d6974efa 17376 if ${emacs_cv_freebsd_terminfo+:} false; then :
067d23c9
KY
17377 $as_echo_n "(cached) " >&6
17378else
17379 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17380/* end confdefs.h. */
17381#include <osreldate.h>
17382int
17383main ()
17384{
17385#if __FreeBSD_version < 400000
17386fail;
17387#endif
17388
17389 ;
17390 return 0;
17391}
17392_ACEOF
17393if ac_fn_c_try_link "$LINENO"; then :
17394 emacs_cv_freebsd_terminfo=yes
17395else
17396 emacs_cv_freebsd_terminfo=no
17397fi
17398rm -f core conftest.err conftest.$ac_objext \
17399 conftest$ac_exeext conftest.$ac_ext
17400fi
17401
17402
17403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
17404$as_echo "$emacs_cv_freebsd_terminfo" >&6; }
17405
17406 if test $emacs_cv_freebsd_terminfo = yes; then
17407 TERMINFO=yes
17408 LIBS_TERMCAP="-lncurses"
17409 else
17410 LIBS_TERMCAP="-ltermcap"
17411 fi
17412 ;;
17413
17414 netbsd)
17415 if test $ac_cv_search_tputs = -lterminfo; then
17416 TERMINFO=yes
17417 LIBS_TERMCAP="-lterminfo"
17418 else
17419 LIBS_TERMCAP="-ltermcap"
17420 fi
17421 ;;
17422
17423esac
17424
17425case "$opsys" in
17426 ## hpux: Make sure we get select from libc rather than from libcurses
17427 ## because libcurses on HPUX 10.10 has a broken version of select.
17428 ## We used to use -lc -lcurses, but this may be cleaner.
17429 hpux*) LIBS_TERMCAP="-ltermcap" ;;
17430
17431 openbsd) LIBS_TERMCAP="-lncurses" ;;
17432
17433 ## Must use system termcap, if we use any termcap. It does special things.
17434 sol2*) test "$TERMINFO" != yes && LIBS_TERMCAP="-ltermcap" ;;
17435esac
17436
17437TERMCAP_OBJ=tparam.o
17438if test $TERMINFO = yes; then
17439
17440$as_echo "#define TERMINFO 1" >>confdefs.h
17441
17442
17443 ## Default used to be -ltermcap. Add a case above if need something else.
17444 test "x$LIBS_TERMCAP" = "x" && LIBS_TERMCAP="-lcurses"
17445
17446 TERMCAP_OBJ=terminfo.o
17447fi
17448
17449
17450
17451
17452# Do we have res_init, for detecting changes in /etc/resolv.conf?
17453resolv=no
17454cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17455/* end confdefs.h. */
17456#include <netinet/in.h>
17457#include <arpa/nameser.h>
17458#include <resolv.h>
17459int
17460main ()
17461{
17462return res_init();
17463 ;
17464 return 0;
17465}
17466_ACEOF
17467if ac_fn_c_try_link "$LINENO"; then :
17468 have_res_init=yes
17469else
17470 have_res_init=no
17471fi
17472rm -f core conftest.err conftest.$ac_objext \
17473 conftest$ac_exeext conftest.$ac_ext
17474if test "$have_res_init" = no; then
17475 OLIBS="$LIBS"
17476 LIBS="$LIBS -lresolv"
17477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
17478$as_echo_n "checking for res_init with -lresolv... " >&6; }
17479 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17480/* end confdefs.h. */
17481#include <netinet/in.h>
17482#include <arpa/nameser.h>
17483#include <resolv.h>
17484int
17485main ()
17486{
17487return res_init();
17488 ;
17489 return 0;
17490}
17491_ACEOF
17492if ac_fn_c_try_link "$LINENO"; then :
17493 have_res_init=yes
17494else
17495 have_res_init=no
17496fi
17497rm -f core conftest.err conftest.$ac_objext \
17498 conftest$ac_exeext conftest.$ac_ext
17499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
17500$as_echo "$have_res_init" >&6; }
17501 if test "$have_res_init" = yes ; then
17502 resolv=yes
17503 fi
17504 LIBS="$OLIBS"
17505fi
17506
17507if test "$have_res_init" = yes; then
17508
17509$as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
17510
17511fi
17512
17513# Do we need the Hesiod library to provide the support routines?
17514LIBHESIOD=
17515if test "$with_hesiod" != no ; then
17516 # Don't set $LIBS here -- see comments above. FIXME which comments?
17517 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
d6974efa 17518if test "x$ac_cv_func_res_send" = xyes; then :
067d23c9
KY
17519
17520else
17521 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
d6974efa 17522if test "x$ac_cv_func___res_send" = xyes; then :
067d23c9
KY
17523
17524else
17525 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
17526$as_echo_n "checking for res_send in -lresolv... " >&6; }
d6974efa 17527if ${ac_cv_lib_resolv_res_send+:} false; then :
067d23c9
KY
17528 $as_echo_n "(cached) " >&6
17529else
17530 ac_check_lib_save_LIBS=$LIBS
17531LIBS="-lresolv $LIBS"
17532cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17533/* end confdefs.h. */
17534
17535/* Override any GCC internal prototype to avoid an error.
17536 Use char because int might match the return type of a GCC
17537 builtin and then its argument prototype would still apply. */
17538#ifdef __cplusplus
17539extern "C"
17540#endif
17541char res_send ();
17542int
17543main ()
17544{
17545return res_send ();
17546 ;
17547 return 0;
17548}
17549_ACEOF
17550if ac_fn_c_try_link "$LINENO"; then :
17551 ac_cv_lib_resolv_res_send=yes
17552else
17553 ac_cv_lib_resolv_res_send=no
17554fi
17555rm -f core conftest.err conftest.$ac_objext \
17556 conftest$ac_exeext conftest.$ac_ext
17557LIBS=$ac_check_lib_save_LIBS
17558fi
17559{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
17560$as_echo "$ac_cv_lib_resolv_res_send" >&6; }
d6974efa 17561if test "x$ac_cv_lib_resolv_res_send" = xyes; then :
067d23c9
KY
17562 resolv=yes
17563else
17564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
17565$as_echo_n "checking for __res_send in -lresolv... " >&6; }
d6974efa 17566if ${ac_cv_lib_resolv___res_send+:} false; then :
067d23c9
KY
17567 $as_echo_n "(cached) " >&6
17568else
17569 ac_check_lib_save_LIBS=$LIBS
17570LIBS="-lresolv $LIBS"
17571cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17572/* end confdefs.h. */
17573
17574/* Override any GCC internal prototype to avoid an error.
17575 Use char because int might match the return type of a GCC
17576 builtin and then its argument prototype would still apply. */
17577#ifdef __cplusplus
17578extern "C"
17579#endif
17580char __res_send ();
17581int
17582main ()
17583{
17584return __res_send ();
17585 ;
17586 return 0;
17587}
17588_ACEOF
17589if ac_fn_c_try_link "$LINENO"; then :
17590 ac_cv_lib_resolv___res_send=yes
17591else
17592 ac_cv_lib_resolv___res_send=no
17593fi
17594rm -f core conftest.err conftest.$ac_objext \
17595 conftest$ac_exeext conftest.$ac_ext
17596LIBS=$ac_check_lib_save_LIBS
17597fi
17598{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
17599$as_echo "$ac_cv_lib_resolv___res_send" >&6; }
d6974efa 17600if test "x$ac_cv_lib_resolv___res_send" = xyes; then :
067d23c9
KY
17601 resolv=yes
17602fi
17603
17604fi
17605
17606fi
17607
17608fi
17609
17610 if test "$resolv" = yes ; then
17611 RESOLVLIB=-lresolv
17612 else
17613 RESOLVLIB=
17614 fi
17615 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
d6974efa 17616if test "x$ac_cv_func_hes_getmailhost" = xyes; then :
067d23c9
KY
17617
17618else
17619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
17620$as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
d6974efa 17621if ${ac_cv_lib_hesiod_hes_getmailhost+:} false; then :
067d23c9
KY
17622 $as_echo_n "(cached) " >&6
17623else
17624 ac_check_lib_save_LIBS=$LIBS
17625LIBS="-lhesiod $RESOLVLIB $LIBS"
17626cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17627/* end confdefs.h. */
17628
17629/* Override any GCC internal prototype to avoid an error.
17630 Use char because int might match the return type of a GCC
17631 builtin and then its argument prototype would still apply. */
17632#ifdef __cplusplus
17633extern "C"
17634#endif
17635char hes_getmailhost ();
17636int
17637main ()
17638{
17639return hes_getmailhost ();
17640 ;
17641 return 0;
17642}
17643_ACEOF
17644if ac_fn_c_try_link "$LINENO"; then :
17645 ac_cv_lib_hesiod_hes_getmailhost=yes
17646else
17647 ac_cv_lib_hesiod_hes_getmailhost=no
17648fi
17649rm -f core conftest.err conftest.$ac_objext \
17650 conftest$ac_exeext conftest.$ac_ext
17651LIBS=$ac_check_lib_save_LIBS
17652fi
17653{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
17654$as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
d6974efa 17655if test "x$ac_cv_lib_hesiod_hes_getmailhost" = xyes; then :
067d23c9
KY
17656 hesiod=yes
17657else
17658 :
17659fi
17660
17661fi
17662
17663
17664 if test x"$hesiod" = xyes; then
17665
17666$as_echo "#define HAVE_LIBHESIOD 1" >>confdefs.h
17667
17668 LIBHESIOD=-lhesiod
17669 fi
17670fi
17671
17672
17673# Do we need libresolv (due to res_init or Hesiod)?
17674if test "$resolv" = yes ; then
17675
17676$as_echo "#define HAVE_LIBRESOLV 1" >>confdefs.h
17677
17678 LIBRESOLV=-lresolv
17679else
17680 LIBRESOLV=
17681fi
17682
17683
17684# These tell us which Kerberos-related libraries to use.
17685COM_ERRLIB=
17686CRYPTOLIB=
17687KRB5LIB=
17688DESLIB=
17689KRB4LIB=
17690
17691if test "${with_kerberos}" != no; then
17692 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
17693$as_echo_n "checking for com_err in -lcom_err... " >&6; }
d6974efa 17694if ${ac_cv_lib_com_err_com_err+:} false; then :
067d23c9
KY
17695 $as_echo_n "(cached) " >&6
17696else
17697 ac_check_lib_save_LIBS=$LIBS
17698LIBS="-lcom_err $LIBS"
17699cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17700/* end confdefs.h. */
17701
17702/* Override any GCC internal prototype to avoid an error.
17703 Use char because int might match the return type of a GCC
17704 builtin and then its argument prototype would still apply. */
17705#ifdef __cplusplus
17706extern "C"
17707#endif
17708char com_err ();
17709int
17710main ()
17711{
17712return com_err ();
17713 ;
17714 return 0;
17715}
17716_ACEOF
17717if ac_fn_c_try_link "$LINENO"; then :
17718 ac_cv_lib_com_err_com_err=yes
17719else
17720 ac_cv_lib_com_err_com_err=no
17721fi
17722rm -f core conftest.err conftest.$ac_objext \
17723 conftest$ac_exeext conftest.$ac_ext
17724LIBS=$ac_check_lib_save_LIBS
17725fi
17726{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
17727$as_echo "$ac_cv_lib_com_err_com_err" >&6; }
d6974efa 17728if test "x$ac_cv_lib_com_err_com_err" = xyes; then :
067d23c9
KY
17729 have_com_err=yes
17730else
17731 have_com_err=no
17732fi
17733
17734 if test $have_com_err = yes; then
17735 COM_ERRLIB=-lcom_err
17736 LIBS="$COM_ERRLIB $LIBS"
17737
17738$as_echo "#define HAVE_LIBCOM_ERR 1" >>confdefs.h
17739
17740 fi
17741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
17742$as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
d6974efa 17743if ${ac_cv_lib_crypto_mit_des_cbc_encrypt+:} false; then :
067d23c9
KY
17744 $as_echo_n "(cached) " >&6
17745else
17746 ac_check_lib_save_LIBS=$LIBS
17747LIBS="-lcrypto $LIBS"
17748cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17749/* end confdefs.h. */
17750
17751/* Override any GCC internal prototype to avoid an error.
17752 Use char because int might match the return type of a GCC
17753 builtin and then its argument prototype would still apply. */
17754#ifdef __cplusplus
17755extern "C"
17756#endif
17757char mit_des_cbc_encrypt ();
17758int
17759main ()
17760{
17761return mit_des_cbc_encrypt ();
17762 ;
17763 return 0;
17764}
17765_ACEOF
17766if ac_fn_c_try_link "$LINENO"; then :
17767 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
17768else
17769 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
17770fi
17771rm -f core conftest.err conftest.$ac_objext \
17772 conftest$ac_exeext conftest.$ac_ext
17773LIBS=$ac_check_lib_save_LIBS
17774fi
17775{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
17776$as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
d6974efa 17777if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = xyes; then :
067d23c9
KY
17778 have_crypto=yes
17779else
17780 have_crypto=no
17781fi
17782
17783 if test $have_crypto = yes; then
17784 CRYPTOLIB=-lcrypto
17785 LIBS="$CRYPTOLIB $LIBS"
17786
17787$as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h
17788
17789 fi
17790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
17791$as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
d6974efa 17792if ${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+:} false; then :
067d23c9
KY
17793 $as_echo_n "(cached) " >&6
17794else
17795 ac_check_lib_save_LIBS=$LIBS
17796LIBS="-lk5crypto $LIBS"
17797cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17798/* end confdefs.h. */
17799
17800/* Override any GCC internal prototype to avoid an error.
17801 Use char because int might match the return type of a GCC
17802 builtin and then its argument prototype would still apply. */
17803#ifdef __cplusplus
17804extern "C"
17805#endif
17806char mit_des_cbc_encrypt ();
17807int
17808main ()
17809{
17810return mit_des_cbc_encrypt ();
17811 ;
17812 return 0;
17813}
17814_ACEOF
17815if ac_fn_c_try_link "$LINENO"; then :
17816 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
17817else
17818 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
17819fi
17820rm -f core conftest.err conftest.$ac_objext \
17821 conftest$ac_exeext conftest.$ac_ext
17822LIBS=$ac_check_lib_save_LIBS
17823fi
17824{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
17825$as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
d6974efa 17826if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = xyes; then :
067d23c9
KY
17827 have_k5crypto=yes
17828else
17829 have_k5crypto=no
17830fi
17831
17832 if test $have_k5crypto = yes; then
17833 CRYPTOLIB=-lk5crypto
17834 LIBS="$CRYPTOLIB $LIBS"
17835
17836$as_echo "#define HAVE_LIBK5CRYPTO 1" >>confdefs.h
17837
17838 fi
17839 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
17840$as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
d6974efa 17841if ${ac_cv_lib_krb5_krb5_init_context+:} false; then :
067d23c9
KY
17842 $as_echo_n "(cached) " >&6
17843else
17844 ac_check_lib_save_LIBS=$LIBS
17845LIBS="-lkrb5 $LIBS"
17846cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17847/* end confdefs.h. */
17848
17849/* Override any GCC internal prototype to avoid an error.
17850 Use char because int might match the return type of a GCC
17851 builtin and then its argument prototype would still apply. */
17852#ifdef __cplusplus
17853extern "C"
17854#endif
17855char krb5_init_context ();
17856int
17857main ()
17858{
17859return krb5_init_context ();
17860 ;
17861 return 0;
17862}
17863_ACEOF
17864if ac_fn_c_try_link "$LINENO"; then :
17865 ac_cv_lib_krb5_krb5_init_context=yes
17866else
17867 ac_cv_lib_krb5_krb5_init_context=no
17868fi
17869rm -f core conftest.err conftest.$ac_objext \
17870 conftest$ac_exeext conftest.$ac_ext
17871LIBS=$ac_check_lib_save_LIBS
17872fi
17873{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
17874$as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
d6974efa 17875if test "x$ac_cv_lib_krb5_krb5_init_context" = xyes; then :
067d23c9
KY
17876 have_krb5=yes
17877else
17878 have_krb5=no
17879fi
17880
17881 if test $have_krb5=yes; then
17882 KRB5LIB=-lkrb5
17883 LIBS="$KRB5LIB $LIBS"
17884
17885$as_echo "#define HAVE_LIBKRB5 1" >>confdefs.h
17886
17887 fi
17888 if test "${with_kerberos5}" = no; then
17889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
17890$as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
d6974efa 17891if ${ac_cv_lib_des425_des_cbc_encrypt+:} false; then :
067d23c9
KY
17892 $as_echo_n "(cached) " >&6
17893else
17894 ac_check_lib_save_LIBS=$LIBS
17895LIBS="-ldes425 $LIBS"
17896cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17897/* end confdefs.h. */
17898
17899/* Override any GCC internal prototype to avoid an error.
17900 Use char because int might match the return type of a GCC
17901 builtin and then its argument prototype would still apply. */
17902#ifdef __cplusplus
17903extern "C"
17904#endif
17905char des_cbc_encrypt ();
17906int
17907main ()
17908{
17909return des_cbc_encrypt ();
17910 ;
17911 return 0;
17912}
17913_ACEOF
17914if ac_fn_c_try_link "$LINENO"; then :
17915 ac_cv_lib_des425_des_cbc_encrypt=yes
17916else
17917 ac_cv_lib_des425_des_cbc_encrypt=no
17918fi
17919rm -f core conftest.err conftest.$ac_objext \
17920 conftest$ac_exeext conftest.$ac_ext
17921LIBS=$ac_check_lib_save_LIBS
17922fi
17923{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
17924$as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
d6974efa 17925if test "x$ac_cv_lib_des425_des_cbc_encrypt" = xyes; then :
067d23c9
KY
17926 have_des425=yes
17927else
17928 have_des425=no
17929fi
17930
17931 if test $have_des425 = yes; then
17932 DESLIB=-ldes425
17933 LIBS="$DESLIB $LIBS"
17934
17935$as_echo "#define HAVE_LIBDES425 1" >>confdefs.h
17936
17937 else
17938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
17939$as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
d6974efa 17940if ${ac_cv_lib_des_des_cbc_encrypt+:} false; then :
067d23c9
KY
17941 $as_echo_n "(cached) " >&6
17942else
17943 ac_check_lib_save_LIBS=$LIBS
17944LIBS="-ldes $LIBS"
17945cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17946/* end confdefs.h. */
17947
17948/* Override any GCC internal prototype to avoid an error.
17949 Use char because int might match the return type of a GCC
17950 builtin and then its argument prototype would still apply. */
17951#ifdef __cplusplus
17952extern "C"
17953#endif
17954char des_cbc_encrypt ();
17955int
17956main ()
17957{
17958return des_cbc_encrypt ();
17959 ;
17960 return 0;
17961}
17962_ACEOF
17963if ac_fn_c_try_link "$LINENO"; then :
17964 ac_cv_lib_des_des_cbc_encrypt=yes
17965else
17966 ac_cv_lib_des_des_cbc_encrypt=no
17967fi
17968rm -f core conftest.err conftest.$ac_objext \
17969 conftest$ac_exeext conftest.$ac_ext
17970LIBS=$ac_check_lib_save_LIBS
17971fi
17972{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
17973$as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
d6974efa 17974if test "x$ac_cv_lib_des_des_cbc_encrypt" = xyes; then :
067d23c9
KY
17975 have_des=yes
17976else
17977 have_des=no
17978fi
17979
17980 if test $have_des = yes; then
17981 DESLIB=-ldes
17982 LIBS="$DESLIB $LIBS"
17983
17984$as_echo "#define HAVE_LIBDES 1" >>confdefs.h
17985
17986 fi
17987 fi
17988 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
17989$as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
d6974efa 17990if ${ac_cv_lib_krb4_krb_get_cred+:} false; then :
067d23c9
KY
17991 $as_echo_n "(cached) " >&6
17992else
17993 ac_check_lib_save_LIBS=$LIBS
17994LIBS="-lkrb4 $LIBS"
17995cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17996/* end confdefs.h. */
17997
17998/* Override any GCC internal prototype to avoid an error.
17999 Use char because int might match the return type of a GCC
18000 builtin and then its argument prototype would still apply. */
18001#ifdef __cplusplus
18002extern "C"
18003#endif
18004char krb_get_cred ();
18005int
18006main ()
18007{
18008return krb_get_cred ();
18009 ;
18010 return 0;
18011}
18012_ACEOF
18013if ac_fn_c_try_link "$LINENO"; then :
18014 ac_cv_lib_krb4_krb_get_cred=yes
18015else
18016 ac_cv_lib_krb4_krb_get_cred=no
18017fi
18018rm -f core conftest.err conftest.$ac_objext \
18019 conftest$ac_exeext conftest.$ac_ext
18020LIBS=$ac_check_lib_save_LIBS
18021fi
18022{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
18023$as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
d6974efa 18024if test "x$ac_cv_lib_krb4_krb_get_cred" = xyes; then :
067d23c9
KY
18025 have_krb4=yes
18026else
18027 have_krb4=no
18028fi
18029
18030 if test $have_krb4 = yes; then
18031 KRB4LIB=-lkrb4
18032 LIBS="$KRB4LIB $LIBS"
18033
18034$as_echo "#define HAVE_LIBKRB4 1" >>confdefs.h
18035
18036 else
18037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
18038$as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
d6974efa 18039if ${ac_cv_lib_krb_krb_get_cred+:} false; then :
067d23c9
KY
18040 $as_echo_n "(cached) " >&6
18041else
18042 ac_check_lib_save_LIBS=$LIBS
18043LIBS="-lkrb $LIBS"
18044cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18045/* end confdefs.h. */
18046
18047/* Override any GCC internal prototype to avoid an error.
18048 Use char because int might match the return type of a GCC
18049 builtin and then its argument prototype would still apply. */
18050#ifdef __cplusplus
18051extern "C"
18052#endif
18053char krb_get_cred ();
18054int
18055main ()
18056{
18057return krb_get_cred ();
18058 ;
18059 return 0;
18060}
18061_ACEOF
18062if ac_fn_c_try_link "$LINENO"; then :
18063 ac_cv_lib_krb_krb_get_cred=yes
18064else
18065 ac_cv_lib_krb_krb_get_cred=no
18066fi
18067rm -f core conftest.err conftest.$ac_objext \
18068 conftest$ac_exeext conftest.$ac_ext
18069LIBS=$ac_check_lib_save_LIBS
18070fi
18071{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
18072$as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
d6974efa 18073if test "x$ac_cv_lib_krb_krb_get_cred" = xyes; then :
067d23c9
KY
18074 have_krb=yes
18075else
18076 have_krb=no
18077fi
18078
18079 if test $have_krb = yes; then
18080 KRB4LIB=-lkrb
18081 LIBS="$KRB4LIB $LIBS"
18082
18083$as_echo "#define HAVE_LIBKRB 1" >>confdefs.h
18084
18085 fi
18086 fi
18087 fi
18088
18089 if test "${with_kerberos5}" != no; then
18090 for ac_header in krb5.h
18091do :
18092 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
d6974efa 18093if test "x$ac_cv_header_krb5_h" = xyes; then :
067d23c9
KY
18094 cat >>confdefs.h <<_ACEOF
18095#define HAVE_KRB5_H 1
18096_ACEOF
18097 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
18098"
d6974efa 18099if test "x$ac_cv_member_krb5_error_text" = xyes; then :
067d23c9
KY
18100
18101cat >>confdefs.h <<_ACEOF
18102#define HAVE_KRB5_ERROR_TEXT 1
18103_ACEOF
18104
18105
18106fi
18107ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
18108"
d6974efa 18109if test "x$ac_cv_member_krb5_error_e_text" = xyes; then :
067d23c9
KY
18110
18111cat >>confdefs.h <<_ACEOF
18112#define HAVE_KRB5_ERROR_E_TEXT 1
18113_ACEOF
18114
18115
18116fi
18117
18118fi
18119
18120done
18121
18122 else
18123 for ac_header in des.h
18124do :
18125 ac_fn_c_check_header_mongrel "$LINENO" "des.h" "ac_cv_header_des_h" "$ac_includes_default"
d6974efa 18126if test "x$ac_cv_header_des_h" = xyes; then :
067d23c9
KY
18127 cat >>confdefs.h <<_ACEOF
18128#define HAVE_DES_H 1
18129_ACEOF
18130
18131else
18132 for ac_header in kerberosIV/des.h
18133do :
18134 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/des.h" "ac_cv_header_kerberosIV_des_h" "$ac_includes_default"
d6974efa 18135if test "x$ac_cv_header_kerberosIV_des_h" = xyes; then :
067d23c9
KY
18136 cat >>confdefs.h <<_ACEOF
18137#define HAVE_KERBEROSIV_DES_H 1
18138_ACEOF
18139
18140else
18141 for ac_header in kerberos/des.h
18142do :
18143 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/des.h" "ac_cv_header_kerberos_des_h" "$ac_includes_default"
d6974efa 18144if test "x$ac_cv_header_kerberos_des_h" = xyes; then :
067d23c9
KY
18145 cat >>confdefs.h <<_ACEOF
18146#define HAVE_KERBEROS_DES_H 1
18147_ACEOF
18148
18149fi
18150
18151done
18152
18153fi
18154
18155done
18156
18157fi
18158
18159done
18160
18161 for ac_header in krb.h
18162do :
18163 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
d6974efa 18164if test "x$ac_cv_header_krb_h" = xyes; then :
067d23c9
KY
18165 cat >>confdefs.h <<_ACEOF
18166#define HAVE_KRB_H 1
18167_ACEOF
18168
18169else
18170 for ac_header in kerberosIV/krb.h
18171do :
18172 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
d6974efa 18173if test "x$ac_cv_header_kerberosIV_krb_h" = xyes; then :
067d23c9
KY
18174 cat >>confdefs.h <<_ACEOF
18175#define HAVE_KERBEROSIV_KRB_H 1
18176_ACEOF
18177
18178else
18179 for ac_header in kerberos/krb.h
18180do :
18181 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
d6974efa 18182if test "x$ac_cv_header_kerberos_krb_h" = xyes; then :
067d23c9
KY
18183 cat >>confdefs.h <<_ACEOF
18184#define HAVE_KERBEROS_KRB_H 1
18185_ACEOF
18186
18187fi
18188
18189done
18190
18191fi
18192
18193done
18194
18195fi
18196
18197done
18198
18199 fi
18200 for ac_header in com_err.h
18201do :
18202 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
d6974efa 18203if test "x$ac_cv_header_com_err_h" = xyes; then :
067d23c9
KY
18204 cat >>confdefs.h <<_ACEOF
18205#define HAVE_COM_ERR_H 1
18206_ACEOF
18207
18208fi
18209
18210done
18211
18212fi
18213
18214
18215
18216
18217
18218
18219
18220# Solaris requires -lintl if you want strerror (which calls dgettext)
18221# to return localized messages.
18222{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for dgettext in -lintl" >&5
18223$as_echo_n "checking for dgettext in -lintl... " >&6; }
d6974efa 18224if ${ac_cv_lib_intl_dgettext+:} false; then :
067d23c9
KY
18225 $as_echo_n "(cached) " >&6
18226else
18227 ac_check_lib_save_LIBS=$LIBS
18228LIBS="-lintl $LIBS"
18229cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18230/* end confdefs.h. */
18231
18232/* Override any GCC internal prototype to avoid an error.
18233 Use char because int might match the return type of a GCC
18234 builtin and then its argument prototype would still apply. */
18235#ifdef __cplusplus
18236extern "C"
18237#endif
18238char dgettext ();
18239int
18240main ()
18241{
18242return dgettext ();
18243 ;
18244 return 0;
18245}
18246_ACEOF
18247if ac_fn_c_try_link "$LINENO"; then :
18248 ac_cv_lib_intl_dgettext=yes
18249else
18250 ac_cv_lib_intl_dgettext=no
18251fi
18252rm -f core conftest.err conftest.$ac_objext \
18253 conftest$ac_exeext conftest.$ac_ext
18254LIBS=$ac_check_lib_save_LIBS
18255fi
18256{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_dgettext" >&5
18257$as_echo "$ac_cv_lib_intl_dgettext" >&6; }
d6974efa 18258if test "x$ac_cv_lib_intl_dgettext" = xyes; then :
067d23c9
KY
18259 cat >>confdefs.h <<_ACEOF
18260#define HAVE_LIBINTL 1
18261_ACEOF
18262
18263 LIBS="-lintl $LIBS"
18264
18265fi
18266
18267
18268{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
18269$as_echo_n "checking whether localtime caches TZ... " >&6; }
d6974efa 18270if ${emacs_cv_localtime_cache+:} false; then :
067d23c9
KY
18271 $as_echo_n "(cached) " >&6
18272else
18273 if test x$ac_cv_func_tzset = xyes; then
18274if test "$cross_compiling" = yes; then :
18275 # If we have tzset, assume the worst when cross-compiling.
18276emacs_cv_localtime_cache=yes
18277else
18278 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18279/* end confdefs.h. */
18280#include <time.h>
18281char TZ_GMT0[] = "TZ=GMT0";
18282char TZ_PST8[] = "TZ=PST8";
18283main()
18284{
18285 time_t now = time ((time_t *) 0);
18286 int hour_GMT0, hour_unset;
18287 if (putenv (TZ_GMT0) != 0)
18288 exit (1);
18289 hour_GMT0 = localtime (&now)->tm_hour;
18290 unsetenv("TZ");
18291 hour_unset = localtime (&now)->tm_hour;
18292 if (putenv (TZ_PST8) != 0)
18293 exit (1);
18294 if (localtime (&now)->tm_hour == hour_GMT0)
18295 exit (1);
18296 unsetenv("TZ");
18297 if (localtime (&now)->tm_hour != hour_unset)
18298 exit (1);
18299 exit (0);
18300}
18301_ACEOF
18302if ac_fn_c_try_run "$LINENO"; then :
18303 emacs_cv_localtime_cache=no
18304else
18305 emacs_cv_localtime_cache=yes
18306fi
18307rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18308 conftest.$ac_objext conftest.beam conftest.$ac_ext
18309fi
18310
18311else
18312 # If we lack tzset, report that localtime does not cache TZ,
18313 # since we can't invalidate the cache if we don't have tzset.
18314 emacs_cv_localtime_cache=no
18315fi
18316fi
18317{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
18318$as_echo "$emacs_cv_localtime_cache" >&6; }
18319if test $emacs_cv_localtime_cache = yes; then
18320
18321$as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
18322
18323fi
18324
18325if test "x$HAVE_TIMEVAL" = xyes; then
18326 for ac_func in gettimeofday
18327do :
18328 ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday"
d6974efa 18329if test "x$ac_cv_func_gettimeofday" = xyes; then :
067d23c9
KY
18330 cat >>confdefs.h <<_ACEOF
18331#define HAVE_GETTIMEOFDAY 1
18332_ACEOF
18333
18334fi
18335done
18336
18337 if test $ac_cv_func_gettimeofday = yes; then
18338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday can accept two arguments" >&5
18339$as_echo_n "checking whether gettimeofday can accept two arguments... " >&6; }
d6974efa 18340if ${emacs_cv_gettimeofday_two_arguments+:} false; then :
067d23c9
KY
18341 $as_echo_n "(cached) " >&6
18342else
18343 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18344/* end confdefs.h. */
18345
18346#ifdef TIME_WITH_SYS_TIME
18347#include <sys/time.h>
18348#include <time.h>
18349#else
18350#ifdef HAVE_SYS_TIME_H
18351#include <sys/time.h>
18352#else
18353#include <time.h>
18354#endif
18355#endif
18356int
18357main ()
18358{
18359struct timeval time;
18360 gettimeofday (&time, 0);
18361 ;
18362 return 0;
18363}
18364_ACEOF
18365if ac_fn_c_try_compile "$LINENO"; then :
18366 emacs_cv_gettimeofday_two_arguments=yes
18367else
18368 emacs_cv_gettimeofday_two_arguments=no
18369fi
18370rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18371fi
18372{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_gettimeofday_two_arguments" >&5
18373$as_echo "$emacs_cv_gettimeofday_two_arguments" >&6; }
18374 if test $emacs_cv_gettimeofday_two_arguments = no; then
18375
18376$as_echo "#define GETTIMEOFDAY_ONE_ARGUMENT 1" >>confdefs.h
18377
18378 fi
18379 fi
18380fi
18381
18382ok_so_far=yes
18383ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
d6974efa 18384if test "x$ac_cv_func_socket" = xyes; then :
067d23c9
KY
18385
18386else
18387 ok_so_far=no
18388fi
18389
18390if test $ok_so_far = yes; then
18391 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
d6974efa 18392if test "x$ac_cv_header_netinet_in_h" = xyes; then :
067d23c9
KY
18393
18394else
18395 ok_so_far=no
18396fi
18397
18398
18399fi
18400if test $ok_so_far = yes; then
18401 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
d6974efa 18402if test "x$ac_cv_header_arpa_inet_h" = xyes; then :
067d23c9
KY
18403
18404else
18405 ok_so_far=no
18406fi
18407
18408
18409fi
18410if test $ok_so_far = yes; then
18411
18412$as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
18413
18414fi
18415
18416if test -f /usr/lpp/X11/bin/smt.exp; then
18417
18418$as_echo "#define HAVE_AIX_SMT_EXP 1" >>confdefs.h
18419
18420fi
18421
18422{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports dynamic ptys" >&5
18423$as_echo_n "checking whether system supports dynamic ptys... " >&6; }
18424if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
18425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18426$as_echo "yes" >&6; }
18427
18428$as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h
18429
18430else
18431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18432$as_echo "no" >&6; }
18433fi
18434
18435ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
d6974efa 18436if test "x$ac_cv_type_pid_t" = xyes; then :
067d23c9
KY
18437
18438else
18439
18440cat >>confdefs.h <<_ACEOF
18441#define pid_t int
18442_ACEOF
18443
18444fi
18445
18446for ac_header in vfork.h
18447do :
18448 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
d6974efa 18449if test "x$ac_cv_header_vfork_h" = xyes; then :
067d23c9
KY
18450 cat >>confdefs.h <<_ACEOF
18451#define HAVE_VFORK_H 1
18452_ACEOF
18453
18454fi
18455
18456done
18457
18458for ac_func in fork vfork
18459do :
18460 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18461ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
2018939f 18462if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
067d23c9
KY
18463 cat >>confdefs.h <<_ACEOF
18464#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18465_ACEOF
18466
18467fi
18468done
18469
18470if test "x$ac_cv_func_fork" = xyes; then
18471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
18472$as_echo_n "checking for working fork... " >&6; }
d6974efa 18473if ${ac_cv_func_fork_works+:} false; then :
067d23c9
KY
18474 $as_echo_n "(cached) " >&6
18475else
18476 if test "$cross_compiling" = yes; then :
18477 ac_cv_func_fork_works=cross
18478else
18479 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18480/* end confdefs.h. */
18481$ac_includes_default
18482int
18483main ()
18484{
18485
18486 /* By Ruediger Kuhlmann. */
18487 return fork () < 0;
18488
18489 ;
18490 return 0;
18491}
18492_ACEOF
18493if ac_fn_c_try_run "$LINENO"; then :
18494 ac_cv_func_fork_works=yes
18495else
18496 ac_cv_func_fork_works=no
18497fi
18498rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18499 conftest.$ac_objext conftest.beam conftest.$ac_ext
18500fi
18501
18502fi
18503{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
18504$as_echo "$ac_cv_func_fork_works" >&6; }
18505
18506else
18507 ac_cv_func_fork_works=$ac_cv_func_fork
18508fi
18509if test "x$ac_cv_func_fork_works" = xcross; then
18510 case $host in
18511 *-*-amigaos* | *-*-msdosdjgpp*)
18512 # Override, as these systems have only a dummy fork() stub
18513 ac_cv_func_fork_works=no
18514 ;;
18515 *)
18516 ac_cv_func_fork_works=yes
18517 ;;
18518 esac
18519 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
18520$as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
18521fi
18522ac_cv_func_vfork_works=$ac_cv_func_vfork
18523if test "x$ac_cv_func_vfork" = xyes; then
18524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
18525$as_echo_n "checking for working vfork... " >&6; }
d6974efa 18526if ${ac_cv_func_vfork_works+:} false; then :
067d23c9
KY
18527 $as_echo_n "(cached) " >&6
18528else
18529 if test "$cross_compiling" = yes; then :
18530 ac_cv_func_vfork_works=cross
18531else
18532 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18533/* end confdefs.h. */
18534/* Thanks to Paul Eggert for this test. */
18535$ac_includes_default
18536#include <sys/wait.h>
18537#ifdef HAVE_VFORK_H
18538# include <vfork.h>
18539#endif
18540/* On some sparc systems, changes by the child to local and incoming
18541 argument registers are propagated back to the parent. The compiler
18542 is told about this with #include <vfork.h>, but some compilers
18543 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
18544 static variable whose address is put into a register that is
18545 clobbered by the vfork. */
18546static void
18547#ifdef __cplusplus
18548sparc_address_test (int arg)
18549# else
18550sparc_address_test (arg) int arg;
18551#endif
18552{
18553 static pid_t child;
18554 if (!child) {
18555 child = vfork ();
18556 if (child < 0) {
18557 perror ("vfork");
18558 _exit(2);
18559 }
18560 if (!child) {
18561 arg = getpid();
18562 write(-1, "", 0);
18563 _exit (arg);
18564 }
18565 }
18566}
18567
18568int
18569main ()
18570{
18571 pid_t parent = getpid ();
18572 pid_t child;
18573
18574 sparc_address_test (0);
18575
18576 child = vfork ();
18577
18578 if (child == 0) {
18579 /* Here is another test for sparc vfork register problems. This
18580 test uses lots of local variables, at least as many local
18581 variables as main has allocated so far including compiler
18582 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
18583 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
18584 reuse the register of parent for one of the local variables,
18585 since it will think that parent can't possibly be used any more
18586 in this routine. Assigning to the local variable will thus
18587 munge parent in the parent process. */
18588 pid_t
18589 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
18590 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
18591 /* Convince the compiler that p..p7 are live; otherwise, it might
18592 use the same hardware register for all 8 local variables. */
18593 if (p != p1 || p != p2 || p != p3 || p != p4
18594 || p != p5 || p != p6 || p != p7)
18595 _exit(1);
18596
18597 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
18598 from child file descriptors. If the child closes a descriptor
18599 before it execs or exits, this munges the parent's descriptor
18600 as well. Test for this by closing stdout in the child. */
18601 _exit(close(fileno(stdout)) != 0);
18602 } else {
18603 int status;
18604 struct stat st;
18605
18606 while (wait(&status) != child)
18607 ;
18608 return (
18609 /* Was there some problem with vforking? */
18610 child < 0
18611
18612 /* Did the child fail? (This shouldn't happen.) */
18613 || status
18614
18615 /* Did the vfork/compiler bug occur? */
18616 || parent != getpid()
18617
18618 /* Did the file descriptor bug occur? */
18619 || fstat(fileno(stdout), &st) != 0
18620 );
18621 }
18622}
18623_ACEOF
18624if ac_fn_c_try_run "$LINENO"; then :
18625 ac_cv_func_vfork_works=yes
18626else
18627 ac_cv_func_vfork_works=no
18628fi
18629rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18630 conftest.$ac_objext conftest.beam conftest.$ac_ext
18631fi
18632
18633fi
18634{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
18635$as_echo "$ac_cv_func_vfork_works" >&6; }
18636
18637fi;
18638if test "x$ac_cv_func_fork_works" = xcross; then
18639 ac_cv_func_vfork_works=$ac_cv_func_vfork
18640 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
18641$as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
18642fi
18643
18644if test "x$ac_cv_func_vfork_works" = xyes; then
18645
18646$as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
18647
18648else
18649
18650$as_echo "#define vfork fork" >>confdefs.h
18651
18652fi
18653if test "x$ac_cv_func_fork_works" = xyes; then
18654
18655$as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
18656
18657fi
18658
18659
18660{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
18661$as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
d6974efa 18662if ${emacs_cv_langinfo_codeset+:} false; then :
067d23c9
KY
18663 $as_echo_n "(cached) " >&6
18664else
18665 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18666/* end confdefs.h. */
18667#include <langinfo.h>
18668int
18669main ()
18670{
18671char* cs = nl_langinfo(CODESET);
18672 ;
18673 return 0;
18674}
18675_ACEOF
18676if ac_fn_c_try_link "$LINENO"; then :
18677 emacs_cv_langinfo_codeset=yes
18678else
18679 emacs_cv_langinfo_codeset=no
18680fi
18681rm -f core conftest.err conftest.$ac_objext \
18682 conftest$ac_exeext conftest.$ac_ext
18683
18684fi
18685{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
18686$as_echo "$emacs_cv_langinfo_codeset" >&6; }
18687if test $emacs_cv_langinfo_codeset = yes; then
18688
18689$as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
18690
18691fi
18692
18693ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
d6974efa 18694if test "x$ac_cv_type_size_t" = xyes; then :
067d23c9
KY
18695
18696cat >>confdefs.h <<_ACEOF
18697#define HAVE_SIZE_T 1
18698_ACEOF
18699
18700
18701fi
18702
18703
18704{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
18705$as_echo_n "checking for mbstate_t... " >&6; }
d6974efa 18706if ${ac_cv_type_mbstate_t+:} false; then :
067d23c9
KY
18707 $as_echo_n "(cached) " >&6
18708else
18709 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18710/* end confdefs.h. */
18711$ac_includes_default
18712# include <wchar.h>
18713int
18714main ()
18715{
18716mbstate_t x; return sizeof x;
18717 ;
18718 return 0;
18719}
18720_ACEOF
18721if ac_fn_c_try_compile "$LINENO"; then :
18722 ac_cv_type_mbstate_t=yes
18723else
18724 ac_cv_type_mbstate_t=no
18725fi
18726rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18727fi
18728{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
18729$as_echo "$ac_cv_type_mbstate_t" >&6; }
18730 if test $ac_cv_type_mbstate_t = yes; then
18731
18732$as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
18733
18734 else
18735
18736$as_echo "#define mbstate_t int" >>confdefs.h
18737
18738 fi
18739
067d23c9
KY
18740{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
18741$as_echo_n "checking for C restricted array declarations... " >&6; }
d6974efa 18742if ${emacs_cv_c_restrict_arr+:} false; then :
067d23c9
KY
18743 $as_echo_n "(cached) " >&6
18744else
18745 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18746/* end confdefs.h. */
18747void fred (int x[__restrict]);
18748int
18749main ()
18750{
18751
18752 ;
18753 return 0;
18754}
18755_ACEOF
18756if ac_fn_c_try_compile "$LINENO"; then :
18757 emacs_cv_c_restrict_arr=yes
18758else
18759 emacs_cv_c_restrict_arr=no
18760fi
18761rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18762fi
18763{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
18764$as_echo "$emacs_cv_c_restrict_arr" >&6; }
18765if test "$emacs_cv_c_restrict_arr" = yes; then
18766
18767$as_echo "#define __restrict_arr __restrict" >>confdefs.h
18768
18769fi
18770
18771
18772
18773# Set up the CFLAGS for real compilation, so we can substitute it.
18774CFLAGS="$REAL_CFLAGS"
18775CPPFLAGS="$REAL_CPPFLAGS"
18776
18777## Hack to detect a buggy GCC version.
18778if test "x$GCC" = xyes \
18779 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
18780 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
18781 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
2018939f 18782 as_fn_error $? "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
067d23c9
KY
18783fi
18784
16fab143 18785version=$PACKAGE_VERSION
067d23c9
KY
18786
18787### Specify what sort of things we'll be editing into Makefile and config.h.
18788### Use configuration here uncanonicalized to avoid exceeding size limits.
18789
18790
18791## Unused?
18792
18793
18794
18795
18796
18797
18798
18799
18800
18801
18802
18803
18804
18805
18806
18807
18808
18809
18810
18811
18812## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
18813## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
18814## end of LIBX_BASE, but nothing ever set it.
18815
18816
18817
18818
18819## Used in lwlib/Makefile.in.
18820
d6a003a8
AS
18821if test -n "${machfile}"; then
18822 M_FILE="\$(srcdir)/${machfile}"
18823else
18824 M_FILE=
18825fi
18826S_FILE="\$(srcdir)/${opsysfile}"
067d23c9
KY
18827
18828
18829
18830
18831
18832
18833
18834
18835
18836
067d23c9
KY
18837cat >>confdefs.h <<_ACEOF
18838#define EMACS_CONFIGURATION "${canonical}"
18839_ACEOF
18840
18841
18842cat >>confdefs.h <<_ACEOF
18843#define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
18844_ACEOF
18845
d6a003a8 18846if test -n "$machfile"; then
067d23c9
KY
18847
18848cat >>confdefs.h <<_ACEOF
18849#define config_machfile "${machfile}"
18850_ACEOF
18851
d6a003a8 18852fi
067d23c9
KY
18853
18854cat >>confdefs.h <<_ACEOF
18855#define config_opsysfile "${opsysfile}"
18856_ACEOF
18857
18858
18859XMENU_OBJ=
18860XOBJ=
18861FONT_OBJ=
18862if test "${HAVE_X_WINDOWS}" = "yes" ; then
18863
18864$as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
18865
18866 XMENU_OBJ=xmenu.o
18867 XOBJ="xterm.o xfns.o xselect.o xrdb.o fontset.o xsmfns.o fringe.o image.o xsettings.o xgselect.o"
18868 FONT_OBJ=xfont.o
18869 if test "$HAVE_XFT" = "yes"; then
18870 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
18871 elif test "$HAVE_FREETYPE" = "yes"; then
18872 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
18873 fi
18874
18875fi
18876
18877
18878
18879
18880WIDGET_OBJ=
18881MOTIF_LIBW=
18882if test "${USE_X_TOOLKIT}" != "none" ; then
18883 WIDGET_OBJ=widget.o
18884
18885$as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
18886
18887 if test "${USE_X_TOOLKIT}" = "LUCID"; then
18888
18889$as_echo "#define USE_LUCID 1" >>confdefs.h
18890
18891 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
18892
18893$as_echo "#define USE_MOTIF 1" >>confdefs.h
18894
18895 MOTIF_LIBW=-lXm
18896 case "$opsys" in
18897 gnu-linux)
18898 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
18899 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
18900 ;;
18901
18902 unixware)
18903 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
18904 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
18905 MOTIF_LIBW="MOTIF_LIBW -lXimp"
18906 ;;
18907
18908 aix4-2)
18909 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
18910 MOTIF_LIBW="$MOTIF_LIBW -li18n"
18911 ;;
18912 esac
18913 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
18914 fi
18915fi
18916
18917
18918TOOLKIT_LIBW=
18919case "$USE_X_TOOLKIT" in
18920 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
18921 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
18922 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
18923esac
18924
18925
18926if test "$USE_X_TOOLKIT" = "none"; then
18927 LIBXT_OTHER="\$(LIBXSM)"
18928 OLDXMENU_TARGET="really-oldXMenu"
18929else
18930 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
18931 OLDXMENU_TARGET="really-lwlib"
18932fi
18933
18934
18935## The X Menu stuff is present in the X10 distribution, but missing
18936## from X11. If we have X10, just use the installed library;
18937## otherwise, use our own copy.
18938if test "${HAVE_X11}" = "yes" ; then
18939
18940$as_echo "#define HAVE_X11 1" >>confdefs.h
18941
18942
18943 if test "$USE_X_TOOLKIT" = "none"; then
18944 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
18945 else
18946 OLDXMENU="\${lwlibdir}/liblw.a"
18947 fi
18948 LIBXMENU="\$(OLDXMENU)"
18949 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
18950 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
18951else
18952 ## For a syntactically valid Makefile; not actually used for anything.
18953 ## See comments in src/Makefile.in.
18954 OLDXMENU=nothing
18955 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
18956 if test "${HAVE_X_WINDOWS}" = "yes"; then
18957 LIBXMENU="-lXMenu"
18958 else
18959 LIBXMENU=
18960 fi
18961 LIBX_OTHER=
18962 OLDXMENU_DEPS=
18963fi
18964
18965if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
18966 OLDXMENU_TARGET=
18967 OLDXMENU=nothing
18968 LIBXMENU=
18969 OLDXMENU_DEPS=
18970fi
18971
18972
18973
18974
18975
18976
18977
18978if test "${HAVE_MENUS}" = "yes" ; then
18979
18980$as_echo "#define HAVE_MENUS 1" >>confdefs.h
18981
18982fi
18983
18984if test "${GNU_MALLOC}" = "yes" ; then
18985
18986$as_echo "#define GNU_MALLOC 1" >>confdefs.h
18987
18988fi
18989
18990RALLOC_OBJ=
18991if test "${REL_ALLOC}" = "yes" ; then
18992
18993$as_echo "#define REL_ALLOC 1" >>confdefs.h
18994
18995
18996 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
18997fi
18998
18999
19000if test "$opsys" = "cygwin"; then
19001 CYGWIN_OBJ="sheap.o"
19002 ## Cygwin differs because of its unexec().
19003 PRE_ALLOC_OBJ=
19004 POST_ALLOC_OBJ=lastfile.o
19005else
19006 CYGWIN_OBJ=
19007 PRE_ALLOC_OBJ=lastfile.o
19008 POST_ALLOC_OBJ=
19009fi
19010
19011
19012
19013
19014
19015case "$opsys" in
19016 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
19017
19018 darwin)
19019 ## The -headerpad option tells ld (see man page) to leave room at the
19020 ## end of the header for adding load commands. Needed for dumping.
19021 ## 0x690 is the total size of 30 segment load commands (at 56
19022 ## each); under Cocoa 31 commands are required.
19023 if test "$HAVE_NS" = "yes"; then
19024 libs_nsgui="-framework AppKit"
19025 headerpad_extra=6C8
19026 else
19027 libs_nsgui=
19028 headerpad_extra=690
19029 fi
19030 LD_SWITCH_SYSTEM_TEMACS="-prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
19031
19032 ## This is here because src/Makefile.in did some extra fiddling around
19033 ## with LD_SWITCH_SYSTEM. The cpp logic was:
19034 ## #ifndef LD_SWITCH_SYSTEM
19035 ## #if !defined (__GNUC__) && ((defined (BSD_SYSTEM) && !defined (COFF)))
19036 ## Since all the *bsds define LD_SWITCH_SYSTEM, this simplifies to:
19037 ## not using gcc, darwin system not on an alpha (ie darwin, since
19038 ## darwin + alpha does not occur).
19039 ## Because this was done in src/Makefile.in, the resulting part of
19040 ## LD_SWITCH_SYSTEM was not used in configure (ie, in ac_link).
19041 ## It therefore seems cleaner to put this in LD_SWITCH_SYSTEM_TEMACS,
19042 ## rather than LD_SWITCH_SYSTEM.
19043 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
19044 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
19045 ;;
19046
19047 ## LD_SWITCH_X_SITE_AUX is a -R option saying where to find X at run-time.
19048 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at
19049 ## the point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_AUX
19050 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
19051 ## had different values in configure (in ac_link) and src/Makefile.in.
19052 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
19053 gnu-linux) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_AUX)" ;;
19054
19055 *) LD_SWITCH_SYSTEM_TEMACS= ;;
19056esac
19057
19058if test "$NS_IMPL_GNUSTEP" = "yes"; then
19059 LD_SWITCH_SYSTEM_TEMACS="${LD_SWITCH_SYSTEM_TEMACS} -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES} -lgnustep-gui -lgnustep-base -lobjc -lpthread"
19060fi
19061
19062
19063
19064
19065LD_FIRSTFLAG=
19066ORDINARY_LINK=
19067case "$opsys" in
19068 ## gnu: GNU needs its own crt0.
19069 aix4-2|cygwin|darwin|gnu|hpux*|irix6-5|sol2*|unixware) ORDINARY_LINK=yes ;;
19070
19071 ## On post 1.3 releases of NetBSD, gcc -nostdlib also clears the
19072 ## library search parth, i.e. it won't search /usr/lib for libc and
19073 ## friends. Using -nostartfiles instead avoids this problem, and
19074 ## will also work on earlier NetBSD releases.
19075 netbsd|openbsd) LD_FIRSTFLAG="-nostartfiles" ;;
19076
19077 ## macpcc: NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp> says
19078 ## MkLinux/LinuxPPC needs this.
19079 ## ibms390x only supports opsys = gnu-linux so it can be added here.
19080 gnu-*)
19081 case "$machine" in
19082 macppc|ibms390x) LD_FIRSTFLAG="-nostdlib" ;;
19083 esac
19084 ;;
19085esac
19086
19087
19088if test "x$ORDINARY_LINK" = "xyes"; then
19089
19090 LD_FIRSTFLAG=""
19091
19092$as_echo "#define ORDINARY_LINK 1" >>confdefs.h
19093
19094
19095## The system files defining neither ORDINARY_LINK nor LD_FIRSTFLAG are:
19096## freebsd, gnu-* not on macppc|ibms390x.
19097elif test "x$GCC" = "xyes" && test "x$LD_FIRSTFLAG" = "x"; then
19098
19099 ## Versions of GCC >= 2.0 put their library, libgcc.a, in obscure
19100 ## places that are difficult to figure out at make time. Fortunately,
19101 ## these same versions allow you to pass arbitrary flags on to the
19102 ## linker, so there is no reason not to use it as a linker.
19103 ##
19104 ## Well, it is not quite perfect. The "-nostdlib" keeps GCC from
19105 ## searching for libraries in its internal directories, so we have to
19106 ## ask GCC explicitly where to find libgcc.a (LIB_GCC below).
19107 LD_FIRSTFLAG="-nostdlib"
19108fi
19109
19110## FIXME? What setting of EDIT_LDFLAGS should this have?
19111test "$NS_IMPL_GNUSTEP" = "yes" && LD_FIRSTFLAG="-rdynamic"
19112
19113
19114
19115
19116## FIXME? The logic here is not precisely the same as that above.
19117## There is no check here for a pre-defined LD_FIRSTFLAG.
19118## Should we only be setting LIB_GCC if LD ~ -nostdlib?
19119LIB_GCC=
19120if test "x$GCC" = "xyes" && test "x$ORDINARY_LINK" != "xyes"; then
19121
19122 case "$opsys" in
19123 freebsd|netbsd|openbsd) LIB_GCC= ;;
19124
19125 gnu-*)
19126 ## armin76@gentoo.org reported that the lgcc_s flag is necessary to
19127 ## build on ARM EABI under GNU/Linux. (Bug#5518)
d6a003a8
AS
19128 case $host_cpu in
19129 arm*)
067d23c9 19130 LIB_GCC="-lgcc_s"
d6a003a8
AS
19131 ;;
19132 *)
067d23c9
KY
19133 ## FIXME? s/gnu-linux.h used to define LIB_GCC as below, then
19134 ## immediately undefine it again and redefine it to empty.
19135 ## Was the C_SWITCH_X_SITE part really necessary?
19136## LIB_GCC=`$CC $C_SWITCH_X_SITE -print-libgcc-file-name`
19137 LIB_GCC=
d6a003a8
AS
19138 ;;
19139 esac
067d23c9
KY
19140 ;;
19141
19142 ## Ask GCC where to find libgcc.a.
19143 *) LIB_GCC=`$CC -print-libgcc-file-name 2> /dev/null` ;;
19144 esac
19145fi
19146
19147
19148TOOLTIP_SUPPORT=
19149WINDOW_SUPPORT=
19150## If we're using X11/GNUstep, define some consequences.
19151if test "$HAVE_X_WINDOWS" = "yes" || test "$HAVE_NS" = "yes"; then
19152
19153$as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
19154
19155
19156$as_echo "#define HAVE_MOUSE 1" >>confdefs.h
19157
19158 MOUSE_SUPPORT="\$(REAL_MOUSE_SUPPORT)"
19159 TOOLTIP_SUPPORT="\${lispsource}/mouse.elc"
19160
19161 WINDOW_SUPPORT="\$(BASE_WINDOW_SUPPORT)"
19162 test "$HAVE_X_WINDOWS" = "yes" && \
19163 WINDOW_SUPPORT="$WINDOW_SUPPORT \$(X_WINDOW_SUPPORT)"
19164
19165fi
19166
19167
19168
19169
19170
19171
19172
19173#### Report on what we decided to do.
19174#### Report GTK as a toolkit, even if it doesn't use Xt.
19175#### It makes printing result more understandable as using GTK sets
19176#### toolkit_scroll_bars to yes by default.
19177if test "${HAVE_GTK}" = "yes"; then
19178 USE_X_TOOLKIT=GTK
19179fi
19180
2b7f50d8
AS
19181and_machfile=
19182if test -n "$machfile"; then
19183 and_machfile=" and \`${machfile}'"
19184fi
19185
067d23c9
KY
19186echo "
19187Configured for \`${canonical}'.
19188
19189 Where should the build process find the source code? ${srcdir}
19190 What operating system and machine description files should Emacs use?
2b7f50d8 19191 \`${opsysfile}'${and_machfile}
067d23c9
KY
19192 What compiler should emacs be built with? ${CC} ${CFLAGS}
19193 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
19194 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
19195 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
19196 What window system should Emacs use? ${window_system}
19197 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
19198
19199if test -n "${x_includes}"; then
19200echo " Where do we find X Windows header files? ${x_includes}"
19201else
19202echo " Where do we find X Windows header files? Standard dirs"
19203fi
19204if test -n "${x_libraries}"; then
19205echo " Where do we find X Windows libraries? ${x_libraries}"
19206else
19207echo " Where do we find X Windows libraries? Standard dirs"
19208fi
19209
19210echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
19211echo " Does Emacs use -lXpm? ${HAVE_XPM}"
19212echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
19213echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
19214echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
19215echo " Does Emacs use -lpng? ${HAVE_PNG}"
19216echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
19217echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
19218
19219echo " Does Emacs use -lgpm? ${HAVE_GPM}"
19220echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
19221echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
19222echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
19223echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
19224echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
19225
19226echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
19227echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
19228echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
19229echo " Does Emacs use -lxft? ${HAVE_XFT}"
19230
19231echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
19232echo
19233
19234if test $USE_XASSERTS = yes; then
19235 echo " Compiling with asserts turned on."
19236 CPPFLAGS="$CPPFLAGS -DXASSERTS=1"
19237fi
19238
19239echo
19240
19241if test "$HAVE_NS" = "yes"; then
19242 echo
19243 echo "You must run \"make install\" in order to test the built application.
19244The installed application will go to nextstep/Emacs.app and can be
19245run or moved from there."
19246 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
19247 echo "The application will be fully self-contained."
19248 else
19249 echo "The lisp resources for the application will be installed under ${prefix}.
19250You may need to run \"make install\" with sudo. The application will fail
19251to run if these resources are not installed."
19252 fi
19253 echo
19254fi
19255
19256
19257# Remove any trailing slashes in these variables.
19258test "${prefix}" != NONE &&
19259 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
19260test "${exec_prefix}" != NONE &&
19261 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
19262
193770ee 19263ac_config_files="$ac_config_files Makefile lib/Makefile lib-src/Makefile oldXMenu/Makefile doc/emacs/Makefile doc/misc/Makefile doc/lispintro/Makefile doc/lispref/Makefile src/Makefile lwlib/Makefile lisp/Makefile leim/Makefile test/automated/Makefile"
067d23c9
KY
19264
19265ac_config_commands="$ac_config_commands default"
19266
19267cat >confcache <<\_ACEOF
19268# This file is a shell script that caches the results of configure
19269# tests run on this system so they can be shared between configure
19270# scripts and configure runs, see configure's option --config-cache.
19271# It is not useful on other systems. If it contains results you don't
19272# want to keep, you may remove or edit it.
19273#
19274# config.status only pays attention to the cache file if you give it
19275# the --recheck option to rerun configure.
19276#
19277# `ac_cv_env_foo' variables (set or unset) will be overridden when
19278# loading this file, other *unset* `ac_cv_foo' will be assigned the
19279# following values.
19280
19281_ACEOF
19282
19283# The following way of writing the cache mishandles newlines in values,
19284# but we know of no workaround that is simple, portable, and efficient.
19285# So, we kill variables containing newlines.
19286# Ultrix sh set writes to stderr and can't be redirected directly,
19287# and sets the high bit in the cache file unless we assign to the vars.
19288(
19289 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
19290 eval ac_val=\$$ac_var
19291 case $ac_val in #(
19292 *${as_nl}*)
19293 case $ac_var in #(
19294 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
19295$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
19296 esac
19297 case $ac_var in #(
19298 _ | IFS | as_nl) ;; #(
19299 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
19300 *) { eval $ac_var=; unset $ac_var;} ;;
19301 esac ;;
19302 esac
19303 done
19304
19305 (set) 2>&1 |
19306 case $as_nl`(ac_space=' '; set) 2>&1` in #(
19307 *${as_nl}ac_space=\ *)
19308 # `set' does not quote correctly, so add quotes: double-quote
19309 # substitution turns \\\\ into \\, and sed turns \\ into \.
19310 sed -n \
19311 "s/'/'\\\\''/g;
19312 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
19313 ;; #(
19314 *)
19315 # `set' quotes correctly as required by POSIX, so do not add quotes.
19316 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
19317 ;;
19318 esac |
19319 sort
19320) |
19321 sed '
19322 /^ac_cv_env_/b end
19323 t clear
19324 :clear
19325 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
19326 t end
19327 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
19328 :end' >>confcache
19329if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
19330 if test -w "$cache_file"; then
d6974efa 19331 if test "x$cache_file" != "x/dev/null"; then
067d23c9
KY
19332 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
19333$as_echo "$as_me: updating cache $cache_file" >&6;}
d6974efa
PE
19334 if test ! -f "$cache_file" || test -h "$cache_file"; then
19335 cat confcache >"$cache_file"
19336 else
19337 case $cache_file in #(
19338 */* | ?:*)
19339 mv -f confcache "$cache_file"$$ &&
19340 mv -f "$cache_file"$$ "$cache_file" ;; #(
19341 *)
19342 mv -f confcache "$cache_file" ;;
19343 esac
19344 fi
19345 fi
067d23c9
KY
19346 else
19347 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
19348$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
19349 fi
19350fi
19351rm -f confcache
19352
19353test "x$prefix" = xNONE && prefix=$ac_default_prefix
19354# Let make expand exec_prefix.
19355test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
19356
19357DEFS=-DHAVE_CONFIG_H
19358
19359ac_libobjs=
19360ac_ltlibobjs=
2018939f 19361U=
067d23c9
KY
19362for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
19363 # 1. Remove the extension, and $U if already installed.
19364 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
19365 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
19366 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
19367 # will be set to the directory where LIBOBJS objects are built.
19368 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
19369 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
19370done
19371LIBOBJS=$ac_libobjs
19372
19373LTLIBOBJS=$ac_ltlibobjs
19374
19375
743c80a7
PE
19376 if test -n "$EXEEXT"; then
19377 am__EXEEXT_TRUE=
19378 am__EXEEXT_FALSE='#'
19379else
19380 am__EXEEXT_TRUE='#'
19381 am__EXEEXT_FALSE=
19382fi
19383
19384if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
19385 as_fn_error $? "conditional \"AMDEP\" was never defined.
19386Usually this means the macro was only invoked conditionally." "$LINENO" 5
19387fi
19388if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
19389 as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
19390Usually this means the macro was only invoked conditionally." "$LINENO" 5
19391fi
19392
19393if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
19394 as_fn_error $? "conditional \"GL_COND_LIBTOOL\" was never defined.
19395Usually this means the macro was only invoked conditionally." "$LINENO" 5
19396fi
19397
942f733f 19398
743c80a7
PE
19399 gl_libobjs=
19400 gl_ltlibobjs=
19401 if test -n "$gl_LIBOBJS"; then
19402 # Remove the extension.
19403 sed_drop_objext='s/\.o$//;s/\.obj$//'
19404 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
19405 gl_libobjs="$gl_libobjs $i.$ac_objext"
19406 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
19407 done
19408 fi
19409 gl_LIBOBJS=$gl_libobjs
19410
19411 gl_LTLIBOBJS=$gl_ltlibobjs
19412
19413
19414
19415 gltests_libobjs=
19416 gltests_ltlibobjs=
19417 if test -n "$gltests_LIBOBJS"; then
19418 # Remove the extension.
19419 sed_drop_objext='s/\.o$//;s/\.obj$//'
19420 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
19421 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
19422 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
19423 done
19424 fi
19425 gltests_LIBOBJS=$gltests_libobjs
19426
19427 gltests_LTLIBOBJS=$gltests_ltlibobjs
19428
067d23c9
KY
19429
19430
d6974efa 19431: "${CONFIG_STATUS=./config.status}"
067d23c9
KY
19432ac_write_fail=0
19433ac_clean_files_save=$ac_clean_files
19434ac_clean_files="$ac_clean_files $CONFIG_STATUS"
19435{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
19436$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
19437as_write_fail=0
19438cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
19439#! $SHELL
19440# Generated by $as_me.
19441# Run this file to recreate the current configuration.
19442# Compiler output produced by configure, useful for debugging
19443# configure, is in config.log if it exists.
19444
19445debug=false
19446ac_cs_recheck=false
19447ac_cs_silent=false
19448
19449SHELL=\${CONFIG_SHELL-$SHELL}
19450export SHELL
19451_ASEOF
19452cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
19453## -------------------- ##
19454## M4sh Initialization. ##
19455## -------------------- ##
19456
19457# Be more Bourne compatible
19458DUALCASE=1; export DUALCASE # for MKS sh
19459if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
19460 emulate sh
19461 NULLCMD=:
19462 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
19463 # is contrary to our usage. Disable this feature.
19464 alias -g '${1+"$@"}'='"$@"'
19465 setopt NO_GLOB_SUBST
19466else
19467 case `(set -o) 2>/dev/null` in #(
19468 *posix*) :
19469 set -o posix ;; #(
19470 *) :
19471 ;;
19472esac
19473fi
19474
19475
19476as_nl='
19477'
19478export as_nl
19479# Printing a long string crashes Solaris 7 /usr/bin/printf.
19480as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
19481as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
19482as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
19483# Prefer a ksh shell builtin over an external printf program on Solaris,
19484# but without wasting forks for bash or zsh.
19485if test -z "$BASH_VERSION$ZSH_VERSION" \
19486 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
19487 as_echo='print -r --'
19488 as_echo_n='print -rn --'
19489elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
19490 as_echo='printf %s\n'
19491 as_echo_n='printf %s'
19492else
19493 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
19494 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
19495 as_echo_n='/usr/ucb/echo -n'
19496 else
19497 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
19498 as_echo_n_body='eval
19499 arg=$1;
19500 case $arg in #(
19501 *"$as_nl"*)
19502 expr "X$arg" : "X\\(.*\\)$as_nl";
19503 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
19504 esac;
19505 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
19506 '
19507 export as_echo_n_body
19508 as_echo_n='sh -c $as_echo_n_body as_echo'
19509 fi
19510 export as_echo_body
19511 as_echo='sh -c $as_echo_body as_echo'
19512fi
19513
19514# The user is always right.
19515if test "${PATH_SEPARATOR+set}" != set; then
19516 PATH_SEPARATOR=:
19517 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
19518 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
19519 PATH_SEPARATOR=';'
19520 }
19521fi
19522
19523
19524# IFS
19525# We need space, tab and new line, in precisely that order. Quoting is
19526# there to prevent editors from complaining about space-tab.
19527# (If _AS_PATH_WALK were called with IFS unset, it would disable word
19528# splitting by setting IFS to empty value.)
19529IFS=" "" $as_nl"
19530
19531# Find who we are. Look in the path if we contain no directory separator.
d6974efa 19532as_myself=
067d23c9
KY
19533case $0 in #((
19534 *[\\/]* ) as_myself=$0 ;;
19535 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19536for as_dir in $PATH
19537do
19538 IFS=$as_save_IFS
19539 test -z "$as_dir" && as_dir=.
19540 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
19541 done
19542IFS=$as_save_IFS
19543
19544 ;;
19545esac
19546# We did not find ourselves, most probably we were run as `sh COMMAND'
19547# in which case we are not to be found in the path.
19548if test "x$as_myself" = x; then
19549 as_myself=$0
19550fi
19551if test ! -f "$as_myself"; then
19552 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
19553 exit 1
19554fi
19555
19556# Unset variables that we do not need and which cause bugs (e.g. in
19557# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
19558# suppresses any "Segmentation fault" message there. '((' could
19559# trigger a bug in pdksh 5.2.14.
19560for as_var in BASH_ENV ENV MAIL MAILPATH
19561do eval test x\${$as_var+set} = xset \
19562 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
19563done
19564PS1='$ '
19565PS2='> '
19566PS4='+ '
19567
19568# NLS nuisances.
19569LC_ALL=C
19570export LC_ALL
19571LANGUAGE=C
19572export LANGUAGE
19573
19574# CDPATH.
19575(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
19576
19577
2018939f
AS
19578# as_fn_error STATUS ERROR [LINENO LOG_FD]
19579# ----------------------------------------
067d23c9
KY
19580# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
19581# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
2018939f 19582# script with STATUS, using 1 if that was 0.
067d23c9
KY
19583as_fn_error ()
19584{
2018939f
AS
19585 as_status=$1; test $as_status -eq 0 && as_status=1
19586 if test "$4"; then
19587 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
19588 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
067d23c9 19589 fi
2018939f 19590 $as_echo "$as_me: error: $2" >&2
067d23c9
KY
19591 as_fn_exit $as_status
19592} # as_fn_error
19593
19594
19595# as_fn_set_status STATUS
19596# -----------------------
19597# Set $? to STATUS, without forking.
19598as_fn_set_status ()
19599{
19600 return $1
19601} # as_fn_set_status
19602
19603# as_fn_exit STATUS
19604# -----------------
19605# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
19606as_fn_exit ()
19607{
19608 set +e
19609 as_fn_set_status $1
19610 exit $1
19611} # as_fn_exit
19612
19613# as_fn_unset VAR
19614# ---------------
19615# Portably unset VAR.
19616as_fn_unset ()
19617{
19618 { eval $1=; unset $1;}
19619}
19620as_unset=as_fn_unset
19621# as_fn_append VAR VALUE
19622# ----------------------
19623# Append the text in VALUE to the end of the definition contained in VAR. Take
19624# advantage of any shell optimizations that allow amortized linear growth over
19625# repeated appends, instead of the typical quadratic growth present in naive
19626# implementations.
19627if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
19628 eval 'as_fn_append ()
19629 {
19630 eval $1+=\$2
19631 }'
19632else
19633 as_fn_append ()
19634 {
19635 eval $1=\$$1\$2
19636 }
19637fi # as_fn_append
19638
19639# as_fn_arith ARG...
19640# ------------------
19641# Perform arithmetic evaluation on the ARGs, and store the result in the
19642# global $as_val. Take advantage of shells that can avoid forks. The arguments
19643# must be portable across $(()) and expr.
19644if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
19645 eval 'as_fn_arith ()
19646 {
19647 as_val=$(( $* ))
19648 }'
19649else
19650 as_fn_arith ()
19651 {
19652 as_val=`expr "$@" || test $? -eq 1`
19653 }
19654fi # as_fn_arith
19655
19656
19657if expr a : '\(a\)' >/dev/null 2>&1 &&
19658 test "X`expr 00001 : '.*\(...\)'`" = X001; then
19659 as_expr=expr
19660else
19661 as_expr=false
19662fi
19663
19664if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
19665 as_basename=basename
19666else
19667 as_basename=false
19668fi
19669
19670if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
19671 as_dirname=dirname
19672else
19673 as_dirname=false
19674fi
19675
19676as_me=`$as_basename -- "$0" ||
19677$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
19678 X"$0" : 'X\(//\)$' \| \
19679 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
19680$as_echo X/"$0" |
19681 sed '/^.*\/\([^/][^/]*\)\/*$/{
19682 s//\1/
19683 q
19684 }
19685 /^X\/\(\/\/\)$/{
19686 s//\1/
19687 q
19688 }
19689 /^X\/\(\/\).*/{
19690 s//\1/
19691 q
19692 }
19693 s/.*/./; q'`
19694
19695# Avoid depending upon Character Ranges.
19696as_cr_letters='abcdefghijklmnopqrstuvwxyz'
19697as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
19698as_cr_Letters=$as_cr_letters$as_cr_LETTERS
19699as_cr_digits='0123456789'
19700as_cr_alnum=$as_cr_Letters$as_cr_digits
19701
19702ECHO_C= ECHO_N= ECHO_T=
19703case `echo -n x` in #(((((
19704-n*)
19705 case `echo 'xy\c'` in
19706 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
19707 xy) ECHO_C='\c';;
19708 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
19709 ECHO_T=' ';;
19710 esac;;
19711*)
19712 ECHO_N='-n';;
19713esac
19714
19715rm -f conf$$ conf$$.exe conf$$.file
19716if test -d conf$$.dir; then
19717 rm -f conf$$.dir/conf$$.file
19718else
19719 rm -f conf$$.dir
19720 mkdir conf$$.dir 2>/dev/null
19721fi
19722if (echo >conf$$.file) 2>/dev/null; then
19723 if ln -s conf$$.file conf$$ 2>/dev/null; then
19724 as_ln_s='ln -s'
19725 # ... but there are two gotchas:
19726 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
19727 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
19728 # In both cases, we have to default to `cp -p'.
19729 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
19730 as_ln_s='cp -p'
19731 elif ln conf$$.file conf$$ 2>/dev/null; then
19732 as_ln_s=ln
19733 else
19734 as_ln_s='cp -p'
19735 fi
19736else
19737 as_ln_s='cp -p'
19738fi
19739rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
19740rmdir conf$$.dir 2>/dev/null
19741
19742
19743# as_fn_mkdir_p
19744# -------------
19745# Create "$as_dir" as a directory, including parents if necessary.
19746as_fn_mkdir_p ()
19747{
19748
19749 case $as_dir in #(
19750 -*) as_dir=./$as_dir;;
19751 esac
19752 test -d "$as_dir" || eval $as_mkdir_p || {
19753 as_dirs=
19754 while :; do
19755 case $as_dir in #(
19756 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
19757 *) as_qdir=$as_dir;;
19758 esac
19759 as_dirs="'$as_qdir' $as_dirs"
19760 as_dir=`$as_dirname -- "$as_dir" ||
19761$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19762 X"$as_dir" : 'X\(//\)[^/]' \| \
19763 X"$as_dir" : 'X\(//\)$' \| \
19764 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
19765$as_echo X"$as_dir" |
19766 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
19767 s//\1/
19768 q
19769 }
19770 /^X\(\/\/\)[^/].*/{
19771 s//\1/
19772 q
19773 }
19774 /^X\(\/\/\)$/{
19775 s//\1/
19776 q
19777 }
19778 /^X\(\/\).*/{
19779 s//\1/
19780 q
19781 }
19782 s/.*/./; q'`
19783 test -d "$as_dir" && break
19784 done
19785 test -z "$as_dirs" || eval "mkdir $as_dirs"
2018939f 19786 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
067d23c9
KY
19787
19788
19789} # as_fn_mkdir_p
19790if mkdir -p . 2>/dev/null; then
19791 as_mkdir_p='mkdir -p "$as_dir"'
19792else
19793 test -d ./-p && rmdir ./-p
19794 as_mkdir_p=false
19795fi
19796
19797if test -x / >/dev/null 2>&1; then
19798 as_test_x='test -x'
19799else
19800 if ls -dL / >/dev/null 2>&1; then
19801 as_ls_L_option=L
19802 else
19803 as_ls_L_option=
19804 fi
19805 as_test_x='
19806 eval sh -c '\''
19807 if test -d "$1"; then
19808 test -d "$1/.";
19809 else
19810 case $1 in #(
19811 -*)set "./$1";;
19812 esac;
19813 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
19814 ???[sx]*):;;*)false;;esac;fi
19815 '\'' sh
19816 '
19817fi
19818as_executable_p=$as_test_x
19819
19820# Sed expression to map a string onto a valid CPP name.
19821as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
19822
19823# Sed expression to map a string onto a valid variable name.
19824as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
19825
19826
19827exec 6>&1
19828## ----------------------------------- ##
19829## Main body of $CONFIG_STATUS script. ##
19830## ----------------------------------- ##
19831_ASEOF
19832test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
19833
19834cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19835# Save the log message, to keep $0 and so on meaningful, and to
19836# report actual input values of CONFIG_FILES etc. instead of their
19837# values after options handling.
19838ac_log="
19839This file was extended by emacs $as_me 24.0.50, which was
d6974efa 19840generated by GNU Autoconf 2.68. Invocation command line was
067d23c9
KY
19841
19842 CONFIG_FILES = $CONFIG_FILES
19843 CONFIG_HEADERS = $CONFIG_HEADERS
19844 CONFIG_LINKS = $CONFIG_LINKS
19845 CONFIG_COMMANDS = $CONFIG_COMMANDS
19846 $ $0 $@
19847
19848on `(hostname || uname -n) 2>/dev/null | sed 1q`
19849"
19850
19851_ACEOF
19852
19853case $ac_config_files in *"
19854"*) set x $ac_config_files; shift; ac_config_files=$*;;
19855esac
19856
19857case $ac_config_headers in *"
19858"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
19859esac
19860
19861
19862cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19863# Files that config.status was made for.
19864config_files="$ac_config_files"
19865config_headers="$ac_config_headers"
19866config_commands="$ac_config_commands"
19867
19868_ACEOF
19869
19870cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19871ac_cs_usage="\
19872\`$as_me' instantiates files and other configuration actions
19873from templates according to the current configuration. Unless the files
19874and actions are specified as TAGs, all are instantiated by default.
19875
19876Usage: $0 [OPTION]... [TAG]...
19877
19878 -h, --help print this help, then exit
19879 -V, --version print version number and configuration settings, then exit
19880 --config print configuration, then exit
19881 -q, --quiet, --silent
19882 do not print progress messages
19883 -d, --debug don't remove temporary files
19884 --recheck update $as_me by reconfiguring in the same conditions
19885 --file=FILE[:TEMPLATE]
19886 instantiate the configuration file FILE
19887 --header=FILE[:TEMPLATE]
19888 instantiate the configuration header FILE
19889
19890Configuration files:
19891$config_files
19892
19893Configuration headers:
19894$config_headers
19895
19896Configuration commands:
19897$config_commands
19898
19899Report bugs to the package provider."
19900
19901_ACEOF
19902cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19903ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
19904ac_cs_version="\\
19905emacs config.status 24.0.50
d6974efa 19906configured by $0, generated by GNU Autoconf 2.68,
067d23c9
KY
19907 with options \\"\$ac_cs_config\\"
19908
2018939f 19909Copyright (C) 2010 Free Software Foundation, Inc.
067d23c9
KY
19910This config.status script is free software; the Free Software Foundation
19911gives unlimited permission to copy, distribute and modify it."
19912
19913ac_pwd='$ac_pwd'
19914srcdir='$srcdir'
19915INSTALL='$INSTALL'
743c80a7
PE
19916MKDIR_P='$MKDIR_P'
19917AWK='$AWK'
067d23c9
KY
19918test -n "\$AWK" || AWK=awk
19919_ACEOF
19920
19921cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
19922# The default lists apply if the user does not specify any file.
19923ac_need_defaults=:
19924while test $# != 0
19925do
19926 case $1 in
2018939f 19927 --*=?*)
067d23c9
KY
19928 ac_option=`expr "X$1" : 'X\([^=]*\)='`
19929 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
19930 ac_shift=:
19931 ;;
2018939f
AS
19932 --*=)
19933 ac_option=`expr "X$1" : 'X\([^=]*\)='`
19934 ac_optarg=
19935 ac_shift=:
19936 ;;
067d23c9
KY
19937 *)
19938 ac_option=$1
19939 ac_optarg=$2
19940 ac_shift=shift
19941 ;;
19942 esac
19943
19944 case $ac_option in
19945 # Handling of the options.
19946 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
19947 ac_cs_recheck=: ;;
19948 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
19949 $as_echo "$ac_cs_version"; exit ;;
19950 --config | --confi | --conf | --con | --co | --c )
19951 $as_echo "$ac_cs_config"; exit ;;
19952 --debug | --debu | --deb | --de | --d | -d )
19953 debug=: ;;
19954 --file | --fil | --fi | --f )
19955 $ac_shift
19956 case $ac_optarg in
19957 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
2018939f 19958 '') as_fn_error $? "missing file argument" ;;
067d23c9
KY
19959 esac
19960 as_fn_append CONFIG_FILES " '$ac_optarg'"
19961 ac_need_defaults=false;;
19962 --header | --heade | --head | --hea )
19963 $ac_shift
19964 case $ac_optarg in
19965 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
19966 esac
19967 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
19968 ac_need_defaults=false;;
19969 --he | --h)
19970 # Conflict between --help and --header
2018939f 19971 as_fn_error $? "ambiguous option: \`$1'
067d23c9
KY
19972Try \`$0 --help' for more information.";;
19973 --help | --hel | -h )
19974 $as_echo "$ac_cs_usage"; exit ;;
19975 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
19976 | -silent | --silent | --silen | --sile | --sil | --si | --s)
19977 ac_cs_silent=: ;;
19978
19979 # This is an error.
2018939f 19980 -*) as_fn_error $? "unrecognized option: \`$1'
067d23c9
KY
19981Try \`$0 --help' for more information." ;;
19982
19983 *) as_fn_append ac_config_targets " $1"
19984 ac_need_defaults=false ;;
19985
19986 esac
19987 shift
19988done
19989
19990ac_configure_extra_args=
19991
19992if $ac_cs_silent; then
19993 exec 6>/dev/null
19994 ac_configure_extra_args="$ac_configure_extra_args --silent"
19995fi
19996
19997_ACEOF
19998cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
19999if \$ac_cs_recheck; then
20000 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
20001 shift
20002 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
20003 CONFIG_SHELL='$SHELL'
20004 export CONFIG_SHELL
20005 exec "\$@"
20006fi
20007
20008_ACEOF
20009cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20010exec 5>>config.log
20011{
20012 echo
20013 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
20014## Running $as_me. ##
20015_ASBOX
20016 $as_echo "$ac_log"
20017} >&5
20018
20019_ACEOF
20020cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20021#
20022# INIT-COMMANDS
20023#
743c80a7 20024AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
067d23c9
KY
20025GCC="$GCC" NON_GNU_CPP="$NON_GNU_CPP" CPP="$CPP" CPPFLAGS="$CPPFLAGS"
20026
20027_ACEOF
20028
20029cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20030
20031# Handling of arguments.
20032for ac_config_target in $ac_config_targets
20033do
20034 case $ac_config_target in
20035 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
743c80a7 20036 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
067d23c9 20037 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
743c80a7 20038 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
067d23c9
KY
20039 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
20040 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
20041 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
20042 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
20043 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
20044 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
20045 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
20046 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
20047 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
20048 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
ea062854 20049 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
067d23c9
KY
20050 "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
20051
d6974efa 20052 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
067d23c9
KY
20053 esac
20054done
20055
20056
20057# If the user did not use the arguments to specify the items to instantiate,
20058# then the envvar interface is used. Set only those that are not.
20059# We use the long form for the default assignment because of an extremely
20060# bizarre bug on SunOS 4.1.3.
20061if $ac_need_defaults; then
20062 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
20063 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
20064 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
20065fi
20066
20067# Have a temporary directory for convenience. Make it in the build tree
20068# simply because there is no reason against having it here, and in addition,
20069# creating and moving files from /tmp can sometimes cause problems.
20070# Hook for its removal unless debugging.
20071# Note that there is a small window in which the directory will not be cleaned:
20072# after its creation but before its name has been assigned to `$tmp'.
20073$debug ||
20074{
d6974efa 20075 tmp= ac_tmp=
067d23c9 20076 trap 'exit_status=$?
d6974efa
PE
20077 : "${ac_tmp:=$tmp}"
20078 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
067d23c9
KY
20079' 0
20080 trap 'as_fn_exit 1' 1 2 13 15
20081}
20082# Create a (secure) tmp directory for tmp files.
20083
20084{
20085 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
d6974efa 20086 test -d "$tmp"
067d23c9
KY
20087} ||
20088{
20089 tmp=./conf$$-$RANDOM
20090 (umask 077 && mkdir "$tmp")
2018939f 20091} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
d6974efa 20092ac_tmp=$tmp
067d23c9
KY
20093
20094# Set up the scripts for CONFIG_FILES section.
20095# No need to generate them if there are no CONFIG_FILES.
20096# This happens for instance with `./config.status config.h'.
20097if test -n "$CONFIG_FILES"; then
20098
20099if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
20100 ac_cs_awk_getline=:
20101 ac_cs_awk_pipe_init=
20102 ac_cs_awk_read_file='
20103 while ((getline aline < (F[key])) > 0)
20104 print(aline)
20105 close(F[key])'
20106 ac_cs_awk_pipe_fini=
20107else
20108 ac_cs_awk_getline=false
20109 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
20110 ac_cs_awk_read_file='
20111 print "|#_!!_#|"
20112 print "cat " F[key] " &&"
20113 '$ac_cs_awk_pipe_init
20114 # The final `:' finishes the AND list.
20115 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
20116fi
20117ac_cr=`echo X | tr X '\015'`
20118# On cygwin, bash can eat \r inside `` if the user requested igncr.
20119# But we know of no other shell where ac_cr would be empty at this
20120# point, so we can use a bashism as a fallback.
20121if test "x$ac_cr" = x; then
20122 eval ac_cr=\$\'\\r\'
20123fi
20124ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
20125if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
2018939f 20126 ac_cs_awk_cr='\\r'
067d23c9
KY
20127else
20128 ac_cs_awk_cr=$ac_cr
20129fi
20130
d6974efa 20131echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
067d23c9
KY
20132_ACEOF
20133
20134# Create commands to substitute file output variables.
20135{
20136 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
d6974efa 20137 echo 'cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&' &&
067d23c9
KY
20138 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
20139 echo "_ACAWK" &&
20140 echo "_ACEOF"
20141} >conf$$files.sh &&
20142. ./conf$$files.sh ||
2018939f 20143 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
067d23c9
KY
20144rm -f conf$$files.sh
20145
20146{
20147 echo "cat >conf$$subs.awk <<_ACEOF" &&
20148 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
20149 echo "_ACEOF"
20150} >conf$$subs.sh ||
2018939f
AS
20151 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
20152ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
067d23c9
KY
20153ac_delim='%!_!# '
20154for ac_last_try in false false false false false :; do
20155 . ./conf$$subs.sh ||
2018939f 20156 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
067d23c9
KY
20157
20158 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
20159 if test $ac_delim_n = $ac_delim_num; then
20160 break
20161 elif $ac_last_try; then
2018939f 20162 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
067d23c9
KY
20163 else
20164 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
20165 fi
20166done
20167rm -f conf$$subs.sh
20168
20169cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
d6974efa 20170cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
067d23c9
KY
20171_ACEOF
20172sed -n '
20173h
20174s/^/S["/; s/!.*/"]=/
20175p
20176g
20177s/^[^!]*!//
20178:repl
20179t repl
20180s/'"$ac_delim"'$//
20181t delim
20182:nl
20183h
20184s/\(.\{148\}\)..*/\1/
20185t more1
20186s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
20187p
20188n
20189b repl
20190:more1
20191s/["\\]/\\&/g; s/^/"/; s/$/"\\/
20192p
20193g
20194s/.\{148\}//
20195t nl
20196:delim
20197h
20198s/\(.\{148\}\)..*/\1/
20199t more2
20200s/["\\]/\\&/g; s/^/"/; s/$/"/
20201p
20202b
20203:more2
20204s/["\\]/\\&/g; s/^/"/; s/$/"\\/
20205p
20206g
20207s/.\{148\}//
20208t delim
20209' <conf$$subs.awk | sed '
20210/^[^""]/{
20211 N
20212 s/\n//
20213}
20214' >>$CONFIG_STATUS || ac_write_fail=1
20215rm -f conf$$subs.awk
20216cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20217_ACAWK
d6974efa 20218cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
067d23c9
KY
20219 for (key in S) S_is_set[key] = 1
20220 FS = "\a"
20221 \$ac_cs_awk_pipe_init
20222}
20223{
20224 line = $ 0
20225 nfields = split(line, field, "@")
20226 substed = 0
20227 len = length(field[1])
20228 for (i = 2; i < nfields; i++) {
20229 key = field[i]
20230 keylen = length(key)
20231 if (S_is_set[key]) {
20232 value = S[key]
20233 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
20234 len += length(value) + length(field[++i])
20235 substed = 1
20236 } else
20237 len += 1 + keylen
20238 }
20239 if (nfields == 3 && !substed) {
20240 key = field[2]
20241 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
20242 \$ac_cs_awk_read_file
20243 next
20244 }
20245 }
20246 print line
20247}
20248\$ac_cs_awk_pipe_fini
20249_ACAWK
20250_ACEOF
20251cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20252if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
20253 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
20254else
20255 cat
d6974efa 20256fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
2018939f 20257 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
067d23c9
KY
20258_ACEOF
20259
2018939f
AS
20260# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
20261# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
067d23c9
KY
20262# trailing colons and then remove the whole line if VPATH becomes empty
20263# (actually we leave an empty line to preserve line numbers).
20264if test "x$srcdir" = x.; then
2018939f
AS
20265 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
20266h
20267s///
20268s/^/:/
20269s/[ ]*$/:/
20270s/:\$(srcdir):/:/g
20271s/:\${srcdir}:/:/g
20272s/:@srcdir@:/:/g
20273s/^:*//
067d23c9 20274s/:*$//
2018939f
AS
20275x
20276s/\(=[ ]*\).*/\1/
20277G
20278s/\n//
067d23c9
KY
20279s/^[^=]*=[ ]*$//
20280}'
20281fi
20282
20283cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20284fi # test -n "$CONFIG_FILES"
20285
20286# Set up the scripts for CONFIG_HEADERS section.
20287# No need to generate them if there are no CONFIG_HEADERS.
20288# This happens for instance with `./config.status Makefile'.
20289if test -n "$CONFIG_HEADERS"; then
d6974efa 20290cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
067d23c9
KY
20291BEGIN {
20292_ACEOF
20293
20294# Transform confdefs.h into an awk script `defines.awk', embedded as
20295# here-document in config.status, that substitutes the proper values into
20296# config.h.in to produce config.h.
20297
20298# Create a delimiter string that does not exist in confdefs.h, to ease
20299# handling of long lines.
20300ac_delim='%!_!# '
20301for ac_last_try in false false :; do
d6974efa
PE
20302 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
20303 if test -z "$ac_tt"; then
067d23c9
KY
20304 break
20305 elif $ac_last_try; then
2018939f 20306 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
067d23c9
KY
20307 else
20308 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
20309 fi
20310done
20311
20312# For the awk script, D is an array of macro values keyed by name,
20313# likewise P contains macro parameters if any. Preserve backslash
20314# newline sequences.
20315
20316ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
20317sed -n '
20318s/.\{148\}/&'"$ac_delim"'/g
20319t rset
20320:rset
20321s/^[ ]*#[ ]*define[ ][ ]*/ /
20322t def
20323d
20324:def
20325s/\\$//
20326t bsnl
20327s/["\\]/\\&/g
20328s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
20329D["\1"]=" \3"/p
20330s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
20331d
20332:bsnl
20333s/["\\]/\\&/g
20334s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
20335D["\1"]=" \3\\\\\\n"\\/p
20336t cont
20337s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
20338t cont
20339d
20340:cont
20341n
20342s/.\{148\}/&'"$ac_delim"'/g
20343t clear
20344:clear
20345s/\\$//
20346t bsnlc
20347s/["\\]/\\&/g; s/^/"/; s/$/"/p
20348d
20349:bsnlc
20350s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
20351b cont
20352' <confdefs.h | sed '
20353s/'"$ac_delim"'/"\\\
20354"/g' >>$CONFIG_STATUS || ac_write_fail=1
20355
20356cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20357 for (key in D) D_is_set[key] = 1
20358 FS = "\a"
20359}
20360/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
20361 line = \$ 0
20362 split(line, arg, " ")
20363 if (arg[1] == "#") {
20364 defundef = arg[2]
20365 mac1 = arg[3]
20366 } else {
20367 defundef = substr(arg[1], 2)
20368 mac1 = arg[2]
20369 }
20370 split(mac1, mac2, "(") #)
20371 macro = mac2[1]
20372 prefix = substr(line, 1, index(line, defundef) - 1)
20373 if (D_is_set[macro]) {
20374 # Preserve the white space surrounding the "#".
20375 print prefix "define", macro P[macro] D[macro]
20376 next
20377 } else {
20378 # Replace #undef with comments. This is necessary, for example,
20379 # in the case of _POSIX_SOURCE, which is predefined and required
20380 # on some systems where configure will not decide to define it.
20381 if (defundef == "undef") {
20382 print "/*", prefix defundef, macro, "*/"
20383 next
20384 }
20385 }
20386}
20387{ print }
20388_ACAWK
20389_ACEOF
20390cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
2018939f 20391 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
067d23c9
KY
20392fi # test -n "$CONFIG_HEADERS"
20393
20394
20395eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
20396shift
20397for ac_tag
20398do
20399 case $ac_tag in
20400 :[FHLC]) ac_mode=$ac_tag; continue;;
20401 esac
20402 case $ac_mode$ac_tag in
20403 :[FHL]*:*);;
d6974efa 20404 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
067d23c9
KY
20405 :[FH]-) ac_tag=-:-;;
20406 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
20407 esac
20408 ac_save_IFS=$IFS
20409 IFS=:
20410 set x $ac_tag
20411 IFS=$ac_save_IFS
20412 shift
20413 ac_file=$1
20414 shift
20415
20416 case $ac_mode in
20417 :L) ac_source=$1;;
20418 :[FH])
20419 ac_file_inputs=
20420 for ac_f
20421 do
20422 case $ac_f in
d6974efa 20423 -) ac_f="$ac_tmp/stdin";;
067d23c9
KY
20424 *) # Look for the file first in the build tree, then in the source tree
20425 # (if the path is not absolute). The absolute path cannot be DOS-style,
20426 # because $ac_f cannot contain `:'.
20427 test -f "$ac_f" ||
20428 case $ac_f in
20429 [\\/$]*) false;;
20430 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
20431 esac ||
d6974efa 20432 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
067d23c9
KY
20433 esac
20434 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
20435 as_fn_append ac_file_inputs " '$ac_f'"
20436 done
20437
20438 # Let's still pretend it is `configure' which instantiates (i.e., don't
20439 # use $as_me), people would be surprised to read:
20440 # /* config.h. Generated by config.status. */
20441 configure_input='Generated from '`
20442 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
20443 `' by configure.'
20444 if test x"$ac_file" != x-; then
20445 configure_input="$ac_file. $configure_input"
20446 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
20447$as_echo "$as_me: creating $ac_file" >&6;}
20448 fi
20449 # Neutralize special characters interpreted by sed in replacement strings.
20450 case $configure_input in #(
20451 *\&* | *\|* | *\\* )
20452 ac_sed_conf_input=`$as_echo "$configure_input" |
20453 sed 's/[\\\\&|]/\\\\&/g'`;; #(
20454 *) ac_sed_conf_input=$configure_input;;
20455 esac
20456
20457 case $ac_tag in
d6974efa
PE
20458 *:-:* | *:-) cat >"$ac_tmp/stdin" \
20459 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
067d23c9
KY
20460 esac
20461 ;;
20462 esac
20463
20464 ac_dir=`$as_dirname -- "$ac_file" ||
20465$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20466 X"$ac_file" : 'X\(//\)[^/]' \| \
20467 X"$ac_file" : 'X\(//\)$' \| \
20468 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
20469$as_echo X"$ac_file" |
20470 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
20471 s//\1/
20472 q
20473 }
20474 /^X\(\/\/\)[^/].*/{
20475 s//\1/
20476 q
20477 }
20478 /^X\(\/\/\)$/{
20479 s//\1/
20480 q
20481 }
20482 /^X\(\/\).*/{
20483 s//\1/
20484 q
20485 }
20486 s/.*/./; q'`
20487 as_dir="$ac_dir"; as_fn_mkdir_p
20488 ac_builddir=.
20489
20490case "$ac_dir" in
20491.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
20492*)
20493 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
20494 # A ".." for each directory in $ac_dir_suffix.
20495 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
20496 case $ac_top_builddir_sub in
20497 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
20498 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
20499 esac ;;
20500esac
20501ac_abs_top_builddir=$ac_pwd
20502ac_abs_builddir=$ac_pwd$ac_dir_suffix
20503# for backward compatibility:
20504ac_top_builddir=$ac_top_build_prefix
20505
20506case $srcdir in
20507 .) # We are building in place.
20508 ac_srcdir=.
20509 ac_top_srcdir=$ac_top_builddir_sub
20510 ac_abs_top_srcdir=$ac_pwd ;;
20511 [\\/]* | ?:[\\/]* ) # Absolute name.
20512 ac_srcdir=$srcdir$ac_dir_suffix;
20513 ac_top_srcdir=$srcdir
20514 ac_abs_top_srcdir=$srcdir ;;
20515 *) # Relative name.
20516 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
20517 ac_top_srcdir=$ac_top_build_prefix$srcdir
20518 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
20519esac
20520ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
20521
20522
20523 case $ac_mode in
20524 :F)
20525 #
20526 # CONFIG_FILE
20527 #
20528
20529 case $INSTALL in
20530 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
20531 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
20532 esac
743c80a7
PE
20533 ac_MKDIR_P=$MKDIR_P
20534 case $MKDIR_P in
20535 [\\/$]* | ?:[\\/]* ) ;;
20536 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
20537 esac
067d23c9
KY
20538_ACEOF
20539
20540cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20541# If the template does not know about datarootdir, expand it.
20542# FIXME: This hack should be removed a few years after 2.60.
20543ac_datarootdir_hack=; ac_datarootdir_seen=
20544ac_sed_dataroot='
20545/datarootdir/ {
20546 p
20547 q
20548}
20549/@datadir@/p
20550/@docdir@/p
20551/@infodir@/p
20552/@localedir@/p
20553/@mandir@/p'
20554case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
20555*datarootdir*) ac_datarootdir_seen=yes;;
20556*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
20557 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
20558$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
20559_ACEOF
20560cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20561 ac_datarootdir_hack='
20562 s&@datadir@&$datadir&g
20563 s&@docdir@&$docdir&g
20564 s&@infodir@&$infodir&g
20565 s&@localedir@&$localedir&g
20566 s&@mandir@&$mandir&g
20567 s&\\\${datarootdir}&$datarootdir&g' ;;
20568esac
20569_ACEOF
20570
20571# Neutralize VPATH when `$srcdir' = `.'.
20572# Shell code in configure.ac might set extrasub.
20573# FIXME: do we really want to maintain this feature?
20574cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
20575ac_sed_extra="$ac_vpsub
20576$extrasub
20577_ACEOF
20578cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
20579:t
20580/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
20581s|@configure_input@|$ac_sed_conf_input|;t t
20582s&@top_builddir@&$ac_top_builddir_sub&;t t
20583s&@top_build_prefix@&$ac_top_build_prefix&;t t
20584s&@srcdir@&$ac_srcdir&;t t
20585s&@abs_srcdir@&$ac_abs_srcdir&;t t
20586s&@top_srcdir@&$ac_top_srcdir&;t t
20587s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
20588s&@builddir@&$ac_builddir&;t t
20589s&@abs_builddir@&$ac_abs_builddir&;t t
20590s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
20591s&@INSTALL@&$ac_INSTALL&;t t
743c80a7 20592s&@MKDIR_P@&$ac_MKDIR_P&;t t
067d23c9
KY
20593$ac_datarootdir_hack
20594"
20595eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
20596if $ac_cs_awk_getline; then
d6974efa 20597 $AWK -f "$ac_tmp/subs.awk"
067d23c9 20598else
d6974efa
PE
20599 $AWK -f "$ac_tmp/subs.awk" | $SHELL
20600fi \
20601 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
067d23c9
KY
20602
20603test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
d6974efa
PE
20604 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
20605 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
20606 "$ac_tmp/out"`; test -z "$ac_out"; } &&
067d23c9 20607 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
2018939f 20608which seems to be undefined. Please make sure it is defined" >&5
067d23c9 20609$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
2018939f 20610which seems to be undefined. Please make sure it is defined" >&2;}
067d23c9 20611
d6974efa 20612 rm -f "$ac_tmp/stdin"
067d23c9 20613 case $ac_file in
d6974efa
PE
20614 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
20615 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
067d23c9 20616 esac \
2018939f 20617 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
067d23c9
KY
20618 ;;
20619 :H)
20620 #
20621 # CONFIG_HEADER
20622 #
20623 if test x"$ac_file" != x-; then
20624 {
20625 $as_echo "/* $configure_input */" \
d6974efa
PE
20626 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
20627 } >"$ac_tmp/config.h" \
2018939f 20628 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
d6974efa 20629 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
067d23c9
KY
20630 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
20631$as_echo "$as_me: $ac_file is unchanged" >&6;}
20632 else
20633 rm -f "$ac_file"
d6974efa 20634 mv "$ac_tmp/config.h" "$ac_file" \
2018939f 20635 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
067d23c9
KY
20636 fi
20637 else
20638 $as_echo "/* $configure_input */" \
d6974efa 20639 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
2018939f 20640 || as_fn_error $? "could not create -" "$LINENO" 5
067d23c9 20641 fi
743c80a7
PE
20642# Compute "$ac_file"'s index in $config_headers.
20643_am_arg="$ac_file"
20644_am_stamp_count=1
20645for _am_header in $config_headers :; do
20646 case $_am_header in
20647 $_am_arg | $_am_arg:* )
20648 break ;;
20649 * )
20650 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
20651 esac
20652done
20653echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
20654$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20655 X"$_am_arg" : 'X\(//\)[^/]' \| \
20656 X"$_am_arg" : 'X\(//\)$' \| \
20657 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
20658$as_echo X"$_am_arg" |
20659 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
20660 s//\1/
20661 q
20662 }
20663 /^X\(\/\/\)[^/].*/{
20664 s//\1/
20665 q
20666 }
20667 /^X\(\/\/\)$/{
20668 s//\1/
20669 q
20670 }
20671 /^X\(\/\).*/{
20672 s//\1/
20673 q
20674 }
20675 s/.*/./; q'`/stamp-h$_am_stamp_count
067d23c9
KY
20676 ;;
20677
20678 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
20679$as_echo "$as_me: executing $ac_file commands" >&6;}
20680 ;;
20681 esac
20682
20683
20684 case $ac_file$ac_mode in
743c80a7
PE
20685 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
20686 # Autoconf 2.62 quotes --file arguments for eval, but not when files
20687 # are listed without --file. Let's play safe and only enable the eval
20688 # if we detect the quoting.
20689 case $CONFIG_FILES in
20690 *\'*) eval set x "$CONFIG_FILES" ;;
20691 *) set x $CONFIG_FILES ;;
20692 esac
20693 shift
20694 for mf
20695 do
20696 # Strip MF so we end up with the name of the file.
20697 mf=`echo "$mf" | sed -e 's/:.*$//'`
20698 # Check whether this is an Automake generated Makefile or not.
20699 # We used to match only the files named `Makefile.in', but
20700 # some people rename them; so instead we look at the file content.
20701 # Grep'ing the first line is not enough: some people post-process
20702 # each Makefile.in and add a new line on top of each file to say so.
20703 # Grep'ing the whole file is not good either: AIX grep has a line
20704 # limit of 2048, but all sed's we know have understand at least 4000.
20705 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
20706 dirpart=`$as_dirname -- "$mf" ||
20707$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20708 X"$mf" : 'X\(//\)[^/]' \| \
20709 X"$mf" : 'X\(//\)$' \| \
20710 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
20711$as_echo X"$mf" |
20712 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
20713 s//\1/
20714 q
20715 }
20716 /^X\(\/\/\)[^/].*/{
20717 s//\1/
20718 q
20719 }
20720 /^X\(\/\/\)$/{
20721 s//\1/
20722 q
20723 }
20724 /^X\(\/\).*/{
20725 s//\1/
20726 q
20727 }
20728 s/.*/./; q'`
20729 else
20730 continue
20731 fi
20732 # Extract the definition of DEPDIR, am__include, and am__quote
20733 # from the Makefile without running `make'.
20734 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
20735 test -z "$DEPDIR" && continue
20736 am__include=`sed -n 's/^am__include = //p' < "$mf"`
20737 test -z "am__include" && continue
20738 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
20739 # When using ansi2knr, U may be empty or an underscore; expand it
20740 U=`sed -n 's/^U = //p' < "$mf"`
20741 # Find all dependency output files, they are included files with
20742 # $(DEPDIR) in their names. We invoke sed twice because it is the
20743 # simplest approach to changing $(DEPDIR) to its actual value in the
20744 # expansion.
20745 for file in `sed -n "
20746 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
20747 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
20748 # Make sure the directory exists.
20749 test -f "$dirpart/$file" && continue
20750 fdir=`$as_dirname -- "$file" ||
20751$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20752 X"$file" : 'X\(//\)[^/]' \| \
20753 X"$file" : 'X\(//\)$' \| \
20754 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
20755$as_echo X"$file" |
20756 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
20757 s//\1/
20758 q
20759 }
20760 /^X\(\/\/\)[^/].*/{
20761 s//\1/
20762 q
20763 }
20764 /^X\(\/\/\)$/{
20765 s//\1/
20766 q
20767 }
20768 /^X\(\/\).*/{
20769 s//\1/
20770 q
20771 }
20772 s/.*/./; q'`
20773 as_dir=$dirpart/$fdir; as_fn_mkdir_p
20774 # echo "creating $dirpart/$file"
20775 echo '# dummy' > "$dirpart/$file"
20776 done
20777 done
20778}
20779 ;;
067d23c9
KY
20780 "default":C)
20781
20782### Make the necessary directories, if they don't exist.
20783for dir in etc lisp ; do
20784 test -d ${dir} || mkdir ${dir}
20785done
20786
20787echo creating src/epaths.h
20788${MAKE-make} epaths-force
20789
20790if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
20791 echo creating src/.gdbinit
20792 echo source $srcdir/src/.gdbinit > src/.gdbinit
20793fi
20794
20795 ;;
20796
20797 esac
20798done # for ac_tag
20799
20800
20801as_fn_exit 0
20802_ACEOF
20803ac_clean_files=$ac_clean_files_save
20804
20805test $ac_write_fail = 0 ||
2018939f 20806 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
067d23c9
KY
20807
20808
20809# configure is writing to config.log, and then calls config.status.
20810# config.status does its own redirection, appending to config.log.
20811# Unfortunately, on DOS this fails, as config.log is still kept open
20812# by configure, so config.status won't be able to write to it; its
20813# output is simply discarded. So we exec the FD to /dev/null,
20814# effectively closing config.log, so it can be properly (re)opened and
20815# appended to by config.status. When coming back to configure, we
20816# need to make the FD available again.
20817if test "$no_create" != yes; then
20818 ac_cs_success=:
20819 ac_config_status_args=
20820 test "$silent" = yes &&
20821 ac_config_status_args="$ac_config_status_args --quiet"
20822 exec 5>/dev/null
20823 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
20824 exec 5>>config.log
20825 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
20826 # would make configure fail if this is the last instruction.
2018939f 20827 $ac_cs_success || as_fn_exit 1
067d23c9
KY
20828fi
20829if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
20830 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
20831$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
20832fi
20833