Commit | Line | Data |
---|---|---|
067d23c9 KY |
1 | #! /bin/sh |
2 | # Guess values for system-dependent variables and create Makefiles. | |
d6974efa | 3 | # Generated by GNU Autoconf 2.68 for emacs 24.0.50. |
067d23c9 KY |
4 | # |
5 | # | |
6 | # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, | |
2018939f AS |
7 | # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software |
8 | # Foundation, Inc. | |
067d23c9 KY |
9 | # |
10 | # | |
11 | # This configure script is free software; the Free Software Foundation | |
12 | # gives unlimited permission to copy, distribute and modify it. | |
13 | ## -------------------- ## | |
14 | ## M4sh Initialization. ## | |
15 | ## -------------------- ## | |
16 | ||
17 | # Be more Bourne compatible | |
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 | *) : | |
31 | ;; | |
32 | esac | |
33 | fi | |
34 | ||
35 | ||
36 | as_nl=' | |
37 | ' | |
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" | |
66 | ' | |
67 | export as_echo_n_body | |
68 | as_echo_n='sh -c $as_echo_n_body as_echo' | |
69 | fi | |
70 | export as_echo_body | |
71 | as_echo='sh -c $as_echo_body as_echo' | |
72 | fi | |
73 | ||
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=';' | |
80 | } | |
81 | fi | |
82 | ||
83 | ||
84 | # IFS | |
85 | # We need space, tab and new line, in precisely that order. Quoting is | |
86 | # there to prevent editors from complaining about space-tab. | |
87 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word | |
88 | # splitting by setting IFS to empty value.) | |
89 | IFS=" "" $as_nl" | |
90 | ||
91 | # Find who we are. Look in the path if we contain no directory separator. | |
d6974efa | 92 | as_myself= |
067d23c9 KY |
93 | case $0 in #(( |
94 | *[\\/]* ) as_myself=$0 ;; | |
95 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
96 | for as_dir in $PATH | |
97 | do | |
98 | IFS=$as_save_IFS | |
99 | test -z "$as_dir" && as_dir=. | |
100 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break | |
101 | done | |
102 | IFS=$as_save_IFS | |
103 | ||
104 | ;; | |
105 | esac | |
106 | # We did not find ourselves, most probably we were run as `sh COMMAND' | |
107 | # in which case we are not to be found in the path. | |
108 | if test "x$as_myself" = x; then | |
109 | as_myself=$0 | |
110 | fi | |
111 | if test ! -f "$as_myself"; then | |
112 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 | |
113 | exit 1 | |
114 | fi | |
115 | ||
116 | # Unset variables that we do not need and which cause bugs (e.g. in | |
117 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" | |
118 | # suppresses any "Segmentation fault" message there. '((' could | |
119 | # trigger a bug in pdksh 5.2.14. | |
120 | for as_var in BASH_ENV ENV MAIL MAILPATH | |
121 | do eval test x\${$as_var+set} = xset \ | |
122 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : | |
123 | done | |
124 | PS1='$ ' | |
125 | PS2='> ' | |
126 | PS4='+ ' | |
127 | ||
128 | # NLS nuisances. | |
129 | LC_ALL=C | |
130 | export LC_ALL | |
131 | LANGUAGE=C | |
132 | export LANGUAGE | |
133 | ||
134 | # CDPATH. | |
135 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH | |
136 | ||
137 | if test "x$CONFIG_SHELL" = x; then | |
138 | as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : | |
139 | emulate sh | |
140 | NULLCMD=: | |
141 | # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which | |
142 | # is contrary to our usage. Disable this feature. | |
143 | alias -g '\${1+\"\$@\"}'='\"\$@\"' | |
144 | setopt NO_GLOB_SUBST | |
145 | else | |
146 | case \`(set -o) 2>/dev/null\` in #( | |
147 | *posix*) : | |
148 | set -o posix ;; #( | |
149 | *) : | |
150 | ;; | |
151 | esac | |
152 | fi | |
153 | " | |
154 | as_required="as_fn_return () { (exit \$1); } | |
155 | as_fn_success () { as_fn_return 0; } | |
156 | as_fn_failure () { as_fn_return 1; } | |
157 | as_fn_ret_success () { return 0; } | |
158 | as_fn_ret_failure () { return 1; } | |
159 | ||
160 | exitcode=0 | |
161 | as_fn_success || { exitcode=1; echo as_fn_success failed.; } | |
162 | as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } | |
163 | as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } | |
164 | as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } | |
165 | if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : | |
166 | ||
167 | else | |
168 | exitcode=1; echo positional parameters were not saved. | |
169 | fi | |
170 | test x\$exitcode = x0 || exit 1" | |
171 | as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO | |
172 | as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO | |
173 | eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && | |
174 | test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 | |
175 | test \$(( 1 + 1 )) = 2 || exit 1" | |
176 | if (eval "$as_required") 2>/dev/null; then : | |
177 | as_have_required=yes | |
178 | else | |
179 | as_have_required=no | |
180 | fi | |
181 | if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : | |
182 | ||
183 | else | |
184 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
185 | as_found=false | |
186 | for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH | |
187 | do | |
188 | IFS=$as_save_IFS | |
189 | test -z "$as_dir" && as_dir=. | |
190 | as_found=: | |
191 | case $as_dir in #( | |
192 | /*) | |
193 | for as_base in sh bash ksh sh5; do | |
194 | # Try only shells that exist, to save several forks. | |
195 | as_shell=$as_dir/$as_base | |
196 | if { test -f "$as_shell" || test -f "$as_shell.exe"; } && | |
197 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : | |
198 | CONFIG_SHELL=$as_shell as_have_required=yes | |
199 | if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : | |
200 | break 2 | |
201 | fi | |
202 | fi | |
203 | done;; | |
204 | esac | |
205 | as_found=false | |
206 | done | |
207 | $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && | |
208 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : | |
209 | CONFIG_SHELL=$SHELL as_have_required=yes | |
210 | fi; } | |
211 | IFS=$as_save_IFS | |
212 | ||
213 | ||
214 | if test "x$CONFIG_SHELL" != x; then : | |
215 | # We cannot yet assume a decent shell, so we have to provide a | |
216 | # neutralization value for shells without unset; and this also | |
217 | # works around shells that cannot unset nonexistent variables. | |
d6974efa | 218 | # Preserve -v and -x to the replacement shell. |
067d23c9 KY |
219 | BASH_ENV=/dev/null |
220 | ENV=/dev/null | |
221 | (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV | |
222 | export CONFIG_SHELL | |
d6974efa PE |
223 | case $- in # (((( |
224 | *v*x* | *x*v* ) as_opts=-vx ;; | |
225 | *v* ) as_opts=-v ;; | |
226 | *x* ) as_opts=-x ;; | |
227 | * ) as_opts= ;; | |
228 | esac | |
229 | exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"} | |
067d23c9 KY |
230 | fi |
231 | ||
232 | if test x$as_have_required = xno; then : | |
233 | $as_echo "$0: This script requires a shell more modern than all" | |
234 | $as_echo "$0: the shells that I found on your system." | |
235 | if test x${ZSH_VERSION+set} = xset ; then | |
236 | $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" | |
237 | $as_echo "$0: be upgraded to zsh 4.3.4 or later." | |
238 | else | |
239 | $as_echo "$0: Please tell bug-autoconf@gnu.org about your system, | |
240 | $0: including any error possibly output before this | |
241 | $0: message. Then install a modern shell, or manually run | |
242 | $0: the script under such a shell if you do have one." | |
243 | fi | |
244 | exit 1 | |
245 | fi | |
246 | fi | |
247 | fi | |
248 | SHELL=${CONFIG_SHELL-/bin/sh} | |
249 | export SHELL | |
250 | # Unset more variables known to interfere with behavior of common tools. | |
251 | CLICOLOR_FORCE= GREP_OPTIONS= | |
252 | unset CLICOLOR_FORCE GREP_OPTIONS | |
253 | ||
254 | ## --------------------- ## | |
255 | ## M4sh Shell Functions. ## | |
256 | ## --------------------- ## | |
257 | # as_fn_unset VAR | |
258 | # --------------- | |
259 | # Portably unset VAR. | |
260 | as_fn_unset () | |
261 | { | |
262 | { eval $1=; unset $1;} | |
263 | } | |
264 | as_unset=as_fn_unset | |
265 | ||
266 | # as_fn_set_status STATUS | |
267 | # ----------------------- | |
268 | # Set $? to STATUS, without forking. | |
269 | as_fn_set_status () | |
270 | { | |
271 | return $1 | |
272 | } # as_fn_set_status | |
273 | ||
274 | # as_fn_exit STATUS | |
275 | # ----------------- | |
276 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. | |
277 | as_fn_exit () | |
278 | { | |
279 | set +e | |
280 | as_fn_set_status $1 | |
281 | exit $1 | |
282 | } # as_fn_exit | |
283 | ||
284 | # as_fn_mkdir_p | |
285 | # ------------- | |
286 | # Create "$as_dir" as a directory, including parents if necessary. | |
287 | as_fn_mkdir_p () | |
288 | { | |
289 | ||
290 | case $as_dir in #( | |
291 | -*) as_dir=./$as_dir;; | |
292 | esac | |
293 | test -d "$as_dir" || eval $as_mkdir_p || { | |
294 | as_dirs= | |
295 | while :; do | |
296 | case $as_dir in #( | |
297 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( | |
298 | *) as_qdir=$as_dir;; | |
299 | esac | |
300 | as_dirs="'$as_qdir' $as_dirs" | |
301 | as_dir=`$as_dirname -- "$as_dir" || | |
302 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
303 | X"$as_dir" : 'X\(//\)[^/]' \| \ | |
304 | X"$as_dir" : 'X\(//\)$' \| \ | |
305 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || | |
306 | $as_echo X"$as_dir" | | |
307 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
308 | s//\1/ | |
309 | q | |
310 | } | |
311 | /^X\(\/\/\)[^/].*/{ | |
312 | s//\1/ | |
313 | q | |
314 | } | |
315 | /^X\(\/\/\)$/{ | |
316 | s//\1/ | |
317 | q | |
318 | } | |
319 | /^X\(\/\).*/{ | |
320 | s//\1/ | |
321 | q | |
322 | } | |
323 | s/.*/./; q'` | |
324 | test -d "$as_dir" && break | |
325 | done | |
326 | test -z "$as_dirs" || eval "mkdir $as_dirs" | |
2018939f | 327 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" |
067d23c9 KY |
328 | |
329 | ||
330 | } # as_fn_mkdir_p | |
331 | # as_fn_append VAR VALUE | |
332 | # ---------------------- | |
333 | # Append the text in VALUE to the end of the definition contained in VAR. Take | |
334 | # advantage of any shell optimizations that allow amortized linear growth over | |
335 | # repeated appends, instead of the typical quadratic growth present in naive | |
336 | # implementations. | |
337 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : | |
338 | eval 'as_fn_append () | |
339 | { | |
340 | eval $1+=\$2 | |
341 | }' | |
342 | else | |
343 | as_fn_append () | |
344 | { | |
345 | eval $1=\$$1\$2 | |
346 | } | |
347 | fi # as_fn_append | |
348 | ||
349 | # as_fn_arith ARG... | |
350 | # ------------------ | |
351 | # Perform arithmetic evaluation on the ARGs, and store the result in the | |
352 | # global $as_val. Take advantage of shells that can avoid forks. The arguments | |
353 | # must be portable across $(()) and expr. | |
354 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : | |
355 | eval 'as_fn_arith () | |
356 | { | |
357 | as_val=$(( $* )) | |
358 | }' | |
359 | else | |
360 | as_fn_arith () | |
361 | { | |
362 | as_val=`expr "$@" || test $? -eq 1` | |
363 | } | |
364 | fi # as_fn_arith | |
365 | ||
366 | ||
2018939f AS |
367 | # as_fn_error STATUS ERROR [LINENO LOG_FD] |
368 | # ---------------------------------------- | |
067d23c9 KY |
369 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
370 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the | |
2018939f | 371 | # script with STATUS, using 1 if that was 0. |
067d23c9 KY |
372 | as_fn_error () |
373 | { | |
2018939f AS |
374 | as_status=$1; test $as_status -eq 0 && as_status=1 |
375 | if test "$4"; then | |
376 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
377 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 | |
067d23c9 | 378 | fi |
2018939f | 379 | $as_echo "$as_me: error: $2" >&2 |
067d23c9 KY |
380 | as_fn_exit $as_status |
381 | } # as_fn_error | |
382 | ||
383 | if expr a : '\(a\)' >/dev/null 2>&1 && | |
384 | test "X`expr 00001 : '.*\(...\)'`" = X001; then | |
385 | as_expr=expr | |
386 | else | |
387 | as_expr=false | |
388 | fi | |
389 | ||
390 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then | |
391 | as_basename=basename | |
392 | else | |
393 | as_basename=false | |
394 | fi | |
395 | ||
396 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then | |
397 | as_dirname=dirname | |
398 | else | |
399 | as_dirname=false | |
400 | fi | |
401 | ||
402 | as_me=`$as_basename -- "$0" || | |
403 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ | |
404 | X"$0" : 'X\(//\)$' \| \ | |
405 | X"$0" : 'X\(/\)' \| . 2>/dev/null || | |
406 | $as_echo X/"$0" | | |
407 | sed '/^.*\/\([^/][^/]*\)\/*$/{ | |
408 | s//\1/ | |
409 | q | |
410 | } | |
411 | /^X\/\(\/\/\)$/{ | |
412 | s//\1/ | |
413 | q | |
414 | } | |
415 | /^X\/\(\/\).*/{ | |
416 | s//\1/ | |
417 | q | |
418 | } | |
419 | s/.*/./; q'` | |
420 | ||
421 | # Avoid depending upon Character Ranges. | |
422 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' | |
423 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' | |
424 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS | |
425 | as_cr_digits='0123456789' | |
426 | as_cr_alnum=$as_cr_Letters$as_cr_digits | |
427 | ||
428 | ||
429 | as_lineno_1=$LINENO as_lineno_1a=$LINENO | |
430 | as_lineno_2=$LINENO as_lineno_2a=$LINENO | |
431 | eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && | |
432 | test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { | |
433 | # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) | |
434 | sed -n ' | |
435 | p | |
436 | /[$]LINENO/= | |
437 | ' <$as_myself | | |
438 | sed ' | |
439 | s/[$]LINENO.*/&-/ | |
440 | t lineno | |
441 | b | |
442 | :lineno | |
443 | N | |
444 | :loop | |
445 | s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ | |
446 | t loop | |
447 | s/-\n.*// | |
448 | ' >$as_me.lineno && | |
449 | chmod +x "$as_me.lineno" || | |
450 | { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } | |
451 | ||
452 | # Don't try to exec as it changes $[0], causing all sort of problems | |
453 | # (the dirname of $[0] is not the place where we might find the | |
454 | # original and so on. Autoconf is especially sensitive to this). | |
455 | . "./$as_me.lineno" | |
456 | # Exit status is that of the last command. | |
457 | exit | |
458 | } | |
459 | ||
460 | ECHO_C= ECHO_N= ECHO_T= | |
461 | case `echo -n x` in #((((( | |
462 | -n*) | |
463 | case `echo 'xy\c'` in | |
464 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. | |
465 | xy) ECHO_C='\c';; | |
466 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null | |
467 | ECHO_T=' ';; | |
468 | esac;; | |
469 | *) | |
470 | ECHO_N='-n';; | |
471 | esac | |
472 | ||
473 | rm -f conf$$ conf$$.exe conf$$.file | |
474 | if test -d conf$$.dir; then | |
475 | rm -f conf$$.dir/conf$$.file | |
476 | else | |
477 | rm -f conf$$.dir | |
478 | mkdir conf$$.dir 2>/dev/null | |
479 | fi | |
480 | if (echo >conf$$.file) 2>/dev/null; then | |
481 | if ln -s conf$$.file conf$$ 2>/dev/null; then | |
482 | as_ln_s='ln -s' | |
483 | # ... but there are two gotchas: | |
484 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. | |
485 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. | |
486 | # In both cases, we have to default to `cp -p'. | |
487 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || | |
488 | as_ln_s='cp -p' | |
489 | elif ln conf$$.file conf$$ 2>/dev/null; then | |
490 | as_ln_s=ln | |
491 | else | |
492 | as_ln_s='cp -p' | |
493 | fi | |
494 | else | |
495 | as_ln_s='cp -p' | |
496 | fi | |
497 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file | |
498 | rmdir conf$$.dir 2>/dev/null | |
499 | ||
500 | if mkdir -p . 2>/dev/null; then | |
501 | as_mkdir_p='mkdir -p "$as_dir"' | |
502 | else | |
503 | test -d ./-p && rmdir ./-p | |
504 | as_mkdir_p=false | |
505 | fi | |
506 | ||
507 | if test -x / >/dev/null 2>&1; then | |
508 | as_test_x='test -x' | |
509 | else | |
510 | if ls -dL / >/dev/null 2>&1; then | |
511 | as_ls_L_option=L | |
512 | else | |
513 | as_ls_L_option= | |
514 | fi | |
515 | as_test_x=' | |
516 | eval sh -c '\'' | |
517 | if test -d "$1"; then | |
518 | test -d "$1/."; | |
519 | else | |
520 | case $1 in #( | |
521 | -*)set "./$1";; | |
522 | esac; | |
523 | case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( | |
524 | ???[sx]*):;;*)false;;esac;fi | |
525 | '\'' sh | |
526 | ' | |
527 | fi | |
528 | as_executable_p=$as_test_x | |
529 | ||
530 | # Sed expression to map a string onto a valid CPP name. | |
531 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" | |
532 | ||
533 | # Sed expression to map a string onto a valid variable name. | |
534 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" | |
535 | ||
536 | ||
537 | test -n "$DJDIR" || exec 7<&0 </dev/null | |
538 | exec 6>&1 | |
539 | ||
540 | # Name of the host. | |
2018939f | 541 | # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, |
067d23c9 KY |
542 | # so uname gets run too. |
543 | ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` | |
544 | ||
545 | # | |
546 | # Initializations. | |
547 | # | |
548 | ac_default_prefix=/usr/local | |
549 | ac_clean_files= | |
550 | ac_config_libobj_dir=. | |
551 | LIBOBJS= | |
552 | cross_compiling=no | |
553 | subdirs= | |
554 | MFLAGS= | |
555 | MAKEFLAGS= | |
556 | ||
557 | # Identity of this package. | |
558 | PACKAGE_NAME='emacs' | |
559 | PACKAGE_TARNAME='emacs' | |
560 | PACKAGE_VERSION='24.0.50' | |
561 | PACKAGE_STRING='emacs 24.0.50' | |
562 | PACKAGE_BUGREPORT='' | |
563 | PACKAGE_URL='' | |
564 | ||
565 | ac_unique_file="src/lisp.h" | |
566 | # Factoring default headers for most tests. | |
567 | ac_includes_default="\ | |
568 | #include <stdio.h> | |
569 | #ifdef HAVE_SYS_TYPES_H | |
570 | # include <sys/types.h> | |
571 | #endif | |
572 | #ifdef HAVE_SYS_STAT_H | |
573 | # include <sys/stat.h> | |
574 | #endif | |
575 | #ifdef STDC_HEADERS | |
576 | # include <stdlib.h> | |
577 | # include <stddef.h> | |
578 | #else | |
579 | # ifdef HAVE_STDLIB_H | |
580 | # include <stdlib.h> | |
581 | # endif | |
582 | #endif | |
583 | #ifdef HAVE_STRING_H | |
584 | # if !defined STDC_HEADERS && defined HAVE_MEMORY_H | |
585 | # include <memory.h> | |
586 | # endif | |
587 | # include <string.h> | |
588 | #endif | |
589 | #ifdef HAVE_STRINGS_H | |
590 | # include <strings.h> | |
591 | #endif | |
592 | #ifdef HAVE_INTTYPES_H | |
593 | # include <inttypes.h> | |
594 | #endif | |
595 | #ifdef HAVE_STDINT_H | |
596 | # include <stdint.h> | |
597 | #endif | |
598 | #ifdef HAVE_UNISTD_H | |
599 | # include <unistd.h> | |
600 | #endif" | |
601 | ||
067d23c9 | 602 | ac_header_list= |
e275c824 PE |
603 | gl_getopt_required=POSIX |
604 | gl_getopt_required=POSIX | |
067d23c9 | 605 | ac_func_list= |
743c80a7 PE |
606 | ac_subst_vars='gltests_LTLIBOBJS |
607 | gltests_LIBOBJS | |
608 | gl_LTLIBOBJS | |
609 | gl_LIBOBJS | |
610 | am__EXEEXT_FALSE | |
611 | am__EXEEXT_TRUE | |
612 | LTLIBOBJS | |
1f5d53eb | 613 | LIBOBJS |
067d23c9 KY |
614 | WINDOW_SUPPORT |
615 | TOOLTIP_SUPPORT | |
616 | MOUSE_SUPPORT | |
617 | LIB_GCC | |
618 | LD_FIRSTFLAG | |
619 | LD_SWITCH_SYSTEM_TEMACS | |
620 | POST_ALLOC_OBJ | |
621 | PRE_ALLOC_OBJ | |
622 | CYGWIN_OBJ | |
623 | RALLOC_OBJ | |
624 | OLDXMENU_DEPS | |
625 | LIBX_OTHER | |
626 | LIBXMENU | |
627 | OLDXMENU | |
628 | OLDXMENU_TARGET | |
629 | LIBXT_OTHER | |
630 | TOOLKIT_LIBW | |
631 | WIDGET_OBJ | |
632 | XOBJ | |
633 | XMENU_OBJ | |
634 | FONT_OBJ | |
635 | OTHER_FILES | |
636 | GNU_OBJC_CFLAGS | |
637 | ns_appsrc | |
638 | ns_appresdir | |
639 | ns_appbindir | |
640 | ns_appdir | |
d6a003a8 AS |
641 | S_FILE |
642 | M_FILE | |
067d23c9 KY |
643 | X_TOOLKIT_TYPE |
644 | C_SWITCH_X_SYSTEM | |
645 | C_SWITCH_X_SITE | |
646 | LD_SWITCH_X_SITE | |
647 | gameuser | |
648 | gamedir | |
649 | bitmapdir | |
650 | archlibdir | |
651 | etcdir | |
652 | x_default_search_path | |
653 | lisppath | |
654 | locallisppath | |
655 | lispdir | |
656 | srcdir | |
657 | canonical | |
658 | configuration | |
659 | version | |
660 | KRB4LIB | |
661 | DESLIB | |
662 | KRB5LIB | |
663 | CRYPTOLIB | |
664 | COM_ERRLIB | |
665 | LIBRESOLV | |
666 | LIBHESIOD | |
667 | TERMCAP_OBJ | |
668 | LIBS_TERMCAP | |
743c80a7 PE |
669 | LIBGNU_LTLIBDEPS |
670 | LIBGNU_LIBDEPS | |
671 | gltests_WITNESS | |
e275c824 PE |
672 | HAVE_UNISTD_H |
673 | NEXT_AS_FIRST_DIRECTIVE_UNISTD_H | |
674 | NEXT_UNISTD_H | |
1fd182f0 PE |
675 | PTHREAD_H_DEFINES_STRUCT_TIMESPEC |
676 | SYS_TIME_H_DEFINES_STRUCT_TIMESPEC | |
677 | TIME_H_DEFINES_STRUCT_TIMESPEC | |
678 | NEXT_AS_FIRST_DIRECTIVE_TIME_H | |
679 | NEXT_TIME_H | |
5fa4ac76 PE |
680 | NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H |
681 | NEXT_SYS_STAT_H | |
682 | REPLACE_UTIMENSAT | |
683 | REPLACE_STAT | |
684 | REPLACE_MKNOD | |
685 | REPLACE_MKFIFO | |
686 | REPLACE_MKDIR | |
687 | REPLACE_LSTAT | |
688 | REPLACE_FUTIMENS | |
689 | REPLACE_FSTATAT | |
690 | REPLACE_FSTAT | |
691 | HAVE_UTIMENSAT | |
692 | HAVE_MKNODAT | |
693 | HAVE_MKNOD | |
694 | HAVE_MKFIFOAT | |
695 | HAVE_MKFIFO | |
696 | HAVE_MKDIRAT | |
697 | HAVE_LSTAT | |
698 | HAVE_LCHMOD | |
699 | HAVE_FUTIMENS | |
700 | HAVE_FSTATAT | |
701 | HAVE_FCHMODAT | |
702 | GNULIB_UTIMENSAT | |
703 | GNULIB_STAT | |
704 | GNULIB_MKNODAT | |
705 | GNULIB_MKNOD | |
706 | GNULIB_MKFIFOAT | |
707 | GNULIB_MKFIFO | |
708 | GNULIB_MKDIRAT | |
709 | GNULIB_LSTAT | |
710 | GNULIB_LCHMOD | |
711 | GNULIB_FUTIMENS | |
712 | GNULIB_FSTATAT | |
713 | GNULIB_FCHMODAT | |
1f5d53eb PE |
714 | NEXT_AS_FIRST_DIRECTIVE_STDLIB_H |
715 | NEXT_STDLIB_H | |
5f90be1b PE |
716 | STDINT_H |
717 | WINT_T_SUFFIX | |
718 | WCHAR_T_SUFFIX | |
719 | SIG_ATOMIC_T_SUFFIX | |
720 | SIZE_T_SUFFIX | |
721 | PTRDIFF_T_SUFFIX | |
722 | HAVE_SIGNED_WINT_T | |
723 | HAVE_SIGNED_WCHAR_T | |
724 | HAVE_SIGNED_SIG_ATOMIC_T | |
725 | BITSIZEOF_WINT_T | |
726 | BITSIZEOF_WCHAR_T | |
727 | BITSIZEOF_SIG_ATOMIC_T | |
728 | BITSIZEOF_SIZE_T | |
729 | BITSIZEOF_PTRDIFF_T | |
730 | HAVE_SYS_BITYPES_H | |
731 | HAVE_SYS_INTTYPES_H | |
732 | HAVE_STDINT_H | |
733 | NEXT_AS_FIRST_DIRECTIVE_STDINT_H | |
734 | NEXT_STDINT_H | |
735 | HAVE_SYS_TYPES_H | |
736 | HAVE_INTTYPES_H | |
737 | HAVE_WCHAR_H | |
738 | HAVE_UNSIGNED_LONG_LONG_INT | |
739 | HAVE_LONG_LONG_INT | |
1fd182f0 PE |
740 | NEXT_AS_FIRST_DIRECTIVE_STDDEF_H |
741 | NEXT_STDDEF_H | |
1fd182f0 PE |
742 | STDDEF_H |
743 | HAVE_WCHAR_T | |
744 | REPLACE_NULL | |
16c3e636 PE |
745 | HAVE__BOOL |
746 | STDBOOL_H | |
1fd182f0 PE |
747 | APPLE_UNIVERSAL_BUILD |
748 | REPLACE_TIMEGM | |
749 | REPLACE_NANOSLEEP | |
750 | REPLACE_MKTIME | |
751 | REPLACE_LOCALTIME_R | |
752 | HAVE_TIMEGM | |
753 | HAVE_STRPTIME | |
754 | HAVE_NANOSLEEP | |
755 | HAVE_DECL_LOCALTIME_R | |
756 | GNULIB_TIME_R | |
757 | GNULIB_TIMEGM | |
758 | GNULIB_STRPTIME | |
759 | GNULIB_NANOSLEEP | |
760 | GNULIB_MKTIME | |
e275c824 PE |
761 | LTLIBINTL |
762 | LIBINTL | |
763 | GETOPT_H | |
764 | HAVE_GETOPT_H | |
765 | NEXT_AS_FIRST_DIRECTIVE_GETOPT_H | |
766 | NEXT_GETOPT_H | |
767 | PRAGMA_COLUMNS | |
768 | PRAGMA_SYSTEM_HEADER | |
769 | INCLUDE_NEXT_AS_FIRST_DIRECTIVE | |
770 | INCLUDE_NEXT | |
771 | UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS | |
772 | UNISTD_H_HAVE_WINSOCK2_H | |
773 | REPLACE_WRITE | |
774 | REPLACE_USLEEP | |
775 | REPLACE_UNLINKAT | |
776 | REPLACE_UNLINK | |
777 | REPLACE_TTYNAME_R | |
778 | REPLACE_SYMLINK | |
779 | REPLACE_SLEEP | |
780 | REPLACE_RMDIR | |
781 | REPLACE_READLINK | |
782 | REPLACE_PWRITE | |
783 | REPLACE_PREAD | |
784 | REPLACE_LSEEK | |
785 | REPLACE_LINKAT | |
786 | REPLACE_LINK | |
787 | REPLACE_LCHOWN | |
788 | REPLACE_GETPAGESIZE | |
789 | REPLACE_GETGROUPS | |
790 | REPLACE_GETLOGIN_R | |
791 | REPLACE_GETDOMAINNAME | |
792 | REPLACE_GETCWD | |
793 | REPLACE_FCHOWNAT | |
794 | REPLACE_DUP2 | |
795 | REPLACE_DUP | |
796 | REPLACE_CLOSE | |
797 | REPLACE_CHOWN | |
798 | HAVE_SYS_PARAM_H | |
799 | HAVE_OS_H | |
800 | HAVE_DECL_TTYNAME_R | |
801 | HAVE_DECL_GETUSERSHELL | |
802 | HAVE_DECL_GETPAGESIZE | |
803 | HAVE_DECL_GETLOGIN_R | |
804 | HAVE_DECL_GETDOMAINNAME | |
805 | HAVE_DECL_FCHDIR | |
806 | HAVE_DECL_ENVIRON | |
807 | HAVE_USLEEP | |
808 | HAVE_UNLINKAT | |
809 | HAVE_SYMLINKAT | |
810 | HAVE_SYMLINK | |
811 | HAVE_SLEEP | |
812 | HAVE_READLINKAT | |
813 | HAVE_READLINK | |
814 | HAVE_PWRITE | |
815 | HAVE_PREAD | |
816 | HAVE_PIPE2 | |
817 | HAVE_PIPE | |
818 | HAVE_LINKAT | |
819 | HAVE_LINK | |
820 | HAVE_LCHOWN | |
821 | HAVE_GETPAGESIZE | |
822 | HAVE_GETLOGIN | |
823 | HAVE_GETHOSTNAME | |
824 | HAVE_GETGROUPS | |
825 | HAVE_GETDTABLESIZE | |
826 | HAVE_FTRUNCATE | |
827 | HAVE_FSYNC | |
828 | HAVE_FCHOWNAT | |
829 | HAVE_FCHDIR | |
830 | HAVE_FACCESSAT | |
831 | HAVE_EUIDACCESS | |
832 | HAVE_DUP3 | |
833 | HAVE_DUP2 | |
834 | HAVE_CHOWN | |
835 | GNULIB_WRITE | |
836 | GNULIB_USLEEP | |
837 | GNULIB_UNLINKAT | |
838 | GNULIB_UNLINK | |
839 | GNULIB_UNISTD_H_SIGPIPE | |
840 | GNULIB_UNISTD_H_GETOPT | |
841 | GNULIB_TTYNAME_R | |
842 | GNULIB_SYMLINKAT | |
843 | GNULIB_SYMLINK | |
844 | GNULIB_SLEEP | |
845 | GNULIB_RMDIR | |
846 | GNULIB_READLINKAT | |
847 | GNULIB_READLINK | |
848 | GNULIB_PWRITE | |
849 | GNULIB_PREAD | |
850 | GNULIB_PIPE2 | |
851 | GNULIB_PIPE | |
852 | GNULIB_LSEEK | |
853 | GNULIB_LINKAT | |
854 | GNULIB_LINK | |
855 | GNULIB_LCHOWN | |
856 | GNULIB_GETUSERSHELL | |
857 | GNULIB_GETPAGESIZE | |
858 | GNULIB_GETLOGIN_R | |
859 | GNULIB_GETLOGIN | |
860 | GNULIB_GETHOSTNAME | |
861 | GNULIB_GETGROUPS | |
862 | GNULIB_GETDTABLESIZE | |
863 | GNULIB_GETDOMAINNAME | |
864 | GNULIB_GETCWD | |
865 | GNULIB_FTRUNCATE | |
866 | GNULIB_FSYNC | |
867 | GNULIB_FCHOWNAT | |
868 | GNULIB_FCHDIR | |
869 | GNULIB_FACCESSAT | |
870 | GNULIB_EUIDACCESS | |
871 | GNULIB_ENVIRON | |
872 | GNULIB_DUP3 | |
873 | GNULIB_DUP2 | |
874 | GNULIB_CLOSE | |
875 | GNULIB_CHOWN | |
1f5d53eb PE |
876 | GETLOADAVG_LIBS |
877 | REPLACE_UNSETENV | |
878 | REPLACE_STRTOD | |
879 | REPLACE_SETENV | |
880 | REPLACE_REALPATH | |
881 | REPLACE_REALLOC | |
882 | REPLACE_PUTENV | |
883 | REPLACE_MKSTEMP | |
884 | REPLACE_MALLOC | |
885 | REPLACE_CANONICALIZE_FILE_NAME | |
886 | REPLACE_CALLOC | |
887 | HAVE_DECL_UNSETENV | |
888 | HAVE_UNLOCKPT | |
889 | HAVE_SYS_LOADAVG_H | |
890 | HAVE_STRUCT_RANDOM_DATA | |
891 | HAVE_STRTOULL | |
892 | HAVE_STRTOLL | |
893 | HAVE_STRTOD | |
894 | HAVE_DECL_SETENV | |
895 | HAVE_SETENV | |
896 | HAVE_RPMATCH | |
897 | HAVE_REALPATH | |
898 | HAVE_RANDOM_R | |
899 | HAVE_RANDOM_H | |
900 | HAVE_PTSNAME | |
901 | HAVE_MKSTEMPS | |
902 | HAVE_MKSTEMP | |
903 | HAVE_MKOSTEMPS | |
904 | HAVE_MKOSTEMP | |
905 | HAVE_MKDTEMP | |
906 | HAVE_GRANTPT | |
907 | HAVE_GETSUBOPT | |
908 | HAVE_DECL_GETLOADAVG | |
909 | HAVE_CANONICALIZE_FILE_NAME | |
910 | HAVE_ATOLL | |
911 | HAVE__EXIT | |
912 | GNULIB_UNSETENV | |
913 | GNULIB_UNLOCKPT | |
914 | GNULIB_SYSTEM_POSIX | |
915 | GNULIB_STRTOULL | |
916 | GNULIB_STRTOLL | |
917 | GNULIB_STRTOD | |
918 | GNULIB_SETENV | |
919 | GNULIB_RPMATCH | |
920 | GNULIB_REALPATH | |
921 | GNULIB_REALLOC_POSIX | |
922 | GNULIB_RANDOM_R | |
923 | GNULIB_PUTENV | |
924 | GNULIB_PTSNAME | |
925 | GNULIB_MKSTEMPS | |
926 | GNULIB_MKSTEMP | |
927 | GNULIB_MKOSTEMPS | |
928 | GNULIB_MKOSTEMP | |
929 | GNULIB_MKDTEMP | |
930 | GNULIB_MALLOC_POSIX | |
931 | GNULIB_GRANTPT | |
932 | GNULIB_GETSUBOPT | |
933 | GNULIB_GETLOADAVG | |
934 | GNULIB_CANONICALIZE_FILE_NAME | |
935 | GNULIB_CALLOC_POSIX | |
936 | GNULIB_ATOLL | |
937 | GNULIB__EXIT | |
743c80a7 PE |
938 | GL_COND_LIBTOOL_FALSE |
939 | GL_COND_LIBTOOL_TRUE | |
067d23c9 KY |
940 | BLESSMAIL_TARGET |
941 | LIBS_MAIL | |
942 | liblockfile | |
943 | ALLOCA | |
944 | LIBXML2_LIBS | |
945 | LIBXML2_CFLAGS | |
946 | LIBXSM | |
947 | LIBGPM | |
948 | LIBGIF | |
949 | LIBTIFF | |
950 | LIBPNG | |
951 | LIBJPEG | |
952 | LIBXPM | |
953 | FREETYPE_LIBS | |
954 | FREETYPE_CFLAGS | |
955 | M17N_FLT_LIBS | |
956 | M17N_FLT_CFLAGS | |
957 | LIBOTF_LIBS | |
958 | LIBOTF_CFLAGS | |
959 | XFT_LIBS | |
960 | XFT_CFLAGS | |
961 | FONTCONFIG_LIBS | |
962 | FONTCONFIG_CFLAGS | |
963 | LIBXMU | |
964 | LIBXTR6 | |
965 | LIBGNUTLS_LIBS | |
966 | LIBGNUTLS_CFLAGS | |
967 | LIBSELINUX_LIBS | |
968 | GCONF_LIBS | |
969 | GCONF_CFLAGS | |
970 | DBUS_OBJ | |
971 | DBUS_LIBS | |
972 | DBUS_CFLAGS | |
973 | GTK_OBJ | |
974 | GTK_LIBS | |
975 | GTK_CFLAGS | |
976 | IMAGEMAGICK_LIBS | |
977 | IMAGEMAGICK_CFLAGS | |
978 | RSVG_LIBS | |
979 | RSVG_CFLAGS | |
980 | VMLIMIT_OBJ | |
981 | GMALLOC_OBJ | |
982 | HAVE_XSERVER | |
983 | LIB_STANDARD | |
984 | NS_SUPPORT | |
00b3c7ac | 985 | NS_OBJC_OBJ |
067d23c9 KY |
986 | NS_OBJ |
987 | TEMACS_LDFLAGS2 | |
988 | LD_SWITCH_X_SITE_AUX_RPATH | |
989 | LD_SWITCH_X_SITE_AUX | |
990 | XMKMF | |
991 | DEPFLAGS | |
992 | MKDEPDIR | |
067d23c9 KY |
993 | CFLAGS_SOUND |
994 | ALSA_LIBS | |
995 | ALSA_CFLAGS | |
996 | PKG_CONFIG | |
997 | LIBSOUND | |
998 | START_FILES | |
999 | LIB_MATH | |
1000 | CRT_DIR | |
1001 | LIBS_SYSTEM | |
1002 | C_SWITCH_SYSTEM | |
1003 | UNEXEC_OBJ | |
1004 | C_SWITCH_MACHINE | |
1005 | LD_SWITCH_SYSTEM | |
1006 | CANNOT_DUMP | |
96f129d5 | 1007 | HAVE_MAKEINFO |
067d23c9 KY |
1008 | GZIP_PROG |
1009 | INSTALL_INFO | |
067d23c9 KY |
1010 | C_WARNINGS_SWITCH |
1011 | EGREP | |
1012 | GREP | |
1013 | CPP | |
743c80a7 PE |
1014 | RANLIB |
1015 | am__fastdepCC_FALSE | |
1016 | am__fastdepCC_TRUE | |
1017 | CCDEPMODE | |
1018 | AMDEPBACKSLASH | |
1019 | AMDEP_FALSE | |
1020 | AMDEP_TRUE | |
1021 | am__quote | |
1022 | am__include | |
1023 | DEPDIR | |
067d23c9 KY |
1024 | OBJEXT |
1025 | EXEEXT | |
1026 | ac_ct_CC | |
1027 | CPPFLAGS | |
1028 | LDFLAGS | |
1029 | CFLAGS | |
1030 | CC | |
1031 | host_os | |
1032 | host_vendor | |
1033 | host_cpu | |
1034 | host | |
1035 | build_os | |
1036 | build_vendor | |
1037 | build_cpu | |
1038 | build | |
1039 | PROFILING_CFLAGS | |
1040 | MAINT | |
1041 | GZIP_INFO | |
743c80a7 PE |
1042 | am__untar |
1043 | am__tar | |
1044 | AMTAR | |
1045 | am__leading_dot | |
1046 | SET_MAKE | |
1047 | AWK | |
1048 | mkdir_p | |
1049 | MKDIR_P | |
1050 | INSTALL_STRIP_PROGRAM | |
1051 | STRIP | |
1052 | install_sh | |
1053 | MAKEINFO | |
1054 | AUTOHEADER | |
1055 | AUTOMAKE | |
1056 | AUTOCONF | |
1057 | ACLOCAL | |
1058 | VERSION | |
1059 | PACKAGE | |
1060 | CYGPATH_W | |
1061 | am__isrc | |
1062 | INSTALL_DATA | |
1063 | INSTALL_SCRIPT | |
1064 | INSTALL_PROGRAM | |
067d23c9 KY |
1065 | target_alias |
1066 | host_alias | |
1067 | build_alias | |
1068 | LIBS | |
1069 | ECHO_T | |
1070 | ECHO_N | |
1071 | ECHO_C | |
1072 | DEFS | |
1073 | mandir | |
1074 | localedir | |
1075 | libdir | |
1076 | psdir | |
1077 | pdfdir | |
1078 | dvidir | |
1079 | htmldir | |
1080 | infodir | |
1081 | docdir | |
1082 | oldincludedir | |
1083 | includedir | |
1084 | localstatedir | |
1085 | sharedstatedir | |
1086 | sysconfdir | |
1087 | datadir | |
1088 | datarootdir | |
1089 | libexecdir | |
1090 | sbindir | |
1091 | bindir | |
1092 | program_transform_name | |
1093 | prefix | |
1094 | exec_prefix | |
1095 | PACKAGE_URL | |
1096 | PACKAGE_BUGREPORT | |
1097 | PACKAGE_STRING | |
1098 | PACKAGE_VERSION | |
1099 | PACKAGE_TARNAME | |
1100 | PACKAGE_NAME | |
1101 | PATH_SEPARATOR | |
1102 | SHELL' | |
1103 | ac_subst_files='deps_frag | |
1104 | ns_frag' | |
1105 | ac_user_opts=' | |
1106 | enable_option_checking | |
1107 | with_pop | |
1108 | with_kerberos | |
1109 | with_kerberos5 | |
1110 | with_hesiod | |
1111 | with_mmdf | |
1112 | with_mail_unlink | |
1113 | with_mailhost | |
1114 | with_sound | |
1115 | with_sync_input | |
1116 | with_x_toolkit | |
1117 | with_xpm | |
1118 | with_jpeg | |
1119 | with_tiff | |
1120 | with_gif | |
1121 | with_png | |
1122 | with_rsvg | |
1123 | with_xml2 | |
1124 | with_imagemagick | |
1125 | with_xft | |
1126 | with_libotf | |
1127 | with_m17n_flt | |
1128 | with_toolkit_scroll_bars | |
1129 | with_xaw3d | |
1130 | with_xim | |
1131 | with_ns | |
1132 | with_gpm | |
1133 | with_dbus | |
1134 | with_gconf | |
1135 | with_selinux | |
1136 | with_gnutls | |
1137 | with_makeinfo | |
1138 | with_compress_info | |
1139 | with_pkg_config_prog | |
1140 | with_crt_dir | |
4fc5868a | 1141 | with_gameuser |
067d23c9 KY |
1142 | with_gnustep_conf |
1143 | enable_ns_self_contained | |
1144 | enable_asserts | |
1145 | enable_maintainer_mode | |
1146 | enable_locallisppath | |
1147 | enable_checking | |
1148 | enable_use_lisp_union_type | |
1149 | enable_profiling | |
1150 | enable_autodepend | |
743c80a7 | 1151 | enable_dependency_tracking |
067d23c9 KY |
1152 | enable_largefile |
1153 | with_x | |
1154 | ' | |
1155 | ac_precious_vars='build_alias | |
1156 | host_alias | |
1157 | target_alias | |
1158 | CC | |
1159 | CFLAGS | |
1160 | LDFLAGS | |
1161 | LIBS | |
1162 | CPPFLAGS | |
1163 | CPP | |
1f5d53eb PE |
1164 | CPPFLAGS |
1165 | CPP | |
1166 | CPPFLAGS | |
067d23c9 KY |
1167 | XMKMF' |
1168 | ||
1169 | ||
1170 | # Initialize some variables set by options. | |
1171 | ac_init_help= | |
1172 | ac_init_version=false | |
1173 | ac_unrecognized_opts= | |
1174 | ac_unrecognized_sep= | |
1175 | # The variables have the same names as the options, with | |
1176 | # dashes changed to underlines. | |
1177 | cache_file=/dev/null | |
1178 | exec_prefix=NONE | |
1179 | no_create= | |
1180 | no_recursion= | |
1181 | prefix=NONE | |
1182 | program_prefix=NONE | |
1183 | program_suffix=NONE | |
1184 | program_transform_name=s,x,x, | |
1185 | silent= | |
1186 | site= | |
1187 | srcdir= | |
1188 | verbose= | |
1189 | x_includes=NONE | |
1190 | x_libraries=NONE | |
1191 | ||
1192 | # Installation directory options. | |
1193 | # These are left unexpanded so users can "make install exec_prefix=/foo" | |
1194 | # and all the variables that are supposed to be based on exec_prefix | |
1195 | # by default will actually change. | |
1196 | # Use braces instead of parens because sh, perl, etc. also accept them. | |
1197 | # (The list follows the same order as the GNU Coding Standards.) | |
1198 | bindir='${exec_prefix}/bin' | |
1199 | sbindir='${exec_prefix}/sbin' | |
1200 | libexecdir='${exec_prefix}/libexec' | |
1201 | datarootdir='${prefix}/share' | |
1202 | datadir='${datarootdir}' | |
1203 | sysconfdir='${prefix}/etc' | |
1204 | sharedstatedir='${prefix}/com' | |
1205 | localstatedir='${prefix}/var' | |
1206 | includedir='${prefix}/include' | |
1207 | oldincludedir='/usr/include' | |
1208 | docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' | |
1209 | infodir='${datarootdir}/info' | |
1210 | htmldir='${docdir}' | |
1211 | dvidir='${docdir}' | |
1212 | pdfdir='${docdir}' | |
1213 | psdir='${docdir}' | |
1214 | libdir='${exec_prefix}/lib' | |
1215 | localedir='${datarootdir}/locale' | |
1216 | mandir='${datarootdir}/man' | |
1217 | ||
1218 | ac_prev= | |
1219 | ac_dashdash= | |
1220 | for ac_option | |
1221 | do | |
1222 | # If the previous option needs an argument, assign it. | |
1223 | if test -n "$ac_prev"; then | |
1224 | eval $ac_prev=\$ac_option | |
1225 | ac_prev= | |
1226 | continue | |
1227 | fi | |
1228 | ||
1229 | case $ac_option in | |
2018939f AS |
1230 | *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; |
1231 | *=) ac_optarg= ;; | |
1232 | *) ac_optarg=yes ;; | |
067d23c9 KY |
1233 | esac |
1234 | ||
1235 | # Accept the important Cygnus configure options, so we can diagnose typos. | |
1236 | ||
1237 | case $ac_dashdash$ac_option in | |
1238 | --) | |
1239 | ac_dashdash=yes ;; | |
1240 | ||
1241 | -bindir | --bindir | --bindi | --bind | --bin | --bi) | |
1242 | ac_prev=bindir ;; | |
1243 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) | |
1244 | bindir=$ac_optarg ;; | |
1245 | ||
1246 | -build | --build | --buil | --bui | --bu) | |
1247 | ac_prev=build_alias ;; | |
1248 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) | |
1249 | build_alias=$ac_optarg ;; | |
1250 | ||
1251 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
1252 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
1253 | ac_prev=cache_file ;; | |
1254 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
1255 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) | |
1256 | cache_file=$ac_optarg ;; | |
1257 | ||
1258 | --config-cache | -C) | |
1259 | cache_file=config.cache ;; | |
1260 | ||
1261 | -datadir | --datadir | --datadi | --datad) | |
1262 | ac_prev=datadir ;; | |
1263 | -datadir=* | --datadir=* | --datadi=* | --datad=*) | |
1264 | datadir=$ac_optarg ;; | |
1265 | ||
1266 | -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ | |
1267 | | --dataroo | --dataro | --datar) | |
1268 | ac_prev=datarootdir ;; | |
1269 | -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | |
1270 | | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) | |
1271 | datarootdir=$ac_optarg ;; | |
1272 | ||
1273 | -disable-* | --disable-*) | |
1274 | ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` | |
1275 | # Reject names that are not valid shell variable names. | |
1276 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && | |
2018939f | 1277 | as_fn_error $? "invalid feature name: $ac_useropt" |
067d23c9 KY |
1278 | ac_useropt_orig=$ac_useropt |
1279 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
1280 | case $ac_user_opts in | |
1281 | *" | |
1282 | "enable_$ac_useropt" | |
1283 | "*) ;; | |
1284 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" | |
1285 | ac_unrecognized_sep=', ';; | |
1286 | esac | |
1287 | eval enable_$ac_useropt=no ;; | |
1288 | ||
1289 | -docdir | --docdir | --docdi | --doc | --do) | |
1290 | ac_prev=docdir ;; | |
1291 | -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) | |
1292 | docdir=$ac_optarg ;; | |
1293 | ||
1294 | -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) | |
1295 | ac_prev=dvidir ;; | |
1296 | -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) | |
1297 | dvidir=$ac_optarg ;; | |
1298 | ||
1299 | -enable-* | --enable-*) | |
1300 | ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` | |
1301 | # Reject names that are not valid shell variable names. | |
1302 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && | |
2018939f | 1303 | as_fn_error $? "invalid feature name: $ac_useropt" |
067d23c9 KY |
1304 | ac_useropt_orig=$ac_useropt |
1305 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
1306 | case $ac_user_opts in | |
1307 | *" | |
1308 | "enable_$ac_useropt" | |
1309 | "*) ;; | |
1310 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" | |
1311 | ac_unrecognized_sep=', ';; | |
1312 | esac | |
1313 | eval enable_$ac_useropt=\$ac_optarg ;; | |
1314 | ||
1315 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | |
1316 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | |
1317 | | --exec | --exe | --ex) | |
1318 | ac_prev=exec_prefix ;; | |
1319 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | |
1320 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | |
1321 | | --exec=* | --exe=* | --ex=*) | |
1322 | exec_prefix=$ac_optarg ;; | |
1323 | ||
1324 | -gas | --gas | --ga | --g) | |
1325 | # Obsolete; use --with-gas. | |
1326 | with_gas=yes ;; | |
1327 | ||
1328 | -help | --help | --hel | --he | -h) | |
1329 | ac_init_help=long ;; | |
1330 | -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) | |
1331 | ac_init_help=recursive ;; | |
1332 | -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) | |
1333 | ac_init_help=short ;; | |
1334 | ||
1335 | -host | --host | --hos | --ho) | |
1336 | ac_prev=host_alias ;; | |
1337 | -host=* | --host=* | --hos=* | --ho=*) | |
1338 | host_alias=$ac_optarg ;; | |
1339 | ||
1340 | -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) | |
1341 | ac_prev=htmldir ;; | |
1342 | -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | |
1343 | | --ht=*) | |
1344 | htmldir=$ac_optarg ;; | |
1345 | ||
1346 | -includedir | --includedir | --includedi | --included | --include \ | |
1347 | | --includ | --inclu | --incl | --inc) | |
1348 | ac_prev=includedir ;; | |
1349 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | |
1350 | | --includ=* | --inclu=* | --incl=* | --inc=*) | |
1351 | includedir=$ac_optarg ;; | |
1352 | ||
1353 | -infodir | --infodir | --infodi | --infod | --info | --inf) | |
1354 | ac_prev=infodir ;; | |
1355 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) | |
1356 | infodir=$ac_optarg ;; | |
1357 | ||
1358 | -libdir | --libdir | --libdi | --libd) | |
1359 | ac_prev=libdir ;; | |
1360 | -libdir=* | --libdir=* | --libdi=* | --libd=*) | |
1361 | libdir=$ac_optarg ;; | |
1362 | ||
1363 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | |
1364 | | --libexe | --libex | --libe) | |
1365 | ac_prev=libexecdir ;; | |
1366 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | |
1367 | | --libexe=* | --libex=* | --libe=*) | |
1368 | libexecdir=$ac_optarg ;; | |
1369 | ||
1370 | -localedir | --localedir | --localedi | --localed | --locale) | |
1371 | ac_prev=localedir ;; | |
1372 | -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) | |
1373 | localedir=$ac_optarg ;; | |
1374 | ||
1375 | -localstatedir | --localstatedir | --localstatedi | --localstated \ | |
1376 | | --localstate | --localstat | --localsta | --localst | --locals) | |
1377 | ac_prev=localstatedir ;; | |
1378 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | |
1379 | | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) | |
1380 | localstatedir=$ac_optarg ;; | |
1381 | ||
1382 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) | |
1383 | ac_prev=mandir ;; | |
1384 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) | |
1385 | mandir=$ac_optarg ;; | |
1386 | ||
1387 | -nfp | --nfp | --nf) | |
1388 | # Obsolete; use --without-fp. | |
1389 | with_fp=no ;; | |
1390 | ||
1391 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
1392 | | --no-cr | --no-c | -n) | |
1393 | no_create=yes ;; | |
1394 | ||
1395 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
1396 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) | |
1397 | no_recursion=yes ;; | |
1398 | ||
1399 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | |
1400 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | |
1401 | | --oldin | --oldi | --old | --ol | --o) | |
1402 | ac_prev=oldincludedir ;; | |
1403 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | |
1404 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | |
1405 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) | |
1406 | oldincludedir=$ac_optarg ;; | |
1407 | ||
1408 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) | |
1409 | ac_prev=prefix ;; | |
1410 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) | |
1411 | prefix=$ac_optarg ;; | |
1412 | ||
1413 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ | |
1414 | | --program-pre | --program-pr | --program-p) | |
1415 | ac_prev=program_prefix ;; | |
1416 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ | |
1417 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) | |
1418 | program_prefix=$ac_optarg ;; | |
1419 | ||
1420 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ | |
1421 | | --program-suf | --program-su | --program-s) | |
1422 | ac_prev=program_suffix ;; | |
1423 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ | |
1424 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) | |
1425 | program_suffix=$ac_optarg ;; | |
1426 | ||
1427 | -program-transform-name | --program-transform-name \ | |
1428 | | --program-transform-nam | --program-transform-na \ | |
1429 | | --program-transform-n | --program-transform- \ | |
1430 | | --program-transform | --program-transfor \ | |
1431 | | --program-transfo | --program-transf \ | |
1432 | | --program-trans | --program-tran \ | |
1433 | | --progr-tra | --program-tr | --program-t) | |
1434 | ac_prev=program_transform_name ;; | |
1435 | -program-transform-name=* | --program-transform-name=* \ | |
1436 | | --program-transform-nam=* | --program-transform-na=* \ | |
1437 | | --program-transform-n=* | --program-transform-=* \ | |
1438 | | --program-transform=* | --program-transfor=* \ | |
1439 | | --program-transfo=* | --program-transf=* \ | |
1440 | | --program-trans=* | --program-tran=* \ | |
1441 | | --progr-tra=* | --program-tr=* | --program-t=*) | |
1442 | program_transform_name=$ac_optarg ;; | |
1443 | ||
1444 | -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) | |
1445 | ac_prev=pdfdir ;; | |
1446 | -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) | |
1447 | pdfdir=$ac_optarg ;; | |
1448 | ||
1449 | -psdir | --psdir | --psdi | --psd | --ps) | |
1450 | ac_prev=psdir ;; | |
1451 | -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) | |
1452 | psdir=$ac_optarg ;; | |
1453 | ||
1454 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | |
1455 | | -silent | --silent | --silen | --sile | --sil) | |
1456 | silent=yes ;; | |
1457 | ||
1458 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) | |
1459 | ac_prev=sbindir ;; | |
1460 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | |
1461 | | --sbi=* | --sb=*) | |
1462 | sbindir=$ac_optarg ;; | |
1463 | ||
1464 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ | |
1465 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | |
1466 | | --sharedst | --shareds | --shared | --share | --shar \ | |
1467 | | --sha | --sh) | |
1468 | ac_prev=sharedstatedir ;; | |
1469 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | |
1470 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | |
1471 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | |
1472 | | --sha=* | --sh=*) | |
1473 | sharedstatedir=$ac_optarg ;; | |
1474 | ||
1475 | -site | --site | --sit) | |
1476 | ac_prev=site ;; | |
1477 | -site=* | --site=* | --sit=*) | |
1478 | site=$ac_optarg ;; | |
1479 | ||
1480 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) | |
1481 | ac_prev=srcdir ;; | |
1482 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
1483 | srcdir=$ac_optarg ;; | |
1484 | ||
1485 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | |
1486 | | --syscon | --sysco | --sysc | --sys | --sy) | |
1487 | ac_prev=sysconfdir ;; | |
1488 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | |
1489 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) | |
1490 | sysconfdir=$ac_optarg ;; | |
1491 | ||
1492 | -target | --target | --targe | --targ | --tar | --ta | --t) | |
1493 | ac_prev=target_alias ;; | |
1494 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) | |
1495 | target_alias=$ac_optarg ;; | |
1496 | ||
1497 | -v | -verbose | --verbose | --verbos | --verbo | --verb) | |
1498 | verbose=yes ;; | |
1499 | ||
1500 | -version | --version | --versio | --versi | --vers | -V) | |
1501 | ac_init_version=: ;; | |
1502 | ||
1503 | -with-* | --with-*) | |
1504 | ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` | |
1505 | # Reject names that are not valid shell variable names. | |
1506 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && | |
2018939f | 1507 | as_fn_error $? "invalid package name: $ac_useropt" |
067d23c9 KY |
1508 | ac_useropt_orig=$ac_useropt |
1509 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
1510 | case $ac_user_opts in | |
1511 | *" | |
1512 | "with_$ac_useropt" | |
1513 | "*) ;; | |
1514 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" | |
1515 | ac_unrecognized_sep=', ';; | |
1516 | esac | |
1517 | eval with_$ac_useropt=\$ac_optarg ;; | |
1518 | ||
1519 | -without-* | --without-*) | |
1520 | ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` | |
1521 | # Reject names that are not valid shell variable names. | |
1522 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && | |
2018939f | 1523 | as_fn_error $? "invalid package name: $ac_useropt" |
067d23c9 KY |
1524 | ac_useropt_orig=$ac_useropt |
1525 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
1526 | case $ac_user_opts in | |
1527 | *" | |
1528 | "with_$ac_useropt" | |
1529 | "*) ;; | |
1530 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" | |
1531 | ac_unrecognized_sep=', ';; | |
1532 | esac | |
1533 | eval with_$ac_useropt=no ;; | |
1534 | ||
1535 | --x) | |
1536 | # Obsolete; use --with-x. | |
1537 | with_x=yes ;; | |
1538 | ||
1539 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | |
1540 | | --x-incl | --x-inc | --x-in | --x-i) | |
1541 | ac_prev=x_includes ;; | |
1542 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | |
1543 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) | |
1544 | x_includes=$ac_optarg ;; | |
1545 | ||
1546 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ | |
1547 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) | |
1548 | ac_prev=x_libraries ;; | |
1549 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | |
1550 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) | |
1551 | x_libraries=$ac_optarg ;; | |
1552 | ||
2018939f AS |
1553 | -*) as_fn_error $? "unrecognized option: \`$ac_option' |
1554 | Try \`$0 --help' for more information" | |
067d23c9 KY |
1555 | ;; |
1556 | ||
1557 | *=*) | |
1558 | ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` | |
1559 | # Reject names that are not valid shell variable names. | |
1560 | case $ac_envvar in #( | |
1561 | '' | [0-9]* | *[!_$as_cr_alnum]* ) | |
2018939f | 1562 | as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; |
067d23c9 KY |
1563 | esac |
1564 | eval $ac_envvar=\$ac_optarg | |
1565 | export $ac_envvar ;; | |
1566 | ||
1567 | *) | |
1568 | # FIXME: should be removed in autoconf 3.0. | |
1569 | $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 | |
1570 | expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && | |
1571 | $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 | |
d6974efa | 1572 | : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" |
067d23c9 KY |
1573 | ;; |
1574 | ||
1575 | esac | |
1576 | done | |
1577 | ||
1578 | if test -n "$ac_prev"; then | |
1579 | ac_option=--`echo $ac_prev | sed 's/_/-/g'` | |
2018939f | 1580 | as_fn_error $? "missing argument to $ac_option" |
067d23c9 KY |
1581 | fi |
1582 | ||
1583 | if test -n "$ac_unrecognized_opts"; then | |
1584 | case $enable_option_checking in | |
1585 | no) ;; | |
2018939f | 1586 | fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; |
067d23c9 KY |
1587 | *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; |
1588 | esac | |
1589 | fi | |
1590 | ||
1591 | # Check all directory arguments for consistency. | |
1592 | for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ | |
1593 | datadir sysconfdir sharedstatedir localstatedir includedir \ | |
1594 | oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ | |
1595 | libdir localedir mandir | |
1596 | do | |
1597 | eval ac_val=\$$ac_var | |
1598 | # Remove trailing slashes. | |
1599 | case $ac_val in | |
1600 | */ ) | |
1601 | ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` | |
1602 | eval $ac_var=\$ac_val;; | |
1603 | esac | |
1604 | # Be sure to have absolute directory names. | |
1605 | case $ac_val in | |
1606 | [\\/$]* | ?:[\\/]* ) continue;; | |
1607 | NONE | '' ) case $ac_var in *prefix ) continue;; esac;; | |
1608 | esac | |
2018939f | 1609 | as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" |
067d23c9 KY |
1610 | done |
1611 | ||
1612 | # There might be people who depend on the old broken behavior: `$host' | |
1613 | # used to hold the argument of --host etc. | |
1614 | # FIXME: To remove some day. | |
1615 | build=$build_alias | |
1616 | host=$host_alias | |
1617 | target=$target_alias | |
1618 | ||
1619 | # FIXME: To remove some day. | |
1620 | if test "x$host_alias" != x; then | |
1621 | if test "x$build_alias" = x; then | |
1622 | cross_compiling=maybe | |
2018939f AS |
1623 | $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host. |
1624 | If a cross compiler is detected then cross compile mode will be used" >&2 | |
067d23c9 KY |
1625 | elif test "x$build_alias" != "x$host_alias"; then |
1626 | cross_compiling=yes | |
1627 | fi | |
1628 | fi | |
1629 | ||
1630 | ac_tool_prefix= | |
1631 | test -n "$host_alias" && ac_tool_prefix=$host_alias- | |
1632 | ||
1633 | test "$silent" = yes && exec 6>/dev/null | |
1634 | ||
1635 | ||
1636 | ac_pwd=`pwd` && test -n "$ac_pwd" && | |
1637 | ac_ls_di=`ls -di .` && | |
1638 | ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || | |
2018939f | 1639 | as_fn_error $? "working directory cannot be determined" |
067d23c9 | 1640 | test "X$ac_ls_di" = "X$ac_pwd_ls_di" || |
2018939f | 1641 | as_fn_error $? "pwd does not report name of working directory" |
067d23c9 KY |
1642 | |
1643 | ||
1644 | # Find the source files, if location was not specified. | |
1645 | if test -z "$srcdir"; then | |
1646 | ac_srcdir_defaulted=yes | |
1647 | # Try the directory containing this script, then the parent directory. | |
1648 | ac_confdir=`$as_dirname -- "$as_myself" || | |
1649 | $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
1650 | X"$as_myself" : 'X\(//\)[^/]' \| \ | |
1651 | X"$as_myself" : 'X\(//\)$' \| \ | |
1652 | X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || | |
1653 | $as_echo X"$as_myself" | | |
1654 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
1655 | s//\1/ | |
1656 | q | |
1657 | } | |
1658 | /^X\(\/\/\)[^/].*/{ | |
1659 | s//\1/ | |
1660 | q | |
1661 | } | |
1662 | /^X\(\/\/\)$/{ | |
1663 | s//\1/ | |
1664 | q | |
1665 | } | |
1666 | /^X\(\/\).*/{ | |
1667 | s//\1/ | |
1668 | q | |
1669 | } | |
1670 | s/.*/./; q'` | |
1671 | srcdir=$ac_confdir | |
1672 | if test ! -r "$srcdir/$ac_unique_file"; then | |
1673 | srcdir=.. | |
1674 | fi | |
1675 | else | |
1676 | ac_srcdir_defaulted=no | |
1677 | fi | |
1678 | if test ! -r "$srcdir/$ac_unique_file"; then | |
1679 | test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." | |
2018939f | 1680 | as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" |
067d23c9 KY |
1681 | fi |
1682 | ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" | |
1683 | ac_abs_confdir=`( | |
2018939f | 1684 | cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" |
067d23c9 KY |
1685 | pwd)` |
1686 | # When building in place, set srcdir=. | |
1687 | if test "$ac_abs_confdir" = "$ac_pwd"; then | |
1688 | srcdir=. | |
1689 | fi | |
1690 | # Remove unnecessary trailing slashes from srcdir. | |
1691 | # Double slashes in file names in object file debugging info | |
1692 | # mess up M-x gdb in Emacs. | |
1693 | case $srcdir in | |
1694 | */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; | |
1695 | esac | |
1696 | for ac_var in $ac_precious_vars; do | |
1697 | eval ac_env_${ac_var}_set=\${${ac_var}+set} | |
1698 | eval ac_env_${ac_var}_value=\$${ac_var} | |
1699 | eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} | |
1700 | eval ac_cv_env_${ac_var}_value=\$${ac_var} | |
1701 | done | |
1702 | ||
1703 | # | |
1704 | # Report the --help message. | |
1705 | # | |
1706 | if test "$ac_init_help" = "long"; then | |
1707 | # Omit some internal or obsolete options to make the list less imposing. | |
1708 | # This message is too long to be a string in the A/UX 3.1 sh. | |
1709 | cat <<_ACEOF | |
1710 | \`configure' configures emacs 24.0.50 to adapt to many kinds of systems. | |
1711 | ||
1712 | Usage: $0 [OPTION]... [VAR=VALUE]... | |
1713 | ||
1714 | To assign environment variables (e.g., CC, CFLAGS...), specify them as | |
1715 | VAR=VALUE. See below for descriptions of some of the useful variables. | |
1716 | ||
1717 | Defaults for the options are specified in brackets. | |
1718 | ||
1719 | Configuration: | |
1720 | -h, --help display this help and exit | |
1721 | --help=short display options specific to this package | |
1722 | --help=recursive display the short help of all the included packages | |
1723 | -V, --version display version information and exit | |
2018939f | 1724 | -q, --quiet, --silent do not print \`checking ...' messages |
067d23c9 KY |
1725 | --cache-file=FILE cache test results in FILE [disabled] |
1726 | -C, --config-cache alias for \`--cache-file=config.cache' | |
1727 | -n, --no-create do not create output files | |
1728 | --srcdir=DIR find the sources in DIR [configure dir or \`..'] | |
1729 | ||
1730 | Installation directories: | |
1731 | --prefix=PREFIX install architecture-independent files in PREFIX | |
1732 | [$ac_default_prefix] | |
1733 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX | |
1734 | [PREFIX] | |
1735 | ||
1736 | By default, \`make install' will install all the files in | |
1737 | \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify | |
1738 | an installation prefix other than \`$ac_default_prefix' using \`--prefix', | |
1739 | for instance \`--prefix=\$HOME'. | |
1740 | ||
1741 | For better control, use the options below. | |
1742 | ||
1743 | Fine tuning of the installation directories: | |
1744 | --bindir=DIR user executables [EPREFIX/bin] | |
1745 | --sbindir=DIR system admin executables [EPREFIX/sbin] | |
1746 | --libexecdir=DIR program executables [EPREFIX/libexec] | |
1747 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] | |
1748 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] | |
1749 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] | |
1750 | --libdir=DIR object code libraries [EPREFIX/lib] | |
1751 | --includedir=DIR C header files [PREFIX/include] | |
1752 | --oldincludedir=DIR C header files for non-gcc [/usr/include] | |
1753 | --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] | |
1754 | --datadir=DIR read-only architecture-independent data [DATAROOTDIR] | |
1755 | --infodir=DIR info documentation [DATAROOTDIR/info] | |
1756 | --localedir=DIR locale-dependent data [DATAROOTDIR/locale] | |
1757 | --mandir=DIR man documentation [DATAROOTDIR/man] | |
1758 | --docdir=DIR documentation root [DATAROOTDIR/doc/emacs] | |
1759 | --htmldir=DIR html documentation [DOCDIR] | |
1760 | --dvidir=DIR dvi documentation [DOCDIR] | |
1761 | --pdfdir=DIR pdf documentation [DOCDIR] | |
1762 | --psdir=DIR ps documentation [DOCDIR] | |
1763 | _ACEOF | |
1764 | ||
1765 | cat <<\_ACEOF | |
1766 | ||
1767 | Program names: | |
1768 | --program-prefix=PREFIX prepend PREFIX to installed program names | |
1769 | --program-suffix=SUFFIX append SUFFIX to installed program names | |
1770 | --program-transform-name=PROGRAM run sed PROGRAM on installed program names | |
1771 | ||
1772 | X features: | |
1773 | --x-includes=DIR X include files are in DIR | |
1774 | --x-libraries=DIR X library files are in DIR | |
1775 | ||
1776 | System types: | |
1777 | --build=BUILD configure for building on BUILD [guessed] | |
1778 | --host=HOST cross-compile to build programs to run on HOST [BUILD] | |
1779 | _ACEOF | |
1780 | fi | |
1781 | ||
1782 | if test -n "$ac_init_help"; then | |
1783 | case $ac_init_help in | |
1784 | short | recursive ) echo "Configuration of emacs 24.0.50:";; | |
1785 | esac | |
1786 | cat <<\_ACEOF | |
1787 | ||
1788 | Optional Features: | |
1789 | --disable-option-checking ignore unrecognized --enable/--with options | |
1790 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) | |
1791 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] | |
1792 | --disable-ns-self-contained | |
1793 | disable self contained build under NeXTstep | |
1794 | --enable-asserts compile code with asserts enabled | |
1795 | --enable-maintainer-mode | |
1796 | enable make rules and dependencies not useful (and | |
1797 | sometimes confusing) to the casual installer | |
1798 | --enable-locallisppath=PATH | |
1799 | directories Emacs should search for lisp files | |
1800 | specific to this site | |
1801 | --enable-checking[=LIST] | |
1802 | enable expensive run-time checks. With LIST, enable | |
1803 | only specific categories of checks. Categories are: | |
1804 | all,yes,no. Flags are: stringbytes, stringoverrun, | |
1805 | stringfreelist, xmallocoverrun, conslist | |
1806 | --enable-use-lisp-union-type | |
1807 | use a union for the Lisp_Object data type. This is | |
1808 | only useful for development for catching certain | |
1809 | types of bugs. | |
1810 | --enable-profiling build emacs with profiling support. This might not | |
1811 | work on all platforms | |
1812 | --enable-autodepend automatically generate dependencies to .h-files. | |
1813 | Requires GNU Make and Gcc. Enabled if GNU Make and | |
1814 | Gcc is found | |
743c80a7 PE |
1815 | --disable-dependency-tracking speeds up one-time build |
1816 | --enable-dependency-tracking do not reject slow dependency extractors | |
067d23c9 KY |
1817 | --disable-largefile omit support for large files |
1818 | ||
1819 | Optional Packages: | |
1820 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] | |
1821 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) | |
1822 | --without-pop don't support POP mail retrieval with movemail | |
1823 | --with-kerberos support Kerberos-authenticated POP | |
1824 | --with-kerberos5 support Kerberos version 5 authenticated POP | |
1825 | --with-hesiod support Hesiod to get the POP server host | |
1826 | --with-mmdf support MMDF mailboxes | |
1827 | --with-mail-unlink unlink, rather than empty, mail spool after reading | |
1828 | --with-mailhost=HOSTNAME | |
1829 | string giving default POP mail host | |
1830 | --without-sound don't compile with sound support | |
1831 | --without-sync-input process async input synchronously | |
1832 | --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk3, | |
1833 | lucid or athena, motif, no) | |
1834 | --without-xpm don't compile with XPM image support | |
1835 | --without-jpeg don't compile with JPEG image support | |
1836 | --without-tiff don't compile with TIFF image support | |
1837 | --without-gif don't compile with GIF image support | |
1838 | --without-png don't compile with PNG image support | |
1839 | --without-rsvg don't compile with SVG image support | |
1840 | --without-xml2 don't compile with XML parsing support | |
1841 | --without-imagemagick don't compile with ImageMagick image support | |
1842 | --without-xft don't use XFT for anti aliased fonts | |
1843 | --without-libotf don't use libotf for OpenType font support | |
1844 | --without-m17n-flt don't use m17n-flt for text shaping | |
1845 | --without-toolkit-scroll-bars | |
1846 | don't use Motif or Xaw3d scroll bars | |
1847 | --without-xaw3d don't use Xaw3d | |
1848 | --without-xim don't use X11 XIM | |
1849 | --with-ns use nextstep (Cocoa or GNUstep) windowing system | |
1850 | --without-gpm don't use -lgpm for mouse support on a GNU/Linux | |
1851 | console | |
1852 | --without-dbus don't compile with D-Bus support | |
1853 | --without-gconf don't compile with GConf support | |
1854 | --without-selinux don't compile with SELinux support | |
1855 | --without-gnutls don't use -lgnutls for SSL/TLS support | |
1856 | --without-makeinfo don't require makeinfo for building manuals | |
1857 | --without-compress-info don't compress the installed Info pages | |
1858 | --with-pkg-config-prog=PATH | |
1859 | path to pkg-config for finding GTK and librsvg | |
1860 | --with-crt-dir=DIR directory containing crtn.o etc. The default is | |
1861 | /usr/lib, or /usr/lib64 on some platforms. | |
4fc5868a | 1862 | --with-gameuser=USER user for shared game score files |
067d23c9 KY |
1863 | --with-gnustep-conf=PATH |
1864 | path to GNUstep.conf; default $GNUSTEP_CONFIG_FILE, | |
1865 | or /etc/GNUstep/GNUstep.conf | |
1866 | --with-x use the X Window System | |
1867 | ||
1868 | Some influential environment variables: | |
1869 | CC C compiler command | |
1870 | CFLAGS C compiler flags | |
1871 | LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a | |
1872 | nonstandard directory <lib dir> | |
1873 | LIBS libraries to pass to the linker, e.g. -l<library> | |
1874 | CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if | |
1875 | you have headers in a nonstandard directory <include dir> | |
1876 | CPP C preprocessor | |
1877 | XMKMF Path to xmkmf, Makefile generator for X Window System | |
1878 | ||
1879 | Use these variables to override the choices made by `configure' or to help | |
1880 | it to find libraries and programs with nonstandard names/locations. | |
1881 | ||
1882 | Report bugs to the package provider. | |
1883 | _ACEOF | |
1884 | ac_status=$? | |
1885 | fi | |
1886 | ||
1887 | if test "$ac_init_help" = "recursive"; then | |
1888 | # If there are subdirs, report their specific --help. | |
1889 | for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue | |
1890 | test -d "$ac_dir" || | |
1891 | { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || | |
1892 | continue | |
1893 | ac_builddir=. | |
1894 | ||
1895 | case "$ac_dir" in | |
1896 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
1897 | *) | |
1898 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` | |
1899 | # A ".." for each directory in $ac_dir_suffix. | |
1900 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` | |
1901 | case $ac_top_builddir_sub in | |
1902 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
1903 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; | |
1904 | esac ;; | |
1905 | esac | |
1906 | ac_abs_top_builddir=$ac_pwd | |
1907 | ac_abs_builddir=$ac_pwd$ac_dir_suffix | |
1908 | # for backward compatibility: | |
1909 | ac_top_builddir=$ac_top_build_prefix | |
1910 | ||
1911 | case $srcdir in | |
1912 | .) # We are building in place. | |
1913 | ac_srcdir=. | |
1914 | ac_top_srcdir=$ac_top_builddir_sub | |
1915 | ac_abs_top_srcdir=$ac_pwd ;; | |
1916 | [\\/]* | ?:[\\/]* ) # Absolute name. | |
1917 | ac_srcdir=$srcdir$ac_dir_suffix; | |
1918 | ac_top_srcdir=$srcdir | |
1919 | ac_abs_top_srcdir=$srcdir ;; | |
1920 | *) # Relative name. | |
1921 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix | |
1922 | ac_top_srcdir=$ac_top_build_prefix$srcdir | |
1923 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; | |
1924 | esac | |
1925 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix | |
1926 | ||
1927 | cd "$ac_dir" || { ac_status=$?; continue; } | |
1928 | # Check for guested configure. | |
1929 | if test -f "$ac_srcdir/configure.gnu"; then | |
1930 | echo && | |
1931 | $SHELL "$ac_srcdir/configure.gnu" --help=recursive | |
1932 | elif test -f "$ac_srcdir/configure"; then | |
1933 | echo && | |
1934 | $SHELL "$ac_srcdir/configure" --help=recursive | |
1935 | else | |
1936 | $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 | |
1937 | fi || ac_status=$? | |
1938 | cd "$ac_pwd" || { ac_status=$?; break; } | |
1939 | done | |
1940 | fi | |
1941 | ||
1942 | test -n "$ac_init_help" && exit $ac_status | |
1943 | if $ac_init_version; then | |
1944 | cat <<\_ACEOF | |
1945 | emacs configure 24.0.50 | |
d6974efa | 1946 | generated by GNU Autoconf 2.68 |
067d23c9 | 1947 | |
2018939f | 1948 | Copyright (C) 2010 Free Software Foundation, Inc. |
067d23c9 KY |
1949 | This configure script is free software; the Free Software Foundation |
1950 | gives unlimited permission to copy, distribute and modify it. | |
1951 | _ACEOF | |
1952 | exit | |
1953 | fi | |
1954 | ||
1955 | ## ------------------------ ## | |
1956 | ## Autoconf initialization. ## | |
1957 | ## ------------------------ ## | |
1958 | ||
1959 | # ac_fn_c_try_compile LINENO | |
1960 | # -------------------------- | |
1961 | # Try to compile conftest.$ac_ext, and return whether this succeeded. | |
1962 | ac_fn_c_try_compile () | |
1963 | { | |
1964 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1965 | rm -f conftest.$ac_objext | |
1966 | if { { ac_try="$ac_compile" | |
1967 | case "(($ac_try" in | |
1968 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1969 | *) ac_try_echo=$ac_try;; | |
1970 | esac | |
1971 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1972 | $as_echo "$ac_try_echo"; } >&5 | |
1973 | (eval "$ac_compile") 2>conftest.err | |
1974 | ac_status=$? | |
1975 | if test -s conftest.err; then | |
1976 | grep -v '^ *+' conftest.err >conftest.er1 | |
1977 | cat conftest.er1 >&5 | |
1978 | mv -f conftest.er1 conftest.err | |
1979 | fi | |
1980 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1981 | test $ac_status = 0; } && { | |
1982 | test -z "$ac_c_werror_flag" || | |
1983 | test ! -s conftest.err | |
1984 | } && test -s conftest.$ac_objext; then : | |
1985 | ac_retval=0 | |
1986 | else | |
1987 | $as_echo "$as_me: failed program was:" >&5 | |
1988 | sed 's/^/| /' conftest.$ac_ext >&5 | |
1989 | ||
1990 | ac_retval=1 | |
1991 | fi | |
d6974efa | 1992 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
067d23c9 KY |
1993 | as_fn_set_status $ac_retval |
1994 | ||
1995 | } # ac_fn_c_try_compile | |
1996 | ||
067d23c9 KY |
1997 | # ac_fn_c_try_cpp LINENO |
1998 | # ---------------------- | |
1999 | # Try to preprocess conftest.$ac_ext, and return whether this succeeded. | |
2000 | ac_fn_c_try_cpp () | |
2001 | { | |
2002 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2003 | if { { ac_try="$ac_cpp conftest.$ac_ext" | |
2004 | case "(($ac_try" in | |
2005 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
2006 | *) ac_try_echo=$ac_try;; | |
2007 | esac | |
2008 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
2009 | $as_echo "$ac_try_echo"; } >&5 | |
2010 | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err | |
2011 | ac_status=$? | |
2012 | if test -s conftest.err; then | |
2013 | grep -v '^ *+' conftest.err >conftest.er1 | |
2014 | cat conftest.er1 >&5 | |
2015 | mv -f conftest.er1 conftest.err | |
2016 | fi | |
2017 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
2018939f | 2018 | test $ac_status = 0; } > conftest.i && { |
067d23c9 KY |
2019 | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || |
2020 | test ! -s conftest.err | |
2021 | }; then : | |
2022 | ac_retval=0 | |
2023 | else | |
2024 | $as_echo "$as_me: failed program was:" >&5 | |
2025 | sed 's/^/| /' conftest.$ac_ext >&5 | |
2026 | ||
2027 | ac_retval=1 | |
2028 | fi | |
d6974efa | 2029 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
067d23c9 KY |
2030 | as_fn_set_status $ac_retval |
2031 | ||
2032 | } # ac_fn_c_try_cpp | |
2033 | ||
2034 | # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES | |
2035 | # ------------------------------------------------------- | |
2036 | # Tests whether HEADER exists, giving a warning if it cannot be compiled using | |
2037 | # the include files in INCLUDES and setting the cache variable VAR | |
2038 | # accordingly. | |
2039 | ac_fn_c_check_header_mongrel () | |
2040 | { | |
2041 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
d6974efa | 2042 | if eval \${$3+:} false; then : |
067d23c9 KY |
2043 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
2044 | $as_echo_n "checking for $2... " >&6; } | |
d6974efa | 2045 | if eval \${$3+:} false; then : |
067d23c9 KY |
2046 | $as_echo_n "(cached) " >&6 |
2047 | fi | |
2048 | eval ac_res=\$$3 | |
2049 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2050 | $as_echo "$ac_res" >&6; } | |
2051 | else | |
2052 | # Is the header compilable? | |
2053 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 | |
2054 | $as_echo_n "checking $2 usability... " >&6; } | |
2055 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2056 | /* end confdefs.h. */ | |
2057 | $4 | |
2058 | #include <$2> | |
2059 | _ACEOF | |
2060 | if ac_fn_c_try_compile "$LINENO"; then : | |
2061 | ac_header_compiler=yes | |
2062 | else | |
2063 | ac_header_compiler=no | |
2064 | fi | |
2065 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2066 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 | |
2067 | $as_echo "$ac_header_compiler" >&6; } | |
2068 | ||
2069 | # Is the header present? | |
2070 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 | |
2071 | $as_echo_n "checking $2 presence... " >&6; } | |
2072 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2073 | /* end confdefs.h. */ | |
2074 | #include <$2> | |
2075 | _ACEOF | |
2076 | if ac_fn_c_try_cpp "$LINENO"; then : | |
2077 | ac_header_preproc=yes | |
2078 | else | |
2079 | ac_header_preproc=no | |
2080 | fi | |
2018939f | 2081 | rm -f conftest.err conftest.i conftest.$ac_ext |
067d23c9 KY |
2082 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 |
2083 | $as_echo "$ac_header_preproc" >&6; } | |
2084 | ||
2085 | # So? What about this header? | |
2086 | case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( | |
2087 | yes:no: ) | |
2088 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 | |
2089 | $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} | |
2090 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 | |
2091 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} | |
2092 | ;; | |
2093 | no:yes:* ) | |
2094 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 | |
2095 | $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} | |
2096 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 | |
2097 | $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} | |
2098 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 | |
2099 | $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} | |
2100 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 | |
2101 | $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} | |
2102 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 | |
2103 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} | |
2104 | ;; | |
2105 | esac | |
2106 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
2107 | $as_echo_n "checking for $2... " >&6; } | |
d6974efa | 2108 | if eval \${$3+:} false; then : |
067d23c9 KY |
2109 | $as_echo_n "(cached) " >&6 |
2110 | else | |
2111 | eval "$3=\$ac_header_compiler" | |
2112 | fi | |
2113 | eval ac_res=\$$3 | |
2114 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2115 | $as_echo "$ac_res" >&6; } | |
2116 | fi | |
d6974efa | 2117 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
067d23c9 KY |
2118 | |
2119 | } # ac_fn_c_check_header_mongrel | |
2120 | ||
2121 | # ac_fn_c_try_run LINENO | |
2122 | # ---------------------- | |
2123 | # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes | |
2124 | # that executables *can* be run. | |
2125 | ac_fn_c_try_run () | |
2126 | { | |
2127 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2128 | if { { ac_try="$ac_link" | |
2129 | case "(($ac_try" in | |
2130 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
2131 | *) ac_try_echo=$ac_try;; | |
2132 | esac | |
2133 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
2134 | $as_echo "$ac_try_echo"; } >&5 | |
2135 | (eval "$ac_link") 2>&5 | |
2136 | ac_status=$? | |
2137 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
2138 | test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' | |
2139 | { { case "(($ac_try" in | |
2140 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
2141 | *) ac_try_echo=$ac_try;; | |
2142 | esac | |
2143 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
2144 | $as_echo "$ac_try_echo"; } >&5 | |
2145 | (eval "$ac_try") 2>&5 | |
2146 | ac_status=$? | |
2147 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
2148 | test $ac_status = 0; }; }; then : | |
2149 | ac_retval=0 | |
2150 | else | |
2151 | $as_echo "$as_me: program exited with status $ac_status" >&5 | |
2152 | $as_echo "$as_me: failed program was:" >&5 | |
2153 | sed 's/^/| /' conftest.$ac_ext >&5 | |
2154 | ||
2155 | ac_retval=$ac_status | |
2156 | fi | |
2157 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo | |
d6974efa | 2158 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
067d23c9 KY |
2159 | as_fn_set_status $ac_retval |
2160 | ||
2161 | } # ac_fn_c_try_run | |
2162 | ||
2163 | # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES | |
2164 | # ------------------------------------------------------- | |
2165 | # Tests whether HEADER exists and can be compiled using the include files in | |
2166 | # INCLUDES, setting the cache variable VAR accordingly. | |
2167 | ac_fn_c_check_header_compile () | |
2168 | { | |
2169 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2170 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
2171 | $as_echo_n "checking for $2... " >&6; } | |
d6974efa | 2172 | if eval \${$3+:} false; then : |
067d23c9 KY |
2173 | $as_echo_n "(cached) " >&6 |
2174 | else | |
2175 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2176 | /* end confdefs.h. */ | |
2177 | $4 | |
2178 | #include <$2> | |
2179 | _ACEOF | |
2180 | if ac_fn_c_try_compile "$LINENO"; then : | |
2181 | eval "$3=yes" | |
2182 | else | |
2183 | eval "$3=no" | |
2184 | fi | |
2185 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2186 | fi | |
2187 | eval ac_res=\$$3 | |
2188 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2189 | $as_echo "$ac_res" >&6; } | |
d6974efa | 2190 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
067d23c9 KY |
2191 | |
2192 | } # ac_fn_c_check_header_compile | |
2193 | ||
1fd182f0 PE |
2194 | # ac_fn_c_try_link LINENO |
2195 | # ----------------------- | |
2196 | # Try to link conftest.$ac_ext, and return whether this succeeded. | |
2197 | ac_fn_c_try_link () | |
2198 | { | |
2199 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2200 | rm -f conftest.$ac_objext conftest$ac_exeext | |
2201 | if { { ac_try="$ac_link" | |
2202 | case "(($ac_try" in | |
2203 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
2204 | *) ac_try_echo=$ac_try;; | |
2205 | esac | |
2206 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
2207 | $as_echo "$ac_try_echo"; } >&5 | |
2208 | (eval "$ac_link") 2>conftest.err | |
2209 | ac_status=$? | |
2210 | if test -s conftest.err; then | |
2211 | grep -v '^ *+' conftest.err >conftest.er1 | |
2212 | cat conftest.er1 >&5 | |
2213 | mv -f conftest.er1 conftest.err | |
2214 | fi | |
2215 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
2216 | test $ac_status = 0; } && { | |
2217 | test -z "$ac_c_werror_flag" || | |
2218 | test ! -s conftest.err | |
2219 | } && test -s conftest$ac_exeext && { | |
2220 | test "$cross_compiling" = yes || | |
2221 | $as_test_x conftest$ac_exeext | |
2222 | }; then : | |
2223 | ac_retval=0 | |
2224 | else | |
2225 | $as_echo "$as_me: failed program was:" >&5 | |
2226 | sed 's/^/| /' conftest.$ac_ext >&5 | |
2227 | ||
2228 | ac_retval=1 | |
2229 | fi | |
2230 | # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information | |
2231 | # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would | |
2232 | # interfere with the next link command; also delete a directory that is | |
2233 | # left behind by Apple's compiler. We do this before executing the actions. | |
2234 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo | |
d6974efa | 2235 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
1fd182f0 PE |
2236 | as_fn_set_status $ac_retval |
2237 | ||
2238 | } # ac_fn_c_try_link | |
2239 | ||
2018939f AS |
2240 | # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES |
2241 | # --------------------------------------------- | |
2242 | # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR | |
2243 | # accordingly. | |
067d23c9 KY |
2244 | ac_fn_c_check_decl () |
2245 | { | |
2246 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2018939f AS |
2247 | as_decl_name=`echo $2|sed 's/ *(.*//'` |
2248 | as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'` | |
2249 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5 | |
2250 | $as_echo_n "checking whether $as_decl_name is declared... " >&6; } | |
d6974efa | 2251 | if eval \${$3+:} false; then : |
067d23c9 KY |
2252 | $as_echo_n "(cached) " >&6 |
2253 | else | |
2254 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2255 | /* end confdefs.h. */ | |
2256 | $4 | |
2257 | int | |
2258 | main () | |
2259 | { | |
2018939f AS |
2260 | #ifndef $as_decl_name |
2261 | #ifdef __cplusplus | |
2262 | (void) $as_decl_use; | |
2263 | #else | |
2264 | (void) $as_decl_name; | |
2265 | #endif | |
067d23c9 KY |
2266 | #endif |
2267 | ||
2268 | ; | |
2269 | return 0; | |
2270 | } | |
2271 | _ACEOF | |
2272 | if ac_fn_c_try_compile "$LINENO"; then : | |
2273 | eval "$3=yes" | |
2274 | else | |
2275 | eval "$3=no" | |
2276 | fi | |
2277 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2278 | fi | |
2279 | eval ac_res=\$$3 | |
2280 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2281 | $as_echo "$ac_res" >&6; } | |
d6974efa | 2282 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
067d23c9 KY |
2283 | |
2284 | } # ac_fn_c_check_decl | |
2285 | ||
2286 | # ac_fn_c_check_header_preproc LINENO HEADER VAR | |
2287 | # ---------------------------------------------- | |
2288 | # Tests whether HEADER is present, setting the cache variable VAR accordingly. | |
2289 | ac_fn_c_check_header_preproc () | |
2290 | { | |
2291 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2292 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
2293 | $as_echo_n "checking for $2... " >&6; } | |
d6974efa | 2294 | if eval \${$3+:} false; then : |
067d23c9 KY |
2295 | $as_echo_n "(cached) " >&6 |
2296 | else | |
2297 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2298 | /* end confdefs.h. */ | |
2299 | #include <$2> | |
2300 | _ACEOF | |
2301 | if ac_fn_c_try_cpp "$LINENO"; then : | |
2302 | eval "$3=yes" | |
2303 | else | |
2304 | eval "$3=no" | |
2305 | fi | |
2018939f | 2306 | rm -f conftest.err conftest.i conftest.$ac_ext |
067d23c9 KY |
2307 | fi |
2308 | eval ac_res=\$$3 | |
2309 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2310 | $as_echo "$ac_res" >&6; } | |
d6974efa | 2311 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
067d23c9 KY |
2312 | |
2313 | } # ac_fn_c_check_header_preproc | |
2314 | ||
2315 | # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES | |
2316 | # ---------------------------------------------------- | |
2317 | # Tries to find if the field MEMBER exists in type AGGR, after including | |
2318 | # INCLUDES, setting cache variable VAR accordingly. | |
2319 | ac_fn_c_check_member () | |
2320 | { | |
2321 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2322 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5 | |
2323 | $as_echo_n "checking for $2.$3... " >&6; } | |
d6974efa | 2324 | if eval \${$4+:} false; then : |
067d23c9 KY |
2325 | $as_echo_n "(cached) " >&6 |
2326 | else | |
2327 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2328 | /* end confdefs.h. */ | |
2329 | $5 | |
2330 | int | |
2331 | main () | |
2332 | { | |
2333 | static $2 ac_aggr; | |
2334 | if (ac_aggr.$3) | |
2335 | return 0; | |
2336 | ; | |
2337 | return 0; | |
2338 | } | |
2339 | _ACEOF | |
2340 | if ac_fn_c_try_compile "$LINENO"; then : | |
2341 | eval "$4=yes" | |
2342 | else | |
2343 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2344 | /* end confdefs.h. */ | |
2345 | $5 | |
2346 | int | |
2347 | main () | |
2348 | { | |
2349 | static $2 ac_aggr; | |
2350 | if (sizeof ac_aggr.$3) | |
2351 | return 0; | |
2352 | ; | |
2353 | return 0; | |
2354 | } | |
2355 | _ACEOF | |
2356 | if ac_fn_c_try_compile "$LINENO"; then : | |
2357 | eval "$4=yes" | |
2358 | else | |
2359 | eval "$4=no" | |
2360 | fi | |
2361 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2362 | fi | |
2363 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2364 | fi | |
2365 | eval ac_res=\$$4 | |
2366 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2367 | $as_echo "$ac_res" >&6; } | |
d6974efa | 2368 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
067d23c9 KY |
2369 | |
2370 | } # ac_fn_c_check_member | |
2371 | ||
2372 | # ac_fn_c_check_func LINENO FUNC VAR | |
2373 | # ---------------------------------- | |
2374 | # Tests whether FUNC exists, setting the cache variable VAR accordingly | |
2375 | ac_fn_c_check_func () | |
2376 | { | |
2377 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2378 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
2379 | $as_echo_n "checking for $2... " >&6; } | |
d6974efa | 2380 | if eval \${$3+:} false; then : |
067d23c9 KY |
2381 | $as_echo_n "(cached) " >&6 |
2382 | else | |
2383 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2384 | /* end confdefs.h. */ | |
2385 | /* Define $2 to an innocuous variant, in case <limits.h> declares $2. | |
2386 | For example, HP-UX 11i <limits.h> declares gettimeofday. */ | |
2387 | #define $2 innocuous_$2 | |
2388 | ||
2389 | /* System header to define __stub macros and hopefully few prototypes, | |
2390 | which can conflict with char $2 (); below. | |
2391 | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
2392 | <limits.h> exists even on freestanding compilers. */ | |
2393 | ||
2394 | #ifdef __STDC__ | |
2395 | # include <limits.h> | |
2396 | #else | |
2397 | # include <assert.h> | |
2398 | #endif | |
2399 | ||
2400 | #undef $2 | |
2401 | ||
2402 | /* Override any GCC internal prototype to avoid an error. | |
2403 | Use char because int might match the return type of a GCC | |
2404 | builtin and then its argument prototype would still apply. */ | |
2405 | #ifdef __cplusplus | |
2406 | extern "C" | |
2407 | #endif | |
2408 | char $2 (); | |
2409 | /* The GNU C library defines this for functions which it implements | |
2410 | to always fail with ENOSYS. Some functions are actually named | |
2411 | something starting with __ and the normal name is an alias. */ | |
2412 | #if defined __stub_$2 || defined __stub___$2 | |
2413 | choke me | |
2414 | #endif | |
2415 | ||
2416 | int | |
2417 | main () | |
2418 | { | |
2419 | return $2 (); | |
2420 | ; | |
2421 | return 0; | |
2422 | } | |
2423 | _ACEOF | |
2424 | if ac_fn_c_try_link "$LINENO"; then : | |
2425 | eval "$3=yes" | |
2426 | else | |
2427 | eval "$3=no" | |
2428 | fi | |
2429 | rm -f core conftest.err conftest.$ac_objext \ | |
2430 | conftest$ac_exeext conftest.$ac_ext | |
2431 | fi | |
2432 | eval ac_res=\$$3 | |
2433 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2434 | $as_echo "$ac_res" >&6; } | |
d6974efa | 2435 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
067d23c9 KY |
2436 | |
2437 | } # ac_fn_c_check_func | |
2438 | ||
2439 | # ac_fn_c_check_type LINENO TYPE VAR INCLUDES | |
2440 | # ------------------------------------------- | |
2441 | # Tests whether TYPE exists after having included INCLUDES, setting cache | |
2442 | # variable VAR accordingly. | |
2443 | ac_fn_c_check_type () | |
2444 | { | |
2445 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2446 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
2447 | $as_echo_n "checking for $2... " >&6; } | |
d6974efa | 2448 | if eval \${$3+:} false; then : |
067d23c9 KY |
2449 | $as_echo_n "(cached) " >&6 |
2450 | else | |
2451 | eval "$3=no" | |
2452 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2453 | /* end confdefs.h. */ | |
2454 | $4 | |
2455 | int | |
2456 | main () | |
2457 | { | |
2458 | if (sizeof ($2)) | |
2459 | return 0; | |
2460 | ; | |
2461 | return 0; | |
2462 | } | |
2463 | _ACEOF | |
2464 | if ac_fn_c_try_compile "$LINENO"; then : | |
2465 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2466 | /* end confdefs.h. */ | |
2467 | $4 | |
2468 | int | |
2469 | main () | |
2470 | { | |
2471 | if (sizeof (($2))) | |
2472 | return 0; | |
2473 | ; | |
2474 | return 0; | |
2475 | } | |
2476 | _ACEOF | |
2477 | if ac_fn_c_try_compile "$LINENO"; then : | |
2478 | ||
2479 | else | |
2480 | eval "$3=yes" | |
2481 | fi | |
2482 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2483 | fi | |
2484 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2485 | fi | |
2486 | eval ac_res=\$$3 | |
2487 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2488 | $as_echo "$ac_res" >&6; } | |
d6974efa | 2489 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
067d23c9 KY |
2490 | |
2491 | } # ac_fn_c_check_type | |
5f90be1b PE |
2492 | |
2493 | # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES | |
2494 | # -------------------------------------------- | |
2495 | # Tries to find the compile-time value of EXPR in a program that includes | |
2496 | # INCLUDES, setting VAR accordingly. Returns whether the value could be | |
2497 | # computed | |
2498 | ac_fn_c_compute_int () | |
2499 | { | |
2500 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2501 | if test "$cross_compiling" = yes; then | |
2502 | # Depending upon the size, compute the lo and hi bounds. | |
2503 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2504 | /* end confdefs.h. */ | |
2505 | $4 | |
2506 | int | |
2507 | main () | |
2508 | { | |
2509 | static int test_array [1 - 2 * !(($2) >= 0)]; | |
2510 | test_array [0] = 0 | |
2511 | ||
2512 | ; | |
2513 | return 0; | |
2514 | } | |
2515 | _ACEOF | |
2516 | if ac_fn_c_try_compile "$LINENO"; then : | |
2517 | ac_lo=0 ac_mid=0 | |
2518 | while :; do | |
2519 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2520 | /* end confdefs.h. */ | |
2521 | $4 | |
2522 | int | |
2523 | main () | |
2524 | { | |
2525 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; | |
2526 | test_array [0] = 0 | |
2527 | ||
2528 | ; | |
2529 | return 0; | |
2530 | } | |
2531 | _ACEOF | |
2532 | if ac_fn_c_try_compile "$LINENO"; then : | |
2533 | ac_hi=$ac_mid; break | |
2534 | else | |
2535 | as_fn_arith $ac_mid + 1 && ac_lo=$as_val | |
2536 | if test $ac_lo -le $ac_mid; then | |
2537 | ac_lo= ac_hi= | |
2538 | break | |
2539 | fi | |
2540 | as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val | |
2541 | fi | |
2542 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2543 | done | |
2544 | else | |
2545 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2546 | /* end confdefs.h. */ | |
2547 | $4 | |
2548 | int | |
2549 | main () | |
2550 | { | |
2551 | static int test_array [1 - 2 * !(($2) < 0)]; | |
2552 | test_array [0] = 0 | |
2553 | ||
2554 | ; | |
2555 | return 0; | |
2556 | } | |
2557 | _ACEOF | |
2558 | if ac_fn_c_try_compile "$LINENO"; then : | |
2559 | ac_hi=-1 ac_mid=-1 | |
2560 | while :; do | |
2561 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2562 | /* end confdefs.h. */ | |
2563 | $4 | |
2564 | int | |
2565 | main () | |
2566 | { | |
2567 | static int test_array [1 - 2 * !(($2) >= $ac_mid)]; | |
2568 | test_array [0] = 0 | |
2569 | ||
2570 | ; | |
2571 | return 0; | |
2572 | } | |
2573 | _ACEOF | |
2574 | if ac_fn_c_try_compile "$LINENO"; then : | |
2575 | ac_lo=$ac_mid; break | |
2576 | else | |
2577 | as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val | |
2578 | if test $ac_mid -le $ac_hi; then | |
2579 | ac_lo= ac_hi= | |
2580 | break | |
2581 | fi | |
2582 | as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val | |
2583 | fi | |
2584 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2585 | done | |
2586 | else | |
2587 | ac_lo= ac_hi= | |
2588 | fi | |
2589 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2590 | fi | |
2591 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2592 | # Binary search between lo and hi bounds. | |
2593 | while test "x$ac_lo" != "x$ac_hi"; do | |
2594 | as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val | |
2595 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2596 | /* end confdefs.h. */ | |
2597 | $4 | |
2598 | int | |
2599 | main () | |
2600 | { | |
2601 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; | |
2602 | test_array [0] = 0 | |
2603 | ||
2604 | ; | |
2605 | return 0; | |
2606 | } | |
2607 | _ACEOF | |
2608 | if ac_fn_c_try_compile "$LINENO"; then : | |
2609 | ac_hi=$ac_mid | |
2610 | else | |
2611 | as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val | |
2612 | fi | |
2613 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2614 | done | |
2615 | case $ac_lo in #(( | |
2616 | ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; | |
2617 | '') ac_retval=1 ;; | |
2618 | esac | |
2619 | else | |
2620 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2621 | /* end confdefs.h. */ | |
2622 | $4 | |
2623 | static long int longval () { return $2; } | |
2624 | static unsigned long int ulongval () { return $2; } | |
2625 | #include <stdio.h> | |
2626 | #include <stdlib.h> | |
2627 | int | |
2628 | main () | |
2629 | { | |
2630 | ||
2631 | FILE *f = fopen ("conftest.val", "w"); | |
2632 | if (! f) | |
2633 | return 1; | |
2634 | if (($2) < 0) | |
2635 | { | |
2636 | long int i = longval (); | |
2637 | if (i != ($2)) | |
2638 | return 1; | |
2639 | fprintf (f, "%ld", i); | |
2640 | } | |
2641 | else | |
2642 | { | |
2643 | unsigned long int i = ulongval (); | |
2644 | if (i != ($2)) | |
2645 | return 1; | |
2646 | fprintf (f, "%lu", i); | |
2647 | } | |
2648 | /* Do not output a trailing newline, as this causes \r\n confusion | |
2649 | on some platforms. */ | |
2650 | return ferror (f) || fclose (f) != 0; | |
2651 | ||
2652 | ; | |
2653 | return 0; | |
2654 | } | |
2655 | _ACEOF | |
2656 | if ac_fn_c_try_run "$LINENO"; then : | |
2657 | echo >>conftest.val; read $3 <conftest.val; ac_retval=0 | |
2658 | else | |
2659 | ac_retval=1 | |
2660 | fi | |
2661 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
2662 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
2663 | rm -f conftest.val | |
2664 | ||
2665 | fi | |
2666 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
2667 | as_fn_set_status $ac_retval | |
2668 | ||
2669 | } # ac_fn_c_compute_int | |
067d23c9 KY |
2670 | cat >config.log <<_ACEOF |
2671 | This file contains any messages produced by compilers while | |
2672 | running configure, to aid debugging if configure makes a mistake. | |
2673 | ||
2674 | It was created by emacs $as_me 24.0.50, which was | |
d6974efa | 2675 | generated by GNU Autoconf 2.68. Invocation command line was |
067d23c9 KY |
2676 | |
2677 | $ $0 $@ | |
2678 | ||
2679 | _ACEOF | |
2680 | exec 5>>config.log | |
2681 | { | |
2682 | cat <<_ASUNAME | |
2683 | ## --------- ## | |
2684 | ## Platform. ## | |
2685 | ## --------- ## | |
2686 | ||
2687 | hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` | |
2688 | uname -m = `(uname -m) 2>/dev/null || echo unknown` | |
2689 | uname -r = `(uname -r) 2>/dev/null || echo unknown` | |
2690 | uname -s = `(uname -s) 2>/dev/null || echo unknown` | |
2691 | uname -v = `(uname -v) 2>/dev/null || echo unknown` | |
2692 | ||
2693 | /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` | |
2694 | /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` | |
2695 | ||
2696 | /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` | |
2697 | /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` | |
2698 | /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` | |
2699 | /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` | |
2700 | /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` | |
2701 | /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` | |
2702 | /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` | |
2703 | ||
2704 | _ASUNAME | |
2705 | ||
2706 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
2707 | for as_dir in $PATH | |
2708 | do | |
2709 | IFS=$as_save_IFS | |
2710 | test -z "$as_dir" && as_dir=. | |
2711 | $as_echo "PATH: $as_dir" | |
2712 | done | |
2713 | IFS=$as_save_IFS | |
2714 | ||
2715 | } >&5 | |
2716 | ||
2717 | cat >&5 <<_ACEOF | |
2718 | ||
2719 | ||
2720 | ## ----------- ## | |
2721 | ## Core tests. ## | |
2722 | ## ----------- ## | |
2723 | ||
2724 | _ACEOF | |
2725 | ||
2726 | ||
2727 | # Keep a trace of the command line. | |
2728 | # Strip out --no-create and --no-recursion so they do not pile up. | |
2729 | # Strip out --silent because we don't want to record it for future runs. | |
2730 | # Also quote any args containing shell meta-characters. | |
2731 | # Make two passes to allow for proper duplicate-argument suppression. | |
2732 | ac_configure_args= | |
2733 | ac_configure_args0= | |
2734 | ac_configure_args1= | |
2735 | ac_must_keep_next=false | |
2736 | for ac_pass in 1 2 | |
2737 | do | |
2738 | for ac_arg | |
2739 | do | |
2740 | case $ac_arg in | |
2741 | -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; | |
2742 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | |
2743 | | -silent | --silent | --silen | --sile | --sil) | |
2744 | continue ;; | |
2745 | *\'*) | |
2746 | ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
2747 | esac | |
2748 | case $ac_pass in | |
2749 | 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; | |
2750 | 2) | |
2751 | as_fn_append ac_configure_args1 " '$ac_arg'" | |
2752 | if test $ac_must_keep_next = true; then | |
2753 | ac_must_keep_next=false # Got value, back to normal. | |
2754 | else | |
2755 | case $ac_arg in | |
2756 | *=* | --config-cache | -C | -disable-* | --disable-* \ | |
2757 | | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | |
2758 | | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | |
2759 | | -with-* | --with-* | -without-* | --without-* | --x) | |
2760 | case "$ac_configure_args0 " in | |
2761 | "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; | |
2762 | esac | |
2763 | ;; | |
2764 | -* ) ac_must_keep_next=true ;; | |
2765 | esac | |
2766 | fi | |
2767 | as_fn_append ac_configure_args " '$ac_arg'" | |
2768 | ;; | |
2769 | esac | |
2770 | done | |
2771 | done | |
2772 | { ac_configure_args0=; unset ac_configure_args0;} | |
2773 | { ac_configure_args1=; unset ac_configure_args1;} | |
2774 | ||
2775 | # When interrupted or exit'd, cleanup temporary files, and complete | |
2776 | # config.log. We remove comments because anyway the quotes in there | |
2777 | # would cause problems or look ugly. | |
2778 | # WARNING: Use '\'' to represent an apostrophe within the trap. | |
2779 | # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. | |
2780 | trap 'exit_status=$? | |
2781 | # Save into config.log some information that might help in debugging. | |
2782 | { | |
2783 | echo | |
2784 | ||
2018939f | 2785 | $as_echo "## ---------------- ## |
067d23c9 | 2786 | ## Cache variables. ## |
2018939f | 2787 | ## ---------------- ##" |
067d23c9 KY |
2788 | echo |
2789 | # The following way of writing the cache mishandles newlines in values, | |
2790 | ( | |
2791 | for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do | |
2792 | eval ac_val=\$$ac_var | |
2793 | case $ac_val in #( | |
2794 | *${as_nl}*) | |
2795 | case $ac_var in #( | |
2796 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 | |
2797 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; | |
2798 | esac | |
2799 | case $ac_var in #( | |
2800 | _ | IFS | as_nl) ;; #( | |
2801 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( | |
2802 | *) { eval $ac_var=; unset $ac_var;} ;; | |
2803 | esac ;; | |
2804 | esac | |
2805 | done | |
2806 | (set) 2>&1 | | |
2807 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( | |
2808 | *${as_nl}ac_space=\ *) | |
2809 | sed -n \ | |
2810 | "s/'\''/'\''\\\\'\'''\''/g; | |
2811 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" | |
2812 | ;; #( | |
2813 | *) | |
2814 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" | |
2815 | ;; | |
2816 | esac | | |
2817 | sort | |
2818 | ) | |
2819 | echo | |
2820 | ||
2018939f | 2821 | $as_echo "## ----------------- ## |
067d23c9 | 2822 | ## Output variables. ## |
2018939f | 2823 | ## ----------------- ##" |
067d23c9 KY |
2824 | echo |
2825 | for ac_var in $ac_subst_vars | |
2826 | do | |
2827 | eval ac_val=\$$ac_var | |
2828 | case $ac_val in | |
2829 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; | |
2830 | esac | |
2831 | $as_echo "$ac_var='\''$ac_val'\''" | |
2832 | done | sort | |
2833 | echo | |
2834 | ||
2835 | if test -n "$ac_subst_files"; then | |
2018939f | 2836 | $as_echo "## ------------------- ## |
067d23c9 | 2837 | ## File substitutions. ## |
2018939f | 2838 | ## ------------------- ##" |
067d23c9 KY |
2839 | echo |
2840 | for ac_var in $ac_subst_files | |
2841 | do | |
2842 | eval ac_val=\$$ac_var | |
2843 | case $ac_val in | |
2844 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; | |
2845 | esac | |
2846 | $as_echo "$ac_var='\''$ac_val'\''" | |
2847 | done | sort | |
2848 | echo | |
2849 | fi | |
2850 | ||
2851 | if test -s confdefs.h; then | |
2018939f | 2852 | $as_echo "## ----------- ## |
067d23c9 | 2853 | ## confdefs.h. ## |
2018939f | 2854 | ## ----------- ##" |
067d23c9 KY |
2855 | echo |
2856 | cat confdefs.h | |
2857 | echo | |
2858 | fi | |
2859 | test "$ac_signal" != 0 && | |
2860 | $as_echo "$as_me: caught signal $ac_signal" | |
2861 | $as_echo "$as_me: exit $exit_status" | |
2862 | } >&5 | |
2863 | rm -f core *.core core.conftest.* && | |
2864 | rm -f -r conftest* confdefs* conf$$* $ac_clean_files && | |
2865 | exit $exit_status | |
2866 | ' 0 | |
2867 | for ac_signal in 1 2 13 15; do | |
2868 | trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal | |
2869 | done | |
2870 | ac_signal=0 | |
2871 | ||
2872 | # confdefs.h avoids OS command line length limits that DEFS can exceed. | |
2873 | rm -f -r conftest* confdefs.h | |
2874 | ||
2875 | $as_echo "/* confdefs.h */" > confdefs.h | |
2876 | ||
2877 | # Predefined preprocessor variables. | |
2878 | ||
2879 | cat >>confdefs.h <<_ACEOF | |
2880 | #define PACKAGE_NAME "$PACKAGE_NAME" | |
2881 | _ACEOF | |
2882 | ||
2883 | cat >>confdefs.h <<_ACEOF | |
2884 | #define PACKAGE_TARNAME "$PACKAGE_TARNAME" | |
2885 | _ACEOF | |
2886 | ||
2887 | cat >>confdefs.h <<_ACEOF | |
2888 | #define PACKAGE_VERSION "$PACKAGE_VERSION" | |
2889 | _ACEOF | |
2890 | ||
2891 | cat >>confdefs.h <<_ACEOF | |
2892 | #define PACKAGE_STRING "$PACKAGE_STRING" | |
2893 | _ACEOF | |
2894 | ||
2895 | cat >>confdefs.h <<_ACEOF | |
2896 | #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" | |
2897 | _ACEOF | |
2898 | ||
2899 | cat >>confdefs.h <<_ACEOF | |
2900 | #define PACKAGE_URL "$PACKAGE_URL" | |
2901 | _ACEOF | |
2902 | ||
2903 | ||
2904 | # Let the site file select an alternate cache file if it wants to. | |
2905 | # Prefer an explicitly selected file to automatically selected ones. | |
2906 | ac_site_file1=NONE | |
2907 | ac_site_file2=NONE | |
2908 | if test -n "$CONFIG_SITE"; then | |
2018939f AS |
2909 | # We do not want a PATH search for config.site. |
2910 | case $CONFIG_SITE in #(( | |
2911 | -*) ac_site_file1=./$CONFIG_SITE;; | |
2912 | */*) ac_site_file1=$CONFIG_SITE;; | |
2913 | *) ac_site_file1=./$CONFIG_SITE;; | |
2914 | esac | |
067d23c9 KY |
2915 | elif test "x$prefix" != xNONE; then |
2916 | ac_site_file1=$prefix/share/config.site | |
2917 | ac_site_file2=$prefix/etc/config.site | |
2918 | else | |
2919 | ac_site_file1=$ac_default_prefix/share/config.site | |
2920 | ac_site_file2=$ac_default_prefix/etc/config.site | |
2921 | fi | |
2922 | for ac_site_file in "$ac_site_file1" "$ac_site_file2" | |
2923 | do | |
2924 | test "x$ac_site_file" = xNONE && continue | |
2925 | if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then | |
2926 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 | |
2927 | $as_echo "$as_me: loading site script $ac_site_file" >&6;} | |
2928 | sed 's/^/| /' "$ac_site_file" >&5 | |
2018939f AS |
2929 | . "$ac_site_file" \ |
2930 | || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
2931 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2932 | as_fn_error $? "failed to load site script $ac_site_file | |
d6974efa | 2933 | See \`config.log' for more details" "$LINENO" 5; } |
067d23c9 KY |
2934 | fi |
2935 | done | |
2936 | ||
2937 | if test -r "$cache_file"; then | |
2938 | # Some versions of bash will fail to source /dev/null (special files | |
2939 | # actually), so we avoid doing that. DJGPP emulates it as a regular file. | |
2940 | if test /dev/null != "$cache_file" && test -f "$cache_file"; then | |
2941 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 | |
2942 | $as_echo "$as_me: loading cache $cache_file" >&6;} | |
2943 | case $cache_file in | |
2944 | [\\/]* | ?:[\\/]* ) . "$cache_file";; | |
2945 | *) . "./$cache_file";; | |
2946 | esac | |
2947 | fi | |
2948 | else | |
2949 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 | |
2950 | $as_echo "$as_me: creating cache $cache_file" >&6;} | |
2951 | >$cache_file | |
2952 | fi | |
2953 | ||
2954 | as_fn_append ac_header_list " stdlib.h" | |
2955 | as_fn_append ac_header_list " unistd.h" | |
2956 | as_fn_append ac_header_list " sys/param.h" | |
e275c824 PE |
2957 | gl_getopt_required=GNU |
2958 | as_fn_append ac_header_list " getopt.h" | |
067d23c9 | 2959 | as_fn_append ac_func_list " alarm" |
5f90be1b PE |
2960 | as_fn_append ac_header_list " wchar.h" |
2961 | as_fn_append ac_header_list " stdint.h" | |
16c3e636 | 2962 | as_fn_append ac_func_list " tzset" |
5fa4ac76 | 2963 | as_fn_append ac_header_list " sys/stat.h" |
1fd182f0 PE |
2964 | as_fn_append ac_header_list " sys/time.h" |
2965 | as_fn_append ac_func_list " localtime_r" | |
067d23c9 KY |
2966 | # Check that the precious variables saved in the cache have kept the same |
2967 | # value. | |
2968 | ac_cache_corrupted=false | |
2969 | for ac_var in $ac_precious_vars; do | |
2970 | eval ac_old_set=\$ac_cv_env_${ac_var}_set | |
2971 | eval ac_new_set=\$ac_env_${ac_var}_set | |
2972 | eval ac_old_val=\$ac_cv_env_${ac_var}_value | |
2973 | eval ac_new_val=\$ac_env_${ac_var}_value | |
2974 | case $ac_old_set,$ac_new_set in | |
2975 | set,) | |
2976 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 | |
2977 | $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} | |
2978 | ac_cache_corrupted=: ;; | |
2979 | ,set) | |
2980 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 | |
2981 | $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} | |
2982 | ac_cache_corrupted=: ;; | |
2983 | ,);; | |
2984 | *) | |
2985 | if test "x$ac_old_val" != "x$ac_new_val"; then | |
2986 | # differences in whitespace do not lead to failure. | |
2987 | ac_old_val_w=`echo x $ac_old_val` | |
2988 | ac_new_val_w=`echo x $ac_new_val` | |
2989 | if test "$ac_old_val_w" != "$ac_new_val_w"; then | |
2990 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 | |
2991 | $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} | |
2992 | ac_cache_corrupted=: | |
2993 | else | |
2994 | { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 | |
2995 | $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} | |
2996 | eval $ac_var=\$ac_old_val | |
2997 | fi | |
2998 | { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 | |
2999 | $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} | |
3000 | { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 | |
3001 | $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} | |
3002 | fi;; | |
3003 | esac | |
3004 | # Pass precious variables to config.status. | |
3005 | if test "$ac_new_set" = set; then | |
3006 | case $ac_new_val in | |
3007 | *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; | |
3008 | *) ac_arg=$ac_var=$ac_new_val ;; | |
3009 | esac | |
3010 | case " $ac_configure_args " in | |
3011 | *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. | |
3012 | *) as_fn_append ac_configure_args " '$ac_arg'" ;; | |
3013 | esac | |
3014 | fi | |
3015 | done | |
3016 | if $ac_cache_corrupted; then | |
3017 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
3018 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
3019 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 | |
3020 | $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} | |
2018939f | 3021 | as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 |
067d23c9 KY |
3022 | fi |
3023 | ## -------------------- ## | |
3024 | ## Main body of script. ## | |
3025 | ## -------------------- ## | |
3026 | ||
3027 | ac_ext=c | |
3028 | ac_cpp='$CPP $CPPFLAGS' | |
3029 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
3030 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
3031 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
3032 | ||
3033 | ||
3034 | ac_config_headers="$ac_config_headers src/config.h:src/config.in" | |
3035 | ||
3036 | ||
743c80a7 | 3037 | am__api_version='1.11' |
067d23c9 | 3038 | |
743c80a7 PE |
3039 | ac_aux_dir= |
3040 | for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do | |
3041 | if test -f "$ac_dir/install-sh"; then | |
3042 | ac_aux_dir=$ac_dir | |
3043 | ac_install_sh="$ac_aux_dir/install-sh -c" | |
3044 | break | |
3045 | elif test -f "$ac_dir/install.sh"; then | |
3046 | ac_aux_dir=$ac_dir | |
3047 | ac_install_sh="$ac_aux_dir/install.sh -c" | |
3048 | break | |
3049 | elif test -f "$ac_dir/shtool"; then | |
3050 | ac_aux_dir=$ac_dir | |
3051 | ac_install_sh="$ac_aux_dir/shtool install -c" | |
3052 | break | |
3053 | fi | |
3054 | done | |
3055 | if test -z "$ac_aux_dir"; then | |
3056 | as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 | |
3057 | fi | |
067d23c9 | 3058 | |
743c80a7 PE |
3059 | # These three variables are undocumented and unsupported, |
3060 | # and are intended to be withdrawn in a future Autoconf release. | |
3061 | # They can cause serious problems if a builder's source tree is in a directory | |
3062 | # whose full name contains unusual characters. | |
3063 | ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. | |
3064 | ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. | |
3065 | ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. | |
067d23c9 | 3066 | |
067d23c9 | 3067 | |
743c80a7 PE |
3068 | # Find a good install program. We prefer a C program (faster), |
3069 | # so one script is as good as another. But avoid the broken or | |
3070 | # incompatible versions: | |
3071 | # SysV /etc/install, /usr/sbin/install | |
3072 | # SunOS /usr/etc/install | |
3073 | # IRIX /sbin/install | |
3074 | # AIX /bin/install | |
3075 | # AmigaOS /C/install, which installs bootblocks on floppy discs | |
3076 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag | |
3077 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args | |
3078 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" | |
3079 | # OS/2's system install, which has a completely different semantic | |
3080 | # ./install, which can be erroneously created by make from ./install.sh. | |
3081 | # Reject install programs that cannot install multiple files. | |
3082 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 | |
3083 | $as_echo_n "checking for a BSD-compatible install... " >&6; } | |
3084 | if test -z "$INSTALL"; then | |
d6974efa | 3085 | if ${ac_cv_path_install+:} false; then : |
743c80a7 PE |
3086 | $as_echo_n "(cached) " >&6 |
3087 | else | |
3088 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
3089 | for as_dir in $PATH | |
3090 | do | |
3091 | IFS=$as_save_IFS | |
3092 | test -z "$as_dir" && as_dir=. | |
3093 | # Account for people who put trailing slashes in PATH elements. | |
3094 | case $as_dir/ in #(( | |
3095 | ./ | .// | /[cC]/* | \ | |
3096 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ | |
3097 | ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ | |
3098 | /usr/ucb/* ) ;; | |
3099 | *) | |
3100 | # OSF1 and SCO ODT 3.0 have their own names for install. | |
3101 | # Don't use installbsd from OSF since it installs stuff as root | |
3102 | # by default. | |
3103 | for ac_prog in ginstall scoinst install; do | |
3104 | for ac_exec_ext in '' $ac_executable_extensions; do | |
3105 | if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then | |
3106 | if test $ac_prog = install && | |
3107 | grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then | |
3108 | # AIX install. It has an incompatible calling convention. | |
3109 | : | |
3110 | elif test $ac_prog = install && | |
3111 | grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then | |
3112 | # program-specific install script used by HP pwplus--don't use. | |
3113 | : | |
3114 | else | |
3115 | rm -rf conftest.one conftest.two conftest.dir | |
3116 | echo one > conftest.one | |
3117 | echo two > conftest.two | |
3118 | mkdir conftest.dir | |
3119 | if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && | |
3120 | test -s conftest.one && test -s conftest.two && | |
3121 | test -s conftest.dir/conftest.one && | |
3122 | test -s conftest.dir/conftest.two | |
3123 | then | |
3124 | ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" | |
3125 | break 3 | |
3126 | fi | |
3127 | fi | |
3128 | fi | |
3129 | done | |
3130 | done | |
3131 | ;; | |
3132 | esac | |
067d23c9 | 3133 | |
743c80a7 PE |
3134 | done |
3135 | IFS=$as_save_IFS | |
067d23c9 | 3136 | |
743c80a7 | 3137 | rm -rf conftest.one conftest.two conftest.dir |
067d23c9 | 3138 | |
067d23c9 | 3139 | fi |
743c80a7 PE |
3140 | if test "${ac_cv_path_install+set}" = set; then |
3141 | INSTALL=$ac_cv_path_install | |
3142 | else | |
3143 | # As a last resort, use the slow shell script. Don't cache a | |
3144 | # value for INSTALL within a source directory, because that will | |
3145 | # break other packages using the cache if that directory is | |
3146 | # removed, or if the value is a relative name. | |
3147 | INSTALL=$ac_install_sh | |
3148 | fi | |
067d23c9 | 3149 | fi |
743c80a7 PE |
3150 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 |
3151 | $as_echo "$INSTALL" >&6; } | |
067d23c9 | 3152 | |
743c80a7 PE |
3153 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. |
3154 | # It thinks the first close brace ends the variable substitution. | |
3155 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' | |
067d23c9 | 3156 | |
743c80a7 | 3157 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' |
067d23c9 | 3158 | |
743c80a7 | 3159 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
067d23c9 | 3160 | |
743c80a7 PE |
3161 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 |
3162 | $as_echo_n "checking whether build environment is sane... " >&6; } | |
3163 | # Just in case | |
3164 | sleep 1 | |
3165 | echo timestamp > conftest.file | |
3166 | # Reject unsafe characters in $srcdir or the absolute working directory | |
3167 | # name. Accept space and tab only in the latter. | |
3168 | am_lf=' | |
3169 | ' | |
3170 | case `pwd` in | |
3171 | *[\\\"\#\$\&\'\`$am_lf]*) | |
d6974efa | 3172 | as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; |
743c80a7 PE |
3173 | esac |
3174 | case $srcdir in | |
3175 | *[\\\"\#\$\&\'\`$am_lf\ \ ]*) | |
d6974efa | 3176 | as_fn_error $? "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;; |
743c80a7 | 3177 | esac |
067d23c9 | 3178 | |
743c80a7 PE |
3179 | # Do `set' in a subshell so we don't clobber the current shell's |
3180 | # arguments. Must try -L first in case configure is actually a | |
3181 | # symlink; some systems play weird games with the mod time of symlinks | |
3182 | # (eg FreeBSD returns the mod time of the symlink's containing | |
3183 | # directory). | |
3184 | if ( | |
3185 | set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` | |
3186 | if test "$*" = "X"; then | |
3187 | # -L didn't work. | |
3188 | set X `ls -t "$srcdir/configure" conftest.file` | |
3189 | fi | |
3190 | rm -f conftest.file | |
3191 | if test "$*" != "X $srcdir/configure conftest.file" \ | |
3192 | && test "$*" != "X conftest.file $srcdir/configure"; then | |
3193 | ||
3194 | # If neither matched, then we have a broken ls. This can happen | |
3195 | # if, for instance, CONFIG_SHELL is bash and it inherits a | |
3196 | # broken ls alias from the environment. This has actually | |
3197 | # happened. Such a system could not be considered "sane". | |
3198 | as_fn_error $? "ls -t appears to fail. Make sure there is not a broken | |
3199 | alias in your environment" "$LINENO" 5 | |
3200 | fi | |
067d23c9 | 3201 | |
743c80a7 PE |
3202 | test "$2" = conftest.file |
3203 | ) | |
3204 | then | |
3205 | # Ok. | |
3206 | : | |
067d23c9 | 3207 | else |
743c80a7 PE |
3208 | as_fn_error $? "newly created file is older than distributed files! |
3209 | Check your system clock" "$LINENO" 5 | |
067d23c9 | 3210 | fi |
743c80a7 PE |
3211 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
3212 | $as_echo "yes" >&6; } | |
3213 | test "$program_prefix" != NONE && | |
3214 | program_transform_name="s&^&$program_prefix&;$program_transform_name" | |
3215 | # Use a double $ so make ignores it. | |
3216 | test "$program_suffix" != NONE && | |
3217 | program_transform_name="s&\$&$program_suffix&;$program_transform_name" | |
3218 | # Double any \ or $. | |
3219 | # By default was `s,x,x', remove it if useless. | |
3220 | ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' | |
3221 | program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` | |
067d23c9 | 3222 | |
743c80a7 PE |
3223 | # expand $ac_aux_dir to an absolute path |
3224 | am_aux_dir=`cd $ac_aux_dir && pwd` | |
067d23c9 | 3225 | |
743c80a7 PE |
3226 | if test x"${MISSING+set}" != xset; then |
3227 | case $am_aux_dir in | |
3228 | *\ * | *\ *) | |
3229 | MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; | |
3230 | *) | |
3231 | MISSING="\${SHELL} $am_aux_dir/missing" ;; | |
3232 | esac | |
067d23c9 | 3233 | fi |
743c80a7 PE |
3234 | # Use eval to expand $SHELL |
3235 | if eval "$MISSING --run true"; then | |
3236 | am_missing_run="$MISSING --run " | |
067d23c9 | 3237 | else |
743c80a7 PE |
3238 | am_missing_run= |
3239 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5 | |
3240 | $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} | |
067d23c9 KY |
3241 | fi |
3242 | ||
743c80a7 PE |
3243 | if test x"${install_sh}" != xset; then |
3244 | case $am_aux_dir in | |
3245 | *\ * | *\ *) | |
3246 | install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; | |
3247 | *) | |
3248 | install_sh="\${SHELL} $am_aux_dir/install-sh" | |
3249 | esac | |
067d23c9 KY |
3250 | fi |
3251 | ||
743c80a7 PE |
3252 | # Installed binaries are usually stripped using `strip' when the user |
3253 | # run `make install-strip'. However `strip' might not be the right | |
3254 | # tool to use in cross-compilation environments, therefore Automake | |
3255 | # will honor the `STRIP' environment variable to overrule this program. | |
3256 | if test "$cross_compiling" != no; then | |
3257 | if test -n "$ac_tool_prefix"; then | |
3258 | # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. | |
3259 | set dummy ${ac_tool_prefix}strip; ac_word=$2 | |
3260 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
3261 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 3262 | if ${ac_cv_prog_STRIP+:} false; then : |
743c80a7 | 3263 | $as_echo_n "(cached) " >&6 |
067d23c9 | 3264 | else |
743c80a7 PE |
3265 | if test -n "$STRIP"; then |
3266 | ac_cv_prog_STRIP="$STRIP" # Let the user override the test. | |
3267 | else | |
3268 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
3269 | for as_dir in $PATH | |
3270 | do | |
3271 | IFS=$as_save_IFS | |
3272 | test -z "$as_dir" && as_dir=. | |
3273 | for ac_exec_ext in '' $ac_executable_extensions; do | |
3274 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
3275 | ac_cv_prog_STRIP="${ac_tool_prefix}strip" | |
3276 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
3277 | break 2 | |
3278 | fi | |
3279 | done | |
3280 | done | |
3281 | IFS=$as_save_IFS | |
067d23c9 KY |
3282 | |
3283 | fi | |
067d23c9 | 3284 | fi |
743c80a7 PE |
3285 | STRIP=$ac_cv_prog_STRIP |
3286 | if test -n "$STRIP"; then | |
3287 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 | |
3288 | $as_echo "$STRIP" >&6; } | |
3289 | else | |
3290 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
3291 | $as_echo "no" >&6; } | |
067d23c9 KY |
3292 | fi |
3293 | ||
3294 | ||
067d23c9 | 3295 | fi |
743c80a7 PE |
3296 | if test -z "$ac_cv_prog_STRIP"; then |
3297 | ac_ct_STRIP=$STRIP | |
3298 | # Extract the first word of "strip", so it can be a program name with args. | |
3299 | set dummy strip; ac_word=$2 | |
3300 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
3301 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 3302 | if ${ac_cv_prog_ac_ct_STRIP+:} false; then : |
743c80a7 PE |
3303 | $as_echo_n "(cached) " >&6 |
3304 | else | |
3305 | if test -n "$ac_ct_STRIP"; then | |
3306 | ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. | |
3307 | else | |
3308 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
3309 | for as_dir in $PATH | |
3310 | do | |
3311 | IFS=$as_save_IFS | |
3312 | test -z "$as_dir" && as_dir=. | |
3313 | for ac_exec_ext in '' $ac_executable_extensions; do | |
3314 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
3315 | ac_cv_prog_ac_ct_STRIP="strip" | |
3316 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
3317 | break 2 | |
3318 | fi | |
3319 | done | |
3320 | done | |
3321 | IFS=$as_save_IFS | |
3322 | ||
3323 | fi | |
3324 | fi | |
3325 | ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP | |
3326 | if test -n "$ac_ct_STRIP"; then | |
3327 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 | |
3328 | $as_echo "$ac_ct_STRIP" >&6; } | |
3329 | else | |
3330 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
3331 | $as_echo "no" >&6; } | |
3332 | fi | |
3333 | ||
3334 | if test "x$ac_ct_STRIP" = x; then | |
3335 | STRIP=":" | |
3336 | else | |
3337 | case $cross_compiling:$ac_tool_warned in | |
3338 | yes:) | |
3339 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
3340 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
3341 | ac_tool_warned=yes ;; | |
3342 | esac | |
3343 | STRIP=$ac_ct_STRIP | |
3344 | fi | |
3345 | else | |
3346 | STRIP="$ac_cv_prog_STRIP" | |
3347 | fi | |
3348 | ||
3349 | fi | |
3350 | INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" | |
3351 | ||
3352 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 | |
3353 | $as_echo_n "checking for a thread-safe mkdir -p... " >&6; } | |
3354 | if test -z "$MKDIR_P"; then | |
d6974efa | 3355 | if ${ac_cv_path_mkdir+:} false; then : |
743c80a7 PE |
3356 | $as_echo_n "(cached) " >&6 |
3357 | else | |
3358 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
3359 | for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin | |
3360 | do | |
3361 | IFS=$as_save_IFS | |
3362 | test -z "$as_dir" && as_dir=. | |
3363 | for ac_prog in mkdir gmkdir; do | |
3364 | for ac_exec_ext in '' $ac_executable_extensions; do | |
3365 | { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue | |
3366 | case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( | |
3367 | 'mkdir (GNU coreutils) '* | \ | |
3368 | 'mkdir (coreutils) '* | \ | |
3369 | 'mkdir (fileutils) '4.1*) | |
3370 | ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext | |
3371 | break 3;; | |
3372 | esac | |
3373 | done | |
3374 | done | |
3375 | done | |
3376 | IFS=$as_save_IFS | |
3377 | ||
3378 | fi | |
3379 | ||
3380 | test -d ./--version && rmdir ./--version | |
3381 | if test "${ac_cv_path_mkdir+set}" = set; then | |
3382 | MKDIR_P="$ac_cv_path_mkdir -p" | |
3383 | else | |
3384 | # As a last resort, use the slow shell script. Don't cache a | |
3385 | # value for MKDIR_P within a source directory, because that will | |
3386 | # break other packages using the cache if that directory is | |
3387 | # removed, or if the value is a relative name. | |
3388 | MKDIR_P="$ac_install_sh -d" | |
3389 | fi | |
3390 | fi | |
3391 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 | |
3392 | $as_echo "$MKDIR_P" >&6; } | |
3393 | ||
a451f14b | 3394 | |
743c80a7 PE |
3395 | mkdir_p="$MKDIR_P" |
3396 | case $mkdir_p in | |
3397 | [\\/$]* | ?:[\\/]*) ;; | |
3398 | */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; | |
3399 | esac | |
3400 | ||
3401 | for ac_prog in gawk mawk nawk awk | |
3402 | do | |
3403 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
3404 | set dummy $ac_prog; ac_word=$2 | |
3405 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
3406 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 3407 | if ${ac_cv_prog_AWK+:} false; then : |
743c80a7 PE |
3408 | $as_echo_n "(cached) " >&6 |
3409 | else | |
3410 | if test -n "$AWK"; then | |
3411 | ac_cv_prog_AWK="$AWK" # Let the user override the test. | |
3412 | else | |
3413 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
3414 | for as_dir in $PATH | |
3415 | do | |
3416 | IFS=$as_save_IFS | |
3417 | test -z "$as_dir" && as_dir=. | |
3418 | for ac_exec_ext in '' $ac_executable_extensions; do | |
3419 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
3420 | ac_cv_prog_AWK="$ac_prog" | |
3421 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
3422 | break 2 | |
3423 | fi | |
3424 | done | |
3425 | done | |
3426 | IFS=$as_save_IFS | |
3427 | ||
3428 | fi | |
3429 | fi | |
3430 | AWK=$ac_cv_prog_AWK | |
3431 | if test -n "$AWK"; then | |
3432 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 | |
3433 | $as_echo "$AWK" >&6; } | |
3434 | else | |
3435 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
3436 | $as_echo "no" >&6; } | |
3437 | fi | |
3438 | ||
3439 | ||
3440 | test -n "$AWK" && break | |
3441 | done | |
3442 | ||
3443 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 | |
3444 | $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } | |
3445 | set x ${MAKE-make} | |
3446 | ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` | |
d6974efa | 3447 | if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : |
743c80a7 PE |
3448 | $as_echo_n "(cached) " >&6 |
3449 | else | |
3450 | cat >conftest.make <<\_ACEOF | |
3451 | SHELL = /bin/sh | |
3452 | all: | |
3453 | @echo '@@@%%%=$(MAKE)=@@@%%%' | |
3454 | _ACEOF | |
3455 | # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. | |
3456 | case `${MAKE-make} -f conftest.make 2>/dev/null` in | |
3457 | *@@@%%%=?*=@@@%%%*) | |
3458 | eval ac_cv_prog_make_${ac_make}_set=yes;; | |
3459 | *) | |
3460 | eval ac_cv_prog_make_${ac_make}_set=no;; | |
3461 | esac | |
3462 | rm -f conftest.make | |
3463 | fi | |
3464 | if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then | |
3465 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
3466 | $as_echo "yes" >&6; } | |
3467 | SET_MAKE= | |
3468 | else | |
3469 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
3470 | $as_echo "no" >&6; } | |
3471 | SET_MAKE="MAKE=${MAKE-make}" | |
3472 | fi | |
3473 | ||
3474 | rm -rf .tst 2>/dev/null | |
3475 | mkdir .tst 2>/dev/null | |
3476 | if test -d .tst; then | |
3477 | am__leading_dot=. | |
3478 | else | |
3479 | am__leading_dot=_ | |
3480 | fi | |
3481 | rmdir .tst 2>/dev/null | |
3482 | ||
3483 | if test "`cd $srcdir && pwd`" != "`pwd`"; then | |
3484 | # Use -I$(srcdir) only when $(srcdir) != ., so that make's output | |
3485 | # is not polluted with repeated "-I." | |
3486 | am__isrc=' -I$(srcdir)' | |
3487 | # test to see if srcdir already configured | |
3488 | if test -f $srcdir/config.status; then | |
3489 | as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 | |
3490 | fi | |
3491 | fi | |
3492 | ||
3493 | # test whether we have cygpath | |
3494 | if test -z "$CYGPATH_W"; then | |
3495 | if (cygpath --version) >/dev/null 2>/dev/null; then | |
3496 | CYGPATH_W='cygpath -w' | |
3497 | else | |
3498 | CYGPATH_W=echo | |
3499 | fi | |
3500 | fi | |
3501 | ||
3502 | ||
3503 | # Define the identity of the package. | |
3504 | PACKAGE='emacs' | |
3505 | VERSION='24.0.50' | |
3506 | ||
3507 | ||
3508 | cat >>confdefs.h <<_ACEOF | |
3509 | #define PACKAGE "$PACKAGE" | |
3510 | _ACEOF | |
3511 | ||
3512 | ||
3513 | cat >>confdefs.h <<_ACEOF | |
3514 | #define VERSION "$VERSION" | |
3515 | _ACEOF | |
3516 | ||
3517 | # Some tools Automake needs. | |
3518 | ||
3519 | ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} | |
3520 | ||
3521 | ||
3522 | AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} | |
3523 | ||
3524 | ||
3525 | AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} | |
3526 | ||
3527 | ||
3528 | AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} | |
3529 | ||
3530 | ||
3531 | MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} | |
3532 | ||
3533 | # We need awk for the "check" target. The system "awk" is bad on | |
3534 | # some platforms. | |
3535 | # Always define AMTAR for backward compatibility. | |
3536 | ||
3537 | AMTAR=${AMTAR-"${am_missing_run}tar"} | |
3538 | ||
3539 | am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -' | |
3540 | ||
3541 | ||
3542 | ||
3543 | ||
3544 | ||
3545 | ||
3546 | ||
3547 | ||
3548 | lispdir='${datadir}/emacs/${version}/lisp' | |
3549 | locallisppath='${datadir}/emacs/${version}/site-lisp:'\ | |
3550 | '${datadir}/emacs/site-lisp' | |
3551 | lisppath='${locallisppath}:${lispdir}:${datadir}/emacs/${version}/leim' | |
3552 | etcdir='${datadir}/emacs/${version}/etc' | |
3553 | archlibdir='${libexecdir}/emacs/${version}/${configuration}' | |
3554 | docdir='${datadir}/emacs/${version}/etc' | |
3555 | gamedir='${localstatedir}/games/emacs' | |
3556 | ||
3557 | ||
3558 | ||
3559 | ||
3560 | # Check whether --with-pop was given. | |
3561 | if test "${with_pop+set}" = set; then : | |
3562 | withval=$with_pop; | |
3563 | else | |
3564 | with_pop=yes | |
3565 | fi | |
3566 | ||
3567 | if test "$with_pop" = yes; then | |
3568 | $as_echo "#define MAIL_USE_POP 1" >>confdefs.h | |
3569 | ||
3570 | fi | |
3571 | ||
3572 | ||
3573 | # Check whether --with-kerberos was given. | |
3574 | if test "${with_kerberos+set}" = set; then : | |
3575 | withval=$with_kerberos; | |
3576 | else | |
3577 | with_kerberos=no | |
3578 | fi | |
3579 | ||
3580 | if test "$with_kerberos" != no; then | |
3581 | $as_echo "#define KERBEROS 1" >>confdefs.h | |
3582 | ||
3583 | fi | |
3584 | ||
3585 | ||
3586 | # Check whether --with-kerberos5 was given. | |
3587 | if test "${with_kerberos5+set}" = set; then : | |
3588 | withval=$with_kerberos5; | |
3589 | else | |
3590 | with_kerberos5=no | |
3591 | fi | |
3592 | ||
3593 | if test "${with_kerberos5}" != no; then | |
3594 | if test "${with_kerberos}" = no; then | |
3595 | with_kerberos=yes | |
3596 | $as_echo "#define KERBEROS 1" >>confdefs.h | |
3597 | ||
3598 | fi | |
3599 | ||
3600 | $as_echo "#define KERBEROS5 1" >>confdefs.h | |
3601 | ||
3602 | fi | |
3603 | ||
3604 | ||
3605 | # Check whether --with-hesiod was given. | |
3606 | if test "${with_hesiod+set}" = set; then : | |
3607 | withval=$with_hesiod; | |
3608 | else | |
3609 | with_hesiod=no | |
3610 | fi | |
3611 | ||
3612 | if test "$with_hesiod" != no; then | |
3613 | ||
3614 | $as_echo "#define HESIOD 1" >>confdefs.h | |
3615 | ||
3616 | fi | |
3617 | ||
3618 | ||
3619 | # Check whether --with-mmdf was given. | |
3620 | if test "${with_mmdf+set}" = set; then : | |
3621 | withval=$with_mmdf; | |
3622 | else | |
3623 | with_mmdf=no | |
3624 | fi | |
3625 | ||
3626 | if test "$with_mmdf" != no; then | |
3627 | ||
3628 | $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h | |
3629 | ||
3630 | fi | |
3631 | ||
3632 | ||
3633 | # Check whether --with-mail-unlink was given. | |
3634 | if test "${with_mail_unlink+set}" = set; then : | |
3635 | withval=$with_mail_unlink; | |
3636 | else | |
3637 | with_mail_unlink=no | |
3638 | fi | |
3639 | ||
3640 | if test "$with_mail_unlink" != no; then | |
3641 | ||
3642 | $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h | |
3643 | ||
3644 | fi | |
3645 | ||
3646 | ||
3647 | # Check whether --with-mailhost was given. | |
3648 | if test "${with_mailhost+set}" = set; then : | |
3649 | withval=$with_mailhost; | |
3650 | cat >>confdefs.h <<_ACEOF | |
3651 | #define MAILHOST "$withval" | |
3652 | _ACEOF | |
3653 | ||
3654 | fi | |
3655 | ||
3656 | ||
3657 | ||
067d23c9 KY |
3658 | # Check whether --with-sound was given. |
3659 | if test "${with_sound+set}" = set; then : | |
3660 | withval=$with_sound; | |
3661 | else | |
3662 | with_sound=yes | |
3663 | fi | |
3664 | ||
3665 | ||
3666 | ||
3667 | # Check whether --with-sync-input was given. | |
3668 | if test "${with_sync_input+set}" = set; then : | |
3669 | withval=$with_sync_input; | |
3670 | else | |
3671 | with_sync_input=yes | |
3672 | fi | |
3673 | ||
3674 | if test "$with_sync_input" = yes; then | |
3675 | ||
3676 | $as_echo "#define SYNC_INPUT 1" >>confdefs.h | |
3677 | ||
3678 | fi | |
3679 | ||
3680 | ||
3681 | # Check whether --with-x-toolkit was given. | |
3682 | if test "${with_x_toolkit+set}" = set; then : | |
3683 | withval=$with_x_toolkit; case "${withval}" in | |
3684 | y | ye | yes ) val=gtk ;; | |
3685 | n | no ) val=no ;; | |
3686 | l | lu | luc | luci | lucid ) val=lucid ;; | |
3687 | a | at | ath | athe | athen | athena ) val=athena ;; | |
3688 | m | mo | mot | moti | motif ) val=motif ;; | |
3689 | g | gt | gtk ) val=gtk ;; | |
3690 | gtk3 ) val=gtk3 ;; | |
3691 | * ) | |
2018939f | 3692 | as_fn_error $? "\`--with-x-toolkit=$withval' is invalid; |
067d23c9 KY |
3693 | this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk' or |
3694 | \`gtk3'. \`yes' and \`gtk' are synonyms. \`athena' and \`lucid' are synonyms." "$LINENO" 5 | |
3695 | ;; | |
3696 | esac | |
3697 | with_x_toolkit=$val | |
3698 | ||
3699 | fi | |
3700 | ||
3701 | ||
3702 | ||
3703 | # Check whether --with-xpm was given. | |
3704 | if test "${with_xpm+set}" = set; then : | |
3705 | withval=$with_xpm; | |
3706 | else | |
3707 | with_xpm=yes | |
3708 | fi | |
3709 | ||
3710 | ||
3711 | # Check whether --with-jpeg was given. | |
3712 | if test "${with_jpeg+set}" = set; then : | |
3713 | withval=$with_jpeg; | |
3714 | else | |
3715 | with_jpeg=yes | |
3716 | fi | |
3717 | ||
3718 | ||
3719 | # Check whether --with-tiff was given. | |
3720 | if test "${with_tiff+set}" = set; then : | |
3721 | withval=$with_tiff; | |
3722 | else | |
3723 | with_tiff=yes | |
3724 | fi | |
3725 | ||
3726 | ||
3727 | # Check whether --with-gif was given. | |
3728 | if test "${with_gif+set}" = set; then : | |
3729 | withval=$with_gif; | |
3730 | else | |
3731 | with_gif=yes | |
3732 | fi | |
3733 | ||
3734 | ||
3735 | # Check whether --with-png was given. | |
3736 | if test "${with_png+set}" = set; then : | |
3737 | withval=$with_png; | |
3738 | else | |
3739 | with_png=yes | |
3740 | fi | |
3741 | ||
3742 | ||
3743 | # Check whether --with-rsvg was given. | |
3744 | if test "${with_rsvg+set}" = set; then : | |
3745 | withval=$with_rsvg; | |
3746 | else | |
3747 | with_rsvg=yes | |
3748 | fi | |
3749 | ||
3750 | ||
3751 | # Check whether --with-xml2 was given. | |
3752 | if test "${with_xml2+set}" = set; then : | |
3753 | withval=$with_xml2; | |
3754 | else | |
3755 | with_xml2=yes | |
3756 | fi | |
3757 | ||
3758 | ||
3759 | # Check whether --with-imagemagick was given. | |
3760 | if test "${with_imagemagick+set}" = set; then : | |
3761 | withval=$with_imagemagick; | |
3762 | else | |
3763 | with_imagemagick=yes | |
3764 | fi | |
3765 | ||
3766 | ||
3767 | ||
3768 | # Check whether --with-xft was given. | |
3769 | if test "${with_xft+set}" = set; then : | |
3770 | withval=$with_xft; | |
3771 | else | |
3772 | with_xft=yes | |
3773 | fi | |
3774 | ||
3775 | ||
3776 | # Check whether --with-libotf was given. | |
3777 | if test "${with_libotf+set}" = set; then : | |
3778 | withval=$with_libotf; | |
3779 | else | |
3780 | with_libotf=yes | |
3781 | fi | |
3782 | ||
3783 | ||
3784 | # Check whether --with-m17n-flt was given. | |
3785 | if test "${with_m17n_flt+set}" = set; then : | |
3786 | withval=$with_m17n_flt; | |
3787 | else | |
3788 | with_m17n_flt=yes | |
3789 | fi | |
3790 | ||
3791 | ||
3792 | ||
3793 | # Check whether --with-toolkit-scroll-bars was given. | |
3794 | if test "${with_toolkit_scroll_bars+set}" = set; then : | |
3795 | withval=$with_toolkit_scroll_bars; | |
3796 | else | |
3797 | with_toolkit_scroll_bars=yes | |
3798 | fi | |
3799 | ||
3800 | ||
3801 | # Check whether --with-xaw3d was given. | |
3802 | if test "${with_xaw3d+set}" = set; then : | |
3803 | withval=$with_xaw3d; | |
3804 | else | |
3805 | with_xaw3d=yes | |
3806 | fi | |
3807 | ||
3808 | ||
3809 | # Check whether --with-xim was given. | |
3810 | if test "${with_xim+set}" = set; then : | |
3811 | withval=$with_xim; | |
3812 | else | |
3813 | with_xim=yes | |
3814 | fi | |
3815 | ||
3816 | ||
3817 | # Check whether --with-ns was given. | |
3818 | if test "${with_ns+set}" = set; then : | |
3819 | withval=$with_ns; | |
3820 | else | |
3821 | with_ns=no | |
3822 | fi | |
3823 | ||
3824 | ||
3825 | ||
3826 | # Check whether --with-gpm was given. | |
3827 | if test "${with_gpm+set}" = set; then : | |
3828 | withval=$with_gpm; | |
3829 | else | |
3830 | with_gpm=yes | |
3831 | fi | |
3832 | ||
3833 | ||
3834 | # Check whether --with-dbus was given. | |
3835 | if test "${with_dbus+set}" = set; then : | |
3836 | withval=$with_dbus; | |
3837 | else | |
3838 | with_dbus=yes | |
3839 | fi | |
3840 | ||
3841 | ||
3842 | # Check whether --with-gconf was given. | |
3843 | if test "${with_gconf+set}" = set; then : | |
3844 | withval=$with_gconf; | |
3845 | else | |
3846 | with_gconf=yes | |
3847 | fi | |
3848 | ||
3849 | ||
3850 | # Check whether --with-selinux was given. | |
3851 | if test "${with_selinux+set}" = set; then : | |
3852 | withval=$with_selinux; | |
3853 | else | |
3854 | with_selinux=yes | |
3855 | fi | |
3856 | ||
3857 | ||
3858 | # Check whether --with-gnutls was given. | |
3859 | if test "${with_gnutls+set}" = set; then : | |
3860 | withval=$with_gnutls; | |
3861 | else | |
3862 | with_gnutls=yes | |
3863 | fi | |
3864 | ||
3865 | ||
3866 | ## For the times when you want to build Emacs but don't have | |
3867 | ## a suitable makeinfo, and can live without the manuals. | |
3868 | ||
3869 | # Check whether --with-makeinfo was given. | |
3870 | if test "${with_makeinfo+set}" = set; then : | |
3871 | withval=$with_makeinfo; | |
3872 | else | |
3873 | with_makeinfo=yes | |
3874 | fi | |
3875 | ||
3876 | ||
3877 | ## This is an option because I do not know if all info/man support | |
3878 | ## compressed files, nor how to test if they do so. | |
3879 | ||
3880 | # Check whether --with-compress-info was given. | |
3881 | if test "${with_compress_info+set}" = set; then : | |
3882 | withval=$with_compress_info; | |
3883 | else | |
3884 | with_compress_info=yes | |
3885 | fi | |
3886 | ||
3887 | if test $with_compress_info = yes; then | |
3888 | GZIP_INFO=yes | |
3889 | else | |
3890 | GZIP_INFO= | |
3891 | fi | |
3892 | ||
3893 | ||
3894 | ||
3895 | # Check whether --with-pkg-config-prog was given. | |
3896 | if test "${with_pkg_config_prog+set}" = set; then : | |
3897 | withval=$with_pkg_config_prog; | |
3898 | fi | |
3899 | ||
3900 | if test "X${with_pkg_config_prog}" != X; then | |
3901 | if test "${with_pkg_config_prog}" != yes; then | |
3902 | PKG_CONFIG="${with_pkg_config_prog}" | |
3903 | fi | |
3904 | fi | |
3905 | ||
3906 | CRT_DIR= | |
3907 | ||
3908 | # Check whether --with-crt-dir was given. | |
3909 | if test "${with_crt_dir+set}" = set; then : | |
3910 | withval=$with_crt_dir; | |
3911 | fi | |
3912 | ||
3913 | CRT_DIR="${with_crt_dir}" | |
3914 | ||
3915 | ||
4fc5868a UM |
3916 | # Check whether --with-gameuser was given. |
3917 | if test "${with_gameuser+set}" = set; then : | |
3918 | withval=$with_gameuser; | |
3919 | fi | |
3920 | ||
3921 | test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \ | |
3922 | && gameuser="${with_gameuser}" | |
3923 | test "X$gameuser" = X && gameuser=games | |
3924 | ||
3925 | ||
067d23c9 KY |
3926 | # Check whether --with-gnustep-conf was given. |
3927 | if test "${with_gnustep_conf+set}" = set; then : | |
3928 | withval=$with_gnustep_conf; | |
3929 | fi | |
3930 | ||
3931 | test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \ | |
3932 | GNUSTEP_CONFIG_FILE="${with_gnustep_conf}" | |
3933 | test "X$GNUSTEP_CONFIG_FILE" = "X" && \ | |
3934 | GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf | |
3935 | ||
3936 | # Check whether --enable-ns-self-contained was given. | |
3937 | if test "${enable_ns_self_contained+set}" = set; then : | |
3938 | enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval | |
3939 | else | |
3940 | EN_NS_SELF_CONTAINED=yes | |
3941 | fi | |
3942 | ||
3943 | ||
3944 | # Check whether --enable-asserts was given. | |
3945 | if test "${enable_asserts+set}" = set; then : | |
3946 | enableval=$enable_asserts; USE_XASSERTS=$enableval | |
3947 | else | |
3948 | USE_XASSERTS=no | |
3949 | fi | |
3950 | ||
3951 | ||
3952 | # Check whether --enable-maintainer-mode was given. | |
3953 | if test "${enable_maintainer_mode+set}" = set; then : | |
3954 | enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval | |
3955 | else | |
3956 | USE_MAINTAINER_MODE=no | |
3957 | fi | |
3958 | ||
3959 | if test $USE_MAINTAINER_MODE = yes; then | |
3960 | MAINT= | |
3961 | else | |
3962 | MAINT=# | |
3963 | fi | |
3964 | ||
3965 | ||
3966 | # Check whether --enable-locallisppath was given. | |
3967 | if test "${enable_locallisppath+set}" = set; then : | |
3968 | enableval=$enable_locallisppath; if test "${enableval}" = "no"; then | |
3969 | locallisppath= | |
3970 | elif test "${enableval}" != "yes"; then | |
3971 | locallisppath=${enableval} | |
3972 | fi | |
3973 | fi | |
3974 | ||
3975 | ||
3976 | # Check whether --enable-checking was given. | |
3977 | if test "${enable_checking+set}" = set; then : | |
3978 | enableval=$enable_checking; ac_checking_flags="${enableval}" | |
3979 | fi | |
3980 | ||
3981 | IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS," | |
3982 | for check in $ac_checking_flags | |
3983 | do | |
3984 | case $check in | |
3985 | # these set all the flags to specific states | |
3986 | yes) ac_enable_checking=1 ;; | |
3987 | no) ac_enable_checking= ; | |
3988 | ac_gc_check_stringbytes= ; | |
3989 | ac_gc_check_string_overrun= ; | |
3990 | ac_gc_check_string_free_list= ; | |
3991 | ac_xmalloc_overrun= ; | |
3992 | ac_gc_check_cons_list= ;; | |
3993 | all) ac_enable_checking=1 ; | |
3994 | ac_gc_check_stringbytes=1 ; | |
3995 | ac_gc_check_string_overrun=1 ; | |
3996 | ac_gc_check_string_free_list=1 ; | |
3997 | ac_xmalloc_overrun=1 ; | |
3998 | ac_gc_check_cons_list=1 ;; | |
3999 | # these enable particular checks | |
4000 | stringbytes) ac_gc_check_stringbytes=1 ;; | |
4001 | stringoverrun) ac_gc_check_string_overrun=1 ;; | |
4002 | stringfreelist) ac_gc_check_string_free_list=1 ;; | |
4003 | xmallocoverrun) ac_xmalloc_overrun=1 ;; | |
4004 | conslist) ac_gc_check_cons_list=1 ;; | |
d6974efa | 4005 | *) as_fn_error $? "unknown check category $check" "$LINENO" 5 ;; |
067d23c9 KY |
4006 | esac |
4007 | done | |
4008 | IFS="$ac_save_IFS" | |
4009 | ||
4010 | if test x$ac_enable_checking != x ; then | |
4011 | ||
4012 | $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h | |
4013 | ||
4014 | fi | |
4015 | if test x$ac_gc_check_stringbytes != x ; then | |
4016 | ||
4017 | $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h | |
4018 | ||
4019 | fi | |
4020 | if test x$ac_gc_check_stringoverrun != x ; then | |
4021 | ||
4022 | $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h | |
4023 | ||
4024 | fi | |
4025 | if test x$ac_gc_check_string_free_list != x ; then | |
4026 | ||
4027 | $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h | |
4028 | ||
4029 | fi | |
4030 | if test x$ac_xmalloc_overrun != x ; then | |
4031 | ||
4032 | $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h | |
4033 | ||
4034 | fi | |
4035 | if test x$ac_gc_check_cons_list != x ; then | |
4036 | ||
4037 | $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h | |
4038 | ||
4039 | fi | |
4040 | ||
4041 | # Check whether --enable-use-lisp-union-type was given. | |
4042 | if test "${enable_use_lisp_union_type+set}" = set; then : | |
4043 | enableval=$enable_use_lisp_union_type; if test "${enableval}" != "no"; then | |
4044 | ||
4045 | $as_echo "#define USE_LISP_UNION_TYPE 1" >>confdefs.h | |
4046 | ||
4047 | fi | |
4048 | fi | |
4049 | ||
4050 | ||
4051 | ||
4052 | # Check whether --enable-profiling was given. | |
4053 | if test "${enable_profiling+set}" = set; then : | |
4054 | enableval=$enable_profiling; ac_enable_profiling="${enableval}" | |
4055 | fi | |
4056 | ||
4057 | if test x$ac_enable_profiling != x ; then | |
4058 | PROFILING_CFLAGS="-DPROFILING=1 -pg" | |
4059 | else | |
4060 | PROFILING_CFLAGS= | |
4061 | fi | |
4062 | ||
4063 | ||
4064 | # Check whether --enable-autodepend was given. | |
4065 | if test "${enable_autodepend+set}" = set; then : | |
4066 | enableval=$enable_autodepend; ac_enable_autodepend="${enableval}" | |
4067 | else | |
4068 | ac_enable_autodepend=yes | |
4069 | fi | |
4070 | ||
4071 | ||
4072 | #### Make srcdir absolute, if it isn't already. It's important to | |
4073 | #### avoid running the path through pwd unnecessarily, since pwd can | |
4074 | #### give you automounter prefixes, which can go away. We do all this | |
4075 | #### so Emacs can find its files when run uninstalled. | |
4076 | ## Make sure CDPATH doesn't affect cd (in case PWD is relative). | |
4077 | unset CDPATH | |
4078 | case "${srcdir}" in | |
4079 | /* ) ;; | |
4080 | . ) | |
4081 | ## We may be able to use the $PWD environment variable to make this | |
4082 | ## absolute. But sometimes PWD is inaccurate. | |
4083 | ## Note: we used to use ${PWD} at the end instead of `pwd`, | |
4084 | ## but that tested only for a well-formed and valid PWD, | |
4085 | ## it did not object when PWD was well-formed and valid but just wrong. | |
4086 | if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ; | |
4087 | then | |
4088 | srcdir="$PWD" | |
4089 | else | |
4090 | srcdir="`(cd ${srcdir}; pwd)`" | |
4091 | fi | |
4092 | ;; | |
4093 | * ) srcdir="`(cd ${srcdir}; pwd)`" ;; | |
4094 | esac | |
4095 | ||
4096 | #### Check if the source directory already has a configured system in it. | |
4097 | if test `pwd` != `(cd ${srcdir} && pwd)` \ | |
4098 | && test -f "${srcdir}/src/config.h" ; then | |
4099 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The directory tree \`${srcdir}' is being used | |
4100 | as a build directory right now; it has been configured in its own | |
4101 | right. To configure in another directory as well, you MUST | |
4102 | use GNU make. If you do not have GNU make, then you must | |
4103 | now do \`make distclean' in ${srcdir}, | |
4104 | and then run $0 again." >&5 | |
4105 | $as_echo "$as_me: WARNING: The directory tree \`${srcdir}' is being used | |
4106 | as a build directory right now; it has been configured in its own | |
4107 | right. To configure in another directory as well, you MUST | |
4108 | use GNU make. If you do not have GNU make, then you must | |
4109 | now do \`make distclean' in ${srcdir}, | |
4110 | and then run $0 again." >&2;} | |
4111 | fi | |
4112 | ||
4113 | #### Given the configuration name, set machfile and opsysfile to the | |
4114 | #### names of the m/*.h and s/*.h files we should use. | |
4115 | ||
4116 | ### Canonicalize the configuration name. | |
4117 | ||
067d23c9 KY |
4118 | # Make sure we can run config.sub. |
4119 | $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || | |
2018939f | 4120 | as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 |
067d23c9 KY |
4121 | |
4122 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 | |
4123 | $as_echo_n "checking build system type... " >&6; } | |
d6974efa | 4124 | if ${ac_cv_build+:} false; then : |
067d23c9 KY |
4125 | $as_echo_n "(cached) " >&6 |
4126 | else | |
4127 | ac_build_alias=$build_alias | |
4128 | test "x$ac_build_alias" = x && | |
4129 | ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` | |
4130 | test "x$ac_build_alias" = x && | |
2018939f | 4131 | as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 |
067d23c9 | 4132 | ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || |
2018939f | 4133 | as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 |
067d23c9 KY |
4134 | |
4135 | fi | |
4136 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 | |
4137 | $as_echo "$ac_cv_build" >&6; } | |
4138 | case $ac_cv_build in | |
4139 | *-*-*) ;; | |
d6974efa | 4140 | *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; |
067d23c9 KY |
4141 | esac |
4142 | build=$ac_cv_build | |
4143 | ac_save_IFS=$IFS; IFS='-' | |
4144 | set x $ac_cv_build | |
4145 | shift | |
4146 | build_cpu=$1 | |
4147 | build_vendor=$2 | |
4148 | shift; shift | |
4149 | # Remember, the first character of IFS is used to create $*, | |
4150 | # except with old shells: | |
4151 | build_os=$* | |
4152 | IFS=$ac_save_IFS | |
4153 | case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac | |
4154 | ||
4155 | ||
4156 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 | |
4157 | $as_echo_n "checking host system type... " >&6; } | |
d6974efa | 4158 | if ${ac_cv_host+:} false; then : |
067d23c9 KY |
4159 | $as_echo_n "(cached) " >&6 |
4160 | else | |
4161 | if test "x$host_alias" = x; then | |
4162 | ac_cv_host=$ac_cv_build | |
4163 | else | |
4164 | ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || | |
2018939f | 4165 | as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 |
067d23c9 KY |
4166 | fi |
4167 | ||
4168 | fi | |
4169 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 | |
4170 | $as_echo "$ac_cv_host" >&6; } | |
4171 | case $ac_cv_host in | |
4172 | *-*-*) ;; | |
d6974efa | 4173 | *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; |
067d23c9 KY |
4174 | esac |
4175 | host=$ac_cv_host | |
4176 | ac_save_IFS=$IFS; IFS='-' | |
4177 | set x $ac_cv_host | |
4178 | shift | |
4179 | host_cpu=$1 | |
4180 | host_vendor=$2 | |
4181 | shift; shift | |
4182 | # Remember, the first character of IFS is used to create $*, | |
4183 | # except with old shells: | |
4184 | host_os=$* | |
4185 | IFS=$ac_save_IFS | |
4186 | case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac | |
4187 | ||
4188 | ||
4189 | canonical=$host | |
4190 | configuration=${host_alias-${build_alias-$host}} | |
4191 | ||
4192 | ||
4193 | ||
4194 | ### If you add support for a new configuration, add code to this | |
4195 | ### switch statement to recognize your configuration name and select | |
4196 | ### the appropriate operating system and machine description files. | |
4197 | ||
4198 | ### You would hope that you could choose an m/*.h file pretty much | |
4199 | ### based on the machine portion of the configuration name, and an s/*.h | |
4200 | ### file based on the operating system portion. However, it turns out | |
4201 | ### that each m/*.h file is pretty manufacturer-specific - for | |
4202 | ### example mips.h is MIPS | |
4203 | ### So we basically have to have a special case for each | |
4204 | ### configuration name. | |
4205 | ### | |
4206 | ### As far as handling version numbers on operating systems is | |
4207 | ### concerned, make sure things will fail in a fixable way. If | |
4208 | ### /etc/MACHINES doesn't say anything about version numbers, be | |
4209 | ### prepared to handle anything reasonably. If version numbers | |
4210 | ### matter, be sure /etc/MACHINES says something about it. | |
4211 | ||
4212 | machine='' opsys='' unported=no | |
4213 | case "${canonical}" in | |
4214 | ||
d6a003a8 AS |
4215 | ## GNU/Linux ports |
4216 | *-*-linux-gnu*) | |
4217 | opsys=gnu-linux | |
4218 | case ${canonical} in | |
4219 | alpha*) machine=alpha ;; | |
4220 | s390-*) machine=ibms390 ;; | |
4221 | s390x-*) machine=ibms390x ;; | |
4222 | powerpc*) machine=macppc ;; | |
4223 | sparc*) machine=sparc ;; | |
4224 | ia64*) machine=ia64 ;; | |
4225 | m68k*) machine=m68k ;; | |
4226 | x86_64*) machine=amdx86-64 ;; | |
4227 | esac | |
4228 | ;; | |
4229 | ||
067d23c9 KY |
4230 | ## FreeBSD ports |
4231 | *-*-freebsd* ) | |
4232 | opsys=freebsd | |
4233 | case "${canonical}" in | |
4234 | alpha*) machine=alpha ;; | |
4235 | amd64-*|x86_64-*) machine=amdx86-64 ;; | |
067d23c9 KY |
4236 | ia64-*) machine=ia64 ;; |
4237 | i[3456]86-*) machine=intel386 ;; | |
4238 | powerpc-*) machine=macppc ;; | |
4239 | sparc-*) machine=sparc ;; | |
4240 | sparc64-*) machine=sparc ;; | |
4241 | esac | |
4242 | ;; | |
4243 | ||
4244 | ## FreeBSD kernel + glibc based userland | |
4245 | *-*-kfreebsd*gnu* ) | |
4246 | opsys=gnu-kfreebsd | |
4247 | case "${canonical}" in | |
4248 | alpha*) machine=alpha ;; | |
4249 | amd64-*|x86_64-*) machine=amdx86-64 ;; | |
4250 | ia64-*) machine=ia64 ;; | |
4251 | i[3456]86-*) machine=intel386 ;; | |
4252 | powerpc-*) machine=macppc ;; | |
4253 | sparc-*) machine=sparc ;; | |
4254 | sparc64-*) machine=sparc ;; | |
4255 | esac | |
4256 | ;; | |
4257 | ||
4258 | ## NetBSD ports | |
4259 | *-*-netbsd* ) | |
4260 | opsys=netbsd | |
4261 | case "${canonical}" in | |
4262 | alpha*) machine=alpha ;; | |
4263 | x86_64-*) machine=amdx86-64 ;; | |
067d23c9 KY |
4264 | i[3456]86-*) machine=intel386 ;; |
4265 | m68k-*) machine=m68k ;; | |
4266 | powerpc-*) machine=macppc ;; | |
067d23c9 KY |
4267 | sparc*-) machine=sparc ;; |
4268 | vax-*) machine=vax ;; | |
4269 | esac | |
4270 | ;; | |
4271 | ||
4272 | ## OpenBSD ports | |
4273 | *-*-openbsd* ) | |
4274 | opsys=openbsd | |
4275 | case "${canonical}" in | |
4276 | alpha*) machine=alpha ;; | |
4277 | x86_64-*) machine=amdx86-64 ;; | |
067d23c9 KY |
4278 | i386-*) machine=intel386 ;; |
4279 | powerpc-*) machine=macppc ;; | |
4280 | sparc*) machine=sparc ;; | |
4281 | vax-*) machine=vax ;; | |
4282 | esac | |
4283 | ;; | |
4284 | ||
067d23c9 KY |
4285 | ## Apple Darwin / Mac OS X |
4286 | *-apple-darwin* ) | |
4287 | case "${canonical}" in | |
4288 | i[3456]86-* ) machine=intel386 ;; | |
4289 | powerpc-* ) machine=macppc ;; | |
4290 | x86_64-* ) machine=amdx86-64 ;; | |
4291 | * ) unported=yes ;; | |
4292 | esac | |
4293 | opsys=darwin | |
4294 | # Define CPP as follows to make autoconf work correctly. | |
4295 | CPP="${CC-cc} -E -no-cpp-precomp" | |
4296 | # Use fink packages if available. | |
4297 | if test -d /sw/include && test -d /sw/lib; then | |
4298 | GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib" | |
4299 | CPP="${CPP} ${GCC_TEST_OPTIONS}" | |
4300 | NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS} | |
4301 | fi | |
4302 | ;; | |
4303 | ||
4304 | ## HP 9000 series 700 and 800, running HP/UX | |
4305 | hppa*-hp-hpux10.2* ) | |
d6a003a8 | 4306 | opsys=hpux10-20 |
067d23c9 KY |
4307 | ;; |
4308 | hppa*-hp-hpux1[1-9]* ) | |
d6a003a8 | 4309 | opsys=hpux11 |
067d23c9 KY |
4310 | CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS" |
4311 | ;; | |
4312 | ||
125c3718 PE |
4313 | ia64*-hp-hpux1[1-9]* ) |
4314 | machine=hp800 opsys=hpux11 | |
4315 | ## FIXME. Peter O'Gorman reports that dumping using unexelf.o doesn't | |
4316 | ## work either: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=6811 | |
4317 | CANNOT_DUMP=yes | |
4318 | ;; | |
4319 | ||
4320 | hppa*-*-linux-gnu* ) | |
4321 | machine=hp800 opsys=gnu-linux | |
4322 | ;; | |
4323 | ||
067d23c9 | 4324 | ## IBM machines |
067d23c9 KY |
4325 | rs6000-ibm-aix4.[23]* ) |
4326 | machine=ibmrs6000 opsys=aix4-2 | |
4327 | ;; | |
4328 | powerpc-ibm-aix4.[23]* ) | |
4329 | machine=ibmrs6000 opsys=aix4-2 | |
4330 | ;; | |
4331 | rs6000-ibm-aix[56]* ) | |
4332 | machine=ibmrs6000 opsys=aix4-2 | |
4333 | ;; | |
4334 | powerpc-ibm-aix[56]* ) | |
4335 | machine=ibmrs6000 opsys=aix4-2 | |
4336 | ;; | |
4337 | ||
067d23c9 KY |
4338 | ## Silicon Graphics machines |
4339 | ## Iris 4D | |
4340 | mips-sgi-irix6.5 ) | |
4341 | machine=iris4d opsys=irix6-5 | |
4342 | # Without defining _LANGUAGE_C, things get masked out in the headers | |
4343 | # so that, for instance, grepping for `free' in stdlib.h fails and | |
4344 | # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m). | |
4345 | NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C" | |
4346 | NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C" | |
4347 | ;; | |
4348 | ||
4349 | ## Suns | |
067d23c9 KY |
4350 | *-sun-solaris* \ |
4351 | | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \ | |
4352 | | x86_64-*-solaris2* | x86_64-*-sunos5*) | |
4353 | case "${canonical}" in | |
4354 | i[3456]86-*-* ) machine=intel386 ;; | |
4355 | amd64-*-*|x86_64-*-*) machine=amdx86-64 ;; | |
4356 | sparc* ) machine=sparc ;; | |
4357 | * ) unported=yes ;; | |
4358 | esac | |
4359 | case "${canonical}" in | |
4360 | *-sunos5.6* | *-solaris2.6* ) | |
4361 | opsys=sol2-6 | |
4362 | NON_GNU_CPP=/usr/ccs/lib/cpp | |
4363 | RANLIB="ar -ts" | |
4364 | ;; | |
4365 | *-sunos5.[7-9]* | *-solaris2.[7-9]* ) | |
4366 | opsys=sol2-6 | |
4367 | emacs_check_sunpro_c=yes | |
4368 | NON_GNU_CPP=/usr/ccs/lib/cpp | |
4369 | ;; | |
4370 | *-sunos5* | *-solaris* ) | |
4371 | opsys=sol2-10 | |
4372 | emacs_check_sunpro_c=yes | |
4373 | NON_GNU_CPP=/usr/ccs/lib/cpp | |
4374 | ;; | |
4375 | esac | |
4376 | ## Watch out for a compiler that we know will not work. | |
4377 | case "${canonical}" in | |
4378 | *-solaris* | *-sunos5* ) | |
4379 | if [ "x$CC" = x/usr/ucb/cc ]; then | |
4380 | ## /usr/ucb/cc doesn't work; | |
4381 | ## we should find some other compiler that does work. | |
4382 | unset CC | |
4383 | fi | |
4384 | ;; | |
4385 | *) ;; | |
4386 | esac | |
4387 | ;; | |
4388 | ||
067d23c9 KY |
4389 | ## Intel 386 machines where we don't care about the manufacturer. |
4390 | i[3456]86-*-* ) | |
4391 | machine=intel386 | |
4392 | case "${canonical}" in | |
4393 | *-cygwin ) opsys=cygwin ;; | |
4394 | *-darwin* ) opsys=darwin | |
4395 | CPP="${CC-cc} -E -no-cpp-precomp" | |
4396 | ;; | |
067d23c9 KY |
4397 | *-sysv4.2uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;; |
4398 | *-sysv5uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;; | |
4399 | *-sysv5OpenUNIX* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;; | |
4400 | ## Otherwise, we'll fall through to the generic opsys code at the bottom. | |
4401 | esac | |
4402 | ;; | |
4403 | ||
067d23c9 KY |
4404 | * ) |
4405 | unported=yes | |
4406 | ;; | |
4407 | esac | |
4408 | ||
4409 | ### If the code above didn't choose an operating system, just choose | |
4410 | ### an operating system based on the configuration name. You really | |
4411 | ### only want to use this when you have no idea what the right | |
4412 | ### operating system is; if you know what operating systems a machine | |
4413 | ### runs, it's cleaner to make it explicit in the case statement | |
4414 | ### above. | |
4415 | if test x"${opsys}" = x; then | |
4416 | case "${canonical}" in | |
4417 | *-gnu* ) opsys=gnu ;; | |
4418 | * ) | |
4419 | unported=yes | |
4420 | ;; | |
4421 | esac | |
4422 | fi | |
4423 | ||
4424 | ||
4425 | ||
4426 | if test $unported = yes; then | |
2018939f | 4427 | as_fn_error $? "Emacs hasn't been ported to \`${canonical}' systems. |
067d23c9 KY |
4428 | Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5 |
4429 | fi | |
4430 | ||
d6a003a8 AS |
4431 | if test -n "$machine"; then |
4432 | machfile="m/${machine}.h" | |
4433 | else | |
4434 | machfile= | |
4435 | fi | |
067d23c9 KY |
4436 | opsysfile="s/${opsys}.h" |
4437 | ||
4438 | ||
4439 | #### Choose a compiler. | |
4440 | test -n "$CC" && cc_specified=yes | |
4441 | ||
4442 | # Save the value of CFLAGS that the user specified. | |
4443 | SPECIFIED_CFLAGS="$CFLAGS" | |
4444 | ||
4445 | ac_ext=c | |
4446 | ac_cpp='$CPP $CPPFLAGS' | |
4447 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4448 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4449 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
4450 | if test -n "$ac_tool_prefix"; then | |
4451 | # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. | |
4452 | set dummy ${ac_tool_prefix}gcc; ac_word=$2 | |
4453 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
4454 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 4455 | if ${ac_cv_prog_CC+:} false; then : |
067d23c9 KY |
4456 | $as_echo_n "(cached) " >&6 |
4457 | else | |
4458 | if test -n "$CC"; then | |
4459 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
4460 | else | |
4461 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4462 | for as_dir in $PATH | |
4463 | do | |
4464 | IFS=$as_save_IFS | |
4465 | test -z "$as_dir" && as_dir=. | |
4466 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4467 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
4468 | ac_cv_prog_CC="${ac_tool_prefix}gcc" | |
4469 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
4470 | break 2 | |
4471 | fi | |
4472 | done | |
4473 | done | |
4474 | IFS=$as_save_IFS | |
4475 | ||
4476 | fi | |
4477 | fi | |
4478 | CC=$ac_cv_prog_CC | |
4479 | if test -n "$CC"; then | |
4480 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 | |
4481 | $as_echo "$CC" >&6; } | |
4482 | else | |
4483 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4484 | $as_echo "no" >&6; } | |
4485 | fi | |
4486 | ||
4487 | ||
4488 | fi | |
4489 | if test -z "$ac_cv_prog_CC"; then | |
4490 | ac_ct_CC=$CC | |
4491 | # Extract the first word of "gcc", so it can be a program name with args. | |
4492 | set dummy gcc; ac_word=$2 | |
4493 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
4494 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 4495 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
067d23c9 KY |
4496 | $as_echo_n "(cached) " >&6 |
4497 | else | |
4498 | if test -n "$ac_ct_CC"; then | |
4499 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. | |
4500 | else | |
4501 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4502 | for as_dir in $PATH | |
4503 | do | |
4504 | IFS=$as_save_IFS | |
4505 | test -z "$as_dir" && as_dir=. | |
4506 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4507 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
4508 | ac_cv_prog_ac_ct_CC="gcc" | |
4509 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
4510 | break 2 | |
4511 | fi | |
4512 | done | |
4513 | done | |
4514 | IFS=$as_save_IFS | |
4515 | ||
4516 | fi | |
4517 | fi | |
4518 | ac_ct_CC=$ac_cv_prog_ac_ct_CC | |
4519 | if test -n "$ac_ct_CC"; then | |
4520 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 | |
4521 | $as_echo "$ac_ct_CC" >&6; } | |
4522 | else | |
4523 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4524 | $as_echo "no" >&6; } | |
4525 | fi | |
4526 | ||
4527 | if test "x$ac_ct_CC" = x; then | |
4528 | CC="" | |
4529 | else | |
4530 | case $cross_compiling:$ac_tool_warned in | |
4531 | yes:) | |
4532 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
4533 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
4534 | ac_tool_warned=yes ;; | |
4535 | esac | |
4536 | CC=$ac_ct_CC | |
4537 | fi | |
4538 | else | |
4539 | CC="$ac_cv_prog_CC" | |
4540 | fi | |
4541 | ||
4542 | if test -z "$CC"; then | |
4543 | if test -n "$ac_tool_prefix"; then | |
4544 | # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. | |
4545 | set dummy ${ac_tool_prefix}cc; ac_word=$2 | |
4546 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
4547 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 4548 | if ${ac_cv_prog_CC+:} false; then : |
067d23c9 KY |
4549 | $as_echo_n "(cached) " >&6 |
4550 | else | |
4551 | if test -n "$CC"; then | |
4552 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
4553 | else | |
4554 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4555 | for as_dir in $PATH | |
4556 | do | |
4557 | IFS=$as_save_IFS | |
4558 | test -z "$as_dir" && as_dir=. | |
4559 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4560 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
4561 | ac_cv_prog_CC="${ac_tool_prefix}cc" | |
4562 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
4563 | break 2 | |
4564 | fi | |
4565 | done | |
4566 | done | |
4567 | IFS=$as_save_IFS | |
4568 | ||
4569 | fi | |
4570 | fi | |
4571 | CC=$ac_cv_prog_CC | |
4572 | if test -n "$CC"; then | |
4573 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 | |
4574 | $as_echo "$CC" >&6; } | |
4575 | else | |
4576 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4577 | $as_echo "no" >&6; } | |
4578 | fi | |
4579 | ||
4580 | ||
4581 | fi | |
4582 | fi | |
4583 | if test -z "$CC"; then | |
4584 | # Extract the first word of "cc", so it can be a program name with args. | |
4585 | set dummy cc; ac_word=$2 | |
4586 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
4587 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 4588 | if ${ac_cv_prog_CC+:} false; then : |
067d23c9 KY |
4589 | $as_echo_n "(cached) " >&6 |
4590 | else | |
4591 | if test -n "$CC"; then | |
4592 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
4593 | else | |
4594 | ac_prog_rejected=no | |
4595 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4596 | for as_dir in $PATH | |
4597 | do | |
4598 | IFS=$as_save_IFS | |
4599 | test -z "$as_dir" && as_dir=. | |
4600 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4601 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
4602 | if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then | |
4603 | ac_prog_rejected=yes | |
4604 | continue | |
4605 | fi | |
4606 | ac_cv_prog_CC="cc" | |
4607 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
4608 | break 2 | |
4609 | fi | |
4610 | done | |
4611 | done | |
4612 | IFS=$as_save_IFS | |
4613 | ||
4614 | if test $ac_prog_rejected = yes; then | |
4615 | # We found a bogon in the path, so make sure we never use it. | |
4616 | set dummy $ac_cv_prog_CC | |
4617 | shift | |
4618 | if test $# != 0; then | |
4619 | # We chose a different compiler from the bogus one. | |
4620 | # However, it has the same basename, so the bogon will be chosen | |
4621 | # first if we set CC to just the basename; use the full file name. | |
4622 | shift | |
4623 | ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" | |
4624 | fi | |
4625 | fi | |
4626 | fi | |
4627 | fi | |
4628 | CC=$ac_cv_prog_CC | |
4629 | if test -n "$CC"; then | |
4630 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 | |
4631 | $as_echo "$CC" >&6; } | |
4632 | else | |
4633 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4634 | $as_echo "no" >&6; } | |
4635 | fi | |
4636 | ||
4637 | ||
4638 | fi | |
4639 | if test -z "$CC"; then | |
4640 | if test -n "$ac_tool_prefix"; then | |
4641 | for ac_prog in cl.exe | |
4642 | do | |
4643 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. | |
4644 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 | |
4645 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
4646 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 4647 | if ${ac_cv_prog_CC+:} false; then : |
067d23c9 KY |
4648 | $as_echo_n "(cached) " >&6 |
4649 | else | |
4650 | if test -n "$CC"; then | |
4651 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
4652 | else | |
4653 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4654 | for as_dir in $PATH | |
4655 | do | |
4656 | IFS=$as_save_IFS | |
4657 | test -z "$as_dir" && as_dir=. | |
4658 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4659 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
4660 | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" | |
4661 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
4662 | break 2 | |
4663 | fi | |
4664 | done | |
4665 | done | |
4666 | IFS=$as_save_IFS | |
4667 | ||
4668 | fi | |
4669 | fi | |
4670 | CC=$ac_cv_prog_CC | |
4671 | if test -n "$CC"; then | |
4672 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 | |
4673 | $as_echo "$CC" >&6; } | |
4674 | else | |
4675 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4676 | $as_echo "no" >&6; } | |
4677 | fi | |
4678 | ||
4679 | ||
4680 | test -n "$CC" && break | |
4681 | done | |
4682 | fi | |
4683 | if test -z "$CC"; then | |
4684 | ac_ct_CC=$CC | |
4685 | for ac_prog in cl.exe | |
4686 | do | |
4687 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
4688 | set dummy $ac_prog; ac_word=$2 | |
4689 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
4690 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 4691 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
067d23c9 KY |
4692 | $as_echo_n "(cached) " >&6 |
4693 | else | |
4694 | if test -n "$ac_ct_CC"; then | |
4695 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. | |
4696 | else | |
4697 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4698 | for as_dir in $PATH | |
4699 | do | |
4700 | IFS=$as_save_IFS | |
4701 | test -z "$as_dir" && as_dir=. | |
4702 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4703 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
4704 | ac_cv_prog_ac_ct_CC="$ac_prog" | |
4705 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
4706 | break 2 | |
4707 | fi | |
4708 | done | |
4709 | done | |
4710 | IFS=$as_save_IFS | |
4711 | ||
4712 | fi | |
4713 | fi | |
4714 | ac_ct_CC=$ac_cv_prog_ac_ct_CC | |
4715 | if test -n "$ac_ct_CC"; then | |
4716 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 | |
4717 | $as_echo "$ac_ct_CC" >&6; } | |
4718 | else | |
4719 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4720 | $as_echo "no" >&6; } | |
4721 | fi | |
4722 | ||
4723 | ||
4724 | test -n "$ac_ct_CC" && break | |
4725 | done | |
4726 | ||
4727 | if test "x$ac_ct_CC" = x; then | |
4728 | CC="" | |
4729 | else | |
4730 | case $cross_compiling:$ac_tool_warned in | |
4731 | yes:) | |
4732 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
4733 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
4734 | ac_tool_warned=yes ;; | |
4735 | esac | |
4736 | CC=$ac_ct_CC | |
4737 | fi | |
4738 | fi | |
4739 | ||
4740 | fi | |
4741 | ||
4742 | ||
4743 | test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
4744 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2018939f | 4745 | as_fn_error $? "no acceptable C compiler found in \$PATH |
d6974efa | 4746 | See \`config.log' for more details" "$LINENO" 5; } |
067d23c9 KY |
4747 | |
4748 | # Provide some information about the compiler. | |
4749 | $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 | |
4750 | set X $ac_compile | |
4751 | ac_compiler=$2 | |
4752 | for ac_option in --version -v -V -qversion; do | |
4753 | { { ac_try="$ac_compiler $ac_option >&5" | |
4754 | case "(($ac_try" in | |
4755 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4756 | *) ac_try_echo=$ac_try;; | |
4757 | esac | |
4758 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
4759 | $as_echo "$ac_try_echo"; } >&5 | |
4760 | (eval "$ac_compiler $ac_option >&5") 2>conftest.err | |
4761 | ac_status=$? | |
4762 | if test -s conftest.err; then | |
4763 | sed '10a\ | |
4764 | ... rest of stderr output deleted ... | |
4765 | 10q' conftest.err >conftest.er1 | |
4766 | cat conftest.er1 >&5 | |
4767 | fi | |
4768 | rm -f conftest.er1 conftest.err | |
4769 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4770 | test $ac_status = 0; } | |
4771 | done | |
4772 | ||
4773 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4774 | /* end confdefs.h. */ | |
4775 | ||
4776 | int | |
4777 | main () | |
4778 | { | |
4779 | ||
4780 | ; | |
4781 | return 0; | |
4782 | } | |
4783 | _ACEOF | |
4784 | ac_clean_files_save=$ac_clean_files | |
4785 | ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" | |
4786 | # Try to create an executable without -o first, disregard a.out. | |
4787 | # It will help us diagnose broken compilers, and finding out an intuition | |
4788 | # of exeext. | |
4789 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 | |
4790 | $as_echo_n "checking whether the C compiler works... " >&6; } | |
4791 | ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` | |
4792 | ||
4793 | # The possible output files: | |
4794 | ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" | |
4795 | ||
4796 | ac_rmfiles= | |
4797 | for ac_file in $ac_files | |
4798 | do | |
4799 | case $ac_file in | |
4800 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; | |
4801 | * ) ac_rmfiles="$ac_rmfiles $ac_file";; | |
4802 | esac | |
4803 | done | |
4804 | rm -f $ac_rmfiles | |
4805 | ||
4806 | if { { ac_try="$ac_link_default" | |
4807 | case "(($ac_try" in | |
4808 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4809 | *) ac_try_echo=$ac_try;; | |
4810 | esac | |
4811 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
4812 | $as_echo "$ac_try_echo"; } >&5 | |
4813 | (eval "$ac_link_default") 2>&5 | |
4814 | ac_status=$? | |
4815 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4816 | test $ac_status = 0; }; then : | |
4817 | # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. | |
4818 | # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' | |
4819 | # in a Makefile. We should not override ac_cv_exeext if it was cached, | |
4820 | # so that the user can short-circuit this test for compilers unknown to | |
4821 | # Autoconf. | |
4822 | for ac_file in $ac_files '' | |
4823 | do | |
4824 | test -f "$ac_file" || continue | |
4825 | case $ac_file in | |
4826 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) | |
4827 | ;; | |
4828 | [ab].out ) | |
4829 | # We found the default executable, but exeext='' is most | |
4830 | # certainly right. | |
4831 | break;; | |
4832 | *.* ) | |
4833 | if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; | |
4834 | then :; else | |
4835 | ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` | |
4836 | fi | |
4837 | # We set ac_cv_exeext here because the later test for it is not | |
4838 | # safe: cross compilers may not add the suffix if given an `-o' | |
4839 | # argument, so we may need to know it at that point already. | |
4840 | # Even if this section looks crufty: it has the advantage of | |
4841 | # actually working. | |
4842 | break;; | |
4843 | * ) | |
4844 | break;; | |
4845 | esac | |
4846 | done | |
4847 | test "$ac_cv_exeext" = no && ac_cv_exeext= | |
4848 | ||
4849 | else | |
4850 | ac_file='' | |
4851 | fi | |
4852 | if test -z "$ac_file"; then : | |
4853 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4854 | $as_echo "no" >&6; } | |
4855 | $as_echo "$as_me: failed program was:" >&5 | |
4856 | sed 's/^/| /' conftest.$ac_ext >&5 | |
4857 | ||
4858 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
4859 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2018939f | 4860 | as_fn_error 77 "C compiler cannot create executables |
d6974efa | 4861 | See \`config.log' for more details" "$LINENO" 5; } |
067d23c9 KY |
4862 | else |
4863 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
4864 | $as_echo "yes" >&6; } | |
4865 | fi | |
4866 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 | |
4867 | $as_echo_n "checking for C compiler default output file name... " >&6; } | |
4868 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 | |
4869 | $as_echo "$ac_file" >&6; } | |
4870 | ac_exeext=$ac_cv_exeext | |
4871 | ||
4872 | rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out | |
4873 | ac_clean_files=$ac_clean_files_save | |
4874 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 | |
4875 | $as_echo_n "checking for suffix of executables... " >&6; } | |
4876 | if { { ac_try="$ac_link" | |
4877 | case "(($ac_try" in | |
4878 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4879 | *) ac_try_echo=$ac_try;; | |
4880 | esac | |
4881 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
4882 | $as_echo "$ac_try_echo"; } >&5 | |
4883 | (eval "$ac_link") 2>&5 | |
4884 | ac_status=$? | |
4885 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4886 | test $ac_status = 0; }; then : | |
4887 | # If both `conftest.exe' and `conftest' are `present' (well, observable) | |
4888 | # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will | |
4889 | # work properly (i.e., refer to `conftest.exe'), while it won't with | |
4890 | # `rm'. | |
4891 | for ac_file in conftest.exe conftest conftest.*; do | |
4892 | test -f "$ac_file" || continue | |
4893 | case $ac_file in | |
4894 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; | |
4895 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` | |
4896 | break;; | |
4897 | * ) break;; | |
4898 | esac | |
4899 | done | |
4900 | else | |
4901 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
4902 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2018939f | 4903 | as_fn_error $? "cannot compute suffix of executables: cannot compile and link |
d6974efa | 4904 | See \`config.log' for more details" "$LINENO" 5; } |
067d23c9 KY |
4905 | fi |
4906 | rm -f conftest conftest$ac_cv_exeext | |
4907 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 | |
4908 | $as_echo "$ac_cv_exeext" >&6; } | |
4909 | ||
4910 | rm -f conftest.$ac_ext | |
4911 | EXEEXT=$ac_cv_exeext | |
4912 | ac_exeext=$EXEEXT | |
4913 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4914 | /* end confdefs.h. */ | |
4915 | #include <stdio.h> | |
4916 | int | |
4917 | main () | |
4918 | { | |
4919 | FILE *f = fopen ("conftest.out", "w"); | |
4920 | return ferror (f) || fclose (f) != 0; | |
4921 | ||
4922 | ; | |
4923 | return 0; | |
4924 | } | |
4925 | _ACEOF | |
4926 | ac_clean_files="$ac_clean_files conftest.out" | |
4927 | # Check that the compiler produces executables we can run. If not, either | |
4928 | # the compiler is broken, or we cross compile. | |
4929 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 | |
4930 | $as_echo_n "checking whether we are cross compiling... " >&6; } | |
4931 | if test "$cross_compiling" != yes; then | |
4932 | { { ac_try="$ac_link" | |
4933 | case "(($ac_try" in | |
4934 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4935 | *) ac_try_echo=$ac_try;; | |
4936 | esac | |
4937 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
4938 | $as_echo "$ac_try_echo"; } >&5 | |
4939 | (eval "$ac_link") 2>&5 | |
4940 | ac_status=$? | |
4941 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4942 | test $ac_status = 0; } | |
4943 | if { ac_try='./conftest$ac_cv_exeext' | |
4944 | { { case "(($ac_try" in | |
4945 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4946 | *) ac_try_echo=$ac_try;; | |
4947 | esac | |
4948 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
4949 | $as_echo "$ac_try_echo"; } >&5 | |
4950 | (eval "$ac_try") 2>&5 | |
4951 | ac_status=$? | |
4952 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4953 | test $ac_status = 0; }; }; then | |
4954 | cross_compiling=no | |
4955 | else | |
4956 | if test "$cross_compiling" = maybe; then | |
4957 | cross_compiling=yes | |
4958 | else | |
4959 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
4960 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2018939f | 4961 | as_fn_error $? "cannot run C compiled programs. |
067d23c9 | 4962 | If you meant to cross compile, use \`--host'. |
d6974efa | 4963 | See \`config.log' for more details" "$LINENO" 5; } |
067d23c9 KY |
4964 | fi |
4965 | fi | |
4966 | fi | |
4967 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 | |
4968 | $as_echo "$cross_compiling" >&6; } | |
4969 | ||
4970 | rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out | |
4971 | ac_clean_files=$ac_clean_files_save | |
4972 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 | |
4973 | $as_echo_n "checking for suffix of object files... " >&6; } | |
d6974efa | 4974 | if ${ac_cv_objext+:} false; then : |
067d23c9 KY |
4975 | $as_echo_n "(cached) " >&6 |
4976 | else | |
4977 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4978 | /* end confdefs.h. */ | |
4979 | ||
4980 | int | |
4981 | main () | |
4982 | { | |
4983 | ||
4984 | ; | |
4985 | return 0; | |
4986 | } | |
4987 | _ACEOF | |
4988 | rm -f conftest.o conftest.obj | |
4989 | if { { ac_try="$ac_compile" | |
4990 | case "(($ac_try" in | |
4991 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4992 | *) ac_try_echo=$ac_try;; | |
4993 | esac | |
4994 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
4995 | $as_echo "$ac_try_echo"; } >&5 | |
4996 | (eval "$ac_compile") 2>&5 | |
4997 | ac_status=$? | |
4998 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4999 | test $ac_status = 0; }; then : | |
5000 | for ac_file in conftest.o conftest.obj conftest.*; do | |
5001 | test -f "$ac_file" || continue; | |
5002 | case $ac_file in | |
5003 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; | |
5004 | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` | |
5005 | break;; | |
5006 | esac | |
5007 | done | |
5008 | else | |
5009 | $as_echo "$as_me: failed program was:" >&5 | |
5010 | sed 's/^/| /' conftest.$ac_ext >&5 | |
5011 | ||
5012 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
5013 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2018939f | 5014 | as_fn_error $? "cannot compute suffix of object files: cannot compile |
d6974efa | 5015 | See \`config.log' for more details" "$LINENO" 5; } |
067d23c9 KY |
5016 | fi |
5017 | rm -f conftest.$ac_cv_objext conftest.$ac_ext | |
5018 | fi | |
5019 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 | |
5020 | $as_echo "$ac_cv_objext" >&6; } | |
5021 | OBJEXT=$ac_cv_objext | |
5022 | ac_objext=$OBJEXT | |
5023 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 | |
5024 | $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } | |
d6974efa | 5025 | if ${ac_cv_c_compiler_gnu+:} false; then : |
067d23c9 KY |
5026 | $as_echo_n "(cached) " >&6 |
5027 | else | |
5028 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5029 | /* end confdefs.h. */ | |
5030 | ||
5031 | int | |
5032 | main () | |
5033 | { | |
5034 | #ifndef __GNUC__ | |
5035 | choke me | |
5036 | #endif | |
5037 | ||
5038 | ; | |
5039 | return 0; | |
5040 | } | |
5041 | _ACEOF | |
5042 | if ac_fn_c_try_compile "$LINENO"; then : | |
5043 | ac_compiler_gnu=yes | |
5044 | else | |
5045 | ac_compiler_gnu=no | |
5046 | fi | |
5047 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
5048 | ac_cv_c_compiler_gnu=$ac_compiler_gnu | |
5049 | ||
5050 | fi | |
5051 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 | |
5052 | $as_echo "$ac_cv_c_compiler_gnu" >&6; } | |
5053 | if test $ac_compiler_gnu = yes; then | |
5054 | GCC=yes | |
5055 | else | |
5056 | GCC= | |
5057 | fi | |
5058 | ac_test_CFLAGS=${CFLAGS+set} | |
5059 | ac_save_CFLAGS=$CFLAGS | |
5060 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 | |
5061 | $as_echo_n "checking whether $CC accepts -g... " >&6; } | |
d6974efa | 5062 | if ${ac_cv_prog_cc_g+:} false; then : |
067d23c9 KY |
5063 | $as_echo_n "(cached) " >&6 |
5064 | else | |
5065 | ac_save_c_werror_flag=$ac_c_werror_flag | |
5066 | ac_c_werror_flag=yes | |
5067 | ac_cv_prog_cc_g=no | |
5068 | CFLAGS="-g" | |
5069 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5070 | /* end confdefs.h. */ | |
5071 | ||
5072 | int | |
5073 | main () | |
5074 | { | |
5075 | ||
5076 | ; | |
5077 | return 0; | |
5078 | } | |
5079 | _ACEOF | |
5080 | if ac_fn_c_try_compile "$LINENO"; then : | |
5081 | ac_cv_prog_cc_g=yes | |
5082 | else | |
5083 | CFLAGS="" | |
5084 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5085 | /* end confdefs.h. */ | |
5086 | ||
5087 | int | |
5088 | main () | |
5089 | { | |
5090 | ||
5091 | ; | |
5092 | return 0; | |
5093 | } | |
5094 | _ACEOF | |
5095 | if ac_fn_c_try_compile "$LINENO"; then : | |
5096 | ||
5097 | else | |
5098 | ac_c_werror_flag=$ac_save_c_werror_flag | |
5099 | CFLAGS="-g" | |
5100 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5101 | /* end confdefs.h. */ | |
5102 | ||
5103 | int | |
5104 | main () | |
5105 | { | |
5106 | ||
5107 | ; | |
5108 | return 0; | |
5109 | } | |
5110 | _ACEOF | |
5111 | if ac_fn_c_try_compile "$LINENO"; then : | |
5112 | ac_cv_prog_cc_g=yes | |
5113 | fi | |
5114 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
5115 | fi | |
5116 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
5117 | fi | |
5118 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
5119 | ac_c_werror_flag=$ac_save_c_werror_flag | |
5120 | fi | |
5121 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 | |
5122 | $as_echo "$ac_cv_prog_cc_g" >&6; } | |
5123 | if test "$ac_test_CFLAGS" = set; then | |
5124 | CFLAGS=$ac_save_CFLAGS | |
5125 | elif test $ac_cv_prog_cc_g = yes; then | |
5126 | if test "$GCC" = yes; then | |
5127 | CFLAGS="-g -O2" | |
5128 | else | |
5129 | CFLAGS="-g" | |
5130 | fi | |
5131 | else | |
5132 | if test "$GCC" = yes; then | |
5133 | CFLAGS="-O2" | |
5134 | else | |
5135 | CFLAGS= | |
5136 | fi | |
5137 | fi | |
5138 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 | |
5139 | $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } | |
d6974efa | 5140 | if ${ac_cv_prog_cc_c89+:} false; then : |
067d23c9 KY |
5141 | $as_echo_n "(cached) " >&6 |
5142 | else | |
5143 | ac_cv_prog_cc_c89=no | |
5144 | ac_save_CC=$CC | |
5145 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5146 | /* end confdefs.h. */ | |
5147 | #include <stdarg.h> | |
5148 | #include <stdio.h> | |
5149 | #include <sys/types.h> | |
5150 | #include <sys/stat.h> | |
5151 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ | |
5152 | struct buf { int x; }; | |
5153 | FILE * (*rcsopen) (struct buf *, struct stat *, int); | |
5154 | static char *e (p, i) | |
5155 | char **p; | |
5156 | int i; | |
5157 | { | |
5158 | return p[i]; | |
5159 | } | |
5160 | static char *f (char * (*g) (char **, int), char **p, ...) | |
5161 | { | |
5162 | char *s; | |
5163 | va_list v; | |
5164 | va_start (v,p); | |
5165 | s = g (p, va_arg (v,int)); | |
5166 | va_end (v); | |
5167 | return s; | |
5168 | } | |
5169 | ||
5170 | /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has | |
5171 | function prototypes and stuff, but not '\xHH' hex character constants. | |
5172 | These don't provoke an error unfortunately, instead are silently treated | |
5173 | as 'x'. The following induces an error, until -std is added to get | |
5174 | proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an | |
5175 | array size at least. It's necessary to write '\x00'==0 to get something | |
5176 | that's true only with -std. */ | |
5177 | int osf4_cc_array ['\x00' == 0 ? 1 : -1]; | |
5178 | ||
5179 | /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters | |
5180 | inside strings and character constants. */ | |
5181 | #define FOO(x) 'x' | |
5182 | int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; | |
5183 | ||
5184 | int test (int i, double x); | |
5185 | struct s1 {int (*f) (int a);}; | |
5186 | struct s2 {int (*f) (double a);}; | |
5187 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); | |
5188 | int argc; | |
5189 | char **argv; | |
5190 | int | |
5191 | main () | |
5192 | { | |
5193 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; | |
5194 | ; | |
5195 | return 0; | |
5196 | } | |
5197 | _ACEOF | |
5198 | for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ | |
5199 | -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" | |
5200 | do | |
5201 | CC="$ac_save_CC $ac_arg" | |
5202 | if ac_fn_c_try_compile "$LINENO"; then : | |
5203 | ac_cv_prog_cc_c89=$ac_arg | |
5204 | fi | |
5205 | rm -f core conftest.err conftest.$ac_objext | |
5206 | test "x$ac_cv_prog_cc_c89" != "xno" && break | |
5207 | done | |
743c80a7 PE |
5208 | rm -f conftest.$ac_ext |
5209 | CC=$ac_save_CC | |
5210 | ||
5211 | fi | |
5212 | # AC_CACHE_VAL | |
5213 | case "x$ac_cv_prog_cc_c89" in | |
5214 | x) | |
5215 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 | |
5216 | $as_echo "none needed" >&6; } ;; | |
5217 | xno) | |
5218 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 | |
5219 | $as_echo "unsupported" >&6; } ;; | |
5220 | *) | |
5221 | CC="$CC $ac_cv_prog_cc_c89" | |
5222 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 | |
5223 | $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; | |
5224 | esac | |
5225 | if test "x$ac_cv_prog_cc_c89" != xno; then : | |
5226 | ||
5227 | fi | |
5228 | ||
5229 | ac_ext=c | |
5230 | ac_cpp='$CPP $CPPFLAGS' | |
5231 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
5232 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
5233 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
5234 | DEPDIR="${am__leading_dot}deps" | |
5235 | ||
5236 | ac_config_commands="$ac_config_commands depfiles" | |
5237 | ||
5238 | ||
5239 | am_make=${MAKE-make} | |
5240 | cat > confinc << 'END' | |
5241 | am__doit: | |
5242 | @echo this is the am__doit target | |
5243 | .PHONY: am__doit | |
5244 | END | |
5245 | # If we don't find an include directive, just comment out the code. | |
5246 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 | |
5247 | $as_echo_n "checking for style of include used by $am_make... " >&6; } | |
5248 | am__include="#" | |
5249 | am__quote= | |
5250 | _am_result=none | |
5251 | # First try GNU make style include. | |
5252 | echo "include confinc" > confmf | |
5253 | # Ignore all kinds of additional output from `make'. | |
5254 | case `$am_make -s -f confmf 2> /dev/null` in #( | |
5255 | *the\ am__doit\ target*) | |
5256 | am__include=include | |
5257 | am__quote= | |
5258 | _am_result=GNU | |
5259 | ;; | |
5260 | esac | |
5261 | # Now try BSD make style include. | |
5262 | if test "$am__include" = "#"; then | |
5263 | echo '.include "confinc"' > confmf | |
5264 | case `$am_make -s -f confmf 2> /dev/null` in #( | |
5265 | *the\ am__doit\ target*) | |
5266 | am__include=.include | |
5267 | am__quote="\"" | |
5268 | _am_result=BSD | |
5269 | ;; | |
5270 | esac | |
5271 | fi | |
5272 | ||
5273 | ||
5274 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 | |
5275 | $as_echo "$_am_result" >&6; } | |
5276 | rm -f confinc confmf | |
5277 | ||
5278 | # Check whether --enable-dependency-tracking was given. | |
5279 | if test "${enable_dependency_tracking+set}" = set; then : | |
5280 | enableval=$enable_dependency_tracking; | |
5281 | fi | |
5282 | ||
5283 | if test "x$enable_dependency_tracking" != xno; then | |
5284 | am_depcomp="$ac_aux_dir/depcomp" | |
5285 | AMDEPBACKSLASH='\' | |
5286 | fi | |
5287 | if test "x$enable_dependency_tracking" != xno; then | |
5288 | AMDEP_TRUE= | |
5289 | AMDEP_FALSE='#' | |
5290 | else | |
5291 | AMDEP_TRUE='#' | |
5292 | AMDEP_FALSE= | |
5293 | fi | |
5294 | ||
5295 | ||
5296 | ||
5297 | depcc="$CC" am_compiler_list= | |
5298 | ||
5299 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 | |
5300 | $as_echo_n "checking dependency style of $depcc... " >&6; } | |
d6974efa | 5301 | if ${am_cv_CC_dependencies_compiler_type+:} false; then : |
743c80a7 PE |
5302 | $as_echo_n "(cached) " >&6 |
5303 | else | |
5304 | if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then | |
5305 | # We make a subdir and do the tests there. Otherwise we can end up | |
5306 | # making bogus files that we don't know about and never remove. For | |
5307 | # instance it was reported that on HP-UX the gcc test will end up | |
5308 | # making a dummy file named `D' -- because `-MD' means `put the output | |
5309 | # in D'. | |
5310 | mkdir conftest.dir | |
5311 | # Copy depcomp to subdir because otherwise we won't find it if we're | |
5312 | # using a relative directory. | |
5313 | cp "$am_depcomp" conftest.dir | |
5314 | cd conftest.dir | |
5315 | # We will build objects and dependencies in a subdirectory because | |
5316 | # it helps to detect inapplicable dependency modes. For instance | |
5317 | # both Tru64's cc and ICC support -MD to output dependencies as a | |
5318 | # side effect of compilation, but ICC will put the dependencies in | |
5319 | # the current directory while Tru64 will put them in the object | |
5320 | # directory. | |
5321 | mkdir sub | |
5322 | ||
5323 | am_cv_CC_dependencies_compiler_type=none | |
5324 | if test "$am_compiler_list" = ""; then | |
5325 | am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` | |
5326 | fi | |
5327 | am__universal=false | |
5328 | case " $depcc " in #( | |
5329 | *\ -arch\ *\ -arch\ *) am__universal=true ;; | |
5330 | esac | |
5331 | ||
5332 | for depmode in $am_compiler_list; do | |
5333 | # Setup a source with many dependencies, because some compilers | |
5334 | # like to wrap large dependency lists on column 80 (with \), and | |
5335 | # we should not choose a depcomp mode which is confused by this. | |
5336 | # | |
5337 | # We need to recreate these files for each test, as the compiler may | |
5338 | # overwrite some of them when testing with obscure command lines. | |
5339 | # This happens at least with the AIX C compiler. | |
5340 | : > sub/conftest.c | |
5341 | for i in 1 2 3 4 5 6; do | |
5342 | echo '#include "conftst'$i'.h"' >> sub/conftest.c | |
5343 | # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with | |
5344 | # Solaris 8's {/usr,}/bin/sh. | |
5345 | touch sub/conftst$i.h | |
5346 | done | |
5347 | echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf | |
5348 | ||
5349 | # We check with `-c' and `-o' for the sake of the "dashmstdout" | |
5350 | # mode. It turns out that the SunPro C++ compiler does not properly | |
5351 | # handle `-M -o', and we need to detect this. Also, some Intel | |
5352 | # versions had trouble with output in subdirs | |
5353 | am__obj=sub/conftest.${OBJEXT-o} | |
5354 | am__minus_obj="-o $am__obj" | |
5355 | case $depmode in | |
5356 | gcc) | |
5357 | # This depmode causes a compiler race in universal mode. | |
5358 | test "$am__universal" = false || continue | |
5359 | ;; | |
5360 | nosideeffect) | |
5361 | # after this tag, mechanisms are not by side-effect, so they'll | |
5362 | # only be used when explicitly requested | |
5363 | if test "x$enable_dependency_tracking" = xyes; then | |
5364 | continue | |
5365 | else | |
5366 | break | |
5367 | fi | |
5368 | ;; | |
5369 | msvisualcpp | msvcmsys) | |
5370 | # This compiler won't grok `-c -o', but also, the minuso test has | |
5371 | # not run yet. These depmodes are late enough in the game, and | |
5372 | # so weak that their functioning should not be impacted. | |
5373 | am__obj=conftest.${OBJEXT-o} | |
5374 | am__minus_obj= | |
5375 | ;; | |
5376 | none) break ;; | |
5377 | esac | |
5378 | if depmode=$depmode \ | |
5379 | source=sub/conftest.c object=$am__obj \ | |
5380 | depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ | |
5381 | $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ | |
5382 | >/dev/null 2>conftest.err && | |
5383 | grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && | |
5384 | grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && | |
5385 | grep $am__obj sub/conftest.Po > /dev/null 2>&1 && | |
5386 | ${MAKE-make} -s -f confmf > /dev/null 2>&1; then | |
5387 | # icc doesn't choke on unknown options, it will just issue warnings | |
5388 | # or remarks (even with -Werror). So we grep stderr for any message | |
5389 | # that says an option was ignored or not supported. | |
5390 | # When given -MP, icc 7.0 and 7.1 complain thusly: | |
5391 | # icc: Command line warning: ignoring option '-M'; no argument required | |
5392 | # The diagnosis changed in icc 8.0: | |
5393 | # icc: Command line remark: option '-MP' not supported | |
5394 | if (grep 'ignoring option' conftest.err || | |
5395 | grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else | |
5396 | am_cv_CC_dependencies_compiler_type=$depmode | |
5397 | break | |
5398 | fi | |
5399 | fi | |
5400 | done | |
5401 | ||
5402 | cd .. | |
5403 | rm -rf conftest.dir | |
5404 | else | |
5405 | am_cv_CC_dependencies_compiler_type=none | |
5406 | fi | |
5407 | ||
5408 | fi | |
5409 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 | |
5410 | $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } | |
5411 | CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type | |
5412 | ||
5413 | if | |
5414 | test "x$enable_dependency_tracking" != xno \ | |
5415 | && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then | |
5416 | am__fastdepCC_TRUE= | |
5417 | am__fastdepCC_FALSE='#' | |
5418 | else | |
5419 | am__fastdepCC_TRUE='#' | |
5420 | am__fastdepCC_FALSE= | |
5421 | fi | |
5422 | ||
5423 | ||
5424 | if test "x$CC" != xcc; then | |
5425 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5 | |
5426 | $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; } | |
5427 | else | |
5428 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5 | |
5429 | $as_echo_n "checking whether cc understands -c and -o together... " >&6; } | |
5430 | fi | |
5431 | set dummy $CC; ac_cc=`$as_echo "$2" | | |
5432 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'` | |
d6974efa | 5433 | if eval \${ac_cv_prog_cc_${ac_cc}_c_o+:} false; then : |
743c80a7 PE |
5434 | $as_echo_n "(cached) " >&6 |
5435 | else | |
5436 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5437 | /* end confdefs.h. */ | |
5438 | ||
5439 | int | |
5440 | main () | |
5441 | { | |
5442 | ||
5443 | ; | |
5444 | return 0; | |
5445 | } | |
5446 | _ACEOF | |
5447 | # Make sure it works both with $CC and with simple cc. | |
5448 | # We do the test twice because some compilers refuse to overwrite an | |
5449 | # existing .o file with -o, though they will create one. | |
5450 | ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5' | |
5451 | rm -f conftest2.* | |
5452 | if { { case "(($ac_try" in | |
5453 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
5454 | *) ac_try_echo=$ac_try;; | |
5455 | esac | |
5456 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
5457 | $as_echo "$ac_try_echo"; } >&5 | |
5458 | (eval "$ac_try") 2>&5 | |
5459 | ac_status=$? | |
5460 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
5461 | test $ac_status = 0; } && | |
5462 | test -f conftest2.$ac_objext && { { case "(($ac_try" in | |
5463 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
5464 | *) ac_try_echo=$ac_try;; | |
5465 | esac | |
5466 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
5467 | $as_echo "$ac_try_echo"; } >&5 | |
5468 | (eval "$ac_try") 2>&5 | |
5469 | ac_status=$? | |
5470 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
5471 | test $ac_status = 0; }; | |
5472 | then | |
5473 | eval ac_cv_prog_cc_${ac_cc}_c_o=yes | |
5474 | if test "x$CC" != xcc; then | |
5475 | # Test first that cc exists at all. | |
5476 | if { ac_try='cc -c conftest.$ac_ext >&5' | |
5477 | { { case "(($ac_try" in | |
5478 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
5479 | *) ac_try_echo=$ac_try;; | |
5480 | esac | |
5481 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
5482 | $as_echo "$ac_try_echo"; } >&5 | |
5483 | (eval "$ac_try") 2>&5 | |
5484 | ac_status=$? | |
5485 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
5486 | test $ac_status = 0; }; }; then | |
5487 | ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5' | |
5488 | rm -f conftest2.* | |
5489 | if { { case "(($ac_try" in | |
5490 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
5491 | *) ac_try_echo=$ac_try;; | |
5492 | esac | |
5493 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
5494 | $as_echo "$ac_try_echo"; } >&5 | |
5495 | (eval "$ac_try") 2>&5 | |
5496 | ac_status=$? | |
5497 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
5498 | test $ac_status = 0; } && | |
5499 | test -f conftest2.$ac_objext && { { case "(($ac_try" in | |
5500 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
5501 | *) ac_try_echo=$ac_try;; | |
5502 | esac | |
5503 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
5504 | $as_echo "$ac_try_echo"; } >&5 | |
5505 | (eval "$ac_try") 2>&5 | |
5506 | ac_status=$? | |
5507 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
5508 | test $ac_status = 0; }; | |
5509 | then | |
5510 | # cc works too. | |
5511 | : | |
5512 | else | |
5513 | # cc exists but doesn't like -o. | |
5514 | eval ac_cv_prog_cc_${ac_cc}_c_o=no | |
5515 | fi | |
5516 | fi | |
5517 | fi | |
5518 | else | |
5519 | eval ac_cv_prog_cc_${ac_cc}_c_o=no | |
5520 | fi | |
5521 | rm -f core conftest* | |
5522 | ||
5523 | fi | |
5524 | if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then | |
5525 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
5526 | $as_echo "yes" >&6; } | |
5527 | else | |
5528 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
5529 | $as_echo "no" >&6; } | |
5530 | ||
5531 | $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h | |
5532 | ||
5533 | fi | |
5534 | ||
5535 | # FIXME: we rely on the cache variable name because | |
5536 | # there is no other way. | |
5537 | set dummy $CC | |
5538 | am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'` | |
5539 | eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o | |
5540 | if test "$am_t" != yes; then | |
5541 | # Losing compiler, so override with the script. | |
5542 | # FIXME: It is wrong to rewrite CC. | |
5543 | # But if we don't then we get into trouble of one sort or another. | |
5544 | # A longer-term fix would be to have automake use am__CC in this case, | |
5545 | # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" | |
5546 | CC="$am_aux_dir/compile $CC" | |
5547 | fi | |
5548 | ||
5549 | ||
5550 | ||
5551 | # Initialize gnulib right after verifying that the C compiler works. | |
5552 | if test -n "$ac_tool_prefix"; then | |
5553 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. | |
5554 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 | |
5555 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
5556 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 5557 | if ${ac_cv_prog_RANLIB+:} false; then : |
743c80a7 PE |
5558 | $as_echo_n "(cached) " >&6 |
5559 | else | |
5560 | if test -n "$RANLIB"; then | |
5561 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
5562 | else | |
5563 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
5564 | for as_dir in $PATH | |
5565 | do | |
5566 | IFS=$as_save_IFS | |
5567 | test -z "$as_dir" && as_dir=. | |
5568 | for ac_exec_ext in '' $ac_executable_extensions; do | |
5569 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
5570 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" | |
5571 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
5572 | break 2 | |
5573 | fi | |
5574 | done | |
5575 | done | |
5576 | IFS=$as_save_IFS | |
5577 | ||
5578 | fi | |
5579 | fi | |
5580 | RANLIB=$ac_cv_prog_RANLIB | |
5581 | if test -n "$RANLIB"; then | |
5582 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 | |
5583 | $as_echo "$RANLIB" >&6; } | |
5584 | else | |
5585 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
5586 | $as_echo "no" >&6; } | |
5587 | fi | |
5588 | ||
5589 | ||
5590 | fi | |
5591 | if test -z "$ac_cv_prog_RANLIB"; then | |
5592 | ac_ct_RANLIB=$RANLIB | |
5593 | # Extract the first word of "ranlib", so it can be a program name with args. | |
5594 | set dummy ranlib; ac_word=$2 | |
5595 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
5596 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 5597 | if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : |
743c80a7 PE |
5598 | $as_echo_n "(cached) " >&6 |
5599 | else | |
5600 | if test -n "$ac_ct_RANLIB"; then | |
5601 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. | |
5602 | else | |
5603 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
5604 | for as_dir in $PATH | |
5605 | do | |
5606 | IFS=$as_save_IFS | |
5607 | test -z "$as_dir" && as_dir=. | |
5608 | for ac_exec_ext in '' $ac_executable_extensions; do | |
5609 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
5610 | ac_cv_prog_ac_ct_RANLIB="ranlib" | |
5611 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
5612 | break 2 | |
5613 | fi | |
5614 | done | |
5615 | done | |
5616 | IFS=$as_save_IFS | |
067d23c9 KY |
5617 | |
5618 | fi | |
743c80a7 PE |
5619 | fi |
5620 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB | |
5621 | if test -n "$ac_ct_RANLIB"; then | |
5622 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 | |
5623 | $as_echo "$ac_ct_RANLIB" >&6; } | |
5624 | else | |
5625 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
5626 | $as_echo "no" >&6; } | |
5627 | fi | |
067d23c9 | 5628 | |
743c80a7 PE |
5629 | if test "x$ac_ct_RANLIB" = x; then |
5630 | RANLIB=":" | |
5631 | else | |
5632 | case $cross_compiling:$ac_tool_warned in | |
5633 | yes:) | |
5634 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
5635 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
5636 | ac_tool_warned=yes ;; | |
5637 | esac | |
5638 | RANLIB=$ac_ct_RANLIB | |
5639 | fi | |
5640 | else | |
5641 | RANLIB="$ac_cv_prog_RANLIB" | |
067d23c9 KY |
5642 | fi |
5643 | ||
743c80a7 | 5644 | |
067d23c9 KY |
5645 | ac_ext=c |
5646 | ac_cpp='$CPP $CPPFLAGS' | |
5647 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
5648 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
5649 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
5650 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 | |
5651 | $as_echo_n "checking how to run the C preprocessor... " >&6; } | |
5652 | # On Suns, sometimes $CPP names a directory. | |
5653 | if test -n "$CPP" && test -d "$CPP"; then | |
5654 | CPP= | |
5655 | fi | |
5656 | if test -z "$CPP"; then | |
d6974efa | 5657 | if ${ac_cv_prog_CPP+:} false; then : |
067d23c9 KY |
5658 | $as_echo_n "(cached) " >&6 |
5659 | else | |
5660 | # Double quotes because CPP needs to be expanded | |
5661 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" | |
5662 | do | |
5663 | ac_preproc_ok=false | |
5664 | for ac_c_preproc_warn_flag in '' yes | |
5665 | do | |
5666 | # Use a header file that comes with gcc, so configuring glibc | |
5667 | # with a fresh cross-compiler works. | |
5668 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
5669 | # <limits.h> exists even on freestanding compilers. | |
5670 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
5671 | # not just through cpp. "Syntax error" is here to catch this case. | |
5672 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5673 | /* end confdefs.h. */ | |
5674 | #ifdef __STDC__ | |
5675 | # include <limits.h> | |
5676 | #else | |
5677 | # include <assert.h> | |
5678 | #endif | |
5679 | Syntax error | |
5680 | _ACEOF | |
5681 | if ac_fn_c_try_cpp "$LINENO"; then : | |
5682 | ||
5683 | else | |
5684 | # Broken: fails on valid input. | |
5685 | continue | |
5686 | fi | |
2018939f | 5687 | rm -f conftest.err conftest.i conftest.$ac_ext |
067d23c9 KY |
5688 | |
5689 | # OK, works on sane cases. Now check whether nonexistent headers | |
5690 | # can be detected and how. | |
5691 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5692 | /* end confdefs.h. */ | |
5693 | #include <ac_nonexistent.h> | |
5694 | _ACEOF | |
5695 | if ac_fn_c_try_cpp "$LINENO"; then : | |
5696 | # Broken: success on invalid input. | |
5697 | continue | |
5698 | else | |
5699 | # Passes both tests. | |
5700 | ac_preproc_ok=: | |
5701 | break | |
5702 | fi | |
2018939f | 5703 | rm -f conftest.err conftest.i conftest.$ac_ext |
067d23c9 KY |
5704 | |
5705 | done | |
5706 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
2018939f | 5707 | rm -f conftest.i conftest.err conftest.$ac_ext |
067d23c9 KY |
5708 | if $ac_preproc_ok; then : |
5709 | break | |
5710 | fi | |
5711 | ||
5712 | done | |
5713 | ac_cv_prog_CPP=$CPP | |
5714 | ||
5715 | fi | |
5716 | CPP=$ac_cv_prog_CPP | |
5717 | else | |
5718 | ac_cv_prog_CPP=$CPP | |
5719 | fi | |
5720 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 | |
5721 | $as_echo "$CPP" >&6; } | |
5722 | ac_preproc_ok=false | |
5723 | for ac_c_preproc_warn_flag in '' yes | |
5724 | do | |
5725 | # Use a header file that comes with gcc, so configuring glibc | |
5726 | # with a fresh cross-compiler works. | |
5727 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
5728 | # <limits.h> exists even on freestanding compilers. | |
5729 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
5730 | # not just through cpp. "Syntax error" is here to catch this case. | |
5731 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5732 | /* end confdefs.h. */ | |
5733 | #ifdef __STDC__ | |
5734 | # include <limits.h> | |
5735 | #else | |
5736 | # include <assert.h> | |
5737 | #endif | |
5738 | Syntax error | |
5739 | _ACEOF | |
5740 | if ac_fn_c_try_cpp "$LINENO"; then : | |
5741 | ||
5742 | else | |
5743 | # Broken: fails on valid input. | |
5744 | continue | |
5745 | fi | |
2018939f | 5746 | rm -f conftest.err conftest.i conftest.$ac_ext |
067d23c9 KY |
5747 | |
5748 | # OK, works on sane cases. Now check whether nonexistent headers | |
5749 | # can be detected and how. | |
5750 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5751 | /* end confdefs.h. */ | |
5752 | #include <ac_nonexistent.h> | |
5753 | _ACEOF | |
5754 | if ac_fn_c_try_cpp "$LINENO"; then : | |
5755 | # Broken: success on invalid input. | |
5756 | continue | |
5757 | else | |
5758 | # Passes both tests. | |
5759 | ac_preproc_ok=: | |
5760 | break | |
5761 | fi | |
2018939f | 5762 | rm -f conftest.err conftest.i conftest.$ac_ext |
067d23c9 KY |
5763 | |
5764 | done | |
5765 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
2018939f | 5766 | rm -f conftest.i conftest.err conftest.$ac_ext |
067d23c9 KY |
5767 | if $ac_preproc_ok; then : |
5768 | ||
5769 | else | |
5770 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
5771 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2018939f | 5772 | as_fn_error $? "C preprocessor \"$CPP\" fails sanity check |
d6974efa | 5773 | See \`config.log' for more details" "$LINENO" 5; } |
067d23c9 KY |
5774 | fi |
5775 | ||
5776 | ac_ext=c | |
5777 | ac_cpp='$CPP $CPPFLAGS' | |
5778 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
5779 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
5780 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
5781 | ||
5782 | ||
5783 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 | |
5784 | $as_echo_n "checking for grep that handles long lines and -e... " >&6; } | |
d6974efa | 5785 | if ${ac_cv_path_GREP+:} false; then : |
067d23c9 KY |
5786 | $as_echo_n "(cached) " >&6 |
5787 | else | |
5788 | if test -z "$GREP"; then | |
5789 | ac_path_GREP_found=false | |
5790 | # Loop through the user's path and test for each of PROGNAME-LIST | |
5791 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
5792 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin | |
5793 | do | |
5794 | IFS=$as_save_IFS | |
5795 | test -z "$as_dir" && as_dir=. | |
5796 | for ac_prog in grep ggrep; do | |
5797 | for ac_exec_ext in '' $ac_executable_extensions; do | |
5798 | ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" | |
5799 | { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue | |
5800 | # Check for GNU ac_path_GREP and select it if it is found. | |
5801 | # Check for GNU $ac_path_GREP | |
5802 | case `"$ac_path_GREP" --version 2>&1` in | |
5803 | *GNU*) | |
5804 | ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; | |
5805 | *) | |
5806 | ac_count=0 | |
5807 | $as_echo_n 0123456789 >"conftest.in" | |
5808 | while : | |
5809 | do | |
5810 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
5811 | mv "conftest.tmp" "conftest.in" | |
5812 | cp "conftest.in" "conftest.nl" | |
5813 | $as_echo 'GREP' >> "conftest.nl" | |
5814 | "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break | |
5815 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break | |
5816 | as_fn_arith $ac_count + 1 && ac_count=$as_val | |
5817 | if test $ac_count -gt ${ac_path_GREP_max-0}; then | |
5818 | # Best one so far, save it but keep looking for a better one | |
5819 | ac_cv_path_GREP="$ac_path_GREP" | |
5820 | ac_path_GREP_max=$ac_count | |
5821 | fi | |
5822 | # 10*(2^10) chars as input seems more than enough | |
5823 | test $ac_count -gt 10 && break | |
5824 | done | |
5825 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; | |
5826 | esac | |
5827 | ||
5828 | $ac_path_GREP_found && break 3 | |
5829 | done | |
5830 | done | |
5831 | done | |
5832 | IFS=$as_save_IFS | |
5833 | if test -z "$ac_cv_path_GREP"; then | |
2018939f | 5834 | as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
067d23c9 KY |
5835 | fi |
5836 | else | |
5837 | ac_cv_path_GREP=$GREP | |
5838 | fi | |
5839 | ||
5840 | fi | |
5841 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 | |
5842 | $as_echo "$ac_cv_path_GREP" >&6; } | |
5843 | GREP="$ac_cv_path_GREP" | |
5844 | ||
5845 | ||
5846 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 | |
5847 | $as_echo_n "checking for egrep... " >&6; } | |
d6974efa | 5848 | if ${ac_cv_path_EGREP+:} false; then : |
067d23c9 KY |
5849 | $as_echo_n "(cached) " >&6 |
5850 | else | |
5851 | if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 | |
5852 | then ac_cv_path_EGREP="$GREP -E" | |
5853 | else | |
5854 | if test -z "$EGREP"; then | |
5855 | ac_path_EGREP_found=false | |
5856 | # Loop through the user's path and test for each of PROGNAME-LIST | |
5857 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
5858 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin | |
5859 | do | |
5860 | IFS=$as_save_IFS | |
5861 | test -z "$as_dir" && as_dir=. | |
5862 | for ac_prog in egrep; do | |
5863 | for ac_exec_ext in '' $ac_executable_extensions; do | |
5864 | ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" | |
5865 | { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue | |
5866 | # Check for GNU ac_path_EGREP and select it if it is found. | |
5867 | # Check for GNU $ac_path_EGREP | |
5868 | case `"$ac_path_EGREP" --version 2>&1` in | |
5869 | *GNU*) | |
5870 | ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; | |
5871 | *) | |
5872 | ac_count=0 | |
5873 | $as_echo_n 0123456789 >"conftest.in" | |
5874 | while : | |
5875 | do | |
5876 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
5877 | mv "conftest.tmp" "conftest.in" | |
5878 | cp "conftest.in" "conftest.nl" | |
5879 | $as_echo 'EGREP' >> "conftest.nl" | |
5880 | "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break | |
5881 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break | |
5882 | as_fn_arith $ac_count + 1 && ac_count=$as_val | |
5883 | if test $ac_count -gt ${ac_path_EGREP_max-0}; then | |
5884 | # Best one so far, save it but keep looking for a better one | |
5885 | ac_cv_path_EGREP="$ac_path_EGREP" | |
5886 | ac_path_EGREP_max=$ac_count | |
5887 | fi | |
5888 | # 10*(2^10) chars as input seems more than enough | |
5889 | test $ac_count -gt 10 && break | |
5890 | done | |
5891 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; | |
5892 | esac | |
5893 | ||
5894 | $ac_path_EGREP_found && break 3 | |
5895 | done | |
5896 | done | |
5897 | done | |
5898 | IFS=$as_save_IFS | |
5899 | if test -z "$ac_cv_path_EGREP"; then | |
2018939f | 5900 | as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
067d23c9 KY |
5901 | fi |
5902 | else | |
5903 | ac_cv_path_EGREP=$EGREP | |
5904 | fi | |
5905 | ||
5906 | fi | |
5907 | fi | |
5908 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 | |
5909 | $as_echo "$ac_cv_path_EGREP" >&6; } | |
5910 | EGREP="$ac_cv_path_EGREP" | |
5911 | ||
5912 | ||
5913 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 | |
5914 | $as_echo_n "checking for ANSI C header files... " >&6; } | |
d6974efa | 5915 | if ${ac_cv_header_stdc+:} false; then : |
067d23c9 KY |
5916 | $as_echo_n "(cached) " >&6 |
5917 | else | |
5918 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5919 | /* end confdefs.h. */ | |
5920 | #include <stdlib.h> | |
5921 | #include <stdarg.h> | |
5922 | #include <string.h> | |
5923 | #include <float.h> | |
5924 | ||
5925 | int | |
5926 | main () | |
5927 | { | |
5928 | ||
5929 | ; | |
5930 | return 0; | |
5931 | } | |
5932 | _ACEOF | |
5933 | if ac_fn_c_try_compile "$LINENO"; then : | |
5934 | ac_cv_header_stdc=yes | |
5935 | else | |
5936 | ac_cv_header_stdc=no | |
5937 | fi | |
5938 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
5939 | ||
5940 | if test $ac_cv_header_stdc = yes; then | |
5941 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
5942 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5943 | /* end confdefs.h. */ | |
5944 | #include <string.h> | |
5945 | ||
5946 | _ACEOF | |
5947 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
5948 | $EGREP "memchr" >/dev/null 2>&1; then : | |
5949 | ||
5950 | else | |
5951 | ac_cv_header_stdc=no | |
5952 | fi | |
5953 | rm -f conftest* | |
5954 | ||
5955 | fi | |
5956 | ||
5957 | if test $ac_cv_header_stdc = yes; then | |
5958 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. | |
5959 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5960 | /* end confdefs.h. */ | |
5961 | #include <stdlib.h> | |
5962 | ||
5963 | _ACEOF | |
5964 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
5965 | $EGREP "free" >/dev/null 2>&1; then : | |
5966 | ||
5967 | else | |
5968 | ac_cv_header_stdc=no | |
5969 | fi | |
5970 | rm -f conftest* | |
5971 | ||
5972 | fi | |
5973 | ||
5974 | if test $ac_cv_header_stdc = yes; then | |
5975 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. | |
5976 | if test "$cross_compiling" = yes; then : | |
5977 | : | |
5978 | else | |
5979 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5980 | /* end confdefs.h. */ | |
5981 | #include <ctype.h> | |
5982 | #include <stdlib.h> | |
5983 | #if ((' ' & 0x0FF) == 0x020) | |
5984 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') | |
5985 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
5986 | #else | |
5987 | # define ISLOWER(c) \ | |
5988 | (('a' <= (c) && (c) <= 'i') \ | |
5989 | || ('j' <= (c) && (c) <= 'r') \ | |
5990 | || ('s' <= (c) && (c) <= 'z')) | |
5991 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) | |
5992 | #endif | |
5993 | ||
5994 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) | |
5995 | int | |
5996 | main () | |
5997 | { | |
5998 | int i; | |
5999 | for (i = 0; i < 256; i++) | |
6000 | if (XOR (islower (i), ISLOWER (i)) | |
6001 | || toupper (i) != TOUPPER (i)) | |
6002 | return 2; | |
6003 | return 0; | |
6004 | } | |
6005 | _ACEOF | |
6006 | if ac_fn_c_try_run "$LINENO"; then : | |
6007 | ||
6008 | else | |
6009 | ac_cv_header_stdc=no | |
6010 | fi | |
6011 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
6012 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
6013 | fi | |
6014 | ||
6015 | fi | |
6016 | fi | |
6017 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 | |
6018 | $as_echo "$ac_cv_header_stdc" >&6; } | |
6019 | if test $ac_cv_header_stdc = yes; then | |
6020 | ||
6021 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h | |
6022 | ||
6023 | fi | |
6024 | ||
6025 | # On IRIX 5.3, sys/types and inttypes.h are conflicting. | |
6026 | for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ | |
6027 | inttypes.h stdint.h unistd.h | |
6028 | do : | |
6029 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
6030 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default | |
6031 | " | |
2018939f | 6032 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
067d23c9 KY |
6033 | cat >>confdefs.h <<_ACEOF |
6034 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
6035 | _ACEOF | |
6036 | ||
6037 | fi | |
6038 | ||
6039 | done | |
6040 | ||
6041 | ||
6042 | ||
1fd182f0 PE |
6043 | |
6044 | ||
067d23c9 | 6045 | ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" |
d6974efa | 6046 | if test "x$ac_cv_header_minix_config_h" = xyes; then : |
067d23c9 KY |
6047 | MINIX=yes |
6048 | else | |
6049 | MINIX= | |
6050 | fi | |
6051 | ||
6052 | ||
6053 | if test "$MINIX" = yes; then | |
6054 | ||
6055 | $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h | |
6056 | ||
6057 | ||
6058 | $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h | |
6059 | ||
6060 | ||
6061 | $as_echo "#define _MINIX 1" >>confdefs.h | |
6062 | ||
6063 | fi | |
6064 | ||
1fd182f0 PE |
6065 | case "$host_os" in |
6066 | hpux*) | |
6067 | ||
6068 | $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h | |
6069 | ||
6070 | ;; | |
6071 | esac | |
6072 | ||
067d23c9 KY |
6073 | |
6074 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 | |
6075 | $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } | |
d6974efa | 6076 | if ${ac_cv_safe_to_define___extensions__+:} false; then : |
067d23c9 KY |
6077 | $as_echo_n "(cached) " >&6 |
6078 | else | |
6079 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
6080 | /* end confdefs.h. */ | |
6081 | ||
1fd182f0 PE |
6082 | # define __EXTENSIONS__ 1 |
6083 | $ac_includes_default | |
067d23c9 KY |
6084 | int |
6085 | main () | |
6086 | { | |
6087 | ||
6088 | ; | |
6089 | return 0; | |
6090 | } | |
6091 | _ACEOF | |
6092 | if ac_fn_c_try_compile "$LINENO"; then : | |
6093 | ac_cv_safe_to_define___extensions__=yes | |
6094 | else | |
6095 | ac_cv_safe_to_define___extensions__=no | |
6096 | fi | |
6097 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
6098 | fi | |
6099 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 | |
6100 | $as_echo "$ac_cv_safe_to_define___extensions__" >&6; } | |
6101 | test $ac_cv_safe_to_define___extensions__ = yes && | |
6102 | $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h | |
6103 | ||
6104 | $as_echo "#define _ALL_SOURCE 1" >>confdefs.h | |
6105 | ||
6106 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h | |
6107 | ||
6108 | $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h | |
6109 | ||
6110 | $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h | |
6111 | ||
6112 | ||
6113 | ||
1fd182f0 PE |
6114 | |
6115 | ||
6116 | ||
6117 | ||
6118 | ||
6119 | ||
6120 | ||
6121 | # Code from module arg-nonnull: | |
6122 | # Code from module c++defs: | |
942f733f | 6123 | # Code from module crypto/md5: |
f737437b | 6124 | # Code from module dtoastr: |
1fd182f0 PE |
6125 | # Code from module extensions: |
6126 | ||
5fa4ac76 | 6127 | # Code from module filemode: |
1f5d53eb | 6128 | # Code from module getloadavg: |
e275c824 PE |
6129 | # Code from module getopt-gnu: |
6130 | # Code from module getopt-posix: | |
6131 | # Code from module gettext-h: | |
67342916 | 6132 | # Code from module ignore-value: |
1fd182f0 PE |
6133 | # Code from module include_next: |
6134 | # Code from module intprops: | |
6135 | # Code from module mktime: | |
6136 | # Code from module multiarch: | |
16c3e636 | 6137 | # Code from module stdbool: |
1fd182f0 | 6138 | # Code from module stddef: |
5f90be1b | 6139 | # Code from module stdint: |
1f5d53eb | 6140 | # Code from module stdlib: |
16c3e636 | 6141 | # Code from module strftime: |
5fa4ac76 | 6142 | # Code from module sys_stat: |
1fd182f0 PE |
6143 | # Code from module time: |
6144 | # Code from module time_r: | |
e275c824 | 6145 | # Code from module unistd: |
1fd182f0 PE |
6146 | # Code from module warn-on-use: |
6147 | ||
6148 | ||
6149 | # On Suns, sometimes $CPP names a directory. | |
6150 | if test -n "$CPP" && test -d "$CPP"; then | |
6151 | CPP= | |
6152 | fi | |
6153 | ||
6154 | ## If not using gcc, and on Solaris, and no CPP specified, see if | |
6155 | ## using a Sun compiler, which needs -Xs to prevent whitespace. | |
6156 | if test x"$GCC" != xyes && test x"$emacs_check_sunpro_c" = xyes && \ | |
6157 | test x"$CPP" = x; then | |
6158 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using a Sun C compiler" >&5 | |
6159 | $as_echo_n "checking whether we are using a Sun C compiler... " >&6; } | |
d6974efa | 6160 | if ${emacs_cv_sunpro_c+:} false; then : |
1fd182f0 PE |
6161 | $as_echo_n "(cached) " >&6 |
6162 | else | |
6163 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
6164 | /* end confdefs.h. */ | |
6165 | ||
6166 | int | |
6167 | main () | |
6168 | { | |
6169 | #ifndef __SUNPRO_C | |
6170 | fail; | |
6171 | #endif | |
6172 | ||
6173 | ; | |
6174 | return 0; | |
6175 | } | |
6176 | _ACEOF | |
6177 | if ac_fn_c_try_link "$LINENO"; then : | |
6178 | emacs_cv_sunpro_c=yes | |
6179 | else | |
6180 | emacs_cv_sunpro_c=no | |
6181 | fi | |
6182 | rm -f core conftest.err conftest.$ac_objext \ | |
6183 | conftest$ac_exeext conftest.$ac_ext | |
6184 | fi | |
6185 | ||
6186 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_sunpro_c" >&5 | |
6187 | $as_echo "$emacs_cv_sunpro_c" >&6; } | |
6188 | ||
6189 | if test x"$emacs_cv_sunpro_c" = xyes; then | |
6190 | NON_GNU_CPP="$CC -E -Xs" | |
6191 | fi | |
6192 | fi | |
6193 | ||
6194 | #### Some systems specify a CPP to use unless we are using GCC. | |
6195 | #### Now that we know whether we are using GCC, we can decide whether | |
6196 | #### to use that one. | |
6197 | if test "x$NON_GNU_CPP" != x && test x$GCC != xyes && test "x$CPP" = x | |
6198 | then | |
6199 | CPP="$NON_GNU_CPP" | |
6200 | fi | |
6201 | ||
6202 | #### Some systems specify a CC to use unless we are using GCC. | |
6203 | #### Now that we know whether we are using GCC, we can decide whether | |
6204 | #### to use that one. | |
6205 | if test "x$NON_GNU_CC" != x && test x$GCC != xyes && | |
6206 | test x$cc_specified != xyes | |
6207 | then | |
6208 | CC="$NON_GNU_CC" | |
6209 | fi | |
6210 | ||
6211 | if test x$GCC = xyes; then | |
6212 | test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS" | |
6213 | else | |
6214 | test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS" | |
6215 | fi | |
6216 | ||
067d23c9 KY |
6217 | ### Use -Wno-pointer-sign if the compiler supports it |
6218 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wno-pointer-sign" >&5 | |
6219 | $as_echo_n "checking whether gcc understands -Wno-pointer-sign... " >&6; } | |
6220 | SAVE_CFLAGS="$CFLAGS" | |
6221 | CFLAGS="$CFLAGS -Wno-pointer-sign" | |
6222 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
6223 | /* end confdefs.h. */ | |
6224 | ||
6225 | int | |
6226 | main () | |
6227 | { | |
6228 | ||
6229 | ; | |
6230 | return 0; | |
6231 | } | |
6232 | _ACEOF | |
6233 | if ac_fn_c_try_compile "$LINENO"; then : | |
6234 | has_option=yes | |
6235 | else | |
6236 | has_option=no | |
6237 | fi | |
6238 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
6239 | if test $has_option = yes; then | |
6240 | C_WARNINGS_SWITCH="-Wno-pointer-sign $C_WARNINGS_SWITCH" | |
6241 | fi | |
6242 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5 | |
6243 | $as_echo "$has_option" >&6; } | |
6244 | CFLAGS="$SAVE_CFLAGS" | |
6245 | unset has_option | |
6246 | unset SAVE_CFLAGS | |
6247 | ||
6248 | ### Use -Wdeclaration-after-statement if the compiler supports it | |
6249 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wdeclaration-after-statement" >&5 | |
6250 | $as_echo_n "checking whether gcc understands -Wdeclaration-after-statement... " >&6; } | |
6251 | SAVE_CFLAGS="$CFLAGS" | |
6252 | CFLAGS="$CFLAGS -Wdeclaration-after-statement" | |
6253 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
6254 | /* end confdefs.h. */ | |
6255 | ||
6256 | int | |
6257 | main () | |
6258 | { | |
6259 | ||
6260 | ; | |
6261 | return 0; | |
6262 | } | |
6263 | _ACEOF | |
6264 | if ac_fn_c_try_compile "$LINENO"; then : | |
6265 | has_option=yes | |
6266 | else | |
6267 | has_option=no | |
6268 | fi | |
6269 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
6270 | if test $has_option = yes; then | |
6271 | C_WARNINGS_SWITCH="-Wdeclaration-after-statement $C_WARNINGS_SWITCH" | |
6272 | fi | |
6273 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5 | |
6274 | $as_echo "$has_option" >&6; } | |
6275 | CFLAGS="$SAVE_CFLAGS" | |
6276 | unset has_option | |
6277 | unset SAVE_CFLAGS | |
6278 | ||
6279 | ### Use -Wold-style-definition if the compiler supports it | |
6280 | # This can be removed when conversion to standard C is finished. | |
6281 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wold-style-definition" >&5 | |
6282 | $as_echo_n "checking whether gcc understands -Wold-style-definition... " >&6; } | |
6283 | SAVE_CFLAGS="$CFLAGS" | |
6284 | CFLAGS="$CFLAGS -Wold-style-definition" | |
6285 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
6286 | /* end confdefs.h. */ | |
6287 | ||
6288 | int | |
6289 | main () | |
6290 | { | |
6291 | ||
6292 | ; | |
6293 | return 0; | |
6294 | } | |
6295 | _ACEOF | |
6296 | if ac_fn_c_try_compile "$LINENO"; then : | |
6297 | has_option=yes | |
6298 | else | |
6299 | has_option=no | |
6300 | fi | |
6301 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
6302 | if test $has_option = yes; then | |
6303 | C_WARNINGS_SWITCH="-Wold-style-definition $C_WARNINGS_SWITCH" | |
6304 | fi | |
6305 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5 | |
6306 | $as_echo "$has_option" >&6; } | |
6307 | CFLAGS="$SAVE_CFLAGS" | |
6308 | unset has_option | |
6309 | unset SAVE_CFLAGS | |
6310 | ||
6311 | ### Use -Wimplicit-function-declaration if the compiler supports it | |
6312 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wimplicit-function-declaration" >&5 | |
6313 | $as_echo_n "checking whether gcc understands -Wimplicit-function-declaration... " >&6; } | |
6314 | SAVE_CFLAGS="$CFLAGS" | |
6315 | CFLAGS="$CFLAGS -Wimplicit-function-declaration" | |
6316 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
6317 | /* end confdefs.h. */ | |
6318 | ||
6319 | int | |
6320 | main () | |
6321 | { | |
6322 | ||
6323 | ; | |
6324 | return 0; | |
6325 | } | |
6326 | _ACEOF | |
6327 | if ac_fn_c_try_compile "$LINENO"; then : | |
6328 | has_option=yes | |
6329 | else | |
6330 | has_option=no | |
6331 | fi | |
6332 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
6333 | if test $has_option = yes; then | |
6334 | C_WARNINGS_SWITCH="-Wimplicit-function-declaration $C_WARNINGS_SWITCH" | |
6335 | fi | |
6336 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5 | |
6337 | $as_echo "$has_option" >&6; } | |
6338 | CFLAGS="$SAVE_CFLAGS" | |
6339 | unset has_option | |
6340 | unset SAVE_CFLAGS | |
6341 | ||
6342 | ||
6343 | ||
6344 | ||
6345 | #### Some other nice autoconf tests. | |
6346 | ||
6347 | ac_ext=c | |
6348 | ac_cpp='$CPP $CPPFLAGS' | |
6349 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
6350 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
6351 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
6352 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 | |
6353 | $as_echo_n "checking how to run the C preprocessor... " >&6; } | |
6354 | # On Suns, sometimes $CPP names a directory. | |
6355 | if test -n "$CPP" && test -d "$CPP"; then | |
6356 | CPP= | |
6357 | fi | |
6358 | if test -z "$CPP"; then | |
d6974efa | 6359 | if ${ac_cv_prog_CPP+:} false; then : |
067d23c9 KY |
6360 | $as_echo_n "(cached) " >&6 |
6361 | else | |
6362 | # Double quotes because CPP needs to be expanded | |
6363 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" | |
6364 | do | |
6365 | ac_preproc_ok=false | |
6366 | for ac_c_preproc_warn_flag in '' yes | |
6367 | do | |
6368 | # Use a header file that comes with gcc, so configuring glibc | |
6369 | # with a fresh cross-compiler works. | |
6370 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
6371 | # <limits.h> exists even on freestanding compilers. | |
6372 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
6373 | # not just through cpp. "Syntax error" is here to catch this case. | |
6374 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
6375 | /* end confdefs.h. */ | |
6376 | #ifdef __STDC__ | |
6377 | # include <limits.h> | |
6378 | #else | |
6379 | # include <assert.h> | |
6380 | #endif | |
6381 | Syntax error | |
6382 | _ACEOF | |
6383 | if ac_fn_c_try_cpp "$LINENO"; then : | |
6384 | ||
6385 | else | |
6386 | # Broken: fails on valid input. | |
6387 | continue | |
6388 | fi | |
2018939f | 6389 | rm -f conftest.err conftest.i conftest.$ac_ext |
067d23c9 KY |
6390 | |
6391 | # OK, works on sane cases. Now check whether nonexistent headers | |
6392 | # can be detected and how. | |
6393 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
6394 | /* end confdefs.h. */ | |
6395 | #include <ac_nonexistent.h> | |
6396 | _ACEOF | |
6397 | if ac_fn_c_try_cpp "$LINENO"; then : | |
6398 | # Broken: success on invalid input. | |
6399 | continue | |
6400 | else | |
6401 | # Passes both tests. | |
6402 | ac_preproc_ok=: | |
6403 | break | |
6404 | fi | |
2018939f | 6405 | rm -f conftest.err conftest.i conftest.$ac_ext |
067d23c9 KY |
6406 | |
6407 | done | |
6408 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
2018939f | 6409 | rm -f conftest.i conftest.err conftest.$ac_ext |
067d23c9 KY |
6410 | if $ac_preproc_ok; then : |
6411 | break | |
6412 | fi | |
6413 | ||
6414 | done | |
6415 | ac_cv_prog_CPP=$CPP | |
6416 | ||
6417 | fi | |
6418 | CPP=$ac_cv_prog_CPP | |
6419 | else | |
6420 | ac_cv_prog_CPP=$CPP | |
6421 | fi | |
6422 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 | |
6423 | $as_echo "$CPP" >&6; } | |
6424 | ac_preproc_ok=false | |
6425 | for ac_c_preproc_warn_flag in '' yes | |
6426 | do | |
6427 | # Use a header file that comes with gcc, so configuring glibc | |
6428 | # with a fresh cross-compiler works. | |
6429 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
6430 | # <limits.h> exists even on freestanding compilers. | |
6431 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
6432 | # not just through cpp. "Syntax error" is here to catch this case. | |
6433 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
6434 | /* end confdefs.h. */ | |
6435 | #ifdef __STDC__ | |
6436 | # include <limits.h> | |
6437 | #else | |
6438 | # include <assert.h> | |
6439 | #endif | |
6440 | Syntax error | |
6441 | _ACEOF | |
6442 | if ac_fn_c_try_cpp "$LINENO"; then : | |
6443 | ||
6444 | else | |
6445 | # Broken: fails on valid input. | |
6446 | continue | |
6447 | fi | |
2018939f | 6448 | rm -f conftest.err conftest.i conftest.$ac_ext |
067d23c9 KY |
6449 | |
6450 | # OK, works on sane cases. Now check whether nonexistent headers | |
6451 | # can be detected and how. | |
6452 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
6453 | /* end confdefs.h. */ | |
6454 | #include <ac_nonexistent.h> | |
6455 | _ACEOF | |
6456 | if ac_fn_c_try_cpp "$LINENO"; then : | |
6457 | # Broken: success on invalid input. | |
6458 | continue | |
6459 | else | |
6460 | # Passes both tests. | |
6461 | ac_preproc_ok=: | |
6462 | break | |
6463 | fi | |
2018939f | 6464 | rm -f conftest.err conftest.i conftest.$ac_ext |
067d23c9 KY |
6465 | |
6466 | done | |
6467 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
2018939f | 6468 | rm -f conftest.i conftest.err conftest.$ac_ext |
067d23c9 KY |
6469 | if $ac_preproc_ok; then : |
6470 | ||
6471 | else | |
6472 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
6473 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2018939f | 6474 | as_fn_error $? "C preprocessor \"$CPP\" fails sanity check |
d6974efa | 6475 | See \`config.log' for more details" "$LINENO" 5; } |
067d23c9 KY |
6476 | fi |
6477 | ||
6478 | ac_ext=c | |
6479 | ac_cpp='$CPP $CPPFLAGS' | |
6480 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
6481 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
6482 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
6483 | ||
067d23c9 KY |
6484 | |
6485 | if test "x$RANLIB" = x; then | |
6486 | if test -n "$ac_tool_prefix"; then | |
6487 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. | |
6488 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 | |
6489 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
6490 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 6491 | if ${ac_cv_prog_RANLIB+:} false; then : |
067d23c9 KY |
6492 | $as_echo_n "(cached) " >&6 |
6493 | else | |
6494 | if test -n "$RANLIB"; then | |
6495 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
6496 | else | |
6497 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
6498 | for as_dir in $PATH | |
6499 | do | |
6500 | IFS=$as_save_IFS | |
6501 | test -z "$as_dir" && as_dir=. | |
6502 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6503 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
6504 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" | |
6505 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
6506 | break 2 | |
6507 | fi | |
6508 | done | |
6509 | done | |
6510 | IFS=$as_save_IFS | |
6511 | ||
6512 | fi | |
6513 | fi | |
6514 | RANLIB=$ac_cv_prog_RANLIB | |
6515 | if test -n "$RANLIB"; then | |
6516 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 | |
6517 | $as_echo "$RANLIB" >&6; } | |
6518 | else | |
6519 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
6520 | $as_echo "no" >&6; } | |
6521 | fi | |
6522 | ||
6523 | ||
6524 | fi | |
6525 | if test -z "$ac_cv_prog_RANLIB"; then | |
6526 | ac_ct_RANLIB=$RANLIB | |
6527 | # Extract the first word of "ranlib", so it can be a program name with args. | |
6528 | set dummy ranlib; ac_word=$2 | |
6529 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
6530 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 6531 | if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : |
067d23c9 KY |
6532 | $as_echo_n "(cached) " >&6 |
6533 | else | |
6534 | if test -n "$ac_ct_RANLIB"; then | |
6535 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. | |
6536 | else | |
6537 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
6538 | for as_dir in $PATH | |
6539 | do | |
6540 | IFS=$as_save_IFS | |
6541 | test -z "$as_dir" && as_dir=. | |
6542 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6543 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
6544 | ac_cv_prog_ac_ct_RANLIB="ranlib" | |
6545 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
6546 | break 2 | |
6547 | fi | |
6548 | done | |
6549 | done | |
6550 | IFS=$as_save_IFS | |
6551 | ||
6552 | fi | |
6553 | fi | |
6554 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB | |
6555 | if test -n "$ac_ct_RANLIB"; then | |
6556 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 | |
6557 | $as_echo "$ac_ct_RANLIB" >&6; } | |
6558 | else | |
6559 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
6560 | $as_echo "no" >&6; } | |
6561 | fi | |
6562 | ||
6563 | if test "x$ac_ct_RANLIB" = x; then | |
6564 | RANLIB=":" | |
6565 | else | |
6566 | case $cross_compiling:$ac_tool_warned in | |
6567 | yes:) | |
6568 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
6569 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
6570 | ac_tool_warned=yes ;; | |
6571 | esac | |
6572 | RANLIB=$ac_ct_RANLIB | |
6573 | fi | |
6574 | else | |
6575 | RANLIB="$ac_cv_prog_RANLIB" | |
6576 | fi | |
6577 | ||
6578 | fi | |
6579 | ||
6580 | ## Although we're running on an amd64 kernel, we're actually compiling for | |
6581 | ## the x86 architecture. The user should probably have provided an | |
6582 | ## explicit --build to `configure', but if everything else than the kernel | |
6583 | ## is running in i386 mode, we can help them out. | |
6584 | if test "$machine" = "amdx86-64"; then | |
6585 | ac_fn_c_check_decl "$LINENO" "i386" "ac_cv_have_decl_i386" "$ac_includes_default" | |
d6974efa | 6586 | if test "x$ac_cv_have_decl_i386" = xyes; then : |
067d23c9 KY |
6587 | |
6588 | fi | |
6589 | ||
6590 | if test "$ac_cv_have_decl_i386" = "yes"; then | |
6591 | canonical=`echo "$canonical" | sed -e 's/^amd64/i386/' -e 's/^x86_64/i386/'` | |
6592 | machine=intel386 | |
6593 | machfile="m/${machine}.h" | |
6594 | fi | |
6595 | fi | |
6596 | ||
6597 | # Extract the first word of "install-info", so it can be a program name with args. | |
6598 | set dummy install-info; ac_word=$2 | |
6599 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
6600 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 6601 | if ${ac_cv_path_INSTALL_INFO+:} false; then : |
067d23c9 KY |
6602 | $as_echo_n "(cached) " >&6 |
6603 | else | |
6604 | case $INSTALL_INFO in | |
6605 | [\\/]* | ?:[\\/]*) | |
6606 | ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path. | |
6607 | ;; | |
6608 | *) | |
6609 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
6610 | for as_dir in $PATH | |
6611 | do | |
6612 | IFS=$as_save_IFS | |
6613 | test -z "$as_dir" && as_dir=. | |
6614 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6615 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
6616 | ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext" | |
6617 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
6618 | break 2 | |
6619 | fi | |
6620 | done | |
6621 | done | |
6622 | IFS=$as_save_IFS | |
6623 | ||
6624 | ;; | |
6625 | esac | |
6626 | fi | |
6627 | INSTALL_INFO=$ac_cv_path_INSTALL_INFO | |
6628 | if test -n "$INSTALL_INFO"; then | |
6629 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5 | |
6630 | $as_echo "$INSTALL_INFO" >&6; } | |
6631 | else | |
6632 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
6633 | $as_echo "no" >&6; } | |
6634 | fi | |
6635 | ||
6636 | ||
6637 | # Extract the first word of "install-info", so it can be a program name with args. | |
6638 | set dummy install-info; ac_word=$2 | |
6639 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
6640 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 6641 | if ${ac_cv_path_INSTALL_INFO+:} false; then : |
067d23c9 KY |
6642 | $as_echo_n "(cached) " >&6 |
6643 | else | |
6644 | case $INSTALL_INFO in | |
6645 | [\\/]* | ?:[\\/]*) | |
6646 | ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path. | |
6647 | ;; | |
6648 | *) | |
6649 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
6650 | for as_dir in /usr/sbin | |
6651 | do | |
6652 | IFS=$as_save_IFS | |
6653 | test -z "$as_dir" && as_dir=. | |
6654 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6655 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
6656 | ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext" | |
6657 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
6658 | break 2 | |
6659 | fi | |
6660 | done | |
6661 | done | |
6662 | IFS=$as_save_IFS | |
6663 | ||
6664 | ;; | |
6665 | esac | |
6666 | fi | |
6667 | INSTALL_INFO=$ac_cv_path_INSTALL_INFO | |
6668 | if test -n "$INSTALL_INFO"; then | |
6669 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5 | |
6670 | $as_echo "$INSTALL_INFO" >&6; } | |
6671 | else | |
6672 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
6673 | $as_echo "no" >&6; } | |
6674 | fi | |
6675 | ||
6676 | ||
6677 | # Extract the first word of "install-info", so it can be a program name with args. | |
6678 | set dummy install-info; ac_word=$2 | |
6679 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
6680 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 6681 | if ${ac_cv_path_INSTALL_INFO+:} false; then : |
067d23c9 KY |
6682 | $as_echo_n "(cached) " >&6 |
6683 | else | |
6684 | case $INSTALL_INFO in | |
6685 | [\\/]* | ?:[\\/]*) | |
6686 | ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path. | |
6687 | ;; | |
6688 | *) | |
6689 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
6690 | for as_dir in /sbin | |
6691 | do | |
6692 | IFS=$as_save_IFS | |
6693 | test -z "$as_dir" && as_dir=. | |
6694 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6695 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
6696 | ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext" | |
6697 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
6698 | break 2 | |
6699 | fi | |
6700 | done | |
6701 | done | |
6702 | IFS=$as_save_IFS | |
6703 | ||
6704 | test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":" | |
6705 | ;; | |
6706 | esac | |
6707 | fi | |
6708 | INSTALL_INFO=$ac_cv_path_INSTALL_INFO | |
6709 | if test -n "$INSTALL_INFO"; then | |
6710 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5 | |
6711 | $as_echo "$INSTALL_INFO" >&6; } | |
6712 | else | |
6713 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
6714 | $as_echo "no" >&6; } | |
6715 | fi | |
6716 | ||
6717 | ||
6718 | # Extract the first word of "gzip", so it can be a program name with args. | |
6719 | set dummy gzip; ac_word=$2 | |
6720 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
6721 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 6722 | if ${ac_cv_path_GZIP_PROG+:} false; then : |
067d23c9 KY |
6723 | $as_echo_n "(cached) " >&6 |
6724 | else | |
6725 | case $GZIP_PROG in | |
6726 | [\\/]* | ?:[\\/]*) | |
6727 | ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path. | |
6728 | ;; | |
6729 | *) | |
6730 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
6731 | for as_dir in $PATH | |
6732 | do | |
6733 | IFS=$as_save_IFS | |
6734 | test -z "$as_dir" && as_dir=. | |
6735 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6736 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
6737 | ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext" | |
6738 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
6739 | break 2 | |
6740 | fi | |
6741 | done | |
6742 | done | |
6743 | IFS=$as_save_IFS | |
6744 | ||
6745 | ;; | |
6746 | esac | |
6747 | fi | |
6748 | GZIP_PROG=$ac_cv_path_GZIP_PROG | |
6749 | if test -n "$GZIP_PROG"; then | |
6750 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5 | |
6751 | $as_echo "$GZIP_PROG" >&6; } | |
6752 | else | |
6753 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
6754 | $as_echo "no" >&6; } | |
6755 | fi | |
6756 | ||
6757 | ||
6758 | ||
6759 | ||
6760 | ## Need makeinfo >= 4.6 (?) to build the manuals. | |
6761 | # Extract the first word of "makeinfo", so it can be a program name with args. | |
6762 | set dummy makeinfo; ac_word=$2 | |
6763 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
6764 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 6765 | if ${ac_cv_path_MAKEINFO+:} false; then : |
067d23c9 KY |
6766 | $as_echo_n "(cached) " >&6 |
6767 | else | |
6768 | case $MAKEINFO in | |
6769 | [\\/]* | ?:[\\/]*) | |
6770 | ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path. | |
6771 | ;; | |
6772 | *) | |
6773 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
6774 | for as_dir in $PATH | |
6775 | do | |
6776 | IFS=$as_save_IFS | |
6777 | test -z "$as_dir" && as_dir=. | |
6778 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6779 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
6780 | ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext" | |
6781 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
6782 | break 2 | |
6783 | fi | |
6784 | done | |
6785 | done | |
6786 | IFS=$as_save_IFS | |
6787 | ||
6788 | test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no" | |
6789 | ;; | |
6790 | esac | |
6791 | fi | |
6792 | MAKEINFO=$ac_cv_path_MAKEINFO | |
6793 | if test -n "$MAKEINFO"; then | |
6794 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5 | |
6795 | $as_echo "$MAKEINFO" >&6; } | |
6796 | else | |
6797 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
6798 | $as_echo "no" >&6; } | |
6799 | fi | |
6800 | ||
6801 | ||
6802 | if test "$MAKEINFO" != "no" && \ | |
6803 | test x"`$MAKEINFO --version 2> /dev/null | $EGREP 'texinfo[^0-9]*([1-4][0-9]+|[5-9]|4\.[6-9]|4\.[1-5][0-9]+)'`" = x; then | |
6804 | MAKEINFO=no | |
6805 | fi | |
6806 | ||
6807 | ## Makeinfo is unusual. For a released Emacs, the manuals are | |
6808 | ## pre-built, and not deleted by the normal clean rules. makeinfo is | |
6809 | ## therefore in the category of "special tools" not normally required, which | |
6810 | ## configure does not have to check for (eg autoconf itself). | |
6811 | ## In a Bazaar checkout on the other hand, the manuals are not included. | |
6812 | ## So makeinfo is a requirement to build from Bazaar, and configure | |
6813 | ## should test for it as it does for any other build requirement. | |
6814 | ## We use the presence of $srcdir/info/emacs to distinguish a release, | |
6815 | ## with pre-built manuals, from a Bazaar checkout. | |
96f129d5 GM |
6816 | HAVE_MAKEINFO=yes |
6817 | ||
067d23c9 | 6818 | if test "$MAKEINFO" = "no"; then |
96f129d5 | 6819 | MAKEINFO=makeinfo |
067d23c9 | 6820 | if test "x${with_makeinfo}" = "xno"; then |
96f129d5 | 6821 | HAVE_MAKEINFO=no |
067d23c9 | 6822 | elif test ! -e $srcdir/info/emacs; then |
2018939f | 6823 | as_fn_error $? "You do not seem to have makeinfo >= 4.6, and your |
067d23c9 KY |
6824 | source tree does not seem to have pre-built manuals in the \`info' directory. |
6825 | Either install a suitable version of makeinfo, or re-run configure | |
6826 | with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5 | |
6827 | fi | |
6828 | fi | |
6829 | ||
6830 | ||
96f129d5 | 6831 | |
067d23c9 KY |
6832 | if test x$GCC = xyes; then |
6833 | test "x$GCC_LINK_TEST_OPTIONS" != x && \ | |
6834 | ac_link="$ac_link $GCC_LINK_TEST_OPTIONS" | |
6835 | else | |
6836 | test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \ | |
6837 | ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS" | |
6838 | fi | |
6839 | ||
6840 | ||
6841 | late_LDFLAGS=$LDFLAGS | |
6842 | if test x$GCC = xyes; then | |
6843 | LDFLAGS="$LDFLAGS -Wl,-znocombreloc" | |
6844 | else | |
6845 | LDFLAGS="$LDFLAGS -znocombreloc" | |
6846 | fi | |
6847 | ||
6848 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5 | |
6849 | $as_echo_n "checking for -znocombreloc... " >&6; } | |
6850 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
6851 | /* end confdefs.h. */ | |
6852 | ||
6853 | int | |
6854 | main () | |
6855 | { | |
6856 | ||
6857 | ; | |
6858 | return 0; | |
6859 | } | |
6860 | _ACEOF | |
6861 | if ac_fn_c_try_link "$LINENO"; then : | |
6862 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
6863 | $as_echo "yes" >&6; } | |
6864 | else | |
6865 | LDFLAGS=$late_LDFLAGS | |
6866 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
6867 | $as_echo "no" >&6; } | |
6868 | fi | |
6869 | rm -f core conftest.err conftest.$ac_objext \ | |
6870 | conftest$ac_exeext conftest.$ac_ext | |
6871 | ||
6872 | ||
6873 | # The value of CPP is a quoted variable reference, so we need to do this | |
6874 | # to get its actual value... | |
6875 | CPP=`eval "echo $CPP"` | |
6876 | ||
6877 | ||
125c3718 | 6878 | test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no |
067d23c9 | 6879 | case "$opsys" in |
125c3718 PE |
6880 | your-opsys-here) CANNOT_DUMP=yes ;; |
6881 | esac | |
6882 | ||
6883 | test "$CANNOT_DUMP" = "yes" && \ | |
067d23c9 KY |
6884 | |
6885 | $as_echo "#define CANNOT_DUMP 1" >>confdefs.h | |
6886 | ||
125c3718 | 6887 | |
067d23c9 KY |
6888 | |
6889 | ||
6890 | ||
6891 | UNEXEC_OBJ=unexelf.o | |
6892 | case "$opsys" in | |
6893 | # MSDOS uses unexcoff.o | |
6894 | # MSWindows uses unexw32.o | |
6895 | aix4-2) | |
6896 | UNEXEC_OBJ=unexaix.o | |
6897 | ;; | |
6898 | cygwin) | |
6899 | UNEXEC_OBJ=unexcw.o | |
6900 | ;; | |
6901 | darwin) | |
6902 | UNEXEC_OBJ=unexmacosx.o | |
6903 | ;; | |
6904 | hpux10-20 | hpux11) | |
6905 | UNEXEC_OBJ=unexhp9k800.o | |
6906 | ;; | |
6907 | sol2-10) | |
6908 | # Use the Solaris dldump() function, called from unexsol.c, to dump | |
6909 | # emacs, instead of the generic ELF dump code found in unexelf.c. | |
6910 | # The resulting binary has a complete symbol table, and is better | |
6911 | # for debugging and other observability tools (debuggers, pstack, etc). | |
6912 | # | |
6913 | # If you encounter a problem using dldump(), please consider sending | |
6914 | # a message to the OpenSolaris tools-linking mailing list: | |
6915 | # http://mail.opensolaris.org/mailman/listinfo/tools-linking | |
6916 | # | |
6917 | # It is likely that dldump() works with older Solaris too, but this has | |
6918 | # not been tested, so for now this change is for Solaris 10 or newer. | |
6919 | UNEXEC_OBJ=unexsol.o | |
6920 | ;; | |
6921 | esac | |
6922 | ||
6923 | LD_SWITCH_SYSTEM= | |
6924 | case "$opsys" in | |
6925 | freebsd) | |
6926 | ## Let `ld' find image libs and similar things in /usr/local/lib. | |
6927 | ## The system compiler, GCC, has apparently been modified to not | |
6928 | ## look there, contrary to what a stock GCC would do. | |
6929 | LD_SWITCH_SYSTEM=-L/usr/local/lib | |
6930 | ;; | |
6931 | ||
6932 | gnu-linux) | |
6933 | ## cpp test was "ifdef __mips__", but presumably this is equivalent... | |
d6a003a8 | 6934 | case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac |
067d23c9 KY |
6935 | ;; |
6936 | ||
6937 | netbsd) | |
6938 | LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib" | |
6939 | ;; | |
6940 | ||
6941 | openbsd) | |
6942 | ## Han Boetes <han@mijncomputer.nl> says this is necessary, | |
6943 | ## otherwise Emacs dumps core on elf systems. | |
6944 | LD_SWITCH_SYSTEM="-Z" | |
6945 | ;; | |
6946 | esac | |
6947 | ||
6948 | ||
6949 | ac_link="$ac_link $LD_SWITCH_SYSTEM" | |
6950 | ||
6951 | ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_AUX, | |
6952 | ## which has not been defined yet. When this was handled with cpp, | |
6953 | ## it was expanded to null when configure sourced the s/*.h file. | |
6954 | ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles. | |
6955 | ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS | |
6956 | ## (or somesuch), but because it is supposed to go at the _front_ | |
6957 | ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way. | |
6958 | ## Compare with the gnu-linux case below, which added to the end | |
6959 | ## of LD_SWITCH_SYSTEM, and so can instead go at the front of | |
6960 | ## LD_SWITCH_SYSTEM_TEMACS. | |
6961 | case "$opsys" in | |
6962 | netbsd|openbsd) | |
6963 | ## _AUX_RPATH is like _AUX, but uses -rpath instead of -R. | |
6964 | LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_AUX_RPATH) $LD_SWITCH_SYSTEM" ;; | |
6965 | esac | |
6966 | ||
6967 | ||
6968 | C_SWITCH_MACHINE= | |
6969 | if test "$machine" = "alpha"; then | |
6970 | ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default" | |
d6974efa | 6971 | if test "x$ac_cv_have_decl___ELF__" = xyes; then : |
067d23c9 KY |
6972 | |
6973 | fi | |
6974 | ||
6975 | if test "$ac_cv_have_decl___ELF__" = "yes"; then | |
6976 | ## With ELF, make sure that all common symbols get allocated to in the | |
6977 | ## data section. Otherwise, the dump of temacs may miss variables in | |
6978 | ## the shared library that have been initialized. For example, with | |
6979 | ## GNU libc, __malloc_initialized would normally be resolved to the | |
6980 | ## shared library's .bss section, which is fatal. | |
6981 | if test "x$GCC" = "xyes"; then | |
6982 | C_SWITCH_MACHINE="-fno-common" | |
6983 | else | |
2018939f | 6984 | as_fn_error $? "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5 |
067d23c9 KY |
6985 | fi |
6986 | else | |
6987 | UNEXEC_OBJ=unexalpha.o | |
6988 | fi | |
6989 | fi | |
6990 | ||
6991 | ||
6992 | ||
6993 | ||
6994 | C_SWITCH_SYSTEM= | |
6995 | ## Some programs in src produce warnings saying certain subprograms | |
6996 | ## are too complex and need a MAXMEM value greater than 2000 for | |
6997 | ## additional optimization. --nils@exp-math.uni-essen.de | |
6998 | test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \ | |
6999 | C_SWITCH_SYSTEM="-ma -qmaxmem=4000" | |
7000 | ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems. | |
7001 | ## It is redundant in glibc2, since we define _GNU_SOURCE. | |
7002 | ||
7003 | ||
7004 | ||
7005 | LIBS_SYSTEM= | |
7006 | case "$opsys" in | |
7007 | ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2. | |
7008 | aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;; | |
7009 | ||
7010 | freebsd) LIBS_SYSTEM="-lutil" ;; | |
7011 | ||
7012 | hpux*) LIBS_SYSTEM="-l:libdld.sl" ;; | |
7013 | ||
1f5d53eb | 7014 | sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;; |
067d23c9 KY |
7015 | |
7016 | ## Motif needs -lgen. | |
7017 | unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;; | |
7018 | esac | |
7019 | ||
7020 | ||
7021 | ||
7022 | ### Make sure subsequent tests use flags consistent with the build flags. | |
7023 | ||
7024 | if test x"${OVERRIDE_CPPFLAGS}" != x; then | |
7025 | CPPFLAGS="${OVERRIDE_CPPFLAGS}" | |
7026 | else | |
7027 | CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS" | |
7028 | fi | |
7029 | ||
067d23c9 KY |
7030 | # Check whether --enable-largefile was given. |
7031 | if test "${enable_largefile+set}" = set; then : | |
7032 | enableval=$enable_largefile; | |
7033 | fi | |
7034 | ||
7035 | if test "$enable_largefile" != no; then | |
7036 | ||
7037 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5 | |
7038 | $as_echo_n "checking for special C compiler options needed for large files... " >&6; } | |
d6974efa | 7039 | if ${ac_cv_sys_largefile_CC+:} false; then : |
067d23c9 KY |
7040 | $as_echo_n "(cached) " >&6 |
7041 | else | |
7042 | ac_cv_sys_largefile_CC=no | |
7043 | if test "$GCC" != yes; then | |
7044 | ac_save_CC=$CC | |
7045 | while :; do | |
7046 | # IRIX 6.2 and later do not support large files by default, | |
7047 | # so use the C compiler's -n32 option if that helps. | |
7048 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7049 | /* end confdefs.h. */ | |
7050 | #include <sys/types.h> | |
7051 | /* Check that off_t can represent 2**63 - 1 correctly. | |
7052 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
7053 | since some C++ compilers masquerading as C compilers | |
7054 | incorrectly reject 9223372036854775807. */ | |
7055 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) | |
7056 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 | |
7057 | && LARGE_OFF_T % 2147483647 == 1) | |
7058 | ? 1 : -1]; | |
7059 | int | |
7060 | main () | |
7061 | { | |
7062 | ||
7063 | ; | |
7064 | return 0; | |
7065 | } | |
7066 | _ACEOF | |
7067 | if ac_fn_c_try_compile "$LINENO"; then : | |
7068 | break | |
7069 | fi | |
7070 | rm -f core conftest.err conftest.$ac_objext | |
7071 | CC="$CC -n32" | |
7072 | if ac_fn_c_try_compile "$LINENO"; then : | |
7073 | ac_cv_sys_largefile_CC=' -n32'; break | |
7074 | fi | |
7075 | rm -f core conftest.err conftest.$ac_objext | |
7076 | break | |
7077 | done | |
7078 | CC=$ac_save_CC | |
7079 | rm -f conftest.$ac_ext | |
7080 | fi | |
7081 | fi | |
7082 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5 | |
7083 | $as_echo "$ac_cv_sys_largefile_CC" >&6; } | |
7084 | if test "$ac_cv_sys_largefile_CC" != no; then | |
7085 | CC=$CC$ac_cv_sys_largefile_CC | |
7086 | fi | |
7087 | ||
7088 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5 | |
7089 | $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; } | |
d6974efa | 7090 | if ${ac_cv_sys_file_offset_bits+:} false; then : |
067d23c9 KY |
7091 | $as_echo_n "(cached) " >&6 |
7092 | else | |
7093 | while :; do | |
7094 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7095 | /* end confdefs.h. */ | |
7096 | #include <sys/types.h> | |
7097 | /* Check that off_t can represent 2**63 - 1 correctly. | |
7098 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
7099 | since some C++ compilers masquerading as C compilers | |
7100 | incorrectly reject 9223372036854775807. */ | |
7101 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) | |
7102 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 | |
7103 | && LARGE_OFF_T % 2147483647 == 1) | |
7104 | ? 1 : -1]; | |
7105 | int | |
7106 | main () | |
7107 | { | |
7108 | ||
7109 | ; | |
7110 | return 0; | |
7111 | } | |
7112 | _ACEOF | |
7113 | if ac_fn_c_try_compile "$LINENO"; then : | |
7114 | ac_cv_sys_file_offset_bits=no; break | |
7115 | fi | |
7116 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7117 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7118 | /* end confdefs.h. */ | |
7119 | #define _FILE_OFFSET_BITS 64 | |
7120 | #include <sys/types.h> | |
7121 | /* Check that off_t can represent 2**63 - 1 correctly. | |
7122 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
7123 | since some C++ compilers masquerading as C compilers | |
7124 | incorrectly reject 9223372036854775807. */ | |
7125 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) | |
7126 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 | |
7127 | && LARGE_OFF_T % 2147483647 == 1) | |
7128 | ? 1 : -1]; | |
7129 | int | |
7130 | main () | |
7131 | { | |
7132 | ||
7133 | ; | |
7134 | return 0; | |
7135 | } | |
7136 | _ACEOF | |
7137 | if ac_fn_c_try_compile "$LINENO"; then : | |
7138 | ac_cv_sys_file_offset_bits=64; break | |
7139 | fi | |
7140 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7141 | ac_cv_sys_file_offset_bits=unknown | |
7142 | break | |
7143 | done | |
7144 | fi | |
7145 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5 | |
7146 | $as_echo "$ac_cv_sys_file_offset_bits" >&6; } | |
7147 | case $ac_cv_sys_file_offset_bits in #( | |
7148 | no | unknown) ;; | |
7149 | *) | |
7150 | cat >>confdefs.h <<_ACEOF | |
7151 | #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits | |
7152 | _ACEOF | |
7153 | ;; | |
7154 | esac | |
7155 | rm -rf conftest* | |
7156 | if test $ac_cv_sys_file_offset_bits = unknown; then | |
7157 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5 | |
7158 | $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; } | |
d6974efa | 7159 | if ${ac_cv_sys_large_files+:} false; then : |
067d23c9 KY |
7160 | $as_echo_n "(cached) " >&6 |
7161 | else | |
7162 | while :; do | |
7163 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7164 | /* end confdefs.h. */ | |
7165 | #include <sys/types.h> | |
7166 | /* Check that off_t can represent 2**63 - 1 correctly. | |
7167 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
7168 | since some C++ compilers masquerading as C compilers | |
7169 | incorrectly reject 9223372036854775807. */ | |
7170 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) | |
7171 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 | |
7172 | && LARGE_OFF_T % 2147483647 == 1) | |
7173 | ? 1 : -1]; | |
7174 | int | |
7175 | main () | |
7176 | { | |
7177 | ||
7178 | ; | |
7179 | return 0; | |
7180 | } | |
7181 | _ACEOF | |
7182 | if ac_fn_c_try_compile "$LINENO"; then : | |
7183 | ac_cv_sys_large_files=no; break | |
7184 | fi | |
7185 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7186 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7187 | /* end confdefs.h. */ | |
7188 | #define _LARGE_FILES 1 | |
7189 | #include <sys/types.h> | |
7190 | /* Check that off_t can represent 2**63 - 1 correctly. | |
7191 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
7192 | since some C++ compilers masquerading as C compilers | |
7193 | incorrectly reject 9223372036854775807. */ | |
7194 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) | |
7195 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 | |
7196 | && LARGE_OFF_T % 2147483647 == 1) | |
7197 | ? 1 : -1]; | |
7198 | int | |
7199 | main () | |
7200 | { | |
7201 | ||
7202 | ; | |
7203 | return 0; | |
7204 | } | |
7205 | _ACEOF | |
7206 | if ac_fn_c_try_compile "$LINENO"; then : | |
7207 | ac_cv_sys_large_files=1; break | |
7208 | fi | |
7209 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7210 | ac_cv_sys_large_files=unknown | |
7211 | break | |
7212 | done | |
7213 | fi | |
7214 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5 | |
7215 | $as_echo "$ac_cv_sys_large_files" >&6; } | |
7216 | case $ac_cv_sys_large_files in #( | |
7217 | no | unknown) ;; | |
7218 | *) | |
7219 | cat >>confdefs.h <<_ACEOF | |
7220 | #define _LARGE_FILES $ac_cv_sys_large_files | |
7221 | _ACEOF | |
7222 | ;; | |
7223 | esac | |
7224 | rm -rf conftest* | |
7225 | fi | |
7226 | fi | |
7227 | ||
7228 | ||
7229 | ||
7230 | ## If user specified a crt-dir, use that unconditionally. | |
7231 | if test "X$CRT_DIR" = "X"; then | |
7232 | ||
7233 | case "$canonical" in | |
7234 | x86_64-*-linux-gnu* | s390x-*-linux-gnu*) | |
7235 | ## On x86-64 and s390x GNU/Linux distributions, the standard library | |
7236 | ## can be in a variety of places. We only try /usr/lib64 and /usr/lib. | |
7237 | ## For anything else (eg /usr/lib32), it is up the user to specify | |
7238 | ## the location (bug#5655). | |
7239 | ## Test for crtn.o, not just the directory, because sometimes the | |
7240 | ## directory exists but does not have the relevant files (bug#1287). | |
7241 | ## FIXME better to test for binary compatibility somehow. | |
7242 | test -e /usr/lib64/crtn.o && CRT_DIR=/usr/lib64 | |
7243 | ;; | |
7244 | ||
7245 | powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*) CRT_DIR=/usr/lib64 ;; | |
7246 | esac | |
7247 | ||
7248 | case "$opsys" in | |
7249 | hpux10-20) CRT_DIR=/lib ;; | |
7250 | esac | |
7251 | ||
7252 | ## Default is /usr/lib. | |
7253 | test "X$CRT_DIR" = "X" && CRT_DIR=/usr/lib | |
7254 | ||
7255 | else | |
7256 | ||
7257 | ## Some platforms don't use any of these files, so it is not | |
7258 | ## appropriate to put this test outside the if block. | |
7259 | test -e $CRT_DIR/crtn.o || test -e $CRT_DIR/crt0.o || \ | |
2018939f | 7260 | as_fn_error $? "crt*.o not found in specified location." "$LINENO" 5 |
067d23c9 KY |
7261 | |
7262 | fi | |
7263 | ||
7264 | ||
7265 | ||
7266 | LIB_MATH=-lm | |
7267 | LIB_STANDARD= | |
7268 | START_FILES= | |
7269 | ||
7270 | case $opsys in | |
7271 | cygwin ) | |
7272 | LIB_MATH= | |
7273 | START_FILES='pre-crt0.o' | |
7274 | ;; | |
7275 | darwin ) | |
7276 | ## Adding -lm confuses the dynamic linker, so omit it. | |
7277 | LIB_MATH= | |
7278 | START_FILES='pre-crt0.o' | |
7279 | ;; | |
7280 | freebsd ) | |
7281 | LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o' | |
7282 | START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o' | |
7283 | ;; | |
7284 | gnu-linux | gnu-kfreebsd ) | |
7285 | LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o' | |
7286 | START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o' | |
7287 | ;; | |
7288 | hpux10-20 | hpux11 ) | |
7289 | LIB_STANDARD=-lc | |
7290 | START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o' | |
7291 | ;; | |
7292 | netbsd | openbsd ) | |
7293 | if test -f $CRT_DIR/crti.o; then | |
7294 | LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o' | |
7295 | START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o' | |
7296 | else | |
7297 | LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o' | |
7298 | START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o' | |
7299 | fi | |
7300 | ;; | |
7301 | esac | |
7302 | ||
7303 | ||
7304 | ||
7305 | ||
7306 | ||
7307 | ||
7308 | ||
7309 | if test "${with_sound}" != "no"; then | |
7310 | # Sound support for GNU/Linux and the free BSDs. | |
7311 | for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h | |
7312 | do : | |
7313 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
7314 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
2018939f | 7315 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
067d23c9 KY |
7316 | cat >>confdefs.h <<_ACEOF |
7317 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
7318 | _ACEOF | |
7319 | have_sound_header=yes | |
7320 | fi | |
7321 | ||
7322 | done | |
7323 | ||
7324 | # Emulation library used on NetBSD. | |
7325 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5 | |
7326 | $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; } | |
d6974efa | 7327 | if ${ac_cv_lib_ossaudio__oss_ioctl+:} false; then : |
067d23c9 KY |
7328 | $as_echo_n "(cached) " >&6 |
7329 | else | |
7330 | ac_check_lib_save_LIBS=$LIBS | |
7331 | LIBS="-lossaudio $LIBS" | |
7332 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7333 | /* end confdefs.h. */ | |
7334 | ||
7335 | /* Override any GCC internal prototype to avoid an error. | |
7336 | Use char because int might match the return type of a GCC | |
7337 | builtin and then its argument prototype would still apply. */ | |
7338 | #ifdef __cplusplus | |
7339 | extern "C" | |
7340 | #endif | |
7341 | char _oss_ioctl (); | |
7342 | int | |
7343 | main () | |
7344 | { | |
7345 | return _oss_ioctl (); | |
7346 | ; | |
7347 | return 0; | |
7348 | } | |
7349 | _ACEOF | |
7350 | if ac_fn_c_try_link "$LINENO"; then : | |
7351 | ac_cv_lib_ossaudio__oss_ioctl=yes | |
7352 | else | |
7353 | ac_cv_lib_ossaudio__oss_ioctl=no | |
7354 | fi | |
7355 | rm -f core conftest.err conftest.$ac_objext \ | |
7356 | conftest$ac_exeext conftest.$ac_ext | |
7357 | LIBS=$ac_check_lib_save_LIBS | |
7358 | fi | |
7359 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5 | |
7360 | $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; } | |
d6974efa | 7361 | if test "x$ac_cv_lib_ossaudio__oss_ioctl" = xyes; then : |
067d23c9 KY |
7362 | LIBSOUND=-lossaudio |
7363 | else | |
7364 | LIBSOUND= | |
7365 | fi | |
7366 | ||
7367 | ||
7368 | ||
7369 | ALSA_REQUIRED=1.0.0 | |
7370 | ALSA_MODULES="alsa >= $ALSA_REQUIRED" | |
7371 | ||
7372 | succeeded=no | |
7373 | ||
7374 | # Extract the first word of "pkg-config", so it can be a program name with args. | |
7375 | set dummy pkg-config; ac_word=$2 | |
7376 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
7377 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 7378 | if ${ac_cv_path_PKG_CONFIG+:} false; then : |
067d23c9 KY |
7379 | $as_echo_n "(cached) " >&6 |
7380 | else | |
7381 | case $PKG_CONFIG in | |
7382 | [\\/]* | ?:[\\/]*) | |
7383 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. | |
7384 | ;; | |
7385 | *) | |
7386 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
7387 | for as_dir in $PATH | |
7388 | do | |
7389 | IFS=$as_save_IFS | |
7390 | test -z "$as_dir" && as_dir=. | |
7391 | for ac_exec_ext in '' $ac_executable_extensions; do | |
7392 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
7393 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" | |
7394 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
7395 | break 2 | |
7396 | fi | |
7397 | done | |
7398 | done | |
7399 | IFS=$as_save_IFS | |
7400 | ||
7401 | test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no" | |
7402 | ;; | |
7403 | esac | |
7404 | fi | |
7405 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG | |
7406 | if test -n "$PKG_CONFIG"; then | |
7407 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 | |
7408 | $as_echo "$PKG_CONFIG" >&6; } | |
7409 | else | |
7410 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
7411 | $as_echo "no" >&6; } | |
7412 | fi | |
7413 | ||
7414 | ||
7415 | ||
7416 | if test "$PKG_CONFIG" = "no" ; then | |
7417 | HAVE_ALSA=no | |
7418 | else | |
7419 | PKG_CONFIG_MIN_VERSION=0.9.0 | |
7420 | if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then | |
7421 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5 | |
7422 | $as_echo_n "checking for $ALSA_MODULES... " >&6; } | |
7423 | ||
7424 | if $PKG_CONFIG --exists "$ALSA_MODULES" 2>&5; then | |
7425 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
7426 | $as_echo "yes" >&6; } | |
7427 | succeeded=yes | |
7428 | ||
7429 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking ALSA_CFLAGS" >&5 | |
7430 | $as_echo_n "checking ALSA_CFLAGS... " >&6; } | |
7431 | ALSA_CFLAGS=`$PKG_CONFIG --cflags "$ALSA_MODULES"|sed -e 's,///*,/,g'` | |
7432 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ALSA_CFLAGS" >&5 | |
7433 | $as_echo "$ALSA_CFLAGS" >&6; } | |
7434 | ||
7435 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking ALSA_LIBS" >&5 | |
7436 | $as_echo_n "checking ALSA_LIBS... " >&6; } | |
7437 | ALSA_LIBS=`$PKG_CONFIG --libs "$ALSA_MODULES"|sed -e 's,///*,/,g'` | |
7438 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ALSA_LIBS" >&5 | |
7439 | $as_echo "$ALSA_LIBS" >&6; } | |
7440 | else | |
7441 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
7442 | $as_echo "no" >&6; } | |
7443 | ALSA_CFLAGS="" | |
7444 | ALSA_LIBS="" | |
7445 | ## If we have a custom action on failure, don't print errors, but | |
7446 | ## do set a variable so people can do so. | |
7447 | ALSA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$ALSA_MODULES"` | |
7448 | ||
7449 | fi | |
7450 | ||
7451 | ||
7452 | ||
7453 | else | |
7454 | echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer." | |
7455 | echo "*** See http://www.freedesktop.org/software/pkgconfig" | |
7456 | fi | |
7457 | fi | |
7458 | ||
7459 | if test $succeeded = yes; then | |
7460 | HAVE_ALSA=yes | |
7461 | else | |
7462 | HAVE_ALSA=no | |
7463 | fi | |
7464 | ||
7465 | if test $HAVE_ALSA = yes; then | |
7466 | SAVE_CFLAGS="$CFLAGS" | |
7467 | SAVE_LDFLAGS="$LDFLAGS" | |
7468 | CFLAGS="$ALSA_CFLAGS $CFLAGS" | |
7469 | LDFLAGS="$ALSA_LIBS $LDFLAGS" | |
7470 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7471 | /* end confdefs.h. */ | |
7472 | #include <asoundlib.h> | |
7473 | int | |
7474 | main () | |
7475 | { | |
7476 | snd_lib_error_set_handler (0); | |
7477 | ; | |
7478 | return 0; | |
7479 | } | |
7480 | _ACEOF | |
7481 | if ac_fn_c_try_compile "$LINENO"; then : | |
7482 | emacs_alsa_normal=yes | |
7483 | else | |
7484 | emacs_alsa_normal=no | |
7485 | fi | |
7486 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7487 | if test "$emacs_alsa_normal" != yes; then | |
7488 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7489 | /* end confdefs.h. */ | |
7490 | #include <alsa/asoundlib.h> | |
7491 | int | |
7492 | main () | |
7493 | { | |
7494 | snd_lib_error_set_handler (0); | |
7495 | ; | |
7496 | return 0; | |
7497 | } | |
7498 | _ACEOF | |
7499 | if ac_fn_c_try_compile "$LINENO"; then : | |
7500 | emacs_alsa_subdir=yes | |
7501 | else | |
7502 | emacs_alsa_subdir=no | |
7503 | fi | |
7504 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7505 | if test "$emacs_alsa_subdir" != yes; then | |
2018939f | 7506 | as_fn_error $? "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5 |
067d23c9 KY |
7507 | fi |
7508 | ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE" | |
7509 | fi | |
7510 | ||
7511 | CFLAGS="$SAVE_CFLAGS" | |
7512 | LDFLAGS="$SAVE_LDFLAGS" | |
7513 | LIBSOUND="$LIBSOUND $ALSA_LIBS" | |
7514 | CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS" | |
7515 | ||
7516 | $as_echo "#define HAVE_ALSA 1" >>confdefs.h | |
7517 | ||
7518 | fi | |
7519 | ||
7520 | if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then | |
7521 | case "$opsys" in | |
7522 | gnu-linux|freebsd|netbsd) | |
7523 | ||
7524 | $as_echo "#define HAVE_SOUND 1" >>confdefs.h | |
7525 | ||
7526 | ;; | |
7527 | esac | |
7528 | fi | |
7529 | ||
7530 | ||
7531 | fi | |
7532 | ||
7533 | for ac_header in sys/select.h sys/time.h unistd.h utime.h \ | |
7534 | linux/version.h sys/systeminfo.h limits.h \ | |
7535 | stdio_ext.h fcntl.h coff.h pty.h sys/mman.h \ | |
7536 | sys/vlimit.h sys/resource.h locale.h sys/_mbstate_t.h \ | |
7537 | sys/utsname.h pwd.h utmp.h dirent.h util.h | |
7538 | do : | |
7539 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
7540 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
2018939f | 7541 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
067d23c9 KY |
7542 | cat >>confdefs.h <<_ACEOF |
7543 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
7544 | _ACEOF | |
7545 | ||
7546 | fi | |
7547 | ||
7548 | done | |
7549 | ||
7550 | ||
7551 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5 | |
7552 | $as_echo_n "checking if personality LINUX32 can be set... " >&6; } | |
7553 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7554 | /* end confdefs.h. */ | |
7555 | #include <sys/personality.h> | |
7556 | int | |
7557 | main () | |
7558 | { | |
7559 | personality (PER_LINUX32) | |
7560 | ; | |
7561 | return 0; | |
7562 | } | |
7563 | _ACEOF | |
7564 | if ac_fn_c_try_compile "$LINENO"; then : | |
7565 | emacs_cv_personality_linux32=yes | |
7566 | else | |
7567 | emacs_cv_personality_linux32=no | |
7568 | fi | |
7569 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7570 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5 | |
7571 | $as_echo "$emacs_cv_personality_linux32" >&6; } | |
7572 | ||
7573 | if test $emacs_cv_personality_linux32 = yes; then | |
7574 | ||
7575 | $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h | |
7576 | ||
7577 | fi | |
7578 | ||
7579 | for ac_header in term.h | |
7580 | do : | |
7581 | ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h" | |
d6974efa | 7582 | if test "x$ac_cv_header_term_h" = xyes; then : |
067d23c9 KY |
7583 | cat >>confdefs.h <<_ACEOF |
7584 | #define HAVE_TERM_H 1 | |
7585 | _ACEOF | |
7586 | ||
7587 | fi | |
7588 | ||
7589 | done | |
7590 | ||
7591 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 | |
7592 | $as_echo_n "checking for ANSI C header files... " >&6; } | |
d6974efa | 7593 | if ${ac_cv_header_stdc+:} false; then : |
067d23c9 KY |
7594 | $as_echo_n "(cached) " >&6 |
7595 | else | |
7596 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7597 | /* end confdefs.h. */ | |
7598 | #include <stdlib.h> | |
7599 | #include <stdarg.h> | |
7600 | #include <string.h> | |
7601 | #include <float.h> | |
7602 | ||
7603 | int | |
7604 | main () | |
7605 | { | |
7606 | ||
7607 | ; | |
7608 | return 0; | |
7609 | } | |
7610 | _ACEOF | |
7611 | if ac_fn_c_try_compile "$LINENO"; then : | |
7612 | ac_cv_header_stdc=yes | |
7613 | else | |
7614 | ac_cv_header_stdc=no | |
7615 | fi | |
7616 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7617 | ||
7618 | if test $ac_cv_header_stdc = yes; then | |
7619 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
7620 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7621 | /* end confdefs.h. */ | |
7622 | #include <string.h> | |
7623 | ||
7624 | _ACEOF | |
7625 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
7626 | $EGREP "memchr" >/dev/null 2>&1; then : | |
7627 | ||
7628 | else | |
7629 | ac_cv_header_stdc=no | |
7630 | fi | |
7631 | rm -f conftest* | |
7632 | ||
7633 | fi | |
7634 | ||
7635 | if test $ac_cv_header_stdc = yes; then | |
7636 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. | |
7637 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7638 | /* end confdefs.h. */ | |
7639 | #include <stdlib.h> | |
7640 | ||
7641 | _ACEOF | |
7642 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
7643 | $EGREP "free" >/dev/null 2>&1; then : | |
7644 | ||
7645 | else | |
7646 | ac_cv_header_stdc=no | |
7647 | fi | |
7648 | rm -f conftest* | |
7649 | ||
7650 | fi | |
7651 | ||
7652 | if test $ac_cv_header_stdc = yes; then | |
7653 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. | |
7654 | if test "$cross_compiling" = yes; then : | |
7655 | : | |
7656 | else | |
7657 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7658 | /* end confdefs.h. */ | |
7659 | #include <ctype.h> | |
7660 | #include <stdlib.h> | |
7661 | #if ((' ' & 0x0FF) == 0x020) | |
7662 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') | |
7663 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
7664 | #else | |
7665 | # define ISLOWER(c) \ | |
7666 | (('a' <= (c) && (c) <= 'i') \ | |
7667 | || ('j' <= (c) && (c) <= 'r') \ | |
7668 | || ('s' <= (c) && (c) <= 'z')) | |
7669 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) | |
7670 | #endif | |
7671 | ||
7672 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) | |
7673 | int | |
7674 | main () | |
7675 | { | |
7676 | int i; | |
7677 | for (i = 0; i < 256; i++) | |
7678 | if (XOR (islower (i), ISLOWER (i)) | |
7679 | || toupper (i) != TOUPPER (i)) | |
7680 | return 2; | |
7681 | return 0; | |
7682 | } | |
7683 | _ACEOF | |
7684 | if ac_fn_c_try_run "$LINENO"; then : | |
7685 | ||
7686 | else | |
7687 | ac_cv_header_stdc=no | |
7688 | fi | |
7689 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
7690 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
7691 | fi | |
7692 | ||
7693 | fi | |
7694 | fi | |
7695 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 | |
7696 | $as_echo "$ac_cv_header_stdc" >&6; } | |
7697 | if test $ac_cv_header_stdc = yes; then | |
7698 | ||
7699 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h | |
7700 | ||
7701 | fi | |
7702 | ||
7703 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 | |
7704 | $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } | |
d6974efa | 7705 | if ${ac_cv_header_time+:} false; then : |
067d23c9 KY |
7706 | $as_echo_n "(cached) " >&6 |
7707 | else | |
7708 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7709 | /* end confdefs.h. */ | |
7710 | #include <sys/types.h> | |
7711 | #include <sys/time.h> | |
7712 | #include <time.h> | |
7713 | ||
7714 | int | |
7715 | main () | |
7716 | { | |
7717 | if ((struct tm *) 0) | |
7718 | return 0; | |
7719 | ; | |
7720 | return 0; | |
7721 | } | |
7722 | _ACEOF | |
7723 | if ac_fn_c_try_compile "$LINENO"; then : | |
7724 | ac_cv_header_time=yes | |
7725 | else | |
7726 | ac_cv_header_time=no | |
7727 | fi | |
7728 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7729 | fi | |
7730 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 | |
7731 | $as_echo "$ac_cv_header_time" >&6; } | |
7732 | if test $ac_cv_header_time = yes; then | |
7733 | ||
7734 | $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h | |
7735 | ||
7736 | fi | |
7737 | ||
7738 | ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "$ac_includes_default" | |
d6974efa | 7739 | if test "x$ac_cv_have_decl_sys_siglist" = xyes; then : |
067d23c9 KY |
7740 | ac_have_decl=1 |
7741 | else | |
7742 | ac_have_decl=0 | |
7743 | fi | |
7744 | ||
7745 | cat >>confdefs.h <<_ACEOF | |
7746 | #define HAVE_DECL_SYS_SIGLIST $ac_have_decl | |
7747 | _ACEOF | |
7748 | ||
7749 | if test $ac_cv_have_decl_sys_siglist != yes; then | |
7750 | # For Tru64, at least: | |
7751 | ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "$ac_includes_default" | |
d6974efa | 7752 | if test "x$ac_cv_have_decl___sys_siglist" = xyes; then : |
067d23c9 KY |
7753 | ac_have_decl=1 |
7754 | else | |
7755 | ac_have_decl=0 | |
7756 | fi | |
7757 | ||
7758 | cat >>confdefs.h <<_ACEOF | |
7759 | #define HAVE_DECL___SYS_SIGLIST $ac_have_decl | |
7760 | _ACEOF | |
7761 | ||
7762 | if test $ac_cv_have_decl___sys_siglist = yes; then | |
7763 | ||
7764 | $as_echo "#define sys_siglist __sys_siglist" >>confdefs.h | |
7765 | ||
7766 | fi | |
7767 | fi | |
7768 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5 | |
7769 | $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; } | |
d6974efa | 7770 | if ${ac_cv_header_sys_wait_h+:} false; then : |
067d23c9 KY |
7771 | $as_echo_n "(cached) " >&6 |
7772 | else | |
7773 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7774 | /* end confdefs.h. */ | |
7775 | #include <sys/types.h> | |
7776 | #include <sys/wait.h> | |
7777 | #ifndef WEXITSTATUS | |
7778 | # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8) | |
7779 | #endif | |
7780 | #ifndef WIFEXITED | |
7781 | # define WIFEXITED(stat_val) (((stat_val) & 255) == 0) | |
7782 | #endif | |
7783 | ||
7784 | int | |
7785 | main () | |
7786 | { | |
7787 | int s; | |
7788 | wait (&s); | |
7789 | s = WIFEXITED (s) ? WEXITSTATUS (s) : 1; | |
7790 | ; | |
7791 | return 0; | |
7792 | } | |
7793 | _ACEOF | |
7794 | if ac_fn_c_try_compile "$LINENO"; then : | |
7795 | ac_cv_header_sys_wait_h=yes | |
7796 | else | |
7797 | ac_cv_header_sys_wait_h=no | |
7798 | fi | |
7799 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7800 | fi | |
7801 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5 | |
7802 | $as_echo "$ac_cv_header_sys_wait_h" >&6; } | |
7803 | if test $ac_cv_header_sys_wait_h = yes; then | |
7804 | ||
7805 | $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h | |
7806 | ||
7807 | fi | |
7808 | ||
7809 | ||
7810 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5 | |
7811 | $as_echo_n "checking for struct utimbuf... " >&6; } | |
d6974efa | 7812 | if ${emacs_cv_struct_utimbuf+:} false; then : |
067d23c9 KY |
7813 | $as_echo_n "(cached) " >&6 |
7814 | else | |
7815 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7816 | /* end confdefs.h. */ | |
7817 | #ifdef TIME_WITH_SYS_TIME | |
7818 | #include <sys/time.h> | |
7819 | #include <time.h> | |
7820 | #else | |
7821 | #ifdef HAVE_SYS_TIME_H | |
7822 | #include <sys/time.h> | |
7823 | #else | |
7824 | #include <time.h> | |
7825 | #endif | |
7826 | #endif | |
7827 | #ifdef HAVE_UTIME_H | |
7828 | #include <utime.h> | |
7829 | #endif | |
7830 | int | |
7831 | main () | |
7832 | { | |
7833 | static struct utimbuf x; x.actime = x.modtime; | |
7834 | ; | |
7835 | return 0; | |
7836 | } | |
7837 | _ACEOF | |
7838 | if ac_fn_c_try_compile "$LINENO"; then : | |
7839 | emacs_cv_struct_utimbuf=yes | |
7840 | else | |
7841 | emacs_cv_struct_utimbuf=no | |
7842 | fi | |
7843 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7844 | fi | |
7845 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_utimbuf" >&5 | |
7846 | $as_echo "$emacs_cv_struct_utimbuf" >&6; } | |
7847 | if test $emacs_cv_struct_utimbuf = yes; then | |
7848 | ||
7849 | $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h | |
7850 | ||
7851 | fi | |
7852 | ||
7853 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5 | |
7854 | $as_echo_n "checking return type of signal handlers... " >&6; } | |
d6974efa | 7855 | if ${ac_cv_type_signal+:} false; then : |
067d23c9 KY |
7856 | $as_echo_n "(cached) " >&6 |
7857 | else | |
7858 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7859 | /* end confdefs.h. */ | |
7860 | #include <sys/types.h> | |
7861 | #include <signal.h> | |
7862 | ||
7863 | int | |
7864 | main () | |
7865 | { | |
7866 | return *(signal (0, 0)) (0) == 1; | |
7867 | ; | |
7868 | return 0; | |
7869 | } | |
7870 | _ACEOF | |
7871 | if ac_fn_c_try_compile "$LINENO"; then : | |
7872 | ac_cv_type_signal=int | |
7873 | else | |
7874 | ac_cv_type_signal=void | |
7875 | fi | |
7876 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7877 | fi | |
7878 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5 | |
7879 | $as_echo "$ac_cv_type_signal" >&6; } | |
7880 | ||
7881 | cat >>confdefs.h <<_ACEOF | |
7882 | #define RETSIGTYPE $ac_cv_type_signal | |
7883 | _ACEOF | |
7884 | ||
7885 | ||
7886 | ||
7887 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t" >&5 | |
7888 | $as_echo_n "checking for speed_t... " >&6; } | |
d6974efa | 7889 | if ${emacs_cv_speed_t+:} false; then : |
067d23c9 KY |
7890 | $as_echo_n "(cached) " >&6 |
7891 | else | |
7892 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7893 | /* end confdefs.h. */ | |
7894 | #include <termios.h> | |
7895 | int | |
7896 | main () | |
7897 | { | |
7898 | speed_t x = 1; | |
7899 | ; | |
7900 | return 0; | |
7901 | } | |
7902 | _ACEOF | |
7903 | if ac_fn_c_try_compile "$LINENO"; then : | |
7904 | emacs_cv_speed_t=yes | |
7905 | else | |
7906 | emacs_cv_speed_t=no | |
7907 | fi | |
7908 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7909 | fi | |
7910 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_speed_t" >&5 | |
7911 | $as_echo "$emacs_cv_speed_t" >&6; } | |
7912 | if test $emacs_cv_speed_t = yes; then | |
7913 | ||
7914 | $as_echo "#define HAVE_SPEED_T 1" >>confdefs.h | |
7915 | ||
7916 | fi | |
7917 | ||
7918 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5 | |
7919 | $as_echo_n "checking for struct timeval... " >&6; } | |
d6974efa | 7920 | if ${emacs_cv_struct_timeval+:} false; then : |
067d23c9 KY |
7921 | $as_echo_n "(cached) " >&6 |
7922 | else | |
7923 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7924 | /* end confdefs.h. */ | |
7925 | #ifdef TIME_WITH_SYS_TIME | |
7926 | #include <sys/time.h> | |
7927 | #include <time.h> | |
7928 | #else | |
7929 | #ifdef HAVE_SYS_TIME_H | |
7930 | #include <sys/time.h> | |
7931 | #else | |
7932 | #include <time.h> | |
7933 | #endif | |
7934 | #endif | |
7935 | int | |
7936 | main () | |
7937 | { | |
7938 | static struct timeval x; x.tv_sec = x.tv_usec; | |
7939 | ; | |
7940 | return 0; | |
7941 | } | |
7942 | _ACEOF | |
7943 | if ac_fn_c_try_compile "$LINENO"; then : | |
7944 | emacs_cv_struct_timeval=yes | |
7945 | else | |
7946 | emacs_cv_struct_timeval=no | |
7947 | fi | |
7948 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7949 | fi | |
7950 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_timeval" >&5 | |
7951 | $as_echo "$emacs_cv_struct_timeval" >&6; } | |
7952 | HAVE_TIMEVAL=$emacs_cv_struct_timeval | |
7953 | if test $emacs_cv_struct_timeval = yes; then | |
7954 | ||
7955 | $as_echo "#define HAVE_TIMEVAL 1" >>confdefs.h | |
7956 | ||
7957 | fi | |
7958 | ||
7959 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct exception" >&5 | |
7960 | $as_echo_n "checking for struct exception... " >&6; } | |
d6974efa | 7961 | if ${emacs_cv_struct_exception+:} false; then : |
067d23c9 KY |
7962 | $as_echo_n "(cached) " >&6 |
7963 | else | |
7964 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7965 | /* end confdefs.h. */ | |
7966 | #include <math.h> | |
7967 | int | |
7968 | main () | |
7969 | { | |
7970 | static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1; | |
7971 | ; | |
7972 | return 0; | |
7973 | } | |
7974 | _ACEOF | |
7975 | if ac_fn_c_try_compile "$LINENO"; then : | |
7976 | emacs_cv_struct_exception=yes | |
7977 | else | |
7978 | emacs_cv_struct_exception=no | |
7979 | fi | |
7980 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7981 | fi | |
7982 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_exception" >&5 | |
7983 | $as_echo "$emacs_cv_struct_exception" >&6; } | |
7984 | HAVE_EXCEPTION=$emacs_cv_struct_exception | |
7985 | if test $emacs_cv_struct_exception != yes; then | |
7986 | ||
7987 | $as_echo "#define NO_MATHERR 1" >>confdefs.h | |
7988 | ||
7989 | fi | |
7990 | ||
7991 | for ac_header in sys/socket.h | |
7992 | do : | |
7993 | ac_fn_c_check_header_mongrel "$LINENO" "sys/socket.h" "ac_cv_header_sys_socket_h" "$ac_includes_default" | |
d6974efa | 7994 | if test "x$ac_cv_header_sys_socket_h" = xyes; then : |
067d23c9 KY |
7995 | cat >>confdefs.h <<_ACEOF |
7996 | #define HAVE_SYS_SOCKET_H 1 | |
7997 | _ACEOF | |
7998 | ||
7999 | fi | |
8000 | ||
8001 | done | |
8002 | ||
8003 | for ac_header in net/if.h | |
8004 | do : | |
8005 | ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default | |
8006 | #if HAVE_SYS_SOCKET_H | |
8007 | #include <sys/socket.h> | |
8008 | #endif | |
8009 | " | |
d6974efa | 8010 | if test "x$ac_cv_header_net_if_h" = xyes; then : |
067d23c9 KY |
8011 | cat >>confdefs.h <<_ACEOF |
8012 | #define HAVE_NET_IF_H 1 | |
8013 | _ACEOF | |
8014 | ||
8015 | fi | |
8016 | ||
8017 | done | |
8018 | ||
8019 | ||
8020 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 | |
8021 | $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } | |
d6974efa | 8022 | if ${ac_cv_struct_tm+:} false; then : |
067d23c9 KY |
8023 | $as_echo_n "(cached) " >&6 |
8024 | else | |
8025 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8026 | /* end confdefs.h. */ | |
8027 | #include <sys/types.h> | |
8028 | #include <time.h> | |
8029 | ||
8030 | int | |
8031 | main () | |
8032 | { | |
8033 | struct tm tm; | |
8034 | int *p = &tm.tm_sec; | |
8035 | return !p; | |
8036 | ; | |
8037 | return 0; | |
8038 | } | |
8039 | _ACEOF | |
8040 | if ac_fn_c_try_compile "$LINENO"; then : | |
8041 | ac_cv_struct_tm=time.h | |
8042 | else | |
8043 | ac_cv_struct_tm=sys/time.h | |
8044 | fi | |
8045 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
8046 | fi | |
8047 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 | |
8048 | $as_echo "$ac_cv_struct_tm" >&6; } | |
8049 | if test $ac_cv_struct_tm = sys/time.h; then | |
8050 | ||
8051 | $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h | |
8052 | ||
8053 | fi | |
8054 | ||
8055 | ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h> | |
8056 | #include <$ac_cv_struct_tm> | |
8057 | ||
8058 | " | |
d6974efa | 8059 | if test "x$ac_cv_member_struct_tm_tm_zone" = xyes; then : |
067d23c9 KY |
8060 | |
8061 | cat >>confdefs.h <<_ACEOF | |
8062 | #define HAVE_STRUCT_TM_TM_ZONE 1 | |
8063 | _ACEOF | |
8064 | ||
8065 | ||
8066 | fi | |
8067 | ||
8068 | if test "$ac_cv_member_struct_tm_tm_zone" = yes; then | |
8069 | ||
8070 | $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h | |
8071 | ||
8072 | else | |
8073 | ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h> | |
8074 | " | |
d6974efa | 8075 | if test "x$ac_cv_have_decl_tzname" = xyes; then : |
067d23c9 KY |
8076 | ac_have_decl=1 |
8077 | else | |
8078 | ac_have_decl=0 | |
8079 | fi | |
8080 | ||
8081 | cat >>confdefs.h <<_ACEOF | |
8082 | #define HAVE_DECL_TZNAME $ac_have_decl | |
8083 | _ACEOF | |
8084 | ||
8085 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5 | |
8086 | $as_echo_n "checking for tzname... " >&6; } | |
d6974efa | 8087 | if ${ac_cv_var_tzname+:} false; then : |
067d23c9 KY |
8088 | $as_echo_n "(cached) " >&6 |
8089 | else | |
8090 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8091 | /* end confdefs.h. */ | |
8092 | #include <time.h> | |
8093 | #if !HAVE_DECL_TZNAME | |
8094 | extern char *tzname[]; | |
8095 | #endif | |
8096 | ||
8097 | int | |
8098 | main () | |
8099 | { | |
8100 | return tzname[0][0]; | |
8101 | ; | |
8102 | return 0; | |
8103 | } | |
8104 | _ACEOF | |
8105 | if ac_fn_c_try_link "$LINENO"; then : | |
8106 | ac_cv_var_tzname=yes | |
8107 | else | |
8108 | ac_cv_var_tzname=no | |
8109 | fi | |
8110 | rm -f core conftest.err conftest.$ac_objext \ | |
8111 | conftest$ac_exeext conftest.$ac_ext | |
8112 | fi | |
8113 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5 | |
8114 | $as_echo "$ac_cv_var_tzname" >&6; } | |
8115 | if test $ac_cv_var_tzname = yes; then | |
8116 | ||
8117 | $as_echo "#define HAVE_TZNAME 1" >>confdefs.h | |
8118 | ||
8119 | fi | |
8120 | fi | |
8121 | ||
8122 | ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h> | |
8123 | " | |
d6974efa | 8124 | if test "x$ac_cv_member_struct_tm_tm_gmtoff" = xyes; then : |
067d23c9 KY |
8125 | |
8126 | $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h | |
8127 | ||
8128 | fi | |
8129 | ||
8130 | ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default | |
8131 | #if HAVE_SYS_SOCKET_H | |
8132 | #include <sys/socket.h> | |
8133 | #endif | |
8134 | #if HAVE_NET_IF_H | |
8135 | #include <net/if.h> | |
8136 | #endif | |
8137 | " | |
d6974efa | 8138 | if test "x$ac_cv_member_struct_ifreq_ifr_flags" = xyes; then : |
067d23c9 KY |
8139 | |
8140 | cat >>confdefs.h <<_ACEOF | |
8141 | #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1 | |
8142 | _ACEOF | |
8143 | ||
8144 | ||
8145 | fi | |
8146 | ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default | |
8147 | #if HAVE_SYS_SOCKET_H | |
8148 | #include <sys/socket.h> | |
8149 | #endif | |
8150 | #if HAVE_NET_IF_H | |
8151 | #include <net/if.h> | |
8152 | #endif | |
8153 | " | |
d6974efa | 8154 | if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = xyes; then : |
067d23c9 KY |
8155 | |
8156 | cat >>confdefs.h <<_ACEOF | |
8157 | #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1 | |
8158 | _ACEOF | |
8159 | ||
8160 | ||
8161 | fi | |
8162 | ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default | |
8163 | #if HAVE_SYS_SOCKET_H | |
8164 | #include <sys/socket.h> | |
8165 | #endif | |
8166 | #if HAVE_NET_IF_H | |
8167 | #include <net/if.h> | |
8168 | #endif | |
8169 | " | |
d6974efa | 8170 | if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = xyes; then : |
067d23c9 KY |
8171 | |
8172 | cat >>confdefs.h <<_ACEOF | |
8173 | #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1 | |
8174 | _ACEOF | |
8175 | ||
8176 | ||
8177 | fi | |
8178 | ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default | |
8179 | #if HAVE_SYS_SOCKET_H | |
8180 | #include <sys/socket.h> | |
8181 | #endif | |
8182 | #if HAVE_NET_IF_H | |
8183 | #include <net/if.h> | |
8184 | #endif | |
8185 | " | |
d6974efa | 8186 | if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = xyes; then : |
067d23c9 KY |
8187 | |
8188 | cat >>confdefs.h <<_ACEOF | |
8189 | #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1 | |
8190 | _ACEOF | |
8191 | ||
8192 | ||
8193 | fi | |
8194 | ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default | |
8195 | #if HAVE_SYS_SOCKET_H | |
8196 | #include <sys/socket.h> | |
8197 | #endif | |
8198 | #if HAVE_NET_IF_H | |
8199 | #include <net/if.h> | |
8200 | #endif | |
8201 | " | |
d6974efa | 8202 | if test "x$ac_cv_member_struct_ifreq_ifr_addr" = xyes; then : |
067d23c9 KY |
8203 | |
8204 | cat >>confdefs.h <<_ACEOF | |
8205 | #define HAVE_STRUCT_IFREQ_IFR_ADDR 1 | |
8206 | _ACEOF | |
8207 | ||
8208 | ||
8209 | fi | |
8210 | ||
8211 | ||
8212 | ||
8213 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for function prototypes" >&5 | |
8214 | $as_echo_n "checking for function prototypes... " >&6; } | |
8215 | if test "$ac_cv_prog_cc_c89" != no; then | |
8216 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
8217 | $as_echo "yes" >&6; } | |
8218 | ||
8219 | $as_echo "#define PROTOTYPES 1" >>confdefs.h | |
8220 | ||
8221 | ||
8222 | $as_echo "#define __PROTOTYPES 1" >>confdefs.h | |
8223 | ||
8224 | else | |
8225 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
8226 | $as_echo "no" >&6; } | |
8227 | fi | |
8228 | ||
8229 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5 | |
8230 | $as_echo_n "checking for working volatile... " >&6; } | |
d6974efa | 8231 | if ${ac_cv_c_volatile+:} false; then : |
067d23c9 KY |
8232 | $as_echo_n "(cached) " >&6 |
8233 | else | |
8234 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8235 | /* end confdefs.h. */ | |
8236 | ||
8237 | int | |
8238 | main () | |
8239 | { | |
8240 | ||
8241 | volatile int x; | |
8242 | int * volatile y = (int *) 0; | |
8243 | return !x && !y; | |
8244 | ; | |
8245 | return 0; | |
8246 | } | |
8247 | _ACEOF | |
8248 | if ac_fn_c_try_compile "$LINENO"; then : | |
8249 | ac_cv_c_volatile=yes | |
8250 | else | |
8251 | ac_cv_c_volatile=no | |
8252 | fi | |
8253 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
8254 | fi | |
8255 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5 | |
8256 | $as_echo "$ac_cv_c_volatile" >&6; } | |
8257 | if test $ac_cv_c_volatile = no; then | |
8258 | ||
8259 | $as_echo "#define volatile /**/" >>confdefs.h | |
8260 | ||
8261 | fi | |
8262 | ||
8263 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 | |
8264 | $as_echo_n "checking for an ANSI C-conforming const... " >&6; } | |
d6974efa | 8265 | if ${ac_cv_c_const+:} false; then : |
067d23c9 KY |
8266 | $as_echo_n "(cached) " >&6 |
8267 | else | |
8268 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8269 | /* end confdefs.h. */ | |
8270 | ||
8271 | int | |
8272 | main () | |
8273 | { | |
8274 | /* FIXME: Include the comments suggested by Paul. */ | |
8275 | #ifndef __cplusplus | |
8276 | /* Ultrix mips cc rejects this. */ | |
8277 | typedef int charset[2]; | |
8278 | const charset cs; | |
8279 | /* SunOS 4.1.1 cc rejects this. */ | |
8280 | char const *const *pcpcc; | |
8281 | char **ppc; | |
8282 | /* NEC SVR4.0.2 mips cc rejects this. */ | |
8283 | struct point {int x, y;}; | |
8284 | static struct point const zero = {0,0}; | |
8285 | /* AIX XL C 1.02.0.0 rejects this. | |
8286 | It does not let you subtract one const X* pointer from another in | |
8287 | an arm of an if-expression whose if-part is not a constant | |
8288 | expression */ | |
8289 | const char *g = "string"; | |
8290 | pcpcc = &g + (g ? g-g : 0); | |
8291 | /* HPUX 7.0 cc rejects these. */ | |
8292 | ++pcpcc; | |
8293 | ppc = (char**) pcpcc; | |
8294 | pcpcc = (char const *const *) ppc; | |
8295 | { /* SCO 3.2v4 cc rejects this. */ | |
8296 | char *t; | |
8297 | char const *s = 0 ? (char *) 0 : (char const *) 0; | |
8298 | ||
8299 | *t++ = 0; | |
8300 | if (s) return 0; | |
8301 | } | |
8302 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ | |
8303 | int x[] = {25, 17}; | |
8304 | const int *foo = &x[0]; | |
8305 | ++foo; | |
8306 | } | |
8307 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ | |
8308 | typedef const int *iptr; | |
8309 | iptr p = 0; | |
8310 | ++p; | |
8311 | } | |
8312 | { /* AIX XL C 1.02.0.0 rejects this saying | |
8313 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ | |
8314 | struct s { int j; const int *ap[3]; }; | |
8315 | struct s *b; b->j = 5; | |
8316 | } | |
8317 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ | |
8318 | const int foo = 10; | |
8319 | if (!foo) return 0; | |
8320 | } | |
8321 | return !cs[0] && !zero.x; | |
8322 | #endif | |
8323 | ||
8324 | ; | |
8325 | return 0; | |
8326 | } | |
8327 | _ACEOF | |
8328 | if ac_fn_c_try_compile "$LINENO"; then : | |
8329 | ac_cv_c_const=yes | |
8330 | else | |
8331 | ac_cv_c_const=no | |
8332 | fi | |
8333 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
8334 | fi | |
8335 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 | |
8336 | $as_echo "$ac_cv_c_const" >&6; } | |
8337 | if test $ac_cv_c_const = no; then | |
8338 | ||
8339 | $as_echo "#define const /**/" >>confdefs.h | |
8340 | ||
8341 | fi | |
8342 | ||
8343 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for void * support" >&5 | |
8344 | $as_echo_n "checking for void * support... " >&6; } | |
d6974efa | 8345 | if ${emacs_cv_void_star+:} false; then : |
067d23c9 KY |
8346 | $as_echo_n "(cached) " >&6 |
8347 | else | |
8348 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8349 | /* end confdefs.h. */ | |
8350 | ||
8351 | int | |
8352 | main () | |
8353 | { | |
8354 | void * foo; | |
8355 | ; | |
8356 | return 0; | |
8357 | } | |
8358 | _ACEOF | |
8359 | if ac_fn_c_try_compile "$LINENO"; then : | |
8360 | emacs_cv_void_star=yes | |
8361 | else | |
8362 | emacs_cv_void_star=no | |
8363 | fi | |
8364 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
8365 | fi | |
8366 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_void_star" >&5 | |
8367 | $as_echo "$emacs_cv_void_star" >&6; } | |
8368 | if test $emacs_cv_void_star = yes; then | |
8369 | $as_echo "#define POINTER_TYPE void" >>confdefs.h | |
8370 | ||
8371 | else | |
8372 | $as_echo "#define POINTER_TYPE char" >>confdefs.h | |
8373 | ||
8374 | fi | |
8375 | ||
8376 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 | |
8377 | $as_echo_n "checking whether byte ordering is bigendian... " >&6; } | |
d6974efa | 8378 | if ${ac_cv_c_bigendian+:} false; then : |
067d23c9 KY |
8379 | $as_echo_n "(cached) " >&6 |
8380 | else | |
8381 | ac_cv_c_bigendian=unknown | |
8382 | # See if we're dealing with a universal compiler. | |
8383 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8384 | /* end confdefs.h. */ | |
8385 | #ifndef __APPLE_CC__ | |
8386 | not a universal capable compiler | |
8387 | #endif | |
8388 | typedef int dummy; | |
8389 | ||
8390 | _ACEOF | |
8391 | if ac_fn_c_try_compile "$LINENO"; then : | |
8392 | ||
8393 | # Check for potential -arch flags. It is not universal unless | |
8394 | # there are at least two -arch flags with different values. | |
8395 | ac_arch= | |
8396 | ac_prev= | |
8397 | for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do | |
8398 | if test -n "$ac_prev"; then | |
8399 | case $ac_word in | |
8400 | i?86 | x86_64 | ppc | ppc64) | |
8401 | if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then | |
8402 | ac_arch=$ac_word | |
8403 | else | |
8404 | ac_cv_c_bigendian=universal | |
8405 | break | |
8406 | fi | |
8407 | ;; | |
8408 | esac | |
8409 | ac_prev= | |
8410 | elif test "x$ac_word" = "x-arch"; then | |
8411 | ac_prev=arch | |
8412 | fi | |
8413 | done | |
8414 | fi | |
8415 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
8416 | if test $ac_cv_c_bigendian = unknown; then | |
8417 | # See if sys/param.h defines the BYTE_ORDER macro. | |
8418 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8419 | /* end confdefs.h. */ | |
8420 | #include <sys/types.h> | |
8421 | #include <sys/param.h> | |
8422 | ||
8423 | int | |
8424 | main () | |
8425 | { | |
8426 | #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ | |
8427 | && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ | |
8428 | && LITTLE_ENDIAN) | |
8429 | bogus endian macros | |
8430 | #endif | |
8431 | ||
8432 | ; | |
8433 | return 0; | |
8434 | } | |
8435 | _ACEOF | |
8436 | if ac_fn_c_try_compile "$LINENO"; then : | |
8437 | # It does; now see whether it defined to BIG_ENDIAN or not. | |
8438 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8439 | /* end confdefs.h. */ | |
8440 | #include <sys/types.h> | |
8441 | #include <sys/param.h> | |
8442 | ||
8443 | int | |
8444 | main () | |
8445 | { | |
8446 | #if BYTE_ORDER != BIG_ENDIAN | |
8447 | not big endian | |
8448 | #endif | |
8449 | ||
8450 | ; | |
8451 | return 0; | |
8452 | } | |
8453 | _ACEOF | |
8454 | if ac_fn_c_try_compile "$LINENO"; then : | |
8455 | ac_cv_c_bigendian=yes | |
8456 | else | |
8457 | ac_cv_c_bigendian=no | |
8458 | fi | |
8459 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
8460 | fi | |
8461 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
8462 | fi | |
8463 | if test $ac_cv_c_bigendian = unknown; then | |
8464 | # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). | |
8465 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8466 | /* end confdefs.h. */ | |
8467 | #include <limits.h> | |
8468 | ||
8469 | int | |
8470 | main () | |
8471 | { | |
8472 | #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) | |
8473 | bogus endian macros | |
8474 | #endif | |
8475 | ||
8476 | ; | |
8477 | return 0; | |
8478 | } | |
8479 | _ACEOF | |
8480 | if ac_fn_c_try_compile "$LINENO"; then : | |
8481 | # It does; now see whether it defined to _BIG_ENDIAN or not. | |
8482 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8483 | /* end confdefs.h. */ | |
8484 | #include <limits.h> | |
8485 | ||
8486 | int | |
8487 | main () | |
8488 | { | |
8489 | #ifndef _BIG_ENDIAN | |
8490 | not big endian | |
8491 | #endif | |
8492 | ||
8493 | ; | |
8494 | return 0; | |
8495 | } | |
8496 | _ACEOF | |
8497 | if ac_fn_c_try_compile "$LINENO"; then : | |
8498 | ac_cv_c_bigendian=yes | |
8499 | else | |
8500 | ac_cv_c_bigendian=no | |
8501 | fi | |
8502 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
8503 | fi | |
8504 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
8505 | fi | |
8506 | if test $ac_cv_c_bigendian = unknown; then | |
8507 | # Compile a test program. | |
8508 | if test "$cross_compiling" = yes; then : | |
8509 | # Try to guess by grepping values from an object file. | |
8510 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8511 | /* end confdefs.h. */ | |
8512 | short int ascii_mm[] = | |
8513 | { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; | |
8514 | short int ascii_ii[] = | |
8515 | { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; | |
8516 | int use_ascii (int i) { | |
8517 | return ascii_mm[i] + ascii_ii[i]; | |
8518 | } | |
8519 | short int ebcdic_ii[] = | |
8520 | { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; | |
8521 | short int ebcdic_mm[] = | |
8522 | { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; | |
8523 | int use_ebcdic (int i) { | |
8524 | return ebcdic_mm[i] + ebcdic_ii[i]; | |
8525 | } | |
8526 | extern int foo; | |
8527 | ||
8528 | int | |
8529 | main () | |
8530 | { | |
8531 | return use_ascii (foo) == use_ebcdic (foo); | |
8532 | ; | |
8533 | return 0; | |
8534 | } | |
8535 | _ACEOF | |
8536 | if ac_fn_c_try_compile "$LINENO"; then : | |
8537 | if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then | |
8538 | ac_cv_c_bigendian=yes | |
8539 | fi | |
8540 | if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then | |
8541 | if test "$ac_cv_c_bigendian" = unknown; then | |
8542 | ac_cv_c_bigendian=no | |
8543 | else | |
8544 | # finding both strings is unlikely to happen, but who knows? | |
8545 | ac_cv_c_bigendian=unknown | |
8546 | fi | |
8547 | fi | |
8548 | fi | |
8549 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
8550 | else | |
8551 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8552 | /* end confdefs.h. */ | |
8553 | $ac_includes_default | |
8554 | int | |
8555 | main () | |
8556 | { | |
8557 | ||
8558 | /* Are we little or big endian? From Harbison&Steele. */ | |
8559 | union | |
8560 | { | |
8561 | long int l; | |
8562 | char c[sizeof (long int)]; | |
8563 | } u; | |
8564 | u.l = 1; | |
8565 | return u.c[sizeof (long int) - 1] == 1; | |
8566 | ||
8567 | ; | |
8568 | return 0; | |
8569 | } | |
8570 | _ACEOF | |
8571 | if ac_fn_c_try_run "$LINENO"; then : | |
8572 | ac_cv_c_bigendian=no | |
8573 | else | |
8574 | ac_cv_c_bigendian=yes | |
8575 | fi | |
8576 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
8577 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
8578 | fi | |
8579 | ||
8580 | fi | |
8581 | fi | |
8582 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 | |
8583 | $as_echo "$ac_cv_c_bigendian" >&6; } | |
8584 | case $ac_cv_c_bigendian in #( | |
8585 | yes) | |
8586 | $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h | |
8587 | ;; #( | |
8588 | no) | |
8589 | ;; #( | |
8590 | universal) | |
8591 | ||
8592 | $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h | |
8593 | ||
8594 | ;; #( | |
8595 | *) | |
2018939f | 8596 | as_fn_error $? "unknown endianness |
d6974efa | 8597 | presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; |
067d23c9 KY |
8598 | esac |
8599 | ||
8600 | ||
7cae64b4 PE |
8601 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __attribute__ ((__aligned__ (expr)))" >&5 |
8602 | $as_echo_n "checking for __attribute__ ((__aligned__ (expr)))... " >&6; } | |
d6974efa | 8603 | if ${emacs_cv_attribute_aligned+:} false; then : |
7cae64b4 PE |
8604 | $as_echo_n "(cached) " >&6 |
8605 | else | |
8606 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8607 | /* end confdefs.h. */ | |
8608 | char __attribute__ ((__aligned__ (1 << 3))) c; | |
8609 | int | |
8610 | main () | |
8611 | { | |
8612 | ||
8613 | ; | |
8614 | return 0; | |
8615 | } | |
8616 | _ACEOF | |
8617 | if ac_fn_c_try_compile "$LINENO"; then : | |
8618 | emacs_cv_attribute_aligned=yes | |
8619 | else | |
8620 | emacs_cv_attribute_aligned=no | |
8621 | fi | |
8622 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
8623 | fi | |
8624 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_attribute_aligned" >&5 | |
8625 | $as_echo "$emacs_cv_attribute_aligned" >&6; } | |
8626 | if test $emacs_cv_attribute_aligned = yes; then | |
8627 | ||
8628 | $as_echo "#define HAVE_ATTRIBUTE_ALIGNED 1" >>confdefs.h | |
8629 | ||
8630 | fi | |
8631 | ||
067d23c9 KY |
8632 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 |
8633 | $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } | |
8634 | set x ${MAKE-make} | |
8635 | ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` | |
d6974efa | 8636 | if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : |
067d23c9 KY |
8637 | $as_echo_n "(cached) " >&6 |
8638 | else | |
8639 | cat >conftest.make <<\_ACEOF | |
8640 | SHELL = /bin/sh | |
8641 | all: | |
8642 | @echo '@@@%%%=$(MAKE)=@@@%%%' | |
8643 | _ACEOF | |
2018939f | 8644 | # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. |
067d23c9 KY |
8645 | case `${MAKE-make} -f conftest.make 2>/dev/null` in |
8646 | *@@@%%%=?*=@@@%%%*) | |
8647 | eval ac_cv_prog_make_${ac_make}_set=yes;; | |
8648 | *) | |
8649 | eval ac_cv_prog_make_${ac_make}_set=no;; | |
8650 | esac | |
8651 | rm -f conftest.make | |
8652 | fi | |
8653 | if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then | |
8654 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
8655 | $as_echo "yes" >&6; } | |
8656 | SET_MAKE= | |
8657 | else | |
8658 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
8659 | $as_echo "no" >&6; } | |
8660 | SET_MAKE="MAKE=${MAKE-make}" | |
8661 | fi | |
8662 | ||
8663 | ||
8664 | DEPFLAGS= | |
8665 | MKDEPDIR=":" | |
8666 | deps_frag=deps.mk | |
8667 | if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then | |
8668 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5 | |
8669 | $as_echo_n "checking whether we are using GNU Make... " >&6; } | |
8670 | HAVE_GNU_MAKE=no | |
8671 | testval=`make --version 2>/dev/null | grep 'GNU Make'` | |
8672 | if test "x$testval" != x; then | |
8673 | HAVE_GNU_MAKE=yes | |
8674 | else | |
8675 | ac_enable_autodepend=no | |
8676 | fi | |
8677 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5 | |
8678 | $as_echo "$HAVE_GNU_MAKE" >&6; } | |
8679 | if test $HAVE_GNU_MAKE = yes; then | |
8680 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5 | |
8681 | $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; } | |
8682 | SAVE_CFLAGS="$CFLAGS" | |
8683 | CFLAGS="$CFLAGS -MMD -MF deps.d" | |
8684 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8685 | /* end confdefs.h. */ | |
8686 | ||
8687 | int | |
8688 | main () | |
8689 | { | |
8690 | ||
8691 | ; | |
8692 | return 0; | |
8693 | } | |
8694 | _ACEOF | |
8695 | if ac_fn_c_try_compile "$LINENO"; then : | |
8696 | ||
8697 | else | |
8698 | ac_enable_autodepend=no | |
8699 | fi | |
8700 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
8701 | CFLAGS="$SAVE_CFLAGS" | |
8702 | test -f deps.d || ac_enable_autodepend=no | |
8703 | rm -rf deps.d | |
8704 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5 | |
8705 | $as_echo "$ac_enable_autodepend" >&6; } | |
8706 | fi | |
8707 | if test $ac_enable_autodepend = yes; then | |
8708 | DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d' | |
8709 | ## In parallel builds, another make might create depdir between | |
8710 | ## the first test and mkdir, so stick another test on the end. | |
8711 | ## Or use mkinstalldirs? mkdir -p is not portable. | |
8712 | MKDEPDIR='test -d ${DEPDIR} || mkdir ${DEPDIR} || test -d ${DEPDIR}' | |
8713 | deps_frag=autodeps.mk | |
8714 | fi | |
8715 | fi | |
8716 | deps_frag=$srcdir/src/$deps_frag | |
8717 | ||
8718 | ||
8719 | ||
8720 | ||
8721 | ||
8722 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5 | |
8723 | $as_echo_n "checking for long file names... " >&6; } | |
d6974efa | 8724 | if ${ac_cv_sys_long_file_names+:} false; then : |
067d23c9 KY |
8725 | $as_echo_n "(cached) " >&6 |
8726 | else | |
8727 | ac_cv_sys_long_file_names=yes | |
8728 | # Test for long file names in all the places we know might matter: | |
8729 | # . the current directory, where building will happen | |
8730 | # $prefix/lib where we will be installing things | |
8731 | # $exec_prefix/lib likewise | |
8732 | # $TMPDIR if set, where it might want to write temporary files | |
8733 | # /tmp where it might want to write temporary files | |
8734 | # /var/tmp likewise | |
8735 | # /usr/tmp likewise | |
8736 | for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do | |
8737 | # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib | |
8738 | # in the usual case where exec_prefix is '${prefix}'. | |
8739 | case $ac_dir in #( | |
8740 | . | /* | ?:[\\/]*) ;; #( | |
8741 | *) continue;; | |
8742 | esac | |
8743 | test -w "$ac_dir/." || continue # It is less confusing to not echo anything here. | |
8744 | ac_xdir=$ac_dir/cf$$ | |
8745 | (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue | |
8746 | ac_tf1=$ac_xdir/conftest9012345 | |
8747 | ac_tf2=$ac_xdir/conftest9012346 | |
8748 | touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" || | |
8749 | ac_cv_sys_long_file_names=no | |
8750 | rm -f -r "$ac_xdir" 2>/dev/null | |
8751 | test $ac_cv_sys_long_file_names = no && break | |
8752 | done | |
8753 | fi | |
8754 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5 | |
8755 | $as_echo "$ac_cv_sys_long_file_names" >&6; } | |
8756 | if test $ac_cv_sys_long_file_names = yes; then | |
8757 | ||
8758 | $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h | |
8759 | ||
8760 | fi | |
8761 | ||
8762 | ||
8763 | #### Choose a window system. | |
8764 | ||
8765 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5 | |
8766 | $as_echo_n "checking for X... " >&6; } | |
8767 | ||
8768 | ||
8769 | # Check whether --with-x was given. | |
8770 | if test "${with_x+set}" = set; then : | |
8771 | withval=$with_x; | |
8772 | fi | |
8773 | ||
8774 | # $have_x is `yes', `no', `disabled', or empty when we do not yet know. | |
8775 | if test "x$with_x" = xno; then | |
8776 | # The user explicitly disabled X. | |
8777 | have_x=disabled | |
8778 | else | |
8779 | case $x_includes,$x_libraries in #( | |
d6974efa PE |
8780 | *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #( |
8781 | *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then : | |
067d23c9 KY |
8782 | $as_echo_n "(cached) " >&6 |
8783 | else | |
8784 | # One or both of the vars are not set, and there is no cached value. | |
8785 | ac_x_includes=no ac_x_libraries=no | |
8786 | rm -f -r conftest.dir | |
8787 | if mkdir conftest.dir; then | |
8788 | cd conftest.dir | |
8789 | cat >Imakefile <<'_ACEOF' | |
8790 | incroot: | |
8791 | @echo incroot='${INCROOT}' | |
8792 | usrlibdir: | |
8793 | @echo usrlibdir='${USRLIBDIR}' | |
8794 | libdir: | |
8795 | @echo libdir='${LIBDIR}' | |
8796 | _ACEOF | |
8797 | if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then | |
2018939f | 8798 | # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. |
067d23c9 KY |
8799 | for ac_var in incroot usrlibdir libdir; do |
8800 | eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`" | |
8801 | done | |
8802 | # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. | |
8803 | for ac_extension in a so sl dylib la dll; do | |
8804 | if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" && | |
8805 | test -f "$ac_im_libdir/libX11.$ac_extension"; then | |
8806 | ac_im_usrlibdir=$ac_im_libdir; break | |
8807 | fi | |
8808 | done | |
8809 | # Screen out bogus values from the imake configuration. They are | |
8810 | # bogus both because they are the default anyway, and because | |
8811 | # using them would break gcc on systems where it needs fixed includes. | |
8812 | case $ac_im_incroot in | |
8813 | /usr/include) ac_x_includes= ;; | |
8814 | *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;; | |
8815 | esac | |
8816 | case $ac_im_usrlibdir in | |
8817 | /usr/lib | /usr/lib64 | /lib | /lib64) ;; | |
8818 | *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;; | |
8819 | esac | |
8820 | fi | |
8821 | cd .. | |
8822 | rm -f -r conftest.dir | |
8823 | fi | |
8824 | ||
8825 | # Standard set of common directories for X headers. | |
8826 | # Check X11 before X11Rn because it is often a symlink to the current release. | |
8827 | ac_x_header_dirs=' | |
8828 | /usr/X11/include | |
8829 | /usr/X11R7/include | |
8830 | /usr/X11R6/include | |
8831 | /usr/X11R5/include | |
8832 | /usr/X11R4/include | |
8833 | ||
8834 | /usr/include/X11 | |
8835 | /usr/include/X11R7 | |
8836 | /usr/include/X11R6 | |
8837 | /usr/include/X11R5 | |
8838 | /usr/include/X11R4 | |
8839 | ||
8840 | /usr/local/X11/include | |
8841 | /usr/local/X11R7/include | |
8842 | /usr/local/X11R6/include | |
8843 | /usr/local/X11R5/include | |
8844 | /usr/local/X11R4/include | |
8845 | ||
8846 | /usr/local/include/X11 | |
8847 | /usr/local/include/X11R7 | |
8848 | /usr/local/include/X11R6 | |
8849 | /usr/local/include/X11R5 | |
8850 | /usr/local/include/X11R4 | |
8851 | ||
8852 | /usr/X386/include | |
8853 | /usr/x386/include | |
8854 | /usr/XFree86/include/X11 | |
8855 | ||
8856 | /usr/include | |
8857 | /usr/local/include | |
8858 | /usr/unsupported/include | |
8859 | /usr/athena/include | |
8860 | /usr/local/x11r5/include | |
8861 | /usr/lpp/Xamples/include | |
8862 | ||
8863 | /usr/openwin/include | |
8864 | /usr/openwin/share/include' | |
8865 | ||
8866 | if test "$ac_x_includes" = no; then | |
8867 | # Guess where to find include files, by looking for Xlib.h. | |
8868 | # First, try using that file with no special directory specified. | |
8869 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8870 | /* end confdefs.h. */ | |
8871 | #include <X11/Xlib.h> | |
8872 | _ACEOF | |
8873 | if ac_fn_c_try_cpp "$LINENO"; then : | |
8874 | # We can compile using X headers with no special include directory. | |
8875 | ac_x_includes= | |
8876 | else | |
8877 | for ac_dir in $ac_x_header_dirs; do | |
8878 | if test -r "$ac_dir/X11/Xlib.h"; then | |
8879 | ac_x_includes=$ac_dir | |
8880 | break | |
8881 | fi | |
8882 | done | |
8883 | fi | |
2018939f | 8884 | rm -f conftest.err conftest.i conftest.$ac_ext |
067d23c9 KY |
8885 | fi # $ac_x_includes = no |
8886 | ||
8887 | if test "$ac_x_libraries" = no; then | |
8888 | # Check for the libraries. | |
8889 | # See if we find them without any special options. | |
8890 | # Don't add to $LIBS permanently. | |
8891 | ac_save_LIBS=$LIBS | |
8892 | LIBS="-lX11 $LIBS" | |
8893 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8894 | /* end confdefs.h. */ | |
8895 | #include <X11/Xlib.h> | |
8896 | int | |
8897 | main () | |
8898 | { | |
8899 | XrmInitialize () | |
8900 | ; | |
8901 | return 0; | |
8902 | } | |
8903 | _ACEOF | |
8904 | if ac_fn_c_try_link "$LINENO"; then : | |
8905 | LIBS=$ac_save_LIBS | |
8906 | # We can link X programs with no special library path. | |
8907 | ac_x_libraries= | |
8908 | else | |
8909 | LIBS=$ac_save_LIBS | |
8910 | for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` | |
8911 | do | |
8912 | # Don't even attempt the hair of trying to link an X program! | |
8913 | for ac_extension in a so sl dylib la dll; do | |
8914 | if test -r "$ac_dir/libX11.$ac_extension"; then | |
8915 | ac_x_libraries=$ac_dir | |
8916 | break 2 | |
8917 | fi | |
8918 | done | |
8919 | done | |
8920 | fi | |
8921 | rm -f core conftest.err conftest.$ac_objext \ | |
8922 | conftest$ac_exeext conftest.$ac_ext | |
8923 | fi # $ac_x_libraries = no | |
8924 | ||
8925 | case $ac_x_includes,$ac_x_libraries in #( | |
8926 | no,* | *,no | *\'*) | |
8927 | # Didn't find X, or a directory has "'" in its name. | |
8928 | ac_cv_have_x="have_x=no";; #( | |
8929 | *) | |
8930 | # Record where we found X for the cache. | |
8931 | ac_cv_have_x="have_x=yes\ | |
8932 | ac_x_includes='$ac_x_includes'\ | |
8933 | ac_x_libraries='$ac_x_libraries'" | |
8934 | esac | |
8935 | fi | |
8936 | ;; #( | |
8937 | *) have_x=yes;; | |
8938 | esac | |
8939 | eval "$ac_cv_have_x" | |
8940 | fi # $with_x != no | |
8941 | ||
8942 | if test "$have_x" != yes; then | |
8943 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5 | |
8944 | $as_echo "$have_x" >&6; } | |
8945 | no_x=yes | |
8946 | else | |
8947 | # If each of the values was on the command line, it overrides each guess. | |
8948 | test "x$x_includes" = xNONE && x_includes=$ac_x_includes | |
8949 | test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries | |
8950 | # Update the cache value to reflect the command line values. | |
8951 | ac_cv_have_x="have_x=yes\ | |
8952 | ac_x_includes='$x_includes'\ | |
8953 | ac_x_libraries='$x_libraries'" | |
8954 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5 | |
8955 | $as_echo "libraries $x_libraries, headers $x_includes" >&6; } | |
8956 | fi | |
8957 | ||
8958 | if test "$no_x" = yes; then | |
8959 | window_system=none | |
8960 | else | |
8961 | window_system=x11 | |
8962 | fi | |
8963 | ||
8964 | ## Workaround for bug in autoconf <= 2.62. | |
8965 | ## http://lists.gnu.org/archive/html/emacs-devel/2008-04/msg01551.html | |
8966 | ## No need to do anything special for these standard directories. | |
8967 | if test -n "${x_libraries}" && test x"${x_libraries}" != xNONE; then | |
8968 | ||
8969 | x_libraries=`echo :${x_libraries}: | sed -e 's|:/usr/lib64:|:|g' -e 's|:/lib64:|:|g' -e 's|^:||' -e 's|:$||'` | |
8970 | ||
8971 | fi | |
8972 | ||
8973 | LD_SWITCH_X_SITE_AUX= | |
8974 | LD_SWITCH_X_SITE_AUX_RPATH= | |
8975 | if test "${x_libraries}" != NONE; then | |
8976 | if test -n "${x_libraries}"; then | |
8977 | LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"` | |
8978 | LD_SWITCH_X_SITE_AUX=-R`echo ${x_libraries} | sed -e "s/:/ -R/g"` | |
8979 | LD_SWITCH_X_SITE_AUX_RPATH=`echo ${LD_SWITCH_X_SITE_AUX} | sed -e 's/-R/-Wl,-rpath,/'` | |
8980 | fi | |
8981 | x_default_search_path="" | |
8982 | x_search_path=${x_libraries} | |
8983 | if test -z "${x_search_path}"; then | |
8984 | x_search_path=/usr/lib | |
8985 | fi | |
8986 | for x_library in `echo ${x_search_path}: | \ | |
8987 | sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do | |
8988 | x_search_path="\ | |
8989 | ${x_library}/X11/%L/%T/%N%C%S:\ | |
8990 | ${x_library}/X11/%l/%T/%N%C%S:\ | |
8991 | ${x_library}/X11/%T/%N%C%S:\ | |
8992 | ${x_library}/X11/%L/%T/%N%S:\ | |
8993 | ${x_library}/X11/%l/%T/%N%S:\ | |
8994 | ${x_library}/X11/%T/%N%S" | |
8995 | if test x"${x_default_search_path}" = x; then | |
8996 | x_default_search_path=${x_search_path} | |
8997 | else | |
8998 | x_default_search_path="${x_search_path}:${x_default_search_path}" | |
8999 | fi | |
9000 | done | |
9001 | fi | |
9002 | ||
9003 | ||
9004 | ||
9005 | if test "${x_includes}" != NONE && test -n "${x_includes}"; then | |
9006 | C_SWITCH_X_SITE=-I`echo ${x_includes} | sed -e "s/:/ -I/g"` | |
9007 | fi | |
9008 | ||
9009 | if test x"${x_includes}" = x; then | |
9010 | bitmapdir=/usr/include/X11/bitmaps | |
9011 | else | |
9012 | # accumulate include directories that have X11 bitmap subdirectories | |
9013 | bmd_acc="dummyval" | |
9014 | for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do | |
9015 | if test -d "${bmd}/X11/bitmaps"; then | |
9016 | bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps" | |
9017 | fi | |
9018 | if test -d "${bmd}/bitmaps"; then | |
9019 | bmd_acc="${bmd_acc}:${bmd}/bitmaps" | |
9020 | fi | |
9021 | done | |
9022 | if test ${bmd_acc} != "dummyval"; then | |
9023 | bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"` | |
9024 | fi | |
9025 | fi | |
9026 | ||
9027 | HAVE_NS=no | |
9028 | NS_IMPL_COCOA=no | |
9029 | NS_IMPL_GNUSTEP=no | |
9030 | tmp_CPPFLAGS="$CPPFLAGS" | |
9031 | tmp_CFLAGS="$CFLAGS" | |
9032 | CPPFLAGS="$CPPFLAGS -x objective-c" | |
9033 | CFLAGS="$CFLAGS -x objective-c" | |
9034 | TEMACS_LDFLAGS2="\${LDFLAGS}" | |
9035 | if test "${with_ns}" != no; then | |
9036 | if test "${opsys}" = darwin; then | |
9037 | NS_IMPL_COCOA=yes | |
9038 | ns_appdir=`pwd`/nextstep/Emacs.app | |
9039 | ns_appbindir=${ns_appdir}/Contents/MacOS/ | |
9040 | ns_appresdir=${ns_appdir}/Contents/Resources | |
9041 | ns_appsrc=${srcdir}/nextstep/Cocoa/Emacs.base | |
9042 | elif test -f $GNUSTEP_CONFIG_FILE; then | |
9043 | NS_IMPL_GNUSTEP=yes | |
9044 | ns_appdir=`pwd`/nextstep/Emacs.app | |
9045 | ns_appbindir=${ns_appdir}/ | |
9046 | ns_appresdir=${ns_appdir}/Resources | |
9047 | ns_appsrc=${srcdir}/nextstep/GNUstep/Emacs.base | |
9048 | GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)" | |
9049 | GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)" | |
9050 | GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)" | |
9051 | GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)" | |
9052 | test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \ | |
9053 | GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}" | |
9054 | test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \ | |
9055 | GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}" | |
9056 | CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}" | |
9057 | CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}" | |
9058 | LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}" | |
9059 | LIB_STANDARD= | |
9060 | START_FILES= | |
9061 | TEMACS_LDFLAGS2= | |
9062 | fi | |
9063 | ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default" | |
d6974efa | 9064 | if test "x$ac_cv_header_AppKit_AppKit_h" = xyes; then : |
067d23c9 KY |
9065 | HAVE_NS=yes |
9066 | else | |
2018939f | 9067 | as_fn_error $? "\`--with-ns' was specified, but the include |
067d23c9 KY |
9068 | files are missing or cannot be compiled." "$LINENO" 5 |
9069 | fi | |
9070 | ||
9071 | ||
9072 | NS_HAVE_NSINTEGER=yes | |
9073 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9074 | /* end confdefs.h. */ | |
9075 | #include <Foundation/NSObjCRuntime.h> | |
9076 | int | |
9077 | main () | |
9078 | { | |
9079 | NSInteger i; | |
9080 | ; | |
9081 | return 0; | |
9082 | } | |
9083 | _ACEOF | |
9084 | if ac_fn_c_try_compile "$LINENO"; then : | |
9085 | ns_have_nsinteger=yes | |
9086 | else | |
9087 | ns_have_nsinteger=no | |
9088 | fi | |
9089 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
9090 | if test $ns_have_nsinteger = no; then | |
9091 | NS_HAVE_NSINTEGER=no | |
9092 | fi | |
9093 | fi | |
9094 | ||
9095 | ||
9096 | ns_frag=/dev/null | |
9097 | NS_OBJ= | |
00b3c7ac | 9098 | NS_OBJC_OBJ= |
067d23c9 KY |
9099 | NS_SUPPORT= |
9100 | if test "${HAVE_NS}" = yes; then | |
9101 | window_system=nextstep | |
9102 | with_xft=no | |
9103 | # set up packaging dirs | |
9104 | exec_prefix=${ns_appbindir} | |
9105 | libexecdir=${ns_appbindir}/libexec | |
9106 | if test "${EN_NS_SELF_CONTAINED}" = yes; then | |
9107 | prefix=${ns_appresdir} | |
9108 | fi | |
9109 | ns_frag=$srcdir/src/ns.mk | |
00b3c7ac TT |
9110 | NS_OBJ="fontset.o fringe.o image.o" |
9111 | NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o" | |
067d23c9 KY |
9112 | NS_SUPPORT="\${lispsource}/emacs-lisp/easymenu.elc \${lispsource}/term/ns-win.elc" |
9113 | fi | |
9114 | CFLAGS="$tmp_CFLAGS" | |
9115 | CPPFLAGS="$tmp_CPPFLAGS" | |
9116 | ||
9117 | ||
9118 | ||
9119 | ||
9120 | ||
00b3c7ac | 9121 | |
067d23c9 KY |
9122 | case "${window_system}" in |
9123 | x11 ) | |
9124 | HAVE_X_WINDOWS=yes | |
9125 | HAVE_X11=yes | |
9126 | case "${with_x_toolkit}" in | |
9127 | athena | lucid ) USE_X_TOOLKIT=LUCID ;; | |
9128 | motif ) USE_X_TOOLKIT=MOTIF ;; | |
9129 | gtk ) with_gtk=yes | |
9130 | USE_X_TOOLKIT=none ;; | |
9131 | gtk3 ) with_gtk3=yes | |
9132 | USE_X_TOOLKIT=none ;; | |
9133 | no ) USE_X_TOOLKIT=none ;; | |
9134 | * ) USE_X_TOOLKIT=maybe ;; | |
9135 | esac | |
9136 | ;; | |
9137 | nextstep | none ) | |
9138 | HAVE_X_WINDOWS=no | |
9139 | HAVE_X11=no | |
9140 | USE_X_TOOLKIT=none | |
9141 | ;; | |
9142 | esac | |
9143 | ||
9144 | if test "$window_system" = none && test "X$with_x" != "Xno"; then | |
9145 | # Extract the first word of "X", so it can be a program name with args. | |
9146 | set dummy X; ac_word=$2 | |
9147 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
9148 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 9149 | if ${ac_cv_prog_HAVE_XSERVER+:} false; then : |
067d23c9 KY |
9150 | $as_echo_n "(cached) " >&6 |
9151 | else | |
9152 | if test -n "$HAVE_XSERVER"; then | |
9153 | ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test. | |
9154 | else | |
9155 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
9156 | for as_dir in $PATH | |
9157 | do | |
9158 | IFS=$as_save_IFS | |
9159 | test -z "$as_dir" && as_dir=. | |
9160 | for ac_exec_ext in '' $ac_executable_extensions; do | |
9161 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
9162 | ac_cv_prog_HAVE_XSERVER="true" | |
9163 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
9164 | break 2 | |
9165 | fi | |
9166 | done | |
9167 | done | |
9168 | IFS=$as_save_IFS | |
9169 | ||
9170 | test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false" | |
9171 | fi | |
9172 | fi | |
9173 | HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER | |
9174 | if test -n "$HAVE_XSERVER"; then | |
9175 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5 | |
9176 | $as_echo "$HAVE_XSERVER" >&6; } | |
9177 | else | |
9178 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
9179 | $as_echo "no" >&6; } | |
9180 | fi | |
9181 | ||
9182 | ||
9183 | if test "$HAVE_XSERVER" = true || | |
9184 | test -n "$DISPLAY" || | |
9185 | test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then | |
2018939f | 9186 | as_fn_error $? "You seem to be running X, but no X development libraries |
067d23c9 KY |
9187 | were found. You should install the relevant development files for X |
9188 | and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make | |
9189 | sure you have development files for image handling, i.e. | |
9190 | tiff, gif, jpeg, png and xpm. | |
9191 | If you are sure you want Emacs compiled without X window support, pass | |
9192 | --without-x | |
9193 | to configure." "$LINENO" 5 | |
9194 | fi | |
9195 | fi | |
9196 | ||
9197 | ### If we're using X11, we should use the X menu package. | |
9198 | HAVE_MENUS=no | |
9199 | case ${HAVE_X11} in | |
9200 | yes ) HAVE_MENUS=yes ;; | |
9201 | esac | |
9202 | ||
9203 | # Do the opsystem or machine files prohibit the use of the GNU malloc? | |
9204 | # Assume not, until told otherwise. | |
9205 | GNU_MALLOC=yes | |
9206 | doug_lea_malloc=yes | |
9207 | ac_fn_c_check_func "$LINENO" "malloc_get_state" "ac_cv_func_malloc_get_state" | |
d6974efa | 9208 | if test "x$ac_cv_func_malloc_get_state" = xyes; then : |
067d23c9 KY |
9209 | |
9210 | else | |
9211 | doug_lea_malloc=no | |
9212 | fi | |
9213 | ||
9214 | ac_fn_c_check_func "$LINENO" "malloc_set_state" "ac_cv_func_malloc_set_state" | |
d6974efa | 9215 | if test "x$ac_cv_func_malloc_set_state" = xyes; then : |
067d23c9 KY |
9216 | |
9217 | else | |
9218 | doug_lea_malloc=no | |
9219 | fi | |
9220 | ||
9221 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __after_morecore_hook exists" >&5 | |
9222 | $as_echo_n "checking whether __after_morecore_hook exists... " >&6; } | |
d6974efa | 9223 | if ${emacs_cv_var___after_morecore_hook+:} false; then : |
067d23c9 KY |
9224 | $as_echo_n "(cached) " >&6 |
9225 | else | |
9226 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9227 | /* end confdefs.h. */ | |
9228 | extern void (* __after_morecore_hook)(); | |
9229 | int | |
9230 | main () | |
9231 | { | |
9232 | __after_morecore_hook = 0 | |
9233 | ; | |
9234 | return 0; | |
9235 | } | |
9236 | _ACEOF | |
9237 | if ac_fn_c_try_link "$LINENO"; then : | |
9238 | emacs_cv_var___after_morecore_hook=yes | |
9239 | else | |
9240 | emacs_cv_var___after_morecore_hook=no | |
9241 | fi | |
9242 | rm -f core conftest.err conftest.$ac_objext \ | |
9243 | conftest$ac_exeext conftest.$ac_ext | |
9244 | fi | |
9245 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var___after_morecore_hook" >&5 | |
9246 | $as_echo "$emacs_cv_var___after_morecore_hook" >&6; } | |
9247 | if test $emacs_cv_var___after_morecore_hook = no; then | |
9248 | doug_lea_malloc=no | |
9249 | fi | |
9250 | ||
9251 | ||
9252 | system_malloc=no | |
9253 | case "$opsys" in | |
9254 | ## darwin ld insists on the use of malloc routines in the System framework. | |
9255 | darwin|sol2-10) system_malloc=yes ;; | |
9256 | esac | |
9257 | ||
9258 | if test "${system_malloc}" = "yes"; then | |
9259 | ||
9260 | $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h | |
9261 | ||
9262 | GNU_MALLOC=no | |
9263 | GNU_MALLOC_reason=" | |
9264 | (The GNU allocators don't work with this system configuration.)" | |
9265 | GMALLOC_OBJ= | |
9266 | VMLIMIT_OBJ= | |
9267 | else | |
9268 | test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o | |
9269 | VMLIMIT_OBJ=vm-limit.o | |
9270 | fi | |
9271 | ||
9272 | ||
9273 | ||
9274 | if test "$doug_lea_malloc" = "yes" ; then | |
9275 | if test "$GNU_MALLOC" = yes ; then | |
9276 | GNU_MALLOC_reason=" | |
9277 | (Using Doug Lea's new malloc from the GNU C Library.)" | |
9278 | fi | |
9279 | ||
9280 | $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h | |
9281 | ||
9282 | ||
9283 | ## Use mmap directly for allocating larger buffers. | |
9284 | ## FIXME this comes from src/s/{gnu,gnu-linux}.h: | |
9285 | ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif | |
9286 | ## Does the AC_FUNC_MMAP test below make this check unecessary? | |
9287 | case "$opsys" in | |
9288 | gnu*) REL_ALLOC=no ;; | |
9289 | esac | |
9290 | fi | |
9291 | ||
9292 | if test x"${REL_ALLOC}" = x; then | |
9293 | REL_ALLOC=${GNU_MALLOC} | |
9294 | fi | |
9295 | ||
9296 | use_mmap_for_buffers=no | |
9297 | case "$opsys" in | |
9298 | freebsd|irix6-5) use_mmap_for_buffers=yes ;; | |
9299 | esac | |
9300 | ||
9301 | ||
9302 | ||
9303 | ||
9304 | for ac_header in $ac_header_list | |
9305 | do : | |
9306 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
9307 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default | |
9308 | " | |
2018939f | 9309 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
067d23c9 KY |
9310 | cat >>confdefs.h <<_ACEOF |
9311 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
9312 | _ACEOF | |
9313 | ||
9314 | fi | |
9315 | ||
9316 | done | |
9317 | ||
9318 | ||
9319 | ||
9320 | ||
9321 | ||
9322 | ||
9323 | ||
9324 | ||
9325 | for ac_func in getpagesize | |
9326 | do : | |
9327 | ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize" | |
d6974efa | 9328 | if test "x$ac_cv_func_getpagesize" = xyes; then : |
067d23c9 KY |
9329 | cat >>confdefs.h <<_ACEOF |
9330 | #define HAVE_GETPAGESIZE 1 | |
9331 | _ACEOF | |
9332 | ||
9333 | fi | |
9334 | done | |
9335 | ||
9336 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5 | |
9337 | $as_echo_n "checking for working mmap... " >&6; } | |
d6974efa | 9338 | if ${ac_cv_func_mmap_fixed_mapped+:} false; then : |
067d23c9 KY |
9339 | $as_echo_n "(cached) " >&6 |
9340 | else | |
9341 | if test "$cross_compiling" = yes; then : | |
9342 | ac_cv_func_mmap_fixed_mapped=no | |
9343 | else | |
9344 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9345 | /* end confdefs.h. */ | |
9346 | $ac_includes_default | |
9347 | /* malloc might have been renamed as rpl_malloc. */ | |
9348 | #undef malloc | |
9349 | ||
9350 | /* Thanks to Mike Haertel and Jim Avera for this test. | |
9351 | Here is a matrix of mmap possibilities: | |
9352 | mmap private not fixed | |
9353 | mmap private fixed at somewhere currently unmapped | |
9354 | mmap private fixed at somewhere already mapped | |
9355 | mmap shared not fixed | |
9356 | mmap shared fixed at somewhere currently unmapped | |
9357 | mmap shared fixed at somewhere already mapped | |
9358 | For private mappings, we should verify that changes cannot be read() | |
9359 | back from the file, nor mmap's back from the file at a different | |
9360 | address. (There have been systems where private was not correctly | |
9361 | implemented like the infamous i386 svr4.0, and systems where the | |
9362 | VM page cache was not coherent with the file system buffer cache | |
9363 | like early versions of FreeBSD and possibly contemporary NetBSD.) | |
9364 | For shared mappings, we should conversely verify that changes get | |
9365 | propagated back to all the places they're supposed to be. | |
9366 | ||
9367 | Grep wants private fixed already mapped. | |
9368 | The main things grep needs to know about mmap are: | |
9369 | * does it exist and is it safe to write into the mmap'd area | |
9370 | * how to use it (BSD variants) */ | |
9371 | ||
9372 | #include <fcntl.h> | |
9373 | #include <sys/mman.h> | |
9374 | ||
9375 | #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H | |
9376 | char *malloc (); | |
9377 | #endif | |
9378 | ||
9379 | /* This mess was copied from the GNU getpagesize.h. */ | |
9380 | #ifndef HAVE_GETPAGESIZE | |
9381 | # ifdef _SC_PAGESIZE | |
9382 | # define getpagesize() sysconf(_SC_PAGESIZE) | |
9383 | # else /* no _SC_PAGESIZE */ | |
9384 | # ifdef HAVE_SYS_PARAM_H | |
9385 | # include <sys/param.h> | |
9386 | # ifdef EXEC_PAGESIZE | |
9387 | # define getpagesize() EXEC_PAGESIZE | |
9388 | # else /* no EXEC_PAGESIZE */ | |
9389 | # ifdef NBPG | |
9390 | # define getpagesize() NBPG * CLSIZE | |
9391 | # ifndef CLSIZE | |
9392 | # define CLSIZE 1 | |
9393 | # endif /* no CLSIZE */ | |
9394 | # else /* no NBPG */ | |
9395 | # ifdef NBPC | |
9396 | # define getpagesize() NBPC | |
9397 | # else /* no NBPC */ | |
9398 | # ifdef PAGESIZE | |
9399 | # define getpagesize() PAGESIZE | |
9400 | # endif /* PAGESIZE */ | |
9401 | # endif /* no NBPC */ | |
9402 | # endif /* no NBPG */ | |
9403 | # endif /* no EXEC_PAGESIZE */ | |
9404 | # else /* no HAVE_SYS_PARAM_H */ | |
9405 | # define getpagesize() 8192 /* punt totally */ | |
9406 | # endif /* no HAVE_SYS_PARAM_H */ | |
9407 | # endif /* no _SC_PAGESIZE */ | |
9408 | ||
9409 | #endif /* no HAVE_GETPAGESIZE */ | |
9410 | ||
9411 | int | |
9412 | main () | |
9413 | { | |
9414 | char *data, *data2, *data3; | |
2018939f | 9415 | const char *cdata2; |
067d23c9 KY |
9416 | int i, pagesize; |
9417 | int fd, fd2; | |
9418 | ||
9419 | pagesize = getpagesize (); | |
9420 | ||
9421 | /* First, make a file with some known garbage in it. */ | |
9422 | data = (char *) malloc (pagesize); | |
9423 | if (!data) | |
9424 | return 1; | |
9425 | for (i = 0; i < pagesize; ++i) | |
9426 | *(data + i) = rand (); | |
9427 | umask (0); | |
9428 | fd = creat ("conftest.mmap", 0600); | |
9429 | if (fd < 0) | |
9430 | return 2; | |
9431 | if (write (fd, data, pagesize) != pagesize) | |
9432 | return 3; | |
9433 | close (fd); | |
9434 | ||
9435 | /* Next, check that the tail of a page is zero-filled. File must have | |
9436 | non-zero length, otherwise we risk SIGBUS for entire page. */ | |
9437 | fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600); | |
9438 | if (fd2 < 0) | |
9439 | return 4; | |
2018939f AS |
9440 | cdata2 = ""; |
9441 | if (write (fd2, cdata2, 1) != 1) | |
067d23c9 | 9442 | return 5; |
2018939f | 9443 | data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L); |
067d23c9 KY |
9444 | if (data2 == MAP_FAILED) |
9445 | return 6; | |
9446 | for (i = 0; i < pagesize; ++i) | |
9447 | if (*(data2 + i)) | |
9448 | return 7; | |
9449 | close (fd2); | |
9450 | if (munmap (data2, pagesize)) | |
9451 | return 8; | |
9452 | ||
9453 | /* Next, try to mmap the file at a fixed address which already has | |
9454 | something else allocated at it. If we can, also make sure that | |
9455 | we see the same garbage. */ | |
9456 | fd = open ("conftest.mmap", O_RDWR); | |
9457 | if (fd < 0) | |
9458 | return 9; | |
9459 | if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE, | |
9460 | MAP_PRIVATE | MAP_FIXED, fd, 0L)) | |
9461 | return 10; | |
9462 | for (i = 0; i < pagesize; ++i) | |
9463 | if (*(data + i) != *(data2 + i)) | |
9464 | return 11; | |
9465 | ||
9466 | /* Finally, make sure that changes to the mapped area do not | |
9467 | percolate back to the file as seen by read(). (This is a bug on | |
9468 | some variants of i386 svr4.0.) */ | |
9469 | for (i = 0; i < pagesize; ++i) | |
9470 | *(data2 + i) = *(data2 + i) + 1; | |
9471 | data3 = (char *) malloc (pagesize); | |
9472 | if (!data3) | |
9473 | return 12; | |
9474 | if (read (fd, data3, pagesize) != pagesize) | |
9475 | return 13; | |
9476 | for (i = 0; i < pagesize; ++i) | |
9477 | if (*(data + i) != *(data3 + i)) | |
9478 | return 14; | |
9479 | close (fd); | |
9480 | return 0; | |
9481 | } | |
9482 | _ACEOF | |
9483 | if ac_fn_c_try_run "$LINENO"; then : | |
9484 | ac_cv_func_mmap_fixed_mapped=yes | |
9485 | else | |
9486 | ac_cv_func_mmap_fixed_mapped=no | |
9487 | fi | |
9488 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
9489 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
9490 | fi | |
9491 | ||
9492 | fi | |
9493 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5 | |
9494 | $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; } | |
9495 | if test $ac_cv_func_mmap_fixed_mapped = yes; then | |
9496 | ||
9497 | $as_echo "#define HAVE_MMAP 1" >>confdefs.h | |
9498 | ||
9499 | fi | |
9500 | rm -f conftest.mmap conftest.txt | |
9501 | ||
9502 | if test $use_mmap_for_buffers = yes; then | |
9503 | ||
9504 | $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h | |
9505 | ||
9506 | REL_ALLOC=no | |
9507 | fi | |
9508 | ||
9509 | LIBS="$LIBS_SYSTEM $LIBS" | |
9510 | ||
9511 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5 | |
9512 | $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; } | |
d6974efa | 9513 | if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then : |
067d23c9 KY |
9514 | $as_echo_n "(cached) " >&6 |
9515 | else | |
9516 | ac_check_lib_save_LIBS=$LIBS | |
9517 | LIBS="-ldnet $LIBS" | |
9518 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9519 | /* end confdefs.h. */ | |
9520 | ||
9521 | /* Override any GCC internal prototype to avoid an error. | |
9522 | Use char because int might match the return type of a GCC | |
9523 | builtin and then its argument prototype would still apply. */ | |
9524 | #ifdef __cplusplus | |
9525 | extern "C" | |
9526 | #endif | |
9527 | char dnet_ntoa (); | |
9528 | int | |
9529 | main () | |
9530 | { | |
9531 | return dnet_ntoa (); | |
9532 | ; | |
9533 | return 0; | |
9534 | } | |
9535 | _ACEOF | |
9536 | if ac_fn_c_try_link "$LINENO"; then : | |
9537 | ac_cv_lib_dnet_dnet_ntoa=yes | |
9538 | else | |
9539 | ac_cv_lib_dnet_dnet_ntoa=no | |
9540 | fi | |
9541 | rm -f core conftest.err conftest.$ac_objext \ | |
9542 | conftest$ac_exeext conftest.$ac_ext | |
9543 | LIBS=$ac_check_lib_save_LIBS | |
9544 | fi | |
9545 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5 | |
9546 | $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; } | |
d6974efa | 9547 | if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then : |
067d23c9 KY |
9548 | cat >>confdefs.h <<_ACEOF |
9549 | #define HAVE_LIBDNET 1 | |
9550 | _ACEOF | |
9551 | ||
9552 | LIBS="-ldnet $LIBS" | |
9553 | ||
9554 | fi | |
9555 | ||
9556 | ||
9557 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5 | |
9558 | $as_echo_n "checking for main in -lXbsd... " >&6; } | |
d6974efa | 9559 | if ${ac_cv_lib_Xbsd_main+:} false; then : |
067d23c9 KY |
9560 | $as_echo_n "(cached) " >&6 |
9561 | else | |
9562 | ac_check_lib_save_LIBS=$LIBS | |
9563 | LIBS="-lXbsd $LIBS" | |
9564 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9565 | /* end confdefs.h. */ | |
9566 | ||
9567 | ||
9568 | int | |
9569 | main () | |
9570 | { | |
9571 | return main (); | |
9572 | ; | |
9573 | return 0; | |
9574 | } | |
9575 | _ACEOF | |
9576 | if ac_fn_c_try_link "$LINENO"; then : | |
9577 | ac_cv_lib_Xbsd_main=yes | |
9578 | else | |
9579 | ac_cv_lib_Xbsd_main=no | |
9580 | fi | |
9581 | rm -f core conftest.err conftest.$ac_objext \ | |
9582 | conftest$ac_exeext conftest.$ac_ext | |
9583 | LIBS=$ac_check_lib_save_LIBS | |
9584 | fi | |
9585 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5 | |
9586 | $as_echo "$ac_cv_lib_Xbsd_main" >&6; } | |
d6974efa | 9587 | if test "x$ac_cv_lib_Xbsd_main" = xyes; then : |
067d23c9 KY |
9588 | LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd" |
9589 | fi | |
9590 | ||
9591 | ||
9592 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5 | |
9593 | $as_echo_n "checking for cma_open in -lpthreads... " >&6; } | |
d6974efa | 9594 | if ${ac_cv_lib_pthreads_cma_open+:} false; then : |
067d23c9 KY |
9595 | $as_echo_n "(cached) " >&6 |
9596 | else | |
9597 | ac_check_lib_save_LIBS=$LIBS | |
9598 | LIBS="-lpthreads $LIBS" | |
9599 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9600 | /* end confdefs.h. */ | |
9601 | ||
9602 | /* Override any GCC internal prototype to avoid an error. | |
9603 | Use char because int might match the return type of a GCC | |
9604 | builtin and then its argument prototype would still apply. */ | |
9605 | #ifdef __cplusplus | |
9606 | extern "C" | |
9607 | #endif | |
9608 | char cma_open (); | |
9609 | int | |
9610 | main () | |
9611 | { | |
9612 | return cma_open (); | |
9613 | ; | |
9614 | return 0; | |
9615 | } | |
9616 | _ACEOF | |
9617 | if ac_fn_c_try_link "$LINENO"; then : | |
9618 | ac_cv_lib_pthreads_cma_open=yes | |
9619 | else | |
9620 | ac_cv_lib_pthreads_cma_open=no | |
9621 | fi | |
9622 | rm -f core conftest.err conftest.$ac_objext \ | |
9623 | conftest$ac_exeext conftest.$ac_ext | |
9624 | LIBS=$ac_check_lib_save_LIBS | |
9625 | fi | |
9626 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5 | |
9627 | $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; } | |
d6974efa | 9628 | if test "x$ac_cv_lib_pthreads_cma_open" = xyes; then : |
067d23c9 KY |
9629 | cat >>confdefs.h <<_ACEOF |
9630 | #define HAVE_LIBPTHREADS 1 | |
9631 | _ACEOF | |
9632 | ||
9633 | LIBS="-lpthreads $LIBS" | |
9634 | ||
9635 | fi | |
9636 | ||
9637 | ||
9638 | ## Note: when using cpp in s/aix4.2.h, this definition depended on | |
9639 | ## HAVE_LIBPTHREADS. That was not defined earlier in configure when | |
9640 | ## the system file was sourced. Hence the value of LIBS_SYSTEM | |
9641 | ## added to LIBS in configure would never contain the pthreads part, | |
9642 | ## but the value used in Makefiles might. FIXME? | |
9643 | ## | |
9644 | ## -lpthreads seems to be necessary for Xlib in X11R6, and should | |
9645 | ## be harmless on older versions of X where it happens to exist. | |
9646 | test "$opsys" = "aix4-2" && \ | |
9647 | test $ac_cv_lib_pthreads_cma_open = yes && \ | |
9648 | LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads" | |
9649 | ||
9650 | ||
9651 | case ${host_os} in | |
9652 | aix*) | |
9653 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5 | |
9654 | $as_echo_n "checking for -bbigtoc option... " >&6; } | |
d6974efa | 9655 | if ${gdb_cv_bigtoc+:} false; then : |
067d23c9 KY |
9656 | $as_echo_n "(cached) " >&6 |
9657 | else | |
9658 | ||
9659 | case $GCC in | |
9660 | yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;; | |
9661 | *) gdb_cv_bigtoc=-bbigtoc ;; | |
9662 | esac | |
9663 | ||
9664 | LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc | |
9665 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9666 | /* end confdefs.h. */ | |
9667 | ||
9668 | int | |
9669 | main () | |
9670 | { | |
9671 | int i; | |
9672 | ; | |
9673 | return 0; | |
9674 | } | |
9675 | _ACEOF | |
9676 | if ac_fn_c_try_link "$LINENO"; then : | |
9677 | ||
9678 | else | |
9679 | gdb_cv_bigtoc= | |
9680 | fi | |
9681 | rm -f core conftest.err conftest.$ac_objext \ | |
9682 | conftest$ac_exeext conftest.$ac_ext | |
9683 | ||
9684 | fi | |
9685 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5 | |
9686 | $as_echo "$gdb_cv_bigtoc" >&6; } | |
9687 | ;; | |
9688 | esac | |
9689 | ||
9690 | # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets | |
9691 | # used for the tests that follow. We set them back to REAL_CFLAGS and | |
9692 | # REAL_CPPFLAGS later on. | |
9693 | ||
9694 | REAL_CFLAGS="$CFLAGS" | |
9695 | REAL_CPPFLAGS="$CPPFLAGS" | |
9696 | ||
9697 | if test "${HAVE_X11}" = "yes"; then | |
9698 | DEFS="$C_SWITCH_X_SITE $DEFS" | |
9699 | LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE" | |
9700 | LIBS="-lX11 $LIBS" | |
9701 | CFLAGS="$C_SWITCH_X_SITE $CFLAGS" | |
9702 | CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS" | |
9703 | ||
9704 | # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests. | |
9705 | # This is handled by LD_SWITCH_X_SITE_AUX during the real build, | |
9706 | # but it's more convenient here to set LD_RUN_PATH | |
9707 | # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX. | |
9708 | if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then | |
9709 | LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH | |
9710 | export LD_RUN_PATH | |
9711 | fi | |
9712 | ||
9713 | if test "${opsys}" = "gnu-linux"; then | |
9714 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5 | |
9715 | $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; } | |
9716 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9717 | /* end confdefs.h. */ | |
9718 | ||
9719 | int | |
9720 | main () | |
9721 | { | |
9722 | XOpenDisplay ("foo"); | |
9723 | ; | |
9724 | return 0; | |
9725 | } | |
9726 | _ACEOF | |
9727 | if ac_fn_c_try_link "$LINENO"; then : | |
9728 | xlinux_first_failure=no | |
9729 | else | |
9730 | xlinux_first_failure=yes | |
9731 | fi | |
9732 | rm -f core conftest.err conftest.$ac_objext \ | |
9733 | conftest$ac_exeext conftest.$ac_ext | |
9734 | if test "${xlinux_first_failure}" = "yes"; then | |
9735 | OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE" | |
9736 | OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE" | |
9737 | OLD_CPPFLAGS="$CPPFLAGS" | |
9738 | OLD_LIBS="$LIBS" | |
9739 | LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout" | |
9740 | C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout" | |
9741 | CPPFLAGS="$CPPFLAGS -b i486-linuxaout" | |
9742 | LIBS="$LIBS -b i486-linuxaout" | |
9743 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9744 | /* end confdefs.h. */ | |
9745 | ||
9746 | int | |
9747 | main () | |
9748 | { | |
9749 | XOpenDisplay ("foo"); | |
9750 | ; | |
9751 | return 0; | |
9752 | } | |
9753 | _ACEOF | |
9754 | if ac_fn_c_try_link "$LINENO"; then : | |
9755 | xlinux_second_failure=no | |
9756 | else | |
9757 | xlinux_second_failure=yes | |
9758 | fi | |
9759 | rm -f core conftest.err conftest.$ac_objext \ | |
9760 | conftest$ac_exeext conftest.$ac_ext | |
9761 | if test "${xlinux_second_failure}" = "yes"; then | |
9762 | # If we get the same failure with -b, there is no use adding -b. | |
9763 | # So take it out. This plays safe. | |
9764 | LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE" | |
9765 | C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE" | |
9766 | CPPFLAGS="$OLD_CPPFLAGS" | |
9767 | LIBS="$OLD_LIBS" | |
9768 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
9769 | $as_echo "no" >&6; } | |
9770 | else | |
9771 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
9772 | $as_echo "yes" >&6; } | |
9773 | fi | |
9774 | else | |
9775 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
9776 | $as_echo "no" >&6; } | |
9777 | fi | |
9778 | fi | |
9779 | ||
9780 | # Reportedly, some broken Solaris systems have XKBlib.h but are missing | |
9781 | # header files included from there. | |
9782 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5 | |
9783 | $as_echo_n "checking for Xkb... " >&6; } | |
9784 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9785 | /* end confdefs.h. */ | |
9786 | #include <X11/Xlib.h> | |
9787 | #include <X11/XKBlib.h> | |
9788 | int | |
9789 | main () | |
9790 | { | |
9791 | XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd); | |
9792 | ; | |
9793 | return 0; | |
9794 | } | |
9795 | _ACEOF | |
9796 | if ac_fn_c_try_link "$LINENO"; then : | |
9797 | emacs_xkb=yes | |
9798 | else | |
9799 | emacs_xkb=no | |
9800 | fi | |
9801 | rm -f core conftest.err conftest.$ac_objext \ | |
9802 | conftest$ac_exeext conftest.$ac_ext | |
9803 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5 | |
9804 | $as_echo "$emacs_xkb" >&6; } | |
9805 | if test $emacs_xkb = yes; then | |
9806 | ||
9807 | $as_echo "#define HAVE_XKBGETKEYBOARD 1" >>confdefs.h | |
9808 | ||
9809 | fi | |
9810 | ||
9811 | for ac_func in XrmSetDatabase XScreenResourceString \ | |
9812 | XScreenNumberOfScreen XSetWMProtocols | |
9813 | do : | |
9814 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9815 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
2018939f | 9816 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
067d23c9 KY |
9817 | cat >>confdefs.h <<_ACEOF |
9818 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
9819 | _ACEOF | |
9820 | ||
9821 | fi | |
9822 | done | |
9823 | ||
9824 | fi | |
9825 | ||
9826 | if test "${window_system}" = "x11"; then | |
9827 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5 | |
9828 | $as_echo_n "checking X11 version 6... " >&6; } | |
d6974efa | 9829 | if ${emacs_cv_x11_version_6+:} false; then : |
067d23c9 KY |
9830 | $as_echo_n "(cached) " >&6 |
9831 | else | |
9832 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9833 | /* end confdefs.h. */ | |
9834 | #include <X11/Xlib.h> | |
9835 | int | |
9836 | main () | |
9837 | { | |
9838 | #if XlibSpecificationRelease < 6 | |
9839 | fail; | |
9840 | #endif | |
9841 | ||
9842 | ; | |
9843 | return 0; | |
9844 | } | |
9845 | _ACEOF | |
9846 | if ac_fn_c_try_link "$LINENO"; then : | |
9847 | emacs_cv_x11_version_6=yes | |
9848 | else | |
9849 | emacs_cv_x11_version_6=no | |
9850 | fi | |
9851 | rm -f core conftest.err conftest.$ac_objext \ | |
9852 | conftest$ac_exeext conftest.$ac_ext | |
9853 | fi | |
9854 | ||
9855 | if test $emacs_cv_x11_version_6 = yes; then | |
9856 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5 | |
9857 | $as_echo "6 or newer" >&6; } | |
9858 | ||
9859 | $as_echo "#define HAVE_X11R6 1" >>confdefs.h | |
9860 | ||
9861 | ||
9862 | $as_echo "#define HAVE_X_I18N 1" >>confdefs.h | |
9863 | ||
9864 | ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style | |
9865 | ## XIM support. | |
9866 | case "$opsys" in | |
9867 | sol2-*) : ;; | |
9868 | *) | |
9869 | $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h | |
9870 | ||
9871 | ;; | |
9872 | esac | |
9873 | else | |
9874 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5 | |
9875 | $as_echo "before 6" >&6; } | |
9876 | fi | |
9877 | fi | |
9878 | ||
9879 | ||
9880 | ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified. | |
9881 | HAVE_RSVG=no | |
9882 | if test "${HAVE_X11}" = "yes" || test "${NS_IMPL_GNUSTEP}" = "yes"; then | |
9883 | if test "${with_rsvg}" != "no"; then | |
9884 | RSVG_REQUIRED=2.11.0 | |
9885 | RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED" | |
9886 | ||
9887 | ||
9888 | succeeded=no | |
9889 | ||
9890 | # Extract the first word of "pkg-config", so it can be a program name with args. | |
9891 | set dummy pkg-config; ac_word=$2 | |
9892 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
9893 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 9894 | if ${ac_cv_path_PKG_CONFIG+:} false; then : |
067d23c9 KY |
9895 | $as_echo_n "(cached) " >&6 |
9896 | else | |
9897 | case $PKG_CONFIG in | |
9898 | [\\/]* | ?:[\\/]*) | |
9899 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. | |
9900 | ;; | |
9901 | *) | |
9902 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
9903 | for as_dir in $PATH | |
9904 | do | |
9905 | IFS=$as_save_IFS | |
9906 | test -z "$as_dir" && as_dir=. | |
9907 | for ac_exec_ext in '' $ac_executable_extensions; do | |
9908 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
9909 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" | |
9910 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
9911 | break 2 | |
9912 | fi | |
9913 | done | |
9914 | done | |
9915 | IFS=$as_save_IFS | |
9916 | ||
9917 | test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no" | |
9918 | ;; | |
9919 | esac | |
9920 | fi | |
9921 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG | |
9922 | if test -n "$PKG_CONFIG"; then | |
9923 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 | |
9924 | $as_echo "$PKG_CONFIG" >&6; } | |
9925 | else | |
9926 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
9927 | $as_echo "no" >&6; } | |
9928 | fi | |
9929 | ||
9930 | ||
9931 | ||
9932 | if test "$PKG_CONFIG" = "no" ; then | |
9933 | : | |
9934 | else | |
9935 | PKG_CONFIG_MIN_VERSION=0.9.0 | |
9936 | if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then | |
9937 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5 | |
9938 | $as_echo_n "checking for $RSVG_MODULE... " >&6; } | |
9939 | ||
9940 | if $PKG_CONFIG --exists "$RSVG_MODULE" 2>&5; then | |
9941 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
9942 | $as_echo "yes" >&6; } | |
9943 | succeeded=yes | |
9944 | ||
9945 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking RSVG_CFLAGS" >&5 | |
9946 | $as_echo_n "checking RSVG_CFLAGS... " >&6; } | |
9947 | RSVG_CFLAGS=`$PKG_CONFIG --cflags "$RSVG_MODULE"|sed -e 's,///*,/,g'` | |
9948 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RSVG_CFLAGS" >&5 | |
9949 | $as_echo "$RSVG_CFLAGS" >&6; } | |
9950 | ||
9951 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking RSVG_LIBS" >&5 | |
9952 | $as_echo_n "checking RSVG_LIBS... " >&6; } | |
9953 | RSVG_LIBS=`$PKG_CONFIG --libs "$RSVG_MODULE"|sed -e 's,///*,/,g'` | |
9954 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RSVG_LIBS" >&5 | |
9955 | $as_echo "$RSVG_LIBS" >&6; } | |
9956 | else | |
9957 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
9958 | $as_echo "no" >&6; } | |
9959 | RSVG_CFLAGS="" | |
9960 | RSVG_LIBS="" | |
9961 | ## If we have a custom action on failure, don't print errors, but | |
9962 | ## do set a variable so people can do so. | |
9963 | RSVG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$RSVG_MODULE"` | |
9964 | ||
9965 | fi | |
9966 | ||
9967 | ||
9968 | ||
9969 | else | |
9970 | echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer." | |
9971 | echo "*** See http://www.freedesktop.org/software/pkgconfig" | |
9972 | fi | |
9973 | fi | |
9974 | ||
9975 | if test $succeeded = yes; then | |
9976 | HAVE_RSVG=yes | |
9977 | else | |
9978 | : | |
9979 | fi | |
9980 | ||
9981 | ||
9982 | ||
9983 | ||
9984 | if test $HAVE_RSVG = yes; then | |
9985 | ||
9986 | $as_echo "#define HAVE_RSVG 1" >>confdefs.h | |
9987 | ||
9988 | CFLAGS="$CFLAGS $RSVG_CFLAGS" | |
9989 | LIBS="$RSVG_LIBS $LIBS" | |
9990 | fi | |
9991 | fi | |
9992 | fi | |
9993 | ||
9994 | HAVE_IMAGEMAGICK=no | |
9995 | if test "${HAVE_X11}" = "yes"; then | |
9996 | if test "${with_imagemagick}" != "no"; then | |
9997 | IMAGEMAGICK_MODULE="Wand" | |
9998 | ||
9999 | succeeded=no | |
10000 | ||
10001 | # Extract the first word of "pkg-config", so it can be a program name with args. | |
10002 | set dummy pkg-config; ac_word=$2 | |
10003 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
10004 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 10005 | if ${ac_cv_path_PKG_CONFIG+:} false; then : |
067d23c9 KY |
10006 | $as_echo_n "(cached) " >&6 |
10007 | else | |
10008 | case $PKG_CONFIG in | |
10009 | [\\/]* | ?:[\\/]*) | |
10010 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. | |
10011 | ;; | |
10012 | *) | |
10013 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
10014 | for as_dir in $PATH | |
10015 | do | |
10016 | IFS=$as_save_IFS | |
10017 | test -z "$as_dir" && as_dir=. | |
10018 | for ac_exec_ext in '' $ac_executable_extensions; do | |
10019 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
10020 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" | |
10021 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
10022 | break 2 | |
10023 | fi | |
10024 | done | |
10025 | done | |
10026 | IFS=$as_save_IFS | |
10027 | ||
10028 | test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no" | |
10029 | ;; | |
10030 | esac | |
10031 | fi | |
10032 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG | |
10033 | if test -n "$PKG_CONFIG"; then | |
10034 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 | |
10035 | $as_echo "$PKG_CONFIG" >&6; } | |
10036 | else | |
10037 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
10038 | $as_echo "no" >&6; } | |
10039 | fi | |
10040 | ||
10041 | ||
10042 | ||
10043 | if test "$PKG_CONFIG" = "no" ; then | |
10044 | : | |
10045 | else | |
10046 | PKG_CONFIG_MIN_VERSION=0.9.0 | |
10047 | if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then | |
10048 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5 | |
10049 | $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; } | |
10050 | ||
10051 | if $PKG_CONFIG --exists "$IMAGEMAGICK_MODULE" 2>&5; then | |
10052 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
10053 | $as_echo "yes" >&6; } | |
10054 | succeeded=yes | |
10055 | ||
10056 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking IMAGEMAGICK_CFLAGS" >&5 | |
10057 | $as_echo_n "checking IMAGEMAGICK_CFLAGS... " >&6; } | |
10058 | IMAGEMAGICK_CFLAGS=`$PKG_CONFIG --cflags "$IMAGEMAGICK_MODULE"|sed -e 's,///*,/,g'` | |
10059 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $IMAGEMAGICK_CFLAGS" >&5 | |
10060 | $as_echo "$IMAGEMAGICK_CFLAGS" >&6; } | |
10061 | ||
10062 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking IMAGEMAGICK_LIBS" >&5 | |
10063 | $as_echo_n "checking IMAGEMAGICK_LIBS... " >&6; } | |
10064 | IMAGEMAGICK_LIBS=`$PKG_CONFIG --libs "$IMAGEMAGICK_MODULE"|sed -e 's,///*,/,g'` | |
10065 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $IMAGEMAGICK_LIBS" >&5 | |
10066 | $as_echo "$IMAGEMAGICK_LIBS" >&6; } | |
10067 | else | |
10068 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
10069 | $as_echo "no" >&6; } | |
10070 | IMAGEMAGICK_CFLAGS="" | |
10071 | IMAGEMAGICK_LIBS="" | |
10072 | ## If we have a custom action on failure, don't print errors, but | |
10073 | ## do set a variable so people can do so. | |
10074 | IMAGEMAGICK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$IMAGEMAGICK_MODULE"` | |
10075 | ||
10076 | fi | |
10077 | ||
10078 | ||
10079 | ||
10080 | else | |
10081 | echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer." | |
10082 | echo "*** See http://www.freedesktop.org/software/pkgconfig" | |
10083 | fi | |
10084 | fi | |
10085 | ||
10086 | if test $succeeded = yes; then | |
10087 | HAVE_IMAGEMAGICK=yes | |
10088 | else | |
10089 | : | |
10090 | fi | |
10091 | ||
10092 | ||
10093 | ||
10094 | ||
10095 | if test $HAVE_IMAGEMAGICK = yes; then | |
10096 | ||
10097 | $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h | |
10098 | ||
10099 | CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS" | |
10100 | LIBS="$IMAGEMAGICK_LIBS $LIBS" | |
10101 | for ac_func in MagickExportImagePixels | |
10102 | do : | |
10103 | ac_fn_c_check_func "$LINENO" "MagickExportImagePixels" "ac_cv_func_MagickExportImagePixels" | |
d6974efa | 10104 | if test "x$ac_cv_func_MagickExportImagePixels" = xyes; then : |
067d23c9 KY |
10105 | cat >>confdefs.h <<_ACEOF |
10106 | #define HAVE_MAGICKEXPORTIMAGEPIXELS 1 | |
10107 | _ACEOF | |
10108 | ||
10109 | fi | |
10110 | done | |
10111 | ||
10112 | fi | |
10113 | fi | |
10114 | fi | |
10115 | ||
10116 | ||
10117 | HAVE_GTK=no | |
10118 | if test "${with_gtk3}" = "yes"; then | |
10119 | GLIB_REQUIRED=2.6 | |
10120 | GTK_REQUIRED=2.90 | |
10121 | GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED" | |
10122 | ||
10123 | ||
10124 | succeeded=no | |
10125 | ||
10126 | # Extract the first word of "pkg-config", so it can be a program name with args. | |
10127 | set dummy pkg-config; ac_word=$2 | |
10128 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
10129 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 10130 | if ${ac_cv_path_PKG_CONFIG+:} false; then : |
067d23c9 KY |
10131 | $as_echo_n "(cached) " >&6 |
10132 | else | |
10133 | case $PKG_CONFIG in | |
10134 | [\\/]* | ?:[\\/]*) | |
10135 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. | |
10136 | ;; | |
10137 | *) | |
10138 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
10139 | for as_dir in $PATH | |
10140 | do | |
10141 | IFS=$as_save_IFS | |
10142 | test -z "$as_dir" && as_dir=. | |
10143 | for ac_exec_ext in '' $ac_executable_extensions; do | |
10144 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
10145 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" | |
10146 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
10147 | break 2 | |
10148 | fi | |
10149 | done | |
10150 | done | |
10151 | IFS=$as_save_IFS | |
10152 | ||
10153 | test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no" | |
10154 | ;; | |
10155 | esac | |
10156 | fi | |
10157 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG | |
10158 | if test -n "$PKG_CONFIG"; then | |
10159 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 | |
10160 | $as_echo "$PKG_CONFIG" >&6; } | |
10161 | else | |
10162 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
10163 | $as_echo "no" >&6; } | |
10164 | fi | |
10165 | ||
10166 | ||
10167 | ||
10168 | if test "$PKG_CONFIG" = "no" ; then | |
10169 | pkg_check_gtk=no | |
10170 | else | |
10171 | PKG_CONFIG_MIN_VERSION=0.9.0 | |
10172 | if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then | |
10173 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5 | |
10174 | $as_echo_n "checking for $GTK_MODULES... " >&6; } | |
10175 | ||
10176 | if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5; then | |
10177 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
10178 | $as_echo "yes" >&6; } | |
10179 | succeeded=yes | |
10180 | ||
10181 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_CFLAGS" >&5 | |
10182 | $as_echo_n "checking GTK_CFLAGS... " >&6; } | |
10183 | GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"|sed -e 's,///*,/,g'` | |
10184 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_CFLAGS" >&5 | |
10185 | $as_echo "$GTK_CFLAGS" >&6; } | |
10186 | ||
10187 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_LIBS" >&5 | |
10188 | $as_echo_n "checking GTK_LIBS... " >&6; } | |
10189 | GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"|sed -e 's,///*,/,g'` | |
10190 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_LIBS" >&5 | |
10191 | $as_echo "$GTK_LIBS" >&6; } | |
10192 | else | |
10193 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
10194 | $as_echo "no" >&6; } | |
10195 | GTK_CFLAGS="" | |
10196 | GTK_LIBS="" | |
10197 | ## If we have a custom action on failure, don't print errors, but | |
10198 | ## do set a variable so people can do so. | |
10199 | GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"` | |
10200 | ||
10201 | fi | |
10202 | ||
10203 | ||
10204 | ||
10205 | else | |
10206 | echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer." | |
10207 | echo "*** See http://www.freedesktop.org/software/pkgconfig" | |
10208 | fi | |
10209 | fi | |
10210 | ||
10211 | if test $succeeded = yes; then | |
10212 | pkg_check_gtk=yes | |
10213 | else | |
10214 | pkg_check_gtk=no | |
10215 | fi | |
10216 | ||
10217 | if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then | |
2018939f | 10218 | as_fn_error $? "$GTK_PKG_ERRORS" "$LINENO" 5 |
067d23c9 KY |
10219 | fi |
10220 | fi | |
10221 | ||
10222 | if test "$pkg_check_gtk" != "yes"; then | |
10223 | HAVE_GTK=no | |
10224 | if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then | |
10225 | GLIB_REQUIRED=2.6 | |
10226 | GTK_REQUIRED=2.6 | |
10227 | GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED" | |
10228 | ||
10229 | ||
10230 | succeeded=no | |
10231 | ||
10232 | # Extract the first word of "pkg-config", so it can be a program name with args. | |
10233 | set dummy pkg-config; ac_word=$2 | |
10234 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
10235 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 10236 | if ${ac_cv_path_PKG_CONFIG+:} false; then : |
067d23c9 KY |
10237 | $as_echo_n "(cached) " >&6 |
10238 | else | |
10239 | case $PKG_CONFIG in | |
10240 | [\\/]* | ?:[\\/]*) | |
10241 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. | |
10242 | ;; | |
10243 | *) | |
10244 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
10245 | for as_dir in $PATH | |
10246 | do | |
10247 | IFS=$as_save_IFS | |
10248 | test -z "$as_dir" && as_dir=. | |
10249 | for ac_exec_ext in '' $ac_executable_extensions; do | |
10250 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
10251 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" | |
10252 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
10253 | break 2 | |
10254 | fi | |
10255 | done | |
10256 | done | |
10257 | IFS=$as_save_IFS | |
10258 | ||
10259 | test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no" | |
10260 | ;; | |
10261 | esac | |
10262 | fi | |
10263 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG | |
10264 | if test -n "$PKG_CONFIG"; then | |
10265 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 | |
10266 | $as_echo "$PKG_CONFIG" >&6; } | |
10267 | else | |
10268 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
10269 | $as_echo "no" >&6; } | |
10270 | fi | |
10271 | ||
10272 | ||
10273 | ||
10274 | if test "$PKG_CONFIG" = "no" ; then | |
10275 | pkg_check_gtk=no | |
10276 | else | |
10277 | PKG_CONFIG_MIN_VERSION=0.9.0 | |
10278 | if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then | |
10279 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5 | |
10280 | $as_echo_n "checking for $GTK_MODULES... " >&6; } | |
10281 | ||
10282 | if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5; then | |
10283 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
10284 | $as_echo "yes" >&6; } | |
10285 | succeeded=yes | |
10286 | ||
10287 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_CFLAGS" >&5 | |
10288 | $as_echo_n "checking GTK_CFLAGS... " >&6; } | |
10289 | GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"|sed -e 's,///*,/,g'` | |
10290 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_CFLAGS" >&5 | |
10291 | $as_echo "$GTK_CFLAGS" >&6; } | |
10292 | ||
10293 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_LIBS" >&5 | |
10294 | $as_echo_n "checking GTK_LIBS... " >&6; } | |
10295 | GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"|sed -e 's,///*,/,g'` | |
10296 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_LIBS" >&5 | |
10297 | $as_echo "$GTK_LIBS" >&6; } | |
10298 | else | |
10299 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
10300 | $as_echo "no" >&6; } | |
10301 | GTK_CFLAGS="" | |
10302 | GTK_LIBS="" | |
10303 | ## If we have a custom action on failure, don't print errors, but | |
10304 | ## do set a variable so people can do so. | |
10305 | GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"` | |
10306 | ||
10307 | fi | |
10308 | ||
10309 | ||
10310 | ||
10311 | else | |
10312 | echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer." | |
10313 | echo "*** See http://www.freedesktop.org/software/pkgconfig" | |
10314 | fi | |
10315 | fi | |
10316 | ||
10317 | if test $succeeded = yes; then | |
10318 | pkg_check_gtk=yes | |
10319 | else | |
10320 | pkg_check_gtk=no | |
10321 | fi | |
10322 | ||
10323 | if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then | |
2018939f | 10324 | as_fn_error $? "$GTK_PKG_ERRORS" "$LINENO" 5 |
067d23c9 KY |
10325 | fi |
10326 | fi | |
10327 | fi | |
10328 | ||
10329 | GTK_OBJ= | |
10330 | if test x"$pkg_check_gtk" = xyes; then | |
10331 | ||
10332 | ||
10333 | ||
10334 | C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS" | |
10335 | CFLAGS="$CFLAGS $GTK_CFLAGS" | |
10336 | LIBS="$GTK_LIBS $LIBS" | |
10337 | GTK_COMPILES=no | |
10338 | for ac_func in gtk_main | |
10339 | do : | |
10340 | ac_fn_c_check_func "$LINENO" "gtk_main" "ac_cv_func_gtk_main" | |
d6974efa | 10341 | if test "x$ac_cv_func_gtk_main" = xyes; then : |
067d23c9 KY |
10342 | cat >>confdefs.h <<_ACEOF |
10343 | #define HAVE_GTK_MAIN 1 | |
10344 | _ACEOF | |
10345 | GTK_COMPILES=yes | |
10346 | fi | |
10347 | done | |
10348 | ||
10349 | if test "${GTK_COMPILES}" != "yes"; then | |
10350 | if test "$USE_X_TOOLKIT" != "maybe"; then | |
d6974efa | 10351 | as_fn_error $? "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5; |
067d23c9 KY |
10352 | fi |
10353 | else | |
10354 | HAVE_GTK=yes | |
10355 | ||
10356 | $as_echo "#define USE_GTK 1" >>confdefs.h | |
10357 | ||
10358 | GTK_OBJ=gtkutil.o | |
10359 | USE_X_TOOLKIT=none | |
10360 | if $PKG_CONFIG --atleast-version=2.10 gtk+-2.0; then | |
10361 | : | |
10362 | else | |
10363 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with | |
10364 | closing open displays. This is no problem if you just use | |
10365 | one display, but if you use more than one and close one of them | |
10366 | Emacs may crash." >&5 | |
10367 | $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with | |
10368 | closing open displays. This is no problem if you just use | |
10369 | one display, but if you use more than one and close one of them | |
10370 | Emacs may crash." >&2;} | |
10371 | sleep 3 | |
10372 | fi | |
10373 | fi | |
10374 | ||
10375 | fi | |
10376 | ||
10377 | ||
10378 | ||
10379 | if test "${HAVE_GTK}" = "yes"; then | |
10380 | ||
10381 | if test "$with_toolkit_scroll_bars" != no; then | |
10382 | with_toolkit_scroll_bars=yes | |
10383 | fi | |
10384 | ||
10385 | HAVE_GTK_FILE_SELECTION=no | |
10386 | ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default | |
10387 | #include <gtk/gtk.h> | |
10388 | " | |
d6974efa | 10389 | if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = xyes; then : |
067d23c9 KY |
10390 | HAVE_GTK_FILE_SELECTION=yes |
10391 | else | |
10392 | HAVE_GTK_FILE_SELECTION=no | |
10393 | fi | |
10394 | ||
10395 | if test "$HAVE_GTK_FILE_SELECTION" = yes; then | |
10396 | for ac_func in gtk_file_selection_new | |
10397 | do : | |
10398 | ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new" | |
d6974efa | 10399 | if test "x$ac_cv_func_gtk_file_selection_new" = xyes; then : |
067d23c9 KY |
10400 | cat >>confdefs.h <<_ACEOF |
10401 | #define HAVE_GTK_FILE_SELECTION_NEW 1 | |
10402 | _ACEOF | |
10403 | ||
10404 | fi | |
10405 | done | |
10406 | ||
10407 | fi | |
10408 | ||
10409 | HAVE_GTK_AND_PTHREAD=no | |
10410 | for ac_header in pthread.h | |
10411 | do : | |
10412 | ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default" | |
d6974efa | 10413 | if test "x$ac_cv_header_pthread_h" = xyes; then : |
067d23c9 KY |
10414 | cat >>confdefs.h <<_ACEOF |
10415 | #define HAVE_PTHREAD_H 1 | |
10416 | _ACEOF | |
10417 | ||
10418 | fi | |
10419 | ||
10420 | done | |
10421 | ||
10422 | if test "$ac_cv_header_pthread_h"; then | |
10423 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_self in -lpthread" >&5 | |
10424 | $as_echo_n "checking for pthread_self in -lpthread... " >&6; } | |
d6974efa | 10425 | if ${ac_cv_lib_pthread_pthread_self+:} false; then : |
067d23c9 KY |
10426 | $as_echo_n "(cached) " >&6 |
10427 | else | |
10428 | ac_check_lib_save_LIBS=$LIBS | |
10429 | LIBS="-lpthread $LIBS" | |
10430 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
10431 | /* end confdefs.h. */ | |
10432 | ||
10433 | /* Override any GCC internal prototype to avoid an error. | |
10434 | Use char because int might match the return type of a GCC | |
10435 | builtin and then its argument prototype would still apply. */ | |
10436 | #ifdef __cplusplus | |
10437 | extern "C" | |
10438 | #endif | |
10439 | char pthread_self (); | |
10440 | int | |
10441 | main () | |
10442 | { | |
10443 | return pthread_self (); | |
10444 | ; | |
10445 | return 0; | |
10446 | } | |
10447 | _ACEOF | |
10448 | if ac_fn_c_try_link "$LINENO"; then : | |
10449 | ac_cv_lib_pthread_pthread_self=yes | |
10450 | else | |
10451 | ac_cv_lib_pthread_pthread_self=no | |
10452 | fi | |
10453 | rm -f core conftest.err conftest.$ac_objext \ | |
10454 | conftest$ac_exeext conftest.$ac_ext | |
10455 | LIBS=$ac_check_lib_save_LIBS | |
10456 | fi | |
10457 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_self" >&5 | |
10458 | $as_echo "$ac_cv_lib_pthread_pthread_self" >&6; } | |
d6974efa | 10459 | if test "x$ac_cv_lib_pthread_pthread_self" = xyes; then : |
067d23c9 KY |
10460 | HAVE_GTK_AND_PTHREAD=yes |
10461 | fi | |
10462 | ||
10463 | fi | |
10464 | if test "$HAVE_GTK_AND_PTHREAD" = yes; then | |
10465 | case "${canonical}" in | |
10466 | *-hpux*) ;; | |
10467 | *) GTK_LIBS="$GTK_LIBS -lpthread" ;; | |
10468 | esac | |
10469 | ||
10470 | $as_echo "#define HAVE_GTK_AND_PTHREAD 1" >>confdefs.h | |
10471 | ||
10472 | fi | |
10473 | ||
10474 | for ac_func in gtk_widget_get_window gtk_widget_set_has_window \ | |
10475 | gtk_dialog_get_action_area gtk_widget_get_sensitive \ | |
10476 | gtk_widget_get_mapped gtk_adjustment_get_page_size \ | |
10477 | gtk_orientable_set_orientation | |
10478 | do : | |
10479 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
10480 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
2018939f | 10481 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
067d23c9 KY |
10482 | cat >>confdefs.h <<_ACEOF |
10483 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
10484 | _ACEOF | |
10485 | ||
10486 | fi | |
10487 | done | |
10488 | ||
10489 | ||
10490 | fi | |
10491 | ||
10492 | HAVE_DBUS=no | |
10493 | DBUS_OBJ= | |
10494 | if test "${with_dbus}" = "yes"; then | |
10495 | ||
10496 | succeeded=no | |
10497 | ||
10498 | # Extract the first word of "pkg-config", so it can be a program name with args. | |
10499 | set dummy pkg-config; ac_word=$2 | |
10500 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
10501 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 10502 | if ${ac_cv_path_PKG_CONFIG+:} false; then : |
067d23c9 KY |
10503 | $as_echo_n "(cached) " >&6 |
10504 | else | |
10505 | case $PKG_CONFIG in | |
10506 | [\\/]* | ?:[\\/]*) | |
10507 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. | |
10508 | ;; | |
10509 | *) | |
10510 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
10511 | for as_dir in $PATH | |
10512 | do | |
10513 | IFS=$as_save_IFS | |
10514 | test -z "$as_dir" && as_dir=. | |
10515 | for ac_exec_ext in '' $ac_executable_extensions; do | |
10516 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
10517 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" | |
10518 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
10519 | break 2 | |
10520 | fi | |
10521 | done | |
10522 | done | |
10523 | IFS=$as_save_IFS | |
10524 | ||
10525 | test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no" | |
10526 | ;; | |
10527 | esac | |
10528 | fi | |
10529 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG | |
10530 | if test -n "$PKG_CONFIG"; then | |
10531 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 | |
10532 | $as_echo "$PKG_CONFIG" >&6; } | |
10533 | else | |
10534 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
10535 | $as_echo "no" >&6; } | |
10536 | fi | |
10537 | ||
10538 | ||
10539 | ||
10540 | if test "$PKG_CONFIG" = "no" ; then | |
10541 | HAVE_DBUS=no | |
10542 | else | |
10543 | PKG_CONFIG_MIN_VERSION=0.9.0 | |
10544 | if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then | |
10545 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5 | |
10546 | $as_echo_n "checking for dbus-1 >= 1.0... " >&6; } | |
10547 | ||
10548 | if $PKG_CONFIG --exists "dbus-1 >= 1.0" 2>&5; then | |
10549 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
10550 | $as_echo "yes" >&6; } | |
10551 | succeeded=yes | |
10552 | ||
10553 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking DBUS_CFLAGS" >&5 | |
10554 | $as_echo_n "checking DBUS_CFLAGS... " >&6; } | |
10555 | DBUS_CFLAGS=`$PKG_CONFIG --cflags "dbus-1 >= 1.0"|sed -e 's,///*,/,g'` | |
10556 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBUS_CFLAGS" >&5 | |
10557 | $as_echo "$DBUS_CFLAGS" >&6; } | |
10558 | ||
10559 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking DBUS_LIBS" >&5 | |
10560 | $as_echo_n "checking DBUS_LIBS... " >&6; } | |
10561 | DBUS_LIBS=`$PKG_CONFIG --libs "dbus-1 >= 1.0"|sed -e 's,///*,/,g'` | |
10562 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBUS_LIBS" >&5 | |
10563 | $as_echo "$DBUS_LIBS" >&6; } | |
10564 | else | |
10565 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
10566 | $as_echo "no" >&6; } | |
10567 | DBUS_CFLAGS="" | |
10568 | DBUS_LIBS="" | |
10569 | ## If we have a custom action on failure, don't print errors, but | |
10570 | ## do set a variable so people can do so. | |
10571 | DBUS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "dbus-1 >= 1.0"` | |
10572 | ||
10573 | fi | |
10574 | ||
10575 | ||
10576 | ||
10577 | else | |
10578 | echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer." | |
10579 | echo "*** See http://www.freedesktop.org/software/pkgconfig" | |
10580 | fi | |
10581 | fi | |
10582 | ||
10583 | if test $succeeded = yes; then | |
10584 | HAVE_DBUS=yes | |
10585 | else | |
10586 | HAVE_DBUS=no | |
10587 | fi | |
10588 | ||
10589 | if test "$HAVE_DBUS" = yes; then | |
10590 | LIBS="$LIBS $DBUS_LIBS" | |
10591 | ||
10592 | $as_echo "#define HAVE_DBUS 1" >>confdefs.h | |
10593 | ||
10594 | for ac_func in dbus_watch_get_unix_fd | |
10595 | do : | |
10596 | ac_fn_c_check_func "$LINENO" "dbus_watch_get_unix_fd" "ac_cv_func_dbus_watch_get_unix_fd" | |
d6974efa | 10597 | if test "x$ac_cv_func_dbus_watch_get_unix_fd" = xyes; then : |
067d23c9 KY |
10598 | cat >>confdefs.h <<_ACEOF |
10599 | #define HAVE_DBUS_WATCH_GET_UNIX_FD 1 | |
10600 | _ACEOF | |
10601 | ||
10602 | fi | |
10603 | done | |
10604 | ||
10605 | DBUS_OBJ=dbusbind.o | |
10606 | fi | |
10607 | fi | |
10608 | ||
10609 | ||
10610 | HAVE_GCONF=no | |
10611 | if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then | |
10612 | ||
10613 | succeeded=no | |
10614 | ||
10615 | # Extract the first word of "pkg-config", so it can be a program name with args. | |
10616 | set dummy pkg-config; ac_word=$2 | |
10617 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
10618 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 10619 | if ${ac_cv_path_PKG_CONFIG+:} false; then : |
067d23c9 KY |
10620 | $as_echo_n "(cached) " >&6 |
10621 | else | |
10622 | case $PKG_CONFIG in | |
10623 | [\\/]* | ?:[\\/]*) | |
10624 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. | |
10625 | ;; | |
10626 | *) | |
10627 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
10628 | for as_dir in $PATH | |
10629 | do | |
10630 | IFS=$as_save_IFS | |
10631 | test -z "$as_dir" && as_dir=. | |
10632 | for ac_exec_ext in '' $ac_executable_extensions; do | |
10633 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
10634 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" | |
10635 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
10636 | break 2 | |
10637 | fi | |
10638 | done | |
10639 | done | |
10640 | IFS=$as_save_IFS | |
10641 | ||
10642 | test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no" | |
10643 | ;; | |
10644 | esac | |
10645 | fi | |
10646 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG | |
10647 | if test -n "$PKG_CONFIG"; then | |
10648 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 | |
10649 | $as_echo "$PKG_CONFIG" >&6; } | |
10650 | else | |
10651 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
10652 | $as_echo "no" >&6; } | |
10653 | fi | |
10654 | ||
10655 | ||
10656 | ||
10657 | if test "$PKG_CONFIG" = "no" ; then | |
10658 | HAVE_GCONF=no | |
10659 | else | |
10660 | PKG_CONFIG_MIN_VERSION=0.9.0 | |
10661 | if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then | |
10662 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5 | |
10663 | $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; } | |
10664 | ||
10665 | if $PKG_CONFIG --exists "gconf-2.0 >= 2.13" 2>&5; then | |
10666 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
10667 | $as_echo "yes" >&6; } | |
10668 | succeeded=yes | |
10669 | ||
10670 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking GCONF_CFLAGS" >&5 | |
10671 | $as_echo_n "checking GCONF_CFLAGS... " >&6; } | |
10672 | GCONF_CFLAGS=`$PKG_CONFIG --cflags "gconf-2.0 >= 2.13"|sed -e 's,///*,/,g'` | |
10673 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCONF_CFLAGS" >&5 | |
10674 | $as_echo "$GCONF_CFLAGS" >&6; } | |
10675 | ||
10676 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking GCONF_LIBS" >&5 | |
10677 | $as_echo_n "checking GCONF_LIBS... " >&6; } | |
10678 | GCONF_LIBS=`$PKG_CONFIG --libs "gconf-2.0 >= 2.13"|sed -e 's,///*,/,g'` | |
10679 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCONF_LIBS" >&5 | |
10680 | $as_echo "$GCONF_LIBS" >&6; } | |
10681 | else | |
10682 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
10683 | $as_echo "no" >&6; } | |
10684 | GCONF_CFLAGS="" | |
10685 | GCONF_LIBS="" | |
10686 | ## If we have a custom action on failure, don't print errors, but | |
10687 | ## do set a variable so people can do so. | |
10688 | GCONF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gconf-2.0 >= 2.13"` | |
10689 | ||
10690 | fi | |
10691 | ||
10692 | ||
10693 | ||
10694 | else | |
10695 | echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer." | |
10696 | echo "*** See http://www.freedesktop.org/software/pkgconfig" | |
10697 | fi | |
10698 | fi | |
10699 | ||
10700 | if test $succeeded = yes; then | |
10701 | HAVE_GCONF=yes | |
10702 | else | |
10703 | HAVE_GCONF=no | |
10704 | fi | |
10705 | ||
10706 | if test "$HAVE_GCONF" = yes; then | |
10707 | ||
10708 | $as_echo "#define HAVE_GCONF 1" >>confdefs.h | |
10709 | ||
10710 | for ac_func in g_type_init | |
10711 | do : | |
10712 | ac_fn_c_check_func "$LINENO" "g_type_init" "ac_cv_func_g_type_init" | |
d6974efa | 10713 | if test "x$ac_cv_func_g_type_init" = xyes; then : |
067d23c9 KY |
10714 | cat >>confdefs.h <<_ACEOF |
10715 | #define HAVE_G_TYPE_INIT 1 | |
10716 | _ACEOF | |
10717 | ||
10718 | fi | |
10719 | done | |
10720 | ||
10721 | fi | |
10722 | fi | |
10723 | ||
10724 | HAVE_LIBSELINUX=no | |
10725 | LIBSELINUX_LIBS= | |
10726 | if test "${with_selinux}" = "yes"; then | |
10727 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5 | |
10728 | $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; } | |
d6974efa | 10729 | if ${ac_cv_lib_selinux_lgetfilecon+:} false; then : |
067d23c9 KY |
10730 | $as_echo_n "(cached) " >&6 |
10731 | else | |
10732 | ac_check_lib_save_LIBS=$LIBS | |
10733 | LIBS="-lselinux $LIBS" | |
10734 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
10735 | /* end confdefs.h. */ | |
10736 | ||
10737 | /* Override any GCC internal prototype to avoid an error. | |
10738 | Use char because int might match the return type of a GCC | |
10739 | builtin and then its argument prototype would still apply. */ | |
10740 | #ifdef __cplusplus | |
10741 | extern "C" | |
10742 | #endif | |
10743 | char lgetfilecon (); | |
10744 | int | |
10745 | main () | |
10746 | { | |
10747 | return lgetfilecon (); | |
10748 | ; | |
10749 | return 0; | |
10750 | } | |
10751 | _ACEOF | |
10752 | if ac_fn_c_try_link "$LINENO"; then : | |
10753 | ac_cv_lib_selinux_lgetfilecon=yes | |
10754 | else | |
10755 | ac_cv_lib_selinux_lgetfilecon=no | |
10756 | fi | |
10757 | rm -f core conftest.err conftest.$ac_objext \ | |
10758 | conftest$ac_exeext conftest.$ac_ext | |
10759 | LIBS=$ac_check_lib_save_LIBS | |
10760 | fi | |
10761 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5 | |
10762 | $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; } | |
d6974efa | 10763 | if test "x$ac_cv_lib_selinux_lgetfilecon" = xyes; then : |
067d23c9 KY |
10764 | HAVE_LIBSELINUX=yes |
10765 | else | |
10766 | HAVE_LIBSELINUX=no | |
10767 | fi | |
10768 | ||
10769 | if test "$HAVE_LIBSELINUX" = yes; then | |
10770 | ||
10771 | $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h | |
10772 | ||
10773 | LIBSELINUX_LIBS=-lselinux | |
10774 | fi | |
10775 | fi | |
10776 | ||
10777 | ||
10778 | HAVE_GNUTLS=no | |
10779 | if test "${with_gnutls}" = "yes" ; then | |
10780 | ||
10781 | succeeded=no | |
10782 | ||
10783 | # Extract the first word of "pkg-config", so it can be a program name with args. | |
10784 | set dummy pkg-config; ac_word=$2 | |
10785 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
10786 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 10787 | if ${ac_cv_path_PKG_CONFIG+:} false; then : |
067d23c9 KY |
10788 | $as_echo_n "(cached) " >&6 |
10789 | else | |
10790 | case $PKG_CONFIG in | |
10791 | [\\/]* | ?:[\\/]*) | |
10792 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. | |
10793 | ;; | |
10794 | *) | |
10795 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
10796 | for as_dir in $PATH | |
10797 | do | |
10798 | IFS=$as_save_IFS | |
10799 | test -z "$as_dir" && as_dir=. | |
10800 | for ac_exec_ext in '' $ac_executable_extensions; do | |
10801 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
10802 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" | |
10803 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
10804 | break 2 | |
10805 | fi | |
10806 | done | |
10807 | done | |
10808 | IFS=$as_save_IFS | |
10809 | ||
10810 | test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no" | |
10811 | ;; | |
10812 | esac | |
10813 | fi | |
10814 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG | |
10815 | if test -n "$PKG_CONFIG"; then | |
10816 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 | |
10817 | $as_echo "$PKG_CONFIG" >&6; } | |
10818 | else | |
10819 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
10820 | $as_echo "no" >&6; } | |
10821 | fi | |
10822 | ||
10823 | ||
10824 | ||
10825 | if test "$PKG_CONFIG" = "no" ; then | |
10826 | HAVE_GNUTLS=no | |
10827 | else | |
10828 | PKG_CONFIG_MIN_VERSION=0.9.0 | |
10829 | if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then | |
10830 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.2.4" >&5 | |
10831 | $as_echo_n "checking for gnutls >= 2.2.4... " >&6; } | |
10832 | ||
10833 | if $PKG_CONFIG --exists "gnutls >= 2.2.4" 2>&5; then | |
10834 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
10835 | $as_echo "yes" >&6; } | |
10836 | succeeded=yes | |
10837 | ||
10838 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBGNUTLS_CFLAGS" >&5 | |
10839 | $as_echo_n "checking LIBGNUTLS_CFLAGS... " >&6; } | |
10840 | LIBGNUTLS_CFLAGS=`$PKG_CONFIG --cflags "gnutls >= 2.2.4"|sed -e 's,///*,/,g'` | |
10841 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBGNUTLS_CFLAGS" >&5 | |
10842 | $as_echo "$LIBGNUTLS_CFLAGS" >&6; } | |
10843 | ||
10844 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBGNUTLS_LIBS" >&5 | |
10845 | $as_echo_n "checking LIBGNUTLS_LIBS... " >&6; } | |
10846 | LIBGNUTLS_LIBS=`$PKG_CONFIG --libs "gnutls >= 2.2.4"|sed -e 's,///*,/,g'` | |
10847 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBGNUTLS_LIBS" >&5 | |
10848 | $as_echo "$LIBGNUTLS_LIBS" >&6; } | |
10849 | else | |
10850 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
10851 | $as_echo "no" >&6; } | |
10852 | LIBGNUTLS_CFLAGS="" | |
10853 | LIBGNUTLS_LIBS="" | |
10854 | ## If we have a custom action on failure, don't print errors, but | |
10855 | ## do set a variable so people can do so. | |
10856 | LIBGNUTLS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gnutls >= 2.2.4"` | |
10857 | ||
10858 | fi | |
10859 | ||
10860 | ||
10861 | ||
10862 | else | |
10863 | echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer." | |
10864 | echo "*** See http://www.freedesktop.org/software/pkgconfig" | |
10865 | fi | |
10866 | fi | |
10867 | ||
10868 | if test $succeeded = yes; then | |
10869 | HAVE_GNUTLS=yes | |
10870 | else | |
10871 | HAVE_GNUTLS=no | |
10872 | fi | |
10873 | ||
10874 | if test "${HAVE_GNUTLS}" = "yes"; then | |
10875 | ||
10876 | $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h | |
10877 | ||
10878 | fi | |
10879 | fi | |
10880 | ||
10881 | ||
10882 | ||
10883 | HAVE_XAW3D=no | |
10884 | LUCID_LIBW= | |
10885 | if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then | |
10886 | if test "$with_xaw3d" != no; then | |
10887 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5 | |
10888 | $as_echo_n "checking for xaw3d... " >&6; } | |
d6974efa | 10889 | if ${emacs_cv_xaw3d+:} false; then : |
067d23c9 KY |
10890 | $as_echo_n "(cached) " >&6 |
10891 | else | |
10892 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
10893 | /* end confdefs.h. */ | |
10894 | ||
10895 | #include <X11/Intrinsic.h> | |
10896 | #include <X11/Xaw3d/Simple.h> | |
10897 | int | |
10898 | main () | |
10899 | { | |
10900 | ||
10901 | ; | |
10902 | return 0; | |
10903 | } | |
10904 | _ACEOF | |
10905 | if ac_fn_c_try_link "$LINENO"; then : | |
14beddf4 CY |
10906 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5 |
10907 | $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; } | |
67342916 | 10908 | if ${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+:} false; then : |
ae1362a3 AS |
10909 | $as_echo_n "(cached) " >&6 |
10910 | else | |
10911 | ac_check_lib_save_LIBS=$LIBS | |
14beddf4 | 10912 | LIBS="-lXaw3d $LIBS" |
ae1362a3 AS |
10913 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
10914 | /* end confdefs.h. */ | |
bf89cb4d | 10915 | |
ae1362a3 AS |
10916 | /* Override any GCC internal prototype to avoid an error. |
10917 | Use char because int might match the return type of a GCC | |
10918 | builtin and then its argument prototype would still apply. */ | |
10919 | #ifdef __cplusplus | |
10920 | extern "C" | |
10921 | #endif | |
14beddf4 | 10922 | char XawScrollbarSetThumb (); |
ae1362a3 AS |
10923 | int |
10924 | main () | |
10925 | { | |
14beddf4 | 10926 | return XawScrollbarSetThumb (); |
ae1362a3 AS |
10927 | ; |
10928 | return 0; | |
10929 | } | |
10930 | _ACEOF | |
10931 | if ac_fn_c_try_link "$LINENO"; then : | |
14beddf4 | 10932 | ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes |
ae1362a3 | 10933 | else |
14beddf4 | 10934 | ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no |
ae1362a3 AS |
10935 | fi |
10936 | rm -f core conftest.err conftest.$ac_objext \ | |
10937 | conftest$ac_exeext conftest.$ac_ext | |
10938 | LIBS=$ac_check_lib_save_LIBS | |
10939 | fi | |
14beddf4 CY |
10940 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5 |
10941 | $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; } | |
67342916 | 10942 | if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = xyes; then : |
067d23c9 KY |
10943 | emacs_cv_xaw3d=yes |
10944 | else | |
10945 | emacs_cv_xaw3d=no | |
10946 | fi | |
14beddf4 CY |
10947 | |
10948 | else | |
10949 | emacs_cv_xaw3d=no | |
10950 | fi | |
067d23c9 KY |
10951 | rm -f core conftest.err conftest.$ac_objext \ |
10952 | conftest$ac_exeext conftest.$ac_ext | |
10953 | fi | |
10954 | ||
10955 | else | |
10956 | emacs_cv_xaw3d=no | |
10957 | fi | |
10958 | if test $emacs_cv_xaw3d = yes; then | |
10959 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5 | |
10960 | $as_echo "yes; using Lucid toolkit" >&6; } | |
10961 | USE_X_TOOLKIT=LUCID | |
10962 | HAVE_XAW3D=yes | |
10963 | LUCID_LIBW=-lXaw3d | |
10964 | ||
10965 | $as_echo "#define HAVE_XAW3D 1" >>confdefs.h | |
10966 | ||
10967 | else | |
10968 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
10969 | $as_echo "no" >&6; } | |
10970 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5 | |
10971 | $as_echo_n "checking for libXaw... " >&6; } | |
d6974efa | 10972 | if ${emacs_cv_xaw+:} false; then : |
067d23c9 KY |
10973 | $as_echo_n "(cached) " >&6 |
10974 | else | |
10975 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
10976 | /* end confdefs.h. */ | |
10977 | ||
10978 | #include <X11/Intrinsic.h> | |
10979 | #include <X11/Xaw/Simple.h> | |
10980 | int | |
10981 | main () | |
10982 | { | |
10983 | ||
10984 | ; | |
10985 | return 0; | |
10986 | } | |
10987 | _ACEOF | |
10988 | if ac_fn_c_try_link "$LINENO"; then : | |
10989 | emacs_cv_xaw=yes | |
10990 | else | |
10991 | emacs_cv_xaw=no | |
10992 | fi | |
10993 | rm -f core conftest.err conftest.$ac_objext \ | |
10994 | conftest$ac_exeext conftest.$ac_ext | |
10995 | fi | |
10996 | ||
10997 | if test $emacs_cv_xaw = yes; then | |
10998 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5 | |
10999 | $as_echo "yes; using Lucid toolkit" >&6; } | |
11000 | USE_X_TOOLKIT=LUCID | |
11001 | LUCID_LIBW=-lXaw | |
11002 | elif test x"${USE_X_TOOLKIT}" = xLUCID; then | |
2018939f | 11003 | as_fn_error $? "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5 |
067d23c9 KY |
11004 | else |
11005 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no; do not use toolkit by default" >&5 | |
11006 | $as_echo "no; do not use toolkit by default" >&6; } | |
11007 | USE_X_TOOLKIT=none | |
11008 | fi | |
11009 | fi | |
11010 | fi | |
11011 | ||
11012 | X_TOOLKIT_TYPE=$USE_X_TOOLKIT | |
11013 | ||
11014 | LIBXTR6= | |
11015 | if test "${USE_X_TOOLKIT}" != "none"; then | |
11016 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5 | |
11017 | $as_echo_n "checking X11 toolkit version... " >&6; } | |
d6974efa | 11018 | if ${emacs_cv_x11_toolkit_version_6+:} false; then : |
067d23c9 KY |
11019 | $as_echo_n "(cached) " >&6 |
11020 | else | |
11021 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
11022 | /* end confdefs.h. */ | |
11023 | #include <X11/Intrinsic.h> | |
11024 | int | |
11025 | main () | |
11026 | { | |
11027 | #if XtSpecificationRelease < 6 | |
11028 | fail; | |
11029 | #endif | |
11030 | ||
11031 | ; | |
11032 | return 0; | |
11033 | } | |
11034 | _ACEOF | |
11035 | if ac_fn_c_try_link "$LINENO"; then : | |
11036 | emacs_cv_x11_toolkit_version_6=yes | |
11037 | else | |
11038 | emacs_cv_x11_toolkit_version_6=no | |
11039 | fi | |
11040 | rm -f core conftest.err conftest.$ac_objext \ | |
11041 | conftest$ac_exeext conftest.$ac_ext | |
11042 | fi | |
11043 | ||
11044 | HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6 | |
11045 | if test $emacs_cv_x11_toolkit_version_6 = yes; then | |
11046 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5 | |
11047 | $as_echo "6 or newer" >&6; } | |
11048 | ||
11049 | $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h | |
11050 | ||
11051 | LIBXTR6="-lSM -lICE" | |
11052 | case "$opsys" in | |
11053 | ## Use libw.a along with X11R6 Xt. | |
11054 | unixware) LIBXTR6="$LIBXTR6 -lw" ;; | |
11055 | esac | |
11056 | else | |
11057 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5 | |
11058 | $as_echo "before 6" >&6; } | |
11059 | fi | |
11060 | ||
11061 | OLDLIBS="$LIBS" | |
11062 | if test x$HAVE_X11XTR6 = xyes; then | |
11063 | LIBS="-lXt -lSM -lICE $LIBS" | |
11064 | else | |
11065 | LIBS="-lXt $LIBS" | |
11066 | fi | |
11067 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5 | |
11068 | $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; } | |
d6974efa | 11069 | if ${ac_cv_lib_Xmu_XmuConvertStandardSelection+:} false; then : |
067d23c9 KY |
11070 | $as_echo_n "(cached) " >&6 |
11071 | else | |
11072 | ac_check_lib_save_LIBS=$LIBS | |
11073 | LIBS="-lXmu $LIBS" | |
11074 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
11075 | /* end confdefs.h. */ | |
11076 | ||
11077 | /* Override any GCC internal prototype to avoid an error. | |
11078 | Use char because int might match the return type of a GCC | |
11079 | builtin and then its argument prototype would still apply. */ | |
11080 | #ifdef __cplusplus | |
11081 | extern "C" | |
11082 | #endif | |
11083 | char XmuConvertStandardSelection (); | |
11084 | int | |
11085 | main () | |
11086 | { | |
11087 | return XmuConvertStandardSelection (); | |
11088 | ; | |
11089 | return 0; | |
11090 | } | |
11091 | _ACEOF | |
11092 | if ac_fn_c_try_link "$LINENO"; then : | |
11093 | ac_cv_lib_Xmu_XmuConvertStandardSelection=yes | |
11094 | else | |
11095 | ac_cv_lib_Xmu_XmuConvertStandardSelection=no | |
11096 | fi | |
11097 | rm -f core conftest.err conftest.$ac_objext \ | |
11098 | conftest$ac_exeext conftest.$ac_ext | |
11099 | LIBS=$ac_check_lib_save_LIBS | |
11100 | fi | |
11101 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5 | |
11102 | $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; } | |
d6974efa | 11103 | if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = xyes; then : |
067d23c9 KY |
11104 | cat >>confdefs.h <<_ACEOF |
11105 | #define HAVE_LIBXMU 1 | |
11106 | _ACEOF | |
11107 | ||
11108 | LIBS="-lXmu $LIBS" | |
11109 | ||
11110 | fi | |
11111 | ||
11112 | test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS" | |
11113 | fi | |
11114 | ||
11115 | ||
11116 | LIBXMU=-lXmu | |
d6a003a8 AS |
11117 | case $opsys in |
11118 | ## These systems don't supply Xmu. | |
067d23c9 KY |
11119 | hpux* | aix4-2 ) |
11120 | test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU= | |
11121 | ;; | |
11122 | esac | |
11123 | ||
11124 | ||
11125 | # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D. | |
11126 | if test "${HAVE_X11}" = "yes"; then | |
11127 | if test "${USE_X_TOOLKIT}" != "none"; then | |
11128 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5 | |
11129 | $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; } | |
d6974efa | 11130 | if ${ac_cv_lib_Xext_XShapeQueryExtension+:} false; then : |
067d23c9 KY |
11131 | $as_echo_n "(cached) " >&6 |
11132 | else | |
11133 | ac_check_lib_save_LIBS=$LIBS | |
11134 | LIBS="-lXext $LIBS" | |
11135 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
11136 | /* end confdefs.h. */ | |
11137 | ||
11138 | /* Override any GCC internal prototype to avoid an error. | |
11139 | Use char because int might match the return type of a GCC | |
11140 | builtin and then its argument prototype would still apply. */ | |
11141 | #ifdef __cplusplus | |
11142 | extern "C" | |
11143 | #endif | |
11144 | char XShapeQueryExtension (); | |
11145 | int | |
11146 | main () | |
11147 | { | |
11148 | return XShapeQueryExtension (); | |
11149 | ; | |
11150 | return 0; | |
11151 | } | |
11152 | _ACEOF | |
11153 | if ac_fn_c_try_link "$LINENO"; then : | |
11154 | ac_cv_lib_Xext_XShapeQueryExtension=yes | |
11155 | else | |
11156 | ac_cv_lib_Xext_XShapeQueryExtension=no | |
11157 | fi | |
11158 | rm -f core conftest.err conftest.$ac_objext \ | |
11159 | conftest$ac_exeext conftest.$ac_ext | |
11160 | LIBS=$ac_check_lib_save_LIBS | |
11161 | fi | |
11162 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5 | |
11163 | $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; } | |
d6974efa | 11164 | if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = xyes; then : |
067d23c9 KY |
11165 | cat >>confdefs.h <<_ACEOF |
11166 | #define HAVE_LIBXEXT 1 | |
11167 | _ACEOF | |
11168 | ||
11169 | LIBS="-lXext $LIBS" | |
11170 | ||
11171 | fi | |
11172 | ||
11173 | fi | |
11174 | fi | |
11175 | ||
11176 | LIBXP= | |
11177 | if test "${USE_X_TOOLKIT}" = "MOTIF"; then | |
11178 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Motif version 2.1" >&5 | |
11179 | $as_echo_n "checking for Motif version 2.1... " >&6; } | |
d6974efa | 11180 | if ${emacs_cv_motif_version_2_1+:} false; then : |
067d23c9 KY |
11181 | $as_echo_n "(cached) " >&6 |
11182 | else | |
11183 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
11184 | /* end confdefs.h. */ | |
11185 | #include <Xm/Xm.h> | |
11186 | int | |
11187 | main () | |
11188 | { | |
11189 | #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1) | |
11190 | int x = 5; | |
11191 | #else | |
11192 | Motif version prior to 2.1. | |
11193 | #endif | |
11194 | ; | |
11195 | return 0; | |
11196 | } | |
11197 | _ACEOF | |
11198 | if ac_fn_c_try_compile "$LINENO"; then : | |
11199 | emacs_cv_motif_version_2_1=yes | |
11200 | else | |
11201 | emacs_cv_motif_version_2_1=no | |
11202 | fi | |
11203 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
11204 | fi | |
11205 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5 | |
11206 | $as_echo "$emacs_cv_motif_version_2_1" >&6; } | |
11207 | if test $emacs_cv_motif_version_2_1 = yes; then | |
11208 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5 | |
11209 | $as_echo_n "checking for XpCreateContext in -lXp... " >&6; } | |
d6974efa | 11210 | if ${ac_cv_lib_Xp_XpCreateContext+:} false; then : |
067d23c9 KY |
11211 | $as_echo_n "(cached) " >&6 |
11212 | else | |
11213 | ac_check_lib_save_LIBS=$LIBS | |
11214 | LIBS="-lXp $LIBS" | |
11215 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
11216 | /* end confdefs.h. */ | |
11217 | ||
11218 | /* Override any GCC internal prototype to avoid an error. | |
11219 | Use char because int might match the return type of a GCC | |
11220 | builtin and then its argument prototype would still apply. */ | |
11221 | #ifdef __cplusplus | |
11222 | extern "C" | |
11223 | #endif | |
11224 | char XpCreateContext (); | |
11225 | int | |
11226 | main () | |
11227 | { | |
11228 | return XpCreateContext (); | |
11229 | ; | |
11230 | return 0; | |
11231 | } | |
11232 | _ACEOF | |
11233 | if ac_fn_c_try_link "$LINENO"; then : | |
11234 | ac_cv_lib_Xp_XpCreateContext=yes | |
11235 | else | |
11236 | ac_cv_lib_Xp_XpCreateContext=no | |
11237 | fi | |
11238 | rm -f core conftest.err conftest.$ac_objext \ | |
11239 | conftest$ac_exeext conftest.$ac_ext | |
11240 | LIBS=$ac_check_lib_save_LIBS | |
11241 | fi | |
11242 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5 | |
11243 | $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; } | |
d6974efa | 11244 | if test "x$ac_cv_lib_Xp_XpCreateContext" = xyes; then : |
067d23c9 KY |
11245 | LIBXP=-lXp |
11246 | fi | |
11247 | ||
11248 | else | |
11249 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5 | |
11250 | $as_echo_n "checking for LessTif where some systems put it... " >&6; } | |
d6974efa | 11251 | if ${emacs_cv_lesstif+:} false; then : |
067d23c9 KY |
11252 | $as_echo_n "(cached) " >&6 |
11253 | else | |
11254 | # We put this in CFLAGS temporarily to precede other -I options | |
11255 | # that might be in CFLAGS temporarily. | |
11256 | # We put this in CPPFLAGS where it precedes the other -I options. | |
11257 | OLD_CPPFLAGS=$CPPFLAGS | |
11258 | OLD_CFLAGS=$CFLAGS | |
11259 | CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS" | |
11260 | CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS" | |
11261 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
11262 | /* end confdefs.h. */ | |
11263 | #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h> | |
11264 | int | |
11265 | main () | |
11266 | { | |
11267 | int x = 5; | |
11268 | ; | |
11269 | return 0; | |
11270 | } | |
11271 | _ACEOF | |
11272 | if ac_fn_c_try_compile "$LINENO"; then : | |
11273 | emacs_cv_lesstif=yes | |
11274 | else | |
11275 | emacs_cv_lesstif=no | |
11276 | fi | |
11277 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
11278 | fi | |
11279 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5 | |
11280 | $as_echo "$emacs_cv_lesstif" >&6; } | |
11281 | if test $emacs_cv_lesstif = yes; then | |
11282 | # Make sure this -I option remains in CPPFLAGS after it is set | |
11283 | # back to REAL_CPPFLAGS. | |
11284 | # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not | |
11285 | # have those other -I options anyway. Ultimately, having this | |
11286 | # directory ultimately in CPPFLAGS will be enough. | |
11287 | REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS" | |
11288 | LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS" | |
11289 | else | |
11290 | CFLAGS=$OLD_CFLAGS | |
11291 | CPPFLAGS=$OLD_CPPFLAGS | |
11292 | fi | |
11293 | fi | |
11294 | fi | |
11295 | ||
11296 | ||
11297 | USE_TOOLKIT_SCROLL_BARS=no | |
11298 | if test "${with_toolkit_scroll_bars}" != "no"; then | |
11299 | if test "${USE_X_TOOLKIT}" != "none"; then | |
11300 | if test "${USE_X_TOOLKIT}" = "MOTIF"; then | |
11301 | $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h | |
11302 | ||
11303 | HAVE_XAW3D=no | |
11304 | USE_TOOLKIT_SCROLL_BARS=yes | |
11305 | elif test "${HAVE_XAW3D}" = "yes"; then | |
11306 | $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h | |
11307 | ||
11308 | USE_TOOLKIT_SCROLL_BARS=yes | |
11309 | fi | |
11310 | elif test "${HAVE_GTK}" = "yes"; then | |
11311 | $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h | |
11312 | ||
11313 | USE_TOOLKIT_SCROLL_BARS=yes | |
11314 | elif test "${HAVE_NS}" = "yes"; then | |
11315 | $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h | |
11316 | ||
11317 | USE_TOOLKIT_SCROLL_BARS=yes | |
11318 | fi | |
11319 | fi | |
11320 | ||
11321 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
11322 | /* end confdefs.h. */ | |
11323 | ||
11324 | #include <X11/Xlib.h> | |
11325 | #include <X11/Xresource.h> | |
11326 | int | |
11327 | main () | |
11328 | { | |
11329 | XIMProc callback; | |
11330 | ; | |
11331 | return 0; | |
11332 | } | |
11333 | _ACEOF | |
11334 | if ac_fn_c_try_compile "$LINENO"; then : | |
11335 | HAVE_XIM=yes | |
11336 | ||
11337 | $as_echo "#define HAVE_XIM 1" >>confdefs.h | |
11338 | ||
11339 | else | |
11340 | HAVE_XIM=no | |
11341 | fi | |
11342 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
11343 | ||
11344 | ||
11345 | if test "${with_xim}" != "no"; then | |
11346 | ||
11347 | $as_echo "#define USE_XIM 1" >>confdefs.h | |
11348 | ||
11349 | fi | |
11350 | ||
11351 | ||
11352 | if test "${HAVE_XIM}" != "no"; then | |
11353 | late_CFLAGS=$CFLAGS | |
11354 | if test "$GCC" = yes; then | |
11355 | CFLAGS="$CFLAGS --pedantic-errors" | |
11356 | fi | |
11357 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
11358 | /* end confdefs.h. */ | |
11359 | ||
11360 | #include <X11/Xlib.h> | |
11361 | #include <X11/Xresource.h> | |
11362 | int | |
11363 | main () | |
11364 | { | |
11365 | Display *display; | |
11366 | XrmDatabase db; | |
11367 | char *res_name; | |
11368 | char *res_class; | |
11369 | XIMProc callback; | |
11370 | XPointer *client_data; | |
11371 | #ifndef __GNUC__ | |
11372 | /* If we're not using GCC, it's probably not XFree86, and this is | |
11373 | probably right, but we can't use something like --pedantic-errors. */ | |
11374 | extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*, | |
11375 | char*, XIMProc, XPointer*); | |
11376 | #endif | |
11377 | (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback, | |
11378 | client_data); | |
11379 | ; | |
11380 | return 0; | |
11381 | } | |
11382 | _ACEOF | |
11383 | if ac_fn_c_try_compile "$LINENO"; then : | |
11384 | emacs_cv_arg6_star=yes | |
11385 | fi | |
11386 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
11387 | if test "$emacs_cv_arg6_star" = yes; then | |
11388 | $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h | |
11389 | ||
11390 | else | |
11391 | $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h | |
11392 | ||
11393 | fi | |
11394 | CFLAGS=$late_CFLAGS | |
11395 | fi | |
11396 | ||
11397 | ### Start of font-backend (under any platform) section. | |
11398 | # (nothing here yet -- this is a placeholder) | |
11399 | ### End of font-backend (under any platform) section. | |
11400 | ||
11401 | ### Start of font-backend (under X11) section. | |
11402 | if test "${HAVE_X11}" = "yes"; then | |
11403 | ||
11404 | succeeded=no | |
11405 | ||
11406 | # Extract the first word of "pkg-config", so it can be a program name with args. | |
11407 | set dummy pkg-config; ac_word=$2 | |
11408 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
11409 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 11410 | if ${ac_cv_path_PKG_CONFIG+:} false; then : |
067d23c9 KY |
11411 | $as_echo_n "(cached) " >&6 |
11412 | else | |
11413 | case $PKG_CONFIG in | |
11414 | [\\/]* | ?:[\\/]*) | |
11415 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. | |
11416 | ;; | |
11417 | *) | |
11418 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
11419 | for as_dir in $PATH | |
11420 | do | |
11421 | IFS=$as_save_IFS | |
11422 | test -z "$as_dir" && as_dir=. | |
11423 | for ac_exec_ext in '' $ac_executable_extensions; do | |
11424 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
11425 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" | |
11426 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
11427 | break 2 | |
11428 | fi | |
11429 | done | |
11430 | done | |
11431 | IFS=$as_save_IFS | |
11432 | ||
11433 | test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no" | |
11434 | ;; | |
11435 | esac | |
11436 | fi | |
11437 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG | |
11438 | if test -n "$PKG_CONFIG"; then | |
11439 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 | |
11440 | $as_echo "$PKG_CONFIG" >&6; } | |
11441 | else | |
11442 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
11443 | $as_echo "no" >&6; } | |
11444 | fi | |
11445 | ||
11446 | ||
11447 | ||
11448 | if test "$PKG_CONFIG" = "no" ; then | |
11449 | HAVE_FC=no | |
11450 | else | |
11451 | PKG_CONFIG_MIN_VERSION=0.9.0 | |
11452 | if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then | |
11453 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5 | |
11454 | $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; } | |
11455 | ||
11456 | if $PKG_CONFIG --exists "fontconfig >= 2.2.0" 2>&5; then | |
11457 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
11458 | $as_echo "yes" >&6; } | |
11459 | succeeded=yes | |
11460 | ||
11461 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking FONTCONFIG_CFLAGS" >&5 | |
11462 | $as_echo_n "checking FONTCONFIG_CFLAGS... " >&6; } | |
11463 | FONTCONFIG_CFLAGS=`$PKG_CONFIG --cflags "fontconfig >= 2.2.0"|sed -e 's,///*,/,g'` | |
11464 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FONTCONFIG_CFLAGS" >&5 | |
11465 | $as_echo "$FONTCONFIG_CFLAGS" >&6; } | |
11466 | ||
11467 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking FONTCONFIG_LIBS" >&5 | |
11468 | $as_echo_n "checking FONTCONFIG_LIBS... " >&6; } | |
11469 | FONTCONFIG_LIBS=`$PKG_CONFIG --libs "fontconfig >= 2.2.0"|sed -e 's,///*,/,g'` | |
11470 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FONTCONFIG_LIBS" >&5 | |
11471 | $as_echo "$FONTCONFIG_LIBS" >&6; } | |
11472 | else | |
11473 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
11474 | $as_echo "no" >&6; } | |
11475 | FONTCONFIG_CFLAGS="" | |
11476 | FONTCONFIG_LIBS="" | |
11477 | ## If we have a custom action on failure, don't print errors, but | |
11478 | ## do set a variable so people can do so. | |
11479 | FONTCONFIG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "fontconfig >= 2.2.0"` | |
11480 | ||
11481 | fi | |
11482 | ||
11483 | ||
11484 | ||
11485 | else | |
11486 | echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer." | |
11487 | echo "*** See http://www.freedesktop.org/software/pkgconfig" | |
11488 | fi | |
11489 | fi | |
11490 | ||
11491 | if test $succeeded = yes; then | |
11492 | HAVE_FC=yes | |
11493 | else | |
11494 | HAVE_FC=no | |
11495 | fi | |
11496 | ||
11497 | ||
11498 | ## Use -lXft if available, unless `--with-xft=no'. | |
11499 | HAVE_XFT=maybe | |
11500 | if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then | |
11501 | with_xft="no"; | |
11502 | fi | |
11503 | if test "x${with_xft}" != "xno"; then | |
11504 | ||
11505 | ||
11506 | succeeded=no | |
11507 | ||
11508 | # Extract the first word of "pkg-config", so it can be a program name with args. | |
11509 | set dummy pkg-config; ac_word=$2 | |
11510 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
11511 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 11512 | if ${ac_cv_path_PKG_CONFIG+:} false; then : |
067d23c9 KY |
11513 | $as_echo_n "(cached) " >&6 |
11514 | else | |
11515 | case $PKG_CONFIG in | |
11516 | [\\/]* | ?:[\\/]*) | |
11517 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. | |
11518 | ;; | |
11519 | *) | |
11520 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
11521 | for as_dir in $PATH | |
11522 | do | |
11523 | IFS=$as_save_IFS | |
11524 | test -z "$as_dir" && as_dir=. | |
11525 | for ac_exec_ext in '' $ac_executable_extensions; do | |
11526 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
11527 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" | |
11528 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
11529 | break 2 | |
11530 | fi | |
11531 | done | |
11532 | done | |
11533 | IFS=$as_save_IFS | |
11534 | ||
11535 | test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no" | |
11536 | ;; | |
11537 | esac | |
11538 | fi | |
11539 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG | |
11540 | if test -n "$PKG_CONFIG"; then | |
11541 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 | |
11542 | $as_echo "$PKG_CONFIG" >&6; } | |
11543 | else | |
11544 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
11545 | $as_echo "no" >&6; } | |
11546 | fi | |
11547 | ||
11548 | ||
11549 | ||
11550 | if test "$PKG_CONFIG" = "no" ; then | |
11551 | HAVE_XFT=no | |
11552 | else | |
11553 | PKG_CONFIG_MIN_VERSION=0.9.0 | |
11554 | if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then | |
11555 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5 | |
11556 | $as_echo_n "checking for xft >= 0.13.0... " >&6; } | |
11557 | ||
11558 | if $PKG_CONFIG --exists "xft >= 0.13.0" 2>&5; then | |
11559 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
11560 | $as_echo "yes" >&6; } | |
11561 | succeeded=yes | |
11562 | ||
11563 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking XFT_CFLAGS" >&5 | |
11564 | $as_echo_n "checking XFT_CFLAGS... " >&6; } | |
11565 | XFT_CFLAGS=`$PKG_CONFIG --cflags "xft >= 0.13.0"|sed -e 's,///*,/,g'` | |
11566 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XFT_CFLAGS" >&5 | |
11567 | $as_echo "$XFT_CFLAGS" >&6; } | |
11568 | ||
11569 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking XFT_LIBS" >&5 | |
11570 | $as_echo_n "checking XFT_LIBS... " >&6; } | |
11571 | XFT_LIBS=`$PKG_CONFIG --libs "xft >= 0.13.0"|sed -e 's,///*,/,g'` | |
11572 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XFT_LIBS" >&5 | |
11573 | $as_echo "$XFT_LIBS" >&6; } | |
11574 | else | |
11575 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
11576 | $as_echo "no" >&6; } | |
11577 | XFT_CFLAGS="" | |
11578 | XFT_LIBS="" | |
11579 | ## If we have a custom action on failure, don't print errors, but | |
11580 | ## do set a variable so people can do so. | |
11581 | XFT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "xft >= 0.13.0"` | |
11582 | ||
11583 | fi | |
11584 | ||
11585 | ||
11586 | ||
11587 | else | |
11588 | echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer." | |
11589 | echo "*** See http://www.freedesktop.org/software/pkgconfig" | |
11590 | fi | |
11591 | fi | |
11592 | ||
11593 | if test $succeeded = yes; then | |
11594 | : | |
11595 | else | |
11596 | HAVE_XFT=no | |
11597 | fi | |
11598 | ||
11599 | ## Because xftfont.c uses XRenderQueryExtension, we also | |
11600 | ## need to link to -lXrender. | |
11601 | HAVE_XRENDER=no | |
11602 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5 | |
11603 | $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; } | |
d6974efa | 11604 | if ${ac_cv_lib_Xrender_XRenderQueryExtension+:} false; then : |
067d23c9 KY |
11605 | $as_echo_n "(cached) " >&6 |
11606 | else | |
11607 | ac_check_lib_save_LIBS=$LIBS | |
11608 | LIBS="-lXrender $LIBS" | |
11609 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
11610 | /* end confdefs.h. */ | |
11611 | ||
11612 | /* Override any GCC internal prototype to avoid an error. | |
11613 | Use char because int might match the return type of a GCC | |
11614 | builtin and then its argument prototype would still apply. */ | |
11615 | #ifdef __cplusplus | |
11616 | extern "C" | |
11617 | #endif | |
11618 | char XRenderQueryExtension (); | |
11619 | int | |
11620 | main () | |
11621 | { | |
11622 | return XRenderQueryExtension (); | |
11623 | ; | |
11624 | return 0; | |
11625 | } | |
11626 | _ACEOF | |
11627 | if ac_fn_c_try_link "$LINENO"; then : | |
11628 | ac_cv_lib_Xrender_XRenderQueryExtension=yes | |
11629 | else | |
11630 | ac_cv_lib_Xrender_XRenderQueryExtension=no | |
11631 | fi | |
11632 | rm -f core conftest.err conftest.$ac_objext \ | |
11633 | conftest$ac_exeext conftest.$ac_ext | |
11634 | LIBS=$ac_check_lib_save_LIBS | |
11635 | fi | |
11636 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5 | |
11637 | $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; } | |
d6974efa | 11638 | if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = xyes; then : |
067d23c9 KY |
11639 | HAVE_XRENDER=yes |
11640 | fi | |
11641 | ||
11642 | if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then | |
11643 | OLD_CPPFLAGS="$CPPFLAGS" | |
11644 | OLD_CFLAGS="$CFLAGS" | |
11645 | OLD_LIBS="$LIBS" | |
11646 | CPPFLAGS="$CPPFLAGS $XFT_CFLAGS" | |
11647 | CFLAGS="$CFLAGS $XFT_CFLAGS" | |
11648 | XFT_LIBS="-lXrender $XFT_LIBS" | |
11649 | LIBS="$XFT_LIBS $LIBS" | |
11650 | ac_fn_c_check_header_mongrel "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "$ac_includes_default" | |
d6974efa | 11651 | if test "x$ac_cv_header_X11_Xft_Xft_h" = xyes; then : |
067d23c9 KY |
11652 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5 |
11653 | $as_echo_n "checking for XftFontOpen in -lXft... " >&6; } | |
d6974efa | 11654 | if ${ac_cv_lib_Xft_XftFontOpen+:} false; then : |
067d23c9 KY |
11655 | $as_echo_n "(cached) " >&6 |
11656 | else | |
11657 | ac_check_lib_save_LIBS=$LIBS | |
11658 | LIBS="-lXft $XFT_LIBS $LIBS" | |
11659 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
11660 | /* end confdefs.h. */ | |
11661 | ||
11662 | /* Override any GCC internal prototype to avoid an error. | |
11663 | Use char because int might match the return type of a GCC | |
11664 | builtin and then its argument prototype would still apply. */ | |
11665 | #ifdef __cplusplus | |
11666 | extern "C" | |
11667 | #endif | |
11668 | char XftFontOpen (); | |
11669 | int | |
11670 | main () | |
11671 | { | |
11672 | return XftFontOpen (); | |
11673 | ; | |
11674 | return 0; | |
11675 | } | |
11676 | _ACEOF | |
11677 | if ac_fn_c_try_link "$LINENO"; then : | |
11678 | ac_cv_lib_Xft_XftFontOpen=yes | |
11679 | else | |
11680 | ac_cv_lib_Xft_XftFontOpen=no | |
11681 | fi | |
11682 | rm -f core conftest.err conftest.$ac_objext \ | |
11683 | conftest$ac_exeext conftest.$ac_ext | |
11684 | LIBS=$ac_check_lib_save_LIBS | |
11685 | fi | |
11686 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5 | |
11687 | $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; } | |
d6974efa | 11688 | if test "x$ac_cv_lib_Xft_XftFontOpen" = xyes; then : |
067d23c9 KY |
11689 | HAVE_XFT=yes |
11690 | fi | |
11691 | ||
11692 | fi | |
11693 | ||
11694 | ||
11695 | ||
11696 | if test "${HAVE_XFT}" = "yes"; then | |
11697 | ||
11698 | $as_echo "#define HAVE_XFT 1" >>confdefs.h | |
11699 | ||
11700 | ||
11701 | C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS" | |
11702 | else | |
11703 | CPPFLAGS="$OLD_CPPFLAGS" | |
11704 | CFLAGS="$OLD_CFLAGS" | |
11705 | LIBS="$OLD_LIBS" | |
11706 | fi # "${HAVE_XFT}" = "yes" | |
11707 | fi # "$HAVE_XFT" != no | |
11708 | fi # "x${with_xft}" != "xno" | |
11709 | ||
11710 | if test "$HAVE_XFT" != "yes"; then | |
11711 | HAVE_XFT=no | |
11712 | fi | |
11713 | ||
067d23c9 KY |
11714 | ## We used to allow building with FreeType and without Xft. |
11715 | ## However, the ftx font backend driver is not in good shape. | |
9ba41eb9 | 11716 | HAVE_FREETYPE=$HAVE_XFT |
067d23c9 KY |
11717 | |
11718 | HAVE_LIBOTF=no | |
11719 | if test "${HAVE_FREETYPE}" = "yes"; then | |
11720 | ||
11721 | $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h | |
11722 | ||
11723 | if test "${with_libotf}" != "no"; then | |
11724 | ||
11725 | succeeded=no | |
11726 | ||
11727 | # Extract the first word of "pkg-config", so it can be a program name with args. | |
11728 | set dummy pkg-config; ac_word=$2 | |
11729 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
11730 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 11731 | if ${ac_cv_path_PKG_CONFIG+:} false; then : |
067d23c9 KY |
11732 | $as_echo_n "(cached) " >&6 |
11733 | else | |
11734 | case $PKG_CONFIG in | |
11735 | [\\/]* | ?:[\\/]*) | |
11736 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. | |
11737 | ;; | |
11738 | *) | |
11739 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
11740 | for as_dir in $PATH | |
11741 | do | |
11742 | IFS=$as_save_IFS | |
11743 | test -z "$as_dir" && as_dir=. | |
11744 | for ac_exec_ext in '' $ac_executable_extensions; do | |
11745 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
11746 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" | |
11747 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
11748 | break 2 | |
11749 | fi | |
11750 | done | |
11751 | done | |
11752 | IFS=$as_save_IFS | |
11753 | ||
11754 | test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no" | |
11755 | ;; | |
11756 | esac | |
11757 | fi | |
11758 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG | |
11759 | if test -n "$PKG_CONFIG"; then | |
11760 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 | |
11761 | $as_echo "$PKG_CONFIG" >&6; } | |
11762 | else | |
11763 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
11764 | $as_echo "no" >&6; } | |
11765 | fi | |
11766 | ||
11767 | ||
11768 | ||
11769 | if test "$PKG_CONFIG" = "no" ; then | |
11770 | HAVE_LIBOTF=no | |
11771 | else | |
11772 | PKG_CONFIG_MIN_VERSION=0.9.0 | |
11773 | if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then | |
11774 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5 | |
11775 | $as_echo_n "checking for libotf... " >&6; } | |
11776 | ||
11777 | if $PKG_CONFIG --exists "libotf" 2>&5; then | |
11778 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
11779 | $as_echo "yes" >&6; } | |
11780 | succeeded=yes | |
11781 | ||
11782 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBOTF_CFLAGS" >&5 | |
11783 | $as_echo_n "checking LIBOTF_CFLAGS... " >&6; } | |
11784 | LIBOTF_CFLAGS=`$PKG_CONFIG --cflags "libotf"|sed -e 's,///*,/,g'` | |
11785 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBOTF_CFLAGS" >&5 | |
11786 | $as_echo "$LIBOTF_CFLAGS" >&6; } | |
11787 | ||
11788 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBOTF_LIBS" >&5 | |
11789 | $as_echo_n "checking LIBOTF_LIBS... " >&6; } | |
11790 | LIBOTF_LIBS=`$PKG_CONFIG --libs "libotf"|sed -e 's,///*,/,g'` | |
11791 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBOTF_LIBS" >&5 | |
11792 | $as_echo "$LIBOTF_LIBS" >&6; } | |
11793 | else | |
11794 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
11795 | $as_echo "no" >&6; } | |
11796 | LIBOTF_CFLAGS="" | |
11797 | LIBOTF_LIBS="" | |
11798 | ## If we have a custom action on failure, don't print errors, but | |
11799 | ## do set a variable so people can do so. | |
11800 | LIBOTF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libotf"` | |
11801 | ||
11802 | fi | |
11803 | ||
11804 | ||
11805 | ||
11806 | else | |
11807 | echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer." | |
11808 | echo "*** See http://www.freedesktop.org/software/pkgconfig" | |
11809 | fi | |
11810 | fi | |
11811 | ||
11812 | if test $succeeded = yes; then | |
11813 | HAVE_LIBOTF=yes | |
11814 | else | |
11815 | HAVE_LIBOTF=no | |
11816 | fi | |
11817 | ||
11818 | if test "$HAVE_LIBOTF" = "yes"; then | |
11819 | ||
11820 | $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h | |
11821 | ||
11822 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5 | |
11823 | $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; } | |
d6974efa | 11824 | if ${ac_cv_lib_otf_OTF_get_variation_glyphs+:} false; then : |
067d23c9 KY |
11825 | $as_echo_n "(cached) " >&6 |
11826 | else | |
11827 | ac_check_lib_save_LIBS=$LIBS | |
11828 | LIBS="-lotf $LIBS" | |
11829 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
11830 | /* end confdefs.h. */ | |
11831 | ||
11832 | /* Override any GCC internal prototype to avoid an error. | |
11833 | Use char because int might match the return type of a GCC | |
11834 | builtin and then its argument prototype would still apply. */ | |
11835 | #ifdef __cplusplus | |
11836 | extern "C" | |
11837 | #endif | |
11838 | char OTF_get_variation_glyphs (); | |
11839 | int | |
11840 | main () | |
11841 | { | |
11842 | return OTF_get_variation_glyphs (); | |
11843 | ; | |
11844 | return 0; | |
11845 | } | |
11846 | _ACEOF | |
11847 | if ac_fn_c_try_link "$LINENO"; then : | |
11848 | ac_cv_lib_otf_OTF_get_variation_glyphs=yes | |
11849 | else | |
11850 | ac_cv_lib_otf_OTF_get_variation_glyphs=no | |
11851 | fi | |
11852 | rm -f core conftest.err conftest.$ac_objext \ | |
11853 | conftest$ac_exeext conftest.$ac_ext | |
11854 | LIBS=$ac_check_lib_save_LIBS | |
11855 | fi | |
11856 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5 | |
11857 | $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; } | |
d6974efa | 11858 | if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = xyes; then : |
067d23c9 KY |
11859 | HAVE_OTF_GET_VARIATION_GLYPHS=yes |
11860 | else | |
11861 | HAVE_OTF_GET_VARIATION_GLYPHS=no | |
11862 | fi | |
11863 | ||
11864 | if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then | |
11865 | ||
11866 | $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h | |
11867 | ||
11868 | fi | |
11869 | fi | |
11870 | fi | |
11871 | fi | |
11872 | ||
11873 | HAVE_M17N_FLT=no | |
11874 | if test "${HAVE_LIBOTF}" = yes; then | |
11875 | if test "${with_m17n_flt}" != "no"; then | |
11876 | ||
11877 | succeeded=no | |
11878 | ||
11879 | # Extract the first word of "pkg-config", so it can be a program name with args. | |
11880 | set dummy pkg-config; ac_word=$2 | |
11881 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
11882 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 11883 | if ${ac_cv_path_PKG_CONFIG+:} false; then : |
067d23c9 KY |
11884 | $as_echo_n "(cached) " >&6 |
11885 | else | |
11886 | case $PKG_CONFIG in | |
11887 | [\\/]* | ?:[\\/]*) | |
11888 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. | |
11889 | ;; | |
11890 | *) | |
11891 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
11892 | for as_dir in $PATH | |
11893 | do | |
11894 | IFS=$as_save_IFS | |
11895 | test -z "$as_dir" && as_dir=. | |
11896 | for ac_exec_ext in '' $ac_executable_extensions; do | |
11897 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
11898 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" | |
11899 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
11900 | break 2 | |
11901 | fi | |
11902 | done | |
11903 | done | |
11904 | IFS=$as_save_IFS | |
11905 | ||
11906 | test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no" | |
11907 | ;; | |
11908 | esac | |
11909 | fi | |
11910 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG | |
11911 | if test -n "$PKG_CONFIG"; then | |
11912 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 | |
11913 | $as_echo "$PKG_CONFIG" >&6; } | |
11914 | else | |
11915 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
11916 | $as_echo "no" >&6; } | |
11917 | fi | |
11918 | ||
11919 | ||
11920 | ||
11921 | if test "$PKG_CONFIG" = "no" ; then | |
11922 | HAVE_M17N_FLT=no | |
11923 | else | |
11924 | PKG_CONFIG_MIN_VERSION=0.9.0 | |
11925 | if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then | |
11926 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5 | |
11927 | $as_echo_n "checking for m17n-flt... " >&6; } | |
11928 | ||
11929 | if $PKG_CONFIG --exists "m17n-flt" 2>&5; then | |
11930 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
11931 | $as_echo "yes" >&6; } | |
11932 | succeeded=yes | |
11933 | ||
11934 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking M17N_FLT_CFLAGS" >&5 | |
11935 | $as_echo_n "checking M17N_FLT_CFLAGS... " >&6; } | |
11936 | M17N_FLT_CFLAGS=`$PKG_CONFIG --cflags "m17n-flt"|sed -e 's,///*,/,g'` | |
11937 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $M17N_FLT_CFLAGS" >&5 | |
11938 | $as_echo "$M17N_FLT_CFLAGS" >&6; } | |
11939 | ||
11940 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking M17N_FLT_LIBS" >&5 | |
11941 | $as_echo_n "checking M17N_FLT_LIBS... " >&6; } | |
11942 | M17N_FLT_LIBS=`$PKG_CONFIG --libs "m17n-flt"|sed -e 's,///*,/,g'` | |
11943 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $M17N_FLT_LIBS" >&5 | |
11944 | $as_echo "$M17N_FLT_LIBS" >&6; } | |
11945 | else | |
11946 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
11947 | $as_echo "no" >&6; } | |
11948 | M17N_FLT_CFLAGS="" | |
11949 | M17N_FLT_LIBS="" | |
11950 | ## If we have a custom action on failure, don't print errors, but | |
11951 | ## do set a variable so people can do so. | |
11952 | M17N_FLT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "m17n-flt"` | |
11953 | ||
11954 | fi | |
11955 | ||
11956 | ||
11957 | ||
11958 | else | |
11959 | echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer." | |
11960 | echo "*** See http://www.freedesktop.org/software/pkgconfig" | |
11961 | fi | |
11962 | fi | |
11963 | ||
11964 | if test $succeeded = yes; then | |
11965 | HAVE_M17N_FLT=yes | |
11966 | else | |
11967 | HAVE_M17N_FLT=no | |
11968 | fi | |
11969 | ||
11970 | if test "$HAVE_M17N_FLT" = "yes"; then | |
11971 | ||
11972 | $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h | |
11973 | ||
11974 | fi | |
11975 | fi | |
11976 | fi | |
11977 | else | |
11978 | HAVE_XFT=no | |
11979 | HAVE_FREETYPE=no | |
11980 | HAVE_LIBOTF=no | |
11981 | HAVE_M17N_FLT=no | |
11982 | fi | |
11983 | ||
11984 | ### End of font-backend (under X11) section. | |
11985 | ||
11986 | ||
11987 | ||
11988 | ||
11989 | ||
11990 | ||
11991 | ||
11992 | ||
11993 | ||
11994 | ||
11995 | ### Use -lXpm if available, unless `--with-xpm=no'. | |
11996 | HAVE_XPM=no | |
11997 | LIBXPM= | |
11998 | if test "${HAVE_X11}" = "yes"; then | |
11999 | if test "${with_xpm}" != "no"; then | |
12000 | ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default" | |
d6974efa | 12001 | if test "x$ac_cv_header_X11_xpm_h" = xyes; then : |
067d23c9 KY |
12002 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5 |
12003 | $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; } | |
d6974efa | 12004 | if ${ac_cv_lib_Xpm_XpmReadFileToPixmap+:} false; then : |
067d23c9 KY |
12005 | $as_echo_n "(cached) " >&6 |
12006 | else | |
12007 | ac_check_lib_save_LIBS=$LIBS | |
12008 | LIBS="-lXpm -lX11 $LIBS" | |
12009 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12010 | /* end confdefs.h. */ | |
12011 | ||
12012 | /* Override any GCC internal prototype to avoid an error. | |
12013 | Use char because int might match the return type of a GCC | |
12014 | builtin and then its argument prototype would still apply. */ | |
12015 | #ifdef __cplusplus | |
12016 | extern "C" | |
12017 | #endif | |
12018 | char XpmReadFileToPixmap (); | |
12019 | int | |
12020 | main () | |
12021 | { | |
12022 | return XpmReadFileToPixmap (); | |
12023 | ; | |
12024 | return 0; | |
12025 | } | |
12026 | _ACEOF | |
12027 | if ac_fn_c_try_link "$LINENO"; then : | |
12028 | ac_cv_lib_Xpm_XpmReadFileToPixmap=yes | |
12029 | else | |
12030 | ac_cv_lib_Xpm_XpmReadFileToPixmap=no | |
12031 | fi | |
12032 | rm -f core conftest.err conftest.$ac_objext \ | |
12033 | conftest$ac_exeext conftest.$ac_ext | |
12034 | LIBS=$ac_check_lib_save_LIBS | |
12035 | fi | |
12036 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5 | |
12037 | $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; } | |
d6974efa | 12038 | if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = xyes; then : |
067d23c9 KY |
12039 | HAVE_XPM=yes |
12040 | fi | |
12041 | ||
12042 | fi | |
12043 | ||
12044 | ||
12045 | if test "${HAVE_XPM}" = "yes"; then | |
12046 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5 | |
12047 | $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; } | |
12048 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12049 | /* end confdefs.h. */ | |
12050 | #include "X11/xpm.h" | |
12051 | #ifndef XpmReturnAllocPixels | |
12052 | no_return_alloc_pixels | |
12053 | #endif | |
12054 | ||
12055 | _ACEOF | |
12056 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
12057 | $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then : | |
12058 | HAVE_XPM=no | |
12059 | else | |
12060 | HAVE_XPM=yes | |
12061 | fi | |
12062 | rm -f conftest* | |
12063 | ||
12064 | ||
12065 | if test "${HAVE_XPM}" = "yes"; then | |
12066 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
12067 | $as_echo "yes" >&6; } | |
12068 | else | |
12069 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
12070 | $as_echo "no" >&6; } | |
12071 | fi | |
12072 | fi | |
12073 | fi | |
12074 | ||
12075 | if test "${HAVE_XPM}" = "yes"; then | |
12076 | ||
12077 | $as_echo "#define HAVE_XPM 1" >>confdefs.h | |
12078 | ||
12079 | LIBXPM=-lXpm | |
12080 | fi | |
12081 | fi | |
12082 | ||
12083 | ||
12084 | ### Use -ljpeg if available, unless `--with-jpeg=no'. | |
12085 | HAVE_JPEG=no | |
12086 | LIBJPEG= | |
12087 | if test "${HAVE_X11}" = "yes"; then | |
12088 | if test "${with_jpeg}" != "no"; then | |
12089 | ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default" | |
d6974efa | 12090 | if test "x$ac_cv_header_jerror_h" = xyes; then : |
067d23c9 KY |
12091 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5 |
12092 | $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; } | |
d6974efa | 12093 | if ${ac_cv_lib_jpeg_jpeg_destroy_compress+:} false; then : |
067d23c9 KY |
12094 | $as_echo_n "(cached) " >&6 |
12095 | else | |
12096 | ac_check_lib_save_LIBS=$LIBS | |
12097 | LIBS="-ljpeg $LIBS" | |
12098 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12099 | /* end confdefs.h. */ | |
12100 | ||
12101 | /* Override any GCC internal prototype to avoid an error. | |
12102 | Use char because int might match the return type of a GCC | |
12103 | builtin and then its argument prototype would still apply. */ | |
12104 | #ifdef __cplusplus | |
12105 | extern "C" | |
12106 | #endif | |
12107 | char jpeg_destroy_compress (); | |
12108 | int | |
12109 | main () | |
12110 | { | |
12111 | return jpeg_destroy_compress (); | |
12112 | ; | |
12113 | return 0; | |
12114 | } | |
12115 | _ACEOF | |
12116 | if ac_fn_c_try_link "$LINENO"; then : | |
12117 | ac_cv_lib_jpeg_jpeg_destroy_compress=yes | |
12118 | else | |
12119 | ac_cv_lib_jpeg_jpeg_destroy_compress=no | |
12120 | fi | |
12121 | rm -f core conftest.err conftest.$ac_objext \ | |
12122 | conftest$ac_exeext conftest.$ac_ext | |
12123 | LIBS=$ac_check_lib_save_LIBS | |
12124 | fi | |
12125 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5 | |
12126 | $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; } | |
d6974efa | 12127 | if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = xyes; then : |
067d23c9 KY |
12128 | HAVE_JPEG=yes |
12129 | fi | |
12130 | ||
12131 | fi | |
12132 | ||
12133 | ||
12134 | fi | |
12135 | ||
12136 | if test "${HAVE_JPEG}" = "yes"; then | |
12137 | $as_echo "#define HAVE_JPEG 1" >>confdefs.h | |
12138 | ||
12139 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12140 | /* end confdefs.h. */ | |
12141 | #include <jpeglib.h> | |
12142 | version=JPEG_LIB_VERSION | |
12143 | ||
12144 | _ACEOF | |
12145 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
12146 | $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then : | |
12147 | $as_echo "#define HAVE_JPEG 1" >>confdefs.h | |
12148 | ||
12149 | else | |
12150 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5 | |
12151 | $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;} | |
12152 | HAVE_JPEG=no | |
12153 | fi | |
12154 | rm -f conftest* | |
12155 | ||
12156 | fi | |
12157 | if test "${HAVE_JPEG}" = "yes"; then | |
12158 | LIBJPEG=-ljpeg | |
12159 | fi | |
12160 | fi | |
12161 | ||
12162 | ||
12163 | ### Use -lpng if available, unless `--with-png=no'. | |
12164 | HAVE_PNG=no | |
12165 | LIBPNG= | |
12166 | if test "${HAVE_X11}" = "yes"; then | |
12167 | if test "${with_png}" != "no"; then | |
12168 | # Debian unstable as of July 2003 has multiple libpngs, and puts png.h | |
12169 | # in /usr/include/libpng. | |
12170 | for ac_header in png.h libpng/png.h | |
12171 | do : | |
12172 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
12173 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
2018939f | 12174 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
067d23c9 KY |
12175 | cat >>confdefs.h <<_ACEOF |
12176 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
12177 | _ACEOF | |
12178 | ||
12179 | fi | |
12180 | ||
12181 | done | |
12182 | ||
12183 | if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then | |
12184 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5 | |
12185 | $as_echo_n "checking for png_get_channels in -lpng... " >&6; } | |
d6974efa | 12186 | if ${ac_cv_lib_png_png_get_channels+:} false; then : |
067d23c9 KY |
12187 | $as_echo_n "(cached) " >&6 |
12188 | else | |
12189 | ac_check_lib_save_LIBS=$LIBS | |
12190 | LIBS="-lpng -lz -lm $LIBS" | |
12191 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12192 | /* end confdefs.h. */ | |
12193 | ||
12194 | /* Override any GCC internal prototype to avoid an error. | |
12195 | Use char because int might match the return type of a GCC | |
12196 | builtin and then its argument prototype would still apply. */ | |
12197 | #ifdef __cplusplus | |
12198 | extern "C" | |
12199 | #endif | |
12200 | char png_get_channels (); | |
12201 | int | |
12202 | main () | |
12203 | { | |
12204 | return png_get_channels (); | |
12205 | ; | |
12206 | return 0; | |
12207 | } | |
12208 | _ACEOF | |
12209 | if ac_fn_c_try_link "$LINENO"; then : | |
12210 | ac_cv_lib_png_png_get_channels=yes | |
12211 | else | |
12212 | ac_cv_lib_png_png_get_channels=no | |
12213 | fi | |
12214 | rm -f core conftest.err conftest.$ac_objext \ | |
12215 | conftest$ac_exeext conftest.$ac_ext | |
12216 | LIBS=$ac_check_lib_save_LIBS | |
12217 | fi | |
12218 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5 | |
12219 | $as_echo "$ac_cv_lib_png_png_get_channels" >&6; } | |
d6974efa | 12220 | if test "x$ac_cv_lib_png_png_get_channels" = xyes; then : |
067d23c9 KY |
12221 | HAVE_PNG=yes |
12222 | fi | |
12223 | ||
12224 | fi | |
12225 | fi | |
12226 | ||
12227 | if test "${HAVE_PNG}" = "yes"; then | |
12228 | ||
12229 | $as_echo "#define HAVE_PNG 1" >>confdefs.h | |
12230 | ||
12231 | LIBPNG="-lpng -lz -lm" | |
12232 | fi | |
12233 | fi | |
12234 | ||
12235 | ||
12236 | ### Use -ltiff if available, unless `--with-tiff=no'. | |
12237 | HAVE_TIFF=no | |
12238 | LIBTIFF= | |
12239 | if test "${HAVE_X11}" = "yes"; then | |
12240 | if test "${with_tiff}" != "no"; then | |
12241 | ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default" | |
d6974efa | 12242 | if test "x$ac_cv_header_tiffio_h" = xyes; then : |
067d23c9 KY |
12243 | tifflibs="-lz -lm" |
12244 | # At least one tiff package requires the jpeg library. | |
12245 | if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi | |
12246 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5 | |
12247 | $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; } | |
d6974efa | 12248 | if ${ac_cv_lib_tiff_TIFFGetVersion+:} false; then : |
067d23c9 KY |
12249 | $as_echo_n "(cached) " >&6 |
12250 | else | |
12251 | ac_check_lib_save_LIBS=$LIBS | |
12252 | LIBS="-ltiff $tifflibs $LIBS" | |
12253 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12254 | /* end confdefs.h. */ | |
12255 | ||
12256 | /* Override any GCC internal prototype to avoid an error. | |
12257 | Use char because int might match the return type of a GCC | |
12258 | builtin and then its argument prototype would still apply. */ | |
12259 | #ifdef __cplusplus | |
12260 | extern "C" | |
12261 | #endif | |
12262 | char TIFFGetVersion (); | |
12263 | int | |
12264 | main () | |
12265 | { | |
12266 | return TIFFGetVersion (); | |
12267 | ; | |
12268 | return 0; | |
12269 | } | |
12270 | _ACEOF | |
12271 | if ac_fn_c_try_link "$LINENO"; then : | |
12272 | ac_cv_lib_tiff_TIFFGetVersion=yes | |
12273 | else | |
12274 | ac_cv_lib_tiff_TIFFGetVersion=no | |
12275 | fi | |
12276 | rm -f core conftest.err conftest.$ac_objext \ | |
12277 | conftest$ac_exeext conftest.$ac_ext | |
12278 | LIBS=$ac_check_lib_save_LIBS | |
12279 | fi | |
12280 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5 | |
12281 | $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; } | |
d6974efa | 12282 | if test "x$ac_cv_lib_tiff_TIFFGetVersion" = xyes; then : |
067d23c9 KY |
12283 | HAVE_TIFF=yes |
12284 | fi | |
12285 | ||
12286 | fi | |
12287 | ||
12288 | ||
12289 | fi | |
12290 | ||
12291 | if test "${HAVE_TIFF}" = "yes"; then | |
12292 | ||
12293 | $as_echo "#define HAVE_TIFF 1" >>confdefs.h | |
12294 | ||
12295 | LIBTIFF=-ltiff | |
12296 | fi | |
12297 | fi | |
12298 | ||
12299 | ||
12300 | ### Use -lgif or -lungif if available, unless `--with-gif=no'. | |
12301 | HAVE_GIF=no | |
12302 | LIBGIF= | |
12303 | if test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no"; then | |
12304 | ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default" | |
d6974efa | 12305 | if test "x$ac_cv_header_gif_lib_h" = xyes; then : |
067d23c9 KY |
12306 | # EGifPutExtensionLast only exists from version libungif-4.1.0b1. |
12307 | # Earlier versions can crash Emacs. | |
12308 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5 | |
12309 | $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; } | |
d6974efa | 12310 | if ${ac_cv_lib_gif_EGifPutExtensionLast+:} false; then : |
067d23c9 KY |
12311 | $as_echo_n "(cached) " >&6 |
12312 | else | |
12313 | ac_check_lib_save_LIBS=$LIBS | |
12314 | LIBS="-lgif $LIBS" | |
12315 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12316 | /* end confdefs.h. */ | |
12317 | ||
12318 | /* Override any GCC internal prototype to avoid an error. | |
12319 | Use char because int might match the return type of a GCC | |
12320 | builtin and then its argument prototype would still apply. */ | |
12321 | #ifdef __cplusplus | |
12322 | extern "C" | |
12323 | #endif | |
12324 | char EGifPutExtensionLast (); | |
12325 | int | |
12326 | main () | |
12327 | { | |
12328 | return EGifPutExtensionLast (); | |
12329 | ; | |
12330 | return 0; | |
12331 | } | |
12332 | _ACEOF | |
12333 | if ac_fn_c_try_link "$LINENO"; then : | |
12334 | ac_cv_lib_gif_EGifPutExtensionLast=yes | |
12335 | else | |
12336 | ac_cv_lib_gif_EGifPutExtensionLast=no | |
12337 | fi | |
12338 | rm -f core conftest.err conftest.$ac_objext \ | |
12339 | conftest$ac_exeext conftest.$ac_ext | |
12340 | LIBS=$ac_check_lib_save_LIBS | |
12341 | fi | |
12342 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5 | |
12343 | $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; } | |
d6974efa | 12344 | if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = xyes; then : |
067d23c9 KY |
12345 | HAVE_GIF=yes |
12346 | else | |
12347 | HAVE_GIF=maybe | |
12348 | fi | |
12349 | ||
12350 | fi | |
12351 | ||
12352 | ||
12353 | ||
12354 | if test "$HAVE_GIF" = yes; then | |
12355 | LIBGIF=-lgif | |
12356 | elif test "$HAVE_GIF" = maybe; then | |
12357 | # If gif_lib.h but no libgif, try libungif. | |
12358 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5 | |
12359 | $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; } | |
d6974efa | 12360 | if ${ac_cv_lib_ungif_EGifPutExtensionLast+:} false; then : |
067d23c9 KY |
12361 | $as_echo_n "(cached) " >&6 |
12362 | else | |
12363 | ac_check_lib_save_LIBS=$LIBS | |
12364 | LIBS="-lungif $LIBS" | |
12365 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12366 | /* end confdefs.h. */ | |
12367 | ||
12368 | /* Override any GCC internal prototype to avoid an error. | |
12369 | Use char because int might match the return type of a GCC | |
12370 | builtin and then its argument prototype would still apply. */ | |
12371 | #ifdef __cplusplus | |
12372 | extern "C" | |
12373 | #endif | |
12374 | char EGifPutExtensionLast (); | |
12375 | int | |
12376 | main () | |
12377 | { | |
12378 | return EGifPutExtensionLast (); | |
12379 | ; | |
12380 | return 0; | |
12381 | } | |
12382 | _ACEOF | |
12383 | if ac_fn_c_try_link "$LINENO"; then : | |
12384 | ac_cv_lib_ungif_EGifPutExtensionLast=yes | |
12385 | else | |
12386 | ac_cv_lib_ungif_EGifPutExtensionLast=no | |
12387 | fi | |
12388 | rm -f core conftest.err conftest.$ac_objext \ | |
12389 | conftest$ac_exeext conftest.$ac_ext | |
12390 | LIBS=$ac_check_lib_save_LIBS | |
12391 | fi | |
12392 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5 | |
12393 | $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; } | |
d6974efa | 12394 | if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = xyes; then : |
067d23c9 KY |
12395 | HAVE_GIF=yes |
12396 | else | |
12397 | HAVE_GIF=no | |
12398 | fi | |
12399 | ||
12400 | test "$HAVE_GIF" = yes && LIBGIF=-lungif | |
12401 | fi | |
12402 | ||
12403 | if test "${HAVE_GIF}" = "yes"; then | |
12404 | ||
12405 | $as_echo "#define HAVE_GIF 1" >>confdefs.h | |
12406 | ||
12407 | fi | |
12408 | fi | |
12409 | ||
12410 | ||
12411 | if test "${HAVE_X11}" = "yes"; then | |
12412 | MISSING="" | |
12413 | WITH_NO="" | |
12414 | test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" && | |
12415 | MISSING="libXpm" && WITH_NO="--with-xpm=no" | |
12416 | test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" && | |
12417 | MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no" | |
12418 | test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" && | |
12419 | MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no" | |
12420 | test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" && | |
12421 | MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no" | |
12422 | test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" && | |
12423 | MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no" | |
12424 | ||
12425 | if test "X${MISSING}" != X; then | |
2018939f | 12426 | as_fn_error $? "The following required libraries were not found: |
067d23c9 KY |
12427 | $MISSING |
12428 | Maybe some development libraries/packages are missing? | |
12429 | If you don't want to link with them give | |
12430 | $WITH_NO | |
12431 | as options to configure" "$LINENO" 5 | |
12432 | fi | |
12433 | fi | |
12434 | ||
12435 | ### Use -lgpm if available, unless `--with-gpm=no'. | |
12436 | HAVE_GPM=no | |
12437 | LIBGPM= | |
12438 | MOUSE_SUPPORT= | |
12439 | if test "${with_gpm}" != "no"; then | |
12440 | ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default" | |
d6974efa | 12441 | if test "x$ac_cv_header_gpm_h" = xyes; then : |
067d23c9 KY |
12442 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5 |
12443 | $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; } | |
d6974efa | 12444 | if ${ac_cv_lib_gpm_Gpm_Open+:} false; then : |
067d23c9 KY |
12445 | $as_echo_n "(cached) " >&6 |
12446 | else | |
12447 | ac_check_lib_save_LIBS=$LIBS | |
12448 | LIBS="-lgpm $LIBS" | |
12449 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12450 | /* end confdefs.h. */ | |
12451 | ||
12452 | /* Override any GCC internal prototype to avoid an error. | |
12453 | Use char because int might match the return type of a GCC | |
12454 | builtin and then its argument prototype would still apply. */ | |
12455 | #ifdef __cplusplus | |
12456 | extern "C" | |
12457 | #endif | |
12458 | char Gpm_Open (); | |
12459 | int | |
12460 | main () | |
12461 | { | |
12462 | return Gpm_Open (); | |
12463 | ; | |
12464 | return 0; | |
12465 | } | |
12466 | _ACEOF | |
12467 | if ac_fn_c_try_link "$LINENO"; then : | |
12468 | ac_cv_lib_gpm_Gpm_Open=yes | |
12469 | else | |
12470 | ac_cv_lib_gpm_Gpm_Open=no | |
12471 | fi | |
12472 | rm -f core conftest.err conftest.$ac_objext \ | |
12473 | conftest$ac_exeext conftest.$ac_ext | |
12474 | LIBS=$ac_check_lib_save_LIBS | |
12475 | fi | |
12476 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5 | |
12477 | $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; } | |
d6974efa | 12478 | if test "x$ac_cv_lib_gpm_Gpm_Open" = xyes; then : |
067d23c9 KY |
12479 | HAVE_GPM=yes |
12480 | fi | |
12481 | ||
12482 | fi | |
12483 | ||
12484 | ||
12485 | ||
12486 | if test "${HAVE_GPM}" = "yes"; then | |
12487 | ||
12488 | $as_echo "#define HAVE_GPM 1" >>confdefs.h | |
12489 | ||
12490 | LIBGPM=-lgpm | |
12491 | ## May be reset below. | |
12492 | MOUSE_SUPPORT="\$(GPM_MOUSE_SUPPORT)" | |
12493 | fi | |
12494 | fi | |
12495 | ||
12496 | ||
12497 | ac_fn_c_check_header_mongrel "$LINENO" "malloc/malloc.h" "ac_cv_header_malloc_malloc_h" "$ac_includes_default" | |
d6974efa | 12498 | if test "x$ac_cv_header_malloc_malloc_h" = xyes; then : |
067d23c9 KY |
12499 | |
12500 | $as_echo "#define HAVE_MALLOC_MALLOC_H 1" >>confdefs.h | |
12501 | ||
12502 | fi | |
12503 | ||
12504 | ||
12505 | ||
12506 | C_SWITCH_X_SYSTEM= | |
12507 | ### Use NeXTstep API to implement GUI. | |
12508 | if test "${HAVE_NS}" = "yes"; then | |
12509 | ||
12510 | $as_echo "#define HAVE_NS 1" >>confdefs.h | |
12511 | ||
12512 | if test "${NS_IMPL_COCOA}" = "yes"; then | |
12513 | ||
12514 | $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h | |
12515 | ||
12516 | GNU_OBJC_CFLAGS= | |
12517 | fi | |
12518 | if test "${NS_IMPL_GNUSTEP}" = "yes"; then | |
12519 | ||
12520 | $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h | |
12521 | ||
12522 | # See also .m.o rule in Makefile.in */ | |
12523 | # FIXME: are all these flags really needed? Document here why. */ | |
12524 | C_SWITCH_X_SYSTEM="-D_REENTRANT -fPIC -fno-strict-aliasing" | |
12525 | GNU_OBJC_CFLAGS="-fgnu-runtime -Wno-import -fconstant-string-class=NSConstantString -DGNUSTEP_BASE_LIBRARY=1 -DGNU_GUI_LIBRARY=1 -DGNU_RUNTIME=1 -DGSWARN -DGSDIAGNOSE" | |
12526 | fi | |
12527 | if test "${NS_HAVE_NSINTEGER}" = "yes"; then | |
12528 | ||
12529 | $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h | |
12530 | ||
12531 | fi | |
12532 | # We also have mouse menus. | |
12533 | HAVE_MENUS=yes | |
12534 | OTHER_FILES=ns-app | |
12535 | fi | |
12536 | ||
12537 | ||
12538 | ### Use session management (-lSM -lICE) if available | |
12539 | HAVE_X_SM=no | |
12540 | LIBXSM= | |
12541 | if test "${HAVE_X11}" = "yes"; then | |
12542 | ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default" | |
d6974efa | 12543 | if test "x$ac_cv_header_X11_SM_SMlib_h" = xyes; then : |
067d23c9 KY |
12544 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5 |
12545 | $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; } | |
d6974efa | 12546 | if ${ac_cv_lib_SM_SmcOpenConnection+:} false; then : |
067d23c9 KY |
12547 | $as_echo_n "(cached) " >&6 |
12548 | else | |
12549 | ac_check_lib_save_LIBS=$LIBS | |
12550 | LIBS="-lSM -lICE $LIBS" | |
12551 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12552 | /* end confdefs.h. */ | |
12553 | ||
12554 | /* Override any GCC internal prototype to avoid an error. | |
12555 | Use char because int might match the return type of a GCC | |
12556 | builtin and then its argument prototype would still apply. */ | |
12557 | #ifdef __cplusplus | |
12558 | extern "C" | |
12559 | #endif | |
12560 | char SmcOpenConnection (); | |
12561 | int | |
12562 | main () | |
12563 | { | |
12564 | return SmcOpenConnection (); | |
12565 | ; | |
12566 | return 0; | |
12567 | } | |
12568 | _ACEOF | |
12569 | if ac_fn_c_try_link "$LINENO"; then : | |
12570 | ac_cv_lib_SM_SmcOpenConnection=yes | |
12571 | else | |
12572 | ac_cv_lib_SM_SmcOpenConnection=no | |
12573 | fi | |
12574 | rm -f core conftest.err conftest.$ac_objext \ | |
12575 | conftest$ac_exeext conftest.$ac_ext | |
12576 | LIBS=$ac_check_lib_save_LIBS | |
12577 | fi | |
12578 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5 | |
12579 | $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; } | |
d6974efa | 12580 | if test "x$ac_cv_lib_SM_SmcOpenConnection" = xyes; then : |
067d23c9 KY |
12581 | HAVE_X_SM=yes |
12582 | fi | |
12583 | ||
12584 | fi | |
12585 | ||
12586 | ||
12587 | ||
12588 | if test "${HAVE_X_SM}" = "yes"; then | |
12589 | ||
12590 | $as_echo "#define HAVE_X_SM 1" >>confdefs.h | |
12591 | ||
12592 | LIBXSM="-lSM -lICE" | |
12593 | case "$LIBS" in | |
12594 | *-lSM*) ;; | |
12595 | *) LIBS="$LIBXSM $LIBS" ;; | |
12596 | esac | |
12597 | fi | |
12598 | fi | |
12599 | ||
12600 | ||
12601 | ### Use libxml (-lxml2) if available | |
12602 | if test "${with_xml2}" != "no"; then | |
12603 | ### I'm not sure what the version number should be, so I just guessed. | |
12604 | ||
12605 | succeeded=no | |
12606 | ||
12607 | # Extract the first word of "pkg-config", so it can be a program name with args. | |
12608 | set dummy pkg-config; ac_word=$2 | |
12609 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
12610 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 12611 | if ${ac_cv_path_PKG_CONFIG+:} false; then : |
067d23c9 KY |
12612 | $as_echo_n "(cached) " >&6 |
12613 | else | |
12614 | case $PKG_CONFIG in | |
12615 | [\\/]* | ?:[\\/]*) | |
12616 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. | |
12617 | ;; | |
12618 | *) | |
12619 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
12620 | for as_dir in $PATH | |
12621 | do | |
12622 | IFS=$as_save_IFS | |
12623 | test -z "$as_dir" && as_dir=. | |
12624 | for ac_exec_ext in '' $ac_executable_extensions; do | |
12625 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
12626 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" | |
12627 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
12628 | break 2 | |
12629 | fi | |
12630 | done | |
12631 | done | |
12632 | IFS=$as_save_IFS | |
12633 | ||
12634 | test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no" | |
12635 | ;; | |
12636 | esac | |
12637 | fi | |
12638 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG | |
12639 | if test -n "$PKG_CONFIG"; then | |
12640 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 | |
12641 | $as_echo "$PKG_CONFIG" >&6; } | |
12642 | else | |
12643 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
12644 | $as_echo "no" >&6; } | |
12645 | fi | |
12646 | ||
12647 | ||
12648 | ||
12649 | if test "$PKG_CONFIG" = "no" ; then | |
12650 | HAVE_LIBXML2=no | |
12651 | else | |
12652 | PKG_CONFIG_MIN_VERSION=0.9.0 | |
12653 | if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then | |
dab73760 CY |
12654 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5 |
12655 | $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; } | |
067d23c9 | 12656 | |
dab73760 | 12657 | if $PKG_CONFIG --exists "libxml-2.0 > 2.6.17" 2>&5; then |
067d23c9 KY |
12658 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
12659 | $as_echo "yes" >&6; } | |
12660 | succeeded=yes | |
12661 | ||
12662 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBXML2_CFLAGS" >&5 | |
12663 | $as_echo_n "checking LIBXML2_CFLAGS... " >&6; } | |
dab73760 | 12664 | LIBXML2_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 > 2.6.17"|sed -e 's,///*,/,g'` |
067d23c9 KY |
12665 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBXML2_CFLAGS" >&5 |
12666 | $as_echo "$LIBXML2_CFLAGS" >&6; } | |
12667 | ||
12668 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBXML2_LIBS" >&5 | |
12669 | $as_echo_n "checking LIBXML2_LIBS... " >&6; } | |
dab73760 | 12670 | LIBXML2_LIBS=`$PKG_CONFIG --libs "libxml-2.0 > 2.6.17"|sed -e 's,///*,/,g'` |
067d23c9 KY |
12671 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBXML2_LIBS" >&5 |
12672 | $as_echo "$LIBXML2_LIBS" >&6; } | |
12673 | else | |
12674 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
12675 | $as_echo "no" >&6; } | |
12676 | LIBXML2_CFLAGS="" | |
12677 | LIBXML2_LIBS="" | |
12678 | ## If we have a custom action on failure, don't print errors, but | |
12679 | ## do set a variable so people can do so. | |
dab73760 | 12680 | LIBXML2_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libxml-2.0 > 2.6.17"` |
067d23c9 KY |
12681 | |
12682 | fi | |
12683 | ||
12684 | ||
12685 | ||
12686 | else | |
12687 | echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer." | |
12688 | echo "*** See http://www.freedesktop.org/software/pkgconfig" | |
12689 | fi | |
12690 | fi | |
12691 | ||
12692 | if test $succeeded = yes; then | |
12693 | HAVE_LIBXML2=yes | |
12694 | else | |
12695 | HAVE_LIBXML2=no | |
12696 | fi | |
12697 | ||
12698 | if test "${HAVE_LIBXML2}" = "yes"; then | |
12699 | LIBS="$LIBXML2_LIBS $LIBS" | |
12700 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5 | |
12701 | $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; } | |
d6974efa | 12702 | if ${ac_cv_lib_xml2_htmlReadMemory+:} false; then : |
067d23c9 KY |
12703 | $as_echo_n "(cached) " >&6 |
12704 | else | |
12705 | ac_check_lib_save_LIBS=$LIBS | |
12706 | LIBS="-lxml2 $LIBS" | |
12707 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12708 | /* end confdefs.h. */ | |
12709 | ||
12710 | /* Override any GCC internal prototype to avoid an error. | |
12711 | Use char because int might match the return type of a GCC | |
12712 | builtin and then its argument prototype would still apply. */ | |
12713 | #ifdef __cplusplus | |
12714 | extern "C" | |
12715 | #endif | |
12716 | char htmlReadMemory (); | |
12717 | int | |
12718 | main () | |
12719 | { | |
12720 | return htmlReadMemory (); | |
12721 | ; | |
12722 | return 0; | |
12723 | } | |
12724 | _ACEOF | |
12725 | if ac_fn_c_try_link "$LINENO"; then : | |
12726 | ac_cv_lib_xml2_htmlReadMemory=yes | |
12727 | else | |
12728 | ac_cv_lib_xml2_htmlReadMemory=no | |
12729 | fi | |
12730 | rm -f core conftest.err conftest.$ac_objext \ | |
12731 | conftest$ac_exeext conftest.$ac_ext | |
12732 | LIBS=$ac_check_lib_save_LIBS | |
12733 | fi | |
12734 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5 | |
12735 | $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; } | |
d6974efa | 12736 | if test "x$ac_cv_lib_xml2_htmlReadMemory" = xyes; then : |
067d23c9 KY |
12737 | HAVE_LIBXML2=yes |
12738 | else | |
12739 | HAVE_LIBXML2=no | |
12740 | fi | |
12741 | ||
12742 | if test "${HAVE_LIBXML2}" = "yes"; then | |
12743 | ||
12744 | $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h | |
12745 | ||
12746 | else | |
12747 | LIBXML2_LIBS="" | |
12748 | LIBXML2_CFLAGS="" | |
12749 | fi | |
12750 | fi | |
12751 | fi | |
12752 | ||
12753 | ||
12754 | ||
12755 | # If netdb.h doesn't declare h_errno, we must declare it by hand. | |
12756 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5 | |
12757 | $as_echo_n "checking whether netdb declares h_errno... " >&6; } | |
d6974efa | 12758 | if ${emacs_cv_netdb_declares_h_errno+:} false; then : |
067d23c9 KY |
12759 | $as_echo_n "(cached) " >&6 |
12760 | else | |
12761 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12762 | /* end confdefs.h. */ | |
12763 | #include <netdb.h> | |
12764 | int | |
12765 | main () | |
12766 | { | |
12767 | return h_errno; | |
12768 | ; | |
12769 | return 0; | |
12770 | } | |
12771 | _ACEOF | |
12772 | if ac_fn_c_try_link "$LINENO"; then : | |
12773 | emacs_cv_netdb_declares_h_errno=yes | |
12774 | else | |
12775 | emacs_cv_netdb_declares_h_errno=no | |
12776 | fi | |
12777 | rm -f core conftest.err conftest.$ac_objext \ | |
12778 | conftest$ac_exeext conftest.$ac_ext | |
12779 | fi | |
12780 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5 | |
12781 | $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; } | |
12782 | if test $emacs_cv_netdb_declares_h_errno = yes; then | |
12783 | ||
12784 | $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h | |
12785 | ||
12786 | fi | |
12787 | ||
d6974efa PE |
12788 | ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" |
12789 | if test "x$ac_cv_type_size_t" = xyes; then : | |
12790 | ||
12791 | else | |
12792 | ||
12793 | cat >>confdefs.h <<_ACEOF | |
12794 | #define size_t unsigned int | |
12795 | _ACEOF | |
12796 | ||
12797 | fi | |
12798 | ||
067d23c9 KY |
12799 | # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works |
12800 | # for constant arguments. Useless! | |
12801 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5 | |
12802 | $as_echo_n "checking for working alloca.h... " >&6; } | |
d6974efa | 12803 | if ${ac_cv_working_alloca_h+:} false; then : |
067d23c9 KY |
12804 | $as_echo_n "(cached) " >&6 |
12805 | else | |
12806 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12807 | /* end confdefs.h. */ | |
12808 | #include <alloca.h> | |
12809 | int | |
12810 | main () | |
12811 | { | |
12812 | char *p = (char *) alloca (2 * sizeof (int)); | |
12813 | if (p) return 0; | |
12814 | ; | |
12815 | return 0; | |
12816 | } | |
12817 | _ACEOF | |
12818 | if ac_fn_c_try_link "$LINENO"; then : | |
12819 | ac_cv_working_alloca_h=yes | |
12820 | else | |
12821 | ac_cv_working_alloca_h=no | |
12822 | fi | |
12823 | rm -f core conftest.err conftest.$ac_objext \ | |
12824 | conftest$ac_exeext conftest.$ac_ext | |
12825 | fi | |
12826 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5 | |
12827 | $as_echo "$ac_cv_working_alloca_h" >&6; } | |
12828 | if test $ac_cv_working_alloca_h = yes; then | |
12829 | ||
12830 | $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h | |
12831 | ||
12832 | fi | |
12833 | ||
12834 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5 | |
12835 | $as_echo_n "checking for alloca... " >&6; } | |
d6974efa | 12836 | if ${ac_cv_func_alloca_works+:} false; then : |
067d23c9 KY |
12837 | $as_echo_n "(cached) " >&6 |
12838 | else | |
12839 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12840 | /* end confdefs.h. */ | |
12841 | #ifdef __GNUC__ | |
12842 | # define alloca __builtin_alloca | |
12843 | #else | |
12844 | # ifdef _MSC_VER | |
12845 | # include <malloc.h> | |
12846 | # define alloca _alloca | |
12847 | # else | |
12848 | # ifdef HAVE_ALLOCA_H | |
12849 | # include <alloca.h> | |
12850 | # else | |
12851 | # ifdef _AIX | |
12852 | #pragma alloca | |
12853 | # else | |
12854 | # ifndef alloca /* predefined by HP cc +Olibcalls */ | |
d6974efa | 12855 | void *alloca (size_t); |
067d23c9 KY |
12856 | # endif |
12857 | # endif | |
12858 | # endif | |
12859 | # endif | |
12860 | #endif | |
12861 | ||
12862 | int | |
12863 | main () | |
12864 | { | |
12865 | char *p = (char *) alloca (1); | |
12866 | if (p) return 0; | |
12867 | ; | |
12868 | return 0; | |
12869 | } | |
12870 | _ACEOF | |
12871 | if ac_fn_c_try_link "$LINENO"; then : | |
12872 | ac_cv_func_alloca_works=yes | |
12873 | else | |
12874 | ac_cv_func_alloca_works=no | |
12875 | fi | |
12876 | rm -f core conftest.err conftest.$ac_objext \ | |
12877 | conftest$ac_exeext conftest.$ac_ext | |
12878 | fi | |
12879 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5 | |
12880 | $as_echo "$ac_cv_func_alloca_works" >&6; } | |
12881 | ||
12882 | if test $ac_cv_func_alloca_works = yes; then | |
12883 | ||
12884 | $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h | |
12885 | ||
12886 | else | |
12887 | # The SVR3 libPW and SVR4 libucb both contain incompatible functions | |
12888 | # that cause trouble. Some versions do not even contain alloca or | |
12889 | # contain a buggy version. If you still want to use their alloca, | |
12890 | # use ar to extract alloca.o from them instead of compiling alloca.c. | |
12891 | ||
12892 | ALLOCA=\${LIBOBJDIR}alloca.$ac_objext | |
12893 | ||
12894 | $as_echo "#define C_ALLOCA 1" >>confdefs.h | |
12895 | ||
12896 | ||
12897 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5 | |
12898 | $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; } | |
d6974efa | 12899 | if ${ac_cv_os_cray+:} false; then : |
067d23c9 KY |
12900 | $as_echo_n "(cached) " >&6 |
12901 | else | |
12902 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12903 | /* end confdefs.h. */ | |
12904 | #if defined CRAY && ! defined CRAY2 | |
12905 | webecray | |
12906 | #else | |
12907 | wenotbecray | |
12908 | #endif | |
12909 | ||
12910 | _ACEOF | |
12911 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
12912 | $EGREP "webecray" >/dev/null 2>&1; then : | |
12913 | ac_cv_os_cray=yes | |
12914 | else | |
12915 | ac_cv_os_cray=no | |
12916 | fi | |
12917 | rm -f conftest* | |
12918 | ||
12919 | fi | |
12920 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5 | |
12921 | $as_echo "$ac_cv_os_cray" >&6; } | |
12922 | if test $ac_cv_os_cray = yes; then | |
12923 | for ac_func in _getb67 GETB67 getb67; do | |
12924 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
12925 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
2018939f | 12926 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
067d23c9 KY |
12927 | |
12928 | cat >>confdefs.h <<_ACEOF | |
12929 | #define CRAY_STACKSEG_END $ac_func | |
12930 | _ACEOF | |
12931 | ||
12932 | break | |
12933 | fi | |
12934 | ||
12935 | done | |
12936 | fi | |
12937 | ||
12938 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 | |
12939 | $as_echo_n "checking stack direction for C alloca... " >&6; } | |
d6974efa | 12940 | if ${ac_cv_c_stack_direction+:} false; then : |
067d23c9 KY |
12941 | $as_echo_n "(cached) " >&6 |
12942 | else | |
12943 | if test "$cross_compiling" = yes; then : | |
12944 | ac_cv_c_stack_direction=0 | |
12945 | else | |
12946 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
12947 | /* end confdefs.h. */ | |
12948 | $ac_includes_default | |
12949 | int | |
12950 | find_stack_direction () | |
12951 | { | |
12952 | static char *addr = 0; | |
12953 | auto char dummy; | |
12954 | if (addr == 0) | |
12955 | { | |
12956 | addr = &dummy; | |
12957 | return find_stack_direction (); | |
12958 | } | |
12959 | else | |
12960 | return (&dummy > addr) ? 1 : -1; | |
12961 | } | |
12962 | ||
12963 | int | |
12964 | main () | |
12965 | { | |
12966 | return find_stack_direction () < 0; | |
12967 | } | |
12968 | _ACEOF | |
12969 | if ac_fn_c_try_run "$LINENO"; then : | |
12970 | ac_cv_c_stack_direction=1 | |
12971 | else | |
12972 | ac_cv_c_stack_direction=-1 | |
12973 | fi | |
12974 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
12975 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
12976 | fi | |
12977 | ||
12978 | fi | |
12979 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 | |
12980 | $as_echo "$ac_cv_c_stack_direction" >&6; } | |
12981 | cat >>confdefs.h <<_ACEOF | |
12982 | #define STACK_DIRECTION $ac_cv_c_stack_direction | |
12983 | _ACEOF | |
12984 | ||
12985 | ||
12986 | fi | |
12987 | ||
12988 | ||
12989 | if test x"$ac_cv_func_alloca_works" != xyes; then | |
2018939f | 12990 | as_fn_error $? "a system implementation of alloca is required " "$LINENO" 5 |
067d23c9 KY |
12991 | fi |
12992 | ||
12993 | # fmod, logb, and frexp are found in -lm on most systems. | |
12994 | # On HPUX 9.01, -lm does not contain logb, so check for sqrt. | |
12995 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5 | |
12996 | $as_echo_n "checking for sqrt in -lm... " >&6; } | |
d6974efa | 12997 | if ${ac_cv_lib_m_sqrt+:} false; then : |
067d23c9 KY |
12998 | $as_echo_n "(cached) " >&6 |
12999 | else | |
13000 | ac_check_lib_save_LIBS=$LIBS | |
13001 | LIBS="-lm $LIBS" | |
13002 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13003 | /* end confdefs.h. */ | |
13004 | ||
13005 | /* Override any GCC internal prototype to avoid an error. | |
13006 | Use char because int might match the return type of a GCC | |
13007 | builtin and then its argument prototype would still apply. */ | |
13008 | #ifdef __cplusplus | |
13009 | extern "C" | |
13010 | #endif | |
13011 | char sqrt (); | |
13012 | int | |
13013 | main () | |
13014 | { | |
13015 | return sqrt (); | |
13016 | ; | |
13017 | return 0; | |
13018 | } | |
13019 | _ACEOF | |
13020 | if ac_fn_c_try_link "$LINENO"; then : | |
13021 | ac_cv_lib_m_sqrt=yes | |
13022 | else | |
13023 | ac_cv_lib_m_sqrt=no | |
13024 | fi | |
13025 | rm -f core conftest.err conftest.$ac_objext \ | |
13026 | conftest$ac_exeext conftest.$ac_ext | |
13027 | LIBS=$ac_check_lib_save_LIBS | |
13028 | fi | |
13029 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5 | |
13030 | $as_echo "$ac_cv_lib_m_sqrt" >&6; } | |
d6974efa | 13031 | if test "x$ac_cv_lib_m_sqrt" = xyes; then : |
067d23c9 KY |
13032 | cat >>confdefs.h <<_ACEOF |
13033 | #define HAVE_LIBM 1 | |
13034 | _ACEOF | |
13035 | ||
13036 | LIBS="-lm $LIBS" | |
13037 | ||
13038 | fi | |
13039 | ||
13040 | ||
13041 | # Check for mail-locking functions in a "mail" library. Probably this should | |
13042 | # have the same check as for liblockfile below. | |
13043 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5 | |
13044 | $as_echo_n "checking for maillock in -lmail... " >&6; } | |
d6974efa | 13045 | if ${ac_cv_lib_mail_maillock+:} false; then : |
067d23c9 KY |
13046 | $as_echo_n "(cached) " >&6 |
13047 | else | |
13048 | ac_check_lib_save_LIBS=$LIBS | |
13049 | LIBS="-lmail $LIBS" | |
13050 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13051 | /* end confdefs.h. */ | |
13052 | ||
13053 | /* Override any GCC internal prototype to avoid an error. | |
13054 | Use char because int might match the return type of a GCC | |
13055 | builtin and then its argument prototype would still apply. */ | |
13056 | #ifdef __cplusplus | |
13057 | extern "C" | |
13058 | #endif | |
13059 | char maillock (); | |
13060 | int | |
13061 | main () | |
13062 | { | |
13063 | return maillock (); | |
13064 | ; | |
13065 | return 0; | |
13066 | } | |
13067 | _ACEOF | |
13068 | if ac_fn_c_try_link "$LINENO"; then : | |
13069 | ac_cv_lib_mail_maillock=yes | |
13070 | else | |
13071 | ac_cv_lib_mail_maillock=no | |
13072 | fi | |
13073 | rm -f core conftest.err conftest.$ac_objext \ | |
13074 | conftest$ac_exeext conftest.$ac_ext | |
13075 | LIBS=$ac_check_lib_save_LIBS | |
13076 | fi | |
13077 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5 | |
13078 | $as_echo "$ac_cv_lib_mail_maillock" >&6; } | |
d6974efa | 13079 | if test "x$ac_cv_lib_mail_maillock" = xyes; then : |
067d23c9 KY |
13080 | have_mail=yes |
13081 | else | |
13082 | have_mail=no | |
13083 | fi | |
13084 | ||
13085 | if test $have_mail = yes; then | |
13086 | LIBS_MAIL=-lmail | |
13087 | LIBS="$LIBS_MAIL $LIBS" | |
13088 | ||
13089 | $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h | |
13090 | ||
13091 | else | |
13092 | LIBS_MAIL= | |
13093 | fi | |
13094 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5 | |
13095 | $as_echo_n "checking for maillock in -llockfile... " >&6; } | |
d6974efa | 13096 | if ${ac_cv_lib_lockfile_maillock+:} false; then : |
067d23c9 KY |
13097 | $as_echo_n "(cached) " >&6 |
13098 | else | |
13099 | ac_check_lib_save_LIBS=$LIBS | |
13100 | LIBS="-llockfile $LIBS" | |
13101 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13102 | /* end confdefs.h. */ | |
13103 | ||
13104 | /* Override any GCC internal prototype to avoid an error. | |
13105 | Use char because int might match the return type of a GCC | |
13106 | builtin and then its argument prototype would still apply. */ | |
13107 | #ifdef __cplusplus | |
13108 | extern "C" | |
13109 | #endif | |
13110 | char maillock (); | |
13111 | int | |
13112 | main () | |
13113 | { | |
13114 | return maillock (); | |
13115 | ; | |
13116 | return 0; | |
13117 | } | |
13118 | _ACEOF | |
13119 | if ac_fn_c_try_link "$LINENO"; then : | |
13120 | ac_cv_lib_lockfile_maillock=yes | |
13121 | else | |
13122 | ac_cv_lib_lockfile_maillock=no | |
13123 | fi | |
13124 | rm -f core conftest.err conftest.$ac_objext \ | |
13125 | conftest$ac_exeext conftest.$ac_ext | |
13126 | LIBS=$ac_check_lib_save_LIBS | |
13127 | fi | |
13128 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5 | |
13129 | $as_echo "$ac_cv_lib_lockfile_maillock" >&6; } | |
d6974efa | 13130 | if test "x$ac_cv_lib_lockfile_maillock" = xyes; then : |
067d23c9 KY |
13131 | have_lockfile=yes |
13132 | else | |
13133 | have_lockfile=no | |
13134 | fi | |
13135 | ||
13136 | if test $have_lockfile = yes; then | |
13137 | LIBS_MAIL=-llockfile | |
13138 | LIBS="$LIBS_MAIL $LIBS" | |
13139 | ||
13140 | $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h | |
13141 | ||
13142 | else | |
13143 | # If we have the shared liblockfile, assume we must use it for mail | |
13144 | # locking (e.g. Debian). If we couldn't link against liblockfile | |
13145 | # (no liblockfile.a installed), ensure that we don't need to. | |
13146 | # Extract the first word of "liblockfile.so", so it can be a program name with args. | |
13147 | set dummy liblockfile.so; ac_word=$2 | |
13148 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
13149 | $as_echo_n "checking for $ac_word... " >&6; } | |
d6974efa | 13150 | if ${ac_cv_prog_liblockfile+:} false; then : |
067d23c9 KY |
13151 | $as_echo_n "(cached) " >&6 |
13152 | else | |
13153 | if test -n "$liblockfile"; then | |
13154 | ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test. | |
13155 | else | |
13156 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
13157 | as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH" | |
13158 | for as_dir in $as_dummy | |
13159 | do | |
13160 | IFS=$as_save_IFS | |
13161 | test -z "$as_dir" && as_dir=. | |
13162 | for ac_exec_ext in '' $ac_executable_extensions; do | |
13163 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
13164 | ac_cv_prog_liblockfile="yes" | |
13165 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
13166 | break 2 | |
13167 | fi | |
13168 | done | |
13169 | done | |
13170 | IFS=$as_save_IFS | |
13171 | ||
13172 | test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no" | |
13173 | fi | |
13174 | fi | |
13175 | liblockfile=$ac_cv_prog_liblockfile | |
13176 | if test -n "$liblockfile"; then | |
13177 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5 | |
13178 | $as_echo "$liblockfile" >&6; } | |
13179 | else | |
13180 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
13181 | $as_echo "no" >&6; } | |
13182 | fi | |
13183 | ||
13184 | ||
13185 | if test $ac_cv_prog_liblockfile = yes; then | |
2018939f | 13186 | as_fn_error $? "Shared liblockfile found but can't link against it. |
067d23c9 KY |
13187 | This probably means that movemail could lose mail. |
13188 | There may be a \`development' package to install containing liblockfile." "$LINENO" 5 | |
13189 | fi | |
13190 | fi | |
13191 | for ac_func in touchlock | |
13192 | do : | |
13193 | ac_fn_c_check_func "$LINENO" "touchlock" "ac_cv_func_touchlock" | |
d6974efa | 13194 | if test "x$ac_cv_func_touchlock" = xyes; then : |
067d23c9 KY |
13195 | cat >>confdefs.h <<_ACEOF |
13196 | #define HAVE_TOUCHLOCK 1 | |
13197 | _ACEOF | |
13198 | ||
13199 | fi | |
13200 | done | |
13201 | ||
13202 | for ac_header in maillock.h | |
13203 | do : | |
13204 | ac_fn_c_check_header_mongrel "$LINENO" "maillock.h" "ac_cv_header_maillock_h" "$ac_includes_default" | |
d6974efa | 13205 | if test "x$ac_cv_header_maillock_h" = xyes; then : |
067d23c9 KY |
13206 | cat >>confdefs.h <<_ACEOF |
13207 | #define HAVE_MAILLOCK_H 1 | |
13208 | _ACEOF | |
13209 | ||
13210 | fi | |
13211 | ||
13212 | done | |
13213 | ||
13214 | ||
13215 | ||
13216 | ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to | |
13217 | ## interlock access to the mail spool. The alternative is a lock file named | |
13218 | ## /usr/spool/mail/$USER.lock. | |
13219 | mail_lock=no | |
13220 | case "$opsys" in | |
13221 | aix4-2) mail_lock="lockf" ;; | |
13222 | ||
13223 | gnu|freebsd|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;; | |
13224 | ||
13225 | ## On GNU/Linux systems, both methods are used by various mail programs. | |
13226 | ## I assume most people are using newer mailers that have heard of flock. | |
13227 | ## Change this if you need to. | |
13228 | ## Debian contains a patch which says: ``On Debian/GNU/Linux systems, | |
13229 | ## configure gets the right answers, and that means *NOT* using flock. | |
13230 | ## Using flock is guaranteed to be the wrong thing. See Debian Policy | |
13231 | ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the | |
13232 | ## Debian maintainer hasn't provided a clean fix for Emacs. | |
13233 | ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and | |
13234 | ## HAVE_MAILLOCK_H are defined, so the following appears to be the | |
13235 | ## correct logic. -- fx | |
13236 | ## We must check for HAVE_LIBLOCKFILE too, as movemail does. | |
13237 | ## liblockfile is a Free Software replacement for libmail, used on | |
13238 | ## Debian systems and elsewhere. -rfr. | |
13239 | gnu-*) | |
13240 | mail_lock="flock" | |
13241 | if test $have_mail = yes || test $have_lockfile = yes; then | |
13242 | test $ac_cv_header_maillock_h = yes && mail_lock=no | |
13243 | fi | |
13244 | ;; | |
13245 | esac | |
13246 | ||
13247 | BLESSMAIL_TARGET= | |
13248 | case "$mail_lock" in | |
13249 | flock) | |
13250 | $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h | |
13251 | ;; | |
13252 | ||
13253 | lockf) | |
13254 | $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h | |
13255 | ;; | |
13256 | ||
13257 | *) BLESSMAIL_TARGET="need-blessmail" ;; | |
13258 | esac | |
13259 | ||
13260 | ||
13261 | ||
13262 | for ac_func in gethostname getdomainname dup2 \ | |
13263 | rename closedir mkdir rmdir sysinfo getrusage get_current_dir_name \ | |
13264 | random lrand48 logb frexp fmod rint cbrt ftime setsid \ | |
1fd182f0 | 13265 | strerror fpathconf select euidaccess getpagesize tzset setlocale \ |
067d23c9 KY |
13266 | utimes getrlimit setrlimit setpgid getcwd getwd shutdown getaddrinfo \ |
13267 | __fpending mblen mbrlen mbsinit strsignal setitimer ualarm strchr strrchr \ | |
13268 | sendto recvfrom getsockopt setsockopt getsockname getpeername \ | |
13269 | gai_strerror mkstemp getline getdelim mremap memmove fsync sync \ | |
13270 | memset memcmp difftime memcpy mempcpy mblen mbrlen posix_memalign \ | |
13271 | cfmakeraw cfsetspeed isnan copysign __executable_start | |
13272 | do : | |
13273 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
13274 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
2018939f | 13275 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
067d23c9 KY |
13276 | cat >>confdefs.h <<_ACEOF |
13277 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
13278 | _ACEOF | |
13279 | ||
13280 | fi | |
13281 | done | |
13282 | ||
13283 | ||
2018939f AS |
13284 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5 |
13285 | $as_echo_n "checking for __builtin_unwind_init... " >&6; } | |
d6974efa | 13286 | if ${emacs_cv_func___builtin_unwind_init+:} false; then : |
2018939f AS |
13287 | $as_echo_n "(cached) " >&6 |
13288 | else | |
13289 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13290 | /* end confdefs.h. */ | |
13291 | ||
13292 | int | |
13293 | main () | |
13294 | { | |
13295 | __builtin_unwind_init (); | |
13296 | ; | |
13297 | return 0; | |
13298 | } | |
13299 | _ACEOF | |
13300 | if ac_fn_c_try_link "$LINENO"; then : | |
13301 | emacs_cv_func___builtin_unwind_init=yes | |
13302 | else | |
13303 | emacs_cv_func___builtin_unwind_init=no | |
13304 | fi | |
13305 | rm -f core conftest.err conftest.$ac_objext \ | |
13306 | conftest$ac_exeext conftest.$ac_ext | |
13307 | fi | |
13308 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5 | |
13309 | $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; } | |
13310 | if test $emacs_cv_func___builtin_unwind_init = yes; then | |
13311 | ||
13312 | $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h | |
13313 | ||
13314 | fi | |
13315 | ||
067d23c9 KY |
13316 | for ac_header in sys/un.h |
13317 | do : | |
13318 | ac_fn_c_check_header_mongrel "$LINENO" "sys/un.h" "ac_cv_header_sys_un_h" "$ac_includes_default" | |
d6974efa | 13319 | if test "x$ac_cv_header_sys_un_h" = xyes; then : |
067d23c9 KY |
13320 | cat >>confdefs.h <<_ACEOF |
13321 | #define HAVE_SYS_UN_H 1 | |
13322 | _ACEOF | |
13323 | ||
13324 | fi | |
13325 | ||
13326 | done | |
13327 | ||
13328 | ||
1f5d53eb PE |
13329 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5 |
13330 | $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; } | |
13331 | if ${ac_cv_sys_largefile_source+:} false; then : | |
067d23c9 KY |
13332 | $as_echo_n "(cached) " >&6 |
13333 | else | |
1f5d53eb PE |
13334 | while :; do |
13335 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
067d23c9 | 13336 | /* end confdefs.h. */ |
1f5d53eb PE |
13337 | #include <sys/types.h> /* for off_t */ |
13338 | #include <stdio.h> | |
067d23c9 KY |
13339 | int |
13340 | main () | |
13341 | { | |
1f5d53eb PE |
13342 | int (*fp) (FILE *, off_t, int) = fseeko; |
13343 | return fseeko (stdin, 0, 0) && fp (stdin, 0, 0); | |
067d23c9 KY |
13344 | ; |
13345 | return 0; | |
13346 | } | |
13347 | _ACEOF | |
13348 | if ac_fn_c_try_link "$LINENO"; then : | |
1f5d53eb | 13349 | ac_cv_sys_largefile_source=no; break |
067d23c9 KY |
13350 | fi |
13351 | rm -f core conftest.err conftest.$ac_objext \ | |
13352 | conftest$ac_exeext conftest.$ac_ext | |
1f5d53eb | 13353 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
067d23c9 | 13354 | /* end confdefs.h. */ |
1f5d53eb PE |
13355 | #define _LARGEFILE_SOURCE 1 |
13356 | #include <sys/types.h> /* for off_t */ | |
13357 | #include <stdio.h> | |
067d23c9 KY |
13358 | int |
13359 | main () | |
13360 | { | |
1f5d53eb PE |
13361 | int (*fp) (FILE *, off_t, int) = fseeko; |
13362 | return fseeko (stdin, 0, 0) && fp (stdin, 0, 0); | |
067d23c9 KY |
13363 | ; |
13364 | return 0; | |
13365 | } | |
13366 | _ACEOF | |
13367 | if ac_fn_c_try_link "$LINENO"; then : | |
1f5d53eb | 13368 | ac_cv_sys_largefile_source=1; break |
067d23c9 KY |
13369 | fi |
13370 | rm -f core conftest.err conftest.$ac_objext \ | |
13371 | conftest$ac_exeext conftest.$ac_ext | |
1f5d53eb PE |
13372 | ac_cv_sys_largefile_source=unknown |
13373 | break | |
13374 | done | |
067d23c9 | 13375 | fi |
1f5d53eb PE |
13376 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5 |
13377 | $as_echo "$ac_cv_sys_largefile_source" >&6; } | |
13378 | case $ac_cv_sys_largefile_source in #( | |
13379 | no | unknown) ;; | |
13380 | *) | |
13381 | cat >>confdefs.h <<_ACEOF | |
13382 | #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source | |
13383 | _ACEOF | |
13384 | ;; | |
13385 | esac | |
13386 | rm -rf conftest* | |
067d23c9 | 13387 | |
1f5d53eb PE |
13388 | # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug |
13389 | # in glibc 2.1.3, but that breaks too many other things. | |
13390 | # If you want fseeko and ftello with glibc, upgrade to a fixed glibc. | |
13391 | if test $ac_cv_sys_largefile_source != unknown; then | |
13392 | ||
13393 | $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h | |
067d23c9 | 13394 | |
067d23c9 KY |
13395 | fi |
13396 | ||
1f5d53eb PE |
13397 | |
13398 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5 | |
13399 | $as_echo_n "checking whether getpgrp requires zero arguments... " >&6; } | |
13400 | if ${ac_cv_func_getpgrp_void+:} false; then : | |
067d23c9 KY |
13401 | $as_echo_n "(cached) " >&6 |
13402 | else | |
1f5d53eb | 13403 | # Use it with a single arg. |
067d23c9 KY |
13404 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
13405 | /* end confdefs.h. */ | |
1f5d53eb | 13406 | $ac_includes_default |
067d23c9 KY |
13407 | int |
13408 | main () | |
13409 | { | |
1f5d53eb | 13410 | getpgrp (0); |
067d23c9 KY |
13411 | ; |
13412 | return 0; | |
13413 | } | |
13414 | _ACEOF | |
1f5d53eb PE |
13415 | if ac_fn_c_try_compile "$LINENO"; then : |
13416 | ac_cv_func_getpgrp_void=no | |
067d23c9 | 13417 | else |
1f5d53eb | 13418 | ac_cv_func_getpgrp_void=yes |
067d23c9 | 13419 | fi |
1f5d53eb PE |
13420 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
13421 | ||
067d23c9 | 13422 | fi |
1f5d53eb PE |
13423 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5 |
13424 | $as_echo "$ac_cv_func_getpgrp_void" >&6; } | |
13425 | if test $ac_cv_func_getpgrp_void = yes; then | |
13426 | ||
13427 | $as_echo "#define GETPGRP_VOID 1" >>confdefs.h | |
067d23c9 KY |
13428 | |
13429 | fi | |
13430 | ||
1f5d53eb PE |
13431 | |
13432 | # Configure gnulib. | |
13433 | ||
13434 | ||
13435 | ||
13436 | ||
13437 | ||
13438 | ||
13439 | ||
13440 | ||
13441 | ||
13442 | ||
13443 | LIBC_FATAL_STDERR_=1 | |
13444 | export LIBC_FATAL_STDERR_ | |
13445 | ||
13446 | ||
942f733f PE |
13447 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 |
13448 | $as_echo_n "checking whether byte ordering is bigendian... " >&6; } | |
13449 | if ${ac_cv_c_bigendian+:} false; then : | |
13450 | $as_echo_n "(cached) " >&6 | |
13451 | else | |
13452 | ac_cv_c_bigendian=unknown | |
13453 | # See if we're dealing with a universal compiler. | |
13454 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13455 | /* end confdefs.h. */ | |
13456 | #ifndef __APPLE_CC__ | |
13457 | not a universal capable compiler | |
13458 | #endif | |
13459 | typedef int dummy; | |
13460 | ||
13461 | _ACEOF | |
13462 | if ac_fn_c_try_compile "$LINENO"; then : | |
13463 | ||
13464 | # Check for potential -arch flags. It is not universal unless | |
13465 | # there are at least two -arch flags with different values. | |
13466 | ac_arch= | |
13467 | ac_prev= | |
13468 | for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do | |
13469 | if test -n "$ac_prev"; then | |
13470 | case $ac_word in | |
13471 | i?86 | x86_64 | ppc | ppc64) | |
13472 | if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then | |
13473 | ac_arch=$ac_word | |
13474 | else | |
13475 | ac_cv_c_bigendian=universal | |
13476 | break | |
13477 | fi | |
13478 | ;; | |
13479 | esac | |
13480 | ac_prev= | |
13481 | elif test "x$ac_word" = "x-arch"; then | |
13482 | ac_prev=arch | |
13483 | fi | |
13484 | done | |
13485 | fi | |
13486 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
13487 | if test $ac_cv_c_bigendian = unknown; then | |
13488 | # See if sys/param.h defines the BYTE_ORDER macro. | |
13489 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13490 | /* end confdefs.h. */ | |
13491 | #include <sys/types.h> | |
13492 | #include <sys/param.h> | |
13493 | ||
13494 | int | |
13495 | main () | |
13496 | { | |
13497 | #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ | |
13498 | && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ | |
13499 | && LITTLE_ENDIAN) | |
13500 | bogus endian macros | |
13501 | #endif | |
13502 | ||
13503 | ; | |
13504 | return 0; | |
13505 | } | |
13506 | _ACEOF | |
13507 | if ac_fn_c_try_compile "$LINENO"; then : | |
13508 | # It does; now see whether it defined to BIG_ENDIAN or not. | |
13509 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13510 | /* end confdefs.h. */ | |
13511 | #include <sys/types.h> | |
13512 | #include <sys/param.h> | |
13513 | ||
13514 | int | |
13515 | main () | |
13516 | { | |
13517 | #if BYTE_ORDER != BIG_ENDIAN | |
13518 | not big endian | |
13519 | #endif | |
13520 | ||
13521 | ; | |
13522 | return 0; | |
13523 | } | |
13524 | _ACEOF | |
13525 | if ac_fn_c_try_compile "$LINENO"; then : | |
13526 | ac_cv_c_bigendian=yes | |
13527 | else | |
13528 | ac_cv_c_bigendian=no | |
13529 | fi | |
13530 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
13531 | fi | |
13532 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
13533 | fi | |
13534 | if test $ac_cv_c_bigendian = unknown; then | |
13535 | # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). | |
13536 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13537 | /* end confdefs.h. */ | |
13538 | #include <limits.h> | |
13539 | ||
13540 | int | |
13541 | main () | |
13542 | { | |
13543 | #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) | |
13544 | bogus endian macros | |
13545 | #endif | |
13546 | ||
13547 | ; | |
13548 | return 0; | |
13549 | } | |
13550 | _ACEOF | |
13551 | if ac_fn_c_try_compile "$LINENO"; then : | |
13552 | # It does; now see whether it defined to _BIG_ENDIAN or not. | |
13553 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13554 | /* end confdefs.h. */ | |
13555 | #include <limits.h> | |
13556 | ||
13557 | int | |
13558 | main () | |
13559 | { | |
13560 | #ifndef _BIG_ENDIAN | |
13561 | not big endian | |
13562 | #endif | |
13563 | ||
13564 | ; | |
13565 | return 0; | |
13566 | } | |
13567 | _ACEOF | |
13568 | if ac_fn_c_try_compile "$LINENO"; then : | |
13569 | ac_cv_c_bigendian=yes | |
13570 | else | |
13571 | ac_cv_c_bigendian=no | |
13572 | fi | |
13573 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
13574 | fi | |
13575 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
13576 | fi | |
13577 | if test $ac_cv_c_bigendian = unknown; then | |
13578 | # Compile a test program. | |
13579 | if test "$cross_compiling" = yes; then : | |
13580 | # Try to guess by grepping values from an object file. | |
13581 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13582 | /* end confdefs.h. */ | |
13583 | short int ascii_mm[] = | |
13584 | { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; | |
13585 | short int ascii_ii[] = | |
13586 | { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; | |
13587 | int use_ascii (int i) { | |
13588 | return ascii_mm[i] + ascii_ii[i]; | |
13589 | } | |
13590 | short int ebcdic_ii[] = | |
13591 | { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; | |
13592 | short int ebcdic_mm[] = | |
13593 | { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; | |
13594 | int use_ebcdic (int i) { | |
13595 | return ebcdic_mm[i] + ebcdic_ii[i]; | |
13596 | } | |
13597 | extern int foo; | |
13598 | ||
13599 | int | |
13600 | main () | |
13601 | { | |
13602 | return use_ascii (foo) == use_ebcdic (foo); | |
13603 | ; | |
13604 | return 0; | |
13605 | } | |
13606 | _ACEOF | |
13607 | if ac_fn_c_try_compile "$LINENO"; then : | |
13608 | if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then | |
13609 | ac_cv_c_bigendian=yes | |
13610 | fi | |
13611 | if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then | |
13612 | if test "$ac_cv_c_bigendian" = unknown; then | |
13613 | ac_cv_c_bigendian=no | |
13614 | else | |
13615 | # finding both strings is unlikely to happen, but who knows? | |
13616 | ac_cv_c_bigendian=unknown | |
13617 | fi | |
13618 | fi | |
13619 | fi | |
13620 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
13621 | else | |
13622 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13623 | /* end confdefs.h. */ | |
13624 | $ac_includes_default | |
13625 | int | |
13626 | main () | |
13627 | { | |
13628 | ||
13629 | /* Are we little or big endian? From Harbison&Steele. */ | |
13630 | union | |
13631 | { | |
13632 | long int l; | |
13633 | char c[sizeof (long int)]; | |
13634 | } u; | |
13635 | u.l = 1; | |
13636 | return u.c[sizeof (long int) - 1] == 1; | |
13637 | ||
13638 | ; | |
13639 | return 0; | |
13640 | } | |
13641 | _ACEOF | |
13642 | if ac_fn_c_try_run "$LINENO"; then : | |
13643 | ac_cv_c_bigendian=no | |
13644 | else | |
13645 | ac_cv_c_bigendian=yes | |
13646 | fi | |
13647 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
13648 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
13649 | fi | |
13650 | ||
13651 | fi | |
13652 | fi | |
13653 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 | |
13654 | $as_echo "$ac_cv_c_bigendian" >&6; } | |
13655 | case $ac_cv_c_bigendian in #( | |
13656 | yes) | |
13657 | $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h | |
13658 | ;; #( | |
13659 | no) | |
13660 | ;; #( | |
13661 | universal) | |
13662 | ||
13663 | $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h | |
13664 | ||
13665 | ;; #( | |
13666 | *) | |
13667 | as_fn_error $? "unknown endianness | |
13668 | presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; | |
13669 | esac | |
13670 | ||
13671 | ||
13672 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 | |
13673 | $as_echo_n "checking for inline... " >&6; } | |
13674 | if ${ac_cv_c_inline+:} false; then : | |
13675 | $as_echo_n "(cached) " >&6 | |
13676 | else | |
13677 | ac_cv_c_inline=no | |
13678 | for ac_kw in inline __inline__ __inline; do | |
13679 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13680 | /* end confdefs.h. */ | |
13681 | #ifndef __cplusplus | |
13682 | typedef int foo_t; | |
13683 | static $ac_kw foo_t static_foo () {return 0; } | |
13684 | $ac_kw foo_t foo () {return 0; } | |
13685 | #endif | |
13686 | ||
13687 | _ACEOF | |
13688 | if ac_fn_c_try_compile "$LINENO"; then : | |
13689 | ac_cv_c_inline=$ac_kw | |
13690 | fi | |
13691 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
13692 | test "$ac_cv_c_inline" != no && break | |
13693 | done | |
13694 | ||
13695 | fi | |
13696 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 | |
13697 | $as_echo "$ac_cv_c_inline" >&6; } | |
13698 | ||
13699 | case $ac_cv_c_inline in | |
13700 | inline | yes) ;; | |
13701 | *) | |
13702 | case $ac_cv_c_inline in | |
13703 | no) ac_val=;; | |
13704 | *) ac_val=$ac_cv_c_inline;; | |
13705 | esac | |
13706 | cat >>confdefs.h <<_ACEOF | |
13707 | #ifndef __cplusplus | |
13708 | #define inline $ac_val | |
13709 | #endif | |
13710 | _ACEOF | |
13711 | ;; | |
13712 | esac | |
13713 | ||
13714 | ||
1f5d53eb PE |
13715 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5 |
13716 | $as_echo_n "checking whether strtold conforms to C99... " >&6; } | |
13717 | if ${gl_cv_func_c99_strtold+:} false; then : | |
067d23c9 KY |
13718 | $as_echo_n "(cached) " >&6 |
13719 | else | |
1f5d53eb | 13720 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
067d23c9 | 13721 | /* end confdefs.h. */ |
1f5d53eb PE |
13722 | /* On HP-UX before 11.23, strtold returns a struct instead of |
13723 | long double. Reject implementations like that, by requiring | |
13724 | compatibility with the C99 prototype. */ | |
13725 | #include <stdlib.h> | |
13726 | static long double (*p) (char const *, char **) = strtold; | |
13727 | static long double | |
13728 | test (char const *nptr, char **endptr) | |
13729 | { | |
13730 | long double r; | |
13731 | r = strtold (nptr, endptr); | |
13732 | return r; | |
13733 | } | |
067d23c9 KY |
13734 | int |
13735 | main () | |
13736 | { | |
1f5d53eb | 13737 | return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1; |
067d23c9 KY |
13738 | ; |
13739 | return 0; | |
13740 | } | |
13741 | _ACEOF | |
13742 | if ac_fn_c_try_link "$LINENO"; then : | |
1f5d53eb | 13743 | gl_cv_func_c99_strtold=yes |
067d23c9 | 13744 | else |
1f5d53eb | 13745 | gl_cv_func_c99_strtold=no |
067d23c9 KY |
13746 | fi |
13747 | rm -f core conftest.err conftest.$ac_objext \ | |
13748 | conftest$ac_exeext conftest.$ac_ext | |
067d23c9 | 13749 | fi |
1f5d53eb PE |
13750 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5 |
13751 | $as_echo "$gl_cv_func_c99_strtold" >&6; } | |
13752 | if test $gl_cv_func_c99_strtold = yes; then | |
067d23c9 | 13753 | |
1f5d53eb | 13754 | $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h |
067d23c9 | 13755 | |
1f5d53eb | 13756 | fi |
067d23c9 | 13757 | |
5fa4ac76 PE |
13758 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5 |
13759 | $as_echo_n "checking for st_dm_mode in struct stat... " >&6; } | |
13760 | if ${ac_cv_struct_st_dm_mode+:} false; then : | |
13761 | $as_echo_n "(cached) " >&6 | |
13762 | else | |
13763 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13764 | /* end confdefs.h. */ | |
13765 | ||
13766 | #include <sys/types.h> | |
13767 | #include <sys/stat.h> | |
13768 | int | |
13769 | main () | |
13770 | { | |
13771 | struct stat s; s.st_dm_mode; | |
13772 | ; | |
13773 | return 0; | |
13774 | } | |
13775 | _ACEOF | |
13776 | if ac_fn_c_try_compile "$LINENO"; then : | |
13777 | ac_cv_struct_st_dm_mode=yes | |
13778 | else | |
13779 | ac_cv_struct_st_dm_mode=no | |
13780 | fi | |
13781 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
13782 | fi | |
13783 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5 | |
13784 | $as_echo "$ac_cv_struct_st_dm_mode" >&6; } | |
13785 | ||
13786 | if test $ac_cv_struct_st_dm_mode = yes; then | |
13787 | ||
13788 | $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h | |
13789 | ||
13790 | fi | |
13791 | ||
13792 | ||
13793 | ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default" | |
13794 | if test "x$ac_cv_have_decl_strmode" = xyes; then : | |
13795 | ac_have_decl=1 | |
13796 | else | |
13797 | ac_have_decl=0 | |
13798 | fi | |
13799 | ||
13800 | cat >>confdefs.h <<_ACEOF | |
13801 | #define HAVE_DECL_STRMODE $ac_have_decl | |
13802 | _ACEOF | |
13803 | ||
067d23c9 | 13804 | |
1f5d53eb PE |
13805 | GNULIB__EXIT=0; |
13806 | GNULIB_ATOLL=0; | |
13807 | GNULIB_CALLOC_POSIX=0; | |
13808 | GNULIB_CANONICALIZE_FILE_NAME=0; | |
13809 | GNULIB_GETLOADAVG=0; | |
13810 | GNULIB_GETSUBOPT=0; | |
13811 | GNULIB_GRANTPT=0; | |
13812 | GNULIB_MALLOC_POSIX=0; | |
13813 | GNULIB_MKDTEMP=0; | |
13814 | GNULIB_MKOSTEMP=0; | |
13815 | GNULIB_MKOSTEMPS=0; | |
13816 | GNULIB_MKSTEMP=0; | |
13817 | GNULIB_MKSTEMPS=0; | |
13818 | GNULIB_PTSNAME=0; | |
13819 | GNULIB_PUTENV=0; | |
13820 | GNULIB_RANDOM_R=0; | |
13821 | GNULIB_REALLOC_POSIX=0; | |
13822 | GNULIB_REALPATH=0; | |
13823 | GNULIB_RPMATCH=0; | |
13824 | GNULIB_SETENV=0; | |
13825 | GNULIB_STRTOD=0; | |
13826 | GNULIB_STRTOLL=0; | |
13827 | GNULIB_STRTOULL=0; | |
13828 | GNULIB_SYSTEM_POSIX=0; | |
13829 | GNULIB_UNLOCKPT=0; | |
13830 | GNULIB_UNSETENV=0; | |
13831 | HAVE__EXIT=1; | |
13832 | HAVE_ATOLL=1; | |
13833 | HAVE_CANONICALIZE_FILE_NAME=1; | |
13834 | HAVE_DECL_GETLOADAVG=1; | |
13835 | HAVE_GETSUBOPT=1; | |
13836 | HAVE_GRANTPT=1; | |
13837 | HAVE_MKDTEMP=1; | |
13838 | HAVE_MKOSTEMP=1; | |
13839 | HAVE_MKOSTEMPS=1; | |
13840 | HAVE_MKSTEMP=1; | |
13841 | HAVE_MKSTEMPS=1; | |
13842 | HAVE_PTSNAME=1; | |
13843 | HAVE_RANDOM_H=1; | |
13844 | HAVE_RANDOM_R=1; | |
13845 | HAVE_REALPATH=1; | |
13846 | HAVE_RPMATCH=1; | |
13847 | HAVE_SETENV=1; | |
13848 | HAVE_DECL_SETENV=1; | |
13849 | HAVE_STRTOD=1; | |
13850 | HAVE_STRTOLL=1; | |
13851 | HAVE_STRTOULL=1; | |
13852 | HAVE_STRUCT_RANDOM_DATA=1; | |
13853 | HAVE_SYS_LOADAVG_H=0; | |
13854 | HAVE_UNLOCKPT=1; | |
13855 | HAVE_DECL_UNSETENV=1; | |
13856 | REPLACE_CALLOC=0; | |
13857 | REPLACE_CANONICALIZE_FILE_NAME=0; | |
13858 | REPLACE_MALLOC=0; | |
13859 | REPLACE_MKSTEMP=0; | |
13860 | REPLACE_PUTENV=0; | |
13861 | REPLACE_REALLOC=0; | |
13862 | REPLACE_REALPATH=0; | |
13863 | REPLACE_SETENV=0; | |
13864 | REPLACE_STRTOD=0; | |
13865 | REPLACE_UNSETENV=0; | |
067d23c9 | 13866 | |
067d23c9 | 13867 | |
1f5d53eb PE |
13868 | GNULIB_CHOWN=0; |
13869 | GNULIB_CLOSE=0; | |
13870 | GNULIB_DUP2=0; | |
13871 | GNULIB_DUP3=0; | |
13872 | GNULIB_ENVIRON=0; | |
13873 | GNULIB_EUIDACCESS=0; | |
13874 | GNULIB_FACCESSAT=0; | |
13875 | GNULIB_FCHDIR=0; | |
13876 | GNULIB_FCHOWNAT=0; | |
13877 | GNULIB_FSYNC=0; | |
13878 | GNULIB_FTRUNCATE=0; | |
13879 | GNULIB_GETCWD=0; | |
13880 | GNULIB_GETDOMAINNAME=0; | |
13881 | GNULIB_GETDTABLESIZE=0; | |
13882 | GNULIB_GETGROUPS=0; | |
13883 | GNULIB_GETHOSTNAME=0; | |
13884 | GNULIB_GETLOGIN=0; | |
13885 | GNULIB_GETLOGIN_R=0; | |
13886 | GNULIB_GETPAGESIZE=0; | |
13887 | GNULIB_GETUSERSHELL=0; | |
13888 | GNULIB_LCHOWN=0; | |
13889 | GNULIB_LINK=0; | |
13890 | GNULIB_LINKAT=0; | |
13891 | GNULIB_LSEEK=0; | |
13892 | GNULIB_PIPE=0; | |
13893 | GNULIB_PIPE2=0; | |
13894 | GNULIB_PREAD=0; | |
13895 | GNULIB_PWRITE=0; | |
13896 | GNULIB_READLINK=0; | |
13897 | GNULIB_READLINKAT=0; | |
13898 | GNULIB_RMDIR=0; | |
13899 | GNULIB_SLEEP=0; | |
13900 | GNULIB_SYMLINK=0; | |
13901 | GNULIB_SYMLINKAT=0; | |
13902 | GNULIB_TTYNAME_R=0; | |
13903 | GNULIB_UNISTD_H_GETOPT=0; | |
13904 | GNULIB_UNISTD_H_SIGPIPE=0; | |
13905 | GNULIB_UNLINK=0; | |
13906 | GNULIB_UNLINKAT=0; | |
13907 | GNULIB_USLEEP=0; | |
13908 | GNULIB_WRITE=0; | |
13909 | HAVE_CHOWN=1; | |
13910 | HAVE_DUP2=1; | |
13911 | HAVE_DUP3=1; | |
13912 | HAVE_EUIDACCESS=1; | |
13913 | HAVE_FACCESSAT=1; | |
13914 | HAVE_FCHDIR=1; | |
13915 | HAVE_FCHOWNAT=1; | |
13916 | HAVE_FSYNC=1; | |
13917 | HAVE_FTRUNCATE=1; | |
13918 | HAVE_GETDTABLESIZE=1; | |
13919 | HAVE_GETGROUPS=1; | |
13920 | HAVE_GETHOSTNAME=1; | |
13921 | HAVE_GETLOGIN=1; | |
13922 | HAVE_GETPAGESIZE=1; | |
13923 | HAVE_LCHOWN=1; | |
13924 | HAVE_LINK=1; | |
13925 | HAVE_LINKAT=1; | |
13926 | HAVE_PIPE=1; | |
13927 | HAVE_PIPE2=1; | |
13928 | HAVE_PREAD=1; | |
13929 | HAVE_PWRITE=1; | |
13930 | HAVE_READLINK=1; | |
13931 | HAVE_READLINKAT=1; | |
13932 | HAVE_SLEEP=1; | |
13933 | HAVE_SYMLINK=1; | |
13934 | HAVE_SYMLINKAT=1; | |
13935 | HAVE_UNLINKAT=1; | |
13936 | HAVE_USLEEP=1; | |
13937 | HAVE_DECL_ENVIRON=1; | |
13938 | HAVE_DECL_FCHDIR=1; | |
13939 | HAVE_DECL_GETDOMAINNAME=1; | |
13940 | HAVE_DECL_GETLOGIN_R=1; | |
13941 | HAVE_DECL_GETPAGESIZE=1; | |
13942 | HAVE_DECL_GETUSERSHELL=1; | |
13943 | HAVE_DECL_TTYNAME_R=1; | |
13944 | HAVE_OS_H=0; | |
13945 | HAVE_SYS_PARAM_H=0; | |
13946 | REPLACE_CHOWN=0; | |
13947 | REPLACE_CLOSE=0; | |
13948 | REPLACE_DUP=0; | |
13949 | REPLACE_DUP2=0; | |
13950 | REPLACE_FCHOWNAT=0; | |
13951 | REPLACE_GETCWD=0; | |
13952 | REPLACE_GETDOMAINNAME=0; | |
13953 | REPLACE_GETLOGIN_R=0; | |
13954 | REPLACE_GETGROUPS=0; | |
13955 | REPLACE_GETPAGESIZE=0; | |
13956 | REPLACE_LCHOWN=0; | |
13957 | REPLACE_LINK=0; | |
13958 | REPLACE_LINKAT=0; | |
13959 | REPLACE_LSEEK=0; | |
13960 | REPLACE_PREAD=0; | |
13961 | REPLACE_PWRITE=0; | |
13962 | REPLACE_READLINK=0; | |
13963 | REPLACE_RMDIR=0; | |
13964 | REPLACE_SLEEP=0; | |
13965 | REPLACE_SYMLINK=0; | |
13966 | REPLACE_TTYNAME_R=0; | |
13967 | REPLACE_UNLINK=0; | |
13968 | REPLACE_UNLINKAT=0; | |
13969 | REPLACE_USLEEP=0; | |
13970 | REPLACE_WRITE=0; | |
13971 | UNISTD_H_HAVE_WINSOCK2_H=0; | |
13972 | UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0; | |
067d23c9 | 13973 | |
067d23c9 | 13974 | |
1f5d53eb PE |
13975 | |
13976 | ||
13977 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5 | |
13978 | $as_echo_n "checking whether the preprocessor supports include_next... " >&6; } | |
13979 | if ${gl_cv_have_include_next+:} false; then : | |
067d23c9 KY |
13980 | $as_echo_n "(cached) " >&6 |
13981 | else | |
1f5d53eb PE |
13982 | rm -rf conftestd1a conftestd1b conftestd2 |
13983 | mkdir conftestd1a conftestd1b conftestd2 | |
13984 | cat <<EOF > conftestd1a/conftest.h | |
13985 | #define DEFINED_IN_CONFTESTD1 | |
13986 | #include_next <conftest.h> | |
13987 | #ifdef DEFINED_IN_CONFTESTD2 | |
13988 | int foo; | |
13989 | #else | |
13990 | #error "include_next doesn't work" | |
067d23c9 | 13991 | #endif |
1f5d53eb PE |
13992 | EOF |
13993 | cat <<EOF > conftestd1b/conftest.h | |
13994 | #define DEFINED_IN_CONFTESTD1 | |
13995 | #include <stdio.h> | |
13996 | #include_next <conftest.h> | |
13997 | #ifdef DEFINED_IN_CONFTESTD2 | |
13998 | int foo; | |
13999 | #else | |
14000 | #error "include_next doesn't work" | |
14001 | #endif | |
14002 | EOF | |
14003 | cat <<EOF > conftestd2/conftest.h | |
14004 | #ifndef DEFINED_IN_CONFTESTD1 | |
14005 | #error "include_next test doesn't work" | |
14006 | #endif | |
14007 | #define DEFINED_IN_CONFTESTD2 | |
14008 | EOF | |
14009 | gl_save_CPPFLAGS="$CPPFLAGS" | |
14010 | CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2" | |
14011 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
14012 | /* end confdefs.h. */ | |
14013 | #include <conftest.h> | |
067d23c9 | 14014 | _ACEOF |
1f5d53eb PE |
14015 | if ac_fn_c_try_compile "$LINENO"; then : |
14016 | gl_cv_have_include_next=yes | |
067d23c9 | 14017 | else |
1f5d53eb PE |
14018 | CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2" |
14019 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
14020 | /* end confdefs.h. */ | |
14021 | #include <conftest.h> | |
067d23c9 | 14022 | _ACEOF |
1f5d53eb PE |
14023 | if ac_fn_c_try_compile "$LINENO"; then : |
14024 | gl_cv_have_include_next=buggy | |
14025 | else | |
14026 | gl_cv_have_include_next=no | |
067d23c9 | 14027 | fi |
1f5d53eb | 14028 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
067d23c9 KY |
14029 | |
14030 | fi | |
1f5d53eb PE |
14031 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
14032 | CPPFLAGS="$gl_save_CPPFLAGS" | |
14033 | rm -rf conftestd1a conftestd1b conftestd2 | |
067d23c9 | 14034 | |
1f5d53eb PE |
14035 | fi |
14036 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5 | |
14037 | $as_echo "$gl_cv_have_include_next" >&6; } | |
14038 | PRAGMA_SYSTEM_HEADER= | |
14039 | if test $gl_cv_have_include_next = yes; then | |
14040 | INCLUDE_NEXT=include_next | |
14041 | INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next | |
14042 | if test -n "$GCC"; then | |
14043 | PRAGMA_SYSTEM_HEADER='#pragma GCC system_header' | |
14044 | fi | |
14045 | else | |
14046 | if test $gl_cv_have_include_next = buggy; then | |
14047 | INCLUDE_NEXT=include | |
14048 | INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next | |
14049 | else | |
14050 | INCLUDE_NEXT=include | |
14051 | INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include | |
14052 | fi | |
14053 | fi | |
067d23c9 KY |
14054 | |
14055 | ||
067d23c9 | 14056 | |
1f5d53eb PE |
14057 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5 |
14058 | $as_echo_n "checking whether system header files limit the line length... " >&6; } | |
14059 | if ${gl_cv_pragma_columns+:} false; then : | |
14060 | $as_echo_n "(cached) " >&6 | |
14061 | else | |
14062 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
14063 | /* end confdefs.h. */ | |
067d23c9 | 14064 | |
1f5d53eb PE |
14065 | #ifdef __TANDEM |
14066 | choke me | |
14067 | #endif | |
067d23c9 | 14068 | |
067d23c9 | 14069 | _ACEOF |
1f5d53eb PE |
14070 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
14071 | $EGREP "choke me" >/dev/null 2>&1; then : | |
14072 | gl_cv_pragma_columns=yes | |
14073 | else | |
14074 | gl_cv_pragma_columns=no | |
067d23c9 | 14075 | fi |
1f5d53eb | 14076 | rm -f conftest* |
067d23c9 | 14077 | |
067d23c9 KY |
14078 | |
14079 | fi | |
1f5d53eb PE |
14080 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5 |
14081 | $as_echo "$gl_cv_pragma_columns" >&6; } | |
14082 | if test $gl_cv_pragma_columns = yes; then | |
14083 | PRAGMA_COLUMNS="#pragma COLUMNS 10000" | |
14084 | else | |
14085 | PRAGMA_COLUMNS= | |
14086 | fi | |
067d23c9 | 14087 | |
067d23c9 | 14088 | |
067d23c9 KY |
14089 | |
14090 | ||
067d23c9 | 14091 | |
067d23c9 KY |
14092 | |
14093 | ||
067d23c9 | 14094 | |
067d23c9 | 14095 | |
067d23c9 KY |
14096 | |
14097 | ||
067d23c9 | 14098 | |
067d23c9 | 14099 | |
067d23c9 | 14100 | |
067d23c9 | 14101 | |
067d23c9 | 14102 | |
067d23c9 | 14103 | |
1f5d53eb PE |
14104 | if test $gl_cv_have_include_next = yes; then |
14105 | gl_cv_next_getopt_h='<'getopt.h'>' | |
14106 | else | |
14107 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5 | |
14108 | $as_echo_n "checking absolute name of <getopt.h>... " >&6; } | |
14109 | if ${gl_cv_next_getopt_h+:} false; then : | |
14110 | $as_echo_n "(cached) " >&6 | |
14111 | else | |
067d23c9 | 14112 | |
1f5d53eb | 14113 | if test $ac_cv_header_getopt_h = yes; then |
067d23c9 | 14114 | |
067d23c9 | 14115 | |
1f5d53eb PE |
14116 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
14117 | /* end confdefs.h. */ | |
14118 | #include <getopt.h> | |
14119 | ||
14120 | _ACEOF | |
14121 | case "$host_os" in | |
14122 | aix*) gl_absname_cpp="$ac_cpp -C" ;; | |
14123 | *) gl_absname_cpp="$ac_cpp" ;; | |
14124 | esac | |
14125 | gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | | |
14126 | sed -n '\#/getopt.h#{ | |
14127 | s#.*"\(.*/getopt.h\)".*#\1# | |
14128 | s#^/[^/]#//&# | |
14129 | p | |
14130 | q | |
14131 | }'`'"' | |
14132 | else | |
14133 | gl_cv_next_getopt_h='<'getopt.h'>' | |
14134 | fi | |
067d23c9 KY |
14135 | |
14136 | ||
14137 | fi | |
1f5d53eb PE |
14138 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5 |
14139 | $as_echo "$gl_cv_next_getopt_h" >&6; } | |
14140 | fi | |
14141 | NEXT_GETOPT_H=$gl_cv_next_getopt_h | |
067d23c9 | 14142 | |
1f5d53eb PE |
14143 | if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then |
14144 | # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' | |
14145 | gl_next_as_first_directive='<'getopt.h'>' | |
14146 | else | |
14147 | # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' | |
14148 | gl_next_as_first_directive=$gl_cv_next_getopt_h | |
14149 | fi | |
14150 | NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive | |
067d23c9 | 14151 | |
067d23c9 KY |
14152 | |
14153 | ||
067d23c9 | 14154 | |
1f5d53eb PE |
14155 | if test $ac_cv_header_getopt_h = yes; then |
14156 | HAVE_GETOPT_H=1 | |
14157 | else | |
14158 | HAVE_GETOPT_H=0 | |
14159 | fi | |
067d23c9 | 14160 | |
1f5d53eb PE |
14161 | |
14162 | gl_replace_getopt= | |
14163 | ||
14164 | if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then | |
14165 | for ac_header in getopt.h | |
14166 | do : | |
14167 | ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default" | |
14168 | if test "x$ac_cv_header_getopt_h" = xyes; then : | |
14169 | cat >>confdefs.h <<_ACEOF | |
14170 | #define HAVE_GETOPT_H 1 | |
14171 | _ACEOF | |
067d23c9 KY |
14172 | |
14173 | else | |
1f5d53eb | 14174 | gl_replace_getopt=yes |
067d23c9 KY |
14175 | fi |
14176 | ||
1f5d53eb PE |
14177 | done |
14178 | ||
14179 | fi | |
14180 | ||
14181 | if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then | |
14182 | for ac_func in getopt_long_only | |
14183 | do : | |
14184 | ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only" | |
14185 | if test "x$ac_cv_func_getopt_long_only" = xyes; then : | |
14186 | cat >>confdefs.h <<_ACEOF | |
14187 | #define HAVE_GETOPT_LONG_ONLY 1 | |
14188 | _ACEOF | |
067d23c9 | 14189 | |
067d23c9 | 14190 | else |
1f5d53eb | 14191 | gl_replace_getopt=yes |
067d23c9 | 14192 | fi |
1f5d53eb | 14193 | done |
067d23c9 | 14194 | |
1f5d53eb | 14195 | fi |
067d23c9 | 14196 | |
1f5d53eb PE |
14197 | if test -z "$gl_replace_getopt"; then |
14198 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5 | |
14199 | $as_echo_n "checking whether getopt is POSIX compatible... " >&6; } | |
14200 | if ${gl_cv_func_getopt_posix+:} false; then : | |
067d23c9 KY |
14201 | $as_echo_n "(cached) " >&6 |
14202 | else | |
1f5d53eb PE |
14203 | |
14204 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
067d23c9 | 14205 | /* end confdefs.h. */ |
1f5d53eb | 14206 | #include <unistd.h> |
067d23c9 KY |
14207 | int |
14208 | main () | |
14209 | { | |
1f5d53eb | 14210 | int *p = &optreset; return optreset; |
067d23c9 KY |
14211 | ; |
14212 | return 0; | |
14213 | } | |
14214 | _ACEOF | |
1f5d53eb PE |
14215 | if ac_fn_c_try_compile "$LINENO"; then : |
14216 | gl_optind_min=1 | |
1fd182f0 | 14217 | else |
1f5d53eb | 14218 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
1fd182f0 | 14219 | /* end confdefs.h. */ |
1f5d53eb | 14220 | #include <getopt.h> |
1fd182f0 PE |
14221 | int |
14222 | main () | |
14223 | { | |
1f5d53eb | 14224 | return !getopt_clip; |
1fd182f0 PE |
14225 | ; |
14226 | return 0; | |
14227 | } | |
14228 | _ACEOF | |
14229 | if ac_fn_c_try_compile "$LINENO"; then : | |
1f5d53eb | 14230 | gl_optind_min=1 |
1fd182f0 | 14231 | else |
1f5d53eb | 14232 | gl_optind_min=0 |
1fd182f0 PE |
14233 | fi |
14234 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1fd182f0 | 14235 | fi |
1f5d53eb | 14236 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
1fd182f0 | 14237 | |
1f5d53eb PE |
14238 | gl_save_CPPFLAGS=$CPPFLAGS |
14239 | CPPFLAGS="$CPPFLAGS -DOPTIND_MIN=$gl_optind_min" | |
14240 | if test "$cross_compiling" = yes; then : | |
14241 | case "$host_os" in | |
14242 | mingw*) gl_cv_func_getopt_posix="guessing no";; | |
14243 | darwin* | aix*) gl_cv_func_getopt_posix="guessing no";; | |
14244 | *) gl_cv_func_getopt_posix="guessing yes";; | |
14245 | esac | |
1fd182f0 | 14246 | |
1f5d53eb PE |
14247 | else |
14248 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
14249 | /* end confdefs.h. */ | |
1fd182f0 | 14250 | |
1f5d53eb PE |
14251 | #include <unistd.h> |
14252 | #include <stdlib.h> | |
14253 | #include <string.h> | |
1fd182f0 | 14254 | |
1f5d53eb PE |
14255 | int |
14256 | main () | |
14257 | { | |
14258 | { | |
14259 | int argc = 0; | |
14260 | char *argv[10]; | |
14261 | int c; | |
1fd182f0 | 14262 | |
1f5d53eb PE |
14263 | argv[argc++] = "program"; |
14264 | argv[argc++] = "-a"; | |
14265 | argv[argc++] = "foo"; | |
14266 | argv[argc++] = "bar"; | |
14267 | argv[argc] = NULL; | |
14268 | optind = OPTIND_MIN; | |
14269 | opterr = 0; | |
b06b1098 | 14270 | |
1f5d53eb PE |
14271 | c = getopt (argc, argv, "ab"); |
14272 | if (!(c == 'a')) | |
14273 | return 1; | |
14274 | c = getopt (argc, argv, "ab"); | |
14275 | if (!(c == -1)) | |
14276 | return 2; | |
14277 | if (!(optind == 2)) | |
14278 | return 3; | |
14279 | } | |
14280 | /* Some internal state exists at this point. */ | |
14281 | { | |
14282 | int argc = 0; | |
14283 | char *argv[10]; | |
14284 | int c; | |
b06b1098 | 14285 | |
1f5d53eb PE |
14286 | argv[argc++] = "program"; |
14287 | argv[argc++] = "donald"; | |
14288 | argv[argc++] = "-p"; | |
14289 | argv[argc++] = "billy"; | |
14290 | argv[argc++] = "duck"; | |
14291 | argv[argc++] = "-a"; | |
14292 | argv[argc++] = "bar"; | |
14293 | argv[argc] = NULL; | |
14294 | optind = OPTIND_MIN; | |
14295 | opterr = 0; | |
b06b1098 | 14296 | |
1f5d53eb PE |
14297 | c = getopt (argc, argv, "+abp:q:"); |
14298 | if (!(c == -1)) | |
14299 | return 4; | |
14300 | if (!(strcmp (argv[0], "program") == 0)) | |
14301 | return 5; | |
14302 | if (!(strcmp (argv[1], "donald") == 0)) | |
14303 | return 6; | |
14304 | if (!(strcmp (argv[2], "-p") == 0)) | |
14305 | return 7; | |
14306 | if (!(strcmp (argv[3], "billy") == 0)) | |
14307 | return 8; | |
14308 | if (!(strcmp (argv[4], "duck") == 0)) | |
14309 | return 9; | |
14310 | if (!(strcmp (argv[5], "-a") == 0)) | |
14311 | return 10; | |
14312 | if (!(strcmp (argv[6], "bar") == 0)) | |
14313 | return 11; | |
14314 | if (!(optind == 1)) | |
14315 | return 12; | |
14316 | } | |
14317 | /* Detect MacOS 10.5, AIX 7.1 bug. */ | |
14318 | { | |
14319 | char *argv[3] = { "program", "-ab", NULL }; | |
14320 | optind = OPTIND_MIN; | |
14321 | opterr = 0; | |
14322 | if (getopt (2, argv, "ab:") != 'a') | |
14323 | return 13; | |
14324 | if (getopt (2, argv, "ab:") != '?') | |
14325 | return 14; | |
14326 | if (optopt != 'b') | |
14327 | return 15; | |
14328 | if (optind != 2) | |
14329 | return 16; | |
14330 | } | |
d6974efa | 14331 | |
1f5d53eb PE |
14332 | return 0; |
14333 | } | |
d6974efa | 14334 | |
1f5d53eb PE |
14335 | _ACEOF |
14336 | if ac_fn_c_try_run "$LINENO"; then : | |
14337 | gl_cv_func_getopt_posix=yes | |
14338 | else | |
14339 | gl_cv_func_getopt_posix=no | |
14340 | fi | |
14341 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
14342 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
14343 | fi | |
d6974efa | 14344 | |
1f5d53eb | 14345 | CPPFLAGS=$gl_save_CPPFLAGS |
1fd182f0 | 14346 | |
1f5d53eb PE |
14347 | fi |
14348 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5 | |
14349 | $as_echo "$gl_cv_func_getopt_posix" >&6; } | |
14350 | case "$gl_cv_func_getopt_posix" in | |
14351 | *no) gl_replace_getopt=yes ;; | |
14352 | esac | |
14353 | fi | |
1fd182f0 | 14354 | |
1f5d53eb PE |
14355 | if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then |
14356 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5 | |
14357 | $as_echo_n "checking for working GNU getopt function... " >&6; } | |
14358 | if ${gl_cv_func_getopt_gnu+:} false; then : | |
1fd182f0 | 14359 | $as_echo_n "(cached) " >&6 |
1f5d53eb PE |
14360 | else |
14361 | # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the | |
14362 | # optstring is necessary for programs like m4 that have POSIX-mandated | |
14363 | # semantics for supporting options interspersed with files. | |
14364 | # Also, since getopt_long is a GNU extension, we require optind=0. | |
14365 | # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT; | |
14366 | # so take care to revert to the correct (non-)export state. | |
14367 | gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }' | |
14368 | case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in | |
14369 | xx) gl_had_POSIXLY_CORRECT=exported ;; | |
14370 | x) gl_had_POSIXLY_CORRECT=yes ;; | |
14371 | *) gl_had_POSIXLY_CORRECT= ;; | |
14372 | esac | |
14373 | POSIXLY_CORRECT=1 | |
14374 | export POSIXLY_CORRECT | |
14375 | if test "$cross_compiling" = yes; then : | |
14376 | case $host_os:$ac_cv_have_decl_optreset in | |
14377 | *-gnu*:* | mingw*:*) gl_cv_func_getopt_gnu=no;; | |
14378 | *:yes) gl_cv_func_getopt_gnu=no;; | |
14379 | *) gl_cv_func_getopt_gnu=yes;; | |
14380 | esac | |
14381 | ||
1fd182f0 PE |
14382 | else |
14383 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
14384 | /* end confdefs.h. */ | |
1f5d53eb PE |
14385 | #include <getopt.h> |
14386 | #include <stddef.h> | |
14387 | #include <string.h> | |
14388 | ||
1fd182f0 PE |
14389 | int |
14390 | main () | |
14391 | { | |
1f5d53eb PE |
14392 | |
14393 | int result = 0; | |
14394 | /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw, | |
14395 | and fails on MacOS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5, | |
14396 | OSF/1 5.1, Solaris 10. */ | |
14397 | { | |
14398 | char *myargv[3]; | |
14399 | myargv[0] = "conftest"; | |
14400 | myargv[1] = "-+"; | |
14401 | myargv[2] = 0; | |
14402 | opterr = 0; | |
14403 | if (getopt (2, myargv, "+a") != '?') | |
14404 | result |= 1; | |
14405 | } | |
14406 | /* This code succeeds on glibc 2.8, mingw, | |
14407 | and fails on MacOS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11, | |
14408 | IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */ | |
14409 | { | |
14410 | char *argv[] = { "program", "-p", "foo", "bar", NULL }; | |
14411 | ||
14412 | optind = 1; | |
14413 | if (getopt (4, argv, "p::") != 'p') | |
14414 | result |= 2; | |
14415 | else if (optarg != NULL) | |
14416 | result |= 4; | |
14417 | else if (getopt (4, argv, "p::") != -1) | |
14418 | result |= 6; | |
14419 | else if (optind != 2) | |
14420 | result |= 8; | |
14421 | } | |
14422 | /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */ | |
14423 | { | |
14424 | char *argv[] = { "program", "foo", "-p", NULL }; | |
14425 | optind = 0; | |
14426 | if (getopt (3, argv, "-p") != 1) | |
14427 | result |= 16; | |
14428 | else if (getopt (3, argv, "-p") != 'p') | |
14429 | result |= 32; | |
14430 | } | |
14431 | /* This code fails on glibc 2.11. */ | |
14432 | { | |
14433 | char *argv[] = { "program", "-b", "-a", NULL }; | |
14434 | optind = opterr = 0; | |
14435 | if (getopt (3, argv, "+:a:b") != 'b') | |
14436 | result |= 64; | |
14437 | else if (getopt (3, argv, "+:a:b") != ':') | |
14438 | result |= 64; | |
14439 | } | |
14440 | return result; | |
14441 | ||
1fd182f0 PE |
14442 | ; |
14443 | return 0; | |
14444 | } | |
14445 | _ACEOF | |
1f5d53eb PE |
14446 | if ac_fn_c_try_run "$LINENO"; then : |
14447 | gl_cv_func_getopt_gnu=yes | |
1fd182f0 | 14448 | else |
1f5d53eb | 14449 | gl_cv_func_getopt_gnu=no |
1fd182f0 | 14450 | fi |
1f5d53eb PE |
14451 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14452 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
1fd182f0 | 14453 | fi |
1fd182f0 | 14454 | |
1f5d53eb PE |
14455 | case $gl_had_POSIXLY_CORRECT in |
14456 | exported) ;; | |
14457 | yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;; | |
14458 | *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;; | |
14459 | esac | |
1fd182f0 | 14460 | |
1f5d53eb PE |
14461 | fi |
14462 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5 | |
14463 | $as_echo "$gl_cv_func_getopt_gnu" >&6; } | |
14464 | if test "$gl_cv_func_getopt_gnu" = "no"; then | |
14465 | gl_replace_getopt=yes | |
14466 | fi | |
1fd182f0 PE |
14467 | fi |
14468 | ||
1f5d53eb PE |
14469 | ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default" |
14470 | if test "x$ac_cv_have_decl_getenv" = xyes; then : | |
14471 | ac_have_decl=1 | |
14472 | else | |
14473 | ac_have_decl=0 | |
14474 | fi | |
1fd182f0 | 14475 | |
1f5d53eb PE |
14476 | cat >>confdefs.h <<_ACEOF |
14477 | #define HAVE_DECL_GETENV $ac_have_decl | |
14478 | _ACEOF | |
1fd182f0 PE |
14479 | |
14480 | ||
14481 | ||
14482 | ||
1f5d53eb PE |
14483 | |
14484 | ||
14485 | if test -n "$gl_replace_getopt"; then : | |
14486 | ||
14487 | ||
14488 | ||
14489 | GETOPT_H=getopt.h | |
14490 | ||
14491 | $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h | |
14492 | ||
14493 | ||
14494 | ||
14495 | GNULIB_UNISTD_H_GETOPT=1 | |
14496 | ||
14497 | ||
14498 | ||
14499 | ||
14500 | ||
14501 | ||
14502 | ||
14503 | ||
14504 | gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext" | |
14505 | ||
14506 | ||
14507 | ||
14508 | ||
14509 | ||
14510 | ||
14511 | ||
14512 | ||
14513 | ||
14514 | gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext" | |
14515 | ||
14516 | ||
14517 | ||
14518 | ||
14519 | ||
14520 | ||
14521 | fi | |
14522 | ||
14523 | ||
1f5d53eb PE |
14524 | |
14525 | GNULIB_MKTIME=0; | |
14526 | GNULIB_NANOSLEEP=0; | |
14527 | GNULIB_STRPTIME=0; | |
14528 | GNULIB_TIMEGM=0; | |
14529 | GNULIB_TIME_R=0; | |
14530 | HAVE_DECL_LOCALTIME_R=1; | |
14531 | HAVE_NANOSLEEP=1; | |
14532 | HAVE_STRPTIME=1; | |
14533 | HAVE_TIMEGM=1; | |
14534 | REPLACE_LOCALTIME_R=GNULIB_PORTCHECK; | |
14535 | REPLACE_MKTIME=GNULIB_PORTCHECK; | |
14536 | REPLACE_NANOSLEEP=GNULIB_PORTCHECK; | |
14537 | REPLACE_TIMEGM=GNULIB_PORTCHECK; | |
14538 | ||
14539 | ||
14540 | ||
14541 | ||
14542 | for ac_func in $ac_func_list | |
14543 | do : | |
14544 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
14545 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
14546 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
14547 | cat >>confdefs.h <<_ACEOF | |
14548 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
14549 | _ACEOF | |
1fd182f0 | 14550 | |
e275c824 | 14551 | fi |
1f5d53eb | 14552 | done |
1fd182f0 PE |
14553 | |
14554 | ||
e275c824 | 14555 | |
1fd182f0 | 14556 | |
1f5d53eb PE |
14557 | gl_cv_c_multiarch=no |
14558 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
14559 | /* end confdefs.h. */ | |
14560 | #ifndef __APPLE_CC__ | |
14561 | not a universal capable compiler | |
14562 | #endif | |
14563 | typedef int dummy; | |
e275c824 PE |
14564 | |
14565 | _ACEOF | |
1f5d53eb | 14566 | if ac_fn_c_try_compile "$LINENO"; then : |
e275c824 | 14567 | |
1f5d53eb PE |
14568 | arch= |
14569 | prev= | |
14570 | for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do | |
14571 | if test -n "$prev"; then | |
14572 | case $word in | |
14573 | i?86 | x86_64 | ppc | ppc64) | |
14574 | if test -z "$arch" || test "$arch" = "$word"; then | |
14575 | arch="$word" | |
14576 | else | |
14577 | gl_cv_c_multiarch=yes | |
14578 | fi | |
14579 | ;; | |
14580 | esac | |
14581 | prev= | |
14582 | else | |
14583 | if test "x$word" = "x-arch"; then | |
14584 | prev=arch | |
14585 | fi | |
14586 | fi | |
14587 | done | |
e275c824 PE |
14588 | |
14589 | fi | |
1f5d53eb PE |
14590 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
14591 | if test $gl_cv_c_multiarch = yes; then | |
14592 | APPLE_UNIVERSAL_BUILD=1 | |
e275c824 | 14593 | else |
1f5d53eb | 14594 | APPLE_UNIVERSAL_BUILD=0 |
e275c824 PE |
14595 | fi |
14596 | ||
14597 | ||
1f5d53eb PE |
14598 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5 |
14599 | $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; } | |
14600 | if ${ac_cv_header_stdbool_h+:} false; then : | |
14601 | $as_echo_n "(cached) " >&6 | |
14602 | else | |
14603 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
14604 | /* end confdefs.h. */ | |
e275c824 | 14605 | |
1f5d53eb PE |
14606 | #include <stdbool.h> |
14607 | #ifndef bool | |
14608 | "error: bool is not defined" | |
14609 | #endif | |
14610 | #ifndef false | |
14611 | "error: false is not defined" | |
14612 | #endif | |
14613 | #if false | |
14614 | "error: false is not 0" | |
14615 | #endif | |
14616 | #ifndef true | |
14617 | "error: true is not defined" | |
14618 | #endif | |
14619 | #if true != 1 | |
14620 | "error: true is not 1" | |
14621 | #endif | |
14622 | #ifndef __bool_true_false_are_defined | |
14623 | "error: __bool_true_false_are_defined is not defined" | |
14624 | #endif | |
e275c824 | 14625 | |
1f5d53eb | 14626 | struct s { _Bool s: 1; _Bool t; } s; |
e275c824 | 14627 | |
1f5d53eb PE |
14628 | char a[true == 1 ? 1 : -1]; |
14629 | char b[false == 0 ? 1 : -1]; | |
14630 | char c[__bool_true_false_are_defined == 1 ? 1 : -1]; | |
14631 | char d[(bool) 0.5 == true ? 1 : -1]; | |
14632 | /* See body of main program for 'e'. */ | |
14633 | char f[(_Bool) 0.0 == false ? 1 : -1]; | |
14634 | char g[true]; | |
14635 | char h[sizeof (_Bool)]; | |
14636 | char i[sizeof s.t]; | |
14637 | enum { j = false, k = true, l = false * true, m = true * 256 }; | |
14638 | /* The following fails for | |
14639 | HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */ | |
14640 | _Bool n[m]; | |
14641 | char o[sizeof n == m * sizeof n[0] ? 1 : -1]; | |
14642 | char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1]; | |
14643 | /* Catch a bug in an HP-UX C compiler. See | |
14644 | http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html | |
14645 | http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html | |
14646 | */ | |
14647 | _Bool q = true; | |
14648 | _Bool *pq = &q; | |
e275c824 | 14649 | |
1f5d53eb PE |
14650 | int |
14651 | main () | |
14652 | { | |
e275c824 | 14653 | |
1f5d53eb PE |
14654 | bool e = &s; |
14655 | *pq |= q; | |
14656 | *pq |= ! q; | |
14657 | /* Refer to every declared value, to avoid compiler optimizations. */ | |
14658 | return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l | |
14659 | + !m + !n + !o + !p + !q + !pq); | |
e275c824 | 14660 | |
1f5d53eb PE |
14661 | ; |
14662 | return 0; | |
14663 | } | |
14664 | _ACEOF | |
14665 | if ac_fn_c_try_compile "$LINENO"; then : | |
14666 | ac_cv_header_stdbool_h=yes | |
14667 | else | |
14668 | ac_cv_header_stdbool_h=no | |
14669 | fi | |
14670 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
14671 | fi | |
14672 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5 | |
14673 | $as_echo "$ac_cv_header_stdbool_h" >&6; } | |
14674 | ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default" | |
14675 | if test "x$ac_cv_type__Bool" = xyes; then : | |
e275c824 | 14676 | |
1f5d53eb PE |
14677 | cat >>confdefs.h <<_ACEOF |
14678 | #define HAVE__BOOL 1 | |
14679 | _ACEOF | |
e275c824 PE |
14680 | |
14681 | ||
1f5d53eb | 14682 | fi |
e275c824 PE |
14683 | |
14684 | ||
14685 | ||
1f5d53eb PE |
14686 | REPLACE_NULL=0; |
14687 | HAVE_WCHAR_T=1; | |
14688 | STDDEF_H=''; | |
b06b1098 PE |
14689 | |
14690 | ||
1f5d53eb PE |
14691 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5 |
14692 | $as_echo_n "checking for wchar_t... " >&6; } | |
14693 | if ${gt_cv_c_wchar_t+:} false; then : | |
e275c824 PE |
14694 | $as_echo_n "(cached) " >&6 |
14695 | else | |
1f5d53eb | 14696 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
e275c824 | 14697 | /* end confdefs.h. */ |
1f5d53eb PE |
14698 | #include <stddef.h> |
14699 | wchar_t foo = (wchar_t)'\0'; | |
14700 | int | |
14701 | main () | |
14702 | { | |
e275c824 | 14703 | |
1f5d53eb PE |
14704 | ; |
14705 | return 0; | |
14706 | } | |
e275c824 | 14707 | _ACEOF |
1f5d53eb PE |
14708 | if ac_fn_c_try_compile "$LINENO"; then : |
14709 | gt_cv_c_wchar_t=yes | |
14710 | else | |
14711 | gt_cv_c_wchar_t=no | |
e275c824 | 14712 | fi |
1f5d53eb PE |
14713 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
14714 | fi | |
14715 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5 | |
14716 | $as_echo "$gt_cv_c_wchar_t" >&6; } | |
14717 | if test $gt_cv_c_wchar_t = yes; then | |
e275c824 | 14718 | |
1f5d53eb | 14719 | $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h |
e275c824 | 14720 | |
e275c824 PE |
14721 | fi |
14722 | ||
14723 | ||
5f90be1b PE |
14724 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5 |
14725 | $as_echo_n "checking for unsigned long long int... " >&6; } | |
14726 | if ${ac_cv_type_unsigned_long_long_int+:} false; then : | |
14727 | $as_echo_n "(cached) " >&6 | |
14728 | else | |
14729 | ac_cv_type_unsigned_long_long_int=yes | |
14730 | if test "x${ac_cv_prog_cc_c99-no}" = xno; then | |
14731 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
14732 | /* end confdefs.h. */ | |
14733 | ||
14734 | /* For now, do not test the preprocessor; as of 2007 there are too many | |
14735 | implementations with broken preprocessors. Perhaps this can | |
14736 | be revisited in 2012. In the meantime, code should not expect | |
14737 | #if to work with literals wider than 32 bits. */ | |
14738 | /* Test literals. */ | |
14739 | long long int ll = 9223372036854775807ll; | |
14740 | long long int nll = -9223372036854775807LL; | |
14741 | unsigned long long int ull = 18446744073709551615ULL; | |
14742 | /* Test constant expressions. */ | |
14743 | typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll) | |
14744 | ? 1 : -1)]; | |
14745 | typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1 | |
14746 | ? 1 : -1)]; | |
14747 | int i = 63; | |
14748 | int | |
14749 | main () | |
14750 | { | |
14751 | /* Test availability of runtime routines for shift and division. */ | |
14752 | long long int llmax = 9223372036854775807ll; | |
14753 | unsigned long long int ullmax = 18446744073709551615ull; | |
14754 | return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i) | |
14755 | | (llmax / ll) | (llmax % ll) | |
14756 | | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i) | |
14757 | | (ullmax / ull) | (ullmax % ull)); | |
14758 | ; | |
14759 | return 0; | |
14760 | } | |
14761 | ||
14762 | _ACEOF | |
14763 | if ac_fn_c_try_link "$LINENO"; then : | |
14764 | ||
14765 | else | |
14766 | ac_cv_type_unsigned_long_long_int=no | |
14767 | fi | |
14768 | rm -f core conftest.err conftest.$ac_objext \ | |
14769 | conftest$ac_exeext conftest.$ac_ext | |
14770 | fi | |
14771 | fi | |
14772 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5 | |
14773 | $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; } | |
14774 | if test $ac_cv_type_unsigned_long_long_int = yes; then | |
14775 | ||
14776 | $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h | |
14777 | ||
14778 | fi | |
14779 | ||
14780 | ||
14781 | ||
14782 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5 | |
14783 | $as_echo_n "checking for long long int... " >&6; } | |
14784 | if ${ac_cv_type_long_long_int+:} false; then : | |
14785 | $as_echo_n "(cached) " >&6 | |
14786 | else | |
14787 | ac_cv_type_long_long_int=yes | |
14788 | if test "x${ac_cv_prog_cc_c99-no}" = xno; then | |
14789 | ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int | |
14790 | if test $ac_cv_type_long_long_int = yes; then | |
14791 | if test "$cross_compiling" = yes; then : | |
14792 | : | |
14793 | else | |
14794 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
14795 | /* end confdefs.h. */ | |
14796 | #include <limits.h> | |
14797 | #ifndef LLONG_MAX | |
14798 | # define HALF \ | |
14799 | (1LL << (sizeof (long long int) * CHAR_BIT - 2)) | |
14800 | # define LLONG_MAX (HALF - 1 + HALF) | |
14801 | #endif | |
14802 | int | |
14803 | main () | |
14804 | { | |
14805 | long long int n = 1; | |
14806 | int i; | |
14807 | for (i = 0; ; i++) | |
14808 | { | |
14809 | long long int m = n << i; | |
14810 | if (m >> i != n) | |
14811 | return 1; | |
14812 | if (LLONG_MAX / 2 < m) | |
14813 | break; | |
14814 | } | |
14815 | return 0; | |
14816 | ; | |
14817 | return 0; | |
14818 | } | |
14819 | _ACEOF | |
14820 | if ac_fn_c_try_run "$LINENO"; then : | |
14821 | ||
14822 | else | |
14823 | ac_cv_type_long_long_int=no | |
14824 | fi | |
14825 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
14826 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
14827 | fi | |
14828 | ||
14829 | fi | |
14830 | fi | |
14831 | fi | |
14832 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5 | |
14833 | $as_echo "$ac_cv_type_long_long_int" >&6; } | |
14834 | if test $ac_cv_type_long_long_int = yes; then | |
14835 | ||
14836 | $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h | |
14837 | ||
14838 | fi | |
14839 | ||
14840 | ||
14841 | ||
14842 | ||
14843 | ||
14844 | ||
1f5d53eb PE |
14845 | ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h> |
14846 | " | |
14847 | if test "x$ac_cv_member_struct_tm_tm_gmtoff" = xyes; then : | |
e275c824 | 14848 | |
1f5d53eb | 14849 | $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h |
e275c824 | 14850 | |
e275c824 PE |
14851 | fi |
14852 | ||
e275c824 | 14853 | |
e275c824 | 14854 | |
e275c824 | 14855 | |
5fa4ac76 PE |
14856 | |
14857 | GNULIB_FCHMODAT=0; | |
14858 | GNULIB_FSTATAT=0; | |
14859 | GNULIB_FUTIMENS=0; | |
14860 | GNULIB_LCHMOD=0; | |
14861 | GNULIB_LSTAT=0; | |
14862 | GNULIB_MKDIRAT=0; | |
14863 | GNULIB_MKFIFO=0; | |
14864 | GNULIB_MKFIFOAT=0; | |
14865 | GNULIB_MKNOD=0; | |
14866 | GNULIB_MKNODAT=0; | |
14867 | GNULIB_STAT=0; | |
14868 | GNULIB_UTIMENSAT=0; | |
14869 | HAVE_FCHMODAT=1; | |
14870 | HAVE_FSTATAT=1; | |
14871 | HAVE_FUTIMENS=1; | |
14872 | HAVE_LCHMOD=1; | |
14873 | HAVE_LSTAT=1; | |
14874 | HAVE_MKDIRAT=1; | |
14875 | HAVE_MKFIFO=1; | |
14876 | HAVE_MKFIFOAT=1; | |
14877 | HAVE_MKNOD=1; | |
14878 | HAVE_MKNODAT=1; | |
14879 | HAVE_UTIMENSAT=1; | |
14880 | REPLACE_FSTAT=0; | |
14881 | REPLACE_FSTATAT=0; | |
14882 | REPLACE_FUTIMENS=0; | |
14883 | REPLACE_LSTAT=0; | |
14884 | REPLACE_MKDIR=0; | |
14885 | REPLACE_MKFIFO=0; | |
14886 | REPLACE_MKNOD=0; | |
14887 | REPLACE_STAT=0; | |
14888 | REPLACE_UTIMENSAT=0; | |
14889 | ||
14890 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5 | |
14891 | $as_echo_n "checking whether stat file-mode macros are broken... " >&6; } | |
14892 | if ${ac_cv_header_stat_broken+:} false; then : | |
14893 | $as_echo_n "(cached) " >&6 | |
14894 | else | |
14895 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
14896 | /* end confdefs.h. */ | |
14897 | #include <sys/types.h> | |
14898 | #include <sys/stat.h> | |
14899 | ||
14900 | #if defined S_ISBLK && defined S_IFDIR | |
14901 | extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1]; | |
14902 | #endif | |
14903 | ||
14904 | #if defined S_ISBLK && defined S_IFCHR | |
14905 | extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1]; | |
14906 | #endif | |
14907 | ||
14908 | #if defined S_ISLNK && defined S_IFREG | |
14909 | extern char c3[S_ISLNK (S_IFREG) ? -1 : 1]; | |
14910 | #endif | |
14911 | ||
14912 | #if defined S_ISSOCK && defined S_IFREG | |
14913 | extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1]; | |
14914 | #endif | |
14915 | ||
14916 | _ACEOF | |
14917 | if ac_fn_c_try_compile "$LINENO"; then : | |
14918 | ac_cv_header_stat_broken=no | |
14919 | else | |
14920 | ac_cv_header_stat_broken=yes | |
14921 | fi | |
14922 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
14923 | fi | |
14924 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5 | |
14925 | $as_echo "$ac_cv_header_stat_broken" >&6; } | |
14926 | if test $ac_cv_header_stat_broken = yes; then | |
14927 | ||
14928 | $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h | |
14929 | ||
14930 | fi | |
14931 | ||
14932 | ||
14933 | ||
1f5d53eb PE |
14934 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5 |
14935 | $as_echo_n "checking for C/C++ restrict keyword... " >&6; } | |
14936 | if ${ac_cv_c_restrict+:} false; then : | |
d6974efa | 14937 | $as_echo_n "(cached) " >&6 |
e275c824 | 14938 | else |
1f5d53eb PE |
14939 | ac_cv_c_restrict=no |
14940 | # The order here caters to the fact that C++ does not require restrict. | |
14941 | for ac_kw in __restrict __restrict__ _Restrict restrict; do | |
14942 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
d6974efa | 14943 | /* end confdefs.h. */ |
1f5d53eb PE |
14944 | typedef int * int_ptr; |
14945 | int foo (int_ptr $ac_kw ip) { | |
14946 | return ip[0]; | |
14947 | } | |
d6974efa PE |
14948 | int |
14949 | main () | |
14950 | { | |
1f5d53eb PE |
14951 | int s[1]; |
14952 | int * $ac_kw t = s; | |
14953 | t[0] = 0; | |
14954 | return foo(t) | |
d6974efa PE |
14955 | ; |
14956 | return 0; | |
14957 | } | |
e275c824 | 14958 | _ACEOF |
1f5d53eb PE |
14959 | if ac_fn_c_try_compile "$LINENO"; then : |
14960 | ac_cv_c_restrict=$ac_kw | |
14961 | fi | |
14962 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
14963 | test "$ac_cv_c_restrict" != no && break | |
14964 | done | |
14965 | ||
14966 | fi | |
14967 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5 | |
14968 | $as_echo "$ac_cv_c_restrict" >&6; } | |
14969 | ||
14970 | case $ac_cv_c_restrict in | |
14971 | restrict) ;; | |
14972 | no) $as_echo "#define restrict /**/" >>confdefs.h | |
14973 | ;; | |
14974 | *) cat >>confdefs.h <<_ACEOF | |
14975 | #define restrict $ac_cv_c_restrict | |
14976 | _ACEOF | |
14977 | ;; | |
14978 | esac | |
14979 | ||
14980 | ||
14981 | ||
14982 | ||
14983 | ||
14984 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5 | |
14985 | $as_echo_n "checking for struct timespec in <time.h>... " >&6; } | |
14986 | if ${gl_cv_sys_struct_timespec_in_time_h+:} false; then : | |
14987 | $as_echo_n "(cached) " >&6 | |
e275c824 | 14988 | else |
d6974efa PE |
14989 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
14990 | /* end confdefs.h. */ | |
1f5d53eb PE |
14991 | #include <time.h> |
14992 | ||
d6974efa PE |
14993 | int |
14994 | main () | |
14995 | { | |
1f5d53eb | 14996 | static struct timespec x; x.tv_sec = x.tv_nsec; |
d6974efa PE |
14997 | ; |
14998 | return 0; | |
14999 | } | |
15000 | _ACEOF | |
15001 | if ac_fn_c_try_compile "$LINENO"; then : | |
1f5d53eb | 15002 | gl_cv_sys_struct_timespec_in_time_h=yes |
e275c824 | 15003 | else |
1f5d53eb | 15004 | gl_cv_sys_struct_timespec_in_time_h=no |
e275c824 | 15005 | fi |
d6974efa | 15006 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
e275c824 | 15007 | fi |
1f5d53eb PE |
15008 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5 |
15009 | $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; } | |
e275c824 | 15010 | |
1f5d53eb PE |
15011 | TIME_H_DEFINES_STRUCT_TIMESPEC=0 |
15012 | SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0 | |
15013 | PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0 | |
15014 | if test $gl_cv_sys_struct_timespec_in_time_h = yes; then | |
15015 | TIME_H_DEFINES_STRUCT_TIMESPEC=1 | |
15016 | else | |
15017 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5 | |
15018 | $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; } | |
15019 | if ${gl_cv_sys_struct_timespec_in_sys_time_h+:} false; then : | |
15020 | $as_echo_n "(cached) " >&6 | |
e275c824 PE |
15021 | else |
15022 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
15023 | /* end confdefs.h. */ | |
1f5d53eb | 15024 | #include <sys/time.h> |
e275c824 | 15025 | |
e275c824 PE |
15026 | int |
15027 | main () | |
15028 | { | |
1f5d53eb PE |
15029 | static struct timespec x; x.tv_sec = x.tv_nsec; |
15030 | ; | |
e275c824 PE |
15031 | return 0; |
15032 | } | |
e275c824 | 15033 | _ACEOF |
1f5d53eb PE |
15034 | if ac_fn_c_try_compile "$LINENO"; then : |
15035 | gl_cv_sys_struct_timespec_in_sys_time_h=yes | |
e275c824 | 15036 | else |
1f5d53eb | 15037 | gl_cv_sys_struct_timespec_in_sys_time_h=no |
e275c824 | 15038 | fi |
1f5d53eb | 15039 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
e275c824 | 15040 | fi |
1f5d53eb PE |
15041 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5 |
15042 | $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; } | |
15043 | if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then | |
15044 | SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1 | |
15045 | else | |
15046 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5 | |
15047 | $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; } | |
15048 | if ${gl_cv_sys_struct_timespec_in_pthread_h+:} false; then : | |
e275c824 | 15049 | $as_echo_n "(cached) " >&6 |
e275c824 PE |
15050 | else |
15051 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
15052 | /* end confdefs.h. */ | |
1f5d53eb | 15053 | #include <pthread.h> |
e275c824 PE |
15054 | |
15055 | int | |
15056 | main () | |
15057 | { | |
1f5d53eb | 15058 | static struct timespec x; x.tv_sec = x.tv_nsec; |
e275c824 PE |
15059 | ; |
15060 | return 0; | |
15061 | } | |
15062 | _ACEOF | |
1f5d53eb PE |
15063 | if ac_fn_c_try_compile "$LINENO"; then : |
15064 | gl_cv_sys_struct_timespec_in_pthread_h=yes | |
e275c824 | 15065 | else |
1f5d53eb | 15066 | gl_cv_sys_struct_timespec_in_pthread_h=no |
e275c824 | 15067 | fi |
1f5d53eb | 15068 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
e275c824 | 15069 | fi |
1f5d53eb PE |
15070 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5 |
15071 | $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; } | |
15072 | if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then | |
15073 | PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1 | |
15074 | fi | |
e275c824 PE |
15075 | fi |
15076 | fi | |
15077 | ||
e275c824 | 15078 | |
e275c824 | 15079 | |
e275c824 PE |
15080 | |
15081 | ||
15082 | ||
e275c824 PE |
15083 | |
15084 | ||
15085 | ||
15086 | ||
15087 | ||
15088 | ||
15089 | ||
15090 | ||
e275c824 | 15091 | |
1f5d53eb PE |
15092 | if test $gl_cv_have_include_next = yes; then |
15093 | gl_cv_next_time_h='<'time.h'>' | |
15094 | else | |
15095 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5 | |
15096 | $as_echo_n "checking absolute name of <time.h>... " >&6; } | |
15097 | if ${gl_cv_next_time_h+:} false; then : | |
15098 | $as_echo_n "(cached) " >&6 | |
15099 | else | |
e275c824 | 15100 | |
1f5d53eb PE |
15101 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
15102 | /* end confdefs.h. */ | |
15103 | #include <time.h> | |
e275c824 | 15104 | |
1f5d53eb PE |
15105 | _ACEOF |
15106 | case "$host_os" in | |
15107 | aix*) gl_absname_cpp="$ac_cpp -C" ;; | |
15108 | *) gl_absname_cpp="$ac_cpp" ;; | |
15109 | esac | |
15110 | gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | | |
15111 | sed -n '\#/time.h#{ | |
15112 | s#.*"\(.*/time.h\)".*#\1# | |
15113 | s#^/[^/]#//&# | |
15114 | p | |
15115 | q | |
15116 | }'`'"' | |
e275c824 PE |
15117 | |
15118 | ||
1f5d53eb PE |
15119 | fi |
15120 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5 | |
15121 | $as_echo "$gl_cv_next_time_h" >&6; } | |
15122 | fi | |
15123 | NEXT_TIME_H=$gl_cv_next_time_h | |
e275c824 | 15124 | |
1f5d53eb PE |
15125 | if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then |
15126 | # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' | |
15127 | gl_next_as_first_directive='<'time.h'>' | |
15128 | else | |
15129 | # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' | |
15130 | gl_next_as_first_directive=$gl_cv_next_time_h | |
15131 | fi | |
15132 | NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive | |
e275c824 PE |
15133 | |
15134 | ||
15135 | ||
e275c824 PE |
15136 | |
15137 | ||
15138 | ||
1f5d53eb PE |
15139 | ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "$ac_includes_default" |
15140 | if test "x$ac_cv_have_decl_localtime_r" = xyes; then : | |
15141 | ac_have_decl=1 | |
15142 | else | |
15143 | ac_have_decl=0 | |
15144 | fi | |
e275c824 | 15145 | |
1f5d53eb PE |
15146 | cat >>confdefs.h <<_ACEOF |
15147 | #define HAVE_DECL_LOCALTIME_R $ac_have_decl | |
15148 | _ACEOF | |
e275c824 PE |
15149 | |
15150 | ||
e275c824 PE |
15151 | |
15152 | ||
1f5d53eb PE |
15153 | if false; then |
15154 | GL_COND_LIBTOOL_TRUE= | |
15155 | GL_COND_LIBTOOL_FALSE='#' | |
67342916 | 15156 | else |
1f5d53eb PE |
15157 | GL_COND_LIBTOOL_TRUE='#' |
15158 | GL_COND_LIBTOOL_FALSE= | |
67342916 | 15159 | fi |
67342916 | 15160 | |
1f5d53eb PE |
15161 | gl_cond_libtool=false |
15162 | gl_libdeps= | |
15163 | gl_ltlibdeps= | |
15164 | gl_m4_base='m4' | |
67342916 | 15165 | |
67342916 | 15166 | |
e275c824 | 15167 | |
e275c824 PE |
15168 | |
15169 | ||
15170 | ||
15171 | ||
e275c824 | 15172 | |
e275c824 | 15173 | |
1f5d53eb PE |
15174 | gl_source_base='lib' |
15175 | # Code from module arg-nonnull: | |
15176 | # Code from module c++defs: | |
942f733f PE |
15177 | # Code from module crypto/md5: |
15178 | ||
15179 | ||
15180 | ||
15181 | ||
15182 | ||
15183 | ||
15184 | ||
15185 | ||
15186 | ||
15187 | gl_LIBOBJS="$gl_LIBOBJS md5.$ac_objext" | |
15188 | ||
15189 | ||
15190 | ||
15191 | ||
15192 | : | |
15193 | ||
1f5d53eb | 15194 | # Code from module dtoastr: |
e275c824 | 15195 | |
1f5d53eb | 15196 | # Code from module extensions: |
5fa4ac76 PE |
15197 | # Code from module filemode: |
15198 | ||
15199 | ||
15200 | ||
15201 | ||
15202 | ||
15203 | ||
15204 | ||
15205 | ||
15206 | ||
15207 | ||
15208 | gl_LIBOBJS="$gl_LIBOBJS filemode.$ac_objext" | |
15209 | ||
15210 | ||
15211 | ||
1f5d53eb | 15212 | # Code from module getloadavg: |
e275c824 PE |
15213 | |
15214 | ||
1f5d53eb | 15215 | # Persuade glibc <stdlib.h> to declare getloadavg(). |
e275c824 | 15216 | |
e275c824 | 15217 | |
1f5d53eb PE |
15218 | # Make sure getloadavg.c is where it belongs, at configure-time. |
15219 | test -f "$srcdir/$gl_source_base/getloadavg.c" || | |
15220 | as_fn_error $? "$srcdir/$gl_source_base/getloadavg.c is missing" "$LINENO" 5 | |
e275c824 | 15221 | |
1f5d53eb | 15222 | gl_save_LIBS=$LIBS |
e275c824 | 15223 | |
7d315eb6 PE |
15224 | # getloadvg is present in libc on glibc >= 2.2, MacOS X, FreeBSD >= 2.0, |
15225 | # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7. | |
1f5d53eb PE |
15226 | ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg" |
15227 | if test "x$ac_cv_func_getloadavg" = xyes; then : | |
e275c824 | 15228 | |
1f5d53eb PE |
15229 | else |
15230 | gl_have_func=no | |
15231 | ||
15232 | # Some systems with -lutil have (and need) -lkvm as well, some do not. | |
15233 | # On Solaris, -lkvm requires nlist from -lelf, so check that first | |
15234 | # to get the right answer into the cache. | |
15235 | # For kstat on solaris, we need to test for libelf and libkvm to force the | |
15236 | # definition of SVR4 below. | |
15237 | if test $gl_have_func = no; then | |
15238 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5 | |
15239 | $as_echo_n "checking for elf_begin in -lelf... " >&6; } | |
15240 | if ${ac_cv_lib_elf_elf_begin+:} false; then : | |
16c3e636 PE |
15241 | $as_echo_n "(cached) " >&6 |
15242 | else | |
1f5d53eb PE |
15243 | ac_check_lib_save_LIBS=$LIBS |
15244 | LIBS="-lelf $LIBS" | |
15245 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
16c3e636 PE |
15246 | /* end confdefs.h. */ |
15247 | ||
1f5d53eb PE |
15248 | /* Override any GCC internal prototype to avoid an error. |
15249 | Use char because int might match the return type of a GCC | |
15250 | builtin and then its argument prototype would still apply. */ | |
15251 | #ifdef __cplusplus | |
15252 | extern "C" | |
15253 | #endif | |
15254 | char elf_begin (); | |
15255 | int | |
15256 | main () | |
15257 | { | |
15258 | return elf_begin (); | |
15259 | ; | |
15260 | return 0; | |
15261 | } | |
15262 | _ACEOF | |
15263 | if ac_fn_c_try_link "$LINENO"; then : | |
15264 | ac_cv_lib_elf_elf_begin=yes | |
15265 | else | |
15266 | ac_cv_lib_elf_elf_begin=no | |
15267 | fi | |
15268 | rm -f core conftest.err conftest.$ac_objext \ | |
15269 | conftest$ac_exeext conftest.$ac_ext | |
15270 | LIBS=$ac_check_lib_save_LIBS | |
15271 | fi | |
15272 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5 | |
15273 | $as_echo "$ac_cv_lib_elf_elf_begin" >&6; } | |
15274 | if test "x$ac_cv_lib_elf_elf_begin" = xyes; then : | |
15275 | LIBS="-lelf $LIBS" | |
15276 | fi | |
15277 | ||
15278 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5 | |
15279 | $as_echo_n "checking for kvm_open in -lkvm... " >&6; } | |
15280 | if ${ac_cv_lib_kvm_kvm_open+:} false; then : | |
15281 | $as_echo_n "(cached) " >&6 | |
15282 | else | |
15283 | ac_check_lib_save_LIBS=$LIBS | |
15284 | LIBS="-lkvm $LIBS" | |
15285 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
15286 | /* end confdefs.h. */ | |
16c3e636 | 15287 | |
1f5d53eb PE |
15288 | /* Override any GCC internal prototype to avoid an error. |
15289 | Use char because int might match the return type of a GCC | |
15290 | builtin and then its argument prototype would still apply. */ | |
15291 | #ifdef __cplusplus | |
15292 | extern "C" | |
15293 | #endif | |
15294 | char kvm_open (); | |
16c3e636 PE |
15295 | int |
15296 | main () | |
15297 | { | |
1f5d53eb | 15298 | return kvm_open (); |
16c3e636 PE |
15299 | ; |
15300 | return 0; | |
15301 | } | |
15302 | _ACEOF | |
1f5d53eb PE |
15303 | if ac_fn_c_try_link "$LINENO"; then : |
15304 | ac_cv_lib_kvm_kvm_open=yes | |
16c3e636 | 15305 | else |
1f5d53eb | 15306 | ac_cv_lib_kvm_kvm_open=no |
16c3e636 | 15307 | fi |
1f5d53eb PE |
15308 | rm -f core conftest.err conftest.$ac_objext \ |
15309 | conftest$ac_exeext conftest.$ac_ext | |
15310 | LIBS=$ac_check_lib_save_LIBS | |
16c3e636 | 15311 | fi |
1f5d53eb PE |
15312 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5 |
15313 | $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; } | |
15314 | if test "x$ac_cv_lib_kvm_kvm_open" = xyes; then : | |
15315 | LIBS="-lkvm $LIBS" | |
16c3e636 PE |
15316 | fi |
15317 | ||
1f5d53eb PE |
15318 | # Check for the 4.4BSD definition of getloadavg. |
15319 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5 | |
15320 | $as_echo_n "checking for getloadavg in -lutil... " >&6; } | |
15321 | if ${ac_cv_lib_util_getloadavg+:} false; then : | |
1fd182f0 PE |
15322 | $as_echo_n "(cached) " >&6 |
15323 | else | |
1f5d53eb PE |
15324 | ac_check_lib_save_LIBS=$LIBS |
15325 | LIBS="-lutil $LIBS" | |
15326 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1fd182f0 | 15327 | /* end confdefs.h. */ |
1f5d53eb PE |
15328 | |
15329 | /* Override any GCC internal prototype to avoid an error. | |
15330 | Use char because int might match the return type of a GCC | |
15331 | builtin and then its argument prototype would still apply. */ | |
15332 | #ifdef __cplusplus | |
15333 | extern "C" | |
15334 | #endif | |
15335 | char getloadavg (); | |
1fd182f0 PE |
15336 | int |
15337 | main () | |
15338 | { | |
1f5d53eb | 15339 | return getloadavg (); |
1fd182f0 PE |
15340 | ; |
15341 | return 0; | |
15342 | } | |
15343 | _ACEOF | |
1f5d53eb PE |
15344 | if ac_fn_c_try_link "$LINENO"; then : |
15345 | ac_cv_lib_util_getloadavg=yes | |
1fd182f0 | 15346 | else |
1f5d53eb | 15347 | ac_cv_lib_util_getloadavg=no |
1fd182f0 | 15348 | fi |
1f5d53eb PE |
15349 | rm -f core conftest.err conftest.$ac_objext \ |
15350 | conftest$ac_exeext conftest.$ac_ext | |
15351 | LIBS=$ac_check_lib_save_LIBS | |
1fd182f0 | 15352 | fi |
1f5d53eb PE |
15353 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5 |
15354 | $as_echo "$ac_cv_lib_util_getloadavg" >&6; } | |
15355 | if test "x$ac_cv_lib_util_getloadavg" = xyes; then : | |
15356 | LIBS="-lutil $LIBS" gl_have_func=yes | |
16c3e636 PE |
15357 | fi |
15358 | ||
1f5d53eb | 15359 | fi |
16c3e636 | 15360 | |
1f5d53eb PE |
15361 | if test $gl_have_func = no; then |
15362 | # There is a commonly available library for RS/6000 AIX. | |
15363 | # Since it is not a standard part of AIX, it might be installed locally. | |
15364 | gl_getloadavg_LIBS=$LIBS | |
15365 | LIBS="-L/usr/local/lib $LIBS" | |
15366 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5 | |
15367 | $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; } | |
15368 | if ${ac_cv_lib_getloadavg_getloadavg+:} false; then : | |
1fd182f0 PE |
15369 | $as_echo_n "(cached) " >&6 |
15370 | else | |
1f5d53eb PE |
15371 | ac_check_lib_save_LIBS=$LIBS |
15372 | LIBS="-lgetloadavg $LIBS" | |
15373 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1fd182f0 | 15374 | /* end confdefs.h. */ |
1f5d53eb PE |
15375 | |
15376 | /* Override any GCC internal prototype to avoid an error. | |
15377 | Use char because int might match the return type of a GCC | |
15378 | builtin and then its argument prototype would still apply. */ | |
15379 | #ifdef __cplusplus | |
15380 | extern "C" | |
15381 | #endif | |
15382 | char getloadavg (); | |
1fd182f0 PE |
15383 | int |
15384 | main () | |
15385 | { | |
1f5d53eb | 15386 | return getloadavg (); |
1fd182f0 PE |
15387 | ; |
15388 | return 0; | |
15389 | } | |
15390 | _ACEOF | |
1f5d53eb PE |
15391 | if ac_fn_c_try_link "$LINENO"; then : |
15392 | ac_cv_lib_getloadavg_getloadavg=yes | |
15393 | else | |
15394 | ac_cv_lib_getloadavg_getloadavg=no | |
1fd182f0 | 15395 | fi |
1f5d53eb PE |
15396 | rm -f core conftest.err conftest.$ac_objext \ |
15397 | conftest$ac_exeext conftest.$ac_ext | |
15398 | LIBS=$ac_check_lib_save_LIBS | |
15399 | fi | |
15400 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5 | |
15401 | $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; } | |
15402 | if test "x$ac_cv_lib_getloadavg_getloadavg" = xyes; then : | |
15403 | LIBS="-lgetloadavg $LIBS" gl_have_func=yes | |
15404 | else | |
15405 | LIBS=$gl_getloadavg_LIBS | |
1fd182f0 | 15406 | fi |
1fd182f0 | 15407 | |
1f5d53eb | 15408 | fi |
1fd182f0 | 15409 | |
1f5d53eb PE |
15410 | # Set up the replacement function if necessary. |
15411 | if test $gl_have_func = no; then | |
1fd182f0 PE |
15412 | |
15413 | ||
15414 | ||
15415 | ||
1f5d53eb PE |
15416 | |
15417 | ||
15418 | ||
15419 | ||
15420 | gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext" | |
15421 | ||
15422 | ||
15423 | # Figure out what our getloadavg.c needs. | |
15424 | ||
15425 | # Solaris has libkstat which does not require root. | |
15426 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5 | |
15427 | $as_echo_n "checking for kstat_open in -lkstat... " >&6; } | |
15428 | if ${ac_cv_lib_kstat_kstat_open+:} false; then : | |
1fd182f0 PE |
15429 | $as_echo_n "(cached) " >&6 |
15430 | else | |
1f5d53eb PE |
15431 | ac_check_lib_save_LIBS=$LIBS |
15432 | LIBS="-lkstat $LIBS" | |
15433 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1fd182f0 | 15434 | /* end confdefs.h. */ |
1fd182f0 | 15435 | |
1f5d53eb PE |
15436 | /* Override any GCC internal prototype to avoid an error. |
15437 | Use char because int might match the return type of a GCC | |
15438 | builtin and then its argument prototype would still apply. */ | |
15439 | #ifdef __cplusplus | |
15440 | extern "C" | |
15441 | #endif | |
15442 | char kstat_open (); | |
1fd182f0 PE |
15443 | int |
15444 | main () | |
15445 | { | |
1f5d53eb | 15446 | return kstat_open (); |
1fd182f0 PE |
15447 | ; |
15448 | return 0; | |
15449 | } | |
15450 | _ACEOF | |
1f5d53eb PE |
15451 | if ac_fn_c_try_link "$LINENO"; then : |
15452 | ac_cv_lib_kstat_kstat_open=yes | |
1fd182f0 | 15453 | else |
1f5d53eb | 15454 | ac_cv_lib_kstat_kstat_open=no |
1fd182f0 | 15455 | fi |
1f5d53eb PE |
15456 | rm -f core conftest.err conftest.$ac_objext \ |
15457 | conftest$ac_exeext conftest.$ac_ext | |
15458 | LIBS=$ac_check_lib_save_LIBS | |
1fd182f0 | 15459 | fi |
1f5d53eb PE |
15460 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5 |
15461 | $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; } | |
15462 | if test "x$ac_cv_lib_kstat_kstat_open" = xyes; then : | |
15463 | cat >>confdefs.h <<_ACEOF | |
15464 | #define HAVE_LIBKSTAT 1 | |
15465 | _ACEOF | |
1fd182f0 | 15466 | |
1f5d53eb PE |
15467 | LIBS="-lkstat $LIBS" |
15468 | ||
15469 | fi | |
15470 | ||
15471 | test $ac_cv_lib_kstat_kstat_open = yes && gl_have_func=yes | |
15472 | ||
15473 | # On HPUX9, an unprivileged user can get load averages this way. | |
15474 | if test $gl_have_func = no; then | |
15475 | for ac_func in pstat_getdynamic | |
15476 | do : | |
15477 | ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic" | |
15478 | if test "x$ac_cv_func_pstat_getdynamic" = xyes; then : | |
15479 | cat >>confdefs.h <<_ACEOF | |
15480 | #define HAVE_PSTAT_GETDYNAMIC 1 | |
15481 | _ACEOF | |
15482 | gl_have_func=yes | |
15483 | fi | |
15484 | done | |
15485 | ||
15486 | fi | |
15487 | ||
15488 | # AIX has libperfstat which does not require root | |
15489 | if test $gl_have_func = no; then | |
15490 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5 | |
15491 | $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; } | |
15492 | if ${ac_cv_lib_perfstat_perfstat_cpu_total+:} false; then : | |
1fd182f0 PE |
15493 | $as_echo_n "(cached) " >&6 |
15494 | else | |
1f5d53eb PE |
15495 | ac_check_lib_save_LIBS=$LIBS |
15496 | LIBS="-lperfstat $LIBS" | |
15497 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1fd182f0 | 15498 | /* end confdefs.h. */ |
1fd182f0 | 15499 | |
1f5d53eb PE |
15500 | /* Override any GCC internal prototype to avoid an error. |
15501 | Use char because int might match the return type of a GCC | |
15502 | builtin and then its argument prototype would still apply. */ | |
15503 | #ifdef __cplusplus | |
15504 | extern "C" | |
15505 | #endif | |
15506 | char perfstat_cpu_total (); | |
1fd182f0 PE |
15507 | int |
15508 | main () | |
15509 | { | |
1f5d53eb | 15510 | return perfstat_cpu_total (); |
1fd182f0 PE |
15511 | ; |
15512 | return 0; | |
15513 | } | |
15514 | _ACEOF | |
1f5d53eb PE |
15515 | if ac_fn_c_try_link "$LINENO"; then : |
15516 | ac_cv_lib_perfstat_perfstat_cpu_total=yes | |
1fd182f0 | 15517 | else |
1f5d53eb | 15518 | ac_cv_lib_perfstat_perfstat_cpu_total=no |
1fd182f0 | 15519 | fi |
1f5d53eb PE |
15520 | rm -f core conftest.err conftest.$ac_objext \ |
15521 | conftest$ac_exeext conftest.$ac_ext | |
15522 | LIBS=$ac_check_lib_save_LIBS | |
1fd182f0 | 15523 | fi |
1f5d53eb PE |
15524 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5 |
15525 | $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; } | |
15526 | if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = xyes; then : | |
15527 | cat >>confdefs.h <<_ACEOF | |
15528 | #define HAVE_LIBPERFSTAT 1 | |
15529 | _ACEOF | |
15530 | ||
15531 | LIBS="-lperfstat $LIBS" | |
15532 | ||
15533 | fi | |
15534 | ||
15535 | test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_have_func=yes | |
15536 | fi | |
15537 | ||
15538 | if test $gl_have_func = no; then | |
15539 | ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default" | |
15540 | if test "x$ac_cv_header_sys_dg_sys_info_h" = xyes; then : | |
15541 | gl_have_func=yes | |
15542 | ||
15543 | $as_echo "#define DGUX 1" >>confdefs.h | |
15544 | ||
15545 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5 | |
15546 | $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; } | |
15547 | if ${ac_cv_lib_dgc_dg_sys_info+:} false; then : | |
1fd182f0 PE |
15548 | $as_echo_n "(cached) " >&6 |
15549 | else | |
1f5d53eb PE |
15550 | ac_check_lib_save_LIBS=$LIBS |
15551 | LIBS="-ldgc $LIBS" | |
15552 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1fd182f0 | 15553 | /* end confdefs.h. */ |
1fd182f0 | 15554 | |
1f5d53eb PE |
15555 | /* Override any GCC internal prototype to avoid an error. |
15556 | Use char because int might match the return type of a GCC | |
15557 | builtin and then its argument prototype would still apply. */ | |
15558 | #ifdef __cplusplus | |
15559 | extern "C" | |
15560 | #endif | |
15561 | char dg_sys_info (); | |
1fd182f0 PE |
15562 | int |
15563 | main () | |
15564 | { | |
1f5d53eb | 15565 | return dg_sys_info (); |
1fd182f0 PE |
15566 | ; |
15567 | return 0; | |
15568 | } | |
15569 | _ACEOF | |
1f5d53eb PE |
15570 | if ac_fn_c_try_link "$LINENO"; then : |
15571 | ac_cv_lib_dgc_dg_sys_info=yes | |
1fd182f0 | 15572 | else |
1f5d53eb | 15573 | ac_cv_lib_dgc_dg_sys_info=no |
1fd182f0 | 15574 | fi |
1f5d53eb PE |
15575 | rm -f core conftest.err conftest.$ac_objext \ |
15576 | conftest$ac_exeext conftest.$ac_ext | |
15577 | LIBS=$ac_check_lib_save_LIBS | |
1fd182f0 | 15578 | fi |
1f5d53eb PE |
15579 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5 |
15580 | $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; } | |
15581 | if test "x$ac_cv_lib_dgc_dg_sys_info" = xyes; then : | |
15582 | cat >>confdefs.h <<_ACEOF | |
15583 | #define HAVE_LIBDGC 1 | |
15584 | _ACEOF | |
1fd182f0 | 15585 | |
1f5d53eb | 15586 | LIBS="-ldgc $LIBS" |
1fd182f0 | 15587 | |
1f5d53eb | 15588 | fi |
1fd182f0 | 15589 | |
1f5d53eb | 15590 | fi |
1fd182f0 PE |
15591 | |
15592 | ||
1f5d53eb | 15593 | fi |
1fd182f0 | 15594 | |
1f5d53eb PE |
15595 | # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it |
15596 | # uses stabs), but it is still SVR4. We cannot check for <elf.h> because | |
15597 | # Irix 4.0.5F has the header but not the library. | |
15598 | if test $gl_have_func = no && test "$ac_cv_lib_elf_elf_begin" = yes \ | |
15599 | && test "$ac_cv_lib_kvm_kvm_open" = yes; then | |
15600 | gl_have_func=yes | |
1fd182f0 | 15601 | |
1f5d53eb | 15602 | $as_echo "#define SVR4 1" >>confdefs.h |
1fd182f0 | 15603 | |
1f5d53eb | 15604 | fi |
1fd182f0 | 15605 | |
1f5d53eb PE |
15606 | if test $gl_have_func = no; then |
15607 | ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default" | |
15608 | if test "x$ac_cv_header_inq_stats_cpustats_h" = xyes; then : | |
15609 | gl_have_func=yes | |
1fd182f0 | 15610 | |
1f5d53eb | 15611 | $as_echo "#define UMAX 1" >>confdefs.h |
1fd182f0 PE |
15612 | |
15613 | ||
1f5d53eb | 15614 | $as_echo "#define UMAX4_3 1" >>confdefs.h |
1fd182f0 | 15615 | |
1f5d53eb | 15616 | fi |
b06b1098 PE |
15617 | |
15618 | ||
1f5d53eb | 15619 | fi |
1fd182f0 | 15620 | |
1f5d53eb PE |
15621 | if test $gl_have_func = no; then |
15622 | ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default" | |
15623 | if test "x$ac_cv_header_sys_cpustats_h" = xyes; then : | |
15624 | gl_have_func=yes; $as_echo "#define UMAX 1" >>confdefs.h | |
1fd182f0 | 15625 | |
1f5d53eb | 15626 | fi |
b06b1098 | 15627 | |
1fd182f0 PE |
15628 | |
15629 | fi | |
1fd182f0 | 15630 | |
1f5d53eb PE |
15631 | if test $gl_have_func = no; then |
15632 | for ac_header in mach/mach.h | |
15633 | do : | |
15634 | ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default" | |
15635 | if test "x$ac_cv_header_mach_mach_h" = xyes; then : | |
15636 | cat >>confdefs.h <<_ACEOF | |
15637 | #define HAVE_MACH_MACH_H 1 | |
15638 | _ACEOF | |
1fd182f0 | 15639 | |
1f5d53eb | 15640 | fi |
1fd182f0 | 15641 | |
1f5d53eb | 15642 | done |
1fd182f0 | 15643 | |
1f5d53eb | 15644 | fi |
1fd182f0 | 15645 | |
1f5d53eb PE |
15646 | for ac_header in nlist.h |
15647 | do : | |
15648 | ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default" | |
15649 | if test "x$ac_cv_header_nlist_h" = xyes; then : | |
15650 | cat >>confdefs.h <<_ACEOF | |
15651 | #define HAVE_NLIST_H 1 | |
15652 | _ACEOF | |
15653 | ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h> | |
15654 | " | |
15655 | if test "x$ac_cv_member_struct_nlist_n_un_n_name" = xyes; then : | |
15656 | ||
15657 | cat >>confdefs.h <<_ACEOF | |
15658 | #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1 | |
15659 | _ACEOF | |
1fd182f0 | 15660 | |
b06b1098 | 15661 | |
1fd182f0 PE |
15662 | fi |
15663 | ||
1f5d53eb PE |
15664 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
15665 | /* end confdefs.h. */ | |
15666 | #include <nlist.h> | |
15667 | int | |
15668 | main () | |
15669 | { | |
15670 | struct nlist x; | |
15671 | #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME | |
15672 | x.n_un.n_name = ""; | |
15673 | #else | |
15674 | x.n_name = ""; | |
15675 | #endif | |
15676 | ; | |
15677 | return 0; | |
15678 | } | |
1fd182f0 | 15679 | _ACEOF |
1f5d53eb PE |
15680 | if ac_fn_c_try_link "$LINENO"; then : |
15681 | ||
15682 | $as_echo "#define N_NAME_POINTER 1" >>confdefs.h | |
15683 | ||
15684 | fi | |
15685 | rm -f core conftest.err conftest.$ac_objext \ | |
15686 | conftest$ac_exeext conftest.$ac_ext | |
1fd182f0 | 15687 | |
1f5d53eb | 15688 | fi |
1fd182f0 | 15689 | |
1f5d53eb | 15690 | done |
1fd182f0 | 15691 | |
1f5d53eb PE |
15692 | fi |
15693 | fi | |
1fd182f0 | 15694 | |
1f5d53eb PE |
15695 | |
15696 | if test "x$gl_save_LIBS" = x; then | |
15697 | GETLOADAVG_LIBS=$LIBS | |
1fd182f0 | 15698 | else |
1f5d53eb | 15699 | GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"` |
1fd182f0 | 15700 | fi |
1f5d53eb | 15701 | LIBS=$gl_save_LIBS |
1fd182f0 | 15702 | |
1fd182f0 | 15703 | |
1f5d53eb PE |
15704 | # Test whether the system declares getloadavg. Solaris has the function |
15705 | # but declares it in <sys/loadavg.h>, not <stdlib.h>. | |
15706 | for ac_header in sys/loadavg.h | |
15707 | do : | |
15708 | ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default" | |
15709 | if test "x$ac_cv_header_sys_loadavg_h" = xyes; then : | |
15710 | cat >>confdefs.h <<_ACEOF | |
15711 | #define HAVE_SYS_LOADAVG_H 1 | |
15712 | _ACEOF | |
15713 | ||
15714 | fi | |
1fd182f0 | 15715 | |
1f5d53eb | 15716 | done |
1fd182f0 | 15717 | |
1f5d53eb PE |
15718 | if test $ac_cv_header_sys_loadavg_h = yes; then |
15719 | HAVE_SYS_LOADAVG_H=1 | |
15720 | else | |
15721 | HAVE_SYS_LOADAVG_H=0 | |
15722 | fi | |
15723 | ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H | |
15724 | # include <sys/loadavg.h> | |
15725 | #endif | |
15726 | #include <stdlib.h> | |
15727 | " | |
15728 | if test "x$ac_cv_have_decl_getloadavg" = xyes; then : | |
1fd182f0 | 15729 | |
1f5d53eb PE |
15730 | else |
15731 | HAVE_DECL_GETLOADAVG=0 | |
15732 | fi | |
1fd182f0 PE |
15733 | |
15734 | ||
15735 | ||
15736 | ||
15737 | ||
1f5d53eb PE |
15738 | GNULIB_GETLOADAVG=1 |
15739 | ||
15740 | ||
1fd182f0 | 15741 | |
e275c824 PE |
15742 | # Code from module getopt-gnu: |
15743 | ||
15744 | ||
15745 | ||
15746 | ||
15747 | ||
15748 | ||
e275c824 PE |
15749 | # Code from module getopt-posix: |
15750 | ||
15751 | ||
15752 | ||
15753 | ||
15754 | ||
15755 | if test -n "$gl_replace_getopt"; then : | |
15756 | ||
15757 | ||
15758 | ||
15759 | GETOPT_H=getopt.h | |
15760 | ||
15761 | $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h | |
15762 | ||
15763 | ||
15764 | ||
15765 | GNULIB_UNISTD_H_GETOPT=1 | |
15766 | ||
15767 | ||
15768 | ||
15769 | ||
15770 | ||
15771 | ||
15772 | ||
15773 | ||
15774 | gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext" | |
15775 | ||
15776 | ||
15777 | ||
15778 | ||
15779 | ||
15780 | ||
15781 | ||
15782 | ||
15783 | ||
15784 | gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext" | |
15785 | ||
15786 | ||
15787 | ||
15788 | ||
15789 | ||
15790 | ||
15791 | fi | |
15792 | ||
15793 | ||
15794 | # Code from module gettext-h: | |
15795 | ||
15796 | ||
67342916 PE |
15797 | # Code from module ignore-value: |
15798 | ||
1fd182f0 PE |
15799 | # Code from module include_next: |
15800 | # Code from module intprops: | |
15801 | # Code from module mktime: | |
15802 | ||
15803 | ||
15804 | ||
15805 | ||
15806 | ||
15807 | if test $APPLE_UNIVERSAL_BUILD = 1; then | |
15808 | # A universal build on Apple MacOS X platforms. | |
15809 | # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode. | |
15810 | # But we need a configuration result that is valid in both modes. | |
15811 | ac_cv_func_working_mktime=no | |
15812 | fi | |
15813 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5 | |
15814 | $as_echo_n "checking for working mktime... " >&6; } | |
d6974efa | 15815 | if ${ac_cv_func_working_mktime+:} false; then : |
1fd182f0 PE |
15816 | $as_echo_n "(cached) " >&6 |
15817 | else | |
15818 | if test "$cross_compiling" = yes; then : | |
15819 | ac_cv_func_working_mktime=no | |
15820 | else | |
15821 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
15822 | /* end confdefs.h. */ | |
15823 | /* Test program from Paul Eggert and Tony Leneis. */ | |
15824 | #include <limits.h> | |
15825 | #include <stdlib.h> | |
15826 | #include <time.h> | |
15827 | ||
15828 | #ifdef HAVE_UNISTD_H | |
15829 | # include <unistd.h> | |
15830 | #endif | |
15831 | ||
15832 | #ifndef HAVE_ALARM | |
15833 | # define alarm(X) /* empty */ | |
15834 | #endif | |
15835 | ||
15836 | /* Work around redefinition to rpl_putenv by other config tests. */ | |
15837 | #undef putenv | |
15838 | ||
15839 | static time_t time_t_max; | |
15840 | static time_t time_t_min; | |
15841 | ||
15842 | /* Values we'll use to set the TZ environment variable. */ | |
15843 | static char *tz_strings[] = { | |
15844 | (char *) 0, "TZ=GMT0", "TZ=JST-9", | |
15845 | "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00" | |
15846 | }; | |
15847 | #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0])) | |
15848 | ||
15849 | /* Return 0 if mktime fails to convert a date in the spring-forward gap. | |
15850 | Based on a problem report from Andreas Jaeger. */ | |
15851 | static int | |
15852 | spring_forward_gap () | |
15853 | { | |
15854 | /* glibc (up to about 1998-10-07) failed this test. */ | |
15855 | struct tm tm; | |
15856 | ||
15857 | /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0" | |
15858 | instead of "TZ=America/Vancouver" in order to detect the bug even | |
15859 | on systems that don't support the Olson extension, or don't have the | |
15860 | full zoneinfo tables installed. */ | |
15861 | putenv ("TZ=PST8PDT,M4.1.0,M10.5.0"); | |
15862 | ||
15863 | tm.tm_year = 98; | |
15864 | tm.tm_mon = 3; | |
15865 | tm.tm_mday = 5; | |
15866 | tm.tm_hour = 2; | |
15867 | tm.tm_min = 0; | |
15868 | tm.tm_sec = 0; | |
15869 | tm.tm_isdst = -1; | |
15870 | return mktime (&tm) != (time_t) -1; | |
15871 | } | |
15872 | ||
15873 | static int | |
15874 | mktime_test1 (time_t now) | |
15875 | { | |
15876 | struct tm *lt; | |
15877 | return ! (lt = localtime (&now)) || mktime (lt) == now; | |
15878 | } | |
15879 | ||
15880 | static int | |
15881 | mktime_test (time_t now) | |
15882 | { | |
15883 | return (mktime_test1 (now) | |
15884 | && mktime_test1 ((time_t) (time_t_max - now)) | |
15885 | && mktime_test1 ((time_t) (time_t_min + now))); | |
15886 | } | |
15887 | ||
15888 | static int | |
15889 | irix_6_4_bug () | |
15890 | { | |
15891 | /* Based on code from Ariel Faigon. */ | |
15892 | struct tm tm; | |
15893 | tm.tm_year = 96; | |
15894 | tm.tm_mon = 3; | |
15895 | tm.tm_mday = 0; | |
15896 | tm.tm_hour = 0; | |
15897 | tm.tm_min = 0; | |
15898 | tm.tm_sec = 0; | |
15899 | tm.tm_isdst = -1; | |
15900 | mktime (&tm); | |
15901 | return tm.tm_mon == 2 && tm.tm_mday == 31; | |
15902 | } | |
15903 | ||
15904 | static int | |
15905 | bigtime_test (int j) | |
15906 | { | |
15907 | struct tm tm; | |
15908 | time_t now; | |
15909 | tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j; | |
15910 | now = mktime (&tm); | |
15911 | if (now != (time_t) -1) | |
15912 | { | |
15913 | struct tm *lt = localtime (&now); | |
15914 | if (! (lt | |
15915 | && lt->tm_year == tm.tm_year | |
15916 | && lt->tm_mon == tm.tm_mon | |
15917 | && lt->tm_mday == tm.tm_mday | |
15918 | && lt->tm_hour == tm.tm_hour | |
15919 | && lt->tm_min == tm.tm_min | |
15920 | && lt->tm_sec == tm.tm_sec | |
15921 | && lt->tm_yday == tm.tm_yday | |
15922 | && lt->tm_wday == tm.tm_wday | |
15923 | && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst) | |
15924 | == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst)))) | |
15925 | return 0; | |
15926 | } | |
15927 | return 1; | |
15928 | } | |
15929 | ||
15930 | static int | |
15931 | year_2050_test () | |
15932 | { | |
15933 | /* The correct answer for 2050-02-01 00:00:00 in Pacific time, | |
15934 | ignoring leap seconds. */ | |
15935 | unsigned long int answer = 2527315200UL; | |
15936 | ||
15937 | struct tm tm; | |
15938 | time_t t; | |
15939 | tm.tm_year = 2050 - 1900; | |
15940 | tm.tm_mon = 2 - 1; | |
15941 | tm.tm_mday = 1; | |
15942 | tm.tm_hour = tm.tm_min = tm.tm_sec = 0; | |
15943 | tm.tm_isdst = -1; | |
15944 | ||
15945 | /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0" | |
15946 | instead of "TZ=America/Vancouver" in order to detect the bug even | |
15947 | on systems that don't support the Olson extension, or don't have the | |
15948 | full zoneinfo tables installed. */ | |
15949 | putenv ("TZ=PST8PDT,M4.1.0,M10.5.0"); | |
15950 | ||
15951 | t = mktime (&tm); | |
15952 | ||
15953 | /* Check that the result is either a failure, or close enough | |
15954 | to the correct answer that we can assume the discrepancy is | |
15955 | due to leap seconds. */ | |
15956 | return (t == (time_t) -1 | |
15957 | || (0 < t && answer - 120 <= t && t <= answer + 120)); | |
15958 | } | |
15959 | ||
15960 | int | |
15961 | main () | |
15962 | { | |
15963 | int result = 0; | |
15964 | time_t t, delta; | |
15965 | int i, j; | |
3de84ad9 PE |
15966 | int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1; |
15967 | int time_t_signed = ! ((time_t) 0 < (time_t) -1); | |
1fd182f0 PE |
15968 | |
15969 | /* This test makes some buggy mktime implementations loop. | |
15970 | Give up after 60 seconds; a mktime slower than that | |
15971 | isn't worth using anyway. */ | |
15972 | alarm (60); | |
15973 | ||
3de84ad9 PE |
15974 | time_t_max = (! time_t_signed |
15975 | ? (time_t) -1 | |
15976 | : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1) | |
15977 | * 2 + 1)); | |
15978 | time_t_min = (! time_t_signed | |
15979 | ? (time_t) 0 | |
15980 | : time_t_signed_magnitude | |
15981 | ? ~ (time_t) 0 | |
15982 | : ~ time_t_max); | |
1fd182f0 PE |
15983 | |
15984 | delta = time_t_max / 997; /* a suitable prime number */ | |
15985 | for (i = 0; i < N_STRINGS; i++) | |
15986 | { | |
15987 | if (tz_strings[i]) | |
15988 | putenv (tz_strings[i]); | |
15989 | ||
15990 | for (t = 0; t <= time_t_max - delta; t += delta) | |
15991 | if (! mktime_test (t)) | |
15992 | result |= 1; | |
15993 | if (! (mktime_test ((time_t) 1) | |
15994 | && mktime_test ((time_t) (60 * 60)) | |
15995 | && mktime_test ((time_t) (60 * 60 * 24)))) | |
15996 | result |= 2; | |
15997 | ||
15998 | for (j = 1; ; j <<= 1) | |
15999 | if (! bigtime_test (j)) | |
16000 | result |= 4; | |
16001 | else if (INT_MAX / 2 < j) | |
16002 | break; | |
16003 | if (! bigtime_test (INT_MAX)) | |
16004 | result |= 8; | |
16005 | } | |
16006 | if (! irix_6_4_bug ()) | |
16007 | result |= 16; | |
16008 | if (! spring_forward_gap ()) | |
16009 | result |= 32; | |
16010 | if (! year_2050_test ()) | |
16011 | result |= 64; | |
16012 | return result; | |
16013 | } | |
16014 | _ACEOF | |
16015 | if ac_fn_c_try_run "$LINENO"; then : | |
16016 | ac_cv_func_working_mktime=yes | |
16017 | else | |
16018 | ac_cv_func_working_mktime=no | |
16019 | fi | |
16020 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
16021 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
067d23c9 | 16022 | fi |
067d23c9 | 16023 | |
1fd182f0 PE |
16024 | fi |
16025 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_working_mktime" >&5 | |
16026 | $as_echo "$ac_cv_func_working_mktime" >&6; } | |
16027 | if test $ac_cv_func_working_mktime = no; then | |
067d23c9 | 16028 | |
067d23c9 | 16029 | |
067d23c9 KY |
16030 | |
16031 | ||
067d23c9 | 16032 | |
067d23c9 KY |
16033 | |
16034 | ||
16035 | ||
1fd182f0 | 16036 | gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext" |
067d23c9 | 16037 | |
1fd182f0 | 16038 | fi |
067d23c9 | 16039 | |
1fd182f0 PE |
16040 | if test $ac_cv_func_working_mktime = no; then |
16041 | REPLACE_MKTIME=1 | |
067d23c9 KY |
16042 | |
16043 | ||
16044 | ||
1fd182f0 PE |
16045 | else |
16046 | REPLACE_MKTIME=0 | |
16047 | fi | |
067d23c9 KY |
16048 | |
16049 | ||
16050 | ||
067d23c9 | 16051 | |
1fd182f0 | 16052 | GNULIB_MKTIME=1 |
067d23c9 KY |
16053 | |
16054 | ||
16055 | ||
1fd182f0 | 16056 | # Code from module multiarch: |
067d23c9 | 16057 | |
16c3e636 PE |
16058 | # Code from module stdbool: |
16059 | ||
16060 | ||
16061 | ||
16062 | # Define two additional variables used in the Makefile substitution. | |
16063 | ||
16064 | if test "$ac_cv_header_stdbool_h" = yes; then | |
16065 | STDBOOL_H='' | |
16066 | else | |
16067 | STDBOOL_H='stdbool.h' | |
16068 | fi | |
16069 | ||
16070 | ||
16071 | if test "$ac_cv_type__Bool" = yes; then | |
16072 | HAVE__BOOL=1 | |
16073 | else | |
16074 | HAVE__BOOL=0 | |
16075 | fi | |
16076 | ||
16077 | ||
1fd182f0 | 16078 | # Code from module stddef: |
067d23c9 | 16079 | |
067d23c9 | 16080 | |
067d23c9 | 16081 | |
1fd182f0 PE |
16082 | if test $gt_cv_c_wchar_t = no; then |
16083 | HAVE_WCHAR_T=0 | |
16084 | STDDEF_H=stddef.h | |
067d23c9 | 16085 | fi |
1fd182f0 PE |
16086 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5 |
16087 | $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; } | |
d6974efa | 16088 | if ${gl_cv_decl_null_works+:} false; then : |
067d23c9 | 16089 | $as_echo_n "(cached) " >&6 |
067d23c9 KY |
16090 | else |
16091 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
16092 | /* end confdefs.h. */ | |
1fd182f0 PE |
16093 | #include <stddef.h> |
16094 | int test[2 * (sizeof NULL == sizeof (void *)) -1]; | |
16095 | ||
067d23c9 KY |
16096 | int |
16097 | main () | |
16098 | { | |
16099 | ||
067d23c9 KY |
16100 | ; |
16101 | return 0; | |
16102 | } | |
16103 | _ACEOF | |
1fd182f0 PE |
16104 | if ac_fn_c_try_compile "$LINENO"; then : |
16105 | gl_cv_decl_null_works=yes | |
067d23c9 | 16106 | else |
1fd182f0 | 16107 | gl_cv_decl_null_works=no |
067d23c9 | 16108 | fi |
1fd182f0 | 16109 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
067d23c9 | 16110 | fi |
1fd182f0 PE |
16111 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5 |
16112 | $as_echo "$gl_cv_decl_null_works" >&6; } | |
16113 | if test $gl_cv_decl_null_works = no; then | |
16114 | REPLACE_NULL=1 | |
16115 | STDDEF_H=stddef.h | |
16116 | fi | |
16117 | if test -n "$STDDEF_H"; then | |
16118 | ||
16119 | ||
16120 | ||
16121 | ||
16122 | ||
16123 | ||
b06b1098 PE |
16124 | |
16125 | ||
1fd182f0 PE |
16126 | if test $gl_cv_have_include_next = yes; then |
16127 | gl_cv_next_stddef_h='<'stddef.h'>' | |
16128 | else | |
16129 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5 | |
16130 | $as_echo_n "checking absolute name of <stddef.h>... " >&6; } | |
d6974efa | 16131 | if ${gl_cv_next_stddef_h+:} false; then : |
1fd182f0 PE |
16132 | $as_echo_n "(cached) " >&6 |
16133 | else | |
16134 | ||
b06b1098 | 16135 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
1fd182f0 PE |
16136 | /* end confdefs.h. */ |
16137 | #include <stddef.h> | |
16138 | ||
16139 | _ACEOF | |
b06b1098 PE |
16140 | case "$host_os" in |
16141 | aix*) gl_absname_cpp="$ac_cpp -C" ;; | |
16142 | *) gl_absname_cpp="$ac_cpp" ;; | |
16143 | esac | |
16144 | gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | | |
16145 | sed -n '\#/stddef.h#{ | |
16146 | s#.*"\(.*/stddef.h\)".*#\1# | |
16147 | s#^/[^/]#//&# | |
16148 | p | |
16149 | q | |
16150 | }'`'"' | |
16151 | ||
067d23c9 KY |
16152 | |
16153 | fi | |
1fd182f0 PE |
16154 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5 |
16155 | $as_echo "$gl_cv_next_stddef_h" >&6; } | |
16156 | fi | |
16157 | NEXT_STDDEF_H=$gl_cv_next_stddef_h | |
16158 | ||
16159 | if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then | |
16160 | # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' | |
16161 | gl_next_as_first_directive='<'stddef.h'>' | |
16162 | else | |
16163 | # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' | |
16164 | gl_next_as_first_directive=$gl_cv_next_stddef_h | |
16165 | fi | |
16166 | NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive | |
16167 | ||
16168 | ||
16169 | ||
b06b1098 | 16170 | |
067d23c9 KY |
16171 | fi |
16172 | ||
5f90be1b PE |
16173 | # Code from module stdint: |
16174 | ||
16175 | ||
16176 | ||
16177 | if test $ac_cv_type_long_long_int = yes; then | |
16178 | HAVE_LONG_LONG_INT=1 | |
16179 | else | |
16180 | HAVE_LONG_LONG_INT=0 | |
16181 | fi | |
16182 | ||
16183 | ||
16184 | if test $ac_cv_type_unsigned_long_long_int = yes; then | |
16185 | HAVE_UNSIGNED_LONG_LONG_INT=1 | |
16186 | else | |
16187 | HAVE_UNSIGNED_LONG_LONG_INT=0 | |
16188 | fi | |
16189 | ||
16190 | ||
16191 | ||
16192 | if test $ac_cv_header_wchar_h = yes; then | |
16193 | HAVE_WCHAR_H=1 | |
16194 | else | |
16195 | HAVE_WCHAR_H=0 | |
16196 | fi | |
16197 | ||
16198 | ||
16199 | if test $ac_cv_header_inttypes_h = yes; then | |
16200 | HAVE_INTTYPES_H=1 | |
16201 | else | |
16202 | HAVE_INTTYPES_H=0 | |
16203 | fi | |
16204 | ||
16205 | ||
16206 | if test $ac_cv_header_sys_types_h = yes; then | |
16207 | HAVE_SYS_TYPES_H=1 | |
16208 | else | |
16209 | HAVE_SYS_TYPES_H=0 | |
16210 | fi | |
16211 | ||
16212 | ||
16213 | ||
16214 | ||
16215 | ||
16216 | ||
16217 | ||
16218 | ||
16219 | ||
16220 | ||
16221 | ||
16222 | if test $gl_cv_have_include_next = yes; then | |
16223 | gl_cv_next_stdint_h='<'stdint.h'>' | |
16224 | else | |
16225 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5 | |
16226 | $as_echo_n "checking absolute name of <stdint.h>... " >&6; } | |
16227 | if ${gl_cv_next_stdint_h+:} false; then : | |
16228 | $as_echo_n "(cached) " >&6 | |
16229 | else | |
16230 | ||
16231 | if test $ac_cv_header_stdint_h = yes; then | |
16232 | ||
16233 | ||
16234 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
16235 | /* end confdefs.h. */ | |
16236 | #include <stdint.h> | |
16237 | ||
16238 | _ACEOF | |
16239 | case "$host_os" in | |
16240 | aix*) gl_absname_cpp="$ac_cpp -C" ;; | |
16241 | *) gl_absname_cpp="$ac_cpp" ;; | |
16242 | esac | |
16243 | gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | | |
16244 | sed -n '\#/stdint.h#{ | |
16245 | s#.*"\(.*/stdint.h\)".*#\1# | |
16246 | s#^/[^/]#//&# | |
16247 | p | |
16248 | q | |
16249 | }'`'"' | |
16250 | else | |
16251 | gl_cv_next_stdint_h='<'stdint.h'>' | |
16252 | fi | |
16253 | ||
16254 | ||
16255 | fi | |
16256 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5 | |
16257 | $as_echo "$gl_cv_next_stdint_h" >&6; } | |
16258 | fi | |
16259 | NEXT_STDINT_H=$gl_cv_next_stdint_h | |
16260 | ||
16261 | if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then | |
16262 | # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' | |
16263 | gl_next_as_first_directive='<'stdint.h'>' | |
16264 | else | |
16265 | # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' | |
16266 | gl_next_as_first_directive=$gl_cv_next_stdint_h | |
16267 | fi | |
16268 | NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive | |
16269 | ||
16270 | ||
16271 | ||
16272 | ||
16273 | if test $ac_cv_header_stdint_h = yes; then | |
16274 | HAVE_STDINT_H=1 | |
16275 | else | |
16276 | HAVE_STDINT_H=0 | |
16277 | fi | |
16278 | ||
16279 | ||
16280 | if test $ac_cv_header_stdint_h = yes; then | |
16281 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5 | |
16282 | $as_echo_n "checking whether stdint.h conforms to C99... " >&6; } | |
16283 | if ${gl_cv_header_working_stdint_h+:} false; then : | |
16284 | $as_echo_n "(cached) " >&6 | |
16285 | else | |
16286 | gl_cv_header_working_stdint_h=no | |
16287 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
16288 | /* end confdefs.h. */ | |
16289 | ||
16290 | ||
16291 | #define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */ | |
16292 | #define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */ | |
16293 | #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */ | |
16294 | #include <stdint.h> | |
16295 | /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */ | |
16296 | #if !(defined WCHAR_MIN && defined WCHAR_MAX) | |
16297 | #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>" | |
16298 | #endif | |
16299 | ||
16300 | ||
16301 | /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be | |
16302 | included before <wchar.h>. */ | |
16303 | #include <stddef.h> | |
16304 | #include <signal.h> | |
16305 | #if HAVE_WCHAR_H | |
16306 | # include <stdio.h> | |
16307 | # include <time.h> | |
16308 | # include <wchar.h> | |
16309 | #endif | |
16310 | ||
16311 | ||
16312 | #ifdef INT8_MAX | |
16313 | int8_t a1 = INT8_MAX; | |
16314 | int8_t a1min = INT8_MIN; | |
16315 | #endif | |
16316 | #ifdef INT16_MAX | |
16317 | int16_t a2 = INT16_MAX; | |
16318 | int16_t a2min = INT16_MIN; | |
16319 | #endif | |
16320 | #ifdef INT32_MAX | |
16321 | int32_t a3 = INT32_MAX; | |
16322 | int32_t a3min = INT32_MIN; | |
16323 | #endif | |
16324 | #ifdef INT64_MAX | |
16325 | int64_t a4 = INT64_MAX; | |
16326 | int64_t a4min = INT64_MIN; | |
16327 | #endif | |
16328 | #ifdef UINT8_MAX | |
16329 | uint8_t b1 = UINT8_MAX; | |
16330 | #else | |
16331 | typedef int b1[(unsigned char) -1 != 255 ? 1 : -1]; | |
16332 | #endif | |
16333 | #ifdef UINT16_MAX | |
16334 | uint16_t b2 = UINT16_MAX; | |
16335 | #endif | |
16336 | #ifdef UINT32_MAX | |
16337 | uint32_t b3 = UINT32_MAX; | |
16338 | #endif | |
16339 | #ifdef UINT64_MAX | |
16340 | uint64_t b4 = UINT64_MAX; | |
16341 | #endif | |
16342 | int_least8_t c1 = INT8_C (0x7f); | |
16343 | int_least8_t c1max = INT_LEAST8_MAX; | |
16344 | int_least8_t c1min = INT_LEAST8_MIN; | |
16345 | int_least16_t c2 = INT16_C (0x7fff); | |
16346 | int_least16_t c2max = INT_LEAST16_MAX; | |
16347 | int_least16_t c2min = INT_LEAST16_MIN; | |
16348 | int_least32_t c3 = INT32_C (0x7fffffff); | |
16349 | int_least32_t c3max = INT_LEAST32_MAX; | |
16350 | int_least32_t c3min = INT_LEAST32_MIN; | |
16351 | int_least64_t c4 = INT64_C (0x7fffffffffffffff); | |
16352 | int_least64_t c4max = INT_LEAST64_MAX; | |
16353 | int_least64_t c4min = INT_LEAST64_MIN; | |
16354 | uint_least8_t d1 = UINT8_C (0xff); | |
16355 | uint_least8_t d1max = UINT_LEAST8_MAX; | |
16356 | uint_least16_t d2 = UINT16_C (0xffff); | |
16357 | uint_least16_t d2max = UINT_LEAST16_MAX; | |
16358 | uint_least32_t d3 = UINT32_C (0xffffffff); | |
16359 | uint_least32_t d3max = UINT_LEAST32_MAX; | |
16360 | uint_least64_t d4 = UINT64_C (0xffffffffffffffff); | |
16361 | uint_least64_t d4max = UINT_LEAST64_MAX; | |
16362 | int_fast8_t e1 = INT_FAST8_MAX; | |
16363 | int_fast8_t e1min = INT_FAST8_MIN; | |
16364 | int_fast16_t e2 = INT_FAST16_MAX; | |
16365 | int_fast16_t e2min = INT_FAST16_MIN; | |
16366 | int_fast32_t e3 = INT_FAST32_MAX; | |
16367 | int_fast32_t e3min = INT_FAST32_MIN; | |
16368 | int_fast64_t e4 = INT_FAST64_MAX; | |
16369 | int_fast64_t e4min = INT_FAST64_MIN; | |
16370 | uint_fast8_t f1 = UINT_FAST8_MAX; | |
16371 | uint_fast16_t f2 = UINT_FAST16_MAX; | |
16372 | uint_fast32_t f3 = UINT_FAST32_MAX; | |
16373 | uint_fast64_t f4 = UINT_FAST64_MAX; | |
16374 | #ifdef INTPTR_MAX | |
16375 | intptr_t g = INTPTR_MAX; | |
16376 | intptr_t gmin = INTPTR_MIN; | |
16377 | #endif | |
16378 | #ifdef UINTPTR_MAX | |
16379 | uintptr_t h = UINTPTR_MAX; | |
16380 | #endif | |
16381 | intmax_t i = INTMAX_MAX; | |
16382 | uintmax_t j = UINTMAX_MAX; | |
16383 | ||
16384 | #include <limits.h> /* for CHAR_BIT */ | |
16385 | #define TYPE_MINIMUM(t) \ | |
16386 | ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t))) | |
16387 | #define TYPE_MAXIMUM(t) \ | |
16388 | ((t) ((t) 0 < (t) -1 \ | |
16389 | ? (t) -1 \ | |
16390 | : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1))) | |
16391 | struct s { | |
16392 | int check_PTRDIFF: | |
16393 | PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t) | |
16394 | && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t) | |
16395 | ? 1 : -1; | |
16396 | /* Detect bug in FreeBSD 6.0 / ia64. */ | |
16397 | int check_SIG_ATOMIC: | |
16398 | SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t) | |
16399 | && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t) | |
16400 | ? 1 : -1; | |
16401 | int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1; | |
16402 | int check_WCHAR: | |
16403 | WCHAR_MIN == TYPE_MINIMUM (wchar_t) | |
16404 | && WCHAR_MAX == TYPE_MAXIMUM (wchar_t) | |
16405 | ? 1 : -1; | |
16406 | /* Detect bug in mingw. */ | |
16407 | int check_WINT: | |
16408 | WINT_MIN == TYPE_MINIMUM (wint_t) | |
16409 | && WINT_MAX == TYPE_MAXIMUM (wint_t) | |
16410 | ? 1 : -1; | |
16411 | ||
16412 | /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */ | |
16413 | int check_UINT8_C: | |
16414 | (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1; | |
16415 | int check_UINT16_C: | |
16416 | (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1; | |
16417 | ||
16418 | /* Detect bugs in OpenBSD 3.9 stdint.h. */ | |
16419 | #ifdef UINT8_MAX | |
16420 | int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1; | |
16421 | #endif | |
16422 | #ifdef UINT16_MAX | |
16423 | int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1; | |
16424 | #endif | |
16425 | #ifdef UINT32_MAX | |
16426 | int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1; | |
16427 | #endif | |
16428 | #ifdef UINT64_MAX | |
16429 | int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1; | |
16430 | #endif | |
16431 | int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1; | |
16432 | int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1; | |
16433 | int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1; | |
16434 | int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1; | |
16435 | int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1; | |
16436 | int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1; | |
16437 | int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1; | |
16438 | int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1; | |
16439 | int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1; | |
16440 | int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1; | |
16441 | int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1; | |
16442 | }; | |
16443 | ||
16444 | int | |
16445 | main () | |
16446 | { | |
16447 | ||
16448 | ; | |
16449 | return 0; | |
16450 | } | |
16451 | _ACEOF | |
16452 | if ac_fn_c_try_compile "$LINENO"; then : | |
16453 | if test "$cross_compiling" = yes; then : | |
16454 | gl_cv_header_working_stdint_h=yes | |
16455 | ||
16456 | else | |
16457 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
16458 | /* end confdefs.h. */ | |
16459 | ||
16460 | ||
16461 | #define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */ | |
16462 | #define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */ | |
16463 | #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */ | |
16464 | #include <stdint.h> | |
16465 | ||
16466 | ||
16467 | /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be | |
16468 | included before <wchar.h>. */ | |
16469 | #include <stddef.h> | |
16470 | #include <signal.h> | |
16471 | #if HAVE_WCHAR_H | |
16472 | # include <stdio.h> | |
16473 | # include <time.h> | |
16474 | # include <wchar.h> | |
16475 | #endif | |
16476 | ||
16477 | ||
16478 | #include <stdio.h> | |
16479 | #include <string.h> | |
16480 | #define MVAL(macro) MVAL1(macro) | |
16481 | #define MVAL1(expression) #expression | |
16482 | static const char *macro_values[] = | |
16483 | { | |
16484 | #ifdef INT8_MAX | |
16485 | MVAL (INT8_MAX), | |
16486 | #endif | |
16487 | #ifdef INT16_MAX | |
16488 | MVAL (INT16_MAX), | |
16489 | #endif | |
16490 | #ifdef INT32_MAX | |
16491 | MVAL (INT32_MAX), | |
16492 | #endif | |
16493 | #ifdef INT64_MAX | |
16494 | MVAL (INT64_MAX), | |
16495 | #endif | |
16496 | #ifdef UINT8_MAX | |
16497 | MVAL (UINT8_MAX), | |
16498 | #endif | |
16499 | #ifdef UINT16_MAX | |
16500 | MVAL (UINT16_MAX), | |
16501 | #endif | |
16502 | #ifdef UINT32_MAX | |
16503 | MVAL (UINT32_MAX), | |
16504 | #endif | |
16505 | #ifdef UINT64_MAX | |
16506 | MVAL (UINT64_MAX), | |
16507 | #endif | |
16508 | NULL | |
16509 | }; | |
16510 | ||
16511 | int | |
16512 | main () | |
16513 | { | |
16514 | ||
16515 | const char **mv; | |
16516 | for (mv = macro_values; *mv != NULL; mv++) | |
16517 | { | |
16518 | const char *value = *mv; | |
16519 | /* Test whether it looks like a cast expression. */ | |
16520 | if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0 | |
16521 | || strncmp (value, "((unsigned short)"/*)*/, 17) == 0 | |
16522 | || strncmp (value, "((unsigned char)"/*)*/, 16) == 0 | |
16523 | || strncmp (value, "((int)"/*)*/, 6) == 0 | |
16524 | || strncmp (value, "((signed short)"/*)*/, 15) == 0 | |
16525 | || strncmp (value, "((signed char)"/*)*/, 14) == 0) | |
16526 | return mv - macro_values + 1; | |
16527 | } | |
16528 | return 0; | |
16529 | ||
16530 | ; | |
16531 | return 0; | |
16532 | } | |
16533 | _ACEOF | |
16534 | if ac_fn_c_try_run "$LINENO"; then : | |
16535 | gl_cv_header_working_stdint_h=yes | |
16536 | fi | |
16537 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
16538 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
16539 | fi | |
16540 | ||
16541 | ||
16542 | fi | |
16543 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
16544 | ||
16545 | fi | |
16546 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5 | |
16547 | $as_echo "$gl_cv_header_working_stdint_h" >&6; } | |
16548 | fi | |
16549 | if test "$gl_cv_header_working_stdint_h" = yes; then | |
16550 | STDINT_H= | |
16551 | else | |
16552 | for ac_header in sys/inttypes.h sys/bitypes.h | |
16553 | do : | |
16554 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
16555 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
16556 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
16557 | cat >>confdefs.h <<_ACEOF | |
16558 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
16559 | _ACEOF | |
16560 | ||
16561 | fi | |
16562 | ||
16563 | done | |
16564 | ||
16565 | if test $ac_cv_header_sys_inttypes_h = yes; then | |
16566 | HAVE_SYS_INTTYPES_H=1 | |
16567 | else | |
16568 | HAVE_SYS_INTTYPES_H=0 | |
16569 | fi | |
16570 | ||
16571 | if test $ac_cv_header_sys_bitypes_h = yes; then | |
16572 | HAVE_SYS_BITYPES_H=1 | |
16573 | else | |
16574 | HAVE_SYS_BITYPES_H=0 | |
16575 | fi | |
16576 | ||
16577 | ||
16578 | ||
16579 | ||
16580 | if test $APPLE_UNIVERSAL_BUILD = 0; then | |
16581 | ||
16582 | ||
16583 | for gltype in ptrdiff_t size_t ; do | |
16584 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5 | |
16585 | $as_echo_n "checking for bit size of $gltype... " >&6; } | |
16586 | if eval \${gl_cv_bitsizeof_${gltype}+:} false; then : | |
16587 | $as_echo_n "(cached) " >&6 | |
16588 | else | |
16589 | if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" " | |
16590 | /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be | |
16591 | included before <wchar.h>. */ | |
16592 | #include <stddef.h> | |
16593 | #include <signal.h> | |
16594 | #if HAVE_WCHAR_H | |
16595 | # include <stdio.h> | |
16596 | # include <time.h> | |
16597 | # include <wchar.h> | |
16598 | #endif | |
16599 | ||
16600 | #include <limits.h>"; then : | |
16601 | ||
16602 | else | |
16603 | result=unknown | |
16604 | fi | |
16605 | ||
16606 | eval gl_cv_bitsizeof_${gltype}=\$result | |
16607 | ||
16608 | fi | |
16609 | eval ac_res=\$gl_cv_bitsizeof_${gltype} | |
16610 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
16611 | $as_echo "$ac_res" >&6; } | |
16612 | eval result=\$gl_cv_bitsizeof_${gltype} | |
16613 | if test $result = unknown; then | |
16614 | result=0 | |
16615 | fi | |
16616 | GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'` | |
16617 | cat >>confdefs.h <<_ACEOF | |
16618 | #define BITSIZEOF_${GLTYPE} $result | |
16619 | _ACEOF | |
16620 | ||
16621 | eval BITSIZEOF_${GLTYPE}=\$result | |
16622 | done | |
16623 | ||
16624 | ||
16625 | fi | |
16626 | ||
16627 | ||
16628 | for gltype in sig_atomic_t wchar_t wint_t ; do | |
16629 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5 | |
16630 | $as_echo_n "checking for bit size of $gltype... " >&6; } | |
16631 | if eval \${gl_cv_bitsizeof_${gltype}+:} false; then : | |
16632 | $as_echo_n "(cached) " >&6 | |
16633 | else | |
16634 | if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" " | |
16635 | /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be | |
16636 | included before <wchar.h>. */ | |
16637 | #include <stddef.h> | |
16638 | #include <signal.h> | |
16639 | #if HAVE_WCHAR_H | |
16640 | # include <stdio.h> | |
16641 | # include <time.h> | |
16642 | # include <wchar.h> | |
16643 | #endif | |
16644 | ||
16645 | #include <limits.h>"; then : | |
16646 | ||
16647 | else | |
16648 | result=unknown | |
16649 | fi | |
16650 | ||
16651 | eval gl_cv_bitsizeof_${gltype}=\$result | |
16652 | ||
16653 | fi | |
16654 | eval ac_res=\$gl_cv_bitsizeof_${gltype} | |
16655 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
16656 | $as_echo "$ac_res" >&6; } | |
16657 | eval result=\$gl_cv_bitsizeof_${gltype} | |
16658 | if test $result = unknown; then | |
16659 | result=0 | |
16660 | fi | |
16661 | GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'` | |
16662 | cat >>confdefs.h <<_ACEOF | |
16663 | #define BITSIZEOF_${GLTYPE} $result | |
16664 | _ACEOF | |
16665 | ||
16666 | eval BITSIZEOF_${GLTYPE}=\$result | |
16667 | done | |
16668 | ||
16669 | ||
16670 | ||
16671 | ||
16672 | for gltype in sig_atomic_t wchar_t wint_t ; do | |
16673 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5 | |
16674 | $as_echo_n "checking whether $gltype is signed... " >&6; } | |
16675 | if eval \${gl_cv_type_${gltype}_signed+:} false; then : | |
16676 | $as_echo_n "(cached) " >&6 | |
16677 | else | |
16678 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
16679 | /* end confdefs.h. */ | |
16680 | ||
16681 | /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be | |
16682 | included before <wchar.h>. */ | |
16683 | #include <stddef.h> | |
16684 | #include <signal.h> | |
16685 | #if HAVE_WCHAR_H | |
16686 | # include <stdio.h> | |
16687 | # include <time.h> | |
16688 | # include <wchar.h> | |
16689 | #endif | |
16690 | ||
16691 | int verify[2 * (($gltype) -1 < ($gltype) 0) - 1]; | |
16692 | int | |
16693 | main () | |
16694 | { | |
16695 | ||
16696 | ; | |
16697 | return 0; | |
16698 | } | |
16699 | _ACEOF | |
16700 | if ac_fn_c_try_compile "$LINENO"; then : | |
16701 | result=yes | |
16702 | else | |
16703 | result=no | |
16704 | fi | |
16705 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
16706 | eval gl_cv_type_${gltype}_signed=\$result | |
16707 | ||
16708 | fi | |
16709 | eval ac_res=\$gl_cv_type_${gltype}_signed | |
16710 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
16711 | $as_echo "$ac_res" >&6; } | |
16712 | eval result=\$gl_cv_type_${gltype}_signed | |
16713 | GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'` | |
16714 | if test "$result" = yes; then | |
16715 | cat >>confdefs.h <<_ACEOF | |
16716 | #define HAVE_SIGNED_${GLTYPE} 1 | |
16717 | _ACEOF | |
16718 | ||
16719 | eval HAVE_SIGNED_${GLTYPE}=1 | |
16720 | else | |
16721 | eval HAVE_SIGNED_${GLTYPE}=0 | |
16722 | fi | |
16723 | done | |
16724 | ||
16725 | ||
16726 | gl_cv_type_ptrdiff_t_signed=yes | |
16727 | gl_cv_type_size_t_signed=no | |
16728 | if test $APPLE_UNIVERSAL_BUILD = 0; then | |
16729 | ||
16730 | ||
16731 | for gltype in ptrdiff_t size_t ; do | |
16732 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5 | |
16733 | $as_echo_n "checking for $gltype integer literal suffix... " >&6; } | |
16734 | if eval \${gl_cv_type_${gltype}_suffix+:} false; then : | |
16735 | $as_echo_n "(cached) " >&6 | |
16736 | else | |
16737 | eval gl_cv_type_${gltype}_suffix=no | |
16738 | eval result=\$gl_cv_type_${gltype}_signed | |
16739 | if test "$result" = yes; then | |
16740 | glsufu= | |
16741 | else | |
16742 | glsufu=u | |
16743 | fi | |
16744 | for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do | |
16745 | case $glsuf in | |
16746 | '') gltype1='int';; | |
16747 | l) gltype1='long int';; | |
16748 | ll) gltype1='long long int';; | |
16749 | i64) gltype1='__int64';; | |
16750 | u) gltype1='unsigned int';; | |
16751 | ul) gltype1='unsigned long int';; | |
16752 | ull) gltype1='unsigned long long int';; | |
16753 | ui64)gltype1='unsigned __int64';; | |
16754 | esac | |
16755 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
16756 | /* end confdefs.h. */ | |
16757 | ||
16758 | /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be | |
16759 | included before <wchar.h>. */ | |
16760 | #include <stddef.h> | |
16761 | #include <signal.h> | |
16762 | #if HAVE_WCHAR_H | |
16763 | # include <stdio.h> | |
16764 | # include <time.h> | |
16765 | # include <wchar.h> | |
16766 | #endif | |
16767 | ||
16768 | extern $gltype foo; | |
16769 | extern $gltype1 foo; | |
16770 | int | |
16771 | main () | |
16772 | { | |
16773 | ||
16774 | ; | |
16775 | return 0; | |
16776 | } | |
16777 | _ACEOF | |
16778 | if ac_fn_c_try_compile "$LINENO"; then : | |
16779 | eval gl_cv_type_${gltype}_suffix=\$glsuf | |
16780 | fi | |
16781 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
16782 | eval result=\$gl_cv_type_${gltype}_suffix | |
16783 | test "$result" != no && break | |
16784 | done | |
16785 | fi | |
16786 | eval ac_res=\$gl_cv_type_${gltype}_suffix | |
16787 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
16788 | $as_echo "$ac_res" >&6; } | |
16789 | GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'` | |
16790 | eval result=\$gl_cv_type_${gltype}_suffix | |
16791 | test "$result" = no && result= | |
16792 | eval ${GLTYPE}_SUFFIX=\$result | |
16793 | cat >>confdefs.h <<_ACEOF | |
16794 | #define ${GLTYPE}_SUFFIX $result | |
16795 | _ACEOF | |
16796 | ||
16797 | done | |
16798 | ||
16799 | ||
16800 | fi | |
16801 | ||
16802 | ||
16803 | for gltype in sig_atomic_t wchar_t wint_t ; do | |
16804 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5 | |
16805 | $as_echo_n "checking for $gltype integer literal suffix... " >&6; } | |
16806 | if eval \${gl_cv_type_${gltype}_suffix+:} false; then : | |
16807 | $as_echo_n "(cached) " >&6 | |
16808 | else | |
16809 | eval gl_cv_type_${gltype}_suffix=no | |
16810 | eval result=\$gl_cv_type_${gltype}_signed | |
16811 | if test "$result" = yes; then | |
16812 | glsufu= | |
16813 | else | |
16814 | glsufu=u | |
16815 | fi | |
16816 | for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do | |
16817 | case $glsuf in | |
16818 | '') gltype1='int';; | |
16819 | l) gltype1='long int';; | |
16820 | ll) gltype1='long long int';; | |
16821 | i64) gltype1='__int64';; | |
16822 | u) gltype1='unsigned int';; | |
16823 | ul) gltype1='unsigned long int';; | |
16824 | ull) gltype1='unsigned long long int';; | |
16825 | ui64)gltype1='unsigned __int64';; | |
16826 | esac | |
16827 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
16828 | /* end confdefs.h. */ | |
16829 | ||
16830 | /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be | |
16831 | included before <wchar.h>. */ | |
16832 | #include <stddef.h> | |
16833 | #include <signal.h> | |
16834 | #if HAVE_WCHAR_H | |
16835 | # include <stdio.h> | |
16836 | # include <time.h> | |
16837 | # include <wchar.h> | |
16838 | #endif | |
16839 | ||
16840 | extern $gltype foo; | |
16841 | extern $gltype1 foo; | |
16842 | int | |
16843 | main () | |
16844 | { | |
16845 | ||
16846 | ; | |
16847 | return 0; | |
16848 | } | |
16849 | _ACEOF | |
16850 | if ac_fn_c_try_compile "$LINENO"; then : | |
16851 | eval gl_cv_type_${gltype}_suffix=\$glsuf | |
16852 | fi | |
16853 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
16854 | eval result=\$gl_cv_type_${gltype}_suffix | |
16855 | test "$result" != no && break | |
16856 | done | |
16857 | fi | |
16858 | eval ac_res=\$gl_cv_type_${gltype}_suffix | |
16859 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
16860 | $as_echo "$ac_res" >&6; } | |
16861 | GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'` | |
16862 | eval result=\$gl_cv_type_${gltype}_suffix | |
16863 | test "$result" = no && result= | |
16864 | eval ${GLTYPE}_SUFFIX=\$result | |
16865 | cat >>confdefs.h <<_ACEOF | |
16866 | #define ${GLTYPE}_SUFFIX $result | |
16867 | _ACEOF | |
16868 | ||
16869 | done | |
16870 | ||
16871 | ||
16872 | ||
16873 | STDINT_H=stdint.h | |
16874 | fi | |
16875 | ||
16876 | ||
1f5d53eb PE |
16877 | # Code from module stdlib: |
16878 | ||
16879 | ||
16880 | ||
16881 | ||
16882 | ||
16883 | ||
16884 | ||
16885 | ||
16886 | ||
16887 | ||
16888 | if test $gl_cv_have_include_next = yes; then | |
16889 | gl_cv_next_stdlib_h='<'stdlib.h'>' | |
16890 | else | |
16891 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5 | |
16892 | $as_echo_n "checking absolute name of <stdlib.h>... " >&6; } | |
16893 | if ${gl_cv_next_stdlib_h+:} false; then : | |
16894 | $as_echo_n "(cached) " >&6 | |
16895 | else | |
16896 | ||
16897 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
16898 | /* end confdefs.h. */ | |
16899 | #include <stdlib.h> | |
16900 | ||
16901 | _ACEOF | |
16902 | case "$host_os" in | |
16903 | aix*) gl_absname_cpp="$ac_cpp -C" ;; | |
16904 | *) gl_absname_cpp="$ac_cpp" ;; | |
16905 | esac | |
16906 | gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | | |
16907 | sed -n '\#/stdlib.h#{ | |
16908 | s#.*"\(.*/stdlib.h\)".*#\1# | |
16909 | s#^/[^/]#//&# | |
16910 | p | |
16911 | q | |
16912 | }'`'"' | |
16913 | ||
16914 | ||
16915 | fi | |
16916 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5 | |
16917 | $as_echo "$gl_cv_next_stdlib_h" >&6; } | |
16918 | fi | |
16919 | NEXT_STDLIB_H=$gl_cv_next_stdlib_h | |
16920 | ||
16921 | if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then | |
16922 | # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' | |
16923 | gl_next_as_first_directive='<'stdlib.h'>' | |
16924 | else | |
16925 | # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' | |
16926 | gl_next_as_first_directive=$gl_cv_next_stdlib_h | |
16927 | fi | |
16928 | NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive | |
16929 | ||
16930 | ||
16931 | ||
16932 | ||
16933 | ||
16934 | ||
16935 | ||
16c3e636 PE |
16936 | # Code from module strftime: |
16937 | ||
16938 | ||
16939 | ||
16940 | ||
16941 | ||
16942 | ||
16943 | ||
16944 | ||
16945 | ||
16946 | ||
16947 | gl_LIBOBJS="$gl_LIBOBJS strftime.$ac_objext" | |
16948 | ||
16949 | ||
16950 | # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE. | |
16951 | ||
16952 | ||
16953 | ||
16954 | ||
16955 | ||
16956 | ||
16957 | ||
16958 | $as_echo "#define my_strftime nstrftime" >>confdefs.h | |
16959 | ||
16960 | ||
16961 | ||
5fa4ac76 PE |
16962 | # Code from module sys_stat: |
16963 | ||
16964 | ||
16965 | ||
16966 | ||
16967 | ||
16968 | ||
16969 | ||
16970 | ||
16971 | ||
16972 | ||
16973 | ||
16974 | ||
16975 | ||
16976 | ||
16977 | ||
16978 | ||
16979 | if test $gl_cv_have_include_next = yes; then | |
16980 | gl_cv_next_sys_stat_h='<'sys/stat.h'>' | |
16981 | else | |
16982 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5 | |
16983 | $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; } | |
16984 | if ${gl_cv_next_sys_stat_h+:} false; then : | |
16985 | $as_echo_n "(cached) " >&6 | |
16986 | else | |
16987 | ||
16988 | if test $ac_cv_header_sys_stat_h = yes; then | |
16989 | ||
16990 | ||
16991 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
16992 | /* end confdefs.h. */ | |
16993 | #include <sys/stat.h> | |
16994 | ||
16995 | _ACEOF | |
16996 | case "$host_os" in | |
16997 | aix*) gl_absname_cpp="$ac_cpp -C" ;; | |
16998 | *) gl_absname_cpp="$ac_cpp" ;; | |
16999 | esac | |
17000 | gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | | |
17001 | sed -n '\#/sys/stat.h#{ | |
17002 | s#.*"\(.*/sys/stat.h\)".*#\1# | |
17003 | s#^/[^/]#//&# | |
17004 | p | |
17005 | q | |
17006 | }'`'"' | |
17007 | else | |
17008 | gl_cv_next_sys_stat_h='<'sys/stat.h'>' | |
17009 | fi | |
17010 | ||
17011 | ||
17012 | fi | |
17013 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5 | |
17014 | $as_echo "$gl_cv_next_sys_stat_h" >&6; } | |
17015 | fi | |
17016 | NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h | |
17017 | ||
17018 | if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then | |
17019 | # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' | |
17020 | gl_next_as_first_directive='<'sys/stat.h'>' | |
17021 | else | |
17022 | # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' | |
17023 | gl_next_as_first_directive=$gl_cv_next_sys_stat_h | |
17024 | fi | |
17025 | NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive | |
17026 | ||
17027 | ||
17028 | ||
17029 | ||
17030 | ||
17031 | ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h> | |
17032 | #include <sys/stat.h> | |
17033 | " | |
17034 | if test "x$ac_cv_type_nlink_t" = xyes; then : | |
17035 | ||
17036 | else | |
17037 | ||
17038 | $as_echo "#define nlink_t int" >>confdefs.h | |
17039 | ||
17040 | fi | |
17041 | ||
17042 | ||
17043 | ||
17044 | ||
17045 | ||
1fd182f0 | 17046 | # Code from module time: |
067d23c9 KY |
17047 | |
17048 | ||
067d23c9 | 17049 | |
1fd182f0 | 17050 | # Code from module time_r: |
067d23c9 | 17051 | |
067d23c9 | 17052 | |
067d23c9 KY |
17053 | |
17054 | ||
17055 | ||
067d23c9 | 17056 | |
067d23c9 | 17057 | |
1fd182f0 PE |
17058 | if test $ac_cv_have_decl_localtime_r = no; then |
17059 | HAVE_DECL_LOCALTIME_R=0 | |
17060 | fi | |
067d23c9 KY |
17061 | |
17062 | ||
1fd182f0 PE |
17063 | if test $ac_cv_func_localtime_r = yes; then |
17064 | HAVE_LOCALTIME_R=1 | |
17065 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5 | |
17066 | $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; } | |
d6974efa | 17067 | if ${gl_cv_time_r_posix+:} false; then : |
067d23c9 KY |
17068 | $as_echo_n "(cached) " >&6 |
17069 | else | |
1fd182f0 | 17070 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
067d23c9 | 17071 | /* end confdefs.h. */ |
1fd182f0 | 17072 | #include <time.h> |
067d23c9 KY |
17073 | int |
17074 | main () | |
17075 | { | |
1fd182f0 PE |
17076 | /* We don't need to append 'restrict's to the argument types, |
17077 | even though the POSIX signature has the 'restrict's, | |
17078 | since C99 says they can't affect type compatibility. */ | |
17079 | struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r; | |
17080 | if (ptr) return 0; | |
17081 | /* Check the return type is a pointer. | |
17082 | On HP-UX 10 it is 'int'. */ | |
17083 | *localtime_r (0, 0); | |
067d23c9 KY |
17084 | ; |
17085 | return 0; | |
17086 | } | |
1fd182f0 | 17087 | |
067d23c9 KY |
17088 | _ACEOF |
17089 | if ac_fn_c_try_compile "$LINENO"; then : | |
1fd182f0 | 17090 | gl_cv_time_r_posix=yes |
067d23c9 | 17091 | else |
1fd182f0 | 17092 | gl_cv_time_r_posix=no |
067d23c9 KY |
17093 | fi |
17094 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
17095 | ||
17096 | fi | |
1fd182f0 PE |
17097 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5 |
17098 | $as_echo "$gl_cv_time_r_posix" >&6; } | |
17099 | if test $gl_cv_time_r_posix = yes; then | |
17100 | REPLACE_LOCALTIME_R=0 | |
17101 | else | |
17102 | REPLACE_LOCALTIME_R=1 | |
17103 | fi | |
17104 | else | |
17105 | HAVE_LOCALTIME_R=0 | |
17106 | fi | |
17107 | if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then | |
067d23c9 | 17108 | |
067d23c9 KY |
17109 | |
17110 | ||
743c80a7 | 17111 | |
a451f14b PE |
17112 | |
17113 | ||
17114 | ||
a451f14b | 17115 | |
1fd182f0 | 17116 | gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext" |
a451f14b | 17117 | |
a451f14b | 17118 | |
1fd182f0 | 17119 | : |
a451f14b PE |
17120 | |
17121 | fi | |
17122 | ||
17123 | ||
743c80a7 PE |
17124 | |
17125 | ||
1fd182f0 | 17126 | GNULIB_TIME_R=1 |
743c80a7 PE |
17127 | |
17128 | ||
17129 | ||
b06b1098 | 17130 | # Code from module unistd: |
a451f14b PE |
17131 | |
17132 | ||
17133 | ||
e275c824 PE |
17134 | |
17135 | ||
17136 | ||
17137 | ||
17138 | ||
17139 | ||
17140 | ||
17141 | ||
17142 | ||
17143 | ||
17144 | if test $gl_cv_have_include_next = yes; then | |
17145 | gl_cv_next_unistd_h='<'unistd.h'>' | |
17146 | else | |
17147 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5 | |
17148 | $as_echo_n "checking absolute name of <unistd.h>... " >&6; } | |
d6974efa | 17149 | if ${gl_cv_next_unistd_h+:} false; then : |
e275c824 PE |
17150 | $as_echo_n "(cached) " >&6 |
17151 | else | |
17152 | ||
b06b1098 PE |
17153 | if test $ac_cv_header_unistd_h = yes; then |
17154 | ||
17155 | ||
17156 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
e275c824 PE |
17157 | /* end confdefs.h. */ |
17158 | #include <unistd.h> | |
17159 | ||
17160 | _ACEOF | |
b06b1098 PE |
17161 | case "$host_os" in |
17162 | aix*) gl_absname_cpp="$ac_cpp -C" ;; | |
17163 | *) gl_absname_cpp="$ac_cpp" ;; | |
17164 | esac | |
17165 | gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | | |
17166 | sed -n '\#/unistd.h#{ | |
17167 | s#.*"\(.*/unistd.h\)".*#\1# | |
17168 | s#^/[^/]#//&# | |
17169 | p | |
17170 | q | |
17171 | }'`'"' | |
e275c824 | 17172 | else |
b06b1098 PE |
17173 | gl_cv_next_unistd_h='<'unistd.h'>' |
17174 | fi | |
17175 | ||
e275c824 PE |
17176 | |
17177 | fi | |
17178 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5 | |
17179 | $as_echo "$gl_cv_next_unistd_h" >&6; } | |
17180 | fi | |
17181 | NEXT_UNISTD_H=$gl_cv_next_unistd_h | |
17182 | ||
17183 | if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then | |
17184 | # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' | |
17185 | gl_next_as_first_directive='<'unistd.h'>' | |
17186 | else | |
17187 | # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' | |
17188 | gl_next_as_first_directive=$gl_cv_next_unistd_h | |
17189 | fi | |
17190 | NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive | |
17191 | ||
17192 | ||
17193 | ||
17194 | ||
e275c824 PE |
17195 | if test $ac_cv_header_unistd_h = yes; then |
17196 | HAVE_UNISTD_H=1 | |
17197 | else | |
17198 | HAVE_UNISTD_H=0 | |
17199 | fi | |
17200 | ||
17201 | ||
17202 | ||
e275c824 | 17203 | |
1fd182f0 PE |
17204 | # Code from module warn-on-use: |
17205 | # End of code from modules | |
a451f14b | 17206 | |
a451f14b | 17207 | |
743c80a7 PE |
17208 | |
17209 | ||
17210 | ||
17211 | ||
17212 | ||
17213 | ||
17214 | ||
17215 | gltests_libdeps= | |
17216 | gltests_ltlibdeps= | |
17217 | ||
17218 | ||
17219 | ||
17220 | ||
17221 | ||
a451f14b PE |
17222 | |
17223 | ||
17224 | ||
17225 | ||
743c80a7 PE |
17226 | gl_source_base='tests' |
17227 | gltests_WITNESS=IN_`echo "${PACKAGE-$PACKAGE_TARNAME}" | LC_ALL=C tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ | LC_ALL=C sed -e 's/[^A-Z0-9_]/_/g'`_GNULIB_TESTS | |
17228 | ||
17229 | gl_module_indicator_condition=$gltests_WITNESS | |
17230 | ||
17231 | ||
17232 | ||
17233 | ||
17234 | ||
17235 | ||
17236 | ||
17237 | ||
17238 | ||
17239 | LIBGNU_LIBDEPS="$gl_libdeps" | |
17240 | ||
17241 | LIBGNU_LTLIBDEPS="$gl_ltlibdeps" | |
17242 | ||
17243 | ||
17244 | ||
067d23c9 KY |
17245 | # UNIX98 PTYs. |
17246 | for ac_func in grantpt | |
17247 | do : | |
17248 | ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt" | |
d6974efa | 17249 | if test "x$ac_cv_func_grantpt" = xyes; then : |
067d23c9 KY |
17250 | cat >>confdefs.h <<_ACEOF |
17251 | #define HAVE_GRANTPT 1 | |
17252 | _ACEOF | |
17253 | ||
17254 | fi | |
17255 | done | |
17256 | ||
17257 | ||
17258 | # PTY-related GNU extensions. | |
17259 | for ac_func in getpt | |
17260 | do : | |
17261 | ac_fn_c_check_func "$LINENO" "getpt" "ac_cv_func_getpt" | |
d6974efa | 17262 | if test "x$ac_cv_func_getpt" = xyes; then : |
067d23c9 KY |
17263 | cat >>confdefs.h <<_ACEOF |
17264 | #define HAVE_GETPT 1 | |
17265 | _ACEOF | |
17266 | ||
17267 | fi | |
17268 | done | |
17269 | ||
17270 | ||
17271 | # Check this now, so that we will NOT find the above functions in ncurses. | |
17272 | # That is because we have not set up to link ncurses in lib-src. | |
17273 | # It's better to believe a function is not available | |
17274 | # than to expect to find it in ncurses. | |
17275 | # Also we need tputs and friends to be able to build at all. | |
17276 | have_tputs_et_al=true | |
17277 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5 | |
17278 | $as_echo_n "checking for library containing tputs... " >&6; } | |
d6974efa | 17279 | if ${ac_cv_search_tputs+:} false; then : |
067d23c9 KY |
17280 | $as_echo_n "(cached) " >&6 |
17281 | else | |
17282 | ac_func_search_save_LIBS=$LIBS | |
17283 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17284 | /* end confdefs.h. */ | |
17285 | ||
17286 | /* Override any GCC internal prototype to avoid an error. | |
17287 | Use char because int might match the return type of a GCC | |
17288 | builtin and then its argument prototype would still apply. */ | |
17289 | #ifdef __cplusplus | |
17290 | extern "C" | |
17291 | #endif | |
17292 | char tputs (); | |
17293 | int | |
17294 | main () | |
17295 | { | |
17296 | return tputs (); | |
17297 | ; | |
17298 | return 0; | |
17299 | } | |
17300 | _ACEOF | |
17301 | for ac_lib in '' ncurses terminfo termcap; do | |
17302 | if test -z "$ac_lib"; then | |
17303 | ac_res="none required" | |
17304 | else | |
17305 | ac_res=-l$ac_lib | |
17306 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" | |
17307 | fi | |
17308 | if ac_fn_c_try_link "$LINENO"; then : | |
17309 | ac_cv_search_tputs=$ac_res | |
17310 | fi | |
17311 | rm -f core conftest.err conftest.$ac_objext \ | |
17312 | conftest$ac_exeext | |
d6974efa | 17313 | if ${ac_cv_search_tputs+:} false; then : |
067d23c9 KY |
17314 | break |
17315 | fi | |
17316 | done | |
d6974efa | 17317 | if ${ac_cv_search_tputs+:} false; then : |
067d23c9 KY |
17318 | |
17319 | else | |
17320 | ac_cv_search_tputs=no | |
17321 | fi | |
17322 | rm conftest.$ac_ext | |
17323 | LIBS=$ac_func_search_save_LIBS | |
17324 | fi | |
17325 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_tputs" >&5 | |
17326 | $as_echo "$ac_cv_search_tputs" >&6; } | |
17327 | ac_res=$ac_cv_search_tputs | |
17328 | if test "$ac_res" != no; then : | |
17329 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" | |
17330 | ||
17331 | else | |
17332 | have_tputs_et_al=false | |
17333 | fi | |
17334 | ||
17335 | if test "$have_tputs_et_al" != true; then | |
2018939f | 17336 | as_fn_error $? "I couldn't find termcap functions (tputs and friends). |
067d23c9 KY |
17337 | Maybe some development libraries/packages are missing? Try installing |
17338 | libncurses-dev(el), libterminfo-dev(el) or similar." "$LINENO" 5 | |
17339 | fi | |
17340 | # Must define this when any termcap library is found. | |
17341 | ||
17342 | $as_echo "#define HAVE_LIBNCURSES 1" >>confdefs.h | |
17343 | ||
17344 | ## FIXME This was the cpp logic, but I am not sure it is right. | |
17345 | ## The above test has not necessarily found libncurses. | |
17346 | HAVE_LIBNCURSES=yes | |
17347 | ||
17348 | ## Use terminfo instead of termcap? | |
17349 | ## Note only system files NOT using terminfo are: | |
17350 | ## freebsd < 40000, ms-w32, msdos, netbsd < 599002500, and | |
17351 | ## darwin|gnu without ncurses. | |
17352 | TERMINFO=no | |
17353 | LIBS_TERMCAP= | |
17354 | case "$opsys" in | |
17355 | ## cygwin: Fewer environment variables to go wrong, more terminal types. | |
17356 | ## hpux10-20: Use the system provided termcap(3) library. | |
17357 | ## openbsd: David Mazieres <dm@reeducation-labor.lcs.mit.edu> says this | |
17358 | ## is necessary. Otherwise Emacs dumps core when run -nw. | |
17359 | aix4-2|cygwin|hpux*|irix6-5|openbsd|sol2*|unixware) TERMINFO=yes ;; | |
17360 | ||
17361 | ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2. | |
17362 | ## The ncurses library has been moved out of the System framework in | |
17363 | ## Mac OS X 10.2. So if configure detects it, set the command-line | |
17364 | ## option to use it. | |
17365 | darwin|gnu*) | |
17366 | ## (HAVE_LIBNCURSES was not always true, but is since 2010-03-18.) | |
17367 | if test "x$HAVE_LIBNCURSES" = "xyes"; then | |
17368 | TERMINFO=yes | |
17369 | LIBS_TERMCAP="-lncurses" | |
17370 | fi | |
17371 | ;; | |
17372 | ||
17373 | freebsd) | |
17374 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5 | |
17375 | $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; } | |
d6974efa | 17376 | if ${emacs_cv_freebsd_terminfo+:} false; then : |
067d23c9 KY |
17377 | $as_echo_n "(cached) " >&6 |
17378 | else | |
17379 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17380 | /* end confdefs.h. */ | |
17381 | #include <osreldate.h> | |
17382 | int | |
17383 | main () | |
17384 | { | |
17385 | #if __FreeBSD_version < 400000 | |
17386 | fail; | |
17387 | #endif | |
17388 | ||
17389 | ; | |
17390 | return 0; | |
17391 | } | |
17392 | _ACEOF | |
17393 | if ac_fn_c_try_link "$LINENO"; then : | |
17394 | emacs_cv_freebsd_terminfo=yes | |
17395 | else | |
17396 | emacs_cv_freebsd_terminfo=no | |
17397 | fi | |
17398 | rm -f core conftest.err conftest.$ac_objext \ | |
17399 | conftest$ac_exeext conftest.$ac_ext | |
17400 | fi | |
17401 | ||
17402 | ||
17403 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5 | |
17404 | $as_echo "$emacs_cv_freebsd_terminfo" >&6; } | |
17405 | ||
17406 | if test $emacs_cv_freebsd_terminfo = yes; then | |
17407 | TERMINFO=yes | |
17408 | LIBS_TERMCAP="-lncurses" | |
17409 | else | |
17410 | LIBS_TERMCAP="-ltermcap" | |
17411 | fi | |
17412 | ;; | |
17413 | ||
17414 | netbsd) | |
17415 | if test $ac_cv_search_tputs = -lterminfo; then | |
17416 | TERMINFO=yes | |
17417 | LIBS_TERMCAP="-lterminfo" | |
17418 | else | |
17419 | LIBS_TERMCAP="-ltermcap" | |
17420 | fi | |
17421 | ;; | |
17422 | ||
17423 | esac | |
17424 | ||
17425 | case "$opsys" in | |
17426 | ## hpux: Make sure we get select from libc rather than from libcurses | |
17427 | ## because libcurses on HPUX 10.10 has a broken version of select. | |
17428 | ## We used to use -lc -lcurses, but this may be cleaner. | |
17429 | hpux*) LIBS_TERMCAP="-ltermcap" ;; | |
17430 | ||
17431 | openbsd) LIBS_TERMCAP="-lncurses" ;; | |
17432 | ||
17433 | ## Must use system termcap, if we use any termcap. It does special things. | |
17434 | sol2*) test "$TERMINFO" != yes && LIBS_TERMCAP="-ltermcap" ;; | |
17435 | esac | |
17436 | ||
17437 | TERMCAP_OBJ=tparam.o | |
17438 | if test $TERMINFO = yes; then | |
17439 | ||
17440 | $as_echo "#define TERMINFO 1" >>confdefs.h | |
17441 | ||
17442 | ||
17443 | ## Default used to be -ltermcap. Add a case above if need something else. | |
17444 | test "x$LIBS_TERMCAP" = "x" && LIBS_TERMCAP="-lcurses" | |
17445 | ||
17446 | TERMCAP_OBJ=terminfo.o | |
17447 | fi | |
17448 | ||
17449 | ||
17450 | ||
17451 | ||
17452 | # Do we have res_init, for detecting changes in /etc/resolv.conf? | |
17453 | resolv=no | |
17454 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17455 | /* end confdefs.h. */ | |
17456 | #include <netinet/in.h> | |
17457 | #include <arpa/nameser.h> | |
17458 | #include <resolv.h> | |
17459 | int | |
17460 | main () | |
17461 | { | |
17462 | return res_init(); | |
17463 | ; | |
17464 | return 0; | |
17465 | } | |
17466 | _ACEOF | |
17467 | if ac_fn_c_try_link "$LINENO"; then : | |
17468 | have_res_init=yes | |
17469 | else | |
17470 | have_res_init=no | |
17471 | fi | |
17472 | rm -f core conftest.err conftest.$ac_objext \ | |
17473 | conftest$ac_exeext conftest.$ac_ext | |
17474 | if test "$have_res_init" = no; then | |
17475 | OLIBS="$LIBS" | |
17476 | LIBS="$LIBS -lresolv" | |
17477 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5 | |
17478 | $as_echo_n "checking for res_init with -lresolv... " >&6; } | |
17479 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17480 | /* end confdefs.h. */ | |
17481 | #include <netinet/in.h> | |
17482 | #include <arpa/nameser.h> | |
17483 | #include <resolv.h> | |
17484 | int | |
17485 | main () | |
17486 | { | |
17487 | return res_init(); | |
17488 | ; | |
17489 | return 0; | |
17490 | } | |
17491 | _ACEOF | |
17492 | if ac_fn_c_try_link "$LINENO"; then : | |
17493 | have_res_init=yes | |
17494 | else | |
17495 | have_res_init=no | |
17496 | fi | |
17497 | rm -f core conftest.err conftest.$ac_objext \ | |
17498 | conftest$ac_exeext conftest.$ac_ext | |
17499 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5 | |
17500 | $as_echo "$have_res_init" >&6; } | |
17501 | if test "$have_res_init" = yes ; then | |
17502 | resolv=yes | |
17503 | fi | |
17504 | LIBS="$OLIBS" | |
17505 | fi | |
17506 | ||
17507 | if test "$have_res_init" = yes; then | |
17508 | ||
17509 | $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h | |
17510 | ||
17511 | fi | |
17512 | ||
17513 | # Do we need the Hesiod library to provide the support routines? | |
17514 | LIBHESIOD= | |
17515 | if test "$with_hesiod" != no ; then | |
17516 | # Don't set $LIBS here -- see comments above. FIXME which comments? | |
17517 | ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send" | |
d6974efa | 17518 | if test "x$ac_cv_func_res_send" = xyes; then : |
067d23c9 KY |
17519 | |
17520 | else | |
17521 | ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send" | |
d6974efa | 17522 | if test "x$ac_cv_func___res_send" = xyes; then : |
067d23c9 KY |
17523 | |
17524 | else | |
17525 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5 | |
17526 | $as_echo_n "checking for res_send in -lresolv... " >&6; } | |
d6974efa | 17527 | if ${ac_cv_lib_resolv_res_send+:} false; then : |
067d23c9 KY |
17528 | $as_echo_n "(cached) " >&6 |
17529 | else | |
17530 | ac_check_lib_save_LIBS=$LIBS | |
17531 | LIBS="-lresolv $LIBS" | |
17532 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17533 | /* end confdefs.h. */ | |
17534 | ||
17535 | /* Override any GCC internal prototype to avoid an error. | |
17536 | Use char because int might match the return type of a GCC | |
17537 | builtin and then its argument prototype would still apply. */ | |
17538 | #ifdef __cplusplus | |
17539 | extern "C" | |
17540 | #endif | |
17541 | char res_send (); | |
17542 | int | |
17543 | main () | |
17544 | { | |
17545 | return res_send (); | |
17546 | ; | |
17547 | return 0; | |
17548 | } | |
17549 | _ACEOF | |
17550 | if ac_fn_c_try_link "$LINENO"; then : | |
17551 | ac_cv_lib_resolv_res_send=yes | |
17552 | else | |
17553 | ac_cv_lib_resolv_res_send=no | |
17554 | fi | |
17555 | rm -f core conftest.err conftest.$ac_objext \ | |
17556 | conftest$ac_exeext conftest.$ac_ext | |
17557 | LIBS=$ac_check_lib_save_LIBS | |
17558 | fi | |
17559 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5 | |
17560 | $as_echo "$ac_cv_lib_resolv_res_send" >&6; } | |
d6974efa | 17561 | if test "x$ac_cv_lib_resolv_res_send" = xyes; then : |
067d23c9 KY |
17562 | resolv=yes |
17563 | else | |
17564 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5 | |
17565 | $as_echo_n "checking for __res_send in -lresolv... " >&6; } | |
d6974efa | 17566 | if ${ac_cv_lib_resolv___res_send+:} false; then : |
067d23c9 KY |
17567 | $as_echo_n "(cached) " >&6 |
17568 | else | |
17569 | ac_check_lib_save_LIBS=$LIBS | |
17570 | LIBS="-lresolv $LIBS" | |
17571 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17572 | /* end confdefs.h. */ | |
17573 | ||
17574 | /* Override any GCC internal prototype to avoid an error. | |
17575 | Use char because int might match the return type of a GCC | |
17576 | builtin and then its argument prototype would still apply. */ | |
17577 | #ifdef __cplusplus | |
17578 | extern "C" | |
17579 | #endif | |
17580 | char __res_send (); | |
17581 | int | |
17582 | main () | |
17583 | { | |
17584 | return __res_send (); | |
17585 | ; | |
17586 | return 0; | |
17587 | } | |
17588 | _ACEOF | |
17589 | if ac_fn_c_try_link "$LINENO"; then : | |
17590 | ac_cv_lib_resolv___res_send=yes | |
17591 | else | |
17592 | ac_cv_lib_resolv___res_send=no | |
17593 | fi | |
17594 | rm -f core conftest.err conftest.$ac_objext \ | |
17595 | conftest$ac_exeext conftest.$ac_ext | |
17596 | LIBS=$ac_check_lib_save_LIBS | |
17597 | fi | |
17598 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5 | |
17599 | $as_echo "$ac_cv_lib_resolv___res_send" >&6; } | |
d6974efa | 17600 | if test "x$ac_cv_lib_resolv___res_send" = xyes; then : |
067d23c9 KY |
17601 | resolv=yes |
17602 | fi | |
17603 | ||
17604 | fi | |
17605 | ||
17606 | fi | |
17607 | ||
17608 | fi | |
17609 | ||
17610 | if test "$resolv" = yes ; then | |
17611 | RESOLVLIB=-lresolv | |
17612 | else | |
17613 | RESOLVLIB= | |
17614 | fi | |
17615 | ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost" | |
d6974efa | 17616 | if test "x$ac_cv_func_hes_getmailhost" = xyes; then : |
067d23c9 KY |
17617 | |
17618 | else | |
17619 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5 | |
17620 | $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; } | |
d6974efa | 17621 | if ${ac_cv_lib_hesiod_hes_getmailhost+:} false; then : |
067d23c9 KY |
17622 | $as_echo_n "(cached) " >&6 |
17623 | else | |
17624 | ac_check_lib_save_LIBS=$LIBS | |
17625 | LIBS="-lhesiod $RESOLVLIB $LIBS" | |
17626 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17627 | /* end confdefs.h. */ | |
17628 | ||
17629 | /* Override any GCC internal prototype to avoid an error. | |
17630 | Use char because int might match the return type of a GCC | |
17631 | builtin and then its argument prototype would still apply. */ | |
17632 | #ifdef __cplusplus | |
17633 | extern "C" | |
17634 | #endif | |
17635 | char hes_getmailhost (); | |
17636 | int | |
17637 | main () | |
17638 | { | |
17639 | return hes_getmailhost (); | |
17640 | ; | |
17641 | return 0; | |
17642 | } | |
17643 | _ACEOF | |
17644 | if ac_fn_c_try_link "$LINENO"; then : | |
17645 | ac_cv_lib_hesiod_hes_getmailhost=yes | |
17646 | else | |
17647 | ac_cv_lib_hesiod_hes_getmailhost=no | |
17648 | fi | |
17649 | rm -f core conftest.err conftest.$ac_objext \ | |
17650 | conftest$ac_exeext conftest.$ac_ext | |
17651 | LIBS=$ac_check_lib_save_LIBS | |
17652 | fi | |
17653 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5 | |
17654 | $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; } | |
d6974efa | 17655 | if test "x$ac_cv_lib_hesiod_hes_getmailhost" = xyes; then : |
067d23c9 KY |
17656 | hesiod=yes |
17657 | else | |
17658 | : | |
17659 | fi | |
17660 | ||
17661 | fi | |
17662 | ||
17663 | ||
17664 | if test x"$hesiod" = xyes; then | |
17665 | ||
17666 | $as_echo "#define HAVE_LIBHESIOD 1" >>confdefs.h | |
17667 | ||
17668 | LIBHESIOD=-lhesiod | |
17669 | fi | |
17670 | fi | |
17671 | ||
17672 | ||
17673 | # Do we need libresolv (due to res_init or Hesiod)? | |
17674 | if test "$resolv" = yes ; then | |
17675 | ||
17676 | $as_echo "#define HAVE_LIBRESOLV 1" >>confdefs.h | |
17677 | ||
17678 | LIBRESOLV=-lresolv | |
17679 | else | |
17680 | LIBRESOLV= | |
17681 | fi | |
17682 | ||
17683 | ||
17684 | # These tell us which Kerberos-related libraries to use. | |
17685 | COM_ERRLIB= | |
17686 | CRYPTOLIB= | |
17687 | KRB5LIB= | |
17688 | DESLIB= | |
17689 | KRB4LIB= | |
17690 | ||
17691 | if test "${with_kerberos}" != no; then | |
17692 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5 | |
17693 | $as_echo_n "checking for com_err in -lcom_err... " >&6; } | |
d6974efa | 17694 | if ${ac_cv_lib_com_err_com_err+:} false; then : |
067d23c9 KY |
17695 | $as_echo_n "(cached) " >&6 |
17696 | else | |
17697 | ac_check_lib_save_LIBS=$LIBS | |
17698 | LIBS="-lcom_err $LIBS" | |
17699 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17700 | /* end confdefs.h. */ | |
17701 | ||
17702 | /* Override any GCC internal prototype to avoid an error. | |
17703 | Use char because int might match the return type of a GCC | |
17704 | builtin and then its argument prototype would still apply. */ | |
17705 | #ifdef __cplusplus | |
17706 | extern "C" | |
17707 | #endif | |
17708 | char com_err (); | |
17709 | int | |
17710 | main () | |
17711 | { | |
17712 | return com_err (); | |
17713 | ; | |
17714 | return 0; | |
17715 | } | |
17716 | _ACEOF | |
17717 | if ac_fn_c_try_link "$LINENO"; then : | |
17718 | ac_cv_lib_com_err_com_err=yes | |
17719 | else | |
17720 | ac_cv_lib_com_err_com_err=no | |
17721 | fi | |
17722 | rm -f core conftest.err conftest.$ac_objext \ | |
17723 | conftest$ac_exeext conftest.$ac_ext | |
17724 | LIBS=$ac_check_lib_save_LIBS | |
17725 | fi | |
17726 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5 | |
17727 | $as_echo "$ac_cv_lib_com_err_com_err" >&6; } | |
d6974efa | 17728 | if test "x$ac_cv_lib_com_err_com_err" = xyes; then : |
067d23c9 KY |
17729 | have_com_err=yes |
17730 | else | |
17731 | have_com_err=no | |
17732 | fi | |
17733 | ||
17734 | if test $have_com_err = yes; then | |
17735 | COM_ERRLIB=-lcom_err | |
17736 | LIBS="$COM_ERRLIB $LIBS" | |
17737 | ||
17738 | $as_echo "#define HAVE_LIBCOM_ERR 1" >>confdefs.h | |
17739 | ||
17740 | fi | |
17741 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5 | |
17742 | $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; } | |
d6974efa | 17743 | if ${ac_cv_lib_crypto_mit_des_cbc_encrypt+:} false; then : |
067d23c9 KY |
17744 | $as_echo_n "(cached) " >&6 |
17745 | else | |
17746 | ac_check_lib_save_LIBS=$LIBS | |
17747 | LIBS="-lcrypto $LIBS" | |
17748 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17749 | /* end confdefs.h. */ | |
17750 | ||
17751 | /* Override any GCC internal prototype to avoid an error. | |
17752 | Use char because int might match the return type of a GCC | |
17753 | builtin and then its argument prototype would still apply. */ | |
17754 | #ifdef __cplusplus | |
17755 | extern "C" | |
17756 | #endif | |
17757 | char mit_des_cbc_encrypt (); | |
17758 | int | |
17759 | main () | |
17760 | { | |
17761 | return mit_des_cbc_encrypt (); | |
17762 | ; | |
17763 | return 0; | |
17764 | } | |
17765 | _ACEOF | |
17766 | if ac_fn_c_try_link "$LINENO"; then : | |
17767 | ac_cv_lib_crypto_mit_des_cbc_encrypt=yes | |
17768 | else | |
17769 | ac_cv_lib_crypto_mit_des_cbc_encrypt=no | |
17770 | fi | |
17771 | rm -f core conftest.err conftest.$ac_objext \ | |
17772 | conftest$ac_exeext conftest.$ac_ext | |
17773 | LIBS=$ac_check_lib_save_LIBS | |
17774 | fi | |
17775 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5 | |
17776 | $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; } | |
d6974efa | 17777 | if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = xyes; then : |
067d23c9 KY |
17778 | have_crypto=yes |
17779 | else | |
17780 | have_crypto=no | |
17781 | fi | |
17782 | ||
17783 | if test $have_crypto = yes; then | |
17784 | CRYPTOLIB=-lcrypto | |
17785 | LIBS="$CRYPTOLIB $LIBS" | |
17786 | ||
17787 | $as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h | |
17788 | ||
17789 | fi | |
17790 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5 | |
17791 | $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; } | |
d6974efa | 17792 | if ${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+:} false; then : |
067d23c9 KY |
17793 | $as_echo_n "(cached) " >&6 |
17794 | else | |
17795 | ac_check_lib_save_LIBS=$LIBS | |
17796 | LIBS="-lk5crypto $LIBS" | |
17797 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17798 | /* end confdefs.h. */ | |
17799 | ||
17800 | /* Override any GCC internal prototype to avoid an error. | |
17801 | Use char because int might match the return type of a GCC | |
17802 | builtin and then its argument prototype would still apply. */ | |
17803 | #ifdef __cplusplus | |
17804 | extern "C" | |
17805 | #endif | |
17806 | char mit_des_cbc_encrypt (); | |
17807 | int | |
17808 | main () | |
17809 | { | |
17810 | return mit_des_cbc_encrypt (); | |
17811 | ; | |
17812 | return 0; | |
17813 | } | |
17814 | _ACEOF | |
17815 | if ac_fn_c_try_link "$LINENO"; then : | |
17816 | ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes | |
17817 | else | |
17818 | ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no | |
17819 | fi | |
17820 | rm -f core conftest.err conftest.$ac_objext \ | |
17821 | conftest$ac_exeext conftest.$ac_ext | |
17822 | LIBS=$ac_check_lib_save_LIBS | |
17823 | fi | |
17824 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5 | |
17825 | $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; } | |
d6974efa | 17826 | if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = xyes; then : |
067d23c9 KY |
17827 | have_k5crypto=yes |
17828 | else | |
17829 | have_k5crypto=no | |
17830 | fi | |
17831 | ||
17832 | if test $have_k5crypto = yes; then | |
17833 | CRYPTOLIB=-lk5crypto | |
17834 | LIBS="$CRYPTOLIB $LIBS" | |
17835 | ||
17836 | $as_echo "#define HAVE_LIBK5CRYPTO 1" >>confdefs.h | |
17837 | ||
17838 | fi | |
17839 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5 | |
17840 | $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; } | |
d6974efa | 17841 | if ${ac_cv_lib_krb5_krb5_init_context+:} false; then : |
067d23c9 KY |
17842 | $as_echo_n "(cached) " >&6 |
17843 | else | |
17844 | ac_check_lib_save_LIBS=$LIBS | |
17845 | LIBS="-lkrb5 $LIBS" | |
17846 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17847 | /* end confdefs.h. */ | |
17848 | ||
17849 | /* Override any GCC internal prototype to avoid an error. | |
17850 | Use char because int might match the return type of a GCC | |
17851 | builtin and then its argument prototype would still apply. */ | |
17852 | #ifdef __cplusplus | |
17853 | extern "C" | |
17854 | #endif | |
17855 | char krb5_init_context (); | |
17856 | int | |
17857 | main () | |
17858 | { | |
17859 | return krb5_init_context (); | |
17860 | ; | |
17861 | return 0; | |
17862 | } | |
17863 | _ACEOF | |
17864 | if ac_fn_c_try_link "$LINENO"; then : | |
17865 | ac_cv_lib_krb5_krb5_init_context=yes | |
17866 | else | |
17867 | ac_cv_lib_krb5_krb5_init_context=no | |
17868 | fi | |
17869 | rm -f core conftest.err conftest.$ac_objext \ | |
17870 | conftest$ac_exeext conftest.$ac_ext | |
17871 | LIBS=$ac_check_lib_save_LIBS | |
17872 | fi | |
17873 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5 | |
17874 | $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; } | |
d6974efa | 17875 | if test "x$ac_cv_lib_krb5_krb5_init_context" = xyes; then : |
067d23c9 KY |
17876 | have_krb5=yes |
17877 | else | |
17878 | have_krb5=no | |
17879 | fi | |
17880 | ||
17881 | if test $have_krb5=yes; then | |
17882 | KRB5LIB=-lkrb5 | |
17883 | LIBS="$KRB5LIB $LIBS" | |
17884 | ||
17885 | $as_echo "#define HAVE_LIBKRB5 1" >>confdefs.h | |
17886 | ||
17887 | fi | |
17888 | if test "${with_kerberos5}" = no; then | |
17889 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5 | |
17890 | $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; } | |
d6974efa | 17891 | if ${ac_cv_lib_des425_des_cbc_encrypt+:} false; then : |
067d23c9 KY |
17892 | $as_echo_n "(cached) " >&6 |
17893 | else | |
17894 | ac_check_lib_save_LIBS=$LIBS | |
17895 | LIBS="-ldes425 $LIBS" | |
17896 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17897 | /* end confdefs.h. */ | |
17898 | ||
17899 | /* Override any GCC internal prototype to avoid an error. | |
17900 | Use char because int might match the return type of a GCC | |
17901 | builtin and then its argument prototype would still apply. */ | |
17902 | #ifdef __cplusplus | |
17903 | extern "C" | |
17904 | #endif | |
17905 | char des_cbc_encrypt (); | |
17906 | int | |
17907 | main () | |
17908 | { | |
17909 | return des_cbc_encrypt (); | |
17910 | ; | |
17911 | return 0; | |
17912 | } | |
17913 | _ACEOF | |
17914 | if ac_fn_c_try_link "$LINENO"; then : | |
17915 | ac_cv_lib_des425_des_cbc_encrypt=yes | |
17916 | else | |
17917 | ac_cv_lib_des425_des_cbc_encrypt=no | |
17918 | fi | |
17919 | rm -f core conftest.err conftest.$ac_objext \ | |
17920 | conftest$ac_exeext conftest.$ac_ext | |
17921 | LIBS=$ac_check_lib_save_LIBS | |
17922 | fi | |
17923 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5 | |
17924 | $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; } | |
d6974efa | 17925 | if test "x$ac_cv_lib_des425_des_cbc_encrypt" = xyes; then : |
067d23c9 KY |
17926 | have_des425=yes |
17927 | else | |
17928 | have_des425=no | |
17929 | fi | |
17930 | ||
17931 | if test $have_des425 = yes; then | |
17932 | DESLIB=-ldes425 | |
17933 | LIBS="$DESLIB $LIBS" | |
17934 | ||
17935 | $as_echo "#define HAVE_LIBDES425 1" >>confdefs.h | |
17936 | ||
17937 | else | |
17938 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5 | |
17939 | $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; } | |
d6974efa | 17940 | if ${ac_cv_lib_des_des_cbc_encrypt+:} false; then : |
067d23c9 KY |
17941 | $as_echo_n "(cached) " >&6 |
17942 | else | |
17943 | ac_check_lib_save_LIBS=$LIBS | |
17944 | LIBS="-ldes $LIBS" | |
17945 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17946 | /* end confdefs.h. */ | |
17947 | ||
17948 | /* Override any GCC internal prototype to avoid an error. | |
17949 | Use char because int might match the return type of a GCC | |
17950 | builtin and then its argument prototype would still apply. */ | |
17951 | #ifdef __cplusplus | |
17952 | extern "C" | |
17953 | #endif | |
17954 | char des_cbc_encrypt (); | |
17955 | int | |
17956 | main () | |
17957 | { | |
17958 | return des_cbc_encrypt (); | |
17959 | ; | |
17960 | return 0; | |
17961 | } | |
17962 | _ACEOF | |
17963 | if ac_fn_c_try_link "$LINENO"; then : | |
17964 | ac_cv_lib_des_des_cbc_encrypt=yes | |
17965 | else | |
17966 | ac_cv_lib_des_des_cbc_encrypt=no | |
17967 | fi | |
17968 | rm -f core conftest.err conftest.$ac_objext \ | |
17969 | conftest$ac_exeext conftest.$ac_ext | |
17970 | LIBS=$ac_check_lib_save_LIBS | |
17971 | fi | |
17972 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5 | |
17973 | $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; } | |
d6974efa | 17974 | if test "x$ac_cv_lib_des_des_cbc_encrypt" = xyes; then : |
067d23c9 KY |
17975 | have_des=yes |
17976 | else | |
17977 | have_des=no | |
17978 | fi | |
17979 | ||
17980 | if test $have_des = yes; then | |
17981 | DESLIB=-ldes | |
17982 | LIBS="$DESLIB $LIBS" | |
17983 | ||
17984 | $as_echo "#define HAVE_LIBDES 1" >>confdefs.h | |
17985 | ||
17986 | fi | |
17987 | fi | |
17988 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5 | |
17989 | $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; } | |
d6974efa | 17990 | if ${ac_cv_lib_krb4_krb_get_cred+:} false; then : |
067d23c9 KY |
17991 | $as_echo_n "(cached) " >&6 |
17992 | else | |
17993 | ac_check_lib_save_LIBS=$LIBS | |
17994 | LIBS="-lkrb4 $LIBS" | |
17995 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17996 | /* end confdefs.h. */ | |
17997 | ||
17998 | /* Override any GCC internal prototype to avoid an error. | |
17999 | Use char because int might match the return type of a GCC | |
18000 | builtin and then its argument prototype would still apply. */ | |
18001 | #ifdef __cplusplus | |
18002 | extern "C" | |
18003 | #endif | |
18004 | char krb_get_cred (); | |
18005 | int | |
18006 | main () | |
18007 | { | |
18008 | return krb_get_cred (); | |
18009 | ; | |
18010 | return 0; | |
18011 | } | |
18012 | _ACEOF | |
18013 | if ac_fn_c_try_link "$LINENO"; then : | |
18014 | ac_cv_lib_krb4_krb_get_cred=yes | |
18015 | else | |
18016 | ac_cv_lib_krb4_krb_get_cred=no | |
18017 | fi | |
18018 | rm -f core conftest.err conftest.$ac_objext \ | |
18019 | conftest$ac_exeext conftest.$ac_ext | |
18020 | LIBS=$ac_check_lib_save_LIBS | |
18021 | fi | |
18022 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5 | |
18023 | $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; } | |
d6974efa | 18024 | if test "x$ac_cv_lib_krb4_krb_get_cred" = xyes; then : |
067d23c9 KY |
18025 | have_krb4=yes |
18026 | else | |
18027 | have_krb4=no | |
18028 | fi | |
18029 | ||
18030 | if test $have_krb4 = yes; then | |
18031 | KRB4LIB=-lkrb4 | |
18032 | LIBS="$KRB4LIB $LIBS" | |
18033 | ||
18034 | $as_echo "#define HAVE_LIBKRB4 1" >>confdefs.h | |
18035 | ||
18036 | else | |
18037 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5 | |
18038 | $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; } | |
d6974efa | 18039 | if ${ac_cv_lib_krb_krb_get_cred+:} false; then : |
067d23c9 KY |
18040 | $as_echo_n "(cached) " >&6 |
18041 | else | |
18042 | ac_check_lib_save_LIBS=$LIBS | |
18043 | LIBS="-lkrb $LIBS" | |
18044 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
18045 | /* end confdefs.h. */ | |
18046 | ||
18047 | /* Override any GCC internal prototype to avoid an error. | |
18048 | Use char because int might match the return type of a GCC | |
18049 | builtin and then its argument prototype would still apply. */ | |
18050 | #ifdef __cplusplus | |
18051 | extern "C" | |
18052 | #endif | |
18053 | char krb_get_cred (); | |
18054 | int | |
18055 | main () | |
18056 | { | |
18057 | return krb_get_cred (); | |
18058 | ; | |
18059 | return 0; | |
18060 | } | |
18061 | _ACEOF | |
18062 | if ac_fn_c_try_link "$LINENO"; then : | |
18063 | ac_cv_lib_krb_krb_get_cred=yes | |
18064 | else | |
18065 | ac_cv_lib_krb_krb_get_cred=no | |
18066 | fi | |
18067 | rm -f core conftest.err conftest.$ac_objext \ | |
18068 | conftest$ac_exeext conftest.$ac_ext | |
18069 | LIBS=$ac_check_lib_save_LIBS | |
18070 | fi | |
18071 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5 | |
18072 | $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; } | |
d6974efa | 18073 | if test "x$ac_cv_lib_krb_krb_get_cred" = xyes; then : |
067d23c9 KY |
18074 | have_krb=yes |
18075 | else | |
18076 | have_krb=no | |
18077 | fi | |
18078 | ||
18079 | if test $have_krb = yes; then | |
18080 | KRB4LIB=-lkrb | |
18081 | LIBS="$KRB4LIB $LIBS" | |
18082 | ||
18083 | $as_echo "#define HAVE_LIBKRB 1" >>confdefs.h | |
18084 | ||
18085 | fi | |
18086 | fi | |
18087 | fi | |
18088 | ||
18089 | if test "${with_kerberos5}" != no; then | |
18090 | for ac_header in krb5.h | |
18091 | do : | |
18092 | ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default" | |
d6974efa | 18093 | if test "x$ac_cv_header_krb5_h" = xyes; then : |
067d23c9 KY |
18094 | cat >>confdefs.h <<_ACEOF |
18095 | #define HAVE_KRB5_H 1 | |
18096 | _ACEOF | |
18097 | ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h> | |
18098 | " | |
d6974efa | 18099 | if test "x$ac_cv_member_krb5_error_text" = xyes; then : |
067d23c9 KY |
18100 | |
18101 | cat >>confdefs.h <<_ACEOF | |
18102 | #define HAVE_KRB5_ERROR_TEXT 1 | |
18103 | _ACEOF | |
18104 | ||
18105 | ||
18106 | fi | |
18107 | ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h> | |
18108 | " | |
d6974efa | 18109 | if test "x$ac_cv_member_krb5_error_e_text" = xyes; then : |
067d23c9 KY |
18110 | |
18111 | cat >>confdefs.h <<_ACEOF | |
18112 | #define HAVE_KRB5_ERROR_E_TEXT 1 | |
18113 | _ACEOF | |
18114 | ||
18115 | ||
18116 | fi | |
18117 | ||
18118 | fi | |
18119 | ||
18120 | done | |
18121 | ||
18122 | else | |
18123 | for ac_header in des.h | |
18124 | do : | |
18125 | ac_fn_c_check_header_mongrel "$LINENO" "des.h" "ac_cv_header_des_h" "$ac_includes_default" | |
d6974efa | 18126 | if test "x$ac_cv_header_des_h" = xyes; then : |
067d23c9 KY |
18127 | cat >>confdefs.h <<_ACEOF |
18128 | #define HAVE_DES_H 1 | |
18129 | _ACEOF | |
18130 | ||
18131 | else | |
18132 | for ac_header in kerberosIV/des.h | |
18133 | do : | |
18134 | ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/des.h" "ac_cv_header_kerberosIV_des_h" "$ac_includes_default" | |
d6974efa | 18135 | if test "x$ac_cv_header_kerberosIV_des_h" = xyes; then : |
067d23c9 KY |
18136 | cat >>confdefs.h <<_ACEOF |
18137 | #define HAVE_KERBEROSIV_DES_H 1 | |
18138 | _ACEOF | |
18139 | ||
18140 | else | |
18141 | for ac_header in kerberos/des.h | |
18142 | do : | |
18143 | ac_fn_c_check_header_mongrel "$LINENO" "kerberos/des.h" "ac_cv_header_kerberos_des_h" "$ac_includes_default" | |
d6974efa | 18144 | if test "x$ac_cv_header_kerberos_des_h" = xyes; then : |
067d23c9 KY |
18145 | cat >>confdefs.h <<_ACEOF |
18146 | #define HAVE_KERBEROS_DES_H 1 | |
18147 | _ACEOF | |
18148 | ||
18149 | fi | |
18150 | ||
18151 | done | |
18152 | ||
18153 | fi | |
18154 | ||
18155 | done | |
18156 | ||
18157 | fi | |
18158 | ||
18159 | done | |
18160 | ||
18161 | for ac_header in krb.h | |
18162 | do : | |
18163 | ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default" | |
d6974efa | 18164 | if test "x$ac_cv_header_krb_h" = xyes; then : |
067d23c9 KY |
18165 | cat >>confdefs.h <<_ACEOF |
18166 | #define HAVE_KRB_H 1 | |
18167 | _ACEOF | |
18168 | ||
18169 | else | |
18170 | for ac_header in kerberosIV/krb.h | |
18171 | do : | |
18172 | ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default" | |
d6974efa | 18173 | if test "x$ac_cv_header_kerberosIV_krb_h" = xyes; then : |
067d23c9 KY |
18174 | cat >>confdefs.h <<_ACEOF |
18175 | #define HAVE_KERBEROSIV_KRB_H 1 | |
18176 | _ACEOF | |
18177 | ||
18178 | else | |
18179 | for ac_header in kerberos/krb.h | |
18180 | do : | |
18181 | ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default" | |
d6974efa | 18182 | if test "x$ac_cv_header_kerberos_krb_h" = xyes; then : |
067d23c9 KY |
18183 | cat >>confdefs.h <<_ACEOF |
18184 | #define HAVE_KERBEROS_KRB_H 1 | |
18185 | _ACEOF | |
18186 | ||
18187 | fi | |
18188 | ||
18189 | done | |
18190 | ||
18191 | fi | |
18192 | ||
18193 | done | |
18194 | ||
18195 | fi | |
18196 | ||
18197 | done | |
18198 | ||
18199 | fi | |
18200 | for ac_header in com_err.h | |
18201 | do : | |
18202 | ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default" | |
d6974efa | 18203 | if test "x$ac_cv_header_com_err_h" = xyes; then : |
067d23c9 KY |
18204 | cat >>confdefs.h <<_ACEOF |
18205 | #define HAVE_COM_ERR_H 1 | |
18206 | _ACEOF | |
18207 | ||
18208 | fi | |
18209 | ||
18210 | done | |
18211 | ||
18212 | fi | |
18213 | ||
18214 | ||
18215 | ||
18216 | ||
18217 | ||
18218 | ||
18219 | ||
18220 | # Solaris requires -lintl if you want strerror (which calls dgettext) | |
18221 | # to return localized messages. | |
18222 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dgettext in -lintl" >&5 | |
18223 | $as_echo_n "checking for dgettext in -lintl... " >&6; } | |
d6974efa | 18224 | if ${ac_cv_lib_intl_dgettext+:} false; then : |
067d23c9 KY |
18225 | $as_echo_n "(cached) " >&6 |
18226 | else | |
18227 | ac_check_lib_save_LIBS=$LIBS | |
18228 | LIBS="-lintl $LIBS" | |
18229 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
18230 | /* end confdefs.h. */ | |
18231 | ||
18232 | /* Override any GCC internal prototype to avoid an error. | |
18233 | Use char because int might match the return type of a GCC | |
18234 | builtin and then its argument prototype would still apply. */ | |
18235 | #ifdef __cplusplus | |
18236 | extern "C" | |
18237 | #endif | |
18238 | char dgettext (); | |
18239 | int | |
18240 | main () | |
18241 | { | |
18242 | return dgettext (); | |
18243 | ; | |
18244 | return 0; | |
18245 | } | |
18246 | _ACEOF | |
18247 | if ac_fn_c_try_link "$LINENO"; then : | |
18248 | ac_cv_lib_intl_dgettext=yes | |
18249 | else | |
18250 | ac_cv_lib_intl_dgettext=no | |
18251 | fi | |
18252 | rm -f core conftest.err conftest.$ac_objext \ | |
18253 | conftest$ac_exeext conftest.$ac_ext | |
18254 | LIBS=$ac_check_lib_save_LIBS | |
18255 | fi | |
18256 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_dgettext" >&5 | |
18257 | $as_echo "$ac_cv_lib_intl_dgettext" >&6; } | |
d6974efa | 18258 | if test "x$ac_cv_lib_intl_dgettext" = xyes; then : |
067d23c9 KY |
18259 | cat >>confdefs.h <<_ACEOF |
18260 | #define HAVE_LIBINTL 1 | |
18261 | _ACEOF | |
18262 | ||
18263 | LIBS="-lintl $LIBS" | |
18264 | ||
18265 | fi | |
18266 | ||
18267 | ||
18268 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5 | |
18269 | $as_echo_n "checking whether localtime caches TZ... " >&6; } | |
d6974efa | 18270 | if ${emacs_cv_localtime_cache+:} false; then : |
067d23c9 KY |
18271 | $as_echo_n "(cached) " >&6 |
18272 | else | |
18273 | if test x$ac_cv_func_tzset = xyes; then | |
18274 | if test "$cross_compiling" = yes; then : | |
18275 | # If we have tzset, assume the worst when cross-compiling. | |
18276 | emacs_cv_localtime_cache=yes | |
18277 | else | |
18278 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
18279 | /* end confdefs.h. */ | |
18280 | #include <time.h> | |
18281 | char TZ_GMT0[] = "TZ=GMT0"; | |
18282 | char TZ_PST8[] = "TZ=PST8"; | |
18283 | main() | |
18284 | { | |
18285 | time_t now = time ((time_t *) 0); | |
18286 | int hour_GMT0, hour_unset; | |
18287 | if (putenv (TZ_GMT0) != 0) | |
18288 | exit (1); | |
18289 | hour_GMT0 = localtime (&now)->tm_hour; | |
18290 | unsetenv("TZ"); | |
18291 | hour_unset = localtime (&now)->tm_hour; | |
18292 | if (putenv (TZ_PST8) != 0) | |
18293 | exit (1); | |
18294 | if (localtime (&now)->tm_hour == hour_GMT0) | |
18295 | exit (1); | |
18296 | unsetenv("TZ"); | |
18297 | if (localtime (&now)->tm_hour != hour_unset) | |
18298 | exit (1); | |
18299 | exit (0); | |
18300 | } | |
18301 | _ACEOF | |
18302 | if ac_fn_c_try_run "$LINENO"; then : | |
18303 | emacs_cv_localtime_cache=no | |
18304 | else | |
18305 | emacs_cv_localtime_cache=yes | |
18306 | fi | |
18307 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
18308 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
18309 | fi | |
18310 | ||
18311 | else | |
18312 | # If we lack tzset, report that localtime does not cache TZ, | |
18313 | # since we can't invalidate the cache if we don't have tzset. | |
18314 | emacs_cv_localtime_cache=no | |
18315 | fi | |
18316 | fi | |
18317 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5 | |
18318 | $as_echo "$emacs_cv_localtime_cache" >&6; } | |
18319 | if test $emacs_cv_localtime_cache = yes; then | |
18320 | ||
18321 | $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h | |
18322 | ||
18323 | fi | |
18324 | ||
18325 | if test "x$HAVE_TIMEVAL" = xyes; then | |
18326 | for ac_func in gettimeofday | |
18327 | do : | |
18328 | ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday" | |
d6974efa | 18329 | if test "x$ac_cv_func_gettimeofday" = xyes; then : |
067d23c9 KY |
18330 | cat >>confdefs.h <<_ACEOF |
18331 | #define HAVE_GETTIMEOFDAY 1 | |
18332 | _ACEOF | |
18333 | ||
18334 | fi | |
18335 | done | |
18336 | ||
18337 | if test $ac_cv_func_gettimeofday = yes; then | |
18338 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday can accept two arguments" >&5 | |
18339 | $as_echo_n "checking whether gettimeofday can accept two arguments... " >&6; } | |
d6974efa | 18340 | if ${emacs_cv_gettimeofday_two_arguments+:} false; then : |
067d23c9 KY |
18341 | $as_echo_n "(cached) " >&6 |
18342 | else | |
18343 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
18344 | /* end confdefs.h. */ | |
18345 | ||
18346 | #ifdef TIME_WITH_SYS_TIME | |
18347 | #include <sys/time.h> | |
18348 | #include <time.h> | |
18349 | #else | |
18350 | #ifdef HAVE_SYS_TIME_H | |
18351 | #include <sys/time.h> | |
18352 | #else | |
18353 | #include <time.h> | |
18354 | #endif | |
18355 | #endif | |
18356 | int | |
18357 | main () | |
18358 | { | |
18359 | struct timeval time; | |
18360 | gettimeofday (&time, 0); | |
18361 | ; | |
18362 | return 0; | |
18363 | } | |
18364 | _ACEOF | |
18365 | if ac_fn_c_try_compile "$LINENO"; then : | |
18366 | emacs_cv_gettimeofday_two_arguments=yes | |
18367 | else | |
18368 | emacs_cv_gettimeofday_two_arguments=no | |
18369 | fi | |
18370 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
18371 | fi | |
18372 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_gettimeofday_two_arguments" >&5 | |
18373 | $as_echo "$emacs_cv_gettimeofday_two_arguments" >&6; } | |
18374 | if test $emacs_cv_gettimeofday_two_arguments = no; then | |
18375 | ||
18376 | $as_echo "#define GETTIMEOFDAY_ONE_ARGUMENT 1" >>confdefs.h | |
18377 | ||
18378 | fi | |
18379 | fi | |
18380 | fi | |
18381 | ||
18382 | ok_so_far=yes | |
18383 | ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket" | |
d6974efa | 18384 | if test "x$ac_cv_func_socket" = xyes; then : |
067d23c9 KY |
18385 | |
18386 | else | |
18387 | ok_so_far=no | |
18388 | fi | |
18389 | ||
18390 | if test $ok_so_far = yes; then | |
18391 | ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default" | |
d6974efa | 18392 | if test "x$ac_cv_header_netinet_in_h" = xyes; then : |
067d23c9 KY |
18393 | |
18394 | else | |
18395 | ok_so_far=no | |
18396 | fi | |
18397 | ||
18398 | ||
18399 | fi | |
18400 | if test $ok_so_far = yes; then | |
18401 | ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default" | |
d6974efa | 18402 | if test "x$ac_cv_header_arpa_inet_h" = xyes; then : |
067d23c9 KY |
18403 | |
18404 | else | |
18405 | ok_so_far=no | |
18406 | fi | |
18407 | ||
18408 | ||
18409 | fi | |
18410 | if test $ok_so_far = yes; then | |
18411 | ||
18412 | $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h | |
18413 | ||
18414 | fi | |
18415 | ||
18416 | if test -f /usr/lpp/X11/bin/smt.exp; then | |
18417 | ||
18418 | $as_echo "#define HAVE_AIX_SMT_EXP 1" >>confdefs.h | |
18419 | ||
18420 | fi | |
18421 | ||
18422 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports dynamic ptys" >&5 | |
18423 | $as_echo_n "checking whether system supports dynamic ptys... " >&6; } | |
18424 | if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then | |
18425 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
18426 | $as_echo "yes" >&6; } | |
18427 | ||
18428 | $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h | |
18429 | ||
18430 | else | |
18431 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
18432 | $as_echo "no" >&6; } | |
18433 | fi | |
18434 | ||
18435 | ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" | |
d6974efa | 18436 | if test "x$ac_cv_type_pid_t" = xyes; then : |
067d23c9 KY |
18437 | |
18438 | else | |
18439 | ||
18440 | cat >>confdefs.h <<_ACEOF | |
18441 | #define pid_t int | |
18442 | _ACEOF | |
18443 | ||
18444 | fi | |
18445 | ||
18446 | for ac_header in vfork.h | |
18447 | do : | |
18448 | ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default" | |
d6974efa | 18449 | if test "x$ac_cv_header_vfork_h" = xyes; then : |
067d23c9 KY |
18450 | cat >>confdefs.h <<_ACEOF |
18451 | #define HAVE_VFORK_H 1 | |
18452 | _ACEOF | |
18453 | ||
18454 | fi | |
18455 | ||
18456 | done | |
18457 | ||
18458 | for ac_func in fork vfork | |
18459 | do : | |
18460 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
18461 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
2018939f | 18462 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
067d23c9 KY |
18463 | cat >>confdefs.h <<_ACEOF |
18464 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
18465 | _ACEOF | |
18466 | ||
18467 | fi | |
18468 | done | |
18469 | ||
18470 | if test "x$ac_cv_func_fork" = xyes; then | |
18471 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5 | |
18472 | $as_echo_n "checking for working fork... " >&6; } | |
d6974efa | 18473 | if ${ac_cv_func_fork_works+:} false; then : |
067d23c9 KY |
18474 | $as_echo_n "(cached) " >&6 |
18475 | else | |
18476 | if test "$cross_compiling" = yes; then : | |
18477 | ac_cv_func_fork_works=cross | |
18478 | else | |
18479 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
18480 | /* end confdefs.h. */ | |
18481 | $ac_includes_default | |
18482 | int | |
18483 | main () | |
18484 | { | |
18485 | ||
18486 | /* By Ruediger Kuhlmann. */ | |
18487 | return fork () < 0; | |
18488 | ||
18489 | ; | |
18490 | return 0; | |
18491 | } | |
18492 | _ACEOF | |
18493 | if ac_fn_c_try_run "$LINENO"; then : | |
18494 | ac_cv_func_fork_works=yes | |
18495 | else | |
18496 | ac_cv_func_fork_works=no | |
18497 | fi | |
18498 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
18499 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
18500 | fi | |
18501 | ||
18502 | fi | |
18503 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5 | |
18504 | $as_echo "$ac_cv_func_fork_works" >&6; } | |
18505 | ||
18506 | else | |
18507 | ac_cv_func_fork_works=$ac_cv_func_fork | |
18508 | fi | |
18509 | if test "x$ac_cv_func_fork_works" = xcross; then | |
18510 | case $host in | |
18511 | *-*-amigaos* | *-*-msdosdjgpp*) | |
18512 | # Override, as these systems have only a dummy fork() stub | |
18513 | ac_cv_func_fork_works=no | |
18514 | ;; | |
18515 | *) | |
18516 | ac_cv_func_fork_works=yes | |
18517 | ;; | |
18518 | esac | |
18519 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5 | |
18520 | $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;} | |
18521 | fi | |
18522 | ac_cv_func_vfork_works=$ac_cv_func_vfork | |
18523 | if test "x$ac_cv_func_vfork" = xyes; then | |
18524 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5 | |
18525 | $as_echo_n "checking for working vfork... " >&6; } | |
d6974efa | 18526 | if ${ac_cv_func_vfork_works+:} false; then : |
067d23c9 KY |
18527 | $as_echo_n "(cached) " >&6 |
18528 | else | |
18529 | if test "$cross_compiling" = yes; then : | |
18530 | ac_cv_func_vfork_works=cross | |
18531 | else | |
18532 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
18533 | /* end confdefs.h. */ | |
18534 | /* Thanks to Paul Eggert for this test. */ | |
18535 | $ac_includes_default | |
18536 | #include <sys/wait.h> | |
18537 | #ifdef HAVE_VFORK_H | |
18538 | # include <vfork.h> | |
18539 | #endif | |
18540 | /* On some sparc systems, changes by the child to local and incoming | |
18541 | argument registers are propagated back to the parent. The compiler | |
18542 | is told about this with #include <vfork.h>, but some compilers | |
18543 | (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a | |
18544 | static variable whose address is put into a register that is | |
18545 | clobbered by the vfork. */ | |
18546 | static void | |
18547 | #ifdef __cplusplus | |
18548 | sparc_address_test (int arg) | |
18549 | # else | |
18550 | sparc_address_test (arg) int arg; | |
18551 | #endif | |
18552 | { | |
18553 | static pid_t child; | |
18554 | if (!child) { | |
18555 | child = vfork (); | |
18556 | if (child < 0) { | |
18557 | perror ("vfork"); | |
18558 | _exit(2); | |
18559 | } | |
18560 | if (!child) { | |
18561 | arg = getpid(); | |
18562 | write(-1, "", 0); | |
18563 | _exit (arg); | |
18564 | } | |
18565 | } | |
18566 | } | |
18567 | ||
18568 | int | |
18569 | main () | |
18570 | { | |
18571 | pid_t parent = getpid (); | |
18572 | pid_t child; | |
18573 | ||
18574 | sparc_address_test (0); | |
18575 | ||
18576 | child = vfork (); | |
18577 | ||
18578 | if (child == 0) { | |
18579 | /* Here is another test for sparc vfork register problems. This | |
18580 | test uses lots of local variables, at least as many local | |
18581 | variables as main has allocated so far including compiler | |
18582 | temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris | |
18583 | 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should | |
18584 | reuse the register of parent for one of the local variables, | |
18585 | since it will think that parent can't possibly be used any more | |
18586 | in this routine. Assigning to the local variable will thus | |
18587 | munge parent in the parent process. */ | |
18588 | pid_t | |
18589 | p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), | |
18590 | p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); | |
18591 | /* Convince the compiler that p..p7 are live; otherwise, it might | |
18592 | use the same hardware register for all 8 local variables. */ | |
18593 | if (p != p1 || p != p2 || p != p3 || p != p4 | |
18594 | || p != p5 || p != p6 || p != p7) | |
18595 | _exit(1); | |
18596 | ||
18597 | /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent | |
18598 | from child file descriptors. If the child closes a descriptor | |
18599 | before it execs or exits, this munges the parent's descriptor | |
18600 | as well. Test for this by closing stdout in the child. */ | |
18601 | _exit(close(fileno(stdout)) != 0); | |
18602 | } else { | |
18603 | int status; | |
18604 | struct stat st; | |
18605 | ||
18606 | while (wait(&status) != child) | |
18607 | ; | |
18608 | return ( | |
18609 | /* Was there some problem with vforking? */ | |
18610 | child < 0 | |
18611 | ||
18612 | /* Did the child fail? (This shouldn't happen.) */ | |
18613 | || status | |
18614 | ||
18615 | /* Did the vfork/compiler bug occur? */ | |
18616 | || parent != getpid() | |
18617 | ||
18618 | /* Did the file descriptor bug occur? */ | |
18619 | || fstat(fileno(stdout), &st) != 0 | |
18620 | ); | |
18621 | } | |
18622 | } | |
18623 | _ACEOF | |
18624 | if ac_fn_c_try_run "$LINENO"; then : | |
18625 | ac_cv_func_vfork_works=yes | |
18626 | else | |
18627 | ac_cv_func_vfork_works=no | |
18628 | fi | |
18629 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
18630 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
18631 | fi | |
18632 | ||
18633 | fi | |
18634 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5 | |
18635 | $as_echo "$ac_cv_func_vfork_works" >&6; } | |
18636 | ||
18637 | fi; | |
18638 | if test "x$ac_cv_func_fork_works" = xcross; then | |
18639 | ac_cv_func_vfork_works=$ac_cv_func_vfork | |
18640 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5 | |
18641 | $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;} | |
18642 | fi | |
18643 | ||
18644 | if test "x$ac_cv_func_vfork_works" = xyes; then | |
18645 | ||
18646 | $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h | |
18647 | ||
18648 | else | |
18649 | ||
18650 | $as_echo "#define vfork fork" >>confdefs.h | |
18651 | ||
18652 | fi | |
18653 | if test "x$ac_cv_func_fork_works" = xyes; then | |
18654 | ||
18655 | $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h | |
18656 | ||
18657 | fi | |
18658 | ||
18659 | ||
18660 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5 | |
18661 | $as_echo_n "checking for nl_langinfo and CODESET... " >&6; } | |
d6974efa | 18662 | if ${emacs_cv_langinfo_codeset+:} false; then : |
067d23c9 KY |
18663 | $as_echo_n "(cached) " >&6 |
18664 | else | |
18665 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
18666 | /* end confdefs.h. */ | |
18667 | #include <langinfo.h> | |
18668 | int | |
18669 | main () | |
18670 | { | |
18671 | char* cs = nl_langinfo(CODESET); | |
18672 | ; | |
18673 | return 0; | |
18674 | } | |
18675 | _ACEOF | |
18676 | if ac_fn_c_try_link "$LINENO"; then : | |
18677 | emacs_cv_langinfo_codeset=yes | |
18678 | else | |
18679 | emacs_cv_langinfo_codeset=no | |
18680 | fi | |
18681 | rm -f core conftest.err conftest.$ac_objext \ | |
18682 | conftest$ac_exeext conftest.$ac_ext | |
18683 | ||
18684 | fi | |
18685 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5 | |
18686 | $as_echo "$emacs_cv_langinfo_codeset" >&6; } | |
18687 | if test $emacs_cv_langinfo_codeset = yes; then | |
18688 | ||
18689 | $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h | |
18690 | ||
18691 | fi | |
18692 | ||
18693 | ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" | |
d6974efa | 18694 | if test "x$ac_cv_type_size_t" = xyes; then : |
067d23c9 KY |
18695 | |
18696 | cat >>confdefs.h <<_ACEOF | |
18697 | #define HAVE_SIZE_T 1 | |
18698 | _ACEOF | |
18699 | ||
18700 | ||
18701 | fi | |
18702 | ||
18703 | ||
18704 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5 | |
18705 | $as_echo_n "checking for mbstate_t... " >&6; } | |
d6974efa | 18706 | if ${ac_cv_type_mbstate_t+:} false; then : |
067d23c9 KY |
18707 | $as_echo_n "(cached) " >&6 |
18708 | else | |
18709 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
18710 | /* end confdefs.h. */ | |
18711 | $ac_includes_default | |
18712 | # include <wchar.h> | |
18713 | int | |
18714 | main () | |
18715 | { | |
18716 | mbstate_t x; return sizeof x; | |
18717 | ; | |
18718 | return 0; | |
18719 | } | |
18720 | _ACEOF | |
18721 | if ac_fn_c_try_compile "$LINENO"; then : | |
18722 | ac_cv_type_mbstate_t=yes | |
18723 | else | |
18724 | ac_cv_type_mbstate_t=no | |
18725 | fi | |
18726 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
18727 | fi | |
18728 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5 | |
18729 | $as_echo "$ac_cv_type_mbstate_t" >&6; } | |
18730 | if test $ac_cv_type_mbstate_t = yes; then | |
18731 | ||
18732 | $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h | |
18733 | ||
18734 | else | |
18735 | ||
18736 | $as_echo "#define mbstate_t int" >>confdefs.h | |
18737 | ||
18738 | fi | |
18739 | ||
067d23c9 KY |
18740 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5 |
18741 | $as_echo_n "checking for C restricted array declarations... " >&6; } | |
d6974efa | 18742 | if ${emacs_cv_c_restrict_arr+:} false; then : |
067d23c9 KY |
18743 | $as_echo_n "(cached) " >&6 |
18744 | else | |
18745 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
18746 | /* end confdefs.h. */ | |
18747 | void fred (int x[__restrict]); | |
18748 | int | |
18749 | main () | |
18750 | { | |
18751 | ||
18752 | ; | |
18753 | return 0; | |
18754 | } | |
18755 | _ACEOF | |
18756 | if ac_fn_c_try_compile "$LINENO"; then : | |
18757 | emacs_cv_c_restrict_arr=yes | |
18758 | else | |
18759 | emacs_cv_c_restrict_arr=no | |
18760 | fi | |
18761 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
18762 | fi | |
18763 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5 | |
18764 | $as_echo "$emacs_cv_c_restrict_arr" >&6; } | |
18765 | if test "$emacs_cv_c_restrict_arr" = yes; then | |
18766 | ||
18767 | $as_echo "#define __restrict_arr __restrict" >>confdefs.h | |
18768 | ||
18769 | fi | |
18770 | ||
18771 | ||
18772 | ||
18773 | # Set up the CFLAGS for real compilation, so we can substitute it. | |
18774 | CFLAGS="$REAL_CFLAGS" | |
18775 | CPPFLAGS="$REAL_CPPFLAGS" | |
18776 | ||
18777 | ## Hack to detect a buggy GCC version. | |
18778 | if test "x$GCC" = xyes \ | |
18779 | && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \ | |
18780 | && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \ | |
18781 | && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then | |
2018939f | 18782 | as_fn_error $? "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5 |
067d23c9 KY |
18783 | fi |
18784 | ||
16fab143 | 18785 | version=$PACKAGE_VERSION |
067d23c9 KY |
18786 | |
18787 | ### Specify what sort of things we'll be editing into Makefile and config.h. | |
18788 | ### Use configuration here uncanonicalized to avoid exceeding size limits. | |
18789 | ||
18790 | ||
18791 | ## Unused? | |
18792 | ||
18793 | ||
18794 | ||
18795 | ||
18796 | ||
18797 | ||
18798 | ||
18799 | ||
18800 | ||
18801 | ||
18802 | ||
18803 | ||
18804 | ||
18805 | ||
18806 | ||
18807 | ||
18808 | ||
18809 | ||
18810 | ||
18811 | ||
18812 | ## FIXME? Nothing uses @LD_SWITCH_X_SITE@. | |
18813 | ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the | |
18814 | ## end of LIBX_BASE, but nothing ever set it. | |
18815 | ||
18816 | ||
18817 | ||
18818 | ||
18819 | ## Used in lwlib/Makefile.in. | |
18820 | ||
d6a003a8 AS |
18821 | if test -n "${machfile}"; then |
18822 | M_FILE="\$(srcdir)/${machfile}" | |
18823 | else | |
18824 | M_FILE= | |
18825 | fi | |
18826 | S_FILE="\$(srcdir)/${opsysfile}" | |
067d23c9 KY |
18827 | |
18828 | ||
18829 | ||
18830 | ||
18831 | ||
18832 | ||
18833 | ||
18834 | ||
18835 | ||
18836 | ||
067d23c9 KY |
18837 | cat >>confdefs.h <<_ACEOF |
18838 | #define EMACS_CONFIGURATION "${canonical}" | |
18839 | _ACEOF | |
18840 | ||
18841 | ||
18842 | cat >>confdefs.h <<_ACEOF | |
18843 | #define EMACS_CONFIG_OPTIONS "${ac_configure_args}" | |
18844 | _ACEOF | |
18845 | ||
d6a003a8 | 18846 | if test -n "$machfile"; then |
067d23c9 KY |
18847 | |
18848 | cat >>confdefs.h <<_ACEOF | |
18849 | #define config_machfile "${machfile}" | |
18850 | _ACEOF | |
18851 | ||
d6a003a8 | 18852 | fi |
067d23c9 KY |
18853 | |
18854 | cat >>confdefs.h <<_ACEOF | |
18855 | #define config_opsysfile "${opsysfile}" | |
18856 | _ACEOF | |
18857 | ||
18858 | ||
18859 | XMENU_OBJ= | |
18860 | XOBJ= | |
18861 | FONT_OBJ= | |
18862 | if test "${HAVE_X_WINDOWS}" = "yes" ; then | |
18863 | ||
18864 | $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h | |
18865 | ||
18866 | XMENU_OBJ=xmenu.o | |
18867 | XOBJ="xterm.o xfns.o xselect.o xrdb.o fontset.o xsmfns.o fringe.o image.o xsettings.o xgselect.o" | |
18868 | FONT_OBJ=xfont.o | |
18869 | if test "$HAVE_XFT" = "yes"; then | |
18870 | FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o" | |
18871 | elif test "$HAVE_FREETYPE" = "yes"; then | |
18872 | FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o" | |
18873 | fi | |
18874 | ||
18875 | fi | |
18876 | ||
18877 | ||
18878 | ||
18879 | ||
18880 | WIDGET_OBJ= | |
18881 | MOTIF_LIBW= | |
18882 | if test "${USE_X_TOOLKIT}" != "none" ; then | |
18883 | WIDGET_OBJ=widget.o | |
18884 | ||
18885 | $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h | |
18886 | ||
18887 | if test "${USE_X_TOOLKIT}" = "LUCID"; then | |
18888 | ||
18889 | $as_echo "#define USE_LUCID 1" >>confdefs.h | |
18890 | ||
18891 | elif test "${USE_X_TOOLKIT}" = "MOTIF"; then | |
18892 | ||
18893 | $as_echo "#define USE_MOTIF 1" >>confdefs.h | |
18894 | ||
18895 | MOTIF_LIBW=-lXm | |
18896 | case "$opsys" in | |
18897 | gnu-linux) | |
18898 | ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed. | |
18899 | MOTIF_LIBW="$MOTIF_LIBW -lXpm" | |
18900 | ;; | |
18901 | ||
18902 | unixware) | |
18903 | ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov> | |
18904 | ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2. | |
18905 | MOTIF_LIBW="MOTIF_LIBW -lXimp" | |
18906 | ;; | |
18907 | ||
18908 | aix4-2) | |
18909 | ## olson@mcs.anl.gov says -li18n is needed by -lXm. | |
18910 | MOTIF_LIBW="$MOTIF_LIBW -li18n" | |
18911 | ;; | |
18912 | esac | |
18913 | MOTIF_LIBW="$MOTIF_LIBW $LIBXP" | |
18914 | fi | |
18915 | fi | |
18916 | ||
18917 | ||
18918 | TOOLKIT_LIBW= | |
18919 | case "$USE_X_TOOLKIT" in | |
18920 | MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;; | |
18921 | LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;; | |
18922 | none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;; | |
18923 | esac | |
18924 | ||
18925 | ||
18926 | if test "$USE_X_TOOLKIT" = "none"; then | |
18927 | LIBXT_OTHER="\$(LIBXSM)" | |
18928 | OLDXMENU_TARGET="really-oldXMenu" | |
18929 | else | |
18930 | LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext" | |
18931 | OLDXMENU_TARGET="really-lwlib" | |
18932 | fi | |
18933 | ||
18934 | ||
18935 | ## The X Menu stuff is present in the X10 distribution, but missing | |
18936 | ## from X11. If we have X10, just use the installed library; | |
18937 | ## otherwise, use our own copy. | |
18938 | if test "${HAVE_X11}" = "yes" ; then | |
18939 | ||
18940 | $as_echo "#define HAVE_X11 1" >>confdefs.h | |
18941 | ||
18942 | ||
18943 | if test "$USE_X_TOOLKIT" = "none"; then | |
18944 | OLDXMENU="\${oldXMenudir}/libXMenu11.a" | |
18945 | else | |
18946 | OLDXMENU="\${lwlibdir}/liblw.a" | |
18947 | fi | |
18948 | LIBXMENU="\$(OLDXMENU)" | |
18949 | LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)" | |
18950 | OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}" | |
18951 | else | |
18952 | ## For a syntactically valid Makefile; not actually used for anything. | |
18953 | ## See comments in src/Makefile.in. | |
18954 | OLDXMENU=nothing | |
18955 | ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?). | |
18956 | if test "${HAVE_X_WINDOWS}" = "yes"; then | |
18957 | LIBXMENU="-lXMenu" | |
18958 | else | |
18959 | LIBXMENU= | |
18960 | fi | |
18961 | LIBX_OTHER= | |
18962 | OLDXMENU_DEPS= | |
18963 | fi | |
18964 | ||
18965 | if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then | |
18966 | OLDXMENU_TARGET= | |
18967 | OLDXMENU=nothing | |
18968 | LIBXMENU= | |
18969 | OLDXMENU_DEPS= | |
18970 | fi | |
18971 | ||
18972 | ||
18973 | ||
18974 | ||
18975 | ||
18976 | ||
18977 | ||
18978 | if test "${HAVE_MENUS}" = "yes" ; then | |
18979 | ||
18980 | $as_echo "#define HAVE_MENUS 1" >>confdefs.h | |
18981 | ||
18982 | fi | |
18983 | ||
18984 | if test "${GNU_MALLOC}" = "yes" ; then | |
18985 | ||
18986 | $as_echo "#define GNU_MALLOC 1" >>confdefs.h | |
18987 | ||
18988 | fi | |
18989 | ||
18990 | RALLOC_OBJ= | |
18991 | if test "${REL_ALLOC}" = "yes" ; then | |
18992 | ||
18993 | $as_echo "#define REL_ALLOC 1" >>confdefs.h | |
18994 | ||
18995 | ||
18996 | test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o | |
18997 | fi | |
18998 | ||
18999 | ||
19000 | if test "$opsys" = "cygwin"; then | |
19001 | CYGWIN_OBJ="sheap.o" | |
19002 | ## Cygwin differs because of its unexec(). | |
19003 | PRE_ALLOC_OBJ= | |
19004 | POST_ALLOC_OBJ=lastfile.o | |
19005 | else | |
19006 | CYGWIN_OBJ= | |
19007 | PRE_ALLOC_OBJ=lastfile.o | |
19008 | POST_ALLOC_OBJ= | |
19009 | fi | |
19010 | ||
19011 | ||
19012 | ||
19013 | ||
19014 | ||
19015 | case "$opsys" in | |
19016 | aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;; | |
19017 | ||
19018 | darwin) | |
19019 | ## The -headerpad option tells ld (see man page) to leave room at the | |
19020 | ## end of the header for adding load commands. Needed for dumping. | |
19021 | ## 0x690 is the total size of 30 segment load commands (at 56 | |
19022 | ## each); under Cocoa 31 commands are required. | |
19023 | if test "$HAVE_NS" = "yes"; then | |
19024 | libs_nsgui="-framework AppKit" | |
19025 | headerpad_extra=6C8 | |
19026 | else | |
19027 | libs_nsgui= | |
19028 | headerpad_extra=690 | |
19029 | fi | |
19030 | LD_SWITCH_SYSTEM_TEMACS="-prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra" | |
19031 | ||
19032 | ## This is here because src/Makefile.in did some extra fiddling around | |
19033 | ## with LD_SWITCH_SYSTEM. The cpp logic was: | |
19034 | ## #ifndef LD_SWITCH_SYSTEM | |
19035 | ## #if !defined (__GNUC__) && ((defined (BSD_SYSTEM) && !defined (COFF))) | |
19036 | ## Since all the *bsds define LD_SWITCH_SYSTEM, this simplifies to: | |
19037 | ## not using gcc, darwin system not on an alpha (ie darwin, since | |
19038 | ## darwin + alpha does not occur). | |
19039 | ## Because this was done in src/Makefile.in, the resulting part of | |
19040 | ## LD_SWITCH_SYSTEM was not used in configure (ie, in ac_link). | |
19041 | ## It therefore seems cleaner to put this in LD_SWITCH_SYSTEM_TEMACS, | |
19042 | ## rather than LD_SWITCH_SYSTEM. | |
19043 | test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \ | |
19044 | LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS" | |
19045 | ;; | |
19046 | ||
19047 | ## LD_SWITCH_X_SITE_AUX is a -R option saying where to find X at run-time. | |
19048 | ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at | |
19049 | ## the point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_AUX | |
19050 | ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM | |
19051 | ## had different values in configure (in ac_link) and src/Makefile.in. | |
19052 | ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS. | |
19053 | gnu-linux) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_AUX)" ;; | |
19054 | ||
19055 | *) LD_SWITCH_SYSTEM_TEMACS= ;; | |
19056 | esac | |
19057 | ||
19058 | if test "$NS_IMPL_GNUSTEP" = "yes"; then | |
19059 | LD_SWITCH_SYSTEM_TEMACS="${LD_SWITCH_SYSTEM_TEMACS} -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES} -lgnustep-gui -lgnustep-base -lobjc -lpthread" | |
19060 | fi | |
19061 | ||
19062 | ||
19063 | ||
19064 | ||
19065 | LD_FIRSTFLAG= | |
19066 | ORDINARY_LINK= | |
19067 | case "$opsys" in | |
19068 | ## gnu: GNU needs its own crt0. | |
19069 | aix4-2|cygwin|darwin|gnu|hpux*|irix6-5|sol2*|unixware) ORDINARY_LINK=yes ;; | |
19070 | ||
19071 | ## On post 1.3 releases of NetBSD, gcc -nostdlib also clears the | |
19072 | ## library search parth, i.e. it won't search /usr/lib for libc and | |
19073 | ## friends. Using -nostartfiles instead avoids this problem, and | |
19074 | ## will also work on earlier NetBSD releases. | |
19075 | netbsd|openbsd) LD_FIRSTFLAG="-nostartfiles" ;; | |
19076 | ||
19077 | ## macpcc: NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp> says | |
19078 | ## MkLinux/LinuxPPC needs this. | |
19079 | ## ibms390x only supports opsys = gnu-linux so it can be added here. | |
19080 | gnu-*) | |
19081 | case "$machine" in | |
19082 | macppc|ibms390x) LD_FIRSTFLAG="-nostdlib" ;; | |
19083 | esac | |
19084 | ;; | |
19085 | esac | |
19086 | ||
19087 | ||
19088 | if test "x$ORDINARY_LINK" = "xyes"; then | |
19089 | ||
19090 | LD_FIRSTFLAG="" | |
19091 | ||
19092 | $as_echo "#define ORDINARY_LINK 1" >>confdefs.h | |
19093 | ||
19094 | ||
19095 | ## The system files defining neither ORDINARY_LINK nor LD_FIRSTFLAG are: | |
19096 | ## freebsd, gnu-* not on macppc|ibms390x. | |
19097 | elif test "x$GCC" = "xyes" && test "x$LD_FIRSTFLAG" = "x"; then | |
19098 | ||
19099 | ## Versions of GCC >= 2.0 put their library, libgcc.a, in obscure | |
19100 | ## places that are difficult to figure out at make time. Fortunately, | |
19101 | ## these same versions allow you to pass arbitrary flags on to the | |
19102 | ## linker, so there is no reason not to use it as a linker. | |
19103 | ## | |
19104 | ## Well, it is not quite perfect. The "-nostdlib" keeps GCC from | |
19105 | ## searching for libraries in its internal directories, so we have to | |
19106 | ## ask GCC explicitly where to find libgcc.a (LIB_GCC below). | |
19107 | LD_FIRSTFLAG="-nostdlib" | |
19108 | fi | |
19109 | ||
19110 | ## FIXME? What setting of EDIT_LDFLAGS should this have? | |
19111 | test "$NS_IMPL_GNUSTEP" = "yes" && LD_FIRSTFLAG="-rdynamic" | |
19112 | ||
19113 | ||
19114 | ||
19115 | ||
19116 | ## FIXME? The logic here is not precisely the same as that above. | |
19117 | ## There is no check here for a pre-defined LD_FIRSTFLAG. | |
19118 | ## Should we only be setting LIB_GCC if LD ~ -nostdlib? | |
19119 | LIB_GCC= | |
19120 | if test "x$GCC" = "xyes" && test "x$ORDINARY_LINK" != "xyes"; then | |
19121 | ||
19122 | case "$opsys" in | |
19123 | freebsd|netbsd|openbsd) LIB_GCC= ;; | |
19124 | ||
19125 | gnu-*) | |
19126 | ## armin76@gentoo.org reported that the lgcc_s flag is necessary to | |
19127 | ## build on ARM EABI under GNU/Linux. (Bug#5518) | |
d6a003a8 AS |
19128 | case $host_cpu in |
19129 | arm*) | |
067d23c9 | 19130 | LIB_GCC="-lgcc_s" |
d6a003a8 AS |
19131 | ;; |
19132 | *) | |
067d23c9 KY |
19133 | ## FIXME? s/gnu-linux.h used to define LIB_GCC as below, then |
19134 | ## immediately undefine it again and redefine it to empty. | |
19135 | ## Was the C_SWITCH_X_SITE part really necessary? | |
19136 | ## LIB_GCC=`$CC $C_SWITCH_X_SITE -print-libgcc-file-name` | |
19137 | LIB_GCC= | |
d6a003a8 AS |
19138 | ;; |
19139 | esac | |
067d23c9 KY |
19140 | ;; |
19141 | ||
19142 | ## Ask GCC where to find libgcc.a. | |
19143 | *) LIB_GCC=`$CC -print-libgcc-file-name 2> /dev/null` ;; | |
19144 | esac | |
19145 | fi | |
19146 | ||
19147 | ||
19148 | TOOLTIP_SUPPORT= | |
19149 | WINDOW_SUPPORT= | |
19150 | ## If we're using X11/GNUstep, define some consequences. | |
19151 | if test "$HAVE_X_WINDOWS" = "yes" || test "$HAVE_NS" = "yes"; then | |
19152 | ||
19153 | $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h | |
19154 | ||
19155 | ||
19156 | $as_echo "#define HAVE_MOUSE 1" >>confdefs.h | |
19157 | ||
19158 | MOUSE_SUPPORT="\$(REAL_MOUSE_SUPPORT)" | |
19159 | TOOLTIP_SUPPORT="\${lispsource}/mouse.elc" | |
19160 | ||
19161 | WINDOW_SUPPORT="\$(BASE_WINDOW_SUPPORT)" | |
19162 | test "$HAVE_X_WINDOWS" = "yes" && \ | |
19163 | WINDOW_SUPPORT="$WINDOW_SUPPORT \$(X_WINDOW_SUPPORT)" | |
19164 | ||
19165 | fi | |
19166 | ||
19167 | ||
19168 | ||
19169 | ||
19170 | ||
19171 | ||
19172 | ||
19173 | #### Report on what we decided to do. | |
19174 | #### Report GTK as a toolkit, even if it doesn't use Xt. | |
19175 | #### It makes printing result more understandable as using GTK sets | |
19176 | #### toolkit_scroll_bars to yes by default. | |
19177 | if test "${HAVE_GTK}" = "yes"; then | |
19178 | USE_X_TOOLKIT=GTK | |
19179 | fi | |
19180 | ||
2b7f50d8 AS |
19181 | and_machfile= |
19182 | if test -n "$machfile"; then | |
19183 | and_machfile=" and \`${machfile}'" | |
19184 | fi | |
19185 | ||
067d23c9 KY |
19186 | echo " |
19187 | Configured for \`${canonical}'. | |
19188 | ||
19189 | Where should the build process find the source code? ${srcdir} | |
19190 | What operating system and machine description files should Emacs use? | |
2b7f50d8 | 19191 | \`${opsysfile}'${and_machfile} |
067d23c9 KY |
19192 | What compiler should emacs be built with? ${CC} ${CFLAGS} |
19193 | Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason} | |
19194 | Should Emacs use a relocating allocator for buffers? ${REL_ALLOC} | |
19195 | Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers | |
19196 | What window system should Emacs use? ${window_system} | |
19197 | What toolkit should Emacs use? ${USE_X_TOOLKIT}" | |
19198 | ||
19199 | if test -n "${x_includes}"; then | |
19200 | echo " Where do we find X Windows header files? ${x_includes}" | |
19201 | else | |
19202 | echo " Where do we find X Windows header files? Standard dirs" | |
19203 | fi | |
19204 | if test -n "${x_libraries}"; then | |
19205 | echo " Where do we find X Windows libraries? ${x_libraries}" | |
19206 | else | |
19207 | echo " Where do we find X Windows libraries? Standard dirs" | |
19208 | fi | |
19209 | ||
19210 | echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}" | |
19211 | echo " Does Emacs use -lXpm? ${HAVE_XPM}" | |
19212 | echo " Does Emacs use -ljpeg? ${HAVE_JPEG}" | |
19213 | echo " Does Emacs use -ltiff? ${HAVE_TIFF}" | |
19214 | echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF" | |
19215 | echo " Does Emacs use -lpng? ${HAVE_PNG}" | |
19216 | echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}" | |
19217 | echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}" | |
19218 | ||
19219 | echo " Does Emacs use -lgpm? ${HAVE_GPM}" | |
19220 | echo " Does Emacs use -ldbus? ${HAVE_DBUS}" | |
19221 | echo " Does Emacs use -lgconf? ${HAVE_GCONF}" | |
19222 | echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}" | |
19223 | echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}" | |
19224 | echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}" | |
19225 | ||
19226 | echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}" | |
19227 | echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}" | |
19228 | echo " Does Emacs use -lotf? ${HAVE_LIBOTF}" | |
19229 | echo " Does Emacs use -lxft? ${HAVE_XFT}" | |
19230 | ||
19231 | echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}" | |
19232 | echo | |
19233 | ||
19234 | if test $USE_XASSERTS = yes; then | |
19235 | echo " Compiling with asserts turned on." | |
19236 | CPPFLAGS="$CPPFLAGS -DXASSERTS=1" | |
19237 | fi | |
19238 | ||
19239 | echo | |
19240 | ||
19241 | if test "$HAVE_NS" = "yes"; then | |
19242 | echo | |
19243 | echo "You must run \"make install\" in order to test the built application. | |
19244 | The installed application will go to nextstep/Emacs.app and can be | |
19245 | run or moved from there." | |
19246 | if test "$EN_NS_SELF_CONTAINED" = "yes"; then | |
19247 | echo "The application will be fully self-contained." | |
19248 | else | |
19249 | echo "The lisp resources for the application will be installed under ${prefix}. | |
19250 | You may need to run \"make install\" with sudo. The application will fail | |
19251 | to run if these resources are not installed." | |
19252 | fi | |
19253 | echo | |
19254 | fi | |
19255 | ||
19256 | ||
19257 | # Remove any trailing slashes in these variables. | |
19258 | test "${prefix}" != NONE && | |
19259 | prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'` | |
19260 | test "${exec_prefix}" != NONE && | |
19261 | exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'` | |
19262 | ||
193770ee | 19263 | ac_config_files="$ac_config_files Makefile lib/Makefile lib-src/Makefile oldXMenu/Makefile doc/emacs/Makefile doc/misc/Makefile doc/lispintro/Makefile doc/lispref/Makefile src/Makefile lwlib/Makefile lisp/Makefile leim/Makefile test/automated/Makefile" |
067d23c9 KY |
19264 | |
19265 | ac_config_commands="$ac_config_commands default" | |
19266 | ||
19267 | cat >confcache <<\_ACEOF | |
19268 | # This file is a shell script that caches the results of configure | |
19269 | # tests run on this system so they can be shared between configure | |
19270 | # scripts and configure runs, see configure's option --config-cache. | |
19271 | # It is not useful on other systems. If it contains results you don't | |
19272 | # want to keep, you may remove or edit it. | |
19273 | # | |
19274 | # config.status only pays attention to the cache file if you give it | |
19275 | # the --recheck option to rerun configure. | |
19276 | # | |
19277 | # `ac_cv_env_foo' variables (set or unset) will be overridden when | |
19278 | # loading this file, other *unset* `ac_cv_foo' will be assigned the | |
19279 | # following values. | |
19280 | ||
19281 | _ACEOF | |
19282 | ||
19283 | # The following way of writing the cache mishandles newlines in values, | |
19284 | # but we know of no workaround that is simple, portable, and efficient. | |
19285 | # So, we kill variables containing newlines. | |
19286 | # Ultrix sh set writes to stderr and can't be redirected directly, | |
19287 | # and sets the high bit in the cache file unless we assign to the vars. | |
19288 | ( | |
19289 | for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do | |
19290 | eval ac_val=\$$ac_var | |
19291 | case $ac_val in #( | |
19292 | *${as_nl}*) | |
19293 | case $ac_var in #( | |
19294 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 | |
19295 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; | |
19296 | esac | |
19297 | case $ac_var in #( | |
19298 | _ | IFS | as_nl) ;; #( | |
19299 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( | |
19300 | *) { eval $ac_var=; unset $ac_var;} ;; | |
19301 | esac ;; | |
19302 | esac | |
19303 | done | |
19304 | ||
19305 | (set) 2>&1 | | |
19306 | case $as_nl`(ac_space=' '; set) 2>&1` in #( | |
19307 | *${as_nl}ac_space=\ *) | |
19308 | # `set' does not quote correctly, so add quotes: double-quote | |
19309 | # substitution turns \\\\ into \\, and sed turns \\ into \. | |
19310 | sed -n \ | |
19311 | "s/'/'\\\\''/g; | |
19312 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" | |
19313 | ;; #( | |
19314 | *) | |
19315 | # `set' quotes correctly as required by POSIX, so do not add quotes. | |
19316 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" | |
19317 | ;; | |
19318 | esac | | |
19319 | sort | |
19320 | ) | | |
19321 | sed ' | |
19322 | /^ac_cv_env_/b end | |
19323 | t clear | |
19324 | :clear | |
19325 | s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ | |
19326 | t end | |
19327 | s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ | |
19328 | :end' >>confcache | |
19329 | if diff "$cache_file" confcache >/dev/null 2>&1; then :; else | |
19330 | if test -w "$cache_file"; then | |
d6974efa | 19331 | if test "x$cache_file" != "x/dev/null"; then |
067d23c9 KY |
19332 | { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 |
19333 | $as_echo "$as_me: updating cache $cache_file" >&6;} | |
d6974efa PE |
19334 | if test ! -f "$cache_file" || test -h "$cache_file"; then |
19335 | cat confcache >"$cache_file" | |
19336 | else | |
19337 | case $cache_file in #( | |
19338 | */* | ?:*) | |
19339 | mv -f confcache "$cache_file"$$ && | |
19340 | mv -f "$cache_file"$$ "$cache_file" ;; #( | |
19341 | *) | |
19342 | mv -f confcache "$cache_file" ;; | |
19343 | esac | |
19344 | fi | |
19345 | fi | |
067d23c9 KY |
19346 | else |
19347 | { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 | |
19348 | $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} | |
19349 | fi | |
19350 | fi | |
19351 | rm -f confcache | |
19352 | ||
19353 | test "x$prefix" = xNONE && prefix=$ac_default_prefix | |
19354 | # Let make expand exec_prefix. | |
19355 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' | |
19356 | ||
19357 | DEFS=-DHAVE_CONFIG_H | |
19358 | ||
19359 | ac_libobjs= | |
19360 | ac_ltlibobjs= | |
2018939f | 19361 | U= |
067d23c9 KY |
19362 | for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue |
19363 | # 1. Remove the extension, and $U if already installed. | |
19364 | ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' | |
19365 | ac_i=`$as_echo "$ac_i" | sed "$ac_script"` | |
19366 | # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR | |
19367 | # will be set to the directory where LIBOBJS objects are built. | |
19368 | as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" | |
19369 | as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' | |
19370 | done | |
19371 | LIBOBJS=$ac_libobjs | |
19372 | ||
19373 | LTLIBOBJS=$ac_ltlibobjs | |
19374 | ||
19375 | ||
743c80a7 PE |
19376 | if test -n "$EXEEXT"; then |
19377 | am__EXEEXT_TRUE= | |
19378 | am__EXEEXT_FALSE='#' | |
19379 | else | |
19380 | am__EXEEXT_TRUE='#' | |
19381 | am__EXEEXT_FALSE= | |
19382 | fi | |
19383 | ||
19384 | if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then | |
19385 | as_fn_error $? "conditional \"AMDEP\" was never defined. | |
19386 | Usually this means the macro was only invoked conditionally." "$LINENO" 5 | |
19387 | fi | |
19388 | if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then | |
19389 | as_fn_error $? "conditional \"am__fastdepCC\" was never defined. | |
19390 | Usually this means the macro was only invoked conditionally." "$LINENO" 5 | |
19391 | fi | |
19392 | ||
19393 | if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then | |
19394 | as_fn_error $? "conditional \"GL_COND_LIBTOOL\" was never defined. | |
19395 | Usually this means the macro was only invoked conditionally." "$LINENO" 5 | |
19396 | fi | |
19397 | ||
942f733f | 19398 | |
743c80a7 PE |
19399 | gl_libobjs= |
19400 | gl_ltlibobjs= | |
19401 | if test -n "$gl_LIBOBJS"; then | |
19402 | # Remove the extension. | |
19403 | sed_drop_objext='s/\.o$//;s/\.obj$//' | |
19404 | for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do | |
19405 | gl_libobjs="$gl_libobjs $i.$ac_objext" | |
19406 | gl_ltlibobjs="$gl_ltlibobjs $i.lo" | |
19407 | done | |
19408 | fi | |
19409 | gl_LIBOBJS=$gl_libobjs | |
19410 | ||
19411 | gl_LTLIBOBJS=$gl_ltlibobjs | |
19412 | ||
19413 | ||
19414 | ||
19415 | gltests_libobjs= | |
19416 | gltests_ltlibobjs= | |
19417 | if test -n "$gltests_LIBOBJS"; then | |
19418 | # Remove the extension. | |
19419 | sed_drop_objext='s/\.o$//;s/\.obj$//' | |
19420 | for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do | |
19421 | gltests_libobjs="$gltests_libobjs $i.$ac_objext" | |
19422 | gltests_ltlibobjs="$gltests_ltlibobjs $i.lo" | |
19423 | done | |
19424 | fi | |
19425 | gltests_LIBOBJS=$gltests_libobjs | |
19426 | ||
19427 | gltests_LTLIBOBJS=$gltests_ltlibobjs | |
19428 | ||
067d23c9 KY |
19429 | |
19430 | ||
d6974efa | 19431 | : "${CONFIG_STATUS=./config.status}" |
067d23c9 KY |
19432 | ac_write_fail=0 |
19433 | ac_clean_files_save=$ac_clean_files | |
19434 | ac_clean_files="$ac_clean_files $CONFIG_STATUS" | |
19435 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 | |
19436 | $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} | |
19437 | as_write_fail=0 | |
19438 | cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 | |
19439 | #! $SHELL | |
19440 | # Generated by $as_me. | |
19441 | # Run this file to recreate the current configuration. | |
19442 | # Compiler output produced by configure, useful for debugging | |
19443 | # configure, is in config.log if it exists. | |
19444 | ||
19445 | debug=false | |
19446 | ac_cs_recheck=false | |
19447 | ac_cs_silent=false | |
19448 | ||
19449 | SHELL=\${CONFIG_SHELL-$SHELL} | |
19450 | export SHELL | |
19451 | _ASEOF | |
19452 | cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 | |
19453 | ## -------------------- ## | |
19454 | ## M4sh Initialization. ## | |
19455 | ## -------------------- ## | |
19456 | ||
19457 | # Be more Bourne compatible | |
19458 | DUALCASE=1; export DUALCASE # for MKS sh | |
19459 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : | |
19460 | emulate sh | |
19461 | NULLCMD=: | |
19462 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which | |
19463 | # is contrary to our usage. Disable this feature. | |
19464 | alias -g '${1+"$@"}'='"$@"' | |
19465 | setopt NO_GLOB_SUBST | |
19466 | else | |
19467 | case `(set -o) 2>/dev/null` in #( | |
19468 | *posix*) : | |
19469 | set -o posix ;; #( | |
19470 | *) : | |
19471 | ;; | |
19472 | esac | |
19473 | fi | |
19474 | ||
19475 | ||
19476 | as_nl=' | |
19477 | ' | |
19478 | export as_nl | |
19479 | # Printing a long string crashes Solaris 7 /usr/bin/printf. | |
19480 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' | |
19481 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo | |
19482 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo | |
19483 | # Prefer a ksh shell builtin over an external printf program on Solaris, | |
19484 | # but without wasting forks for bash or zsh. | |
19485 | if test -z "$BASH_VERSION$ZSH_VERSION" \ | |
19486 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then | |
19487 | as_echo='print -r --' | |
19488 | as_echo_n='print -rn --' | |
19489 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then | |
19490 | as_echo='printf %s\n' | |
19491 | as_echo_n='printf %s' | |
19492 | else | |
19493 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then | |
19494 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' | |
19495 | as_echo_n='/usr/ucb/echo -n' | |
19496 | else | |
19497 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' | |
19498 | as_echo_n_body='eval | |
19499 | arg=$1; | |
19500 | case $arg in #( | |
19501 | *"$as_nl"*) | |
19502 | expr "X$arg" : "X\\(.*\\)$as_nl"; | |
19503 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; | |
19504 | esac; | |
19505 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" | |
19506 | ' | |
19507 | export as_echo_n_body | |
19508 | as_echo_n='sh -c $as_echo_n_body as_echo' | |
19509 | fi | |
19510 | export as_echo_body | |
19511 | as_echo='sh -c $as_echo_body as_echo' | |
19512 | fi | |
19513 | ||
19514 | # The user is always right. | |
19515 | if test "${PATH_SEPARATOR+set}" != set; then | |
19516 | PATH_SEPARATOR=: | |
19517 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { | |
19518 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || | |
19519 | PATH_SEPARATOR=';' | |
19520 | } | |
19521 | fi | |
19522 | ||
19523 | ||
19524 | # IFS | |
19525 | # We need space, tab and new line, in precisely that order. Quoting is | |
19526 | # there to prevent editors from complaining about space-tab. | |
19527 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word | |
19528 | # splitting by setting IFS to empty value.) | |
19529 | IFS=" "" $as_nl" | |
19530 | ||
19531 | # Find who we are. Look in the path if we contain no directory separator. | |
d6974efa | 19532 | as_myself= |
067d23c9 KY |
19533 | case $0 in #(( |
19534 | *[\\/]* ) as_myself=$0 ;; | |
19535 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
19536 | for as_dir in $PATH | |
19537 | do | |
19538 | IFS=$as_save_IFS | |
19539 | test -z "$as_dir" && as_dir=. | |
19540 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break | |
19541 | done | |
19542 | IFS=$as_save_IFS | |
19543 | ||
19544 | ;; | |
19545 | esac | |
19546 | # We did not find ourselves, most probably we were run as `sh COMMAND' | |
19547 | # in which case we are not to be found in the path. | |
19548 | if test "x$as_myself" = x; then | |
19549 | as_myself=$0 | |
19550 | fi | |
19551 | if test ! -f "$as_myself"; then | |
19552 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 | |
19553 | exit 1 | |
19554 | fi | |
19555 | ||
19556 | # Unset variables that we do not need and which cause bugs (e.g. in | |
19557 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" | |
19558 | # suppresses any "Segmentation fault" message there. '((' could | |
19559 | # trigger a bug in pdksh 5.2.14. | |
19560 | for as_var in BASH_ENV ENV MAIL MAILPATH | |
19561 | do eval test x\${$as_var+set} = xset \ | |
19562 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : | |
19563 | done | |
19564 | PS1='$ ' | |
19565 | PS2='> ' | |
19566 | PS4='+ ' | |
19567 | ||
19568 | # NLS nuisances. | |
19569 | LC_ALL=C | |
19570 | export LC_ALL | |
19571 | LANGUAGE=C | |
19572 | export LANGUAGE | |
19573 | ||
19574 | # CDPATH. | |
19575 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH | |
19576 | ||
19577 | ||
2018939f AS |
19578 | # as_fn_error STATUS ERROR [LINENO LOG_FD] |
19579 | # ---------------------------------------- | |
067d23c9 KY |
19580 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
19581 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the | |
2018939f | 19582 | # script with STATUS, using 1 if that was 0. |
067d23c9 KY |
19583 | as_fn_error () |
19584 | { | |
2018939f AS |
19585 | as_status=$1; test $as_status -eq 0 && as_status=1 |
19586 | if test "$4"; then | |
19587 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
19588 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 | |
067d23c9 | 19589 | fi |
2018939f | 19590 | $as_echo "$as_me: error: $2" >&2 |
067d23c9 KY |
19591 | as_fn_exit $as_status |
19592 | } # as_fn_error | |
19593 | ||
19594 | ||
19595 | # as_fn_set_status STATUS | |
19596 | # ----------------------- | |
19597 | # Set $? to STATUS, without forking. | |
19598 | as_fn_set_status () | |
19599 | { | |
19600 | return $1 | |
19601 | } # as_fn_set_status | |
19602 | ||
19603 | # as_fn_exit STATUS | |
19604 | # ----------------- | |
19605 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. | |
19606 | as_fn_exit () | |
19607 | { | |
19608 | set +e | |
19609 | as_fn_set_status $1 | |
19610 | exit $1 | |
19611 | } # as_fn_exit | |
19612 | ||
19613 | # as_fn_unset VAR | |
19614 | # --------------- | |
19615 | # Portably unset VAR. | |
19616 | as_fn_unset () | |
19617 | { | |
19618 | { eval $1=; unset $1;} | |
19619 | } | |
19620 | as_unset=as_fn_unset | |
19621 | # as_fn_append VAR VALUE | |
19622 | # ---------------------- | |
19623 | # Append the text in VALUE to the end of the definition contained in VAR. Take | |
19624 | # advantage of any shell optimizations that allow amortized linear growth over | |
19625 | # repeated appends, instead of the typical quadratic growth present in naive | |
19626 | # implementations. | |
19627 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : | |
19628 | eval 'as_fn_append () | |
19629 | { | |
19630 | eval $1+=\$2 | |
19631 | }' | |
19632 | else | |
19633 | as_fn_append () | |
19634 | { | |
19635 | eval $1=\$$1\$2 | |
19636 | } | |
19637 | fi # as_fn_append | |
19638 | ||
19639 | # as_fn_arith ARG... | |
19640 | # ------------------ | |
19641 | # Perform arithmetic evaluation on the ARGs, and store the result in the | |
19642 | # global $as_val. Take advantage of shells that can avoid forks. The arguments | |
19643 | # must be portable across $(()) and expr. | |
19644 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : | |
19645 | eval 'as_fn_arith () | |
19646 | { | |
19647 | as_val=$(( $* )) | |
19648 | }' | |
19649 | else | |
19650 | as_fn_arith () | |
19651 | { | |
19652 | as_val=`expr "$@" || test $? -eq 1` | |
19653 | } | |
19654 | fi # as_fn_arith | |
19655 | ||
19656 | ||
19657 | if expr a : '\(a\)' >/dev/null 2>&1 && | |
19658 | test "X`expr 00001 : '.*\(...\)'`" = X001; then | |
19659 | as_expr=expr | |
19660 | else | |
19661 | as_expr=false | |
19662 | fi | |
19663 | ||
19664 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then | |
19665 | as_basename=basename | |
19666 | else | |
19667 | as_basename=false | |
19668 | fi | |
19669 | ||
19670 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then | |
19671 | as_dirname=dirname | |
19672 | else | |
19673 | as_dirname=false | |
19674 | fi | |
19675 | ||
19676 | as_me=`$as_basename -- "$0" || | |
19677 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ | |
19678 | X"$0" : 'X\(//\)$' \| \ | |
19679 | X"$0" : 'X\(/\)' \| . 2>/dev/null || | |
19680 | $as_echo X/"$0" | | |
19681 | sed '/^.*\/\([^/][^/]*\)\/*$/{ | |
19682 | s//\1/ | |
19683 | q | |
19684 | } | |
19685 | /^X\/\(\/\/\)$/{ | |
19686 | s//\1/ | |
19687 | q | |
19688 | } | |
19689 | /^X\/\(\/\).*/{ | |
19690 | s//\1/ | |
19691 | q | |
19692 | } | |
19693 | s/.*/./; q'` | |
19694 | ||
19695 | # Avoid depending upon Character Ranges. | |
19696 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' | |
19697 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' | |
19698 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS | |
19699 | as_cr_digits='0123456789' | |
19700 | as_cr_alnum=$as_cr_Letters$as_cr_digits | |
19701 | ||
19702 | ECHO_C= ECHO_N= ECHO_T= | |
19703 | case `echo -n x` in #((((( | |
19704 | -n*) | |
19705 | case `echo 'xy\c'` in | |
19706 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. | |
19707 | xy) ECHO_C='\c';; | |
19708 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null | |
19709 | ECHO_T=' ';; | |
19710 | esac;; | |
19711 | *) | |
19712 | ECHO_N='-n';; | |
19713 | esac | |
19714 | ||
19715 | rm -f conf$$ conf$$.exe conf$$.file | |
19716 | if test -d conf$$.dir; then | |
19717 | rm -f conf$$.dir/conf$$.file | |
19718 | else | |
19719 | rm -f conf$$.dir | |
19720 | mkdir conf$$.dir 2>/dev/null | |
19721 | fi | |
19722 | if (echo >conf$$.file) 2>/dev/null; then | |
19723 | if ln -s conf$$.file conf$$ 2>/dev/null; then | |
19724 | as_ln_s='ln -s' | |
19725 | # ... but there are two gotchas: | |
19726 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. | |
19727 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. | |
19728 | # In both cases, we have to default to `cp -p'. | |
19729 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || | |
19730 | as_ln_s='cp -p' | |
19731 | elif ln conf$$.file conf$$ 2>/dev/null; then | |
19732 | as_ln_s=ln | |
19733 | else | |
19734 | as_ln_s='cp -p' | |
19735 | fi | |
19736 | else | |
19737 | as_ln_s='cp -p' | |
19738 | fi | |
19739 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file | |
19740 | rmdir conf$$.dir 2>/dev/null | |
19741 | ||
19742 | ||
19743 | # as_fn_mkdir_p | |
19744 | # ------------- | |
19745 | # Create "$as_dir" as a directory, including parents if necessary. | |
19746 | as_fn_mkdir_p () | |
19747 | { | |
19748 | ||
19749 | case $as_dir in #( | |
19750 | -*) as_dir=./$as_dir;; | |
19751 | esac | |
19752 | test -d "$as_dir" || eval $as_mkdir_p || { | |
19753 | as_dirs= | |
19754 | while :; do | |
19755 | case $as_dir in #( | |
19756 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( | |
19757 | *) as_qdir=$as_dir;; | |
19758 | esac | |
19759 | as_dirs="'$as_qdir' $as_dirs" | |
19760 | as_dir=`$as_dirname -- "$as_dir" || | |
19761 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
19762 | X"$as_dir" : 'X\(//\)[^/]' \| \ | |
19763 | X"$as_dir" : 'X\(//\)$' \| \ | |
19764 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || | |
19765 | $as_echo X"$as_dir" | | |
19766 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
19767 | s//\1/ | |
19768 | q | |
19769 | } | |
19770 | /^X\(\/\/\)[^/].*/{ | |
19771 | s//\1/ | |
19772 | q | |
19773 | } | |
19774 | /^X\(\/\/\)$/{ | |
19775 | s//\1/ | |
19776 | q | |
19777 | } | |
19778 | /^X\(\/\).*/{ | |
19779 | s//\1/ | |
19780 | q | |
19781 | } | |
19782 | s/.*/./; q'` | |
19783 | test -d "$as_dir" && break | |
19784 | done | |
19785 | test -z "$as_dirs" || eval "mkdir $as_dirs" | |
2018939f | 19786 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" |
067d23c9 KY |
19787 | |
19788 | ||
19789 | } # as_fn_mkdir_p | |
19790 | if mkdir -p . 2>/dev/null; then | |
19791 | as_mkdir_p='mkdir -p "$as_dir"' | |
19792 | else | |
19793 | test -d ./-p && rmdir ./-p | |
19794 | as_mkdir_p=false | |
19795 | fi | |
19796 | ||
19797 | if test -x / >/dev/null 2>&1; then | |
19798 | as_test_x='test -x' | |
19799 | else | |
19800 | if ls -dL / >/dev/null 2>&1; then | |
19801 | as_ls_L_option=L | |
19802 | else | |
19803 | as_ls_L_option= | |
19804 | fi | |
19805 | as_test_x=' | |
19806 | eval sh -c '\'' | |
19807 | if test -d "$1"; then | |
19808 | test -d "$1/."; | |
19809 | else | |
19810 | case $1 in #( | |
19811 | -*)set "./$1";; | |
19812 | esac; | |
19813 | case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( | |
19814 | ???[sx]*):;;*)false;;esac;fi | |
19815 | '\'' sh | |
19816 | ' | |
19817 | fi | |
19818 | as_executable_p=$as_test_x | |
19819 | ||
19820 | # Sed expression to map a string onto a valid CPP name. | |
19821 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" | |
19822 | ||
19823 | # Sed expression to map a string onto a valid variable name. | |
19824 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" | |
19825 | ||
19826 | ||
19827 | exec 6>&1 | |
19828 | ## ----------------------------------- ## | |
19829 | ## Main body of $CONFIG_STATUS script. ## | |
19830 | ## ----------------------------------- ## | |
19831 | _ASEOF | |
19832 | test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 | |
19833 | ||
19834 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
19835 | # Save the log message, to keep $0 and so on meaningful, and to | |
19836 | # report actual input values of CONFIG_FILES etc. instead of their | |
19837 | # values after options handling. | |
19838 | ac_log=" | |
19839 | This file was extended by emacs $as_me 24.0.50, which was | |
d6974efa | 19840 | generated by GNU Autoconf 2.68. Invocation command line was |
067d23c9 KY |
19841 | |
19842 | CONFIG_FILES = $CONFIG_FILES | |
19843 | CONFIG_HEADERS = $CONFIG_HEADERS | |
19844 | CONFIG_LINKS = $CONFIG_LINKS | |
19845 | CONFIG_COMMANDS = $CONFIG_COMMANDS | |
19846 | $ $0 $@ | |
19847 | ||
19848 | on `(hostname || uname -n) 2>/dev/null | sed 1q` | |
19849 | " | |
19850 | ||
19851 | _ACEOF | |
19852 | ||
19853 | case $ac_config_files in *" | |
19854 | "*) set x $ac_config_files; shift; ac_config_files=$*;; | |
19855 | esac | |
19856 | ||
19857 | case $ac_config_headers in *" | |
19858 | "*) set x $ac_config_headers; shift; ac_config_headers=$*;; | |
19859 | esac | |
19860 | ||
19861 | ||
19862 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
19863 | # Files that config.status was made for. | |
19864 | config_files="$ac_config_files" | |
19865 | config_headers="$ac_config_headers" | |
19866 | config_commands="$ac_config_commands" | |
19867 | ||
19868 | _ACEOF | |
19869 | ||
19870 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
19871 | ac_cs_usage="\ | |
19872 | \`$as_me' instantiates files and other configuration actions | |
19873 | from templates according to the current configuration. Unless the files | |
19874 | and actions are specified as TAGs, all are instantiated by default. | |
19875 | ||
19876 | Usage: $0 [OPTION]... [TAG]... | |
19877 | ||
19878 | -h, --help print this help, then exit | |
19879 | -V, --version print version number and configuration settings, then exit | |
19880 | --config print configuration, then exit | |
19881 | -q, --quiet, --silent | |
19882 | do not print progress messages | |
19883 | -d, --debug don't remove temporary files | |
19884 | --recheck update $as_me by reconfiguring in the same conditions | |
19885 | --file=FILE[:TEMPLATE] | |
19886 | instantiate the configuration file FILE | |
19887 | --header=FILE[:TEMPLATE] | |
19888 | instantiate the configuration header FILE | |
19889 | ||
19890 | Configuration files: | |
19891 | $config_files | |
19892 | ||
19893 | Configuration headers: | |
19894 | $config_headers | |
19895 | ||
19896 | Configuration commands: | |
19897 | $config_commands | |
19898 | ||
19899 | Report bugs to the package provider." | |
19900 | ||
19901 | _ACEOF | |
19902 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
19903 | ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" | |
19904 | ac_cs_version="\\ | |
19905 | emacs config.status 24.0.50 | |
d6974efa | 19906 | configured by $0, generated by GNU Autoconf 2.68, |
067d23c9 KY |
19907 | with options \\"\$ac_cs_config\\" |
19908 | ||
2018939f | 19909 | Copyright (C) 2010 Free Software Foundation, Inc. |
067d23c9 KY |
19910 | This config.status script is free software; the Free Software Foundation |
19911 | gives unlimited permission to copy, distribute and modify it." | |
19912 | ||
19913 | ac_pwd='$ac_pwd' | |
19914 | srcdir='$srcdir' | |
19915 | INSTALL='$INSTALL' | |
743c80a7 PE |
19916 | MKDIR_P='$MKDIR_P' |
19917 | AWK='$AWK' | |
067d23c9 KY |
19918 | test -n "\$AWK" || AWK=awk |
19919 | _ACEOF | |
19920 | ||
19921 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
19922 | # The default lists apply if the user does not specify any file. | |
19923 | ac_need_defaults=: | |
19924 | while test $# != 0 | |
19925 | do | |
19926 | case $1 in | |
2018939f | 19927 | --*=?*) |
067d23c9 KY |
19928 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
19929 | ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` | |
19930 | ac_shift=: | |
19931 | ;; | |
2018939f AS |
19932 | --*=) |
19933 | ac_option=`expr "X$1" : 'X\([^=]*\)='` | |
19934 | ac_optarg= | |
19935 | ac_shift=: | |
19936 | ;; | |
067d23c9 KY |
19937 | *) |
19938 | ac_option=$1 | |
19939 | ac_optarg=$2 | |
19940 | ac_shift=shift | |
19941 | ;; | |
19942 | esac | |
19943 | ||
19944 | case $ac_option in | |
19945 | # Handling of the options. | |
19946 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) | |
19947 | ac_cs_recheck=: ;; | |
19948 | --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) | |
19949 | $as_echo "$ac_cs_version"; exit ;; | |
19950 | --config | --confi | --conf | --con | --co | --c ) | |
19951 | $as_echo "$ac_cs_config"; exit ;; | |
19952 | --debug | --debu | --deb | --de | --d | -d ) | |
19953 | debug=: ;; | |
19954 | --file | --fil | --fi | --f ) | |
19955 | $ac_shift | |
19956 | case $ac_optarg in | |
19957 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
2018939f | 19958 | '') as_fn_error $? "missing file argument" ;; |
067d23c9 KY |
19959 | esac |
19960 | as_fn_append CONFIG_FILES " '$ac_optarg'" | |
19961 | ac_need_defaults=false;; | |
19962 | --header | --heade | --head | --hea ) | |
19963 | $ac_shift | |
19964 | case $ac_optarg in | |
19965 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
19966 | esac | |
19967 | as_fn_append CONFIG_HEADERS " '$ac_optarg'" | |
19968 | ac_need_defaults=false;; | |
19969 | --he | --h) | |
19970 | # Conflict between --help and --header | |
2018939f | 19971 | as_fn_error $? "ambiguous option: \`$1' |
067d23c9 KY |
19972 | Try \`$0 --help' for more information.";; |
19973 | --help | --hel | -h ) | |
19974 | $as_echo "$ac_cs_usage"; exit ;; | |
19975 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | |
19976 | | -silent | --silent | --silen | --sile | --sil | --si | --s) | |
19977 | ac_cs_silent=: ;; | |
19978 | ||
19979 | # This is an error. | |
2018939f | 19980 | -*) as_fn_error $? "unrecognized option: \`$1' |
067d23c9 KY |
19981 | Try \`$0 --help' for more information." ;; |
19982 | ||
19983 | *) as_fn_append ac_config_targets " $1" | |
19984 | ac_need_defaults=false ;; | |
19985 | ||
19986 | esac | |
19987 | shift | |
19988 | done | |
19989 | ||
19990 | ac_configure_extra_args= | |
19991 | ||
19992 | if $ac_cs_silent; then | |
19993 | exec 6>/dev/null | |
19994 | ac_configure_extra_args="$ac_configure_extra_args --silent" | |
19995 | fi | |
19996 | ||
19997 | _ACEOF | |
19998 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
19999 | if \$ac_cs_recheck; then | |
20000 | set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion | |
20001 | shift | |
20002 | \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 | |
20003 | CONFIG_SHELL='$SHELL' | |
20004 | export CONFIG_SHELL | |
20005 | exec "\$@" | |
20006 | fi | |
20007 | ||
20008 | _ACEOF | |
20009 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
20010 | exec 5>>config.log | |
20011 | { | |
20012 | echo | |
20013 | sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX | |
20014 | ## Running $as_me. ## | |
20015 | _ASBOX | |
20016 | $as_echo "$ac_log" | |
20017 | } >&5 | |
20018 | ||
20019 | _ACEOF | |
20020 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
20021 | # | |
20022 | # INIT-COMMANDS | |
20023 | # | |
743c80a7 | 20024 | AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" |
067d23c9 KY |
20025 | GCC="$GCC" NON_GNU_CPP="$NON_GNU_CPP" CPP="$CPP" CPPFLAGS="$CPPFLAGS" |
20026 | ||
20027 | _ACEOF | |
20028 | ||
20029 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
20030 | ||
20031 | # Handling of arguments. | |
20032 | for ac_config_target in $ac_config_targets | |
20033 | do | |
20034 | case $ac_config_target in | |
20035 | "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;; | |
743c80a7 | 20036 | "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; |
067d23c9 | 20037 | "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; |
743c80a7 | 20038 | "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;; |
067d23c9 KY |
20039 | "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;; |
20040 | "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;; | |
20041 | "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;; | |
20042 | "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;; | |
20043 | "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;; | |
20044 | "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;; | |
20045 | "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;; | |
20046 | "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;; | |
20047 | "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;; | |
20048 | "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;; | |
ea062854 | 20049 | "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;; |
067d23c9 KY |
20050 | "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;; |
20051 | ||
d6974efa | 20052 | *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; |
067d23c9 KY |
20053 | esac |
20054 | done | |
20055 | ||
20056 | ||
20057 | # If the user did not use the arguments to specify the items to instantiate, | |
20058 | # then the envvar interface is used. Set only those that are not. | |
20059 | # We use the long form for the default assignment because of an extremely | |
20060 | # bizarre bug on SunOS 4.1.3. | |
20061 | if $ac_need_defaults; then | |
20062 | test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files | |
20063 | test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers | |
20064 | test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands | |
20065 | fi | |
20066 | ||
20067 | # Have a temporary directory for convenience. Make it in the build tree | |
20068 | # simply because there is no reason against having it here, and in addition, | |
20069 | # creating and moving files from /tmp can sometimes cause problems. | |
20070 | # Hook for its removal unless debugging. | |
20071 | # Note that there is a small window in which the directory will not be cleaned: | |
20072 | # after its creation but before its name has been assigned to `$tmp'. | |
20073 | $debug || | |
20074 | { | |
d6974efa | 20075 | tmp= ac_tmp= |
067d23c9 | 20076 | trap 'exit_status=$? |
d6974efa PE |
20077 | : "${ac_tmp:=$tmp}" |
20078 | { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status | |
067d23c9 KY |
20079 | ' 0 |
20080 | trap 'as_fn_exit 1' 1 2 13 15 | |
20081 | } | |
20082 | # Create a (secure) tmp directory for tmp files. | |
20083 | ||
20084 | { | |
20085 | tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && | |
d6974efa | 20086 | test -d "$tmp" |
067d23c9 KY |
20087 | } || |
20088 | { | |
20089 | tmp=./conf$$-$RANDOM | |
20090 | (umask 077 && mkdir "$tmp") | |
2018939f | 20091 | } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 |
d6974efa | 20092 | ac_tmp=$tmp |
067d23c9 KY |
20093 | |
20094 | # Set up the scripts for CONFIG_FILES section. | |
20095 | # No need to generate them if there are no CONFIG_FILES. | |
20096 | # This happens for instance with `./config.status config.h'. | |
20097 | if test -n "$CONFIG_FILES"; then | |
20098 | ||
20099 | if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then | |
20100 | ac_cs_awk_getline=: | |
20101 | ac_cs_awk_pipe_init= | |
20102 | ac_cs_awk_read_file=' | |
20103 | while ((getline aline < (F[key])) > 0) | |
20104 | print(aline) | |
20105 | close(F[key])' | |
20106 | ac_cs_awk_pipe_fini= | |
20107 | else | |
20108 | ac_cs_awk_getline=false | |
20109 | ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\"" | |
20110 | ac_cs_awk_read_file=' | |
20111 | print "|#_!!_#|" | |
20112 | print "cat " F[key] " &&" | |
20113 | '$ac_cs_awk_pipe_init | |
20114 | # The final `:' finishes the AND list. | |
20115 | ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }' | |
20116 | fi | |
20117 | ac_cr=`echo X | tr X '\015'` | |
20118 | # On cygwin, bash can eat \r inside `` if the user requested igncr. | |
20119 | # But we know of no other shell where ac_cr would be empty at this | |
20120 | # point, so we can use a bashism as a fallback. | |
20121 | if test "x$ac_cr" = x; then | |
20122 | eval ac_cr=\$\'\\r\' | |
20123 | fi | |
20124 | ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` | |
20125 | if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then | |
2018939f | 20126 | ac_cs_awk_cr='\\r' |
067d23c9 KY |
20127 | else |
20128 | ac_cs_awk_cr=$ac_cr | |
20129 | fi | |
20130 | ||
d6974efa | 20131 | echo 'BEGIN {' >"$ac_tmp/subs1.awk" && |
067d23c9 KY |
20132 | _ACEOF |
20133 | ||
20134 | # Create commands to substitute file output variables. | |
20135 | { | |
20136 | echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" && | |
d6974efa | 20137 | echo 'cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&' && |
067d23c9 KY |
20138 | echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' && |
20139 | echo "_ACAWK" && | |
20140 | echo "_ACEOF" | |
20141 | } >conf$$files.sh && | |
20142 | . ./conf$$files.sh || | |
2018939f | 20143 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
067d23c9 KY |
20144 | rm -f conf$$files.sh |
20145 | ||
20146 | { | |
20147 | echo "cat >conf$$subs.awk <<_ACEOF" && | |
20148 | echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && | |
20149 | echo "_ACEOF" | |
20150 | } >conf$$subs.sh || | |
2018939f AS |
20151 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
20152 | ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` | |
067d23c9 KY |
20153 | ac_delim='%!_!# ' |
20154 | for ac_last_try in false false false false false :; do | |
20155 | . ./conf$$subs.sh || | |
2018939f | 20156 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
067d23c9 KY |
20157 | |
20158 | ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` | |
20159 | if test $ac_delim_n = $ac_delim_num; then | |
20160 | break | |
20161 | elif $ac_last_try; then | |
2018939f | 20162 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
067d23c9 KY |
20163 | else |
20164 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " | |
20165 | fi | |
20166 | done | |
20167 | rm -f conf$$subs.sh | |
20168 | ||
20169 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
d6974efa | 20170 | cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && |
067d23c9 KY |
20171 | _ACEOF |
20172 | sed -n ' | |
20173 | h | |
20174 | s/^/S["/; s/!.*/"]=/ | |
20175 | p | |
20176 | g | |
20177 | s/^[^!]*!// | |
20178 | :repl | |
20179 | t repl | |
20180 | s/'"$ac_delim"'$// | |
20181 | t delim | |
20182 | :nl | |
20183 | h | |
20184 | s/\(.\{148\}\)..*/\1/ | |
20185 | t more1 | |
20186 | s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ | |
20187 | p | |
20188 | n | |
20189 | b repl | |
20190 | :more1 | |
20191 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ | |
20192 | p | |
20193 | g | |
20194 | s/.\{148\}// | |
20195 | t nl | |
20196 | :delim | |
20197 | h | |
20198 | s/\(.\{148\}\)..*/\1/ | |
20199 | t more2 | |
20200 | s/["\\]/\\&/g; s/^/"/; s/$/"/ | |
20201 | p | |
20202 | b | |
20203 | :more2 | |
20204 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ | |
20205 | p | |
20206 | g | |
20207 | s/.\{148\}// | |
20208 | t delim | |
20209 | ' <conf$$subs.awk | sed ' | |
20210 | /^[^""]/{ | |
20211 | N | |
20212 | s/\n// | |
20213 | } | |
20214 | ' >>$CONFIG_STATUS || ac_write_fail=1 | |
20215 | rm -f conf$$subs.awk | |
20216 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
20217 | _ACAWK | |
d6974efa | 20218 | cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && |
067d23c9 KY |
20219 | for (key in S) S_is_set[key] = 1 |
20220 | FS = "\a" | |
20221 | \$ac_cs_awk_pipe_init | |
20222 | } | |
20223 | { | |
20224 | line = $ 0 | |
20225 | nfields = split(line, field, "@") | |
20226 | substed = 0 | |
20227 | len = length(field[1]) | |
20228 | for (i = 2; i < nfields; i++) { | |
20229 | key = field[i] | |
20230 | keylen = length(key) | |
20231 | if (S_is_set[key]) { | |
20232 | value = S[key] | |
20233 | line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) | |
20234 | len += length(value) + length(field[++i]) | |
20235 | substed = 1 | |
20236 | } else | |
20237 | len += 1 + keylen | |
20238 | } | |
20239 | if (nfields == 3 && !substed) { | |
20240 | key = field[2] | |
20241 | if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) { | |
20242 | \$ac_cs_awk_read_file | |
20243 | next | |
20244 | } | |
20245 | } | |
20246 | print line | |
20247 | } | |
20248 | \$ac_cs_awk_pipe_fini | |
20249 | _ACAWK | |
20250 | _ACEOF | |
20251 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
20252 | if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then | |
20253 | sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" | |
20254 | else | |
20255 | cat | |
d6974efa | 20256 | fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ |
2018939f | 20257 | || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 |
067d23c9 KY |
20258 | _ACEOF |
20259 | ||
2018939f AS |
20260 | # VPATH may cause trouble with some makes, so we remove sole $(srcdir), |
20261 | # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and | |
067d23c9 KY |
20262 | # trailing colons and then remove the whole line if VPATH becomes empty |
20263 | # (actually we leave an empty line to preserve line numbers). | |
20264 | if test "x$srcdir" = x.; then | |
2018939f AS |
20265 | ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ |
20266 | h | |
20267 | s/// | |
20268 | s/^/:/ | |
20269 | s/[ ]*$/:/ | |
20270 | s/:\$(srcdir):/:/g | |
20271 | s/:\${srcdir}:/:/g | |
20272 | s/:@srcdir@:/:/g | |
20273 | s/^:*// | |
067d23c9 | 20274 | s/:*$// |
2018939f AS |
20275 | x |
20276 | s/\(=[ ]*\).*/\1/ | |
20277 | G | |
20278 | s/\n// | |
067d23c9 KY |
20279 | s/^[^=]*=[ ]*$// |
20280 | }' | |
20281 | fi | |
20282 | ||
20283 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
20284 | fi # test -n "$CONFIG_FILES" | |
20285 | ||
20286 | # Set up the scripts for CONFIG_HEADERS section. | |
20287 | # No need to generate them if there are no CONFIG_HEADERS. | |
20288 | # This happens for instance with `./config.status Makefile'. | |
20289 | if test -n "$CONFIG_HEADERS"; then | |
d6974efa | 20290 | cat >"$ac_tmp/defines.awk" <<\_ACAWK || |
067d23c9 KY |
20291 | BEGIN { |
20292 | _ACEOF | |
20293 | ||
20294 | # Transform confdefs.h into an awk script `defines.awk', embedded as | |
20295 | # here-document in config.status, that substitutes the proper values into | |
20296 | # config.h.in to produce config.h. | |
20297 | ||
20298 | # Create a delimiter string that does not exist in confdefs.h, to ease | |
20299 | # handling of long lines. | |
20300 | ac_delim='%!_!# ' | |
20301 | for ac_last_try in false false :; do | |
d6974efa PE |
20302 | ac_tt=`sed -n "/$ac_delim/p" confdefs.h` |
20303 | if test -z "$ac_tt"; then | |
067d23c9 KY |
20304 | break |
20305 | elif $ac_last_try; then | |
2018939f | 20306 | as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 |
067d23c9 KY |
20307 | else |
20308 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " | |
20309 | fi | |
20310 | done | |
20311 | ||
20312 | # For the awk script, D is an array of macro values keyed by name, | |
20313 | # likewise P contains macro parameters if any. Preserve backslash | |
20314 | # newline sequences. | |
20315 | ||
20316 | ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* | |
20317 | sed -n ' | |
20318 | s/.\{148\}/&'"$ac_delim"'/g | |
20319 | t rset | |
20320 | :rset | |
20321 | s/^[ ]*#[ ]*define[ ][ ]*/ / | |
20322 | t def | |
20323 | d | |
20324 | :def | |
20325 | s/\\$// | |
20326 | t bsnl | |
20327 | s/["\\]/\\&/g | |
20328 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ | |
20329 | D["\1"]=" \3"/p | |
20330 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p | |
20331 | d | |
20332 | :bsnl | |
20333 | s/["\\]/\\&/g | |
20334 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ | |
20335 | D["\1"]=" \3\\\\\\n"\\/p | |
20336 | t cont | |
20337 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p | |
20338 | t cont | |
20339 | d | |
20340 | :cont | |
20341 | n | |
20342 | s/.\{148\}/&'"$ac_delim"'/g | |
20343 | t clear | |
20344 | :clear | |
20345 | s/\\$// | |
20346 | t bsnlc | |
20347 | s/["\\]/\\&/g; s/^/"/; s/$/"/p | |
20348 | d | |
20349 | :bsnlc | |
20350 | s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p | |
20351 | b cont | |
20352 | ' <confdefs.h | sed ' | |
20353 | s/'"$ac_delim"'/"\\\ | |
20354 | "/g' >>$CONFIG_STATUS || ac_write_fail=1 | |
20355 | ||
20356 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
20357 | for (key in D) D_is_set[key] = 1 | |
20358 | FS = "\a" | |
20359 | } | |
20360 | /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { | |
20361 | line = \$ 0 | |
20362 | split(line, arg, " ") | |
20363 | if (arg[1] == "#") { | |
20364 | defundef = arg[2] | |
20365 | mac1 = arg[3] | |
20366 | } else { | |
20367 | defundef = substr(arg[1], 2) | |
20368 | mac1 = arg[2] | |
20369 | } | |
20370 | split(mac1, mac2, "(") #) | |
20371 | macro = mac2[1] | |
20372 | prefix = substr(line, 1, index(line, defundef) - 1) | |
20373 | if (D_is_set[macro]) { | |
20374 | # Preserve the white space surrounding the "#". | |
20375 | print prefix "define", macro P[macro] D[macro] | |
20376 | next | |
20377 | } else { | |
20378 | # Replace #undef with comments. This is necessary, for example, | |
20379 | # in the case of _POSIX_SOURCE, which is predefined and required | |
20380 | # on some systems where configure will not decide to define it. | |
20381 | if (defundef == "undef") { | |
20382 | print "/*", prefix defundef, macro, "*/" | |
20383 | next | |
20384 | } | |
20385 | } | |
20386 | } | |
20387 | { print } | |
20388 | _ACAWK | |
20389 | _ACEOF | |
20390 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
2018939f | 20391 | as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 |
067d23c9 KY |
20392 | fi # test -n "$CONFIG_HEADERS" |
20393 | ||
20394 | ||
20395 | eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" | |
20396 | shift | |
20397 | for ac_tag | |
20398 | do | |
20399 | case $ac_tag in | |
20400 | :[FHLC]) ac_mode=$ac_tag; continue;; | |
20401 | esac | |
20402 | case $ac_mode$ac_tag in | |
20403 | :[FHL]*:*);; | |
d6974efa | 20404 | :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; |
067d23c9 KY |
20405 | :[FH]-) ac_tag=-:-;; |
20406 | :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; | |
20407 | esac | |
20408 | ac_save_IFS=$IFS | |
20409 | IFS=: | |
20410 | set x $ac_tag | |
20411 | IFS=$ac_save_IFS | |
20412 | shift | |
20413 | ac_file=$1 | |
20414 | shift | |
20415 | ||
20416 | case $ac_mode in | |
20417 | :L) ac_source=$1;; | |
20418 | :[FH]) | |
20419 | ac_file_inputs= | |
20420 | for ac_f | |
20421 | do | |
20422 | case $ac_f in | |
d6974efa | 20423 | -) ac_f="$ac_tmp/stdin";; |
067d23c9 KY |
20424 | *) # Look for the file first in the build tree, then in the source tree |
20425 | # (if the path is not absolute). The absolute path cannot be DOS-style, | |
20426 | # because $ac_f cannot contain `:'. | |
20427 | test -f "$ac_f" || | |
20428 | case $ac_f in | |
20429 | [\\/$]*) false;; | |
20430 | *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; | |
20431 | esac || | |
d6974efa | 20432 | as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; |
067d23c9 KY |
20433 | esac |
20434 | case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac | |
20435 | as_fn_append ac_file_inputs " '$ac_f'" | |
20436 | done | |
20437 | ||
20438 | # Let's still pretend it is `configure' which instantiates (i.e., don't | |
20439 | # use $as_me), people would be surprised to read: | |
20440 | # /* config.h. Generated by config.status. */ | |
20441 | configure_input='Generated from '` | |
20442 | $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' | |
20443 | `' by configure.' | |
20444 | if test x"$ac_file" != x-; then | |
20445 | configure_input="$ac_file. $configure_input" | |
20446 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 | |
20447 | $as_echo "$as_me: creating $ac_file" >&6;} | |
20448 | fi | |
20449 | # Neutralize special characters interpreted by sed in replacement strings. | |
20450 | case $configure_input in #( | |
20451 | *\&* | *\|* | *\\* ) | |
20452 | ac_sed_conf_input=`$as_echo "$configure_input" | | |
20453 | sed 's/[\\\\&|]/\\\\&/g'`;; #( | |
20454 | *) ac_sed_conf_input=$configure_input;; | |
20455 | esac | |
20456 | ||
20457 | case $ac_tag in | |
d6974efa PE |
20458 | *:-:* | *:-) cat >"$ac_tmp/stdin" \ |
20459 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; | |
067d23c9 KY |
20460 | esac |
20461 | ;; | |
20462 | esac | |
20463 | ||
20464 | ac_dir=`$as_dirname -- "$ac_file" || | |
20465 | $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
20466 | X"$ac_file" : 'X\(//\)[^/]' \| \ | |
20467 | X"$ac_file" : 'X\(//\)$' \| \ | |
20468 | X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || | |
20469 | $as_echo X"$ac_file" | | |
20470 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
20471 | s//\1/ | |
20472 | q | |
20473 | } | |
20474 | /^X\(\/\/\)[^/].*/{ | |
20475 | s//\1/ | |
20476 | q | |
20477 | } | |
20478 | /^X\(\/\/\)$/{ | |
20479 | s//\1/ | |
20480 | q | |
20481 | } | |
20482 | /^X\(\/\).*/{ | |
20483 | s//\1/ | |
20484 | q | |
20485 | } | |
20486 | s/.*/./; q'` | |
20487 | as_dir="$ac_dir"; as_fn_mkdir_p | |
20488 | ac_builddir=. | |
20489 | ||
20490 | case "$ac_dir" in | |
20491 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
20492 | *) | |
20493 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` | |
20494 | # A ".." for each directory in $ac_dir_suffix. | |
20495 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` | |
20496 | case $ac_top_builddir_sub in | |
20497 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
20498 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; | |
20499 | esac ;; | |
20500 | esac | |
20501 | ac_abs_top_builddir=$ac_pwd | |
20502 | ac_abs_builddir=$ac_pwd$ac_dir_suffix | |
20503 | # for backward compatibility: | |
20504 | ac_top_builddir=$ac_top_build_prefix | |
20505 | ||
20506 | case $srcdir in | |
20507 | .) # We are building in place. | |
20508 | ac_srcdir=. | |
20509 | ac_top_srcdir=$ac_top_builddir_sub | |
20510 | ac_abs_top_srcdir=$ac_pwd ;; | |
20511 | [\\/]* | ?:[\\/]* ) # Absolute name. | |
20512 | ac_srcdir=$srcdir$ac_dir_suffix; | |
20513 | ac_top_srcdir=$srcdir | |
20514 | ac_abs_top_srcdir=$srcdir ;; | |
20515 | *) # Relative name. | |
20516 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix | |
20517 | ac_top_srcdir=$ac_top_build_prefix$srcdir | |
20518 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; | |
20519 | esac | |
20520 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix | |
20521 | ||
20522 | ||
20523 | case $ac_mode in | |
20524 | :F) | |
20525 | # | |
20526 | # CONFIG_FILE | |
20527 | # | |
20528 | ||
20529 | case $INSTALL in | |
20530 | [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; | |
20531 | *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; | |
20532 | esac | |
743c80a7 PE |
20533 | ac_MKDIR_P=$MKDIR_P |
20534 | case $MKDIR_P in | |
20535 | [\\/$]* | ?:[\\/]* ) ;; | |
20536 | */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; | |
20537 | esac | |
067d23c9 KY |
20538 | _ACEOF |
20539 | ||
20540 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
20541 | # If the template does not know about datarootdir, expand it. | |
20542 | # FIXME: This hack should be removed a few years after 2.60. | |
20543 | ac_datarootdir_hack=; ac_datarootdir_seen= | |
20544 | ac_sed_dataroot=' | |
20545 | /datarootdir/ { | |
20546 | p | |
20547 | q | |
20548 | } | |
20549 | /@datadir@/p | |
20550 | /@docdir@/p | |
20551 | /@infodir@/p | |
20552 | /@localedir@/p | |
20553 | /@mandir@/p' | |
20554 | case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in | |
20555 | *datarootdir*) ac_datarootdir_seen=yes;; | |
20556 | *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) | |
20557 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 | |
20558 | $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} | |
20559 | _ACEOF | |
20560 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
20561 | ac_datarootdir_hack=' | |
20562 | s&@datadir@&$datadir&g | |
20563 | s&@docdir@&$docdir&g | |
20564 | s&@infodir@&$infodir&g | |
20565 | s&@localedir@&$localedir&g | |
20566 | s&@mandir@&$mandir&g | |
20567 | s&\\\${datarootdir}&$datarootdir&g' ;; | |
20568 | esac | |
20569 | _ACEOF | |
20570 | ||
20571 | # Neutralize VPATH when `$srcdir' = `.'. | |
20572 | # Shell code in configure.ac might set extrasub. | |
20573 | # FIXME: do we really want to maintain this feature? | |
20574 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
20575 | ac_sed_extra="$ac_vpsub | |
20576 | $extrasub | |
20577 | _ACEOF | |
20578 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
20579 | :t | |
20580 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b | |
20581 | s|@configure_input@|$ac_sed_conf_input|;t t | |
20582 | s&@top_builddir@&$ac_top_builddir_sub&;t t | |
20583 | s&@top_build_prefix@&$ac_top_build_prefix&;t t | |
20584 | s&@srcdir@&$ac_srcdir&;t t | |
20585 | s&@abs_srcdir@&$ac_abs_srcdir&;t t | |
20586 | s&@top_srcdir@&$ac_top_srcdir&;t t | |
20587 | s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t | |
20588 | s&@builddir@&$ac_builddir&;t t | |
20589 | s&@abs_builddir@&$ac_abs_builddir&;t t | |
20590 | s&@abs_top_builddir@&$ac_abs_top_builddir&;t t | |
20591 | s&@INSTALL@&$ac_INSTALL&;t t | |
743c80a7 | 20592 | s&@MKDIR_P@&$ac_MKDIR_P&;t t |
067d23c9 KY |
20593 | $ac_datarootdir_hack |
20594 | " | |
20595 | eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | | |
20596 | if $ac_cs_awk_getline; then | |
d6974efa | 20597 | $AWK -f "$ac_tmp/subs.awk" |
067d23c9 | 20598 | else |
d6974efa PE |
20599 | $AWK -f "$ac_tmp/subs.awk" | $SHELL |
20600 | fi \ | |
20601 | >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 | |
067d23c9 KY |
20602 | |
20603 | test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && | |
d6974efa PE |
20604 | { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && |
20605 | { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ | |
20606 | "$ac_tmp/out"`; test -z "$ac_out"; } && | |
067d23c9 | 20607 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
2018939f | 20608 | which seems to be undefined. Please make sure it is defined" >&5 |
067d23c9 | 20609 | $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
2018939f | 20610 | which seems to be undefined. Please make sure it is defined" >&2;} |
067d23c9 | 20611 | |
d6974efa | 20612 | rm -f "$ac_tmp/stdin" |
067d23c9 | 20613 | case $ac_file in |
d6974efa PE |
20614 | -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; |
20615 | *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; | |
067d23c9 | 20616 | esac \ |
2018939f | 20617 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
067d23c9 KY |
20618 | ;; |
20619 | :H) | |
20620 | # | |
20621 | # CONFIG_HEADER | |
20622 | # | |
20623 | if test x"$ac_file" != x-; then | |
20624 | { | |
20625 | $as_echo "/* $configure_input */" \ | |
d6974efa PE |
20626 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" |
20627 | } >"$ac_tmp/config.h" \ | |
2018939f | 20628 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
d6974efa | 20629 | if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then |
067d23c9 KY |
20630 | { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 |
20631 | $as_echo "$as_me: $ac_file is unchanged" >&6;} | |
20632 | else | |
20633 | rm -f "$ac_file" | |
d6974efa | 20634 | mv "$ac_tmp/config.h" "$ac_file" \ |
2018939f | 20635 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
067d23c9 KY |
20636 | fi |
20637 | else | |
20638 | $as_echo "/* $configure_input */" \ | |
d6974efa | 20639 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ |
2018939f | 20640 | || as_fn_error $? "could not create -" "$LINENO" 5 |
067d23c9 | 20641 | fi |
743c80a7 PE |
20642 | # Compute "$ac_file"'s index in $config_headers. |
20643 | _am_arg="$ac_file" | |
20644 | _am_stamp_count=1 | |
20645 | for _am_header in $config_headers :; do | |
20646 | case $_am_header in | |
20647 | $_am_arg | $_am_arg:* ) | |
20648 | break ;; | |
20649 | * ) | |
20650 | _am_stamp_count=`expr $_am_stamp_count + 1` ;; | |
20651 | esac | |
20652 | done | |
20653 | echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || | |
20654 | $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
20655 | X"$_am_arg" : 'X\(//\)[^/]' \| \ | |
20656 | X"$_am_arg" : 'X\(//\)$' \| \ | |
20657 | X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || | |
20658 | $as_echo X"$_am_arg" | | |
20659 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
20660 | s//\1/ | |
20661 | q | |
20662 | } | |
20663 | /^X\(\/\/\)[^/].*/{ | |
20664 | s//\1/ | |
20665 | q | |
20666 | } | |
20667 | /^X\(\/\/\)$/{ | |
20668 | s//\1/ | |
20669 | q | |
20670 | } | |
20671 | /^X\(\/\).*/{ | |
20672 | s//\1/ | |
20673 | q | |
20674 | } | |
20675 | s/.*/./; q'`/stamp-h$_am_stamp_count | |
067d23c9 KY |
20676 | ;; |
20677 | ||
20678 | :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 | |
20679 | $as_echo "$as_me: executing $ac_file commands" >&6;} | |
20680 | ;; | |
20681 | esac | |
20682 | ||
20683 | ||
20684 | case $ac_file$ac_mode in | |
743c80a7 PE |
20685 | "depfiles":C) test x"$AMDEP_TRUE" != x"" || { |
20686 | # Autoconf 2.62 quotes --file arguments for eval, but not when files | |
20687 | # are listed without --file. Let's play safe and only enable the eval | |
20688 | # if we detect the quoting. | |
20689 | case $CONFIG_FILES in | |
20690 | *\'*) eval set x "$CONFIG_FILES" ;; | |
20691 | *) set x $CONFIG_FILES ;; | |
20692 | esac | |
20693 | shift | |
20694 | for mf | |
20695 | do | |
20696 | # Strip MF so we end up with the name of the file. | |
20697 | mf=`echo "$mf" | sed -e 's/:.*$//'` | |
20698 | # Check whether this is an Automake generated Makefile or not. | |
20699 | # We used to match only the files named `Makefile.in', but | |
20700 | # some people rename them; so instead we look at the file content. | |
20701 | # Grep'ing the first line is not enough: some people post-process | |
20702 | # each Makefile.in and add a new line on top of each file to say so. | |
20703 | # Grep'ing the whole file is not good either: AIX grep has a line | |
20704 | # limit of 2048, but all sed's we know have understand at least 4000. | |
20705 | if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then | |
20706 | dirpart=`$as_dirname -- "$mf" || | |
20707 | $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
20708 | X"$mf" : 'X\(//\)[^/]' \| \ | |
20709 | X"$mf" : 'X\(//\)$' \| \ | |
20710 | X"$mf" : 'X\(/\)' \| . 2>/dev/null || | |
20711 | $as_echo X"$mf" | | |
20712 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
20713 | s//\1/ | |
20714 | q | |
20715 | } | |
20716 | /^X\(\/\/\)[^/].*/{ | |
20717 | s//\1/ | |
20718 | q | |
20719 | } | |
20720 | /^X\(\/\/\)$/{ | |
20721 | s//\1/ | |
20722 | q | |
20723 | } | |
20724 | /^X\(\/\).*/{ | |
20725 | s//\1/ | |
20726 | q | |
20727 | } | |
20728 | s/.*/./; q'` | |
20729 | else | |
20730 | continue | |
20731 | fi | |
20732 | # Extract the definition of DEPDIR, am__include, and am__quote | |
20733 | # from the Makefile without running `make'. | |
20734 | DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` | |
20735 | test -z "$DEPDIR" && continue | |
20736 | am__include=`sed -n 's/^am__include = //p' < "$mf"` | |
20737 | test -z "am__include" && continue | |
20738 | am__quote=`sed -n 's/^am__quote = //p' < "$mf"` | |
20739 | # When using ansi2knr, U may be empty or an underscore; expand it | |
20740 | U=`sed -n 's/^U = //p' < "$mf"` | |
20741 | # Find all dependency output files, they are included files with | |
20742 | # $(DEPDIR) in their names. We invoke sed twice because it is the | |
20743 | # simplest approach to changing $(DEPDIR) to its actual value in the | |
20744 | # expansion. | |
20745 | for file in `sed -n " | |
20746 | s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ | |
20747 | sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do | |
20748 | # Make sure the directory exists. | |
20749 | test -f "$dirpart/$file" && continue | |
20750 | fdir=`$as_dirname -- "$file" || | |
20751 | $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
20752 | X"$file" : 'X\(//\)[^/]' \| \ | |
20753 | X"$file" : 'X\(//\)$' \| \ | |
20754 | X"$file" : 'X\(/\)' \| . 2>/dev/null || | |
20755 | $as_echo X"$file" | | |
20756 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
20757 | s//\1/ | |
20758 | q | |
20759 | } | |
20760 | /^X\(\/\/\)[^/].*/{ | |
20761 | s//\1/ | |
20762 | q | |
20763 | } | |
20764 | /^X\(\/\/\)$/{ | |
20765 | s//\1/ | |
20766 | q | |
20767 | } | |
20768 | /^X\(\/\).*/{ | |
20769 | s//\1/ | |
20770 | q | |
20771 | } | |
20772 | s/.*/./; q'` | |
20773 | as_dir=$dirpart/$fdir; as_fn_mkdir_p | |
20774 | # echo "creating $dirpart/$file" | |
20775 | echo '# dummy' > "$dirpart/$file" | |
20776 | done | |
20777 | done | |
20778 | } | |
20779 | ;; | |
067d23c9 KY |
20780 | "default":C) |
20781 | ||
20782 | ### Make the necessary directories, if they don't exist. | |
20783 | for dir in etc lisp ; do | |
20784 | test -d ${dir} || mkdir ${dir} | |
20785 | done | |
20786 | ||
20787 | echo creating src/epaths.h | |
20788 | ${MAKE-make} epaths-force | |
20789 | ||
20790 | if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then | |
20791 | echo creating src/.gdbinit | |
20792 | echo source $srcdir/src/.gdbinit > src/.gdbinit | |
20793 | fi | |
20794 | ||
20795 | ;; | |
20796 | ||
20797 | esac | |
20798 | done # for ac_tag | |
20799 | ||
20800 | ||
20801 | as_fn_exit 0 | |
20802 | _ACEOF | |
20803 | ac_clean_files=$ac_clean_files_save | |
20804 | ||
20805 | test $ac_write_fail = 0 || | |
2018939f | 20806 | as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 |
067d23c9 KY |
20807 | |
20808 | ||
20809 | # configure is writing to config.log, and then calls config.status. | |
20810 | # config.status does its own redirection, appending to config.log. | |
20811 | # Unfortunately, on DOS this fails, as config.log is still kept open | |
20812 | # by configure, so config.status won't be able to write to it; its | |
20813 | # output is simply discarded. So we exec the FD to /dev/null, | |
20814 | # effectively closing config.log, so it can be properly (re)opened and | |
20815 | # appended to by config.status. When coming back to configure, we | |
20816 | # need to make the FD available again. | |
20817 | if test "$no_create" != yes; then | |
20818 | ac_cs_success=: | |
20819 | ac_config_status_args= | |
20820 | test "$silent" = yes && | |
20821 | ac_config_status_args="$ac_config_status_args --quiet" | |
20822 | exec 5>/dev/null | |
20823 | $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false | |
20824 | exec 5>>config.log | |
20825 | # Use ||, not &&, to avoid exiting from the if with $? = 1, which | |
20826 | # would make configure fail if this is the last instruction. | |
2018939f | 20827 | $ac_cs_success || as_fn_exit 1 |
067d23c9 KY |
20828 | fi |
20829 | if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then | |
20830 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 | |
20831 | $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} | |
20832 | fi | |
20833 |