Merge from trunk
[emacs.git] / configure
blobf283e8402901609522877a266d191c5e92f0e773
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 POST_EDIT_LDFLAGS
604 PRE_EDIT_LDFLAGS
605 LD_SWITCH_SYSTEM_TEMACS
606 POST_ALLOC_OBJ
607 PRE_ALLOC_OBJ
608 CYGWIN_OBJ
609 RALLOC_OBJ
610 OLDXMENU_DEPS
611 LIBX_OTHER
612 LIBXMENU
613 OLDXMENU
614 OLDXMENU_TARGET
615 LIBXT_OTHER
616 TOOLKIT_LIBW
617 WIDGET_OBJ
618 XOBJ
619 XMENU_OBJ
620 FONT_OBJ
621 OTHER_FILES
622 GNU_OBJC_CFLAGS
623 ns_appsrc
624 ns_appresdir
625 ns_appbindir
626 ns_appdir
627 opsysfile
628 machfile
629 X_TOOLKIT_TYPE
630 C_SWITCH_X_SYSTEM
631 C_SWITCH_X_SITE
632 LD_SWITCH_X_SITE
633 gameuser
634 gamedir
635 bitmapdir
636 archlibdir
637 etcdir
638 x_default_search_path
639 lisppath
640 locallisppath
641 lispdir
642 srcdir
643 canonical
644 configuration
645 version
646 KRB4LIB
647 DESLIB
648 KRB5LIB
649 CRYPTOLIB
650 COM_ERRLIB
651 LIBRESOLV
652 LIBHESIOD
653 TERMCAP_OBJ
654 LIBS_TERMCAP
655 GETOPTOBJS
656 GETOPT_H
657 GETLOADAVG_LIBS
658 KMEM_GROUP
659 NEED_SETGID
660 LIBOBJS
661 BLESSMAIL_TARGET
662 LIBS_MAIL
663 liblockfile
664 ALLOCA
665 LIBXSM
666 LIBGPM
667 LIBGIF
668 LIBTIFF
669 LIBPNG
670 LIBJPEG
671 LIBXPM
672 FREETYPE_LIBS
673 FREETYPE_CFLAGS
674 M17N_FLT_LIBS
675 M17N_FLT_CFLAGS
676 LIBOTF_LIBS
677 LIBOTF_CFLAGS
678 XFT_LIBS
679 XFT_CFLAGS
680 FONTCONFIG_LIBS
681 FONTCONFIG_CFLAGS
682 LIBXMU
683 LIBXTR6
684 LIBSELINUX_LIBS
685 GCONF_LIBS
686 GCONF_CFLAGS
687 DBUS_OBJ
688 DBUS_LIBS
689 DBUS_CFLAGS
690 GTK_OBJ
691 GTK_LIBS
692 GTK_CFLAGS
693 RSVG_LIBS
694 RSVG_CFLAGS
695 VMLIMIT_OBJ
696 GMALLOC_OBJ
697 HAVE_XSERVER
698 LIB_STANDARD
699 NS_SUPPORT
700 NS_OBJ
701 TEMACS_LDFLAGS2
702 LD_SWITCH_X_SITE_AUX_RPATH
703 LD_SWITCH_X_SITE_AUX
704 XMKMF
705 DEPFLAGS
706 MKDEPDIR
707 SET_MAKE
708 CFLAGS_SOUND
709 ALSA_LIBS
710 ALSA_CFLAGS
711 PKG_CONFIG
712 LIBSOUND
713 START_FILES
714 LIB_MATH
715 CRT_DIR
716 LIBS_SYSTEM
717 C_SWITCH_SYSTEM
718 UNEXEC_OBJ
719 C_SWITCH_MACHINE
720 LD_SWITCH_SYSTEM
721 cannot_dump
722 MAKEINFO
723 GZIP_PROG
724 INSTALL_INFO
725 RANLIB
726 INSTALL_DATA
727 INSTALL_SCRIPT
728 INSTALL_PROGRAM
729 EGREP
730 GREP
732 OBJEXT
733 EXEEXT
734 ac_ct_CC
735 CPPFLAGS
736 LDFLAGS
737 CFLAGS
739 host_os
740 host_vendor
741 host_cpu
742 host
743 build_os
744 build_vendor
745 build_cpu
746 build
747 MAINT
748 GZIP_INFO
749 target_alias
750 host_alias
751 build_alias
752 LIBS
753 ECHO_T
754 ECHO_N
755 ECHO_C
756 DEFS
757 mandir
758 localedir
759 libdir
760 psdir
761 pdfdir
762 dvidir
763 htmldir
764 infodir
765 docdir
766 oldincludedir
767 includedir
768 localstatedir
769 sharedstatedir
770 sysconfdir
771 datadir
772 datarootdir
773 libexecdir
774 sbindir
775 bindir
776 program_transform_name
777 prefix
778 exec_prefix
779 PACKAGE_URL
780 PACKAGE_BUGREPORT
781 PACKAGE_STRING
782 PACKAGE_VERSION
783 PACKAGE_TARNAME
784 PACKAGE_NAME
785 PATH_SEPARATOR
786 SHELL'
787 ac_subst_files='deps_frag
788 ns_frag'
789 ac_user_opts='
790 enable_option_checking
791 with_pop
792 with_kerberos
793 with_kerberos5
794 with_hesiod
795 with_mmdf
796 with_mail_unlink
797 with_mailhost
798 with_sound
799 with_sync_input
800 with_x_toolkit
801 with_xpm
802 with_jpeg
803 with_tiff
804 with_gif
805 with_png
806 with_rsvg
807 with_xft
808 with_libotf
809 with_m17n_flt
810 with_toolkit_scroll_bars
811 with_xaw3d
812 with_xim
813 with_ns
814 with_gpm
815 with_dbus
816 with_gconf
817 with_selinux
818 with_makeinfo
819 with_compress_info
820 with_pkg_config_prog
821 with_crt_dir
822 with_gnustep_conf
823 enable_ns_self_contained
824 enable_asserts
825 enable_maintainer_mode
826 enable_locallisppath
827 enable_checking
828 enable_profiling
829 enable_autodepend
830 enable_largefile
831 with_x
833 ac_precious_vars='build_alias
834 host_alias
835 target_alias
837 CFLAGS
838 LDFLAGS
839 LIBS
840 CPPFLAGS
842 XMKMF'
845 # Initialize some variables set by options.
846 ac_init_help=
847 ac_init_version=false
848 ac_unrecognized_opts=
849 ac_unrecognized_sep=
850 # The variables have the same names as the options, with
851 # dashes changed to underlines.
852 cache_file=/dev/null
853 exec_prefix=NONE
854 no_create=
855 no_recursion=
856 prefix=NONE
857 program_prefix=NONE
858 program_suffix=NONE
859 program_transform_name=s,x,x,
860 silent=
861 site=
862 srcdir=
863 verbose=
864 x_includes=NONE
865 x_libraries=NONE
867 # Installation directory options.
868 # These are left unexpanded so users can "make install exec_prefix=/foo"
869 # and all the variables that are supposed to be based on exec_prefix
870 # by default will actually change.
871 # Use braces instead of parens because sh, perl, etc. also accept them.
872 # (The list follows the same order as the GNU Coding Standards.)
873 bindir='${exec_prefix}/bin'
874 sbindir='${exec_prefix}/sbin'
875 libexecdir='${exec_prefix}/libexec'
876 datarootdir='${prefix}/share'
877 datadir='${datarootdir}'
878 sysconfdir='${prefix}/etc'
879 sharedstatedir='${prefix}/com'
880 localstatedir='${prefix}/var'
881 includedir='${prefix}/include'
882 oldincludedir='/usr/include'
883 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
884 infodir='${datarootdir}/info'
885 htmldir='${docdir}'
886 dvidir='${docdir}'
887 pdfdir='${docdir}'
888 psdir='${docdir}'
889 libdir='${exec_prefix}/lib'
890 localedir='${datarootdir}/locale'
891 mandir='${datarootdir}/man'
893 ac_prev=
894 ac_dashdash=
895 for ac_option
897 # If the previous option needs an argument, assign it.
898 if test -n "$ac_prev"; then
899 eval $ac_prev=\$ac_option
900 ac_prev=
901 continue
904 case $ac_option in
905 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
906 *) ac_optarg=yes ;;
907 esac
909 # Accept the important Cygnus configure options, so we can diagnose typos.
911 case $ac_dashdash$ac_option in
913 ac_dashdash=yes ;;
915 -bindir | --bindir | --bindi | --bind | --bin | --bi)
916 ac_prev=bindir ;;
917 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
918 bindir=$ac_optarg ;;
920 -build | --build | --buil | --bui | --bu)
921 ac_prev=build_alias ;;
922 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
923 build_alias=$ac_optarg ;;
925 -cache-file | --cache-file | --cache-fil | --cache-fi \
926 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
927 ac_prev=cache_file ;;
928 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
929 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
930 cache_file=$ac_optarg ;;
932 --config-cache | -C)
933 cache_file=config.cache ;;
935 -datadir | --datadir | --datadi | --datad)
936 ac_prev=datadir ;;
937 -datadir=* | --datadir=* | --datadi=* | --datad=*)
938 datadir=$ac_optarg ;;
940 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
941 | --dataroo | --dataro | --datar)
942 ac_prev=datarootdir ;;
943 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
944 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
945 datarootdir=$ac_optarg ;;
947 -disable-* | --disable-*)
948 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
949 # Reject names that are not valid shell variable names.
950 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
951 as_fn_error "invalid feature name: $ac_useropt"
952 ac_useropt_orig=$ac_useropt
953 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
954 case $ac_user_opts in
956 "enable_$ac_useropt"
957 "*) ;;
958 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
959 ac_unrecognized_sep=', ';;
960 esac
961 eval enable_$ac_useropt=no ;;
963 -docdir | --docdir | --docdi | --doc | --do)
964 ac_prev=docdir ;;
965 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
966 docdir=$ac_optarg ;;
968 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
969 ac_prev=dvidir ;;
970 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
971 dvidir=$ac_optarg ;;
973 -enable-* | --enable-*)
974 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
975 # Reject names that are not valid shell variable names.
976 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
977 as_fn_error "invalid feature name: $ac_useropt"
978 ac_useropt_orig=$ac_useropt
979 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
980 case $ac_user_opts in
982 "enable_$ac_useropt"
983 "*) ;;
984 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
985 ac_unrecognized_sep=', ';;
986 esac
987 eval enable_$ac_useropt=\$ac_optarg ;;
989 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
990 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
991 | --exec | --exe | --ex)
992 ac_prev=exec_prefix ;;
993 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
994 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
995 | --exec=* | --exe=* | --ex=*)
996 exec_prefix=$ac_optarg ;;
998 -gas | --gas | --ga | --g)
999 # Obsolete; use --with-gas.
1000 with_gas=yes ;;
1002 -help | --help | --hel | --he | -h)
1003 ac_init_help=long ;;
1004 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1005 ac_init_help=recursive ;;
1006 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1007 ac_init_help=short ;;
1009 -host | --host | --hos | --ho)
1010 ac_prev=host_alias ;;
1011 -host=* | --host=* | --hos=* | --ho=*)
1012 host_alias=$ac_optarg ;;
1014 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1015 ac_prev=htmldir ;;
1016 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1017 | --ht=*)
1018 htmldir=$ac_optarg ;;
1020 -includedir | --includedir | --includedi | --included | --include \
1021 | --includ | --inclu | --incl | --inc)
1022 ac_prev=includedir ;;
1023 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1024 | --includ=* | --inclu=* | --incl=* | --inc=*)
1025 includedir=$ac_optarg ;;
1027 -infodir | --infodir | --infodi | --infod | --info | --inf)
1028 ac_prev=infodir ;;
1029 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1030 infodir=$ac_optarg ;;
1032 -libdir | --libdir | --libdi | --libd)
1033 ac_prev=libdir ;;
1034 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1035 libdir=$ac_optarg ;;
1037 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1038 | --libexe | --libex | --libe)
1039 ac_prev=libexecdir ;;
1040 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1041 | --libexe=* | --libex=* | --libe=*)
1042 libexecdir=$ac_optarg ;;
1044 -localedir | --localedir | --localedi | --localed | --locale)
1045 ac_prev=localedir ;;
1046 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1047 localedir=$ac_optarg ;;
1049 -localstatedir | --localstatedir | --localstatedi | --localstated \
1050 | --localstate | --localstat | --localsta | --localst | --locals)
1051 ac_prev=localstatedir ;;
1052 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1053 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1054 localstatedir=$ac_optarg ;;
1056 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1057 ac_prev=mandir ;;
1058 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1059 mandir=$ac_optarg ;;
1061 -nfp | --nfp | --nf)
1062 # Obsolete; use --without-fp.
1063 with_fp=no ;;
1065 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1066 | --no-cr | --no-c | -n)
1067 no_create=yes ;;
1069 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1070 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1071 no_recursion=yes ;;
1073 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1074 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1075 | --oldin | --oldi | --old | --ol | --o)
1076 ac_prev=oldincludedir ;;
1077 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1078 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1079 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1080 oldincludedir=$ac_optarg ;;
1082 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1083 ac_prev=prefix ;;
1084 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1085 prefix=$ac_optarg ;;
1087 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1088 | --program-pre | --program-pr | --program-p)
1089 ac_prev=program_prefix ;;
1090 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1091 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1092 program_prefix=$ac_optarg ;;
1094 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1095 | --program-suf | --program-su | --program-s)
1096 ac_prev=program_suffix ;;
1097 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1098 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1099 program_suffix=$ac_optarg ;;
1101 -program-transform-name | --program-transform-name \
1102 | --program-transform-nam | --program-transform-na \
1103 | --program-transform-n | --program-transform- \
1104 | --program-transform | --program-transfor \
1105 | --program-transfo | --program-transf \
1106 | --program-trans | --program-tran \
1107 | --progr-tra | --program-tr | --program-t)
1108 ac_prev=program_transform_name ;;
1109 -program-transform-name=* | --program-transform-name=* \
1110 | --program-transform-nam=* | --program-transform-na=* \
1111 | --program-transform-n=* | --program-transform-=* \
1112 | --program-transform=* | --program-transfor=* \
1113 | --program-transfo=* | --program-transf=* \
1114 | --program-trans=* | --program-tran=* \
1115 | --progr-tra=* | --program-tr=* | --program-t=*)
1116 program_transform_name=$ac_optarg ;;
1118 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1119 ac_prev=pdfdir ;;
1120 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1121 pdfdir=$ac_optarg ;;
1123 -psdir | --psdir | --psdi | --psd | --ps)
1124 ac_prev=psdir ;;
1125 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1126 psdir=$ac_optarg ;;
1128 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1129 | -silent | --silent | --silen | --sile | --sil)
1130 silent=yes ;;
1132 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1133 ac_prev=sbindir ;;
1134 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1135 | --sbi=* | --sb=*)
1136 sbindir=$ac_optarg ;;
1138 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1139 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1140 | --sharedst | --shareds | --shared | --share | --shar \
1141 | --sha | --sh)
1142 ac_prev=sharedstatedir ;;
1143 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1144 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1145 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1146 | --sha=* | --sh=*)
1147 sharedstatedir=$ac_optarg ;;
1149 -site | --site | --sit)
1150 ac_prev=site ;;
1151 -site=* | --site=* | --sit=*)
1152 site=$ac_optarg ;;
1154 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1155 ac_prev=srcdir ;;
1156 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1157 srcdir=$ac_optarg ;;
1159 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1160 | --syscon | --sysco | --sysc | --sys | --sy)
1161 ac_prev=sysconfdir ;;
1162 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1163 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1164 sysconfdir=$ac_optarg ;;
1166 -target | --target | --targe | --targ | --tar | --ta | --t)
1167 ac_prev=target_alias ;;
1168 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1169 target_alias=$ac_optarg ;;
1171 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1172 verbose=yes ;;
1174 -version | --version | --versio | --versi | --vers | -V)
1175 ac_init_version=: ;;
1177 -with-* | --with-*)
1178 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1179 # Reject names that are not valid shell variable names.
1180 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1181 as_fn_error "invalid package name: $ac_useropt"
1182 ac_useropt_orig=$ac_useropt
1183 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1184 case $ac_user_opts in
1186 "with_$ac_useropt"
1187 "*) ;;
1188 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1189 ac_unrecognized_sep=', ';;
1190 esac
1191 eval with_$ac_useropt=\$ac_optarg ;;
1193 -without-* | --without-*)
1194 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1195 # Reject names that are not valid shell variable names.
1196 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1197 as_fn_error "invalid package name: $ac_useropt"
1198 ac_useropt_orig=$ac_useropt
1199 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1200 case $ac_user_opts in
1202 "with_$ac_useropt"
1203 "*) ;;
1204 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1205 ac_unrecognized_sep=', ';;
1206 esac
1207 eval with_$ac_useropt=no ;;
1209 --x)
1210 # Obsolete; use --with-x.
1211 with_x=yes ;;
1213 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1214 | --x-incl | --x-inc | --x-in | --x-i)
1215 ac_prev=x_includes ;;
1216 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1217 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1218 x_includes=$ac_optarg ;;
1220 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1221 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1222 ac_prev=x_libraries ;;
1223 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1224 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1225 x_libraries=$ac_optarg ;;
1227 -*) as_fn_error "unrecognized option: \`$ac_option'
1228 Try \`$0 --help' for more information."
1231 *=*)
1232 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1233 # Reject names that are not valid shell variable names.
1234 case $ac_envvar in #(
1235 '' | [0-9]* | *[!_$as_cr_alnum]* )
1236 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1237 esac
1238 eval $ac_envvar=\$ac_optarg
1239 export $ac_envvar ;;
1242 # FIXME: should be removed in autoconf 3.0.
1243 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1244 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1245 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1246 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1249 esac
1250 done
1252 if test -n "$ac_prev"; then
1253 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1254 as_fn_error "missing argument to $ac_option"
1257 if test -n "$ac_unrecognized_opts"; then
1258 case $enable_option_checking in
1259 no) ;;
1260 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1261 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1262 esac
1265 # Check all directory arguments for consistency.
1266 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1267 datadir sysconfdir sharedstatedir localstatedir includedir \
1268 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1269 libdir localedir mandir
1271 eval ac_val=\$$ac_var
1272 # Remove trailing slashes.
1273 case $ac_val in
1274 */ )
1275 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1276 eval $ac_var=\$ac_val;;
1277 esac
1278 # Be sure to have absolute directory names.
1279 case $ac_val in
1280 [\\/$]* | ?:[\\/]* ) continue;;
1281 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1282 esac
1283 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
1284 done
1286 # There might be people who depend on the old broken behavior: `$host'
1287 # used to hold the argument of --host etc.
1288 # FIXME: To remove some day.
1289 build=$build_alias
1290 host=$host_alias
1291 target=$target_alias
1293 # FIXME: To remove some day.
1294 if test "x$host_alias" != x; then
1295 if test "x$build_alias" = x; then
1296 cross_compiling=maybe
1297 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1298 If a cross compiler is detected then cross compile mode will be used." >&2
1299 elif test "x$build_alias" != "x$host_alias"; then
1300 cross_compiling=yes
1304 ac_tool_prefix=
1305 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1307 test "$silent" = yes && exec 6>/dev/null
1310 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1311 ac_ls_di=`ls -di .` &&
1312 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1313 as_fn_error "working directory cannot be determined"
1314 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1315 as_fn_error "pwd does not report name of working directory"
1318 # Find the source files, if location was not specified.
1319 if test -z "$srcdir"; then
1320 ac_srcdir_defaulted=yes
1321 # Try the directory containing this script, then the parent directory.
1322 ac_confdir=`$as_dirname -- "$as_myself" ||
1323 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1324 X"$as_myself" : 'X\(//\)[^/]' \| \
1325 X"$as_myself" : 'X\(//\)$' \| \
1326 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1327 $as_echo X"$as_myself" |
1328 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1329 s//\1/
1332 /^X\(\/\/\)[^/].*/{
1333 s//\1/
1336 /^X\(\/\/\)$/{
1337 s//\1/
1340 /^X\(\/\).*/{
1341 s//\1/
1344 s/.*/./; q'`
1345 srcdir=$ac_confdir
1346 if test ! -r "$srcdir/$ac_unique_file"; then
1347 srcdir=..
1349 else
1350 ac_srcdir_defaulted=no
1352 if test ! -r "$srcdir/$ac_unique_file"; then
1353 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1354 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1356 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1357 ac_abs_confdir=`(
1358 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1359 pwd)`
1360 # When building in place, set srcdir=.
1361 if test "$ac_abs_confdir" = "$ac_pwd"; then
1362 srcdir=.
1364 # Remove unnecessary trailing slashes from srcdir.
1365 # Double slashes in file names in object file debugging info
1366 # mess up M-x gdb in Emacs.
1367 case $srcdir in
1368 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1369 esac
1370 for ac_var in $ac_precious_vars; do
1371 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1372 eval ac_env_${ac_var}_value=\$${ac_var}
1373 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1374 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1375 done
1378 # Report the --help message.
1380 if test "$ac_init_help" = "long"; then
1381 # Omit some internal or obsolete options to make the list less imposing.
1382 # This message is too long to be a string in the A/UX 3.1 sh.
1383 cat <<_ACEOF
1384 \`configure' configures emacs 24.0.50 to adapt to many kinds of systems.
1386 Usage: $0 [OPTION]... [VAR=VALUE]...
1388 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1389 VAR=VALUE. See below for descriptions of some of the useful variables.
1391 Defaults for the options are specified in brackets.
1393 Configuration:
1394 -h, --help display this help and exit
1395 --help=short display options specific to this package
1396 --help=recursive display the short help of all the included packages
1397 -V, --version display version information and exit
1398 -q, --quiet, --silent do not print \`checking...' messages
1399 --cache-file=FILE cache test results in FILE [disabled]
1400 -C, --config-cache alias for \`--cache-file=config.cache'
1401 -n, --no-create do not create output files
1402 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1404 Installation directories:
1405 --prefix=PREFIX install architecture-independent files in PREFIX
1406 [$ac_default_prefix]
1407 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1408 [PREFIX]
1410 By default, \`make install' will install all the files in
1411 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1412 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1413 for instance \`--prefix=\$HOME'.
1415 For better control, use the options below.
1417 Fine tuning of the installation directories:
1418 --bindir=DIR user executables [EPREFIX/bin]
1419 --sbindir=DIR system admin executables [EPREFIX/sbin]
1420 --libexecdir=DIR program executables [EPREFIX/libexec]
1421 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1422 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1423 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1424 --libdir=DIR object code libraries [EPREFIX/lib]
1425 --includedir=DIR C header files [PREFIX/include]
1426 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1427 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1428 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1429 --infodir=DIR info documentation [DATAROOTDIR/info]
1430 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1431 --mandir=DIR man documentation [DATAROOTDIR/man]
1432 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
1433 --htmldir=DIR html documentation [DOCDIR]
1434 --dvidir=DIR dvi documentation [DOCDIR]
1435 --pdfdir=DIR pdf documentation [DOCDIR]
1436 --psdir=DIR ps documentation [DOCDIR]
1437 _ACEOF
1439 cat <<\_ACEOF
1441 Program names:
1442 --program-prefix=PREFIX prepend PREFIX to installed program names
1443 --program-suffix=SUFFIX append SUFFIX to installed program names
1444 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1446 X features:
1447 --x-includes=DIR X include files are in DIR
1448 --x-libraries=DIR X library files are in DIR
1450 System types:
1451 --build=BUILD configure for building on BUILD [guessed]
1452 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1453 _ACEOF
1456 if test -n "$ac_init_help"; then
1457 case $ac_init_help in
1458 short | recursive ) echo "Configuration of emacs 24.0.50:";;
1459 esac
1460 cat <<\_ACEOF
1462 Optional Features:
1463 --disable-option-checking ignore unrecognized --enable/--with options
1464 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1465 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1466 --disable-ns-self-contained
1467 disable self contained build under NeXTstep
1468 --enable-asserts compile code with asserts enabled
1469 --enable-maintainer-mode
1470 enable make rules and dependencies not useful (and
1471 sometimes confusing) to the casual installer
1472 --enable-locallisppath=PATH
1473 directories Emacs should search for lisp files
1474 specific to this site
1475 --enable-checking[=LIST]
1476 enable expensive run-time checks. With LIST, enable
1477 only specific categories of checks. Categories are:
1478 all,yes,no. Flags are: stringbytes, stringoverrun,
1479 stringfreelist, xmallocoverrun, conslist
1480 --enable-profiling build emacs with profiling support. This might not
1481 work on all platforms
1482 --enable-autodepend automatically generate dependencies to .h-files.
1483 Requires GNU Make and Gcc. Enabled if GNU Make and
1484 Gcc is found
1485 --disable-largefile omit support for large files
1487 Optional Packages:
1488 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1489 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1490 --without-pop don't support POP mail retrieval with movemail
1491 --with-kerberos support Kerberos-authenticated POP
1492 --with-kerberos5 support Kerberos version 5 authenticated POP
1493 --with-hesiod support Hesiod to get the POP server host
1494 --with-mmdf support MMDF mailboxes
1495 --with-mail-unlink unlink, rather than empty, mail spool after reading
1496 --with-mailhost=HOSTNAME
1497 string giving default POP mail host
1498 --without-sound don't compile with sound support
1499 --without-sync-input process async input synchronously
1500 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk3,
1501 lucid or athena, motif, no)
1502 --without-xpm don't compile with XPM image support
1503 --without-jpeg don't compile with JPEG image support
1504 --without-tiff don't compile with TIFF image support
1505 --without-gif don't compile with GIF image support
1506 --without-png don't compile with PNG image support
1507 --without-rsvg don't compile with SVG image support
1508 --without-xft don't use XFT for anti aliased fonts
1509 --without-libotf don't use libotf for OpenType font support
1510 --without-m17n-flt don't use m17n-flt for text shaping
1511 --without-toolkit-scroll-bars
1512 don't use Motif or Xaw3d scroll bars
1513 --without-xaw3d don't use Xaw3d
1514 --without-xim don't use X11 XIM
1515 --with-ns use nextstep (Cocoa or GNUstep) windowing system
1516 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
1517 console
1518 --without-dbus don't compile with D-Bus support
1519 --without-gconf don't compile with GConf support
1520 --without-selinux don't compile with SELinux support
1521 --without-makeinfo don't require makeinfo for building manuals
1522 --without-compress-info don't compress the installed Info pages
1523 --with-pkg-config-prog=PATH
1524 path to pkg-config for finding GTK and librsvg
1525 --with-crt-dir=DIR directory containing crtn.o etc. The default is
1526 /usr/lib, or /usr/lib64 on some platforms.
1527 --with-gnustep-conf=PATH
1528 path to GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
1529 or /etc/GNUstep/GNUstep.conf
1530 --with-x use the X Window System
1532 Some influential environment variables:
1533 CC C compiler command
1534 CFLAGS C compiler flags
1535 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1536 nonstandard directory <lib dir>
1537 LIBS libraries to pass to the linker, e.g. -l<library>
1538 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1539 you have headers in a nonstandard directory <include dir>
1540 CPP C preprocessor
1541 XMKMF Path to xmkmf, Makefile generator for X Window System
1543 Use these variables to override the choices made by `configure' or to help
1544 it to find libraries and programs with nonstandard names/locations.
1546 Report bugs to the package provider.
1547 _ACEOF
1548 ac_status=$?
1551 if test "$ac_init_help" = "recursive"; then
1552 # If there are subdirs, report their specific --help.
1553 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1554 test -d "$ac_dir" ||
1555 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1556 continue
1557 ac_builddir=.
1559 case "$ac_dir" in
1560 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1562 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1563 # A ".." for each directory in $ac_dir_suffix.
1564 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1565 case $ac_top_builddir_sub in
1566 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1567 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1568 esac ;;
1569 esac
1570 ac_abs_top_builddir=$ac_pwd
1571 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1572 # for backward compatibility:
1573 ac_top_builddir=$ac_top_build_prefix
1575 case $srcdir in
1576 .) # We are building in place.
1577 ac_srcdir=.
1578 ac_top_srcdir=$ac_top_builddir_sub
1579 ac_abs_top_srcdir=$ac_pwd ;;
1580 [\\/]* | ?:[\\/]* ) # Absolute name.
1581 ac_srcdir=$srcdir$ac_dir_suffix;
1582 ac_top_srcdir=$srcdir
1583 ac_abs_top_srcdir=$srcdir ;;
1584 *) # Relative name.
1585 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1586 ac_top_srcdir=$ac_top_build_prefix$srcdir
1587 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1588 esac
1589 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1591 cd "$ac_dir" || { ac_status=$?; continue; }
1592 # Check for guested configure.
1593 if test -f "$ac_srcdir/configure.gnu"; then
1594 echo &&
1595 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1596 elif test -f "$ac_srcdir/configure"; then
1597 echo &&
1598 $SHELL "$ac_srcdir/configure" --help=recursive
1599 else
1600 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1601 fi || ac_status=$?
1602 cd "$ac_pwd" || { ac_status=$?; break; }
1603 done
1606 test -n "$ac_init_help" && exit $ac_status
1607 if $ac_init_version; then
1608 cat <<\_ACEOF
1609 emacs configure 24.0.50
1610 generated by GNU Autoconf 2.65
1612 Copyright (C) 2009 Free Software Foundation, Inc.
1613 This configure script is free software; the Free Software Foundation
1614 gives unlimited permission to copy, distribute and modify it.
1615 _ACEOF
1616 exit
1619 ## ------------------------ ##
1620 ## Autoconf initialization. ##
1621 ## ------------------------ ##
1623 # ac_fn_c_try_compile LINENO
1624 # --------------------------
1625 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1626 ac_fn_c_try_compile ()
1628 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1629 rm -f conftest.$ac_objext
1630 if { { ac_try="$ac_compile"
1631 case "(($ac_try" in
1632 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1633 *) ac_try_echo=$ac_try;;
1634 esac
1635 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1636 $as_echo "$ac_try_echo"; } >&5
1637 (eval "$ac_compile") 2>conftest.err
1638 ac_status=$?
1639 if test -s conftest.err; then
1640 grep -v '^ *+' conftest.err >conftest.er1
1641 cat conftest.er1 >&5
1642 mv -f conftest.er1 conftest.err
1644 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1645 test $ac_status = 0; } && {
1646 test -z "$ac_c_werror_flag" ||
1647 test ! -s conftest.err
1648 } && test -s conftest.$ac_objext; then :
1649 ac_retval=0
1650 else
1651 $as_echo "$as_me: failed program was:" >&5
1652 sed 's/^/| /' conftest.$ac_ext >&5
1654 ac_retval=1
1656 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1657 as_fn_set_status $ac_retval
1659 } # ac_fn_c_try_compile
1661 # ac_fn_c_try_link LINENO
1662 # -----------------------
1663 # Try to link conftest.$ac_ext, and return whether this succeeded.
1664 ac_fn_c_try_link ()
1666 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1667 rm -f conftest.$ac_objext conftest$ac_exeext
1668 if { { ac_try="$ac_link"
1669 case "(($ac_try" in
1670 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1671 *) ac_try_echo=$ac_try;;
1672 esac
1673 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1674 $as_echo "$ac_try_echo"; } >&5
1675 (eval "$ac_link") 2>conftest.err
1676 ac_status=$?
1677 if test -s conftest.err; then
1678 grep -v '^ *+' conftest.err >conftest.er1
1679 cat conftest.er1 >&5
1680 mv -f conftest.er1 conftest.err
1682 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1683 test $ac_status = 0; } && {
1684 test -z "$ac_c_werror_flag" ||
1685 test ! -s conftest.err
1686 } && test -s conftest$ac_exeext && {
1687 test "$cross_compiling" = yes ||
1688 $as_test_x conftest$ac_exeext
1689 }; then :
1690 ac_retval=0
1691 else
1692 $as_echo "$as_me: failed program was:" >&5
1693 sed 's/^/| /' conftest.$ac_ext >&5
1695 ac_retval=1
1697 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1698 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1699 # interfere with the next link command; also delete a directory that is
1700 # left behind by Apple's compiler. We do this before executing the actions.
1701 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1702 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1703 as_fn_set_status $ac_retval
1705 } # ac_fn_c_try_link
1707 # ac_fn_c_try_cpp LINENO
1708 # ----------------------
1709 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1710 ac_fn_c_try_cpp ()
1712 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1713 if { { ac_try="$ac_cpp conftest.$ac_ext"
1714 case "(($ac_try" in
1715 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1716 *) ac_try_echo=$ac_try;;
1717 esac
1718 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1719 $as_echo "$ac_try_echo"; } >&5
1720 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1721 ac_status=$?
1722 if test -s conftest.err; then
1723 grep -v '^ *+' conftest.err >conftest.er1
1724 cat conftest.er1 >&5
1725 mv -f conftest.er1 conftest.err
1727 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1728 test $ac_status = 0; } >/dev/null && {
1729 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1730 test ! -s conftest.err
1731 }; then :
1732 ac_retval=0
1733 else
1734 $as_echo "$as_me: failed program was:" >&5
1735 sed 's/^/| /' conftest.$ac_ext >&5
1737 ac_retval=1
1739 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1740 as_fn_set_status $ac_retval
1742 } # ac_fn_c_try_cpp
1744 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1745 # -------------------------------------------------------
1746 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1747 # the include files in INCLUDES and setting the cache variable VAR
1748 # accordingly.
1749 ac_fn_c_check_header_mongrel ()
1751 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1752 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1754 $as_echo_n "checking for $2... " >&6; }
1755 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1756 $as_echo_n "(cached) " >&6
1758 eval ac_res=\$$3
1759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1760 $as_echo "$ac_res" >&6; }
1761 else
1762 # Is the header compilable?
1763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1764 $as_echo_n "checking $2 usability... " >&6; }
1765 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1766 /* end confdefs.h. */
1768 #include <$2>
1769 _ACEOF
1770 if ac_fn_c_try_compile "$LINENO"; then :
1771 ac_header_compiler=yes
1772 else
1773 ac_header_compiler=no
1775 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1777 $as_echo "$ac_header_compiler" >&6; }
1779 # Is the header present?
1780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1781 $as_echo_n "checking $2 presence... " >&6; }
1782 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1783 /* end confdefs.h. */
1784 #include <$2>
1785 _ACEOF
1786 if ac_fn_c_try_cpp "$LINENO"; then :
1787 ac_header_preproc=yes
1788 else
1789 ac_header_preproc=no
1791 rm -f conftest.err conftest.$ac_ext
1792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1793 $as_echo "$ac_header_preproc" >&6; }
1795 # So? What about this header?
1796 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1797 yes:no: )
1798 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1799 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1800 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1801 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1803 no:yes:* )
1804 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1805 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1806 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
1807 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
1808 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1809 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1810 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
1811 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
1812 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1813 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1815 esac
1816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1817 $as_echo_n "checking for $2... " >&6; }
1818 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1819 $as_echo_n "(cached) " >&6
1820 else
1821 eval "$3=\$ac_header_compiler"
1823 eval ac_res=\$$3
1824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1825 $as_echo "$ac_res" >&6; }
1827 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1829 } # ac_fn_c_check_header_mongrel
1831 # ac_fn_c_try_run LINENO
1832 # ----------------------
1833 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1834 # that executables *can* be run.
1835 ac_fn_c_try_run ()
1837 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1838 if { { ac_try="$ac_link"
1839 case "(($ac_try" in
1840 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1841 *) ac_try_echo=$ac_try;;
1842 esac
1843 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1844 $as_echo "$ac_try_echo"; } >&5
1845 (eval "$ac_link") 2>&5
1846 ac_status=$?
1847 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1848 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1849 { { case "(($ac_try" in
1850 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1851 *) ac_try_echo=$ac_try;;
1852 esac
1853 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1854 $as_echo "$ac_try_echo"; } >&5
1855 (eval "$ac_try") 2>&5
1856 ac_status=$?
1857 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1858 test $ac_status = 0; }; }; then :
1859 ac_retval=0
1860 else
1861 $as_echo "$as_me: program exited with status $ac_status" >&5
1862 $as_echo "$as_me: failed program was:" >&5
1863 sed 's/^/| /' conftest.$ac_ext >&5
1865 ac_retval=$ac_status
1867 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1868 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1869 as_fn_set_status $ac_retval
1871 } # ac_fn_c_try_run
1873 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1874 # -------------------------------------------------------
1875 # Tests whether HEADER exists and can be compiled using the include files in
1876 # INCLUDES, setting the cache variable VAR accordingly.
1877 ac_fn_c_check_header_compile ()
1879 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1881 $as_echo_n "checking for $2... " >&6; }
1882 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1883 $as_echo_n "(cached) " >&6
1884 else
1885 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1886 /* end confdefs.h. */
1888 #include <$2>
1889 _ACEOF
1890 if ac_fn_c_try_compile "$LINENO"; then :
1891 eval "$3=yes"
1892 else
1893 eval "$3=no"
1895 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1897 eval ac_res=\$$3
1898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1899 $as_echo "$ac_res" >&6; }
1900 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1902 } # ac_fn_c_check_header_compile
1904 # ac_fn_c_check_decl LINENO SYMBOL VAR
1905 # ------------------------------------
1906 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
1907 ac_fn_c_check_decl ()
1909 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
1911 $as_echo_n "checking whether $2 is declared... " >&6; }
1912 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1913 $as_echo_n "(cached) " >&6
1914 else
1915 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1916 /* end confdefs.h. */
1919 main ()
1921 #ifndef $2
1922 (void) $2;
1923 #endif
1926 return 0;
1928 _ACEOF
1929 if ac_fn_c_try_compile "$LINENO"; then :
1930 eval "$3=yes"
1931 else
1932 eval "$3=no"
1934 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1936 eval ac_res=\$$3
1937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1938 $as_echo "$ac_res" >&6; }
1939 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1941 } # ac_fn_c_check_decl
1943 # ac_fn_c_check_header_preproc LINENO HEADER VAR
1944 # ----------------------------------------------
1945 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
1946 ac_fn_c_check_header_preproc ()
1948 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1950 $as_echo_n "checking for $2... " >&6; }
1951 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
1952 $as_echo_n "(cached) " >&6
1953 else
1954 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1955 /* end confdefs.h. */
1956 #include <$2>
1957 _ACEOF
1958 if ac_fn_c_try_cpp "$LINENO"; then :
1959 eval "$3=yes"
1960 else
1961 eval "$3=no"
1963 rm -f conftest.err conftest.$ac_ext
1965 eval ac_res=\$$3
1966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1967 $as_echo "$ac_res" >&6; }
1968 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1970 } # ac_fn_c_check_header_preproc
1972 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
1973 # ----------------------------------------------------
1974 # Tries to find if the field MEMBER exists in type AGGR, after including
1975 # INCLUDES, setting cache variable VAR accordingly.
1976 ac_fn_c_check_member ()
1978 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
1980 $as_echo_n "checking for $2.$3... " >&6; }
1981 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
1982 $as_echo_n "(cached) " >&6
1983 else
1984 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1985 /* end confdefs.h. */
1988 main ()
1990 static $2 ac_aggr;
1991 if (ac_aggr.$3)
1992 return 0;
1994 return 0;
1996 _ACEOF
1997 if ac_fn_c_try_compile "$LINENO"; then :
1998 eval "$4=yes"
1999 else
2000 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2001 /* end confdefs.h. */
2004 main ()
2006 static $2 ac_aggr;
2007 if (sizeof ac_aggr.$3)
2008 return 0;
2010 return 0;
2012 _ACEOF
2013 if ac_fn_c_try_compile "$LINENO"; then :
2014 eval "$4=yes"
2015 else
2016 eval "$4=no"
2018 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2020 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2022 eval ac_res=\$$4
2023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2024 $as_echo "$ac_res" >&6; }
2025 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2027 } # ac_fn_c_check_member
2029 # ac_fn_c_check_func LINENO FUNC VAR
2030 # ----------------------------------
2031 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2032 ac_fn_c_check_func ()
2034 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2036 $as_echo_n "checking for $2... " >&6; }
2037 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2038 $as_echo_n "(cached) " >&6
2039 else
2040 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2041 /* end confdefs.h. */
2042 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2043 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2044 #define $2 innocuous_$2
2046 /* System header to define __stub macros and hopefully few prototypes,
2047 which can conflict with char $2 (); below.
2048 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2049 <limits.h> exists even on freestanding compilers. */
2051 #ifdef __STDC__
2052 # include <limits.h>
2053 #else
2054 # include <assert.h>
2055 #endif
2057 #undef $2
2059 /* Override any GCC internal prototype to avoid an error.
2060 Use char because int might match the return type of a GCC
2061 builtin and then its argument prototype would still apply. */
2062 #ifdef __cplusplus
2063 extern "C"
2064 #endif
2065 char $2 ();
2066 /* The GNU C library defines this for functions which it implements
2067 to always fail with ENOSYS. Some functions are actually named
2068 something starting with __ and the normal name is an alias. */
2069 #if defined __stub_$2 || defined __stub___$2
2070 choke me
2071 #endif
2074 main ()
2076 return $2 ();
2078 return 0;
2080 _ACEOF
2081 if ac_fn_c_try_link "$LINENO"; then :
2082 eval "$3=yes"
2083 else
2084 eval "$3=no"
2086 rm -f core conftest.err conftest.$ac_objext \
2087 conftest$ac_exeext conftest.$ac_ext
2089 eval ac_res=\$$3
2090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2091 $as_echo "$ac_res" >&6; }
2092 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2094 } # ac_fn_c_check_func
2096 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2097 # -------------------------------------------
2098 # Tests whether TYPE exists after having included INCLUDES, setting cache
2099 # variable VAR accordingly.
2100 ac_fn_c_check_type ()
2102 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2104 $as_echo_n "checking for $2... " >&6; }
2105 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2106 $as_echo_n "(cached) " >&6
2107 else
2108 eval "$3=no"
2109 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2110 /* end confdefs.h. */
2113 main ()
2115 if (sizeof ($2))
2116 return 0;
2118 return 0;
2120 _ACEOF
2121 if ac_fn_c_try_compile "$LINENO"; then :
2122 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2123 /* end confdefs.h. */
2126 main ()
2128 if (sizeof (($2)))
2129 return 0;
2131 return 0;
2133 _ACEOF
2134 if ac_fn_c_try_compile "$LINENO"; then :
2136 else
2137 eval "$3=yes"
2139 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2141 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2143 eval ac_res=\$$3
2144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2145 $as_echo "$ac_res" >&6; }
2146 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2148 } # ac_fn_c_check_type
2149 cat >config.log <<_ACEOF
2150 This file contains any messages produced by compilers while
2151 running configure, to aid debugging if configure makes a mistake.
2153 It was created by emacs $as_me 24.0.50, which was
2154 generated by GNU Autoconf 2.65. Invocation command line was
2156 $ $0 $@
2158 _ACEOF
2159 exec 5>>config.log
2161 cat <<_ASUNAME
2162 ## --------- ##
2163 ## Platform. ##
2164 ## --------- ##
2166 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2167 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2168 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2169 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2170 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2172 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2173 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2175 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2176 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2177 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2178 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2179 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2180 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2181 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2183 _ASUNAME
2185 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2186 for as_dir in $PATH
2188 IFS=$as_save_IFS
2189 test -z "$as_dir" && as_dir=.
2190 $as_echo "PATH: $as_dir"
2191 done
2192 IFS=$as_save_IFS
2194 } >&5
2196 cat >&5 <<_ACEOF
2199 ## ----------- ##
2200 ## Core tests. ##
2201 ## ----------- ##
2203 _ACEOF
2206 # Keep a trace of the command line.
2207 # Strip out --no-create and --no-recursion so they do not pile up.
2208 # Strip out --silent because we don't want to record it for future runs.
2209 # Also quote any args containing shell meta-characters.
2210 # Make two passes to allow for proper duplicate-argument suppression.
2211 ac_configure_args=
2212 ac_configure_args0=
2213 ac_configure_args1=
2214 ac_must_keep_next=false
2215 for ac_pass in 1 2
2217 for ac_arg
2219 case $ac_arg in
2220 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2221 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2222 | -silent | --silent | --silen | --sile | --sil)
2223 continue ;;
2224 *\'*)
2225 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2226 esac
2227 case $ac_pass in
2228 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2230 as_fn_append ac_configure_args1 " '$ac_arg'"
2231 if test $ac_must_keep_next = true; then
2232 ac_must_keep_next=false # Got value, back to normal.
2233 else
2234 case $ac_arg in
2235 *=* | --config-cache | -C | -disable-* | --disable-* \
2236 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2237 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2238 | -with-* | --with-* | -without-* | --without-* | --x)
2239 case "$ac_configure_args0 " in
2240 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2241 esac
2243 -* ) ac_must_keep_next=true ;;
2244 esac
2246 as_fn_append ac_configure_args " '$ac_arg'"
2248 esac
2249 done
2250 done
2251 { ac_configure_args0=; unset ac_configure_args0;}
2252 { ac_configure_args1=; unset ac_configure_args1;}
2254 # When interrupted or exit'd, cleanup temporary files, and complete
2255 # config.log. We remove comments because anyway the quotes in there
2256 # would cause problems or look ugly.
2257 # WARNING: Use '\'' to represent an apostrophe within the trap.
2258 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2259 trap 'exit_status=$?
2260 # Save into config.log some information that might help in debugging.
2262 echo
2264 cat <<\_ASBOX
2265 ## ---------------- ##
2266 ## Cache variables. ##
2267 ## ---------------- ##
2268 _ASBOX
2269 echo
2270 # The following way of writing the cache mishandles newlines in values,
2272 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2273 eval ac_val=\$$ac_var
2274 case $ac_val in #(
2275 *${as_nl}*)
2276 case $ac_var in #(
2277 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2278 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2279 esac
2280 case $ac_var in #(
2281 _ | IFS | as_nl) ;; #(
2282 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2283 *) { eval $ac_var=; unset $ac_var;} ;;
2284 esac ;;
2285 esac
2286 done
2287 (set) 2>&1 |
2288 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2289 *${as_nl}ac_space=\ *)
2290 sed -n \
2291 "s/'\''/'\''\\\\'\'''\''/g;
2292 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2293 ;; #(
2295 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2297 esac |
2298 sort
2300 echo
2302 cat <<\_ASBOX
2303 ## ----------------- ##
2304 ## Output variables. ##
2305 ## ----------------- ##
2306 _ASBOX
2307 echo
2308 for ac_var in $ac_subst_vars
2310 eval ac_val=\$$ac_var
2311 case $ac_val in
2312 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2313 esac
2314 $as_echo "$ac_var='\''$ac_val'\''"
2315 done | sort
2316 echo
2318 if test -n "$ac_subst_files"; then
2319 cat <<\_ASBOX
2320 ## ------------------- ##
2321 ## File substitutions. ##
2322 ## ------------------- ##
2323 _ASBOX
2324 echo
2325 for ac_var in $ac_subst_files
2327 eval ac_val=\$$ac_var
2328 case $ac_val in
2329 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2330 esac
2331 $as_echo "$ac_var='\''$ac_val'\''"
2332 done | sort
2333 echo
2336 if test -s confdefs.h; then
2337 cat <<\_ASBOX
2338 ## ----------- ##
2339 ## confdefs.h. ##
2340 ## ----------- ##
2341 _ASBOX
2342 echo
2343 cat confdefs.h
2344 echo
2346 test "$ac_signal" != 0 &&
2347 $as_echo "$as_me: caught signal $ac_signal"
2348 $as_echo "$as_me: exit $exit_status"
2349 } >&5
2350 rm -f core *.core core.conftest.* &&
2351 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2352 exit $exit_status
2354 for ac_signal in 1 2 13 15; do
2355 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2356 done
2357 ac_signal=0
2359 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2360 rm -f -r conftest* confdefs.h
2362 $as_echo "/* confdefs.h */" > confdefs.h
2364 # Predefined preprocessor variables.
2366 cat >>confdefs.h <<_ACEOF
2367 #define PACKAGE_NAME "$PACKAGE_NAME"
2368 _ACEOF
2370 cat >>confdefs.h <<_ACEOF
2371 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2372 _ACEOF
2374 cat >>confdefs.h <<_ACEOF
2375 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2376 _ACEOF
2378 cat >>confdefs.h <<_ACEOF
2379 #define PACKAGE_STRING "$PACKAGE_STRING"
2380 _ACEOF
2382 cat >>confdefs.h <<_ACEOF
2383 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2384 _ACEOF
2386 cat >>confdefs.h <<_ACEOF
2387 #define PACKAGE_URL "$PACKAGE_URL"
2388 _ACEOF
2391 # Let the site file select an alternate cache file if it wants to.
2392 # Prefer an explicitly selected file to automatically selected ones.
2393 ac_site_file1=NONE
2394 ac_site_file2=NONE
2395 if test -n "$CONFIG_SITE"; then
2396 ac_site_file1=$CONFIG_SITE
2397 elif test "x$prefix" != xNONE; then
2398 ac_site_file1=$prefix/share/config.site
2399 ac_site_file2=$prefix/etc/config.site
2400 else
2401 ac_site_file1=$ac_default_prefix/share/config.site
2402 ac_site_file2=$ac_default_prefix/etc/config.site
2404 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2406 test "x$ac_site_file" = xNONE && continue
2407 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2408 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2409 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2410 sed 's/^/| /' "$ac_site_file" >&5
2411 . "$ac_site_file"
2413 done
2415 if test -r "$cache_file"; then
2416 # Some versions of bash will fail to source /dev/null (special files
2417 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2418 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2419 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2420 $as_echo "$as_me: loading cache $cache_file" >&6;}
2421 case $cache_file in
2422 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2423 *) . "./$cache_file";;
2424 esac
2426 else
2427 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2428 $as_echo "$as_me: creating cache $cache_file" >&6;}
2429 >$cache_file
2432 as_fn_append ac_header_list " stdlib.h"
2433 as_fn_append ac_header_list " unistd.h"
2434 as_fn_append ac_header_list " sys/param.h"
2435 as_fn_append ac_header_list " sys/time.h"
2436 as_fn_append ac_func_list " alarm"
2437 # Check that the precious variables saved in the cache have kept the same
2438 # value.
2439 ac_cache_corrupted=false
2440 for ac_var in $ac_precious_vars; do
2441 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2442 eval ac_new_set=\$ac_env_${ac_var}_set
2443 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2444 eval ac_new_val=\$ac_env_${ac_var}_value
2445 case $ac_old_set,$ac_new_set in
2446 set,)
2447 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2448 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2449 ac_cache_corrupted=: ;;
2450 ,set)
2451 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2452 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2453 ac_cache_corrupted=: ;;
2454 ,);;
2456 if test "x$ac_old_val" != "x$ac_new_val"; then
2457 # differences in whitespace do not lead to failure.
2458 ac_old_val_w=`echo x $ac_old_val`
2459 ac_new_val_w=`echo x $ac_new_val`
2460 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2461 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2462 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2463 ac_cache_corrupted=:
2464 else
2465 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2466 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2467 eval $ac_var=\$ac_old_val
2469 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2470 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2471 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2472 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2473 fi;;
2474 esac
2475 # Pass precious variables to config.status.
2476 if test "$ac_new_set" = set; then
2477 case $ac_new_val in
2478 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2479 *) ac_arg=$ac_var=$ac_new_val ;;
2480 esac
2481 case " $ac_configure_args " in
2482 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2483 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2484 esac
2486 done
2487 if $ac_cache_corrupted; then
2488 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2489 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2490 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2491 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2492 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2494 ## -------------------- ##
2495 ## Main body of script. ##
2496 ## -------------------- ##
2498 ac_ext=c
2499 ac_cpp='$CPP $CPPFLAGS'
2500 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2501 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2502 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2505 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
2509 test "$program_prefix" != NONE &&
2510 program_transform_name="s&^&$program_prefix&;$program_transform_name"
2511 # Use a double $ so make ignores it.
2512 test "$program_suffix" != NONE &&
2513 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
2514 # Double any \ or $.
2515 # By default was `s,x,x', remove it if useless.
2516 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
2517 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
2520 lispdir='${datadir}/emacs/${version}/lisp'
2521 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
2522 '${datadir}/emacs/site-lisp'
2523 lisppath='${locallisppath}:${lispdir}:${datadir}/emacs/${version}/leim'
2524 etcdir='${datadir}/emacs/${version}/etc'
2525 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
2526 docdir='${datadir}/emacs/${version}/etc'
2527 gamedir='${localstatedir}/games/emacs'
2529 gameuser=games
2534 # Check whether --with-pop was given.
2535 if test "${with_pop+set}" = set; then :
2536 withval=$with_pop;
2537 else
2538 with_pop=yes
2541 if test "$with_pop" = yes; then
2542 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
2547 # Check whether --with-kerberos was given.
2548 if test "${with_kerberos+set}" = set; then :
2549 withval=$with_kerberos;
2550 else
2551 with_kerberos=no
2554 if test "$with_kerberos" != no; then
2555 $as_echo "#define KERBEROS 1" >>confdefs.h
2560 # Check whether --with-kerberos5 was given.
2561 if test "${with_kerberos5+set}" = set; then :
2562 withval=$with_kerberos5;
2563 else
2564 with_kerberos5=no
2567 if test "${with_kerberos5}" != no; then
2568 if test "${with_kerberos}" = no; then
2569 with_kerberos=yes
2570 $as_echo "#define KERBEROS 1" >>confdefs.h
2574 $as_echo "#define KERBEROS5 1" >>confdefs.h
2579 # Check whether --with-hesiod was given.
2580 if test "${with_hesiod+set}" = set; then :
2581 withval=$with_hesiod;
2582 else
2583 with_hesiod=no
2586 if test "$with_hesiod" != no; then
2588 $as_echo "#define HESIOD 1" >>confdefs.h
2593 # Check whether --with-mmdf was given.
2594 if test "${with_mmdf+set}" = set; then :
2595 withval=$with_mmdf;
2596 else
2597 with_mmdf=no
2600 if test "$with_mmdf" != no; then
2602 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
2607 # Check whether --with-mail-unlink was given.
2608 if test "${with_mail_unlink+set}" = set; then :
2609 withval=$with_mail_unlink;
2610 else
2611 with_mail_unlink=no
2614 if test "$with_mail_unlink" != no; then
2616 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
2621 # Check whether --with-mailhost was given.
2622 if test "${with_mailhost+set}" = set; then :
2623 withval=$with_mailhost;
2624 cat >>confdefs.h <<_ACEOF
2625 #define MAILHOST "$withval"
2626 _ACEOF
2632 # Check whether --with-sound was given.
2633 if test "${with_sound+set}" = set; then :
2634 withval=$with_sound;
2635 else
2636 with_sound=yes
2641 # Check whether --with-sync-input was given.
2642 if test "${with_sync_input+set}" = set; then :
2643 withval=$with_sync_input;
2644 else
2645 with_sync_input=yes
2648 if test "$with_sync_input" = yes; then
2650 $as_echo "#define SYNC_INPUT 1" >>confdefs.h
2655 # Check whether --with-x-toolkit was given.
2656 if test "${with_x_toolkit+set}" = set; then :
2657 withval=$with_x_toolkit; case "${withval}" in
2658 y | ye | yes ) val=gtk ;;
2659 n | no ) val=no ;;
2660 l | lu | luc | luci | lucid ) val=lucid ;;
2661 a | at | ath | athe | athen | athena ) val=athena ;;
2662 m | mo | mot | moti | motif ) val=motif ;;
2663 g | gt | gtk ) val=gtk ;;
2664 gtk3 ) val=gtk3 ;;
2666 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
2667 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk' or
2668 \`gtk3'. \`yes' and \`gtk' are synonyms. \`athena' and \`lucid' are synonyms." "$LINENO" 5
2670 esac
2671 with_x_toolkit=$val
2677 # Check whether --with-xpm was given.
2678 if test "${with_xpm+set}" = set; then :
2679 withval=$with_xpm;
2680 else
2681 with_xpm=yes
2685 # Check whether --with-jpeg was given.
2686 if test "${with_jpeg+set}" = set; then :
2687 withval=$with_jpeg;
2688 else
2689 with_jpeg=yes
2693 # Check whether --with-tiff was given.
2694 if test "${with_tiff+set}" = set; then :
2695 withval=$with_tiff;
2696 else
2697 with_tiff=yes
2701 # Check whether --with-gif was given.
2702 if test "${with_gif+set}" = set; then :
2703 withval=$with_gif;
2704 else
2705 with_gif=yes
2709 # Check whether --with-png was given.
2710 if test "${with_png+set}" = set; then :
2711 withval=$with_png;
2712 else
2713 with_png=yes
2717 # Check whether --with-rsvg was given.
2718 if test "${with_rsvg+set}" = set; then :
2719 withval=$with_rsvg;
2720 else
2721 with_rsvg=yes
2726 # Check whether --with-xft was given.
2727 if test "${with_xft+set}" = set; then :
2728 withval=$with_xft;
2729 else
2730 with_xft=yes
2734 # Check whether --with-libotf was given.
2735 if test "${with_libotf+set}" = set; then :
2736 withval=$with_libotf;
2737 else
2738 with_libotf=yes
2742 # Check whether --with-m17n-flt was given.
2743 if test "${with_m17n_flt+set}" = set; then :
2744 withval=$with_m17n_flt;
2745 else
2746 with_m17n_flt=yes
2751 # Check whether --with-toolkit-scroll-bars was given.
2752 if test "${with_toolkit_scroll_bars+set}" = set; then :
2753 withval=$with_toolkit_scroll_bars;
2754 else
2755 with_toolkit_scroll_bars=yes
2759 # Check whether --with-xaw3d was given.
2760 if test "${with_xaw3d+set}" = set; then :
2761 withval=$with_xaw3d;
2762 else
2763 with_xaw3d=yes
2767 # Check whether --with-xim was given.
2768 if test "${with_xim+set}" = set; then :
2769 withval=$with_xim;
2770 else
2771 with_xim=yes
2775 # Check whether --with-ns was given.
2776 if test "${with_ns+set}" = set; then :
2777 withval=$with_ns;
2778 else
2779 with_ns=no
2784 # Check whether --with-gpm was given.
2785 if test "${with_gpm+set}" = set; then :
2786 withval=$with_gpm;
2787 else
2788 with_gpm=yes
2792 # Check whether --with-dbus was given.
2793 if test "${with_dbus+set}" = set; then :
2794 withval=$with_dbus;
2795 else
2796 with_dbus=yes
2800 # Check whether --with-gconf was given.
2801 if test "${with_gconf+set}" = set; then :
2802 withval=$with_gconf;
2803 else
2804 with_gconf=yes
2808 # Check whether --with-selinux was given.
2809 if test "${with_selinux+set}" = set; then :
2810 withval=$with_selinux;
2811 else
2812 with_selinux=yes
2816 ## For the times when you want to build Emacs but don't have
2817 ## a suitable makeinfo, and can live without the manuals.
2819 # Check whether --with-makeinfo was given.
2820 if test "${with_makeinfo+set}" = set; then :
2821 withval=$with_makeinfo;
2822 else
2823 with_makeinfo=yes
2827 ## This is an option because I do not know if all info/man support
2828 ## compressed files, nor how to test if they do so.
2830 # Check whether --with-compress-info was given.
2831 if test "${with_compress_info+set}" = set; then :
2832 withval=$with_compress_info;
2833 else
2834 with_compress_info=yes
2837 if test $with_compress_info = yes; then
2838 GZIP_INFO=yes
2839 else
2840 GZIP_INFO=
2845 # Check whether --with-pkg-config-prog was given.
2846 if test "${with_pkg_config_prog+set}" = set; then :
2847 withval=$with_pkg_config_prog;
2850 if test "X${with_pkg_config_prog}" != X; then
2851 if test "${with_pkg_config_prog}" != yes; then
2852 PKG_CONFIG="${with_pkg_config_prog}"
2856 CRT_DIR=
2858 # Check whether --with-crt-dir was given.
2859 if test "${with_crt_dir+set}" = set; then :
2860 withval=$with_crt_dir;
2863 CRT_DIR="${with_crt_dir}"
2866 # Check whether --with-gnustep-conf was given.
2867 if test "${with_gnustep_conf+set}" = set; then :
2868 withval=$with_gnustep_conf;
2871 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
2872 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
2873 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
2874 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
2876 # Check whether --enable-ns-self-contained was given.
2877 if test "${enable_ns_self_contained+set}" = set; then :
2878 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
2879 else
2880 EN_NS_SELF_CONTAINED=yes
2884 # Check whether --enable-asserts was given.
2885 if test "${enable_asserts+set}" = set; then :
2886 enableval=$enable_asserts; USE_XASSERTS=$enableval
2887 else
2888 USE_XASSERTS=no
2892 # Check whether --enable-maintainer-mode was given.
2893 if test "${enable_maintainer_mode+set}" = set; then :
2894 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
2895 else
2896 USE_MAINTAINER_MODE=no
2899 if test $USE_MAINTAINER_MODE = yes; then
2900 MAINT=
2901 else
2902 MAINT=#
2906 # Check whether --enable-locallisppath was given.
2907 if test "${enable_locallisppath+set}" = set; then :
2908 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
2909 locallisppath=
2910 elif test "${enableval}" != "yes"; then
2911 locallisppath=${enableval}
2916 # Check whether --enable-checking was given.
2917 if test "${enable_checking+set}" = set; then :
2918 enableval=$enable_checking; ac_checking_flags="${enableval}"
2921 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
2922 for check in $ac_checking_flags
2924 case $check in
2925 # these set all the flags to specific states
2926 yes) ac_enable_checking=1 ;;
2927 no) ac_enable_checking= ;
2928 ac_gc_check_stringbytes= ;
2929 ac_gc_check_string_overrun= ;
2930 ac_gc_check_string_free_list= ;
2931 ac_xmalloc_overrun= ;
2932 ac_gc_check_cons_list= ;;
2933 all) ac_enable_checking=1 ;
2934 ac_gc_check_stringbytes=1 ;
2935 ac_gc_check_string_overrun=1 ;
2936 ac_gc_check_string_free_list=1 ;
2937 ac_xmalloc_overrun=1 ;
2938 ac_gc_check_cons_list=1 ;;
2939 # these enable particular checks
2940 stringbytes) ac_gc_check_stringbytes=1 ;;
2941 stringoverrun) ac_gc_check_string_overrun=1 ;;
2942 stringfreelist) ac_gc_check_string_free_list=1 ;;
2943 xmallocoverrun) ac_xmalloc_overrun=1 ;;
2944 conslist) ac_gc_check_cons_list=1 ;;
2945 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
2946 esac
2947 done
2948 IFS="$ac_save_IFS"
2950 if test x$ac_enable_checking != x ; then
2952 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
2955 if test x$ac_gc_check_stringbytes != x ; then
2957 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
2960 if test x$ac_gc_check_stringoverrun != x ; then
2962 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
2965 if test x$ac_gc_check_string_free_list != x ; then
2967 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
2970 if test x$ac_xmalloc_overrun != x ; then
2972 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
2975 if test x$ac_gc_check_cons_list != x ; then
2977 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
2981 # Check whether --enable-profiling was given.
2982 if test "${enable_profiling+set}" = set; then :
2983 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
2986 if test x$ac_enable_profiling != x ; then
2987 PROFILING_CFLAGS="-DPROFILING=1 -pg"
2988 PROFILING_LDFLAGS="-pg"
2989 else
2990 PROFILING_CFLAGS=
2991 PROFILING_LDFLAGS=
2994 # Check whether --enable-autodepend was given.
2995 if test "${enable_autodepend+set}" = set; then :
2996 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
2997 else
2998 ac_enable_autodepend=yes
3002 #### Make srcdir absolute, if it isn't already. It's important to
3003 #### avoid running the path through pwd unnecessarily, since pwd can
3004 #### give you automounter prefixes, which can go away. We do all this
3005 #### so Emacs can find its files when run uninstalled.
3006 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
3007 unset CDPATH
3008 case "${srcdir}" in
3009 /* ) ;;
3011 ## We may be able to use the $PWD environment variable to make this
3012 ## absolute. But sometimes PWD is inaccurate.
3013 ## Note: we used to use ${PWD} at the end instead of `pwd`,
3014 ## but that tested only for a well-formed and valid PWD,
3015 ## it did not object when PWD was well-formed and valid but just wrong.
3016 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
3017 then
3018 srcdir="$PWD"
3019 else
3020 srcdir="`(cd ${srcdir}; pwd)`"
3023 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
3024 esac
3026 #### Check if the source directory already has a configured system in it.
3027 if test `pwd` != `(cd ${srcdir} && pwd)` \
3028 && test -f "${srcdir}/src/config.h" ; then
3029 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The directory tree \`${srcdir}' is being used
3030 as a build directory right now; it has been configured in its own
3031 right. To configure in another directory as well, you MUST
3032 use GNU make. If you do not have GNU make, then you must
3033 now do \`make distclean' in ${srcdir},
3034 and then run $0 again." >&5
3035 $as_echo "$as_me: WARNING: The directory tree \`${srcdir}' is being used
3036 as a build directory right now; it has been configured in its own
3037 right. To configure in another directory as well, you MUST
3038 use GNU make. If you do not have GNU make, then you must
3039 now do \`make distclean' in ${srcdir},
3040 and then run $0 again." >&2;}
3043 #### Given the configuration name, set machfile and opsysfile to the
3044 #### names of the m/*.h and s/*.h files we should use.
3046 ### Canonicalize the configuration name.
3048 ac_aux_dir=
3049 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
3050 for ac_t in install-sh install.sh shtool; do
3051 if test -f "$ac_dir/$ac_t"; then
3052 ac_aux_dir=$ac_dir
3053 ac_install_sh="$ac_aux_dir/$ac_t -c"
3054 break 2
3056 done
3057 done
3058 if test -z "$ac_aux_dir"; then
3059 as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
3062 # These three variables are undocumented and unsupported,
3063 # and are intended to be withdrawn in a future Autoconf release.
3064 # They can cause serious problems if a builder's source tree is in a directory
3065 # whose full name contains unusual characters.
3066 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3067 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3068 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3071 # Make sure we can run config.sub.
3072 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
3073 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
3075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
3076 $as_echo_n "checking build system type... " >&6; }
3077 if test "${ac_cv_build+set}" = set; then :
3078 $as_echo_n "(cached) " >&6
3079 else
3080 ac_build_alias=$build_alias
3081 test "x$ac_build_alias" = x &&
3082 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
3083 test "x$ac_build_alias" = x &&
3084 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
3085 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
3086 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
3089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
3090 $as_echo "$ac_cv_build" >&6; }
3091 case $ac_cv_build in
3092 *-*-*) ;;
3093 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
3094 esac
3095 build=$ac_cv_build
3096 ac_save_IFS=$IFS; IFS='-'
3097 set x $ac_cv_build
3098 shift
3099 build_cpu=$1
3100 build_vendor=$2
3101 shift; shift
3102 # Remember, the first character of IFS is used to create $*,
3103 # except with old shells:
3104 build_os=$*
3105 IFS=$ac_save_IFS
3106 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
3109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
3110 $as_echo_n "checking host system type... " >&6; }
3111 if test "${ac_cv_host+set}" = set; then :
3112 $as_echo_n "(cached) " >&6
3113 else
3114 if test "x$host_alias" = x; then
3115 ac_cv_host=$ac_cv_build
3116 else
3117 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
3118 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
3122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
3123 $as_echo "$ac_cv_host" >&6; }
3124 case $ac_cv_host in
3125 *-*-*) ;;
3126 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
3127 esac
3128 host=$ac_cv_host
3129 ac_save_IFS=$IFS; IFS='-'
3130 set x $ac_cv_host
3131 shift
3132 host_cpu=$1
3133 host_vendor=$2
3134 shift; shift
3135 # Remember, the first character of IFS is used to create $*,
3136 # except with old shells:
3137 host_os=$*
3138 IFS=$ac_save_IFS
3139 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
3142 canonical=$host
3143 configuration=${host_alias-${build_alias-$host}}
3147 ### If you add support for a new configuration, add code to this
3148 ### switch statement to recognize your configuration name and select
3149 ### the appropriate operating system and machine description files.
3151 ### You would hope that you could choose an m/*.h file pretty much
3152 ### based on the machine portion of the configuration name, and an s/*.h
3153 ### file based on the operating system portion. However, it turns out
3154 ### that each m/*.h file is pretty manufacturer-specific - for
3155 ### example mips.h is MIPS
3156 ### So we basically have to have a special case for each
3157 ### configuration name.
3159 ### As far as handling version numbers on operating systems is
3160 ### concerned, make sure things will fail in a fixable way. If
3161 ### /etc/MACHINES doesn't say anything about version numbers, be
3162 ### prepared to handle anything reasonably. If version numbers
3163 ### matter, be sure /etc/MACHINES says something about it.
3165 machine='' opsys='' unported=no
3166 case "${canonical}" in
3168 ## FreeBSD ports
3169 *-*-freebsd* )
3170 opsys=freebsd
3171 case "${canonical}" in
3172 alpha*) machine=alpha ;;
3173 amd64-*|x86_64-*) machine=amdx86-64 ;;
3174 arm*) machine=arm ;;
3175 ia64-*) machine=ia64 ;;
3176 i[3456]86-*) machine=intel386 ;;
3177 powerpc-*) machine=macppc ;;
3178 sparc-*) machine=sparc ;;
3179 sparc64-*) machine=sparc ;;
3180 esac
3183 ## FreeBSD kernel + glibc based userland
3184 *-*-kfreebsd*gnu* )
3185 opsys=gnu-kfreebsd
3186 case "${canonical}" in
3187 alpha*) machine=alpha ;;
3188 amd64-*|x86_64-*) machine=amdx86-64 ;;
3189 ia64-*) machine=ia64 ;;
3190 i[3456]86-*) machine=intel386 ;;
3191 powerpc-*) machine=macppc ;;
3192 sparc-*) machine=sparc ;;
3193 sparc64-*) machine=sparc ;;
3194 esac
3197 ## NetBSD ports
3198 *-*-netbsd* )
3199 opsys=netbsd
3200 case "${canonical}" in
3201 alpha*) machine=alpha ;;
3202 x86_64-*) machine=amdx86-64 ;;
3203 arm-*) machine=arm ;;
3204 hppa-*) machine=hp800 ;;
3205 i[3456]86-*) machine=intel386 ;;
3206 m68k-*) machine=m68k ;;
3207 powerpc-*) machine=macppc ;;
3208 mips-*) machine=mips ;;
3209 mipse[bl]-*) machine=mips ;;
3210 sparc*-) machine=sparc ;;
3211 vax-*) machine=vax ;;
3212 esac
3215 ## OpenBSD ports
3216 *-*-openbsd* )
3217 opsys=openbsd
3218 case "${canonical}" in
3219 alpha*) machine=alpha ;;
3220 x86_64-*) machine=amdx86-64 ;;
3221 arm-*) machine=arm ;;
3222 hppa-*) machine=hp800 ;;
3223 i386-*) machine=intel386 ;;
3224 powerpc-*) machine=macppc ;;
3225 sparc*) machine=sparc ;;
3226 vax-*) machine=vax ;;
3227 esac
3230 alpha*-*-linux-gnu* )
3231 machine=alpha opsys=gnu-linux
3234 arm*-*-linux-gnu* )
3235 machine=arm opsys=gnu-linux
3238 ## Apple Darwin / Mac OS X
3239 *-apple-darwin* )
3240 case "${canonical}" in
3241 i[3456]86-* ) machine=intel386 ;;
3242 powerpc-* ) machine=macppc ;;
3243 x86_64-* ) machine=amdx86-64 ;;
3244 * ) unported=yes ;;
3245 esac
3246 opsys=darwin
3247 # Define CPP as follows to make autoconf work correctly.
3248 CPP="${CC-cc} -E -no-cpp-precomp"
3249 # Use fink packages if available.
3250 if test -d /sw/include && test -d /sw/lib; then
3251 GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
3252 CPP="${CPP} ${GCC_TEST_OPTIONS}"
3253 NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
3257 ## HP 9000 series 700 and 800, running HP/UX
3258 hppa*-hp-hpux10.2* )
3259 machine=hp800 opsys=hpux10-20
3261 hppa*-hp-hpux1[1-9]* )
3262 machine=hp800 opsys=hpux11
3263 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
3266 hppa*-*-linux-gnu* )
3267 machine=hp800 opsys=gnu-linux
3270 ## IBM machines
3271 s390-*-linux-gnu* )
3272 machine=ibms390 opsys=gnu-linux
3274 s390x-*-linux-gnu* )
3275 machine=ibms390x opsys=gnu-linux
3277 rs6000-ibm-aix4.[23]* )
3278 machine=ibmrs6000 opsys=aix4-2
3280 powerpc-ibm-aix4.[23]* )
3281 machine=ibmrs6000 opsys=aix4-2
3283 rs6000-ibm-aix[56]* )
3284 machine=ibmrs6000 opsys=aix4-2
3286 powerpc-ibm-aix[56]* )
3287 machine=ibmrs6000 opsys=aix4-2
3290 ## Macintosh PowerPC
3291 powerpc*-*-linux-gnu* )
3292 machine=macppc opsys=gnu-linux
3295 ## Silicon Graphics machines
3296 ## Iris 4D
3297 mips-sgi-irix6.5 )
3298 machine=iris4d opsys=irix6-5
3299 # Without defining _LANGUAGE_C, things get masked out in the headers
3300 # so that, for instance, grepping for `free' in stdlib.h fails and
3301 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
3302 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
3303 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
3306 ## Suns
3307 sparc-*-linux-gnu* | sparc64-*-linux-gnu* )
3308 machine=sparc opsys=gnu-linux
3311 *-sun-solaris* \
3312 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
3313 | x86_64-*-solaris2* | x86_64-*-sunos5*)
3314 case "${canonical}" in
3315 i[3456]86-*-* ) machine=intel386 ;;
3316 amd64-*-*|x86_64-*-*) machine=amdx86-64 ;;
3317 sparc* ) machine=sparc ;;
3318 * ) unported=yes ;;
3319 esac
3320 case "${canonical}" in
3321 *-sunos5.6* | *-solaris2.6* )
3322 opsys=sol2-6
3323 NON_GNU_CPP=/usr/ccs/lib/cpp
3324 RANLIB="ar -ts"
3326 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
3327 opsys=sol2-6
3328 emacs_check_sunpro_c=yes
3329 NON_GNU_CPP=/usr/ccs/lib/cpp
3331 *-sunos5* | *-solaris* )
3332 opsys=sol2-10
3333 emacs_check_sunpro_c=yes
3334 NON_GNU_CPP=/usr/ccs/lib/cpp
3336 esac
3337 ## Watch out for a compiler that we know will not work.
3338 case "${canonical}" in
3339 *-solaris* | *-sunos5* )
3340 if [ "x$CC" = x/usr/ucb/cc ]; then
3341 ## /usr/ucb/cc doesn't work;
3342 ## we should find some other compiler that does work.
3343 unset CC
3346 *) ;;
3347 esac
3350 ## IA-64
3351 ia64*-*-linux* )
3352 machine=ia64 opsys=gnu-linux
3355 ## Intel 386 machines where we don't care about the manufacturer.
3356 i[3456]86-*-* )
3357 machine=intel386
3358 case "${canonical}" in
3359 *-cygwin ) opsys=cygwin ;;
3360 *-darwin* ) opsys=darwin
3361 CPP="${CC-cc} -E -no-cpp-precomp"
3363 *-linux-gnu* ) opsys=gnu-linux ;;
3364 *-sysv4.2uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
3365 *-sysv5uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
3366 *-sysv5OpenUNIX* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
3367 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
3368 esac
3371 ## m68k Linux-based GNU system
3372 m68k-*-linux-gnu* )
3373 machine=m68k opsys=gnu-linux
3376 ## Mips Linux-based GNU system
3377 mips-*-linux-gnu* | mipsel-*-linux-gnu* \
3378 | mips64-*-linux-gnu* | mips64el-*-linux-gnu* )
3379 machine=mips opsys=gnu-linux
3382 ## AMD x86-64 Linux-based GNU system
3383 x86_64-*-linux-gnu* )
3384 machine=amdx86-64 opsys=gnu-linux
3387 ## Tensilica Xtensa Linux-based GNU system
3388 xtensa*-*-linux-gnu* )
3389 machine=xtensa opsys=gnu-linux
3392 ## SuperH Linux-based GNU system
3393 sh[34]*-*-linux-gnu* )
3394 machine=sh3 opsys=gnu-linux
3398 unported=yes
3400 esac
3402 ### If the code above didn't choose an operating system, just choose
3403 ### an operating system based on the configuration name. You really
3404 ### only want to use this when you have no idea what the right
3405 ### operating system is; if you know what operating systems a machine
3406 ### runs, it's cleaner to make it explicit in the case statement
3407 ### above.
3408 if test x"${opsys}" = x; then
3409 case "${canonical}" in
3410 *-gnu* ) opsys=gnu ;;
3412 unported=yes
3414 esac
3419 if test $unported = yes; then
3420 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
3421 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
3424 machfile="m/${machine}.h"
3425 opsysfile="s/${opsys}.h"
3428 #### Choose a compiler.
3429 test -n "$CC" && cc_specified=yes
3431 # Save the value of CFLAGS that the user specified.
3432 SPECIFIED_CFLAGS="$CFLAGS"
3434 ac_ext=c
3435 ac_cpp='$CPP $CPPFLAGS'
3436 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3437 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3438 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3439 if test -n "$ac_tool_prefix"; then
3440 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3441 set dummy ${ac_tool_prefix}gcc; ac_word=$2
3442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3443 $as_echo_n "checking for $ac_word... " >&6; }
3444 if test "${ac_cv_prog_CC+set}" = set; then :
3445 $as_echo_n "(cached) " >&6
3446 else
3447 if test -n "$CC"; then
3448 ac_cv_prog_CC="$CC" # Let the user override the test.
3449 else
3450 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3451 for as_dir in $PATH
3453 IFS=$as_save_IFS
3454 test -z "$as_dir" && as_dir=.
3455 for ac_exec_ext in '' $ac_executable_extensions; do
3456 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3457 ac_cv_prog_CC="${ac_tool_prefix}gcc"
3458 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3459 break 2
3461 done
3462 done
3463 IFS=$as_save_IFS
3467 CC=$ac_cv_prog_CC
3468 if test -n "$CC"; then
3469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3470 $as_echo "$CC" >&6; }
3471 else
3472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3473 $as_echo "no" >&6; }
3478 if test -z "$ac_cv_prog_CC"; then
3479 ac_ct_CC=$CC
3480 # Extract the first word of "gcc", so it can be a program name with args.
3481 set dummy gcc; ac_word=$2
3482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3483 $as_echo_n "checking for $ac_word... " >&6; }
3484 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
3485 $as_echo_n "(cached) " >&6
3486 else
3487 if test -n "$ac_ct_CC"; then
3488 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3489 else
3490 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3491 for as_dir in $PATH
3493 IFS=$as_save_IFS
3494 test -z "$as_dir" && as_dir=.
3495 for ac_exec_ext in '' $ac_executable_extensions; do
3496 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3497 ac_cv_prog_ac_ct_CC="gcc"
3498 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3499 break 2
3501 done
3502 done
3503 IFS=$as_save_IFS
3507 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3508 if test -n "$ac_ct_CC"; then
3509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3510 $as_echo "$ac_ct_CC" >&6; }
3511 else
3512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3513 $as_echo "no" >&6; }
3516 if test "x$ac_ct_CC" = x; then
3517 CC=""
3518 else
3519 case $cross_compiling:$ac_tool_warned in
3520 yes:)
3521 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3522 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3523 ac_tool_warned=yes ;;
3524 esac
3525 CC=$ac_ct_CC
3527 else
3528 CC="$ac_cv_prog_CC"
3531 if test -z "$CC"; then
3532 if test -n "$ac_tool_prefix"; then
3533 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3534 set dummy ${ac_tool_prefix}cc; ac_word=$2
3535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3536 $as_echo_n "checking for $ac_word... " >&6; }
3537 if test "${ac_cv_prog_CC+set}" = set; then :
3538 $as_echo_n "(cached) " >&6
3539 else
3540 if test -n "$CC"; then
3541 ac_cv_prog_CC="$CC" # Let the user override the test.
3542 else
3543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3544 for as_dir in $PATH
3546 IFS=$as_save_IFS
3547 test -z "$as_dir" && as_dir=.
3548 for ac_exec_ext in '' $ac_executable_extensions; do
3549 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3550 ac_cv_prog_CC="${ac_tool_prefix}cc"
3551 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3552 break 2
3554 done
3555 done
3556 IFS=$as_save_IFS
3560 CC=$ac_cv_prog_CC
3561 if test -n "$CC"; then
3562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3563 $as_echo "$CC" >&6; }
3564 else
3565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3566 $as_echo "no" >&6; }
3572 if test -z "$CC"; then
3573 # Extract the first word of "cc", so it can be a program name with args.
3574 set dummy cc; ac_word=$2
3575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3576 $as_echo_n "checking for $ac_word... " >&6; }
3577 if test "${ac_cv_prog_CC+set}" = set; then :
3578 $as_echo_n "(cached) " >&6
3579 else
3580 if test -n "$CC"; then
3581 ac_cv_prog_CC="$CC" # Let the user override the test.
3582 else
3583 ac_prog_rejected=no
3584 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3585 for as_dir in $PATH
3587 IFS=$as_save_IFS
3588 test -z "$as_dir" && as_dir=.
3589 for ac_exec_ext in '' $ac_executable_extensions; do
3590 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3591 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3592 ac_prog_rejected=yes
3593 continue
3595 ac_cv_prog_CC="cc"
3596 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3597 break 2
3599 done
3600 done
3601 IFS=$as_save_IFS
3603 if test $ac_prog_rejected = yes; then
3604 # We found a bogon in the path, so make sure we never use it.
3605 set dummy $ac_cv_prog_CC
3606 shift
3607 if test $# != 0; then
3608 # We chose a different compiler from the bogus one.
3609 # However, it has the same basename, so the bogon will be chosen
3610 # first if we set CC to just the basename; use the full file name.
3611 shift
3612 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3617 CC=$ac_cv_prog_CC
3618 if test -n "$CC"; then
3619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3620 $as_echo "$CC" >&6; }
3621 else
3622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3623 $as_echo "no" >&6; }
3628 if test -z "$CC"; then
3629 if test -n "$ac_tool_prefix"; then
3630 for ac_prog in cl.exe
3632 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3633 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3635 $as_echo_n "checking for $ac_word... " >&6; }
3636 if test "${ac_cv_prog_CC+set}" = set; then :
3637 $as_echo_n "(cached) " >&6
3638 else
3639 if test -n "$CC"; then
3640 ac_cv_prog_CC="$CC" # Let the user override the test.
3641 else
3642 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3643 for as_dir in $PATH
3645 IFS=$as_save_IFS
3646 test -z "$as_dir" && as_dir=.
3647 for ac_exec_ext in '' $ac_executable_extensions; do
3648 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3649 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3650 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3651 break 2
3653 done
3654 done
3655 IFS=$as_save_IFS
3659 CC=$ac_cv_prog_CC
3660 if test -n "$CC"; then
3661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3662 $as_echo "$CC" >&6; }
3663 else
3664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3665 $as_echo "no" >&6; }
3669 test -n "$CC" && break
3670 done
3672 if test -z "$CC"; then
3673 ac_ct_CC=$CC
3674 for ac_prog in cl.exe
3676 # Extract the first word of "$ac_prog", so it can be a program name with args.
3677 set dummy $ac_prog; ac_word=$2
3678 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3679 $as_echo_n "checking for $ac_word... " >&6; }
3680 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
3681 $as_echo_n "(cached) " >&6
3682 else
3683 if test -n "$ac_ct_CC"; then
3684 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3685 else
3686 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3687 for as_dir in $PATH
3689 IFS=$as_save_IFS
3690 test -z "$as_dir" && as_dir=.
3691 for ac_exec_ext in '' $ac_executable_extensions; do
3692 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3693 ac_cv_prog_ac_ct_CC="$ac_prog"
3694 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3695 break 2
3697 done
3698 done
3699 IFS=$as_save_IFS
3703 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3704 if test -n "$ac_ct_CC"; then
3705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3706 $as_echo "$ac_ct_CC" >&6; }
3707 else
3708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3709 $as_echo "no" >&6; }
3713 test -n "$ac_ct_CC" && break
3714 done
3716 if test "x$ac_ct_CC" = x; then
3717 CC=""
3718 else
3719 case $cross_compiling:$ac_tool_warned in
3720 yes:)
3721 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3722 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3723 ac_tool_warned=yes ;;
3724 esac
3725 CC=$ac_ct_CC
3732 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3733 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3734 as_fn_error "no acceptable C compiler found in \$PATH
3735 See \`config.log' for more details." "$LINENO" 5; }
3737 # Provide some information about the compiler.
3738 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3739 set X $ac_compile
3740 ac_compiler=$2
3741 for ac_option in --version -v -V -qversion; do
3742 { { ac_try="$ac_compiler $ac_option >&5"
3743 case "(($ac_try" in
3744 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3745 *) ac_try_echo=$ac_try;;
3746 esac
3747 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3748 $as_echo "$ac_try_echo"; } >&5
3749 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3750 ac_status=$?
3751 if test -s conftest.err; then
3752 sed '10a\
3753 ... rest of stderr output deleted ...
3754 10q' conftest.err >conftest.er1
3755 cat conftest.er1 >&5
3757 rm -f conftest.er1 conftest.err
3758 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3759 test $ac_status = 0; }
3760 done
3762 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3763 /* end confdefs.h. */
3766 main ()
3770 return 0;
3772 _ACEOF
3773 ac_clean_files_save=$ac_clean_files
3774 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3775 # Try to create an executable without -o first, disregard a.out.
3776 # It will help us diagnose broken compilers, and finding out an intuition
3777 # of exeext.
3778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3779 $as_echo_n "checking whether the C compiler works... " >&6; }
3780 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3782 # The possible output files:
3783 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3785 ac_rmfiles=
3786 for ac_file in $ac_files
3788 case $ac_file in
3789 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3790 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3791 esac
3792 done
3793 rm -f $ac_rmfiles
3795 if { { ac_try="$ac_link_default"
3796 case "(($ac_try" in
3797 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3798 *) ac_try_echo=$ac_try;;
3799 esac
3800 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3801 $as_echo "$ac_try_echo"; } >&5
3802 (eval "$ac_link_default") 2>&5
3803 ac_status=$?
3804 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3805 test $ac_status = 0; }; then :
3806 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3807 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3808 # in a Makefile. We should not override ac_cv_exeext if it was cached,
3809 # so that the user can short-circuit this test for compilers unknown to
3810 # Autoconf.
3811 for ac_file in $ac_files ''
3813 test -f "$ac_file" || continue
3814 case $ac_file in
3815 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3817 [ab].out )
3818 # We found the default executable, but exeext='' is most
3819 # certainly right.
3820 break;;
3821 *.* )
3822 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3823 then :; else
3824 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3826 # We set ac_cv_exeext here because the later test for it is not
3827 # safe: cross compilers may not add the suffix if given an `-o'
3828 # argument, so we may need to know it at that point already.
3829 # Even if this section looks crufty: it has the advantage of
3830 # actually working.
3831 break;;
3833 break;;
3834 esac
3835 done
3836 test "$ac_cv_exeext" = no && ac_cv_exeext=
3838 else
3839 ac_file=''
3841 if test -z "$ac_file"; then :
3842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3843 $as_echo "no" >&6; }
3844 $as_echo "$as_me: failed program was:" >&5
3845 sed 's/^/| /' conftest.$ac_ext >&5
3847 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3848 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3849 { as_fn_set_status 77
3850 as_fn_error "C compiler cannot create executables
3851 See \`config.log' for more details." "$LINENO" 5; }; }
3852 else
3853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3854 $as_echo "yes" >&6; }
3856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3857 $as_echo_n "checking for C compiler default output file name... " >&6; }
3858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3859 $as_echo "$ac_file" >&6; }
3860 ac_exeext=$ac_cv_exeext
3862 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3863 ac_clean_files=$ac_clean_files_save
3864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3865 $as_echo_n "checking for suffix of executables... " >&6; }
3866 if { { ac_try="$ac_link"
3867 case "(($ac_try" in
3868 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3869 *) ac_try_echo=$ac_try;;
3870 esac
3871 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3872 $as_echo "$ac_try_echo"; } >&5
3873 (eval "$ac_link") 2>&5
3874 ac_status=$?
3875 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3876 test $ac_status = 0; }; then :
3877 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3878 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3879 # work properly (i.e., refer to `conftest.exe'), while it won't with
3880 # `rm'.
3881 for ac_file in conftest.exe conftest conftest.*; do
3882 test -f "$ac_file" || continue
3883 case $ac_file in
3884 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3885 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3886 break;;
3887 * ) break;;
3888 esac
3889 done
3890 else
3891 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3892 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3893 as_fn_error "cannot compute suffix of executables: cannot compile and link
3894 See \`config.log' for more details." "$LINENO" 5; }
3896 rm -f conftest conftest$ac_cv_exeext
3897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3898 $as_echo "$ac_cv_exeext" >&6; }
3900 rm -f conftest.$ac_ext
3901 EXEEXT=$ac_cv_exeext
3902 ac_exeext=$EXEEXT
3903 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3904 /* end confdefs.h. */
3905 #include <stdio.h>
3907 main ()
3909 FILE *f = fopen ("conftest.out", "w");
3910 return ferror (f) || fclose (f) != 0;
3913 return 0;
3915 _ACEOF
3916 ac_clean_files="$ac_clean_files conftest.out"
3917 # Check that the compiler produces executables we can run. If not, either
3918 # the compiler is broken, or we cross compile.
3919 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3920 $as_echo_n "checking whether we are cross compiling... " >&6; }
3921 if test "$cross_compiling" != yes; then
3922 { { ac_try="$ac_link"
3923 case "(($ac_try" in
3924 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3925 *) ac_try_echo=$ac_try;;
3926 esac
3927 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3928 $as_echo "$ac_try_echo"; } >&5
3929 (eval "$ac_link") 2>&5
3930 ac_status=$?
3931 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3932 test $ac_status = 0; }
3933 if { ac_try='./conftest$ac_cv_exeext'
3934 { { case "(($ac_try" in
3935 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3936 *) ac_try_echo=$ac_try;;
3937 esac
3938 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3939 $as_echo "$ac_try_echo"; } >&5
3940 (eval "$ac_try") 2>&5
3941 ac_status=$?
3942 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3943 test $ac_status = 0; }; }; then
3944 cross_compiling=no
3945 else
3946 if test "$cross_compiling" = maybe; then
3947 cross_compiling=yes
3948 else
3949 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3950 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3951 as_fn_error "cannot run C compiled programs.
3952 If you meant to cross compile, use \`--host'.
3953 See \`config.log' for more details." "$LINENO" 5; }
3957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3958 $as_echo "$cross_compiling" >&6; }
3960 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3961 ac_clean_files=$ac_clean_files_save
3962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3963 $as_echo_n "checking for suffix of object files... " >&6; }
3964 if test "${ac_cv_objext+set}" = set; then :
3965 $as_echo_n "(cached) " >&6
3966 else
3967 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3968 /* end confdefs.h. */
3971 main ()
3975 return 0;
3977 _ACEOF
3978 rm -f conftest.o conftest.obj
3979 if { { ac_try="$ac_compile"
3980 case "(($ac_try" in
3981 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3982 *) ac_try_echo=$ac_try;;
3983 esac
3984 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3985 $as_echo "$ac_try_echo"; } >&5
3986 (eval "$ac_compile") 2>&5
3987 ac_status=$?
3988 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3989 test $ac_status = 0; }; then :
3990 for ac_file in conftest.o conftest.obj conftest.*; do
3991 test -f "$ac_file" || continue;
3992 case $ac_file in
3993 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3994 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3995 break;;
3996 esac
3997 done
3998 else
3999 $as_echo "$as_me: failed program was:" >&5
4000 sed 's/^/| /' conftest.$ac_ext >&5
4002 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4003 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4004 as_fn_error "cannot compute suffix of object files: cannot compile
4005 See \`config.log' for more details." "$LINENO" 5; }
4007 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4010 $as_echo "$ac_cv_objext" >&6; }
4011 OBJEXT=$ac_cv_objext
4012 ac_objext=$OBJEXT
4013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4014 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4015 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
4016 $as_echo_n "(cached) " >&6
4017 else
4018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4019 /* end confdefs.h. */
4022 main ()
4024 #ifndef __GNUC__
4025 choke me
4026 #endif
4029 return 0;
4031 _ACEOF
4032 if ac_fn_c_try_compile "$LINENO"; then :
4033 ac_compiler_gnu=yes
4034 else
4035 ac_compiler_gnu=no
4037 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4038 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4042 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
4043 if test $ac_compiler_gnu = yes; then
4044 GCC=yes
4045 else
4046 GCC=
4048 ac_test_CFLAGS=${CFLAGS+set}
4049 ac_save_CFLAGS=$CFLAGS
4050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4051 $as_echo_n "checking whether $CC accepts -g... " >&6; }
4052 if test "${ac_cv_prog_cc_g+set}" = set; then :
4053 $as_echo_n "(cached) " >&6
4054 else
4055 ac_save_c_werror_flag=$ac_c_werror_flag
4056 ac_c_werror_flag=yes
4057 ac_cv_prog_cc_g=no
4058 CFLAGS="-g"
4059 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4060 /* end confdefs.h. */
4063 main ()
4067 return 0;
4069 _ACEOF
4070 if ac_fn_c_try_compile "$LINENO"; then :
4071 ac_cv_prog_cc_g=yes
4072 else
4073 CFLAGS=""
4074 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4075 /* end confdefs.h. */
4078 main ()
4082 return 0;
4084 _ACEOF
4085 if ac_fn_c_try_compile "$LINENO"; then :
4087 else
4088 ac_c_werror_flag=$ac_save_c_werror_flag
4089 CFLAGS="-g"
4090 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4091 /* end confdefs.h. */
4094 main ()
4098 return 0;
4100 _ACEOF
4101 if ac_fn_c_try_compile "$LINENO"; then :
4102 ac_cv_prog_cc_g=yes
4104 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4106 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4108 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4109 ac_c_werror_flag=$ac_save_c_werror_flag
4111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4112 $as_echo "$ac_cv_prog_cc_g" >&6; }
4113 if test "$ac_test_CFLAGS" = set; then
4114 CFLAGS=$ac_save_CFLAGS
4115 elif test $ac_cv_prog_cc_g = yes; then
4116 if test "$GCC" = yes; then
4117 CFLAGS="-g -O2"
4118 else
4119 CFLAGS="-g"
4121 else
4122 if test "$GCC" = yes; then
4123 CFLAGS="-O2"
4124 else
4125 CFLAGS=
4128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4129 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4130 if test "${ac_cv_prog_cc_c89+set}" = set; then :
4131 $as_echo_n "(cached) " >&6
4132 else
4133 ac_cv_prog_cc_c89=no
4134 ac_save_CC=$CC
4135 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4136 /* end confdefs.h. */
4137 #include <stdarg.h>
4138 #include <stdio.h>
4139 #include <sys/types.h>
4140 #include <sys/stat.h>
4141 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4142 struct buf { int x; };
4143 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4144 static char *e (p, i)
4145 char **p;
4146 int i;
4148 return p[i];
4150 static char *f (char * (*g) (char **, int), char **p, ...)
4152 char *s;
4153 va_list v;
4154 va_start (v,p);
4155 s = g (p, va_arg (v,int));
4156 va_end (v);
4157 return s;
4160 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
4161 function prototypes and stuff, but not '\xHH' hex character constants.
4162 These don't provoke an error unfortunately, instead are silently treated
4163 as 'x'. The following induces an error, until -std is added to get
4164 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
4165 array size at least. It's necessary to write '\x00'==0 to get something
4166 that's true only with -std. */
4167 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4169 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4170 inside strings and character constants. */
4171 #define FOO(x) 'x'
4172 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4174 int test (int i, double x);
4175 struct s1 {int (*f) (int a);};
4176 struct s2 {int (*f) (double a);};
4177 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4178 int argc;
4179 char **argv;
4181 main ()
4183 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4185 return 0;
4187 _ACEOF
4188 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4189 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4191 CC="$ac_save_CC $ac_arg"
4192 if ac_fn_c_try_compile "$LINENO"; then :
4193 ac_cv_prog_cc_c89=$ac_arg
4195 rm -f core conftest.err conftest.$ac_objext
4196 test "x$ac_cv_prog_cc_c89" != "xno" && break
4197 done
4198 rm -f conftest.$ac_ext
4199 CC=$ac_save_CC
4202 # AC_CACHE_VAL
4203 case "x$ac_cv_prog_cc_c89" in
4205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4206 $as_echo "none needed" >&6; } ;;
4207 xno)
4208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4209 $as_echo "unsupported" >&6; } ;;
4211 CC="$CC $ac_cv_prog_cc_c89"
4212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4213 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4214 esac
4215 if test "x$ac_cv_prog_cc_c89" != xno; then :
4219 ac_ext=c
4220 ac_cpp='$CPP $CPPFLAGS'
4221 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4222 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4223 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4226 # On Suns, sometimes $CPP names a directory.
4227 if test -n "$CPP" && test -d "$CPP"; then
4228 CPP=
4231 ## If not using gcc, and on Solaris, and no CPP specified, see if
4232 ## using a Sun compiler, which needs -Xs to prevent whitespace.
4233 if test x"$GCC" != xyes && test x"$emacs_check_sunpro_c" = xyes && \
4234 test x"$CPP" = x; then
4235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using a Sun C compiler" >&5
4236 $as_echo_n "checking whether we are using a Sun C compiler... " >&6; }
4238 if test "${emacs_cv_sunpro_c+set}" = set; then :
4239 $as_echo_n "(cached) " >&6
4240 else
4241 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4242 /* end confdefs.h. */
4245 main ()
4247 #ifndef __SUNPRO_C
4248 fail;
4249 #endif
4252 return 0;
4254 _ACEOF
4255 if ac_fn_c_try_link "$LINENO"; then :
4256 emacs_cv_sunpro_c=yes
4257 else
4258 emacs_cv_sunpro_c=no
4260 rm -f core conftest.err conftest.$ac_objext \
4261 conftest$ac_exeext conftest.$ac_ext
4264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_sunpro_c" >&5
4265 $as_echo "$emacs_cv_sunpro_c" >&6; }
4267 if test x"$emacs_cv_sunpro_c" = xyes; then
4268 NON_GNU_CPP="$CC -E -Xs"
4272 #### Some systems specify a CPP to use unless we are using GCC.
4273 #### Now that we know whether we are using GCC, we can decide whether
4274 #### to use that one.
4275 if test "x$NON_GNU_CPP" != x && test x$GCC != xyes && test "x$CPP" = x
4276 then
4277 CPP="$NON_GNU_CPP"
4280 #### Some systems specify a CC to use unless we are using GCC.
4281 #### Now that we know whether we are using GCC, we can decide whether
4282 #### to use that one.
4283 if test "x$NON_GNU_CC" != x && test x$GCC != xyes &&
4284 test x$cc_specified != xyes
4285 then
4286 CC="$NON_GNU_CC"
4289 if test x$GCC = xyes && test "x$GCC_TEST_OPTIONS" != x
4290 then
4291 CC="$CC $GCC_TEST_OPTIONS"
4294 if test x$GCC = x && test "x$NON_GCC_TEST_OPTIONS" != x
4295 then
4296 CC="$CC $NON_GCC_TEST_OPTIONS"
4299 ac_ext=c
4300 ac_cpp='$CPP $CPPFLAGS'
4301 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4302 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4303 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4304 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4305 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4306 # On Suns, sometimes $CPP names a directory.
4307 if test -n "$CPP" && test -d "$CPP"; then
4308 CPP=
4310 if test -z "$CPP"; then
4311 if test "${ac_cv_prog_CPP+set}" = set; then :
4312 $as_echo_n "(cached) " >&6
4313 else
4314 # Double quotes because CPP needs to be expanded
4315 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4317 ac_preproc_ok=false
4318 for ac_c_preproc_warn_flag in '' yes
4320 # Use a header file that comes with gcc, so configuring glibc
4321 # with a fresh cross-compiler works.
4322 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4323 # <limits.h> exists even on freestanding compilers.
4324 # On the NeXT, cc -E runs the code through the compiler's parser,
4325 # not just through cpp. "Syntax error" is here to catch this case.
4326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4327 /* end confdefs.h. */
4328 #ifdef __STDC__
4329 # include <limits.h>
4330 #else
4331 # include <assert.h>
4332 #endif
4333 Syntax error
4334 _ACEOF
4335 if ac_fn_c_try_cpp "$LINENO"; then :
4337 else
4338 # Broken: fails on valid input.
4339 continue
4341 rm -f conftest.err conftest.$ac_ext
4343 # OK, works on sane cases. Now check whether nonexistent headers
4344 # can be detected and how.
4345 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4346 /* end confdefs.h. */
4347 #include <ac_nonexistent.h>
4348 _ACEOF
4349 if ac_fn_c_try_cpp "$LINENO"; then :
4350 # Broken: success on invalid input.
4351 continue
4352 else
4353 # Passes both tests.
4354 ac_preproc_ok=:
4355 break
4357 rm -f conftest.err conftest.$ac_ext
4359 done
4360 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4361 rm -f conftest.err conftest.$ac_ext
4362 if $ac_preproc_ok; then :
4363 break
4366 done
4367 ac_cv_prog_CPP=$CPP
4370 CPP=$ac_cv_prog_CPP
4371 else
4372 ac_cv_prog_CPP=$CPP
4374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4375 $as_echo "$CPP" >&6; }
4376 ac_preproc_ok=false
4377 for ac_c_preproc_warn_flag in '' yes
4379 # Use a header file that comes with gcc, so configuring glibc
4380 # with a fresh cross-compiler works.
4381 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4382 # <limits.h> exists even on freestanding compilers.
4383 # On the NeXT, cc -E runs the code through the compiler's parser,
4384 # not just through cpp. "Syntax error" is here to catch this case.
4385 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4386 /* end confdefs.h. */
4387 #ifdef __STDC__
4388 # include <limits.h>
4389 #else
4390 # include <assert.h>
4391 #endif
4392 Syntax error
4393 _ACEOF
4394 if ac_fn_c_try_cpp "$LINENO"; then :
4396 else
4397 # Broken: fails on valid input.
4398 continue
4400 rm -f conftest.err conftest.$ac_ext
4402 # OK, works on sane cases. Now check whether nonexistent headers
4403 # can be detected and how.
4404 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4405 /* end confdefs.h. */
4406 #include <ac_nonexistent.h>
4407 _ACEOF
4408 if ac_fn_c_try_cpp "$LINENO"; then :
4409 # Broken: success on invalid input.
4410 continue
4411 else
4412 # Passes both tests.
4413 ac_preproc_ok=:
4414 break
4416 rm -f conftest.err conftest.$ac_ext
4418 done
4419 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4420 rm -f conftest.err conftest.$ac_ext
4421 if $ac_preproc_ok; then :
4423 else
4424 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4425 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4426 as_fn_error "C preprocessor \"$CPP\" fails sanity check
4427 See \`config.log' for more details." "$LINENO" 5; }
4430 ac_ext=c
4431 ac_cpp='$CPP $CPPFLAGS'
4432 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4433 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4434 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4438 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4439 if test "${ac_cv_path_GREP+set}" = set; then :
4440 $as_echo_n "(cached) " >&6
4441 else
4442 if test -z "$GREP"; then
4443 ac_path_GREP_found=false
4444 # Loop through the user's path and test for each of PROGNAME-LIST
4445 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4446 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4448 IFS=$as_save_IFS
4449 test -z "$as_dir" && as_dir=.
4450 for ac_prog in grep ggrep; do
4451 for ac_exec_ext in '' $ac_executable_extensions; do
4452 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4453 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
4454 # Check for GNU ac_path_GREP and select it if it is found.
4455 # Check for GNU $ac_path_GREP
4456 case `"$ac_path_GREP" --version 2>&1` in
4457 *GNU*)
4458 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4460 ac_count=0
4461 $as_echo_n 0123456789 >"conftest.in"
4462 while :
4464 cat "conftest.in" "conftest.in" >"conftest.tmp"
4465 mv "conftest.tmp" "conftest.in"
4466 cp "conftest.in" "conftest.nl"
4467 $as_echo 'GREP' >> "conftest.nl"
4468 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4469 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4470 as_fn_arith $ac_count + 1 && ac_count=$as_val
4471 if test $ac_count -gt ${ac_path_GREP_max-0}; then
4472 # Best one so far, save it but keep looking for a better one
4473 ac_cv_path_GREP="$ac_path_GREP"
4474 ac_path_GREP_max=$ac_count
4476 # 10*(2^10) chars as input seems more than enough
4477 test $ac_count -gt 10 && break
4478 done
4479 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4480 esac
4482 $ac_path_GREP_found && break 3
4483 done
4484 done
4485 done
4486 IFS=$as_save_IFS
4487 if test -z "$ac_cv_path_GREP"; then
4488 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4490 else
4491 ac_cv_path_GREP=$GREP
4495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4496 $as_echo "$ac_cv_path_GREP" >&6; }
4497 GREP="$ac_cv_path_GREP"
4500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4501 $as_echo_n "checking for egrep... " >&6; }
4502 if test "${ac_cv_path_EGREP+set}" = set; then :
4503 $as_echo_n "(cached) " >&6
4504 else
4505 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4506 then ac_cv_path_EGREP="$GREP -E"
4507 else
4508 if test -z "$EGREP"; then
4509 ac_path_EGREP_found=false
4510 # Loop through the user's path and test for each of PROGNAME-LIST
4511 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4512 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4514 IFS=$as_save_IFS
4515 test -z "$as_dir" && as_dir=.
4516 for ac_prog in egrep; do
4517 for ac_exec_ext in '' $ac_executable_extensions; do
4518 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4519 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
4520 # Check for GNU ac_path_EGREP and select it if it is found.
4521 # Check for GNU $ac_path_EGREP
4522 case `"$ac_path_EGREP" --version 2>&1` in
4523 *GNU*)
4524 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4526 ac_count=0
4527 $as_echo_n 0123456789 >"conftest.in"
4528 while :
4530 cat "conftest.in" "conftest.in" >"conftest.tmp"
4531 mv "conftest.tmp" "conftest.in"
4532 cp "conftest.in" "conftest.nl"
4533 $as_echo 'EGREP' >> "conftest.nl"
4534 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4535 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4536 as_fn_arith $ac_count + 1 && ac_count=$as_val
4537 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4538 # Best one so far, save it but keep looking for a better one
4539 ac_cv_path_EGREP="$ac_path_EGREP"
4540 ac_path_EGREP_max=$ac_count
4542 # 10*(2^10) chars as input seems more than enough
4543 test $ac_count -gt 10 && break
4544 done
4545 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4546 esac
4548 $ac_path_EGREP_found && break 3
4549 done
4550 done
4551 done
4552 IFS=$as_save_IFS
4553 if test -z "$ac_cv_path_EGREP"; then
4554 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4556 else
4557 ac_cv_path_EGREP=$EGREP
4562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4563 $as_echo "$ac_cv_path_EGREP" >&6; }
4564 EGREP="$ac_cv_path_EGREP"
4567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4568 $as_echo_n "checking for ANSI C header files... " >&6; }
4569 if test "${ac_cv_header_stdc+set}" = set; then :
4570 $as_echo_n "(cached) " >&6
4571 else
4572 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4573 /* end confdefs.h. */
4574 #include <stdlib.h>
4575 #include <stdarg.h>
4576 #include <string.h>
4577 #include <float.h>
4580 main ()
4584 return 0;
4586 _ACEOF
4587 if ac_fn_c_try_compile "$LINENO"; then :
4588 ac_cv_header_stdc=yes
4589 else
4590 ac_cv_header_stdc=no
4592 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4594 if test $ac_cv_header_stdc = yes; then
4595 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4597 /* end confdefs.h. */
4598 #include <string.h>
4600 _ACEOF
4601 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4602 $EGREP "memchr" >/dev/null 2>&1; then :
4604 else
4605 ac_cv_header_stdc=no
4607 rm -f conftest*
4611 if test $ac_cv_header_stdc = yes; then
4612 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4613 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4614 /* end confdefs.h. */
4615 #include <stdlib.h>
4617 _ACEOF
4618 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4619 $EGREP "free" >/dev/null 2>&1; then :
4621 else
4622 ac_cv_header_stdc=no
4624 rm -f conftest*
4628 if test $ac_cv_header_stdc = yes; then
4629 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4630 if test "$cross_compiling" = yes; then :
4632 else
4633 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4634 /* end confdefs.h. */
4635 #include <ctype.h>
4636 #include <stdlib.h>
4637 #if ((' ' & 0x0FF) == 0x020)
4638 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4639 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4640 #else
4641 # define ISLOWER(c) \
4642 (('a' <= (c) && (c) <= 'i') \
4643 || ('j' <= (c) && (c) <= 'r') \
4644 || ('s' <= (c) && (c) <= 'z'))
4645 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4646 #endif
4648 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4650 main ()
4652 int i;
4653 for (i = 0; i < 256; i++)
4654 if (XOR (islower (i), ISLOWER (i))
4655 || toupper (i) != TOUPPER (i))
4656 return 2;
4657 return 0;
4659 _ACEOF
4660 if ac_fn_c_try_run "$LINENO"; then :
4662 else
4663 ac_cv_header_stdc=no
4665 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4666 conftest.$ac_objext conftest.beam conftest.$ac_ext
4671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4672 $as_echo "$ac_cv_header_stdc" >&6; }
4673 if test $ac_cv_header_stdc = yes; then
4675 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4679 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4680 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4681 inttypes.h stdint.h unistd.h
4682 do :
4683 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4684 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4686 eval as_val=\$$as_ac_Header
4687 if test "x$as_val" = x""yes; then :
4688 cat >>confdefs.h <<_ACEOF
4689 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4690 _ACEOF
4694 done
4698 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4699 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
4700 MINIX=yes
4701 else
4702 MINIX=
4706 if test "$MINIX" = yes; then
4708 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4711 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4714 $as_echo "#define _MINIX 1" >>confdefs.h
4719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4720 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4721 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
4722 $as_echo_n "(cached) " >&6
4723 else
4724 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4725 /* end confdefs.h. */
4727 # define __EXTENSIONS__ 1
4728 $ac_includes_default
4730 main ()
4734 return 0;
4736 _ACEOF
4737 if ac_fn_c_try_compile "$LINENO"; then :
4738 ac_cv_safe_to_define___extensions__=yes
4739 else
4740 ac_cv_safe_to_define___extensions__=no
4742 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4745 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
4746 test $ac_cv_safe_to_define___extensions__ = yes &&
4747 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
4749 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
4751 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
4753 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4755 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
4759 ### Use -Wno-pointer-sign if the compiler supports it
4760 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wno-pointer-sign" >&5
4761 $as_echo_n "checking whether gcc understands -Wno-pointer-sign... " >&6; }
4762 SAVE_CFLAGS="$CFLAGS"
4763 CFLAGS="$CFLAGS -Wno-pointer-sign"
4764 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4765 /* end confdefs.h. */
4768 main ()
4772 return 0;
4774 _ACEOF
4775 if ac_fn_c_try_compile "$LINENO"; then :
4776 has_option=yes
4777 else
4778 has_option=no
4780 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4781 if test $has_option = yes; then
4782 C_WARNINGS_SWITCH="-Wno-pointer-sign $C_WARNINGS_SWITCH"
4784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
4785 $as_echo "$has_option" >&6; }
4786 CFLAGS="$SAVE_CFLAGS"
4787 unset has_option
4788 unset SAVE_CFLAGS
4790 ### Use -Wdeclaration-after-statement if the compiler supports it
4791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wdeclaration-after-statement" >&5
4792 $as_echo_n "checking whether gcc understands -Wdeclaration-after-statement... " >&6; }
4793 SAVE_CFLAGS="$CFLAGS"
4794 CFLAGS="$CFLAGS -Wdeclaration-after-statement"
4795 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4796 /* end confdefs.h. */
4799 main ()
4803 return 0;
4805 _ACEOF
4806 if ac_fn_c_try_compile "$LINENO"; then :
4807 has_option=yes
4808 else
4809 has_option=no
4811 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4812 if test $has_option = yes; then
4813 C_WARNINGS_SWITCH="-Wdeclaration-after-statement $C_WARNINGS_SWITCH"
4815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
4816 $as_echo "$has_option" >&6; }
4817 CFLAGS="$SAVE_CFLAGS"
4818 unset has_option
4819 unset SAVE_CFLAGS
4821 #### Some other nice autoconf tests.
4823 ac_ext=c
4824 ac_cpp='$CPP $CPPFLAGS'
4825 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4826 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4827 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4829 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4830 # On Suns, sometimes $CPP names a directory.
4831 if test -n "$CPP" && test -d "$CPP"; then
4832 CPP=
4834 if test -z "$CPP"; then
4835 if test "${ac_cv_prog_CPP+set}" = set; then :
4836 $as_echo_n "(cached) " >&6
4837 else
4838 # Double quotes because CPP needs to be expanded
4839 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4841 ac_preproc_ok=false
4842 for ac_c_preproc_warn_flag in '' yes
4844 # Use a header file that comes with gcc, so configuring glibc
4845 # with a fresh cross-compiler works.
4846 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4847 # <limits.h> exists even on freestanding compilers.
4848 # On the NeXT, cc -E runs the code through the compiler's parser,
4849 # not just through cpp. "Syntax error" is here to catch this case.
4850 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4851 /* end confdefs.h. */
4852 #ifdef __STDC__
4853 # include <limits.h>
4854 #else
4855 # include <assert.h>
4856 #endif
4857 Syntax error
4858 _ACEOF
4859 if ac_fn_c_try_cpp "$LINENO"; then :
4861 else
4862 # Broken: fails on valid input.
4863 continue
4865 rm -f conftest.err conftest.$ac_ext
4867 # OK, works on sane cases. Now check whether nonexistent headers
4868 # can be detected and how.
4869 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4870 /* end confdefs.h. */
4871 #include <ac_nonexistent.h>
4872 _ACEOF
4873 if ac_fn_c_try_cpp "$LINENO"; then :
4874 # Broken: success on invalid input.
4875 continue
4876 else
4877 # Passes both tests.
4878 ac_preproc_ok=:
4879 break
4881 rm -f conftest.err conftest.$ac_ext
4883 done
4884 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4885 rm -f conftest.err conftest.$ac_ext
4886 if $ac_preproc_ok; then :
4887 break
4890 done
4891 ac_cv_prog_CPP=$CPP
4894 CPP=$ac_cv_prog_CPP
4895 else
4896 ac_cv_prog_CPP=$CPP
4898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4899 $as_echo "$CPP" >&6; }
4900 ac_preproc_ok=false
4901 for ac_c_preproc_warn_flag in '' yes
4903 # Use a header file that comes with gcc, so configuring glibc
4904 # with a fresh cross-compiler works.
4905 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4906 # <limits.h> exists even on freestanding compilers.
4907 # On the NeXT, cc -E runs the code through the compiler's parser,
4908 # not just through cpp. "Syntax error" is here to catch this case.
4909 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4910 /* end confdefs.h. */
4911 #ifdef __STDC__
4912 # include <limits.h>
4913 #else
4914 # include <assert.h>
4915 #endif
4916 Syntax error
4917 _ACEOF
4918 if ac_fn_c_try_cpp "$LINENO"; then :
4920 else
4921 # Broken: fails on valid input.
4922 continue
4924 rm -f conftest.err conftest.$ac_ext
4926 # OK, works on sane cases. Now check whether nonexistent headers
4927 # can be detected and how.
4928 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4929 /* end confdefs.h. */
4930 #include <ac_nonexistent.h>
4931 _ACEOF
4932 if ac_fn_c_try_cpp "$LINENO"; then :
4933 # Broken: success on invalid input.
4934 continue
4935 else
4936 # Passes both tests.
4937 ac_preproc_ok=:
4938 break
4940 rm -f conftest.err conftest.$ac_ext
4942 done
4943 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4944 rm -f conftest.err conftest.$ac_ext
4945 if $ac_preproc_ok; then :
4947 else
4948 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4949 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4950 as_fn_error "C preprocessor \"$CPP\" fails sanity check
4951 See \`config.log' for more details." "$LINENO" 5; }
4954 ac_ext=c
4955 ac_cpp='$CPP $CPPFLAGS'
4956 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4957 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4958 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4960 # Find a good install program. We prefer a C program (faster),
4961 # so one script is as good as another. But avoid the broken or
4962 # incompatible versions:
4963 # SysV /etc/install, /usr/sbin/install
4964 # SunOS /usr/etc/install
4965 # IRIX /sbin/install
4966 # AIX /bin/install
4967 # AmigaOS /C/install, which installs bootblocks on floppy discs
4968 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
4969 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
4970 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
4971 # OS/2's system install, which has a completely different semantic
4972 # ./install, which can be erroneously created by make from ./install.sh.
4973 # Reject install programs that cannot install multiple files.
4974 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
4975 $as_echo_n "checking for a BSD-compatible install... " >&6; }
4976 if test -z "$INSTALL"; then
4977 if test "${ac_cv_path_install+set}" = set; then :
4978 $as_echo_n "(cached) " >&6
4979 else
4980 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4981 for as_dir in $PATH
4983 IFS=$as_save_IFS
4984 test -z "$as_dir" && as_dir=.
4985 # Account for people who put trailing slashes in PATH elements.
4986 case $as_dir/ in #((
4987 ./ | .// | /[cC]/* | \
4988 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
4989 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
4990 /usr/ucb/* ) ;;
4992 # OSF1 and SCO ODT 3.0 have their own names for install.
4993 # Don't use installbsd from OSF since it installs stuff as root
4994 # by default.
4995 for ac_prog in ginstall scoinst install; do
4996 for ac_exec_ext in '' $ac_executable_extensions; do
4997 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
4998 if test $ac_prog = install &&
4999 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
5000 # AIX install. It has an incompatible calling convention.
5002 elif test $ac_prog = install &&
5003 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
5004 # program-specific install script used by HP pwplus--don't use.
5006 else
5007 rm -rf conftest.one conftest.two conftest.dir
5008 echo one > conftest.one
5009 echo two > conftest.two
5010 mkdir conftest.dir
5011 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
5012 test -s conftest.one && test -s conftest.two &&
5013 test -s conftest.dir/conftest.one &&
5014 test -s conftest.dir/conftest.two
5015 then
5016 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
5017 break 3
5021 done
5022 done
5024 esac
5026 done
5027 IFS=$as_save_IFS
5029 rm -rf conftest.one conftest.two conftest.dir
5032 if test "${ac_cv_path_install+set}" = set; then
5033 INSTALL=$ac_cv_path_install
5034 else
5035 # As a last resort, use the slow shell script. Don't cache a
5036 # value for INSTALL within a source directory, because that will
5037 # break other packages using the cache if that directory is
5038 # removed, or if the value is a relative name.
5039 INSTALL=$ac_install_sh
5042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
5043 $as_echo "$INSTALL" >&6; }
5045 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
5046 # It thinks the first close brace ends the variable substitution.
5047 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
5049 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
5051 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
5053 if test "x$RANLIB" = x; then
5054 if test -n "$ac_tool_prefix"; then
5055 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5056 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5058 $as_echo_n "checking for $ac_word... " >&6; }
5059 if test "${ac_cv_prog_RANLIB+set}" = set; then :
5060 $as_echo_n "(cached) " >&6
5061 else
5062 if test -n "$RANLIB"; then
5063 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5064 else
5065 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5066 for as_dir in $PATH
5068 IFS=$as_save_IFS
5069 test -z "$as_dir" && as_dir=.
5070 for ac_exec_ext in '' $ac_executable_extensions; do
5071 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5072 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5073 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5074 break 2
5076 done
5077 done
5078 IFS=$as_save_IFS
5082 RANLIB=$ac_cv_prog_RANLIB
5083 if test -n "$RANLIB"; then
5084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
5085 $as_echo "$RANLIB" >&6; }
5086 else
5087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5088 $as_echo "no" >&6; }
5093 if test -z "$ac_cv_prog_RANLIB"; then
5094 ac_ct_RANLIB=$RANLIB
5095 # Extract the first word of "ranlib", so it can be a program name with args.
5096 set dummy ranlib; ac_word=$2
5097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5098 $as_echo_n "checking for $ac_word... " >&6; }
5099 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
5100 $as_echo_n "(cached) " >&6
5101 else
5102 if test -n "$ac_ct_RANLIB"; then
5103 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5104 else
5105 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5106 for as_dir in $PATH
5108 IFS=$as_save_IFS
5109 test -z "$as_dir" && as_dir=.
5110 for ac_exec_ext in '' $ac_executable_extensions; do
5111 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5112 ac_cv_prog_ac_ct_RANLIB="ranlib"
5113 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5114 break 2
5116 done
5117 done
5118 IFS=$as_save_IFS
5122 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5123 if test -n "$ac_ct_RANLIB"; then
5124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
5125 $as_echo "$ac_ct_RANLIB" >&6; }
5126 else
5127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5128 $as_echo "no" >&6; }
5131 if test "x$ac_ct_RANLIB" = x; then
5132 RANLIB=":"
5133 else
5134 case $cross_compiling:$ac_tool_warned in
5135 yes:)
5136 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5137 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5138 ac_tool_warned=yes ;;
5139 esac
5140 RANLIB=$ac_ct_RANLIB
5142 else
5143 RANLIB="$ac_cv_prog_RANLIB"
5148 ## Although we're running on an amd64 kernel, we're actually compiling for
5149 ## the x86 architecture. The user should probably have provided an
5150 ## explicit --build to `configure', but if everything else than the kernel
5151 ## is running in i386 mode, we can help them out.
5152 if test "$machine" = "amdx86-64"; then
5153 ac_fn_c_check_decl "$LINENO" "i386" "ac_cv_have_decl_i386" "$ac_includes_default"
5154 if test "x$ac_cv_have_decl_i386" = x""yes; then :
5158 if test "$ac_cv_have_decl_i386" = "yes"; then
5159 canonical=`echo "$canonical" | sed -e 's/^amd64/i386/' -e 's/^x86_64/i386/'`
5160 machine=intel386
5161 machfile="m/${machine}.h"
5165 # Extract the first word of "install-info", so it can be a program name with args.
5166 set dummy install-info; ac_word=$2
5167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5168 $as_echo_n "checking for $ac_word... " >&6; }
5169 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
5170 $as_echo_n "(cached) " >&6
5171 else
5172 case $INSTALL_INFO in
5173 [\\/]* | ?:[\\/]*)
5174 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
5177 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5178 for as_dir in $PATH
5180 IFS=$as_save_IFS
5181 test -z "$as_dir" && as_dir=.
5182 for ac_exec_ext in '' $ac_executable_extensions; do
5183 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5184 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
5185 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5186 break 2
5188 done
5189 done
5190 IFS=$as_save_IFS
5193 esac
5195 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
5196 if test -n "$INSTALL_INFO"; then
5197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
5198 $as_echo "$INSTALL_INFO" >&6; }
5199 else
5200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5201 $as_echo "no" >&6; }
5205 # Extract the first word of "install-info", so it can be a program name with args.
5206 set dummy install-info; ac_word=$2
5207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5208 $as_echo_n "checking for $ac_word... " >&6; }
5209 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
5210 $as_echo_n "(cached) " >&6
5211 else
5212 case $INSTALL_INFO in
5213 [\\/]* | ?:[\\/]*)
5214 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
5217 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5218 for as_dir in /usr/sbin
5220 IFS=$as_save_IFS
5221 test -z "$as_dir" && as_dir=.
5222 for ac_exec_ext in '' $ac_executable_extensions; do
5223 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5224 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
5225 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5226 break 2
5228 done
5229 done
5230 IFS=$as_save_IFS
5233 esac
5235 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
5236 if test -n "$INSTALL_INFO"; then
5237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
5238 $as_echo "$INSTALL_INFO" >&6; }
5239 else
5240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5241 $as_echo "no" >&6; }
5245 # Extract the first word of "install-info", so it can be a program name with args.
5246 set dummy install-info; ac_word=$2
5247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5248 $as_echo_n "checking for $ac_word... " >&6; }
5249 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
5250 $as_echo_n "(cached) " >&6
5251 else
5252 case $INSTALL_INFO in
5253 [\\/]* | ?:[\\/]*)
5254 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
5257 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5258 for as_dir in /sbin
5260 IFS=$as_save_IFS
5261 test -z "$as_dir" && as_dir=.
5262 for ac_exec_ext in '' $ac_executable_extensions; do
5263 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5264 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
5265 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5266 break 2
5268 done
5269 done
5270 IFS=$as_save_IFS
5272 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
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 "gzip", so it can be a program name with args.
5287 set dummy gzip; 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_GZIP_PROG+set}" = set; then :
5291 $as_echo_n "(cached) " >&6
5292 else
5293 case $GZIP_PROG in
5294 [\\/]* | ?:[\\/]*)
5295 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
5298 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5299 for as_dir in $PATH
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_GZIP_PROG="$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 GZIP_PROG=$ac_cv_path_GZIP_PROG
5317 if test -n "$GZIP_PROG"; then
5318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
5319 $as_echo "$GZIP_PROG" >&6; }
5320 else
5321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5322 $as_echo "no" >&6; }
5328 ## Need makeinfo >= 4.6 (?) to build the manuals.
5329 # Extract the first word of "makeinfo", so it can be a program name with args.
5330 set dummy makeinfo; ac_word=$2
5331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5332 $as_echo_n "checking for $ac_word... " >&6; }
5333 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
5334 $as_echo_n "(cached) " >&6
5335 else
5336 case $MAKEINFO in
5337 [\\/]* | ?:[\\/]*)
5338 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
5341 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5342 for as_dir in $PATH
5344 IFS=$as_save_IFS
5345 test -z "$as_dir" && as_dir=.
5346 for ac_exec_ext in '' $ac_executable_extensions; do
5347 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5348 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
5349 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5350 break 2
5352 done
5353 done
5354 IFS=$as_save_IFS
5356 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
5358 esac
5360 MAKEINFO=$ac_cv_path_MAKEINFO
5361 if test -n "$MAKEINFO"; then
5362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
5363 $as_echo "$MAKEINFO" >&6; }
5364 else
5365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5366 $as_echo "no" >&6; }
5370 if test "$MAKEINFO" != "no" && \
5371 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
5372 MAKEINFO=no
5375 ## Makeinfo is unusual. For a released Emacs, the manuals are
5376 ## pre-built, and not deleted by the normal clean rules. makeinfo is
5377 ## therefore in the category of "special tools" not normally required, which
5378 ## configure does not have to check for (eg autoconf itself).
5379 ## In a Bazaar checkout on the other hand, the manuals are not included.
5380 ## So makeinfo is a requirement to build from Bazaar, and configure
5381 ## should test for it as it does for any other build requirement.
5382 ## We use the presence of $srcdir/info/emacs to distinguish a release,
5383 ## with pre-built manuals, from a Bazaar checkout.
5384 if test "$MAKEINFO" = "no"; then
5385 if test "x${with_makeinfo}" = "xno"; then
5386 MAKEINFO=off
5387 elif test ! -e $srcdir/info/emacs; then
5388 as_fn_error "You do not seem to have makeinfo >= 4.6, and your
5389 source tree does not seem to have pre-built manuals in the \`info' directory.
5390 Either install a suitable version of makeinfo, or re-run configure
5391 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
5396 if test x$GCC = xyes && test "x$GCC_LINK_TEST_OPTIONS" != x
5397 then
5398 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
5401 if test x$GCC = x && test "x$NON_GCC_LINK_TEST_OPTIONS" != x
5402 then
5403 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
5407 late_LDFLAGS=$LDFLAGS
5408 if test "$GCC" = yes; then
5409 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
5410 else
5411 LDFLAGS="$LDFLAGS -znocombreloc"
5414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
5415 $as_echo_n "checking for -znocombreloc... " >&6; }
5416 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5417 /* end confdefs.h. */
5418 main(){return 0;}
5419 _ACEOF
5420 if ac_fn_c_try_link "$LINENO"; then :
5421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5422 $as_echo "yes" >&6; }
5423 else
5424 LDFLAGS=$late_LDFLAGS
5425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5426 $as_echo "no" >&6; }
5428 rm -f core conftest.err conftest.$ac_objext \
5429 conftest$ac_exeext conftest.$ac_ext
5431 #### Extract some information from the operating system and machine files.
5433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the machine- and system-dependent files to find out
5434 - which libraries the lib-src programs will want, and
5435 - whether the GNU malloc routines are usable..." >&5
5436 $as_echo "$as_me: checking the machine- and system-dependent files to find out
5437 - which libraries the lib-src programs will want, and
5438 - whether the GNU malloc routines are usable..." >&6;}
5440 ### First figure out CFLAGS (which we use for running the compiler here)
5441 ### and REAL_CFLAGS (which we use for real compilation).
5442 ### The two are the same except on a few systems, where they are made
5443 ### different to work around various lossages. For example,
5444 ### GCC 2.5 on GNU/Linux needs them to be different because it treats -g
5445 ### as implying static linking.
5447 ### If the CFLAGS env var is specified, we use that value
5448 ### instead of the default.
5450 ### It's not important that this name contain the PID; you can't run
5451 ### two configures in the same directory and have anything work
5452 ### anyway.
5453 tempcname="conftest.c"
5455 echo '
5456 #include "'${srcdir}'/src/'${opsysfile}'"
5457 #include "'${srcdir}'/src/'${machfile}'"
5459 configure___ LIBX=-lX11
5461 #ifdef CANNOT_DUMP
5462 configure___ cannot_dump=yes
5463 #else
5464 configure___ cannot_dump=no
5465 #endif
5467 #ifdef SYSTEM_MALLOC
5468 configure___ system_malloc=yes
5469 #else
5470 configure___ system_malloc=no
5471 #endif
5473 #ifdef USE_MMAP_FOR_BUFFERS
5474 configure___ use_mmap_for_buffers=yes
5475 #else
5476 configure___ use_mmap_for_buffers=no
5477 #endif
5479 #ifndef C_OPTIMIZE_SWITCH
5480 #ifdef __GNUC__
5481 #define C_OPTIMIZE_SWITCH -O2
5482 #else
5483 #define C_OPTIMIZE_SWITCH -O
5484 #endif
5485 #endif
5487 #ifndef C_WARNINGS_SWITCH
5488 #define C_WARNINGS_SWITCH ${C_WARNINGS_SWITCH}
5489 #endif
5491 #ifdef THIS_IS_CONFIGURE
5493 /* Get the CFLAGS for tests in configure. */
5494 #ifdef __GNUC__
5495 configure___ CFLAGS=-g C_OPTIMIZE_SWITCH '${SPECIFIED_CFLAGS}'
5496 #else
5497 configure___ CFLAGS='${SPECIFIED_CFLAGS}'
5498 #endif
5500 #else /* not THIS_IS_CONFIGURE */
5502 /* Get the CFLAGS for real compilation. */
5503 #ifdef __GNUC__
5504 configure___ REAL_CFLAGS=-g C_OPTIMIZE_SWITCH C_WARNINGS_SWITCH ${PROFILING_CFLAGS} '${SPECIFIED_CFLAGS}'
5505 #else
5506 configure___ REAL_CFLAGS='${SPECIFIED_CFLAGS}'
5507 #endif
5509 #endif /* not THIS_IS_CONFIGURE */
5510 ' > ${tempcname}
5512 LDFLAGS="${LDFLAGS} ${PROFILING_LDFLAGS}"
5514 # The value of CPP is a quoted variable reference, so we need to do this
5515 # to get its actual value...
5516 CPP=`eval "echo $CPP"`
5517 eval `${CPP} -Isrc ${tempcname} \
5518 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
5519 if test "x$SPECIFIED_CFLAGS" = x; then
5520 eval `${CPP} -Isrc -DTHIS_IS_CONFIGURE ${tempcname} \
5521 | sed -n -e 's/^configure___ \([^=]*=\)\(.*\)$/\1"\2"/p'`
5522 else
5523 REAL_CFLAGS="$CFLAGS"
5525 rm ${tempcname}
5530 UNEXEC_OBJ=unexelf.o
5531 case "$opsys" in
5532 aix4-2)
5533 UNEXEC_OBJ=unexaix.o
5535 cygwin)
5536 UNEXEC_OBJ=unexcw.o
5538 darwin)
5539 UNEXEC_OBJ=unexmacosx.o
5541 hpux10-20 | hpux11)
5542 UNEXEC_OBJ=unexhp9k800.o
5544 sol2-10)
5545 # Use the Solaris dldump() function, called from unexsol.c, to dump
5546 # emacs, instead of the generic ELF dump code found in unexelf.c.
5547 # The resulting binary has a complete symbol table, and is better
5548 # for debugging and other observability tools (debuggers, pstack, etc).
5550 # If you encounter a problem using dldump(), please consider sending
5551 # a message to the OpenSolaris tools-linking mailing list:
5552 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
5554 # It is likely that dldump() works with older Solaris too, but this has
5555 # not been tested, so for now this change is for Solaris 10 or newer.
5556 UNEXEC_OBJ=unexsol.o
5558 esac
5560 LD_SWITCH_SYSTEM=
5561 case "$opsys" in
5562 freebsd)
5563 ## Let `ld' find image libs and similar things in /usr/local/lib.
5564 ## The system compiler, GCC, has apparently been modified to not
5565 ## look there, contrary to what a stock GCC would do.
5566 LD_SWITCH_SYSTEM=-L/usr/local/lib
5569 gnu-linux)
5570 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
5571 test "$machine" = "mips" && LD_SWITCH_SYSTEM="-G 0"
5574 netbsd)
5575 LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
5578 openbsd)
5579 ## Han Boetes <han@mijncomputer.nl> says this is necessary,
5580 ## otherwise Emacs dumps core on elf systems.
5581 LD_SWITCH_SYSTEM="-Z"
5583 esac
5586 ac_link="$ac_link $LD_SWITCH_SYSTEM"
5588 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_AUX,
5589 ## which has not been defined yet. When this was handled with cpp,
5590 ## it was expanded to null when configure sourced the s/*.h file.
5591 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
5592 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
5593 ## (or somesuch), but because it is supposed to go at the _front_
5594 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
5595 ## Compare with the gnu-linux case below, which added to the end
5596 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
5597 ## LD_SWITCH_SYSTEM_TEMACS.
5598 case "$opsys" in
5599 netbsd|openbsd)
5600 ## _AUX_RPATH is like _AUX, but uses -rpath instead of -R.
5601 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_AUX_RPATH) $LD_SWITCH_SYSTEM" ;;
5602 esac
5605 C_SWITCH_MACHINE=
5606 if test "$machine" = "alpha"; then
5607 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
5608 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
5612 if test "$ac_cv_have_decl___ELF__" = "yes"; then
5613 ## With ELF, make sure that all common symbols get allocated to in the
5614 ## data section. Otherwise, the dump of temacs may miss variables in
5615 ## the shared library that have been initialized. For example, with
5616 ## GNU libc, __malloc_initialized would normally be resolved to the
5617 ## shared library's .bss section, which is fatal.
5618 if test "x$GCC" = "xyes"; then
5619 C_SWITCH_MACHINE="-fno-common"
5620 else
5621 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
5623 else
5624 UNEXEC_OBJ=unexalpha.o
5631 C_SWITCH_SYSTEM=
5632 ## Some programs in src produce warnings saying certain subprograms
5633 ## are too complex and need a MAXMEM value greater than 2000 for
5634 ## additional optimization. --nils@exp-math.uni-essen.de
5635 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
5636 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
5637 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
5638 ## It is redundant in glibc2, since we define _GNU_SOURCE.
5642 LIBS_SYSTEM=
5643 case "$opsys" in
5644 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
5645 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
5647 freebsd) LIBS_SYSTEM="-lutil" ;;
5649 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
5651 sol2*) LIBS_SYSTEM="-lsocket -lnsl -lkstat" ;;
5653 ## Motif needs -lgen.
5654 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
5655 esac
5659 ### Make sure subsequent tests use flags consistent with the build flags.
5661 if test x"${OVERRIDE_CPPFLAGS}" != x; then
5662 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
5663 else
5664 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
5669 # Check whether --enable-largefile was given.
5670 if test "${enable_largefile+set}" = set; then :
5671 enableval=$enable_largefile;
5674 if test "$enable_largefile" != no; then
5676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
5677 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
5678 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
5679 $as_echo_n "(cached) " >&6
5680 else
5681 ac_cv_sys_largefile_CC=no
5682 if test "$GCC" != yes; then
5683 ac_save_CC=$CC
5684 while :; do
5685 # IRIX 6.2 and later do not support large files by default,
5686 # so use the C compiler's -n32 option if that helps.
5687 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5688 /* end confdefs.h. */
5689 #include <sys/types.h>
5690 /* Check that off_t can represent 2**63 - 1 correctly.
5691 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5692 since some C++ compilers masquerading as C compilers
5693 incorrectly reject 9223372036854775807. */
5694 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5695 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5696 && LARGE_OFF_T % 2147483647 == 1)
5697 ? 1 : -1];
5699 main ()
5703 return 0;
5705 _ACEOF
5706 if ac_fn_c_try_compile "$LINENO"; then :
5707 break
5709 rm -f core conftest.err conftest.$ac_objext
5710 CC="$CC -n32"
5711 if ac_fn_c_try_compile "$LINENO"; then :
5712 ac_cv_sys_largefile_CC=' -n32'; break
5714 rm -f core conftest.err conftest.$ac_objext
5715 break
5716 done
5717 CC=$ac_save_CC
5718 rm -f conftest.$ac_ext
5721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
5722 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
5723 if test "$ac_cv_sys_largefile_CC" != no; then
5724 CC=$CC$ac_cv_sys_largefile_CC
5727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
5728 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
5729 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
5730 $as_echo_n "(cached) " >&6
5731 else
5732 while :; do
5733 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5734 /* end confdefs.h. */
5735 #include <sys/types.h>
5736 /* Check that off_t can represent 2**63 - 1 correctly.
5737 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5738 since some C++ compilers masquerading as C compilers
5739 incorrectly reject 9223372036854775807. */
5740 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5741 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5742 && LARGE_OFF_T % 2147483647 == 1)
5743 ? 1 : -1];
5745 main ()
5749 return 0;
5751 _ACEOF
5752 if ac_fn_c_try_compile "$LINENO"; then :
5753 ac_cv_sys_file_offset_bits=no; break
5755 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5757 /* end confdefs.h. */
5758 #define _FILE_OFFSET_BITS 64
5759 #include <sys/types.h>
5760 /* Check that off_t can represent 2**63 - 1 correctly.
5761 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5762 since some C++ compilers masquerading as C compilers
5763 incorrectly reject 9223372036854775807. */
5764 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5765 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5766 && LARGE_OFF_T % 2147483647 == 1)
5767 ? 1 : -1];
5769 main ()
5773 return 0;
5775 _ACEOF
5776 if ac_fn_c_try_compile "$LINENO"; then :
5777 ac_cv_sys_file_offset_bits=64; break
5779 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5780 ac_cv_sys_file_offset_bits=unknown
5781 break
5782 done
5784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
5785 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
5786 case $ac_cv_sys_file_offset_bits in #(
5787 no | unknown) ;;
5789 cat >>confdefs.h <<_ACEOF
5790 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
5791 _ACEOF
5793 esac
5794 rm -rf conftest*
5795 if test $ac_cv_sys_file_offset_bits = unknown; then
5796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
5797 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
5798 if test "${ac_cv_sys_large_files+set}" = set; then :
5799 $as_echo_n "(cached) " >&6
5800 else
5801 while :; do
5802 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5803 /* end confdefs.h. */
5804 #include <sys/types.h>
5805 /* Check that off_t can represent 2**63 - 1 correctly.
5806 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5807 since some C++ compilers masquerading as C compilers
5808 incorrectly reject 9223372036854775807. */
5809 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5810 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5811 && LARGE_OFF_T % 2147483647 == 1)
5812 ? 1 : -1];
5814 main ()
5818 return 0;
5820 _ACEOF
5821 if ac_fn_c_try_compile "$LINENO"; then :
5822 ac_cv_sys_large_files=no; break
5824 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5826 /* end confdefs.h. */
5827 #define _LARGE_FILES 1
5828 #include <sys/types.h>
5829 /* Check that off_t can represent 2**63 - 1 correctly.
5830 We can't simply define LARGE_OFF_T to be 9223372036854775807,
5831 since some C++ compilers masquerading as C compilers
5832 incorrectly reject 9223372036854775807. */
5833 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5834 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5835 && LARGE_OFF_T % 2147483647 == 1)
5836 ? 1 : -1];
5838 main ()
5842 return 0;
5844 _ACEOF
5845 if ac_fn_c_try_compile "$LINENO"; then :
5846 ac_cv_sys_large_files=1; break
5848 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5849 ac_cv_sys_large_files=unknown
5850 break
5851 done
5853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
5854 $as_echo "$ac_cv_sys_large_files" >&6; }
5855 case $ac_cv_sys_large_files in #(
5856 no | unknown) ;;
5858 cat >>confdefs.h <<_ACEOF
5859 #define _LARGE_FILES $ac_cv_sys_large_files
5860 _ACEOF
5862 esac
5863 rm -rf conftest*
5869 ## If user specified a crt-dir, use that unconditionally.
5870 if test "X$CRT_DIR" = "X"; then
5872 case "$canonical" in
5873 x86_64-*-linux-gnu* | s390x-*-linux-gnu*)
5874 ## On x86-64 and s390x GNU/Linux distributions, the standard library
5875 ## can be in a variety of places. We only try /usr/lib64 and /usr/lib.
5876 ## For anything else (eg /usr/lib32), it is up the user to specify
5877 ## the location (bug#5655).
5878 ## Test for crtn.o, not just the directory, because sometimes the
5879 ## directory exists but does not have the relevant files (bug#1287).
5880 ## FIXME better to test for binary compatibility somehow.
5881 test -e /usr/lib64/crtn.o && CRT_DIR=/usr/lib64
5884 powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*) CRT_DIR=/usr/lib64 ;;
5885 esac
5887 case "$opsys" in
5888 hpux10-20) CRT_DIR=/lib ;;
5889 esac
5891 ## Default is /usr/lib.
5892 test "X$CRT_DIR" = "X" && CRT_DIR=/usr/lib
5894 else
5896 ## Some platforms don't use any of these files, so it is not
5897 ## appropriate to put this test outside the if block.
5898 test -e $CRT_DIR/crtn.o || test -e $CRT_DIR/crt0.o || \
5899 as_fn_error "crt*.o not found in specified location." "$LINENO" 5
5905 LIB_MATH=-lm
5906 LIB_STANDARD=
5907 START_FILES=
5909 case $opsys in
5910 cygwin )
5911 LIB_MATH=
5912 START_FILES='ecrt0.o'
5914 darwin )
5915 ## Adding -lm confuses the dynamic linker, so omit it.
5916 LIB_MATH=
5917 START_FILES='pre-crt0.o'
5919 freebsd )
5920 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
5921 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
5923 gnu-linux | gnu-kfreebsd )
5924 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
5925 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
5927 hpux10-20 | hpux11 )
5928 LIB_STANDARD=-lc
5929 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o'
5931 netbsd | openbsd )
5932 if test -f $CRT_DIR/crti.o; then
5933 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
5934 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
5935 else
5936 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
5937 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
5940 esac
5948 if test "${with_sound}" != "no"; then
5949 # Sound support for GNU/Linux and the free BSDs.
5950 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
5951 do :
5952 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
5953 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
5954 eval as_val=\$$as_ac_Header
5955 if test "x$as_val" = x""yes; then :
5956 cat >>confdefs.h <<_ACEOF
5957 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
5958 _ACEOF
5962 done
5964 # Emulation library used on NetBSD.
5965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
5966 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
5967 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
5968 $as_echo_n "(cached) " >&6
5969 else
5970 ac_check_lib_save_LIBS=$LIBS
5971 LIBS="-lossaudio $LIBS"
5972 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5973 /* end confdefs.h. */
5975 /* Override any GCC internal prototype to avoid an error.
5976 Use char because int might match the return type of a GCC
5977 builtin and then its argument prototype would still apply. */
5978 #ifdef __cplusplus
5979 extern "C"
5980 #endif
5981 char _oss_ioctl ();
5983 main ()
5985 return _oss_ioctl ();
5987 return 0;
5989 _ACEOF
5990 if ac_fn_c_try_link "$LINENO"; then :
5991 ac_cv_lib_ossaudio__oss_ioctl=yes
5992 else
5993 ac_cv_lib_ossaudio__oss_ioctl=no
5995 rm -f core conftest.err conftest.$ac_objext \
5996 conftest$ac_exeext conftest.$ac_ext
5997 LIBS=$ac_check_lib_save_LIBS
5999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
6000 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
6001 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
6002 LIBSOUND=-lossaudio
6003 else
6004 LIBSOUND=
6009 ALSA_REQUIRED=1.0.0
6010 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
6012 succeeded=no
6014 # Extract the first word of "pkg-config", so it can be a program name with args.
6015 set dummy pkg-config; ac_word=$2
6016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6017 $as_echo_n "checking for $ac_word... " >&6; }
6018 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
6019 $as_echo_n "(cached) " >&6
6020 else
6021 case $PKG_CONFIG in
6022 [\\/]* | ?:[\\/]*)
6023 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
6026 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6027 for as_dir in $PATH
6029 IFS=$as_save_IFS
6030 test -z "$as_dir" && as_dir=.
6031 for ac_exec_ext in '' $ac_executable_extensions; do
6032 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6033 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
6034 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6035 break 2
6037 done
6038 done
6039 IFS=$as_save_IFS
6041 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
6043 esac
6045 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
6046 if test -n "$PKG_CONFIG"; then
6047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
6048 $as_echo "$PKG_CONFIG" >&6; }
6049 else
6050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6051 $as_echo "no" >&6; }
6056 if test "$PKG_CONFIG" = "no" ; then
6057 HAVE_ALSA=no
6058 else
6059 PKG_CONFIG_MIN_VERSION=0.9.0
6060 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
6061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
6062 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
6064 if $PKG_CONFIG --exists "$ALSA_MODULES" 2>&5; then
6065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6066 $as_echo "yes" >&6; }
6067 succeeded=yes
6069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking ALSA_CFLAGS" >&5
6070 $as_echo_n "checking ALSA_CFLAGS... " >&6; }
6071 ALSA_CFLAGS=`$PKG_CONFIG --cflags "$ALSA_MODULES"|sed -e 's,///*,/,g'`
6072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ALSA_CFLAGS" >&5
6073 $as_echo "$ALSA_CFLAGS" >&6; }
6075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking ALSA_LIBS" >&5
6076 $as_echo_n "checking ALSA_LIBS... " >&6; }
6077 ALSA_LIBS=`$PKG_CONFIG --libs "$ALSA_MODULES"|sed -e 's,///*,/,g'`
6078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ALSA_LIBS" >&5
6079 $as_echo "$ALSA_LIBS" >&6; }
6080 else
6081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6082 $as_echo "no" >&6; }
6083 ALSA_CFLAGS=""
6084 ALSA_LIBS=""
6085 ## If we have a custom action on failure, don't print errors, but
6086 ## do set a variable so people can do so.
6087 ALSA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$ALSA_MODULES"`
6093 else
6094 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
6095 echo "*** See http://www.freedesktop.org/software/pkgconfig"
6099 if test $succeeded = yes; then
6100 HAVE_ALSA=yes
6101 else
6102 HAVE_ALSA=no
6105 if test $HAVE_ALSA = yes; then
6106 SAVE_CFLAGS="$CFLAGS"
6107 SAVE_LDFLAGS="$LDFLAGS"
6108 CFLAGS="$ALSA_CFLAGS $CFLAGS"
6109 LDFLAGS="$ALSA_LIBS $LDFLAGS"
6110 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6111 /* end confdefs.h. */
6112 #include <asoundlib.h>
6114 main ()
6116 snd_lib_error_set_handler (0);
6118 return 0;
6120 _ACEOF
6121 if ac_fn_c_try_compile "$LINENO"; then :
6122 emacs_alsa_normal=yes
6123 else
6124 emacs_alsa_normal=no
6126 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6127 if test "$emacs_alsa_normal" != yes; then
6128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6129 /* end confdefs.h. */
6130 #include <alsa/asoundlib.h>
6132 main ()
6134 snd_lib_error_set_handler (0);
6136 return 0;
6138 _ACEOF
6139 if ac_fn_c_try_compile "$LINENO"; then :
6140 emacs_alsa_subdir=yes
6141 else
6142 emacs_alsa_subdir=no
6144 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6145 if test "$emacs_alsa_subdir" != yes; then
6146 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
6148 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
6151 CFLAGS="$SAVE_CFLAGS"
6152 LDFLAGS="$SAVE_LDFLAGS"
6153 LIBSOUND="$LIBSOUND $ALSA_LIBS"
6154 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
6156 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
6162 for ac_header in sys/select.h sys/timeb.h sys/time.h unistd.h utime.h \
6163 linux/version.h sys/systeminfo.h termios.h limits.h string.h stdlib.h \
6164 stdio_ext.h fcntl.h strings.h coff.h pty.h sys/mman.h \
6165 sys/param.h sys/vlimit.h sys/resource.h locale.h sys/_mbstate_t.h \
6166 sys/utsname.h pwd.h utmp.h
6167 do :
6168 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6169 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
6170 eval as_val=\$$as_ac_Header
6171 if test "x$as_val" = x""yes; then :
6172 cat >>confdefs.h <<_ACEOF
6173 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6174 _ACEOF
6178 done
6181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
6182 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
6183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6184 /* end confdefs.h. */
6185 #include <sys/personality.h>
6187 main ()
6189 personality (PER_LINUX32)
6191 return 0;
6193 _ACEOF
6194 if ac_fn_c_try_compile "$LINENO"; then :
6195 emacs_cv_personality_linux32=yes
6196 else
6197 emacs_cv_personality_linux32=no
6199 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
6201 $as_echo "$emacs_cv_personality_linux32" >&6; }
6203 if test $emacs_cv_personality_linux32 = yes; then
6205 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
6209 for ac_header in term.h
6210 do :
6211 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
6212 if test "x$ac_cv_header_term_h" = x""yes; then :
6213 cat >>confdefs.h <<_ACEOF
6214 #define HAVE_TERM_H 1
6215 _ACEOF
6219 done
6221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6222 $as_echo_n "checking for ANSI C header files... " >&6; }
6223 if test "${ac_cv_header_stdc+set}" = set; then :
6224 $as_echo_n "(cached) " >&6
6225 else
6226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6227 /* end confdefs.h. */
6228 #include <stdlib.h>
6229 #include <stdarg.h>
6230 #include <string.h>
6231 #include <float.h>
6234 main ()
6238 return 0;
6240 _ACEOF
6241 if ac_fn_c_try_compile "$LINENO"; then :
6242 ac_cv_header_stdc=yes
6243 else
6244 ac_cv_header_stdc=no
6246 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6248 if test $ac_cv_header_stdc = yes; then
6249 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6251 /* end confdefs.h. */
6252 #include <string.h>
6254 _ACEOF
6255 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6256 $EGREP "memchr" >/dev/null 2>&1; then :
6258 else
6259 ac_cv_header_stdc=no
6261 rm -f conftest*
6265 if test $ac_cv_header_stdc = yes; then
6266 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6267 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6268 /* end confdefs.h. */
6269 #include <stdlib.h>
6271 _ACEOF
6272 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6273 $EGREP "free" >/dev/null 2>&1; then :
6275 else
6276 ac_cv_header_stdc=no
6278 rm -f conftest*
6282 if test $ac_cv_header_stdc = yes; then
6283 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6284 if test "$cross_compiling" = yes; then :
6286 else
6287 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6288 /* end confdefs.h. */
6289 #include <ctype.h>
6290 #include <stdlib.h>
6291 #if ((' ' & 0x0FF) == 0x020)
6292 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6293 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6294 #else
6295 # define ISLOWER(c) \
6296 (('a' <= (c) && (c) <= 'i') \
6297 || ('j' <= (c) && (c) <= 'r') \
6298 || ('s' <= (c) && (c) <= 'z'))
6299 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6300 #endif
6302 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6304 main ()
6306 int i;
6307 for (i = 0; i < 256; i++)
6308 if (XOR (islower (i), ISLOWER (i))
6309 || toupper (i) != TOUPPER (i))
6310 return 2;
6311 return 0;
6313 _ACEOF
6314 if ac_fn_c_try_run "$LINENO"; then :
6316 else
6317 ac_cv_header_stdc=no
6319 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6320 conftest.$ac_objext conftest.beam conftest.$ac_ext
6325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6326 $as_echo "$ac_cv_header_stdc" >&6; }
6327 if test $ac_cv_header_stdc = yes; then
6329 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
6334 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
6335 if test "${ac_cv_header_time+set}" = set; then :
6336 $as_echo_n "(cached) " >&6
6337 else
6338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6339 /* end confdefs.h. */
6340 #include <sys/types.h>
6341 #include <sys/time.h>
6342 #include <time.h>
6345 main ()
6347 if ((struct tm *) 0)
6348 return 0;
6350 return 0;
6352 _ACEOF
6353 if ac_fn_c_try_compile "$LINENO"; then :
6354 ac_cv_header_time=yes
6355 else
6356 ac_cv_header_time=no
6358 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
6361 $as_echo "$ac_cv_header_time" >&6; }
6362 if test $ac_cv_header_time = yes; then
6364 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
6368 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "$ac_includes_default"
6369 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
6370 ac_have_decl=1
6371 else
6372 ac_have_decl=0
6375 cat >>confdefs.h <<_ACEOF
6376 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
6377 _ACEOF
6379 if test $ac_cv_have_decl_sys_siglist != yes; then
6380 # For Tru64, at least:
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
6394 $as_echo "#define sys_siglist __sys_siglist" >>confdefs.h
6398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
6399 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
6400 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
6401 $as_echo_n "(cached) " >&6
6402 else
6403 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6404 /* end confdefs.h. */
6405 #include <sys/types.h>
6406 #include <sys/wait.h>
6407 #ifndef WEXITSTATUS
6408 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
6409 #endif
6410 #ifndef WIFEXITED
6411 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
6412 #endif
6415 main ()
6417 int s;
6418 wait (&s);
6419 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
6421 return 0;
6423 _ACEOF
6424 if ac_fn_c_try_compile "$LINENO"; then :
6425 ac_cv_header_sys_wait_h=yes
6426 else
6427 ac_cv_header_sys_wait_h=no
6429 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
6432 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
6433 if test $ac_cv_header_sys_wait_h = yes; then
6435 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
6440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
6441 $as_echo_n "checking for struct utimbuf... " >&6; }
6442 if test "${emacs_cv_struct_utimbuf+set}" = set; then :
6443 $as_echo_n "(cached) " >&6
6444 else
6445 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6446 /* end confdefs.h. */
6447 #ifdef TIME_WITH_SYS_TIME
6448 #include <sys/time.h>
6449 #include <time.h>
6450 #else
6451 #ifdef HAVE_SYS_TIME_H
6452 #include <sys/time.h>
6453 #else
6454 #include <time.h>
6455 #endif
6456 #endif
6457 #ifdef HAVE_UTIME_H
6458 #include <utime.h>
6459 #endif
6461 main ()
6463 static struct utimbuf x; x.actime = x.modtime;
6465 return 0;
6467 _ACEOF
6468 if ac_fn_c_try_compile "$LINENO"; then :
6469 emacs_cv_struct_utimbuf=yes
6470 else
6471 emacs_cv_struct_utimbuf=no
6473 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_utimbuf" >&5
6476 $as_echo "$emacs_cv_struct_utimbuf" >&6; }
6477 if test $emacs_cv_struct_utimbuf = yes; then
6479 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
6483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
6484 $as_echo_n "checking return type of signal handlers... " >&6; }
6485 if test "${ac_cv_type_signal+set}" = set; then :
6486 $as_echo_n "(cached) " >&6
6487 else
6488 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6489 /* end confdefs.h. */
6490 #include <sys/types.h>
6491 #include <signal.h>
6494 main ()
6496 return *(signal (0, 0)) (0) == 1;
6498 return 0;
6500 _ACEOF
6501 if ac_fn_c_try_compile "$LINENO"; then :
6502 ac_cv_type_signal=int
6503 else
6504 ac_cv_type_signal=void
6506 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
6509 $as_echo "$ac_cv_type_signal" >&6; }
6511 cat >>confdefs.h <<_ACEOF
6512 #define RETSIGTYPE $ac_cv_type_signal
6513 _ACEOF
6517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t" >&5
6518 $as_echo_n "checking for speed_t... " >&6; }
6519 if test "${emacs_cv_speed_t+set}" = set; then :
6520 $as_echo_n "(cached) " >&6
6521 else
6522 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6523 /* end confdefs.h. */
6524 #include <termios.h>
6526 main ()
6528 speed_t x = 1;
6530 return 0;
6532 _ACEOF
6533 if ac_fn_c_try_compile "$LINENO"; then :
6534 emacs_cv_speed_t=yes
6535 else
6536 emacs_cv_speed_t=no
6538 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_speed_t" >&5
6541 $as_echo "$emacs_cv_speed_t" >&6; }
6542 if test $emacs_cv_speed_t = yes; then
6544 $as_echo "#define HAVE_SPEED_T 1" >>confdefs.h
6548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
6549 $as_echo_n "checking for struct timeval... " >&6; }
6550 if test "${emacs_cv_struct_timeval+set}" = set; then :
6551 $as_echo_n "(cached) " >&6
6552 else
6553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6554 /* end confdefs.h. */
6555 #ifdef TIME_WITH_SYS_TIME
6556 #include <sys/time.h>
6557 #include <time.h>
6558 #else
6559 #ifdef HAVE_SYS_TIME_H
6560 #include <sys/time.h>
6561 #else
6562 #include <time.h>
6563 #endif
6564 #endif
6566 main ()
6568 static struct timeval x; x.tv_sec = x.tv_usec;
6570 return 0;
6572 _ACEOF
6573 if ac_fn_c_try_compile "$LINENO"; then :
6574 emacs_cv_struct_timeval=yes
6575 else
6576 emacs_cv_struct_timeval=no
6578 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_timeval" >&5
6581 $as_echo "$emacs_cv_struct_timeval" >&6; }
6582 HAVE_TIMEVAL=$emacs_cv_struct_timeval
6583 if test $emacs_cv_struct_timeval = yes; then
6585 $as_echo "#define HAVE_TIMEVAL 1" >>confdefs.h
6589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct exception" >&5
6590 $as_echo_n "checking for struct exception... " >&6; }
6591 if test "${emacs_cv_struct_exception+set}" = set; then :
6592 $as_echo_n "(cached) " >&6
6593 else
6594 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6595 /* end confdefs.h. */
6596 #include <math.h>
6598 main ()
6600 static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
6602 return 0;
6604 _ACEOF
6605 if ac_fn_c_try_compile "$LINENO"; then :
6606 emacs_cv_struct_exception=yes
6607 else
6608 emacs_cv_struct_exception=no
6610 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_exception" >&5
6613 $as_echo "$emacs_cv_struct_exception" >&6; }
6614 HAVE_EXCEPTION=$emacs_cv_struct_exception
6615 if test $emacs_cv_struct_exception != yes; then
6617 $as_echo "#define NO_MATHERR 1" >>confdefs.h
6621 for ac_header in sys/socket.h
6622 do :
6623 ac_fn_c_check_header_mongrel "$LINENO" "sys/socket.h" "ac_cv_header_sys_socket_h" "$ac_includes_default"
6624 if test "x$ac_cv_header_sys_socket_h" = x""yes; then :
6625 cat >>confdefs.h <<_ACEOF
6626 #define HAVE_SYS_SOCKET_H 1
6627 _ACEOF
6631 done
6633 for ac_header in net/if.h
6634 do :
6635 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
6636 #if HAVE_SYS_SOCKET_H
6637 #include <sys/socket.h>
6638 #endif
6640 if test "x$ac_cv_header_net_if_h" = x""yes; then :
6641 cat >>confdefs.h <<_ACEOF
6642 #define HAVE_NET_IF_H 1
6643 _ACEOF
6647 done
6650 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
6651 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
6652 if test "${ac_cv_struct_tm+set}" = set; then :
6653 $as_echo_n "(cached) " >&6
6654 else
6655 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6656 /* end confdefs.h. */
6657 #include <sys/types.h>
6658 #include <time.h>
6661 main ()
6663 struct tm tm;
6664 int *p = &tm.tm_sec;
6665 return !p;
6667 return 0;
6669 _ACEOF
6670 if ac_fn_c_try_compile "$LINENO"; then :
6671 ac_cv_struct_tm=time.h
6672 else
6673 ac_cv_struct_tm=sys/time.h
6675 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
6678 $as_echo "$ac_cv_struct_tm" >&6; }
6679 if test $ac_cv_struct_tm = sys/time.h; then
6681 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
6685 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
6686 #include <$ac_cv_struct_tm>
6689 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
6691 cat >>confdefs.h <<_ACEOF
6692 #define HAVE_STRUCT_TM_TM_ZONE 1
6693 _ACEOF
6698 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
6700 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
6702 else
6703 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
6705 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
6706 ac_have_decl=1
6707 else
6708 ac_have_decl=0
6711 cat >>confdefs.h <<_ACEOF
6712 #define HAVE_DECL_TZNAME $ac_have_decl
6713 _ACEOF
6715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
6716 $as_echo_n "checking for tzname... " >&6; }
6717 if test "${ac_cv_var_tzname+set}" = set; then :
6718 $as_echo_n "(cached) " >&6
6719 else
6720 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6721 /* end confdefs.h. */
6722 #include <time.h>
6723 #if !HAVE_DECL_TZNAME
6724 extern char *tzname[];
6725 #endif
6728 main ()
6730 return tzname[0][0];
6732 return 0;
6734 _ACEOF
6735 if ac_fn_c_try_link "$LINENO"; then :
6736 ac_cv_var_tzname=yes
6737 else
6738 ac_cv_var_tzname=no
6740 rm -f core conftest.err conftest.$ac_objext \
6741 conftest$ac_exeext conftest.$ac_ext
6743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
6744 $as_echo "$ac_cv_var_tzname" >&6; }
6745 if test $ac_cv_var_tzname = yes; then
6747 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
6752 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
6754 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
6756 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
6760 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
6761 #if HAVE_SYS_SOCKET_H
6762 #include <sys/socket.h>
6763 #endif
6764 #if HAVE_NET_IF_H
6765 #include <net/if.h>
6766 #endif
6768 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
6770 cat >>confdefs.h <<_ACEOF
6771 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
6772 _ACEOF
6776 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
6777 #if HAVE_SYS_SOCKET_H
6778 #include <sys/socket.h>
6779 #endif
6780 #if HAVE_NET_IF_H
6781 #include <net/if.h>
6782 #endif
6784 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
6786 cat >>confdefs.h <<_ACEOF
6787 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
6788 _ACEOF
6792 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
6793 #if HAVE_SYS_SOCKET_H
6794 #include <sys/socket.h>
6795 #endif
6796 #if HAVE_NET_IF_H
6797 #include <net/if.h>
6798 #endif
6800 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
6802 cat >>confdefs.h <<_ACEOF
6803 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
6804 _ACEOF
6808 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
6809 #if HAVE_SYS_SOCKET_H
6810 #include <sys/socket.h>
6811 #endif
6812 #if HAVE_NET_IF_H
6813 #include <net/if.h>
6814 #endif
6816 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
6818 cat >>confdefs.h <<_ACEOF
6819 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
6820 _ACEOF
6824 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
6825 #if HAVE_SYS_SOCKET_H
6826 #include <sys/socket.h>
6827 #endif
6828 #if HAVE_NET_IF_H
6829 #include <net/if.h>
6830 #endif
6832 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
6834 cat >>confdefs.h <<_ACEOF
6835 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
6836 _ACEOF
6843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for function prototypes" >&5
6844 $as_echo_n "checking for function prototypes... " >&6; }
6845 if test "$ac_cv_prog_cc_c89" != no; then
6846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6847 $as_echo "yes" >&6; }
6849 $as_echo "#define PROTOTYPES 1" >>confdefs.h
6852 $as_echo "#define __PROTOTYPES 1" >>confdefs.h
6854 else
6855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6856 $as_echo "no" >&6; }
6859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5
6860 $as_echo_n "checking for working volatile... " >&6; }
6861 if test "${ac_cv_c_volatile+set}" = set; then :
6862 $as_echo_n "(cached) " >&6
6863 else
6864 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6865 /* end confdefs.h. */
6868 main ()
6871 volatile int x;
6872 int * volatile y = (int *) 0;
6873 return !x && !y;
6875 return 0;
6877 _ACEOF
6878 if ac_fn_c_try_compile "$LINENO"; then :
6879 ac_cv_c_volatile=yes
6880 else
6881 ac_cv_c_volatile=no
6883 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5
6886 $as_echo "$ac_cv_c_volatile" >&6; }
6887 if test $ac_cv_c_volatile = no; then
6889 $as_echo "#define volatile /**/" >>confdefs.h
6893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
6894 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
6895 if test "${ac_cv_c_const+set}" = set; then :
6896 $as_echo_n "(cached) " >&6
6897 else
6898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6899 /* end confdefs.h. */
6902 main ()
6904 /* FIXME: Include the comments suggested by Paul. */
6905 #ifndef __cplusplus
6906 /* Ultrix mips cc rejects this. */
6907 typedef int charset[2];
6908 const charset cs;
6909 /* SunOS 4.1.1 cc rejects this. */
6910 char const *const *pcpcc;
6911 char **ppc;
6912 /* NEC SVR4.0.2 mips cc rejects this. */
6913 struct point {int x, y;};
6914 static struct point const zero = {0,0};
6915 /* AIX XL C 1.02.0.0 rejects this.
6916 It does not let you subtract one const X* pointer from another in
6917 an arm of an if-expression whose if-part is not a constant
6918 expression */
6919 const char *g = "string";
6920 pcpcc = &g + (g ? g-g : 0);
6921 /* HPUX 7.0 cc rejects these. */
6922 ++pcpcc;
6923 ppc = (char**) pcpcc;
6924 pcpcc = (char const *const *) ppc;
6925 { /* SCO 3.2v4 cc rejects this. */
6926 char *t;
6927 char const *s = 0 ? (char *) 0 : (char const *) 0;
6929 *t++ = 0;
6930 if (s) return 0;
6932 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
6933 int x[] = {25, 17};
6934 const int *foo = &x[0];
6935 ++foo;
6937 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
6938 typedef const int *iptr;
6939 iptr p = 0;
6940 ++p;
6942 { /* AIX XL C 1.02.0.0 rejects this saying
6943 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
6944 struct s { int j; const int *ap[3]; };
6945 struct s *b; b->j = 5;
6947 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
6948 const int foo = 10;
6949 if (!foo) return 0;
6951 return !cs[0] && !zero.x;
6952 #endif
6955 return 0;
6957 _ACEOF
6958 if ac_fn_c_try_compile "$LINENO"; then :
6959 ac_cv_c_const=yes
6960 else
6961 ac_cv_c_const=no
6963 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
6966 $as_echo "$ac_cv_c_const" >&6; }
6967 if test $ac_cv_c_const = no; then
6969 $as_echo "#define const /**/" >>confdefs.h
6973 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for void * support" >&5
6974 $as_echo_n "checking for void * support... " >&6; }
6975 if test "${emacs_cv_void_star+set}" = set; then :
6976 $as_echo_n "(cached) " >&6
6977 else
6978 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6979 /* end confdefs.h. */
6982 main ()
6984 void * foo;
6986 return 0;
6988 _ACEOF
6989 if ac_fn_c_try_compile "$LINENO"; then :
6990 emacs_cv_void_star=yes
6991 else
6992 emacs_cv_void_star=no
6994 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6996 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_void_star" >&5
6997 $as_echo "$emacs_cv_void_star" >&6; }
6998 if test $emacs_cv_void_star = yes; then
6999 $as_echo "#define POINTER_TYPE void" >>confdefs.h
7001 else
7002 $as_echo "#define POINTER_TYPE char" >>confdefs.h
7009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
7010 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
7011 set x ${MAKE-make}
7012 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
7013 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
7014 $as_echo_n "(cached) " >&6
7015 else
7016 cat >conftest.make <<\_ACEOF
7017 SHELL = /bin/sh
7018 all:
7019 @echo '@@@%%%=$(MAKE)=@@@%%%'
7020 _ACEOF
7021 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
7022 case `${MAKE-make} -f conftest.make 2>/dev/null` in
7023 *@@@%%%=?*=@@@%%%*)
7024 eval ac_cv_prog_make_${ac_make}_set=yes;;
7026 eval ac_cv_prog_make_${ac_make}_set=no;;
7027 esac
7028 rm -f conftest.make
7030 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
7031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7032 $as_echo "yes" >&6; }
7033 SET_MAKE=
7034 else
7035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7036 $as_echo "no" >&6; }
7037 SET_MAKE="MAKE=${MAKE-make}"
7041 DEPFLAGS=
7042 MKDEPDIR=":"
7043 deps_frag=deps.mk
7044 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
7045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
7046 $as_echo_n "checking whether we are using GNU Make... " >&6; }
7047 HAVE_GNU_MAKE=no
7048 testval=`make --version 2>/dev/null | grep 'GNU Make'`
7049 if test "x$testval" != x; then
7050 HAVE_GNU_MAKE=yes
7051 else
7052 ac_enable_autodepend=no
7054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
7055 $as_echo "$HAVE_GNU_MAKE" >&6; }
7056 if test $HAVE_GNU_MAKE = yes; then
7057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
7058 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
7059 SAVE_CFLAGS="$CFLAGS"
7060 CFLAGS="$CFLAGS -MMD -MF deps.d"
7061 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7062 /* end confdefs.h. */
7065 main ()
7069 return 0;
7071 _ACEOF
7072 if ac_fn_c_try_compile "$LINENO"; then :
7074 else
7075 ac_enable_autodepend=no
7077 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7078 CFLAGS="$SAVE_CFLAGS"
7079 test -f deps.d || ac_enable_autodepend=no
7080 rm -rf deps.d
7081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
7082 $as_echo "$ac_enable_autodepend" >&6; }
7084 if test $ac_enable_autodepend = yes; then
7085 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d'
7086 ## In parallel builds, another make might create depdir between
7087 ## the first test and mkdir, so stick another test on the end.
7088 ## Or use mkinstalldirs? mkdir -p is not portable.
7089 MKDEPDIR='test -d ${DEPDIR} || mkdir ${DEPDIR} || test -d ${DEPDIR}'
7090 deps_frag=autodeps.mk
7093 deps_frag=$srcdir/src/$deps_frag
7099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
7100 $as_echo_n "checking for long file names... " >&6; }
7101 if test "${ac_cv_sys_long_file_names+set}" = set; then :
7102 $as_echo_n "(cached) " >&6
7103 else
7104 ac_cv_sys_long_file_names=yes
7105 # Test for long file names in all the places we know might matter:
7106 # . the current directory, where building will happen
7107 # $prefix/lib where we will be installing things
7108 # $exec_prefix/lib likewise
7109 # $TMPDIR if set, where it might want to write temporary files
7110 # /tmp where it might want to write temporary files
7111 # /var/tmp likewise
7112 # /usr/tmp likewise
7113 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
7114 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
7115 # in the usual case where exec_prefix is '${prefix}'.
7116 case $ac_dir in #(
7117 . | /* | ?:[\\/]*) ;; #(
7118 *) continue;;
7119 esac
7120 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
7121 ac_xdir=$ac_dir/cf$$
7122 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
7123 ac_tf1=$ac_xdir/conftest9012345
7124 ac_tf2=$ac_xdir/conftest9012346
7125 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
7126 ac_cv_sys_long_file_names=no
7127 rm -f -r "$ac_xdir" 2>/dev/null
7128 test $ac_cv_sys_long_file_names = no && break
7129 done
7131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
7132 $as_echo "$ac_cv_sys_long_file_names" >&6; }
7133 if test $ac_cv_sys_long_file_names = yes; then
7135 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
7140 #### Choose a window system.
7142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
7143 $as_echo_n "checking for X... " >&6; }
7146 # Check whether --with-x was given.
7147 if test "${with_x+set}" = set; then :
7148 withval=$with_x;
7151 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
7152 if test "x$with_x" = xno; then
7153 # The user explicitly disabled X.
7154 have_x=disabled
7155 else
7156 case $x_includes,$x_libraries in #(
7157 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
7158 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
7159 $as_echo_n "(cached) " >&6
7160 else
7161 # One or both of the vars are not set, and there is no cached value.
7162 ac_x_includes=no ac_x_libraries=no
7163 rm -f -r conftest.dir
7164 if mkdir conftest.dir; then
7165 cd conftest.dir
7166 cat >Imakefile <<'_ACEOF'
7167 incroot:
7168 @echo incroot='${INCROOT}'
7169 usrlibdir:
7170 @echo usrlibdir='${USRLIBDIR}'
7171 libdir:
7172 @echo libdir='${LIBDIR}'
7173 _ACEOF
7174 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
7175 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
7176 for ac_var in incroot usrlibdir libdir; do
7177 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
7178 done
7179 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
7180 for ac_extension in a so sl dylib la dll; do
7181 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
7182 test -f "$ac_im_libdir/libX11.$ac_extension"; then
7183 ac_im_usrlibdir=$ac_im_libdir; break
7185 done
7186 # Screen out bogus values from the imake configuration. They are
7187 # bogus both because they are the default anyway, and because
7188 # using them would break gcc on systems where it needs fixed includes.
7189 case $ac_im_incroot in
7190 /usr/include) ac_x_includes= ;;
7191 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
7192 esac
7193 case $ac_im_usrlibdir in
7194 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
7195 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
7196 esac
7198 cd ..
7199 rm -f -r conftest.dir
7202 # Standard set of common directories for X headers.
7203 # Check X11 before X11Rn because it is often a symlink to the current release.
7204 ac_x_header_dirs='
7205 /usr/X11/include
7206 /usr/X11R7/include
7207 /usr/X11R6/include
7208 /usr/X11R5/include
7209 /usr/X11R4/include
7211 /usr/include/X11
7212 /usr/include/X11R7
7213 /usr/include/X11R6
7214 /usr/include/X11R5
7215 /usr/include/X11R4
7217 /usr/local/X11/include
7218 /usr/local/X11R7/include
7219 /usr/local/X11R6/include
7220 /usr/local/X11R5/include
7221 /usr/local/X11R4/include
7223 /usr/local/include/X11
7224 /usr/local/include/X11R7
7225 /usr/local/include/X11R6
7226 /usr/local/include/X11R5
7227 /usr/local/include/X11R4
7229 /usr/X386/include
7230 /usr/x386/include
7231 /usr/XFree86/include/X11
7233 /usr/include
7234 /usr/local/include
7235 /usr/unsupported/include
7236 /usr/athena/include
7237 /usr/local/x11r5/include
7238 /usr/lpp/Xamples/include
7240 /usr/openwin/include
7241 /usr/openwin/share/include'
7243 if test "$ac_x_includes" = no; then
7244 # Guess where to find include files, by looking for Xlib.h.
7245 # First, try using that file with no special directory specified.
7246 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7247 /* end confdefs.h. */
7248 #include <X11/Xlib.h>
7249 _ACEOF
7250 if ac_fn_c_try_cpp "$LINENO"; then :
7251 # We can compile using X headers with no special include directory.
7252 ac_x_includes=
7253 else
7254 for ac_dir in $ac_x_header_dirs; do
7255 if test -r "$ac_dir/X11/Xlib.h"; then
7256 ac_x_includes=$ac_dir
7257 break
7259 done
7261 rm -f conftest.err conftest.$ac_ext
7262 fi # $ac_x_includes = no
7264 if test "$ac_x_libraries" = no; then
7265 # Check for the libraries.
7266 # See if we find them without any special options.
7267 # Don't add to $LIBS permanently.
7268 ac_save_LIBS=$LIBS
7269 LIBS="-lX11 $LIBS"
7270 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7271 /* end confdefs.h. */
7272 #include <X11/Xlib.h>
7274 main ()
7276 XrmInitialize ()
7278 return 0;
7280 _ACEOF
7281 if ac_fn_c_try_link "$LINENO"; then :
7282 LIBS=$ac_save_LIBS
7283 # We can link X programs with no special library path.
7284 ac_x_libraries=
7285 else
7286 LIBS=$ac_save_LIBS
7287 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
7289 # Don't even attempt the hair of trying to link an X program!
7290 for ac_extension in a so sl dylib la dll; do
7291 if test -r "$ac_dir/libX11.$ac_extension"; then
7292 ac_x_libraries=$ac_dir
7293 break 2
7295 done
7296 done
7298 rm -f core conftest.err conftest.$ac_objext \
7299 conftest$ac_exeext conftest.$ac_ext
7300 fi # $ac_x_libraries = no
7302 case $ac_x_includes,$ac_x_libraries in #(
7303 no,* | *,no | *\'*)
7304 # Didn't find X, or a directory has "'" in its name.
7305 ac_cv_have_x="have_x=no";; #(
7307 # Record where we found X for the cache.
7308 ac_cv_have_x="have_x=yes\
7309 ac_x_includes='$ac_x_includes'\
7310 ac_x_libraries='$ac_x_libraries'"
7311 esac
7313 ;; #(
7314 *) have_x=yes;;
7315 esac
7316 eval "$ac_cv_have_x"
7317 fi # $with_x != no
7319 if test "$have_x" != yes; then
7320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
7321 $as_echo "$have_x" >&6; }
7322 no_x=yes
7323 else
7324 # If each of the values was on the command line, it overrides each guess.
7325 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
7326 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
7327 # Update the cache value to reflect the command line values.
7328 ac_cv_have_x="have_x=yes\
7329 ac_x_includes='$x_includes'\
7330 ac_x_libraries='$x_libraries'"
7331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
7332 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
7335 if test "$no_x" = yes; then
7336 window_system=none
7337 else
7338 window_system=x11
7341 ## Workaround for bug in autoconf <= 2.62.
7342 ## http://lists.gnu.org/archive/html/emacs-devel/2008-04/msg01551.html
7343 ## No need to do anything special for these standard directories.
7344 if test -n "${x_libraries}" && test x"${x_libraries}" != xNONE; then
7346 x_libraries=`echo :${x_libraries}: | sed -e 's|:/usr/lib64:|:|g' -e 's|:/lib64:|:|g' -e 's|^:||' -e 's|:$||'`
7350 LD_SWITCH_X_SITE_AUX=
7351 LD_SWITCH_X_SITE_AUX_RPATH=
7352 if test "${x_libraries}" != NONE; then
7353 if test -n "${x_libraries}"; then
7354 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
7355 LD_SWITCH_X_SITE_AUX=-R`echo ${x_libraries} | sed -e "s/:/ -R/g"`
7356 LD_SWITCH_X_SITE_AUX_RPATH=`echo ${LD_SWITCH_X_SITE_AUX} | sed -e 's/-R/-Wl,-rpath,/'`
7358 x_default_search_path=""
7359 x_search_path=${x_libraries}
7360 if test -z "${x_search_path}"; then
7361 x_search_path=/usr/lib
7363 for x_library in `echo ${x_search_path}: | \
7364 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
7365 x_search_path="\
7366 ${x_library}/X11/%L/%T/%N%C%S:\
7367 ${x_library}/X11/%l/%T/%N%C%S:\
7368 ${x_library}/X11/%T/%N%C%S:\
7369 ${x_library}/X11/%L/%T/%N%S:\
7370 ${x_library}/X11/%l/%T/%N%S:\
7371 ${x_library}/X11/%T/%N%S"
7372 if test x"${x_default_search_path}" = x; then
7373 x_default_search_path=${x_search_path}
7374 else
7375 x_default_search_path="${x_search_path}:${x_default_search_path}"
7377 done
7382 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
7383 C_SWITCH_X_SITE=-I`echo ${x_includes} | sed -e "s/:/ -I/g"`
7386 if test x"${x_includes}" = x; then
7387 bitmapdir=/usr/include/X11/bitmaps
7388 else
7389 # accumulate include directories that have X11 bitmap subdirectories
7390 bmd_acc="dummyval"
7391 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
7392 if test -d "${bmd}/X11/bitmaps"; then
7393 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
7395 if test -d "${bmd}/bitmaps"; then
7396 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
7398 done
7399 if test ${bmd_acc} != "dummyval"; then
7400 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
7404 HAVE_NS=no
7405 NS_IMPL_COCOA=no
7406 NS_IMPL_GNUSTEP=no
7407 tmp_CPPFLAGS="$CPPFLAGS"
7408 tmp_CFLAGS="$CFLAGS"
7409 CPPFLAGS="$CPPFLAGS -x objective-c"
7410 CFLAGS="$CFLAGS -x objective-c"
7411 TEMACS_LDFLAGS2="\${LDFLAGS}"
7412 if test "${with_ns}" != no; then
7413 if test "${opsys}" = darwin; then
7414 NS_IMPL_COCOA=yes
7415 ns_appdir=`pwd`/nextstep/Emacs.app/
7416 ns_appbindir=${ns_appdir}Contents/MacOS/
7417 ns_appresdir=${ns_appdir}Contents/Resources
7418 ns_appsrc=${srcdir}/nextstep/Cocoa/Emacs.base
7419 elif test -f $GNUSTEP_CONFIG_FILE; then
7420 NS_IMPL_GNUSTEP=yes
7421 ns_appdir=`pwd`/nextstep/Emacs.app/
7422 ns_appbindir=${ns_appdir}
7423 ns_appresdir=${ns_appdir}Resources
7424 ns_appsrc=${srcdir}/nextstep/GNUstep/Emacs.base
7425 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
7426 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
7427 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
7428 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
7429 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
7430 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
7431 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
7432 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
7433 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
7434 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
7435 REAL_CFLAGS="$REAL_CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
7436 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
7437 LIB_STANDARD=
7438 START_FILES=
7439 TEMACS_LDFLAGS2=
7441 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
7442 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
7443 HAVE_NS=yes
7444 else
7445 as_fn_error "\`--with-ns' was specified, but the include
7446 files are missing or cannot be compiled." "$LINENO" 5
7450 NS_HAVE_NSINTEGER=yes
7451 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7452 /* end confdefs.h. */
7453 #include <Foundation/NSObjCRuntime.h>
7455 main ()
7457 NSInteger i;
7459 return 0;
7461 _ACEOF
7462 if ac_fn_c_try_compile "$LINENO"; then :
7463 ns_have_nsinteger=yes
7464 else
7465 ns_have_nsinteger=no
7467 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7468 if test $ns_have_nsinteger = no; then
7469 NS_HAVE_NSINTEGER=no
7474 ns_frag=/dev/null
7475 NS_OBJ=
7476 NS_SUPPORT=
7477 if test "${HAVE_NS}" = yes; then
7478 window_system=nextstep
7479 with_xft=no
7480 # set up packaging dirs
7481 exec_prefix=${ns_appbindir}
7482 libexecdir=${ns_appbindir}/libexec
7483 if test "${EN_NS_SELF_CONTAINED}" = yes; then
7484 prefix=${ns_appresdir}
7486 ns_frag=$srcdir/src/ns.mk
7487 NS_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o fontset.o fringe.o image.o"
7488 NS_SUPPORT="\${lispsource}emacs-lisp/easymenu.elc \${lispsource}term/ns-win.elc"
7490 CFLAGS="$tmp_CFLAGS"
7491 CPPFLAGS="$tmp_CPPFLAGS"
7497 case "${window_system}" in
7498 x11 )
7499 HAVE_X_WINDOWS=yes
7500 HAVE_X11=yes
7501 case "${with_x_toolkit}" in
7502 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
7503 motif ) USE_X_TOOLKIT=MOTIF ;;
7504 gtk ) with_gtk=yes
7505 USE_X_TOOLKIT=none ;;
7506 gtk3 ) with_gtk3=yes
7507 USE_X_TOOLKIT=none ;;
7508 no ) USE_X_TOOLKIT=none ;;
7509 * ) USE_X_TOOLKIT=maybe ;;
7510 esac
7512 nextstep | none )
7513 HAVE_X_WINDOWS=no
7514 HAVE_X11=no
7515 USE_X_TOOLKIT=none
7517 esac
7519 if test "$window_system" = none && test "X$with_x" != "Xno"; then
7520 # Extract the first word of "X", so it can be a program name with args.
7521 set dummy X; ac_word=$2
7522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7523 $as_echo_n "checking for $ac_word... " >&6; }
7524 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
7525 $as_echo_n "(cached) " >&6
7526 else
7527 if test -n "$HAVE_XSERVER"; then
7528 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
7529 else
7530 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7531 for as_dir in $PATH
7533 IFS=$as_save_IFS
7534 test -z "$as_dir" && as_dir=.
7535 for ac_exec_ext in '' $ac_executable_extensions; do
7536 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7537 ac_cv_prog_HAVE_XSERVER="true"
7538 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7539 break 2
7541 done
7542 done
7543 IFS=$as_save_IFS
7545 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
7548 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
7549 if test -n "$HAVE_XSERVER"; then
7550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
7551 $as_echo "$HAVE_XSERVER" >&6; }
7552 else
7553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7554 $as_echo "no" >&6; }
7558 if test "$HAVE_XSERVER" = true ||
7559 test -n "$DISPLAY" ||
7560 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
7561 as_fn_error "You seem to be running X, but no X development libraries
7562 were found. You should install the relevant development files for X
7563 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
7564 sure you have development files for image handling, i.e.
7565 tiff, gif, jpeg, png and xpm.
7566 If you are sure you want Emacs compiled without X window support, pass
7567 --without-x
7568 to configure." "$LINENO" 5
7572 ### If we're using X11, we should use the X menu package.
7573 HAVE_MENUS=no
7574 case ${HAVE_X11} in
7575 yes ) HAVE_MENUS=yes ;;
7576 esac
7578 # Do the opsystem or machine files prohibit the use of the GNU malloc?
7579 # Assume not, until told otherwise.
7580 GNU_MALLOC=yes
7581 doug_lea_malloc=yes
7582 ac_fn_c_check_func "$LINENO" "malloc_get_state" "ac_cv_func_malloc_get_state"
7583 if test "x$ac_cv_func_malloc_get_state" = x""yes; then :
7585 else
7586 doug_lea_malloc=no
7589 ac_fn_c_check_func "$LINENO" "malloc_set_state" "ac_cv_func_malloc_set_state"
7590 if test "x$ac_cv_func_malloc_set_state" = x""yes; then :
7592 else
7593 doug_lea_malloc=no
7596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __after_morecore_hook exists" >&5
7597 $as_echo_n "checking whether __after_morecore_hook exists... " >&6; }
7598 if test "${emacs_cv_var___after_morecore_hook+set}" = set; then :
7599 $as_echo_n "(cached) " >&6
7600 else
7601 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7602 /* end confdefs.h. */
7603 extern void (* __after_morecore_hook)();
7605 main ()
7607 __after_morecore_hook = 0
7609 return 0;
7611 _ACEOF
7612 if ac_fn_c_try_link "$LINENO"; then :
7613 emacs_cv_var___after_morecore_hook=yes
7614 else
7615 emacs_cv_var___after_morecore_hook=no
7617 rm -f core conftest.err conftest.$ac_objext \
7618 conftest$ac_exeext conftest.$ac_ext
7620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var___after_morecore_hook" >&5
7621 $as_echo "$emacs_cv_var___after_morecore_hook" >&6; }
7622 if test $emacs_cv_var___after_morecore_hook = no; then
7623 doug_lea_malloc=no
7626 if test "${system_malloc}" = "yes"; then
7627 GNU_MALLOC=no
7628 GNU_MALLOC_reason="
7629 (The GNU allocators don't work with this system configuration.)"
7630 GMALLOC_OBJ=
7631 VMLIMIT_OBJ=
7632 else
7633 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
7634 VMLIMIT_OBJ=vm-limit.o
7639 if test "$doug_lea_malloc" = "yes" ; then
7640 if test "$GNU_MALLOC" = yes ; then
7641 GNU_MALLOC_reason="
7642 (Using Doug Lea's new malloc from the GNU C Library.)"
7645 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
7648 ## Use mmap directly for allocating larger buffers.
7649 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
7650 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
7651 ## Does the AC_FUNC_MMAP test below make this check unecessary?
7652 case "$opsys" in
7653 gnu*) REL_ALLOC=no ;;
7654 esac
7657 if test x"${REL_ALLOC}" = x; then
7658 REL_ALLOC=${GNU_MALLOC}
7665 for ac_header in $ac_header_list
7666 do :
7667 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7668 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
7670 eval as_val=\$$as_ac_Header
7671 if test "x$as_val" = x""yes; then :
7672 cat >>confdefs.h <<_ACEOF
7673 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7674 _ACEOF
7678 done
7687 for ac_func in getpagesize
7688 do :
7689 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
7690 if test "x$ac_cv_func_getpagesize" = x""yes; then :
7691 cat >>confdefs.h <<_ACEOF
7692 #define HAVE_GETPAGESIZE 1
7693 _ACEOF
7696 done
7698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
7699 $as_echo_n "checking for working mmap... " >&6; }
7700 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
7701 $as_echo_n "(cached) " >&6
7702 else
7703 if test "$cross_compiling" = yes; then :
7704 ac_cv_func_mmap_fixed_mapped=no
7705 else
7706 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7707 /* end confdefs.h. */
7708 $ac_includes_default
7709 /* malloc might have been renamed as rpl_malloc. */
7710 #undef malloc
7712 /* Thanks to Mike Haertel and Jim Avera for this test.
7713 Here is a matrix of mmap possibilities:
7714 mmap private not fixed
7715 mmap private fixed at somewhere currently unmapped
7716 mmap private fixed at somewhere already mapped
7717 mmap shared not fixed
7718 mmap shared fixed at somewhere currently unmapped
7719 mmap shared fixed at somewhere already mapped
7720 For private mappings, we should verify that changes cannot be read()
7721 back from the file, nor mmap's back from the file at a different
7722 address. (There have been systems where private was not correctly
7723 implemented like the infamous i386 svr4.0, and systems where the
7724 VM page cache was not coherent with the file system buffer cache
7725 like early versions of FreeBSD and possibly contemporary NetBSD.)
7726 For shared mappings, we should conversely verify that changes get
7727 propagated back to all the places they're supposed to be.
7729 Grep wants private fixed already mapped.
7730 The main things grep needs to know about mmap are:
7731 * does it exist and is it safe to write into the mmap'd area
7732 * how to use it (BSD variants) */
7734 #include <fcntl.h>
7735 #include <sys/mman.h>
7737 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
7738 char *malloc ();
7739 #endif
7741 /* This mess was copied from the GNU getpagesize.h. */
7742 #ifndef HAVE_GETPAGESIZE
7743 # ifdef _SC_PAGESIZE
7744 # define getpagesize() sysconf(_SC_PAGESIZE)
7745 # else /* no _SC_PAGESIZE */
7746 # ifdef HAVE_SYS_PARAM_H
7747 # include <sys/param.h>
7748 # ifdef EXEC_PAGESIZE
7749 # define getpagesize() EXEC_PAGESIZE
7750 # else /* no EXEC_PAGESIZE */
7751 # ifdef NBPG
7752 # define getpagesize() NBPG * CLSIZE
7753 # ifndef CLSIZE
7754 # define CLSIZE 1
7755 # endif /* no CLSIZE */
7756 # else /* no NBPG */
7757 # ifdef NBPC
7758 # define getpagesize() NBPC
7759 # else /* no NBPC */
7760 # ifdef PAGESIZE
7761 # define getpagesize() PAGESIZE
7762 # endif /* PAGESIZE */
7763 # endif /* no NBPC */
7764 # endif /* no NBPG */
7765 # endif /* no EXEC_PAGESIZE */
7766 # else /* no HAVE_SYS_PARAM_H */
7767 # define getpagesize() 8192 /* punt totally */
7768 # endif /* no HAVE_SYS_PARAM_H */
7769 # endif /* no _SC_PAGESIZE */
7771 #endif /* no HAVE_GETPAGESIZE */
7774 main ()
7776 char *data, *data2, *data3;
7777 int i, pagesize;
7778 int fd, fd2;
7780 pagesize = getpagesize ();
7782 /* First, make a file with some known garbage in it. */
7783 data = (char *) malloc (pagesize);
7784 if (!data)
7785 return 1;
7786 for (i = 0; i < pagesize; ++i)
7787 *(data + i) = rand ();
7788 umask (0);
7789 fd = creat ("conftest.mmap", 0600);
7790 if (fd < 0)
7791 return 2;
7792 if (write (fd, data, pagesize) != pagesize)
7793 return 3;
7794 close (fd);
7796 /* Next, check that the tail of a page is zero-filled. File must have
7797 non-zero length, otherwise we risk SIGBUS for entire page. */
7798 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
7799 if (fd2 < 0)
7800 return 4;
7801 data2 = "";
7802 if (write (fd2, data2, 1) != 1)
7803 return 5;
7804 data2 = mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
7805 if (data2 == MAP_FAILED)
7806 return 6;
7807 for (i = 0; i < pagesize; ++i)
7808 if (*(data2 + i))
7809 return 7;
7810 close (fd2);
7811 if (munmap (data2, pagesize))
7812 return 8;
7814 /* Next, try to mmap the file at a fixed address which already has
7815 something else allocated at it. If we can, also make sure that
7816 we see the same garbage. */
7817 fd = open ("conftest.mmap", O_RDWR);
7818 if (fd < 0)
7819 return 9;
7820 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
7821 MAP_PRIVATE | MAP_FIXED, fd, 0L))
7822 return 10;
7823 for (i = 0; i < pagesize; ++i)
7824 if (*(data + i) != *(data2 + i))
7825 return 11;
7827 /* Finally, make sure that changes to the mapped area do not
7828 percolate back to the file as seen by read(). (This is a bug on
7829 some variants of i386 svr4.0.) */
7830 for (i = 0; i < pagesize; ++i)
7831 *(data2 + i) = *(data2 + i) + 1;
7832 data3 = (char *) malloc (pagesize);
7833 if (!data3)
7834 return 12;
7835 if (read (fd, data3, pagesize) != pagesize)
7836 return 13;
7837 for (i = 0; i < pagesize; ++i)
7838 if (*(data + i) != *(data3 + i))
7839 return 14;
7840 close (fd);
7841 return 0;
7843 _ACEOF
7844 if ac_fn_c_try_run "$LINENO"; then :
7845 ac_cv_func_mmap_fixed_mapped=yes
7846 else
7847 ac_cv_func_mmap_fixed_mapped=no
7849 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7850 conftest.$ac_objext conftest.beam conftest.$ac_ext
7854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
7855 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
7856 if test $ac_cv_func_mmap_fixed_mapped = yes; then
7858 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
7861 rm -f conftest.mmap conftest.txt
7863 if test $use_mmap_for_buffers = yes; then
7864 REL_ALLOC=no
7867 LIBS="$LIBS_SYSTEM $LIBS"
7869 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
7870 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
7871 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
7872 $as_echo_n "(cached) " >&6
7873 else
7874 ac_check_lib_save_LIBS=$LIBS
7875 LIBS="-ldnet $LIBS"
7876 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7877 /* end confdefs.h. */
7879 /* Override any GCC internal prototype to avoid an error.
7880 Use char because int might match the return type of a GCC
7881 builtin and then its argument prototype would still apply. */
7882 #ifdef __cplusplus
7883 extern "C"
7884 #endif
7885 char dnet_ntoa ();
7887 main ()
7889 return dnet_ntoa ();
7891 return 0;
7893 _ACEOF
7894 if ac_fn_c_try_link "$LINENO"; then :
7895 ac_cv_lib_dnet_dnet_ntoa=yes
7896 else
7897 ac_cv_lib_dnet_dnet_ntoa=no
7899 rm -f core conftest.err conftest.$ac_objext \
7900 conftest$ac_exeext conftest.$ac_ext
7901 LIBS=$ac_check_lib_save_LIBS
7903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
7904 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
7905 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
7906 cat >>confdefs.h <<_ACEOF
7907 #define HAVE_LIBDNET 1
7908 _ACEOF
7910 LIBS="-ldnet $LIBS"
7915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
7916 $as_echo_n "checking for main in -lXbsd... " >&6; }
7917 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
7918 $as_echo_n "(cached) " >&6
7919 else
7920 ac_check_lib_save_LIBS=$LIBS
7921 LIBS="-lXbsd $LIBS"
7922 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7923 /* end confdefs.h. */
7927 main ()
7929 return main ();
7931 return 0;
7933 _ACEOF
7934 if ac_fn_c_try_link "$LINENO"; then :
7935 ac_cv_lib_Xbsd_main=yes
7936 else
7937 ac_cv_lib_Xbsd_main=no
7939 rm -f core conftest.err conftest.$ac_objext \
7940 conftest$ac_exeext conftest.$ac_ext
7941 LIBS=$ac_check_lib_save_LIBS
7943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
7944 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
7945 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
7946 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
7950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
7951 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
7952 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
7953 $as_echo_n "(cached) " >&6
7954 else
7955 ac_check_lib_save_LIBS=$LIBS
7956 LIBS="-lpthreads $LIBS"
7957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7958 /* end confdefs.h. */
7960 /* Override any GCC internal prototype to avoid an error.
7961 Use char because int might match the return type of a GCC
7962 builtin and then its argument prototype would still apply. */
7963 #ifdef __cplusplus
7964 extern "C"
7965 #endif
7966 char cma_open ();
7968 main ()
7970 return cma_open ();
7972 return 0;
7974 _ACEOF
7975 if ac_fn_c_try_link "$LINENO"; then :
7976 ac_cv_lib_pthreads_cma_open=yes
7977 else
7978 ac_cv_lib_pthreads_cma_open=no
7980 rm -f core conftest.err conftest.$ac_objext \
7981 conftest$ac_exeext conftest.$ac_ext
7982 LIBS=$ac_check_lib_save_LIBS
7984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
7985 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
7986 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
7987 cat >>confdefs.h <<_ACEOF
7988 #define HAVE_LIBPTHREADS 1
7989 _ACEOF
7991 LIBS="-lpthreads $LIBS"
7996 ## Note: when using cpp in s/aix4.2.h, this definition depended on
7997 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
7998 ## the system file was sourced. Hence the value of LIBS_SYSTEM
7999 ## added to LIBS in configure would never contain the pthreads part,
8000 ## but the value used in Makefiles might. FIXME?
8002 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
8003 ## be harmless on older versions of X where it happens to exist.
8004 test "$opsys" = "aix4-2" && \
8005 test $ac_cv_lib_pthreads_cma_open = yes && \
8006 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
8009 case ${host_os} in
8010 aix*)
8011 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
8012 $as_echo_n "checking for -bbigtoc option... " >&6; }
8013 if test "${gdb_cv_bigtoc+set}" = set; then :
8014 $as_echo_n "(cached) " >&6
8015 else
8017 case $GCC in
8018 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
8019 *) gdb_cv_bigtoc=-bbigtoc ;;
8020 esac
8022 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
8023 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8024 /* end confdefs.h. */
8027 main ()
8029 int i;
8031 return 0;
8033 _ACEOF
8034 if ac_fn_c_try_link "$LINENO"; then :
8036 else
8037 gdb_cv_bigtoc=
8039 rm -f core conftest.err conftest.$ac_objext \
8040 conftest$ac_exeext conftest.$ac_ext
8043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
8044 $as_echo "$gdb_cv_bigtoc" >&6; }
8046 esac
8048 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
8049 # used for the tests that follow. We set them back to REAL_CFLAGS and
8050 # REAL_CPPFLAGS later on.
8052 REAL_CPPFLAGS="$CPPFLAGS"
8054 if test "${HAVE_X11}" = "yes"; then
8055 DEFS="$C_SWITCH_X_SITE $DEFS"
8056 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
8057 LIBS="$LIBX $LIBS"
8058 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
8059 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
8061 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
8062 # This is handled by LD_SWITCH_X_SITE_AUX during the real build,
8063 # but it's more convenient here to set LD_RUN_PATH
8064 # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX.
8065 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
8066 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
8067 export LD_RUN_PATH
8070 if test "${opsys}" = "gnu-linux"; then
8071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
8072 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
8073 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8074 /* end confdefs.h. */
8077 main ()
8079 XOpenDisplay ("foo");
8081 return 0;
8083 _ACEOF
8084 if ac_fn_c_try_link "$LINENO"; then :
8085 xlinux_first_failure=no
8086 else
8087 xlinux_first_failure=yes
8089 rm -f core conftest.err conftest.$ac_objext \
8090 conftest$ac_exeext conftest.$ac_ext
8091 if test "${xlinux_first_failure}" = "yes"; then
8092 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
8093 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
8094 OLD_CPPFLAGS="$CPPFLAGS"
8095 OLD_LIBS="$LIBS"
8096 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
8097 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
8098 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
8099 LIBS="$LIBS -b i486-linuxaout"
8100 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8101 /* end confdefs.h. */
8104 main ()
8106 XOpenDisplay ("foo");
8108 return 0;
8110 _ACEOF
8111 if ac_fn_c_try_link "$LINENO"; then :
8112 xlinux_second_failure=no
8113 else
8114 xlinux_second_failure=yes
8116 rm -f core conftest.err conftest.$ac_objext \
8117 conftest$ac_exeext conftest.$ac_ext
8118 if test "${xlinux_second_failure}" = "yes"; then
8119 # If we get the same failure with -b, there is no use adding -b.
8120 # So take it out. This plays safe.
8121 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
8122 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
8123 CPPFLAGS="$OLD_CPPFLAGS"
8124 LIBS="$OLD_LIBS"
8125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8126 $as_echo "no" >&6; }
8127 else
8128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8129 $as_echo "yes" >&6; }
8131 else
8132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8133 $as_echo "no" >&6; }
8137 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
8138 # header files included from there.
8139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
8140 $as_echo_n "checking for Xkb... " >&6; }
8141 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8142 /* end confdefs.h. */
8143 #include <X11/Xlib.h>
8144 #include <X11/XKBlib.h>
8146 main ()
8148 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
8150 return 0;
8152 _ACEOF
8153 if ac_fn_c_try_link "$LINENO"; then :
8154 emacs_xkb=yes
8155 else
8156 emacs_xkb=no
8158 rm -f core conftest.err conftest.$ac_objext \
8159 conftest$ac_exeext conftest.$ac_ext
8160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
8161 $as_echo "$emacs_xkb" >&6; }
8162 if test $emacs_xkb = yes; then
8164 $as_echo "#define HAVE_XKBGETKEYBOARD 1" >>confdefs.h
8168 for ac_func in XrmSetDatabase XScreenResourceString \
8169 XScreenNumberOfScreen XSetWMProtocols
8170 do :
8171 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8172 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8173 eval as_val=\$$as_ac_var
8174 if test "x$as_val" = x""yes; then :
8175 cat >>confdefs.h <<_ACEOF
8176 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
8177 _ACEOF
8180 done
8184 if test "${window_system}" = "x11"; then
8185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
8186 $as_echo_n "checking X11 version 6... " >&6; }
8187 if test "${emacs_cv_x11_version_6+set}" = set; then :
8188 $as_echo_n "(cached) " >&6
8189 else
8190 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8191 /* end confdefs.h. */
8192 #include <X11/Xlib.h>
8194 main ()
8196 #if XlibSpecificationRelease < 6
8197 fail;
8198 #endif
8201 return 0;
8203 _ACEOF
8204 if ac_fn_c_try_link "$LINENO"; then :
8205 emacs_cv_x11_version_6=yes
8206 else
8207 emacs_cv_x11_version_6=no
8209 rm -f core conftest.err conftest.$ac_objext \
8210 conftest$ac_exeext conftest.$ac_ext
8213 if test $emacs_cv_x11_version_6 = yes; then
8214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
8215 $as_echo "6 or newer" >&6; }
8217 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
8219 else
8220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
8221 $as_echo "before 6" >&6; }
8226 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
8227 HAVE_RSVG=no
8228 if test "${HAVE_X11}" = "yes" || test "${NS_IMPL_GNUSTEP}" = "yes"; then
8229 if test "${with_rsvg}" != "no"; then
8230 RSVG_REQUIRED=2.11.0
8231 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
8234 succeeded=no
8236 # Extract the first word of "pkg-config", so it can be a program name with args.
8237 set dummy pkg-config; ac_word=$2
8238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8239 $as_echo_n "checking for $ac_word... " >&6; }
8240 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8241 $as_echo_n "(cached) " >&6
8242 else
8243 case $PKG_CONFIG in
8244 [\\/]* | ?:[\\/]*)
8245 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8248 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8249 for as_dir in $PATH
8251 IFS=$as_save_IFS
8252 test -z "$as_dir" && as_dir=.
8253 for ac_exec_ext in '' $ac_executable_extensions; do
8254 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8255 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8256 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8257 break 2
8259 done
8260 done
8261 IFS=$as_save_IFS
8263 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8265 esac
8267 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8268 if test -n "$PKG_CONFIG"; then
8269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8270 $as_echo "$PKG_CONFIG" >&6; }
8271 else
8272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8273 $as_echo "no" >&6; }
8278 if test "$PKG_CONFIG" = "no" ; then
8280 else
8281 PKG_CONFIG_MIN_VERSION=0.9.0
8282 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
8284 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
8286 if $PKG_CONFIG --exists "$RSVG_MODULE" 2>&5; then
8287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8288 $as_echo "yes" >&6; }
8289 succeeded=yes
8291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking RSVG_CFLAGS" >&5
8292 $as_echo_n "checking RSVG_CFLAGS... " >&6; }
8293 RSVG_CFLAGS=`$PKG_CONFIG --cflags "$RSVG_MODULE"|sed -e 's,///*,/,g'`
8294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RSVG_CFLAGS" >&5
8295 $as_echo "$RSVG_CFLAGS" >&6; }
8297 { $as_echo "$as_me:${as_lineno-$LINENO}: checking RSVG_LIBS" >&5
8298 $as_echo_n "checking RSVG_LIBS... " >&6; }
8299 RSVG_LIBS=`$PKG_CONFIG --libs "$RSVG_MODULE"|sed -e 's,///*,/,g'`
8300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RSVG_LIBS" >&5
8301 $as_echo "$RSVG_LIBS" >&6; }
8302 else
8303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8304 $as_echo "no" >&6; }
8305 RSVG_CFLAGS=""
8306 RSVG_LIBS=""
8307 ## If we have a custom action on failure, don't print errors, but
8308 ## do set a variable so people can do so.
8309 RSVG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$RSVG_MODULE"`
8315 else
8316 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8317 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8321 if test $succeeded = yes; then
8323 else
8330 if test ".${RSVG_CFLAGS}" != "."; then
8331 HAVE_RSVG=yes
8333 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
8335 CFLAGS="$CFLAGS $RSVG_CFLAGS"
8336 LIBS="$RSVG_LIBS $LIBS"
8342 HAVE_GTK=no
8343 if test "${with_gtk3}" = "yes"; then
8344 GLIB_REQUIRED=2.6
8345 GTK_REQUIRED=2.90
8346 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
8349 succeeded=no
8351 # Extract the first word of "pkg-config", so it can be a program name with args.
8352 set dummy pkg-config; ac_word=$2
8353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8354 $as_echo_n "checking for $ac_word... " >&6; }
8355 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8356 $as_echo_n "(cached) " >&6
8357 else
8358 case $PKG_CONFIG in
8359 [\\/]* | ?:[\\/]*)
8360 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8363 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8364 for as_dir in $PATH
8366 IFS=$as_save_IFS
8367 test -z "$as_dir" && as_dir=.
8368 for ac_exec_ext in '' $ac_executable_extensions; do
8369 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8370 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8371 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8372 break 2
8374 done
8375 done
8376 IFS=$as_save_IFS
8378 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8380 esac
8382 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8383 if test -n "$PKG_CONFIG"; then
8384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8385 $as_echo "$PKG_CONFIG" >&6; }
8386 else
8387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8388 $as_echo "no" >&6; }
8393 if test "$PKG_CONFIG" = "no" ; then
8394 pkg_check_gtk=no
8395 else
8396 PKG_CONFIG_MIN_VERSION=0.9.0
8397 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
8399 $as_echo_n "checking for $GTK_MODULES... " >&6; }
8401 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5; then
8402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8403 $as_echo "yes" >&6; }
8404 succeeded=yes
8406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_CFLAGS" >&5
8407 $as_echo_n "checking GTK_CFLAGS... " >&6; }
8408 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"|sed -e 's,///*,/,g'`
8409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_CFLAGS" >&5
8410 $as_echo "$GTK_CFLAGS" >&6; }
8412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_LIBS" >&5
8413 $as_echo_n "checking GTK_LIBS... " >&6; }
8414 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"|sed -e 's,///*,/,g'`
8415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_LIBS" >&5
8416 $as_echo "$GTK_LIBS" >&6; }
8417 else
8418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8419 $as_echo "no" >&6; }
8420 GTK_CFLAGS=""
8421 GTK_LIBS=""
8422 ## If we have a custom action on failure, don't print errors, but
8423 ## do set a variable so people can do so.
8424 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
8430 else
8431 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8432 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8436 if test $succeeded = yes; then
8437 pkg_check_gtk=yes
8438 else
8439 pkg_check_gtk=no
8442 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
8443 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
8447 if test "$pkg_check_gtk" != "yes"; then
8448 HAVE_GTK=no
8449 if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
8450 GLIB_REQUIRED=2.6
8451 GTK_REQUIRED=2.6
8452 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
8455 succeeded=no
8457 # Extract the first word of "pkg-config", so it can be a program name with args.
8458 set dummy pkg-config; ac_word=$2
8459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8460 $as_echo_n "checking for $ac_word... " >&6; }
8461 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8462 $as_echo_n "(cached) " >&6
8463 else
8464 case $PKG_CONFIG in
8465 [\\/]* | ?:[\\/]*)
8466 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8469 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8470 for as_dir in $PATH
8472 IFS=$as_save_IFS
8473 test -z "$as_dir" && as_dir=.
8474 for ac_exec_ext in '' $ac_executable_extensions; do
8475 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8476 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8477 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8478 break 2
8480 done
8481 done
8482 IFS=$as_save_IFS
8484 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8486 esac
8488 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8489 if test -n "$PKG_CONFIG"; then
8490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8491 $as_echo "$PKG_CONFIG" >&6; }
8492 else
8493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8494 $as_echo "no" >&6; }
8499 if test "$PKG_CONFIG" = "no" ; then
8500 pkg_check_gtk=no
8501 else
8502 PKG_CONFIG_MIN_VERSION=0.9.0
8503 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
8505 $as_echo_n "checking for $GTK_MODULES... " >&6; }
8507 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5; then
8508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8509 $as_echo "yes" >&6; }
8510 succeeded=yes
8512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_CFLAGS" >&5
8513 $as_echo_n "checking GTK_CFLAGS... " >&6; }
8514 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"|sed -e 's,///*,/,g'`
8515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_CFLAGS" >&5
8516 $as_echo "$GTK_CFLAGS" >&6; }
8518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_LIBS" >&5
8519 $as_echo_n "checking GTK_LIBS... " >&6; }
8520 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"|sed -e 's,///*,/,g'`
8521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_LIBS" >&5
8522 $as_echo "$GTK_LIBS" >&6; }
8523 else
8524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8525 $as_echo "no" >&6; }
8526 GTK_CFLAGS=""
8527 GTK_LIBS=""
8528 ## If we have a custom action on failure, don't print errors, but
8529 ## do set a variable so people can do so.
8530 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
8536 else
8537 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8538 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8542 if test $succeeded = yes; then
8543 pkg_check_gtk=yes
8544 else
8545 pkg_check_gtk=no
8548 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
8549 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
8554 GTK_OBJ=
8555 if test x"$pkg_check_gtk" = xyes; then
8559 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
8560 CFLAGS="$CFLAGS $GTK_CFLAGS"
8561 LIBS="$GTK_LIBS $LIBS"
8562 GTK_COMPILES=no
8563 for ac_func in gtk_main
8564 do :
8565 ac_fn_c_check_func "$LINENO" "gtk_main" "ac_cv_func_gtk_main"
8566 if test "x$ac_cv_func_gtk_main" = x""yes; then :
8567 cat >>confdefs.h <<_ACEOF
8568 #define HAVE_GTK_MAIN 1
8569 _ACEOF
8570 GTK_COMPILES=yes
8572 done
8574 if test "${GTK_COMPILES}" != "yes"; then
8575 if test "$USE_X_TOOLKIT" != "maybe"; then
8576 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
8578 else
8579 HAVE_GTK=yes
8581 $as_echo "#define USE_GTK 1" >>confdefs.h
8583 GTK_OBJ=gtkutil.o
8584 USE_X_TOOLKIT=none
8585 if $PKG_CONFIG --atleast-version=2.10 gtk+-2.0; then
8587 else
8588 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
8589 closing open displays. This is no problem if you just use
8590 one display, but if you use more than one and close one of them
8591 Emacs may crash." >&5
8592 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
8593 closing open displays. This is no problem if you just use
8594 one display, but if you use more than one and close one of them
8595 Emacs may crash." >&2;}
8596 sleep 3
8604 if test "${HAVE_GTK}" = "yes"; then
8606 if test "$with_toolkit_scroll_bars" != no; then
8607 with_toolkit_scroll_bars=yes
8610 HAVE_GTK_FILE_SELECTION=no
8611 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
8612 #include <gtk/gtk.h>
8614 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
8615 HAVE_GTK_FILE_SELECTION=yes
8616 else
8617 HAVE_GTK_FILE_SELECTION=no
8620 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
8621 for ac_func in gtk_file_selection_new
8622 do :
8623 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
8624 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
8625 cat >>confdefs.h <<_ACEOF
8626 #define HAVE_GTK_FILE_SELECTION_NEW 1
8627 _ACEOF
8630 done
8634 HAVE_GTK_AND_PTHREAD=no
8635 for ac_header in pthread.h
8636 do :
8637 ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
8638 if test "x$ac_cv_header_pthread_h" = x""yes; then :
8639 cat >>confdefs.h <<_ACEOF
8640 #define HAVE_PTHREAD_H 1
8641 _ACEOF
8645 done
8647 if test "$ac_cv_header_pthread_h"; then
8648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_self in -lpthread" >&5
8649 $as_echo_n "checking for pthread_self in -lpthread... " >&6; }
8650 if test "${ac_cv_lib_pthread_pthread_self+set}" = set; then :
8651 $as_echo_n "(cached) " >&6
8652 else
8653 ac_check_lib_save_LIBS=$LIBS
8654 LIBS="-lpthread $LIBS"
8655 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8656 /* end confdefs.h. */
8658 /* Override any GCC internal prototype to avoid an error.
8659 Use char because int might match the return type of a GCC
8660 builtin and then its argument prototype would still apply. */
8661 #ifdef __cplusplus
8662 extern "C"
8663 #endif
8664 char pthread_self ();
8666 main ()
8668 return pthread_self ();
8670 return 0;
8672 _ACEOF
8673 if ac_fn_c_try_link "$LINENO"; then :
8674 ac_cv_lib_pthread_pthread_self=yes
8675 else
8676 ac_cv_lib_pthread_pthread_self=no
8678 rm -f core conftest.err conftest.$ac_objext \
8679 conftest$ac_exeext conftest.$ac_ext
8680 LIBS=$ac_check_lib_save_LIBS
8682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_self" >&5
8683 $as_echo "$ac_cv_lib_pthread_pthread_self" >&6; }
8684 if test "x$ac_cv_lib_pthread_pthread_self" = x""yes; then :
8685 HAVE_GTK_AND_PTHREAD=yes
8689 if test "$HAVE_GTK_AND_PTHREAD" = yes; then
8690 case "${canonical}" in
8691 *-hpux*) ;;
8692 *) GTK_LIBS="$GTK_LIBS -lpthread" ;;
8693 esac
8695 $as_echo "#define HAVE_GTK_AND_PTHREAD 1" >>confdefs.h
8699 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
8700 gtk_dialog_get_action_area gtk_widget_get_sensitive \
8701 gtk_widget_get_mapped gtk_adjustment_get_page_size \
8702 gtk_orientable_set_orientation
8703 do :
8704 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8705 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8706 eval as_val=\$$as_ac_var
8707 if test "x$as_val" = x""yes; then :
8708 cat >>confdefs.h <<_ACEOF
8709 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
8710 _ACEOF
8713 done
8718 HAVE_DBUS=no
8719 DBUS_OBJ=
8720 if test "${with_dbus}" = "yes"; then
8722 succeeded=no
8724 # Extract the first word of "pkg-config", so it can be a program name with args.
8725 set dummy pkg-config; ac_word=$2
8726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8727 $as_echo_n "checking for $ac_word... " >&6; }
8728 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8729 $as_echo_n "(cached) " >&6
8730 else
8731 case $PKG_CONFIG in
8732 [\\/]* | ?:[\\/]*)
8733 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8736 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8737 for as_dir in $PATH
8739 IFS=$as_save_IFS
8740 test -z "$as_dir" && as_dir=.
8741 for ac_exec_ext in '' $ac_executable_extensions; do
8742 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8743 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8744 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8745 break 2
8747 done
8748 done
8749 IFS=$as_save_IFS
8751 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8753 esac
8755 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8756 if test -n "$PKG_CONFIG"; then
8757 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8758 $as_echo "$PKG_CONFIG" >&6; }
8759 else
8760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8761 $as_echo "no" >&6; }
8766 if test "$PKG_CONFIG" = "no" ; then
8767 HAVE_DBUS=no
8768 else
8769 PKG_CONFIG_MIN_VERSION=0.9.0
8770 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
8772 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
8774 if $PKG_CONFIG --exists "dbus-1 >= 1.0" 2>&5; then
8775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8776 $as_echo "yes" >&6; }
8777 succeeded=yes
8779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking DBUS_CFLAGS" >&5
8780 $as_echo_n "checking DBUS_CFLAGS... " >&6; }
8781 DBUS_CFLAGS=`$PKG_CONFIG --cflags "dbus-1 >= 1.0"|sed -e 's,///*,/,g'`
8782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBUS_CFLAGS" >&5
8783 $as_echo "$DBUS_CFLAGS" >&6; }
8785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking DBUS_LIBS" >&5
8786 $as_echo_n "checking DBUS_LIBS... " >&6; }
8787 DBUS_LIBS=`$PKG_CONFIG --libs "dbus-1 >= 1.0"|sed -e 's,///*,/,g'`
8788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBUS_LIBS" >&5
8789 $as_echo "$DBUS_LIBS" >&6; }
8790 else
8791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8792 $as_echo "no" >&6; }
8793 DBUS_CFLAGS=""
8794 DBUS_LIBS=""
8795 ## If we have a custom action on failure, don't print errors, but
8796 ## do set a variable so people can do so.
8797 DBUS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "dbus-1 >= 1.0"`
8803 else
8804 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8805 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8809 if test $succeeded = yes; then
8810 HAVE_DBUS=yes
8811 else
8812 HAVE_DBUS=no
8815 if test "$HAVE_DBUS" = yes; then
8816 LIBS="$LIBS $DBUS_LIBS"
8818 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
8820 for ac_func in dbus_watch_get_unix_fd
8821 do :
8822 ac_fn_c_check_func "$LINENO" "dbus_watch_get_unix_fd" "ac_cv_func_dbus_watch_get_unix_fd"
8823 if test "x$ac_cv_func_dbus_watch_get_unix_fd" = x""yes; then :
8824 cat >>confdefs.h <<_ACEOF
8825 #define HAVE_DBUS_WATCH_GET_UNIX_FD 1
8826 _ACEOF
8829 done
8831 DBUS_OBJ=dbusbind.o
8836 HAVE_GCONF=no
8837 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
8839 succeeded=no
8841 # Extract the first word of "pkg-config", so it can be a program name with args.
8842 set dummy pkg-config; ac_word=$2
8843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8844 $as_echo_n "checking for $ac_word... " >&6; }
8845 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8846 $as_echo_n "(cached) " >&6
8847 else
8848 case $PKG_CONFIG in
8849 [\\/]* | ?:[\\/]*)
8850 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8853 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8854 for as_dir in $PATH
8856 IFS=$as_save_IFS
8857 test -z "$as_dir" && as_dir=.
8858 for ac_exec_ext in '' $ac_executable_extensions; do
8859 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8860 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8861 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8862 break 2
8864 done
8865 done
8866 IFS=$as_save_IFS
8868 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8870 esac
8872 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8873 if test -n "$PKG_CONFIG"; then
8874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8875 $as_echo "$PKG_CONFIG" >&6; }
8876 else
8877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8878 $as_echo "no" >&6; }
8883 if test "$PKG_CONFIG" = "no" ; then
8884 HAVE_GCONF=no
8885 else
8886 PKG_CONFIG_MIN_VERSION=0.9.0
8887 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
8889 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
8891 if $PKG_CONFIG --exists "gconf-2.0 >= 2.13" 2>&5; then
8892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8893 $as_echo "yes" >&6; }
8894 succeeded=yes
8896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GCONF_CFLAGS" >&5
8897 $as_echo_n "checking GCONF_CFLAGS... " >&6; }
8898 GCONF_CFLAGS=`$PKG_CONFIG --cflags "gconf-2.0 >= 2.13"|sed -e 's,///*,/,g'`
8899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCONF_CFLAGS" >&5
8900 $as_echo "$GCONF_CFLAGS" >&6; }
8902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GCONF_LIBS" >&5
8903 $as_echo_n "checking GCONF_LIBS... " >&6; }
8904 GCONF_LIBS=`$PKG_CONFIG --libs "gconf-2.0 >= 2.13"|sed -e 's,///*,/,g'`
8905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCONF_LIBS" >&5
8906 $as_echo "$GCONF_LIBS" >&6; }
8907 else
8908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8909 $as_echo "no" >&6; }
8910 GCONF_CFLAGS=""
8911 GCONF_LIBS=""
8912 ## If we have a custom action on failure, don't print errors, but
8913 ## do set a variable so people can do so.
8914 GCONF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gconf-2.0 >= 2.13"`
8920 else
8921 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8922 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8926 if test $succeeded = yes; then
8927 HAVE_GCONF=yes
8928 else
8929 HAVE_GCONF=no
8932 if test "$HAVE_GCONF" = yes; then
8934 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
8939 HAVE_LIBSELINUX=no
8940 LIBSELINUX_LIBS=
8941 if test "${with_selinux}" = "yes"; then
8942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
8943 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
8944 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
8945 $as_echo_n "(cached) " >&6
8946 else
8947 ac_check_lib_save_LIBS=$LIBS
8948 LIBS="-lselinux $LIBS"
8949 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8950 /* end confdefs.h. */
8952 /* Override any GCC internal prototype to avoid an error.
8953 Use char because int might match the return type of a GCC
8954 builtin and then its argument prototype would still apply. */
8955 #ifdef __cplusplus
8956 extern "C"
8957 #endif
8958 char lgetfilecon ();
8960 main ()
8962 return lgetfilecon ();
8964 return 0;
8966 _ACEOF
8967 if ac_fn_c_try_link "$LINENO"; then :
8968 ac_cv_lib_selinux_lgetfilecon=yes
8969 else
8970 ac_cv_lib_selinux_lgetfilecon=no
8972 rm -f core conftest.err conftest.$ac_objext \
8973 conftest$ac_exeext conftest.$ac_ext
8974 LIBS=$ac_check_lib_save_LIBS
8976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
8977 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
8978 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
8979 HAVE_LIBSELINUX=yes
8980 else
8981 HAVE_LIBSELINUX=no
8984 if test "$HAVE_LIBSELINUX" = yes; then
8986 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
8988 LIBSELINUX_LIBS=-lselinux
8993 HAVE_XAW3D=no
8994 LUCID_LIBW=
8995 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
8996 if test "$with_xaw3d" != no; then
8997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
8998 $as_echo_n "checking for xaw3d... " >&6; }
8999 if test "${emacs_cv_xaw3d+set}" = set; then :
9000 $as_echo_n "(cached) " >&6
9001 else
9002 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9003 /* end confdefs.h. */
9005 #include <X11/Intrinsic.h>
9006 #include <X11/Xaw3d/Simple.h>
9008 main ()
9012 return 0;
9014 _ACEOF
9015 if ac_fn_c_try_link "$LINENO"; then :
9016 emacs_cv_xaw3d=yes
9017 else
9018 emacs_cv_xaw3d=no
9020 rm -f core conftest.err conftest.$ac_objext \
9021 conftest$ac_exeext conftest.$ac_ext
9024 else
9025 emacs_cv_xaw3d=no
9027 if test $emacs_cv_xaw3d = yes; then
9028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
9029 $as_echo "yes; using Lucid toolkit" >&6; }
9030 USE_X_TOOLKIT=LUCID
9031 HAVE_XAW3D=yes
9032 LUCID_LIBW=-lXaw3d
9034 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
9036 else
9037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9038 $as_echo "no" >&6; }
9039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
9040 $as_echo_n "checking for libXaw... " >&6; }
9041 if test "${emacs_cv_xaw+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/Xaw/Simple.h>
9050 main ()
9054 return 0;
9056 _ACEOF
9057 if ac_fn_c_try_link "$LINENO"; then :
9058 emacs_cv_xaw=yes
9059 else
9060 emacs_cv_xaw=no
9062 rm -f core conftest.err conftest.$ac_objext \
9063 conftest$ac_exeext conftest.$ac_ext
9066 if test $emacs_cv_xaw = yes; then
9067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
9068 $as_echo "yes; using Lucid toolkit" >&6; }
9069 USE_X_TOOLKIT=LUCID
9070 LUCID_LIBW=-lXaw
9071 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
9072 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
9073 else
9074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no; do not use toolkit by default" >&5
9075 $as_echo "no; do not use toolkit by default" >&6; }
9076 USE_X_TOOLKIT=none
9081 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
9083 LIBXTR6=
9084 if test "${USE_X_TOOLKIT}" != "none"; then
9085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
9086 $as_echo_n "checking X11 toolkit version... " >&6; }
9087 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
9088 $as_echo_n "(cached) " >&6
9089 else
9090 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9091 /* end confdefs.h. */
9092 #include <X11/Intrinsic.h>
9094 main ()
9096 #if XtSpecificationRelease < 6
9097 fail;
9098 #endif
9101 return 0;
9103 _ACEOF
9104 if ac_fn_c_try_link "$LINENO"; then :
9105 emacs_cv_x11_toolkit_version_6=yes
9106 else
9107 emacs_cv_x11_toolkit_version_6=no
9109 rm -f core conftest.err conftest.$ac_objext \
9110 conftest$ac_exeext conftest.$ac_ext
9113 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
9114 if test $emacs_cv_x11_toolkit_version_6 = yes; then
9115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
9116 $as_echo "6 or newer" >&6; }
9118 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
9120 LIBXTR6="-lSM -lICE"
9121 case "$opsys" in
9122 ## Use libw.a along with X11R6 Xt.
9123 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
9124 esac
9125 else
9126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
9127 $as_echo "before 6" >&6; }
9130 OLDLIBS="$LIBS"
9131 if test x$HAVE_X11XTR6 = xyes; then
9132 LIBS="-lXt -lSM -lICE $LIBS"
9133 else
9134 LIBS="-lXt $LIBS"
9136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
9137 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
9138 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
9139 $as_echo_n "(cached) " >&6
9140 else
9141 ac_check_lib_save_LIBS=$LIBS
9142 LIBS="-lXmu $LIBS"
9143 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9144 /* end confdefs.h. */
9146 /* Override any GCC internal prototype to avoid an error.
9147 Use char because int might match the return type of a GCC
9148 builtin and then its argument prototype would still apply. */
9149 #ifdef __cplusplus
9150 extern "C"
9151 #endif
9152 char XmuConvertStandardSelection ();
9154 main ()
9156 return XmuConvertStandardSelection ();
9158 return 0;
9160 _ACEOF
9161 if ac_fn_c_try_link "$LINENO"; then :
9162 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
9163 else
9164 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
9166 rm -f core conftest.err conftest.$ac_objext \
9167 conftest$ac_exeext conftest.$ac_ext
9168 LIBS=$ac_check_lib_save_LIBS
9170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
9171 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
9172 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
9173 cat >>confdefs.h <<_ACEOF
9174 #define HAVE_LIBXMU 1
9175 _ACEOF
9177 LIBS="-lXmu $LIBS"
9181 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
9185 LIBXMU=-lXmu
9186 case "$machine" in
9187 ## These machines don't supply Xmu.
9188 hpux* | aix4-2 )
9189 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
9191 esac
9194 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
9195 if test "${HAVE_X11}" = "yes"; then
9196 if test "${USE_X_TOOLKIT}" != "none"; then
9197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
9198 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
9199 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
9200 $as_echo_n "(cached) " >&6
9201 else
9202 ac_check_lib_save_LIBS=$LIBS
9203 LIBS="-lXext $LIBS"
9204 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9205 /* end confdefs.h. */
9207 /* Override any GCC internal prototype to avoid an error.
9208 Use char because int might match the return type of a GCC
9209 builtin and then its argument prototype would still apply. */
9210 #ifdef __cplusplus
9211 extern "C"
9212 #endif
9213 char XShapeQueryExtension ();
9215 main ()
9217 return XShapeQueryExtension ();
9219 return 0;
9221 _ACEOF
9222 if ac_fn_c_try_link "$LINENO"; then :
9223 ac_cv_lib_Xext_XShapeQueryExtension=yes
9224 else
9225 ac_cv_lib_Xext_XShapeQueryExtension=no
9227 rm -f core conftest.err conftest.$ac_objext \
9228 conftest$ac_exeext conftest.$ac_ext
9229 LIBS=$ac_check_lib_save_LIBS
9231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
9232 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
9233 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
9234 cat >>confdefs.h <<_ACEOF
9235 #define HAVE_LIBXEXT 1
9236 _ACEOF
9238 LIBS="-lXext $LIBS"
9245 LIBXP=
9246 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
9247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Motif version 2.1" >&5
9248 $as_echo_n "checking for Motif version 2.1... " >&6; }
9249 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
9250 $as_echo_n "(cached) " >&6
9251 else
9252 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9253 /* end confdefs.h. */
9254 #include <Xm/Xm.h>
9256 main ()
9258 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
9259 int x = 5;
9260 #else
9261 Motif version prior to 2.1.
9262 #endif
9264 return 0;
9266 _ACEOF
9267 if ac_fn_c_try_compile "$LINENO"; then :
9268 emacs_cv_motif_version_2_1=yes
9269 else
9270 emacs_cv_motif_version_2_1=no
9272 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
9275 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
9276 if test $emacs_cv_motif_version_2_1 = yes; then
9277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
9278 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
9279 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
9280 $as_echo_n "(cached) " >&6
9281 else
9282 ac_check_lib_save_LIBS=$LIBS
9283 LIBS="-lXp $LIBS"
9284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9285 /* end confdefs.h. */
9287 /* Override any GCC internal prototype to avoid an error.
9288 Use char because int might match the return type of a GCC
9289 builtin and then its argument prototype would still apply. */
9290 #ifdef __cplusplus
9291 extern "C"
9292 #endif
9293 char XpCreateContext ();
9295 main ()
9297 return XpCreateContext ();
9299 return 0;
9301 _ACEOF
9302 if ac_fn_c_try_link "$LINENO"; then :
9303 ac_cv_lib_Xp_XpCreateContext=yes
9304 else
9305 ac_cv_lib_Xp_XpCreateContext=no
9307 rm -f core conftest.err conftest.$ac_objext \
9308 conftest$ac_exeext conftest.$ac_ext
9309 LIBS=$ac_check_lib_save_LIBS
9311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
9312 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
9313 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
9314 LIBXP=-lXp
9317 else
9318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
9319 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
9320 if test "${emacs_cv_lesstif+set}" = set; then :
9321 $as_echo_n "(cached) " >&6
9322 else
9323 # We put this in CFLAGS temporarily to precede other -I options
9324 # that might be in CFLAGS temporarily.
9325 # We put this in CPPFLAGS where it precedes the other -I options.
9326 OLD_CPPFLAGS=$CPPFLAGS
9327 OLD_CFLAGS=$CFLAGS
9328 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
9329 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
9330 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9331 /* end confdefs.h. */
9332 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
9334 main ()
9336 int x = 5;
9338 return 0;
9340 _ACEOF
9341 if ac_fn_c_try_compile "$LINENO"; then :
9342 emacs_cv_lesstif=yes
9343 else
9344 emacs_cv_lesstif=no
9346 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
9349 $as_echo "$emacs_cv_lesstif" >&6; }
9350 if test $emacs_cv_lesstif = yes; then
9351 # Make sure this -I option remains in CPPFLAGS after it is set
9352 # back to REAL_CPPFLAGS.
9353 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
9354 # have those other -I options anyway. Ultimately, having this
9355 # directory ultimately in CPPFLAGS will be enough.
9356 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
9357 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
9358 else
9359 CFLAGS=$OLD_CFLAGS
9360 CPPFLAGS=$OLD_CPPFLAGS
9366 USE_TOOLKIT_SCROLL_BARS=no
9367 if test "${with_toolkit_scroll_bars}" != "no"; then
9368 if test "${USE_X_TOOLKIT}" != "none"; then
9369 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
9370 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
9372 HAVE_XAW3D=no
9373 USE_TOOLKIT_SCROLL_BARS=yes
9374 elif test "${HAVE_XAW3D}" = "yes"; then
9375 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
9377 USE_TOOLKIT_SCROLL_BARS=yes
9379 elif test "${HAVE_GTK}" = "yes"; then
9380 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
9382 USE_TOOLKIT_SCROLL_BARS=yes
9383 elif test "${HAVE_NS}" = "yes"; then
9384 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
9386 USE_TOOLKIT_SCROLL_BARS=yes
9390 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9391 /* end confdefs.h. */
9393 #include <X11/Xlib.h>
9394 #include <X11/Xresource.h>
9396 main ()
9398 XIMProc callback;
9400 return 0;
9402 _ACEOF
9403 if ac_fn_c_try_compile "$LINENO"; then :
9404 HAVE_XIM=yes
9406 $as_echo "#define HAVE_XIM 1" >>confdefs.h
9408 else
9409 HAVE_XIM=no
9411 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9414 if test "${with_xim}" != "no"; then
9416 $as_echo "#define USE_XIM 1" >>confdefs.h
9421 if test "${HAVE_XIM}" != "no"; then
9422 late_CFLAGS=$CFLAGS
9423 if test "$GCC" = yes; then
9424 CFLAGS="$CFLAGS --pedantic-errors"
9426 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9427 /* end confdefs.h. */
9429 #include <X11/Xlib.h>
9430 #include <X11/Xresource.h>
9432 main ()
9434 Display *display;
9435 XrmDatabase db;
9436 char *res_name;
9437 char *res_class;
9438 XIMProc callback;
9439 XPointer *client_data;
9440 #ifndef __GNUC__
9441 /* If we're not using GCC, it's probably not XFree86, and this is
9442 probably right, but we can't use something like --pedantic-errors. */
9443 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
9444 char*, XIMProc, XPointer*);
9445 #endif
9446 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
9447 client_data);
9449 return 0;
9451 _ACEOF
9452 if ac_fn_c_try_compile "$LINENO"; then :
9453 emacs_cv_arg6_star=yes
9455 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9456 if test "$emacs_cv_arg6_star" = yes; then
9457 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
9459 else
9460 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
9463 CFLAGS=$late_CFLAGS
9466 ### Start of font-backend (under any platform) section.
9467 # (nothing here yet -- this is a placeholder)
9468 ### End of font-backend (under any platform) section.
9470 ### Start of font-backend (under X11) section.
9471 if test "${HAVE_X11}" = "yes"; then
9473 succeeded=no
9475 # Extract the first word of "pkg-config", so it can be a program name with args.
9476 set dummy pkg-config; ac_word=$2
9477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9478 $as_echo_n "checking for $ac_word... " >&6; }
9479 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
9480 $as_echo_n "(cached) " >&6
9481 else
9482 case $PKG_CONFIG in
9483 [\\/]* | ?:[\\/]*)
9484 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9487 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9488 for as_dir in $PATH
9490 IFS=$as_save_IFS
9491 test -z "$as_dir" && as_dir=.
9492 for ac_exec_ext in '' $ac_executable_extensions; do
9493 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9494 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9495 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9496 break 2
9498 done
9499 done
9500 IFS=$as_save_IFS
9502 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9504 esac
9506 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9507 if test -n "$PKG_CONFIG"; then
9508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
9509 $as_echo "$PKG_CONFIG" >&6; }
9510 else
9511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9512 $as_echo "no" >&6; }
9517 if test "$PKG_CONFIG" = "no" ; then
9518 HAVE_FC=no
9519 else
9520 PKG_CONFIG_MIN_VERSION=0.9.0
9521 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
9523 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
9525 if $PKG_CONFIG --exists "fontconfig >= 2.2.0" 2>&5; then
9526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9527 $as_echo "yes" >&6; }
9528 succeeded=yes
9530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking FONTCONFIG_CFLAGS" >&5
9531 $as_echo_n "checking FONTCONFIG_CFLAGS... " >&6; }
9532 FONTCONFIG_CFLAGS=`$PKG_CONFIG --cflags "fontconfig >= 2.2.0"|sed -e 's,///*,/,g'`
9533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FONTCONFIG_CFLAGS" >&5
9534 $as_echo "$FONTCONFIG_CFLAGS" >&6; }
9536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking FONTCONFIG_LIBS" >&5
9537 $as_echo_n "checking FONTCONFIG_LIBS... " >&6; }
9538 FONTCONFIG_LIBS=`$PKG_CONFIG --libs "fontconfig >= 2.2.0"|sed -e 's,///*,/,g'`
9539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FONTCONFIG_LIBS" >&5
9540 $as_echo "$FONTCONFIG_LIBS" >&6; }
9541 else
9542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9543 $as_echo "no" >&6; }
9544 FONTCONFIG_CFLAGS=""
9545 FONTCONFIG_LIBS=""
9546 ## If we have a custom action on failure, don't print errors, but
9547 ## do set a variable so people can do so.
9548 FONTCONFIG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "fontconfig >= 2.2.0"`
9554 else
9555 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9556 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9560 if test $succeeded = yes; then
9561 HAVE_FC=yes
9562 else
9563 HAVE_FC=no
9567 ## Use -lXft if available, unless `--with-xft=no'.
9568 HAVE_XFT=maybe
9569 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
9570 with_xft="no";
9572 if test "x${with_xft}" != "xno"; then
9575 succeeded=no
9577 # Extract the first word of "pkg-config", so it can be a program name with args.
9578 set dummy pkg-config; ac_word=$2
9579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9580 $as_echo_n "checking for $ac_word... " >&6; }
9581 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
9582 $as_echo_n "(cached) " >&6
9583 else
9584 case $PKG_CONFIG in
9585 [\\/]* | ?:[\\/]*)
9586 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9589 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9590 for as_dir in $PATH
9592 IFS=$as_save_IFS
9593 test -z "$as_dir" && as_dir=.
9594 for ac_exec_ext in '' $ac_executable_extensions; do
9595 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9596 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9597 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9598 break 2
9600 done
9601 done
9602 IFS=$as_save_IFS
9604 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9606 esac
9608 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9609 if test -n "$PKG_CONFIG"; then
9610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
9611 $as_echo "$PKG_CONFIG" >&6; }
9612 else
9613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9614 $as_echo "no" >&6; }
9619 if test "$PKG_CONFIG" = "no" ; then
9620 HAVE_XFT=no
9621 else
9622 PKG_CONFIG_MIN_VERSION=0.9.0
9623 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
9625 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
9627 if $PKG_CONFIG --exists "xft >= 0.13.0" 2>&5; then
9628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9629 $as_echo "yes" >&6; }
9630 succeeded=yes
9632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking XFT_CFLAGS" >&5
9633 $as_echo_n "checking XFT_CFLAGS... " >&6; }
9634 XFT_CFLAGS=`$PKG_CONFIG --cflags "xft >= 0.13.0"|sed -e 's,///*,/,g'`
9635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XFT_CFLAGS" >&5
9636 $as_echo "$XFT_CFLAGS" >&6; }
9638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking XFT_LIBS" >&5
9639 $as_echo_n "checking XFT_LIBS... " >&6; }
9640 XFT_LIBS=`$PKG_CONFIG --libs "xft >= 0.13.0"|sed -e 's,///*,/,g'`
9641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XFT_LIBS" >&5
9642 $as_echo "$XFT_LIBS" >&6; }
9643 else
9644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9645 $as_echo "no" >&6; }
9646 XFT_CFLAGS=""
9647 XFT_LIBS=""
9648 ## If we have a custom action on failure, don't print errors, but
9649 ## do set a variable so people can do so.
9650 XFT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "xft >= 0.13.0"`
9656 else
9657 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9658 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9662 if test $succeeded = yes; then
9664 else
9665 HAVE_XFT=no
9668 ## Because xftfont.c uses XRenderQueryExtension, we also
9669 ## need to link to -lXrender.
9670 HAVE_XRENDER=no
9671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
9672 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
9673 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
9674 $as_echo_n "(cached) " >&6
9675 else
9676 ac_check_lib_save_LIBS=$LIBS
9677 LIBS="-lXrender $LIBS"
9678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9679 /* end confdefs.h. */
9681 /* Override any GCC internal prototype to avoid an error.
9682 Use char because int might match the return type of a GCC
9683 builtin and then its argument prototype would still apply. */
9684 #ifdef __cplusplus
9685 extern "C"
9686 #endif
9687 char XRenderQueryExtension ();
9689 main ()
9691 return XRenderQueryExtension ();
9693 return 0;
9695 _ACEOF
9696 if ac_fn_c_try_link "$LINENO"; then :
9697 ac_cv_lib_Xrender_XRenderQueryExtension=yes
9698 else
9699 ac_cv_lib_Xrender_XRenderQueryExtension=no
9701 rm -f core conftest.err conftest.$ac_objext \
9702 conftest$ac_exeext conftest.$ac_ext
9703 LIBS=$ac_check_lib_save_LIBS
9705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
9706 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
9707 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
9708 HAVE_XRENDER=yes
9711 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
9712 OLD_CPPFLAGS="$CPPFLAGS"
9713 OLD_CFLAGS="$CFLAGS"
9714 OLD_LIBS="$LIBS"
9715 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
9716 CFLAGS="$CFLAGS $XFT_CFLAGS"
9717 XFT_LIBS="-lXrender $XFT_LIBS"
9718 LIBS="$XFT_LIBS $LIBS"
9719 ac_fn_c_check_header_mongrel "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "$ac_includes_default"
9720 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
9721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
9722 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
9723 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
9724 $as_echo_n "(cached) " >&6
9725 else
9726 ac_check_lib_save_LIBS=$LIBS
9727 LIBS="-lXft $XFT_LIBS $LIBS"
9728 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9729 /* end confdefs.h. */
9731 /* Override any GCC internal prototype to avoid an error.
9732 Use char because int might match the return type of a GCC
9733 builtin and then its argument prototype would still apply. */
9734 #ifdef __cplusplus
9735 extern "C"
9736 #endif
9737 char XftFontOpen ();
9739 main ()
9741 return XftFontOpen ();
9743 return 0;
9745 _ACEOF
9746 if ac_fn_c_try_link "$LINENO"; then :
9747 ac_cv_lib_Xft_XftFontOpen=yes
9748 else
9749 ac_cv_lib_Xft_XftFontOpen=no
9751 rm -f core conftest.err conftest.$ac_objext \
9752 conftest$ac_exeext conftest.$ac_ext
9753 LIBS=$ac_check_lib_save_LIBS
9755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
9756 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
9757 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
9758 HAVE_XFT=yes
9765 if test "${HAVE_XFT}" = "yes"; then
9767 $as_echo "#define HAVE_XFT 1" >>confdefs.h
9770 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
9771 else
9772 CPPFLAGS="$OLD_CPPFLAGS"
9773 CFLAGS="$OLD_CFLAGS"
9774 LIBS="$OLD_LIBS"
9775 fi # "${HAVE_XFT}" = "yes"
9776 fi # "$HAVE_XFT" != no
9777 fi # "x${with_xft}" != "xno"
9779 if test "$HAVE_XFT" != "yes"; then
9780 HAVE_XFT=no
9784 HAVE_FREETYPE=no
9785 ## We used to allow building with FreeType and without Xft.
9786 ## However, the ftx font backend driver is not in good shape.
9787 if test "${HAVE_XFT}" = "yes"; then
9788 HAVE_FREETYPE=yes
9789 FONTCONFIG_CFLAGS=
9790 FONTCONFIG_LIBS=
9793 HAVE_LIBOTF=no
9794 if test "${HAVE_FREETYPE}" = "yes"; then
9796 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
9798 if test "${with_libotf}" != "no"; then
9800 succeeded=no
9802 # Extract the first word of "pkg-config", so it can be a program name with args.
9803 set dummy pkg-config; ac_word=$2
9804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9805 $as_echo_n "checking for $ac_word... " >&6; }
9806 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
9807 $as_echo_n "(cached) " >&6
9808 else
9809 case $PKG_CONFIG in
9810 [\\/]* | ?:[\\/]*)
9811 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9814 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9815 for as_dir in $PATH
9817 IFS=$as_save_IFS
9818 test -z "$as_dir" && as_dir=.
9819 for ac_exec_ext in '' $ac_executable_extensions; do
9820 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9821 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9822 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9823 break 2
9825 done
9826 done
9827 IFS=$as_save_IFS
9829 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9831 esac
9833 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9834 if test -n "$PKG_CONFIG"; then
9835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
9836 $as_echo "$PKG_CONFIG" >&6; }
9837 else
9838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9839 $as_echo "no" >&6; }
9844 if test "$PKG_CONFIG" = "no" ; then
9845 HAVE_LIBOTF=no
9846 else
9847 PKG_CONFIG_MIN_VERSION=0.9.0
9848 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
9850 $as_echo_n "checking for libotf... " >&6; }
9852 if $PKG_CONFIG --exists "libotf" 2>&5; then
9853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9854 $as_echo "yes" >&6; }
9855 succeeded=yes
9857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBOTF_CFLAGS" >&5
9858 $as_echo_n "checking LIBOTF_CFLAGS... " >&6; }
9859 LIBOTF_CFLAGS=`$PKG_CONFIG --cflags "libotf"|sed -e 's,///*,/,g'`
9860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBOTF_CFLAGS" >&5
9861 $as_echo "$LIBOTF_CFLAGS" >&6; }
9863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBOTF_LIBS" >&5
9864 $as_echo_n "checking LIBOTF_LIBS... " >&6; }
9865 LIBOTF_LIBS=`$PKG_CONFIG --libs "libotf"|sed -e 's,///*,/,g'`
9866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBOTF_LIBS" >&5
9867 $as_echo "$LIBOTF_LIBS" >&6; }
9868 else
9869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9870 $as_echo "no" >&6; }
9871 LIBOTF_CFLAGS=""
9872 LIBOTF_LIBS=""
9873 ## If we have a custom action on failure, don't print errors, but
9874 ## do set a variable so people can do so.
9875 LIBOTF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libotf"`
9881 else
9882 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9883 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9887 if test $succeeded = yes; then
9888 HAVE_LIBOTF=yes
9889 else
9890 HAVE_LIBOTF=no
9893 if test "$HAVE_LIBOTF" = "yes"; then
9895 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
9897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
9898 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
9899 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
9900 $as_echo_n "(cached) " >&6
9901 else
9902 ac_check_lib_save_LIBS=$LIBS
9903 LIBS="-lotf $LIBS"
9904 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9905 /* end confdefs.h. */
9907 /* Override any GCC internal prototype to avoid an error.
9908 Use char because int might match the return type of a GCC
9909 builtin and then its argument prototype would still apply. */
9910 #ifdef __cplusplus
9911 extern "C"
9912 #endif
9913 char OTF_get_variation_glyphs ();
9915 main ()
9917 return OTF_get_variation_glyphs ();
9919 return 0;
9921 _ACEOF
9922 if ac_fn_c_try_link "$LINENO"; then :
9923 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
9924 else
9925 ac_cv_lib_otf_OTF_get_variation_glyphs=no
9927 rm -f core conftest.err conftest.$ac_objext \
9928 conftest$ac_exeext conftest.$ac_ext
9929 LIBS=$ac_check_lib_save_LIBS
9931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
9932 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
9933 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
9934 HAVE_OTF_GET_VARIATION_GLYPHS=yes
9935 else
9936 HAVE_OTF_GET_VARIATION_GLYPHS=no
9939 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
9941 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
9948 HAVE_M17N_FLT=no
9949 if test "${HAVE_LIBOTF}" = yes; then
9950 if test "${with_m17n_flt}" != "no"; then
9952 succeeded=no
9954 # Extract the first word of "pkg-config", so it can be a program name with args.
9955 set dummy pkg-config; ac_word=$2
9956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9957 $as_echo_n "checking for $ac_word... " >&6; }
9958 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
9959 $as_echo_n "(cached) " >&6
9960 else
9961 case $PKG_CONFIG in
9962 [\\/]* | ?:[\\/]*)
9963 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9966 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9967 for as_dir in $PATH
9969 IFS=$as_save_IFS
9970 test -z "$as_dir" && as_dir=.
9971 for ac_exec_ext in '' $ac_executable_extensions; do
9972 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9973 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9974 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9975 break 2
9977 done
9978 done
9979 IFS=$as_save_IFS
9981 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9983 esac
9985 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9986 if test -n "$PKG_CONFIG"; then
9987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
9988 $as_echo "$PKG_CONFIG" >&6; }
9989 else
9990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9991 $as_echo "no" >&6; }
9996 if test "$PKG_CONFIG" = "no" ; then
9997 HAVE_M17N_FLT=no
9998 else
9999 PKG_CONFIG_MIN_VERSION=0.9.0
10000 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
10002 $as_echo_n "checking for m17n-flt... " >&6; }
10004 if $PKG_CONFIG --exists "m17n-flt" 2>&5; then
10005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10006 $as_echo "yes" >&6; }
10007 succeeded=yes
10009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking M17N_FLT_CFLAGS" >&5
10010 $as_echo_n "checking M17N_FLT_CFLAGS... " >&6; }
10011 M17N_FLT_CFLAGS=`$PKG_CONFIG --cflags "m17n-flt"|sed -e 's,///*,/,g'`
10012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $M17N_FLT_CFLAGS" >&5
10013 $as_echo "$M17N_FLT_CFLAGS" >&6; }
10015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking M17N_FLT_LIBS" >&5
10016 $as_echo_n "checking M17N_FLT_LIBS... " >&6; }
10017 M17N_FLT_LIBS=`$PKG_CONFIG --libs "m17n-flt"|sed -e 's,///*,/,g'`
10018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $M17N_FLT_LIBS" >&5
10019 $as_echo "$M17N_FLT_LIBS" >&6; }
10020 else
10021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10022 $as_echo "no" >&6; }
10023 M17N_FLT_CFLAGS=""
10024 M17N_FLT_LIBS=""
10025 ## If we have a custom action on failure, don't print errors, but
10026 ## do set a variable so people can do so.
10027 M17N_FLT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "m17n-flt"`
10033 else
10034 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10035 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10039 if test $succeeded = yes; then
10040 HAVE_M17N_FLT=yes
10041 else
10042 HAVE_M17N_FLT=no
10045 if test "$HAVE_M17N_FLT" = "yes"; then
10047 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
10052 else
10053 HAVE_XFT=no
10054 HAVE_FREETYPE=no
10055 HAVE_LIBOTF=no
10056 HAVE_M17N_FLT=no
10059 ### End of font-backend (under X11) section.
10070 ### Use -lXpm if available, unless `--with-xpm=no'.
10071 HAVE_XPM=no
10072 LIBXPM=
10073 if test "${HAVE_X11}" = "yes"; then
10074 if test "${with_xpm}" != "no"; then
10075 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
10076 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
10077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
10078 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
10079 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
10080 $as_echo_n "(cached) " >&6
10081 else
10082 ac_check_lib_save_LIBS=$LIBS
10083 LIBS="-lXpm -lX11 $LIBS"
10084 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10085 /* end confdefs.h. */
10087 /* Override any GCC internal prototype to avoid an error.
10088 Use char because int might match the return type of a GCC
10089 builtin and then its argument prototype would still apply. */
10090 #ifdef __cplusplus
10091 extern "C"
10092 #endif
10093 char XpmReadFileToPixmap ();
10095 main ()
10097 return XpmReadFileToPixmap ();
10099 return 0;
10101 _ACEOF
10102 if ac_fn_c_try_link "$LINENO"; then :
10103 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
10104 else
10105 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
10107 rm -f core conftest.err conftest.$ac_objext \
10108 conftest$ac_exeext conftest.$ac_ext
10109 LIBS=$ac_check_lib_save_LIBS
10111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
10112 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
10113 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
10114 HAVE_XPM=yes
10120 if test "${HAVE_XPM}" = "yes"; then
10121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
10122 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
10123 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10124 /* end confdefs.h. */
10125 #include "X11/xpm.h"
10126 #ifndef XpmReturnAllocPixels
10127 no_return_alloc_pixels
10128 #endif
10130 _ACEOF
10131 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10132 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
10133 HAVE_XPM=no
10134 else
10135 HAVE_XPM=yes
10137 rm -f conftest*
10140 if test "${HAVE_XPM}" = "yes"; then
10141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10142 $as_echo "yes" >&6; }
10143 else
10144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10145 $as_echo "no" >&6; }
10150 if test "${HAVE_XPM}" = "yes"; then
10152 $as_echo "#define HAVE_XPM 1" >>confdefs.h
10154 LIBXPM=-lXpm
10159 ### Use -ljpeg if available, unless `--with-jpeg=no'.
10160 HAVE_JPEG=no
10161 LIBJPEG=
10162 if test "${HAVE_X11}" = "yes"; then
10163 if test "${with_jpeg}" != "no"; then
10164 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
10165 if test "x$ac_cv_header_jerror_h" = x""yes; then :
10166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
10167 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
10168 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
10169 $as_echo_n "(cached) " >&6
10170 else
10171 ac_check_lib_save_LIBS=$LIBS
10172 LIBS="-ljpeg $LIBS"
10173 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10174 /* end confdefs.h. */
10176 /* Override any GCC internal prototype to avoid an error.
10177 Use char because int might match the return type of a GCC
10178 builtin and then its argument prototype would still apply. */
10179 #ifdef __cplusplus
10180 extern "C"
10181 #endif
10182 char jpeg_destroy_compress ();
10184 main ()
10186 return jpeg_destroy_compress ();
10188 return 0;
10190 _ACEOF
10191 if ac_fn_c_try_link "$LINENO"; then :
10192 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
10193 else
10194 ac_cv_lib_jpeg_jpeg_destroy_compress=no
10196 rm -f core conftest.err conftest.$ac_objext \
10197 conftest$ac_exeext conftest.$ac_ext
10198 LIBS=$ac_check_lib_save_LIBS
10200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
10201 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
10202 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
10203 HAVE_JPEG=yes
10211 if test "${HAVE_JPEG}" = "yes"; then
10212 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
10214 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10215 /* end confdefs.h. */
10216 #include <jpeglib.h>
10217 version=JPEG_LIB_VERSION
10219 _ACEOF
10220 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10221 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
10222 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
10224 else
10225 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
10226 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
10227 HAVE_JPEG=no
10229 rm -f conftest*
10232 if test "${HAVE_JPEG}" = "yes"; then
10233 LIBJPEG=-ljpeg
10238 ### Use -lpng if available, unless `--with-png=no'.
10239 HAVE_PNG=no
10240 LIBPNG=
10241 if test "${HAVE_X11}" = "yes"; then
10242 if test "${with_png}" != "no"; then
10243 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
10244 # in /usr/include/libpng.
10245 for ac_header in png.h libpng/png.h
10246 do :
10247 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10248 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
10249 eval as_val=\$$as_ac_Header
10250 if test "x$as_val" = x""yes; then :
10251 cat >>confdefs.h <<_ACEOF
10252 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10253 _ACEOF
10257 done
10259 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
10260 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
10261 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
10262 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
10263 $as_echo_n "(cached) " >&6
10264 else
10265 ac_check_lib_save_LIBS=$LIBS
10266 LIBS="-lpng -lz -lm $LIBS"
10267 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10268 /* end confdefs.h. */
10270 /* Override any GCC internal prototype to avoid an error.
10271 Use char because int might match the return type of a GCC
10272 builtin and then its argument prototype would still apply. */
10273 #ifdef __cplusplus
10274 extern "C"
10275 #endif
10276 char png_get_channels ();
10278 main ()
10280 return png_get_channels ();
10282 return 0;
10284 _ACEOF
10285 if ac_fn_c_try_link "$LINENO"; then :
10286 ac_cv_lib_png_png_get_channels=yes
10287 else
10288 ac_cv_lib_png_png_get_channels=no
10290 rm -f core conftest.err conftest.$ac_objext \
10291 conftest$ac_exeext conftest.$ac_ext
10292 LIBS=$ac_check_lib_save_LIBS
10294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
10295 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
10296 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
10297 HAVE_PNG=yes
10303 if test "${HAVE_PNG}" = "yes"; then
10305 $as_echo "#define HAVE_PNG 1" >>confdefs.h
10307 LIBPNG="-lpng -lz -lm"
10312 ### Use -ltiff if available, unless `--with-tiff=no'.
10313 HAVE_TIFF=no
10314 LIBTIFF=
10315 if test "${HAVE_X11}" = "yes"; then
10316 if test "${with_tiff}" != "no"; then
10317 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
10318 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
10319 tifflibs="-lz -lm"
10320 # At least one tiff package requires the jpeg library.
10321 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
10322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
10323 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
10324 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
10325 $as_echo_n "(cached) " >&6
10326 else
10327 ac_check_lib_save_LIBS=$LIBS
10328 LIBS="-ltiff $tifflibs $LIBS"
10329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10330 /* end confdefs.h. */
10332 /* Override any GCC internal prototype to avoid an error.
10333 Use char because int might match the return type of a GCC
10334 builtin and then its argument prototype would still apply. */
10335 #ifdef __cplusplus
10336 extern "C"
10337 #endif
10338 char TIFFGetVersion ();
10340 main ()
10342 return TIFFGetVersion ();
10344 return 0;
10346 _ACEOF
10347 if ac_fn_c_try_link "$LINENO"; then :
10348 ac_cv_lib_tiff_TIFFGetVersion=yes
10349 else
10350 ac_cv_lib_tiff_TIFFGetVersion=no
10352 rm -f core conftest.err conftest.$ac_objext \
10353 conftest$ac_exeext conftest.$ac_ext
10354 LIBS=$ac_check_lib_save_LIBS
10356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
10357 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
10358 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
10359 HAVE_TIFF=yes
10367 if test "${HAVE_TIFF}" = "yes"; then
10369 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
10371 LIBTIFF=-ltiff
10376 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
10377 HAVE_GIF=no
10378 LIBGIF=
10379 if test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no"; then
10380 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
10381 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
10382 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
10383 # Earlier versions can crash Emacs.
10384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
10385 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
10386 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
10387 $as_echo_n "(cached) " >&6
10388 else
10389 ac_check_lib_save_LIBS=$LIBS
10390 LIBS="-lgif $LIBS"
10391 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10392 /* end confdefs.h. */
10394 /* Override any GCC internal prototype to avoid an error.
10395 Use char because int might match the return type of a GCC
10396 builtin and then its argument prototype would still apply. */
10397 #ifdef __cplusplus
10398 extern "C"
10399 #endif
10400 char EGifPutExtensionLast ();
10402 main ()
10404 return EGifPutExtensionLast ();
10406 return 0;
10408 _ACEOF
10409 if ac_fn_c_try_link "$LINENO"; then :
10410 ac_cv_lib_gif_EGifPutExtensionLast=yes
10411 else
10412 ac_cv_lib_gif_EGifPutExtensionLast=no
10414 rm -f core conftest.err conftest.$ac_objext \
10415 conftest$ac_exeext conftest.$ac_ext
10416 LIBS=$ac_check_lib_save_LIBS
10418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
10419 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
10420 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
10421 HAVE_GIF=yes
10422 else
10423 HAVE_GIF=maybe
10430 if test "$HAVE_GIF" = yes; then
10431 LIBGIF=-lgif
10432 elif test "$HAVE_GIF" = maybe; then
10433 # If gif_lib.h but no libgif, try libungif.
10434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
10435 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
10436 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
10437 $as_echo_n "(cached) " >&6
10438 else
10439 ac_check_lib_save_LIBS=$LIBS
10440 LIBS="-lungif $LIBS"
10441 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10442 /* end confdefs.h. */
10444 /* Override any GCC internal prototype to avoid an error.
10445 Use char because int might match the return type of a GCC
10446 builtin and then its argument prototype would still apply. */
10447 #ifdef __cplusplus
10448 extern "C"
10449 #endif
10450 char EGifPutExtensionLast ();
10452 main ()
10454 return EGifPutExtensionLast ();
10456 return 0;
10458 _ACEOF
10459 if ac_fn_c_try_link "$LINENO"; then :
10460 ac_cv_lib_ungif_EGifPutExtensionLast=yes
10461 else
10462 ac_cv_lib_ungif_EGifPutExtensionLast=no
10464 rm -f core conftest.err conftest.$ac_objext \
10465 conftest$ac_exeext conftest.$ac_ext
10466 LIBS=$ac_check_lib_save_LIBS
10468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
10469 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
10470 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
10471 HAVE_GIF=yes
10472 else
10473 HAVE_GIF=no
10476 test "$HAVE_GIF" = yes && LIBGIF=-lungif
10479 if test "${HAVE_GIF}" = "yes"; then
10481 $as_echo "#define HAVE_GIF 1" >>confdefs.h
10487 if test "${HAVE_X11}" = "yes"; then
10488 MISSING=""
10489 WITH_NO=""
10490 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
10491 MISSING="libXpm" && WITH_NO="--with-xpm=no"
10492 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
10493 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
10494 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
10495 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
10496 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
10497 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
10498 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
10499 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
10501 if test "X${MISSING}" != X; then
10502 as_fn_error "The following required libraries were not found:
10503 $MISSING
10504 Maybe some development libraries/packages are missing?
10505 If you don't want to link with them give
10506 $WITH_NO
10507 as options to configure" "$LINENO" 5
10511 ### Use -lgpm if available, unless `--with-gpm=no'.
10512 HAVE_GPM=no
10513 LIBGPM=
10514 MOUSE_SUPPORT=
10515 if test "${with_gpm}" != "no"; then
10516 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
10517 if test "x$ac_cv_header_gpm_h" = x""yes; then :
10518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
10519 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
10520 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
10521 $as_echo_n "(cached) " >&6
10522 else
10523 ac_check_lib_save_LIBS=$LIBS
10524 LIBS="-lgpm $LIBS"
10525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10526 /* end confdefs.h. */
10528 /* Override any GCC internal prototype to avoid an error.
10529 Use char because int might match the return type of a GCC
10530 builtin and then its argument prototype would still apply. */
10531 #ifdef __cplusplus
10532 extern "C"
10533 #endif
10534 char Gpm_Open ();
10536 main ()
10538 return Gpm_Open ();
10540 return 0;
10542 _ACEOF
10543 if ac_fn_c_try_link "$LINENO"; then :
10544 ac_cv_lib_gpm_Gpm_Open=yes
10545 else
10546 ac_cv_lib_gpm_Gpm_Open=no
10548 rm -f core conftest.err conftest.$ac_objext \
10549 conftest$ac_exeext conftest.$ac_ext
10550 LIBS=$ac_check_lib_save_LIBS
10552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
10553 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
10554 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
10555 HAVE_GPM=yes
10562 if test "${HAVE_GPM}" = "yes"; then
10564 $as_echo "#define HAVE_GPM 1" >>confdefs.h
10566 LIBGPM=-lgpm
10567 ## May be reset below.
10568 MOUSE_SUPPORT="\$(GPM_MOUSE_SUPPORT)"
10573 ac_fn_c_check_header_mongrel "$LINENO" "malloc/malloc.h" "ac_cv_header_malloc_malloc_h" "$ac_includes_default"
10574 if test "x$ac_cv_header_malloc_malloc_h" = x""yes; then :
10576 $as_echo "#define HAVE_MALLOC_MALLOC_H 1" >>confdefs.h
10582 C_SWITCH_X_SYSTEM=
10583 ### Use NeXTstep API to implement GUI.
10584 if test "${HAVE_NS}" = "yes"; then
10586 $as_echo "#define HAVE_NS 1" >>confdefs.h
10588 if test "${NS_IMPL_COCOA}" = "yes"; then
10590 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
10592 GNU_OBJC_CFLAGS=
10594 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
10596 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
10598 # See also .m.o rule in Makefile.in */
10599 # FIXME: are all these flags really needed? Document here why. */
10600 C_SWITCH_X_SYSTEM="-D_REENTRANT -fPIC -fno-strict-aliasing"
10601 GNU_OBJC_CFLAGS="-fgnu-runtime -Wno-import -fconstant-string-class=NSConstantString -DGNUSTEP_BASE_LIBRARY=1 -DGNU_GUI_LIBRARY=1 -DGNU_RUNTIME=1 -DGSWARN -DGSDIAGNOSE"
10603 if test "${NS_HAVE_NSINTEGER}" = "yes"; then
10605 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
10608 # We also have mouse menus.
10609 HAVE_MENUS=yes
10610 OTHER_FILES=ns-app
10614 ### Use session management (-lSM -lICE) if available
10615 HAVE_X_SM=no
10616 LIBXSM=
10617 if test "${HAVE_X11}" = "yes"; then
10618 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
10619 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
10620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
10621 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
10622 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
10623 $as_echo_n "(cached) " >&6
10624 else
10625 ac_check_lib_save_LIBS=$LIBS
10626 LIBS="-lSM -lICE $LIBS"
10627 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10628 /* end confdefs.h. */
10630 /* Override any GCC internal prototype to avoid an error.
10631 Use char because int might match the return type of a GCC
10632 builtin and then its argument prototype would still apply. */
10633 #ifdef __cplusplus
10634 extern "C"
10635 #endif
10636 char SmcOpenConnection ();
10638 main ()
10640 return SmcOpenConnection ();
10642 return 0;
10644 _ACEOF
10645 if ac_fn_c_try_link "$LINENO"; then :
10646 ac_cv_lib_SM_SmcOpenConnection=yes
10647 else
10648 ac_cv_lib_SM_SmcOpenConnection=no
10650 rm -f core conftest.err conftest.$ac_objext \
10651 conftest$ac_exeext conftest.$ac_ext
10652 LIBS=$ac_check_lib_save_LIBS
10654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
10655 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
10656 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
10657 HAVE_X_SM=yes
10664 if test "${HAVE_X_SM}" = "yes"; then
10666 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
10668 LIBXSM="-lSM -lICE"
10669 case "$LIBS" in
10670 *-lSM*) ;;
10671 *) LIBS="$LIBXSM $LIBS" ;;
10672 esac
10677 # If netdb.h doesn't declare h_errno, we must declare it by hand.
10678 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
10679 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
10680 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
10681 $as_echo_n "(cached) " >&6
10682 else
10683 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10684 /* end confdefs.h. */
10685 #include <netdb.h>
10687 main ()
10689 return h_errno;
10691 return 0;
10693 _ACEOF
10694 if ac_fn_c_try_link "$LINENO"; then :
10695 emacs_cv_netdb_declares_h_errno=yes
10696 else
10697 emacs_cv_netdb_declares_h_errno=no
10699 rm -f core conftest.err conftest.$ac_objext \
10700 conftest$ac_exeext conftest.$ac_ext
10702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
10703 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
10704 if test $emacs_cv_netdb_declares_h_errno = yes; then
10706 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
10710 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
10711 # for constant arguments. Useless!
10712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
10713 $as_echo_n "checking for working alloca.h... " >&6; }
10714 if test "${ac_cv_working_alloca_h+set}" = set; then :
10715 $as_echo_n "(cached) " >&6
10716 else
10717 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10718 /* end confdefs.h. */
10719 #include <alloca.h>
10721 main ()
10723 char *p = (char *) alloca (2 * sizeof (int));
10724 if (p) return 0;
10726 return 0;
10728 _ACEOF
10729 if ac_fn_c_try_link "$LINENO"; then :
10730 ac_cv_working_alloca_h=yes
10731 else
10732 ac_cv_working_alloca_h=no
10734 rm -f core conftest.err conftest.$ac_objext \
10735 conftest$ac_exeext conftest.$ac_ext
10737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
10738 $as_echo "$ac_cv_working_alloca_h" >&6; }
10739 if test $ac_cv_working_alloca_h = yes; then
10741 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
10745 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
10746 $as_echo_n "checking for alloca... " >&6; }
10747 if test "${ac_cv_func_alloca_works+set}" = set; then :
10748 $as_echo_n "(cached) " >&6
10749 else
10750 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10751 /* end confdefs.h. */
10752 #ifdef __GNUC__
10753 # define alloca __builtin_alloca
10754 #else
10755 # ifdef _MSC_VER
10756 # include <malloc.h>
10757 # define alloca _alloca
10758 # else
10759 # ifdef HAVE_ALLOCA_H
10760 # include <alloca.h>
10761 # else
10762 # ifdef _AIX
10763 #pragma alloca
10764 # else
10765 # ifndef alloca /* predefined by HP cc +Olibcalls */
10766 char *alloca ();
10767 # endif
10768 # endif
10769 # endif
10770 # endif
10771 #endif
10774 main ()
10776 char *p = (char *) alloca (1);
10777 if (p) return 0;
10779 return 0;
10781 _ACEOF
10782 if ac_fn_c_try_link "$LINENO"; then :
10783 ac_cv_func_alloca_works=yes
10784 else
10785 ac_cv_func_alloca_works=no
10787 rm -f core conftest.err conftest.$ac_objext \
10788 conftest$ac_exeext conftest.$ac_ext
10790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
10791 $as_echo "$ac_cv_func_alloca_works" >&6; }
10793 if test $ac_cv_func_alloca_works = yes; then
10795 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
10797 else
10798 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
10799 # that cause trouble. Some versions do not even contain alloca or
10800 # contain a buggy version. If you still want to use their alloca,
10801 # use ar to extract alloca.o from them instead of compiling alloca.c.
10803 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
10805 $as_echo "#define C_ALLOCA 1" >>confdefs.h
10808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
10809 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
10810 if test "${ac_cv_os_cray+set}" = set; then :
10811 $as_echo_n "(cached) " >&6
10812 else
10813 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10814 /* end confdefs.h. */
10815 #if defined CRAY && ! defined CRAY2
10816 webecray
10817 #else
10818 wenotbecray
10819 #endif
10821 _ACEOF
10822 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10823 $EGREP "webecray" >/dev/null 2>&1; then :
10824 ac_cv_os_cray=yes
10825 else
10826 ac_cv_os_cray=no
10828 rm -f conftest*
10831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
10832 $as_echo "$ac_cv_os_cray" >&6; }
10833 if test $ac_cv_os_cray = yes; then
10834 for ac_func in _getb67 GETB67 getb67; do
10835 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10836 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10837 eval as_val=\$$as_ac_var
10838 if test "x$as_val" = x""yes; then :
10840 cat >>confdefs.h <<_ACEOF
10841 #define CRAY_STACKSEG_END $ac_func
10842 _ACEOF
10844 break
10847 done
10850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
10851 $as_echo_n "checking stack direction for C alloca... " >&6; }
10852 if test "${ac_cv_c_stack_direction+set}" = set; then :
10853 $as_echo_n "(cached) " >&6
10854 else
10855 if test "$cross_compiling" = yes; then :
10856 ac_cv_c_stack_direction=0
10857 else
10858 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10859 /* end confdefs.h. */
10860 $ac_includes_default
10862 find_stack_direction ()
10864 static char *addr = 0;
10865 auto char dummy;
10866 if (addr == 0)
10868 addr = &dummy;
10869 return find_stack_direction ();
10871 else
10872 return (&dummy > addr) ? 1 : -1;
10876 main ()
10878 return find_stack_direction () < 0;
10880 _ACEOF
10881 if ac_fn_c_try_run "$LINENO"; then :
10882 ac_cv_c_stack_direction=1
10883 else
10884 ac_cv_c_stack_direction=-1
10886 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10887 conftest.$ac_objext conftest.beam conftest.$ac_ext
10891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
10892 $as_echo "$ac_cv_c_stack_direction" >&6; }
10893 cat >>confdefs.h <<_ACEOF
10894 #define STACK_DIRECTION $ac_cv_c_stack_direction
10895 _ACEOF
10901 if test x"$ac_cv_func_alloca_works" != xyes; then
10902 as_fn_error "a system implementation of alloca is required " "$LINENO" 5
10905 # fmod, logb, and frexp are found in -lm on most systems.
10906 # On HPUX 9.01, -lm does not contain logb, so check for sqrt.
10907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
10908 $as_echo_n "checking for sqrt in -lm... " >&6; }
10909 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
10910 $as_echo_n "(cached) " >&6
10911 else
10912 ac_check_lib_save_LIBS=$LIBS
10913 LIBS="-lm $LIBS"
10914 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10915 /* end confdefs.h. */
10917 /* Override any GCC internal prototype to avoid an error.
10918 Use char because int might match the return type of a GCC
10919 builtin and then its argument prototype would still apply. */
10920 #ifdef __cplusplus
10921 extern "C"
10922 #endif
10923 char sqrt ();
10925 main ()
10927 return sqrt ();
10929 return 0;
10931 _ACEOF
10932 if ac_fn_c_try_link "$LINENO"; then :
10933 ac_cv_lib_m_sqrt=yes
10934 else
10935 ac_cv_lib_m_sqrt=no
10937 rm -f core conftest.err conftest.$ac_objext \
10938 conftest$ac_exeext conftest.$ac_ext
10939 LIBS=$ac_check_lib_save_LIBS
10941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
10942 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
10943 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
10944 cat >>confdefs.h <<_ACEOF
10945 #define HAVE_LIBM 1
10946 _ACEOF
10948 LIBS="-lm $LIBS"
10953 # Check for mail-locking functions in a "mail" library. Probably this should
10954 # have the same check as for liblockfile below.
10955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
10956 $as_echo_n "checking for maillock in -lmail... " >&6; }
10957 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
10958 $as_echo_n "(cached) " >&6
10959 else
10960 ac_check_lib_save_LIBS=$LIBS
10961 LIBS="-lmail $LIBS"
10962 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10963 /* end confdefs.h. */
10965 /* Override any GCC internal prototype to avoid an error.
10966 Use char because int might match the return type of a GCC
10967 builtin and then its argument prototype would still apply. */
10968 #ifdef __cplusplus
10969 extern "C"
10970 #endif
10971 char maillock ();
10973 main ()
10975 return maillock ();
10977 return 0;
10979 _ACEOF
10980 if ac_fn_c_try_link "$LINENO"; then :
10981 ac_cv_lib_mail_maillock=yes
10982 else
10983 ac_cv_lib_mail_maillock=no
10985 rm -f core conftest.err conftest.$ac_objext \
10986 conftest$ac_exeext conftest.$ac_ext
10987 LIBS=$ac_check_lib_save_LIBS
10989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
10990 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
10991 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
10992 have_mail=yes
10993 else
10994 have_mail=no
10997 if test $have_mail = yes; then
10998 LIBS_MAIL=-lmail
10999 LIBS="$LIBS_MAIL $LIBS"
11001 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
11003 else
11004 LIBS_MAIL=
11006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
11007 $as_echo_n "checking for maillock in -llockfile... " >&6; }
11008 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
11009 $as_echo_n "(cached) " >&6
11010 else
11011 ac_check_lib_save_LIBS=$LIBS
11012 LIBS="-llockfile $LIBS"
11013 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11014 /* end confdefs.h. */
11016 /* Override any GCC internal prototype to avoid an error.
11017 Use char because int might match the return type of a GCC
11018 builtin and then its argument prototype would still apply. */
11019 #ifdef __cplusplus
11020 extern "C"
11021 #endif
11022 char maillock ();
11024 main ()
11026 return maillock ();
11028 return 0;
11030 _ACEOF
11031 if ac_fn_c_try_link "$LINENO"; then :
11032 ac_cv_lib_lockfile_maillock=yes
11033 else
11034 ac_cv_lib_lockfile_maillock=no
11036 rm -f core conftest.err conftest.$ac_objext \
11037 conftest$ac_exeext conftest.$ac_ext
11038 LIBS=$ac_check_lib_save_LIBS
11040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
11041 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
11042 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
11043 have_lockfile=yes
11044 else
11045 have_lockfile=no
11048 if test $have_lockfile = yes; then
11049 LIBS_MAIL=-llockfile
11050 LIBS="$LIBS_MAIL $LIBS"
11052 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
11054 else
11055 # If we have the shared liblockfile, assume we must use it for mail
11056 # locking (e.g. Debian). If we couldn't link against liblockfile
11057 # (no liblockfile.a installed), ensure that we don't need to.
11058 # Extract the first word of "liblockfile.so", so it can be a program name with args.
11059 set dummy liblockfile.so; ac_word=$2
11060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11061 $as_echo_n "checking for $ac_word... " >&6; }
11062 if test "${ac_cv_prog_liblockfile+set}" = set; then :
11063 $as_echo_n "(cached) " >&6
11064 else
11065 if test -n "$liblockfile"; then
11066 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
11067 else
11068 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11069 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
11070 for as_dir in $as_dummy
11072 IFS=$as_save_IFS
11073 test -z "$as_dir" && as_dir=.
11074 for ac_exec_ext in '' $ac_executable_extensions; do
11075 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11076 ac_cv_prog_liblockfile="yes"
11077 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11078 break 2
11080 done
11081 done
11082 IFS=$as_save_IFS
11084 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
11087 liblockfile=$ac_cv_prog_liblockfile
11088 if test -n "$liblockfile"; then
11089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
11090 $as_echo "$liblockfile" >&6; }
11091 else
11092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11093 $as_echo "no" >&6; }
11097 if test $ac_cv_prog_liblockfile = yes; then
11098 as_fn_error "Shared liblockfile found but can't link against it.
11099 This probably means that movemail could lose mail.
11100 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
11103 for ac_func in touchlock
11104 do :
11105 ac_fn_c_check_func "$LINENO" "touchlock" "ac_cv_func_touchlock"
11106 if test "x$ac_cv_func_touchlock" = x""yes; then :
11107 cat >>confdefs.h <<_ACEOF
11108 #define HAVE_TOUCHLOCK 1
11109 _ACEOF
11112 done
11114 for ac_header in maillock.h
11115 do :
11116 ac_fn_c_check_header_mongrel "$LINENO" "maillock.h" "ac_cv_header_maillock_h" "$ac_includes_default"
11117 if test "x$ac_cv_header_maillock_h" = x""yes; then :
11118 cat >>confdefs.h <<_ACEOF
11119 #define HAVE_MAILLOCK_H 1
11120 _ACEOF
11124 done
11128 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
11129 ## interlock access to the mail spool. The alternative is a lock file named
11130 ## /usr/spool/mail/$USER.lock.
11131 mail_lock=no
11132 case "$opsys" in
11133 aix4-2) mail_lock="lockf" ;;
11135 gnu|freebsd|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
11137 ## On GNU/Linux systems, both methods are used by various mail programs.
11138 ## I assume most people are using newer mailers that have heard of flock.
11139 ## Change this if you need to.
11140 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
11141 ## configure gets the right answers, and that means *NOT* using flock.
11142 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
11143 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
11144 ## Debian maintainer hasn't provided a clean fix for Emacs.
11145 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
11146 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
11147 ## correct logic. -- fx
11148 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
11149 ## liblockfile is a Free Software replacement for libmail, used on
11150 ## Debian systems and elsewhere. -rfr.
11151 gnu-*)
11152 mail_lock="flock"
11153 if test $have_mail = yes || test $have_lockfile = yes; then
11154 test $ac_cv_header_maillock_h = yes && mail_lock=no
11157 esac
11159 BLESSMAIL_TARGET=
11160 case "$mail_lock" in
11161 flock)
11162 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
11165 lockf)
11166 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
11169 *) BLESSMAIL_TARGET="need-blessmail" ;;
11170 esac
11174 for ac_func in gethostname getdomainname dup2 \
11175 rename closedir mkdir rmdir sysinfo getrusage get_current_dir_name \
11176 random lrand48 bcopy bcmp logb frexp fmod rint cbrt ftime setsid \
11177 strerror fpathconf select mktime euidaccess getpagesize tzset setlocale \
11178 utimes getrlimit setrlimit setpgid getcwd getwd shutdown getaddrinfo \
11179 __fpending mblen mbrlen mbsinit strsignal setitimer ualarm index rindex \
11180 sendto recvfrom getsockopt setsockopt getsockname getpeername \
11181 gai_strerror mkstemp getline getdelim mremap memmove fsync sync bzero \
11182 memset memcmp difftime memcpy mempcpy mblen mbrlen posix_memalign \
11183 cfmakeraw cfsetspeed isnan copysign
11184 do :
11185 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11186 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11187 eval as_val=\$$as_ac_var
11188 if test "x$as_val" = x""yes; then :
11189 cat >>confdefs.h <<_ACEOF
11190 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11191 _ACEOF
11194 done
11197 for ac_header in sys/un.h
11198 do :
11199 ac_fn_c_check_header_mongrel "$LINENO" "sys/un.h" "ac_cv_header_sys_un_h" "$ac_includes_default"
11200 if test "x$ac_cv_header_sys_un_h" = x""yes; then :
11201 cat >>confdefs.h <<_ACEOF
11202 #define HAVE_SYS_UN_H 1
11203 _ACEOF
11207 done
11215 for ac_func in $ac_func_list
11216 do :
11217 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11218 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11219 eval as_val=\$$as_ac_var
11220 if test "x$as_val" = x""yes; then :
11221 cat >>confdefs.h <<_ACEOF
11222 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11223 _ACEOF
11226 done
11232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
11233 $as_echo_n "checking for working mktime... " >&6; }
11234 if test "${ac_cv_func_working_mktime+set}" = set; then :
11235 $as_echo_n "(cached) " >&6
11236 else
11237 if test "$cross_compiling" = yes; then :
11238 ac_cv_func_working_mktime=no
11239 else
11240 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11241 /* end confdefs.h. */
11242 /* Test program from Paul Eggert and Tony Leneis. */
11243 #ifdef TIME_WITH_SYS_TIME
11244 # include <sys/time.h>
11245 # include <time.h>
11246 #else
11247 # ifdef HAVE_SYS_TIME_H
11248 # include <sys/time.h>
11249 # else
11250 # include <time.h>
11251 # endif
11252 #endif
11254 #include <limits.h>
11255 #include <stdlib.h>
11257 #ifdef HAVE_UNISTD_H
11258 # include <unistd.h>
11259 #endif
11261 #ifndef HAVE_ALARM
11262 # define alarm(X) /* empty */
11263 #endif
11265 /* Work around redefinition to rpl_putenv by other config tests. */
11266 #undef putenv
11268 static time_t time_t_max;
11269 static time_t time_t_min;
11271 /* Values we'll use to set the TZ environment variable. */
11272 static char *tz_strings[] = {
11273 (char *) 0, "TZ=GMT0", "TZ=JST-9",
11274 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
11276 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
11278 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
11279 Based on a problem report from Andreas Jaeger. */
11280 static int
11281 spring_forward_gap ()
11283 /* glibc (up to about 1998-10-07) failed this test. */
11284 struct tm tm;
11286 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
11287 instead of "TZ=America/Vancouver" in order to detect the bug even
11288 on systems that don't support the Olson extension, or don't have the
11289 full zoneinfo tables installed. */
11290 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
11292 tm.tm_year = 98;
11293 tm.tm_mon = 3;
11294 tm.tm_mday = 5;
11295 tm.tm_hour = 2;
11296 tm.tm_min = 0;
11297 tm.tm_sec = 0;
11298 tm.tm_isdst = -1;
11299 return mktime (&tm) != (time_t) -1;
11302 static int
11303 mktime_test1 (now)
11304 time_t now;
11306 struct tm *lt;
11307 return ! (lt = localtime (&now)) || mktime (lt) == now;
11310 static int
11311 mktime_test (now)
11312 time_t now;
11314 return (mktime_test1 (now)
11315 && mktime_test1 ((time_t) (time_t_max - now))
11316 && mktime_test1 ((time_t) (time_t_min + now)));
11319 static int
11320 irix_6_4_bug ()
11322 /* Based on code from Ariel Faigon. */
11323 struct tm tm;
11324 tm.tm_year = 96;
11325 tm.tm_mon = 3;
11326 tm.tm_mday = 0;
11327 tm.tm_hour = 0;
11328 tm.tm_min = 0;
11329 tm.tm_sec = 0;
11330 tm.tm_isdst = -1;
11331 mktime (&tm);
11332 return tm.tm_mon == 2 && tm.tm_mday == 31;
11335 static int
11336 bigtime_test (j)
11337 int j;
11339 struct tm tm;
11340 time_t now;
11341 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
11342 now = mktime (&tm);
11343 if (now != (time_t) -1)
11345 struct tm *lt = localtime (&now);
11346 if (! (lt
11347 && lt->tm_year == tm.tm_year
11348 && lt->tm_mon == tm.tm_mon
11349 && lt->tm_mday == tm.tm_mday
11350 && lt->tm_hour == tm.tm_hour
11351 && lt->tm_min == tm.tm_min
11352 && lt->tm_sec == tm.tm_sec
11353 && lt->tm_yday == tm.tm_yday
11354 && lt->tm_wday == tm.tm_wday
11355 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
11356 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
11357 return 0;
11359 return 1;
11362 static int
11363 year_2050_test ()
11365 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
11366 ignoring leap seconds. */
11367 unsigned long int answer = 2527315200UL;
11369 struct tm tm;
11370 time_t t;
11371 tm.tm_year = 2050 - 1900;
11372 tm.tm_mon = 2 - 1;
11373 tm.tm_mday = 1;
11374 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
11375 tm.tm_isdst = -1;
11377 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
11378 instead of "TZ=America/Vancouver" in order to detect the bug even
11379 on systems that don't support the Olson extension, or don't have the
11380 full zoneinfo tables installed. */
11381 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
11383 t = mktime (&tm);
11385 /* Check that the result is either a failure, or close enough
11386 to the correct answer that we can assume the discrepancy is
11387 due to leap seconds. */
11388 return (t == (time_t) -1
11389 || (0 < t && answer - 120 <= t && t <= answer + 120));
11393 main ()
11395 time_t t, delta;
11396 int i, j;
11398 /* This test makes some buggy mktime implementations loop.
11399 Give up after 60 seconds; a mktime slower than that
11400 isn't worth using anyway. */
11401 alarm (60);
11403 for (;;)
11405 t = (time_t_max << 1) + 1;
11406 if (t <= time_t_max)
11407 break;
11408 time_t_max = t;
11410 time_t_min = - ((time_t) ~ (time_t) 0 == (time_t) -1) - time_t_max;
11412 delta = time_t_max / 997; /* a suitable prime number */
11413 for (i = 0; i < N_STRINGS; i++)
11415 if (tz_strings[i])
11416 putenv (tz_strings[i]);
11418 for (t = 0; t <= time_t_max - delta; t += delta)
11419 if (! mktime_test (t))
11420 return 1;
11421 if (! (mktime_test ((time_t) 1)
11422 && mktime_test ((time_t) (60 * 60))
11423 && mktime_test ((time_t) (60 * 60 * 24))))
11424 return 1;
11426 for (j = 1; ; j <<= 1)
11427 if (! bigtime_test (j))
11428 return 1;
11429 else if (INT_MAX / 2 < j)
11430 break;
11431 if (! bigtime_test (INT_MAX))
11432 return 1;
11434 return ! (irix_6_4_bug () && spring_forward_gap () && year_2050_test ());
11436 _ACEOF
11437 if ac_fn_c_try_run "$LINENO"; then :
11438 ac_cv_func_working_mktime=yes
11439 else
11440 ac_cv_func_working_mktime=no
11442 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11443 conftest.$ac_objext conftest.beam conftest.$ac_ext
11447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_working_mktime" >&5
11448 $as_echo "$ac_cv_func_working_mktime" >&6; }
11449 if test $ac_cv_func_working_mktime = no; then
11450 case " $LIBOBJS " in
11451 *" mktime.$ac_objext "* ) ;;
11452 *) LIBOBJS="$LIBOBJS mktime.$ac_objext"
11454 esac
11458 if test "$ac_cv_func_working_mktime" = no; then
11460 $as_echo "#define BROKEN_MKTIME 1" >>confdefs.h
11464 ac_have_func=no # yes means we've found a way to get the load average.
11466 # Make sure getloadavg.c is where it belongs, at configure-time.
11467 test -f "$srcdir/$ac_config_libobj_dir/getloadavg.c" ||
11468 as_fn_error "$srcdir/$ac_config_libobj_dir/getloadavg.c is missing" "$LINENO" 5
11470 ac_save_LIBS=$LIBS
11472 # Check for getloadavg, but be sure not to touch the cache variable.
11473 (ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
11474 if test "x$ac_cv_func_getloadavg" = x""yes; then :
11475 exit 0
11476 else
11477 exit 1
11479 ) && ac_have_func=yes
11481 # On HPUX9, an unprivileged user can get load averages through this function.
11482 for ac_func in pstat_getdynamic
11483 do :
11484 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
11485 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
11486 cat >>confdefs.h <<_ACEOF
11487 #define HAVE_PSTAT_GETDYNAMIC 1
11488 _ACEOF
11491 done
11494 # Solaris has libkstat which does not require root.
11495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
11496 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
11497 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
11498 $as_echo_n "(cached) " >&6
11499 else
11500 ac_check_lib_save_LIBS=$LIBS
11501 LIBS="-lkstat $LIBS"
11502 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11503 /* end confdefs.h. */
11505 /* Override any GCC internal prototype to avoid an error.
11506 Use char because int might match the return type of a GCC
11507 builtin and then its argument prototype would still apply. */
11508 #ifdef __cplusplus
11509 extern "C"
11510 #endif
11511 char kstat_open ();
11513 main ()
11515 return kstat_open ();
11517 return 0;
11519 _ACEOF
11520 if ac_fn_c_try_link "$LINENO"; then :
11521 ac_cv_lib_kstat_kstat_open=yes
11522 else
11523 ac_cv_lib_kstat_kstat_open=no
11525 rm -f core conftest.err conftest.$ac_objext \
11526 conftest$ac_exeext conftest.$ac_ext
11527 LIBS=$ac_check_lib_save_LIBS
11529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
11530 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
11531 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
11532 cat >>confdefs.h <<_ACEOF
11533 #define HAVE_LIBKSTAT 1
11534 _ACEOF
11536 LIBS="-lkstat $LIBS"
11540 test $ac_cv_lib_kstat_kstat_open = yes && ac_have_func=yes
11542 # Some systems with -lutil have (and need) -lkvm as well, some do not.
11543 # On Solaris, -lkvm requires nlist from -lelf, so check that first
11544 # to get the right answer into the cache.
11545 # For kstat on solaris, we need libelf to force the definition of SVR4 below.
11546 if test $ac_have_func = no; then
11547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
11548 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
11549 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
11550 $as_echo_n "(cached) " >&6
11551 else
11552 ac_check_lib_save_LIBS=$LIBS
11553 LIBS="-lelf $LIBS"
11554 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11555 /* end confdefs.h. */
11557 /* Override any GCC internal prototype to avoid an error.
11558 Use char because int might match the return type of a GCC
11559 builtin and then its argument prototype would still apply. */
11560 #ifdef __cplusplus
11561 extern "C"
11562 #endif
11563 char elf_begin ();
11565 main ()
11567 return elf_begin ();
11569 return 0;
11571 _ACEOF
11572 if ac_fn_c_try_link "$LINENO"; then :
11573 ac_cv_lib_elf_elf_begin=yes
11574 else
11575 ac_cv_lib_elf_elf_begin=no
11577 rm -f core conftest.err conftest.$ac_objext \
11578 conftest$ac_exeext conftest.$ac_ext
11579 LIBS=$ac_check_lib_save_LIBS
11581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
11582 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
11583 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
11584 LIBS="-lelf $LIBS"
11588 if test $ac_have_func = no; then
11589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
11590 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
11591 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
11592 $as_echo_n "(cached) " >&6
11593 else
11594 ac_check_lib_save_LIBS=$LIBS
11595 LIBS="-lkvm $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 kvm_open ();
11607 main ()
11609 return kvm_open ();
11611 return 0;
11613 _ACEOF
11614 if ac_fn_c_try_link "$LINENO"; then :
11615 ac_cv_lib_kvm_kvm_open=yes
11616 else
11617 ac_cv_lib_kvm_kvm_open=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_kvm_kvm_open" >&5
11624 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
11625 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
11626 LIBS="-lkvm $LIBS"
11629 # Check for the 4.4BSD definition of getloadavg.
11630 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
11631 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
11632 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
11633 $as_echo_n "(cached) " >&6
11634 else
11635 ac_check_lib_save_LIBS=$LIBS
11636 LIBS="-lutil $LIBS"
11637 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11638 /* end confdefs.h. */
11640 /* Override any GCC internal prototype to avoid an error.
11641 Use char because int might match the return type of a GCC
11642 builtin and then its argument prototype would still apply. */
11643 #ifdef __cplusplus
11644 extern "C"
11645 #endif
11646 char getloadavg ();
11648 main ()
11650 return getloadavg ();
11652 return 0;
11654 _ACEOF
11655 if ac_fn_c_try_link "$LINENO"; then :
11656 ac_cv_lib_util_getloadavg=yes
11657 else
11658 ac_cv_lib_util_getloadavg=no
11660 rm -f core conftest.err conftest.$ac_objext \
11661 conftest$ac_exeext conftest.$ac_ext
11662 LIBS=$ac_check_lib_save_LIBS
11664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
11665 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
11666 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
11667 LIBS="-lutil $LIBS" ac_have_func=yes ac_cv_func_getloadavg_setgid=yes
11672 if test $ac_have_func = no; then
11673 # There is a commonly available library for RS/6000 AIX.
11674 # Since it is not a standard part of AIX, it might be installed locally.
11675 ac_getloadavg_LIBS=$LIBS
11676 LIBS="-L/usr/local/lib $LIBS"
11677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
11678 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
11679 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
11680 $as_echo_n "(cached) " >&6
11681 else
11682 ac_check_lib_save_LIBS=$LIBS
11683 LIBS="-lgetloadavg $LIBS"
11684 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11685 /* end confdefs.h. */
11687 /* Override any GCC internal prototype to avoid an error.
11688 Use char because int might match the return type of a GCC
11689 builtin and then its argument prototype would still apply. */
11690 #ifdef __cplusplus
11691 extern "C"
11692 #endif
11693 char getloadavg ();
11695 main ()
11697 return getloadavg ();
11699 return 0;
11701 _ACEOF
11702 if ac_fn_c_try_link "$LINENO"; then :
11703 ac_cv_lib_getloadavg_getloadavg=yes
11704 else
11705 ac_cv_lib_getloadavg_getloadavg=no
11707 rm -f core conftest.err conftest.$ac_objext \
11708 conftest$ac_exeext conftest.$ac_ext
11709 LIBS=$ac_check_lib_save_LIBS
11711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
11712 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
11713 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
11714 LIBS="-lgetloadavg $LIBS"
11715 else
11716 LIBS=$ac_getloadavg_LIBS
11721 # Make sure it is really in the library, if we think we found it,
11722 # otherwise set up the replacement function.
11723 for ac_func in getloadavg
11724 do :
11725 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
11726 if test "x$ac_cv_func_getloadavg" = x""yes; then :
11727 cat >>confdefs.h <<_ACEOF
11728 #define HAVE_GETLOADAVG 1
11729 _ACEOF
11731 else
11732 case " $LIBOBJS " in
11733 *" getloadavg.$ac_objext "* ) ;;
11734 *) LIBOBJS="$LIBOBJS getloadavg.$ac_objext"
11736 esac
11739 $as_echo "#define C_GETLOADAVG 1" >>confdefs.h
11741 # Figure out what our getloadavg.c needs.
11742 ac_have_func=no
11743 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
11744 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
11745 ac_have_func=yes
11747 $as_echo "#define DGUX 1" >>confdefs.h
11749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
11750 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
11751 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
11752 $as_echo_n "(cached) " >&6
11753 else
11754 ac_check_lib_save_LIBS=$LIBS
11755 LIBS="-ldgc $LIBS"
11756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11757 /* end confdefs.h. */
11759 /* Override any GCC internal prototype to avoid an error.
11760 Use char because int might match the return type of a GCC
11761 builtin and then its argument prototype would still apply. */
11762 #ifdef __cplusplus
11763 extern "C"
11764 #endif
11765 char dg_sys_info ();
11767 main ()
11769 return dg_sys_info ();
11771 return 0;
11773 _ACEOF
11774 if ac_fn_c_try_link "$LINENO"; then :
11775 ac_cv_lib_dgc_dg_sys_info=yes
11776 else
11777 ac_cv_lib_dgc_dg_sys_info=no
11779 rm -f core conftest.err conftest.$ac_objext \
11780 conftest$ac_exeext conftest.$ac_ext
11781 LIBS=$ac_check_lib_save_LIBS
11783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
11784 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
11785 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
11786 cat >>confdefs.h <<_ACEOF
11787 #define HAVE_LIBDGC 1
11788 _ACEOF
11790 LIBS="-ldgc $LIBS"
11798 ac_fn_c_check_header_mongrel "$LINENO" "locale.h" "ac_cv_header_locale_h" "$ac_includes_default"
11799 if test "x$ac_cv_header_locale_h" = x""yes; then :
11804 for ac_func in setlocale
11805 do :
11806 ac_fn_c_check_func "$LINENO" "setlocale" "ac_cv_func_setlocale"
11807 if test "x$ac_cv_func_setlocale" = x""yes; then :
11808 cat >>confdefs.h <<_ACEOF
11809 #define HAVE_SETLOCALE 1
11810 _ACEOF
11813 done
11816 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
11817 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
11818 # Irix 4.0.5F has the header but not the library.
11819 if test $ac_have_func = no && test "$ac_cv_lib_elf_elf_begin" = yes; then
11820 ac_have_func=yes
11822 $as_echo "#define SVR4 1" >>confdefs.h
11826 if test $ac_have_func = no; then
11827 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
11828 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
11829 ac_have_func=yes
11831 $as_echo "#define UMAX 1" >>confdefs.h
11834 $as_echo "#define UMAX4_3 1" >>confdefs.h
11841 if test $ac_have_func = no; then
11842 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
11843 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
11844 ac_have_func=yes; $as_echo "#define UMAX 1" >>confdefs.h
11851 if test $ac_have_func = no; then
11852 for ac_header in mach/mach.h
11853 do :
11854 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
11855 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
11856 cat >>confdefs.h <<_ACEOF
11857 #define HAVE_MACH_MACH_H 1
11858 _ACEOF
11862 done
11866 for ac_header in nlist.h
11867 do :
11868 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
11869 if test "x$ac_cv_header_nlist_h" = x""yes; then :
11870 cat >>confdefs.h <<_ACEOF
11871 #define HAVE_NLIST_H 1
11872 _ACEOF
11873 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
11875 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
11877 cat >>confdefs.h <<_ACEOF
11878 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
11879 _ACEOF
11882 $as_echo "#define NLIST_NAME_UNION 1" >>confdefs.h
11889 done
11892 done
11895 # Some definitions of getloadavg require that the program be installed setgid.
11896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getloadavg requires setgid" >&5
11897 $as_echo_n "checking whether getloadavg requires setgid... " >&6; }
11898 if test "${ac_cv_func_getloadavg_setgid+set}" = set; then :
11899 $as_echo_n "(cached) " >&6
11900 else
11901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11902 /* end confdefs.h. */
11903 #include "$srcdir/$ac_config_libobj_dir/getloadavg.c"
11904 #ifdef LDAV_PRIVILEGED
11905 Yowza Am I SETGID yet
11906 #endif
11907 _ACEOF
11908 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11909 $EGREP "Yowza Am I SETGID yet" >/dev/null 2>&1; then :
11910 ac_cv_func_getloadavg_setgid=yes
11911 else
11912 ac_cv_func_getloadavg_setgid=no
11914 rm -f conftest*
11917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getloadavg_setgid" >&5
11918 $as_echo "$ac_cv_func_getloadavg_setgid" >&6; }
11919 if test $ac_cv_func_getloadavg_setgid = yes; then
11920 NEED_SETGID=true
11922 $as_echo "#define GETLOADAVG_PRIVILEGED 1" >>confdefs.h
11924 else
11925 NEED_SETGID=false
11928 if test $ac_cv_func_getloadavg_setgid = yes; then
11929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking group of /dev/kmem" >&5
11930 $as_echo_n "checking group of /dev/kmem... " >&6; }
11931 if test "${ac_cv_group_kmem+set}" = set; then :
11932 $as_echo_n "(cached) " >&6
11933 else
11934 # On Solaris, /dev/kmem is a symlink. Get info on the real file.
11935 ac_ls_output=`ls -lgL /dev/kmem 2>/dev/null`
11936 # If we got an error (system does not support symlinks), try without -L.
11937 test -z "$ac_ls_output" && ac_ls_output=`ls -lg /dev/kmem`
11938 ac_cv_group_kmem=`$as_echo "$ac_ls_output" \
11939 | sed -ne 's/[ ][ ]*/ /g;
11940 s/^.[sSrwx-]* *[0-9]* *\([^0-9]*\) *.*/\1/;
11941 / /s/.* //;p;'`
11944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_group_kmem" >&5
11945 $as_echo "$ac_cv_group_kmem" >&6; }
11946 KMEM_GROUP=$ac_cv_group_kmem
11948 if test "x$ac_save_LIBS" = x; then
11949 GETLOADAVG_LIBS=$LIBS
11950 else
11951 GETLOADAVG_LIBS=`$as_echo "$LIBS" | sed "s|$ac_save_LIBS||"`
11953 LIBS=$ac_save_LIBS
11957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
11958 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
11959 if test "${ac_cv_sys_largefile_source+set}" = set; then :
11960 $as_echo_n "(cached) " >&6
11961 else
11962 while :; do
11963 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11964 /* end confdefs.h. */
11965 #include <sys/types.h> /* for off_t */
11966 #include <stdio.h>
11968 main ()
11970 int (*fp) (FILE *, off_t, int) = fseeko;
11971 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
11973 return 0;
11975 _ACEOF
11976 if ac_fn_c_try_link "$LINENO"; then :
11977 ac_cv_sys_largefile_source=no; break
11979 rm -f core conftest.err conftest.$ac_objext \
11980 conftest$ac_exeext conftest.$ac_ext
11981 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11982 /* end confdefs.h. */
11983 #define _LARGEFILE_SOURCE 1
11984 #include <sys/types.h> /* for off_t */
11985 #include <stdio.h>
11987 main ()
11989 int (*fp) (FILE *, off_t, int) = fseeko;
11990 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
11992 return 0;
11994 _ACEOF
11995 if ac_fn_c_try_link "$LINENO"; then :
11996 ac_cv_sys_largefile_source=1; break
11998 rm -f core conftest.err conftest.$ac_objext \
11999 conftest$ac_exeext conftest.$ac_ext
12000 ac_cv_sys_largefile_source=unknown
12001 break
12002 done
12004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
12005 $as_echo "$ac_cv_sys_largefile_source" >&6; }
12006 case $ac_cv_sys_largefile_source in #(
12007 no | unknown) ;;
12009 cat >>confdefs.h <<_ACEOF
12010 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
12011 _ACEOF
12013 esac
12014 rm -rf conftest*
12016 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
12017 # in glibc 2.1.3, but that breaks too many other things.
12018 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
12019 if test $ac_cv_sys_largefile_source != unknown; then
12021 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
12026 # Configure getopt.
12027 # getopt.m4 serial 10
12029 # The getopt module assume you want GNU getopt, with getopt_long etc,
12030 # rather than vanilla POSIX getopt. This means your your code should
12031 # always include <getopt.h> for the getopt prototypes.
12043 # Prerequisites of lib/getopt*.
12048 GETOPT_H=
12049 for ac_header in getopt.h
12050 do :
12051 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
12052 if test "x$ac_cv_header_getopt_h" = x""yes; then :
12053 cat >>confdefs.h <<_ACEOF
12054 #define HAVE_GETOPT_H 1
12055 _ACEOF
12057 else
12058 GETOPT_H=getopt.h
12061 done
12063 if test -z "$GETOPT_H"; then
12064 for ac_func in getopt_long_only
12065 do :
12066 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
12067 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
12068 cat >>confdefs.h <<_ACEOF
12069 #define HAVE_GETOPT_LONG_ONLY 1
12070 _ACEOF
12072 else
12073 GETOPT_H=getopt.h
12075 done
12079 if test -z "$GETOPT_H"; then
12080 ac_fn_c_check_decl "$LINENO" "optreset" "ac_cv_have_decl_optreset" "#include <getopt.h>
12082 if test "x$ac_cv_have_decl_optreset" = x""yes; then :
12083 GETOPT_H=getopt.h
12088 if test -z "$GETOPT_H"; then
12089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
12090 $as_echo_n "checking for working GNU getopt function... " >&6; }
12091 if test "${gl_cv_func_gnu_getopt+set}" = set; then :
12092 $as_echo_n "(cached) " >&6
12093 else
12094 if test "$cross_compiling" = yes; then :
12095 ac_fn_c_check_decl "$LINENO" "getopt_clip" "ac_cv_have_decl_getopt_clip" "#include <getopt.h>
12097 if test "x$ac_cv_have_decl_getopt_clip" = x""yes; then :
12098 gl_cv_func_gnu_getopt=no
12099 else
12100 gl_cv_func_gnu_getopt=yes
12103 else
12104 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12105 /* end confdefs.h. */
12106 #include <getopt.h>
12108 main ()
12111 char *myargv[3];
12112 myargv[0] = "conftest";
12113 myargv[1] = "-+";
12114 myargv[2] = 0;
12115 return getopt (2, myargv, "+a") != '?';
12118 return 0;
12120 _ACEOF
12121 if ac_fn_c_try_run "$LINENO"; then :
12122 gl_cv_func_gnu_getopt=yes
12123 else
12124 gl_cv_func_gnu_getopt=no
12126 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12127 conftest.$ac_objext conftest.beam conftest.$ac_ext
12131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gnu_getopt" >&5
12132 $as_echo "$gl_cv_func_gnu_getopt" >&6; }
12133 if test "$gl_cv_func_gnu_getopt" = "no"; then
12134 GETOPT_H=getopt.h
12140 if test -n "$GETOPT_H"; then :
12143 GETOPT_H=getopt.h
12145 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
12150 GETOPTOBJS='getopt.o getopt1.o'
12156 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5
12157 $as_echo_n "checking whether getpgrp requires zero arguments... " >&6; }
12158 if test "${ac_cv_func_getpgrp_void+set}" = set; then :
12159 $as_echo_n "(cached) " >&6
12160 else
12161 # Use it with a single arg.
12162 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12163 /* end confdefs.h. */
12164 $ac_includes_default
12166 main ()
12168 getpgrp (0);
12170 return 0;
12172 _ACEOF
12173 if ac_fn_c_try_compile "$LINENO"; then :
12174 ac_cv_func_getpgrp_void=no
12175 else
12176 ac_cv_func_getpgrp_void=yes
12178 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5
12182 $as_echo "$ac_cv_func_getpgrp_void" >&6; }
12183 if test $ac_cv_func_getpgrp_void = yes; then
12185 $as_echo "#define GETPGRP_VOID 1" >>confdefs.h
12190 for ac_func in strftime
12191 do :
12192 ac_fn_c_check_func "$LINENO" "strftime" "ac_cv_func_strftime"
12193 if test "x$ac_cv_func_strftime" = x""yes; then :
12194 cat >>confdefs.h <<_ACEOF
12195 #define HAVE_STRFTIME 1
12196 _ACEOF
12198 else
12199 # strftime is in -lintl on SCO UNIX.
12200 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for strftime in -lintl" >&5
12201 $as_echo_n "checking for strftime in -lintl... " >&6; }
12202 if test "${ac_cv_lib_intl_strftime+set}" = set; then :
12203 $as_echo_n "(cached) " >&6
12204 else
12205 ac_check_lib_save_LIBS=$LIBS
12206 LIBS="-lintl $LIBS"
12207 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12208 /* end confdefs.h. */
12210 /* Override any GCC internal prototype to avoid an error.
12211 Use char because int might match the return type of a GCC
12212 builtin and then its argument prototype would still apply. */
12213 #ifdef __cplusplus
12214 extern "C"
12215 #endif
12216 char strftime ();
12218 main ()
12220 return strftime ();
12222 return 0;
12224 _ACEOF
12225 if ac_fn_c_try_link "$LINENO"; then :
12226 ac_cv_lib_intl_strftime=yes
12227 else
12228 ac_cv_lib_intl_strftime=no
12230 rm -f core conftest.err conftest.$ac_objext \
12231 conftest$ac_exeext conftest.$ac_ext
12232 LIBS=$ac_check_lib_save_LIBS
12234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_strftime" >&5
12235 $as_echo "$ac_cv_lib_intl_strftime" >&6; }
12236 if test "x$ac_cv_lib_intl_strftime" = x""yes; then :
12237 $as_echo "#define HAVE_STRFTIME 1" >>confdefs.h
12239 LIBS="-lintl $LIBS"
12243 done
12246 # UNIX98 PTYs.
12247 for ac_func in grantpt
12248 do :
12249 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
12250 if test "x$ac_cv_func_grantpt" = x""yes; then :
12251 cat >>confdefs.h <<_ACEOF
12252 #define HAVE_GRANTPT 1
12253 _ACEOF
12256 done
12259 # PTY-related GNU extensions.
12260 for ac_func in getpt
12261 do :
12262 ac_fn_c_check_func "$LINENO" "getpt" "ac_cv_func_getpt"
12263 if test "x$ac_cv_func_getpt" = x""yes; then :
12264 cat >>confdefs.h <<_ACEOF
12265 #define HAVE_GETPT 1
12266 _ACEOF
12269 done
12272 # Check this now, so that we will NOT find the above functions in ncurses.
12273 # That is because we have not set up to link ncurses in lib-src.
12274 # It's better to believe a function is not available
12275 # than to expect to find it in ncurses.
12276 # Also we need tputs and friends to be able to build at all.
12277 have_tputs_et_al=true
12278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
12279 $as_echo_n "checking for library containing tputs... " >&6; }
12280 if test "${ac_cv_search_tputs+set}" = set; then :
12281 $as_echo_n "(cached) " >&6
12282 else
12283 ac_func_search_save_LIBS=$LIBS
12284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12285 /* end confdefs.h. */
12287 /* Override any GCC internal prototype to avoid an error.
12288 Use char because int might match the return type of a GCC
12289 builtin and then its argument prototype would still apply. */
12290 #ifdef __cplusplus
12291 extern "C"
12292 #endif
12293 char tputs ();
12295 main ()
12297 return tputs ();
12299 return 0;
12301 _ACEOF
12302 for ac_lib in '' ncurses terminfo termcap; do
12303 if test -z "$ac_lib"; then
12304 ac_res="none required"
12305 else
12306 ac_res=-l$ac_lib
12307 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
12309 if ac_fn_c_try_link "$LINENO"; then :
12310 ac_cv_search_tputs=$ac_res
12312 rm -f core conftest.err conftest.$ac_objext \
12313 conftest$ac_exeext
12314 if test "${ac_cv_search_tputs+set}" = set; then :
12315 break
12317 done
12318 if test "${ac_cv_search_tputs+set}" = set; then :
12320 else
12321 ac_cv_search_tputs=no
12323 rm conftest.$ac_ext
12324 LIBS=$ac_func_search_save_LIBS
12326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_tputs" >&5
12327 $as_echo "$ac_cv_search_tputs" >&6; }
12328 ac_res=$ac_cv_search_tputs
12329 if test "$ac_res" != no; then :
12330 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
12332 else
12333 have_tputs_et_al=false
12336 if test "$have_tputs_et_al" != true; then
12337 as_fn_error "I couldn't find termcap functions (tputs and friends).
12338 Maybe some development libraries/packages are missing? Try installing
12339 libncurses-dev(el), libterminfo-dev(el) or similar." "$LINENO" 5
12341 # Must define this when any termcap library is found.
12343 $as_echo "#define HAVE_LIBNCURSES 1" >>confdefs.h
12345 ## FIXME This was the cpp logic, but I am not sure it is right.
12346 ## The above test has not necessarily found libncurses.
12347 HAVE_LIBNCURSES=yes
12349 ## Use terminfo instead of termcap?
12350 ## Note only system files NOT using terminfo are:
12351 ## freebsd < 40000, ms-w32, msdos, netbsd < 599002500, and
12352 ## darwin|gnu without ncurses.
12353 TERMINFO=no
12354 LIBS_TERMCAP=
12355 case "$opsys" in
12356 ## cygwin: Fewer environment variables to go wrong, more terminal types.
12357 ## hpux10-20: Use the system provided termcap(3) library.
12358 ## openbsd: David Mazieres <dm@reeducation-labor.lcs.mit.edu> says this
12359 ## is necessary. Otherwise Emacs dumps core when run -nw.
12360 aix4-2|cygwin|hpux*|irix6-5|openbsd|sol2*|unixware) TERMINFO=yes ;;
12362 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
12363 ## The ncurses library has been moved out of the System framework in
12364 ## Mac OS X 10.2. So if configure detects it, set the command-line
12365 ## option to use it.
12366 darwin|gnu*)
12367 ## (HAVE_LIBNCURSES was not always true, but is since 2010-03-18.)
12368 if test "x$HAVE_LIBNCURSES" = "xyes"; then
12369 TERMINFO=yes
12370 LIBS_TERMCAP="-lncurses"
12374 freebsd)
12375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
12376 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
12377 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
12378 $as_echo_n "(cached) " >&6
12379 else
12380 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12381 /* end confdefs.h. */
12382 #include <osreldate.h>
12384 main ()
12386 #if __FreeBSD_version < 400000
12387 fail;
12388 #endif
12391 return 0;
12393 _ACEOF
12394 if ac_fn_c_try_link "$LINENO"; then :
12395 emacs_cv_freebsd_terminfo=yes
12396 else
12397 emacs_cv_freebsd_terminfo=no
12399 rm -f core conftest.err conftest.$ac_objext \
12400 conftest$ac_exeext conftest.$ac_ext
12404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
12405 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
12407 if test $emacs_cv_freebsd_terminfo = yes; then
12408 TERMINFO=yes
12409 LIBS_TERMCAP="-lncurses"
12410 else
12411 LIBS_TERMCAP="-ltermcap"
12415 netbsd)
12416 if test $ac_cv_search_tputs = -lterminfo; then
12417 TERMINFO=yes
12418 LIBS_TERMCAP="-lterminfo"
12419 else
12420 LIBS_TERMCAP="-ltermcap"
12424 esac
12426 case "$opsys" in
12427 ## hpux: Make sure we get select from libc rather than from libcurses
12428 ## because libcurses on HPUX 10.10 has a broken version of select.
12429 ## We used to use -lc -lcurses, but this may be cleaner.
12430 hpux*) LIBS_TERMCAP="-ltermcap" ;;
12432 openbsd) LIBS_TERMCAP="-lncurses" ;;
12434 ## Must use system termcap, if we use any termcap. It does special things.
12435 sol2*) test "$TERMINFO" != yes && LIBS_TERMCAP="-ltermcap" ;;
12436 esac
12438 TERMCAP_OBJ=tparam.o
12439 if test $TERMINFO = yes; then
12441 $as_echo "#define TERMINFO 1" >>confdefs.h
12444 ## Default used to be -ltermcap. Add a case above if need something else.
12445 test "x$LIBS_TERMCAP" = "x" && LIBS_TERMCAP="-lcurses"
12447 TERMCAP_OBJ=terminfo.o
12453 # Do we have res_init, for detecting changes in /etc/resolv.conf?
12454 resolv=no
12455 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12456 /* end confdefs.h. */
12457 #include <netinet/in.h>
12458 #include <arpa/nameser.h>
12459 #include <resolv.h>
12461 main ()
12463 return res_init();
12465 return 0;
12467 _ACEOF
12468 if ac_fn_c_try_link "$LINENO"; then :
12469 have_res_init=yes
12470 else
12471 have_res_init=no
12473 rm -f core conftest.err conftest.$ac_objext \
12474 conftest$ac_exeext conftest.$ac_ext
12475 if test "$have_res_init" = no; then
12476 OLIBS="$LIBS"
12477 LIBS="$LIBS -lresolv"
12478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
12479 $as_echo_n "checking for res_init with -lresolv... " >&6; }
12480 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12481 /* end confdefs.h. */
12482 #include <netinet/in.h>
12483 #include <arpa/nameser.h>
12484 #include <resolv.h>
12486 main ()
12488 return res_init();
12490 return 0;
12492 _ACEOF
12493 if ac_fn_c_try_link "$LINENO"; then :
12494 have_res_init=yes
12495 else
12496 have_res_init=no
12498 rm -f core conftest.err conftest.$ac_objext \
12499 conftest$ac_exeext conftest.$ac_ext
12500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
12501 $as_echo "$have_res_init" >&6; }
12502 if test "$have_res_init" = yes ; then
12503 resolv=yes
12505 LIBS="$OLIBS"
12508 if test "$have_res_init" = yes; then
12510 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
12514 # Do we need the Hesiod library to provide the support routines?
12515 LIBHESIOD=
12516 if test "$with_hesiod" != no ; then
12517 # Don't set $LIBS here -- see comments above. FIXME which comments?
12518 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
12519 if test "x$ac_cv_func_res_send" = x""yes; then :
12521 else
12522 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
12523 if test "x$ac_cv_func___res_send" = x""yes; then :
12525 else
12526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
12527 $as_echo_n "checking for res_send in -lresolv... " >&6; }
12528 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
12529 $as_echo_n "(cached) " >&6
12530 else
12531 ac_check_lib_save_LIBS=$LIBS
12532 LIBS="-lresolv $LIBS"
12533 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12534 /* end confdefs.h. */
12536 /* Override any GCC internal prototype to avoid an error.
12537 Use char because int might match the return type of a GCC
12538 builtin and then its argument prototype would still apply. */
12539 #ifdef __cplusplus
12540 extern "C"
12541 #endif
12542 char res_send ();
12544 main ()
12546 return res_send ();
12548 return 0;
12550 _ACEOF
12551 if ac_fn_c_try_link "$LINENO"; then :
12552 ac_cv_lib_resolv_res_send=yes
12553 else
12554 ac_cv_lib_resolv_res_send=no
12556 rm -f core conftest.err conftest.$ac_objext \
12557 conftest$ac_exeext conftest.$ac_ext
12558 LIBS=$ac_check_lib_save_LIBS
12560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
12561 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
12562 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
12563 resolv=yes
12564 else
12565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
12566 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
12567 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
12568 $as_echo_n "(cached) " >&6
12569 else
12570 ac_check_lib_save_LIBS=$LIBS
12571 LIBS="-lresolv $LIBS"
12572 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12573 /* end confdefs.h. */
12575 /* Override any GCC internal prototype to avoid an error.
12576 Use char because int might match the return type of a GCC
12577 builtin and then its argument prototype would still apply. */
12578 #ifdef __cplusplus
12579 extern "C"
12580 #endif
12581 char __res_send ();
12583 main ()
12585 return __res_send ();
12587 return 0;
12589 _ACEOF
12590 if ac_fn_c_try_link "$LINENO"; then :
12591 ac_cv_lib_resolv___res_send=yes
12592 else
12593 ac_cv_lib_resolv___res_send=no
12595 rm -f core conftest.err conftest.$ac_objext \
12596 conftest$ac_exeext conftest.$ac_ext
12597 LIBS=$ac_check_lib_save_LIBS
12599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
12600 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
12601 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
12602 resolv=yes
12611 if test "$resolv" = yes ; then
12612 RESOLVLIB=-lresolv
12613 else
12614 RESOLVLIB=
12616 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
12617 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
12619 else
12620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
12621 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
12622 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
12623 $as_echo_n "(cached) " >&6
12624 else
12625 ac_check_lib_save_LIBS=$LIBS
12626 LIBS="-lhesiod $RESOLVLIB $LIBS"
12627 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12628 /* end confdefs.h. */
12630 /* Override any GCC internal prototype to avoid an error.
12631 Use char because int might match the return type of a GCC
12632 builtin and then its argument prototype would still apply. */
12633 #ifdef __cplusplus
12634 extern "C"
12635 #endif
12636 char hes_getmailhost ();
12638 main ()
12640 return hes_getmailhost ();
12642 return 0;
12644 _ACEOF
12645 if ac_fn_c_try_link "$LINENO"; then :
12646 ac_cv_lib_hesiod_hes_getmailhost=yes
12647 else
12648 ac_cv_lib_hesiod_hes_getmailhost=no
12650 rm -f core conftest.err conftest.$ac_objext \
12651 conftest$ac_exeext conftest.$ac_ext
12652 LIBS=$ac_check_lib_save_LIBS
12654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
12655 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
12656 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
12657 hesiod=yes
12658 else
12665 if test x"$hesiod" = xyes; then
12667 $as_echo "#define HAVE_LIBHESIOD 1" >>confdefs.h
12669 LIBHESIOD=-lhesiod
12674 # Do we need libresolv (due to res_init or Hesiod)?
12675 if test "$resolv" = yes ; then
12677 $as_echo "#define HAVE_LIBRESOLV 1" >>confdefs.h
12679 LIBRESOLV=-lresolv
12680 else
12681 LIBRESOLV=
12685 # These tell us which Kerberos-related libraries to use.
12686 COM_ERRLIB=
12687 CRYPTOLIB=
12688 KRB5LIB=
12689 DESLIB=
12690 KRB4LIB=
12692 if test "${with_kerberos}" != no; then
12693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
12694 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
12695 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
12696 $as_echo_n "(cached) " >&6
12697 else
12698 ac_check_lib_save_LIBS=$LIBS
12699 LIBS="-lcom_err $LIBS"
12700 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12701 /* end confdefs.h. */
12703 /* Override any GCC internal prototype to avoid an error.
12704 Use char because int might match the return type of a GCC
12705 builtin and then its argument prototype would still apply. */
12706 #ifdef __cplusplus
12707 extern "C"
12708 #endif
12709 char com_err ();
12711 main ()
12713 return com_err ();
12715 return 0;
12717 _ACEOF
12718 if ac_fn_c_try_link "$LINENO"; then :
12719 ac_cv_lib_com_err_com_err=yes
12720 else
12721 ac_cv_lib_com_err_com_err=no
12723 rm -f core conftest.err conftest.$ac_objext \
12724 conftest$ac_exeext conftest.$ac_ext
12725 LIBS=$ac_check_lib_save_LIBS
12727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
12728 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
12729 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
12730 have_com_err=yes
12731 else
12732 have_com_err=no
12735 if test $have_com_err = yes; then
12736 COM_ERRLIB=-lcom_err
12737 LIBS="$COM_ERRLIB $LIBS"
12739 $as_echo "#define HAVE_LIBCOM_ERR 1" >>confdefs.h
12742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
12743 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
12744 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
12745 $as_echo_n "(cached) " >&6
12746 else
12747 ac_check_lib_save_LIBS=$LIBS
12748 LIBS="-lcrypto $LIBS"
12749 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12750 /* end confdefs.h. */
12752 /* Override any GCC internal prototype to avoid an error.
12753 Use char because int might match the return type of a GCC
12754 builtin and then its argument prototype would still apply. */
12755 #ifdef __cplusplus
12756 extern "C"
12757 #endif
12758 char mit_des_cbc_encrypt ();
12760 main ()
12762 return mit_des_cbc_encrypt ();
12764 return 0;
12766 _ACEOF
12767 if ac_fn_c_try_link "$LINENO"; then :
12768 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
12769 else
12770 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
12772 rm -f core conftest.err conftest.$ac_objext \
12773 conftest$ac_exeext conftest.$ac_ext
12774 LIBS=$ac_check_lib_save_LIBS
12776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
12777 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
12778 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
12779 have_crypto=yes
12780 else
12781 have_crypto=no
12784 if test $have_crypto = yes; then
12785 CRYPTOLIB=-lcrypto
12786 LIBS="$CRYPTOLIB $LIBS"
12788 $as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h
12791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
12792 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
12793 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
12794 $as_echo_n "(cached) " >&6
12795 else
12796 ac_check_lib_save_LIBS=$LIBS
12797 LIBS="-lk5crypto $LIBS"
12798 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12799 /* end confdefs.h. */
12801 /* Override any GCC internal prototype to avoid an error.
12802 Use char because int might match the return type of a GCC
12803 builtin and then its argument prototype would still apply. */
12804 #ifdef __cplusplus
12805 extern "C"
12806 #endif
12807 char mit_des_cbc_encrypt ();
12809 main ()
12811 return mit_des_cbc_encrypt ();
12813 return 0;
12815 _ACEOF
12816 if ac_fn_c_try_link "$LINENO"; then :
12817 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
12818 else
12819 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
12821 rm -f core conftest.err conftest.$ac_objext \
12822 conftest$ac_exeext conftest.$ac_ext
12823 LIBS=$ac_check_lib_save_LIBS
12825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
12826 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
12827 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
12828 have_k5crypto=yes
12829 else
12830 have_k5crypto=no
12833 if test $have_k5crypto = yes; then
12834 CRYPTOLIB=-lk5crypto
12835 LIBS="$CRYPTOLIB $LIBS"
12837 $as_echo "#define HAVE_LIBK5CRYPTO 1" >>confdefs.h
12840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
12841 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
12842 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
12843 $as_echo_n "(cached) " >&6
12844 else
12845 ac_check_lib_save_LIBS=$LIBS
12846 LIBS="-lkrb5 $LIBS"
12847 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12848 /* end confdefs.h. */
12850 /* Override any GCC internal prototype to avoid an error.
12851 Use char because int might match the return type of a GCC
12852 builtin and then its argument prototype would still apply. */
12853 #ifdef __cplusplus
12854 extern "C"
12855 #endif
12856 char krb5_init_context ();
12858 main ()
12860 return krb5_init_context ();
12862 return 0;
12864 _ACEOF
12865 if ac_fn_c_try_link "$LINENO"; then :
12866 ac_cv_lib_krb5_krb5_init_context=yes
12867 else
12868 ac_cv_lib_krb5_krb5_init_context=no
12870 rm -f core conftest.err conftest.$ac_objext \
12871 conftest$ac_exeext conftest.$ac_ext
12872 LIBS=$ac_check_lib_save_LIBS
12874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
12875 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
12876 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
12877 have_krb5=yes
12878 else
12879 have_krb5=no
12882 if test $have_krb5=yes; then
12883 KRB5LIB=-lkrb5
12884 LIBS="$KRB5LIB $LIBS"
12886 $as_echo "#define HAVE_LIBKRB5 1" >>confdefs.h
12889 if test "${with_kerberos5}" = no; then
12890 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
12891 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
12892 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
12893 $as_echo_n "(cached) " >&6
12894 else
12895 ac_check_lib_save_LIBS=$LIBS
12896 LIBS="-ldes425 $LIBS"
12897 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12898 /* end confdefs.h. */
12900 /* Override any GCC internal prototype to avoid an error.
12901 Use char because int might match the return type of a GCC
12902 builtin and then its argument prototype would still apply. */
12903 #ifdef __cplusplus
12904 extern "C"
12905 #endif
12906 char des_cbc_encrypt ();
12908 main ()
12910 return des_cbc_encrypt ();
12912 return 0;
12914 _ACEOF
12915 if ac_fn_c_try_link "$LINENO"; then :
12916 ac_cv_lib_des425_des_cbc_encrypt=yes
12917 else
12918 ac_cv_lib_des425_des_cbc_encrypt=no
12920 rm -f core conftest.err conftest.$ac_objext \
12921 conftest$ac_exeext conftest.$ac_ext
12922 LIBS=$ac_check_lib_save_LIBS
12924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
12925 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
12926 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
12927 have_des425=yes
12928 else
12929 have_des425=no
12932 if test $have_des425 = yes; then
12933 DESLIB=-ldes425
12934 LIBS="$DESLIB $LIBS"
12936 $as_echo "#define HAVE_LIBDES425 1" >>confdefs.h
12938 else
12939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
12940 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
12941 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
12942 $as_echo_n "(cached) " >&6
12943 else
12944 ac_check_lib_save_LIBS=$LIBS
12945 LIBS="-ldes $LIBS"
12946 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12947 /* end confdefs.h. */
12949 /* Override any GCC internal prototype to avoid an error.
12950 Use char because int might match the return type of a GCC
12951 builtin and then its argument prototype would still apply. */
12952 #ifdef __cplusplus
12953 extern "C"
12954 #endif
12955 char des_cbc_encrypt ();
12957 main ()
12959 return des_cbc_encrypt ();
12961 return 0;
12963 _ACEOF
12964 if ac_fn_c_try_link "$LINENO"; then :
12965 ac_cv_lib_des_des_cbc_encrypt=yes
12966 else
12967 ac_cv_lib_des_des_cbc_encrypt=no
12969 rm -f core conftest.err conftest.$ac_objext \
12970 conftest$ac_exeext conftest.$ac_ext
12971 LIBS=$ac_check_lib_save_LIBS
12973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
12974 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
12975 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
12976 have_des=yes
12977 else
12978 have_des=no
12981 if test $have_des = yes; then
12982 DESLIB=-ldes
12983 LIBS="$DESLIB $LIBS"
12985 $as_echo "#define HAVE_LIBDES 1" >>confdefs.h
12989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
12990 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
12991 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
12992 $as_echo_n "(cached) " >&6
12993 else
12994 ac_check_lib_save_LIBS=$LIBS
12995 LIBS="-lkrb4 $LIBS"
12996 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12997 /* end confdefs.h. */
12999 /* Override any GCC internal prototype to avoid an error.
13000 Use char because int might match the return type of a GCC
13001 builtin and then its argument prototype would still apply. */
13002 #ifdef __cplusplus
13003 extern "C"
13004 #endif
13005 char krb_get_cred ();
13007 main ()
13009 return krb_get_cred ();
13011 return 0;
13013 _ACEOF
13014 if ac_fn_c_try_link "$LINENO"; then :
13015 ac_cv_lib_krb4_krb_get_cred=yes
13016 else
13017 ac_cv_lib_krb4_krb_get_cred=no
13019 rm -f core conftest.err conftest.$ac_objext \
13020 conftest$ac_exeext conftest.$ac_ext
13021 LIBS=$ac_check_lib_save_LIBS
13023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
13024 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
13025 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
13026 have_krb4=yes
13027 else
13028 have_krb4=no
13031 if test $have_krb4 = yes; then
13032 KRB4LIB=-lkrb4
13033 LIBS="$KRB4LIB $LIBS"
13035 $as_echo "#define HAVE_LIBKRB4 1" >>confdefs.h
13037 else
13038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
13039 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
13040 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
13041 $as_echo_n "(cached) " >&6
13042 else
13043 ac_check_lib_save_LIBS=$LIBS
13044 LIBS="-lkrb $LIBS"
13045 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13046 /* end confdefs.h. */
13048 /* Override any GCC internal prototype to avoid an error.
13049 Use char because int might match the return type of a GCC
13050 builtin and then its argument prototype would still apply. */
13051 #ifdef __cplusplus
13052 extern "C"
13053 #endif
13054 char krb_get_cred ();
13056 main ()
13058 return krb_get_cred ();
13060 return 0;
13062 _ACEOF
13063 if ac_fn_c_try_link "$LINENO"; then :
13064 ac_cv_lib_krb_krb_get_cred=yes
13065 else
13066 ac_cv_lib_krb_krb_get_cred=no
13068 rm -f core conftest.err conftest.$ac_objext \
13069 conftest$ac_exeext conftest.$ac_ext
13070 LIBS=$ac_check_lib_save_LIBS
13072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
13073 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
13074 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
13075 have_krb=yes
13076 else
13077 have_krb=no
13080 if test $have_krb = yes; then
13081 KRB4LIB=-lkrb
13082 LIBS="$KRB4LIB $LIBS"
13084 $as_echo "#define HAVE_LIBKRB 1" >>confdefs.h
13090 if test "${with_kerberos5}" != no; then
13091 for ac_header in krb5.h
13092 do :
13093 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
13094 if test "x$ac_cv_header_krb5_h" = x""yes; then :
13095 cat >>confdefs.h <<_ACEOF
13096 #define HAVE_KRB5_H 1
13097 _ACEOF
13098 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
13100 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
13102 cat >>confdefs.h <<_ACEOF
13103 #define HAVE_KRB5_ERROR_TEXT 1
13104 _ACEOF
13108 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
13110 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
13112 cat >>confdefs.h <<_ACEOF
13113 #define HAVE_KRB5_ERROR_E_TEXT 1
13114 _ACEOF
13121 done
13123 else
13124 for ac_header in des.h
13125 do :
13126 ac_fn_c_check_header_mongrel "$LINENO" "des.h" "ac_cv_header_des_h" "$ac_includes_default"
13127 if test "x$ac_cv_header_des_h" = x""yes; then :
13128 cat >>confdefs.h <<_ACEOF
13129 #define HAVE_DES_H 1
13130 _ACEOF
13132 else
13133 for ac_header in kerberosIV/des.h
13134 do :
13135 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/des.h" "ac_cv_header_kerberosIV_des_h" "$ac_includes_default"
13136 if test "x$ac_cv_header_kerberosIV_des_h" = x""yes; then :
13137 cat >>confdefs.h <<_ACEOF
13138 #define HAVE_KERBEROSIV_DES_H 1
13139 _ACEOF
13141 else
13142 for ac_header in kerberos/des.h
13143 do :
13144 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/des.h" "ac_cv_header_kerberos_des_h" "$ac_includes_default"
13145 if test "x$ac_cv_header_kerberos_des_h" = x""yes; then :
13146 cat >>confdefs.h <<_ACEOF
13147 #define HAVE_KERBEROS_DES_H 1
13148 _ACEOF
13152 done
13156 done
13160 done
13162 for ac_header in krb.h
13163 do :
13164 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
13165 if test "x$ac_cv_header_krb_h" = x""yes; then :
13166 cat >>confdefs.h <<_ACEOF
13167 #define HAVE_KRB_H 1
13168 _ACEOF
13170 else
13171 for ac_header in kerberosIV/krb.h
13172 do :
13173 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
13174 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
13175 cat >>confdefs.h <<_ACEOF
13176 #define HAVE_KERBEROSIV_KRB_H 1
13177 _ACEOF
13179 else
13180 for ac_header in kerberos/krb.h
13181 do :
13182 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
13183 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
13184 cat >>confdefs.h <<_ACEOF
13185 #define HAVE_KERBEROS_KRB_H 1
13186 _ACEOF
13190 done
13194 done
13198 done
13201 for ac_header in com_err.h
13202 do :
13203 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
13204 if test "x$ac_cv_header_com_err_h" = x""yes; then :
13205 cat >>confdefs.h <<_ACEOF
13206 #define HAVE_COM_ERR_H 1
13207 _ACEOF
13211 done
13221 # Solaris requires -lintl if you want strerror (which calls dgettext)
13222 # to return localized messages.
13223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dgettext in -lintl" >&5
13224 $as_echo_n "checking for dgettext in -lintl... " >&6; }
13225 if test "${ac_cv_lib_intl_dgettext+set}" = set; then :
13226 $as_echo_n "(cached) " >&6
13227 else
13228 ac_check_lib_save_LIBS=$LIBS
13229 LIBS="-lintl $LIBS"
13230 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13231 /* end confdefs.h. */
13233 /* Override any GCC internal prototype to avoid an error.
13234 Use char because int might match the return type of a GCC
13235 builtin and then its argument prototype would still apply. */
13236 #ifdef __cplusplus
13237 extern "C"
13238 #endif
13239 char dgettext ();
13241 main ()
13243 return dgettext ();
13245 return 0;
13247 _ACEOF
13248 if ac_fn_c_try_link "$LINENO"; then :
13249 ac_cv_lib_intl_dgettext=yes
13250 else
13251 ac_cv_lib_intl_dgettext=no
13253 rm -f core conftest.err conftest.$ac_objext \
13254 conftest$ac_exeext conftest.$ac_ext
13255 LIBS=$ac_check_lib_save_LIBS
13257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_dgettext" >&5
13258 $as_echo "$ac_cv_lib_intl_dgettext" >&6; }
13259 if test "x$ac_cv_lib_intl_dgettext" = x""yes; then :
13260 cat >>confdefs.h <<_ACEOF
13261 #define HAVE_LIBINTL 1
13262 _ACEOF
13264 LIBS="-lintl $LIBS"
13269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
13270 $as_echo_n "checking whether localtime caches TZ... " >&6; }
13271 if test "${emacs_cv_localtime_cache+set}" = set; then :
13272 $as_echo_n "(cached) " >&6
13273 else
13274 if test x$ac_cv_func_tzset = xyes; then
13275 if test "$cross_compiling" = yes; then :
13276 # If we have tzset, assume the worst when cross-compiling.
13277 emacs_cv_localtime_cache=yes
13278 else
13279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13280 /* end confdefs.h. */
13281 #include <time.h>
13282 extern char **environ;
13283 unset_TZ ()
13285 char **from, **to;
13286 for (to = from = environ; (*to = *from); from++)
13287 if (! (to[0][0] == 'T' && to[0][1] == 'Z' && to[0][2] == '='))
13288 to++;
13290 char TZ_GMT0[] = "TZ=GMT0";
13291 char TZ_PST8[] = "TZ=PST8";
13292 main()
13294 time_t now = time ((time_t *) 0);
13295 int hour_GMT0, hour_unset;
13296 if (putenv (TZ_GMT0) != 0)
13297 exit (1);
13298 hour_GMT0 = localtime (&now)->tm_hour;
13299 unset_TZ ();
13300 hour_unset = localtime (&now)->tm_hour;
13301 if (putenv (TZ_PST8) != 0)
13302 exit (1);
13303 if (localtime (&now)->tm_hour == hour_GMT0)
13304 exit (1);
13305 unset_TZ ();
13306 if (localtime (&now)->tm_hour != hour_unset)
13307 exit (1);
13308 exit (0);
13310 _ACEOF
13311 if ac_fn_c_try_run "$LINENO"; then :
13312 emacs_cv_localtime_cache=no
13313 else
13314 emacs_cv_localtime_cache=yes
13316 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13317 conftest.$ac_objext conftest.beam conftest.$ac_ext
13320 else
13321 # If we lack tzset, report that localtime does not cache TZ,
13322 # since we can't invalidate the cache if we don't have tzset.
13323 emacs_cv_localtime_cache=no
13326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
13327 $as_echo "$emacs_cv_localtime_cache" >&6; }
13328 if test $emacs_cv_localtime_cache = yes; then
13330 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
13334 if test "x$HAVE_TIMEVAL" = xyes; then
13335 for ac_func in gettimeofday
13336 do :
13337 ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday"
13338 if test "x$ac_cv_func_gettimeofday" = x""yes; then :
13339 cat >>confdefs.h <<_ACEOF
13340 #define HAVE_GETTIMEOFDAY 1
13341 _ACEOF
13344 done
13346 if test $ac_cv_func_gettimeofday = yes; then
13347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday can accept two arguments" >&5
13348 $as_echo_n "checking whether gettimeofday can accept two arguments... " >&6; }
13349 if test "${emacs_cv_gettimeofday_two_arguments+set}" = set; then :
13350 $as_echo_n "(cached) " >&6
13351 else
13352 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13353 /* end confdefs.h. */
13355 #ifdef TIME_WITH_SYS_TIME
13356 #include <sys/time.h>
13357 #include <time.h>
13358 #else
13359 #ifdef HAVE_SYS_TIME_H
13360 #include <sys/time.h>
13361 #else
13362 #include <time.h>
13363 #endif
13364 #endif
13366 main ()
13368 struct timeval time;
13369 gettimeofday (&time, 0);
13371 return 0;
13373 _ACEOF
13374 if ac_fn_c_try_compile "$LINENO"; then :
13375 emacs_cv_gettimeofday_two_arguments=yes
13376 else
13377 emacs_cv_gettimeofday_two_arguments=no
13379 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_gettimeofday_two_arguments" >&5
13382 $as_echo "$emacs_cv_gettimeofday_two_arguments" >&6; }
13383 if test $emacs_cv_gettimeofday_two_arguments = no; then
13385 $as_echo "#define GETTIMEOFDAY_ONE_ARGUMENT 1" >>confdefs.h
13391 ok_so_far=yes
13392 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
13393 if test "x$ac_cv_func_socket" = x""yes; then :
13395 else
13396 ok_so_far=no
13399 if test $ok_so_far = yes; then
13400 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
13401 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
13403 else
13404 ok_so_far=no
13409 if test $ok_so_far = yes; then
13410 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
13411 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
13413 else
13414 ok_so_far=no
13419 if test $ok_so_far = yes; then
13421 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
13425 for ac_header in sys/ioctl.h
13426 do :
13427 ac_fn_c_check_header_mongrel "$LINENO" "sys/ioctl.h" "ac_cv_header_sys_ioctl_h" "$ac_includes_default"
13428 if test "x$ac_cv_header_sys_ioctl_h" = x""yes; then :
13429 cat >>confdefs.h <<_ACEOF
13430 #define HAVE_SYS_IOCTL_H 1
13431 _ACEOF
13435 done
13438 if test -f /usr/lpp/X11/bin/smt.exp; then
13440 $as_echo "#define HAVE_AIX_SMT_EXP 1" >>confdefs.h
13444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports dynamic ptys" >&5
13445 $as_echo_n "checking whether system supports dynamic ptys... " >&6; }
13446 if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
13447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13448 $as_echo "yes" >&6; }
13450 $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h
13452 else
13453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13454 $as_echo "no" >&6; }
13457 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
13458 if test "x$ac_cv_type_pid_t" = x""yes; then :
13460 else
13462 cat >>confdefs.h <<_ACEOF
13463 #define pid_t int
13464 _ACEOF
13468 for ac_header in vfork.h
13469 do :
13470 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
13471 if test "x$ac_cv_header_vfork_h" = x""yes; then :
13472 cat >>confdefs.h <<_ACEOF
13473 #define HAVE_VFORK_H 1
13474 _ACEOF
13478 done
13480 for ac_func in fork vfork
13481 do :
13482 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13483 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13484 eval as_val=\$$as_ac_var
13485 if test "x$as_val" = x""yes; then :
13486 cat >>confdefs.h <<_ACEOF
13487 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13488 _ACEOF
13491 done
13493 if test "x$ac_cv_func_fork" = xyes; then
13494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
13495 $as_echo_n "checking for working fork... " >&6; }
13496 if test "${ac_cv_func_fork_works+set}" = set; then :
13497 $as_echo_n "(cached) " >&6
13498 else
13499 if test "$cross_compiling" = yes; then :
13500 ac_cv_func_fork_works=cross
13501 else
13502 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13503 /* end confdefs.h. */
13504 $ac_includes_default
13506 main ()
13509 /* By Ruediger Kuhlmann. */
13510 return fork () < 0;
13513 return 0;
13515 _ACEOF
13516 if ac_fn_c_try_run "$LINENO"; then :
13517 ac_cv_func_fork_works=yes
13518 else
13519 ac_cv_func_fork_works=no
13521 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13522 conftest.$ac_objext conftest.beam conftest.$ac_ext
13526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
13527 $as_echo "$ac_cv_func_fork_works" >&6; }
13529 else
13530 ac_cv_func_fork_works=$ac_cv_func_fork
13532 if test "x$ac_cv_func_fork_works" = xcross; then
13533 case $host in
13534 *-*-amigaos* | *-*-msdosdjgpp*)
13535 # Override, as these systems have only a dummy fork() stub
13536 ac_cv_func_fork_works=no
13539 ac_cv_func_fork_works=yes
13541 esac
13542 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
13543 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
13545 ac_cv_func_vfork_works=$ac_cv_func_vfork
13546 if test "x$ac_cv_func_vfork" = xyes; then
13547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
13548 $as_echo_n "checking for working vfork... " >&6; }
13549 if test "${ac_cv_func_vfork_works+set}" = set; then :
13550 $as_echo_n "(cached) " >&6
13551 else
13552 if test "$cross_compiling" = yes; then :
13553 ac_cv_func_vfork_works=cross
13554 else
13555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13556 /* end confdefs.h. */
13557 /* Thanks to Paul Eggert for this test. */
13558 $ac_includes_default
13559 #include <sys/wait.h>
13560 #ifdef HAVE_VFORK_H
13561 # include <vfork.h>
13562 #endif
13563 /* On some sparc systems, changes by the child to local and incoming
13564 argument registers are propagated back to the parent. The compiler
13565 is told about this with #include <vfork.h>, but some compilers
13566 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
13567 static variable whose address is put into a register that is
13568 clobbered by the vfork. */
13569 static void
13570 #ifdef __cplusplus
13571 sparc_address_test (int arg)
13572 # else
13573 sparc_address_test (arg) int arg;
13574 #endif
13576 static pid_t child;
13577 if (!child) {
13578 child = vfork ();
13579 if (child < 0) {
13580 perror ("vfork");
13581 _exit(2);
13583 if (!child) {
13584 arg = getpid();
13585 write(-1, "", 0);
13586 _exit (arg);
13592 main ()
13594 pid_t parent = getpid ();
13595 pid_t child;
13597 sparc_address_test (0);
13599 child = vfork ();
13601 if (child == 0) {
13602 /* Here is another test for sparc vfork register problems. This
13603 test uses lots of local variables, at least as many local
13604 variables as main has allocated so far including compiler
13605 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
13606 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
13607 reuse the register of parent for one of the local variables,
13608 since it will think that parent can't possibly be used any more
13609 in this routine. Assigning to the local variable will thus
13610 munge parent in the parent process. */
13611 pid_t
13612 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
13613 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
13614 /* Convince the compiler that p..p7 are live; otherwise, it might
13615 use the same hardware register for all 8 local variables. */
13616 if (p != p1 || p != p2 || p != p3 || p != p4
13617 || p != p5 || p != p6 || p != p7)
13618 _exit(1);
13620 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
13621 from child file descriptors. If the child closes a descriptor
13622 before it execs or exits, this munges the parent's descriptor
13623 as well. Test for this by closing stdout in the child. */
13624 _exit(close(fileno(stdout)) != 0);
13625 } else {
13626 int status;
13627 struct stat st;
13629 while (wait(&status) != child)
13631 return (
13632 /* Was there some problem with vforking? */
13633 child < 0
13635 /* Did the child fail? (This shouldn't happen.) */
13636 || status
13638 /* Did the vfork/compiler bug occur? */
13639 || parent != getpid()
13641 /* Did the file descriptor bug occur? */
13642 || fstat(fileno(stdout), &st) != 0
13646 _ACEOF
13647 if ac_fn_c_try_run "$LINENO"; then :
13648 ac_cv_func_vfork_works=yes
13649 else
13650 ac_cv_func_vfork_works=no
13652 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13653 conftest.$ac_objext conftest.beam conftest.$ac_ext
13657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
13658 $as_echo "$ac_cv_func_vfork_works" >&6; }
13661 if test "x$ac_cv_func_fork_works" = xcross; then
13662 ac_cv_func_vfork_works=$ac_cv_func_vfork
13663 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
13664 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
13667 if test "x$ac_cv_func_vfork_works" = xyes; then
13669 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
13671 else
13673 $as_echo "#define vfork fork" >>confdefs.h
13676 if test "x$ac_cv_func_fork_works" = xyes; then
13678 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
13683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
13684 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
13685 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
13686 $as_echo_n "(cached) " >&6
13687 else
13688 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13689 /* end confdefs.h. */
13690 #include <langinfo.h>
13692 main ()
13694 char* cs = nl_langinfo(CODESET);
13696 return 0;
13698 _ACEOF
13699 if ac_fn_c_try_link "$LINENO"; then :
13700 emacs_cv_langinfo_codeset=yes
13701 else
13702 emacs_cv_langinfo_codeset=no
13704 rm -f core conftest.err conftest.$ac_objext \
13705 conftest$ac_exeext conftest.$ac_ext
13708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
13709 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
13710 if test $emacs_cv_langinfo_codeset = yes; then
13712 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
13716 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
13717 if test "x$ac_cv_type_size_t" = x""yes; then :
13719 cat >>confdefs.h <<_ACEOF
13720 #define HAVE_SIZE_T 1
13721 _ACEOF
13727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
13728 $as_echo_n "checking for mbstate_t... " >&6; }
13729 if test "${ac_cv_type_mbstate_t+set}" = set; then :
13730 $as_echo_n "(cached) " >&6
13731 else
13732 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13733 /* end confdefs.h. */
13734 $ac_includes_default
13735 # include <wchar.h>
13737 main ()
13739 mbstate_t x; return sizeof x;
13741 return 0;
13743 _ACEOF
13744 if ac_fn_c_try_compile "$LINENO"; then :
13745 ac_cv_type_mbstate_t=yes
13746 else
13747 ac_cv_type_mbstate_t=no
13749 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
13752 $as_echo "$ac_cv_type_mbstate_t" >&6; }
13753 if test $ac_cv_type_mbstate_t = yes; then
13755 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
13757 else
13759 $as_echo "#define mbstate_t int" >>confdefs.h
13763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restrict keyword" >&5
13764 $as_echo_n "checking for C restrict keyword... " >&6; }
13765 if test "${emacs_cv_c_restrict+set}" = set; then :
13766 $as_echo_n "(cached) " >&6
13767 else
13768 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13769 /* end confdefs.h. */
13770 void fred (int *restrict x);
13772 main ()
13776 return 0;
13778 _ACEOF
13779 if ac_fn_c_try_compile "$LINENO"; then :
13780 emacs_cv_c_restrict=yes
13781 else
13782 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13783 /* end confdefs.h. */
13784 void fred (int *__restrict x);
13786 main ()
13790 return 0;
13792 _ACEOF
13793 if ac_fn_c_try_compile "$LINENO"; then :
13794 emacs_cv_c_restrict=__restrict
13795 else
13796 emacs_cv_c_restrict=no
13798 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13800 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict" >&5
13803 $as_echo "$emacs_cv_c_restrict" >&6; }
13804 case "$emacs_cv_c_restrict" in
13805 yes) emacs_restrict=restrict;;
13806 no) emacs_restrict="";;
13807 *) emacs_restrict="$emacs_cv_c_restrict";;
13808 esac
13809 if test "$emacs_restrict" != __restrict; then
13811 cat >>confdefs.h <<_ACEOF
13812 #define __restrict $emacs_restrict
13813 _ACEOF
13817 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
13818 $as_echo_n "checking for C restricted array declarations... " >&6; }
13819 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
13820 $as_echo_n "(cached) " >&6
13821 else
13822 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13823 /* end confdefs.h. */
13824 void fred (int x[__restrict]);
13826 main ()
13830 return 0;
13832 _ACEOF
13833 if ac_fn_c_try_compile "$LINENO"; then :
13834 emacs_cv_c_restrict_arr=yes
13835 else
13836 emacs_cv_c_restrict_arr=no
13838 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
13841 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
13842 if test "$emacs_cv_c_restrict_arr" = yes; then
13844 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
13850 # Set up the CFLAGS for real compilation, so we can substitute it.
13851 CFLAGS="$REAL_CFLAGS"
13852 CPPFLAGS="$REAL_CPPFLAGS"
13854 ## Hack to detect a buggy GCC version.
13855 if test "x$GCC" = xyes \
13856 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
13857 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
13858 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
13859 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
13862 #### Find out which version of Emacs this is.
13863 version=`grep 'const char emacs_version' ${srcdir}/src/emacs.c \
13864 | sed -e 's/^[^"]*"\([^"]*\)".*$/\1/'`
13865 if test x"${version}" = x; then
13866 as_fn_error "can't find current emacs version in \`${srcdir}/src/emacs.c'." "$LINENO" 5
13868 if test x"${version}" != x"$PACKAGE_VERSION"; then
13869 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: version mismatch between \`${srcdir}/configure.in' and \`${srcdir}/src/emacs.c'." >&5
13870 $as_echo "$as_me: WARNING: version mismatch between \`${srcdir}/configure.in' and \`${srcdir}/src/emacs.c'." >&2;}
13873 ### Specify what sort of things we'll be editing into Makefile and config.h.
13874 ### Use configuration here uncanonicalized to avoid exceeding size limits.
13877 ## Unused?
13898 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
13899 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
13900 ## end of LIBX_BASE, but nothing ever set it.
13905 ## Used in lwlib/Makefile.in.
13918 cat >>confdefs.h <<_ACEOF
13919 #define EMACS_CONFIGURATION "${canonical}"
13920 _ACEOF
13923 cat >>confdefs.h <<_ACEOF
13924 #define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
13925 _ACEOF
13928 cat >>confdefs.h <<_ACEOF
13929 #define config_machfile "${machfile}"
13930 _ACEOF
13933 cat >>confdefs.h <<_ACEOF
13934 #define config_opsysfile "${opsysfile}"
13935 _ACEOF
13938 XMENU_OBJ=
13939 XOBJ=
13940 FONT_OBJ=
13941 if test "${HAVE_X_WINDOWS}" = "yes" ; then
13943 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
13945 XMENU_OBJ=xmenu.o
13946 XOBJ="xterm.o xfns.o xselect.o xrdb.o fontset.o xsmfns.o fringe.o image.o xsettings.o xgselect.o"
13947 FONT_OBJ=xfont.o
13948 if test "$HAVE_XFT" = "yes"; then
13949 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
13950 elif test "$HAVE_FREETYPE" = "yes"; then
13951 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
13959 WIDGET_OBJ=
13960 MOTIF_LIBW=
13961 if test "${USE_X_TOOLKIT}" != "none" ; then
13962 WIDGET_OBJ=widget.o
13964 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
13966 if test "${USE_X_TOOLKIT}" = "LUCID"; then
13968 $as_echo "#define USE_LUCID 1" >>confdefs.h
13970 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
13972 $as_echo "#define USE_MOTIF 1" >>confdefs.h
13974 MOTIF_LIBW=-lXm
13975 case "$opsys" in
13976 gnu-linux)
13977 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
13978 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
13981 unixware)
13982 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
13983 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
13984 MOTIF_LIBW="MOTIF_LIBW -lXimp"
13987 aix4-2)
13988 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
13989 MOTIF_LIBW="$MOTIF_LIBW -li18n"
13991 esac
13992 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
13997 TOOLKIT_LIBW=
13998 case "$USE_X_TOOLKIT" in
13999 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
14000 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
14001 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
14002 esac
14005 if test "$USE_X_TOOLKIT" = "none"; then
14006 LIBXT_OTHER="\$(LIBXSM)"
14007 OLDXMENU_TARGET="really-oldXMenu"
14008 else
14009 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
14010 OLDXMENU_TARGET="really-lwlib"
14014 ## The X Menu stuff is present in the X10 distribution, but missing
14015 ## from X11. If we have X10, just use the installed library;
14016 ## otherwise, use our own copy.
14017 if test "${HAVE_X11}" = "yes" ; then
14019 $as_echo "#define HAVE_X11 1" >>confdefs.h
14022 if test "$USE_X_TOOLKIT" = "none"; then
14023 OLDXMENU="\${oldXMenudir}libXMenu11.a"
14024 else
14025 OLDXMENU="\${lwlibdir}liblw.a"
14027 LIBXMENU="\$(OLDXMENU)"
14028 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
14029 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
14030 else
14031 ## For a syntactically valid Makefile; not actually used for anything.
14032 ## See comments in src/Makefile.in.
14033 OLDXMENU=nothing
14034 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
14035 if test "${HAVE_X_WINDOWS}" = "yes"; then
14036 LIBXMENU="-lXMenu"
14037 else
14038 LIBXMENU=
14040 LIBX_OTHER=
14041 OLDXMENU_DEPS=
14044 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
14045 OLDXMENU_TARGET=
14046 OLDXMENU=nothing
14047 LIBXMENU=
14048 OLDXMENU_DEPS=
14057 if test "${HAVE_MENUS}" = "yes" ; then
14059 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
14063 if test "${GNU_MALLOC}" = "yes" ; then
14065 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
14069 RALLOC_OBJ=
14070 if test "${REL_ALLOC}" = "yes" ; then
14072 $as_echo "#define REL_ALLOC 1" >>confdefs.h
14075 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
14079 if test "$opsys" = "cygwin"; then
14080 CYGWIN_OBJ="sheap.o"
14081 ## Cygwin differs because of its unexec().
14082 PRE_ALLOC_OBJ=
14083 POST_ALLOC_OBJ=lastfile.o
14084 else
14085 CYGWIN_OBJ=
14086 PRE_ALLOC_OBJ=lastfile.o
14087 POST_ALLOC_OBJ=
14094 case "$opsys" in
14095 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
14097 darwin)
14098 ## The -headerpad option tells ld (see man page) to leave room at the
14099 ## end of the header for adding load commands. Needed for dumping.
14100 ## 0x690 is the total size of 30 segment load commands (at 56
14101 ## each); under Cocoa 31 commands are required.
14102 if test "$HAVE_NS" = "yes"; then
14103 libs_nsgui="-framework AppKit"
14104 headerpad_extra=6C8
14105 else
14106 libs_nsgui=
14107 headerpad_extra=690
14109 LD_SWITCH_SYSTEM_TEMACS="-prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
14111 ## This is here because src/Makefile.in did some extra fiddling around
14112 ## with LD_SWITCH_SYSTEM. The cpp logic was:
14113 ## #ifndef LD_SWITCH_SYSTEM
14114 ## #if !defined (__GNUC__) && ((defined (BSD_SYSTEM) && !defined (COFF)))
14115 ## Since all the *bsds define LD_SWITCH_SYSTEM, this simplifies to:
14116 ## not using gcc, darwin system not on an alpha (ie darwin, since
14117 ## darwin + alpha does not occur).
14118 ## Because this was done in src/Makefile.in, the resulting part of
14119 ## LD_SWITCH_SYSTEM was not used in configure (ie, in ac_link).
14120 ## It therefore seems cleaner to put this in LD_SWITCH_SYSTEM_TEMACS,
14121 ## rather than LD_SWITCH_SYSTEM.
14122 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
14123 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
14126 ## LD_SWITCH_X_SITE_AUX is a -R option saying where to find X at run-time.
14127 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at
14128 ## the point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_AUX
14129 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
14130 ## had different values in configure (in ac_link) and src/Makefile.in.
14131 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
14132 gnu-linux) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_AUX)" ;;
14134 *) LD_SWITCH_SYSTEM_TEMACS= ;;
14135 esac
14137 if test "$NS_IMPL_GNUSTEP" = "yes"; then
14138 LD_SWITCH_SYSTEM_TEMACS="${LD_SWITCH_SYSTEM_TEMACS} -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES} -lgnustep-gui -lgnustep-base -lobjc -lpthread"
14144 LINKER=
14145 ORDINARY_LINK=
14146 case "$opsys" in
14147 ## gnu: GNU needs its own crt0.
14148 aix4-2|darwin|gnu|usg5-4|irix6-5|sol2*|unixware) ORDINARY_LINK=yes ;;
14150 cygwin) LINKER="\$(CC)" ;;
14152 ## On post 1.3 releases of NetBSD, gcc -nostdlib also clears the
14153 ## library search parth, i.e. it won't search /usr/lib for libc and
14154 ## friends. Using -nostartfiles instead avoids this problem, and
14155 ## will also work on earlier NetBSD releases.
14156 netbsd|openbsd) LINKER="\$(CC) -nostartfiles" ;;
14158 ## macpcc: NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp> says
14159 ## MkLinux/LinuxPPC needs this.
14160 ## ibms390x only supports opsys = gnu-linux so it can be added here.
14161 gnu-*)
14162 case "$machine" in
14163 macppc|ibms390x) LINKER="\$(CC) -nostdlib" ;;
14164 esac
14166 esac
14169 PRE_EDIT_LDFLAGS=
14170 POST_EDIT_LDFLAGS=
14171 if test "x$ORDINARY_LINK" = "xyes"; then
14173 LINKER="\$(CC)"
14175 $as_echo "#define ORDINARY_LINK 1" >>confdefs.h
14178 ## The system files defining neither ORDINARY_LINK nor LINKER are:
14179 ## (bsd-common), freebsd, gnu-* not on macppc|ibms390x, hpux*.
14180 elif test "x$GCC" = "xyes" && test "x$LINKER" = "x"; then
14182 ## Versions of GCC >= 2.0 put their library, libgcc.a, in obscure
14183 ## places that are difficult to figure out at make time. Fortunately,
14184 ## these same versions allow you to pass arbitrary flags on to the
14185 ## linker, so there is no reason not to use it as a linker.
14187 ## Well, it is not quite perfect. The "-nostdlib" keeps GCC from
14188 ## searching for libraries in its internal directories, so we have to
14189 ## ask GCC explicitly where to find libgcc.a (LIB_GCC below).
14190 LINKER="\$(CC) -nostdlib"
14191 ## GCC passes any argument prefixed with -Xlinker directly to the linker.
14192 ## See prefix-args.c for an explanation of why we do not do this with the
14193 ## shell''s ``for'' construct. Note that sane people do not have '.' in
14194 ## their paths, so we must use ./prefix-args.
14195 ## TODO either make prefix-args check ORDINARY_LINK internally,
14196 ## or remove it altogether (bug#6184), removing the need for this hack.
14197 PRE_EDIT_LDFLAGS='`./prefix-args -Xlinker'
14198 POST_EDIT_LDFLAGS='`'
14203 test "x$LINKER" = "x" && LINKER=ld
14204 ## FIXME? What setting of EDIT_LDFLAGS should this have?
14205 test "$NS_IMPL_GNUSTEP" = "yes" && LINKER="\$(CC) -rdynamic"
14210 ## FIXME? The logic here is not precisely the same as that above.
14211 ## There is no check here for a pre-defined LINKER.
14212 ## Should we only be setting LIB_GCC if LD ~ -nostdlib?
14213 LIB_GCC=
14214 if test "x$GCC" = "xyes" && test "x$ORDINARY_LINK" != "xyes"; then
14216 case "$opsys" in
14217 ## cygwin: don't link against static libgcc.
14218 cygwin|freebsd|netbsd|openbsd) LIB_GCC= ;;
14220 gnu-*)
14221 ## armin76@gentoo.org reported that the lgcc_s flag is necessary to
14222 ## build on ARM EABI under GNU/Linux. (Bug#5518)
14223 ## Note that m/arm.h never bothered to undefine LIB_GCC first.
14224 if test "$machine" = "arm"; then
14225 LIB_GCC="-lgcc_s"
14226 else
14227 ## FIXME? s/gnu-linux.h used to define LIB_GCC as below, then
14228 ## immediately undefine it again and redefine it to empty.
14229 ## Was the C_SWITCH_X_SITE part really necessary?
14230 ## LIB_GCC=`$CC $C_SWITCH_X_SITE -print-libgcc-file-name`
14231 LIB_GCC=
14235 ## Ask GCC where to find libgcc.a.
14236 *) LIB_GCC=`$CC -print-libgcc-file-name 2> /dev/null` ;;
14237 esac
14241 TOOLTIP_SUPPORT=
14242 WINDOW_SUPPORT=
14243 ## If we're using X11/GNUstep, define some consequences.
14244 if test "$HAVE_X_WINDOWS" = "yes" || test "$HAVE_NS" = "yes"; then
14246 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
14249 $as_echo "#define HAVE_MOUSE 1" >>confdefs.h
14251 MOUSE_SUPPORT="\$(REAL_MOUSE_SUPPORT)"
14252 TOOLTIP_SUPPORT="\${lispsource}mouse.elc"
14254 WINDOW_SUPPORT="\$(BASE_WINDOW_SUPPORT)"
14255 test "$HAVE_X_WINDOWS" = "yes" && \
14256 WINDOW_SUPPORT="$WINDOW_SUPPORT \$(X_WINDOW_SUPPORT)"
14266 #### Report on what we decided to do.
14267 #### Report GTK as a toolkit, even if it doesn't use Xt.
14268 #### It makes printing result more understandable as using GTK sets
14269 #### toolkit_scroll_bars to yes by default.
14270 if test "${HAVE_GTK}" = "yes"; then
14271 USE_X_TOOLKIT=GTK
14274 echo "
14275 Configured for \`${canonical}'.
14277 Where should the build process find the source code? ${srcdir}
14278 What operating system and machine description files should Emacs use?
14279 \`${opsysfile}' and \`${machfile}'
14280 What compiler should emacs be built with? ${CC} ${CFLAGS}
14281 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
14282 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
14283 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
14284 What window system should Emacs use? ${window_system}
14285 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
14287 if test -n "${x_includes}"; then
14288 echo " Where do we find X Windows header files? ${x_includes}"
14289 else
14290 echo " Where do we find X Windows header files? Standard dirs"
14292 if test -n "${x_libraries}"; then
14293 echo " Where do we find X Windows libraries? ${x_libraries}"
14294 else
14295 echo " Where do we find X Windows libraries? Standard dirs"
14298 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
14299 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
14300 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
14301 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
14302 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
14303 echo " Does Emacs use -lpng? ${HAVE_PNG}"
14304 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
14305 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
14306 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
14307 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
14308 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
14310 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
14311 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
14312 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
14313 echo " Does Emacs use -lxft? ${HAVE_XFT}"
14315 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
14316 echo
14318 if test $USE_XASSERTS = yes; then
14319 echo " Compiling with asserts turned on."
14320 CPPFLAGS="$CPPFLAGS -DXASSERTS=1"
14323 echo
14325 if test "$HAVE_NS" = "yes"; then
14326 echo
14327 echo "You must run \"make install\" in order to test the built application.
14328 The installed application will go to nextstep/Emacs.app and can be
14329 run or moved from there."
14330 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
14331 echo "The application will be fully self-contained."
14332 else
14333 echo "The lisp resources for the application will be installed under ${prefix}.
14334 You may need to run \"make install\" with sudo. The application will fail
14335 to run if these resources are not installed."
14337 echo
14340 if test "$HAVE_DBUS" = yes && test "${opsys}" != "gnu-linux"; then
14341 echo "D-Bus integration has been tested for GNU/Linux only."
14342 echo
14346 # Remove any trailing slashes in these variables.
14347 test "${prefix}" != NONE &&
14348 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
14349 test "${exec_prefix}" != NONE &&
14350 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
14352 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"
14354 ac_config_commands="$ac_config_commands default"
14356 cat >confcache <<\_ACEOF
14357 # This file is a shell script that caches the results of configure
14358 # tests run on this system so they can be shared between configure
14359 # scripts and configure runs, see configure's option --config-cache.
14360 # It is not useful on other systems. If it contains results you don't
14361 # want to keep, you may remove or edit it.
14363 # config.status only pays attention to the cache file if you give it
14364 # the --recheck option to rerun configure.
14366 # `ac_cv_env_foo' variables (set or unset) will be overridden when
14367 # loading this file, other *unset* `ac_cv_foo' will be assigned the
14368 # following values.
14370 _ACEOF
14372 # The following way of writing the cache mishandles newlines in values,
14373 # but we know of no workaround that is simple, portable, and efficient.
14374 # So, we kill variables containing newlines.
14375 # Ultrix sh set writes to stderr and can't be redirected directly,
14376 # and sets the high bit in the cache file unless we assign to the vars.
14378 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
14379 eval ac_val=\$$ac_var
14380 case $ac_val in #(
14381 *${as_nl}*)
14382 case $ac_var in #(
14383 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
14384 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
14385 esac
14386 case $ac_var in #(
14387 _ | IFS | as_nl) ;; #(
14388 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
14389 *) { eval $ac_var=; unset $ac_var;} ;;
14390 esac ;;
14391 esac
14392 done
14394 (set) 2>&1 |
14395 case $as_nl`(ac_space=' '; set) 2>&1` in #(
14396 *${as_nl}ac_space=\ *)
14397 # `set' does not quote correctly, so add quotes: double-quote
14398 # substitution turns \\\\ into \\, and sed turns \\ into \.
14399 sed -n \
14400 "s/'/'\\\\''/g;
14401 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
14402 ;; #(
14404 # `set' quotes correctly as required by POSIX, so do not add quotes.
14405 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
14407 esac |
14408 sort
14410 sed '
14411 /^ac_cv_env_/b end
14412 t clear
14413 :clear
14414 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
14415 t end
14416 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
14417 :end' >>confcache
14418 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
14419 if test -w "$cache_file"; then
14420 test "x$cache_file" != "x/dev/null" &&
14421 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
14422 $as_echo "$as_me: updating cache $cache_file" >&6;}
14423 cat confcache >$cache_file
14424 else
14425 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
14426 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
14429 rm -f confcache
14431 test "x$prefix" = xNONE && prefix=$ac_default_prefix
14432 # Let make expand exec_prefix.
14433 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
14435 DEFS=-DHAVE_CONFIG_H
14437 ac_libobjs=
14438 ac_ltlibobjs=
14439 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
14440 # 1. Remove the extension, and $U if already installed.
14441 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
14442 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
14443 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
14444 # will be set to the directory where LIBOBJS objects are built.
14445 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
14446 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
14447 done
14448 LIBOBJS=$ac_libobjs
14450 LTLIBOBJS=$ac_ltlibobjs
14454 : ${CONFIG_STATUS=./config.status}
14455 ac_write_fail=0
14456 ac_clean_files_save=$ac_clean_files
14457 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
14458 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
14459 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
14460 as_write_fail=0
14461 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
14462 #! $SHELL
14463 # Generated by $as_me.
14464 # Run this file to recreate the current configuration.
14465 # Compiler output produced by configure, useful for debugging
14466 # configure, is in config.log if it exists.
14468 debug=false
14469 ac_cs_recheck=false
14470 ac_cs_silent=false
14472 SHELL=\${CONFIG_SHELL-$SHELL}
14473 export SHELL
14474 _ASEOF
14475 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
14476 ## -------------------- ##
14477 ## M4sh Initialization. ##
14478 ## -------------------- ##
14480 # Be more Bourne compatible
14481 DUALCASE=1; export DUALCASE # for MKS sh
14482 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
14483 emulate sh
14484 NULLCMD=:
14485 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
14486 # is contrary to our usage. Disable this feature.
14487 alias -g '${1+"$@"}'='"$@"'
14488 setopt NO_GLOB_SUBST
14489 else
14490 case `(set -o) 2>/dev/null` in #(
14491 *posix*) :
14492 set -o posix ;; #(
14493 *) :
14495 esac
14499 as_nl='
14501 export as_nl
14502 # Printing a long string crashes Solaris 7 /usr/bin/printf.
14503 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
14504 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
14505 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
14506 # Prefer a ksh shell builtin over an external printf program on Solaris,
14507 # but without wasting forks for bash or zsh.
14508 if test -z "$BASH_VERSION$ZSH_VERSION" \
14509 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
14510 as_echo='print -r --'
14511 as_echo_n='print -rn --'
14512 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
14513 as_echo='printf %s\n'
14514 as_echo_n='printf %s'
14515 else
14516 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
14517 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
14518 as_echo_n='/usr/ucb/echo -n'
14519 else
14520 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
14521 as_echo_n_body='eval
14522 arg=$1;
14523 case $arg in #(
14524 *"$as_nl"*)
14525 expr "X$arg" : "X\\(.*\\)$as_nl";
14526 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
14527 esac;
14528 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
14530 export as_echo_n_body
14531 as_echo_n='sh -c $as_echo_n_body as_echo'
14533 export as_echo_body
14534 as_echo='sh -c $as_echo_body as_echo'
14537 # The user is always right.
14538 if test "${PATH_SEPARATOR+set}" != set; then
14539 PATH_SEPARATOR=:
14540 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
14541 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
14542 PATH_SEPARATOR=';'
14547 # IFS
14548 # We need space, tab and new line, in precisely that order. Quoting is
14549 # there to prevent editors from complaining about space-tab.
14550 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
14551 # splitting by setting IFS to empty value.)
14552 IFS=" "" $as_nl"
14554 # Find who we are. Look in the path if we contain no directory separator.
14555 case $0 in #((
14556 *[\\/]* ) as_myself=$0 ;;
14557 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14558 for as_dir in $PATH
14560 IFS=$as_save_IFS
14561 test -z "$as_dir" && as_dir=.
14562 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
14563 done
14564 IFS=$as_save_IFS
14567 esac
14568 # We did not find ourselves, most probably we were run as `sh COMMAND'
14569 # in which case we are not to be found in the path.
14570 if test "x$as_myself" = x; then
14571 as_myself=$0
14573 if test ! -f "$as_myself"; then
14574 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
14575 exit 1
14578 # Unset variables that we do not need and which cause bugs (e.g. in
14579 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
14580 # suppresses any "Segmentation fault" message there. '((' could
14581 # trigger a bug in pdksh 5.2.14.
14582 for as_var in BASH_ENV ENV MAIL MAILPATH
14583 do eval test x\${$as_var+set} = xset \
14584 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
14585 done
14586 PS1='$ '
14587 PS2='> '
14588 PS4='+ '
14590 # NLS nuisances.
14591 LC_ALL=C
14592 export LC_ALL
14593 LANGUAGE=C
14594 export LANGUAGE
14596 # CDPATH.
14597 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
14600 # as_fn_error ERROR [LINENO LOG_FD]
14601 # ---------------------------------
14602 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
14603 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
14604 # script with status $?, using 1 if that was 0.
14605 as_fn_error ()
14607 as_status=$?; test $as_status -eq 0 && as_status=1
14608 if test "$3"; then
14609 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
14610 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
14612 $as_echo "$as_me: error: $1" >&2
14613 as_fn_exit $as_status
14614 } # as_fn_error
14617 # as_fn_set_status STATUS
14618 # -----------------------
14619 # Set $? to STATUS, without forking.
14620 as_fn_set_status ()
14622 return $1
14623 } # as_fn_set_status
14625 # as_fn_exit STATUS
14626 # -----------------
14627 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
14628 as_fn_exit ()
14630 set +e
14631 as_fn_set_status $1
14632 exit $1
14633 } # as_fn_exit
14635 # as_fn_unset VAR
14636 # ---------------
14637 # Portably unset VAR.
14638 as_fn_unset ()
14640 { eval $1=; unset $1;}
14642 as_unset=as_fn_unset
14643 # as_fn_append VAR VALUE
14644 # ----------------------
14645 # Append the text in VALUE to the end of the definition contained in VAR. Take
14646 # advantage of any shell optimizations that allow amortized linear growth over
14647 # repeated appends, instead of the typical quadratic growth present in naive
14648 # implementations.
14649 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
14650 eval 'as_fn_append ()
14652 eval $1+=\$2
14654 else
14655 as_fn_append ()
14657 eval $1=\$$1\$2
14659 fi # as_fn_append
14661 # as_fn_arith ARG...
14662 # ------------------
14663 # Perform arithmetic evaluation on the ARGs, and store the result in the
14664 # global $as_val. Take advantage of shells that can avoid forks. The arguments
14665 # must be portable across $(()) and expr.
14666 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
14667 eval 'as_fn_arith ()
14669 as_val=$(( $* ))
14671 else
14672 as_fn_arith ()
14674 as_val=`expr "$@" || test $? -eq 1`
14676 fi # as_fn_arith
14679 if expr a : '\(a\)' >/dev/null 2>&1 &&
14680 test "X`expr 00001 : '.*\(...\)'`" = X001; then
14681 as_expr=expr
14682 else
14683 as_expr=false
14686 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
14687 as_basename=basename
14688 else
14689 as_basename=false
14692 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
14693 as_dirname=dirname
14694 else
14695 as_dirname=false
14698 as_me=`$as_basename -- "$0" ||
14699 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
14700 X"$0" : 'X\(//\)$' \| \
14701 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
14702 $as_echo X/"$0" |
14703 sed '/^.*\/\([^/][^/]*\)\/*$/{
14704 s//\1/
14707 /^X\/\(\/\/\)$/{
14708 s//\1/
14711 /^X\/\(\/\).*/{
14712 s//\1/
14715 s/.*/./; q'`
14717 # Avoid depending upon Character Ranges.
14718 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
14719 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
14720 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
14721 as_cr_digits='0123456789'
14722 as_cr_alnum=$as_cr_Letters$as_cr_digits
14724 ECHO_C= ECHO_N= ECHO_T=
14725 case `echo -n x` in #(((((
14726 -n*)
14727 case `echo 'xy\c'` in
14728 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
14729 xy) ECHO_C='\c';;
14730 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
14731 ECHO_T=' ';;
14732 esac;;
14734 ECHO_N='-n';;
14735 esac
14737 rm -f conf$$ conf$$.exe conf$$.file
14738 if test -d conf$$.dir; then
14739 rm -f conf$$.dir/conf$$.file
14740 else
14741 rm -f conf$$.dir
14742 mkdir conf$$.dir 2>/dev/null
14744 if (echo >conf$$.file) 2>/dev/null; then
14745 if ln -s conf$$.file conf$$ 2>/dev/null; then
14746 as_ln_s='ln -s'
14747 # ... but there are two gotchas:
14748 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
14749 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
14750 # In both cases, we have to default to `cp -p'.
14751 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
14752 as_ln_s='cp -p'
14753 elif ln conf$$.file conf$$ 2>/dev/null; then
14754 as_ln_s=ln
14755 else
14756 as_ln_s='cp -p'
14758 else
14759 as_ln_s='cp -p'
14761 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
14762 rmdir conf$$.dir 2>/dev/null
14765 # as_fn_mkdir_p
14766 # -------------
14767 # Create "$as_dir" as a directory, including parents if necessary.
14768 as_fn_mkdir_p ()
14771 case $as_dir in #(
14772 -*) as_dir=./$as_dir;;
14773 esac
14774 test -d "$as_dir" || eval $as_mkdir_p || {
14775 as_dirs=
14776 while :; do
14777 case $as_dir in #(
14778 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
14779 *) as_qdir=$as_dir;;
14780 esac
14781 as_dirs="'$as_qdir' $as_dirs"
14782 as_dir=`$as_dirname -- "$as_dir" ||
14783 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
14784 X"$as_dir" : 'X\(//\)[^/]' \| \
14785 X"$as_dir" : 'X\(//\)$' \| \
14786 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
14787 $as_echo X"$as_dir" |
14788 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
14789 s//\1/
14792 /^X\(\/\/\)[^/].*/{
14793 s//\1/
14796 /^X\(\/\/\)$/{
14797 s//\1/
14800 /^X\(\/\).*/{
14801 s//\1/
14804 s/.*/./; q'`
14805 test -d "$as_dir" && break
14806 done
14807 test -z "$as_dirs" || eval "mkdir $as_dirs"
14808 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
14811 } # as_fn_mkdir_p
14812 if mkdir -p . 2>/dev/null; then
14813 as_mkdir_p='mkdir -p "$as_dir"'
14814 else
14815 test -d ./-p && rmdir ./-p
14816 as_mkdir_p=false
14819 if test -x / >/dev/null 2>&1; then
14820 as_test_x='test -x'
14821 else
14822 if ls -dL / >/dev/null 2>&1; then
14823 as_ls_L_option=L
14824 else
14825 as_ls_L_option=
14827 as_test_x='
14828 eval sh -c '\''
14829 if test -d "$1"; then
14830 test -d "$1/.";
14831 else
14832 case $1 in #(
14833 -*)set "./$1";;
14834 esac;
14835 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
14836 ???[sx]*):;;*)false;;esac;fi
14837 '\'' sh
14840 as_executable_p=$as_test_x
14842 # Sed expression to map a string onto a valid CPP name.
14843 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
14845 # Sed expression to map a string onto a valid variable name.
14846 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
14849 exec 6>&1
14850 ## ----------------------------------- ##
14851 ## Main body of $CONFIG_STATUS script. ##
14852 ## ----------------------------------- ##
14853 _ASEOF
14854 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
14856 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
14857 # Save the log message, to keep $0 and so on meaningful, and to
14858 # report actual input values of CONFIG_FILES etc. instead of their
14859 # values after options handling.
14860 ac_log="
14861 This file was extended by emacs $as_me 24.0.50, which was
14862 generated by GNU Autoconf 2.65. Invocation command line was
14864 CONFIG_FILES = $CONFIG_FILES
14865 CONFIG_HEADERS = $CONFIG_HEADERS
14866 CONFIG_LINKS = $CONFIG_LINKS
14867 CONFIG_COMMANDS = $CONFIG_COMMANDS
14868 $ $0 $@
14870 on `(hostname || uname -n) 2>/dev/null | sed 1q`
14873 _ACEOF
14875 case $ac_config_files in *"
14876 "*) set x $ac_config_files; shift; ac_config_files=$*;;
14877 esac
14879 case $ac_config_headers in *"
14880 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
14881 esac
14884 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
14885 # Files that config.status was made for.
14886 config_files="$ac_config_files"
14887 config_headers="$ac_config_headers"
14888 config_commands="$ac_config_commands"
14890 _ACEOF
14892 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
14893 ac_cs_usage="\
14894 \`$as_me' instantiates files and other configuration actions
14895 from templates according to the current configuration. Unless the files
14896 and actions are specified as TAGs, all are instantiated by default.
14898 Usage: $0 [OPTION]... [TAG]...
14900 -h, --help print this help, then exit
14901 -V, --version print version number and configuration settings, then exit
14902 --config print configuration, then exit
14903 -q, --quiet, --silent
14904 do not print progress messages
14905 -d, --debug don't remove temporary files
14906 --recheck update $as_me by reconfiguring in the same conditions
14907 --file=FILE[:TEMPLATE]
14908 instantiate the configuration file FILE
14909 --header=FILE[:TEMPLATE]
14910 instantiate the configuration header FILE
14912 Configuration files:
14913 $config_files
14915 Configuration headers:
14916 $config_headers
14918 Configuration commands:
14919 $config_commands
14921 Report bugs to the package provider."
14923 _ACEOF
14924 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
14925 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
14926 ac_cs_version="\\
14927 emacs config.status 24.0.50
14928 configured by $0, generated by GNU Autoconf 2.65,
14929 with options \\"\$ac_cs_config\\"
14931 Copyright (C) 2009 Free Software Foundation, Inc.
14932 This config.status script is free software; the Free Software Foundation
14933 gives unlimited permission to copy, distribute and modify it."
14935 ac_pwd='$ac_pwd'
14936 srcdir='$srcdir'
14937 INSTALL='$INSTALL'
14938 test -n "\$AWK" || AWK=awk
14939 _ACEOF
14941 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
14942 # The default lists apply if the user does not specify any file.
14943 ac_need_defaults=:
14944 while test $# != 0
14946 case $1 in
14947 --*=*)
14948 ac_option=`expr "X$1" : 'X\([^=]*\)='`
14949 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
14950 ac_shift=:
14953 ac_option=$1
14954 ac_optarg=$2
14955 ac_shift=shift
14957 esac
14959 case $ac_option in
14960 # Handling of the options.
14961 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
14962 ac_cs_recheck=: ;;
14963 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
14964 $as_echo "$ac_cs_version"; exit ;;
14965 --config | --confi | --conf | --con | --co | --c )
14966 $as_echo "$ac_cs_config"; exit ;;
14967 --debug | --debu | --deb | --de | --d | -d )
14968 debug=: ;;
14969 --file | --fil | --fi | --f )
14970 $ac_shift
14971 case $ac_optarg in
14972 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
14973 esac
14974 as_fn_append CONFIG_FILES " '$ac_optarg'"
14975 ac_need_defaults=false;;
14976 --header | --heade | --head | --hea )
14977 $ac_shift
14978 case $ac_optarg in
14979 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
14980 esac
14981 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
14982 ac_need_defaults=false;;
14983 --he | --h)
14984 # Conflict between --help and --header
14985 as_fn_error "ambiguous option: \`$1'
14986 Try \`$0 --help' for more information.";;
14987 --help | --hel | -h )
14988 $as_echo "$ac_cs_usage"; exit ;;
14989 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
14990 | -silent | --silent | --silen | --sile | --sil | --si | --s)
14991 ac_cs_silent=: ;;
14993 # This is an error.
14994 -*) as_fn_error "unrecognized option: \`$1'
14995 Try \`$0 --help' for more information." ;;
14997 *) as_fn_append ac_config_targets " $1"
14998 ac_need_defaults=false ;;
15000 esac
15001 shift
15002 done
15004 ac_configure_extra_args=
15006 if $ac_cs_silent; then
15007 exec 6>/dev/null
15008 ac_configure_extra_args="$ac_configure_extra_args --silent"
15011 _ACEOF
15012 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15013 if \$ac_cs_recheck; then
15014 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
15015 shift
15016 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
15017 CONFIG_SHELL='$SHELL'
15018 export CONFIG_SHELL
15019 exec "\$@"
15022 _ACEOF
15023 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15024 exec 5>>config.log
15026 echo
15027 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
15028 ## Running $as_me. ##
15029 _ASBOX
15030 $as_echo "$ac_log"
15031 } >&5
15033 _ACEOF
15034 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15036 # INIT-COMMANDS
15038 GCC="$GCC" NON_GNU_CPP="$NON_GNU_CPP" CPP="$CPP" CPPFLAGS="$CPPFLAGS"
15040 _ACEOF
15042 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15044 # Handling of arguments.
15045 for ac_config_target in $ac_config_targets
15047 case $ac_config_target in
15048 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
15049 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
15050 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
15051 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
15052 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
15053 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
15054 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
15055 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
15056 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
15057 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
15058 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
15059 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
15060 "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
15062 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
15063 esac
15064 done
15067 # If the user did not use the arguments to specify the items to instantiate,
15068 # then the envvar interface is used. Set only those that are not.
15069 # We use the long form for the default assignment because of an extremely
15070 # bizarre bug on SunOS 4.1.3.
15071 if $ac_need_defaults; then
15072 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
15073 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
15074 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
15077 # Have a temporary directory for convenience. Make it in the build tree
15078 # simply because there is no reason against having it here, and in addition,
15079 # creating and moving files from /tmp can sometimes cause problems.
15080 # Hook for its removal unless debugging.
15081 # Note that there is a small window in which the directory will not be cleaned:
15082 # after its creation but before its name has been assigned to `$tmp'.
15083 $debug ||
15085 tmp=
15086 trap 'exit_status=$?
15087 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
15089 trap 'as_fn_exit 1' 1 2 13 15
15091 # Create a (secure) tmp directory for tmp files.
15094 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
15095 test -n "$tmp" && test -d "$tmp"
15096 } ||
15098 tmp=./conf$$-$RANDOM
15099 (umask 077 && mkdir "$tmp")
15100 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
15102 # Set up the scripts for CONFIG_FILES section.
15103 # No need to generate them if there are no CONFIG_FILES.
15104 # This happens for instance with `./config.status config.h'.
15105 if test -n "$CONFIG_FILES"; then
15107 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
15108 ac_cs_awk_getline=:
15109 ac_cs_awk_pipe_init=
15110 ac_cs_awk_read_file='
15111 while ((getline aline < (F[key])) > 0)
15112 print(aline)
15113 close(F[key])'
15114 ac_cs_awk_pipe_fini=
15115 else
15116 ac_cs_awk_getline=false
15117 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
15118 ac_cs_awk_read_file='
15119 print "|#_!!_#|"
15120 print "cat " F[key] " &&"
15121 '$ac_cs_awk_pipe_init
15122 # The final `:' finishes the AND list.
15123 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
15125 ac_cr=`echo X | tr X '\015'`
15126 # On cygwin, bash can eat \r inside `` if the user requested igncr.
15127 # But we know of no other shell where ac_cr would be empty at this
15128 # point, so we can use a bashism as a fallback.
15129 if test "x$ac_cr" = x; then
15130 eval ac_cr=\$\'\\r\'
15132 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
15133 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
15134 ac_cs_awk_cr='\r'
15135 else
15136 ac_cs_awk_cr=$ac_cr
15139 echo 'BEGIN {' >"$tmp/subs1.awk" &&
15140 _ACEOF
15142 # Create commands to substitute file output variables.
15144 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
15145 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
15146 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
15147 echo "_ACAWK" &&
15148 echo "_ACEOF"
15149 } >conf$$files.sh &&
15150 . ./conf$$files.sh ||
15151 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
15152 rm -f conf$$files.sh
15155 echo "cat >conf$$subs.awk <<_ACEOF" &&
15156 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
15157 echo "_ACEOF"
15158 } >conf$$subs.sh ||
15159 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
15160 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
15161 ac_delim='%!_!# '
15162 for ac_last_try in false false false false false :; do
15163 . ./conf$$subs.sh ||
15164 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
15166 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
15167 if test $ac_delim_n = $ac_delim_num; then
15168 break
15169 elif $ac_last_try; then
15170 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
15171 else
15172 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
15174 done
15175 rm -f conf$$subs.sh
15177 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15178 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
15179 _ACEOF
15180 sed -n '
15182 s/^/S["/; s/!.*/"]=/
15185 s/^[^!]*!//
15186 :repl
15187 t repl
15188 s/'"$ac_delim"'$//
15189 t delim
15192 s/\(.\{148\}\)..*/\1/
15193 t more1
15194 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
15197 b repl
15198 :more1
15199 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
15202 s/.\{148\}//
15203 t nl
15204 :delim
15206 s/\(.\{148\}\)..*/\1/
15207 t more2
15208 s/["\\]/\\&/g; s/^/"/; s/$/"/
15211 :more2
15212 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
15215 s/.\{148\}//
15216 t delim
15217 ' <conf$$subs.awk | sed '
15218 /^[^""]/{
15220 s/\n//
15222 ' >>$CONFIG_STATUS || ac_write_fail=1
15223 rm -f conf$$subs.awk
15224 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15225 _ACAWK
15226 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
15227 for (key in S) S_is_set[key] = 1
15228 FS = "\a"
15229 \$ac_cs_awk_pipe_init
15232 line = $ 0
15233 nfields = split(line, field, "@")
15234 substed = 0
15235 len = length(field[1])
15236 for (i = 2; i < nfields; i++) {
15237 key = field[i]
15238 keylen = length(key)
15239 if (S_is_set[key]) {
15240 value = S[key]
15241 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
15242 len += length(value) + length(field[++i])
15243 substed = 1
15244 } else
15245 len += 1 + keylen
15247 if (nfields == 3 && !substed) {
15248 key = field[2]
15249 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
15250 \$ac_cs_awk_read_file
15251 next
15254 print line
15256 \$ac_cs_awk_pipe_fini
15257 _ACAWK
15258 _ACEOF
15259 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15260 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
15261 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
15262 else
15264 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
15265 || as_fn_error "could not setup config files machinery" "$LINENO" 5
15266 _ACEOF
15268 # VPATH may cause trouble with some makes, so we remove $(srcdir),
15269 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
15270 # trailing colons and then remove the whole line if VPATH becomes empty
15271 # (actually we leave an empty line to preserve line numbers).
15272 if test "x$srcdir" = x.; then
15273 ac_vpsub='/^[ ]*VPATH[ ]*=/{
15274 s/:*\$(srcdir):*/:/
15275 s/:*\${srcdir}:*/:/
15276 s/:*@srcdir@:*/:/
15277 s/^\([^=]*=[ ]*\):*/\1/
15278 s/:*$//
15279 s/^[^=]*=[ ]*$//
15283 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15284 fi # test -n "$CONFIG_FILES"
15286 # Set up the scripts for CONFIG_HEADERS section.
15287 # No need to generate them if there are no CONFIG_HEADERS.
15288 # This happens for instance with `./config.status Makefile'.
15289 if test -n "$CONFIG_HEADERS"; then
15290 cat >"$tmp/defines.awk" <<\_ACAWK ||
15291 BEGIN {
15292 _ACEOF
15294 # Transform confdefs.h into an awk script `defines.awk', embedded as
15295 # here-document in config.status, that substitutes the proper values into
15296 # config.h.in to produce config.h.
15298 # Create a delimiter string that does not exist in confdefs.h, to ease
15299 # handling of long lines.
15300 ac_delim='%!_!# '
15301 for ac_last_try in false false :; do
15302 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
15303 if test -z "$ac_t"; then
15304 break
15305 elif $ac_last_try; then
15306 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
15307 else
15308 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
15310 done
15312 # For the awk script, D is an array of macro values keyed by name,
15313 # likewise P contains macro parameters if any. Preserve backslash
15314 # newline sequences.
15316 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
15317 sed -n '
15318 s/.\{148\}/&'"$ac_delim"'/g
15319 t rset
15320 :rset
15321 s/^[ ]*#[ ]*define[ ][ ]*/ /
15322 t def
15324 :def
15325 s/\\$//
15326 t bsnl
15327 s/["\\]/\\&/g
15328 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
15329 D["\1"]=" \3"/p
15330 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
15332 :bsnl
15333 s/["\\]/\\&/g
15334 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
15335 D["\1"]=" \3\\\\\\n"\\/p
15336 t cont
15337 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
15338 t cont
15340 :cont
15342 s/.\{148\}/&'"$ac_delim"'/g
15343 t clear
15344 :clear
15345 s/\\$//
15346 t bsnlc
15347 s/["\\]/\\&/g; s/^/"/; s/$/"/p
15349 :bsnlc
15350 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
15351 b cont
15352 ' <confdefs.h | sed '
15353 s/'"$ac_delim"'/"\\\
15354 "/g' >>$CONFIG_STATUS || ac_write_fail=1
15356 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15357 for (key in D) D_is_set[key] = 1
15358 FS = "\a"
15360 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
15361 line = \$ 0
15362 split(line, arg, " ")
15363 if (arg[1] == "#") {
15364 defundef = arg[2]
15365 mac1 = arg[3]
15366 } else {
15367 defundef = substr(arg[1], 2)
15368 mac1 = arg[2]
15370 split(mac1, mac2, "(") #)
15371 macro = mac2[1]
15372 prefix = substr(line, 1, index(line, defundef) - 1)
15373 if (D_is_set[macro]) {
15374 # Preserve the white space surrounding the "#".
15375 print prefix "define", macro P[macro] D[macro]
15376 next
15377 } else {
15378 # Replace #undef with comments. This is necessary, for example,
15379 # in the case of _POSIX_SOURCE, which is predefined and required
15380 # on some systems where configure will not decide to define it.
15381 if (defundef == "undef") {
15382 print "/*", prefix defundef, macro, "*/"
15383 next
15387 { print }
15388 _ACAWK
15389 _ACEOF
15390 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15391 as_fn_error "could not setup config headers machinery" "$LINENO" 5
15392 fi # test -n "$CONFIG_HEADERS"
15395 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
15396 shift
15397 for ac_tag
15399 case $ac_tag in
15400 :[FHLC]) ac_mode=$ac_tag; continue;;
15401 esac
15402 case $ac_mode$ac_tag in
15403 :[FHL]*:*);;
15404 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
15405 :[FH]-) ac_tag=-:-;;
15406 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
15407 esac
15408 ac_save_IFS=$IFS
15409 IFS=:
15410 set x $ac_tag
15411 IFS=$ac_save_IFS
15412 shift
15413 ac_file=$1
15414 shift
15416 case $ac_mode in
15417 :L) ac_source=$1;;
15418 :[FH])
15419 ac_file_inputs=
15420 for ac_f
15422 case $ac_f in
15423 -) ac_f="$tmp/stdin";;
15424 *) # Look for the file first in the build tree, then in the source tree
15425 # (if the path is not absolute). The absolute path cannot be DOS-style,
15426 # because $ac_f cannot contain `:'.
15427 test -f "$ac_f" ||
15428 case $ac_f in
15429 [\\/$]*) false;;
15430 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
15431 esac ||
15432 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
15433 esac
15434 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
15435 as_fn_append ac_file_inputs " '$ac_f'"
15436 done
15438 # Let's still pretend it is `configure' which instantiates (i.e., don't
15439 # use $as_me), people would be surprised to read:
15440 # /* config.h. Generated by config.status. */
15441 configure_input='Generated from '`
15442 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
15443 `' by configure.'
15444 if test x"$ac_file" != x-; then
15445 configure_input="$ac_file. $configure_input"
15446 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
15447 $as_echo "$as_me: creating $ac_file" >&6;}
15449 # Neutralize special characters interpreted by sed in replacement strings.
15450 case $configure_input in #(
15451 *\&* | *\|* | *\\* )
15452 ac_sed_conf_input=`$as_echo "$configure_input" |
15453 sed 's/[\\\\&|]/\\\\&/g'`;; #(
15454 *) ac_sed_conf_input=$configure_input;;
15455 esac
15457 case $ac_tag in
15458 *:-:* | *:-) cat >"$tmp/stdin" \
15459 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
15460 esac
15462 esac
15464 ac_dir=`$as_dirname -- "$ac_file" ||
15465 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
15466 X"$ac_file" : 'X\(//\)[^/]' \| \
15467 X"$ac_file" : 'X\(//\)$' \| \
15468 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
15469 $as_echo X"$ac_file" |
15470 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
15471 s//\1/
15474 /^X\(\/\/\)[^/].*/{
15475 s//\1/
15478 /^X\(\/\/\)$/{
15479 s//\1/
15482 /^X\(\/\).*/{
15483 s//\1/
15486 s/.*/./; q'`
15487 as_dir="$ac_dir"; as_fn_mkdir_p
15488 ac_builddir=.
15490 case "$ac_dir" in
15491 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
15493 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
15494 # A ".." for each directory in $ac_dir_suffix.
15495 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
15496 case $ac_top_builddir_sub in
15497 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
15498 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
15499 esac ;;
15500 esac
15501 ac_abs_top_builddir=$ac_pwd
15502 ac_abs_builddir=$ac_pwd$ac_dir_suffix
15503 # for backward compatibility:
15504 ac_top_builddir=$ac_top_build_prefix
15506 case $srcdir in
15507 .) # We are building in place.
15508 ac_srcdir=.
15509 ac_top_srcdir=$ac_top_builddir_sub
15510 ac_abs_top_srcdir=$ac_pwd ;;
15511 [\\/]* | ?:[\\/]* ) # Absolute name.
15512 ac_srcdir=$srcdir$ac_dir_suffix;
15513 ac_top_srcdir=$srcdir
15514 ac_abs_top_srcdir=$srcdir ;;
15515 *) # Relative name.
15516 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
15517 ac_top_srcdir=$ac_top_build_prefix$srcdir
15518 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
15519 esac
15520 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
15523 case $ac_mode in
15526 # CONFIG_FILE
15529 case $INSTALL in
15530 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
15531 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
15532 esac
15533 _ACEOF
15535 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15536 # If the template does not know about datarootdir, expand it.
15537 # FIXME: This hack should be removed a few years after 2.60.
15538 ac_datarootdir_hack=; ac_datarootdir_seen=
15539 ac_sed_dataroot='
15540 /datarootdir/ {
15544 /@datadir@/p
15545 /@docdir@/p
15546 /@infodir@/p
15547 /@localedir@/p
15548 /@mandir@/p'
15549 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
15550 *datarootdir*) ac_datarootdir_seen=yes;;
15551 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
15552 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
15553 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
15554 _ACEOF
15555 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15556 ac_datarootdir_hack='
15557 s&@datadir@&$datadir&g
15558 s&@docdir@&$docdir&g
15559 s&@infodir@&$infodir&g
15560 s&@localedir@&$localedir&g
15561 s&@mandir@&$mandir&g
15562 s&\\\${datarootdir}&$datarootdir&g' ;;
15563 esac
15564 _ACEOF
15566 # Neutralize VPATH when `$srcdir' = `.'.
15567 # Shell code in configure.ac might set extrasub.
15568 # FIXME: do we really want to maintain this feature?
15569 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
15570 ac_sed_extra="$ac_vpsub
15571 $extrasub
15572 _ACEOF
15573 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
15575 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
15576 s|@configure_input@|$ac_sed_conf_input|;t t
15577 s&@top_builddir@&$ac_top_builddir_sub&;t t
15578 s&@top_build_prefix@&$ac_top_build_prefix&;t t
15579 s&@srcdir@&$ac_srcdir&;t t
15580 s&@abs_srcdir@&$ac_abs_srcdir&;t t
15581 s&@top_srcdir@&$ac_top_srcdir&;t t
15582 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
15583 s&@builddir@&$ac_builddir&;t t
15584 s&@abs_builddir@&$ac_abs_builddir&;t t
15585 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
15586 s&@INSTALL@&$ac_INSTALL&;t t
15587 $ac_datarootdir_hack
15589 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
15590 if $ac_cs_awk_getline; then
15591 $AWK -f "$tmp/subs.awk"
15592 else
15593 $AWK -f "$tmp/subs.awk" | $SHELL
15594 fi >$tmp/out \
15595 || as_fn_error "could not create $ac_file" "$LINENO" 5
15597 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
15598 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
15599 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
15600 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
15601 which seems to be undefined. Please make sure it is defined." >&5
15602 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
15603 which seems to be undefined. Please make sure it is defined." >&2;}
15605 rm -f "$tmp/stdin"
15606 case $ac_file in
15607 -) cat "$tmp/out" && rm -f "$tmp/out";;
15608 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
15609 esac \
15610 || as_fn_error "could not create $ac_file" "$LINENO" 5
15614 # CONFIG_HEADER
15616 if test x"$ac_file" != x-; then
15618 $as_echo "/* $configure_input */" \
15619 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
15620 } >"$tmp/config.h" \
15621 || as_fn_error "could not create $ac_file" "$LINENO" 5
15622 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
15623 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
15624 $as_echo "$as_me: $ac_file is unchanged" >&6;}
15625 else
15626 rm -f "$ac_file"
15627 mv "$tmp/config.h" "$ac_file" \
15628 || as_fn_error "could not create $ac_file" "$LINENO" 5
15630 else
15631 $as_echo "/* $configure_input */" \
15632 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
15633 || as_fn_error "could not create -" "$LINENO" 5
15637 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
15638 $as_echo "$as_me: executing $ac_file commands" >&6;}
15640 esac
15643 case $ac_file$ac_mode in
15644 "default":C)
15646 ### Make the necessary directories, if they don't exist.
15647 for dir in etc lisp ; do
15648 test -d ${dir} || mkdir ${dir}
15649 done
15651 echo creating src/epaths.h
15652 ${MAKE-make} epaths-force
15654 if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
15655 echo creating src/.gdbinit
15656 echo source $srcdir/src/.gdbinit > src/.gdbinit
15661 esac
15662 done # for ac_tag
15665 as_fn_exit 0
15666 _ACEOF
15667 ac_clean_files=$ac_clean_files_save
15669 test $ac_write_fail = 0 ||
15670 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
15673 # configure is writing to config.log, and then calls config.status.
15674 # config.status does its own redirection, appending to config.log.
15675 # Unfortunately, on DOS this fails, as config.log is still kept open
15676 # by configure, so config.status won't be able to write to it; its
15677 # output is simply discarded. So we exec the FD to /dev/null,
15678 # effectively closing config.log, so it can be properly (re)opened and
15679 # appended to by config.status. When coming back to configure, we
15680 # need to make the FD available again.
15681 if test "$no_create" != yes; then
15682 ac_cs_success=:
15683 ac_config_status_args=
15684 test "$silent" = yes &&
15685 ac_config_status_args="$ac_config_status_args --quiet"
15686 exec 5>/dev/null
15687 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
15688 exec 5>>config.log
15689 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
15690 # would make configure fail if this is the last instruction.
15691 $ac_cs_success || as_fn_exit $?
15693 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
15694 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
15695 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}