Remove duplicate declarations.
[emacs.git] / configure
blob53c2407f3a9f76bf23ec14ebe2343901880a6482
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.65 for emacs 24.0.50.
6 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
7 # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
8 # Inc.
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 ## -------------------- ##
17 # Be more Bourne compatible
18 DUALCASE=1; export DUALCASE # for MKS sh
19 if 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
26 else
27 case `(set -o) 2>/dev/null` in #(
28 *posix*) :
29 set -o posix ;; #(
30 *) :
32 esac
36 as_nl='
38 export as_nl
39 # Printing a long string crashes Solaris 7 /usr/bin/printf.
40 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42 as_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.
45 if 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 --'
49 elif (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'
52 else
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"
67 export as_echo_n_body
68 as_echo_n='sh -c $as_echo_n_body as_echo'
70 export as_echo_body
71 as_echo='sh -c $as_echo_body as_echo'
74 # The user is always right.
75 if 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=';'
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.)
89 IFS=" "" $as_nl"
91 # Find who we are. Look in the path if we contain no directory separator.
92 case $0 in #((
93 *[\\/]* ) as_myself=$0 ;;
94 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
95 for as_dir in $PATH
97 IFS=$as_save_IFS
98 test -z "$as_dir" && as_dir=.
99 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
100 done
101 IFS=$as_save_IFS
104 esac
105 # We did not find ourselves, most probably we were run as `sh COMMAND'
106 # in which case we are not to be found in the path.
107 if test "x$as_myself" = x; then
108 as_myself=$0
110 if test ! -f "$as_myself"; then
111 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
112 exit 1
115 # Unset variables that we do not need and which cause bugs (e.g. in
116 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
117 # suppresses any "Segmentation fault" message there. '((' could
118 # trigger a bug in pdksh 5.2.14.
119 for as_var in BASH_ENV ENV MAIL MAILPATH
120 do eval test x\${$as_var+set} = xset \
121 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
122 done
123 PS1='$ '
124 PS2='> '
125 PS4='+ '
127 # NLS nuisances.
128 LC_ALL=C
129 export LC_ALL
130 LANGUAGE=C
131 export LANGUAGE
133 # CDPATH.
134 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
136 if test "x$CONFIG_SHELL" = x; then
137 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
138 emulate sh
139 NULLCMD=:
140 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
141 # is contrary to our usage. Disable this feature.
142 alias -g '\${1+\"\$@\"}'='\"\$@\"'
143 setopt NO_GLOB_SUBST
144 else
145 case \`(set -o) 2>/dev/null\` in #(
146 *posix*) :
147 set -o posix ;; #(
148 *) :
150 esac
153 as_required="as_fn_return () { (exit \$1); }
154 as_fn_success () { as_fn_return 0; }
155 as_fn_failure () { as_fn_return 1; }
156 as_fn_ret_success () { return 0; }
157 as_fn_ret_failure () { return 1; }
159 exitcode=0
160 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
161 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
162 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
163 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
164 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
166 else
167 exitcode=1; echo positional parameters were not saved.
169 test x\$exitcode = x0 || exit 1"
170 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
171 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
172 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
173 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
174 test \$(( 1 + 1 )) = 2 || exit 1"
175 if (eval "$as_required") 2>/dev/null; then :
176 as_have_required=yes
177 else
178 as_have_required=no
180 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
182 else
183 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
184 as_found=false
185 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
187 IFS=$as_save_IFS
188 test -z "$as_dir" && as_dir=.
189 as_found=:
190 case $as_dir in #(
192 for as_base in sh bash ksh sh5; do
193 # Try only shells that exist, to save several forks.
194 as_shell=$as_dir/$as_base
195 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
196 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
197 CONFIG_SHELL=$as_shell as_have_required=yes
198 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
199 break 2
202 done;;
203 esac
204 as_found=false
205 done
206 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
207 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
208 CONFIG_SHELL=$SHELL as_have_required=yes
209 fi; }
210 IFS=$as_save_IFS
213 if test "x$CONFIG_SHELL" != x; then :
214 # We cannot yet assume a decent shell, so we have to provide a
215 # neutralization value for shells without unset; and this also
216 # works around shells that cannot unset nonexistent variables.
217 BASH_ENV=/dev/null
218 ENV=/dev/null
219 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
220 export CONFIG_SHELL
221 exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
224 if test x$as_have_required = xno; then :
225 $as_echo "$0: This script requires a shell more modern than all"
226 $as_echo "$0: the shells that I found on your system."
227 if test x${ZSH_VERSION+set} = xset ; then
228 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
229 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
230 else
231 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
232 $0: including any error possibly output before this
233 $0: message. Then install a modern shell, or manually run
234 $0: the script under such a shell if you do have one."
236 exit 1
240 SHELL=${CONFIG_SHELL-/bin/sh}
241 export SHELL
242 # Unset more variables known to interfere with behavior of common tools.
243 CLICOLOR_FORCE= GREP_OPTIONS=
244 unset CLICOLOR_FORCE GREP_OPTIONS
246 ## --------------------- ##
247 ## M4sh Shell Functions. ##
248 ## --------------------- ##
249 # as_fn_unset VAR
250 # ---------------
251 # Portably unset VAR.
252 as_fn_unset ()
254 { eval $1=; unset $1;}
256 as_unset=as_fn_unset
258 # as_fn_set_status STATUS
259 # -----------------------
260 # Set $? to STATUS, without forking.
261 as_fn_set_status ()
263 return $1
264 } # as_fn_set_status
266 # as_fn_exit STATUS
267 # -----------------
268 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
269 as_fn_exit ()
271 set +e
272 as_fn_set_status $1
273 exit $1
274 } # as_fn_exit
276 # as_fn_mkdir_p
277 # -------------
278 # Create "$as_dir" as a directory, including parents if necessary.
279 as_fn_mkdir_p ()
282 case $as_dir in #(
283 -*) as_dir=./$as_dir;;
284 esac
285 test -d "$as_dir" || eval $as_mkdir_p || {
286 as_dirs=
287 while :; do
288 case $as_dir in #(
289 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
290 *) as_qdir=$as_dir;;
291 esac
292 as_dirs="'$as_qdir' $as_dirs"
293 as_dir=`$as_dirname -- "$as_dir" ||
294 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
295 X"$as_dir" : 'X\(//\)[^/]' \| \
296 X"$as_dir" : 'X\(//\)$' \| \
297 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
298 $as_echo X"$as_dir" |
299 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
300 s//\1/
303 /^X\(\/\/\)[^/].*/{
304 s//\1/
307 /^X\(\/\/\)$/{
308 s//\1/
311 /^X\(\/\).*/{
312 s//\1/
315 s/.*/./; q'`
316 test -d "$as_dir" && break
317 done
318 test -z "$as_dirs" || eval "mkdir $as_dirs"
319 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
322 } # as_fn_mkdir_p
323 # as_fn_append VAR VALUE
324 # ----------------------
325 # Append the text in VALUE to the end of the definition contained in VAR. Take
326 # advantage of any shell optimizations that allow amortized linear growth over
327 # repeated appends, instead of the typical quadratic growth present in naive
328 # implementations.
329 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
330 eval 'as_fn_append ()
332 eval $1+=\$2
334 else
335 as_fn_append ()
337 eval $1=\$$1\$2
339 fi # as_fn_append
341 # as_fn_arith ARG...
342 # ------------------
343 # Perform arithmetic evaluation on the ARGs, and store the result in the
344 # global $as_val. Take advantage of shells that can avoid forks. The arguments
345 # must be portable across $(()) and expr.
346 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
347 eval 'as_fn_arith ()
349 as_val=$(( $* ))
351 else
352 as_fn_arith ()
354 as_val=`expr "$@" || test $? -eq 1`
356 fi # as_fn_arith
359 # as_fn_error ERROR [LINENO LOG_FD]
360 # ---------------------------------
361 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
362 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
363 # script with status $?, using 1 if that was 0.
364 as_fn_error ()
366 as_status=$?; test $as_status -eq 0 && as_status=1
367 if test "$3"; then
368 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
369 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
371 $as_echo "$as_me: error: $1" >&2
372 as_fn_exit $as_status
373 } # as_fn_error
375 if expr a : '\(a\)' >/dev/null 2>&1 &&
376 test "X`expr 00001 : '.*\(...\)'`" = X001; then
377 as_expr=expr
378 else
379 as_expr=false
382 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
383 as_basename=basename
384 else
385 as_basename=false
388 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
389 as_dirname=dirname
390 else
391 as_dirname=false
394 as_me=`$as_basename -- "$0" ||
395 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
396 X"$0" : 'X\(//\)$' \| \
397 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
398 $as_echo X/"$0" |
399 sed '/^.*\/\([^/][^/]*\)\/*$/{
400 s//\1/
403 /^X\/\(\/\/\)$/{
404 s//\1/
407 /^X\/\(\/\).*/{
408 s//\1/
411 s/.*/./; q'`
413 # Avoid depending upon Character Ranges.
414 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
415 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
416 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
417 as_cr_digits='0123456789'
418 as_cr_alnum=$as_cr_Letters$as_cr_digits
421 as_lineno_1=$LINENO as_lineno_1a=$LINENO
422 as_lineno_2=$LINENO as_lineno_2a=$LINENO
423 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
424 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
425 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
426 sed -n '
428 /[$]LINENO/=
429 ' <$as_myself |
430 sed '
431 s/[$]LINENO.*/&-/
432 t lineno
434 :lineno
436 :loop
437 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
438 t loop
439 s/-\n.*//
440 ' >$as_me.lineno &&
441 chmod +x "$as_me.lineno" ||
442 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
444 # Don't try to exec as it changes $[0], causing all sort of problems
445 # (the dirname of $[0] is not the place where we might find the
446 # original and so on. Autoconf is especially sensitive to this).
447 . "./$as_me.lineno"
448 # Exit status is that of the last command.
449 exit
452 ECHO_C= ECHO_N= ECHO_T=
453 case `echo -n x` in #(((((
454 -n*)
455 case `echo 'xy\c'` in
456 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
457 xy) ECHO_C='\c';;
458 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
459 ECHO_T=' ';;
460 esac;;
462 ECHO_N='-n';;
463 esac
465 rm -f conf$$ conf$$.exe conf$$.file
466 if test -d conf$$.dir; then
467 rm -f conf$$.dir/conf$$.file
468 else
469 rm -f conf$$.dir
470 mkdir conf$$.dir 2>/dev/null
472 if (echo >conf$$.file) 2>/dev/null; then
473 if ln -s conf$$.file conf$$ 2>/dev/null; then
474 as_ln_s='ln -s'
475 # ... but there are two gotchas:
476 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
477 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
478 # In both cases, we have to default to `cp -p'.
479 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
480 as_ln_s='cp -p'
481 elif ln conf$$.file conf$$ 2>/dev/null; then
482 as_ln_s=ln
483 else
484 as_ln_s='cp -p'
486 else
487 as_ln_s='cp -p'
489 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
490 rmdir conf$$.dir 2>/dev/null
492 if mkdir -p . 2>/dev/null; then
493 as_mkdir_p='mkdir -p "$as_dir"'
494 else
495 test -d ./-p && rmdir ./-p
496 as_mkdir_p=false
499 if test -x / >/dev/null 2>&1; then
500 as_test_x='test -x'
501 else
502 if ls -dL / >/dev/null 2>&1; then
503 as_ls_L_option=L
504 else
505 as_ls_L_option=
507 as_test_x='
508 eval sh -c '\''
509 if test -d "$1"; then
510 test -d "$1/.";
511 else
512 case $1 in #(
513 -*)set "./$1";;
514 esac;
515 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
516 ???[sx]*):;;*)false;;esac;fi
517 '\'' sh
520 as_executable_p=$as_test_x
522 # Sed expression to map a string onto a valid CPP name.
523 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
525 # Sed expression to map a string onto a valid variable name.
526 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
529 test -n "$DJDIR" || exec 7<&0 </dev/null
530 exec 6>&1
532 # Name of the host.
533 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
534 # so uname gets run too.
535 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
538 # Initializations.
540 ac_default_prefix=/usr/local
541 ac_clean_files=
542 ac_config_libobj_dir=.
543 LIBOBJS=
544 cross_compiling=no
545 subdirs=
546 MFLAGS=
547 MAKEFLAGS=
549 # Identity of this package.
550 PACKAGE_NAME='emacs'
551 PACKAGE_TARNAME='emacs'
552 PACKAGE_VERSION='24.0.50'
553 PACKAGE_STRING='emacs 24.0.50'
554 PACKAGE_BUGREPORT=''
555 PACKAGE_URL=''
557 ac_unique_file="src/lisp.h"
558 # Factoring default headers for most tests.
559 ac_includes_default="\
560 #include <stdio.h>
561 #ifdef HAVE_SYS_TYPES_H
562 # include <sys/types.h>
563 #endif
564 #ifdef HAVE_SYS_STAT_H
565 # include <sys/stat.h>
566 #endif
567 #ifdef STDC_HEADERS
568 # include <stdlib.h>
569 # include <stddef.h>
570 #else
571 # ifdef HAVE_STDLIB_H
572 # include <stdlib.h>
573 # endif
574 #endif
575 #ifdef HAVE_STRING_H
576 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
577 # include <memory.h>
578 # endif
579 # include <string.h>
580 #endif
581 #ifdef HAVE_STRINGS_H
582 # include <strings.h>
583 #endif
584 #ifdef HAVE_INTTYPES_H
585 # include <inttypes.h>
586 #endif
587 #ifdef HAVE_STDINT_H
588 # include <stdint.h>
589 #endif
590 #ifdef HAVE_UNISTD_H
591 # include <unistd.h>
592 #endif"
594 ac_config_libobj_dir=src
595 ac_header_list=
596 ac_func_list=
597 ac_subst_vars='LTLIBOBJS
598 WINDOW_SUPPORT
599 TOOLTIP_SUPPORT
600 MOUSE_SUPPORT
601 LIB_GCC
602 LINKER
603 LD_SWITCH_SYSTEM_TEMACS
604 POST_ALLOC_OBJ
605 PRE_ALLOC_OBJ
606 CYGWIN_OBJ
607 RALLOC_OBJ
608 OLDXMENU_DEPS
609 LIBX_OTHER
610 LIBXMENU
611 OLDXMENU
612 OLDXMENU_TARGET
613 LIBXT_OTHER
614 TOOLKIT_LIBW
615 WIDGET_OBJ
616 XOBJ
617 XMENU_OBJ
618 FONT_OBJ
619 OTHER_FILES
620 GNU_OBJC_CFLAGS
621 ns_appsrc
622 ns_appresdir
623 ns_appbindir
624 ns_appdir
625 opsysfile
626 machfile
627 X_TOOLKIT_TYPE
628 C_SWITCH_X_SYSTEM
629 C_SWITCH_X_SITE
630 LD_SWITCH_X_SITE
631 gameuser
632 gamedir
633 bitmapdir
634 archlibdir
635 etcdir
636 x_default_search_path
637 lisppath
638 locallisppath
639 lispdir
640 srcdir
641 canonical
642 configuration
643 version
644 KRB4LIB
645 DESLIB
646 KRB5LIB
647 CRYPTOLIB
648 COM_ERRLIB
649 LIBRESOLV
650 LIBHESIOD
651 TERMCAP_OBJ
652 LIBS_TERMCAP
653 GETOPTOBJS
654 GETOPT_H
655 GETLOADAVG_LIBS
656 KMEM_GROUP
657 NEED_SETGID
658 LIBOBJS
659 BLESSMAIL_TARGET
660 LIBS_MAIL
661 liblockfile
662 ALLOCA
663 LIBXSM
664 LIBGPM
665 LIBGIF
666 LIBTIFF
667 LIBPNG
668 LIBJPEG
669 LIBXPM
670 FREETYPE_LIBS
671 FREETYPE_CFLAGS
672 M17N_FLT_LIBS
673 M17N_FLT_CFLAGS
674 LIBOTF_LIBS
675 LIBOTF_CFLAGS
676 XFT_LIBS
677 XFT_CFLAGS
678 FONTCONFIG_LIBS
679 FONTCONFIG_CFLAGS
680 LIBXMU
681 LIBXTR6
682 LIBSELINUX_LIBS
683 GCONF_LIBS
684 GCONF_CFLAGS
685 DBUS_OBJ
686 DBUS_LIBS
687 DBUS_CFLAGS
688 GTK_OBJ
689 GTK_LIBS
690 GTK_CFLAGS
691 RSVG_LIBS
692 RSVG_CFLAGS
693 VMLIMIT_OBJ
694 GMALLOC_OBJ
695 HAVE_XSERVER
696 LIB_STANDARD
697 NS_SUPPORT
698 NS_OBJ
699 TEMACS_LDFLAGS2
700 LD_SWITCH_X_SITE_AUX_RPATH
701 LD_SWITCH_X_SITE_AUX
702 XMKMF
703 DEPFLAGS
704 MKDEPDIR
705 SET_MAKE
706 CFLAGS_SOUND
707 ALSA_LIBS
708 ALSA_CFLAGS
709 PKG_CONFIG
710 LIBSOUND
711 START_FILES
712 LIB_MATH
713 CRT_DIR
714 LIBS_SYSTEM
715 C_SWITCH_SYSTEM
716 UNEXEC_OBJ
717 C_SWITCH_MACHINE
718 LD_SWITCH_SYSTEM
719 CANNOT_DUMP
720 MAKEINFO
721 GZIP_PROG
722 INSTALL_INFO
723 RANLIB
724 INSTALL_DATA
725 INSTALL_SCRIPT
726 INSTALL_PROGRAM
727 C_WARNINGS_SWITCH
728 EGREP
729 GREP
731 OBJEXT
732 EXEEXT
733 ac_ct_CC
734 CPPFLAGS
735 LDFLAGS
736 CFLAGS
738 host_os
739 host_vendor
740 host_cpu
741 host
742 build_os
743 build_vendor
744 build_cpu
745 build
746 PROFILING_LDFLAGS
747 PROFILING_CFLAGS
748 MAINT
749 GZIP_INFO
750 target_alias
751 host_alias
752 build_alias
753 LIBS
754 ECHO_T
755 ECHO_N
756 ECHO_C
757 DEFS
758 mandir
759 localedir
760 libdir
761 psdir
762 pdfdir
763 dvidir
764 htmldir
765 infodir
766 docdir
767 oldincludedir
768 includedir
769 localstatedir
770 sharedstatedir
771 sysconfdir
772 datadir
773 datarootdir
774 libexecdir
775 sbindir
776 bindir
777 program_transform_name
778 prefix
779 exec_prefix
780 PACKAGE_URL
781 PACKAGE_BUGREPORT
782 PACKAGE_STRING
783 PACKAGE_VERSION
784 PACKAGE_TARNAME
785 PACKAGE_NAME
786 PATH_SEPARATOR
787 SHELL'
788 ac_subst_files='deps_frag
789 ns_frag'
790 ac_user_opts='
791 enable_option_checking
792 with_pop
793 with_kerberos
794 with_kerberos5
795 with_hesiod
796 with_mmdf
797 with_mail_unlink
798 with_mailhost
799 with_sound
800 with_sync_input
801 with_x_toolkit
802 with_xpm
803 with_jpeg
804 with_tiff
805 with_gif
806 with_png
807 with_rsvg
808 with_xft
809 with_libotf
810 with_m17n_flt
811 with_toolkit_scroll_bars
812 with_xaw3d
813 with_xim
814 with_ns
815 with_gpm
816 with_dbus
817 with_gconf
818 with_selinux
819 with_makeinfo
820 with_compress_info
821 with_pkg_config_prog
822 with_crt_dir
823 with_gnustep_conf
824 enable_ns_self_contained
825 enable_asserts
826 enable_maintainer_mode
827 enable_locallisppath
828 enable_checking
829 enable_use_lisp_union_type
830 enable_profiling
831 enable_autodepend
832 enable_largefile
833 with_x
835 ac_precious_vars='build_alias
836 host_alias
837 target_alias
839 CFLAGS
840 LDFLAGS
841 LIBS
842 CPPFLAGS
844 XMKMF'
847 # Initialize some variables set by options.
848 ac_init_help=
849 ac_init_version=false
850 ac_unrecognized_opts=
851 ac_unrecognized_sep=
852 # The variables have the same names as the options, with
853 # dashes changed to underlines.
854 cache_file=/dev/null
855 exec_prefix=NONE
856 no_create=
857 no_recursion=
858 prefix=NONE
859 program_prefix=NONE
860 program_suffix=NONE
861 program_transform_name=s,x,x,
862 silent=
863 site=
864 srcdir=
865 verbose=
866 x_includes=NONE
867 x_libraries=NONE
869 # Installation directory options.
870 # These are left unexpanded so users can "make install exec_prefix=/foo"
871 # and all the variables that are supposed to be based on exec_prefix
872 # by default will actually change.
873 # Use braces instead of parens because sh, perl, etc. also accept them.
874 # (The list follows the same order as the GNU Coding Standards.)
875 bindir='${exec_prefix}/bin'
876 sbindir='${exec_prefix}/sbin'
877 libexecdir='${exec_prefix}/libexec'
878 datarootdir='${prefix}/share'
879 datadir='${datarootdir}'
880 sysconfdir='${prefix}/etc'
881 sharedstatedir='${prefix}/com'
882 localstatedir='${prefix}/var'
883 includedir='${prefix}/include'
884 oldincludedir='/usr/include'
885 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
886 infodir='${datarootdir}/info'
887 htmldir='${docdir}'
888 dvidir='${docdir}'
889 pdfdir='${docdir}'
890 psdir='${docdir}'
891 libdir='${exec_prefix}/lib'
892 localedir='${datarootdir}/locale'
893 mandir='${datarootdir}/man'
895 ac_prev=
896 ac_dashdash=
897 for ac_option
899 # If the previous option needs an argument, assign it.
900 if test -n "$ac_prev"; then
901 eval $ac_prev=\$ac_option
902 ac_prev=
903 continue
906 case $ac_option in
907 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
908 *) ac_optarg=yes ;;
909 esac
911 # Accept the important Cygnus configure options, so we can diagnose typos.
913 case $ac_dashdash$ac_option in
915 ac_dashdash=yes ;;
917 -bindir | --bindir | --bindi | --bind | --bin | --bi)
918 ac_prev=bindir ;;
919 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
920 bindir=$ac_optarg ;;
922 -build | --build | --buil | --bui | --bu)
923 ac_prev=build_alias ;;
924 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
925 build_alias=$ac_optarg ;;
927 -cache-file | --cache-file | --cache-fil | --cache-fi \
928 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
929 ac_prev=cache_file ;;
930 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
931 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
932 cache_file=$ac_optarg ;;
934 --config-cache | -C)
935 cache_file=config.cache ;;
937 -datadir | --datadir | --datadi | --datad)
938 ac_prev=datadir ;;
939 -datadir=* | --datadir=* | --datadi=* | --datad=*)
940 datadir=$ac_optarg ;;
942 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
943 | --dataroo | --dataro | --datar)
944 ac_prev=datarootdir ;;
945 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
946 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
947 datarootdir=$ac_optarg ;;
949 -disable-* | --disable-*)
950 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
951 # Reject names that are not valid shell variable names.
952 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
953 as_fn_error "invalid feature name: $ac_useropt"
954 ac_useropt_orig=$ac_useropt
955 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
956 case $ac_user_opts in
958 "enable_$ac_useropt"
959 "*) ;;
960 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
961 ac_unrecognized_sep=', ';;
962 esac
963 eval enable_$ac_useropt=no ;;
965 -docdir | --docdir | --docdi | --doc | --do)
966 ac_prev=docdir ;;
967 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
968 docdir=$ac_optarg ;;
970 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
971 ac_prev=dvidir ;;
972 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
973 dvidir=$ac_optarg ;;
975 -enable-* | --enable-*)
976 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
977 # Reject names that are not valid shell variable names.
978 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
979 as_fn_error "invalid feature name: $ac_useropt"
980 ac_useropt_orig=$ac_useropt
981 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
982 case $ac_user_opts in
984 "enable_$ac_useropt"
985 "*) ;;
986 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
987 ac_unrecognized_sep=', ';;
988 esac
989 eval enable_$ac_useropt=\$ac_optarg ;;
991 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
992 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
993 | --exec | --exe | --ex)
994 ac_prev=exec_prefix ;;
995 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
996 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
997 | --exec=* | --exe=* | --ex=*)
998 exec_prefix=$ac_optarg ;;
1000 -gas | --gas | --ga | --g)
1001 # Obsolete; use --with-gas.
1002 with_gas=yes ;;
1004 -help | --help | --hel | --he | -h)
1005 ac_init_help=long ;;
1006 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1007 ac_init_help=recursive ;;
1008 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1009 ac_init_help=short ;;
1011 -host | --host | --hos | --ho)
1012 ac_prev=host_alias ;;
1013 -host=* | --host=* | --hos=* | --ho=*)
1014 host_alias=$ac_optarg ;;
1016 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1017 ac_prev=htmldir ;;
1018 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1019 | --ht=*)
1020 htmldir=$ac_optarg ;;
1022 -includedir | --includedir | --includedi | --included | --include \
1023 | --includ | --inclu | --incl | --inc)
1024 ac_prev=includedir ;;
1025 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1026 | --includ=* | --inclu=* | --incl=* | --inc=*)
1027 includedir=$ac_optarg ;;
1029 -infodir | --infodir | --infodi | --infod | --info | --inf)
1030 ac_prev=infodir ;;
1031 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1032 infodir=$ac_optarg ;;
1034 -libdir | --libdir | --libdi | --libd)
1035 ac_prev=libdir ;;
1036 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1037 libdir=$ac_optarg ;;
1039 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1040 | --libexe | --libex | --libe)
1041 ac_prev=libexecdir ;;
1042 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1043 | --libexe=* | --libex=* | --libe=*)
1044 libexecdir=$ac_optarg ;;
1046 -localedir | --localedir | --localedi | --localed | --locale)
1047 ac_prev=localedir ;;
1048 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1049 localedir=$ac_optarg ;;
1051 -localstatedir | --localstatedir | --localstatedi | --localstated \
1052 | --localstate | --localstat | --localsta | --localst | --locals)
1053 ac_prev=localstatedir ;;
1054 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1055 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1056 localstatedir=$ac_optarg ;;
1058 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1059 ac_prev=mandir ;;
1060 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1061 mandir=$ac_optarg ;;
1063 -nfp | --nfp | --nf)
1064 # Obsolete; use --without-fp.
1065 with_fp=no ;;
1067 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1068 | --no-cr | --no-c | -n)
1069 no_create=yes ;;
1071 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1072 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1073 no_recursion=yes ;;
1075 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1076 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1077 | --oldin | --oldi | --old | --ol | --o)
1078 ac_prev=oldincludedir ;;
1079 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1080 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1081 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1082 oldincludedir=$ac_optarg ;;
1084 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1085 ac_prev=prefix ;;
1086 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1087 prefix=$ac_optarg ;;
1089 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1090 | --program-pre | --program-pr | --program-p)
1091 ac_prev=program_prefix ;;
1092 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1093 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1094 program_prefix=$ac_optarg ;;
1096 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1097 | --program-suf | --program-su | --program-s)
1098 ac_prev=program_suffix ;;
1099 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1100 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1101 program_suffix=$ac_optarg ;;
1103 -program-transform-name | --program-transform-name \
1104 | --program-transform-nam | --program-transform-na \
1105 | --program-transform-n | --program-transform- \
1106 | --program-transform | --program-transfor \
1107 | --program-transfo | --program-transf \
1108 | --program-trans | --program-tran \
1109 | --progr-tra | --program-tr | --program-t)
1110 ac_prev=program_transform_name ;;
1111 -program-transform-name=* | --program-transform-name=* \
1112 | --program-transform-nam=* | --program-transform-na=* \
1113 | --program-transform-n=* | --program-transform-=* \
1114 | --program-transform=* | --program-transfor=* \
1115 | --program-transfo=* | --program-transf=* \
1116 | --program-trans=* | --program-tran=* \
1117 | --progr-tra=* | --program-tr=* | --program-t=*)
1118 program_transform_name=$ac_optarg ;;
1120 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1121 ac_prev=pdfdir ;;
1122 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1123 pdfdir=$ac_optarg ;;
1125 -psdir | --psdir | --psdi | --psd | --ps)
1126 ac_prev=psdir ;;
1127 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1128 psdir=$ac_optarg ;;
1130 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1131 | -silent | --silent | --silen | --sile | --sil)
1132 silent=yes ;;
1134 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1135 ac_prev=sbindir ;;
1136 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1137 | --sbi=* | --sb=*)
1138 sbindir=$ac_optarg ;;
1140 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1141 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1142 | --sharedst | --shareds | --shared | --share | --shar \
1143 | --sha | --sh)
1144 ac_prev=sharedstatedir ;;
1145 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1146 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1147 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1148 | --sha=* | --sh=*)
1149 sharedstatedir=$ac_optarg ;;
1151 -site | --site | --sit)
1152 ac_prev=site ;;
1153 -site=* | --site=* | --sit=*)
1154 site=$ac_optarg ;;
1156 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1157 ac_prev=srcdir ;;
1158 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1159 srcdir=$ac_optarg ;;
1161 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1162 | --syscon | --sysco | --sysc | --sys | --sy)
1163 ac_prev=sysconfdir ;;
1164 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1165 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1166 sysconfdir=$ac_optarg ;;
1168 -target | --target | --targe | --targ | --tar | --ta | --t)
1169 ac_prev=target_alias ;;
1170 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1171 target_alias=$ac_optarg ;;
1173 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1174 verbose=yes ;;
1176 -version | --version | --versio | --versi | --vers | -V)
1177 ac_init_version=: ;;
1179 -with-* | --with-*)
1180 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1181 # Reject names that are not valid shell variable names.
1182 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1183 as_fn_error "invalid package name: $ac_useropt"
1184 ac_useropt_orig=$ac_useropt
1185 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1186 case $ac_user_opts in
1188 "with_$ac_useropt"
1189 "*) ;;
1190 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1191 ac_unrecognized_sep=', ';;
1192 esac
1193 eval with_$ac_useropt=\$ac_optarg ;;
1195 -without-* | --without-*)
1196 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1197 # Reject names that are not valid shell variable names.
1198 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1199 as_fn_error "invalid package name: $ac_useropt"
1200 ac_useropt_orig=$ac_useropt
1201 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1202 case $ac_user_opts in
1204 "with_$ac_useropt"
1205 "*) ;;
1206 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1207 ac_unrecognized_sep=', ';;
1208 esac
1209 eval with_$ac_useropt=no ;;
1211 --x)
1212 # Obsolete; use --with-x.
1213 with_x=yes ;;
1215 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1216 | --x-incl | --x-inc | --x-in | --x-i)
1217 ac_prev=x_includes ;;
1218 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1219 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1220 x_includes=$ac_optarg ;;
1222 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1223 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1224 ac_prev=x_libraries ;;
1225 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1226 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1227 x_libraries=$ac_optarg ;;
1229 -*) as_fn_error "unrecognized option: \`$ac_option'
1230 Try \`$0 --help' for more information."
1233 *=*)
1234 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1235 # Reject names that are not valid shell variable names.
1236 case $ac_envvar in #(
1237 '' | [0-9]* | *[!_$as_cr_alnum]* )
1238 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1239 esac
1240 eval $ac_envvar=\$ac_optarg
1241 export $ac_envvar ;;
1244 # FIXME: should be removed in autoconf 3.0.
1245 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1246 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1247 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1248 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1251 esac
1252 done
1254 if test -n "$ac_prev"; then
1255 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1256 as_fn_error "missing argument to $ac_option"
1259 if test -n "$ac_unrecognized_opts"; then
1260 case $enable_option_checking in
1261 no) ;;
1262 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1263 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1264 esac
1267 # Check all directory arguments for consistency.
1268 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1269 datadir sysconfdir sharedstatedir localstatedir includedir \
1270 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1271 libdir localedir mandir
1273 eval ac_val=\$$ac_var
1274 # Remove trailing slashes.
1275 case $ac_val in
1276 */ )
1277 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1278 eval $ac_var=\$ac_val;;
1279 esac
1280 # Be sure to have absolute directory names.
1281 case $ac_val in
1282 [\\/$]* | ?:[\\/]* ) continue;;
1283 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1284 esac
1285 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
1286 done
1288 # There might be people who depend on the old broken behavior: `$host'
1289 # used to hold the argument of --host etc.
1290 # FIXME: To remove some day.
1291 build=$build_alias
1292 host=$host_alias
1293 target=$target_alias
1295 # FIXME: To remove some day.
1296 if test "x$host_alias" != x; then
1297 if test "x$build_alias" = x; then
1298 cross_compiling=maybe
1299 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1300 If a cross compiler is detected then cross compile mode will be used." >&2
1301 elif test "x$build_alias" != "x$host_alias"; then
1302 cross_compiling=yes
1306 ac_tool_prefix=
1307 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1309 test "$silent" = yes && exec 6>/dev/null
1312 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1313 ac_ls_di=`ls -di .` &&
1314 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1315 as_fn_error "working directory cannot be determined"
1316 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1317 as_fn_error "pwd does not report name of working directory"
1320 # Find the source files, if location was not specified.
1321 if test -z "$srcdir"; then
1322 ac_srcdir_defaulted=yes
1323 # Try the directory containing this script, then the parent directory.
1324 ac_confdir=`$as_dirname -- "$as_myself" ||
1325 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1326 X"$as_myself" : 'X\(//\)[^/]' \| \
1327 X"$as_myself" : 'X\(//\)$' \| \
1328 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1329 $as_echo X"$as_myself" |
1330 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1331 s//\1/
1334 /^X\(\/\/\)[^/].*/{
1335 s//\1/
1338 /^X\(\/\/\)$/{
1339 s//\1/
1342 /^X\(\/\).*/{
1343 s//\1/
1346 s/.*/./; q'`
1347 srcdir=$ac_confdir
1348 if test ! -r "$srcdir/$ac_unique_file"; then
1349 srcdir=..
1351 else
1352 ac_srcdir_defaulted=no
1354 if test ! -r "$srcdir/$ac_unique_file"; then
1355 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1356 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1358 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1359 ac_abs_confdir=`(
1360 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1361 pwd)`
1362 # When building in place, set srcdir=.
1363 if test "$ac_abs_confdir" = "$ac_pwd"; then
1364 srcdir=.
1366 # Remove unnecessary trailing slashes from srcdir.
1367 # Double slashes in file names in object file debugging info
1368 # mess up M-x gdb in Emacs.
1369 case $srcdir in
1370 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1371 esac
1372 for ac_var in $ac_precious_vars; do
1373 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1374 eval ac_env_${ac_var}_value=\$${ac_var}
1375 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1376 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1377 done
1380 # Report the --help message.
1382 if test "$ac_init_help" = "long"; then
1383 # Omit some internal or obsolete options to make the list less imposing.
1384 # This message is too long to be a string in the A/UX 3.1 sh.
1385 cat <<_ACEOF
1386 \`configure' configures emacs 24.0.50 to adapt to many kinds of systems.
1388 Usage: $0 [OPTION]... [VAR=VALUE]...
1390 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1391 VAR=VALUE. See below for descriptions of some of the useful variables.
1393 Defaults for the options are specified in brackets.
1395 Configuration:
1396 -h, --help display this help and exit
1397 --help=short display options specific to this package
1398 --help=recursive display the short help of all the included packages
1399 -V, --version display version information and exit
1400 -q, --quiet, --silent do not print \`checking...' messages
1401 --cache-file=FILE cache test results in FILE [disabled]
1402 -C, --config-cache alias for \`--cache-file=config.cache'
1403 -n, --no-create do not create output files
1404 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1406 Installation directories:
1407 --prefix=PREFIX install architecture-independent files in PREFIX
1408 [$ac_default_prefix]
1409 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1410 [PREFIX]
1412 By default, \`make install' will install all the files in
1413 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1414 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1415 for instance \`--prefix=\$HOME'.
1417 For better control, use the options below.
1419 Fine tuning of the installation directories:
1420 --bindir=DIR user executables [EPREFIX/bin]
1421 --sbindir=DIR system admin executables [EPREFIX/sbin]
1422 --libexecdir=DIR program executables [EPREFIX/libexec]
1423 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1424 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1425 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1426 --libdir=DIR object code libraries [EPREFIX/lib]
1427 --includedir=DIR C header files [PREFIX/include]
1428 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1429 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1430 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1431 --infodir=DIR info documentation [DATAROOTDIR/info]
1432 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1433 --mandir=DIR man documentation [DATAROOTDIR/man]
1434 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
1435 --htmldir=DIR html documentation [DOCDIR]
1436 --dvidir=DIR dvi documentation [DOCDIR]
1437 --pdfdir=DIR pdf documentation [DOCDIR]
1438 --psdir=DIR ps documentation [DOCDIR]
1439 _ACEOF
1441 cat <<\_ACEOF
1443 Program names:
1444 --program-prefix=PREFIX prepend PREFIX to installed program names
1445 --program-suffix=SUFFIX append SUFFIX to installed program names
1446 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1448 X features:
1449 --x-includes=DIR X include files are in DIR
1450 --x-libraries=DIR X library files are in DIR
1452 System types:
1453 --build=BUILD configure for building on BUILD [guessed]
1454 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1455 _ACEOF
1458 if test -n "$ac_init_help"; then
1459 case $ac_init_help in
1460 short | recursive ) echo "Configuration of emacs 24.0.50:";;
1461 esac
1462 cat <<\_ACEOF
1464 Optional Features:
1465 --disable-option-checking ignore unrecognized --enable/--with options
1466 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1467 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1468 --disable-ns-self-contained
1469 disable self contained build under NeXTstep
1470 --enable-asserts compile code with asserts enabled
1471 --enable-maintainer-mode
1472 enable make rules and dependencies not useful (and
1473 sometimes confusing) to the casual installer
1474 --enable-locallisppath=PATH
1475 directories Emacs should search for lisp files
1476 specific to this site
1477 --enable-checking[=LIST]
1478 enable expensive run-time checks. With LIST, enable
1479 only specific categories of checks. Categories are:
1480 all,yes,no. Flags are: stringbytes, stringoverrun,
1481 stringfreelist, xmallocoverrun, conslist
1482 --enable-use-lisp-union-type
1483 use a union for the Lisp_Object data type. This is
1484 only useful for development for catching certain
1485 types of bugs.
1486 --enable-profiling build emacs with profiling support. This might not
1487 work on all platforms
1488 --enable-autodepend automatically generate dependencies to .h-files.
1489 Requires GNU Make and Gcc. Enabled if GNU Make and
1490 Gcc is found
1491 --disable-largefile omit support for large files
1493 Optional Packages:
1494 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1495 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1496 --without-pop don't support POP mail retrieval with movemail
1497 --with-kerberos support Kerberos-authenticated POP
1498 --with-kerberos5 support Kerberos version 5 authenticated POP
1499 --with-hesiod support Hesiod to get the POP server host
1500 --with-mmdf support MMDF mailboxes
1501 --with-mail-unlink unlink, rather than empty, mail spool after reading
1502 --with-mailhost=HOSTNAME
1503 string giving default POP mail host
1504 --without-sound don't compile with sound support
1505 --without-sync-input process async input synchronously
1506 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk3,
1507 lucid or athena, motif, no)
1508 --without-xpm don't compile with XPM image support
1509 --without-jpeg don't compile with JPEG image support
1510 --without-tiff don't compile with TIFF image support
1511 --without-gif don't compile with GIF image support
1512 --without-png don't compile with PNG image support
1513 --without-rsvg don't compile with SVG image support
1514 --without-xft don't use XFT for anti aliased fonts
1515 --without-libotf don't use libotf for OpenType font support
1516 --without-m17n-flt don't use m17n-flt for text shaping
1517 --without-toolkit-scroll-bars
1518 don't use Motif or Xaw3d scroll bars
1519 --without-xaw3d don't use Xaw3d
1520 --without-xim don't use X11 XIM
1521 --with-ns use nextstep (Cocoa or GNUstep) windowing system
1522 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
1523 console
1524 --without-dbus don't compile with D-Bus support
1525 --without-gconf don't compile with GConf support
1526 --without-selinux don't compile with SELinux support
1527 --without-makeinfo don't require makeinfo for building manuals
1528 --without-compress-info don't compress the installed Info pages
1529 --with-pkg-config-prog=PATH
1530 path to pkg-config for finding GTK and librsvg
1531 --with-crt-dir=DIR directory containing crtn.o etc. The default is
1532 /usr/lib, or /usr/lib64 on some platforms.
1533 --with-gnustep-conf=PATH
1534 path to GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
1535 or /etc/GNUstep/GNUstep.conf
1536 --with-x use the X Window System
1538 Some influential environment variables:
1539 CC C compiler command
1540 CFLAGS C compiler flags
1541 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1542 nonstandard directory <lib dir>
1543 LIBS libraries to pass to the linker, e.g. -l<library>
1544 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1545 you have headers in a nonstandard directory <include dir>
1546 CPP C preprocessor
1547 XMKMF Path to xmkmf, Makefile generator for X Window System
1549 Use these variables to override the choices made by `configure' or to help
1550 it to find libraries and programs with nonstandard names/locations.
1552 Report bugs to the package provider.
1553 _ACEOF
1554 ac_status=$?
1557 if test "$ac_init_help" = "recursive"; then
1558 # If there are subdirs, report their specific --help.
1559 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1560 test -d "$ac_dir" ||
1561 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1562 continue
1563 ac_builddir=.
1565 case "$ac_dir" in
1566 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1568 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1569 # A ".." for each directory in $ac_dir_suffix.
1570 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1571 case $ac_top_builddir_sub in
1572 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1573 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1574 esac ;;
1575 esac
1576 ac_abs_top_builddir=$ac_pwd
1577 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1578 # for backward compatibility:
1579 ac_top_builddir=$ac_top_build_prefix
1581 case $srcdir in
1582 .) # We are building in place.
1583 ac_srcdir=.
1584 ac_top_srcdir=$ac_top_builddir_sub
1585 ac_abs_top_srcdir=$ac_pwd ;;
1586 [\\/]* | ?:[\\/]* ) # Absolute name.
1587 ac_srcdir=$srcdir$ac_dir_suffix;
1588 ac_top_srcdir=$srcdir
1589 ac_abs_top_srcdir=$srcdir ;;
1590 *) # Relative name.
1591 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1592 ac_top_srcdir=$ac_top_build_prefix$srcdir
1593 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1594 esac
1595 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1597 cd "$ac_dir" || { ac_status=$?; continue; }
1598 # Check for guested configure.
1599 if test -f "$ac_srcdir/configure.gnu"; then
1600 echo &&
1601 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1602 elif test -f "$ac_srcdir/configure"; then
1603 echo &&
1604 $SHELL "$ac_srcdir/configure" --help=recursive
1605 else
1606 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1607 fi || ac_status=$?
1608 cd "$ac_pwd" || { ac_status=$?; break; }
1609 done
1612 test -n "$ac_init_help" && exit $ac_status
1613 if $ac_init_version; then
1614 cat <<\_ACEOF
1615 emacs configure 24.0.50
1616 generated by GNU Autoconf 2.65
1618 Copyright (C) 2009 Free Software Foundation, Inc.
1619 This configure script is free software; the Free Software Foundation
1620 gives unlimited permission to copy, distribute and modify it.
1621 _ACEOF
1622 exit
1625 ## ------------------------ ##
1626 ## Autoconf initialization. ##
1627 ## ------------------------ ##
1629 # ac_fn_c_try_compile LINENO
1630 # --------------------------
1631 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1632 ac_fn_c_try_compile ()
1634 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1635 rm -f conftest.$ac_objext
1636 if { { ac_try="$ac_compile"
1637 case "(($ac_try" in
1638 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1639 *) ac_try_echo=$ac_try;;
1640 esac
1641 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1642 $as_echo "$ac_try_echo"; } >&5
1643 (eval "$ac_compile") 2>conftest.err
1644 ac_status=$?
1645 if test -s conftest.err; then
1646 grep -v '^ *+' conftest.err >conftest.er1
1647 cat conftest.er1 >&5
1648 mv -f conftest.er1 conftest.err
1650 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1651 test $ac_status = 0; } && {
1652 test -z "$ac_c_werror_flag" ||
1653 test ! -s conftest.err
1654 } && test -s conftest.$ac_objext; then :
1655 ac_retval=0
1656 else
1657 $as_echo "$as_me: failed program was:" >&5
1658 sed 's/^/| /' conftest.$ac_ext >&5
1660 ac_retval=1
1662 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1663 as_fn_set_status $ac_retval
1665 } # ac_fn_c_try_compile
1667 # ac_fn_c_try_link LINENO
1668 # -----------------------
1669 # Try to link conftest.$ac_ext, and return whether this succeeded.
1670 ac_fn_c_try_link ()
1672 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1673 rm -f conftest.$ac_objext conftest$ac_exeext
1674 if { { ac_try="$ac_link"
1675 case "(($ac_try" in
1676 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1677 *) ac_try_echo=$ac_try;;
1678 esac
1679 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1680 $as_echo "$ac_try_echo"; } >&5
1681 (eval "$ac_link") 2>conftest.err
1682 ac_status=$?
1683 if test -s conftest.err; then
1684 grep -v '^ *+' conftest.err >conftest.er1
1685 cat conftest.er1 >&5
1686 mv -f conftest.er1 conftest.err
1688 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1689 test $ac_status = 0; } && {
1690 test -z "$ac_c_werror_flag" ||
1691 test ! -s conftest.err
1692 } && test -s conftest$ac_exeext && {
1693 test "$cross_compiling" = yes ||
1694 $as_test_x conftest$ac_exeext
1695 }; then :
1696 ac_retval=0
1697 else
1698 $as_echo "$as_me: failed program was:" >&5
1699 sed 's/^/| /' conftest.$ac_ext >&5
1701 ac_retval=1
1703 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1704 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1705 # interfere with the next link command; also delete a directory that is
1706 # left behind by Apple's compiler. We do this before executing the actions.
1707 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1708 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1709 as_fn_set_status $ac_retval
1711 } # ac_fn_c_try_link
1713 # ac_fn_c_try_cpp LINENO
1714 # ----------------------
1715 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1716 ac_fn_c_try_cpp ()
1718 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1719 if { { ac_try="$ac_cpp conftest.$ac_ext"
1720 case "(($ac_try" in
1721 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1722 *) ac_try_echo=$ac_try;;
1723 esac
1724 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1725 $as_echo "$ac_try_echo"; } >&5
1726 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1727 ac_status=$?
1728 if test -s conftest.err; then
1729 grep -v '^ *+' conftest.err >conftest.er1
1730 cat conftest.er1 >&5
1731 mv -f conftest.er1 conftest.err
1733 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1734 test $ac_status = 0; } >/dev/null && {
1735 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1736 test ! -s conftest.err
1737 }; then :
1738 ac_retval=0
1739 else
1740 $as_echo "$as_me: failed program was:" >&5
1741 sed 's/^/| /' conftest.$ac_ext >&5
1743 ac_retval=1
1745 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1746 as_fn_set_status $ac_retval
1748 } # ac_fn_c_try_cpp
1750 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1751 # -------------------------------------------------------
1752 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1753 # the include files in INCLUDES and setting the cache variable VAR
1754 # accordingly.
1755 ac_fn_c_check_header_mongrel ()
1757 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1758 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1760 $as_echo_n "checking for $2... " >&6; }
1761 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1762 $as_echo_n "(cached) " >&6
1764 eval ac_res=\$$3
1765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1766 $as_echo "$ac_res" >&6; }
1767 else
1768 # Is the header compilable?
1769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1770 $as_echo_n "checking $2 usability... " >&6; }
1771 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1772 /* end confdefs.h. */
1774 #include <$2>
1775 _ACEOF
1776 if ac_fn_c_try_compile "$LINENO"; then :
1777 ac_header_compiler=yes
1778 else
1779 ac_header_compiler=no
1781 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1783 $as_echo "$ac_header_compiler" >&6; }
1785 # Is the header present?
1786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1787 $as_echo_n "checking $2 presence... " >&6; }
1788 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1789 /* end confdefs.h. */
1790 #include <$2>
1791 _ACEOF
1792 if ac_fn_c_try_cpp "$LINENO"; then :
1793 ac_header_preproc=yes
1794 else
1795 ac_header_preproc=no
1797 rm -f conftest.err conftest.$ac_ext
1798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1799 $as_echo "$ac_header_preproc" >&6; }
1801 # So? What about this header?
1802 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1803 yes:no: )
1804 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1805 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1806 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1807 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1809 no:yes:* )
1810 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1811 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1812 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
1813 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
1814 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1815 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1816 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
1817 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
1818 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1819 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1821 esac
1822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1823 $as_echo_n "checking for $2... " >&6; }
1824 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1825 $as_echo_n "(cached) " >&6
1826 else
1827 eval "$3=\$ac_header_compiler"
1829 eval ac_res=\$$3
1830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1831 $as_echo "$ac_res" >&6; }
1833 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1835 } # ac_fn_c_check_header_mongrel
1837 # ac_fn_c_try_run LINENO
1838 # ----------------------
1839 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1840 # that executables *can* be run.
1841 ac_fn_c_try_run ()
1843 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1844 if { { ac_try="$ac_link"
1845 case "(($ac_try" in
1846 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1847 *) ac_try_echo=$ac_try;;
1848 esac
1849 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1850 $as_echo "$ac_try_echo"; } >&5
1851 (eval "$ac_link") 2>&5
1852 ac_status=$?
1853 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1854 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1855 { { case "(($ac_try" in
1856 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1857 *) ac_try_echo=$ac_try;;
1858 esac
1859 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1860 $as_echo "$ac_try_echo"; } >&5
1861 (eval "$ac_try") 2>&5
1862 ac_status=$?
1863 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1864 test $ac_status = 0; }; }; then :
1865 ac_retval=0
1866 else
1867 $as_echo "$as_me: program exited with status $ac_status" >&5
1868 $as_echo "$as_me: failed program was:" >&5
1869 sed 's/^/| /' conftest.$ac_ext >&5
1871 ac_retval=$ac_status
1873 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1874 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1875 as_fn_set_status $ac_retval
1877 } # ac_fn_c_try_run
1879 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1880 # -------------------------------------------------------
1881 # Tests whether HEADER exists and can be compiled using the include files in
1882 # INCLUDES, setting the cache variable VAR accordingly.
1883 ac_fn_c_check_header_compile ()
1885 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1887 $as_echo_n "checking for $2... " >&6; }
1888 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1889 $as_echo_n "(cached) " >&6
1890 else
1891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1892 /* end confdefs.h. */
1894 #include <$2>
1895 _ACEOF
1896 if ac_fn_c_try_compile "$LINENO"; then :
1897 eval "$3=yes"
1898 else
1899 eval "$3=no"
1901 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1903 eval ac_res=\$$3
1904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1905 $as_echo "$ac_res" >&6; }
1906 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1908 } # ac_fn_c_check_header_compile
1910 # ac_fn_c_check_decl LINENO SYMBOL VAR
1911 # ------------------------------------
1912 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
1913 ac_fn_c_check_decl ()
1915 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
1917 $as_echo_n "checking whether $2 is declared... " >&6; }
1918 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1919 $as_echo_n "(cached) " >&6
1920 else
1921 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1922 /* end confdefs.h. */
1925 main ()
1927 #ifndef $2
1928 (void) $2;
1929 #endif
1932 return 0;
1934 _ACEOF
1935 if ac_fn_c_try_compile "$LINENO"; then :
1936 eval "$3=yes"
1937 else
1938 eval "$3=no"
1940 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1942 eval ac_res=\$$3
1943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1944 $as_echo "$ac_res" >&6; }
1945 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1947 } # ac_fn_c_check_decl
1949 # ac_fn_c_check_header_preproc LINENO HEADER VAR
1950 # ----------------------------------------------
1951 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
1952 ac_fn_c_check_header_preproc ()
1954 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1956 $as_echo_n "checking for $2... " >&6; }
1957 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1958 $as_echo_n "(cached) " >&6
1959 else
1960 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1961 /* end confdefs.h. */
1962 #include <$2>
1963 _ACEOF
1964 if ac_fn_c_try_cpp "$LINENO"; then :
1965 eval "$3=yes"
1966 else
1967 eval "$3=no"
1969 rm -f conftest.err conftest.$ac_ext
1971 eval ac_res=\$$3
1972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1973 $as_echo "$ac_res" >&6; }
1974 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1976 } # ac_fn_c_check_header_preproc
1978 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
1979 # ----------------------------------------------------
1980 # Tries to find if the field MEMBER exists in type AGGR, after including
1981 # INCLUDES, setting cache variable VAR accordingly.
1982 ac_fn_c_check_member ()
1984 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
1986 $as_echo_n "checking for $2.$3... " >&6; }
1987 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
1988 $as_echo_n "(cached) " >&6
1989 else
1990 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1991 /* end confdefs.h. */
1994 main ()
1996 static $2 ac_aggr;
1997 if (ac_aggr.$3)
1998 return 0;
2000 return 0;
2002 _ACEOF
2003 if ac_fn_c_try_compile "$LINENO"; then :
2004 eval "$4=yes"
2005 else
2006 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2007 /* end confdefs.h. */
2010 main ()
2012 static $2 ac_aggr;
2013 if (sizeof ac_aggr.$3)
2014 return 0;
2016 return 0;
2018 _ACEOF
2019 if ac_fn_c_try_compile "$LINENO"; then :
2020 eval "$4=yes"
2021 else
2022 eval "$4=no"
2024 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2026 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2028 eval ac_res=\$$4
2029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2030 $as_echo "$ac_res" >&6; }
2031 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2033 } # ac_fn_c_check_member
2035 # ac_fn_c_check_func LINENO FUNC VAR
2036 # ----------------------------------
2037 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2038 ac_fn_c_check_func ()
2040 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2041 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2042 $as_echo_n "checking for $2... " >&6; }
2043 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2044 $as_echo_n "(cached) " >&6
2045 else
2046 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2047 /* end confdefs.h. */
2048 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2049 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2050 #define $2 innocuous_$2
2052 /* System header to define __stub macros and hopefully few prototypes,
2053 which can conflict with char $2 (); below.
2054 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2055 <limits.h> exists even on freestanding compilers. */
2057 #ifdef __STDC__
2058 # include <limits.h>
2059 #else
2060 # include <assert.h>
2061 #endif
2063 #undef $2
2065 /* Override any GCC internal prototype to avoid an error.
2066 Use char because int might match the return type of a GCC
2067 builtin and then its argument prototype would still apply. */
2068 #ifdef __cplusplus
2069 extern "C"
2070 #endif
2071 char $2 ();
2072 /* The GNU C library defines this for functions which it implements
2073 to always fail with ENOSYS. Some functions are actually named
2074 something starting with __ and the normal name is an alias. */
2075 #if defined __stub_$2 || defined __stub___$2
2076 choke me
2077 #endif
2080 main ()
2082 return $2 ();
2084 return 0;
2086 _ACEOF
2087 if ac_fn_c_try_link "$LINENO"; then :
2088 eval "$3=yes"
2089 else
2090 eval "$3=no"
2092 rm -f core conftest.err conftest.$ac_objext \
2093 conftest$ac_exeext conftest.$ac_ext
2095 eval ac_res=\$$3
2096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2097 $as_echo "$ac_res" >&6; }
2098 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2100 } # ac_fn_c_check_func
2102 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2103 # -------------------------------------------
2104 # Tests whether TYPE exists after having included INCLUDES, setting cache
2105 # variable VAR accordingly.
2106 ac_fn_c_check_type ()
2108 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2110 $as_echo_n "checking for $2... " >&6; }
2111 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2112 $as_echo_n "(cached) " >&6
2113 else
2114 eval "$3=no"
2115 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2116 /* end confdefs.h. */
2119 main ()
2121 if (sizeof ($2))
2122 return 0;
2124 return 0;
2126 _ACEOF
2127 if ac_fn_c_try_compile "$LINENO"; then :
2128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2129 /* end confdefs.h. */
2132 main ()
2134 if (sizeof (($2)))
2135 return 0;
2137 return 0;
2139 _ACEOF
2140 if ac_fn_c_try_compile "$LINENO"; then :
2142 else
2143 eval "$3=yes"
2145 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2147 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2149 eval ac_res=\$$3
2150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2151 $as_echo "$ac_res" >&6; }
2152 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2154 } # ac_fn_c_check_type
2155 cat >config.log <<_ACEOF
2156 This file contains any messages produced by compilers while
2157 running configure, to aid debugging if configure makes a mistake.
2159 It was created by emacs $as_me 24.0.50, which was
2160 generated by GNU Autoconf 2.65. Invocation command line was
2162 $ $0 $@
2164 _ACEOF
2165 exec 5>>config.log
2167 cat <<_ASUNAME
2168 ## --------- ##
2169 ## Platform. ##
2170 ## --------- ##
2172 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2173 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2174 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2175 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2176 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2178 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2179 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2181 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2182 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2183 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2184 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2185 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2186 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2187 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2189 _ASUNAME
2191 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2192 for as_dir in $PATH
2194 IFS=$as_save_IFS
2195 test -z "$as_dir" && as_dir=.
2196 $as_echo "PATH: $as_dir"
2197 done
2198 IFS=$as_save_IFS
2200 } >&5
2202 cat >&5 <<_ACEOF
2205 ## ----------- ##
2206 ## Core tests. ##
2207 ## ----------- ##
2209 _ACEOF
2212 # Keep a trace of the command line.
2213 # Strip out --no-create and --no-recursion so they do not pile up.
2214 # Strip out --silent because we don't want to record it for future runs.
2215 # Also quote any args containing shell meta-characters.
2216 # Make two passes to allow for proper duplicate-argument suppression.
2217 ac_configure_args=
2218 ac_configure_args0=
2219 ac_configure_args1=
2220 ac_must_keep_next=false
2221 for ac_pass in 1 2
2223 for ac_arg
2225 case $ac_arg in
2226 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2227 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2228 | -silent | --silent | --silen | --sile | --sil)
2229 continue ;;
2230 *\'*)
2231 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2232 esac
2233 case $ac_pass in
2234 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2236 as_fn_append ac_configure_args1 " '$ac_arg'"
2237 if test $ac_must_keep_next = true; then
2238 ac_must_keep_next=false # Got value, back to normal.
2239 else
2240 case $ac_arg in
2241 *=* | --config-cache | -C | -disable-* | --disable-* \
2242 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2243 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2244 | -with-* | --with-* | -without-* | --without-* | --x)
2245 case "$ac_configure_args0 " in
2246 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2247 esac
2249 -* ) ac_must_keep_next=true ;;
2250 esac
2252 as_fn_append ac_configure_args " '$ac_arg'"
2254 esac
2255 done
2256 done
2257 { ac_configure_args0=; unset ac_configure_args0;}
2258 { ac_configure_args1=; unset ac_configure_args1;}
2260 # When interrupted or exit'd, cleanup temporary files, and complete
2261 # config.log. We remove comments because anyway the quotes in there
2262 # would cause problems or look ugly.
2263 # WARNING: Use '\'' to represent an apostrophe within the trap.
2264 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2265 trap 'exit_status=$?
2266 # Save into config.log some information that might help in debugging.
2268 echo
2270 cat <<\_ASBOX
2271 ## ---------------- ##
2272 ## Cache variables. ##
2273 ## ---------------- ##
2274 _ASBOX
2275 echo
2276 # The following way of writing the cache mishandles newlines in values,
2278 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2279 eval ac_val=\$$ac_var
2280 case $ac_val in #(
2281 *${as_nl}*)
2282 case $ac_var in #(
2283 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2284 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2285 esac
2286 case $ac_var in #(
2287 _ | IFS | as_nl) ;; #(
2288 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2289 *) { eval $ac_var=; unset $ac_var;} ;;
2290 esac ;;
2291 esac
2292 done
2293 (set) 2>&1 |
2294 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2295 *${as_nl}ac_space=\ *)
2296 sed -n \
2297 "s/'\''/'\''\\\\'\'''\''/g;
2298 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2299 ;; #(
2301 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2303 esac |
2304 sort
2306 echo
2308 cat <<\_ASBOX
2309 ## ----------------- ##
2310 ## Output variables. ##
2311 ## ----------------- ##
2312 _ASBOX
2313 echo
2314 for ac_var in $ac_subst_vars
2316 eval ac_val=\$$ac_var
2317 case $ac_val in
2318 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2319 esac
2320 $as_echo "$ac_var='\''$ac_val'\''"
2321 done | sort
2322 echo
2324 if test -n "$ac_subst_files"; then
2325 cat <<\_ASBOX
2326 ## ------------------- ##
2327 ## File substitutions. ##
2328 ## ------------------- ##
2329 _ASBOX
2330 echo
2331 for ac_var in $ac_subst_files
2333 eval ac_val=\$$ac_var
2334 case $ac_val in
2335 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2336 esac
2337 $as_echo "$ac_var='\''$ac_val'\''"
2338 done | sort
2339 echo
2342 if test -s confdefs.h; then
2343 cat <<\_ASBOX
2344 ## ----------- ##
2345 ## confdefs.h. ##
2346 ## ----------- ##
2347 _ASBOX
2348 echo
2349 cat confdefs.h
2350 echo
2352 test "$ac_signal" != 0 &&
2353 $as_echo "$as_me: caught signal $ac_signal"
2354 $as_echo "$as_me: exit $exit_status"
2355 } >&5
2356 rm -f core *.core core.conftest.* &&
2357 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2358 exit $exit_status
2360 for ac_signal in 1 2 13 15; do
2361 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2362 done
2363 ac_signal=0
2365 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2366 rm -f -r conftest* confdefs.h
2368 $as_echo "/* confdefs.h */" > confdefs.h
2370 # Predefined preprocessor variables.
2372 cat >>confdefs.h <<_ACEOF
2373 #define PACKAGE_NAME "$PACKAGE_NAME"
2374 _ACEOF
2376 cat >>confdefs.h <<_ACEOF
2377 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2378 _ACEOF
2380 cat >>confdefs.h <<_ACEOF
2381 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2382 _ACEOF
2384 cat >>confdefs.h <<_ACEOF
2385 #define PACKAGE_STRING "$PACKAGE_STRING"
2386 _ACEOF
2388 cat >>confdefs.h <<_ACEOF
2389 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2390 _ACEOF
2392 cat >>confdefs.h <<_ACEOF
2393 #define PACKAGE_URL "$PACKAGE_URL"
2394 _ACEOF
2397 # Let the site file select an alternate cache file if it wants to.
2398 # Prefer an explicitly selected file to automatically selected ones.
2399 ac_site_file1=NONE
2400 ac_site_file2=NONE
2401 if test -n "$CONFIG_SITE"; then
2402 ac_site_file1=$CONFIG_SITE
2403 elif test "x$prefix" != xNONE; then
2404 ac_site_file1=$prefix/share/config.site
2405 ac_site_file2=$prefix/etc/config.site
2406 else
2407 ac_site_file1=$ac_default_prefix/share/config.site
2408 ac_site_file2=$ac_default_prefix/etc/config.site
2410 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2412 test "x$ac_site_file" = xNONE && continue
2413 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2414 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2415 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2416 sed 's/^/| /' "$ac_site_file" >&5
2417 . "$ac_site_file"
2419 done
2421 if test -r "$cache_file"; then
2422 # Some versions of bash will fail to source /dev/null (special files
2423 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2424 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2425 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2426 $as_echo "$as_me: loading cache $cache_file" >&6;}
2427 case $cache_file in
2428 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2429 *) . "./$cache_file";;
2430 esac
2432 else
2433 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2434 $as_echo "$as_me: creating cache $cache_file" >&6;}
2435 >$cache_file
2438 as_fn_append ac_header_list " stdlib.h"
2439 as_fn_append ac_header_list " unistd.h"
2440 as_fn_append ac_header_list " sys/param.h"
2441 as_fn_append ac_header_list " sys/time.h"
2442 as_fn_append ac_func_list " alarm"
2443 # Check that the precious variables saved in the cache have kept the same
2444 # value.
2445 ac_cache_corrupted=false
2446 for ac_var in $ac_precious_vars; do
2447 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2448 eval ac_new_set=\$ac_env_${ac_var}_set
2449 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2450 eval ac_new_val=\$ac_env_${ac_var}_value
2451 case $ac_old_set,$ac_new_set in
2452 set,)
2453 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2454 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2455 ac_cache_corrupted=: ;;
2456 ,set)
2457 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2458 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2459 ac_cache_corrupted=: ;;
2460 ,);;
2462 if test "x$ac_old_val" != "x$ac_new_val"; then
2463 # differences in whitespace do not lead to failure.
2464 ac_old_val_w=`echo x $ac_old_val`
2465 ac_new_val_w=`echo x $ac_new_val`
2466 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2467 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2468 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2469 ac_cache_corrupted=:
2470 else
2471 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2472 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2473 eval $ac_var=\$ac_old_val
2475 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2476 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2477 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2478 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2479 fi;;
2480 esac
2481 # Pass precious variables to config.status.
2482 if test "$ac_new_set" = set; then
2483 case $ac_new_val in
2484 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2485 *) ac_arg=$ac_var=$ac_new_val ;;
2486 esac
2487 case " $ac_configure_args " in
2488 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2489 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2490 esac
2492 done
2493 if $ac_cache_corrupted; then
2494 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2495 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2496 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2497 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2498 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2500 ## -------------------- ##
2501 ## Main body of script. ##
2502 ## -------------------- ##
2504 ac_ext=c
2505 ac_cpp='$CPP $CPPFLAGS'
2506 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2507 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2508 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2511 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
2515 test "$program_prefix" != NONE &&
2516 program_transform_name="s&^&$program_prefix&;$program_transform_name"
2517 # Use a double $ so make ignores it.
2518 test "$program_suffix" != NONE &&
2519 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
2520 # Double any \ or $.
2521 # By default was `s,x,x', remove it if useless.
2522 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
2523 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
2526 lispdir='${datadir}/emacs/${version}/lisp'
2527 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
2528 '${datadir}/emacs/site-lisp'
2529 lisppath='${locallisppath}:${lispdir}:${datadir}/emacs/${version}/leim'
2530 etcdir='${datadir}/emacs/${version}/etc'
2531 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
2532 docdir='${datadir}/emacs/${version}/etc'
2533 gamedir='${localstatedir}/games/emacs'
2535 gameuser=games
2540 # Check whether --with-pop was given.
2541 if test "${with_pop+set}" = set; then :
2542 withval=$with_pop;
2543 else
2544 with_pop=yes
2547 if test "$with_pop" = yes; then
2548 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
2553 # Check whether --with-kerberos was given.
2554 if test "${with_kerberos+set}" = set; then :
2555 withval=$with_kerberos;
2556 else
2557 with_kerberos=no
2560 if test "$with_kerberos" != no; then
2561 $as_echo "#define KERBEROS 1" >>confdefs.h
2566 # Check whether --with-kerberos5 was given.
2567 if test "${with_kerberos5+set}" = set; then :
2568 withval=$with_kerberos5;
2569 else
2570 with_kerberos5=no
2573 if test "${with_kerberos5}" != no; then
2574 if test "${with_kerberos}" = no; then
2575 with_kerberos=yes
2576 $as_echo "#define KERBEROS 1" >>confdefs.h
2580 $as_echo "#define KERBEROS5 1" >>confdefs.h
2585 # Check whether --with-hesiod was given.
2586 if test "${with_hesiod+set}" = set; then :
2587 withval=$with_hesiod;
2588 else
2589 with_hesiod=no
2592 if test "$with_hesiod" != no; then
2594 $as_echo "#define HESIOD 1" >>confdefs.h
2599 # Check whether --with-mmdf was given.
2600 if test "${with_mmdf+set}" = set; then :
2601 withval=$with_mmdf;
2602 else
2603 with_mmdf=no
2606 if test "$with_mmdf" != no; then
2608 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
2613 # Check whether --with-mail-unlink was given.
2614 if test "${with_mail_unlink+set}" = set; then :
2615 withval=$with_mail_unlink;
2616 else
2617 with_mail_unlink=no
2620 if test "$with_mail_unlink" != no; then
2622 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
2627 # Check whether --with-mailhost was given.
2628 if test "${with_mailhost+set}" = set; then :
2629 withval=$with_mailhost;
2630 cat >>confdefs.h <<_ACEOF
2631 #define MAILHOST "$withval"
2632 _ACEOF
2638 # Check whether --with-sound was given.
2639 if test "${with_sound+set}" = set; then :
2640 withval=$with_sound;
2641 else
2642 with_sound=yes
2647 # Check whether --with-sync-input was given.
2648 if test "${with_sync_input+set}" = set; then :
2649 withval=$with_sync_input;
2650 else
2651 with_sync_input=yes
2654 if test "$with_sync_input" = yes; then
2656 $as_echo "#define SYNC_INPUT 1" >>confdefs.h
2661 # Check whether --with-x-toolkit was given.
2662 if test "${with_x_toolkit+set}" = set; then :
2663 withval=$with_x_toolkit; case "${withval}" in
2664 y | ye | yes ) val=gtk ;;
2665 n | no ) val=no ;;
2666 l | lu | luc | luci | lucid ) val=lucid ;;
2667 a | at | ath | athe | athen | athena ) val=athena ;;
2668 m | mo | mot | moti | motif ) val=motif ;;
2669 g | gt | gtk ) val=gtk ;;
2670 gtk3 ) val=gtk3 ;;
2672 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
2673 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk' or
2674 \`gtk3'. \`yes' and \`gtk' are synonyms. \`athena' and \`lucid' are synonyms." "$LINENO" 5
2676 esac
2677 with_x_toolkit=$val
2683 # Check whether --with-xpm was given.
2684 if test "${with_xpm+set}" = set; then :
2685 withval=$with_xpm;
2686 else
2687 with_xpm=yes
2691 # Check whether --with-jpeg was given.
2692 if test "${with_jpeg+set}" = set; then :
2693 withval=$with_jpeg;
2694 else
2695 with_jpeg=yes
2699 # Check whether --with-tiff was given.
2700 if test "${with_tiff+set}" = set; then :
2701 withval=$with_tiff;
2702 else
2703 with_tiff=yes
2707 # Check whether --with-gif was given.
2708 if test "${with_gif+set}" = set; then :
2709 withval=$with_gif;
2710 else
2711 with_gif=yes
2715 # Check whether --with-png was given.
2716 if test "${with_png+set}" = set; then :
2717 withval=$with_png;
2718 else
2719 with_png=yes
2723 # Check whether --with-rsvg was given.
2724 if test "${with_rsvg+set}" = set; then :
2725 withval=$with_rsvg;
2726 else
2727 with_rsvg=yes
2732 # Check whether --with-xft was given.
2733 if test "${with_xft+set}" = set; then :
2734 withval=$with_xft;
2735 else
2736 with_xft=yes
2740 # Check whether --with-libotf was given.
2741 if test "${with_libotf+set}" = set; then :
2742 withval=$with_libotf;
2743 else
2744 with_libotf=yes
2748 # Check whether --with-m17n-flt was given.
2749 if test "${with_m17n_flt+set}" = set; then :
2750 withval=$with_m17n_flt;
2751 else
2752 with_m17n_flt=yes
2757 # Check whether --with-toolkit-scroll-bars was given.
2758 if test "${with_toolkit_scroll_bars+set}" = set; then :
2759 withval=$with_toolkit_scroll_bars;
2760 else
2761 with_toolkit_scroll_bars=yes
2765 # Check whether --with-xaw3d was given.
2766 if test "${with_xaw3d+set}" = set; then :
2767 withval=$with_xaw3d;
2768 else
2769 with_xaw3d=yes
2773 # Check whether --with-xim was given.
2774 if test "${with_xim+set}" = set; then :
2775 withval=$with_xim;
2776 else
2777 with_xim=yes
2781 # Check whether --with-ns was given.
2782 if test "${with_ns+set}" = set; then :
2783 withval=$with_ns;
2784 else
2785 with_ns=no
2790 # Check whether --with-gpm was given.
2791 if test "${with_gpm+set}" = set; then :
2792 withval=$with_gpm;
2793 else
2794 with_gpm=yes
2798 # Check whether --with-dbus was given.
2799 if test "${with_dbus+set}" = set; then :
2800 withval=$with_dbus;
2801 else
2802 with_dbus=yes
2806 # Check whether --with-gconf was given.
2807 if test "${with_gconf+set}" = set; then :
2808 withval=$with_gconf;
2809 else
2810 with_gconf=yes
2814 # Check whether --with-selinux was given.
2815 if test "${with_selinux+set}" = set; then :
2816 withval=$with_selinux;
2817 else
2818 with_selinux=yes
2822 ## For the times when you want to build Emacs but don't have
2823 ## a suitable makeinfo, and can live without the manuals.
2825 # Check whether --with-makeinfo was given.
2826 if test "${with_makeinfo+set}" = set; then :
2827 withval=$with_makeinfo;
2828 else
2829 with_makeinfo=yes
2833 ## This is an option because I do not know if all info/man support
2834 ## compressed files, nor how to test if they do so.
2836 # Check whether --with-compress-info was given.
2837 if test "${with_compress_info+set}" = set; then :
2838 withval=$with_compress_info;
2839 else
2840 with_compress_info=yes
2843 if test $with_compress_info = yes; then
2844 GZIP_INFO=yes
2845 else
2846 GZIP_INFO=
2851 # Check whether --with-pkg-config-prog was given.
2852 if test "${with_pkg_config_prog+set}" = set; then :
2853 withval=$with_pkg_config_prog;
2856 if test "X${with_pkg_config_prog}" != X; then
2857 if test "${with_pkg_config_prog}" != yes; then
2858 PKG_CONFIG="${with_pkg_config_prog}"
2862 CRT_DIR=
2864 # Check whether --with-crt-dir was given.
2865 if test "${with_crt_dir+set}" = set; then :
2866 withval=$with_crt_dir;
2869 CRT_DIR="${with_crt_dir}"
2872 # Check whether --with-gnustep-conf was given.
2873 if test "${with_gnustep_conf+set}" = set; then :
2874 withval=$with_gnustep_conf;
2877 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
2878 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
2879 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
2880 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
2882 # Check whether --enable-ns-self-contained was given.
2883 if test "${enable_ns_self_contained+set}" = set; then :
2884 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
2885 else
2886 EN_NS_SELF_CONTAINED=yes
2890 # Check whether --enable-asserts was given.
2891 if test "${enable_asserts+set}" = set; then :
2892 enableval=$enable_asserts; USE_XASSERTS=$enableval
2893 else
2894 USE_XASSERTS=no
2898 # Check whether --enable-maintainer-mode was given.
2899 if test "${enable_maintainer_mode+set}" = set; then :
2900 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
2901 else
2902 USE_MAINTAINER_MODE=no
2905 if test $USE_MAINTAINER_MODE = yes; then
2906 MAINT=
2907 else
2908 MAINT=#
2912 # Check whether --enable-locallisppath was given.
2913 if test "${enable_locallisppath+set}" = set; then :
2914 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
2915 locallisppath=
2916 elif test "${enableval}" != "yes"; then
2917 locallisppath=${enableval}
2922 # Check whether --enable-checking was given.
2923 if test "${enable_checking+set}" = set; then :
2924 enableval=$enable_checking; ac_checking_flags="${enableval}"
2927 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
2928 for check in $ac_checking_flags
2930 case $check in
2931 # these set all the flags to specific states
2932 yes) ac_enable_checking=1 ;;
2933 no) ac_enable_checking= ;
2934 ac_gc_check_stringbytes= ;
2935 ac_gc_check_string_overrun= ;
2936 ac_gc_check_string_free_list= ;
2937 ac_xmalloc_overrun= ;
2938 ac_gc_check_cons_list= ;;
2939 all) ac_enable_checking=1 ;
2940 ac_gc_check_stringbytes=1 ;
2941 ac_gc_check_string_overrun=1 ;
2942 ac_gc_check_string_free_list=1 ;
2943 ac_xmalloc_overrun=1 ;
2944 ac_gc_check_cons_list=1 ;;
2945 # these enable particular checks
2946 stringbytes) ac_gc_check_stringbytes=1 ;;
2947 stringoverrun) ac_gc_check_string_overrun=1 ;;
2948 stringfreelist) ac_gc_check_string_free_list=1 ;;
2949 xmallocoverrun) ac_xmalloc_overrun=1 ;;
2950 conslist) ac_gc_check_cons_list=1 ;;
2951 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
2952 esac
2953 done
2954 IFS="$ac_save_IFS"
2956 if test x$ac_enable_checking != x ; then
2958 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
2961 if test x$ac_gc_check_stringbytes != x ; then
2963 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
2966 if test x$ac_gc_check_stringoverrun != x ; then
2968 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
2971 if test x$ac_gc_check_string_free_list != x ; then
2973 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
2976 if test x$ac_xmalloc_overrun != x ; then
2978 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
2981 if test x$ac_gc_check_cons_list != x ; then
2983 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
2987 # Check whether --enable-use-lisp-union-type was given.
2988 if test "${enable_use_lisp_union_type+set}" = set; then :
2989 enableval=$enable_use_lisp_union_type; if test "${enableval}" != "no"; then
2991 $as_echo "#define USE_LISP_UNION_TYPE 1" >>confdefs.h
2998 # Check whether --enable-profiling was given.
2999 if test "${enable_profiling+set}" = set; then :
3000 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
3003 if test x$ac_enable_profiling != x ; then
3004 PROFILING_CFLAGS="-DPROFILING=1 -pg"
3005 PROFILING_LDFLAGS="-pg"
3006 else
3007 PROFILING_CFLAGS=
3008 PROFILING_LDFLAGS=
3013 # Check whether --enable-autodepend was given.
3014 if test "${enable_autodepend+set}" = set; then :
3015 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
3016 else
3017 ac_enable_autodepend=yes
3021 #### Make srcdir absolute, if it isn't already. It's important to
3022 #### avoid running the path through pwd unnecessarily, since pwd can
3023 #### give you automounter prefixes, which can go away. We do all this
3024 #### so Emacs can find its files when run uninstalled.
3025 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
3026 unset CDPATH
3027 case "${srcdir}" in
3028 /* ) ;;
3030 ## We may be able to use the $PWD environment variable to make this
3031 ## absolute. But sometimes PWD is inaccurate.
3032 ## Note: we used to use ${PWD} at the end instead of `pwd`,
3033 ## but that tested only for a well-formed and valid PWD,
3034 ## it did not object when PWD was well-formed and valid but just wrong.
3035 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
3036 then
3037 srcdir="$PWD"
3038 else
3039 srcdir="`(cd ${srcdir}; pwd)`"
3042 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
3043 esac
3045 #### Check if the source directory already has a configured system in it.
3046 if test `pwd` != `(cd ${srcdir} && pwd)` \
3047 && test -f "${srcdir}/src/config.h" ; then
3048 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The directory tree \`${srcdir}' is being used
3049 as a build directory right now; it has been configured in its own
3050 right. To configure in another directory as well, you MUST
3051 use GNU make. If you do not have GNU make, then you must
3052 now do \`make distclean' in ${srcdir},
3053 and then run $0 again." >&5
3054 $as_echo "$as_me: WARNING: The directory tree \`${srcdir}' is being used
3055 as a build directory right now; it has been configured in its own
3056 right. To configure in another directory as well, you MUST
3057 use GNU make. If you do not have GNU make, then you must
3058 now do \`make distclean' in ${srcdir},
3059 and then run $0 again." >&2;}
3062 #### Given the configuration name, set machfile and opsysfile to the
3063 #### names of the m/*.h and s/*.h files we should use.
3065 ### Canonicalize the configuration name.
3067 ac_aux_dir=
3068 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
3069 for ac_t in install-sh install.sh shtool; do
3070 if test -f "$ac_dir/$ac_t"; then
3071 ac_aux_dir=$ac_dir
3072 ac_install_sh="$ac_aux_dir/$ac_t -c"
3073 break 2
3075 done
3076 done
3077 if test -z "$ac_aux_dir"; then
3078 as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
3081 # These three variables are undocumented and unsupported,
3082 # and are intended to be withdrawn in a future Autoconf release.
3083 # They can cause serious problems if a builder's source tree is in a directory
3084 # whose full name contains unusual characters.
3085 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3086 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3087 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3090 # Make sure we can run config.sub.
3091 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
3092 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
3094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
3095 $as_echo_n "checking build system type... " >&6; }
3096 if test "${ac_cv_build+set}" = set; then :
3097 $as_echo_n "(cached) " >&6
3098 else
3099 ac_build_alias=$build_alias
3100 test "x$ac_build_alias" = x &&
3101 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
3102 test "x$ac_build_alias" = x &&
3103 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
3104 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
3105 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
3108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
3109 $as_echo "$ac_cv_build" >&6; }
3110 case $ac_cv_build in
3111 *-*-*) ;;
3112 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
3113 esac
3114 build=$ac_cv_build
3115 ac_save_IFS=$IFS; IFS='-'
3116 set x $ac_cv_build
3117 shift
3118 build_cpu=$1
3119 build_vendor=$2
3120 shift; shift
3121 # Remember, the first character of IFS is used to create $*,
3122 # except with old shells:
3123 build_os=$*
3124 IFS=$ac_save_IFS
3125 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
3128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
3129 $as_echo_n "checking host system type... " >&6; }
3130 if test "${ac_cv_host+set}" = set; then :
3131 $as_echo_n "(cached) " >&6
3132 else
3133 if test "x$host_alias" = x; then
3134 ac_cv_host=$ac_cv_build
3135 else
3136 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
3137 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
3141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
3142 $as_echo "$ac_cv_host" >&6; }
3143 case $ac_cv_host in
3144 *-*-*) ;;
3145 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
3146 esac
3147 host=$ac_cv_host
3148 ac_save_IFS=$IFS; IFS='-'
3149 set x $ac_cv_host
3150 shift
3151 host_cpu=$1
3152 host_vendor=$2
3153 shift; shift
3154 # Remember, the first character of IFS is used to create $*,
3155 # except with old shells:
3156 host_os=$*
3157 IFS=$ac_save_IFS
3158 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
3161 canonical=$host
3162 configuration=${host_alias-${build_alias-$host}}
3166 ### If you add support for a new configuration, add code to this
3167 ### switch statement to recognize your configuration name and select
3168 ### the appropriate operating system and machine description files.
3170 ### You would hope that you could choose an m/*.h file pretty much
3171 ### based on the machine portion of the configuration name, and an s/*.h
3172 ### file based on the operating system portion. However, it turns out
3173 ### that each m/*.h file is pretty manufacturer-specific - for
3174 ### example mips.h is MIPS
3175 ### So we basically have to have a special case for each
3176 ### configuration name.
3178 ### As far as handling version numbers on operating systems is
3179 ### concerned, make sure things will fail in a fixable way. If
3180 ### /etc/MACHINES doesn't say anything about version numbers, be
3181 ### prepared to handle anything reasonably. If version numbers
3182 ### matter, be sure /etc/MACHINES says something about it.
3184 machine='' opsys='' unported=no
3185 case "${canonical}" in
3187 ## FreeBSD ports
3188 *-*-freebsd* )
3189 opsys=freebsd
3190 case "${canonical}" in
3191 alpha*) machine=alpha ;;
3192 amd64-*|x86_64-*) machine=amdx86-64 ;;
3193 arm*) machine=arm ;;
3194 ia64-*) machine=ia64 ;;
3195 i[3456]86-*) machine=intel386 ;;
3196 powerpc-*) machine=macppc ;;
3197 sparc-*) machine=sparc ;;
3198 sparc64-*) machine=sparc ;;
3199 esac
3202 ## FreeBSD kernel + glibc based userland
3203 *-*-kfreebsd*gnu* )
3204 opsys=gnu-kfreebsd
3205 case "${canonical}" in
3206 alpha*) machine=alpha ;;
3207 amd64-*|x86_64-*) machine=amdx86-64 ;;
3208 ia64-*) machine=ia64 ;;
3209 i[3456]86-*) machine=intel386 ;;
3210 powerpc-*) machine=macppc ;;
3211 sparc-*) machine=sparc ;;
3212 sparc64-*) machine=sparc ;;
3213 esac
3216 ## NetBSD ports
3217 *-*-netbsd* )
3218 opsys=netbsd
3219 case "${canonical}" in
3220 alpha*) machine=alpha ;;
3221 x86_64-*) machine=amdx86-64 ;;
3222 arm-*) machine=arm ;;
3223 hppa-*) machine=hp800 ;;
3224 i[3456]86-*) machine=intel386 ;;
3225 m68k-*) machine=m68k ;;
3226 powerpc-*) machine=macppc ;;
3227 mips-*) machine=mips ;;
3228 mipse[bl]-*) machine=mips ;;
3229 sparc*-) machine=sparc ;;
3230 vax-*) machine=vax ;;
3231 esac
3234 ## OpenBSD ports
3235 *-*-openbsd* )
3236 opsys=openbsd
3237 case "${canonical}" in
3238 alpha*) machine=alpha ;;
3239 x86_64-*) machine=amdx86-64 ;;
3240 arm-*) machine=arm ;;
3241 hppa-*) machine=hp800 ;;
3242 i386-*) machine=intel386 ;;
3243 powerpc-*) machine=macppc ;;
3244 sparc*) machine=sparc ;;
3245 vax-*) machine=vax ;;
3246 esac
3249 alpha*-*-linux-gnu* )
3250 machine=alpha opsys=gnu-linux
3253 arm*-*-linux-gnu* )
3254 machine=arm opsys=gnu-linux
3257 ## Apple Darwin / Mac OS X
3258 *-apple-darwin* )
3259 case "${canonical}" in
3260 i[3456]86-* ) machine=intel386 ;;
3261 powerpc-* ) machine=macppc ;;
3262 x86_64-* ) machine=amdx86-64 ;;
3263 * ) unported=yes ;;
3264 esac
3265 opsys=darwin
3266 # Define CPP as follows to make autoconf work correctly.
3267 CPP="${CC-cc} -E -no-cpp-precomp"
3268 # Use fink packages if available.
3269 if test -d /sw/include && test -d /sw/lib; then
3270 GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
3271 CPP="${CPP} ${GCC_TEST_OPTIONS}"
3272 NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
3276 ## HP 9000 series 700 and 800, running HP/UX
3277 hppa*-hp-hpux10.2* )
3278 machine=hp800 opsys=hpux10-20
3280 hppa*-hp-hpux1[1-9]* )
3281 machine=hp800 opsys=hpux11
3282 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
3285 hppa*-*-linux-gnu* )
3286 machine=hp800 opsys=gnu-linux
3289 ## IBM machines
3290 s390-*-linux-gnu* )
3291 machine=ibms390 opsys=gnu-linux
3293 s390x-*-linux-gnu* )
3294 machine=ibms390x opsys=gnu-linux
3296 rs6000-ibm-aix4.[23]* )
3297 machine=ibmrs6000 opsys=aix4-2
3299 powerpc-ibm-aix4.[23]* )
3300 machine=ibmrs6000 opsys=aix4-2
3302 rs6000-ibm-aix[56]* )
3303 machine=ibmrs6000 opsys=aix4-2
3305 powerpc-ibm-aix[56]* )
3306 machine=ibmrs6000 opsys=aix4-2
3309 ## Macintosh PowerPC
3310 powerpc*-*-linux-gnu* )
3311 machine=macppc opsys=gnu-linux
3314 ## Silicon Graphics machines
3315 ## Iris 4D
3316 mips-sgi-irix6.5 )
3317 machine=iris4d opsys=irix6-5
3318 # Without defining _LANGUAGE_C, things get masked out in the headers
3319 # so that, for instance, grepping for `free' in stdlib.h fails and
3320 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
3321 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
3322 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
3325 ## Suns
3326 sparc-*-linux-gnu* | sparc64-*-linux-gnu* )
3327 machine=sparc opsys=gnu-linux
3330 *-sun-solaris* \
3331 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
3332 | x86_64-*-solaris2* | x86_64-*-sunos5*)
3333 case "${canonical}" in
3334 i[3456]86-*-* ) machine=intel386 ;;
3335 amd64-*-*|x86_64-*-*) machine=amdx86-64 ;;
3336 sparc* ) machine=sparc ;;
3337 * ) unported=yes ;;
3338 esac
3339 case "${canonical}" in
3340 *-sunos5.6* | *-solaris2.6* )
3341 opsys=sol2-6
3342 NON_GNU_CPP=/usr/ccs/lib/cpp
3343 RANLIB="ar -ts"
3345 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
3346 opsys=sol2-6
3347 emacs_check_sunpro_c=yes
3348 NON_GNU_CPP=/usr/ccs/lib/cpp
3350 *-sunos5* | *-solaris* )
3351 opsys=sol2-10
3352 emacs_check_sunpro_c=yes
3353 NON_GNU_CPP=/usr/ccs/lib/cpp
3355 esac
3356 ## Watch out for a compiler that we know will not work.
3357 case "${canonical}" in
3358 *-solaris* | *-sunos5* )
3359 if [ "x$CC" = x/usr/ucb/cc ]; then
3360 ## /usr/ucb/cc doesn't work;
3361 ## we should find some other compiler that does work.
3362 unset CC
3365 *) ;;
3366 esac
3369 ## IA-64
3370 ia64*-*-linux* )
3371 machine=ia64 opsys=gnu-linux
3374 ## Intel 386 machines where we don't care about the manufacturer.
3375 i[3456]86-*-* )
3376 machine=intel386
3377 case "${canonical}" in
3378 *-cygwin ) opsys=cygwin ;;
3379 *-darwin* ) opsys=darwin
3380 CPP="${CC-cc} -E -no-cpp-precomp"
3382 *-linux-gnu* ) opsys=gnu-linux ;;
3383 *-sysv4.2uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
3384 *-sysv5uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
3385 *-sysv5OpenUNIX* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
3386 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
3387 esac
3390 ## m68k Linux-based GNU system
3391 m68k-*-linux-gnu* )
3392 machine=m68k opsys=gnu-linux
3395 ## Mips Linux-based GNU system
3396 mips-*-linux-gnu* | mipsel-*-linux-gnu* \
3397 | mips64-*-linux-gnu* | mips64el-*-linux-gnu* )
3398 machine=mips opsys=gnu-linux
3401 ## AMD x86-64 Linux-based GNU system
3402 x86_64-*-linux-gnu* )
3403 machine=amdx86-64 opsys=gnu-linux
3406 ## Tensilica Xtensa Linux-based GNU system
3407 xtensa*-*-linux-gnu* )
3408 machine=xtensa opsys=gnu-linux
3411 ## SuperH Linux-based GNU system
3412 sh[34]*-*-linux-gnu* )
3413 machine=sh3 opsys=gnu-linux
3417 unported=yes
3419 esac
3421 ### If the code above didn't choose an operating system, just choose
3422 ### an operating system based on the configuration name. You really
3423 ### only want to use this when you have no idea what the right
3424 ### operating system is; if you know what operating systems a machine
3425 ### runs, it's cleaner to make it explicit in the case statement
3426 ### above.
3427 if test x"${opsys}" = x; then
3428 case "${canonical}" in
3429 *-gnu* ) opsys=gnu ;;
3431 unported=yes
3433 esac
3438 if test $unported = yes; then
3439 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
3440 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
3443 machfile="m/${machine}.h"
3444 opsysfile="s/${opsys}.h"
3447 #### Choose a compiler.
3448 test -n "$CC" && cc_specified=yes
3450 # Save the value of CFLAGS that the user specified.
3451 SPECIFIED_CFLAGS="$CFLAGS"
3453 ac_ext=c
3454 ac_cpp='$CPP $CPPFLAGS'
3455 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3456 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3457 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3458 if test -n "$ac_tool_prefix"; then
3459 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3460 set dummy ${ac_tool_prefix}gcc; ac_word=$2
3461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3462 $as_echo_n "checking for $ac_word... " >&6; }
3463 if test "${ac_cv_prog_CC+set}" = set; then :
3464 $as_echo_n "(cached) " >&6
3465 else
3466 if test -n "$CC"; then
3467 ac_cv_prog_CC="$CC" # Let the user override the test.
3468 else
3469 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3470 for as_dir in $PATH
3472 IFS=$as_save_IFS
3473 test -z "$as_dir" && as_dir=.
3474 for ac_exec_ext in '' $ac_executable_extensions; do
3475 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3476 ac_cv_prog_CC="${ac_tool_prefix}gcc"
3477 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3478 break 2
3480 done
3481 done
3482 IFS=$as_save_IFS
3486 CC=$ac_cv_prog_CC
3487 if test -n "$CC"; then
3488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3489 $as_echo "$CC" >&6; }
3490 else
3491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3492 $as_echo "no" >&6; }
3497 if test -z "$ac_cv_prog_CC"; then
3498 ac_ct_CC=$CC
3499 # Extract the first word of "gcc", so it can be a program name with args.
3500 set dummy gcc; ac_word=$2
3501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3502 $as_echo_n "checking for $ac_word... " >&6; }
3503 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
3504 $as_echo_n "(cached) " >&6
3505 else
3506 if test -n "$ac_ct_CC"; then
3507 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3508 else
3509 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3510 for as_dir in $PATH
3512 IFS=$as_save_IFS
3513 test -z "$as_dir" && as_dir=.
3514 for ac_exec_ext in '' $ac_executable_extensions; do
3515 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3516 ac_cv_prog_ac_ct_CC="gcc"
3517 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3518 break 2
3520 done
3521 done
3522 IFS=$as_save_IFS
3526 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3527 if test -n "$ac_ct_CC"; then
3528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3529 $as_echo "$ac_ct_CC" >&6; }
3530 else
3531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3532 $as_echo "no" >&6; }
3535 if test "x$ac_ct_CC" = x; then
3536 CC=""
3537 else
3538 case $cross_compiling:$ac_tool_warned in
3539 yes:)
3540 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3541 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3542 ac_tool_warned=yes ;;
3543 esac
3544 CC=$ac_ct_CC
3546 else
3547 CC="$ac_cv_prog_CC"
3550 if test -z "$CC"; then
3551 if test -n "$ac_tool_prefix"; then
3552 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3553 set dummy ${ac_tool_prefix}cc; ac_word=$2
3554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3555 $as_echo_n "checking for $ac_word... " >&6; }
3556 if test "${ac_cv_prog_CC+set}" = set; then :
3557 $as_echo_n "(cached) " >&6
3558 else
3559 if test -n "$CC"; then
3560 ac_cv_prog_CC="$CC" # Let the user override the test.
3561 else
3562 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3563 for as_dir in $PATH
3565 IFS=$as_save_IFS
3566 test -z "$as_dir" && as_dir=.
3567 for ac_exec_ext in '' $ac_executable_extensions; do
3568 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3569 ac_cv_prog_CC="${ac_tool_prefix}cc"
3570 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3571 break 2
3573 done
3574 done
3575 IFS=$as_save_IFS
3579 CC=$ac_cv_prog_CC
3580 if test -n "$CC"; then
3581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3582 $as_echo "$CC" >&6; }
3583 else
3584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3585 $as_echo "no" >&6; }
3591 if test -z "$CC"; then
3592 # Extract the first word of "cc", so it can be a program name with args.
3593 set dummy cc; ac_word=$2
3594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3595 $as_echo_n "checking for $ac_word... " >&6; }
3596 if test "${ac_cv_prog_CC+set}" = set; then :
3597 $as_echo_n "(cached) " >&6
3598 else
3599 if test -n "$CC"; then
3600 ac_cv_prog_CC="$CC" # Let the user override the test.
3601 else
3602 ac_prog_rejected=no
3603 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3604 for as_dir in $PATH
3606 IFS=$as_save_IFS
3607 test -z "$as_dir" && as_dir=.
3608 for ac_exec_ext in '' $ac_executable_extensions; do
3609 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3610 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3611 ac_prog_rejected=yes
3612 continue
3614 ac_cv_prog_CC="cc"
3615 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3616 break 2
3618 done
3619 done
3620 IFS=$as_save_IFS
3622 if test $ac_prog_rejected = yes; then
3623 # We found a bogon in the path, so make sure we never use it.
3624 set dummy $ac_cv_prog_CC
3625 shift
3626 if test $# != 0; then
3627 # We chose a different compiler from the bogus one.
3628 # However, it has the same basename, so the bogon will be chosen
3629 # first if we set CC to just the basename; use the full file name.
3630 shift
3631 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3636 CC=$ac_cv_prog_CC
3637 if test -n "$CC"; then
3638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3639 $as_echo "$CC" >&6; }
3640 else
3641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3642 $as_echo "no" >&6; }
3647 if test -z "$CC"; then
3648 if test -n "$ac_tool_prefix"; then
3649 for ac_prog in cl.exe
3651 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3652 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3654 $as_echo_n "checking for $ac_word... " >&6; }
3655 if test "${ac_cv_prog_CC+set}" = set; then :
3656 $as_echo_n "(cached) " >&6
3657 else
3658 if test -n "$CC"; then
3659 ac_cv_prog_CC="$CC" # Let the user override the test.
3660 else
3661 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3662 for as_dir in $PATH
3664 IFS=$as_save_IFS
3665 test -z "$as_dir" && as_dir=.
3666 for ac_exec_ext in '' $ac_executable_extensions; do
3667 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3668 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3669 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3670 break 2
3672 done
3673 done
3674 IFS=$as_save_IFS
3678 CC=$ac_cv_prog_CC
3679 if test -n "$CC"; then
3680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3681 $as_echo "$CC" >&6; }
3682 else
3683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3684 $as_echo "no" >&6; }
3688 test -n "$CC" && break
3689 done
3691 if test -z "$CC"; then
3692 ac_ct_CC=$CC
3693 for ac_prog in cl.exe
3695 # Extract the first word of "$ac_prog", so it can be a program name with args.
3696 set dummy $ac_prog; ac_word=$2
3697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3698 $as_echo_n "checking for $ac_word... " >&6; }
3699 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
3700 $as_echo_n "(cached) " >&6
3701 else
3702 if test -n "$ac_ct_CC"; then
3703 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3704 else
3705 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3706 for as_dir in $PATH
3708 IFS=$as_save_IFS
3709 test -z "$as_dir" && as_dir=.
3710 for ac_exec_ext in '' $ac_executable_extensions; do
3711 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3712 ac_cv_prog_ac_ct_CC="$ac_prog"
3713 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3714 break 2
3716 done
3717 done
3718 IFS=$as_save_IFS
3722 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3723 if test -n "$ac_ct_CC"; then
3724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3725 $as_echo "$ac_ct_CC" >&6; }
3726 else
3727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3728 $as_echo "no" >&6; }
3732 test -n "$ac_ct_CC" && break
3733 done
3735 if test "x$ac_ct_CC" = x; then
3736 CC=""
3737 else
3738 case $cross_compiling:$ac_tool_warned in
3739 yes:)
3740 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3741 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3742 ac_tool_warned=yes ;;
3743 esac
3744 CC=$ac_ct_CC
3751 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3752 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3753 as_fn_error "no acceptable C compiler found in \$PATH
3754 See \`config.log' for more details." "$LINENO" 5; }
3756 # Provide some information about the compiler.
3757 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3758 set X $ac_compile
3759 ac_compiler=$2
3760 for ac_option in --version -v -V -qversion; do
3761 { { ac_try="$ac_compiler $ac_option >&5"
3762 case "(($ac_try" in
3763 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3764 *) ac_try_echo=$ac_try;;
3765 esac
3766 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3767 $as_echo "$ac_try_echo"; } >&5
3768 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3769 ac_status=$?
3770 if test -s conftest.err; then
3771 sed '10a\
3772 ... rest of stderr output deleted ...
3773 10q' conftest.err >conftest.er1
3774 cat conftest.er1 >&5
3776 rm -f conftest.er1 conftest.err
3777 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3778 test $ac_status = 0; }
3779 done
3781 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3782 /* end confdefs.h. */
3785 main ()
3789 return 0;
3791 _ACEOF
3792 ac_clean_files_save=$ac_clean_files
3793 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3794 # Try to create an executable without -o first, disregard a.out.
3795 # It will help us diagnose broken compilers, and finding out an intuition
3796 # of exeext.
3797 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3798 $as_echo_n "checking whether the C compiler works... " >&6; }
3799 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3801 # The possible output files:
3802 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3804 ac_rmfiles=
3805 for ac_file in $ac_files
3807 case $ac_file in
3808 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3809 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3810 esac
3811 done
3812 rm -f $ac_rmfiles
3814 if { { ac_try="$ac_link_default"
3815 case "(($ac_try" in
3816 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3817 *) ac_try_echo=$ac_try;;
3818 esac
3819 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3820 $as_echo "$ac_try_echo"; } >&5
3821 (eval "$ac_link_default") 2>&5
3822 ac_status=$?
3823 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3824 test $ac_status = 0; }; then :
3825 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3826 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3827 # in a Makefile. We should not override ac_cv_exeext if it was cached,
3828 # so that the user can short-circuit this test for compilers unknown to
3829 # Autoconf.
3830 for ac_file in $ac_files ''
3832 test -f "$ac_file" || continue
3833 case $ac_file in
3834 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3836 [ab].out )
3837 # We found the default executable, but exeext='' is most
3838 # certainly right.
3839 break;;
3840 *.* )
3841 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3842 then :; else
3843 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3845 # We set ac_cv_exeext here because the later test for it is not
3846 # safe: cross compilers may not add the suffix if given an `-o'
3847 # argument, so we may need to know it at that point already.
3848 # Even if this section looks crufty: it has the advantage of
3849 # actually working.
3850 break;;
3852 break;;
3853 esac
3854 done
3855 test "$ac_cv_exeext" = no && ac_cv_exeext=
3857 else
3858 ac_file=''
3860 if test -z "$ac_file"; then :
3861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3862 $as_echo "no" >&6; }
3863 $as_echo "$as_me: failed program was:" >&5
3864 sed 's/^/| /' conftest.$ac_ext >&5
3866 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3867 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3868 { as_fn_set_status 77
3869 as_fn_error "C compiler cannot create executables
3870 See \`config.log' for more details." "$LINENO" 5; }; }
3871 else
3872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3873 $as_echo "yes" >&6; }
3875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3876 $as_echo_n "checking for C compiler default output file name... " >&6; }
3877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3878 $as_echo "$ac_file" >&6; }
3879 ac_exeext=$ac_cv_exeext
3881 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3882 ac_clean_files=$ac_clean_files_save
3883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3884 $as_echo_n "checking for suffix of executables... " >&6; }
3885 if { { ac_try="$ac_link"
3886 case "(($ac_try" in
3887 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3888 *) ac_try_echo=$ac_try;;
3889 esac
3890 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3891 $as_echo "$ac_try_echo"; } >&5
3892 (eval "$ac_link") 2>&5
3893 ac_status=$?
3894 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3895 test $ac_status = 0; }; then :
3896 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3897 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3898 # work properly (i.e., refer to `conftest.exe'), while it won't with
3899 # `rm'.
3900 for ac_file in conftest.exe conftest conftest.*; do
3901 test -f "$ac_file" || continue
3902 case $ac_file in
3903 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3904 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3905 break;;
3906 * ) break;;
3907 esac
3908 done
3909 else
3910 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3911 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3912 as_fn_error "cannot compute suffix of executables: cannot compile and link
3913 See \`config.log' for more details." "$LINENO" 5; }
3915 rm -f conftest conftest$ac_cv_exeext
3916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3917 $as_echo "$ac_cv_exeext" >&6; }
3919 rm -f conftest.$ac_ext
3920 EXEEXT=$ac_cv_exeext
3921 ac_exeext=$EXEEXT
3922 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3923 /* end confdefs.h. */
3924 #include <stdio.h>
3926 main ()
3928 FILE *f = fopen ("conftest.out", "w");
3929 return ferror (f) || fclose (f) != 0;
3932 return 0;
3934 _ACEOF
3935 ac_clean_files="$ac_clean_files conftest.out"
3936 # Check that the compiler produces executables we can run. If not, either
3937 # the compiler is broken, or we cross compile.
3938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3939 $as_echo_n "checking whether we are cross compiling... " >&6; }
3940 if test "$cross_compiling" != yes; then
3941 { { ac_try="$ac_link"
3942 case "(($ac_try" in
3943 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3944 *) ac_try_echo=$ac_try;;
3945 esac
3946 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3947 $as_echo "$ac_try_echo"; } >&5
3948 (eval "$ac_link") 2>&5
3949 ac_status=$?
3950 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3951 test $ac_status = 0; }
3952 if { ac_try='./conftest$ac_cv_exeext'
3953 { { case "(($ac_try" in
3954 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3955 *) ac_try_echo=$ac_try;;
3956 esac
3957 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3958 $as_echo "$ac_try_echo"; } >&5
3959 (eval "$ac_try") 2>&5
3960 ac_status=$?
3961 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3962 test $ac_status = 0; }; }; then
3963 cross_compiling=no
3964 else
3965 if test "$cross_compiling" = maybe; then
3966 cross_compiling=yes
3967 else
3968 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3969 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3970 as_fn_error "cannot run C compiled programs.
3971 If you meant to cross compile, use \`--host'.
3972 See \`config.log' for more details." "$LINENO" 5; }
3976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3977 $as_echo "$cross_compiling" >&6; }
3979 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3980 ac_clean_files=$ac_clean_files_save
3981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3982 $as_echo_n "checking for suffix of object files... " >&6; }
3983 if test "${ac_cv_objext+set}" = set; then :
3984 $as_echo_n "(cached) " >&6
3985 else
3986 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3987 /* end confdefs.h. */
3990 main ()
3994 return 0;
3996 _ACEOF
3997 rm -f conftest.o conftest.obj
3998 if { { ac_try="$ac_compile"
3999 case "(($ac_try" in
4000 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4001 *) ac_try_echo=$ac_try;;
4002 esac
4003 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4004 $as_echo "$ac_try_echo"; } >&5
4005 (eval "$ac_compile") 2>&5
4006 ac_status=$?
4007 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4008 test $ac_status = 0; }; then :
4009 for ac_file in conftest.o conftest.obj conftest.*; do
4010 test -f "$ac_file" || continue;
4011 case $ac_file in
4012 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4013 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4014 break;;
4015 esac
4016 done
4017 else
4018 $as_echo "$as_me: failed program was:" >&5
4019 sed 's/^/| /' conftest.$ac_ext >&5
4021 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4022 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4023 as_fn_error "cannot compute suffix of object files: cannot compile
4024 See \`config.log' for more details." "$LINENO" 5; }
4026 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4029 $as_echo "$ac_cv_objext" >&6; }
4030 OBJEXT=$ac_cv_objext
4031 ac_objext=$OBJEXT
4032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4033 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4034 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
4035 $as_echo_n "(cached) " >&6
4036 else
4037 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4038 /* end confdefs.h. */
4041 main ()
4043 #ifndef __GNUC__
4044 choke me
4045 #endif
4048 return 0;
4050 _ACEOF
4051 if ac_fn_c_try_compile "$LINENO"; then :
4052 ac_compiler_gnu=yes
4053 else
4054 ac_compiler_gnu=no
4056 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4057 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4061 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
4062 if test $ac_compiler_gnu = yes; then
4063 GCC=yes
4064 else
4065 GCC=
4067 ac_test_CFLAGS=${CFLAGS+set}
4068 ac_save_CFLAGS=$CFLAGS
4069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4070 $as_echo_n "checking whether $CC accepts -g... " >&6; }
4071 if test "${ac_cv_prog_cc_g+set}" = set; then :
4072 $as_echo_n "(cached) " >&6
4073 else
4074 ac_save_c_werror_flag=$ac_c_werror_flag
4075 ac_c_werror_flag=yes
4076 ac_cv_prog_cc_g=no
4077 CFLAGS="-g"
4078 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4079 /* end confdefs.h. */
4082 main ()
4086 return 0;
4088 _ACEOF
4089 if ac_fn_c_try_compile "$LINENO"; then :
4090 ac_cv_prog_cc_g=yes
4091 else
4092 CFLAGS=""
4093 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4094 /* end confdefs.h. */
4097 main ()
4101 return 0;
4103 _ACEOF
4104 if ac_fn_c_try_compile "$LINENO"; then :
4106 else
4107 ac_c_werror_flag=$ac_save_c_werror_flag
4108 CFLAGS="-g"
4109 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4110 /* end confdefs.h. */
4113 main ()
4117 return 0;
4119 _ACEOF
4120 if ac_fn_c_try_compile "$LINENO"; then :
4121 ac_cv_prog_cc_g=yes
4123 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4125 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4127 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4128 ac_c_werror_flag=$ac_save_c_werror_flag
4130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4131 $as_echo "$ac_cv_prog_cc_g" >&6; }
4132 if test "$ac_test_CFLAGS" = set; then
4133 CFLAGS=$ac_save_CFLAGS
4134 elif test $ac_cv_prog_cc_g = yes; then
4135 if test "$GCC" = yes; then
4136 CFLAGS="-g -O2"
4137 else
4138 CFLAGS="-g"
4140 else
4141 if test "$GCC" = yes; then
4142 CFLAGS="-O2"
4143 else
4144 CFLAGS=
4147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4148 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4149 if test "${ac_cv_prog_cc_c89+set}" = set; then :
4150 $as_echo_n "(cached) " >&6
4151 else
4152 ac_cv_prog_cc_c89=no
4153 ac_save_CC=$CC
4154 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4155 /* end confdefs.h. */
4156 #include <stdarg.h>
4157 #include <stdio.h>
4158 #include <sys/types.h>
4159 #include <sys/stat.h>
4160 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4161 struct buf { int x; };
4162 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4163 static char *e (p, i)
4164 char **p;
4165 int i;
4167 return p[i];
4169 static char *f (char * (*g) (char **, int), char **p, ...)
4171 char *s;
4172 va_list v;
4173 va_start (v,p);
4174 s = g (p, va_arg (v,int));
4175 va_end (v);
4176 return s;
4179 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
4180 function prototypes and stuff, but not '\xHH' hex character constants.
4181 These don't provoke an error unfortunately, instead are silently treated
4182 as 'x'. The following induces an error, until -std is added to get
4183 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
4184 array size at least. It's necessary to write '\x00'==0 to get something
4185 that's true only with -std. */
4186 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4188 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4189 inside strings and character constants. */
4190 #define FOO(x) 'x'
4191 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4193 int test (int i, double x);
4194 struct s1 {int (*f) (int a);};
4195 struct s2 {int (*f) (double a);};
4196 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4197 int argc;
4198 char **argv;
4200 main ()
4202 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4204 return 0;
4206 _ACEOF
4207 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4208 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4210 CC="$ac_save_CC $ac_arg"
4211 if ac_fn_c_try_compile "$LINENO"; then :
4212 ac_cv_prog_cc_c89=$ac_arg
4214 rm -f core conftest.err conftest.$ac_objext
4215 test "x$ac_cv_prog_cc_c89" != "xno" && break
4216 done
4217 rm -f conftest.$ac_ext
4218 CC=$ac_save_CC
4221 # AC_CACHE_VAL
4222 case "x$ac_cv_prog_cc_c89" in
4224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4225 $as_echo "none needed" >&6; } ;;
4226 xno)
4227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4228 $as_echo "unsupported" >&6; } ;;
4230 CC="$CC $ac_cv_prog_cc_c89"
4231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4232 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4233 esac
4234 if test "x$ac_cv_prog_cc_c89" != xno; then :
4238 ac_ext=c
4239 ac_cpp='$CPP $CPPFLAGS'
4240 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4241 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4242 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4245 # On Suns, sometimes $CPP names a directory.
4246 if test -n "$CPP" && test -d "$CPP"; then
4247 CPP=
4250 ## If not using gcc, and on Solaris, and no CPP specified, see if
4251 ## using a Sun compiler, which needs -Xs to prevent whitespace.
4252 if test x"$GCC" != xyes && test x"$emacs_check_sunpro_c" = xyes && \
4253 test x"$CPP" = x; then
4254 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using a Sun C compiler" >&5
4255 $as_echo_n "checking whether we are using a Sun C compiler... " >&6; }
4257 if test "${emacs_cv_sunpro_c+set}" = set; then :
4258 $as_echo_n "(cached) " >&6
4259 else
4260 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4261 /* end confdefs.h. */
4264 main ()
4266 #ifndef __SUNPRO_C
4267 fail;
4268 #endif
4271 return 0;
4273 _ACEOF
4274 if ac_fn_c_try_link "$LINENO"; then :
4275 emacs_cv_sunpro_c=yes
4276 else
4277 emacs_cv_sunpro_c=no
4279 rm -f core conftest.err conftest.$ac_objext \
4280 conftest$ac_exeext conftest.$ac_ext
4283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_sunpro_c" >&5
4284 $as_echo "$emacs_cv_sunpro_c" >&6; }
4286 if test x"$emacs_cv_sunpro_c" = xyes; then
4287 NON_GNU_CPP="$CC -E -Xs"
4291 #### Some systems specify a CPP to use unless we are using GCC.
4292 #### Now that we know whether we are using GCC, we can decide whether
4293 #### to use that one.
4294 if test "x$NON_GNU_CPP" != x && test x$GCC != xyes && test "x$CPP" = x
4295 then
4296 CPP="$NON_GNU_CPP"
4299 #### Some systems specify a CC to use unless we are using GCC.
4300 #### Now that we know whether we are using GCC, we can decide whether
4301 #### to use that one.
4302 if test "x$NON_GNU_CC" != x && test x$GCC != xyes &&
4303 test x$cc_specified != xyes
4304 then
4305 CC="$NON_GNU_CC"
4308 if test x$GCC = xyes; then
4309 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
4310 else
4311 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
4314 ac_ext=c
4315 ac_cpp='$CPP $CPPFLAGS'
4316 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4317 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4318 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4320 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4321 # On Suns, sometimes $CPP names a directory.
4322 if test -n "$CPP" && test -d "$CPP"; then
4323 CPP=
4325 if test -z "$CPP"; then
4326 if test "${ac_cv_prog_CPP+set}" = set; then :
4327 $as_echo_n "(cached) " >&6
4328 else
4329 # Double quotes because CPP needs to be expanded
4330 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4332 ac_preproc_ok=false
4333 for ac_c_preproc_warn_flag in '' yes
4335 # Use a header file that comes with gcc, so configuring glibc
4336 # with a fresh cross-compiler works.
4337 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4338 # <limits.h> exists even on freestanding compilers.
4339 # On the NeXT, cc -E runs the code through the compiler's parser,
4340 # not just through cpp. "Syntax error" is here to catch this case.
4341 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4342 /* end confdefs.h. */
4343 #ifdef __STDC__
4344 # include <limits.h>
4345 #else
4346 # include <assert.h>
4347 #endif
4348 Syntax error
4349 _ACEOF
4350 if ac_fn_c_try_cpp "$LINENO"; then :
4352 else
4353 # Broken: fails on valid input.
4354 continue
4356 rm -f conftest.err conftest.$ac_ext
4358 # OK, works on sane cases. Now check whether nonexistent headers
4359 # can be detected and how.
4360 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4361 /* end confdefs.h. */
4362 #include <ac_nonexistent.h>
4363 _ACEOF
4364 if ac_fn_c_try_cpp "$LINENO"; then :
4365 # Broken: success on invalid input.
4366 continue
4367 else
4368 # Passes both tests.
4369 ac_preproc_ok=:
4370 break
4372 rm -f conftest.err conftest.$ac_ext
4374 done
4375 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4376 rm -f conftest.err conftest.$ac_ext
4377 if $ac_preproc_ok; then :
4378 break
4381 done
4382 ac_cv_prog_CPP=$CPP
4385 CPP=$ac_cv_prog_CPP
4386 else
4387 ac_cv_prog_CPP=$CPP
4389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4390 $as_echo "$CPP" >&6; }
4391 ac_preproc_ok=false
4392 for ac_c_preproc_warn_flag in '' yes
4394 # Use a header file that comes with gcc, so configuring glibc
4395 # with a fresh cross-compiler works.
4396 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4397 # <limits.h> exists even on freestanding compilers.
4398 # On the NeXT, cc -E runs the code through the compiler's parser,
4399 # not just through cpp. "Syntax error" is here to catch this case.
4400 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4401 /* end confdefs.h. */
4402 #ifdef __STDC__
4403 # include <limits.h>
4404 #else
4405 # include <assert.h>
4406 #endif
4407 Syntax error
4408 _ACEOF
4409 if ac_fn_c_try_cpp "$LINENO"; then :
4411 else
4412 # Broken: fails on valid input.
4413 continue
4415 rm -f conftest.err conftest.$ac_ext
4417 # OK, works on sane cases. Now check whether nonexistent headers
4418 # can be detected and how.
4419 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4420 /* end confdefs.h. */
4421 #include <ac_nonexistent.h>
4422 _ACEOF
4423 if ac_fn_c_try_cpp "$LINENO"; then :
4424 # Broken: success on invalid input.
4425 continue
4426 else
4427 # Passes both tests.
4428 ac_preproc_ok=:
4429 break
4431 rm -f conftest.err conftest.$ac_ext
4433 done
4434 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4435 rm -f conftest.err conftest.$ac_ext
4436 if $ac_preproc_ok; then :
4438 else
4439 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4440 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4441 as_fn_error "C preprocessor \"$CPP\" fails sanity check
4442 See \`config.log' for more details." "$LINENO" 5; }
4445 ac_ext=c
4446 ac_cpp='$CPP $CPPFLAGS'
4447 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4448 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4449 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4452 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4453 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4454 if test "${ac_cv_path_GREP+set}" = set; then :
4455 $as_echo_n "(cached) " >&6
4456 else
4457 if test -z "$GREP"; then
4458 ac_path_GREP_found=false
4459 # Loop through the user's path and test for each of PROGNAME-LIST
4460 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4461 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4463 IFS=$as_save_IFS
4464 test -z "$as_dir" && as_dir=.
4465 for ac_prog in grep ggrep; do
4466 for ac_exec_ext in '' $ac_executable_extensions; do
4467 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4468 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
4469 # Check for GNU ac_path_GREP and select it if it is found.
4470 # Check for GNU $ac_path_GREP
4471 case `"$ac_path_GREP" --version 2>&1` in
4472 *GNU*)
4473 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4475 ac_count=0
4476 $as_echo_n 0123456789 >"conftest.in"
4477 while :
4479 cat "conftest.in" "conftest.in" >"conftest.tmp"
4480 mv "conftest.tmp" "conftest.in"
4481 cp "conftest.in" "conftest.nl"
4482 $as_echo 'GREP' >> "conftest.nl"
4483 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4484 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4485 as_fn_arith $ac_count + 1 && ac_count=$as_val
4486 if test $ac_count -gt ${ac_path_GREP_max-0}; then
4487 # Best one so far, save it but keep looking for a better one
4488 ac_cv_path_GREP="$ac_path_GREP"
4489 ac_path_GREP_max=$ac_count
4491 # 10*(2^10) chars as input seems more than enough
4492 test $ac_count -gt 10 && break
4493 done
4494 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4495 esac
4497 $ac_path_GREP_found && break 3
4498 done
4499 done
4500 done
4501 IFS=$as_save_IFS
4502 if test -z "$ac_cv_path_GREP"; then
4503 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4505 else
4506 ac_cv_path_GREP=$GREP
4510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4511 $as_echo "$ac_cv_path_GREP" >&6; }
4512 GREP="$ac_cv_path_GREP"
4515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4516 $as_echo_n "checking for egrep... " >&6; }
4517 if test "${ac_cv_path_EGREP+set}" = set; then :
4518 $as_echo_n "(cached) " >&6
4519 else
4520 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4521 then ac_cv_path_EGREP="$GREP -E"
4522 else
4523 if test -z "$EGREP"; then
4524 ac_path_EGREP_found=false
4525 # Loop through the user's path and test for each of PROGNAME-LIST
4526 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4527 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4529 IFS=$as_save_IFS
4530 test -z "$as_dir" && as_dir=.
4531 for ac_prog in egrep; do
4532 for ac_exec_ext in '' $ac_executable_extensions; do
4533 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4534 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
4535 # Check for GNU ac_path_EGREP and select it if it is found.
4536 # Check for GNU $ac_path_EGREP
4537 case `"$ac_path_EGREP" --version 2>&1` in
4538 *GNU*)
4539 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4541 ac_count=0
4542 $as_echo_n 0123456789 >"conftest.in"
4543 while :
4545 cat "conftest.in" "conftest.in" >"conftest.tmp"
4546 mv "conftest.tmp" "conftest.in"
4547 cp "conftest.in" "conftest.nl"
4548 $as_echo 'EGREP' >> "conftest.nl"
4549 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4550 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4551 as_fn_arith $ac_count + 1 && ac_count=$as_val
4552 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4553 # Best one so far, save it but keep looking for a better one
4554 ac_cv_path_EGREP="$ac_path_EGREP"
4555 ac_path_EGREP_max=$ac_count
4557 # 10*(2^10) chars as input seems more than enough
4558 test $ac_count -gt 10 && break
4559 done
4560 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4561 esac
4563 $ac_path_EGREP_found && break 3
4564 done
4565 done
4566 done
4567 IFS=$as_save_IFS
4568 if test -z "$ac_cv_path_EGREP"; then
4569 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4571 else
4572 ac_cv_path_EGREP=$EGREP
4577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4578 $as_echo "$ac_cv_path_EGREP" >&6; }
4579 EGREP="$ac_cv_path_EGREP"
4582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4583 $as_echo_n "checking for ANSI C header files... " >&6; }
4584 if test "${ac_cv_header_stdc+set}" = set; then :
4585 $as_echo_n "(cached) " >&6
4586 else
4587 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4588 /* end confdefs.h. */
4589 #include <stdlib.h>
4590 #include <stdarg.h>
4591 #include <string.h>
4592 #include <float.h>
4595 main ()
4599 return 0;
4601 _ACEOF
4602 if ac_fn_c_try_compile "$LINENO"; then :
4603 ac_cv_header_stdc=yes
4604 else
4605 ac_cv_header_stdc=no
4607 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4609 if test $ac_cv_header_stdc = yes; then
4610 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4611 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4612 /* end confdefs.h. */
4613 #include <string.h>
4615 _ACEOF
4616 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4617 $EGREP "memchr" >/dev/null 2>&1; then :
4619 else
4620 ac_cv_header_stdc=no
4622 rm -f conftest*
4626 if test $ac_cv_header_stdc = yes; then
4627 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4628 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4629 /* end confdefs.h. */
4630 #include <stdlib.h>
4632 _ACEOF
4633 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4634 $EGREP "free" >/dev/null 2>&1; then :
4636 else
4637 ac_cv_header_stdc=no
4639 rm -f conftest*
4643 if test $ac_cv_header_stdc = yes; then
4644 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4645 if test "$cross_compiling" = yes; then :
4647 else
4648 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4649 /* end confdefs.h. */
4650 #include <ctype.h>
4651 #include <stdlib.h>
4652 #if ((' ' & 0x0FF) == 0x020)
4653 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4654 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4655 #else
4656 # define ISLOWER(c) \
4657 (('a' <= (c) && (c) <= 'i') \
4658 || ('j' <= (c) && (c) <= 'r') \
4659 || ('s' <= (c) && (c) <= 'z'))
4660 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4661 #endif
4663 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4665 main ()
4667 int i;
4668 for (i = 0; i < 256; i++)
4669 if (XOR (islower (i), ISLOWER (i))
4670 || toupper (i) != TOUPPER (i))
4671 return 2;
4672 return 0;
4674 _ACEOF
4675 if ac_fn_c_try_run "$LINENO"; then :
4677 else
4678 ac_cv_header_stdc=no
4680 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4681 conftest.$ac_objext conftest.beam conftest.$ac_ext
4686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4687 $as_echo "$ac_cv_header_stdc" >&6; }
4688 if test $ac_cv_header_stdc = yes; then
4690 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4694 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4695 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4696 inttypes.h stdint.h unistd.h
4697 do :
4698 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4699 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4701 eval as_val=\$$as_ac_Header
4702 if test "x$as_val" = x""yes; then :
4703 cat >>confdefs.h <<_ACEOF
4704 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4705 _ACEOF
4709 done
4713 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4714 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
4715 MINIX=yes
4716 else
4717 MINIX=
4721 if test "$MINIX" = yes; then
4723 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4726 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4729 $as_echo "#define _MINIX 1" >>confdefs.h
4734 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4735 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4736 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
4737 $as_echo_n "(cached) " >&6
4738 else
4739 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4740 /* end confdefs.h. */
4742 # define __EXTENSIONS__ 1
4743 $ac_includes_default
4745 main ()
4749 return 0;
4751 _ACEOF
4752 if ac_fn_c_try_compile "$LINENO"; then :
4753 ac_cv_safe_to_define___extensions__=yes
4754 else
4755 ac_cv_safe_to_define___extensions__=no
4757 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4760 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4761 test $ac_cv_safe_to_define___extensions__ = yes &&
4762 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4764 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4766 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4768 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4770 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4774 ### Use -Wno-pointer-sign if the compiler supports it
4775 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wno-pointer-sign" >&5
4776 $as_echo_n "checking whether gcc understands -Wno-pointer-sign... " >&6; }
4777 SAVE_CFLAGS="$CFLAGS"
4778 CFLAGS="$CFLAGS -Wno-pointer-sign"
4779 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4780 /* end confdefs.h. */
4783 main ()
4787 return 0;
4789 _ACEOF
4790 if ac_fn_c_try_compile "$LINENO"; then :
4791 has_option=yes
4792 else
4793 has_option=no
4795 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4796 if test $has_option = yes; then
4797 C_WARNINGS_SWITCH="-Wno-pointer-sign $C_WARNINGS_SWITCH"
4799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
4800 $as_echo "$has_option" >&6; }
4801 CFLAGS="$SAVE_CFLAGS"
4802 unset has_option
4803 unset SAVE_CFLAGS
4805 ### Use -Wdeclaration-after-statement if the compiler supports it
4806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wdeclaration-after-statement" >&5
4807 $as_echo_n "checking whether gcc understands -Wdeclaration-after-statement... " >&6; }
4808 SAVE_CFLAGS="$CFLAGS"
4809 CFLAGS="$CFLAGS -Wdeclaration-after-statement"
4810 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4811 /* end confdefs.h. */
4814 main ()
4818 return 0;
4820 _ACEOF
4821 if ac_fn_c_try_compile "$LINENO"; then :
4822 has_option=yes
4823 else
4824 has_option=no
4826 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4827 if test $has_option = yes; then
4828 C_WARNINGS_SWITCH="-Wdeclaration-after-statement $C_WARNINGS_SWITCH"
4830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
4831 $as_echo "$has_option" >&6; }
4832 CFLAGS="$SAVE_CFLAGS"
4833 unset has_option
4834 unset SAVE_CFLAGS
4836 ### Use -Wold-style-definition if the compiler supports it
4837 # This can be removed when conversion to standard C is finished.
4838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wold-style-definition" >&5
4839 $as_echo_n "checking whether gcc understands -Wold-style-definition... " >&6; }
4840 SAVE_CFLAGS="$CFLAGS"
4841 CFLAGS="$CFLAGS -Wold-style-definition"
4842 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4843 /* end confdefs.h. */
4846 main ()
4850 return 0;
4852 _ACEOF
4853 if ac_fn_c_try_compile "$LINENO"; then :
4854 has_option=yes
4855 else
4856 has_option=no
4858 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4859 if test $has_option = yes; then
4860 C_WARNINGS_SWITCH="-Wold-style-definition $C_WARNINGS_SWITCH"
4862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
4863 $as_echo "$has_option" >&6; }
4864 CFLAGS="$SAVE_CFLAGS"
4865 unset has_option
4866 unset SAVE_CFLAGS
4868 ### Use -Wimplicit-function-declaration if the compiler supports it
4869 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wimplicit-function-declaration" >&5
4870 $as_echo_n "checking whether gcc understands -Wimplicit-function-declaration... " >&6; }
4871 SAVE_CFLAGS="$CFLAGS"
4872 CFLAGS="$CFLAGS -Wimplicit-function-declaration"
4873 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4874 /* end confdefs.h. */
4877 main ()
4881 return 0;
4883 _ACEOF
4884 if ac_fn_c_try_compile "$LINENO"; then :
4885 has_option=yes
4886 else
4887 has_option=no
4889 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4890 if test $has_option = yes; then
4891 C_WARNINGS_SWITCH="-Wimplicit-function-declaration $C_WARNINGS_SWITCH"
4893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
4894 $as_echo "$has_option" >&6; }
4895 CFLAGS="$SAVE_CFLAGS"
4896 unset has_option
4897 unset SAVE_CFLAGS
4902 #### Some other nice autoconf tests.
4904 ac_ext=c
4905 ac_cpp='$CPP $CPPFLAGS'
4906 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4907 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4908 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4910 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4911 # On Suns, sometimes $CPP names a directory.
4912 if test -n "$CPP" && test -d "$CPP"; then
4913 CPP=
4915 if test -z "$CPP"; then
4916 if test "${ac_cv_prog_CPP+set}" = set; then :
4917 $as_echo_n "(cached) " >&6
4918 else
4919 # Double quotes because CPP needs to be expanded
4920 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4922 ac_preproc_ok=false
4923 for ac_c_preproc_warn_flag in '' yes
4925 # Use a header file that comes with gcc, so configuring glibc
4926 # with a fresh cross-compiler works.
4927 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4928 # <limits.h> exists even on freestanding compilers.
4929 # On the NeXT, cc -E runs the code through the compiler's parser,
4930 # not just through cpp. "Syntax error" is here to catch this case.
4931 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4932 /* end confdefs.h. */
4933 #ifdef __STDC__
4934 # include <limits.h>
4935 #else
4936 # include <assert.h>
4937 #endif
4938 Syntax error
4939 _ACEOF
4940 if ac_fn_c_try_cpp "$LINENO"; then :
4942 else
4943 # Broken: fails on valid input.
4944 continue
4946 rm -f conftest.err conftest.$ac_ext
4948 # OK, works on sane cases. Now check whether nonexistent headers
4949 # can be detected and how.
4950 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4951 /* end confdefs.h. */
4952 #include <ac_nonexistent.h>
4953 _ACEOF
4954 if ac_fn_c_try_cpp "$LINENO"; then :
4955 # Broken: success on invalid input.
4956 continue
4957 else
4958 # Passes both tests.
4959 ac_preproc_ok=:
4960 break
4962 rm -f conftest.err conftest.$ac_ext
4964 done
4965 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4966 rm -f conftest.err conftest.$ac_ext
4967 if $ac_preproc_ok; then :
4968 break
4971 done
4972 ac_cv_prog_CPP=$CPP
4975 CPP=$ac_cv_prog_CPP
4976 else
4977 ac_cv_prog_CPP=$CPP
4979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4980 $as_echo "$CPP" >&6; }
4981 ac_preproc_ok=false
4982 for ac_c_preproc_warn_flag in '' yes
4984 # Use a header file that comes with gcc, so configuring glibc
4985 # with a fresh cross-compiler works.
4986 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4987 # <limits.h> exists even on freestanding compilers.
4988 # On the NeXT, cc -E runs the code through the compiler's parser,
4989 # not just through cpp. "Syntax error" is here to catch this case.
4990 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4991 /* end confdefs.h. */
4992 #ifdef __STDC__
4993 # include <limits.h>
4994 #else
4995 # include <assert.h>
4996 #endif
4997 Syntax error
4998 _ACEOF
4999 if ac_fn_c_try_cpp "$LINENO"; then :
5001 else
5002 # Broken: fails on valid input.
5003 continue
5005 rm -f conftest.err conftest.$ac_ext
5007 # OK, works on sane cases. Now check whether nonexistent headers
5008 # can be detected and how.
5009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5010 /* end confdefs.h. */
5011 #include <ac_nonexistent.h>
5012 _ACEOF
5013 if ac_fn_c_try_cpp "$LINENO"; then :
5014 # Broken: success on invalid input.
5015 continue
5016 else
5017 # Passes both tests.
5018 ac_preproc_ok=:
5019 break
5021 rm -f conftest.err conftest.$ac_ext
5023 done
5024 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5025 rm -f conftest.err conftest.$ac_ext
5026 if $ac_preproc_ok; then :
5028 else
5029 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5030 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5031 as_fn_error "C preprocessor \"$CPP\" fails sanity check
5032 See \`config.log' for more details." "$LINENO" 5; }
5035 ac_ext=c
5036 ac_cpp='$CPP $CPPFLAGS'
5037 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5038 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5039 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5041 # Find a good install program. We prefer a C program (faster),
5042 # so one script is as good as another. But avoid the broken or
5043 # incompatible versions:
5044 # SysV /etc/install, /usr/sbin/install
5045 # SunOS /usr/etc/install
5046 # IRIX /sbin/install
5047 # AIX /bin/install
5048 # AmigaOS /C/install, which installs bootblocks on floppy discs
5049 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
5050 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
5051 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
5052 # OS/2's system install, which has a completely different semantic
5053 # ./install, which can be erroneously created by make from ./install.sh.
5054 # Reject install programs that cannot install multiple files.
5055 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
5056 $as_echo_n "checking for a BSD-compatible install... " >&6; }
5057 if test -z "$INSTALL"; then
5058 if test "${ac_cv_path_install+set}" = set; then :
5059 $as_echo_n "(cached) " >&6
5060 else
5061 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5062 for as_dir in $PATH
5064 IFS=$as_save_IFS
5065 test -z "$as_dir" && as_dir=.
5066 # Account for people who put trailing slashes in PATH elements.
5067 case $as_dir/ in #((
5068 ./ | .// | /[cC]/* | \
5069 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
5070 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
5071 /usr/ucb/* ) ;;
5073 # OSF1 and SCO ODT 3.0 have their own names for install.
5074 # Don't use installbsd from OSF since it installs stuff as root
5075 # by default.
5076 for ac_prog in ginstall scoinst install; do
5077 for ac_exec_ext in '' $ac_executable_extensions; do
5078 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
5079 if test $ac_prog = install &&
5080 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
5081 # AIX install. It has an incompatible calling convention.
5083 elif test $ac_prog = install &&
5084 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
5085 # program-specific install script used by HP pwplus--don't use.
5087 else
5088 rm -rf conftest.one conftest.two conftest.dir
5089 echo one > conftest.one
5090 echo two > conftest.two
5091 mkdir conftest.dir
5092 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
5093 test -s conftest.one && test -s conftest.two &&
5094 test -s conftest.dir/conftest.one &&
5095 test -s conftest.dir/conftest.two
5096 then
5097 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
5098 break 3
5102 done
5103 done
5105 esac
5107 done
5108 IFS=$as_save_IFS
5110 rm -rf conftest.one conftest.two conftest.dir
5113 if test "${ac_cv_path_install+set}" = set; then
5114 INSTALL=$ac_cv_path_install
5115 else
5116 # As a last resort, use the slow shell script. Don't cache a
5117 # value for INSTALL within a source directory, because that will
5118 # break other packages using the cache if that directory is
5119 # removed, or if the value is a relative name.
5120 INSTALL=$ac_install_sh
5123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
5124 $as_echo "$INSTALL" >&6; }
5126 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
5127 # It thinks the first close brace ends the variable substitution.
5128 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
5130 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
5132 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
5134 if test "x$RANLIB" = x; then
5135 if test -n "$ac_tool_prefix"; then
5136 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5137 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5139 $as_echo_n "checking for $ac_word... " >&6; }
5140 if test "${ac_cv_prog_RANLIB+set}" = set; then :
5141 $as_echo_n "(cached) " >&6
5142 else
5143 if test -n "$RANLIB"; then
5144 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5145 else
5146 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5147 for as_dir in $PATH
5149 IFS=$as_save_IFS
5150 test -z "$as_dir" && as_dir=.
5151 for ac_exec_ext in '' $ac_executable_extensions; do
5152 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5153 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5154 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5155 break 2
5157 done
5158 done
5159 IFS=$as_save_IFS
5163 RANLIB=$ac_cv_prog_RANLIB
5164 if test -n "$RANLIB"; then
5165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
5166 $as_echo "$RANLIB" >&6; }
5167 else
5168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5169 $as_echo "no" >&6; }
5174 if test -z "$ac_cv_prog_RANLIB"; then
5175 ac_ct_RANLIB=$RANLIB
5176 # Extract the first word of "ranlib", so it can be a program name with args.
5177 set dummy ranlib; ac_word=$2
5178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5179 $as_echo_n "checking for $ac_word... " >&6; }
5180 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
5181 $as_echo_n "(cached) " >&6
5182 else
5183 if test -n "$ac_ct_RANLIB"; then
5184 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5185 else
5186 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5187 for as_dir in $PATH
5189 IFS=$as_save_IFS
5190 test -z "$as_dir" && as_dir=.
5191 for ac_exec_ext in '' $ac_executable_extensions; do
5192 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5193 ac_cv_prog_ac_ct_RANLIB="ranlib"
5194 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5195 break 2
5197 done
5198 done
5199 IFS=$as_save_IFS
5203 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5204 if test -n "$ac_ct_RANLIB"; then
5205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
5206 $as_echo "$ac_ct_RANLIB" >&6; }
5207 else
5208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5209 $as_echo "no" >&6; }
5212 if test "x$ac_ct_RANLIB" = x; then
5213 RANLIB=":"
5214 else
5215 case $cross_compiling:$ac_tool_warned in
5216 yes:)
5217 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5218 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5219 ac_tool_warned=yes ;;
5220 esac
5221 RANLIB=$ac_ct_RANLIB
5223 else
5224 RANLIB="$ac_cv_prog_RANLIB"
5229 ## Although we're running on an amd64 kernel, we're actually compiling for
5230 ## the x86 architecture. The user should probably have provided an
5231 ## explicit --build to `configure', but if everything else than the kernel
5232 ## is running in i386 mode, we can help them out.
5233 if test "$machine" = "amdx86-64"; then
5234 ac_fn_c_check_decl "$LINENO" "i386" "ac_cv_have_decl_i386" "$ac_includes_default"
5235 if test "x$ac_cv_have_decl_i386" = x""yes; then :
5239 if test "$ac_cv_have_decl_i386" = "yes"; then
5240 canonical=`echo "$canonical" | sed -e 's/^amd64/i386/' -e 's/^x86_64/i386/'`
5241 machine=intel386
5242 machfile="m/${machine}.h"
5246 # Extract the first word of "install-info", so it can be a program name with args.
5247 set dummy install-info; ac_word=$2
5248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5249 $as_echo_n "checking for $ac_word... " >&6; }
5250 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
5251 $as_echo_n "(cached) " >&6
5252 else
5253 case $INSTALL_INFO in
5254 [\\/]* | ?:[\\/]*)
5255 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
5258 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5259 for as_dir in $PATH
5261 IFS=$as_save_IFS
5262 test -z "$as_dir" && as_dir=.
5263 for ac_exec_ext in '' $ac_executable_extensions; do
5264 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5265 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
5266 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5267 break 2
5269 done
5270 done
5271 IFS=$as_save_IFS
5274 esac
5276 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
5277 if test -n "$INSTALL_INFO"; then
5278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
5279 $as_echo "$INSTALL_INFO" >&6; }
5280 else
5281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5282 $as_echo "no" >&6; }
5286 # Extract the first word of "install-info", so it can be a program name with args.
5287 set dummy install-info; ac_word=$2
5288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5289 $as_echo_n "checking for $ac_word... " >&6; }
5290 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
5291 $as_echo_n "(cached) " >&6
5292 else
5293 case $INSTALL_INFO in
5294 [\\/]* | ?:[\\/]*)
5295 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
5298 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5299 for as_dir in /usr/sbin
5301 IFS=$as_save_IFS
5302 test -z "$as_dir" && as_dir=.
5303 for ac_exec_ext in '' $ac_executable_extensions; do
5304 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5305 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
5306 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5307 break 2
5309 done
5310 done
5311 IFS=$as_save_IFS
5314 esac
5316 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
5317 if test -n "$INSTALL_INFO"; then
5318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
5319 $as_echo "$INSTALL_INFO" >&6; }
5320 else
5321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5322 $as_echo "no" >&6; }
5326 # Extract the first word of "install-info", so it can be a program name with args.
5327 set dummy install-info; ac_word=$2
5328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5329 $as_echo_n "checking for $ac_word... " >&6; }
5330 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
5331 $as_echo_n "(cached) " >&6
5332 else
5333 case $INSTALL_INFO in
5334 [\\/]* | ?:[\\/]*)
5335 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
5338 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5339 for as_dir in /sbin
5341 IFS=$as_save_IFS
5342 test -z "$as_dir" && as_dir=.
5343 for ac_exec_ext in '' $ac_executable_extensions; do
5344 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5345 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
5346 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5347 break 2
5349 done
5350 done
5351 IFS=$as_save_IFS
5353 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
5355 esac
5357 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
5358 if test -n "$INSTALL_INFO"; then
5359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
5360 $as_echo "$INSTALL_INFO" >&6; }
5361 else
5362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5363 $as_echo "no" >&6; }
5367 # Extract the first word of "gzip", so it can be a program name with args.
5368 set dummy gzip; ac_word=$2
5369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5370 $as_echo_n "checking for $ac_word... " >&6; }
5371 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
5372 $as_echo_n "(cached) " >&6
5373 else
5374 case $GZIP_PROG in
5375 [\\/]* | ?:[\\/]*)
5376 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
5379 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5380 for as_dir in $PATH
5382 IFS=$as_save_IFS
5383 test -z "$as_dir" && as_dir=.
5384 for ac_exec_ext in '' $ac_executable_extensions; do
5385 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5386 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
5387 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5388 break 2
5390 done
5391 done
5392 IFS=$as_save_IFS
5395 esac
5397 GZIP_PROG=$ac_cv_path_GZIP_PROG
5398 if test -n "$GZIP_PROG"; then
5399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
5400 $as_echo "$GZIP_PROG" >&6; }
5401 else
5402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5403 $as_echo "no" >&6; }
5409 ## Need makeinfo >= 4.6 (?) to build the manuals.
5410 # Extract the first word of "makeinfo", so it can be a program name with args.
5411 set dummy makeinfo; ac_word=$2
5412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5413 $as_echo_n "checking for $ac_word... " >&6; }
5414 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
5415 $as_echo_n "(cached) " >&6
5416 else
5417 case $MAKEINFO in
5418 [\\/]* | ?:[\\/]*)
5419 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
5422 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5423 for as_dir in $PATH
5425 IFS=$as_save_IFS
5426 test -z "$as_dir" && as_dir=.
5427 for ac_exec_ext in '' $ac_executable_extensions; do
5428 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5429 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
5430 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5431 break 2
5433 done
5434 done
5435 IFS=$as_save_IFS
5437 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
5439 esac
5441 MAKEINFO=$ac_cv_path_MAKEINFO
5442 if test -n "$MAKEINFO"; then
5443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
5444 $as_echo "$MAKEINFO" >&6; }
5445 else
5446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5447 $as_echo "no" >&6; }
5451 if test "$MAKEINFO" != "no" && \
5452 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
5453 MAKEINFO=no
5456 ## Makeinfo is unusual. For a released Emacs, the manuals are
5457 ## pre-built, and not deleted by the normal clean rules. makeinfo is
5458 ## therefore in the category of "special tools" not normally required, which
5459 ## configure does not have to check for (eg autoconf itself).
5460 ## In a Bazaar checkout on the other hand, the manuals are not included.
5461 ## So makeinfo is a requirement to build from Bazaar, and configure
5462 ## should test for it as it does for any other build requirement.
5463 ## We use the presence of $srcdir/info/emacs to distinguish a release,
5464 ## with pre-built manuals, from a Bazaar checkout.
5465 if test "$MAKEINFO" = "no"; then
5466 if test "x${with_makeinfo}" = "xno"; then
5467 MAKEINFO=off
5468 elif test ! -e $srcdir/info/emacs; then
5469 as_fn_error "You do not seem to have makeinfo >= 4.6, and your
5470 source tree does not seem to have pre-built manuals in the \`info' directory.
5471 Either install a suitable version of makeinfo, or re-run configure
5472 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
5477 if test x$GCC = xyes && test "x$GCC_LINK_TEST_OPTIONS" != x
5478 then
5479 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
5482 if test x$GCC = x && test "x$NON_GCC_LINK_TEST_OPTIONS" != x
5483 then
5484 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
5488 late_LDFLAGS=$LDFLAGS
5489 if test "$GCC" = yes; then
5490 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
5491 else
5492 LDFLAGS="$LDFLAGS -znocombreloc"
5495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
5496 $as_echo_n "checking for -znocombreloc... " >&6; }
5497 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5498 /* end confdefs.h. */
5499 main(){return 0;}
5500 _ACEOF
5501 if ac_fn_c_try_link "$LINENO"; then :
5502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5503 $as_echo "yes" >&6; }
5504 else
5505 LDFLAGS=$late_LDFLAGS
5506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5507 $as_echo "no" >&6; }
5509 rm -f core conftest.err conftest.$ac_objext \
5510 conftest$ac_exeext conftest.$ac_ext
5513 # The value of CPP is a quoted variable reference, so we need to do this
5514 # to get its actual value...
5515 CPP=`eval "echo $CPP"`
5518 CANNOT_DUMP=no
5519 case "$opsys" in
5520 your-opsys-here)
5521 CANNOT_DUMP=yes
5523 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
5526 esac
5530 UNEXEC_OBJ=unexelf.o
5531 case "$opsys" in
5532 # MSDOS uses unexcoff.o
5533 # MSWindows uses unexw32.o
5534 aix4-2)
5535 UNEXEC_OBJ=unexaix.o
5537 cygwin)
5538 UNEXEC_OBJ=unexcw.o
5540 darwin)
5541 UNEXEC_OBJ=unexmacosx.o
5543 hpux10-20 | hpux11)
5544 UNEXEC_OBJ=unexhp9k800.o
5546 sol2-10)
5547 # Use the Solaris dldump() function, called from unexsol.c, to dump
5548 # emacs, instead of the generic ELF dump code found in unexelf.c.
5549 # The resulting binary has a complete symbol table, and is better
5550 # for debugging and other observability tools (debuggers, pstack, etc).
5552 # If you encounter a problem using dldump(), please consider sending
5553 # a message to the OpenSolaris tools-linking mailing list:
5554 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
5556 # It is likely that dldump() works with older Solaris too, but this has
5557 # not been tested, so for now this change is for Solaris 10 or newer.
5558 UNEXEC_OBJ=unexsol.o
5560 esac
5562 LD_SWITCH_SYSTEM=
5563 case "$opsys" in
5564 freebsd)
5565 ## Let `ld' find image libs and similar things in /usr/local/lib.
5566 ## The system compiler, GCC, has apparently been modified to not
5567 ## look there, contrary to what a stock GCC would do.
5568 LD_SWITCH_SYSTEM=-L/usr/local/lib
5571 gnu-linux)
5572 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
5573 test "$machine" = "mips" && LD_SWITCH_SYSTEM="-G 0"
5576 netbsd)
5577 LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
5580 openbsd)
5581 ## Han Boetes <han@mijncomputer.nl> says this is necessary,
5582 ## otherwise Emacs dumps core on elf systems.
5583 LD_SWITCH_SYSTEM="-Z"
5585 esac
5588 ac_link="$ac_link $LD_SWITCH_SYSTEM"
5590 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_AUX,
5591 ## which has not been defined yet. When this was handled with cpp,
5592 ## it was expanded to null when configure sourced the s/*.h file.
5593 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
5594 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
5595 ## (or somesuch), but because it is supposed to go at the _front_
5596 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
5597 ## Compare with the gnu-linux case below, which added to the end
5598 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
5599 ## LD_SWITCH_SYSTEM_TEMACS.
5600 case "$opsys" in
5601 netbsd|openbsd)
5602 ## _AUX_RPATH is like _AUX, but uses -rpath instead of -R.
5603 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_AUX_RPATH) $LD_SWITCH_SYSTEM" ;;
5604 esac
5607 C_SWITCH_MACHINE=
5608 if test "$machine" = "alpha"; then
5609 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
5610 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
5614 if test "$ac_cv_have_decl___ELF__" = "yes"; then
5615 ## With ELF, make sure that all common symbols get allocated to in the
5616 ## data section. Otherwise, the dump of temacs may miss variables in
5617 ## the shared library that have been initialized. For example, with
5618 ## GNU libc, __malloc_initialized would normally be resolved to the
5619 ## shared library's .bss section, which is fatal.
5620 if test "x$GCC" = "xyes"; then
5621 C_SWITCH_MACHINE="-fno-common"
5622 else
5623 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
5625 else
5626 UNEXEC_OBJ=unexalpha.o
5633 C_SWITCH_SYSTEM=
5634 ## Some programs in src produce warnings saying certain subprograms
5635 ## are too complex and need a MAXMEM value greater than 2000 for
5636 ## additional optimization. --nils@exp-math.uni-essen.de
5637 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
5638 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
5639 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
5640 ## It is redundant in glibc2, since we define _GNU_SOURCE.
5644 LIBS_SYSTEM=
5645 case "$opsys" in
5646 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
5647 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
5649 freebsd) LIBS_SYSTEM="-lutil" ;;
5651 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
5653 sol2*) LIBS_SYSTEM="-lsocket -lnsl -lkstat" ;;
5655 ## Motif needs -lgen.
5656 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
5657 esac
5661 ### Make sure subsequent tests use flags consistent with the build flags.
5663 if test x"${OVERRIDE_CPPFLAGS}" != x; then
5664 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
5665 else
5666 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
5671 # Check whether --enable-largefile was given.
5672 if test "${enable_largefile+set}" = set; then :
5673 enableval=$enable_largefile;
5676 if test "$enable_largefile" != no; then
5678 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
5679 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
5680 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
5681 $as_echo_n "(cached) " >&6
5682 else
5683 ac_cv_sys_largefile_CC=no
5684 if test "$GCC" != yes; then
5685 ac_save_CC=$CC
5686 while :; do
5687 # IRIX 6.2 and later do not support large files by default,
5688 # so use the C compiler's -n32 option if that helps.
5689 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5690 /* end confdefs.h. */
5691 #include <sys/types.h>
5692 /* Check that off_t can represent 2**63 - 1 correctly.
5693 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5694 since some C++ compilers masquerading as C compilers
5695 incorrectly reject 9223372036854775807. */
5696 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5697 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5698 && LARGE_OFF_T % 2147483647 == 1)
5699 ? 1 : -1];
5701 main ()
5705 return 0;
5707 _ACEOF
5708 if ac_fn_c_try_compile "$LINENO"; then :
5709 break
5711 rm -f core conftest.err conftest.$ac_objext
5712 CC="$CC -n32"
5713 if ac_fn_c_try_compile "$LINENO"; then :
5714 ac_cv_sys_largefile_CC=' -n32'; break
5716 rm -f core conftest.err conftest.$ac_objext
5717 break
5718 done
5719 CC=$ac_save_CC
5720 rm -f conftest.$ac_ext
5723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
5724 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
5725 if test "$ac_cv_sys_largefile_CC" != no; then
5726 CC=$CC$ac_cv_sys_largefile_CC
5729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
5730 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
5731 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
5732 $as_echo_n "(cached) " >&6
5733 else
5734 while :; do
5735 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5736 /* end confdefs.h. */
5737 #include <sys/types.h>
5738 /* Check that off_t can represent 2**63 - 1 correctly.
5739 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5740 since some C++ compilers masquerading as C compilers
5741 incorrectly reject 9223372036854775807. */
5742 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5743 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5744 && LARGE_OFF_T % 2147483647 == 1)
5745 ? 1 : -1];
5747 main ()
5751 return 0;
5753 _ACEOF
5754 if ac_fn_c_try_compile "$LINENO"; then :
5755 ac_cv_sys_file_offset_bits=no; break
5757 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5758 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5759 /* end confdefs.h. */
5760 #define _FILE_OFFSET_BITS 64
5761 #include <sys/types.h>
5762 /* Check that off_t can represent 2**63 - 1 correctly.
5763 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5764 since some C++ compilers masquerading as C compilers
5765 incorrectly reject 9223372036854775807. */
5766 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5767 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5768 && LARGE_OFF_T % 2147483647 == 1)
5769 ? 1 : -1];
5771 main ()
5775 return 0;
5777 _ACEOF
5778 if ac_fn_c_try_compile "$LINENO"; then :
5779 ac_cv_sys_file_offset_bits=64; break
5781 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5782 ac_cv_sys_file_offset_bits=unknown
5783 break
5784 done
5786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
5787 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
5788 case $ac_cv_sys_file_offset_bits in #(
5789 no | unknown) ;;
5791 cat >>confdefs.h <<_ACEOF
5792 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
5793 _ACEOF
5795 esac
5796 rm -rf conftest*
5797 if test $ac_cv_sys_file_offset_bits = unknown; then
5798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
5799 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
5800 if test "${ac_cv_sys_large_files+set}" = set; then :
5801 $as_echo_n "(cached) " >&6
5802 else
5803 while :; do
5804 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5805 /* end confdefs.h. */
5806 #include <sys/types.h>
5807 /* Check that off_t can represent 2**63 - 1 correctly.
5808 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5809 since some C++ compilers masquerading as C compilers
5810 incorrectly reject 9223372036854775807. */
5811 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5812 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5813 && LARGE_OFF_T % 2147483647 == 1)
5814 ? 1 : -1];
5816 main ()
5820 return 0;
5822 _ACEOF
5823 if ac_fn_c_try_compile "$LINENO"; then :
5824 ac_cv_sys_large_files=no; break
5826 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5827 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5828 /* end confdefs.h. */
5829 #define _LARGE_FILES 1
5830 #include <sys/types.h>
5831 /* Check that off_t can represent 2**63 - 1 correctly.
5832 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5833 since some C++ compilers masquerading as C compilers
5834 incorrectly reject 9223372036854775807. */
5835 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5836 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5837 && LARGE_OFF_T % 2147483647 == 1)
5838 ? 1 : -1];
5840 main ()
5844 return 0;
5846 _ACEOF
5847 if ac_fn_c_try_compile "$LINENO"; then :
5848 ac_cv_sys_large_files=1; break
5850 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5851 ac_cv_sys_large_files=unknown
5852 break
5853 done
5855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
5856 $as_echo "$ac_cv_sys_large_files" >&6; }
5857 case $ac_cv_sys_large_files in #(
5858 no | unknown) ;;
5860 cat >>confdefs.h <<_ACEOF
5861 #define _LARGE_FILES $ac_cv_sys_large_files
5862 _ACEOF
5864 esac
5865 rm -rf conftest*
5871 ## If user specified a crt-dir, use that unconditionally.
5872 if test "X$CRT_DIR" = "X"; then
5874 case "$canonical" in
5875 x86_64-*-linux-gnu* | s390x-*-linux-gnu*)
5876 ## On x86-64 and s390x GNU/Linux distributions, the standard library
5877 ## can be in a variety of places. We only try /usr/lib64 and /usr/lib.
5878 ## For anything else (eg /usr/lib32), it is up the user to specify
5879 ## the location (bug#5655).
5880 ## Test for crtn.o, not just the directory, because sometimes the
5881 ## directory exists but does not have the relevant files (bug#1287).
5882 ## FIXME better to test for binary compatibility somehow.
5883 test -e /usr/lib64/crtn.o && CRT_DIR=/usr/lib64
5886 powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*) CRT_DIR=/usr/lib64 ;;
5887 esac
5889 case "$opsys" in
5890 hpux10-20) CRT_DIR=/lib ;;
5891 esac
5893 ## Default is /usr/lib.
5894 test "X$CRT_DIR" = "X" && CRT_DIR=/usr/lib
5896 else
5898 ## Some platforms don't use any of these files, so it is not
5899 ## appropriate to put this test outside the if block.
5900 test -e $CRT_DIR/crtn.o || test -e $CRT_DIR/crt0.o || \
5901 as_fn_error "crt*.o not found in specified location." "$LINENO" 5
5907 LIB_MATH=-lm
5908 LIB_STANDARD=
5909 START_FILES=
5911 case $opsys in
5912 cygwin )
5913 LIB_MATH=
5914 START_FILES='pre-crt0.o'
5916 darwin )
5917 ## Adding -lm confuses the dynamic linker, so omit it.
5918 LIB_MATH=
5919 START_FILES='pre-crt0.o'
5921 freebsd )
5922 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
5923 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
5925 gnu-linux | gnu-kfreebsd )
5926 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
5927 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
5929 hpux10-20 | hpux11 )
5930 LIB_STANDARD=-lc
5931 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o'
5933 netbsd | openbsd )
5934 if test -f $CRT_DIR/crti.o; then
5935 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
5936 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
5937 else
5938 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
5939 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
5942 esac
5950 if test "${with_sound}" != "no"; then
5951 # Sound support for GNU/Linux and the free BSDs.
5952 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
5953 do :
5954 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
5955 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
5956 eval as_val=\$$as_ac_Header
5957 if test "x$as_val" = x""yes; then :
5958 cat >>confdefs.h <<_ACEOF
5959 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
5960 _ACEOF
5961 have_sound_header=yes
5964 done
5966 # Emulation library used on NetBSD.
5967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
5968 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
5969 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
5970 $as_echo_n "(cached) " >&6
5971 else
5972 ac_check_lib_save_LIBS=$LIBS
5973 LIBS="-lossaudio $LIBS"
5974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5975 /* end confdefs.h. */
5977 /* Override any GCC internal prototype to avoid an error.
5978 Use char because int might match the return type of a GCC
5979 builtin and then its argument prototype would still apply. */
5980 #ifdef __cplusplus
5981 extern "C"
5982 #endif
5983 char _oss_ioctl ();
5985 main ()
5987 return _oss_ioctl ();
5989 return 0;
5991 _ACEOF
5992 if ac_fn_c_try_link "$LINENO"; then :
5993 ac_cv_lib_ossaudio__oss_ioctl=yes
5994 else
5995 ac_cv_lib_ossaudio__oss_ioctl=no
5997 rm -f core conftest.err conftest.$ac_objext \
5998 conftest$ac_exeext conftest.$ac_ext
5999 LIBS=$ac_check_lib_save_LIBS
6001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
6002 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
6003 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
6004 LIBSOUND=-lossaudio
6005 else
6006 LIBSOUND=
6011 ALSA_REQUIRED=1.0.0
6012 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
6014 succeeded=no
6016 # Extract the first word of "pkg-config", so it can be a program name with args.
6017 set dummy pkg-config; ac_word=$2
6018 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6019 $as_echo_n "checking for $ac_word... " >&6; }
6020 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
6021 $as_echo_n "(cached) " >&6
6022 else
6023 case $PKG_CONFIG in
6024 [\\/]* | ?:[\\/]*)
6025 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
6028 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6029 for as_dir in $PATH
6031 IFS=$as_save_IFS
6032 test -z "$as_dir" && as_dir=.
6033 for ac_exec_ext in '' $ac_executable_extensions; do
6034 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6035 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
6036 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6037 break 2
6039 done
6040 done
6041 IFS=$as_save_IFS
6043 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
6045 esac
6047 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
6048 if test -n "$PKG_CONFIG"; then
6049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
6050 $as_echo "$PKG_CONFIG" >&6; }
6051 else
6052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6053 $as_echo "no" >&6; }
6058 if test "$PKG_CONFIG" = "no" ; then
6059 HAVE_ALSA=no
6060 else
6061 PKG_CONFIG_MIN_VERSION=0.9.0
6062 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
6063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
6064 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
6066 if $PKG_CONFIG --exists "$ALSA_MODULES" 2>&5; then
6067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6068 $as_echo "yes" >&6; }
6069 succeeded=yes
6071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking ALSA_CFLAGS" >&5
6072 $as_echo_n "checking ALSA_CFLAGS... " >&6; }
6073 ALSA_CFLAGS=`$PKG_CONFIG --cflags "$ALSA_MODULES"|sed -e 's,///*,/,g'`
6074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ALSA_CFLAGS" >&5
6075 $as_echo "$ALSA_CFLAGS" >&6; }
6077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking ALSA_LIBS" >&5
6078 $as_echo_n "checking ALSA_LIBS... " >&6; }
6079 ALSA_LIBS=`$PKG_CONFIG --libs "$ALSA_MODULES"|sed -e 's,///*,/,g'`
6080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ALSA_LIBS" >&5
6081 $as_echo "$ALSA_LIBS" >&6; }
6082 else
6083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6084 $as_echo "no" >&6; }
6085 ALSA_CFLAGS=""
6086 ALSA_LIBS=""
6087 ## If we have a custom action on failure, don't print errors, but
6088 ## do set a variable so people can do so.
6089 ALSA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$ALSA_MODULES"`
6095 else
6096 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
6097 echo "*** See http://www.freedesktop.org/software/pkgconfig"
6101 if test $succeeded = yes; then
6102 HAVE_ALSA=yes
6103 else
6104 HAVE_ALSA=no
6107 if test $HAVE_ALSA = yes; then
6108 SAVE_CFLAGS="$CFLAGS"
6109 SAVE_LDFLAGS="$LDFLAGS"
6110 CFLAGS="$ALSA_CFLAGS $CFLAGS"
6111 LDFLAGS="$ALSA_LIBS $LDFLAGS"
6112 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6113 /* end confdefs.h. */
6114 #include <asoundlib.h>
6116 main ()
6118 snd_lib_error_set_handler (0);
6120 return 0;
6122 _ACEOF
6123 if ac_fn_c_try_compile "$LINENO"; then :
6124 emacs_alsa_normal=yes
6125 else
6126 emacs_alsa_normal=no
6128 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6129 if test "$emacs_alsa_normal" != yes; then
6130 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6131 /* end confdefs.h. */
6132 #include <alsa/asoundlib.h>
6134 main ()
6136 snd_lib_error_set_handler (0);
6138 return 0;
6140 _ACEOF
6141 if ac_fn_c_try_compile "$LINENO"; then :
6142 emacs_alsa_subdir=yes
6143 else
6144 emacs_alsa_subdir=no
6146 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6147 if test "$emacs_alsa_subdir" != yes; then
6148 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
6150 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
6153 CFLAGS="$SAVE_CFLAGS"
6154 LDFLAGS="$SAVE_LDFLAGS"
6155 LIBSOUND="$LIBSOUND $ALSA_LIBS"
6156 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
6158 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
6162 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
6163 case "$opsys" in
6164 gnu-linux|freebsd|netbsd)
6166 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
6169 esac
6175 for ac_header in sys/select.h sys/timeb.h sys/time.h unistd.h utime.h \
6176 linux/version.h sys/systeminfo.h termios.h limits.h string.h stdlib.h \
6177 stdio_ext.h fcntl.h strings.h coff.h pty.h sys/mman.h \
6178 sys/param.h sys/vlimit.h sys/resource.h locale.h sys/_mbstate_t.h \
6179 sys/utsname.h pwd.h utmp.h dirent.h util.h
6180 do :
6181 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6182 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
6183 eval as_val=\$$as_ac_Header
6184 if test "x$as_val" = x""yes; then :
6185 cat >>confdefs.h <<_ACEOF
6186 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6187 _ACEOF
6191 done
6194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
6195 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
6196 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6197 /* end confdefs.h. */
6198 #include <sys/personality.h>
6200 main ()
6202 personality (PER_LINUX32)
6204 return 0;
6206 _ACEOF
6207 if ac_fn_c_try_compile "$LINENO"; then :
6208 emacs_cv_personality_linux32=yes
6209 else
6210 emacs_cv_personality_linux32=no
6212 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
6214 $as_echo "$emacs_cv_personality_linux32" >&6; }
6216 if test $emacs_cv_personality_linux32 = yes; then
6218 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
6222 for ac_header in term.h
6223 do :
6224 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
6225 if test "x$ac_cv_header_term_h" = x""yes; then :
6226 cat >>confdefs.h <<_ACEOF
6227 #define HAVE_TERM_H 1
6228 _ACEOF
6232 done
6234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6235 $as_echo_n "checking for ANSI C header files... " >&6; }
6236 if test "${ac_cv_header_stdc+set}" = set; then :
6237 $as_echo_n "(cached) " >&6
6238 else
6239 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6240 /* end confdefs.h. */
6241 #include <stdlib.h>
6242 #include <stdarg.h>
6243 #include <string.h>
6244 #include <float.h>
6247 main ()
6251 return 0;
6253 _ACEOF
6254 if ac_fn_c_try_compile "$LINENO"; then :
6255 ac_cv_header_stdc=yes
6256 else
6257 ac_cv_header_stdc=no
6259 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6261 if test $ac_cv_header_stdc = yes; then
6262 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6263 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6264 /* end confdefs.h. */
6265 #include <string.h>
6267 _ACEOF
6268 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6269 $EGREP "memchr" >/dev/null 2>&1; then :
6271 else
6272 ac_cv_header_stdc=no
6274 rm -f conftest*
6278 if test $ac_cv_header_stdc = yes; then
6279 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6280 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6281 /* end confdefs.h. */
6282 #include <stdlib.h>
6284 _ACEOF
6285 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6286 $EGREP "free" >/dev/null 2>&1; then :
6288 else
6289 ac_cv_header_stdc=no
6291 rm -f conftest*
6295 if test $ac_cv_header_stdc = yes; then
6296 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6297 if test "$cross_compiling" = yes; then :
6299 else
6300 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6301 /* end confdefs.h. */
6302 #include <ctype.h>
6303 #include <stdlib.h>
6304 #if ((' ' & 0x0FF) == 0x020)
6305 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6306 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6307 #else
6308 # define ISLOWER(c) \
6309 (('a' <= (c) && (c) <= 'i') \
6310 || ('j' <= (c) && (c) <= 'r') \
6311 || ('s' <= (c) && (c) <= 'z'))
6312 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6313 #endif
6315 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6317 main ()
6319 int i;
6320 for (i = 0; i < 256; i++)
6321 if (XOR (islower (i), ISLOWER (i))
6322 || toupper (i) != TOUPPER (i))
6323 return 2;
6324 return 0;
6326 _ACEOF
6327 if ac_fn_c_try_run "$LINENO"; then :
6329 else
6330 ac_cv_header_stdc=no
6332 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6333 conftest.$ac_objext conftest.beam conftest.$ac_ext
6338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6339 $as_echo "$ac_cv_header_stdc" >&6; }
6340 if test $ac_cv_header_stdc = yes; then
6342 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
6347 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
6348 if test "${ac_cv_header_time+set}" = set; then :
6349 $as_echo_n "(cached) " >&6
6350 else
6351 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6352 /* end confdefs.h. */
6353 #include <sys/types.h>
6354 #include <sys/time.h>
6355 #include <time.h>
6358 main ()
6360 if ((struct tm *) 0)
6361 return 0;
6363 return 0;
6365 _ACEOF
6366 if ac_fn_c_try_compile "$LINENO"; then :
6367 ac_cv_header_time=yes
6368 else
6369 ac_cv_header_time=no
6371 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
6374 $as_echo "$ac_cv_header_time" >&6; }
6375 if test $ac_cv_header_time = yes; then
6377 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
6381 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "$ac_includes_default"
6382 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
6383 ac_have_decl=1
6384 else
6385 ac_have_decl=0
6388 cat >>confdefs.h <<_ACEOF
6389 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
6390 _ACEOF
6392 if test $ac_cv_have_decl_sys_siglist != yes; then
6393 # For Tru64, at least:
6394 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "$ac_includes_default"
6395 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
6396 ac_have_decl=1
6397 else
6398 ac_have_decl=0
6401 cat >>confdefs.h <<_ACEOF
6402 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
6403 _ACEOF
6405 if test $ac_cv_have_decl___sys_siglist = yes; then
6407 $as_echo "#define sys_siglist __sys_siglist" >>confdefs.h
6411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
6412 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
6413 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
6414 $as_echo_n "(cached) " >&6
6415 else
6416 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6417 /* end confdefs.h. */
6418 #include <sys/types.h>
6419 #include <sys/wait.h>
6420 #ifndef WEXITSTATUS
6421 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
6422 #endif
6423 #ifndef WIFEXITED
6424 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
6425 #endif
6428 main ()
6430 int s;
6431 wait (&s);
6432 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
6434 return 0;
6436 _ACEOF
6437 if ac_fn_c_try_compile "$LINENO"; then :
6438 ac_cv_header_sys_wait_h=yes
6439 else
6440 ac_cv_header_sys_wait_h=no
6442 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
6445 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
6446 if test $ac_cv_header_sys_wait_h = yes; then
6448 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
6453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
6454 $as_echo_n "checking for struct utimbuf... " >&6; }
6455 if test "${emacs_cv_struct_utimbuf+set}" = set; then :
6456 $as_echo_n "(cached) " >&6
6457 else
6458 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6459 /* end confdefs.h. */
6460 #ifdef TIME_WITH_SYS_TIME
6461 #include <sys/time.h>
6462 #include <time.h>
6463 #else
6464 #ifdef HAVE_SYS_TIME_H
6465 #include <sys/time.h>
6466 #else
6467 #include <time.h>
6468 #endif
6469 #endif
6470 #ifdef HAVE_UTIME_H
6471 #include <utime.h>
6472 #endif
6474 main ()
6476 static struct utimbuf x; x.actime = x.modtime;
6478 return 0;
6480 _ACEOF
6481 if ac_fn_c_try_compile "$LINENO"; then :
6482 emacs_cv_struct_utimbuf=yes
6483 else
6484 emacs_cv_struct_utimbuf=no
6486 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_utimbuf" >&5
6489 $as_echo "$emacs_cv_struct_utimbuf" >&6; }
6490 if test $emacs_cv_struct_utimbuf = yes; then
6492 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
6496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
6497 $as_echo_n "checking return type of signal handlers... " >&6; }
6498 if test "${ac_cv_type_signal+set}" = set; then :
6499 $as_echo_n "(cached) " >&6
6500 else
6501 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6502 /* end confdefs.h. */
6503 #include <sys/types.h>
6504 #include <signal.h>
6507 main ()
6509 return *(signal (0, 0)) (0) == 1;
6511 return 0;
6513 _ACEOF
6514 if ac_fn_c_try_compile "$LINENO"; then :
6515 ac_cv_type_signal=int
6516 else
6517 ac_cv_type_signal=void
6519 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
6522 $as_echo "$ac_cv_type_signal" >&6; }
6524 cat >>confdefs.h <<_ACEOF
6525 #define RETSIGTYPE $ac_cv_type_signal
6526 _ACEOF
6530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t" >&5
6531 $as_echo_n "checking for speed_t... " >&6; }
6532 if test "${emacs_cv_speed_t+set}" = set; then :
6533 $as_echo_n "(cached) " >&6
6534 else
6535 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6536 /* end confdefs.h. */
6537 #include <termios.h>
6539 main ()
6541 speed_t x = 1;
6543 return 0;
6545 _ACEOF
6546 if ac_fn_c_try_compile "$LINENO"; then :
6547 emacs_cv_speed_t=yes
6548 else
6549 emacs_cv_speed_t=no
6551 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_speed_t" >&5
6554 $as_echo "$emacs_cv_speed_t" >&6; }
6555 if test $emacs_cv_speed_t = yes; then
6557 $as_echo "#define HAVE_SPEED_T 1" >>confdefs.h
6561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
6562 $as_echo_n "checking for struct timeval... " >&6; }
6563 if test "${emacs_cv_struct_timeval+set}" = set; then :
6564 $as_echo_n "(cached) " >&6
6565 else
6566 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6567 /* end confdefs.h. */
6568 #ifdef TIME_WITH_SYS_TIME
6569 #include <sys/time.h>
6570 #include <time.h>
6571 #else
6572 #ifdef HAVE_SYS_TIME_H
6573 #include <sys/time.h>
6574 #else
6575 #include <time.h>
6576 #endif
6577 #endif
6579 main ()
6581 static struct timeval x; x.tv_sec = x.tv_usec;
6583 return 0;
6585 _ACEOF
6586 if ac_fn_c_try_compile "$LINENO"; then :
6587 emacs_cv_struct_timeval=yes
6588 else
6589 emacs_cv_struct_timeval=no
6591 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_timeval" >&5
6594 $as_echo "$emacs_cv_struct_timeval" >&6; }
6595 HAVE_TIMEVAL=$emacs_cv_struct_timeval
6596 if test $emacs_cv_struct_timeval = yes; then
6598 $as_echo "#define HAVE_TIMEVAL 1" >>confdefs.h
6602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct exception" >&5
6603 $as_echo_n "checking for struct exception... " >&6; }
6604 if test "${emacs_cv_struct_exception+set}" = set; then :
6605 $as_echo_n "(cached) " >&6
6606 else
6607 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6608 /* end confdefs.h. */
6609 #include <math.h>
6611 main ()
6613 static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
6615 return 0;
6617 _ACEOF
6618 if ac_fn_c_try_compile "$LINENO"; then :
6619 emacs_cv_struct_exception=yes
6620 else
6621 emacs_cv_struct_exception=no
6623 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_exception" >&5
6626 $as_echo "$emacs_cv_struct_exception" >&6; }
6627 HAVE_EXCEPTION=$emacs_cv_struct_exception
6628 if test $emacs_cv_struct_exception != yes; then
6630 $as_echo "#define NO_MATHERR 1" >>confdefs.h
6634 for ac_header in sys/socket.h
6635 do :
6636 ac_fn_c_check_header_mongrel "$LINENO" "sys/socket.h" "ac_cv_header_sys_socket_h" "$ac_includes_default"
6637 if test "x$ac_cv_header_sys_socket_h" = x""yes; then :
6638 cat >>confdefs.h <<_ACEOF
6639 #define HAVE_SYS_SOCKET_H 1
6640 _ACEOF
6644 done
6646 for ac_header in net/if.h
6647 do :
6648 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
6649 #if HAVE_SYS_SOCKET_H
6650 #include <sys/socket.h>
6651 #endif
6653 if test "x$ac_cv_header_net_if_h" = x""yes; then :
6654 cat >>confdefs.h <<_ACEOF
6655 #define HAVE_NET_IF_H 1
6656 _ACEOF
6660 done
6663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
6664 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
6665 if test "${ac_cv_struct_tm+set}" = set; then :
6666 $as_echo_n "(cached) " >&6
6667 else
6668 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6669 /* end confdefs.h. */
6670 #include <sys/types.h>
6671 #include <time.h>
6674 main ()
6676 struct tm tm;
6677 int *p = &tm.tm_sec;
6678 return !p;
6680 return 0;
6682 _ACEOF
6683 if ac_fn_c_try_compile "$LINENO"; then :
6684 ac_cv_struct_tm=time.h
6685 else
6686 ac_cv_struct_tm=sys/time.h
6688 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
6691 $as_echo "$ac_cv_struct_tm" >&6; }
6692 if test $ac_cv_struct_tm = sys/time.h; then
6694 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
6698 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
6699 #include <$ac_cv_struct_tm>
6702 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
6704 cat >>confdefs.h <<_ACEOF
6705 #define HAVE_STRUCT_TM_TM_ZONE 1
6706 _ACEOF
6711 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
6713 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
6715 else
6716 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
6718 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
6719 ac_have_decl=1
6720 else
6721 ac_have_decl=0
6724 cat >>confdefs.h <<_ACEOF
6725 #define HAVE_DECL_TZNAME $ac_have_decl
6726 _ACEOF
6728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
6729 $as_echo_n "checking for tzname... " >&6; }
6730 if test "${ac_cv_var_tzname+set}" = set; then :
6731 $as_echo_n "(cached) " >&6
6732 else
6733 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6734 /* end confdefs.h. */
6735 #include <time.h>
6736 #if !HAVE_DECL_TZNAME
6737 extern char *tzname[];
6738 #endif
6741 main ()
6743 return tzname[0][0];
6745 return 0;
6747 _ACEOF
6748 if ac_fn_c_try_link "$LINENO"; then :
6749 ac_cv_var_tzname=yes
6750 else
6751 ac_cv_var_tzname=no
6753 rm -f core conftest.err conftest.$ac_objext \
6754 conftest$ac_exeext conftest.$ac_ext
6756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
6757 $as_echo "$ac_cv_var_tzname" >&6; }
6758 if test $ac_cv_var_tzname = yes; then
6760 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
6765 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
6767 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
6769 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
6773 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
6774 #if HAVE_SYS_SOCKET_H
6775 #include <sys/socket.h>
6776 #endif
6777 #if HAVE_NET_IF_H
6778 #include <net/if.h>
6779 #endif
6781 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
6783 cat >>confdefs.h <<_ACEOF
6784 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
6785 _ACEOF
6789 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
6790 #if HAVE_SYS_SOCKET_H
6791 #include <sys/socket.h>
6792 #endif
6793 #if HAVE_NET_IF_H
6794 #include <net/if.h>
6795 #endif
6797 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
6799 cat >>confdefs.h <<_ACEOF
6800 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
6801 _ACEOF
6805 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
6806 #if HAVE_SYS_SOCKET_H
6807 #include <sys/socket.h>
6808 #endif
6809 #if HAVE_NET_IF_H
6810 #include <net/if.h>
6811 #endif
6813 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
6815 cat >>confdefs.h <<_ACEOF
6816 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
6817 _ACEOF
6821 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
6822 #if HAVE_SYS_SOCKET_H
6823 #include <sys/socket.h>
6824 #endif
6825 #if HAVE_NET_IF_H
6826 #include <net/if.h>
6827 #endif
6829 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
6831 cat >>confdefs.h <<_ACEOF
6832 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
6833 _ACEOF
6837 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
6838 #if HAVE_SYS_SOCKET_H
6839 #include <sys/socket.h>
6840 #endif
6841 #if HAVE_NET_IF_H
6842 #include <net/if.h>
6843 #endif
6845 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
6847 cat >>confdefs.h <<_ACEOF
6848 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
6849 _ACEOF
6856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for function prototypes" >&5
6857 $as_echo_n "checking for function prototypes... " >&6; }
6858 if test "$ac_cv_prog_cc_c89" != no; then
6859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6860 $as_echo "yes" >&6; }
6862 $as_echo "#define PROTOTYPES 1" >>confdefs.h
6865 $as_echo "#define __PROTOTYPES 1" >>confdefs.h
6867 else
6868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6869 $as_echo "no" >&6; }
6872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5
6873 $as_echo_n "checking for working volatile... " >&6; }
6874 if test "${ac_cv_c_volatile+set}" = set; then :
6875 $as_echo_n "(cached) " >&6
6876 else
6877 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6878 /* end confdefs.h. */
6881 main ()
6884 volatile int x;
6885 int * volatile y = (int *) 0;
6886 return !x && !y;
6888 return 0;
6890 _ACEOF
6891 if ac_fn_c_try_compile "$LINENO"; then :
6892 ac_cv_c_volatile=yes
6893 else
6894 ac_cv_c_volatile=no
6896 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5
6899 $as_echo "$ac_cv_c_volatile" >&6; }
6900 if test $ac_cv_c_volatile = no; then
6902 $as_echo "#define volatile /**/" >>confdefs.h
6906 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
6907 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
6908 if test "${ac_cv_c_const+set}" = set; then :
6909 $as_echo_n "(cached) " >&6
6910 else
6911 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6912 /* end confdefs.h. */
6915 main ()
6917 /* FIXME: Include the comments suggested by Paul. */
6918 #ifndef __cplusplus
6919 /* Ultrix mips cc rejects this. */
6920 typedef int charset[2];
6921 const charset cs;
6922 /* SunOS 4.1.1 cc rejects this. */
6923 char const *const *pcpcc;
6924 char **ppc;
6925 /* NEC SVR4.0.2 mips cc rejects this. */
6926 struct point {int x, y;};
6927 static struct point const zero = {0,0};
6928 /* AIX XL C 1.02.0.0 rejects this.
6929 It does not let you subtract one const X* pointer from another in
6930 an arm of an if-expression whose if-part is not a constant
6931 expression */
6932 const char *g = "string";
6933 pcpcc = &g + (g ? g-g : 0);
6934 /* HPUX 7.0 cc rejects these. */
6935 ++pcpcc;
6936 ppc = (char**) pcpcc;
6937 pcpcc = (char const *const *) ppc;
6938 { /* SCO 3.2v4 cc rejects this. */
6939 char *t;
6940 char const *s = 0 ? (char *) 0 : (char const *) 0;
6942 *t++ = 0;
6943 if (s) return 0;
6945 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
6946 int x[] = {25, 17};
6947 const int *foo = &x[0];
6948 ++foo;
6950 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
6951 typedef const int *iptr;
6952 iptr p = 0;
6953 ++p;
6955 { /* AIX XL C 1.02.0.0 rejects this saying
6956 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
6957 struct s { int j; const int *ap[3]; };
6958 struct s *b; b->j = 5;
6960 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
6961 const int foo = 10;
6962 if (!foo) return 0;
6964 return !cs[0] && !zero.x;
6965 #endif
6968 return 0;
6970 _ACEOF
6971 if ac_fn_c_try_compile "$LINENO"; then :
6972 ac_cv_c_const=yes
6973 else
6974 ac_cv_c_const=no
6976 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
6979 $as_echo "$ac_cv_c_const" >&6; }
6980 if test $ac_cv_c_const = no; then
6982 $as_echo "#define const /**/" >>confdefs.h
6986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for void * support" >&5
6987 $as_echo_n "checking for void * support... " >&6; }
6988 if test "${emacs_cv_void_star+set}" = set; then :
6989 $as_echo_n "(cached) " >&6
6990 else
6991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6992 /* end confdefs.h. */
6995 main ()
6997 void * foo;
6999 return 0;
7001 _ACEOF
7002 if ac_fn_c_try_compile "$LINENO"; then :
7003 emacs_cv_void_star=yes
7004 else
7005 emacs_cv_void_star=no
7007 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_void_star" >&5
7010 $as_echo "$emacs_cv_void_star" >&6; }
7011 if test $emacs_cv_void_star = yes; then
7012 $as_echo "#define POINTER_TYPE void" >>confdefs.h
7014 else
7015 $as_echo "#define POINTER_TYPE char" >>confdefs.h
7022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
7023 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
7024 set x ${MAKE-make}
7025 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
7026 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
7027 $as_echo_n "(cached) " >&6
7028 else
7029 cat >conftest.make <<\_ACEOF
7030 SHELL = /bin/sh
7031 all:
7032 @echo '@@@%%%=$(MAKE)=@@@%%%'
7033 _ACEOF
7034 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
7035 case `${MAKE-make} -f conftest.make 2>/dev/null` in
7036 *@@@%%%=?*=@@@%%%*)
7037 eval ac_cv_prog_make_${ac_make}_set=yes;;
7039 eval ac_cv_prog_make_${ac_make}_set=no;;
7040 esac
7041 rm -f conftest.make
7043 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
7044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7045 $as_echo "yes" >&6; }
7046 SET_MAKE=
7047 else
7048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7049 $as_echo "no" >&6; }
7050 SET_MAKE="MAKE=${MAKE-make}"
7054 DEPFLAGS=
7055 MKDEPDIR=":"
7056 deps_frag=deps.mk
7057 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
7058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
7059 $as_echo_n "checking whether we are using GNU Make... " >&6; }
7060 HAVE_GNU_MAKE=no
7061 testval=`make --version 2>/dev/null | grep 'GNU Make'`
7062 if test "x$testval" != x; then
7063 HAVE_GNU_MAKE=yes
7064 else
7065 ac_enable_autodepend=no
7067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
7068 $as_echo "$HAVE_GNU_MAKE" >&6; }
7069 if test $HAVE_GNU_MAKE = yes; then
7070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
7071 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
7072 SAVE_CFLAGS="$CFLAGS"
7073 CFLAGS="$CFLAGS -MMD -MF deps.d"
7074 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7075 /* end confdefs.h. */
7078 main ()
7082 return 0;
7084 _ACEOF
7085 if ac_fn_c_try_compile "$LINENO"; then :
7087 else
7088 ac_enable_autodepend=no
7090 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7091 CFLAGS="$SAVE_CFLAGS"
7092 test -f deps.d || ac_enable_autodepend=no
7093 rm -rf deps.d
7094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
7095 $as_echo "$ac_enable_autodepend" >&6; }
7097 if test $ac_enable_autodepend = yes; then
7098 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d'
7099 ## In parallel builds, another make might create depdir between
7100 ## the first test and mkdir, so stick another test on the end.
7101 ## Or use mkinstalldirs? mkdir -p is not portable.
7102 MKDEPDIR='test -d ${DEPDIR} || mkdir ${DEPDIR} || test -d ${DEPDIR}'
7103 deps_frag=autodeps.mk
7106 deps_frag=$srcdir/src/$deps_frag
7112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
7113 $as_echo_n "checking for long file names... " >&6; }
7114 if test "${ac_cv_sys_long_file_names+set}" = set; then :
7115 $as_echo_n "(cached) " >&6
7116 else
7117 ac_cv_sys_long_file_names=yes
7118 # Test for long file names in all the places we know might matter:
7119 # . the current directory, where building will happen
7120 # $prefix/lib where we will be installing things
7121 # $exec_prefix/lib likewise
7122 # $TMPDIR if set, where it might want to write temporary files
7123 # /tmp where it might want to write temporary files
7124 # /var/tmp likewise
7125 # /usr/tmp likewise
7126 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
7127 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
7128 # in the usual case where exec_prefix is '${prefix}'.
7129 case $ac_dir in #(
7130 . | /* | ?:[\\/]*) ;; #(
7131 *) continue;;
7132 esac
7133 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
7134 ac_xdir=$ac_dir/cf$$
7135 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
7136 ac_tf1=$ac_xdir/conftest9012345
7137 ac_tf2=$ac_xdir/conftest9012346
7138 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
7139 ac_cv_sys_long_file_names=no
7140 rm -f -r "$ac_xdir" 2>/dev/null
7141 test $ac_cv_sys_long_file_names = no && break
7142 done
7144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
7145 $as_echo "$ac_cv_sys_long_file_names" >&6; }
7146 if test $ac_cv_sys_long_file_names = yes; then
7148 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
7153 #### Choose a window system.
7155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
7156 $as_echo_n "checking for X... " >&6; }
7159 # Check whether --with-x was given.
7160 if test "${with_x+set}" = set; then :
7161 withval=$with_x;
7164 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
7165 if test "x$with_x" = xno; then
7166 # The user explicitly disabled X.
7167 have_x=disabled
7168 else
7169 case $x_includes,$x_libraries in #(
7170 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
7171 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
7172 $as_echo_n "(cached) " >&6
7173 else
7174 # One or both of the vars are not set, and there is no cached value.
7175 ac_x_includes=no ac_x_libraries=no
7176 rm -f -r conftest.dir
7177 if mkdir conftest.dir; then
7178 cd conftest.dir
7179 cat >Imakefile <<'_ACEOF'
7180 incroot:
7181 @echo incroot='${INCROOT}'
7182 usrlibdir:
7183 @echo usrlibdir='${USRLIBDIR}'
7184 libdir:
7185 @echo libdir='${LIBDIR}'
7186 _ACEOF
7187 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
7188 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
7189 for ac_var in incroot usrlibdir libdir; do
7190 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
7191 done
7192 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
7193 for ac_extension in a so sl dylib la dll; do
7194 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
7195 test -f "$ac_im_libdir/libX11.$ac_extension"; then
7196 ac_im_usrlibdir=$ac_im_libdir; break
7198 done
7199 # Screen out bogus values from the imake configuration. They are
7200 # bogus both because they are the default anyway, and because
7201 # using them would break gcc on systems where it needs fixed includes.
7202 case $ac_im_incroot in
7203 /usr/include) ac_x_includes= ;;
7204 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
7205 esac
7206 case $ac_im_usrlibdir in
7207 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
7208 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
7209 esac
7211 cd ..
7212 rm -f -r conftest.dir
7215 # Standard set of common directories for X headers.
7216 # Check X11 before X11Rn because it is often a symlink to the current release.
7217 ac_x_header_dirs='
7218 /usr/X11/include
7219 /usr/X11R7/include
7220 /usr/X11R6/include
7221 /usr/X11R5/include
7222 /usr/X11R4/include
7224 /usr/include/X11
7225 /usr/include/X11R7
7226 /usr/include/X11R6
7227 /usr/include/X11R5
7228 /usr/include/X11R4
7230 /usr/local/X11/include
7231 /usr/local/X11R7/include
7232 /usr/local/X11R6/include
7233 /usr/local/X11R5/include
7234 /usr/local/X11R4/include
7236 /usr/local/include/X11
7237 /usr/local/include/X11R7
7238 /usr/local/include/X11R6
7239 /usr/local/include/X11R5
7240 /usr/local/include/X11R4
7242 /usr/X386/include
7243 /usr/x386/include
7244 /usr/XFree86/include/X11
7246 /usr/include
7247 /usr/local/include
7248 /usr/unsupported/include
7249 /usr/athena/include
7250 /usr/local/x11r5/include
7251 /usr/lpp/Xamples/include
7253 /usr/openwin/include
7254 /usr/openwin/share/include'
7256 if test "$ac_x_includes" = no; then
7257 # Guess where to find include files, by looking for Xlib.h.
7258 # First, try using that file with no special directory specified.
7259 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7260 /* end confdefs.h. */
7261 #include <X11/Xlib.h>
7262 _ACEOF
7263 if ac_fn_c_try_cpp "$LINENO"; then :
7264 # We can compile using X headers with no special include directory.
7265 ac_x_includes=
7266 else
7267 for ac_dir in $ac_x_header_dirs; do
7268 if test -r "$ac_dir/X11/Xlib.h"; then
7269 ac_x_includes=$ac_dir
7270 break
7272 done
7274 rm -f conftest.err conftest.$ac_ext
7275 fi # $ac_x_includes = no
7277 if test "$ac_x_libraries" = no; then
7278 # Check for the libraries.
7279 # See if we find them without any special options.
7280 # Don't add to $LIBS permanently.
7281 ac_save_LIBS=$LIBS
7282 LIBS="-lX11 $LIBS"
7283 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7284 /* end confdefs.h. */
7285 #include <X11/Xlib.h>
7287 main ()
7289 XrmInitialize ()
7291 return 0;
7293 _ACEOF
7294 if ac_fn_c_try_link "$LINENO"; then :
7295 LIBS=$ac_save_LIBS
7296 # We can link X programs with no special library path.
7297 ac_x_libraries=
7298 else
7299 LIBS=$ac_save_LIBS
7300 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
7302 # Don't even attempt the hair of trying to link an X program!
7303 for ac_extension in a so sl dylib la dll; do
7304 if test -r "$ac_dir/libX11.$ac_extension"; then
7305 ac_x_libraries=$ac_dir
7306 break 2
7308 done
7309 done
7311 rm -f core conftest.err conftest.$ac_objext \
7312 conftest$ac_exeext conftest.$ac_ext
7313 fi # $ac_x_libraries = no
7315 case $ac_x_includes,$ac_x_libraries in #(
7316 no,* | *,no | *\'*)
7317 # Didn't find X, or a directory has "'" in its name.
7318 ac_cv_have_x="have_x=no";; #(
7320 # Record where we found X for the cache.
7321 ac_cv_have_x="have_x=yes\
7322 ac_x_includes='$ac_x_includes'\
7323 ac_x_libraries='$ac_x_libraries'"
7324 esac
7326 ;; #(
7327 *) have_x=yes;;
7328 esac
7329 eval "$ac_cv_have_x"
7330 fi # $with_x != no
7332 if test "$have_x" != yes; then
7333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
7334 $as_echo "$have_x" >&6; }
7335 no_x=yes
7336 else
7337 # If each of the values was on the command line, it overrides each guess.
7338 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
7339 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
7340 # Update the cache value to reflect the command line values.
7341 ac_cv_have_x="have_x=yes\
7342 ac_x_includes='$x_includes'\
7343 ac_x_libraries='$x_libraries'"
7344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
7345 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
7348 if test "$no_x" = yes; then
7349 window_system=none
7350 else
7351 window_system=x11
7354 ## Workaround for bug in autoconf <= 2.62.
7355 ## http://lists.gnu.org/archive/html/emacs-devel/2008-04/msg01551.html
7356 ## No need to do anything special for these standard directories.
7357 if test -n "${x_libraries}" && test x"${x_libraries}" != xNONE; then
7359 x_libraries=`echo :${x_libraries}: | sed -e 's|:/usr/lib64:|:|g' -e 's|:/lib64:|:|g' -e 's|^:||' -e 's|:$||'`
7363 LD_SWITCH_X_SITE_AUX=
7364 LD_SWITCH_X_SITE_AUX_RPATH=
7365 if test "${x_libraries}" != NONE; then
7366 if test -n "${x_libraries}"; then
7367 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
7368 LD_SWITCH_X_SITE_AUX=-R`echo ${x_libraries} | sed -e "s/:/ -R/g"`
7369 LD_SWITCH_X_SITE_AUX_RPATH=`echo ${LD_SWITCH_X_SITE_AUX} | sed -e 's/-R/-Wl,-rpath,/'`
7371 x_default_search_path=""
7372 x_search_path=${x_libraries}
7373 if test -z "${x_search_path}"; then
7374 x_search_path=/usr/lib
7376 for x_library in `echo ${x_search_path}: | \
7377 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
7378 x_search_path="\
7379 ${x_library}/X11/%L/%T/%N%C%S:\
7380 ${x_library}/X11/%l/%T/%N%C%S:\
7381 ${x_library}/X11/%T/%N%C%S:\
7382 ${x_library}/X11/%L/%T/%N%S:\
7383 ${x_library}/X11/%l/%T/%N%S:\
7384 ${x_library}/X11/%T/%N%S"
7385 if test x"${x_default_search_path}" = x; then
7386 x_default_search_path=${x_search_path}
7387 else
7388 x_default_search_path="${x_search_path}:${x_default_search_path}"
7390 done
7395 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
7396 C_SWITCH_X_SITE=-I`echo ${x_includes} | sed -e "s/:/ -I/g"`
7399 if test x"${x_includes}" = x; then
7400 bitmapdir=/usr/include/X11/bitmaps
7401 else
7402 # accumulate include directories that have X11 bitmap subdirectories
7403 bmd_acc="dummyval"
7404 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
7405 if test -d "${bmd}/X11/bitmaps"; then
7406 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
7408 if test -d "${bmd}/bitmaps"; then
7409 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
7411 done
7412 if test ${bmd_acc} != "dummyval"; then
7413 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
7417 HAVE_NS=no
7418 NS_IMPL_COCOA=no
7419 NS_IMPL_GNUSTEP=no
7420 tmp_CPPFLAGS="$CPPFLAGS"
7421 tmp_CFLAGS="$CFLAGS"
7422 CPPFLAGS="$CPPFLAGS -x objective-c"
7423 CFLAGS="$CFLAGS -x objective-c"
7424 TEMACS_LDFLAGS2="\${LDFLAGS} \${PROFILING_LDFLAGS}"
7425 if test "${with_ns}" != no; then
7426 if test "${opsys}" = darwin; then
7427 NS_IMPL_COCOA=yes
7428 ns_appdir=`pwd`/nextstep/Emacs.app/
7429 ns_appbindir=${ns_appdir}Contents/MacOS/
7430 ns_appresdir=${ns_appdir}Contents/Resources
7431 ns_appsrc=${srcdir}/nextstep/Cocoa/Emacs.base
7432 elif test -f $GNUSTEP_CONFIG_FILE; then
7433 NS_IMPL_GNUSTEP=yes
7434 ns_appdir=`pwd`/nextstep/Emacs.app/
7435 ns_appbindir=${ns_appdir}
7436 ns_appresdir=${ns_appdir}Resources
7437 ns_appsrc=${srcdir}/nextstep/GNUstep/Emacs.base
7438 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
7439 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
7440 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
7441 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
7442 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
7443 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
7444 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
7445 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
7446 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
7447 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
7448 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
7449 LIB_STANDARD=
7450 START_FILES=
7451 TEMACS_LDFLAGS2=
7453 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
7454 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
7455 HAVE_NS=yes
7456 else
7457 as_fn_error "\`--with-ns' was specified, but the include
7458 files are missing or cannot be compiled." "$LINENO" 5
7462 NS_HAVE_NSINTEGER=yes
7463 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7464 /* end confdefs.h. */
7465 #include <Foundation/NSObjCRuntime.h>
7467 main ()
7469 NSInteger i;
7471 return 0;
7473 _ACEOF
7474 if ac_fn_c_try_compile "$LINENO"; then :
7475 ns_have_nsinteger=yes
7476 else
7477 ns_have_nsinteger=no
7479 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7480 if test $ns_have_nsinteger = no; then
7481 NS_HAVE_NSINTEGER=no
7486 ns_frag=/dev/null
7487 NS_OBJ=
7488 NS_SUPPORT=
7489 if test "${HAVE_NS}" = yes; then
7490 window_system=nextstep
7491 with_xft=no
7492 # set up packaging dirs
7493 exec_prefix=${ns_appbindir}
7494 libexecdir=${ns_appbindir}/libexec
7495 if test "${EN_NS_SELF_CONTAINED}" = yes; then
7496 prefix=${ns_appresdir}
7498 ns_frag=$srcdir/src/ns.mk
7499 NS_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o fontset.o fringe.o image.o"
7500 NS_SUPPORT="\${lispsource}emacs-lisp/easymenu.elc \${lispsource}term/ns-win.elc"
7502 CFLAGS="$tmp_CFLAGS"
7503 CPPFLAGS="$tmp_CPPFLAGS"
7509 case "${window_system}" in
7510 x11 )
7511 HAVE_X_WINDOWS=yes
7512 HAVE_X11=yes
7513 case "${with_x_toolkit}" in
7514 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
7515 motif ) USE_X_TOOLKIT=MOTIF ;;
7516 gtk ) with_gtk=yes
7517 USE_X_TOOLKIT=none ;;
7518 gtk3 ) with_gtk3=yes
7519 USE_X_TOOLKIT=none ;;
7520 no ) USE_X_TOOLKIT=none ;;
7521 * ) USE_X_TOOLKIT=maybe ;;
7522 esac
7524 nextstep | none )
7525 HAVE_X_WINDOWS=no
7526 HAVE_X11=no
7527 USE_X_TOOLKIT=none
7529 esac
7531 if test "$window_system" = none && test "X$with_x" != "Xno"; then
7532 # Extract the first word of "X", so it can be a program name with args.
7533 set dummy X; ac_word=$2
7534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7535 $as_echo_n "checking for $ac_word... " >&6; }
7536 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
7537 $as_echo_n "(cached) " >&6
7538 else
7539 if test -n "$HAVE_XSERVER"; then
7540 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
7541 else
7542 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7543 for as_dir in $PATH
7545 IFS=$as_save_IFS
7546 test -z "$as_dir" && as_dir=.
7547 for ac_exec_ext in '' $ac_executable_extensions; do
7548 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7549 ac_cv_prog_HAVE_XSERVER="true"
7550 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7551 break 2
7553 done
7554 done
7555 IFS=$as_save_IFS
7557 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
7560 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
7561 if test -n "$HAVE_XSERVER"; then
7562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
7563 $as_echo "$HAVE_XSERVER" >&6; }
7564 else
7565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7566 $as_echo "no" >&6; }
7570 if test "$HAVE_XSERVER" = true ||
7571 test -n "$DISPLAY" ||
7572 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
7573 as_fn_error "You seem to be running X, but no X development libraries
7574 were found. You should install the relevant development files for X
7575 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
7576 sure you have development files for image handling, i.e.
7577 tiff, gif, jpeg, png and xpm.
7578 If you are sure you want Emacs compiled without X window support, pass
7579 --without-x
7580 to configure." "$LINENO" 5
7584 ### If we're using X11, we should use the X menu package.
7585 HAVE_MENUS=no
7586 case ${HAVE_X11} in
7587 yes ) HAVE_MENUS=yes ;;
7588 esac
7590 # Do the opsystem or machine files prohibit the use of the GNU malloc?
7591 # Assume not, until told otherwise.
7592 GNU_MALLOC=yes
7593 doug_lea_malloc=yes
7594 ac_fn_c_check_func "$LINENO" "malloc_get_state" "ac_cv_func_malloc_get_state"
7595 if test "x$ac_cv_func_malloc_get_state" = x""yes; then :
7597 else
7598 doug_lea_malloc=no
7601 ac_fn_c_check_func "$LINENO" "malloc_set_state" "ac_cv_func_malloc_set_state"
7602 if test "x$ac_cv_func_malloc_set_state" = x""yes; then :
7604 else
7605 doug_lea_malloc=no
7608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __after_morecore_hook exists" >&5
7609 $as_echo_n "checking whether __after_morecore_hook exists... " >&6; }
7610 if test "${emacs_cv_var___after_morecore_hook+set}" = set; then :
7611 $as_echo_n "(cached) " >&6
7612 else
7613 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7614 /* end confdefs.h. */
7615 extern void (* __after_morecore_hook)();
7617 main ()
7619 __after_morecore_hook = 0
7621 return 0;
7623 _ACEOF
7624 if ac_fn_c_try_link "$LINENO"; then :
7625 emacs_cv_var___after_morecore_hook=yes
7626 else
7627 emacs_cv_var___after_morecore_hook=no
7629 rm -f core conftest.err conftest.$ac_objext \
7630 conftest$ac_exeext conftest.$ac_ext
7632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var___after_morecore_hook" >&5
7633 $as_echo "$emacs_cv_var___after_morecore_hook" >&6; }
7634 if test $emacs_cv_var___after_morecore_hook = no; then
7635 doug_lea_malloc=no
7639 system_malloc=no
7640 case "$opsys" in
7641 ## darwin ld insists on the use of malloc routines in the System framework.
7642 darwin|sol2-10) system_malloc=yes ;;
7643 esac
7645 if test "${system_malloc}" = "yes"; then
7647 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
7649 GNU_MALLOC=no
7650 GNU_MALLOC_reason="
7651 (The GNU allocators don't work with this system configuration.)"
7652 GMALLOC_OBJ=
7653 VMLIMIT_OBJ=
7654 else
7655 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
7656 VMLIMIT_OBJ=vm-limit.o
7661 if test "$doug_lea_malloc" = "yes" ; then
7662 if test "$GNU_MALLOC" = yes ; then
7663 GNU_MALLOC_reason="
7664 (Using Doug Lea's new malloc from the GNU C Library.)"
7667 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
7670 ## Use mmap directly for allocating larger buffers.
7671 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
7672 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
7673 ## Does the AC_FUNC_MMAP test below make this check unecessary?
7674 case "$opsys" in
7675 gnu*) REL_ALLOC=no ;;
7676 esac
7679 if test x"${REL_ALLOC}" = x; then
7680 REL_ALLOC=${GNU_MALLOC}
7683 use_mmap_for_buffers=no
7684 case "$opsys" in
7685 freebsd|irix6-5) use_mmap_for_buffers=yes ;;
7686 esac
7691 for ac_header in $ac_header_list
7692 do :
7693 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7694 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
7696 eval as_val=\$$as_ac_Header
7697 if test "x$as_val" = x""yes; then :
7698 cat >>confdefs.h <<_ACEOF
7699 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7700 _ACEOF
7704 done
7713 for ac_func in getpagesize
7714 do :
7715 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
7716 if test "x$ac_cv_func_getpagesize" = x""yes; then :
7717 cat >>confdefs.h <<_ACEOF
7718 #define HAVE_GETPAGESIZE 1
7719 _ACEOF
7722 done
7724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
7725 $as_echo_n "checking for working mmap... " >&6; }
7726 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
7727 $as_echo_n "(cached) " >&6
7728 else
7729 if test "$cross_compiling" = yes; then :
7730 ac_cv_func_mmap_fixed_mapped=no
7731 else
7732 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7733 /* end confdefs.h. */
7734 $ac_includes_default
7735 /* malloc might have been renamed as rpl_malloc. */
7736 #undef malloc
7738 /* Thanks to Mike Haertel and Jim Avera for this test.
7739 Here is a matrix of mmap possibilities:
7740 mmap private not fixed
7741 mmap private fixed at somewhere currently unmapped
7742 mmap private fixed at somewhere already mapped
7743 mmap shared not fixed
7744 mmap shared fixed at somewhere currently unmapped
7745 mmap shared fixed at somewhere already mapped
7746 For private mappings, we should verify that changes cannot be read()
7747 back from the file, nor mmap's back from the file at a different
7748 address. (There have been systems where private was not correctly
7749 implemented like the infamous i386 svr4.0, and systems where the
7750 VM page cache was not coherent with the file system buffer cache
7751 like early versions of FreeBSD and possibly contemporary NetBSD.)
7752 For shared mappings, we should conversely verify that changes get
7753 propagated back to all the places they're supposed to be.
7755 Grep wants private fixed already mapped.
7756 The main things grep needs to know about mmap are:
7757 * does it exist and is it safe to write into the mmap'd area
7758 * how to use it (BSD variants) */
7760 #include <fcntl.h>
7761 #include <sys/mman.h>
7763 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
7764 char *malloc ();
7765 #endif
7767 /* This mess was copied from the GNU getpagesize.h. */
7768 #ifndef HAVE_GETPAGESIZE
7769 # ifdef _SC_PAGESIZE
7770 # define getpagesize() sysconf(_SC_PAGESIZE)
7771 # else /* no _SC_PAGESIZE */
7772 # ifdef HAVE_SYS_PARAM_H
7773 # include <sys/param.h>
7774 # ifdef EXEC_PAGESIZE
7775 # define getpagesize() EXEC_PAGESIZE
7776 # else /* no EXEC_PAGESIZE */
7777 # ifdef NBPG
7778 # define getpagesize() NBPG * CLSIZE
7779 # ifndef CLSIZE
7780 # define CLSIZE 1
7781 # endif /* no CLSIZE */
7782 # else /* no NBPG */
7783 # ifdef NBPC
7784 # define getpagesize() NBPC
7785 # else /* no NBPC */
7786 # ifdef PAGESIZE
7787 # define getpagesize() PAGESIZE
7788 # endif /* PAGESIZE */
7789 # endif /* no NBPC */
7790 # endif /* no NBPG */
7791 # endif /* no EXEC_PAGESIZE */
7792 # else /* no HAVE_SYS_PARAM_H */
7793 # define getpagesize() 8192 /* punt totally */
7794 # endif /* no HAVE_SYS_PARAM_H */
7795 # endif /* no _SC_PAGESIZE */
7797 #endif /* no HAVE_GETPAGESIZE */
7800 main ()
7802 char *data, *data2, *data3;
7803 int i, pagesize;
7804 int fd, fd2;
7806 pagesize = getpagesize ();
7808 /* First, make a file with some known garbage in it. */
7809 data = (char *) malloc (pagesize);
7810 if (!data)
7811 return 1;
7812 for (i = 0; i < pagesize; ++i)
7813 *(data + i) = rand ();
7814 umask (0);
7815 fd = creat ("conftest.mmap", 0600);
7816 if (fd < 0)
7817 return 2;
7818 if (write (fd, data, pagesize) != pagesize)
7819 return 3;
7820 close (fd);
7822 /* Next, check that the tail of a page is zero-filled. File must have
7823 non-zero length, otherwise we risk SIGBUS for entire page. */
7824 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
7825 if (fd2 < 0)
7826 return 4;
7827 data2 = "";
7828 if (write (fd2, data2, 1) != 1)
7829 return 5;
7830 data2 = mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
7831 if (data2 == MAP_FAILED)
7832 return 6;
7833 for (i = 0; i < pagesize; ++i)
7834 if (*(data2 + i))
7835 return 7;
7836 close (fd2);
7837 if (munmap (data2, pagesize))
7838 return 8;
7840 /* Next, try to mmap the file at a fixed address which already has
7841 something else allocated at it. If we can, also make sure that
7842 we see the same garbage. */
7843 fd = open ("conftest.mmap", O_RDWR);
7844 if (fd < 0)
7845 return 9;
7846 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
7847 MAP_PRIVATE | MAP_FIXED, fd, 0L))
7848 return 10;
7849 for (i = 0; i < pagesize; ++i)
7850 if (*(data + i) != *(data2 + i))
7851 return 11;
7853 /* Finally, make sure that changes to the mapped area do not
7854 percolate back to the file as seen by read(). (This is a bug on
7855 some variants of i386 svr4.0.) */
7856 for (i = 0; i < pagesize; ++i)
7857 *(data2 + i) = *(data2 + i) + 1;
7858 data3 = (char *) malloc (pagesize);
7859 if (!data3)
7860 return 12;
7861 if (read (fd, data3, pagesize) != pagesize)
7862 return 13;
7863 for (i = 0; i < pagesize; ++i)
7864 if (*(data + i) != *(data3 + i))
7865 return 14;
7866 close (fd);
7867 return 0;
7869 _ACEOF
7870 if ac_fn_c_try_run "$LINENO"; then :
7871 ac_cv_func_mmap_fixed_mapped=yes
7872 else
7873 ac_cv_func_mmap_fixed_mapped=no
7875 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7876 conftest.$ac_objext conftest.beam conftest.$ac_ext
7880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
7881 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
7882 if test $ac_cv_func_mmap_fixed_mapped = yes; then
7884 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
7887 rm -f conftest.mmap conftest.txt
7889 if test $use_mmap_for_buffers = yes; then
7891 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
7893 REL_ALLOC=no
7896 LIBS="$LIBS_SYSTEM $LIBS"
7898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
7899 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
7900 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
7901 $as_echo_n "(cached) " >&6
7902 else
7903 ac_check_lib_save_LIBS=$LIBS
7904 LIBS="-ldnet $LIBS"
7905 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7906 /* end confdefs.h. */
7908 /* Override any GCC internal prototype to avoid an error.
7909 Use char because int might match the return type of a GCC
7910 builtin and then its argument prototype would still apply. */
7911 #ifdef __cplusplus
7912 extern "C"
7913 #endif
7914 char dnet_ntoa ();
7916 main ()
7918 return dnet_ntoa ();
7920 return 0;
7922 _ACEOF
7923 if ac_fn_c_try_link "$LINENO"; then :
7924 ac_cv_lib_dnet_dnet_ntoa=yes
7925 else
7926 ac_cv_lib_dnet_dnet_ntoa=no
7928 rm -f core conftest.err conftest.$ac_objext \
7929 conftest$ac_exeext conftest.$ac_ext
7930 LIBS=$ac_check_lib_save_LIBS
7932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
7933 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
7934 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
7935 cat >>confdefs.h <<_ACEOF
7936 #define HAVE_LIBDNET 1
7937 _ACEOF
7939 LIBS="-ldnet $LIBS"
7944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
7945 $as_echo_n "checking for main in -lXbsd... " >&6; }
7946 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
7947 $as_echo_n "(cached) " >&6
7948 else
7949 ac_check_lib_save_LIBS=$LIBS
7950 LIBS="-lXbsd $LIBS"
7951 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7952 /* end confdefs.h. */
7956 main ()
7958 return main ();
7960 return 0;
7962 _ACEOF
7963 if ac_fn_c_try_link "$LINENO"; then :
7964 ac_cv_lib_Xbsd_main=yes
7965 else
7966 ac_cv_lib_Xbsd_main=no
7968 rm -f core conftest.err conftest.$ac_objext \
7969 conftest$ac_exeext conftest.$ac_ext
7970 LIBS=$ac_check_lib_save_LIBS
7972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
7973 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
7974 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
7975 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
7979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
7980 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
7981 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
7982 $as_echo_n "(cached) " >&6
7983 else
7984 ac_check_lib_save_LIBS=$LIBS
7985 LIBS="-lpthreads $LIBS"
7986 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7987 /* end confdefs.h. */
7989 /* Override any GCC internal prototype to avoid an error.
7990 Use char because int might match the return type of a GCC
7991 builtin and then its argument prototype would still apply. */
7992 #ifdef __cplusplus
7993 extern "C"
7994 #endif
7995 char cma_open ();
7997 main ()
7999 return cma_open ();
8001 return 0;
8003 _ACEOF
8004 if ac_fn_c_try_link "$LINENO"; then :
8005 ac_cv_lib_pthreads_cma_open=yes
8006 else
8007 ac_cv_lib_pthreads_cma_open=no
8009 rm -f core conftest.err conftest.$ac_objext \
8010 conftest$ac_exeext conftest.$ac_ext
8011 LIBS=$ac_check_lib_save_LIBS
8013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
8014 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
8015 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
8016 cat >>confdefs.h <<_ACEOF
8017 #define HAVE_LIBPTHREADS 1
8018 _ACEOF
8020 LIBS="-lpthreads $LIBS"
8025 ## Note: when using cpp in s/aix4.2.h, this definition depended on
8026 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
8027 ## the system file was sourced. Hence the value of LIBS_SYSTEM
8028 ## added to LIBS in configure would never contain the pthreads part,
8029 ## but the value used in Makefiles might. FIXME?
8031 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
8032 ## be harmless on older versions of X where it happens to exist.
8033 test "$opsys" = "aix4-2" && \
8034 test $ac_cv_lib_pthreads_cma_open = yes && \
8035 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
8038 case ${host_os} in
8039 aix*)
8040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
8041 $as_echo_n "checking for -bbigtoc option... " >&6; }
8042 if test "${gdb_cv_bigtoc+set}" = set; then :
8043 $as_echo_n "(cached) " >&6
8044 else
8046 case $GCC in
8047 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
8048 *) gdb_cv_bigtoc=-bbigtoc ;;
8049 esac
8051 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
8052 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8053 /* end confdefs.h. */
8056 main ()
8058 int i;
8060 return 0;
8062 _ACEOF
8063 if ac_fn_c_try_link "$LINENO"; then :
8065 else
8066 gdb_cv_bigtoc=
8068 rm -f core conftest.err conftest.$ac_objext \
8069 conftest$ac_exeext conftest.$ac_ext
8072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
8073 $as_echo "$gdb_cv_bigtoc" >&6; }
8075 esac
8077 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
8078 # used for the tests that follow. We set them back to REAL_CFLAGS and
8079 # REAL_CPPFLAGS later on.
8081 REAL_CFLAGS="$CFLAGS"
8082 REAL_CPPFLAGS="$CPPFLAGS"
8084 if test "${HAVE_X11}" = "yes"; then
8085 DEFS="$C_SWITCH_X_SITE $DEFS"
8086 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
8087 LIBS="-lX11 $LIBS"
8088 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
8089 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
8091 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
8092 # This is handled by LD_SWITCH_X_SITE_AUX during the real build,
8093 # but it's more convenient here to set LD_RUN_PATH
8094 # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX.
8095 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
8096 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
8097 export LD_RUN_PATH
8100 if test "${opsys}" = "gnu-linux"; then
8101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
8102 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
8103 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8104 /* end confdefs.h. */
8107 main ()
8109 XOpenDisplay ("foo");
8111 return 0;
8113 _ACEOF
8114 if ac_fn_c_try_link "$LINENO"; then :
8115 xlinux_first_failure=no
8116 else
8117 xlinux_first_failure=yes
8119 rm -f core conftest.err conftest.$ac_objext \
8120 conftest$ac_exeext conftest.$ac_ext
8121 if test "${xlinux_first_failure}" = "yes"; then
8122 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
8123 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
8124 OLD_CPPFLAGS="$CPPFLAGS"
8125 OLD_LIBS="$LIBS"
8126 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
8127 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
8128 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
8129 LIBS="$LIBS -b i486-linuxaout"
8130 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8131 /* end confdefs.h. */
8134 main ()
8136 XOpenDisplay ("foo");
8138 return 0;
8140 _ACEOF
8141 if ac_fn_c_try_link "$LINENO"; then :
8142 xlinux_second_failure=no
8143 else
8144 xlinux_second_failure=yes
8146 rm -f core conftest.err conftest.$ac_objext \
8147 conftest$ac_exeext conftest.$ac_ext
8148 if test "${xlinux_second_failure}" = "yes"; then
8149 # If we get the same failure with -b, there is no use adding -b.
8150 # So take it out. This plays safe.
8151 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
8152 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
8153 CPPFLAGS="$OLD_CPPFLAGS"
8154 LIBS="$OLD_LIBS"
8155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8156 $as_echo "no" >&6; }
8157 else
8158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8159 $as_echo "yes" >&6; }
8161 else
8162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8163 $as_echo "no" >&6; }
8167 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
8168 # header files included from there.
8169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
8170 $as_echo_n "checking for Xkb... " >&6; }
8171 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8172 /* end confdefs.h. */
8173 #include <X11/Xlib.h>
8174 #include <X11/XKBlib.h>
8176 main ()
8178 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
8180 return 0;
8182 _ACEOF
8183 if ac_fn_c_try_link "$LINENO"; then :
8184 emacs_xkb=yes
8185 else
8186 emacs_xkb=no
8188 rm -f core conftest.err conftest.$ac_objext \
8189 conftest$ac_exeext conftest.$ac_ext
8190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
8191 $as_echo "$emacs_xkb" >&6; }
8192 if test $emacs_xkb = yes; then
8194 $as_echo "#define HAVE_XKBGETKEYBOARD 1" >>confdefs.h
8198 for ac_func in XrmSetDatabase XScreenResourceString \
8199 XScreenNumberOfScreen XSetWMProtocols
8200 do :
8201 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8202 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8203 eval as_val=\$$as_ac_var
8204 if test "x$as_val" = x""yes; then :
8205 cat >>confdefs.h <<_ACEOF
8206 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
8207 _ACEOF
8210 done
8214 if test "${window_system}" = "x11"; then
8215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
8216 $as_echo_n "checking X11 version 6... " >&6; }
8217 if test "${emacs_cv_x11_version_6+set}" = set; then :
8218 $as_echo_n "(cached) " >&6
8219 else
8220 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8221 /* end confdefs.h. */
8222 #include <X11/Xlib.h>
8224 main ()
8226 #if XlibSpecificationRelease < 6
8227 fail;
8228 #endif
8231 return 0;
8233 _ACEOF
8234 if ac_fn_c_try_link "$LINENO"; then :
8235 emacs_cv_x11_version_6=yes
8236 else
8237 emacs_cv_x11_version_6=no
8239 rm -f core conftest.err conftest.$ac_objext \
8240 conftest$ac_exeext conftest.$ac_ext
8243 if test $emacs_cv_x11_version_6 = yes; then
8244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
8245 $as_echo "6 or newer" >&6; }
8247 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
8250 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
8252 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
8253 ## XIM support.
8254 case "$opsys" in
8255 sol2-*) : ;;
8257 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
8260 esac
8261 else
8262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
8263 $as_echo "before 6" >&6; }
8268 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
8269 HAVE_RSVG=no
8270 if test "${HAVE_X11}" = "yes" || test "${NS_IMPL_GNUSTEP}" = "yes"; then
8271 if test "${with_rsvg}" != "no"; then
8272 RSVG_REQUIRED=2.11.0
8273 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
8276 succeeded=no
8278 # Extract the first word of "pkg-config", so it can be a program name with args.
8279 set dummy pkg-config; ac_word=$2
8280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8281 $as_echo_n "checking for $ac_word... " >&6; }
8282 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8283 $as_echo_n "(cached) " >&6
8284 else
8285 case $PKG_CONFIG in
8286 [\\/]* | ?:[\\/]*)
8287 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8290 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8291 for as_dir in $PATH
8293 IFS=$as_save_IFS
8294 test -z "$as_dir" && as_dir=.
8295 for ac_exec_ext in '' $ac_executable_extensions; do
8296 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8297 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8298 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8299 break 2
8301 done
8302 done
8303 IFS=$as_save_IFS
8305 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8307 esac
8309 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8310 if test -n "$PKG_CONFIG"; then
8311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8312 $as_echo "$PKG_CONFIG" >&6; }
8313 else
8314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8315 $as_echo "no" >&6; }
8320 if test "$PKG_CONFIG" = "no" ; then
8322 else
8323 PKG_CONFIG_MIN_VERSION=0.9.0
8324 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
8326 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
8328 if $PKG_CONFIG --exists "$RSVG_MODULE" 2>&5; then
8329 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8330 $as_echo "yes" >&6; }
8331 succeeded=yes
8333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking RSVG_CFLAGS" >&5
8334 $as_echo_n "checking RSVG_CFLAGS... " >&6; }
8335 RSVG_CFLAGS=`$PKG_CONFIG --cflags "$RSVG_MODULE"|sed -e 's,///*,/,g'`
8336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RSVG_CFLAGS" >&5
8337 $as_echo "$RSVG_CFLAGS" >&6; }
8339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking RSVG_LIBS" >&5
8340 $as_echo_n "checking RSVG_LIBS... " >&6; }
8341 RSVG_LIBS=`$PKG_CONFIG --libs "$RSVG_MODULE"|sed -e 's,///*,/,g'`
8342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RSVG_LIBS" >&5
8343 $as_echo "$RSVG_LIBS" >&6; }
8344 else
8345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8346 $as_echo "no" >&6; }
8347 RSVG_CFLAGS=""
8348 RSVG_LIBS=""
8349 ## If we have a custom action on failure, don't print errors, but
8350 ## do set a variable so people can do so.
8351 RSVG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$RSVG_MODULE"`
8357 else
8358 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8359 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8363 if test $succeeded = yes; then
8365 else
8372 if test ".${RSVG_CFLAGS}" != "."; then
8373 HAVE_RSVG=yes
8375 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
8377 CFLAGS="$CFLAGS $RSVG_CFLAGS"
8378 LIBS="$RSVG_LIBS $LIBS"
8384 HAVE_GTK=no
8385 if test "${with_gtk3}" = "yes"; then
8386 GLIB_REQUIRED=2.6
8387 GTK_REQUIRED=2.90
8388 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
8391 succeeded=no
8393 # Extract the first word of "pkg-config", so it can be a program name with args.
8394 set dummy pkg-config; ac_word=$2
8395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8396 $as_echo_n "checking for $ac_word... " >&6; }
8397 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8398 $as_echo_n "(cached) " >&6
8399 else
8400 case $PKG_CONFIG in
8401 [\\/]* | ?:[\\/]*)
8402 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8405 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8406 for as_dir in $PATH
8408 IFS=$as_save_IFS
8409 test -z "$as_dir" && as_dir=.
8410 for ac_exec_ext in '' $ac_executable_extensions; do
8411 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8412 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8413 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8414 break 2
8416 done
8417 done
8418 IFS=$as_save_IFS
8420 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8422 esac
8424 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8425 if test -n "$PKG_CONFIG"; then
8426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8427 $as_echo "$PKG_CONFIG" >&6; }
8428 else
8429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8430 $as_echo "no" >&6; }
8435 if test "$PKG_CONFIG" = "no" ; then
8436 pkg_check_gtk=no
8437 else
8438 PKG_CONFIG_MIN_VERSION=0.9.0
8439 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
8441 $as_echo_n "checking for $GTK_MODULES... " >&6; }
8443 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5; then
8444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8445 $as_echo "yes" >&6; }
8446 succeeded=yes
8448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_CFLAGS" >&5
8449 $as_echo_n "checking GTK_CFLAGS... " >&6; }
8450 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"|sed -e 's,///*,/,g'`
8451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_CFLAGS" >&5
8452 $as_echo "$GTK_CFLAGS" >&6; }
8454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_LIBS" >&5
8455 $as_echo_n "checking GTK_LIBS... " >&6; }
8456 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"|sed -e 's,///*,/,g'`
8457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_LIBS" >&5
8458 $as_echo "$GTK_LIBS" >&6; }
8459 else
8460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8461 $as_echo "no" >&6; }
8462 GTK_CFLAGS=""
8463 GTK_LIBS=""
8464 ## If we have a custom action on failure, don't print errors, but
8465 ## do set a variable so people can do so.
8466 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
8472 else
8473 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8474 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8478 if test $succeeded = yes; then
8479 pkg_check_gtk=yes
8480 else
8481 pkg_check_gtk=no
8484 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
8485 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
8489 if test "$pkg_check_gtk" != "yes"; then
8490 HAVE_GTK=no
8491 if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
8492 GLIB_REQUIRED=2.6
8493 GTK_REQUIRED=2.6
8494 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
8497 succeeded=no
8499 # Extract the first word of "pkg-config", so it can be a program name with args.
8500 set dummy pkg-config; ac_word=$2
8501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8502 $as_echo_n "checking for $ac_word... " >&6; }
8503 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8504 $as_echo_n "(cached) " >&6
8505 else
8506 case $PKG_CONFIG in
8507 [\\/]* | ?:[\\/]*)
8508 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8511 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8512 for as_dir in $PATH
8514 IFS=$as_save_IFS
8515 test -z "$as_dir" && as_dir=.
8516 for ac_exec_ext in '' $ac_executable_extensions; do
8517 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8518 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8519 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8520 break 2
8522 done
8523 done
8524 IFS=$as_save_IFS
8526 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8528 esac
8530 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8531 if test -n "$PKG_CONFIG"; then
8532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8533 $as_echo "$PKG_CONFIG" >&6; }
8534 else
8535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8536 $as_echo "no" >&6; }
8541 if test "$PKG_CONFIG" = "no" ; then
8542 pkg_check_gtk=no
8543 else
8544 PKG_CONFIG_MIN_VERSION=0.9.0
8545 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
8547 $as_echo_n "checking for $GTK_MODULES... " >&6; }
8549 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5; then
8550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8551 $as_echo "yes" >&6; }
8552 succeeded=yes
8554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_CFLAGS" >&5
8555 $as_echo_n "checking GTK_CFLAGS... " >&6; }
8556 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"|sed -e 's,///*,/,g'`
8557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_CFLAGS" >&5
8558 $as_echo "$GTK_CFLAGS" >&6; }
8560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_LIBS" >&5
8561 $as_echo_n "checking GTK_LIBS... " >&6; }
8562 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"|sed -e 's,///*,/,g'`
8563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_LIBS" >&5
8564 $as_echo "$GTK_LIBS" >&6; }
8565 else
8566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8567 $as_echo "no" >&6; }
8568 GTK_CFLAGS=""
8569 GTK_LIBS=""
8570 ## If we have a custom action on failure, don't print errors, but
8571 ## do set a variable so people can do so.
8572 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
8578 else
8579 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8580 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8584 if test $succeeded = yes; then
8585 pkg_check_gtk=yes
8586 else
8587 pkg_check_gtk=no
8590 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
8591 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
8596 GTK_OBJ=
8597 if test x"$pkg_check_gtk" = xyes; then
8601 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
8602 CFLAGS="$CFLAGS $GTK_CFLAGS"
8603 LIBS="$GTK_LIBS $LIBS"
8604 GTK_COMPILES=no
8605 for ac_func in gtk_main
8606 do :
8607 ac_fn_c_check_func "$LINENO" "gtk_main" "ac_cv_func_gtk_main"
8608 if test "x$ac_cv_func_gtk_main" = x""yes; then :
8609 cat >>confdefs.h <<_ACEOF
8610 #define HAVE_GTK_MAIN 1
8611 _ACEOF
8612 GTK_COMPILES=yes
8614 done
8616 if test "${GTK_COMPILES}" != "yes"; then
8617 if test "$USE_X_TOOLKIT" != "maybe"; then
8618 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
8620 else
8621 HAVE_GTK=yes
8623 $as_echo "#define USE_GTK 1" >>confdefs.h
8625 GTK_OBJ=gtkutil.o
8626 USE_X_TOOLKIT=none
8627 if $PKG_CONFIG --atleast-version=2.10 gtk+-2.0; then
8629 else
8630 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
8631 closing open displays. This is no problem if you just use
8632 one display, but if you use more than one and close one of them
8633 Emacs may crash." >&5
8634 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
8635 closing open displays. This is no problem if you just use
8636 one display, but if you use more than one and close one of them
8637 Emacs may crash." >&2;}
8638 sleep 3
8646 if test "${HAVE_GTK}" = "yes"; then
8648 if test "$with_toolkit_scroll_bars" != no; then
8649 with_toolkit_scroll_bars=yes
8652 HAVE_GTK_FILE_SELECTION=no
8653 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
8654 #include <gtk/gtk.h>
8656 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
8657 HAVE_GTK_FILE_SELECTION=yes
8658 else
8659 HAVE_GTK_FILE_SELECTION=no
8662 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
8663 for ac_func in gtk_file_selection_new
8664 do :
8665 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
8666 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
8667 cat >>confdefs.h <<_ACEOF
8668 #define HAVE_GTK_FILE_SELECTION_NEW 1
8669 _ACEOF
8672 done
8676 HAVE_GTK_AND_PTHREAD=no
8677 for ac_header in pthread.h
8678 do :
8679 ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
8680 if test "x$ac_cv_header_pthread_h" = x""yes; then :
8681 cat >>confdefs.h <<_ACEOF
8682 #define HAVE_PTHREAD_H 1
8683 _ACEOF
8687 done
8689 if test "$ac_cv_header_pthread_h"; then
8690 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_self in -lpthread" >&5
8691 $as_echo_n "checking for pthread_self in -lpthread... " >&6; }
8692 if test "${ac_cv_lib_pthread_pthread_self+set}" = set; then :
8693 $as_echo_n "(cached) " >&6
8694 else
8695 ac_check_lib_save_LIBS=$LIBS
8696 LIBS="-lpthread $LIBS"
8697 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8698 /* end confdefs.h. */
8700 /* Override any GCC internal prototype to avoid an error.
8701 Use char because int might match the return type of a GCC
8702 builtin and then its argument prototype would still apply. */
8703 #ifdef __cplusplus
8704 extern "C"
8705 #endif
8706 char pthread_self ();
8708 main ()
8710 return pthread_self ();
8712 return 0;
8714 _ACEOF
8715 if ac_fn_c_try_link "$LINENO"; then :
8716 ac_cv_lib_pthread_pthread_self=yes
8717 else
8718 ac_cv_lib_pthread_pthread_self=no
8720 rm -f core conftest.err conftest.$ac_objext \
8721 conftest$ac_exeext conftest.$ac_ext
8722 LIBS=$ac_check_lib_save_LIBS
8724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_self" >&5
8725 $as_echo "$ac_cv_lib_pthread_pthread_self" >&6; }
8726 if test "x$ac_cv_lib_pthread_pthread_self" = x""yes; then :
8727 HAVE_GTK_AND_PTHREAD=yes
8731 if test "$HAVE_GTK_AND_PTHREAD" = yes; then
8732 case "${canonical}" in
8733 *-hpux*) ;;
8734 *) GTK_LIBS="$GTK_LIBS -lpthread" ;;
8735 esac
8737 $as_echo "#define HAVE_GTK_AND_PTHREAD 1" >>confdefs.h
8741 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
8742 gtk_dialog_get_action_area gtk_widget_get_sensitive \
8743 gtk_widget_get_mapped gtk_adjustment_get_page_size \
8744 gtk_orientable_set_orientation
8745 do :
8746 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8747 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8748 eval as_val=\$$as_ac_var
8749 if test "x$as_val" = x""yes; then :
8750 cat >>confdefs.h <<_ACEOF
8751 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
8752 _ACEOF
8755 done
8760 HAVE_DBUS=no
8761 DBUS_OBJ=
8762 if test "${with_dbus}" = "yes"; then
8764 succeeded=no
8766 # Extract the first word of "pkg-config", so it can be a program name with args.
8767 set dummy pkg-config; ac_word=$2
8768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8769 $as_echo_n "checking for $ac_word... " >&6; }
8770 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8771 $as_echo_n "(cached) " >&6
8772 else
8773 case $PKG_CONFIG in
8774 [\\/]* | ?:[\\/]*)
8775 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8778 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8779 for as_dir in $PATH
8781 IFS=$as_save_IFS
8782 test -z "$as_dir" && as_dir=.
8783 for ac_exec_ext in '' $ac_executable_extensions; do
8784 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8785 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8786 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8787 break 2
8789 done
8790 done
8791 IFS=$as_save_IFS
8793 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8795 esac
8797 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8798 if test -n "$PKG_CONFIG"; then
8799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8800 $as_echo "$PKG_CONFIG" >&6; }
8801 else
8802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8803 $as_echo "no" >&6; }
8808 if test "$PKG_CONFIG" = "no" ; then
8809 HAVE_DBUS=no
8810 else
8811 PKG_CONFIG_MIN_VERSION=0.9.0
8812 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
8814 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
8816 if $PKG_CONFIG --exists "dbus-1 >= 1.0" 2>&5; then
8817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8818 $as_echo "yes" >&6; }
8819 succeeded=yes
8821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking DBUS_CFLAGS" >&5
8822 $as_echo_n "checking DBUS_CFLAGS... " >&6; }
8823 DBUS_CFLAGS=`$PKG_CONFIG --cflags "dbus-1 >= 1.0"|sed -e 's,///*,/,g'`
8824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBUS_CFLAGS" >&5
8825 $as_echo "$DBUS_CFLAGS" >&6; }
8827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking DBUS_LIBS" >&5
8828 $as_echo_n "checking DBUS_LIBS... " >&6; }
8829 DBUS_LIBS=`$PKG_CONFIG --libs "dbus-1 >= 1.0"|sed -e 's,///*,/,g'`
8830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBUS_LIBS" >&5
8831 $as_echo "$DBUS_LIBS" >&6; }
8832 else
8833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8834 $as_echo "no" >&6; }
8835 DBUS_CFLAGS=""
8836 DBUS_LIBS=""
8837 ## If we have a custom action on failure, don't print errors, but
8838 ## do set a variable so people can do so.
8839 DBUS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "dbus-1 >= 1.0"`
8845 else
8846 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8847 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8851 if test $succeeded = yes; then
8852 HAVE_DBUS=yes
8853 else
8854 HAVE_DBUS=no
8857 if test "$HAVE_DBUS" = yes; then
8858 LIBS="$LIBS $DBUS_LIBS"
8860 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
8862 for ac_func in dbus_watch_get_unix_fd
8863 do :
8864 ac_fn_c_check_func "$LINENO" "dbus_watch_get_unix_fd" "ac_cv_func_dbus_watch_get_unix_fd"
8865 if test "x$ac_cv_func_dbus_watch_get_unix_fd" = x""yes; then :
8866 cat >>confdefs.h <<_ACEOF
8867 #define HAVE_DBUS_WATCH_GET_UNIX_FD 1
8868 _ACEOF
8871 done
8873 DBUS_OBJ=dbusbind.o
8878 HAVE_GCONF=no
8879 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
8881 succeeded=no
8883 # Extract the first word of "pkg-config", so it can be a program name with args.
8884 set dummy pkg-config; ac_word=$2
8885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8886 $as_echo_n "checking for $ac_word... " >&6; }
8887 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8888 $as_echo_n "(cached) " >&6
8889 else
8890 case $PKG_CONFIG in
8891 [\\/]* | ?:[\\/]*)
8892 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8895 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8896 for as_dir in $PATH
8898 IFS=$as_save_IFS
8899 test -z "$as_dir" && as_dir=.
8900 for ac_exec_ext in '' $ac_executable_extensions; do
8901 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8902 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8903 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8904 break 2
8906 done
8907 done
8908 IFS=$as_save_IFS
8910 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8912 esac
8914 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8915 if test -n "$PKG_CONFIG"; then
8916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8917 $as_echo "$PKG_CONFIG" >&6; }
8918 else
8919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8920 $as_echo "no" >&6; }
8925 if test "$PKG_CONFIG" = "no" ; then
8926 HAVE_GCONF=no
8927 else
8928 PKG_CONFIG_MIN_VERSION=0.9.0
8929 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
8931 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
8933 if $PKG_CONFIG --exists "gconf-2.0 >= 2.13" 2>&5; then
8934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8935 $as_echo "yes" >&6; }
8936 succeeded=yes
8938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GCONF_CFLAGS" >&5
8939 $as_echo_n "checking GCONF_CFLAGS... " >&6; }
8940 GCONF_CFLAGS=`$PKG_CONFIG --cflags "gconf-2.0 >= 2.13"|sed -e 's,///*,/,g'`
8941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCONF_CFLAGS" >&5
8942 $as_echo "$GCONF_CFLAGS" >&6; }
8944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GCONF_LIBS" >&5
8945 $as_echo_n "checking GCONF_LIBS... " >&6; }
8946 GCONF_LIBS=`$PKG_CONFIG --libs "gconf-2.0 >= 2.13"|sed -e 's,///*,/,g'`
8947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCONF_LIBS" >&5
8948 $as_echo "$GCONF_LIBS" >&6; }
8949 else
8950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8951 $as_echo "no" >&6; }
8952 GCONF_CFLAGS=""
8953 GCONF_LIBS=""
8954 ## If we have a custom action on failure, don't print errors, but
8955 ## do set a variable so people can do so.
8956 GCONF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gconf-2.0 >= 2.13"`
8962 else
8963 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8964 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8968 if test $succeeded = yes; then
8969 HAVE_GCONF=yes
8970 else
8971 HAVE_GCONF=no
8974 if test "$HAVE_GCONF" = yes; then
8976 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
8981 HAVE_LIBSELINUX=no
8982 LIBSELINUX_LIBS=
8983 if test "${with_selinux}" = "yes"; then
8984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
8985 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
8986 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
8987 $as_echo_n "(cached) " >&6
8988 else
8989 ac_check_lib_save_LIBS=$LIBS
8990 LIBS="-lselinux $LIBS"
8991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8992 /* end confdefs.h. */
8994 /* Override any GCC internal prototype to avoid an error.
8995 Use char because int might match the return type of a GCC
8996 builtin and then its argument prototype would still apply. */
8997 #ifdef __cplusplus
8998 extern "C"
8999 #endif
9000 char lgetfilecon ();
9002 main ()
9004 return lgetfilecon ();
9006 return 0;
9008 _ACEOF
9009 if ac_fn_c_try_link "$LINENO"; then :
9010 ac_cv_lib_selinux_lgetfilecon=yes
9011 else
9012 ac_cv_lib_selinux_lgetfilecon=no
9014 rm -f core conftest.err conftest.$ac_objext \
9015 conftest$ac_exeext conftest.$ac_ext
9016 LIBS=$ac_check_lib_save_LIBS
9018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
9019 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
9020 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
9021 HAVE_LIBSELINUX=yes
9022 else
9023 HAVE_LIBSELINUX=no
9026 if test "$HAVE_LIBSELINUX" = yes; then
9028 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
9030 LIBSELINUX_LIBS=-lselinux
9035 HAVE_XAW3D=no
9036 LUCID_LIBW=
9037 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
9038 if test "$with_xaw3d" != no; then
9039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
9040 $as_echo_n "checking for xaw3d... " >&6; }
9041 if test "${emacs_cv_xaw3d+set}" = set; then :
9042 $as_echo_n "(cached) " >&6
9043 else
9044 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9045 /* end confdefs.h. */
9047 #include <X11/Intrinsic.h>
9048 #include <X11/Xaw3d/Simple.h>
9050 main ()
9054 return 0;
9056 _ACEOF
9057 if ac_fn_c_try_link "$LINENO"; then :
9058 emacs_cv_xaw3d=yes
9059 else
9060 emacs_cv_xaw3d=no
9062 rm -f core conftest.err conftest.$ac_objext \
9063 conftest$ac_exeext conftest.$ac_ext
9066 else
9067 emacs_cv_xaw3d=no
9069 if test $emacs_cv_xaw3d = yes; then
9070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
9071 $as_echo "yes; using Lucid toolkit" >&6; }
9072 USE_X_TOOLKIT=LUCID
9073 HAVE_XAW3D=yes
9074 LUCID_LIBW=-lXaw3d
9076 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
9078 else
9079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9080 $as_echo "no" >&6; }
9081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
9082 $as_echo_n "checking for libXaw... " >&6; }
9083 if test "${emacs_cv_xaw+set}" = set; then :
9084 $as_echo_n "(cached) " >&6
9085 else
9086 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9087 /* end confdefs.h. */
9089 #include <X11/Intrinsic.h>
9090 #include <X11/Xaw/Simple.h>
9092 main ()
9096 return 0;
9098 _ACEOF
9099 if ac_fn_c_try_link "$LINENO"; then :
9100 emacs_cv_xaw=yes
9101 else
9102 emacs_cv_xaw=no
9104 rm -f core conftest.err conftest.$ac_objext \
9105 conftest$ac_exeext conftest.$ac_ext
9108 if test $emacs_cv_xaw = yes; then
9109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
9110 $as_echo "yes; using Lucid toolkit" >&6; }
9111 USE_X_TOOLKIT=LUCID
9112 LUCID_LIBW=-lXaw
9113 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
9114 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
9115 else
9116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no; do not use toolkit by default" >&5
9117 $as_echo "no; do not use toolkit by default" >&6; }
9118 USE_X_TOOLKIT=none
9123 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
9125 LIBXTR6=
9126 if test "${USE_X_TOOLKIT}" != "none"; then
9127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
9128 $as_echo_n "checking X11 toolkit version... " >&6; }
9129 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
9130 $as_echo_n "(cached) " >&6
9131 else
9132 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9133 /* end confdefs.h. */
9134 #include <X11/Intrinsic.h>
9136 main ()
9138 #if XtSpecificationRelease < 6
9139 fail;
9140 #endif
9143 return 0;
9145 _ACEOF
9146 if ac_fn_c_try_link "$LINENO"; then :
9147 emacs_cv_x11_toolkit_version_6=yes
9148 else
9149 emacs_cv_x11_toolkit_version_6=no
9151 rm -f core conftest.err conftest.$ac_objext \
9152 conftest$ac_exeext conftest.$ac_ext
9155 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
9156 if test $emacs_cv_x11_toolkit_version_6 = yes; then
9157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
9158 $as_echo "6 or newer" >&6; }
9160 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
9162 LIBXTR6="-lSM -lICE"
9163 case "$opsys" in
9164 ## Use libw.a along with X11R6 Xt.
9165 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
9166 esac
9167 else
9168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
9169 $as_echo "before 6" >&6; }
9172 OLDLIBS="$LIBS"
9173 if test x$HAVE_X11XTR6 = xyes; then
9174 LIBS="-lXt -lSM -lICE $LIBS"
9175 else
9176 LIBS="-lXt $LIBS"
9178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
9179 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
9180 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
9181 $as_echo_n "(cached) " >&6
9182 else
9183 ac_check_lib_save_LIBS=$LIBS
9184 LIBS="-lXmu $LIBS"
9185 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9186 /* end confdefs.h. */
9188 /* Override any GCC internal prototype to avoid an error.
9189 Use char because int might match the return type of a GCC
9190 builtin and then its argument prototype would still apply. */
9191 #ifdef __cplusplus
9192 extern "C"
9193 #endif
9194 char XmuConvertStandardSelection ();
9196 main ()
9198 return XmuConvertStandardSelection ();
9200 return 0;
9202 _ACEOF
9203 if ac_fn_c_try_link "$LINENO"; then :
9204 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
9205 else
9206 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
9208 rm -f core conftest.err conftest.$ac_objext \
9209 conftest$ac_exeext conftest.$ac_ext
9210 LIBS=$ac_check_lib_save_LIBS
9212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
9213 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
9214 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
9215 cat >>confdefs.h <<_ACEOF
9216 #define HAVE_LIBXMU 1
9217 _ACEOF
9219 LIBS="-lXmu $LIBS"
9223 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
9227 LIBXMU=-lXmu
9228 case "$machine" in
9229 ## These machines don't supply Xmu.
9230 hpux* | aix4-2 )
9231 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
9233 esac
9236 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
9237 if test "${HAVE_X11}" = "yes"; then
9238 if test "${USE_X_TOOLKIT}" != "none"; then
9239 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
9240 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
9241 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
9242 $as_echo_n "(cached) " >&6
9243 else
9244 ac_check_lib_save_LIBS=$LIBS
9245 LIBS="-lXext $LIBS"
9246 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9247 /* end confdefs.h. */
9249 /* Override any GCC internal prototype to avoid an error.
9250 Use char because int might match the return type of a GCC
9251 builtin and then its argument prototype would still apply. */
9252 #ifdef __cplusplus
9253 extern "C"
9254 #endif
9255 char XShapeQueryExtension ();
9257 main ()
9259 return XShapeQueryExtension ();
9261 return 0;
9263 _ACEOF
9264 if ac_fn_c_try_link "$LINENO"; then :
9265 ac_cv_lib_Xext_XShapeQueryExtension=yes
9266 else
9267 ac_cv_lib_Xext_XShapeQueryExtension=no
9269 rm -f core conftest.err conftest.$ac_objext \
9270 conftest$ac_exeext conftest.$ac_ext
9271 LIBS=$ac_check_lib_save_LIBS
9273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
9274 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
9275 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
9276 cat >>confdefs.h <<_ACEOF
9277 #define HAVE_LIBXEXT 1
9278 _ACEOF
9280 LIBS="-lXext $LIBS"
9287 LIBXP=
9288 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
9289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Motif version 2.1" >&5
9290 $as_echo_n "checking for Motif version 2.1... " >&6; }
9291 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
9292 $as_echo_n "(cached) " >&6
9293 else
9294 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9295 /* end confdefs.h. */
9296 #include <Xm/Xm.h>
9298 main ()
9300 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
9301 int x = 5;
9302 #else
9303 Motif version prior to 2.1.
9304 #endif
9306 return 0;
9308 _ACEOF
9309 if ac_fn_c_try_compile "$LINENO"; then :
9310 emacs_cv_motif_version_2_1=yes
9311 else
9312 emacs_cv_motif_version_2_1=no
9314 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
9317 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
9318 if test $emacs_cv_motif_version_2_1 = yes; then
9319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
9320 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
9321 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
9322 $as_echo_n "(cached) " >&6
9323 else
9324 ac_check_lib_save_LIBS=$LIBS
9325 LIBS="-lXp $LIBS"
9326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9327 /* end confdefs.h. */
9329 /* Override any GCC internal prototype to avoid an error.
9330 Use char because int might match the return type of a GCC
9331 builtin and then its argument prototype would still apply. */
9332 #ifdef __cplusplus
9333 extern "C"
9334 #endif
9335 char XpCreateContext ();
9337 main ()
9339 return XpCreateContext ();
9341 return 0;
9343 _ACEOF
9344 if ac_fn_c_try_link "$LINENO"; then :
9345 ac_cv_lib_Xp_XpCreateContext=yes
9346 else
9347 ac_cv_lib_Xp_XpCreateContext=no
9349 rm -f core conftest.err conftest.$ac_objext \
9350 conftest$ac_exeext conftest.$ac_ext
9351 LIBS=$ac_check_lib_save_LIBS
9353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
9354 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
9355 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
9356 LIBXP=-lXp
9359 else
9360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
9361 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
9362 if test "${emacs_cv_lesstif+set}" = set; then :
9363 $as_echo_n "(cached) " >&6
9364 else
9365 # We put this in CFLAGS temporarily to precede other -I options
9366 # that might be in CFLAGS temporarily.
9367 # We put this in CPPFLAGS where it precedes the other -I options.
9368 OLD_CPPFLAGS=$CPPFLAGS
9369 OLD_CFLAGS=$CFLAGS
9370 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
9371 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
9372 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9373 /* end confdefs.h. */
9374 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
9376 main ()
9378 int x = 5;
9380 return 0;
9382 _ACEOF
9383 if ac_fn_c_try_compile "$LINENO"; then :
9384 emacs_cv_lesstif=yes
9385 else
9386 emacs_cv_lesstif=no
9388 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
9391 $as_echo "$emacs_cv_lesstif" >&6; }
9392 if test $emacs_cv_lesstif = yes; then
9393 # Make sure this -I option remains in CPPFLAGS after it is set
9394 # back to REAL_CPPFLAGS.
9395 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
9396 # have those other -I options anyway. Ultimately, having this
9397 # directory ultimately in CPPFLAGS will be enough.
9398 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
9399 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
9400 else
9401 CFLAGS=$OLD_CFLAGS
9402 CPPFLAGS=$OLD_CPPFLAGS
9408 USE_TOOLKIT_SCROLL_BARS=no
9409 if test "${with_toolkit_scroll_bars}" != "no"; then
9410 if test "${USE_X_TOOLKIT}" != "none"; then
9411 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
9412 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
9414 HAVE_XAW3D=no
9415 USE_TOOLKIT_SCROLL_BARS=yes
9416 elif test "${HAVE_XAW3D}" = "yes"; then
9417 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
9419 USE_TOOLKIT_SCROLL_BARS=yes
9421 elif test "${HAVE_GTK}" = "yes"; then
9422 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
9424 USE_TOOLKIT_SCROLL_BARS=yes
9425 elif test "${HAVE_NS}" = "yes"; then
9426 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
9428 USE_TOOLKIT_SCROLL_BARS=yes
9432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9433 /* end confdefs.h. */
9435 #include <X11/Xlib.h>
9436 #include <X11/Xresource.h>
9438 main ()
9440 XIMProc callback;
9442 return 0;
9444 _ACEOF
9445 if ac_fn_c_try_compile "$LINENO"; then :
9446 HAVE_XIM=yes
9448 $as_echo "#define HAVE_XIM 1" >>confdefs.h
9450 else
9451 HAVE_XIM=no
9453 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9456 if test "${with_xim}" != "no"; then
9458 $as_echo "#define USE_XIM 1" >>confdefs.h
9463 if test "${HAVE_XIM}" != "no"; then
9464 late_CFLAGS=$CFLAGS
9465 if test "$GCC" = yes; then
9466 CFLAGS="$CFLAGS --pedantic-errors"
9468 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9469 /* end confdefs.h. */
9471 #include <X11/Xlib.h>
9472 #include <X11/Xresource.h>
9474 main ()
9476 Display *display;
9477 XrmDatabase db;
9478 char *res_name;
9479 char *res_class;
9480 XIMProc callback;
9481 XPointer *client_data;
9482 #ifndef __GNUC__
9483 /* If we're not using GCC, it's probably not XFree86, and this is
9484 probably right, but we can't use something like --pedantic-errors. */
9485 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
9486 char*, XIMProc, XPointer*);
9487 #endif
9488 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
9489 client_data);
9491 return 0;
9493 _ACEOF
9494 if ac_fn_c_try_compile "$LINENO"; then :
9495 emacs_cv_arg6_star=yes
9497 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9498 if test "$emacs_cv_arg6_star" = yes; then
9499 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
9501 else
9502 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
9505 CFLAGS=$late_CFLAGS
9508 ### Start of font-backend (under any platform) section.
9509 # (nothing here yet -- this is a placeholder)
9510 ### End of font-backend (under any platform) section.
9512 ### Start of font-backend (under X11) section.
9513 if test "${HAVE_X11}" = "yes"; then
9515 succeeded=no
9517 # Extract the first word of "pkg-config", so it can be a program name with args.
9518 set dummy pkg-config; ac_word=$2
9519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9520 $as_echo_n "checking for $ac_word... " >&6; }
9521 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
9522 $as_echo_n "(cached) " >&6
9523 else
9524 case $PKG_CONFIG in
9525 [\\/]* | ?:[\\/]*)
9526 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9529 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9530 for as_dir in $PATH
9532 IFS=$as_save_IFS
9533 test -z "$as_dir" && as_dir=.
9534 for ac_exec_ext in '' $ac_executable_extensions; do
9535 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9536 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9537 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9538 break 2
9540 done
9541 done
9542 IFS=$as_save_IFS
9544 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9546 esac
9548 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9549 if test -n "$PKG_CONFIG"; then
9550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
9551 $as_echo "$PKG_CONFIG" >&6; }
9552 else
9553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9554 $as_echo "no" >&6; }
9559 if test "$PKG_CONFIG" = "no" ; then
9560 HAVE_FC=no
9561 else
9562 PKG_CONFIG_MIN_VERSION=0.9.0
9563 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
9565 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
9567 if $PKG_CONFIG --exists "fontconfig >= 2.2.0" 2>&5; then
9568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9569 $as_echo "yes" >&6; }
9570 succeeded=yes
9572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking FONTCONFIG_CFLAGS" >&5
9573 $as_echo_n "checking FONTCONFIG_CFLAGS... " >&6; }
9574 FONTCONFIG_CFLAGS=`$PKG_CONFIG --cflags "fontconfig >= 2.2.0"|sed -e 's,///*,/,g'`
9575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FONTCONFIG_CFLAGS" >&5
9576 $as_echo "$FONTCONFIG_CFLAGS" >&6; }
9578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking FONTCONFIG_LIBS" >&5
9579 $as_echo_n "checking FONTCONFIG_LIBS... " >&6; }
9580 FONTCONFIG_LIBS=`$PKG_CONFIG --libs "fontconfig >= 2.2.0"|sed -e 's,///*,/,g'`
9581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FONTCONFIG_LIBS" >&5
9582 $as_echo "$FONTCONFIG_LIBS" >&6; }
9583 else
9584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9585 $as_echo "no" >&6; }
9586 FONTCONFIG_CFLAGS=""
9587 FONTCONFIG_LIBS=""
9588 ## If we have a custom action on failure, don't print errors, but
9589 ## do set a variable so people can do so.
9590 FONTCONFIG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "fontconfig >= 2.2.0"`
9596 else
9597 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9598 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9602 if test $succeeded = yes; then
9603 HAVE_FC=yes
9604 else
9605 HAVE_FC=no
9609 ## Use -lXft if available, unless `--with-xft=no'.
9610 HAVE_XFT=maybe
9611 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
9612 with_xft="no";
9614 if test "x${with_xft}" != "xno"; then
9617 succeeded=no
9619 # Extract the first word of "pkg-config", so it can be a program name with args.
9620 set dummy pkg-config; ac_word=$2
9621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9622 $as_echo_n "checking for $ac_word... " >&6; }
9623 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
9624 $as_echo_n "(cached) " >&6
9625 else
9626 case $PKG_CONFIG in
9627 [\\/]* | ?:[\\/]*)
9628 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9631 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9632 for as_dir in $PATH
9634 IFS=$as_save_IFS
9635 test -z "$as_dir" && as_dir=.
9636 for ac_exec_ext in '' $ac_executable_extensions; do
9637 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9638 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9639 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9640 break 2
9642 done
9643 done
9644 IFS=$as_save_IFS
9646 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9648 esac
9650 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9651 if test -n "$PKG_CONFIG"; then
9652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
9653 $as_echo "$PKG_CONFIG" >&6; }
9654 else
9655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9656 $as_echo "no" >&6; }
9661 if test "$PKG_CONFIG" = "no" ; then
9662 HAVE_XFT=no
9663 else
9664 PKG_CONFIG_MIN_VERSION=0.9.0
9665 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
9667 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
9669 if $PKG_CONFIG --exists "xft >= 0.13.0" 2>&5; then
9670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9671 $as_echo "yes" >&6; }
9672 succeeded=yes
9674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking XFT_CFLAGS" >&5
9675 $as_echo_n "checking XFT_CFLAGS... " >&6; }
9676 XFT_CFLAGS=`$PKG_CONFIG --cflags "xft >= 0.13.0"|sed -e 's,///*,/,g'`
9677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XFT_CFLAGS" >&5
9678 $as_echo "$XFT_CFLAGS" >&6; }
9680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking XFT_LIBS" >&5
9681 $as_echo_n "checking XFT_LIBS... " >&6; }
9682 XFT_LIBS=`$PKG_CONFIG --libs "xft >= 0.13.0"|sed -e 's,///*,/,g'`
9683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XFT_LIBS" >&5
9684 $as_echo "$XFT_LIBS" >&6; }
9685 else
9686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9687 $as_echo "no" >&6; }
9688 XFT_CFLAGS=""
9689 XFT_LIBS=""
9690 ## If we have a custom action on failure, don't print errors, but
9691 ## do set a variable so people can do so.
9692 XFT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "xft >= 0.13.0"`
9698 else
9699 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9700 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9704 if test $succeeded = yes; then
9706 else
9707 HAVE_XFT=no
9710 ## Because xftfont.c uses XRenderQueryExtension, we also
9711 ## need to link to -lXrender.
9712 HAVE_XRENDER=no
9713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
9714 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
9715 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
9716 $as_echo_n "(cached) " >&6
9717 else
9718 ac_check_lib_save_LIBS=$LIBS
9719 LIBS="-lXrender $LIBS"
9720 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9721 /* end confdefs.h. */
9723 /* Override any GCC internal prototype to avoid an error.
9724 Use char because int might match the return type of a GCC
9725 builtin and then its argument prototype would still apply. */
9726 #ifdef __cplusplus
9727 extern "C"
9728 #endif
9729 char XRenderQueryExtension ();
9731 main ()
9733 return XRenderQueryExtension ();
9735 return 0;
9737 _ACEOF
9738 if ac_fn_c_try_link "$LINENO"; then :
9739 ac_cv_lib_Xrender_XRenderQueryExtension=yes
9740 else
9741 ac_cv_lib_Xrender_XRenderQueryExtension=no
9743 rm -f core conftest.err conftest.$ac_objext \
9744 conftest$ac_exeext conftest.$ac_ext
9745 LIBS=$ac_check_lib_save_LIBS
9747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
9748 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
9749 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
9750 HAVE_XRENDER=yes
9753 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
9754 OLD_CPPFLAGS="$CPPFLAGS"
9755 OLD_CFLAGS="$CFLAGS"
9756 OLD_LIBS="$LIBS"
9757 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
9758 CFLAGS="$CFLAGS $XFT_CFLAGS"
9759 XFT_LIBS="-lXrender $XFT_LIBS"
9760 LIBS="$XFT_LIBS $LIBS"
9761 ac_fn_c_check_header_mongrel "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "$ac_includes_default"
9762 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
9763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
9764 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
9765 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
9766 $as_echo_n "(cached) " >&6
9767 else
9768 ac_check_lib_save_LIBS=$LIBS
9769 LIBS="-lXft $XFT_LIBS $LIBS"
9770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9771 /* end confdefs.h. */
9773 /* Override any GCC internal prototype to avoid an error.
9774 Use char because int might match the return type of a GCC
9775 builtin and then its argument prototype would still apply. */
9776 #ifdef __cplusplus
9777 extern "C"
9778 #endif
9779 char XftFontOpen ();
9781 main ()
9783 return XftFontOpen ();
9785 return 0;
9787 _ACEOF
9788 if ac_fn_c_try_link "$LINENO"; then :
9789 ac_cv_lib_Xft_XftFontOpen=yes
9790 else
9791 ac_cv_lib_Xft_XftFontOpen=no
9793 rm -f core conftest.err conftest.$ac_objext \
9794 conftest$ac_exeext conftest.$ac_ext
9795 LIBS=$ac_check_lib_save_LIBS
9797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
9798 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
9799 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
9800 HAVE_XFT=yes
9807 if test "${HAVE_XFT}" = "yes"; then
9809 $as_echo "#define HAVE_XFT 1" >>confdefs.h
9812 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
9813 else
9814 CPPFLAGS="$OLD_CPPFLAGS"
9815 CFLAGS="$OLD_CFLAGS"
9816 LIBS="$OLD_LIBS"
9817 fi # "${HAVE_XFT}" = "yes"
9818 fi # "$HAVE_XFT" != no
9819 fi # "x${with_xft}" != "xno"
9821 if test "$HAVE_XFT" != "yes"; then
9822 HAVE_XFT=no
9826 HAVE_FREETYPE=no
9827 ## We used to allow building with FreeType and without Xft.
9828 ## However, the ftx font backend driver is not in good shape.
9829 if test "${HAVE_XFT}" = "yes"; then
9830 HAVE_FREETYPE=yes
9831 FONTCONFIG_CFLAGS=
9832 FONTCONFIG_LIBS=
9835 HAVE_LIBOTF=no
9836 if test "${HAVE_FREETYPE}" = "yes"; then
9838 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
9840 if test "${with_libotf}" != "no"; then
9842 succeeded=no
9844 # Extract the first word of "pkg-config", so it can be a program name with args.
9845 set dummy pkg-config; ac_word=$2
9846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9847 $as_echo_n "checking for $ac_word... " >&6; }
9848 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
9849 $as_echo_n "(cached) " >&6
9850 else
9851 case $PKG_CONFIG in
9852 [\\/]* | ?:[\\/]*)
9853 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9856 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9857 for as_dir in $PATH
9859 IFS=$as_save_IFS
9860 test -z "$as_dir" && as_dir=.
9861 for ac_exec_ext in '' $ac_executable_extensions; do
9862 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9863 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9864 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9865 break 2
9867 done
9868 done
9869 IFS=$as_save_IFS
9871 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9873 esac
9875 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9876 if test -n "$PKG_CONFIG"; then
9877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
9878 $as_echo "$PKG_CONFIG" >&6; }
9879 else
9880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9881 $as_echo "no" >&6; }
9886 if test "$PKG_CONFIG" = "no" ; then
9887 HAVE_LIBOTF=no
9888 else
9889 PKG_CONFIG_MIN_VERSION=0.9.0
9890 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
9892 $as_echo_n "checking for libotf... " >&6; }
9894 if $PKG_CONFIG --exists "libotf" 2>&5; then
9895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9896 $as_echo "yes" >&6; }
9897 succeeded=yes
9899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBOTF_CFLAGS" >&5
9900 $as_echo_n "checking LIBOTF_CFLAGS... " >&6; }
9901 LIBOTF_CFLAGS=`$PKG_CONFIG --cflags "libotf"|sed -e 's,///*,/,g'`
9902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBOTF_CFLAGS" >&5
9903 $as_echo "$LIBOTF_CFLAGS" >&6; }
9905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBOTF_LIBS" >&5
9906 $as_echo_n "checking LIBOTF_LIBS... " >&6; }
9907 LIBOTF_LIBS=`$PKG_CONFIG --libs "libotf"|sed -e 's,///*,/,g'`
9908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBOTF_LIBS" >&5
9909 $as_echo "$LIBOTF_LIBS" >&6; }
9910 else
9911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9912 $as_echo "no" >&6; }
9913 LIBOTF_CFLAGS=""
9914 LIBOTF_LIBS=""
9915 ## If we have a custom action on failure, don't print errors, but
9916 ## do set a variable so people can do so.
9917 LIBOTF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libotf"`
9923 else
9924 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9925 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9929 if test $succeeded = yes; then
9930 HAVE_LIBOTF=yes
9931 else
9932 HAVE_LIBOTF=no
9935 if test "$HAVE_LIBOTF" = "yes"; then
9937 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
9939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
9940 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
9941 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
9942 $as_echo_n "(cached) " >&6
9943 else
9944 ac_check_lib_save_LIBS=$LIBS
9945 LIBS="-lotf $LIBS"
9946 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9947 /* end confdefs.h. */
9949 /* Override any GCC internal prototype to avoid an error.
9950 Use char because int might match the return type of a GCC
9951 builtin and then its argument prototype would still apply. */
9952 #ifdef __cplusplus
9953 extern "C"
9954 #endif
9955 char OTF_get_variation_glyphs ();
9957 main ()
9959 return OTF_get_variation_glyphs ();
9961 return 0;
9963 _ACEOF
9964 if ac_fn_c_try_link "$LINENO"; then :
9965 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
9966 else
9967 ac_cv_lib_otf_OTF_get_variation_glyphs=no
9969 rm -f core conftest.err conftest.$ac_objext \
9970 conftest$ac_exeext conftest.$ac_ext
9971 LIBS=$ac_check_lib_save_LIBS
9973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
9974 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
9975 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
9976 HAVE_OTF_GET_VARIATION_GLYPHS=yes
9977 else
9978 HAVE_OTF_GET_VARIATION_GLYPHS=no
9981 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
9983 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
9990 HAVE_M17N_FLT=no
9991 if test "${HAVE_LIBOTF}" = yes; then
9992 if test "${with_m17n_flt}" != "no"; then
9994 succeeded=no
9996 # Extract the first word of "pkg-config", so it can be a program name with args.
9997 set dummy pkg-config; ac_word=$2
9998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9999 $as_echo_n "checking for $ac_word... " >&6; }
10000 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
10001 $as_echo_n "(cached) " >&6
10002 else
10003 case $PKG_CONFIG in
10004 [\\/]* | ?:[\\/]*)
10005 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10008 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10009 for as_dir in $PATH
10011 IFS=$as_save_IFS
10012 test -z "$as_dir" && as_dir=.
10013 for ac_exec_ext in '' $ac_executable_extensions; do
10014 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10015 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10016 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10017 break 2
10019 done
10020 done
10021 IFS=$as_save_IFS
10023 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10025 esac
10027 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10028 if test -n "$PKG_CONFIG"; then
10029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10030 $as_echo "$PKG_CONFIG" >&6; }
10031 else
10032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10033 $as_echo "no" >&6; }
10038 if test "$PKG_CONFIG" = "no" ; then
10039 HAVE_M17N_FLT=no
10040 else
10041 PKG_CONFIG_MIN_VERSION=0.9.0
10042 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
10044 $as_echo_n "checking for m17n-flt... " >&6; }
10046 if $PKG_CONFIG --exists "m17n-flt" 2>&5; then
10047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10048 $as_echo "yes" >&6; }
10049 succeeded=yes
10051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking M17N_FLT_CFLAGS" >&5
10052 $as_echo_n "checking M17N_FLT_CFLAGS... " >&6; }
10053 M17N_FLT_CFLAGS=`$PKG_CONFIG --cflags "m17n-flt"|sed -e 's,///*,/,g'`
10054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $M17N_FLT_CFLAGS" >&5
10055 $as_echo "$M17N_FLT_CFLAGS" >&6; }
10057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking M17N_FLT_LIBS" >&5
10058 $as_echo_n "checking M17N_FLT_LIBS... " >&6; }
10059 M17N_FLT_LIBS=`$PKG_CONFIG --libs "m17n-flt"|sed -e 's,///*,/,g'`
10060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $M17N_FLT_LIBS" >&5
10061 $as_echo "$M17N_FLT_LIBS" >&6; }
10062 else
10063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10064 $as_echo "no" >&6; }
10065 M17N_FLT_CFLAGS=""
10066 M17N_FLT_LIBS=""
10067 ## If we have a custom action on failure, don't print errors, but
10068 ## do set a variable so people can do so.
10069 M17N_FLT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "m17n-flt"`
10075 else
10076 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10077 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10081 if test $succeeded = yes; then
10082 HAVE_M17N_FLT=yes
10083 else
10084 HAVE_M17N_FLT=no
10087 if test "$HAVE_M17N_FLT" = "yes"; then
10089 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
10094 else
10095 HAVE_XFT=no
10096 HAVE_FREETYPE=no
10097 HAVE_LIBOTF=no
10098 HAVE_M17N_FLT=no
10101 ### End of font-backend (under X11) section.
10112 ### Use -lXpm if available, unless `--with-xpm=no'.
10113 HAVE_XPM=no
10114 LIBXPM=
10115 if test "${HAVE_X11}" = "yes"; then
10116 if test "${with_xpm}" != "no"; then
10117 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
10118 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
10119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
10120 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
10121 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
10122 $as_echo_n "(cached) " >&6
10123 else
10124 ac_check_lib_save_LIBS=$LIBS
10125 LIBS="-lXpm -lX11 $LIBS"
10126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10127 /* end confdefs.h. */
10129 /* Override any GCC internal prototype to avoid an error.
10130 Use char because int might match the return type of a GCC
10131 builtin and then its argument prototype would still apply. */
10132 #ifdef __cplusplus
10133 extern "C"
10134 #endif
10135 char XpmReadFileToPixmap ();
10137 main ()
10139 return XpmReadFileToPixmap ();
10141 return 0;
10143 _ACEOF
10144 if ac_fn_c_try_link "$LINENO"; then :
10145 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
10146 else
10147 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
10149 rm -f core conftest.err conftest.$ac_objext \
10150 conftest$ac_exeext conftest.$ac_ext
10151 LIBS=$ac_check_lib_save_LIBS
10153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
10154 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
10155 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
10156 HAVE_XPM=yes
10162 if test "${HAVE_XPM}" = "yes"; then
10163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
10164 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
10165 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10166 /* end confdefs.h. */
10167 #include "X11/xpm.h"
10168 #ifndef XpmReturnAllocPixels
10169 no_return_alloc_pixels
10170 #endif
10172 _ACEOF
10173 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10174 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
10175 HAVE_XPM=no
10176 else
10177 HAVE_XPM=yes
10179 rm -f conftest*
10182 if test "${HAVE_XPM}" = "yes"; then
10183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10184 $as_echo "yes" >&6; }
10185 else
10186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10187 $as_echo "no" >&6; }
10192 if test "${HAVE_XPM}" = "yes"; then
10194 $as_echo "#define HAVE_XPM 1" >>confdefs.h
10196 LIBXPM=-lXpm
10201 ### Use -ljpeg if available, unless `--with-jpeg=no'.
10202 HAVE_JPEG=no
10203 LIBJPEG=
10204 if test "${HAVE_X11}" = "yes"; then
10205 if test "${with_jpeg}" != "no"; then
10206 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
10207 if test "x$ac_cv_header_jerror_h" = x""yes; then :
10208 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
10209 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
10210 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
10211 $as_echo_n "(cached) " >&6
10212 else
10213 ac_check_lib_save_LIBS=$LIBS
10214 LIBS="-ljpeg $LIBS"
10215 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10216 /* end confdefs.h. */
10218 /* Override any GCC internal prototype to avoid an error.
10219 Use char because int might match the return type of a GCC
10220 builtin and then its argument prototype would still apply. */
10221 #ifdef __cplusplus
10222 extern "C"
10223 #endif
10224 char jpeg_destroy_compress ();
10226 main ()
10228 return jpeg_destroy_compress ();
10230 return 0;
10232 _ACEOF
10233 if ac_fn_c_try_link "$LINENO"; then :
10234 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
10235 else
10236 ac_cv_lib_jpeg_jpeg_destroy_compress=no
10238 rm -f core conftest.err conftest.$ac_objext \
10239 conftest$ac_exeext conftest.$ac_ext
10240 LIBS=$ac_check_lib_save_LIBS
10242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
10243 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
10244 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
10245 HAVE_JPEG=yes
10253 if test "${HAVE_JPEG}" = "yes"; then
10254 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
10256 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10257 /* end confdefs.h. */
10258 #include <jpeglib.h>
10259 version=JPEG_LIB_VERSION
10261 _ACEOF
10262 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10263 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
10264 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
10266 else
10267 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
10268 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
10269 HAVE_JPEG=no
10271 rm -f conftest*
10274 if test "${HAVE_JPEG}" = "yes"; then
10275 LIBJPEG=-ljpeg
10280 ### Use -lpng if available, unless `--with-png=no'.
10281 HAVE_PNG=no
10282 LIBPNG=
10283 if test "${HAVE_X11}" = "yes"; then
10284 if test "${with_png}" != "no"; then
10285 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
10286 # in /usr/include/libpng.
10287 for ac_header in png.h libpng/png.h
10288 do :
10289 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10290 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
10291 eval as_val=\$$as_ac_Header
10292 if test "x$as_val" = x""yes; then :
10293 cat >>confdefs.h <<_ACEOF
10294 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10295 _ACEOF
10299 done
10301 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
10302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
10303 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
10304 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
10305 $as_echo_n "(cached) " >&6
10306 else
10307 ac_check_lib_save_LIBS=$LIBS
10308 LIBS="-lpng -lz -lm $LIBS"
10309 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10310 /* end confdefs.h. */
10312 /* Override any GCC internal prototype to avoid an error.
10313 Use char because int might match the return type of a GCC
10314 builtin and then its argument prototype would still apply. */
10315 #ifdef __cplusplus
10316 extern "C"
10317 #endif
10318 char png_get_channels ();
10320 main ()
10322 return png_get_channels ();
10324 return 0;
10326 _ACEOF
10327 if ac_fn_c_try_link "$LINENO"; then :
10328 ac_cv_lib_png_png_get_channels=yes
10329 else
10330 ac_cv_lib_png_png_get_channels=no
10332 rm -f core conftest.err conftest.$ac_objext \
10333 conftest$ac_exeext conftest.$ac_ext
10334 LIBS=$ac_check_lib_save_LIBS
10336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
10337 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
10338 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
10339 HAVE_PNG=yes
10345 if test "${HAVE_PNG}" = "yes"; then
10347 $as_echo "#define HAVE_PNG 1" >>confdefs.h
10349 LIBPNG="-lpng -lz -lm"
10354 ### Use -ltiff if available, unless `--with-tiff=no'.
10355 HAVE_TIFF=no
10356 LIBTIFF=
10357 if test "${HAVE_X11}" = "yes"; then
10358 if test "${with_tiff}" != "no"; then
10359 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
10360 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
10361 tifflibs="-lz -lm"
10362 # At least one tiff package requires the jpeg library.
10363 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
10364 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
10365 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
10366 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
10367 $as_echo_n "(cached) " >&6
10368 else
10369 ac_check_lib_save_LIBS=$LIBS
10370 LIBS="-ltiff $tifflibs $LIBS"
10371 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10372 /* end confdefs.h. */
10374 /* Override any GCC internal prototype to avoid an error.
10375 Use char because int might match the return type of a GCC
10376 builtin and then its argument prototype would still apply. */
10377 #ifdef __cplusplus
10378 extern "C"
10379 #endif
10380 char TIFFGetVersion ();
10382 main ()
10384 return TIFFGetVersion ();
10386 return 0;
10388 _ACEOF
10389 if ac_fn_c_try_link "$LINENO"; then :
10390 ac_cv_lib_tiff_TIFFGetVersion=yes
10391 else
10392 ac_cv_lib_tiff_TIFFGetVersion=no
10394 rm -f core conftest.err conftest.$ac_objext \
10395 conftest$ac_exeext conftest.$ac_ext
10396 LIBS=$ac_check_lib_save_LIBS
10398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
10399 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
10400 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
10401 HAVE_TIFF=yes
10409 if test "${HAVE_TIFF}" = "yes"; then
10411 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
10413 LIBTIFF=-ltiff
10418 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
10419 HAVE_GIF=no
10420 LIBGIF=
10421 if test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no"; then
10422 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
10423 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
10424 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
10425 # Earlier versions can crash Emacs.
10426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
10427 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
10428 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
10429 $as_echo_n "(cached) " >&6
10430 else
10431 ac_check_lib_save_LIBS=$LIBS
10432 LIBS="-lgif $LIBS"
10433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10434 /* end confdefs.h. */
10436 /* Override any GCC internal prototype to avoid an error.
10437 Use char because int might match the return type of a GCC
10438 builtin and then its argument prototype would still apply. */
10439 #ifdef __cplusplus
10440 extern "C"
10441 #endif
10442 char EGifPutExtensionLast ();
10444 main ()
10446 return EGifPutExtensionLast ();
10448 return 0;
10450 _ACEOF
10451 if ac_fn_c_try_link "$LINENO"; then :
10452 ac_cv_lib_gif_EGifPutExtensionLast=yes
10453 else
10454 ac_cv_lib_gif_EGifPutExtensionLast=no
10456 rm -f core conftest.err conftest.$ac_objext \
10457 conftest$ac_exeext conftest.$ac_ext
10458 LIBS=$ac_check_lib_save_LIBS
10460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
10461 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
10462 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
10463 HAVE_GIF=yes
10464 else
10465 HAVE_GIF=maybe
10472 if test "$HAVE_GIF" = yes; then
10473 LIBGIF=-lgif
10474 elif test "$HAVE_GIF" = maybe; then
10475 # If gif_lib.h but no libgif, try libungif.
10476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
10477 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
10478 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
10479 $as_echo_n "(cached) " >&6
10480 else
10481 ac_check_lib_save_LIBS=$LIBS
10482 LIBS="-lungif $LIBS"
10483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10484 /* end confdefs.h. */
10486 /* Override any GCC internal prototype to avoid an error.
10487 Use char because int might match the return type of a GCC
10488 builtin and then its argument prototype would still apply. */
10489 #ifdef __cplusplus
10490 extern "C"
10491 #endif
10492 char EGifPutExtensionLast ();
10494 main ()
10496 return EGifPutExtensionLast ();
10498 return 0;
10500 _ACEOF
10501 if ac_fn_c_try_link "$LINENO"; then :
10502 ac_cv_lib_ungif_EGifPutExtensionLast=yes
10503 else
10504 ac_cv_lib_ungif_EGifPutExtensionLast=no
10506 rm -f core conftest.err conftest.$ac_objext \
10507 conftest$ac_exeext conftest.$ac_ext
10508 LIBS=$ac_check_lib_save_LIBS
10510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
10511 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
10512 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
10513 HAVE_GIF=yes
10514 else
10515 HAVE_GIF=no
10518 test "$HAVE_GIF" = yes && LIBGIF=-lungif
10521 if test "${HAVE_GIF}" = "yes"; then
10523 $as_echo "#define HAVE_GIF 1" >>confdefs.h
10529 if test "${HAVE_X11}" = "yes"; then
10530 MISSING=""
10531 WITH_NO=""
10532 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
10533 MISSING="libXpm" && WITH_NO="--with-xpm=no"
10534 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
10535 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
10536 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
10537 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
10538 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
10539 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
10540 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
10541 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
10543 if test "X${MISSING}" != X; then
10544 as_fn_error "The following required libraries were not found:
10545 $MISSING
10546 Maybe some development libraries/packages are missing?
10547 If you don't want to link with them give
10548 $WITH_NO
10549 as options to configure" "$LINENO" 5
10553 ### Use -lgpm if available, unless `--with-gpm=no'.
10554 HAVE_GPM=no
10555 LIBGPM=
10556 MOUSE_SUPPORT=
10557 if test "${with_gpm}" != "no"; then
10558 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
10559 if test "x$ac_cv_header_gpm_h" = x""yes; then :
10560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
10561 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
10562 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
10563 $as_echo_n "(cached) " >&6
10564 else
10565 ac_check_lib_save_LIBS=$LIBS
10566 LIBS="-lgpm $LIBS"
10567 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10568 /* end confdefs.h. */
10570 /* Override any GCC internal prototype to avoid an error.
10571 Use char because int might match the return type of a GCC
10572 builtin and then its argument prototype would still apply. */
10573 #ifdef __cplusplus
10574 extern "C"
10575 #endif
10576 char Gpm_Open ();
10578 main ()
10580 return Gpm_Open ();
10582 return 0;
10584 _ACEOF
10585 if ac_fn_c_try_link "$LINENO"; then :
10586 ac_cv_lib_gpm_Gpm_Open=yes
10587 else
10588 ac_cv_lib_gpm_Gpm_Open=no
10590 rm -f core conftest.err conftest.$ac_objext \
10591 conftest$ac_exeext conftest.$ac_ext
10592 LIBS=$ac_check_lib_save_LIBS
10594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
10595 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
10596 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
10597 HAVE_GPM=yes
10604 if test "${HAVE_GPM}" = "yes"; then
10606 $as_echo "#define HAVE_GPM 1" >>confdefs.h
10608 LIBGPM=-lgpm
10609 ## May be reset below.
10610 MOUSE_SUPPORT="\$(GPM_MOUSE_SUPPORT)"
10615 ac_fn_c_check_header_mongrel "$LINENO" "malloc/malloc.h" "ac_cv_header_malloc_malloc_h" "$ac_includes_default"
10616 if test "x$ac_cv_header_malloc_malloc_h" = x""yes; then :
10618 $as_echo "#define HAVE_MALLOC_MALLOC_H 1" >>confdefs.h
10624 C_SWITCH_X_SYSTEM=
10625 ### Use NeXTstep API to implement GUI.
10626 if test "${HAVE_NS}" = "yes"; then
10628 $as_echo "#define HAVE_NS 1" >>confdefs.h
10630 if test "${NS_IMPL_COCOA}" = "yes"; then
10632 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
10634 GNU_OBJC_CFLAGS=
10636 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
10638 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
10640 # See also .m.o rule in Makefile.in */
10641 # FIXME: are all these flags really needed? Document here why. */
10642 C_SWITCH_X_SYSTEM="-D_REENTRANT -fPIC -fno-strict-aliasing"
10643 GNU_OBJC_CFLAGS="-fgnu-runtime -Wno-import -fconstant-string-class=NSConstantString -DGNUSTEP_BASE_LIBRARY=1 -DGNU_GUI_LIBRARY=1 -DGNU_RUNTIME=1 -DGSWARN -DGSDIAGNOSE"
10645 if test "${NS_HAVE_NSINTEGER}" = "yes"; then
10647 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
10650 # We also have mouse menus.
10651 HAVE_MENUS=yes
10652 OTHER_FILES=ns-app
10656 ### Use session management (-lSM -lICE) if available
10657 HAVE_X_SM=no
10658 LIBXSM=
10659 if test "${HAVE_X11}" = "yes"; then
10660 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
10661 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
10662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
10663 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
10664 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
10665 $as_echo_n "(cached) " >&6
10666 else
10667 ac_check_lib_save_LIBS=$LIBS
10668 LIBS="-lSM -lICE $LIBS"
10669 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10670 /* end confdefs.h. */
10672 /* Override any GCC internal prototype to avoid an error.
10673 Use char because int might match the return type of a GCC
10674 builtin and then its argument prototype would still apply. */
10675 #ifdef __cplusplus
10676 extern "C"
10677 #endif
10678 char SmcOpenConnection ();
10680 main ()
10682 return SmcOpenConnection ();
10684 return 0;
10686 _ACEOF
10687 if ac_fn_c_try_link "$LINENO"; then :
10688 ac_cv_lib_SM_SmcOpenConnection=yes
10689 else
10690 ac_cv_lib_SM_SmcOpenConnection=no
10692 rm -f core conftest.err conftest.$ac_objext \
10693 conftest$ac_exeext conftest.$ac_ext
10694 LIBS=$ac_check_lib_save_LIBS
10696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
10697 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
10698 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
10699 HAVE_X_SM=yes
10706 if test "${HAVE_X_SM}" = "yes"; then
10708 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
10710 LIBXSM="-lSM -lICE"
10711 case "$LIBS" in
10712 *-lSM*) ;;
10713 *) LIBS="$LIBXSM $LIBS" ;;
10714 esac
10719 # If netdb.h doesn't declare h_errno, we must declare it by hand.
10720 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
10721 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
10722 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
10723 $as_echo_n "(cached) " >&6
10724 else
10725 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10726 /* end confdefs.h. */
10727 #include <netdb.h>
10729 main ()
10731 return h_errno;
10733 return 0;
10735 _ACEOF
10736 if ac_fn_c_try_link "$LINENO"; then :
10737 emacs_cv_netdb_declares_h_errno=yes
10738 else
10739 emacs_cv_netdb_declares_h_errno=no
10741 rm -f core conftest.err conftest.$ac_objext \
10742 conftest$ac_exeext conftest.$ac_ext
10744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
10745 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
10746 if test $emacs_cv_netdb_declares_h_errno = yes; then
10748 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
10752 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
10753 # for constant arguments. Useless!
10754 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
10755 $as_echo_n "checking for working alloca.h... " >&6; }
10756 if test "${ac_cv_working_alloca_h+set}" = set; then :
10757 $as_echo_n "(cached) " >&6
10758 else
10759 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10760 /* end confdefs.h. */
10761 #include <alloca.h>
10763 main ()
10765 char *p = (char *) alloca (2 * sizeof (int));
10766 if (p) return 0;
10768 return 0;
10770 _ACEOF
10771 if ac_fn_c_try_link "$LINENO"; then :
10772 ac_cv_working_alloca_h=yes
10773 else
10774 ac_cv_working_alloca_h=no
10776 rm -f core conftest.err conftest.$ac_objext \
10777 conftest$ac_exeext conftest.$ac_ext
10779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
10780 $as_echo "$ac_cv_working_alloca_h" >&6; }
10781 if test $ac_cv_working_alloca_h = yes; then
10783 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
10787 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
10788 $as_echo_n "checking for alloca... " >&6; }
10789 if test "${ac_cv_func_alloca_works+set}" = set; then :
10790 $as_echo_n "(cached) " >&6
10791 else
10792 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10793 /* end confdefs.h. */
10794 #ifdef __GNUC__
10795 # define alloca __builtin_alloca
10796 #else
10797 # ifdef _MSC_VER
10798 # include <malloc.h>
10799 # define alloca _alloca
10800 # else
10801 # ifdef HAVE_ALLOCA_H
10802 # include <alloca.h>
10803 # else
10804 # ifdef _AIX
10805 #pragma alloca
10806 # else
10807 # ifndef alloca /* predefined by HP cc +Olibcalls */
10808 char *alloca ();
10809 # endif
10810 # endif
10811 # endif
10812 # endif
10813 #endif
10816 main ()
10818 char *p = (char *) alloca (1);
10819 if (p) return 0;
10821 return 0;
10823 _ACEOF
10824 if ac_fn_c_try_link "$LINENO"; then :
10825 ac_cv_func_alloca_works=yes
10826 else
10827 ac_cv_func_alloca_works=no
10829 rm -f core conftest.err conftest.$ac_objext \
10830 conftest$ac_exeext conftest.$ac_ext
10832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
10833 $as_echo "$ac_cv_func_alloca_works" >&6; }
10835 if test $ac_cv_func_alloca_works = yes; then
10837 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
10839 else
10840 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
10841 # that cause trouble. Some versions do not even contain alloca or
10842 # contain a buggy version. If you still want to use their alloca,
10843 # use ar to extract alloca.o from them instead of compiling alloca.c.
10845 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
10847 $as_echo "#define C_ALLOCA 1" >>confdefs.h
10850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
10851 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
10852 if test "${ac_cv_os_cray+set}" = set; then :
10853 $as_echo_n "(cached) " >&6
10854 else
10855 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10856 /* end confdefs.h. */
10857 #if defined CRAY && ! defined CRAY2
10858 webecray
10859 #else
10860 wenotbecray
10861 #endif
10863 _ACEOF
10864 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10865 $EGREP "webecray" >/dev/null 2>&1; then :
10866 ac_cv_os_cray=yes
10867 else
10868 ac_cv_os_cray=no
10870 rm -f conftest*
10873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
10874 $as_echo "$ac_cv_os_cray" >&6; }
10875 if test $ac_cv_os_cray = yes; then
10876 for ac_func in _getb67 GETB67 getb67; do
10877 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10878 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10879 eval as_val=\$$as_ac_var
10880 if test "x$as_val" = x""yes; then :
10882 cat >>confdefs.h <<_ACEOF
10883 #define CRAY_STACKSEG_END $ac_func
10884 _ACEOF
10886 break
10889 done
10892 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
10893 $as_echo_n "checking stack direction for C alloca... " >&6; }
10894 if test "${ac_cv_c_stack_direction+set}" = set; then :
10895 $as_echo_n "(cached) " >&6
10896 else
10897 if test "$cross_compiling" = yes; then :
10898 ac_cv_c_stack_direction=0
10899 else
10900 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10901 /* end confdefs.h. */
10902 $ac_includes_default
10904 find_stack_direction ()
10906 static char *addr = 0;
10907 auto char dummy;
10908 if (addr == 0)
10910 addr = &dummy;
10911 return find_stack_direction ();
10913 else
10914 return (&dummy > addr) ? 1 : -1;
10918 main ()
10920 return find_stack_direction () < 0;
10922 _ACEOF
10923 if ac_fn_c_try_run "$LINENO"; then :
10924 ac_cv_c_stack_direction=1
10925 else
10926 ac_cv_c_stack_direction=-1
10928 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10929 conftest.$ac_objext conftest.beam conftest.$ac_ext
10933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
10934 $as_echo "$ac_cv_c_stack_direction" >&6; }
10935 cat >>confdefs.h <<_ACEOF
10936 #define STACK_DIRECTION $ac_cv_c_stack_direction
10937 _ACEOF
10943 if test x"$ac_cv_func_alloca_works" != xyes; then
10944 as_fn_error "a system implementation of alloca is required " "$LINENO" 5
10947 # fmod, logb, and frexp are found in -lm on most systems.
10948 # On HPUX 9.01, -lm does not contain logb, so check for sqrt.
10949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
10950 $as_echo_n "checking for sqrt in -lm... " >&6; }
10951 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
10952 $as_echo_n "(cached) " >&6
10953 else
10954 ac_check_lib_save_LIBS=$LIBS
10955 LIBS="-lm $LIBS"
10956 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10957 /* end confdefs.h. */
10959 /* Override any GCC internal prototype to avoid an error.
10960 Use char because int might match the return type of a GCC
10961 builtin and then its argument prototype would still apply. */
10962 #ifdef __cplusplus
10963 extern "C"
10964 #endif
10965 char sqrt ();
10967 main ()
10969 return sqrt ();
10971 return 0;
10973 _ACEOF
10974 if ac_fn_c_try_link "$LINENO"; then :
10975 ac_cv_lib_m_sqrt=yes
10976 else
10977 ac_cv_lib_m_sqrt=no
10979 rm -f core conftest.err conftest.$ac_objext \
10980 conftest$ac_exeext conftest.$ac_ext
10981 LIBS=$ac_check_lib_save_LIBS
10983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
10984 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
10985 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
10986 cat >>confdefs.h <<_ACEOF
10987 #define HAVE_LIBM 1
10988 _ACEOF
10990 LIBS="-lm $LIBS"
10995 # Check for mail-locking functions in a "mail" library. Probably this should
10996 # have the same check as for liblockfile below.
10997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
10998 $as_echo_n "checking for maillock in -lmail... " >&6; }
10999 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
11000 $as_echo_n "(cached) " >&6
11001 else
11002 ac_check_lib_save_LIBS=$LIBS
11003 LIBS="-lmail $LIBS"
11004 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11005 /* end confdefs.h. */
11007 /* Override any GCC internal prototype to avoid an error.
11008 Use char because int might match the return type of a GCC
11009 builtin and then its argument prototype would still apply. */
11010 #ifdef __cplusplus
11011 extern "C"
11012 #endif
11013 char maillock ();
11015 main ()
11017 return maillock ();
11019 return 0;
11021 _ACEOF
11022 if ac_fn_c_try_link "$LINENO"; then :
11023 ac_cv_lib_mail_maillock=yes
11024 else
11025 ac_cv_lib_mail_maillock=no
11027 rm -f core conftest.err conftest.$ac_objext \
11028 conftest$ac_exeext conftest.$ac_ext
11029 LIBS=$ac_check_lib_save_LIBS
11031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
11032 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
11033 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
11034 have_mail=yes
11035 else
11036 have_mail=no
11039 if test $have_mail = yes; then
11040 LIBS_MAIL=-lmail
11041 LIBS="$LIBS_MAIL $LIBS"
11043 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
11045 else
11046 LIBS_MAIL=
11048 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
11049 $as_echo_n "checking for maillock in -llockfile... " >&6; }
11050 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
11051 $as_echo_n "(cached) " >&6
11052 else
11053 ac_check_lib_save_LIBS=$LIBS
11054 LIBS="-llockfile $LIBS"
11055 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11056 /* end confdefs.h. */
11058 /* Override any GCC internal prototype to avoid an error.
11059 Use char because int might match the return type of a GCC
11060 builtin and then its argument prototype would still apply. */
11061 #ifdef __cplusplus
11062 extern "C"
11063 #endif
11064 char maillock ();
11066 main ()
11068 return maillock ();
11070 return 0;
11072 _ACEOF
11073 if ac_fn_c_try_link "$LINENO"; then :
11074 ac_cv_lib_lockfile_maillock=yes
11075 else
11076 ac_cv_lib_lockfile_maillock=no
11078 rm -f core conftest.err conftest.$ac_objext \
11079 conftest$ac_exeext conftest.$ac_ext
11080 LIBS=$ac_check_lib_save_LIBS
11082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
11083 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
11084 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
11085 have_lockfile=yes
11086 else
11087 have_lockfile=no
11090 if test $have_lockfile = yes; then
11091 LIBS_MAIL=-llockfile
11092 LIBS="$LIBS_MAIL $LIBS"
11094 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
11096 else
11097 # If we have the shared liblockfile, assume we must use it for mail
11098 # locking (e.g. Debian). If we couldn't link against liblockfile
11099 # (no liblockfile.a installed), ensure that we don't need to.
11100 # Extract the first word of "liblockfile.so", so it can be a program name with args.
11101 set dummy liblockfile.so; ac_word=$2
11102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11103 $as_echo_n "checking for $ac_word... " >&6; }
11104 if test "${ac_cv_prog_liblockfile+set}" = set; then :
11105 $as_echo_n "(cached) " >&6
11106 else
11107 if test -n "$liblockfile"; then
11108 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
11109 else
11110 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11111 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
11112 for as_dir in $as_dummy
11114 IFS=$as_save_IFS
11115 test -z "$as_dir" && as_dir=.
11116 for ac_exec_ext in '' $ac_executable_extensions; do
11117 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11118 ac_cv_prog_liblockfile="yes"
11119 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11120 break 2
11122 done
11123 done
11124 IFS=$as_save_IFS
11126 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
11129 liblockfile=$ac_cv_prog_liblockfile
11130 if test -n "$liblockfile"; then
11131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
11132 $as_echo "$liblockfile" >&6; }
11133 else
11134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11135 $as_echo "no" >&6; }
11139 if test $ac_cv_prog_liblockfile = yes; then
11140 as_fn_error "Shared liblockfile found but can't link against it.
11141 This probably means that movemail could lose mail.
11142 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
11145 for ac_func in touchlock
11146 do :
11147 ac_fn_c_check_func "$LINENO" "touchlock" "ac_cv_func_touchlock"
11148 if test "x$ac_cv_func_touchlock" = x""yes; then :
11149 cat >>confdefs.h <<_ACEOF
11150 #define HAVE_TOUCHLOCK 1
11151 _ACEOF
11154 done
11156 for ac_header in maillock.h
11157 do :
11158 ac_fn_c_check_header_mongrel "$LINENO" "maillock.h" "ac_cv_header_maillock_h" "$ac_includes_default"
11159 if test "x$ac_cv_header_maillock_h" = x""yes; then :
11160 cat >>confdefs.h <<_ACEOF
11161 #define HAVE_MAILLOCK_H 1
11162 _ACEOF
11166 done
11170 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
11171 ## interlock access to the mail spool. The alternative is a lock file named
11172 ## /usr/spool/mail/$USER.lock.
11173 mail_lock=no
11174 case "$opsys" in
11175 aix4-2) mail_lock="lockf" ;;
11177 gnu|freebsd|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
11179 ## On GNU/Linux systems, both methods are used by various mail programs.
11180 ## I assume most people are using newer mailers that have heard of flock.
11181 ## Change this if you need to.
11182 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
11183 ## configure gets the right answers, and that means *NOT* using flock.
11184 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
11185 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
11186 ## Debian maintainer hasn't provided a clean fix for Emacs.
11187 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
11188 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
11189 ## correct logic. -- fx
11190 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
11191 ## liblockfile is a Free Software replacement for libmail, used on
11192 ## Debian systems and elsewhere. -rfr.
11193 gnu-*)
11194 mail_lock="flock"
11195 if test $have_mail = yes || test $have_lockfile = yes; then
11196 test $ac_cv_header_maillock_h = yes && mail_lock=no
11199 esac
11201 BLESSMAIL_TARGET=
11202 case "$mail_lock" in
11203 flock)
11204 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
11207 lockf)
11208 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
11211 *) BLESSMAIL_TARGET="need-blessmail" ;;
11212 esac
11216 for ac_func in gethostname getdomainname dup2 \
11217 rename closedir mkdir rmdir sysinfo getrusage get_current_dir_name \
11218 random lrand48 logb frexp fmod rint cbrt ftime setsid \
11219 strerror fpathconf select mktime euidaccess getpagesize tzset setlocale \
11220 utimes getrlimit setrlimit setpgid getcwd getwd shutdown getaddrinfo \
11221 __fpending mblen mbrlen mbsinit strsignal setitimer ualarm strchr strrchr \
11222 sendto recvfrom getsockopt setsockopt getsockname getpeername \
11223 gai_strerror mkstemp getline getdelim mremap memmove fsync sync \
11224 memset memcmp difftime memcpy mempcpy mblen mbrlen posix_memalign \
11225 cfmakeraw cfsetspeed isnan copysign __executable_start
11226 do :
11227 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11228 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11229 eval as_val=\$$as_ac_var
11230 if test "x$as_val" = x""yes; then :
11231 cat >>confdefs.h <<_ACEOF
11232 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11233 _ACEOF
11236 done
11239 for ac_header in sys/un.h
11240 do :
11241 ac_fn_c_check_header_mongrel "$LINENO" "sys/un.h" "ac_cv_header_sys_un_h" "$ac_includes_default"
11242 if test "x$ac_cv_header_sys_un_h" = x""yes; then :
11243 cat >>confdefs.h <<_ACEOF
11244 #define HAVE_SYS_UN_H 1
11245 _ACEOF
11249 done
11257 for ac_func in $ac_func_list
11258 do :
11259 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11260 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11261 eval as_val=\$$as_ac_var
11262 if test "x$as_val" = x""yes; then :
11263 cat >>confdefs.h <<_ACEOF
11264 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11265 _ACEOF
11268 done
11274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
11275 $as_echo_n "checking for working mktime... " >&6; }
11276 if test "${ac_cv_func_working_mktime+set}" = set; then :
11277 $as_echo_n "(cached) " >&6
11278 else
11279 if test "$cross_compiling" = yes; then :
11280 ac_cv_func_working_mktime=no
11281 else
11282 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11283 /* end confdefs.h. */
11284 /* Test program from Paul Eggert and Tony Leneis. */
11285 #ifdef TIME_WITH_SYS_TIME
11286 # include <sys/time.h>
11287 # include <time.h>
11288 #else
11289 # ifdef HAVE_SYS_TIME_H
11290 # include <sys/time.h>
11291 # else
11292 # include <time.h>
11293 # endif
11294 #endif
11296 #include <limits.h>
11297 #include <stdlib.h>
11299 #ifdef HAVE_UNISTD_H
11300 # include <unistd.h>
11301 #endif
11303 #ifndef HAVE_ALARM
11304 # define alarm(X) /* empty */
11305 #endif
11307 /* Work around redefinition to rpl_putenv by other config tests. */
11308 #undef putenv
11310 static time_t time_t_max;
11311 static time_t time_t_min;
11313 /* Values we'll use to set the TZ environment variable. */
11314 static char *tz_strings[] = {
11315 (char *) 0, "TZ=GMT0", "TZ=JST-9",
11316 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
11318 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
11320 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
11321 Based on a problem report from Andreas Jaeger. */
11322 static int
11323 spring_forward_gap ()
11325 /* glibc (up to about 1998-10-07) failed this test. */
11326 struct tm tm;
11328 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
11329 instead of "TZ=America/Vancouver" in order to detect the bug even
11330 on systems that don't support the Olson extension, or don't have the
11331 full zoneinfo tables installed. */
11332 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
11334 tm.tm_year = 98;
11335 tm.tm_mon = 3;
11336 tm.tm_mday = 5;
11337 tm.tm_hour = 2;
11338 tm.tm_min = 0;
11339 tm.tm_sec = 0;
11340 tm.tm_isdst = -1;
11341 return mktime (&tm) != (time_t) -1;
11344 static int
11345 mktime_test1 (now)
11346 time_t now;
11348 struct tm *lt;
11349 return ! (lt = localtime (&now)) || mktime (lt) == now;
11352 static int
11353 mktime_test (now)
11354 time_t now;
11356 return (mktime_test1 (now)
11357 && mktime_test1 ((time_t) (time_t_max - now))
11358 && mktime_test1 ((time_t) (time_t_min + now)));
11361 static int
11362 irix_6_4_bug ()
11364 /* Based on code from Ariel Faigon. */
11365 struct tm tm;
11366 tm.tm_year = 96;
11367 tm.tm_mon = 3;
11368 tm.tm_mday = 0;
11369 tm.tm_hour = 0;
11370 tm.tm_min = 0;
11371 tm.tm_sec = 0;
11372 tm.tm_isdst = -1;
11373 mktime (&tm);
11374 return tm.tm_mon == 2 && tm.tm_mday == 31;
11377 static int
11378 bigtime_test (j)
11379 int j;
11381 struct tm tm;
11382 time_t now;
11383 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
11384 now = mktime (&tm);
11385 if (now != (time_t) -1)
11387 struct tm *lt = localtime (&now);
11388 if (! (lt
11389 && lt->tm_year == tm.tm_year
11390 && lt->tm_mon == tm.tm_mon
11391 && lt->tm_mday == tm.tm_mday
11392 && lt->tm_hour == tm.tm_hour
11393 && lt->tm_min == tm.tm_min
11394 && lt->tm_sec == tm.tm_sec
11395 && lt->tm_yday == tm.tm_yday
11396 && lt->tm_wday == tm.tm_wday
11397 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
11398 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
11399 return 0;
11401 return 1;
11404 static int
11405 year_2050_test ()
11407 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
11408 ignoring leap seconds. */
11409 unsigned long int answer = 2527315200UL;
11411 struct tm tm;
11412 time_t t;
11413 tm.tm_year = 2050 - 1900;
11414 tm.tm_mon = 2 - 1;
11415 tm.tm_mday = 1;
11416 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
11417 tm.tm_isdst = -1;
11419 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
11420 instead of "TZ=America/Vancouver" in order to detect the bug even
11421 on systems that don't support the Olson extension, or don't have the
11422 full zoneinfo tables installed. */
11423 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
11425 t = mktime (&tm);
11427 /* Check that the result is either a failure, or close enough
11428 to the correct answer that we can assume the discrepancy is
11429 due to leap seconds. */
11430 return (t == (time_t) -1
11431 || (0 < t && answer - 120 <= t && t <= answer + 120));
11435 main ()
11437 time_t t, delta;
11438 int i, j;
11440 /* This test makes some buggy mktime implementations loop.
11441 Give up after 60 seconds; a mktime slower than that
11442 isn't worth using anyway. */
11443 alarm (60);
11445 for (;;)
11447 t = (time_t_max << 1) + 1;
11448 if (t <= time_t_max)
11449 break;
11450 time_t_max = t;
11452 time_t_min = - ((time_t) ~ (time_t) 0 == (time_t) -1) - time_t_max;
11454 delta = time_t_max / 997; /* a suitable prime number */
11455 for (i = 0; i < N_STRINGS; i++)
11457 if (tz_strings[i])
11458 putenv (tz_strings[i]);
11460 for (t = 0; t <= time_t_max - delta; t += delta)
11461 if (! mktime_test (t))
11462 return 1;
11463 if (! (mktime_test ((time_t) 1)
11464 && mktime_test ((time_t) (60 * 60))
11465 && mktime_test ((time_t) (60 * 60 * 24))))
11466 return 1;
11468 for (j = 1; ; j <<= 1)
11469 if (! bigtime_test (j))
11470 return 1;
11471 else if (INT_MAX / 2 < j)
11472 break;
11473 if (! bigtime_test (INT_MAX))
11474 return 1;
11476 return ! (irix_6_4_bug () && spring_forward_gap () && year_2050_test ());
11478 _ACEOF
11479 if ac_fn_c_try_run "$LINENO"; then :
11480 ac_cv_func_working_mktime=yes
11481 else
11482 ac_cv_func_working_mktime=no
11484 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11485 conftest.$ac_objext conftest.beam conftest.$ac_ext
11489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_working_mktime" >&5
11490 $as_echo "$ac_cv_func_working_mktime" >&6; }
11491 if test $ac_cv_func_working_mktime = no; then
11492 case " $LIBOBJS " in
11493 *" mktime.$ac_objext "* ) ;;
11494 *) LIBOBJS="$LIBOBJS mktime.$ac_objext"
11496 esac
11500 if test "$ac_cv_func_working_mktime" = no; then
11502 $as_echo "#define BROKEN_MKTIME 1" >>confdefs.h
11506 ac_have_func=no # yes means we've found a way to get the load average.
11508 # Make sure getloadavg.c is where it belongs, at configure-time.
11509 test -f "$srcdir/$ac_config_libobj_dir/getloadavg.c" ||
11510 as_fn_error "$srcdir/$ac_config_libobj_dir/getloadavg.c is missing" "$LINENO" 5
11512 ac_save_LIBS=$LIBS
11514 # Check for getloadavg, but be sure not to touch the cache variable.
11515 (ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
11516 if test "x$ac_cv_func_getloadavg" = x""yes; then :
11517 exit 0
11518 else
11519 exit 1
11521 ) && ac_have_func=yes
11523 # On HPUX9, an unprivileged user can get load averages through this function.
11524 for ac_func in pstat_getdynamic
11525 do :
11526 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
11527 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
11528 cat >>confdefs.h <<_ACEOF
11529 #define HAVE_PSTAT_GETDYNAMIC 1
11530 _ACEOF
11533 done
11536 # Solaris has libkstat which does not require root.
11537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
11538 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
11539 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
11540 $as_echo_n "(cached) " >&6
11541 else
11542 ac_check_lib_save_LIBS=$LIBS
11543 LIBS="-lkstat $LIBS"
11544 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11545 /* end confdefs.h. */
11547 /* Override any GCC internal prototype to avoid an error.
11548 Use char because int might match the return type of a GCC
11549 builtin and then its argument prototype would still apply. */
11550 #ifdef __cplusplus
11551 extern "C"
11552 #endif
11553 char kstat_open ();
11555 main ()
11557 return kstat_open ();
11559 return 0;
11561 _ACEOF
11562 if ac_fn_c_try_link "$LINENO"; then :
11563 ac_cv_lib_kstat_kstat_open=yes
11564 else
11565 ac_cv_lib_kstat_kstat_open=no
11567 rm -f core conftest.err conftest.$ac_objext \
11568 conftest$ac_exeext conftest.$ac_ext
11569 LIBS=$ac_check_lib_save_LIBS
11571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
11572 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
11573 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
11574 cat >>confdefs.h <<_ACEOF
11575 #define HAVE_LIBKSTAT 1
11576 _ACEOF
11578 LIBS="-lkstat $LIBS"
11582 test $ac_cv_lib_kstat_kstat_open = yes && ac_have_func=yes
11584 # Some systems with -lutil have (and need) -lkvm as well, some do not.
11585 # On Solaris, -lkvm requires nlist from -lelf, so check that first
11586 # to get the right answer into the cache.
11587 # For kstat on solaris, we need libelf to force the definition of SVR4 below.
11588 if test $ac_have_func = no; then
11589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
11590 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
11591 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
11592 $as_echo_n "(cached) " >&6
11593 else
11594 ac_check_lib_save_LIBS=$LIBS
11595 LIBS="-lelf $LIBS"
11596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11597 /* end confdefs.h. */
11599 /* Override any GCC internal prototype to avoid an error.
11600 Use char because int might match the return type of a GCC
11601 builtin and then its argument prototype would still apply. */
11602 #ifdef __cplusplus
11603 extern "C"
11604 #endif
11605 char elf_begin ();
11607 main ()
11609 return elf_begin ();
11611 return 0;
11613 _ACEOF
11614 if ac_fn_c_try_link "$LINENO"; then :
11615 ac_cv_lib_elf_elf_begin=yes
11616 else
11617 ac_cv_lib_elf_elf_begin=no
11619 rm -f core conftest.err conftest.$ac_objext \
11620 conftest$ac_exeext conftest.$ac_ext
11621 LIBS=$ac_check_lib_save_LIBS
11623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
11624 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
11625 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
11626 LIBS="-lelf $LIBS"
11630 if test $ac_have_func = no; then
11631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
11632 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
11633 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
11634 $as_echo_n "(cached) " >&6
11635 else
11636 ac_check_lib_save_LIBS=$LIBS
11637 LIBS="-lkvm $LIBS"
11638 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11639 /* end confdefs.h. */
11641 /* Override any GCC internal prototype to avoid an error.
11642 Use char because int might match the return type of a GCC
11643 builtin and then its argument prototype would still apply. */
11644 #ifdef __cplusplus
11645 extern "C"
11646 #endif
11647 char kvm_open ();
11649 main ()
11651 return kvm_open ();
11653 return 0;
11655 _ACEOF
11656 if ac_fn_c_try_link "$LINENO"; then :
11657 ac_cv_lib_kvm_kvm_open=yes
11658 else
11659 ac_cv_lib_kvm_kvm_open=no
11661 rm -f core conftest.err conftest.$ac_objext \
11662 conftest$ac_exeext conftest.$ac_ext
11663 LIBS=$ac_check_lib_save_LIBS
11665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
11666 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
11667 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
11668 LIBS="-lkvm $LIBS"
11671 # Check for the 4.4BSD definition of getloadavg.
11672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
11673 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
11674 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
11675 $as_echo_n "(cached) " >&6
11676 else
11677 ac_check_lib_save_LIBS=$LIBS
11678 LIBS="-lutil $LIBS"
11679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11680 /* end confdefs.h. */
11682 /* Override any GCC internal prototype to avoid an error.
11683 Use char because int might match the return type of a GCC
11684 builtin and then its argument prototype would still apply. */
11685 #ifdef __cplusplus
11686 extern "C"
11687 #endif
11688 char getloadavg ();
11690 main ()
11692 return getloadavg ();
11694 return 0;
11696 _ACEOF
11697 if ac_fn_c_try_link "$LINENO"; then :
11698 ac_cv_lib_util_getloadavg=yes
11699 else
11700 ac_cv_lib_util_getloadavg=no
11702 rm -f core conftest.err conftest.$ac_objext \
11703 conftest$ac_exeext conftest.$ac_ext
11704 LIBS=$ac_check_lib_save_LIBS
11706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
11707 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
11708 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
11709 LIBS="-lutil $LIBS" ac_have_func=yes ac_cv_func_getloadavg_setgid=yes
11714 if test $ac_have_func = no; then
11715 # There is a commonly available library for RS/6000 AIX.
11716 # Since it is not a standard part of AIX, it might be installed locally.
11717 ac_getloadavg_LIBS=$LIBS
11718 LIBS="-L/usr/local/lib $LIBS"
11719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
11720 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
11721 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
11722 $as_echo_n "(cached) " >&6
11723 else
11724 ac_check_lib_save_LIBS=$LIBS
11725 LIBS="-lgetloadavg $LIBS"
11726 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11727 /* end confdefs.h. */
11729 /* Override any GCC internal prototype to avoid an error.
11730 Use char because int might match the return type of a GCC
11731 builtin and then its argument prototype would still apply. */
11732 #ifdef __cplusplus
11733 extern "C"
11734 #endif
11735 char getloadavg ();
11737 main ()
11739 return getloadavg ();
11741 return 0;
11743 _ACEOF
11744 if ac_fn_c_try_link "$LINENO"; then :
11745 ac_cv_lib_getloadavg_getloadavg=yes
11746 else
11747 ac_cv_lib_getloadavg_getloadavg=no
11749 rm -f core conftest.err conftest.$ac_objext \
11750 conftest$ac_exeext conftest.$ac_ext
11751 LIBS=$ac_check_lib_save_LIBS
11753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
11754 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
11755 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
11756 LIBS="-lgetloadavg $LIBS"
11757 else
11758 LIBS=$ac_getloadavg_LIBS
11763 # Make sure it is really in the library, if we think we found it,
11764 # otherwise set up the replacement function.
11765 for ac_func in getloadavg
11766 do :
11767 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
11768 if test "x$ac_cv_func_getloadavg" = x""yes; then :
11769 cat >>confdefs.h <<_ACEOF
11770 #define HAVE_GETLOADAVG 1
11771 _ACEOF
11773 else
11774 case " $LIBOBJS " in
11775 *" getloadavg.$ac_objext "* ) ;;
11776 *) LIBOBJS="$LIBOBJS getloadavg.$ac_objext"
11778 esac
11781 $as_echo "#define C_GETLOADAVG 1" >>confdefs.h
11783 # Figure out what our getloadavg.c needs.
11784 ac_have_func=no
11785 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
11786 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
11787 ac_have_func=yes
11789 $as_echo "#define DGUX 1" >>confdefs.h
11791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
11792 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
11793 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
11794 $as_echo_n "(cached) " >&6
11795 else
11796 ac_check_lib_save_LIBS=$LIBS
11797 LIBS="-ldgc $LIBS"
11798 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11799 /* end confdefs.h. */
11801 /* Override any GCC internal prototype to avoid an error.
11802 Use char because int might match the return type of a GCC
11803 builtin and then its argument prototype would still apply. */
11804 #ifdef __cplusplus
11805 extern "C"
11806 #endif
11807 char dg_sys_info ();
11809 main ()
11811 return dg_sys_info ();
11813 return 0;
11815 _ACEOF
11816 if ac_fn_c_try_link "$LINENO"; then :
11817 ac_cv_lib_dgc_dg_sys_info=yes
11818 else
11819 ac_cv_lib_dgc_dg_sys_info=no
11821 rm -f core conftest.err conftest.$ac_objext \
11822 conftest$ac_exeext conftest.$ac_ext
11823 LIBS=$ac_check_lib_save_LIBS
11825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
11826 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
11827 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
11828 cat >>confdefs.h <<_ACEOF
11829 #define HAVE_LIBDGC 1
11830 _ACEOF
11832 LIBS="-ldgc $LIBS"
11840 ac_fn_c_check_header_mongrel "$LINENO" "locale.h" "ac_cv_header_locale_h" "$ac_includes_default"
11841 if test "x$ac_cv_header_locale_h" = x""yes; then :
11846 for ac_func in setlocale
11847 do :
11848 ac_fn_c_check_func "$LINENO" "setlocale" "ac_cv_func_setlocale"
11849 if test "x$ac_cv_func_setlocale" = x""yes; then :
11850 cat >>confdefs.h <<_ACEOF
11851 #define HAVE_SETLOCALE 1
11852 _ACEOF
11855 done
11858 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
11859 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
11860 # Irix 4.0.5F has the header but not the library.
11861 if test $ac_have_func = no && test "$ac_cv_lib_elf_elf_begin" = yes; then
11862 ac_have_func=yes
11864 $as_echo "#define SVR4 1" >>confdefs.h
11868 if test $ac_have_func = no; then
11869 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
11870 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
11871 ac_have_func=yes
11873 $as_echo "#define UMAX 1" >>confdefs.h
11876 $as_echo "#define UMAX4_3 1" >>confdefs.h
11883 if test $ac_have_func = no; then
11884 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
11885 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
11886 ac_have_func=yes; $as_echo "#define UMAX 1" >>confdefs.h
11893 if test $ac_have_func = no; then
11894 for ac_header in mach/mach.h
11895 do :
11896 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
11897 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
11898 cat >>confdefs.h <<_ACEOF
11899 #define HAVE_MACH_MACH_H 1
11900 _ACEOF
11904 done
11908 for ac_header in nlist.h
11909 do :
11910 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
11911 if test "x$ac_cv_header_nlist_h" = x""yes; then :
11912 cat >>confdefs.h <<_ACEOF
11913 #define HAVE_NLIST_H 1
11914 _ACEOF
11915 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
11917 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
11919 cat >>confdefs.h <<_ACEOF
11920 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
11921 _ACEOF
11924 $as_echo "#define NLIST_NAME_UNION 1" >>confdefs.h
11931 done
11934 done
11937 # Some definitions of getloadavg require that the program be installed setgid.
11938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getloadavg requires setgid" >&5
11939 $as_echo_n "checking whether getloadavg requires setgid... " >&6; }
11940 if test "${ac_cv_func_getloadavg_setgid+set}" = set; then :
11941 $as_echo_n "(cached) " >&6
11942 else
11943 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11944 /* end confdefs.h. */
11945 #include "$srcdir/$ac_config_libobj_dir/getloadavg.c"
11946 #ifdef LDAV_PRIVILEGED
11947 Yowza Am I SETGID yet
11948 #endif
11949 _ACEOF
11950 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11951 $EGREP "Yowza Am I SETGID yet" >/dev/null 2>&1; then :
11952 ac_cv_func_getloadavg_setgid=yes
11953 else
11954 ac_cv_func_getloadavg_setgid=no
11956 rm -f conftest*
11959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getloadavg_setgid" >&5
11960 $as_echo "$ac_cv_func_getloadavg_setgid" >&6; }
11961 if test $ac_cv_func_getloadavg_setgid = yes; then
11962 NEED_SETGID=true
11964 $as_echo "#define GETLOADAVG_PRIVILEGED 1" >>confdefs.h
11966 else
11967 NEED_SETGID=false
11970 if test $ac_cv_func_getloadavg_setgid = yes; then
11971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking group of /dev/kmem" >&5
11972 $as_echo_n "checking group of /dev/kmem... " >&6; }
11973 if test "${ac_cv_group_kmem+set}" = set; then :
11974 $as_echo_n "(cached) " >&6
11975 else
11976 # On Solaris, /dev/kmem is a symlink. Get info on the real file.
11977 ac_ls_output=`ls -lgL /dev/kmem 2>/dev/null`
11978 # If we got an error (system does not support symlinks), try without -L.
11979 test -z "$ac_ls_output" && ac_ls_output=`ls -lg /dev/kmem`
11980 ac_cv_group_kmem=`$as_echo "$ac_ls_output" \
11981 | sed -ne 's/[ ][ ]*/ /g;
11982 s/^.[sSrwx-]* *[0-9]* *\([^0-9]*\) *.*/\1/;
11983 / /s/.* //;p;'`
11986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_group_kmem" >&5
11987 $as_echo "$ac_cv_group_kmem" >&6; }
11988 KMEM_GROUP=$ac_cv_group_kmem
11990 if test "x$ac_save_LIBS" = x; then
11991 GETLOADAVG_LIBS=$LIBS
11992 else
11993 GETLOADAVG_LIBS=`$as_echo "$LIBS" | sed "s|$ac_save_LIBS||"`
11995 LIBS=$ac_save_LIBS
11999 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
12000 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
12001 if test "${ac_cv_sys_largefile_source+set}" = set; then :
12002 $as_echo_n "(cached) " >&6
12003 else
12004 while :; do
12005 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12006 /* end confdefs.h. */
12007 #include <sys/types.h> /* for off_t */
12008 #include <stdio.h>
12010 main ()
12012 int (*fp) (FILE *, off_t, int) = fseeko;
12013 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
12015 return 0;
12017 _ACEOF
12018 if ac_fn_c_try_link "$LINENO"; then :
12019 ac_cv_sys_largefile_source=no; break
12021 rm -f core conftest.err conftest.$ac_objext \
12022 conftest$ac_exeext conftest.$ac_ext
12023 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12024 /* end confdefs.h. */
12025 #define _LARGEFILE_SOURCE 1
12026 #include <sys/types.h> /* for off_t */
12027 #include <stdio.h>
12029 main ()
12031 int (*fp) (FILE *, off_t, int) = fseeko;
12032 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
12034 return 0;
12036 _ACEOF
12037 if ac_fn_c_try_link "$LINENO"; then :
12038 ac_cv_sys_largefile_source=1; break
12040 rm -f core conftest.err conftest.$ac_objext \
12041 conftest$ac_exeext conftest.$ac_ext
12042 ac_cv_sys_largefile_source=unknown
12043 break
12044 done
12046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
12047 $as_echo "$ac_cv_sys_largefile_source" >&6; }
12048 case $ac_cv_sys_largefile_source in #(
12049 no | unknown) ;;
12051 cat >>confdefs.h <<_ACEOF
12052 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
12053 _ACEOF
12055 esac
12056 rm -rf conftest*
12058 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
12059 # in glibc 2.1.3, but that breaks too many other things.
12060 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
12061 if test $ac_cv_sys_largefile_source != unknown; then
12063 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
12068 # Configure getopt.
12069 # getopt.m4 serial 10
12071 # The getopt module assume you want GNU getopt, with getopt_long etc,
12072 # rather than vanilla POSIX getopt. This means your your code should
12073 # always include <getopt.h> for the getopt prototypes.
12085 # Prerequisites of lib/getopt*.
12090 GETOPT_H=
12091 for ac_header in getopt.h
12092 do :
12093 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
12094 if test "x$ac_cv_header_getopt_h" = x""yes; then :
12095 cat >>confdefs.h <<_ACEOF
12096 #define HAVE_GETOPT_H 1
12097 _ACEOF
12099 else
12100 GETOPT_H=getopt.h
12103 done
12105 if test -z "$GETOPT_H"; then
12106 for ac_func in getopt_long_only
12107 do :
12108 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
12109 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
12110 cat >>confdefs.h <<_ACEOF
12111 #define HAVE_GETOPT_LONG_ONLY 1
12112 _ACEOF
12114 else
12115 GETOPT_H=getopt.h
12117 done
12121 if test -z "$GETOPT_H"; then
12122 ac_fn_c_check_decl "$LINENO" "optreset" "ac_cv_have_decl_optreset" "#include <getopt.h>
12124 if test "x$ac_cv_have_decl_optreset" = x""yes; then :
12125 GETOPT_H=getopt.h
12130 if test -z "$GETOPT_H"; then
12131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
12132 $as_echo_n "checking for working GNU getopt function... " >&6; }
12133 if test "${gl_cv_func_gnu_getopt+set}" = set; then :
12134 $as_echo_n "(cached) " >&6
12135 else
12136 if test "$cross_compiling" = yes; then :
12137 ac_fn_c_check_decl "$LINENO" "getopt_clip" "ac_cv_have_decl_getopt_clip" "#include <getopt.h>
12139 if test "x$ac_cv_have_decl_getopt_clip" = x""yes; then :
12140 gl_cv_func_gnu_getopt=no
12141 else
12142 gl_cv_func_gnu_getopt=yes
12145 else
12146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12147 /* end confdefs.h. */
12148 #include <getopt.h>
12150 main ()
12153 char *myargv[3];
12154 myargv[0] = "conftest";
12155 myargv[1] = "-+";
12156 myargv[2] = 0;
12157 return getopt (2, myargv, "+a") != '?';
12160 return 0;
12162 _ACEOF
12163 if ac_fn_c_try_run "$LINENO"; then :
12164 gl_cv_func_gnu_getopt=yes
12165 else
12166 gl_cv_func_gnu_getopt=no
12168 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12169 conftest.$ac_objext conftest.beam conftest.$ac_ext
12173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gnu_getopt" >&5
12174 $as_echo "$gl_cv_func_gnu_getopt" >&6; }
12175 if test "$gl_cv_func_gnu_getopt" = "no"; then
12176 GETOPT_H=getopt.h
12182 if test -n "$GETOPT_H"; then :
12185 GETOPT_H=getopt.h
12187 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
12192 GETOPTOBJS='getopt.o getopt1.o'
12198 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5
12199 $as_echo_n "checking whether getpgrp requires zero arguments... " >&6; }
12200 if test "${ac_cv_func_getpgrp_void+set}" = set; then :
12201 $as_echo_n "(cached) " >&6
12202 else
12203 # Use it with a single arg.
12204 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12205 /* end confdefs.h. */
12206 $ac_includes_default
12208 main ()
12210 getpgrp (0);
12212 return 0;
12214 _ACEOF
12215 if ac_fn_c_try_compile "$LINENO"; then :
12216 ac_cv_func_getpgrp_void=no
12217 else
12218 ac_cv_func_getpgrp_void=yes
12220 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5
12224 $as_echo "$ac_cv_func_getpgrp_void" >&6; }
12225 if test $ac_cv_func_getpgrp_void = yes; then
12227 $as_echo "#define GETPGRP_VOID 1" >>confdefs.h
12232 for ac_func in strftime
12233 do :
12234 ac_fn_c_check_func "$LINENO" "strftime" "ac_cv_func_strftime"
12235 if test "x$ac_cv_func_strftime" = x""yes; then :
12236 cat >>confdefs.h <<_ACEOF
12237 #define HAVE_STRFTIME 1
12238 _ACEOF
12240 else
12241 # strftime is in -lintl on SCO UNIX.
12242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for strftime in -lintl" >&5
12243 $as_echo_n "checking for strftime in -lintl... " >&6; }
12244 if test "${ac_cv_lib_intl_strftime+set}" = set; then :
12245 $as_echo_n "(cached) " >&6
12246 else
12247 ac_check_lib_save_LIBS=$LIBS
12248 LIBS="-lintl $LIBS"
12249 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12250 /* end confdefs.h. */
12252 /* Override any GCC internal prototype to avoid an error.
12253 Use char because int might match the return type of a GCC
12254 builtin and then its argument prototype would still apply. */
12255 #ifdef __cplusplus
12256 extern "C"
12257 #endif
12258 char strftime ();
12260 main ()
12262 return strftime ();
12264 return 0;
12266 _ACEOF
12267 if ac_fn_c_try_link "$LINENO"; then :
12268 ac_cv_lib_intl_strftime=yes
12269 else
12270 ac_cv_lib_intl_strftime=no
12272 rm -f core conftest.err conftest.$ac_objext \
12273 conftest$ac_exeext conftest.$ac_ext
12274 LIBS=$ac_check_lib_save_LIBS
12276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_strftime" >&5
12277 $as_echo "$ac_cv_lib_intl_strftime" >&6; }
12278 if test "x$ac_cv_lib_intl_strftime" = x""yes; then :
12279 $as_echo "#define HAVE_STRFTIME 1" >>confdefs.h
12281 LIBS="-lintl $LIBS"
12285 done
12288 # UNIX98 PTYs.
12289 for ac_func in grantpt
12290 do :
12291 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
12292 if test "x$ac_cv_func_grantpt" = x""yes; then :
12293 cat >>confdefs.h <<_ACEOF
12294 #define HAVE_GRANTPT 1
12295 _ACEOF
12298 done
12301 # PTY-related GNU extensions.
12302 for ac_func in getpt
12303 do :
12304 ac_fn_c_check_func "$LINENO" "getpt" "ac_cv_func_getpt"
12305 if test "x$ac_cv_func_getpt" = x""yes; then :
12306 cat >>confdefs.h <<_ACEOF
12307 #define HAVE_GETPT 1
12308 _ACEOF
12311 done
12314 # Check this now, so that we will NOT find the above functions in ncurses.
12315 # That is because we have not set up to link ncurses in lib-src.
12316 # It's better to believe a function is not available
12317 # than to expect to find it in ncurses.
12318 # Also we need tputs and friends to be able to build at all.
12319 have_tputs_et_al=true
12320 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
12321 $as_echo_n "checking for library containing tputs... " >&6; }
12322 if test "${ac_cv_search_tputs+set}" = set; then :
12323 $as_echo_n "(cached) " >&6
12324 else
12325 ac_func_search_save_LIBS=$LIBS
12326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12327 /* end confdefs.h. */
12329 /* Override any GCC internal prototype to avoid an error.
12330 Use char because int might match the return type of a GCC
12331 builtin and then its argument prototype would still apply. */
12332 #ifdef __cplusplus
12333 extern "C"
12334 #endif
12335 char tputs ();
12337 main ()
12339 return tputs ();
12341 return 0;
12343 _ACEOF
12344 for ac_lib in '' ncurses terminfo termcap; do
12345 if test -z "$ac_lib"; then
12346 ac_res="none required"
12347 else
12348 ac_res=-l$ac_lib
12349 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
12351 if ac_fn_c_try_link "$LINENO"; then :
12352 ac_cv_search_tputs=$ac_res
12354 rm -f core conftest.err conftest.$ac_objext \
12355 conftest$ac_exeext
12356 if test "${ac_cv_search_tputs+set}" = set; then :
12357 break
12359 done
12360 if test "${ac_cv_search_tputs+set}" = set; then :
12362 else
12363 ac_cv_search_tputs=no
12365 rm conftest.$ac_ext
12366 LIBS=$ac_func_search_save_LIBS
12368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_tputs" >&5
12369 $as_echo "$ac_cv_search_tputs" >&6; }
12370 ac_res=$ac_cv_search_tputs
12371 if test "$ac_res" != no; then :
12372 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
12374 else
12375 have_tputs_et_al=false
12378 if test "$have_tputs_et_al" != true; then
12379 as_fn_error "I couldn't find termcap functions (tputs and friends).
12380 Maybe some development libraries/packages are missing? Try installing
12381 libncurses-dev(el), libterminfo-dev(el) or similar." "$LINENO" 5
12383 # Must define this when any termcap library is found.
12385 $as_echo "#define HAVE_LIBNCURSES 1" >>confdefs.h
12387 ## FIXME This was the cpp logic, but I am not sure it is right.
12388 ## The above test has not necessarily found libncurses.
12389 HAVE_LIBNCURSES=yes
12391 ## Use terminfo instead of termcap?
12392 ## Note only system files NOT using terminfo are:
12393 ## freebsd < 40000, ms-w32, msdos, netbsd < 599002500, and
12394 ## darwin|gnu without ncurses.
12395 TERMINFO=no
12396 LIBS_TERMCAP=
12397 case "$opsys" in
12398 ## cygwin: Fewer environment variables to go wrong, more terminal types.
12399 ## hpux10-20: Use the system provided termcap(3) library.
12400 ## openbsd: David Mazieres <dm@reeducation-labor.lcs.mit.edu> says this
12401 ## is necessary. Otherwise Emacs dumps core when run -nw.
12402 aix4-2|cygwin|hpux*|irix6-5|openbsd|sol2*|unixware) TERMINFO=yes ;;
12404 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
12405 ## The ncurses library has been moved out of the System framework in
12406 ## Mac OS X 10.2. So if configure detects it, set the command-line
12407 ## option to use it.
12408 darwin|gnu*)
12409 ## (HAVE_LIBNCURSES was not always true, but is since 2010-03-18.)
12410 if test "x$HAVE_LIBNCURSES" = "xyes"; then
12411 TERMINFO=yes
12412 LIBS_TERMCAP="-lncurses"
12416 freebsd)
12417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
12418 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
12419 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
12420 $as_echo_n "(cached) " >&6
12421 else
12422 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12423 /* end confdefs.h. */
12424 #include <osreldate.h>
12426 main ()
12428 #if __FreeBSD_version < 400000
12429 fail;
12430 #endif
12433 return 0;
12435 _ACEOF
12436 if ac_fn_c_try_link "$LINENO"; then :
12437 emacs_cv_freebsd_terminfo=yes
12438 else
12439 emacs_cv_freebsd_terminfo=no
12441 rm -f core conftest.err conftest.$ac_objext \
12442 conftest$ac_exeext conftest.$ac_ext
12446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
12447 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
12449 if test $emacs_cv_freebsd_terminfo = yes; then
12450 TERMINFO=yes
12451 LIBS_TERMCAP="-lncurses"
12452 else
12453 LIBS_TERMCAP="-ltermcap"
12457 netbsd)
12458 if test $ac_cv_search_tputs = -lterminfo; then
12459 TERMINFO=yes
12460 LIBS_TERMCAP="-lterminfo"
12461 else
12462 LIBS_TERMCAP="-ltermcap"
12466 esac
12468 case "$opsys" in
12469 ## hpux: Make sure we get select from libc rather than from libcurses
12470 ## because libcurses on HPUX 10.10 has a broken version of select.
12471 ## We used to use -lc -lcurses, but this may be cleaner.
12472 hpux*) LIBS_TERMCAP="-ltermcap" ;;
12474 openbsd) LIBS_TERMCAP="-lncurses" ;;
12476 ## Must use system termcap, if we use any termcap. It does special things.
12477 sol2*) test "$TERMINFO" != yes && LIBS_TERMCAP="-ltermcap" ;;
12478 esac
12480 TERMCAP_OBJ=tparam.o
12481 if test $TERMINFO = yes; then
12483 $as_echo "#define TERMINFO 1" >>confdefs.h
12486 ## Default used to be -ltermcap. Add a case above if need something else.
12487 test "x$LIBS_TERMCAP" = "x" && LIBS_TERMCAP="-lcurses"
12489 TERMCAP_OBJ=terminfo.o
12495 # Do we have res_init, for detecting changes in /etc/resolv.conf?
12496 resolv=no
12497 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12498 /* end confdefs.h. */
12499 #include <netinet/in.h>
12500 #include <arpa/nameser.h>
12501 #include <resolv.h>
12503 main ()
12505 return res_init();
12507 return 0;
12509 _ACEOF
12510 if ac_fn_c_try_link "$LINENO"; then :
12511 have_res_init=yes
12512 else
12513 have_res_init=no
12515 rm -f core conftest.err conftest.$ac_objext \
12516 conftest$ac_exeext conftest.$ac_ext
12517 if test "$have_res_init" = no; then
12518 OLIBS="$LIBS"
12519 LIBS="$LIBS -lresolv"
12520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
12521 $as_echo_n "checking for res_init with -lresolv... " >&6; }
12522 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12523 /* end confdefs.h. */
12524 #include <netinet/in.h>
12525 #include <arpa/nameser.h>
12526 #include <resolv.h>
12528 main ()
12530 return res_init();
12532 return 0;
12534 _ACEOF
12535 if ac_fn_c_try_link "$LINENO"; then :
12536 have_res_init=yes
12537 else
12538 have_res_init=no
12540 rm -f core conftest.err conftest.$ac_objext \
12541 conftest$ac_exeext conftest.$ac_ext
12542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
12543 $as_echo "$have_res_init" >&6; }
12544 if test "$have_res_init" = yes ; then
12545 resolv=yes
12547 LIBS="$OLIBS"
12550 if test "$have_res_init" = yes; then
12552 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
12556 # Do we need the Hesiod library to provide the support routines?
12557 LIBHESIOD=
12558 if test "$with_hesiod" != no ; then
12559 # Don't set $LIBS here -- see comments above. FIXME which comments?
12560 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
12561 if test "x$ac_cv_func_res_send" = x""yes; then :
12563 else
12564 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
12565 if test "x$ac_cv_func___res_send" = x""yes; then :
12567 else
12568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
12569 $as_echo_n "checking for res_send in -lresolv... " >&6; }
12570 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
12571 $as_echo_n "(cached) " >&6
12572 else
12573 ac_check_lib_save_LIBS=$LIBS
12574 LIBS="-lresolv $LIBS"
12575 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12576 /* end confdefs.h. */
12578 /* Override any GCC internal prototype to avoid an error.
12579 Use char because int might match the return type of a GCC
12580 builtin and then its argument prototype would still apply. */
12581 #ifdef __cplusplus
12582 extern "C"
12583 #endif
12584 char res_send ();
12586 main ()
12588 return res_send ();
12590 return 0;
12592 _ACEOF
12593 if ac_fn_c_try_link "$LINENO"; then :
12594 ac_cv_lib_resolv_res_send=yes
12595 else
12596 ac_cv_lib_resolv_res_send=no
12598 rm -f core conftest.err conftest.$ac_objext \
12599 conftest$ac_exeext conftest.$ac_ext
12600 LIBS=$ac_check_lib_save_LIBS
12602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
12603 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
12604 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
12605 resolv=yes
12606 else
12607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
12608 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
12609 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
12610 $as_echo_n "(cached) " >&6
12611 else
12612 ac_check_lib_save_LIBS=$LIBS
12613 LIBS="-lresolv $LIBS"
12614 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12615 /* end confdefs.h. */
12617 /* Override any GCC internal prototype to avoid an error.
12618 Use char because int might match the return type of a GCC
12619 builtin and then its argument prototype would still apply. */
12620 #ifdef __cplusplus
12621 extern "C"
12622 #endif
12623 char __res_send ();
12625 main ()
12627 return __res_send ();
12629 return 0;
12631 _ACEOF
12632 if ac_fn_c_try_link "$LINENO"; then :
12633 ac_cv_lib_resolv___res_send=yes
12634 else
12635 ac_cv_lib_resolv___res_send=no
12637 rm -f core conftest.err conftest.$ac_objext \
12638 conftest$ac_exeext conftest.$ac_ext
12639 LIBS=$ac_check_lib_save_LIBS
12641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
12642 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
12643 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
12644 resolv=yes
12653 if test "$resolv" = yes ; then
12654 RESOLVLIB=-lresolv
12655 else
12656 RESOLVLIB=
12658 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
12659 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
12661 else
12662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
12663 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
12664 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
12665 $as_echo_n "(cached) " >&6
12666 else
12667 ac_check_lib_save_LIBS=$LIBS
12668 LIBS="-lhesiod $RESOLVLIB $LIBS"
12669 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12670 /* end confdefs.h. */
12672 /* Override any GCC internal prototype to avoid an error.
12673 Use char because int might match the return type of a GCC
12674 builtin and then its argument prototype would still apply. */
12675 #ifdef __cplusplus
12676 extern "C"
12677 #endif
12678 char hes_getmailhost ();
12680 main ()
12682 return hes_getmailhost ();
12684 return 0;
12686 _ACEOF
12687 if ac_fn_c_try_link "$LINENO"; then :
12688 ac_cv_lib_hesiod_hes_getmailhost=yes
12689 else
12690 ac_cv_lib_hesiod_hes_getmailhost=no
12692 rm -f core conftest.err conftest.$ac_objext \
12693 conftest$ac_exeext conftest.$ac_ext
12694 LIBS=$ac_check_lib_save_LIBS
12696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
12697 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
12698 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
12699 hesiod=yes
12700 else
12707 if test x"$hesiod" = xyes; then
12709 $as_echo "#define HAVE_LIBHESIOD 1" >>confdefs.h
12711 LIBHESIOD=-lhesiod
12716 # Do we need libresolv (due to res_init or Hesiod)?
12717 if test "$resolv" = yes ; then
12719 $as_echo "#define HAVE_LIBRESOLV 1" >>confdefs.h
12721 LIBRESOLV=-lresolv
12722 else
12723 LIBRESOLV=
12727 # These tell us which Kerberos-related libraries to use.
12728 COM_ERRLIB=
12729 CRYPTOLIB=
12730 KRB5LIB=
12731 DESLIB=
12732 KRB4LIB=
12734 if test "${with_kerberos}" != no; then
12735 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
12736 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
12737 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
12738 $as_echo_n "(cached) " >&6
12739 else
12740 ac_check_lib_save_LIBS=$LIBS
12741 LIBS="-lcom_err $LIBS"
12742 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12743 /* end confdefs.h. */
12745 /* Override any GCC internal prototype to avoid an error.
12746 Use char because int might match the return type of a GCC
12747 builtin and then its argument prototype would still apply. */
12748 #ifdef __cplusplus
12749 extern "C"
12750 #endif
12751 char com_err ();
12753 main ()
12755 return com_err ();
12757 return 0;
12759 _ACEOF
12760 if ac_fn_c_try_link "$LINENO"; then :
12761 ac_cv_lib_com_err_com_err=yes
12762 else
12763 ac_cv_lib_com_err_com_err=no
12765 rm -f core conftest.err conftest.$ac_objext \
12766 conftest$ac_exeext conftest.$ac_ext
12767 LIBS=$ac_check_lib_save_LIBS
12769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
12770 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
12771 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
12772 have_com_err=yes
12773 else
12774 have_com_err=no
12777 if test $have_com_err = yes; then
12778 COM_ERRLIB=-lcom_err
12779 LIBS="$COM_ERRLIB $LIBS"
12781 $as_echo "#define HAVE_LIBCOM_ERR 1" >>confdefs.h
12784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
12785 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
12786 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
12787 $as_echo_n "(cached) " >&6
12788 else
12789 ac_check_lib_save_LIBS=$LIBS
12790 LIBS="-lcrypto $LIBS"
12791 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12792 /* end confdefs.h. */
12794 /* Override any GCC internal prototype to avoid an error.
12795 Use char because int might match the return type of a GCC
12796 builtin and then its argument prototype would still apply. */
12797 #ifdef __cplusplus
12798 extern "C"
12799 #endif
12800 char mit_des_cbc_encrypt ();
12802 main ()
12804 return mit_des_cbc_encrypt ();
12806 return 0;
12808 _ACEOF
12809 if ac_fn_c_try_link "$LINENO"; then :
12810 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
12811 else
12812 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
12814 rm -f core conftest.err conftest.$ac_objext \
12815 conftest$ac_exeext conftest.$ac_ext
12816 LIBS=$ac_check_lib_save_LIBS
12818 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
12819 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
12820 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
12821 have_crypto=yes
12822 else
12823 have_crypto=no
12826 if test $have_crypto = yes; then
12827 CRYPTOLIB=-lcrypto
12828 LIBS="$CRYPTOLIB $LIBS"
12830 $as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h
12833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
12834 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
12835 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
12836 $as_echo_n "(cached) " >&6
12837 else
12838 ac_check_lib_save_LIBS=$LIBS
12839 LIBS="-lk5crypto $LIBS"
12840 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12841 /* end confdefs.h. */
12843 /* Override any GCC internal prototype to avoid an error.
12844 Use char because int might match the return type of a GCC
12845 builtin and then its argument prototype would still apply. */
12846 #ifdef __cplusplus
12847 extern "C"
12848 #endif
12849 char mit_des_cbc_encrypt ();
12851 main ()
12853 return mit_des_cbc_encrypt ();
12855 return 0;
12857 _ACEOF
12858 if ac_fn_c_try_link "$LINENO"; then :
12859 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
12860 else
12861 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
12863 rm -f core conftest.err conftest.$ac_objext \
12864 conftest$ac_exeext conftest.$ac_ext
12865 LIBS=$ac_check_lib_save_LIBS
12867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
12868 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
12869 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
12870 have_k5crypto=yes
12871 else
12872 have_k5crypto=no
12875 if test $have_k5crypto = yes; then
12876 CRYPTOLIB=-lk5crypto
12877 LIBS="$CRYPTOLIB $LIBS"
12879 $as_echo "#define HAVE_LIBK5CRYPTO 1" >>confdefs.h
12882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
12883 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
12884 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
12885 $as_echo_n "(cached) " >&6
12886 else
12887 ac_check_lib_save_LIBS=$LIBS
12888 LIBS="-lkrb5 $LIBS"
12889 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12890 /* end confdefs.h. */
12892 /* Override any GCC internal prototype to avoid an error.
12893 Use char because int might match the return type of a GCC
12894 builtin and then its argument prototype would still apply. */
12895 #ifdef __cplusplus
12896 extern "C"
12897 #endif
12898 char krb5_init_context ();
12900 main ()
12902 return krb5_init_context ();
12904 return 0;
12906 _ACEOF
12907 if ac_fn_c_try_link "$LINENO"; then :
12908 ac_cv_lib_krb5_krb5_init_context=yes
12909 else
12910 ac_cv_lib_krb5_krb5_init_context=no
12912 rm -f core conftest.err conftest.$ac_objext \
12913 conftest$ac_exeext conftest.$ac_ext
12914 LIBS=$ac_check_lib_save_LIBS
12916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
12917 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
12918 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
12919 have_krb5=yes
12920 else
12921 have_krb5=no
12924 if test $have_krb5=yes; then
12925 KRB5LIB=-lkrb5
12926 LIBS="$KRB5LIB $LIBS"
12928 $as_echo "#define HAVE_LIBKRB5 1" >>confdefs.h
12931 if test "${with_kerberos5}" = no; then
12932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
12933 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
12934 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
12935 $as_echo_n "(cached) " >&6
12936 else
12937 ac_check_lib_save_LIBS=$LIBS
12938 LIBS="-ldes425 $LIBS"
12939 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12940 /* end confdefs.h. */
12942 /* Override any GCC internal prototype to avoid an error.
12943 Use char because int might match the return type of a GCC
12944 builtin and then its argument prototype would still apply. */
12945 #ifdef __cplusplus
12946 extern "C"
12947 #endif
12948 char des_cbc_encrypt ();
12950 main ()
12952 return des_cbc_encrypt ();
12954 return 0;
12956 _ACEOF
12957 if ac_fn_c_try_link "$LINENO"; then :
12958 ac_cv_lib_des425_des_cbc_encrypt=yes
12959 else
12960 ac_cv_lib_des425_des_cbc_encrypt=no
12962 rm -f core conftest.err conftest.$ac_objext \
12963 conftest$ac_exeext conftest.$ac_ext
12964 LIBS=$ac_check_lib_save_LIBS
12966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
12967 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
12968 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
12969 have_des425=yes
12970 else
12971 have_des425=no
12974 if test $have_des425 = yes; then
12975 DESLIB=-ldes425
12976 LIBS="$DESLIB $LIBS"
12978 $as_echo "#define HAVE_LIBDES425 1" >>confdefs.h
12980 else
12981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
12982 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
12983 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
12984 $as_echo_n "(cached) " >&6
12985 else
12986 ac_check_lib_save_LIBS=$LIBS
12987 LIBS="-ldes $LIBS"
12988 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12989 /* end confdefs.h. */
12991 /* Override any GCC internal prototype to avoid an error.
12992 Use char because int might match the return type of a GCC
12993 builtin and then its argument prototype would still apply. */
12994 #ifdef __cplusplus
12995 extern "C"
12996 #endif
12997 char des_cbc_encrypt ();
12999 main ()
13001 return des_cbc_encrypt ();
13003 return 0;
13005 _ACEOF
13006 if ac_fn_c_try_link "$LINENO"; then :
13007 ac_cv_lib_des_des_cbc_encrypt=yes
13008 else
13009 ac_cv_lib_des_des_cbc_encrypt=no
13011 rm -f core conftest.err conftest.$ac_objext \
13012 conftest$ac_exeext conftest.$ac_ext
13013 LIBS=$ac_check_lib_save_LIBS
13015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
13016 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
13017 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
13018 have_des=yes
13019 else
13020 have_des=no
13023 if test $have_des = yes; then
13024 DESLIB=-ldes
13025 LIBS="$DESLIB $LIBS"
13027 $as_echo "#define HAVE_LIBDES 1" >>confdefs.h
13031 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
13032 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
13033 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
13034 $as_echo_n "(cached) " >&6
13035 else
13036 ac_check_lib_save_LIBS=$LIBS
13037 LIBS="-lkrb4 $LIBS"
13038 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13039 /* end confdefs.h. */
13041 /* Override any GCC internal prototype to avoid an error.
13042 Use char because int might match the return type of a GCC
13043 builtin and then its argument prototype would still apply. */
13044 #ifdef __cplusplus
13045 extern "C"
13046 #endif
13047 char krb_get_cred ();
13049 main ()
13051 return krb_get_cred ();
13053 return 0;
13055 _ACEOF
13056 if ac_fn_c_try_link "$LINENO"; then :
13057 ac_cv_lib_krb4_krb_get_cred=yes
13058 else
13059 ac_cv_lib_krb4_krb_get_cred=no
13061 rm -f core conftest.err conftest.$ac_objext \
13062 conftest$ac_exeext conftest.$ac_ext
13063 LIBS=$ac_check_lib_save_LIBS
13065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
13066 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
13067 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
13068 have_krb4=yes
13069 else
13070 have_krb4=no
13073 if test $have_krb4 = yes; then
13074 KRB4LIB=-lkrb4
13075 LIBS="$KRB4LIB $LIBS"
13077 $as_echo "#define HAVE_LIBKRB4 1" >>confdefs.h
13079 else
13080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
13081 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
13082 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
13083 $as_echo_n "(cached) " >&6
13084 else
13085 ac_check_lib_save_LIBS=$LIBS
13086 LIBS="-lkrb $LIBS"
13087 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13088 /* end confdefs.h. */
13090 /* Override any GCC internal prototype to avoid an error.
13091 Use char because int might match the return type of a GCC
13092 builtin and then its argument prototype would still apply. */
13093 #ifdef __cplusplus
13094 extern "C"
13095 #endif
13096 char krb_get_cred ();
13098 main ()
13100 return krb_get_cred ();
13102 return 0;
13104 _ACEOF
13105 if ac_fn_c_try_link "$LINENO"; then :
13106 ac_cv_lib_krb_krb_get_cred=yes
13107 else
13108 ac_cv_lib_krb_krb_get_cred=no
13110 rm -f core conftest.err conftest.$ac_objext \
13111 conftest$ac_exeext conftest.$ac_ext
13112 LIBS=$ac_check_lib_save_LIBS
13114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
13115 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
13116 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
13117 have_krb=yes
13118 else
13119 have_krb=no
13122 if test $have_krb = yes; then
13123 KRB4LIB=-lkrb
13124 LIBS="$KRB4LIB $LIBS"
13126 $as_echo "#define HAVE_LIBKRB 1" >>confdefs.h
13132 if test "${with_kerberos5}" != no; then
13133 for ac_header in krb5.h
13134 do :
13135 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
13136 if test "x$ac_cv_header_krb5_h" = x""yes; then :
13137 cat >>confdefs.h <<_ACEOF
13138 #define HAVE_KRB5_H 1
13139 _ACEOF
13140 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
13142 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
13144 cat >>confdefs.h <<_ACEOF
13145 #define HAVE_KRB5_ERROR_TEXT 1
13146 _ACEOF
13150 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
13152 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
13154 cat >>confdefs.h <<_ACEOF
13155 #define HAVE_KRB5_ERROR_E_TEXT 1
13156 _ACEOF
13163 done
13165 else
13166 for ac_header in des.h
13167 do :
13168 ac_fn_c_check_header_mongrel "$LINENO" "des.h" "ac_cv_header_des_h" "$ac_includes_default"
13169 if test "x$ac_cv_header_des_h" = x""yes; then :
13170 cat >>confdefs.h <<_ACEOF
13171 #define HAVE_DES_H 1
13172 _ACEOF
13174 else
13175 for ac_header in kerberosIV/des.h
13176 do :
13177 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/des.h" "ac_cv_header_kerberosIV_des_h" "$ac_includes_default"
13178 if test "x$ac_cv_header_kerberosIV_des_h" = x""yes; then :
13179 cat >>confdefs.h <<_ACEOF
13180 #define HAVE_KERBEROSIV_DES_H 1
13181 _ACEOF
13183 else
13184 for ac_header in kerberos/des.h
13185 do :
13186 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/des.h" "ac_cv_header_kerberos_des_h" "$ac_includes_default"
13187 if test "x$ac_cv_header_kerberos_des_h" = x""yes; then :
13188 cat >>confdefs.h <<_ACEOF
13189 #define HAVE_KERBEROS_DES_H 1
13190 _ACEOF
13194 done
13198 done
13202 done
13204 for ac_header in krb.h
13205 do :
13206 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
13207 if test "x$ac_cv_header_krb_h" = x""yes; then :
13208 cat >>confdefs.h <<_ACEOF
13209 #define HAVE_KRB_H 1
13210 _ACEOF
13212 else
13213 for ac_header in kerberosIV/krb.h
13214 do :
13215 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
13216 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
13217 cat >>confdefs.h <<_ACEOF
13218 #define HAVE_KERBEROSIV_KRB_H 1
13219 _ACEOF
13221 else
13222 for ac_header in kerberos/krb.h
13223 do :
13224 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
13225 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
13226 cat >>confdefs.h <<_ACEOF
13227 #define HAVE_KERBEROS_KRB_H 1
13228 _ACEOF
13232 done
13236 done
13240 done
13243 for ac_header in com_err.h
13244 do :
13245 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
13246 if test "x$ac_cv_header_com_err_h" = x""yes; then :
13247 cat >>confdefs.h <<_ACEOF
13248 #define HAVE_COM_ERR_H 1
13249 _ACEOF
13253 done
13263 # Solaris requires -lintl if you want strerror (which calls dgettext)
13264 # to return localized messages.
13265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dgettext in -lintl" >&5
13266 $as_echo_n "checking for dgettext in -lintl... " >&6; }
13267 if test "${ac_cv_lib_intl_dgettext+set}" = set; then :
13268 $as_echo_n "(cached) " >&6
13269 else
13270 ac_check_lib_save_LIBS=$LIBS
13271 LIBS="-lintl $LIBS"
13272 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13273 /* end confdefs.h. */
13275 /* Override any GCC internal prototype to avoid an error.
13276 Use char because int might match the return type of a GCC
13277 builtin and then its argument prototype would still apply. */
13278 #ifdef __cplusplus
13279 extern "C"
13280 #endif
13281 char dgettext ();
13283 main ()
13285 return dgettext ();
13287 return 0;
13289 _ACEOF
13290 if ac_fn_c_try_link "$LINENO"; then :
13291 ac_cv_lib_intl_dgettext=yes
13292 else
13293 ac_cv_lib_intl_dgettext=no
13295 rm -f core conftest.err conftest.$ac_objext \
13296 conftest$ac_exeext conftest.$ac_ext
13297 LIBS=$ac_check_lib_save_LIBS
13299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_dgettext" >&5
13300 $as_echo "$ac_cv_lib_intl_dgettext" >&6; }
13301 if test "x$ac_cv_lib_intl_dgettext" = x""yes; then :
13302 cat >>confdefs.h <<_ACEOF
13303 #define HAVE_LIBINTL 1
13304 _ACEOF
13306 LIBS="-lintl $LIBS"
13311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
13312 $as_echo_n "checking whether localtime caches TZ... " >&6; }
13313 if test "${emacs_cv_localtime_cache+set}" = set; then :
13314 $as_echo_n "(cached) " >&6
13315 else
13316 if test x$ac_cv_func_tzset = xyes; then
13317 if test "$cross_compiling" = yes; then :
13318 # If we have tzset, assume the worst when cross-compiling.
13319 emacs_cv_localtime_cache=yes
13320 else
13321 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13322 /* end confdefs.h. */
13323 #include <time.h>
13324 extern char **environ;
13325 unset_TZ ()
13327 char **from, **to;
13328 for (to = from = environ; (*to = *from); from++)
13329 if (! (to[0][0] == 'T' && to[0][1] == 'Z' && to[0][2] == '='))
13330 to++;
13332 char TZ_GMT0[] = "TZ=GMT0";
13333 char TZ_PST8[] = "TZ=PST8";
13334 main()
13336 time_t now = time ((time_t *) 0);
13337 int hour_GMT0, hour_unset;
13338 if (putenv (TZ_GMT0) != 0)
13339 exit (1);
13340 hour_GMT0 = localtime (&now)->tm_hour;
13341 unset_TZ ();
13342 hour_unset = localtime (&now)->tm_hour;
13343 if (putenv (TZ_PST8) != 0)
13344 exit (1);
13345 if (localtime (&now)->tm_hour == hour_GMT0)
13346 exit (1);
13347 unset_TZ ();
13348 if (localtime (&now)->tm_hour != hour_unset)
13349 exit (1);
13350 exit (0);
13352 _ACEOF
13353 if ac_fn_c_try_run "$LINENO"; then :
13354 emacs_cv_localtime_cache=no
13355 else
13356 emacs_cv_localtime_cache=yes
13358 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13359 conftest.$ac_objext conftest.beam conftest.$ac_ext
13362 else
13363 # If we lack tzset, report that localtime does not cache TZ,
13364 # since we can't invalidate the cache if we don't have tzset.
13365 emacs_cv_localtime_cache=no
13368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
13369 $as_echo "$emacs_cv_localtime_cache" >&6; }
13370 if test $emacs_cv_localtime_cache = yes; then
13372 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
13376 if test "x$HAVE_TIMEVAL" = xyes; then
13377 for ac_func in gettimeofday
13378 do :
13379 ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday"
13380 if test "x$ac_cv_func_gettimeofday" = x""yes; then :
13381 cat >>confdefs.h <<_ACEOF
13382 #define HAVE_GETTIMEOFDAY 1
13383 _ACEOF
13386 done
13388 if test $ac_cv_func_gettimeofday = yes; then
13389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday can accept two arguments" >&5
13390 $as_echo_n "checking whether gettimeofday can accept two arguments... " >&6; }
13391 if test "${emacs_cv_gettimeofday_two_arguments+set}" = set; then :
13392 $as_echo_n "(cached) " >&6
13393 else
13394 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13395 /* end confdefs.h. */
13397 #ifdef TIME_WITH_SYS_TIME
13398 #include <sys/time.h>
13399 #include <time.h>
13400 #else
13401 #ifdef HAVE_SYS_TIME_H
13402 #include <sys/time.h>
13403 #else
13404 #include <time.h>
13405 #endif
13406 #endif
13408 main ()
13410 struct timeval time;
13411 gettimeofday (&time, 0);
13413 return 0;
13415 _ACEOF
13416 if ac_fn_c_try_compile "$LINENO"; then :
13417 emacs_cv_gettimeofday_two_arguments=yes
13418 else
13419 emacs_cv_gettimeofday_two_arguments=no
13421 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_gettimeofday_two_arguments" >&5
13424 $as_echo "$emacs_cv_gettimeofday_two_arguments" >&6; }
13425 if test $emacs_cv_gettimeofday_two_arguments = no; then
13427 $as_echo "#define GETTIMEOFDAY_ONE_ARGUMENT 1" >>confdefs.h
13433 ok_so_far=yes
13434 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
13435 if test "x$ac_cv_func_socket" = x""yes; then :
13437 else
13438 ok_so_far=no
13441 if test $ok_so_far = yes; then
13442 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
13443 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
13445 else
13446 ok_so_far=no
13451 if test $ok_so_far = yes; then
13452 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
13453 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
13455 else
13456 ok_so_far=no
13461 if test $ok_so_far = yes; then
13463 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
13467 for ac_header in sys/ioctl.h
13468 do :
13469 ac_fn_c_check_header_mongrel "$LINENO" "sys/ioctl.h" "ac_cv_header_sys_ioctl_h" "$ac_includes_default"
13470 if test "x$ac_cv_header_sys_ioctl_h" = x""yes; then :
13471 cat >>confdefs.h <<_ACEOF
13472 #define HAVE_SYS_IOCTL_H 1
13473 _ACEOF
13477 done
13480 if test -f /usr/lpp/X11/bin/smt.exp; then
13482 $as_echo "#define HAVE_AIX_SMT_EXP 1" >>confdefs.h
13486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports dynamic ptys" >&5
13487 $as_echo_n "checking whether system supports dynamic ptys... " >&6; }
13488 if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
13489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13490 $as_echo "yes" >&6; }
13492 $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h
13494 else
13495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13496 $as_echo "no" >&6; }
13499 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
13500 if test "x$ac_cv_type_pid_t" = x""yes; then :
13502 else
13504 cat >>confdefs.h <<_ACEOF
13505 #define pid_t int
13506 _ACEOF
13510 for ac_header in vfork.h
13511 do :
13512 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
13513 if test "x$ac_cv_header_vfork_h" = x""yes; then :
13514 cat >>confdefs.h <<_ACEOF
13515 #define HAVE_VFORK_H 1
13516 _ACEOF
13520 done
13522 for ac_func in fork vfork
13523 do :
13524 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13525 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13526 eval as_val=\$$as_ac_var
13527 if test "x$as_val" = x""yes; then :
13528 cat >>confdefs.h <<_ACEOF
13529 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13530 _ACEOF
13533 done
13535 if test "x$ac_cv_func_fork" = xyes; then
13536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
13537 $as_echo_n "checking for working fork... " >&6; }
13538 if test "${ac_cv_func_fork_works+set}" = set; then :
13539 $as_echo_n "(cached) " >&6
13540 else
13541 if test "$cross_compiling" = yes; then :
13542 ac_cv_func_fork_works=cross
13543 else
13544 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13545 /* end confdefs.h. */
13546 $ac_includes_default
13548 main ()
13551 /* By Ruediger Kuhlmann. */
13552 return fork () < 0;
13555 return 0;
13557 _ACEOF
13558 if ac_fn_c_try_run "$LINENO"; then :
13559 ac_cv_func_fork_works=yes
13560 else
13561 ac_cv_func_fork_works=no
13563 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13564 conftest.$ac_objext conftest.beam conftest.$ac_ext
13568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
13569 $as_echo "$ac_cv_func_fork_works" >&6; }
13571 else
13572 ac_cv_func_fork_works=$ac_cv_func_fork
13574 if test "x$ac_cv_func_fork_works" = xcross; then
13575 case $host in
13576 *-*-amigaos* | *-*-msdosdjgpp*)
13577 # Override, as these systems have only a dummy fork() stub
13578 ac_cv_func_fork_works=no
13581 ac_cv_func_fork_works=yes
13583 esac
13584 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
13585 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
13587 ac_cv_func_vfork_works=$ac_cv_func_vfork
13588 if test "x$ac_cv_func_vfork" = xyes; then
13589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
13590 $as_echo_n "checking for working vfork... " >&6; }
13591 if test "${ac_cv_func_vfork_works+set}" = set; then :
13592 $as_echo_n "(cached) " >&6
13593 else
13594 if test "$cross_compiling" = yes; then :
13595 ac_cv_func_vfork_works=cross
13596 else
13597 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13598 /* end confdefs.h. */
13599 /* Thanks to Paul Eggert for this test. */
13600 $ac_includes_default
13601 #include <sys/wait.h>
13602 #ifdef HAVE_VFORK_H
13603 # include <vfork.h>
13604 #endif
13605 /* On some sparc systems, changes by the child to local and incoming
13606 argument registers are propagated back to the parent. The compiler
13607 is told about this with #include <vfork.h>, but some compilers
13608 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
13609 static variable whose address is put into a register that is
13610 clobbered by the vfork. */
13611 static void
13612 #ifdef __cplusplus
13613 sparc_address_test (int arg)
13614 # else
13615 sparc_address_test (arg) int arg;
13616 #endif
13618 static pid_t child;
13619 if (!child) {
13620 child = vfork ();
13621 if (child < 0) {
13622 perror ("vfork");
13623 _exit(2);
13625 if (!child) {
13626 arg = getpid();
13627 write(-1, "", 0);
13628 _exit (arg);
13634 main ()
13636 pid_t parent = getpid ();
13637 pid_t child;
13639 sparc_address_test (0);
13641 child = vfork ();
13643 if (child == 0) {
13644 /* Here is another test for sparc vfork register problems. This
13645 test uses lots of local variables, at least as many local
13646 variables as main has allocated so far including compiler
13647 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
13648 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
13649 reuse the register of parent for one of the local variables,
13650 since it will think that parent can't possibly be used any more
13651 in this routine. Assigning to the local variable will thus
13652 munge parent in the parent process. */
13653 pid_t
13654 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
13655 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
13656 /* Convince the compiler that p..p7 are live; otherwise, it might
13657 use the same hardware register for all 8 local variables. */
13658 if (p != p1 || p != p2 || p != p3 || p != p4
13659 || p != p5 || p != p6 || p != p7)
13660 _exit(1);
13662 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
13663 from child file descriptors. If the child closes a descriptor
13664 before it execs or exits, this munges the parent's descriptor
13665 as well. Test for this by closing stdout in the child. */
13666 _exit(close(fileno(stdout)) != 0);
13667 } else {
13668 int status;
13669 struct stat st;
13671 while (wait(&status) != child)
13673 return (
13674 /* Was there some problem with vforking? */
13675 child < 0
13677 /* Did the child fail? (This shouldn't happen.) */
13678 || status
13680 /* Did the vfork/compiler bug occur? */
13681 || parent != getpid()
13683 /* Did the file descriptor bug occur? */
13684 || fstat(fileno(stdout), &st) != 0
13688 _ACEOF
13689 if ac_fn_c_try_run "$LINENO"; then :
13690 ac_cv_func_vfork_works=yes
13691 else
13692 ac_cv_func_vfork_works=no
13694 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13695 conftest.$ac_objext conftest.beam conftest.$ac_ext
13699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
13700 $as_echo "$ac_cv_func_vfork_works" >&6; }
13703 if test "x$ac_cv_func_fork_works" = xcross; then
13704 ac_cv_func_vfork_works=$ac_cv_func_vfork
13705 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
13706 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
13709 if test "x$ac_cv_func_vfork_works" = xyes; then
13711 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
13713 else
13715 $as_echo "#define vfork fork" >>confdefs.h
13718 if test "x$ac_cv_func_fork_works" = xyes; then
13720 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
13725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
13726 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
13727 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
13728 $as_echo_n "(cached) " >&6
13729 else
13730 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13731 /* end confdefs.h. */
13732 #include <langinfo.h>
13734 main ()
13736 char* cs = nl_langinfo(CODESET);
13738 return 0;
13740 _ACEOF
13741 if ac_fn_c_try_link "$LINENO"; then :
13742 emacs_cv_langinfo_codeset=yes
13743 else
13744 emacs_cv_langinfo_codeset=no
13746 rm -f core conftest.err conftest.$ac_objext \
13747 conftest$ac_exeext conftest.$ac_ext
13750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
13751 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
13752 if test $emacs_cv_langinfo_codeset = yes; then
13754 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
13758 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
13759 if test "x$ac_cv_type_size_t" = x""yes; then :
13761 cat >>confdefs.h <<_ACEOF
13762 #define HAVE_SIZE_T 1
13763 _ACEOF
13769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
13770 $as_echo_n "checking for mbstate_t... " >&6; }
13771 if test "${ac_cv_type_mbstate_t+set}" = set; then :
13772 $as_echo_n "(cached) " >&6
13773 else
13774 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13775 /* end confdefs.h. */
13776 $ac_includes_default
13777 # include <wchar.h>
13779 main ()
13781 mbstate_t x; return sizeof x;
13783 return 0;
13785 _ACEOF
13786 if ac_fn_c_try_compile "$LINENO"; then :
13787 ac_cv_type_mbstate_t=yes
13788 else
13789 ac_cv_type_mbstate_t=no
13791 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
13794 $as_echo "$ac_cv_type_mbstate_t" >&6; }
13795 if test $ac_cv_type_mbstate_t = yes; then
13797 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
13799 else
13801 $as_echo "#define mbstate_t int" >>confdefs.h
13805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restrict keyword" >&5
13806 $as_echo_n "checking for C restrict keyword... " >&6; }
13807 if test "${emacs_cv_c_restrict+set}" = set; then :
13808 $as_echo_n "(cached) " >&6
13809 else
13810 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13811 /* end confdefs.h. */
13812 void fred (int *restrict x);
13814 main ()
13818 return 0;
13820 _ACEOF
13821 if ac_fn_c_try_compile "$LINENO"; then :
13822 emacs_cv_c_restrict=yes
13823 else
13824 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13825 /* end confdefs.h. */
13826 void fred (int *__restrict x);
13828 main ()
13832 return 0;
13834 _ACEOF
13835 if ac_fn_c_try_compile "$LINENO"; then :
13836 emacs_cv_c_restrict=__restrict
13837 else
13838 emacs_cv_c_restrict=no
13840 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13842 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict" >&5
13845 $as_echo "$emacs_cv_c_restrict" >&6; }
13846 case "$emacs_cv_c_restrict" in
13847 yes) emacs_restrict=restrict;;
13848 no) emacs_restrict="";;
13849 *) emacs_restrict="$emacs_cv_c_restrict";;
13850 esac
13851 if test "$emacs_restrict" != __restrict; then
13853 cat >>confdefs.h <<_ACEOF
13854 #define __restrict $emacs_restrict
13855 _ACEOF
13859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
13860 $as_echo_n "checking for C restricted array declarations... " >&6; }
13861 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
13862 $as_echo_n "(cached) " >&6
13863 else
13864 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13865 /* end confdefs.h. */
13866 void fred (int x[__restrict]);
13868 main ()
13872 return 0;
13874 _ACEOF
13875 if ac_fn_c_try_compile "$LINENO"; then :
13876 emacs_cv_c_restrict_arr=yes
13877 else
13878 emacs_cv_c_restrict_arr=no
13880 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
13883 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
13884 if test "$emacs_cv_c_restrict_arr" = yes; then
13886 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
13892 # Set up the CFLAGS for real compilation, so we can substitute it.
13893 CFLAGS="$REAL_CFLAGS"
13894 CPPFLAGS="$REAL_CPPFLAGS"
13896 ## Hack to detect a buggy GCC version.
13897 if test "x$GCC" = xyes \
13898 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
13899 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
13900 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
13901 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
13904 #### Find out which version of Emacs this is.
13905 version=`grep 'const char emacs_version' ${srcdir}/src/emacs.c \
13906 | sed -e 's/^[^"]*"\([^"]*\)".*$/\1/'`
13907 if test x"${version}" = x; then
13908 as_fn_error "can't find current emacs version in \`${srcdir}/src/emacs.c'." "$LINENO" 5
13910 if test x"${version}" != x"$PACKAGE_VERSION"; then
13911 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: version mismatch between \`${srcdir}/configure.in' and \`${srcdir}/src/emacs.c'." >&5
13912 $as_echo "$as_me: WARNING: version mismatch between \`${srcdir}/configure.in' and \`${srcdir}/src/emacs.c'." >&2;}
13915 ### Specify what sort of things we'll be editing into Makefile and config.h.
13916 ### Use configuration here uncanonicalized to avoid exceeding size limits.
13919 ## Unused?
13940 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
13941 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
13942 ## end of LIBX_BASE, but nothing ever set it.
13947 ## Used in lwlib/Makefile.in.
13960 cat >>confdefs.h <<_ACEOF
13961 #define EMACS_CONFIGURATION "${canonical}"
13962 _ACEOF
13965 cat >>confdefs.h <<_ACEOF
13966 #define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
13967 _ACEOF
13970 cat >>confdefs.h <<_ACEOF
13971 #define config_machfile "${machfile}"
13972 _ACEOF
13975 cat >>confdefs.h <<_ACEOF
13976 #define config_opsysfile "${opsysfile}"
13977 _ACEOF
13980 XMENU_OBJ=
13981 XOBJ=
13982 FONT_OBJ=
13983 if test "${HAVE_X_WINDOWS}" = "yes" ; then
13985 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
13987 XMENU_OBJ=xmenu.o
13988 XOBJ="xterm.o xfns.o xselect.o xrdb.o fontset.o xsmfns.o fringe.o image.o xsettings.o xgselect.o"
13989 FONT_OBJ=xfont.o
13990 if test "$HAVE_XFT" = "yes"; then
13991 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
13992 elif test "$HAVE_FREETYPE" = "yes"; then
13993 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
14001 WIDGET_OBJ=
14002 MOTIF_LIBW=
14003 if test "${USE_X_TOOLKIT}" != "none" ; then
14004 WIDGET_OBJ=widget.o
14006 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
14008 if test "${USE_X_TOOLKIT}" = "LUCID"; then
14010 $as_echo "#define USE_LUCID 1" >>confdefs.h
14012 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
14014 $as_echo "#define USE_MOTIF 1" >>confdefs.h
14016 MOTIF_LIBW=-lXm
14017 case "$opsys" in
14018 gnu-linux)
14019 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
14020 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
14023 unixware)
14024 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
14025 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
14026 MOTIF_LIBW="MOTIF_LIBW -lXimp"
14029 aix4-2)
14030 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
14031 MOTIF_LIBW="$MOTIF_LIBW -li18n"
14033 esac
14034 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
14039 TOOLKIT_LIBW=
14040 case "$USE_X_TOOLKIT" in
14041 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
14042 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
14043 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
14044 esac
14047 if test "$USE_X_TOOLKIT" = "none"; then
14048 LIBXT_OTHER="\$(LIBXSM)"
14049 OLDXMENU_TARGET="really-oldXMenu"
14050 else
14051 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
14052 OLDXMENU_TARGET="really-lwlib"
14056 ## The X Menu stuff is present in the X10 distribution, but missing
14057 ## from X11. If we have X10, just use the installed library;
14058 ## otherwise, use our own copy.
14059 if test "${HAVE_X11}" = "yes" ; then
14061 $as_echo "#define HAVE_X11 1" >>confdefs.h
14064 if test "$USE_X_TOOLKIT" = "none"; then
14065 OLDXMENU="\${oldXMenudir}libXMenu11.a"
14066 else
14067 OLDXMENU="\${lwlibdir}liblw.a"
14069 LIBXMENU="\$(OLDXMENU)"
14070 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
14071 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
14072 else
14073 ## For a syntactically valid Makefile; not actually used for anything.
14074 ## See comments in src/Makefile.in.
14075 OLDXMENU=nothing
14076 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
14077 if test "${HAVE_X_WINDOWS}" = "yes"; then
14078 LIBXMENU="-lXMenu"
14079 else
14080 LIBXMENU=
14082 LIBX_OTHER=
14083 OLDXMENU_DEPS=
14086 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
14087 OLDXMENU_TARGET=
14088 OLDXMENU=nothing
14089 LIBXMENU=
14090 OLDXMENU_DEPS=
14099 if test "${HAVE_MENUS}" = "yes" ; then
14101 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
14105 if test "${GNU_MALLOC}" = "yes" ; then
14107 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
14111 RALLOC_OBJ=
14112 if test "${REL_ALLOC}" = "yes" ; then
14114 $as_echo "#define REL_ALLOC 1" >>confdefs.h
14117 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
14121 if test "$opsys" = "cygwin"; then
14122 CYGWIN_OBJ="sheap.o"
14123 ## Cygwin differs because of its unexec().
14124 PRE_ALLOC_OBJ=
14125 POST_ALLOC_OBJ=lastfile.o
14126 else
14127 CYGWIN_OBJ=
14128 PRE_ALLOC_OBJ=lastfile.o
14129 POST_ALLOC_OBJ=
14136 case "$opsys" in
14137 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
14139 darwin)
14140 ## The -headerpad option tells ld (see man page) to leave room at the
14141 ## end of the header for adding load commands. Needed for dumping.
14142 ## 0x690 is the total size of 30 segment load commands (at 56
14143 ## each); under Cocoa 31 commands are required.
14144 if test "$HAVE_NS" = "yes"; then
14145 libs_nsgui="-framework AppKit"
14146 headerpad_extra=6C8
14147 else
14148 libs_nsgui=
14149 headerpad_extra=690
14151 LD_SWITCH_SYSTEM_TEMACS="-prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
14153 ## This is here because src/Makefile.in did some extra fiddling around
14154 ## with LD_SWITCH_SYSTEM. The cpp logic was:
14155 ## #ifndef LD_SWITCH_SYSTEM
14156 ## #if !defined (__GNUC__) && ((defined (BSD_SYSTEM) && !defined (COFF)))
14157 ## Since all the *bsds define LD_SWITCH_SYSTEM, this simplifies to:
14158 ## not using gcc, darwin system not on an alpha (ie darwin, since
14159 ## darwin + alpha does not occur).
14160 ## Because this was done in src/Makefile.in, the resulting part of
14161 ## LD_SWITCH_SYSTEM was not used in configure (ie, in ac_link).
14162 ## It therefore seems cleaner to put this in LD_SWITCH_SYSTEM_TEMACS,
14163 ## rather than LD_SWITCH_SYSTEM.
14164 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
14165 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
14168 ## LD_SWITCH_X_SITE_AUX is a -R option saying where to find X at run-time.
14169 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at
14170 ## the point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_AUX
14171 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
14172 ## had different values in configure (in ac_link) and src/Makefile.in.
14173 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
14174 gnu-linux) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_AUX)" ;;
14176 *) LD_SWITCH_SYSTEM_TEMACS= ;;
14177 esac
14179 if test "$NS_IMPL_GNUSTEP" = "yes"; then
14180 LD_SWITCH_SYSTEM_TEMACS="${LD_SWITCH_SYSTEM_TEMACS} -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES} -lgnustep-gui -lgnustep-base -lobjc -lpthread"
14186 LINKER=
14187 ORDINARY_LINK=
14188 case "$opsys" in
14189 ## gnu: GNU needs its own crt0.
14190 aix4-2|cygwin|darwin|gnu|irix6-5|sol2*|unixware) ORDINARY_LINK=yes ;;
14192 ## On post 1.3 releases of NetBSD, gcc -nostdlib also clears the
14193 ## library search parth, i.e. it won't search /usr/lib for libc and
14194 ## friends. Using -nostartfiles instead avoids this problem, and
14195 ## will also work on earlier NetBSD releases.
14196 netbsd|openbsd) LINKER="\$(CC) -nostartfiles" ;;
14198 ## macpcc: NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp> says
14199 ## MkLinux/LinuxPPC needs this.
14200 ## ibms390x only supports opsys = gnu-linux so it can be added here.
14201 gnu-*)
14202 case "$machine" in
14203 macppc|ibms390x) LINKER="\$(CC) -nostdlib" ;;
14204 esac
14206 esac
14209 if test "x$ORDINARY_LINK" = "xyes"; then
14211 LINKER="\$(CC)"
14213 $as_echo "#define ORDINARY_LINK 1" >>confdefs.h
14216 ## The system files defining neither ORDINARY_LINK nor LINKER are:
14217 ## (bsd-common), freebsd, gnu-* not on macppc|ibms390x, hpux*.
14218 elif test "x$GCC" = "xyes" && test "x$LINKER" = "x"; then
14220 ## Versions of GCC >= 2.0 put their library, libgcc.a, in obscure
14221 ## places that are difficult to figure out at make time. Fortunately,
14222 ## these same versions allow you to pass arbitrary flags on to the
14223 ## linker, so there is no reason not to use it as a linker.
14225 ## Well, it is not quite perfect. The "-nostdlib" keeps GCC from
14226 ## searching for libraries in its internal directories, so we have to
14227 ## ask GCC explicitly where to find libgcc.a (LIB_GCC below).
14228 LINKER="\$(CC) -nostdlib"
14231 test "x$LINKER" = "x" && LINKER=ld
14232 ## FIXME? What setting of EDIT_LDFLAGS should this have?
14233 test "$NS_IMPL_GNUSTEP" = "yes" && LINKER="\$(CC) -rdynamic"
14238 ## FIXME? The logic here is not precisely the same as that above.
14239 ## There is no check here for a pre-defined LINKER.
14240 ## Should we only be setting LIB_GCC if LD ~ -nostdlib?
14241 LIB_GCC=
14242 if test "x$GCC" = "xyes" && test "x$ORDINARY_LINK" != "xyes"; then
14244 case "$opsys" in
14245 freebsd|netbsd|openbsd) LIB_GCC= ;;
14247 gnu-*)
14248 ## armin76@gentoo.org reported that the lgcc_s flag is necessary to
14249 ## build on ARM EABI under GNU/Linux. (Bug#5518)
14250 ## Note that m/arm.h never bothered to undefine LIB_GCC first.
14251 if test "$machine" = "arm"; then
14252 LIB_GCC="-lgcc_s"
14253 else
14254 ## FIXME? s/gnu-linux.h used to define LIB_GCC as below, then
14255 ## immediately undefine it again and redefine it to empty.
14256 ## Was the C_SWITCH_X_SITE part really necessary?
14257 ## LIB_GCC=`$CC $C_SWITCH_X_SITE -print-libgcc-file-name`
14258 LIB_GCC=
14262 ## Ask GCC where to find libgcc.a.
14263 *) LIB_GCC=`$CC -print-libgcc-file-name 2> /dev/null` ;;
14264 esac
14268 TOOLTIP_SUPPORT=
14269 WINDOW_SUPPORT=
14270 ## If we're using X11/GNUstep, define some consequences.
14271 if test "$HAVE_X_WINDOWS" = "yes" || test "$HAVE_NS" = "yes"; then
14273 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
14276 $as_echo "#define HAVE_MOUSE 1" >>confdefs.h
14278 MOUSE_SUPPORT="\$(REAL_MOUSE_SUPPORT)"
14279 TOOLTIP_SUPPORT="\${lispsource}mouse.elc"
14281 WINDOW_SUPPORT="\$(BASE_WINDOW_SUPPORT)"
14282 test "$HAVE_X_WINDOWS" = "yes" && \
14283 WINDOW_SUPPORT="$WINDOW_SUPPORT \$(X_WINDOW_SUPPORT)"
14293 #### Report on what we decided to do.
14294 #### Report GTK as a toolkit, even if it doesn't use Xt.
14295 #### It makes printing result more understandable as using GTK sets
14296 #### toolkit_scroll_bars to yes by default.
14297 if test "${HAVE_GTK}" = "yes"; then
14298 USE_X_TOOLKIT=GTK
14301 echo "
14302 Configured for \`${canonical}'.
14304 Where should the build process find the source code? ${srcdir}
14305 What operating system and machine description files should Emacs use?
14306 \`${opsysfile}' and \`${machfile}'
14307 What compiler should emacs be built with? ${CC} ${CFLAGS}
14308 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
14309 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
14310 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
14311 What window system should Emacs use? ${window_system}
14312 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
14314 if test -n "${x_includes}"; then
14315 echo " Where do we find X Windows header files? ${x_includes}"
14316 else
14317 echo " Where do we find X Windows header files? Standard dirs"
14319 if test -n "${x_libraries}"; then
14320 echo " Where do we find X Windows libraries? ${x_libraries}"
14321 else
14322 echo " Where do we find X Windows libraries? Standard dirs"
14325 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
14326 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
14327 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
14328 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
14329 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
14330 echo " Does Emacs use -lpng? ${HAVE_PNG}"
14331 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
14332 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
14333 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
14334 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
14335 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
14337 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
14338 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
14339 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
14340 echo " Does Emacs use -lxft? ${HAVE_XFT}"
14342 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
14343 echo
14345 if test $USE_XASSERTS = yes; then
14346 echo " Compiling with asserts turned on."
14347 CPPFLAGS="$CPPFLAGS -DXASSERTS=1"
14350 echo
14352 if test "$HAVE_NS" = "yes"; then
14353 echo
14354 echo "You must run \"make install\" in order to test the built application.
14355 The installed application will go to nextstep/Emacs.app and can be
14356 run or moved from there."
14357 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
14358 echo "The application will be fully self-contained."
14359 else
14360 echo "The lisp resources for the application will be installed under ${prefix}.
14361 You may need to run \"make install\" with sudo. The application will fail
14362 to run if these resources are not installed."
14364 echo
14367 if test "$HAVE_DBUS" = yes && test "${opsys}" != "gnu-linux"; then
14368 echo "D-Bus integration has been tested for GNU/Linux only."
14369 echo
14373 # Remove any trailing slashes in these variables.
14374 test "${prefix}" != NONE &&
14375 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
14376 test "${exec_prefix}" != NONE &&
14377 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
14379 ac_config_files="$ac_config_files 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"
14381 ac_config_commands="$ac_config_commands default"
14383 cat >confcache <<\_ACEOF
14384 # This file is a shell script that caches the results of configure
14385 # tests run on this system so they can be shared between configure
14386 # scripts and configure runs, see configure's option --config-cache.
14387 # It is not useful on other systems. If it contains results you don't
14388 # want to keep, you may remove or edit it.
14390 # config.status only pays attention to the cache file if you give it
14391 # the --recheck option to rerun configure.
14393 # `ac_cv_env_foo' variables (set or unset) will be overridden when
14394 # loading this file, other *unset* `ac_cv_foo' will be assigned the
14395 # following values.
14397 _ACEOF
14399 # The following way of writing the cache mishandles newlines in values,
14400 # but we know of no workaround that is simple, portable, and efficient.
14401 # So, we kill variables containing newlines.
14402 # Ultrix sh set writes to stderr and can't be redirected directly,
14403 # and sets the high bit in the cache file unless we assign to the vars.
14405 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
14406 eval ac_val=\$$ac_var
14407 case $ac_val in #(
14408 *${as_nl}*)
14409 case $ac_var in #(
14410 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
14411 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
14412 esac
14413 case $ac_var in #(
14414 _ | IFS | as_nl) ;; #(
14415 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
14416 *) { eval $ac_var=; unset $ac_var;} ;;
14417 esac ;;
14418 esac
14419 done
14421 (set) 2>&1 |
14422 case $as_nl`(ac_space=' '; set) 2>&1` in #(
14423 *${as_nl}ac_space=\ *)
14424 # `set' does not quote correctly, so add quotes: double-quote
14425 # substitution turns \\\\ into \\, and sed turns \\ into \.
14426 sed -n \
14427 "s/'/'\\\\''/g;
14428 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
14429 ;; #(
14431 # `set' quotes correctly as required by POSIX, so do not add quotes.
14432 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
14434 esac |
14435 sort
14437 sed '
14438 /^ac_cv_env_/b end
14439 t clear
14440 :clear
14441 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
14442 t end
14443 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
14444 :end' >>confcache
14445 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
14446 if test -w "$cache_file"; then
14447 test "x$cache_file" != "x/dev/null" &&
14448 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
14449 $as_echo "$as_me: updating cache $cache_file" >&6;}
14450 cat confcache >$cache_file
14451 else
14452 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
14453 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
14456 rm -f confcache
14458 test "x$prefix" = xNONE && prefix=$ac_default_prefix
14459 # Let make expand exec_prefix.
14460 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
14462 DEFS=-DHAVE_CONFIG_H
14464 ac_libobjs=
14465 ac_ltlibobjs=
14466 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
14467 # 1. Remove the extension, and $U if already installed.
14468 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
14469 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
14470 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
14471 # will be set to the directory where LIBOBJS objects are built.
14472 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
14473 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
14474 done
14475 LIBOBJS=$ac_libobjs
14477 LTLIBOBJS=$ac_ltlibobjs
14481 : ${CONFIG_STATUS=./config.status}
14482 ac_write_fail=0
14483 ac_clean_files_save=$ac_clean_files
14484 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
14485 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
14486 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
14487 as_write_fail=0
14488 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
14489 #! $SHELL
14490 # Generated by $as_me.
14491 # Run this file to recreate the current configuration.
14492 # Compiler output produced by configure, useful for debugging
14493 # configure, is in config.log if it exists.
14495 debug=false
14496 ac_cs_recheck=false
14497 ac_cs_silent=false
14499 SHELL=\${CONFIG_SHELL-$SHELL}
14500 export SHELL
14501 _ASEOF
14502 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
14503 ## -------------------- ##
14504 ## M4sh Initialization. ##
14505 ## -------------------- ##
14507 # Be more Bourne compatible
14508 DUALCASE=1; export DUALCASE # for MKS sh
14509 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
14510 emulate sh
14511 NULLCMD=:
14512 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
14513 # is contrary to our usage. Disable this feature.
14514 alias -g '${1+"$@"}'='"$@"'
14515 setopt NO_GLOB_SUBST
14516 else
14517 case `(set -o) 2>/dev/null` in #(
14518 *posix*) :
14519 set -o posix ;; #(
14520 *) :
14522 esac
14526 as_nl='
14528 export as_nl
14529 # Printing a long string crashes Solaris 7 /usr/bin/printf.
14530 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
14531 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
14532 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
14533 # Prefer a ksh shell builtin over an external printf program on Solaris,
14534 # but without wasting forks for bash or zsh.
14535 if test -z "$BASH_VERSION$ZSH_VERSION" \
14536 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
14537 as_echo='print -r --'
14538 as_echo_n='print -rn --'
14539 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
14540 as_echo='printf %s\n'
14541 as_echo_n='printf %s'
14542 else
14543 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
14544 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
14545 as_echo_n='/usr/ucb/echo -n'
14546 else
14547 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
14548 as_echo_n_body='eval
14549 arg=$1;
14550 case $arg in #(
14551 *"$as_nl"*)
14552 expr "X$arg" : "X\\(.*\\)$as_nl";
14553 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
14554 esac;
14555 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
14557 export as_echo_n_body
14558 as_echo_n='sh -c $as_echo_n_body as_echo'
14560 export as_echo_body
14561 as_echo='sh -c $as_echo_body as_echo'
14564 # The user is always right.
14565 if test "${PATH_SEPARATOR+set}" != set; then
14566 PATH_SEPARATOR=:
14567 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
14568 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
14569 PATH_SEPARATOR=';'
14574 # IFS
14575 # We need space, tab and new line, in precisely that order. Quoting is
14576 # there to prevent editors from complaining about space-tab.
14577 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
14578 # splitting by setting IFS to empty value.)
14579 IFS=" "" $as_nl"
14581 # Find who we are. Look in the path if we contain no directory separator.
14582 case $0 in #((
14583 *[\\/]* ) as_myself=$0 ;;
14584 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14585 for as_dir in $PATH
14587 IFS=$as_save_IFS
14588 test -z "$as_dir" && as_dir=.
14589 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
14590 done
14591 IFS=$as_save_IFS
14594 esac
14595 # We did not find ourselves, most probably we were run as `sh COMMAND'
14596 # in which case we are not to be found in the path.
14597 if test "x$as_myself" = x; then
14598 as_myself=$0
14600 if test ! -f "$as_myself"; then
14601 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
14602 exit 1
14605 # Unset variables that we do not need and which cause bugs (e.g. in
14606 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
14607 # suppresses any "Segmentation fault" message there. '((' could
14608 # trigger a bug in pdksh 5.2.14.
14609 for as_var in BASH_ENV ENV MAIL MAILPATH
14610 do eval test x\${$as_var+set} = xset \
14611 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
14612 done
14613 PS1='$ '
14614 PS2='> '
14615 PS4='+ '
14617 # NLS nuisances.
14618 LC_ALL=C
14619 export LC_ALL
14620 LANGUAGE=C
14621 export LANGUAGE
14623 # CDPATH.
14624 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
14627 # as_fn_error ERROR [LINENO LOG_FD]
14628 # ---------------------------------
14629 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
14630 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
14631 # script with status $?, using 1 if that was 0.
14632 as_fn_error ()
14634 as_status=$?; test $as_status -eq 0 && as_status=1
14635 if test "$3"; then
14636 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
14637 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
14639 $as_echo "$as_me: error: $1" >&2
14640 as_fn_exit $as_status
14641 } # as_fn_error
14644 # as_fn_set_status STATUS
14645 # -----------------------
14646 # Set $? to STATUS, without forking.
14647 as_fn_set_status ()
14649 return $1
14650 } # as_fn_set_status
14652 # as_fn_exit STATUS
14653 # -----------------
14654 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
14655 as_fn_exit ()
14657 set +e
14658 as_fn_set_status $1
14659 exit $1
14660 } # as_fn_exit
14662 # as_fn_unset VAR
14663 # ---------------
14664 # Portably unset VAR.
14665 as_fn_unset ()
14667 { eval $1=; unset $1;}
14669 as_unset=as_fn_unset
14670 # as_fn_append VAR VALUE
14671 # ----------------------
14672 # Append the text in VALUE to the end of the definition contained in VAR. Take
14673 # advantage of any shell optimizations that allow amortized linear growth over
14674 # repeated appends, instead of the typical quadratic growth present in naive
14675 # implementations.
14676 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
14677 eval 'as_fn_append ()
14679 eval $1+=\$2
14681 else
14682 as_fn_append ()
14684 eval $1=\$$1\$2
14686 fi # as_fn_append
14688 # as_fn_arith ARG...
14689 # ------------------
14690 # Perform arithmetic evaluation on the ARGs, and store the result in the
14691 # global $as_val. Take advantage of shells that can avoid forks. The arguments
14692 # must be portable across $(()) and expr.
14693 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
14694 eval 'as_fn_arith ()
14696 as_val=$(( $* ))
14698 else
14699 as_fn_arith ()
14701 as_val=`expr "$@" || test $? -eq 1`
14703 fi # as_fn_arith
14706 if expr a : '\(a\)' >/dev/null 2>&1 &&
14707 test "X`expr 00001 : '.*\(...\)'`" = X001; then
14708 as_expr=expr
14709 else
14710 as_expr=false
14713 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
14714 as_basename=basename
14715 else
14716 as_basename=false
14719 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
14720 as_dirname=dirname
14721 else
14722 as_dirname=false
14725 as_me=`$as_basename -- "$0" ||
14726 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
14727 X"$0" : 'X\(//\)$' \| \
14728 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
14729 $as_echo X/"$0" |
14730 sed '/^.*\/\([^/][^/]*\)\/*$/{
14731 s//\1/
14734 /^X\/\(\/\/\)$/{
14735 s//\1/
14738 /^X\/\(\/\).*/{
14739 s//\1/
14742 s/.*/./; q'`
14744 # Avoid depending upon Character Ranges.
14745 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
14746 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
14747 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
14748 as_cr_digits='0123456789'
14749 as_cr_alnum=$as_cr_Letters$as_cr_digits
14751 ECHO_C= ECHO_N= ECHO_T=
14752 case `echo -n x` in #(((((
14753 -n*)
14754 case `echo 'xy\c'` in
14755 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
14756 xy) ECHO_C='\c';;
14757 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
14758 ECHO_T=' ';;
14759 esac;;
14761 ECHO_N='-n';;
14762 esac
14764 rm -f conf$$ conf$$.exe conf$$.file
14765 if test -d conf$$.dir; then
14766 rm -f conf$$.dir/conf$$.file
14767 else
14768 rm -f conf$$.dir
14769 mkdir conf$$.dir 2>/dev/null
14771 if (echo >conf$$.file) 2>/dev/null; then
14772 if ln -s conf$$.file conf$$ 2>/dev/null; then
14773 as_ln_s='ln -s'
14774 # ... but there are two gotchas:
14775 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
14776 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
14777 # In both cases, we have to default to `cp -p'.
14778 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
14779 as_ln_s='cp -p'
14780 elif ln conf$$.file conf$$ 2>/dev/null; then
14781 as_ln_s=ln
14782 else
14783 as_ln_s='cp -p'
14785 else
14786 as_ln_s='cp -p'
14788 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
14789 rmdir conf$$.dir 2>/dev/null
14792 # as_fn_mkdir_p
14793 # -------------
14794 # Create "$as_dir" as a directory, including parents if necessary.
14795 as_fn_mkdir_p ()
14798 case $as_dir in #(
14799 -*) as_dir=./$as_dir;;
14800 esac
14801 test -d "$as_dir" || eval $as_mkdir_p || {
14802 as_dirs=
14803 while :; do
14804 case $as_dir in #(
14805 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
14806 *) as_qdir=$as_dir;;
14807 esac
14808 as_dirs="'$as_qdir' $as_dirs"
14809 as_dir=`$as_dirname -- "$as_dir" ||
14810 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
14811 X"$as_dir" : 'X\(//\)[^/]' \| \
14812 X"$as_dir" : 'X\(//\)$' \| \
14813 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
14814 $as_echo X"$as_dir" |
14815 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
14816 s//\1/
14819 /^X\(\/\/\)[^/].*/{
14820 s//\1/
14823 /^X\(\/\/\)$/{
14824 s//\1/
14827 /^X\(\/\).*/{
14828 s//\1/
14831 s/.*/./; q'`
14832 test -d "$as_dir" && break
14833 done
14834 test -z "$as_dirs" || eval "mkdir $as_dirs"
14835 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
14838 } # as_fn_mkdir_p
14839 if mkdir -p . 2>/dev/null; then
14840 as_mkdir_p='mkdir -p "$as_dir"'
14841 else
14842 test -d ./-p && rmdir ./-p
14843 as_mkdir_p=false
14846 if test -x / >/dev/null 2>&1; then
14847 as_test_x='test -x'
14848 else
14849 if ls -dL / >/dev/null 2>&1; then
14850 as_ls_L_option=L
14851 else
14852 as_ls_L_option=
14854 as_test_x='
14855 eval sh -c '\''
14856 if test -d "$1"; then
14857 test -d "$1/.";
14858 else
14859 case $1 in #(
14860 -*)set "./$1";;
14861 esac;
14862 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
14863 ???[sx]*):;;*)false;;esac;fi
14864 '\'' sh
14867 as_executable_p=$as_test_x
14869 # Sed expression to map a string onto a valid CPP name.
14870 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
14872 # Sed expression to map a string onto a valid variable name.
14873 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
14876 exec 6>&1
14877 ## ----------------------------------- ##
14878 ## Main body of $CONFIG_STATUS script. ##
14879 ## ----------------------------------- ##
14880 _ASEOF
14881 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
14883 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
14884 # Save the log message, to keep $0 and so on meaningful, and to
14885 # report actual input values of CONFIG_FILES etc. instead of their
14886 # values after options handling.
14887 ac_log="
14888 This file was extended by emacs $as_me 24.0.50, which was
14889 generated by GNU Autoconf 2.65. Invocation command line was
14891 CONFIG_FILES = $CONFIG_FILES
14892 CONFIG_HEADERS = $CONFIG_HEADERS
14893 CONFIG_LINKS = $CONFIG_LINKS
14894 CONFIG_COMMANDS = $CONFIG_COMMANDS
14895 $ $0 $@
14897 on `(hostname || uname -n) 2>/dev/null | sed 1q`
14900 _ACEOF
14902 case $ac_config_files in *"
14903 "*) set x $ac_config_files; shift; ac_config_files=$*;;
14904 esac
14906 case $ac_config_headers in *"
14907 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
14908 esac
14911 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
14912 # Files that config.status was made for.
14913 config_files="$ac_config_files"
14914 config_headers="$ac_config_headers"
14915 config_commands="$ac_config_commands"
14917 _ACEOF
14919 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
14920 ac_cs_usage="\
14921 \`$as_me' instantiates files and other configuration actions
14922 from templates according to the current configuration. Unless the files
14923 and actions are specified as TAGs, all are instantiated by default.
14925 Usage: $0 [OPTION]... [TAG]...
14927 -h, --help print this help, then exit
14928 -V, --version print version number and configuration settings, then exit
14929 --config print configuration, then exit
14930 -q, --quiet, --silent
14931 do not print progress messages
14932 -d, --debug don't remove temporary files
14933 --recheck update $as_me by reconfiguring in the same conditions
14934 --file=FILE[:TEMPLATE]
14935 instantiate the configuration file FILE
14936 --header=FILE[:TEMPLATE]
14937 instantiate the configuration header FILE
14939 Configuration files:
14940 $config_files
14942 Configuration headers:
14943 $config_headers
14945 Configuration commands:
14946 $config_commands
14948 Report bugs to the package provider."
14950 _ACEOF
14951 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
14952 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
14953 ac_cs_version="\\
14954 emacs config.status 24.0.50
14955 configured by $0, generated by GNU Autoconf 2.65,
14956 with options \\"\$ac_cs_config\\"
14958 Copyright (C) 2009 Free Software Foundation, Inc.
14959 This config.status script is free software; the Free Software Foundation
14960 gives unlimited permission to copy, distribute and modify it."
14962 ac_pwd='$ac_pwd'
14963 srcdir='$srcdir'
14964 INSTALL='$INSTALL'
14965 test -n "\$AWK" || AWK=awk
14966 _ACEOF
14968 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
14969 # The default lists apply if the user does not specify any file.
14970 ac_need_defaults=:
14971 while test $# != 0
14973 case $1 in
14974 --*=*)
14975 ac_option=`expr "X$1" : 'X\([^=]*\)='`
14976 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
14977 ac_shift=:
14980 ac_option=$1
14981 ac_optarg=$2
14982 ac_shift=shift
14984 esac
14986 case $ac_option in
14987 # Handling of the options.
14988 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
14989 ac_cs_recheck=: ;;
14990 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
14991 $as_echo "$ac_cs_version"; exit ;;
14992 --config | --confi | --conf | --con | --co | --c )
14993 $as_echo "$ac_cs_config"; exit ;;
14994 --debug | --debu | --deb | --de | --d | -d )
14995 debug=: ;;
14996 --file | --fil | --fi | --f )
14997 $ac_shift
14998 case $ac_optarg in
14999 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
15000 esac
15001 as_fn_append CONFIG_FILES " '$ac_optarg'"
15002 ac_need_defaults=false;;
15003 --header | --heade | --head | --hea )
15004 $ac_shift
15005 case $ac_optarg in
15006 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
15007 esac
15008 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
15009 ac_need_defaults=false;;
15010 --he | --h)
15011 # Conflict between --help and --header
15012 as_fn_error "ambiguous option: \`$1'
15013 Try \`$0 --help' for more information.";;
15014 --help | --hel | -h )
15015 $as_echo "$ac_cs_usage"; exit ;;
15016 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
15017 | -silent | --silent | --silen | --sile | --sil | --si | --s)
15018 ac_cs_silent=: ;;
15020 # This is an error.
15021 -*) as_fn_error "unrecognized option: \`$1'
15022 Try \`$0 --help' for more information." ;;
15024 *) as_fn_append ac_config_targets " $1"
15025 ac_need_defaults=false ;;
15027 esac
15028 shift
15029 done
15031 ac_configure_extra_args=
15033 if $ac_cs_silent; then
15034 exec 6>/dev/null
15035 ac_configure_extra_args="$ac_configure_extra_args --silent"
15038 _ACEOF
15039 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15040 if \$ac_cs_recheck; then
15041 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
15042 shift
15043 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
15044 CONFIG_SHELL='$SHELL'
15045 export CONFIG_SHELL
15046 exec "\$@"
15049 _ACEOF
15050 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15051 exec 5>>config.log
15053 echo
15054 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
15055 ## Running $as_me. ##
15056 _ASBOX
15057 $as_echo "$ac_log"
15058 } >&5
15060 _ACEOF
15061 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15063 # INIT-COMMANDS
15065 GCC="$GCC" NON_GNU_CPP="$NON_GNU_CPP" CPP="$CPP" CPPFLAGS="$CPPFLAGS"
15067 _ACEOF
15069 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15071 # Handling of arguments.
15072 for ac_config_target in $ac_config_targets
15074 case $ac_config_target in
15075 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
15076 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
15077 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
15078 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
15079 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
15080 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
15081 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
15082 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
15083 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
15084 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
15085 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
15086 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
15087 "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
15089 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
15090 esac
15091 done
15094 # If the user did not use the arguments to specify the items to instantiate,
15095 # then the envvar interface is used. Set only those that are not.
15096 # We use the long form for the default assignment because of an extremely
15097 # bizarre bug on SunOS 4.1.3.
15098 if $ac_need_defaults; then
15099 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
15100 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
15101 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
15104 # Have a temporary directory for convenience. Make it in the build tree
15105 # simply because there is no reason against having it here, and in addition,
15106 # creating and moving files from /tmp can sometimes cause problems.
15107 # Hook for its removal unless debugging.
15108 # Note that there is a small window in which the directory will not be cleaned:
15109 # after its creation but before its name has been assigned to `$tmp'.
15110 $debug ||
15112 tmp=
15113 trap 'exit_status=$?
15114 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
15116 trap 'as_fn_exit 1' 1 2 13 15
15118 # Create a (secure) tmp directory for tmp files.
15121 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
15122 test -n "$tmp" && test -d "$tmp"
15123 } ||
15125 tmp=./conf$$-$RANDOM
15126 (umask 077 && mkdir "$tmp")
15127 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
15129 # Set up the scripts for CONFIG_FILES section.
15130 # No need to generate them if there are no CONFIG_FILES.
15131 # This happens for instance with `./config.status config.h'.
15132 if test -n "$CONFIG_FILES"; then
15134 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
15135 ac_cs_awk_getline=:
15136 ac_cs_awk_pipe_init=
15137 ac_cs_awk_read_file='
15138 while ((getline aline < (F[key])) > 0)
15139 print(aline)
15140 close(F[key])'
15141 ac_cs_awk_pipe_fini=
15142 else
15143 ac_cs_awk_getline=false
15144 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
15145 ac_cs_awk_read_file='
15146 print "|#_!!_#|"
15147 print "cat " F[key] " &&"
15148 '$ac_cs_awk_pipe_init
15149 # The final `:' finishes the AND list.
15150 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
15152 ac_cr=`echo X | tr X '\015'`
15153 # On cygwin, bash can eat \r inside `` if the user requested igncr.
15154 # But we know of no other shell where ac_cr would be empty at this
15155 # point, so we can use a bashism as a fallback.
15156 if test "x$ac_cr" = x; then
15157 eval ac_cr=\$\'\\r\'
15159 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
15160 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
15161 ac_cs_awk_cr='\r'
15162 else
15163 ac_cs_awk_cr=$ac_cr
15166 echo 'BEGIN {' >"$tmp/subs1.awk" &&
15167 _ACEOF
15169 # Create commands to substitute file output variables.
15171 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
15172 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
15173 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
15174 echo "_ACAWK" &&
15175 echo "_ACEOF"
15176 } >conf$$files.sh &&
15177 . ./conf$$files.sh ||
15178 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
15179 rm -f conf$$files.sh
15182 echo "cat >conf$$subs.awk <<_ACEOF" &&
15183 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
15184 echo "_ACEOF"
15185 } >conf$$subs.sh ||
15186 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
15187 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
15188 ac_delim='%!_!# '
15189 for ac_last_try in false false false false false :; do
15190 . ./conf$$subs.sh ||
15191 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
15193 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
15194 if test $ac_delim_n = $ac_delim_num; then
15195 break
15196 elif $ac_last_try; then
15197 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
15198 else
15199 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
15201 done
15202 rm -f conf$$subs.sh
15204 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15205 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
15206 _ACEOF
15207 sed -n '
15209 s/^/S["/; s/!.*/"]=/
15212 s/^[^!]*!//
15213 :repl
15214 t repl
15215 s/'"$ac_delim"'$//
15216 t delim
15219 s/\(.\{148\}\)..*/\1/
15220 t more1
15221 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
15224 b repl
15225 :more1
15226 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
15229 s/.\{148\}//
15230 t nl
15231 :delim
15233 s/\(.\{148\}\)..*/\1/
15234 t more2
15235 s/["\\]/\\&/g; s/^/"/; s/$/"/
15238 :more2
15239 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
15242 s/.\{148\}//
15243 t delim
15244 ' <conf$$subs.awk | sed '
15245 /^[^""]/{
15247 s/\n//
15249 ' >>$CONFIG_STATUS || ac_write_fail=1
15250 rm -f conf$$subs.awk
15251 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15252 _ACAWK
15253 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
15254 for (key in S) S_is_set[key] = 1
15255 FS = "\a"
15256 \$ac_cs_awk_pipe_init
15259 line = $ 0
15260 nfields = split(line, field, "@")
15261 substed = 0
15262 len = length(field[1])
15263 for (i = 2; i < nfields; i++) {
15264 key = field[i]
15265 keylen = length(key)
15266 if (S_is_set[key]) {
15267 value = S[key]
15268 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
15269 len += length(value) + length(field[++i])
15270 substed = 1
15271 } else
15272 len += 1 + keylen
15274 if (nfields == 3 && !substed) {
15275 key = field[2]
15276 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
15277 \$ac_cs_awk_read_file
15278 next
15281 print line
15283 \$ac_cs_awk_pipe_fini
15284 _ACAWK
15285 _ACEOF
15286 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15287 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
15288 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
15289 else
15291 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
15292 || as_fn_error "could not setup config files machinery" "$LINENO" 5
15293 _ACEOF
15295 # VPATH may cause trouble with some makes, so we remove $(srcdir),
15296 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
15297 # trailing colons and then remove the whole line if VPATH becomes empty
15298 # (actually we leave an empty line to preserve line numbers).
15299 if test "x$srcdir" = x.; then
15300 ac_vpsub='/^[ ]*VPATH[ ]*=/{
15301 s/:*\$(srcdir):*/:/
15302 s/:*\${srcdir}:*/:/
15303 s/:*@srcdir@:*/:/
15304 s/^\([^=]*=[ ]*\):*/\1/
15305 s/:*$//
15306 s/^[^=]*=[ ]*$//
15310 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15311 fi # test -n "$CONFIG_FILES"
15313 # Set up the scripts for CONFIG_HEADERS section.
15314 # No need to generate them if there are no CONFIG_HEADERS.
15315 # This happens for instance with `./config.status Makefile'.
15316 if test -n "$CONFIG_HEADERS"; then
15317 cat >"$tmp/defines.awk" <<\_ACAWK ||
15318 BEGIN {
15319 _ACEOF
15321 # Transform confdefs.h into an awk script `defines.awk', embedded as
15322 # here-document in config.status, that substitutes the proper values into
15323 # config.h.in to produce config.h.
15325 # Create a delimiter string that does not exist in confdefs.h, to ease
15326 # handling of long lines.
15327 ac_delim='%!_!# '
15328 for ac_last_try in false false :; do
15329 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
15330 if test -z "$ac_t"; then
15331 break
15332 elif $ac_last_try; then
15333 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
15334 else
15335 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
15337 done
15339 # For the awk script, D is an array of macro values keyed by name,
15340 # likewise P contains macro parameters if any. Preserve backslash
15341 # newline sequences.
15343 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
15344 sed -n '
15345 s/.\{148\}/&'"$ac_delim"'/g
15346 t rset
15347 :rset
15348 s/^[ ]*#[ ]*define[ ][ ]*/ /
15349 t def
15351 :def
15352 s/\\$//
15353 t bsnl
15354 s/["\\]/\\&/g
15355 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
15356 D["\1"]=" \3"/p
15357 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
15359 :bsnl
15360 s/["\\]/\\&/g
15361 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
15362 D["\1"]=" \3\\\\\\n"\\/p
15363 t cont
15364 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
15365 t cont
15367 :cont
15369 s/.\{148\}/&'"$ac_delim"'/g
15370 t clear
15371 :clear
15372 s/\\$//
15373 t bsnlc
15374 s/["\\]/\\&/g; s/^/"/; s/$/"/p
15376 :bsnlc
15377 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
15378 b cont
15379 ' <confdefs.h | sed '
15380 s/'"$ac_delim"'/"\\\
15381 "/g' >>$CONFIG_STATUS || ac_write_fail=1
15383 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15384 for (key in D) D_is_set[key] = 1
15385 FS = "\a"
15387 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
15388 line = \$ 0
15389 split(line, arg, " ")
15390 if (arg[1] == "#") {
15391 defundef = arg[2]
15392 mac1 = arg[3]
15393 } else {
15394 defundef = substr(arg[1], 2)
15395 mac1 = arg[2]
15397 split(mac1, mac2, "(") #)
15398 macro = mac2[1]
15399 prefix = substr(line, 1, index(line, defundef) - 1)
15400 if (D_is_set[macro]) {
15401 # Preserve the white space surrounding the "#".
15402 print prefix "define", macro P[macro] D[macro]
15403 next
15404 } else {
15405 # Replace #undef with comments. This is necessary, for example,
15406 # in the case of _POSIX_SOURCE, which is predefined and required
15407 # on some systems where configure will not decide to define it.
15408 if (defundef == "undef") {
15409 print "/*", prefix defundef, macro, "*/"
15410 next
15414 { print }
15415 _ACAWK
15416 _ACEOF
15417 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15418 as_fn_error "could not setup config headers machinery" "$LINENO" 5
15419 fi # test -n "$CONFIG_HEADERS"
15422 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
15423 shift
15424 for ac_tag
15426 case $ac_tag in
15427 :[FHLC]) ac_mode=$ac_tag; continue;;
15428 esac
15429 case $ac_mode$ac_tag in
15430 :[FHL]*:*);;
15431 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
15432 :[FH]-) ac_tag=-:-;;
15433 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
15434 esac
15435 ac_save_IFS=$IFS
15436 IFS=:
15437 set x $ac_tag
15438 IFS=$ac_save_IFS
15439 shift
15440 ac_file=$1
15441 shift
15443 case $ac_mode in
15444 :L) ac_source=$1;;
15445 :[FH])
15446 ac_file_inputs=
15447 for ac_f
15449 case $ac_f in
15450 -) ac_f="$tmp/stdin";;
15451 *) # Look for the file first in the build tree, then in the source tree
15452 # (if the path is not absolute). The absolute path cannot be DOS-style,
15453 # because $ac_f cannot contain `:'.
15454 test -f "$ac_f" ||
15455 case $ac_f in
15456 [\\/$]*) false;;
15457 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
15458 esac ||
15459 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
15460 esac
15461 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
15462 as_fn_append ac_file_inputs " '$ac_f'"
15463 done
15465 # Let's still pretend it is `configure' which instantiates (i.e., don't
15466 # use $as_me), people would be surprised to read:
15467 # /* config.h. Generated by config.status. */
15468 configure_input='Generated from '`
15469 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
15470 `' by configure.'
15471 if test x"$ac_file" != x-; then
15472 configure_input="$ac_file. $configure_input"
15473 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
15474 $as_echo "$as_me: creating $ac_file" >&6;}
15476 # Neutralize special characters interpreted by sed in replacement strings.
15477 case $configure_input in #(
15478 *\&* | *\|* | *\\* )
15479 ac_sed_conf_input=`$as_echo "$configure_input" |
15480 sed 's/[\\\\&|]/\\\\&/g'`;; #(
15481 *) ac_sed_conf_input=$configure_input;;
15482 esac
15484 case $ac_tag in
15485 *:-:* | *:-) cat >"$tmp/stdin" \
15486 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
15487 esac
15489 esac
15491 ac_dir=`$as_dirname -- "$ac_file" ||
15492 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15493 X"$ac_file" : 'X\(//\)[^/]' \| \
15494 X"$ac_file" : 'X\(//\)$' \| \
15495 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
15496 $as_echo X"$ac_file" |
15497 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
15498 s//\1/
15501 /^X\(\/\/\)[^/].*/{
15502 s//\1/
15505 /^X\(\/\/\)$/{
15506 s//\1/
15509 /^X\(\/\).*/{
15510 s//\1/
15513 s/.*/./; q'`
15514 as_dir="$ac_dir"; as_fn_mkdir_p
15515 ac_builddir=.
15517 case "$ac_dir" in
15518 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
15520 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
15521 # A ".." for each directory in $ac_dir_suffix.
15522 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
15523 case $ac_top_builddir_sub in
15524 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
15525 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
15526 esac ;;
15527 esac
15528 ac_abs_top_builddir=$ac_pwd
15529 ac_abs_builddir=$ac_pwd$ac_dir_suffix
15530 # for backward compatibility:
15531 ac_top_builddir=$ac_top_build_prefix
15533 case $srcdir in
15534 .) # We are building in place.
15535 ac_srcdir=.
15536 ac_top_srcdir=$ac_top_builddir_sub
15537 ac_abs_top_srcdir=$ac_pwd ;;
15538 [\\/]* | ?:[\\/]* ) # Absolute name.
15539 ac_srcdir=$srcdir$ac_dir_suffix;
15540 ac_top_srcdir=$srcdir
15541 ac_abs_top_srcdir=$srcdir ;;
15542 *) # Relative name.
15543 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
15544 ac_top_srcdir=$ac_top_build_prefix$srcdir
15545 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
15546 esac
15547 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
15550 case $ac_mode in
15553 # CONFIG_FILE
15556 case $INSTALL in
15557 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
15558 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
15559 esac
15560 _ACEOF
15562 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15563 # If the template does not know about datarootdir, expand it.
15564 # FIXME: This hack should be removed a few years after 2.60.
15565 ac_datarootdir_hack=; ac_datarootdir_seen=
15566 ac_sed_dataroot='
15567 /datarootdir/ {
15571 /@datadir@/p
15572 /@docdir@/p
15573 /@infodir@/p
15574 /@localedir@/p
15575 /@mandir@/p'
15576 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
15577 *datarootdir*) ac_datarootdir_seen=yes;;
15578 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
15579 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
15580 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
15581 _ACEOF
15582 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15583 ac_datarootdir_hack='
15584 s&@datadir@&$datadir&g
15585 s&@docdir@&$docdir&g
15586 s&@infodir@&$infodir&g
15587 s&@localedir@&$localedir&g
15588 s&@mandir@&$mandir&g
15589 s&\\\${datarootdir}&$datarootdir&g' ;;
15590 esac
15591 _ACEOF
15593 # Neutralize VPATH when `$srcdir' = `.'.
15594 # Shell code in configure.ac might set extrasub.
15595 # FIXME: do we really want to maintain this feature?
15596 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15597 ac_sed_extra="$ac_vpsub
15598 $extrasub
15599 _ACEOF
15600 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15602 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
15603 s|@configure_input@|$ac_sed_conf_input|;t t
15604 s&@top_builddir@&$ac_top_builddir_sub&;t t
15605 s&@top_build_prefix@&$ac_top_build_prefix&;t t
15606 s&@srcdir@&$ac_srcdir&;t t
15607 s&@abs_srcdir@&$ac_abs_srcdir&;t t
15608 s&@top_srcdir@&$ac_top_srcdir&;t t
15609 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
15610 s&@builddir@&$ac_builddir&;t t
15611 s&@abs_builddir@&$ac_abs_builddir&;t t
15612 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
15613 s&@INSTALL@&$ac_INSTALL&;t t
15614 $ac_datarootdir_hack
15616 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
15617 if $ac_cs_awk_getline; then
15618 $AWK -f "$tmp/subs.awk"
15619 else
15620 $AWK -f "$tmp/subs.awk" | $SHELL
15621 fi >$tmp/out \
15622 || as_fn_error "could not create $ac_file" "$LINENO" 5
15624 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
15625 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
15626 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
15627 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
15628 which seems to be undefined. Please make sure it is defined." >&5
15629 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
15630 which seems to be undefined. Please make sure it is defined." >&2;}
15632 rm -f "$tmp/stdin"
15633 case $ac_file in
15634 -) cat "$tmp/out" && rm -f "$tmp/out";;
15635 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
15636 esac \
15637 || as_fn_error "could not create $ac_file" "$LINENO" 5
15641 # CONFIG_HEADER
15643 if test x"$ac_file" != x-; then
15645 $as_echo "/* $configure_input */" \
15646 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
15647 } >"$tmp/config.h" \
15648 || as_fn_error "could not create $ac_file" "$LINENO" 5
15649 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
15650 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
15651 $as_echo "$as_me: $ac_file is unchanged" >&6;}
15652 else
15653 rm -f "$ac_file"
15654 mv "$tmp/config.h" "$ac_file" \
15655 || as_fn_error "could not create $ac_file" "$LINENO" 5
15657 else
15658 $as_echo "/* $configure_input */" \
15659 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
15660 || as_fn_error "could not create -" "$LINENO" 5
15664 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
15665 $as_echo "$as_me: executing $ac_file commands" >&6;}
15667 esac
15670 case $ac_file$ac_mode in
15671 "default":C)
15673 ### Make the necessary directories, if they don't exist.
15674 for dir in etc lisp ; do
15675 test -d ${dir} || mkdir ${dir}
15676 done
15678 echo creating src/epaths.h
15679 ${MAKE-make} epaths-force
15681 if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
15682 echo creating src/.gdbinit
15683 echo source $srcdir/src/.gdbinit > src/.gdbinit
15688 esac
15689 done # for ac_tag
15692 as_fn_exit 0
15693 _ACEOF
15694 ac_clean_files=$ac_clean_files_save
15696 test $ac_write_fail = 0 ||
15697 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
15700 # configure is writing to config.log, and then calls config.status.
15701 # config.status does its own redirection, appending to config.log.
15702 # Unfortunately, on DOS this fails, as config.log is still kept open
15703 # by configure, so config.status won't be able to write to it; its
15704 # output is simply discarded. So we exec the FD to /dev/null,
15705 # effectively closing config.log, so it can be properly (re)opened and
15706 # appended to by config.status. When coming back to configure, we
15707 # need to make the FD available again.
15708 if test "$no_create" != yes; then
15709 ac_cs_success=:
15710 ac_config_status_args=
15711 test "$silent" = yes &&
15712 ac_config_status_args="$ac_config_status_args --quiet"
15713 exec 5>/dev/null
15714 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
15715 exec 5>>config.log
15716 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
15717 # would make configure fail if this is the last instruction.
15718 $ac_cs_success || as_fn_exit $?
15720 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
15721 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
15722 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}