]> git.ipfire.org Git - thirdparty/e2fsprogs.git/blame - configure
Merge branch 'maint' into next
[thirdparty/e2fsprogs.git] / configure
CommitLineData
50e1e10f 1#! /bin/sh
50e1e10f 2# Guess values for system-dependent variables and create Makefiles.
54445dc2 3# Generated by GNU Autoconf 2.71.
61ef2474 4#
50e1e10f 5#
54445dc2
TT
6# Copyright (C) 1992-1996, 1998-2017, 2020-2021 Free Software Foundation,
7# Inc.
61ef2474 8#
57aa50d4 9#
50e1e10f
TT
10# This configure script is free software; the Free Software Foundation
11# gives unlimited permission to copy, distribute and modify it.
57aa50d4
TT
12## -------------------- ##
13## M4sh Initialization. ##
14## -------------------- ##
b0cacab0 15
29a5deed
TT
16# Be more Bourne compatible
17DUALCASE=1; export DUALCASE # for MKS sh
54445dc2
TT
18as_nop=:
19if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
20then :
b0cacab0
TT
21 emulate sh
22 NULLCMD=:
39fd3d4f 23 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
b0cacab0
TT
24 # is contrary to our usage. Disable this feature.
25 alias -g '${1+"$@"}'='"$@"'
e1052144 26 setopt NO_GLOB_SUBST
54445dc2 27else $as_nop
57aa50d4
TT
28 case `(set -o) 2>/dev/null` in #(
29 *posix*) :
30 set -o posix ;; #(
31 *) :
32 ;;
29a5deed 33esac
b0cacab0 34fi
29a5deed
TT
35
36
54445dc2
TT
37
38# Reset variables that may have inherited troublesome values from
39# the environment.
40
41# IFS needs to be set, to space, tab, and newline, in precisely that order.
42# (If _AS_PATH_WALK were called with IFS unset, it would have the
43# side effect of setting IFS to empty, thus disabling word splitting.)
44# Quoting is to prevent editors from complaining about space-tab.
39fd3d4f
SJR
45as_nl='
46'
47export as_nl
54445dc2
TT
48IFS=" "" $as_nl"
49
50PS1='$ '
51PS2='> '
52PS4='+ '
53
54# Ensure predictable behavior from utilities with locale-dependent output.
55LC_ALL=C
56export LC_ALL
57LANGUAGE=C
58export LANGUAGE
59
60# We cannot yet rely on "unset" to work, but we need these variables
61# to be unset--not just set to an empty or harmless value--now, to
62# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct
63# also avoids known problems related to "unset" and subshell syntax
64# in other old shells (e.g. bash 2.01 and pdksh 5.2.14).
65for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH
66do eval test \${$as_var+y} \
67 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
68done
69
70# Ensure that fds 0, 1, and 2 are open.
71if (exec 3>&0) 2>/dev/null; then :; else exec 0</dev/null; fi
72if (exec 3>&1) 2>/dev/null; then :; else exec 1>/dev/null; fi
73if (exec 3>&2) ; then :; else exec 2>/dev/null; fi
39fd3d4f
SJR
74
75# The user is always right.
54445dc2 76if ${PATH_SEPARATOR+false} :; then
39fd3d4f
SJR
77 PATH_SEPARATOR=:
78 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
79 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
80 PATH_SEPARATOR=';'
81 }
e1052144
TT
82fi
83
b0cacab0 84
e1052144 85# Find who we are. Look in the path if we contain no directory separator.
d6a4bcb5 86as_myself=
57aa50d4 87case $0 in #((
e1052144
TT
88 *[\\/]* ) as_myself=$0 ;;
89 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
90for as_dir in $PATH
91do
92 IFS=$as_save_IFS
54445dc2
TT
93 case $as_dir in #(((
94 '') as_dir=./ ;;
95 */) ;;
96 *) as_dir=$as_dir/ ;;
97 esac
98 test -r "$as_dir$0" && as_myself=$as_dir$0 && break
57aa50d4 99 done
e1052144
TT
100IFS=$as_save_IFS
101
102 ;;
103esac
104# We did not find ourselves, most probably we were run as `sh COMMAND'
105# in which case we are not to be found in the path.
106if test "x$as_myself" = x; then
107 as_myself=$0
108fi
109if test ! -f "$as_myself"; then
54445dc2 110 printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
57aa50d4 111 exit 1
e1052144
TT
112fi
113
57aa50d4 114
d6a4bcb5
TB
115# Use a proper internal environment variable to ensure we don't fall
116 # into an infinite loop, continuously re-executing ourselves.
117 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
118 _as_can_reexec=no; export _as_can_reexec;
119 # We cannot yet assume a decent shell, so we have to provide a
120# neutralization value for shells without unset; and this also
121# works around shells that cannot unset nonexistent variables.
122# Preserve -v and -x to the replacement shell.
123BASH_ENV=/dev/null
124ENV=/dev/null
125(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
126case $- in # ((((
127 *v*x* | *x*v* ) as_opts=-vx ;;
128 *v* ) as_opts=-v ;;
129 *x* ) as_opts=-x ;;
130 * ) as_opts= ;;
131esac
132exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
133# Admittedly, this is quite paranoid, since all the known shells bail
134# out after a failed `exec'.
54445dc2
TT
135printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
136exit 255
d6a4bcb5
TB
137 fi
138 # We don't want this to propagate to other subprocesses.
139 { _as_can_reexec=; unset _as_can_reexec;}
57aa50d4 140if test "x$CONFIG_SHELL" = x; then
54445dc2
TT
141 as_bourne_compatible="as_nop=:
142if test \${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
143then :
57aa50d4
TT
144 emulate sh
145 NULLCMD=:
146 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
147 # is contrary to our usage. Disable this feature.
148 alias -g '\${1+\"\$@\"}'='\"\$@\"'
149 setopt NO_GLOB_SUBST
54445dc2 150else \$as_nop
57aa50d4
TT
151 case \`(set -o) 2>/dev/null\` in #(
152 *posix*) :
153 set -o posix ;; #(
154 *) :
155 ;;
156esac
157fi
158"
159 as_required="as_fn_return () { (exit \$1); }
160as_fn_success () { as_fn_return 0; }
161as_fn_failure () { as_fn_return 1; }
162as_fn_ret_success () { return 0; }
163as_fn_ret_failure () { return 1; }
164
165exitcode=0
166as_fn_success || { exitcode=1; echo as_fn_success failed.; }
167as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
168as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
169as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
54445dc2
TT
170if ( set x; as_fn_ret_success y && test x = \"\$1\" )
171then :
57aa50d4 172
54445dc2 173else \$as_nop
57aa50d4
TT
174 exitcode=1; echo positional parameters were not saved.
175fi
d6a4bcb5 176test x\$exitcode = x0 || exit 1
54445dc2
TT
177blah=\$(echo \$(echo blah))
178test x\"\$blah\" = xblah || exit 1
d6a4bcb5 179test -x / || exit 1"
57aa50d4
TT
180 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
181 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
182 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
183 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
184test \$(( 1 + 1 )) = 2 || exit 1"
54445dc2
TT
185 if (eval "$as_required") 2>/dev/null
186then :
57aa50d4 187 as_have_required=yes
54445dc2 188else $as_nop
57aa50d4
TT
189 as_have_required=no
190fi
54445dc2
TT
191 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null
192then :
57aa50d4 193
54445dc2 194else $as_nop
57aa50d4
TT
195 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
196as_found=false
197for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
198do
199 IFS=$as_save_IFS
54445dc2
TT
200 case $as_dir in #(((
201 '') as_dir=./ ;;
202 */) ;;
203 *) as_dir=$as_dir/ ;;
204 esac
57aa50d4
TT
205 as_found=:
206 case $as_dir in #(
207 /*)
208 for as_base in sh bash ksh sh5; do
209 # Try only shells that exist, to save several forks.
54445dc2 210 as_shell=$as_dir$as_base
57aa50d4 211 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
54445dc2
TT
212 as_run=a "$as_shell" -c "$as_bourne_compatible""$as_required" 2>/dev/null
213then :
57aa50d4 214 CONFIG_SHELL=$as_shell as_have_required=yes
54445dc2
TT
215 if as_run=a "$as_shell" -c "$as_bourne_compatible""$as_suggested" 2>/dev/null
216then :
57aa50d4
TT
217 break 2
218fi
219fi
220 done;;
221 esac
222 as_found=false
223done
57aa50d4 224IFS=$as_save_IFS
54445dc2
TT
225if $as_found
226then :
227
228else $as_nop
229 if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
230 as_run=a "$SHELL" -c "$as_bourne_compatible""$as_required" 2>/dev/null
231then :
232 CONFIG_SHELL=$SHELL as_have_required=yes
233fi
234fi
57aa50d4
TT
235
236
54445dc2
TT
237 if test "x$CONFIG_SHELL" != x
238then :
d6a4bcb5
TB
239 export CONFIG_SHELL
240 # We cannot yet assume a decent shell, so we have to provide a
241# neutralization value for shells without unset; and this also
242# works around shells that cannot unset nonexistent variables.
243# Preserve -v and -x to the replacement shell.
244BASH_ENV=/dev/null
245ENV=/dev/null
246(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
247case $- in # ((((
248 *v*x* | *x*v* ) as_opts=-vx ;;
249 *v* ) as_opts=-v ;;
250 *x* ) as_opts=-x ;;
251 * ) as_opts= ;;
252esac
253exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
254# Admittedly, this is quite paranoid, since all the known shells bail
255# out after a failed `exec'.
54445dc2 256printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
d6a4bcb5 257exit 255
57aa50d4
TT
258fi
259
54445dc2
TT
260 if test x$as_have_required = xno
261then :
262 printf "%s\n" "$0: This script requires a shell more modern than all"
263 printf "%s\n" "$0: the shells that I found on your system."
264 if test ${ZSH_VERSION+y} ; then
265 printf "%s\n" "$0: In particular, zsh $ZSH_VERSION has bugs and should"
266 printf "%s\n" "$0: be upgraded to zsh 4.3.4 or later."
57aa50d4 267 else
54445dc2 268 printf "%s\n" "$0: Please tell bug-autoconf@gnu.org about your system,
57aa50d4
TT
269$0: including any error possibly output before this
270$0: message. Then install a modern shell, or manually run
271$0: the script under such a shell if you do have one."
272 fi
273 exit 1
274fi
275fi
276fi
277SHELL=${CONFIG_SHELL-/bin/sh}
278export SHELL
279# Unset more variables known to interfere with behavior of common tools.
280CLICOLOR_FORCE= GREP_OPTIONS=
281unset CLICOLOR_FORCE GREP_OPTIONS
282
283## --------------------- ##
284## M4sh Shell Functions. ##
285## --------------------- ##
286# as_fn_unset VAR
287# ---------------
288# Portably unset VAR.
289as_fn_unset ()
290{
291 { eval $1=; unset $1;}
292}
293as_unset=as_fn_unset
294
54445dc2 295
57aa50d4
TT
296# as_fn_set_status STATUS
297# -----------------------
298# Set $? to STATUS, without forking.
299as_fn_set_status ()
300{
301 return $1
302} # as_fn_set_status
303
304# as_fn_exit STATUS
305# -----------------
306# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
307as_fn_exit ()
308{
309 set +e
310 as_fn_set_status $1
311 exit $1
312} # as_fn_exit
54445dc2
TT
313# as_fn_nop
314# ---------
315# Do nothing but, unlike ":", preserve the value of $?.
316as_fn_nop ()
317{
318 return $?
319}
320as_nop=as_fn_nop
57aa50d4
TT
321
322# as_fn_mkdir_p
323# -------------
324# Create "$as_dir" as a directory, including parents if necessary.
325as_fn_mkdir_p ()
326{
327
328 case $as_dir in #(
329 -*) as_dir=./$as_dir;;
330 esac
331 test -d "$as_dir" || eval $as_mkdir_p || {
332 as_dirs=
333 while :; do
334 case $as_dir in #(
54445dc2 335 *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
57aa50d4
TT
336 *) as_qdir=$as_dir;;
337 esac
338 as_dirs="'$as_qdir' $as_dirs"
339 as_dir=`$as_dirname -- "$as_dir" ||
340$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
341 X"$as_dir" : 'X\(//\)[^/]' \| \
342 X"$as_dir" : 'X\(//\)$' \| \
343 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
54445dc2 344printf "%s\n" X"$as_dir" |
57aa50d4
TT
345 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
346 s//\1/
347 q
348 }
349 /^X\(\/\/\)[^/].*/{
350 s//\1/
351 q
352 }
353 /^X\(\/\/\)$/{
354 s//\1/
355 q
356 }
357 /^X\(\/\).*/{
358 s//\1/
359 q
360 }
361 s/.*/./; q'`
362 test -d "$as_dir" && break
363 done
364 test -z "$as_dirs" || eval "mkdir $as_dirs"
d6a4bcb5 365 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
57aa50d4
TT
366
367
368} # as_fn_mkdir_p
d6a4bcb5
TB
369
370# as_fn_executable_p FILE
371# -----------------------
372# Test if FILE is an executable regular file.
373as_fn_executable_p ()
374{
375 test -f "$1" && test -x "$1"
376} # as_fn_executable_p
57aa50d4
TT
377# as_fn_append VAR VALUE
378# ----------------------
379# Append the text in VALUE to the end of the definition contained in VAR. Take
380# advantage of any shell optimizations that allow amortized linear growth over
381# repeated appends, instead of the typical quadratic growth present in naive
382# implementations.
54445dc2
TT
383if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null
384then :
57aa50d4
TT
385 eval 'as_fn_append ()
386 {
387 eval $1+=\$2
388 }'
54445dc2 389else $as_nop
57aa50d4
TT
390 as_fn_append ()
391 {
392 eval $1=\$$1\$2
393 }
394fi # as_fn_append
395
396# as_fn_arith ARG...
397# ------------------
398# Perform arithmetic evaluation on the ARGs, and store the result in the
399# global $as_val. Take advantage of shells that can avoid forks. The arguments
400# must be portable across $(()) and expr.
54445dc2
TT
401if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null
402then :
57aa50d4
TT
403 eval 'as_fn_arith ()
404 {
405 as_val=$(( $* ))
406 }'
54445dc2 407else $as_nop
57aa50d4
TT
408 as_fn_arith ()
409 {
410 as_val=`expr "$@" || test $? -eq 1`
411 }
412fi # as_fn_arith
413
54445dc2
TT
414# as_fn_nop
415# ---------
416# Do nothing but, unlike ":", preserve the value of $?.
417as_fn_nop ()
418{
419 return $?
420}
421as_nop=as_fn_nop
57aa50d4 422
d6a4bcb5
TB
423# as_fn_error STATUS ERROR [LINENO LOG_FD]
424# ----------------------------------------
57aa50d4
TT
425# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
426# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
d6a4bcb5 427# script with STATUS, using 1 if that was 0.
57aa50d4
TT
428as_fn_error ()
429{
d6a4bcb5
TB
430 as_status=$1; test $as_status -eq 0 && as_status=1
431 if test "$4"; then
432 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
54445dc2 433 printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
57aa50d4 434 fi
54445dc2 435 printf "%s\n" "$as_me: error: $2" >&2
57aa50d4
TT
436 as_fn_exit $as_status
437} # as_fn_error
438
e1052144
TT
439if expr a : '\(a\)' >/dev/null 2>&1 &&
440 test "X`expr 00001 : '.*\(...\)'`" = X001; then
b0cacab0
TT
441 as_expr=expr
442else
443 as_expr=false
444fi
445
e1052144 446if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
b0cacab0
TT
447 as_basename=basename
448else
449 as_basename=false
450fi
451
57aa50d4
TT
452if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
453 as_dirname=dirname
454else
455 as_dirname=false
456fi
b0cacab0 457
e1052144 458as_me=`$as_basename -- "$0" ||
b0cacab0
TT
459$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
460 X"$0" : 'X\(//\)$' \| \
e1052144 461 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
54445dc2 462printf "%s\n" X/"$0" |
e1052144
TT
463 sed '/^.*\/\([^/][^/]*\)\/*$/{
464 s//\1/
465 q
466 }
467 /^X\/\(\/\/\)$/{
468 s//\1/
469 q
470 }
471 /^X\/\(\/\).*/{
472 s//\1/
473 q
474 }
475 s/.*/./; q'`
b0cacab0 476
57aa50d4
TT
477# Avoid depending upon Character Ranges.
478as_cr_letters='abcdefghijklmnopqrstuvwxyz'
479as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
480as_cr_Letters=$as_cr_letters$as_cr_LETTERS
481as_cr_digits='0123456789'
482as_cr_alnum=$as_cr_Letters$as_cr_digits
b0cacab0 483
b0cacab0 484
57aa50d4
TT
485 as_lineno_1=$LINENO as_lineno_1a=$LINENO
486 as_lineno_2=$LINENO as_lineno_2a=$LINENO
487 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
488 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
489 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
490 sed -n '
491 p
492 /[$]LINENO/=
493 ' <$as_myself |
494 sed '
495 s/[$]LINENO.*/&-/
496 t lineno
497 b
498 :lineno
499 N
500 :loop
501 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
502 t loop
503 s/-\n.*//
504 ' >$as_me.lineno &&
505 chmod +x "$as_me.lineno" ||
54445dc2 506 { printf "%s\n" "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
e1052144 507
d6a4bcb5
TB
508 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
509 # already done that, so ensure we don't try to do so again and fall
510 # in an infinite loop. This has already happened in practice.
511 _as_can_reexec=no; export _as_can_reexec
57aa50d4
TT
512 # Don't try to exec as it changes $[0], causing all sort of problems
513 # (the dirname of $[0] is not the place where we might find the
514 # original and so on. Autoconf is especially sensitive to this).
515 . "./$as_me.lineno"
516 # Exit status is that of the last command.
517 exit
e1052144
TT
518}
519
54445dc2
TT
520
521# Determine whether it's possible to make 'echo' print without a newline.
522# These variables are no longer used directly by Autoconf, but are AC_SUBSTed
523# for compatibility with existing Makefiles.
57aa50d4
TT
524ECHO_C= ECHO_N= ECHO_T=
525case `echo -n x` in #(((((
526-n*)
527 case `echo 'xy\c'` in
528 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
529 xy) ECHO_C='\c';;
530 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
531 ECHO_T=' ';;
532 esac;;
533*)
534 ECHO_N='-n';;
535esac
b0cacab0 536
54445dc2
TT
537# For backward compatibility with old third-party macros, we provide
538# the shell variables $as_echo and $as_echo_n. New code should use
539# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively.
540as_echo='printf %s\n'
541as_echo_n='printf %s'
542
543
57aa50d4
TT
544rm -f conf$$ conf$$.exe conf$$.file
545if test -d conf$$.dir; then
546 rm -f conf$$.dir/conf$$.file
547else
548 rm -f conf$$.dir
549 mkdir conf$$.dir 2>/dev/null
e1052144 550fi
57aa50d4
TT
551if (echo >conf$$.file) 2>/dev/null; then
552 if ln -s conf$$.file conf$$ 2>/dev/null; then
553 as_ln_s='ln -s'
554 # ... but there are two gotchas:
555 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
556 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
d6a4bcb5 557 # In both cases, we have to default to `cp -pR'.
57aa50d4 558 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
d6a4bcb5 559 as_ln_s='cp -pR'
57aa50d4
TT
560 elif ln conf$$.file conf$$ 2>/dev/null; then
561 as_ln_s=ln
562 else
d6a4bcb5 563 as_ln_s='cp -pR'
57aa50d4 564 fi
e1052144 565else
d6a4bcb5 566 as_ln_s='cp -pR'
e1052144 567fi
57aa50d4
TT
568rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
569rmdir conf$$.dir 2>/dev/null
b0cacab0 570
57aa50d4
TT
571if mkdir -p . 2>/dev/null; then
572 as_mkdir_p='mkdir -p "$as_dir"'
573else
574 test -d ./-p && rmdir ./-p
575 as_mkdir_p=false
e1052144
TT
576fi
577
d6a4bcb5
TB
578as_test_x='test -x'
579as_executable_p=as_fn_executable_p
e1052144 580
57aa50d4
TT
581# Sed expression to map a string onto a valid CPP name.
582as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
e1052144 583
57aa50d4
TT
584# Sed expression to map a string onto a valid variable name.
585as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
e1052144 586
29a5deed 587
61ef2474
TT
588test -n "$DJDIR" || exec 7<&0 </dev/null
589exec 6>&1
b0cacab0
TT
590
591# Name of the host.
d6a4bcb5 592# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
b0cacab0
TT
593# so uname gets run too.
594ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
50e1e10f 595
b0cacab0
TT
596#
597# Initializations.
598#
50e1e10f 599ac_default_prefix=/usr/local
e1052144 600ac_clean_files=
b0cacab0 601ac_config_libobj_dir=.
e1052144 602LIBOBJS=
b0cacab0
TT
603cross_compiling=no
604subdirs=
605MFLAGS=
606MAKEFLAGS=
b0cacab0 607
b0cacab0 608# Identity of this package.
54445dc2
TT
609PACKAGE_NAME=''
610PACKAGE_TARNAME=''
611PACKAGE_VERSION=''
612PACKAGE_STRING=''
613PACKAGE_BUGREPORT=''
614PACKAGE_URL=''
b0cacab0
TT
615
616ac_unique_file="version.h"
617# Factoring default headers for most tests.
618ac_includes_default="\
54445dc2
TT
619#include <stddef.h>
620#ifdef HAVE_STDIO_H
621# include <stdio.h>
b0cacab0 622#endif
54445dc2 623#ifdef HAVE_STDLIB_H
b0cacab0 624# include <stdlib.h>
b0cacab0 625#endif
29a5deed 626#ifdef HAVE_STRING_H
b0cacab0
TT
627# include <string.h>
628#endif
29a5deed 629#ifdef HAVE_INTTYPES_H
b0cacab0 630# include <inttypes.h>
e1052144 631#endif
29a5deed 632#ifdef HAVE_STDINT_H
e1052144 633# include <stdint.h>
b0cacab0 634#endif
54445dc2
TT
635#ifdef HAVE_STRINGS_H
636# include <strings.h>
637#endif
638#ifdef HAVE_SYS_TYPES_H
639# include <sys/types.h>
640#endif
641#ifdef HAVE_SYS_STAT_H
642# include <sys/stat.h>
643#endif
29a5deed 644#ifdef HAVE_UNISTD_H
b0cacab0
TT
645# include <unistd.h>
646#endif"
647
54445dc2 648ac_header_c_list=
93613951 649gt_needs=
54445dc2 650ac_func_c_list=
39fd3d4f 651ac_subst_vars='LTLIBOBJS
e1052144 652LIBOBJS
d1d44c14 653OS_IO_FILE
a2df5894
DW
654systemd_system_unit_dir
655have_systemd
656systemd_LIBS
657systemd_CFLAGS
658crond_dir
659have_crond
5ce368f0
DW
660pkg_udev_rules_dir
661have_udev
662udev_LIBS
663udev_CFLAGS
fd1677e8
TT
664LDFLAGS_SHLIB
665CFLAGS_STLIB
666CFLAGS_SHLIB
39fd3d4f
SJR
667BUILD_LDFLAGS
668BUILD_CFLAGS
d1154eb4 669INCLUDES
39fd3d4f 670DO_TEST_SUITE
fd1677e8 671LDFLAGS_STATIC
39fd3d4f
SJR
672root_sysconfdir
673root_libdir
674root_sbindir
675root_bindir
676root_prefix
5ce368f0 677E2SCRUB_CMT
39fd3d4f
SJR
678UNIX_CMT
679CYGWIN_CMT
680LINUX_CMT
2869485b
TT
681FUZZING_CMT
682fuzzer_ldflags
683fuzzer_cflags
684have_fuzzer
685ac_ct_CXX
686CXXFLAGS
687CXX
bcca786b
DW
688threadsan_ldflags
689threadsan_cflags
690have_threadsan
5e666e3d
DW
691addrsan_ldflags
692addrsan_cflags
693have_addrsan
1c2a76ae
DW
694ubsan_ldflags
695ubsan_cflags
696have_ubsan
4aece328
DW
697lto_ldflags
698lto_cflags
699have_lto
700gcc_ranlib
701gcc_ar
39fd3d4f
SJR
702UNI_DIFF_OPTS
703SEM_INIT_LIB
81cbf1ef
DW
704FUSE_CMT
705FUSE_LIB
c94da047 706CLOCK_GETTIME_LIB
b291c11f 707MAGIC_LIB
39fd3d4f 708SOCKET_LIB
2dd680f3 709SIZEOF_TIME_T
cc68e8a6 710SIZEOF_OFF_T
39fd3d4f
SJR
711SIZEOF_LONG_LONG
712SIZEOF_LONG
713SIZEOF_INT
714SIZEOF_SHORT
ec3a69bb 715DD
39fd3d4f
SJR
716BUILD_CC
717MAKEINFO
718STRIP
e598c29b 719RANLIB
39fd3d4f
SJR
720AR
721LDCONFIG
722PERL
39fd3d4f
SJR
723AWK
724CHMOD
725RM
726CP
727MV
728LN_S
3fb16e74 729mkdir_p
39fd3d4f 730LN
bcb915b0
TT
731ifNotGNUmake
732ifGNUmake
39fd3d4f
SJR
733BINARY_TYPE
734POSUB
735LTLIBINTL
736LIBINTL
737INTLLIBS
93613951
TT
738LTLIBICONV
739LIBICONV
e598c29b 740INTL_MACOSX_LIBS
93613951 741XGETTEXT_EXTRA_OPTIONS
bdcd5f22 742MSGMERGE_FOR_MSGFMT_OPTION
39fd3d4f 743MSGMERGE
93613951 744XGETTEXT_015
39fd3d4f 745XGETTEXT
93613951 746GMSGFMT_015
39fd3d4f
SJR
747GMSGFMT
748MSGFMT
93613951 749GETTEXT_MACRO_VERSION
39fd3d4f 750USE_NLS
93613951 751MKDIR_P
39fd3d4f
SJR
752INSTALL_DATA
753INSTALL_SCRIPT
754INSTALL_PROGRAM
755SET_MAKE
756VERSION
757PACKAGE
758GETTEXT_PACKAGE
749f0712
TT
759TDB_MAN_COMMENT
760TDB_CMT
39fd3d4f 761UUIDD_CMT
bdcd5f22
TT
762PTHREAD_CFLAGS
763PTHREAD_LIBS
54445dc2 764PTHREAD_CXX
bdcd5f22
TT
765PTHREAD_CC
766ax_pthread_config
54445dc2
TT
767EGREP
768GREP
bdcd5f22 769SED
39fd3d4f
SJR
770E2INITRD_MAN
771E2INITRD_PROG
772FSCK_MAN
773FSCK_PROG
8d9c50c5 774DEFRAG_CMT
39fd3d4f
SJR
775RESIZER_CMT
776IMAGER_CMT
777DEBUGFS_CMT
feb235e0 778SUBSET_CMT
0afb9be6 779ALL_CMT
39fd3d4f
SJR
780BLKID_CMT
781DEPPROFILED_LIBBLKID
782PROFILED_LIBBLKID
783DEPSTATIC_LIBBLKID
784STATIC_LIBBLKID
785DEPLIBBLKID
786LIBBLKID
787UUID_CMT
788DEPPROFILED_LIBUUID
789PROFILED_LIBUUID
790DEPSTATIC_LIBUUID
791STATIC_LIBUUID
792DEPLIBUUID
793LIBUUID
93613951
TT
794PKG_CONFIG_LIBDIR
795PKG_CONFIG_PATH
39fd3d4f 796PKG_CONFIG
b9e66a18 797DEV_FEATURES_CMT
39fd3d4f
SJR
798TEST_IO_CMT
799PRIVATE_LIBS_CMT
800LDFLAG_DYNAMIC
801PROFILED_LIB_EXT
802STATIC_LIB_EXT
803LIB_EXT
39fd3d4f
SJR
804PROFILE_CMT
805BSDLIB_CMT
806ELF_CMT
c13351f6 807Q
c1986ecb 808ES
c13351f6 809E
5aa6c3f6 810LINK_BUILD_FLAGS
183c73b0 811SYMLINK_RELATIVE
5aa6c3f6 812LINK_INSTALL_FLAGS
39fd3d4f 813MAINTAINER_CMT
39fd3d4f 814CPP
9b3018a8 815RDYNAMIC
57aa50d4 816DLOPEN_LIB
39fd3d4f
SJR
817host_os
818host_vendor
819host_cpu
820host
821build_os
822build_vendor
823build_cpu
824build
5ce368f0 825E2FSPROGS_DATE
39fd3d4f 826E2FSPROGS_PKGVER
1ac00616 827E2FSPROGS_PKGREL
39fd3d4f
SJR
828E2FSPROGS_VERSION
829E2FSPROGS_DAY
830E2FSPROGS_MONTH
831E2FSPROGS_YEAR
54445dc2
TT
832OBJEXT
833EXEEXT
834ac_ct_CC
835CPPFLAGS
836LDFLAGS
837CFLAGS
838CC
39fd3d4f
SJR
839target_alias
840host_alias
841build_alias
842LIBS
843ECHO_T
844ECHO_N
845ECHO_C
846DEFS
847mandir
848localedir
849libdir
850psdir
851pdfdir
852dvidir
853htmldir
854infodir
855docdir
856oldincludedir
857includedir
2ab53829 858runstatedir
39fd3d4f
SJR
859localstatedir
860sharedstatedir
861sysconfdir
862datadir
863datarootdir
864libexecdir
865sbindir
866bindir
867program_transform_name
868prefix
869exec_prefix
57aa50d4 870PACKAGE_URL
39fd3d4f
SJR
871PACKAGE_BUGREPORT
872PACKAGE_STRING
873PACKAGE_VERSION
874PACKAGE_TARNAME
875PACKAGE_NAME
876PATH_SEPARATOR
877SHELL'
e1052144
TT
878ac_subst_files='MCONFIG
879MAKEFILE_ELF
880MAKEFILE_BSDLIB
881MAKEFILE_PROFILE
e1052144 882MAKEFILE_LIBRARY
488c75a6
TT
883ASM_TYPES_HEADER
884PUBLIC_CONFIG_HEADER'
39fd3d4f
SJR
885ac_user_opts='
886enable_option_checking
887with_diet_libc
888with_cc
39fd3d4f
SJR
889with_ccopts
890with_ldopts
891with_root_prefix
892enable_maintainer_mode
5aa6c3f6 893enable_symlink_install
91d11da1 894enable_relative_symlinks
183c73b0 895enable_symlink_relative_symlinks
5aa6c3f6 896enable_symlink_build
c13351f6 897enable_verbose_makecmds
39fd3d4f
SJR
898enable_elf_shlibs
899enable_bsd_shlibs
900enable_profile
fedfb27f 901enable_gcov
fd1677e8 902enable_hardening
39fd3d4f
SJR
903enable_jbd_debug
904enable_blkid_debug
905enable_testio_debug
b9e66a18 906enable_developer_features
39fd3d4f
SJR
907enable_libuuid
908enable_libblkid
0afb9be6 909enable_subset
3df6014a 910enable_backtrace
39fd3d4f
SJR
911enable_debugfs
912enable_imager
913enable_resizer
8d9c50c5 914enable_defrag
39fd3d4f
SJR
915enable_fsck
916enable_e2initrd_helper
917enable_tls
bdcd5f22 918with_pthread
39fd3d4f 919enable_uuidd
d6a4bcb5 920enable_mmp
749f0712 921enable_tdb
1625bf42
TB
922enable_bmap_stats
923enable_bmap_stats_ops
39fd3d4f
SJR
924enable_nls
925with_gnu_ld
926enable_rpath
927with_libiconv_prefix
39fd3d4f 928with_libintl_prefix
81cbf1ef 929enable_fuse2fs
4aece328 930enable_lto
1c2a76ae 931enable_ubsan
5e666e3d 932enable_addrsan
bcca786b 933enable_threadsan
2869485b 934enable_fuzzing
55e00a25 935with_multiarch
5ce368f0 936with_udev_rules_dir
a2df5894
DW
937with_crond_dir
938with_systemd_unit_dir
a22e7f16 939enable_largefile
39fd3d4f 940'
e1052144
TT
941 ac_precious_vars='build_alias
942host_alias
943target_alias
944CC
945CFLAGS
946LDFLAGS
29a5deed 947LIBS
e1052144 948CPPFLAGS
14b596d4 949CPP
93613951
TT
950PKG_CONFIG
951PKG_CONFIG_PATH
5ce368f0 952PKG_CONFIG_LIBDIR
2869485b
TT
953CXX
954CXXFLAGS
955CCC
5ce368f0 956udev_CFLAGS
a2df5894
DW
957udev_LIBS
958systemd_CFLAGS
959systemd_LIBS'
e1052144 960
50e1e10f
TT
961
962# Initialize some variables set by options.
b0cacab0
TT
963ac_init_help=
964ac_init_version=false
39fd3d4f
SJR
965ac_unrecognized_opts=
966ac_unrecognized_sep=
50e1e10f
TT
967# The variables have the same names as the options, with
968# dashes changed to underlines.
b0cacab0 969cache_file=/dev/null
50e1e10f 970exec_prefix=NONE
50e1e10f 971no_create=
50e1e10f
TT
972no_recursion=
973prefix=NONE
974program_prefix=NONE
975program_suffix=NONE
976program_transform_name=s,x,x,
977silent=
978site=
979srcdir=
50e1e10f
TT
980verbose=
981x_includes=NONE
982x_libraries=NONE
b0cacab0
TT
983
984# Installation directory options.
985# These are left unexpanded so users can "make install exec_prefix=/foo"
986# and all the variables that are supposed to be based on exec_prefix
987# by default will actually change.
988# Use braces instead of parens because sh, perl, etc. also accept them.
e1052144 989# (The list follows the same order as the GNU Coding Standards.)
21c84b71
TT
990bindir='${exec_prefix}/bin'
991sbindir='${exec_prefix}/sbin'
992libexecdir='${exec_prefix}/libexec'
e1052144
TT
993datarootdir='${prefix}/share'
994datadir='${datarootdir}'
21c84b71
TT
995sysconfdir='${prefix}/etc'
996sharedstatedir='${prefix}/com'
997localstatedir='${prefix}/var'
2ab53829 998runstatedir='${localstatedir}/run'
21c84b71
TT
999includedir='${prefix}/include'
1000oldincludedir='/usr/include'
e1052144
TT
1001docdir='${datarootdir}/doc/${PACKAGE}'
1002infodir='${datarootdir}/info'
1003htmldir='${docdir}'
1004dvidir='${docdir}'
1005pdfdir='${docdir}'
1006psdir='${docdir}'
1007libdir='${exec_prefix}/lib'
1008localedir='${datarootdir}/locale'
1009mandir='${datarootdir}/man'
50e1e10f 1010
50e1e10f 1011ac_prev=
e1052144 1012ac_dashdash=
50e1e10f
TT
1013for ac_option
1014do
50e1e10f
TT
1015 # If the previous option needs an argument, assign it.
1016 if test -n "$ac_prev"; then
e1052144 1017 eval $ac_prev=\$ac_option
50e1e10f
TT
1018 ac_prev=
1019 continue
1020 fi
1021
e1052144 1022 case $ac_option in
d6a4bcb5
TB
1023 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1024 *=) ac_optarg= ;;
1025 *) ac_optarg=yes ;;
e1052144 1026 esac
50e1e10f 1027
e1052144
TT
1028 case $ac_dashdash$ac_option in
1029 --)
1030 ac_dashdash=yes ;;
50e1e10f 1031
21c84b71
TT
1032 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1033 ac_prev=bindir ;;
1034 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
b0cacab0 1035 bindir=$ac_optarg ;;
21c84b71
TT
1036
1037 -build | --build | --buil | --bui | --bu)
b0cacab0 1038 ac_prev=build_alias ;;
21c84b71 1039 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
b0cacab0 1040 build_alias=$ac_optarg ;;
50e1e10f
TT
1041
1042 -cache-file | --cache-file | --cache-fil | --cache-fi \
1043 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1044 ac_prev=cache_file ;;
1045 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1046 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
b0cacab0
TT
1047 cache_file=$ac_optarg ;;
1048
1049 --config-cache | -C)
1050 cache_file=config.cache ;;
50e1e10f 1051
e1052144 1052 -datadir | --datadir | --datadi | --datad)
21c84b71 1053 ac_prev=datadir ;;
e1052144 1054 -datadir=* | --datadir=* | --datadi=* | --datad=*)
b0cacab0 1055 datadir=$ac_optarg ;;
21c84b71 1056
e1052144
TT
1057 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1058 | --dataroo | --dataro | --datar)
1059 ac_prev=datarootdir ;;
1060 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1061 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1062 datarootdir=$ac_optarg ;;
1063
50e1e10f 1064 -disable-* | --disable-*)
39fd3d4f 1065 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
50e1e10f 1066 # Reject names that are not valid shell variable names.
39fd3d4f 1067 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
54445dc2 1068 as_fn_error $? "invalid feature name: \`$ac_useropt'"
39fd3d4f 1069 ac_useropt_orig=$ac_useropt
54445dc2 1070 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
39fd3d4f
SJR
1071 case $ac_user_opts in
1072 *"
1073"enable_$ac_useropt"
1074"*) ;;
1075 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1076 ac_unrecognized_sep=', ';;
1077 esac
1078 eval enable_$ac_useropt=no ;;
e1052144
TT
1079
1080 -docdir | --docdir | --docdi | --doc | --do)
1081 ac_prev=docdir ;;
1082 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1083 docdir=$ac_optarg ;;
1084
1085 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1086 ac_prev=dvidir ;;
1087 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1088 dvidir=$ac_optarg ;;
50e1e10f
TT
1089
1090 -enable-* | --enable-*)
39fd3d4f 1091 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
50e1e10f 1092 # Reject names that are not valid shell variable names.
39fd3d4f 1093 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
54445dc2 1094 as_fn_error $? "invalid feature name: \`$ac_useropt'"
39fd3d4f 1095 ac_useropt_orig=$ac_useropt
54445dc2 1096 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
39fd3d4f
SJR
1097 case $ac_user_opts in
1098 *"
1099"enable_$ac_useropt"
1100"*) ;;
1101 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1102 ac_unrecognized_sep=', ';;
1103 esac
1104 eval enable_$ac_useropt=\$ac_optarg ;;
50e1e10f
TT
1105
1106 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1107 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1108 | --exec | --exe | --ex)
1109 ac_prev=exec_prefix ;;
1110 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1111 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1112 | --exec=* | --exe=* | --ex=*)
b0cacab0 1113 exec_prefix=$ac_optarg ;;
50e1e10f
TT
1114
1115 -gas | --gas | --ga | --g)
1116 # Obsolete; use --with-gas.
1117 with_gas=yes ;;
1118
b0cacab0
TT
1119 -help | --help | --hel | --he | -h)
1120 ac_init_help=long ;;
1121 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1122 ac_init_help=recursive ;;
1123 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1124 ac_init_help=short ;;
50e1e10f
TT
1125
1126 -host | --host | --hos | --ho)
b0cacab0 1127 ac_prev=host_alias ;;
50e1e10f 1128 -host=* | --host=* | --hos=* | --ho=*)
b0cacab0 1129 host_alias=$ac_optarg ;;
50e1e10f 1130
e1052144
TT
1131 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1132 ac_prev=htmldir ;;
1133 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1134 | --ht=*)
1135 htmldir=$ac_optarg ;;
1136
21c84b71
TT
1137 -includedir | --includedir | --includedi | --included | --include \
1138 | --includ | --inclu | --incl | --inc)
1139 ac_prev=includedir ;;
1140 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1141 | --includ=* | --inclu=* | --incl=* | --inc=*)
b0cacab0 1142 includedir=$ac_optarg ;;
21c84b71
TT
1143
1144 -infodir | --infodir | --infodi | --infod | --info | --inf)
1145 ac_prev=infodir ;;
1146 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
b0cacab0 1147 infodir=$ac_optarg ;;
21c84b71
TT
1148
1149 -libdir | --libdir | --libdi | --libd)
1150 ac_prev=libdir ;;
1151 -libdir=* | --libdir=* | --libdi=* | --libd=*)
b0cacab0 1152 libdir=$ac_optarg ;;
21c84b71
TT
1153
1154 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1155 | --libexe | --libex | --libe)
1156 ac_prev=libexecdir ;;
1157 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1158 | --libexe=* | --libex=* | --libe=*)
b0cacab0 1159 libexecdir=$ac_optarg ;;
21c84b71 1160
e1052144
TT
1161 -localedir | --localedir | --localedi | --localed | --locale)
1162 ac_prev=localedir ;;
1163 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1164 localedir=$ac_optarg ;;
1165
21c84b71 1166 -localstatedir | --localstatedir | --localstatedi | --localstated \
e1052144 1167 | --localstate | --localstat | --localsta | --localst | --locals)
21c84b71
TT
1168 ac_prev=localstatedir ;;
1169 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
e1052144 1170 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
b0cacab0 1171 localstatedir=$ac_optarg ;;
21c84b71
TT
1172
1173 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1174 ac_prev=mandir ;;
1175 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
b0cacab0 1176 mandir=$ac_optarg ;;
21c84b71 1177
50e1e10f
TT
1178 -nfp | --nfp | --nf)
1179 # Obsolete; use --without-fp.
1180 with_fp=no ;;
1181
1182 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
b0cacab0 1183 | --no-cr | --no-c | -n)
50e1e10f
TT
1184 no_create=yes ;;
1185
1186 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1187 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1188 no_recursion=yes ;;
1189
21c84b71
TT
1190 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1191 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1192 | --oldin | --oldi | --old | --ol | --o)
1193 ac_prev=oldincludedir ;;
1194 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1195 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1196 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
b0cacab0 1197 oldincludedir=$ac_optarg ;;
21c84b71 1198
50e1e10f
TT
1199 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1200 ac_prev=prefix ;;
1201 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
b0cacab0 1202 prefix=$ac_optarg ;;
50e1e10f
TT
1203
1204 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1205 | --program-pre | --program-pr | --program-p)
1206 ac_prev=program_prefix ;;
1207 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1208 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
b0cacab0 1209 program_prefix=$ac_optarg ;;
50e1e10f
TT
1210
1211 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1212 | --program-suf | --program-su | --program-s)
1213 ac_prev=program_suffix ;;
1214 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1215 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
b0cacab0 1216 program_suffix=$ac_optarg ;;
50e1e10f
TT
1217
1218 -program-transform-name | --program-transform-name \
1219 | --program-transform-nam | --program-transform-na \
1220 | --program-transform-n | --program-transform- \
1221 | --program-transform | --program-transfor \
1222 | --program-transfo | --program-transf \
1223 | --program-trans | --program-tran \
1224 | --progr-tra | --program-tr | --program-t)
1225 ac_prev=program_transform_name ;;
1226 -program-transform-name=* | --program-transform-name=* \
1227 | --program-transform-nam=* | --program-transform-na=* \
1228 | --program-transform-n=* | --program-transform-=* \
1229 | --program-transform=* | --program-transfor=* \
1230 | --program-transfo=* | --program-transf=* \
1231 | --program-trans=* | --program-tran=* \
1232 | --progr-tra=* | --program-tr=* | --program-t=*)
b0cacab0 1233 program_transform_name=$ac_optarg ;;
50e1e10f 1234
e1052144
TT
1235 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1236 ac_prev=pdfdir ;;
1237 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1238 pdfdir=$ac_optarg ;;
1239
1240 -psdir | --psdir | --psdi | --psd | --ps)
1241 ac_prev=psdir ;;
1242 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1243 psdir=$ac_optarg ;;
1244
50e1e10f
TT
1245 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1246 | -silent | --silent | --silen | --sile | --sil)
1247 silent=yes ;;
1248
2ab53829
TT
1249 -runstatedir | --runstatedir | --runstatedi | --runstated \
1250 | --runstate | --runstat | --runsta | --runst | --runs \
1251 | --run | --ru | --r)
1252 ac_prev=runstatedir ;;
1253 -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
1254 | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
1255 | --run=* | --ru=* | --r=*)
1256 runstatedir=$ac_optarg ;;
1257
21c84b71
TT
1258 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1259 ac_prev=sbindir ;;
1260 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1261 | --sbi=* | --sb=*)
b0cacab0 1262 sbindir=$ac_optarg ;;
21c84b71
TT
1263
1264 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1265 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1266 | --sharedst | --shareds | --shared | --share | --shar \
1267 | --sha | --sh)
1268 ac_prev=sharedstatedir ;;
1269 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1270 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1271 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1272 | --sha=* | --sh=*)
b0cacab0 1273 sharedstatedir=$ac_optarg ;;
21c84b71 1274
50e1e10f
TT
1275 -site | --site | --sit)
1276 ac_prev=site ;;
1277 -site=* | --site=* | --sit=*)
b0cacab0 1278 site=$ac_optarg ;;
50e1e10f
TT
1279
1280 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1281 ac_prev=srcdir ;;
1282 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
b0cacab0 1283 srcdir=$ac_optarg ;;
50e1e10f 1284
21c84b71
TT
1285 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1286 | --syscon | --sysco | --sysc | --sys | --sy)
1287 ac_prev=sysconfdir ;;
1288 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1289 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
b0cacab0 1290 sysconfdir=$ac_optarg ;;
21c84b71 1291
50e1e10f 1292 -target | --target | --targe | --targ | --tar | --ta | --t)
b0cacab0 1293 ac_prev=target_alias ;;
50e1e10f 1294 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
b0cacab0 1295 target_alias=$ac_optarg ;;
50e1e10f
TT
1296
1297 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1298 verbose=yes ;;
1299
b0cacab0
TT
1300 -version | --version | --versio | --versi | --vers | -V)
1301 ac_init_version=: ;;
50e1e10f
TT
1302
1303 -with-* | --with-*)
39fd3d4f 1304 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
50e1e10f 1305 # Reject names that are not valid shell variable names.
39fd3d4f 1306 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
54445dc2 1307 as_fn_error $? "invalid package name: \`$ac_useropt'"
39fd3d4f 1308 ac_useropt_orig=$ac_useropt
54445dc2 1309 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
39fd3d4f
SJR
1310 case $ac_user_opts in
1311 *"
1312"with_$ac_useropt"
1313"*) ;;
1314 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1315 ac_unrecognized_sep=', ';;
1316 esac
1317 eval with_$ac_useropt=\$ac_optarg ;;
50e1e10f
TT
1318
1319 -without-* | --without-*)
39fd3d4f 1320 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
50e1e10f 1321 # Reject names that are not valid shell variable names.
39fd3d4f 1322 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
54445dc2 1323 as_fn_error $? "invalid package name: \`$ac_useropt'"
39fd3d4f 1324 ac_useropt_orig=$ac_useropt
54445dc2 1325 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
39fd3d4f
SJR
1326 case $ac_user_opts in
1327 *"
1328"with_$ac_useropt"
1329"*) ;;
1330 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1331 ac_unrecognized_sep=', ';;
1332 esac
1333 eval with_$ac_useropt=no ;;
50e1e10f
TT
1334
1335 --x)
1336 # Obsolete; use --with-x.
1337 with_x=yes ;;
1338
1339 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1340 | --x-incl | --x-inc | --x-in | --x-i)
1341 ac_prev=x_includes ;;
1342 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1343 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
b0cacab0 1344 x_includes=$ac_optarg ;;
50e1e10f
TT
1345
1346 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1347 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1348 ac_prev=x_libraries ;;
1349 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1350 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
b0cacab0 1351 x_libraries=$ac_optarg ;;
50e1e10f 1352
d6a4bcb5
TB
1353 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1354Try \`$0 --help' for more information"
50e1e10f
TT
1355 ;;
1356
b0cacab0
TT
1357 *=*)
1358 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1359 # Reject names that are not valid shell variable names.
57aa50d4
TT
1360 case $ac_envvar in #(
1361 '' | [0-9]* | *[!_$as_cr_alnum]* )
d6a4bcb5 1362 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
57aa50d4 1363 esac
e1052144 1364 eval $ac_envvar=\$ac_optarg
b0cacab0
TT
1365 export $ac_envvar ;;
1366
21c84b71 1367 *)
b0cacab0 1368 # FIXME: should be removed in autoconf 3.0.
54445dc2 1369 printf "%s\n" "$as_me: WARNING: you should use --build, --host, --target" >&2
b0cacab0 1370 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
54445dc2 1371 printf "%s\n" "$as_me: WARNING: invalid host type: $ac_option" >&2
d6a4bcb5 1372 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
50e1e10f
TT
1373 ;;
1374
1375 esac
1376done
1377
1378if test -n "$ac_prev"; then
b0cacab0 1379 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
d6a4bcb5 1380 as_fn_error $? "missing argument to $ac_option"
50e1e10f 1381fi
50e1e10f 1382
39fd3d4f
SJR
1383if test -n "$ac_unrecognized_opts"; then
1384 case $enable_option_checking in
1385 no) ;;
d6a4bcb5 1386 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
54445dc2 1387 *) printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
39fd3d4f
SJR
1388 esac
1389fi
1390
1391# Check all directory arguments for consistency.
e1052144
TT
1392for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1393 datadir sysconfdir sharedstatedir localstatedir includedir \
1394 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
2ab53829 1395 libdir localedir mandir runstatedir
50e1e10f 1396do
e1052144 1397 eval ac_val=\$$ac_var
39fd3d4f
SJR
1398 # Remove trailing slashes.
1399 case $ac_val in
1400 */ )
1401 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1402 eval $ac_var=\$ac_val;;
1403 esac
1404 # Be sure to have absolute directory names.
b0cacab0 1405 case $ac_val in
e1052144
TT
1406 [\\/$]* | ?:[\\/]* ) continue;;
1407 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
50e1e10f 1408 esac
d6a4bcb5 1409 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
50e1e10f
TT
1410done
1411
b0cacab0
TT
1412# There might be people who depend on the old broken behavior: `$host'
1413# used to hold the argument of --host etc.
1414# FIXME: To remove some day.
1415build=$build_alias
1416host=$host_alias
1417target=$target_alias
1418
1419# FIXME: To remove some day.
1420if test "x$host_alias" != x; then
1421 if test "x$build_alias" = x; then
1422 cross_compiling=maybe
b0cacab0
TT
1423 elif test "x$build_alias" != "x$host_alias"; then
1424 cross_compiling=yes
1425 fi
1426fi
50e1e10f 1427
b0cacab0
TT
1428ac_tool_prefix=
1429test -n "$host_alias" && ac_tool_prefix=$host_alias-
1430
1431test "$silent" = yes && exec 6>/dev/null
50e1e10f 1432
50e1e10f 1433
e1052144
TT
1434ac_pwd=`pwd` && test -n "$ac_pwd" &&
1435ac_ls_di=`ls -di .` &&
1436ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
d6a4bcb5 1437 as_fn_error $? "working directory cannot be determined"
e1052144 1438test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
d6a4bcb5 1439 as_fn_error $? "pwd does not report name of working directory"
e1052144
TT
1440
1441
50e1e10f
TT
1442# Find the source files, if location was not specified.
1443if test -z "$srcdir"; then
1444 ac_srcdir_defaulted=yes
e1052144 1445 # Try the directory containing this script, then the parent directory.
39fd3d4f
SJR
1446 ac_confdir=`$as_dirname -- "$as_myself" ||
1447$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1448 X"$as_myself" : 'X\(//\)[^/]' \| \
1449 X"$as_myself" : 'X\(//\)$' \| \
1450 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
54445dc2 1451printf "%s\n" X"$as_myself" |
e1052144
TT
1452 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1453 s//\1/
1454 q
1455 }
1456 /^X\(\/\/\)[^/].*/{
1457 s//\1/
1458 q
1459 }
1460 /^X\(\/\/\)$/{
1461 s//\1/
1462 q
1463 }
1464 /^X\(\/\).*/{
1465 s//\1/
1466 q
1467 }
1468 s/.*/./; q'`
50e1e10f 1469 srcdir=$ac_confdir
e1052144 1470 if test ! -r "$srcdir/$ac_unique_file"; then
50e1e10f
TT
1471 srcdir=..
1472 fi
1473else
1474 ac_srcdir_defaulted=no
1475fi
e1052144
TT
1476if test ! -r "$srcdir/$ac_unique_file"; then
1477 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
d6a4bcb5 1478 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
50e1e10f 1479fi
e1052144
TT
1480ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1481ac_abs_confdir=`(
d6a4bcb5 1482 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
e1052144
TT
1483 pwd)`
1484# When building in place, set srcdir=.
1485if test "$ac_abs_confdir" = "$ac_pwd"; then
1486 srcdir=.
1487fi
1488# Remove unnecessary trailing slashes from srcdir.
1489# Double slashes in file names in object file debugging info
1490# mess up M-x gdb in Emacs.
1491case $srcdir in
1492*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1493esac
1494for ac_var in $ac_precious_vars; do
1495 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1496 eval ac_env_${ac_var}_value=\$${ac_var}
1497 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1498 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1499done
b0cacab0
TT
1500
1501#
1502# Report the --help message.
1503#
1504if test "$ac_init_help" = "long"; then
1505 # Omit some internal or obsolete options to make the list less imposing.
1506 # This message is too long to be a string in the A/UX 3.1 sh.
1507 cat <<_ACEOF
1508\`configure' configures this package to adapt to many kinds of systems.
1509
1510Usage: $0 [OPTION]... [VAR=VALUE]...
1511
1512To assign environment variables (e.g., CC, CFLAGS...), specify them as
1513VAR=VALUE. See below for descriptions of some of the useful variables.
1514
1515Defaults for the options are specified in brackets.
1516
1517Configuration:
1518 -h, --help display this help and exit
1519 --help=short display options specific to this package
1520 --help=recursive display the short help of all the included packages
1521 -V, --version display version information and exit
d6a4bcb5 1522 -q, --quiet, --silent do not print \`checking ...' messages
b0cacab0
TT
1523 --cache-file=FILE cache test results in FILE [disabled]
1524 -C, --config-cache alias for \`--cache-file=config.cache'
1525 -n, --no-create do not create output files
1526 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1527
b0cacab0
TT
1528Installation directories:
1529 --prefix=PREFIX install architecture-independent files in PREFIX
39fd3d4f 1530 [$ac_default_prefix]
b0cacab0 1531 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
39fd3d4f 1532 [PREFIX]
b0cacab0
TT
1533
1534By default, \`make install' will install all the files in
1535\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1536an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1537for instance \`--prefix=\$HOME'.
1538
1539For better control, use the options below.
1540
1541Fine tuning of the installation directories:
39fd3d4f
SJR
1542 --bindir=DIR user executables [EPREFIX/bin]
1543 --sbindir=DIR system admin executables [EPREFIX/sbin]
1544 --libexecdir=DIR program executables [EPREFIX/libexec]
1545 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1546 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1547 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
2ab53829 1548 --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
39fd3d4f
SJR
1549 --libdir=DIR object code libraries [EPREFIX/lib]
1550 --includedir=DIR C header files [PREFIX/include]
1551 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1552 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1553 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1554 --infodir=DIR info documentation [DATAROOTDIR/info]
1555 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1556 --mandir=DIR man documentation [DATAROOTDIR/man]
1557 --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
1558 --htmldir=DIR html documentation [DOCDIR]
1559 --dvidir=DIR dvi documentation [DOCDIR]
1560 --pdfdir=DIR pdf documentation [DOCDIR]
1561 --psdir=DIR ps documentation [DOCDIR]
b0cacab0
TT
1562_ACEOF
1563
1564 cat <<\_ACEOF
1565
1566System types:
1567 --build=BUILD configure for building on BUILD [guessed]
1568 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1569_ACEOF
1570fi
1571
1572if test -n "$ac_init_help"; then
1573
1574 cat <<\_ACEOF
1575
1576Optional Features:
39fd3d4f 1577 --disable-option-checking ignore unrecognized --enable/--with options
b0cacab0
TT
1578 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1579 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
8c9e2921
TT
1580 --enable-maintainer-mode
1581 enable makefile rules useful for maintainers
1582 --enable-symlink-install
1583 use symlinks when installing instead of hard links
1584 --enable-relative-symlinks
1585 use relative symlinks when installing
91d11da1 1586
5aa6c3f6 1587 --enable-symlink-build use symlinks while building instead of hard links
8c9e2921
TT
1588 --enable-verbose-makecmds
1589 enable verbose make command output
1590 --enable-elf-shlibs select ELF shared libraries
1591 --enable-bsd-shlibs select BSD shared libraries
1592 --enable-profile build profiling libraries
1593 --enable-gcov build for coverage testing using gcov
1594 --enable-hardening build for coverage testing using gcov
1595 --enable-jbd-debug enable journal debugging
b0cacab0 1596 --enable-blkid-debug enable blkid debugging
8c9e2921
TT
1597 --disable-testio-debug disable the use of the test I/O manager for
1598 debugging
1599 --enable-developer-features
1600 enable features for use by ext4 developers
1601 --enable-libuuid build and use private uuid library
1602 --enable-libblkid build and use private blkid library
1603 --enable-subset enable subset-only build
1604 --disable-backtrace disable use backtrace
1605 --disable-debugfs disable support of debugfs program
1606 --disable-imager disable support of e2image program
1607 --disable-resizer disable support of e2resize program
1608 --disable-defrag disable support of e4defrag program
b0cacab0 1609 --enable-fsck build fsck wrapper program
8c9e2921
TT
1610 --enable-e2initrd-helper
1611 build e2initrd-helper program
3249394d 1612 --disable-tls disable use of thread local support
5610f992 1613 --disable-uuidd disable building the uuid daemon
d6a4bcb5 1614 --disable-mmp disable support mmp, Multi Mount Protection
749f0712 1615 --disable-tdb disable tdb support
8c9e2921 1616 --disable-bmap-stats disable collection of bitmap stats
1625bf42 1617 --enable-bmap-stats-ops enable collection of additional bitmap stats
b0cacab0
TT
1618 --disable-nls do not use Native Language Support
1619 --disable-rpath do not hardcode runtime library paths
8c9e2921
TT
1620 --disable-fuse2fs do not build fuse2fs
1621 --enable-lto enable link time optimization
1622 --enable-ubsan enable undefined behavior sanitizer
1623 --enable-addrsan enable address sanitizer
1624 --enable-threadsan enable thread sanitizer
2869485b 1625 --enable-fuzzing enable fuzzing sanitizer
a22e7f16 1626 --disable-largefile omit support for large files
b0cacab0
TT
1627
1628Optional Packages:
1629 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1630 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
3249394d 1631 --with-diet-libc use diet libc
0b5b9f90
TT
1632 --with-cc no longer supported, use CC= instead
1633 --with-ccopts no longer supported, use CFLAGS= instead
1634 --with-ldopts no longer supported, use LDFLAGS= instead
8c9e2921
TT
1635 --with-root-prefix=PREFIX
1636 override prefix variable for files to be placed in
1637 the root
bdcd5f22 1638 --without-pthread disable use of pthread support
93613951 1639 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
b0cacab0
TT
1640 --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
1641 --without-libiconv-prefix don't search for libiconv in includedir and libdir
b0cacab0
TT
1642 --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib
1643 --without-libintl-prefix don't search for libintl in includedir and libdir
8c9e2921 1644 --with-multiarch=ARCH specify the multiarch triplet
5ce368f0
DW
1645 --with-udev-rules-dir[=DIR]
1646 Install udev rules into DIR.
a2df5894
DW
1647 --with-crond-dir[=DIR] Install system crontabs into DIR.
1648 --with-systemd-unit-dir[=DIR]
1649 Install systemd system units into DIR.
b0cacab0
TT
1650
1651Some influential environment variables:
1652 CC C compiler command
1653 CFLAGS C compiler flags
1654 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1655 nonstandard directory <lib dir>
29a5deed 1656 LIBS libraries to pass to the linker, e.g. -l<library>
61ef2474 1657 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
e1052144 1658 you have headers in a nonstandard directory <include dir>
b0cacab0 1659 CPP C preprocessor
14b596d4 1660 PKG_CONFIG path to pkg-config utility
93613951
TT
1661 PKG_CONFIG_PATH
1662 directories to add to pkg-config's search path
1663 PKG_CONFIG_LIBDIR
1664 path overriding pkg-config's built-in search path
2869485b
TT
1665 CXX C++ compiler command
1666 CXXFLAGS C++ compiler flags
5ce368f0
DW
1667 udev_CFLAGS C compiler flags for udev, overriding pkg-config
1668 udev_LIBS linker flags for udev, overriding pkg-config
a2df5894
DW
1669 systemd_CFLAGS
1670 C compiler flags for systemd, overriding pkg-config
1671 systemd_LIBS
1672 linker flags for systemd, overriding pkg-config
b0cacab0
TT
1673
1674Use these variables to override the choices made by `configure' or to help
1675it to find libraries and programs with nonstandard names/locations.
1676
57aa50d4 1677Report bugs to the package provider.
b0cacab0 1678_ACEOF
e1052144 1679ac_status=$?
b0cacab0
TT
1680fi
1681
1682if test "$ac_init_help" = "recursive"; then
1683 # If there are subdirs, report their specific --help.
b0cacab0 1684 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
39fd3d4f
SJR
1685 test -d "$ac_dir" ||
1686 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1687 continue
b0cacab0
TT
1688 ac_builddir=.
1689
e1052144
TT
1690case "$ac_dir" in
1691.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1692*)
54445dc2 1693 ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'`
e1052144 1694 # A ".." for each directory in $ac_dir_suffix.
54445dc2 1695 ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
e1052144
TT
1696 case $ac_top_builddir_sub in
1697 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1698 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1699 esac ;;
1700esac
1701ac_abs_top_builddir=$ac_pwd
1702ac_abs_builddir=$ac_pwd$ac_dir_suffix
1703# for backward compatibility:
1704ac_top_builddir=$ac_top_build_prefix
b0cacab0
TT
1705
1706case $srcdir in
e1052144 1707 .) # We are building in place.
b0cacab0 1708 ac_srcdir=.
e1052144
TT
1709 ac_top_srcdir=$ac_top_builddir_sub
1710 ac_abs_top_srcdir=$ac_pwd ;;
1711 [\\/]* | ?:[\\/]* ) # Absolute name.
b0cacab0 1712 ac_srcdir=$srcdir$ac_dir_suffix;
e1052144
TT
1713 ac_top_srcdir=$srcdir
1714 ac_abs_top_srcdir=$srcdir ;;
1715 *) # Relative name.
1716 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1717 ac_top_srcdir=$ac_top_build_prefix$srcdir
1718 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
b0cacab0 1719esac
e1052144
TT
1720ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1721
1722 cd "$ac_dir" || { ac_status=$?; continue; }
54445dc2
TT
1723 # Check for configure.gnu first; this name is used for a wrapper for
1724 # Metaconfig's "Configure" on case-insensitive file systems.
e1052144
TT
1725 if test -f "$ac_srcdir/configure.gnu"; then
1726 echo &&
1727 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1728 elif test -f "$ac_srcdir/configure"; then
1729 echo &&
1730 $SHELL "$ac_srcdir/configure" --help=recursive
b0cacab0 1731 else
54445dc2 1732 printf "%s\n" "$as_me: WARNING: no configuration information is in $ac_dir" >&2
e1052144
TT
1733 fi || ac_status=$?
1734 cd "$ac_pwd" || { ac_status=$?; break; }
b0cacab0
TT
1735 done
1736fi
1737
e1052144 1738test -n "$ac_init_help" && exit $ac_status
b0cacab0
TT
1739if $ac_init_version; then
1740 cat <<\_ACEOF
e1052144 1741configure
54445dc2 1742generated by GNU Autoconf 2.71
b0cacab0 1743
54445dc2 1744Copyright (C) 2021 Free Software Foundation, Inc.
b0cacab0
TT
1745This configure script is free software; the Free Software Foundation
1746gives unlimited permission to copy, distribute and modify it.
1747_ACEOF
e1052144 1748 exit
b0cacab0 1749fi
b0cacab0 1750
57aa50d4
TT
1751## ------------------------ ##
1752## Autoconf initialization. ##
1753## ------------------------ ##
b0cacab0 1754
57aa50d4
TT
1755# ac_fn_c_try_compile LINENO
1756# --------------------------
1757# Try to compile conftest.$ac_ext, and return whether this succeeded.
1758ac_fn_c_try_compile ()
1759{
1760 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
54445dc2 1761 rm -f conftest.$ac_objext conftest.beam
57aa50d4
TT
1762 if { { ac_try="$ac_compile"
1763case "(($ac_try" in
1764 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1765 *) ac_try_echo=$ac_try;;
1766esac
1767eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
54445dc2 1768printf "%s\n" "$ac_try_echo"; } >&5
57aa50d4
TT
1769 (eval "$ac_compile") 2>conftest.err
1770 ac_status=$?
1771 if test -s conftest.err; then
1772 grep -v '^ *+' conftest.err >conftest.er1
1773 cat conftest.er1 >&5
1774 mv -f conftest.er1 conftest.err
1775 fi
54445dc2 1776 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
57aa50d4
TT
1777 test $ac_status = 0; } && {
1778 test -z "$ac_c_werror_flag" ||
1779 test ! -s conftest.err
54445dc2
TT
1780 } && test -s conftest.$ac_objext
1781then :
57aa50d4 1782 ac_retval=0
54445dc2
TT
1783else $as_nop
1784 printf "%s\n" "$as_me: failed program was:" >&5
57aa50d4 1785sed 's/^/| /' conftest.$ac_ext >&5
b0cacab0 1786
57aa50d4
TT
1787 ac_retval=1
1788fi
d6a4bcb5 1789 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
61ef2474 1790 as_fn_set_status $ac_retval
57aa50d4
TT
1791
1792} # ac_fn_c_try_compile
1793
54445dc2
TT
1794# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1795# -------------------------------------------------------
1796# Tests whether HEADER exists and can be compiled using the include files in
1797# INCLUDES, setting the cache variable VAR accordingly.
1798ac_fn_c_check_header_compile ()
1799{
1800 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1801 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1802printf %s "checking for $2... " >&6; }
1803if eval test \${$3+y}
1804then :
1805 printf %s "(cached) " >&6
1806else $as_nop
1807 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1808/* end confdefs.h. */
1809$4
1810#include <$2>
1811_ACEOF
1812if ac_fn_c_try_compile "$LINENO"
1813then :
1814 eval "$3=yes"
1815else $as_nop
1816 eval "$3=no"
1817fi
1818rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
1819fi
1820eval ac_res=\$$3
1821 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1822printf "%s\n" "$ac_res" >&6; }
1823 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1824
1825} # ac_fn_c_check_header_compile
1826
57aa50d4
TT
1827# ac_fn_c_try_link LINENO
1828# -----------------------
1829# Try to link conftest.$ac_ext, and return whether this succeeded.
1830ac_fn_c_try_link ()
b0cacab0 1831{
57aa50d4 1832 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
54445dc2 1833 rm -f conftest.$ac_objext conftest.beam conftest$ac_exeext
57aa50d4
TT
1834 if { { ac_try="$ac_link"
1835case "(($ac_try" in
1836 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1837 *) ac_try_echo=$ac_try;;
1838esac
1839eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
54445dc2 1840printf "%s\n" "$ac_try_echo"; } >&5
57aa50d4
TT
1841 (eval "$ac_link") 2>conftest.err
1842 ac_status=$?
1843 if test -s conftest.err; then
1844 grep -v '^ *+' conftest.err >conftest.er1
1845 cat conftest.er1 >&5
1846 mv -f conftest.er1 conftest.err
1847 fi
54445dc2 1848 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
57aa50d4
TT
1849 test $ac_status = 0; } && {
1850 test -z "$ac_c_werror_flag" ||
1851 test ! -s conftest.err
1852 } && test -s conftest$ac_exeext && {
1853 test "$cross_compiling" = yes ||
d6a4bcb5 1854 test -x conftest$ac_exeext
54445dc2
TT
1855 }
1856then :
57aa50d4 1857 ac_retval=0
54445dc2
TT
1858else $as_nop
1859 printf "%s\n" "$as_me: failed program was:" >&5
57aa50d4 1860sed 's/^/| /' conftest.$ac_ext >&5
b0cacab0 1861
57aa50d4
TT
1862 ac_retval=1
1863fi
1864 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1865 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1866 # interfere with the next link command; also delete a directory that is
1867 # left behind by Apple's compiler. We do this before executing the actions.
1868 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
d6a4bcb5 1869 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
61ef2474 1870 as_fn_set_status $ac_retval
b0cacab0 1871
57aa50d4 1872} # ac_fn_c_try_link
b0cacab0 1873
57aa50d4
TT
1874# ac_fn_c_try_cpp LINENO
1875# ----------------------
1876# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1877ac_fn_c_try_cpp ()
1878{
1879 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1880 if { { ac_try="$ac_cpp conftest.$ac_ext"
1881case "(($ac_try" in
1882 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1883 *) ac_try_echo=$ac_try;;
1884esac
1885eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
54445dc2 1886printf "%s\n" "$ac_try_echo"; } >&5
57aa50d4
TT
1887 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1888 ac_status=$?
1889 if test -s conftest.err; then
1890 grep -v '^ *+' conftest.err >conftest.er1
1891 cat conftest.er1 >&5
1892 mv -f conftest.er1 conftest.err
1893 fi
54445dc2 1894 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
d6a4bcb5 1895 test $ac_status = 0; } > conftest.i && {
57aa50d4
TT
1896 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1897 test ! -s conftest.err
54445dc2
TT
1898 }
1899then :
57aa50d4 1900 ac_retval=0
54445dc2
TT
1901else $as_nop
1902 printf "%s\n" "$as_me: failed program was:" >&5
57aa50d4 1903sed 's/^/| /' conftest.$ac_ext >&5
b0cacab0 1904
57aa50d4
TT
1905 ac_retval=1
1906fi
d6a4bcb5 1907 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
61ef2474 1908 as_fn_set_status $ac_retval
b0cacab0 1909
57aa50d4 1910} # ac_fn_c_try_cpp
b0cacab0 1911
57aa50d4
TT
1912# ac_fn_c_try_run LINENO
1913# ----------------------
54445dc2
TT
1914# Try to run conftest.$ac_ext, and return whether this succeeded. Assumes that
1915# executables *can* be run.
57aa50d4
TT
1916ac_fn_c_try_run ()
1917{
1918 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1919 if { { ac_try="$ac_link"
1920case "(($ac_try" in
1921 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1922 *) ac_try_echo=$ac_try;;
1923esac
1924eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
54445dc2 1925printf "%s\n" "$ac_try_echo"; } >&5
57aa50d4
TT
1926 (eval "$ac_link") 2>&5
1927 ac_status=$?
54445dc2 1928 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
57aa50d4
TT
1929 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1930 { { case "(($ac_try" in
1931 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1932 *) ac_try_echo=$ac_try;;
1933esac
1934eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
54445dc2 1935printf "%s\n" "$ac_try_echo"; } >&5
57aa50d4
TT
1936 (eval "$ac_try") 2>&5
1937 ac_status=$?
54445dc2
TT
1938 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1939 test $ac_status = 0; }; }
1940then :
57aa50d4 1941 ac_retval=0
54445dc2
TT
1942else $as_nop
1943 printf "%s\n" "$as_me: program exited with status $ac_status" >&5
1944 printf "%s\n" "$as_me: failed program was:" >&5
57aa50d4 1945sed 's/^/| /' conftest.$ac_ext >&5
b0cacab0 1946
57aa50d4
TT
1947 ac_retval=$ac_status
1948fi
1949 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
d6a4bcb5 1950 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
61ef2474 1951 as_fn_set_status $ac_retval
b0cacab0 1952
57aa50d4 1953} # ac_fn_c_try_run
b0cacab0 1954
57aa50d4
TT
1955# ac_fn_c_check_func LINENO FUNC VAR
1956# ----------------------------------
1957# Tests whether FUNC exists, setting the cache variable VAR accordingly
1958ac_fn_c_check_func ()
1959{
1960 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
54445dc2
TT
1961 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1962printf %s "checking for $2... " >&6; }
1963if eval test \${$3+y}
1964then :
1965 printf %s "(cached) " >&6
1966else $as_nop
57aa50d4
TT
1967 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1968/* end confdefs.h. */
1969/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
1970 For example, HP-UX 11i <limits.h> declares gettimeofday. */
1971#define $2 innocuous_$2
b0cacab0 1972
57aa50d4 1973/* System header to define __stub macros and hopefully few prototypes,
54445dc2 1974 which can conflict with char $2 (); below. */
a04eba3f 1975
54445dc2 1976#include <limits.h>
57aa50d4 1977#undef $2
07a0db15 1978
57aa50d4
TT
1979/* Override any GCC internal prototype to avoid an error.
1980 Use char because int might match the return type of a GCC
1981 builtin and then its argument prototype would still apply. */
1982#ifdef __cplusplus
1983extern "C"
1984#endif
1985char $2 ();
1986/* The GNU C library defines this for functions which it implements
1987 to always fail with ENOSYS. Some functions are actually named
1988 something starting with __ and the normal name is an alias. */
1989#if defined __stub_$2 || defined __stub___$2
1990choke me
1991#endif
74becf3c 1992
57aa50d4 1993int
54445dc2 1994main (void)
57aa50d4
TT
1995{
1996return $2 ();
1997 ;
1998 return 0;
1999}
2000_ACEOF
54445dc2
TT
2001if ac_fn_c_try_link "$LINENO"
2002then :
57aa50d4 2003 eval "$3=yes"
54445dc2 2004else $as_nop
57aa50d4
TT
2005 eval "$3=no"
2006fi
54445dc2 2007rm -f core conftest.err conftest.$ac_objext conftest.beam \
57aa50d4
TT
2008 conftest$ac_exeext conftest.$ac_ext
2009fi
2010eval ac_res=\$$3
54445dc2
TT
2011 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2012printf "%s\n" "$ac_res" >&6; }
d6a4bcb5 2013 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
93636bde 2014
57aa50d4 2015} # ac_fn_c_check_func
93636bde 2016
e598c29b
TT
2017# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2018# ----------------------------------------------------
2019# Tries to find if the field MEMBER exists in type AGGR, after including
2020# INCLUDES, setting cache variable VAR accordingly.
2021ac_fn_c_check_member ()
2022{
2023 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
54445dc2
TT
2024 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2025printf %s "checking for $2.$3... " >&6; }
2026if eval test \${$4+y}
2027then :
2028 printf %s "(cached) " >&6
2029else $as_nop
e598c29b
TT
2030 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2031/* end confdefs.h. */
2032$5
2033int
54445dc2 2034main (void)
e598c29b
TT
2035{
2036static $2 ac_aggr;
2037if (ac_aggr.$3)
2038return 0;
2039 ;
2040 return 0;
2041}
2042_ACEOF
54445dc2
TT
2043if ac_fn_c_try_compile "$LINENO"
2044then :
e598c29b 2045 eval "$4=yes"
54445dc2 2046else $as_nop
e598c29b
TT
2047 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2048/* end confdefs.h. */
2049$5
2050int
54445dc2 2051main (void)
e598c29b
TT
2052{
2053static $2 ac_aggr;
2054if (sizeof ac_aggr.$3)
2055return 0;
2056 ;
2057 return 0;
2058}
2059_ACEOF
54445dc2
TT
2060if ac_fn_c_try_compile "$LINENO"
2061then :
e598c29b 2062 eval "$4=yes"
54445dc2 2063else $as_nop
e598c29b
TT
2064 eval "$4=no"
2065fi
54445dc2 2066rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
e598c29b 2067fi
54445dc2 2068rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
e598c29b
TT
2069fi
2070eval ac_res=\$$4
54445dc2
TT
2071 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2072printf "%s\n" "$ac_res" >&6; }
e598c29b
TT
2073 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2074
2075} # ac_fn_c_check_member
2076
2077# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2078# -------------------------------------------
2079# Tests whether TYPE exists after having included INCLUDES, setting cache
2080# variable VAR accordingly.
2081ac_fn_c_check_type ()
2082{
2083 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
54445dc2
TT
2084 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2085printf %s "checking for $2... " >&6; }
2086if eval test \${$3+y}
2087then :
2088 printf %s "(cached) " >&6
2089else $as_nop
e598c29b
TT
2090 eval "$3=no"
2091 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2092/* end confdefs.h. */
2093$4
2094int
54445dc2 2095main (void)
e598c29b
TT
2096{
2097if (sizeof ($2))
2098 return 0;
2099 ;
2100 return 0;
2101}
2102_ACEOF
54445dc2
TT
2103if ac_fn_c_try_compile "$LINENO"
2104then :
e598c29b
TT
2105 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2106/* end confdefs.h. */
2107$4
2108int
54445dc2 2109main (void)
e598c29b
TT
2110{
2111if (sizeof (($2)))
2112 return 0;
2113 ;
2114 return 0;
2115}
2116_ACEOF
54445dc2
TT
2117if ac_fn_c_try_compile "$LINENO"
2118then :
e598c29b 2119
54445dc2 2120else $as_nop
e598c29b
TT
2121 eval "$3=yes"
2122fi
54445dc2 2123rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
e598c29b 2124fi
54445dc2 2125rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
e598c29b
TT
2126fi
2127eval ac_res=\$$3
54445dc2
TT
2128 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2129printf "%s\n" "$ac_res" >&6; }
e598c29b
TT
2130 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2131
2132} # ac_fn_c_check_type
2133
54445dc2
TT
2134# ac_fn_check_decl LINENO SYMBOL VAR INCLUDES EXTRA-OPTIONS FLAG-VAR
2135# ------------------------------------------------------------------
93613951 2136# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
54445dc2
TT
2137# accordingly. Pass EXTRA-OPTIONS to the compiler, using FLAG-VAR.
2138ac_fn_check_decl ()
d1154eb4
TT
2139{
2140 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
93613951 2141 as_decl_name=`echo $2|sed 's/ *(.*//'`
54445dc2
TT
2142 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2143printf %s "checking whether $as_decl_name is declared... " >&6; }
2144if eval test \${$3+y}
2145then :
2146 printf %s "(cached) " >&6
2147else $as_nop
93613951 2148 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
54445dc2
TT
2149 eval ac_save_FLAGS=\$$6
2150 as_fn_append $6 " $5"
93613951 2151 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
d1154eb4
TT
2152/* end confdefs.h. */
2153$4
93613951 2154int
54445dc2 2155main (void)
93613951
TT
2156{
2157#ifndef $as_decl_name
2158#ifdef __cplusplus
2159 (void) $as_decl_use;
2160#else
2161 (void) $as_decl_name;
2162#endif
2163#endif
2164
2165 ;
2166 return 0;
2167}
d1154eb4 2168_ACEOF
54445dc2
TT
2169if ac_fn_c_try_compile "$LINENO"
2170then :
93613951 2171 eval "$3=yes"
54445dc2 2172else $as_nop
93613951 2173 eval "$3=no"
d1154eb4 2174fi
54445dc2
TT
2175rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2176 eval $6=\$ac_save_FLAGS
2177
d1154eb4
TT
2178fi
2179eval ac_res=\$$3
54445dc2
TT
2180 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2181printf "%s\n" "$ac_res" >&6; }
d6a4bcb5 2182 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
d1154eb4 2183
54445dc2 2184} # ac_fn_check_decl
d1154eb4 2185
57aa50d4
TT
2186# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2187# --------------------------------------------
2188# Tries to find the compile-time value of EXPR in a program that includes
2189# INCLUDES, setting VAR accordingly. Returns whether the value could be
2190# computed
2191ac_fn_c_compute_int ()
2192{
2193 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2194 if test "$cross_compiling" = yes; then
2195 # Depending upon the size, compute the lo and hi bounds.
2196cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2197/* end confdefs.h. */
2198$4
2199int
54445dc2 2200main (void)
57aa50d4
TT
2201{
2202static int test_array [1 - 2 * !(($2) >= 0)];
d6a4bcb5
TB
2203test_array [0] = 0;
2204return test_array [0];
93636bde 2205
57aa50d4
TT
2206 ;
2207 return 0;
2208}
2209_ACEOF
54445dc2
TT
2210if ac_fn_c_try_compile "$LINENO"
2211then :
57aa50d4
TT
2212 ac_lo=0 ac_mid=0
2213 while :; do
2214 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2215/* end confdefs.h. */
2216$4
2217int
54445dc2 2218main (void)
57aa50d4
TT
2219{
2220static int test_array [1 - 2 * !(($2) <= $ac_mid)];
d6a4bcb5
TB
2221test_array [0] = 0;
2222return test_array [0];
93636bde 2223
57aa50d4
TT
2224 ;
2225 return 0;
2226}
2227_ACEOF
54445dc2
TT
2228if ac_fn_c_try_compile "$LINENO"
2229then :
57aa50d4 2230 ac_hi=$ac_mid; break
54445dc2 2231else $as_nop
57aa50d4
TT
2232 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2233 if test $ac_lo -le $ac_mid; then
2234 ac_lo= ac_hi=
2235 break
2236 fi
2237 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
b0cacab0 2238fi
54445dc2 2239rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
57aa50d4 2240 done
54445dc2 2241else $as_nop
57aa50d4
TT
2242 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2243/* end confdefs.h. */
2244$4
2245int
54445dc2 2246main (void)
57aa50d4
TT
2247{
2248static int test_array [1 - 2 * !(($2) < 0)];
d6a4bcb5
TB
2249test_array [0] = 0;
2250return test_array [0];
e1052144 2251
57aa50d4
TT
2252 ;
2253 return 0;
2254}
2255_ACEOF
54445dc2
TT
2256if ac_fn_c_try_compile "$LINENO"
2257then :
57aa50d4
TT
2258 ac_hi=-1 ac_mid=-1
2259 while :; do
2260 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2261/* end confdefs.h. */
2262$4
2263int
54445dc2 2264main (void)
57aa50d4
TT
2265{
2266static int test_array [1 - 2 * !(($2) >= $ac_mid)];
d6a4bcb5
TB
2267test_array [0] = 0;
2268return test_array [0];
93636bde 2269
57aa50d4
TT
2270 ;
2271 return 0;
2272}
2273_ACEOF
54445dc2
TT
2274if ac_fn_c_try_compile "$LINENO"
2275then :
57aa50d4 2276 ac_lo=$ac_mid; break
54445dc2 2277else $as_nop
57aa50d4
TT
2278 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2279 if test $ac_mid -le $ac_hi; then
2280 ac_lo= ac_hi=
2281 break
2282 fi
2283 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
93636bde 2284fi
54445dc2 2285rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
57aa50d4 2286 done
54445dc2 2287else $as_nop
57aa50d4
TT
2288 ac_lo= ac_hi=
2289fi
54445dc2 2290rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
57aa50d4 2291fi
54445dc2 2292rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
57aa50d4
TT
2293# Binary search between lo and hi bounds.
2294while test "x$ac_lo" != "x$ac_hi"; do
2295 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2296 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2297/* end confdefs.h. */
2298$4
2299int
54445dc2 2300main (void)
57aa50d4
TT
2301{
2302static int test_array [1 - 2 * !(($2) <= $ac_mid)];
d6a4bcb5
TB
2303test_array [0] = 0;
2304return test_array [0];
93636bde 2305
57aa50d4
TT
2306 ;
2307 return 0;
2308}
2309_ACEOF
54445dc2
TT
2310if ac_fn_c_try_compile "$LINENO"
2311then :
57aa50d4 2312 ac_hi=$ac_mid
54445dc2 2313else $as_nop
57aa50d4
TT
2314 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2315fi
54445dc2 2316rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
57aa50d4
TT
2317done
2318case $ac_lo in #((
2319?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2320'') ac_retval=1 ;;
927566a3 2321esac
57aa50d4
TT
2322 else
2323 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2324/* end confdefs.h. */
2325$4
54445dc2
TT
2326static long int longval (void) { return $2; }
2327static unsigned long int ulongval (void) { return $2; }
57aa50d4
TT
2328#include <stdio.h>
2329#include <stdlib.h>
2330int
54445dc2 2331main (void)
57aa50d4 2332{
927566a3 2333
57aa50d4
TT
2334 FILE *f = fopen ("conftest.val", "w");
2335 if (! f)
2336 return 1;
2337 if (($2) < 0)
2338 {
2339 long int i = longval ();
2340 if (i != ($2))
2341 return 1;
2342 fprintf (f, "%ld", i);
2343 }
2344 else
2345 {
2346 unsigned long int i = ulongval ();
2347 if (i != ($2))
2348 return 1;
2349 fprintf (f, "%lu", i);
2350 }
2351 /* Do not output a trailing newline, as this causes \r\n confusion
2352 on some platforms. */
2353 return ferror (f) || fclose (f) != 0;
93636bde 2354
57aa50d4
TT
2355 ;
2356 return 0;
2357}
2358_ACEOF
54445dc2
TT
2359if ac_fn_c_try_run "$LINENO"
2360then :
57aa50d4 2361 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
54445dc2 2362else $as_nop
57aa50d4
TT
2363 ac_retval=1
2364fi
2365rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2366 conftest.$ac_objext conftest.beam conftest.$ac_ext
2367rm -f conftest.val
93636bde 2368
57aa50d4 2369 fi
d6a4bcb5 2370 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
61ef2474 2371 as_fn_set_status $ac_retval
927566a3 2372
57aa50d4 2373} # ac_fn_c_compute_int
2869485b
TT
2374
2375# ac_fn_cxx_try_compile LINENO
2376# ----------------------------
2377# Try to compile conftest.$ac_ext, and return whether this succeeded.
2378ac_fn_cxx_try_compile ()
2379{
2380 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2381 rm -f conftest.$ac_objext conftest.beam
2382 if { { ac_try="$ac_compile"
2383case "(($ac_try" in
2384 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2385 *) ac_try_echo=$ac_try;;
2386esac
2387eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2388printf "%s\n" "$ac_try_echo"; } >&5
2389 (eval "$ac_compile") 2>conftest.err
2390 ac_status=$?
2391 if test -s conftest.err; then
2392 grep -v '^ *+' conftest.err >conftest.er1
2393 cat conftest.er1 >&5
2394 mv -f conftest.er1 conftest.err
2395 fi
2396 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2397 test $ac_status = 0; } && {
2398 test -z "$ac_cxx_werror_flag" ||
2399 test ! -s conftest.err
2400 } && test -s conftest.$ac_objext
2401then :
2402 ac_retval=0
2403else $as_nop
2404 printf "%s\n" "$as_me: failed program was:" >&5
2405sed 's/^/| /' conftest.$ac_ext >&5
2406
2407 ac_retval=1
2408fi
2409 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2410 as_fn_set_status $ac_retval
2411
2412} # ac_fn_cxx_try_compile
54445dc2
TT
2413ac_configure_args_raw=
2414for ac_arg
2415do
2416 case $ac_arg in
2417 *\'*)
2418 ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2419 esac
2420 as_fn_append ac_configure_args_raw " '$ac_arg'"
2421done
2422
2423case $ac_configure_args_raw in
2424 *$as_nl*)
2425 ac_safe_unquote= ;;
2426 *)
2427 ac_unsafe_z='|&;<>()$`\\"*?[ '' ' # This string ends in space, tab.
2428 ac_unsafe_a="$ac_unsafe_z#~"
2429 ac_safe_unquote="s/ '\\([^$ac_unsafe_a][^$ac_unsafe_z]*\\)'/ \\1/g"
2430 ac_configure_args_raw=` printf "%s\n" "$ac_configure_args_raw" | sed "$ac_safe_unquote"`;;
2431esac
2432
57aa50d4
TT
2433cat >config.log <<_ACEOF
2434This file contains any messages produced by compilers while
2435running configure, to aid debugging if configure makes a mistake.
93636bde 2436
57aa50d4 2437It was created by $as_me, which was
54445dc2 2438generated by GNU Autoconf 2.71. Invocation command line was
07a0db15 2439
54445dc2 2440 $ $0$ac_configure_args_raw
e1052144 2441
57aa50d4
TT
2442_ACEOF
2443exec 5>>config.log
2444{
2445cat <<_ASUNAME
2446## --------- ##
2447## Platform. ##
2448## --------- ##
0b5b9f90 2449
57aa50d4
TT
2450hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2451uname -m = `(uname -m) 2>/dev/null || echo unknown`
2452uname -r = `(uname -r) 2>/dev/null || echo unknown`
2453uname -s = `(uname -s) 2>/dev/null || echo unknown`
2454uname -v = `(uname -v) 2>/dev/null || echo unknown`
0b5b9f90 2455
57aa50d4
TT
2456/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2457/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
0b5b9f90 2458
57aa50d4
TT
2459/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2460/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2461/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2462/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2463/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2464/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2465/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
0b5b9f90 2466
57aa50d4 2467_ASUNAME
b0cacab0 2468
b0cacab0
TT
2469as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2470for as_dir in $PATH
2471do
2472 IFS=$as_save_IFS
54445dc2
TT
2473 case $as_dir in #(((
2474 '') as_dir=./ ;;
2475 */) ;;
2476 *) as_dir=$as_dir/ ;;
2477 esac
2478 printf "%s\n" "PATH: $as_dir"
57aa50d4 2479 done
e1052144 2480IFS=$as_save_IFS
b0cacab0 2481
57aa50d4 2482} >&5
74becf3c 2483
57aa50d4 2484cat >&5 <<_ACEOF
e1052144 2485
b0cacab0 2486
57aa50d4
TT
2487## ----------- ##
2488## Core tests. ##
2489## ----------- ##
b0cacab0 2490
57aa50d4 2491_ACEOF
b0cacab0 2492
57aa50d4
TT
2493
2494# Keep a trace of the command line.
2495# Strip out --no-create and --no-recursion so they do not pile up.
2496# Strip out --silent because we don't want to record it for future runs.
2497# Also quote any args containing shell meta-characters.
2498# Make two passes to allow for proper duplicate-argument suppression.
2499ac_configure_args=
2500ac_configure_args0=
2501ac_configure_args1=
2502ac_must_keep_next=false
2503for ac_pass in 1 2
b0cacab0 2504do
57aa50d4
TT
2505 for ac_arg
2506 do
2507 case $ac_arg in
2508 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2509 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2510 | -silent | --silent | --silen | --sile | --sil)
2511 continue ;;
2512 *\'*)
54445dc2 2513 ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
57aa50d4
TT
2514 esac
2515 case $ac_pass in
2516 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2517 2)
2518 as_fn_append ac_configure_args1 " '$ac_arg'"
2519 if test $ac_must_keep_next = true; then
2520 ac_must_keep_next=false # Got value, back to normal.
2521 else
2522 case $ac_arg in
2523 *=* | --config-cache | -C | -disable-* | --disable-* \
2524 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2525 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2526 | -with-* | --with-* | -without-* | --without-* | --x)
2527 case "$ac_configure_args0 " in
2528 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2529 esac
2530 ;;
2531 -* ) ac_must_keep_next=true ;;
2532 esac
2533 fi
2534 as_fn_append ac_configure_args " '$ac_arg'"
2535 ;;
2536 esac
2537 done
b0cacab0 2538done
57aa50d4
TT
2539{ ac_configure_args0=; unset ac_configure_args0;}
2540{ ac_configure_args1=; unset ac_configure_args1;}
2541
2542# When interrupted or exit'd, cleanup temporary files, and complete
2543# config.log. We remove comments because anyway the quotes in there
2544# would cause problems or look ugly.
2545# WARNING: Use '\'' to represent an apostrophe within the trap.
2546# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2547trap 'exit_status=$?
54445dc2
TT
2548 # Sanitize IFS.
2549 IFS=" "" $as_nl"
57aa50d4
TT
2550 # Save into config.log some information that might help in debugging.
2551 {
2552 echo
2553
54445dc2 2554 printf "%s\n" "## ---------------- ##
57aa50d4 2555## Cache variables. ##
d6a4bcb5 2556## ---------------- ##"
57aa50d4
TT
2557 echo
2558 # The following way of writing the cache mishandles newlines in values,
2559(
2560 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2561 eval ac_val=\$$ac_var
2562 case $ac_val in #(
2563 *${as_nl}*)
2564 case $ac_var in #(
54445dc2
TT
2565 *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2566printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
57aa50d4
TT
2567 esac
2568 case $ac_var in #(
2569 _ | IFS | as_nl) ;; #(
2570 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2571 *) { eval $ac_var=; unset $ac_var;} ;;
2572 esac ;;
2573 esac
2574 done
2575 (set) 2>&1 |
2576 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2577 *${as_nl}ac_space=\ *)
2578 sed -n \
2579 "s/'\''/'\''\\\\'\'''\''/g;
2580 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2581 ;; #(
2582 *)
2583 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2584 ;;
2585 esac |
2586 sort
2587)
2588 echo
2589
54445dc2 2590 printf "%s\n" "## ----------------- ##
57aa50d4 2591## Output variables. ##
d6a4bcb5 2592## ----------------- ##"
57aa50d4
TT
2593 echo
2594 for ac_var in $ac_subst_vars
2595 do
2596 eval ac_val=\$$ac_var
2597 case $ac_val in
54445dc2 2598 *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
57aa50d4 2599 esac
54445dc2 2600 printf "%s\n" "$ac_var='\''$ac_val'\''"
57aa50d4
TT
2601 done | sort
2602 echo
2603
2604 if test -n "$ac_subst_files"; then
54445dc2 2605 printf "%s\n" "## ------------------- ##
57aa50d4 2606## File substitutions. ##
d6a4bcb5 2607## ------------------- ##"
57aa50d4
TT
2608 echo
2609 for ac_var in $ac_subst_files
2610 do
2611 eval ac_val=\$$ac_var
2612 case $ac_val in
54445dc2 2613 *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
57aa50d4 2614 esac
54445dc2 2615 printf "%s\n" "$ac_var='\''$ac_val'\''"
57aa50d4
TT
2616 done | sort
2617 echo
2618 fi
2619
2620 if test -s confdefs.h; then
54445dc2 2621 printf "%s\n" "## ----------- ##
57aa50d4 2622## confdefs.h. ##
d6a4bcb5 2623## ----------- ##"
57aa50d4
TT
2624 echo
2625 cat confdefs.h
2626 echo
2627 fi
2628 test "$ac_signal" != 0 &&
54445dc2
TT
2629 printf "%s\n" "$as_me: caught signal $ac_signal"
2630 printf "%s\n" "$as_me: exit $exit_status"
57aa50d4
TT
2631 } >&5
2632 rm -f core *.core core.conftest.* &&
2633 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2634 exit $exit_status
2635' 0
2636for ac_signal in 1 2 13 15; do
2637 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
b0cacab0 2638done
57aa50d4 2639ac_signal=0
b0cacab0 2640
57aa50d4
TT
2641# confdefs.h avoids OS command line length limits that DEFS can exceed.
2642rm -f -r conftest* confdefs.h
b0cacab0 2643
54445dc2 2644printf "%s\n" "/* confdefs.h */" > confdefs.h
73ae2d4a 2645
57aa50d4
TT
2646# Predefined preprocessor variables.
2647
54445dc2 2648printf "%s\n" "#define PACKAGE_NAME \"$PACKAGE_NAME\"" >>confdefs.h
57aa50d4 2649
54445dc2 2650printf "%s\n" "#define PACKAGE_TARNAME \"$PACKAGE_TARNAME\"" >>confdefs.h
57aa50d4 2651
54445dc2 2652printf "%s\n" "#define PACKAGE_VERSION \"$PACKAGE_VERSION\"" >>confdefs.h
57aa50d4 2653
54445dc2 2654printf "%s\n" "#define PACKAGE_STRING \"$PACKAGE_STRING\"" >>confdefs.h
57aa50d4 2655
54445dc2 2656printf "%s\n" "#define PACKAGE_BUGREPORT \"$PACKAGE_BUGREPORT\"" >>confdefs.h
57aa50d4 2657
54445dc2 2658printf "%s\n" "#define PACKAGE_URL \"$PACKAGE_URL\"" >>confdefs.h
57aa50d4
TT
2659
2660
2661# Let the site file select an alternate cache file if it wants to.
2662# Prefer an explicitly selected file to automatically selected ones.
57aa50d4 2663if test -n "$CONFIG_SITE"; then
54445dc2 2664 ac_site_files="$CONFIG_SITE"
57aa50d4 2665elif test "x$prefix" != xNONE; then
54445dc2 2666 ac_site_files="$prefix/share/config.site $prefix/etc/config.site"
73ae2d4a 2667else
54445dc2 2668 ac_site_files="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
57aa50d4 2669fi
54445dc2
TT
2670
2671for ac_site_file in $ac_site_files
b0cacab0 2672do
54445dc2
TT
2673 case $ac_site_file in #(
2674 */*) :
2675 ;; #(
2676 *) :
2677 ac_site_file=./$ac_site_file ;;
2678esac
2679 if test -f "$ac_site_file" && test -r "$ac_site_file"; then
2680 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2681printf "%s\n" "$as_me: loading site script $ac_site_file" >&6;}
57aa50d4 2682 sed 's/^/| /' "$ac_site_file" >&5
d6a4bcb5 2683 . "$ac_site_file" \
54445dc2
TT
2684 || { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2685printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
d6a4bcb5
TB
2686as_fn_error $? "failed to load site script $ac_site_file
2687See \`config.log' for more details" "$LINENO" 5; }
b0cacab0
TT
2688 fi
2689done
b0cacab0 2690
57aa50d4 2691if test -r "$cache_file"; then
61ef2474
TT
2692 # Some versions of bash will fail to source /dev/null (special files
2693 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2694 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
54445dc2
TT
2695 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2696printf "%s\n" "$as_me: loading cache $cache_file" >&6;}
57aa50d4
TT
2697 case $cache_file in
2698 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2699 *) . "./$cache_file";;
2700 esac
73ae2d4a 2701 fi
57aa50d4 2702else
54445dc2
TT
2703 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2704printf "%s\n" "$as_me: creating cache $cache_file" >&6;}
57aa50d4 2705 >$cache_file
73ae2d4a 2706fi
57aa50d4 2707
54445dc2
TT
2708as_fn_append ac_header_c_list " stdio.h stdio_h HAVE_STDIO_H"
2709# Test code for whether the C compiler supports C89 (global declarations)
2710ac_c_conftest_c89_globals='
2711/* Does the compiler advertise C89 conformance?
2712 Do not test the value of __STDC__, because some compilers set it to 0
2713 while being otherwise adequately conformant. */
2714#if !defined __STDC__
2715# error "Compiler does not advertise C89 conformance"
2716#endif
57aa50d4 2717
54445dc2
TT
2718#include <stddef.h>
2719#include <stdarg.h>
2720struct stat;
2721/* Most of the following tests are stolen from RCS 5.7 src/conf.sh. */
2722struct buf { int x; };
2723struct buf * (*rcsopen) (struct buf *, struct stat *, int);
2724static char *e (p, i)
2725 char **p;
2726 int i;
2727{
2728 return p[i];
2729}
2730static char *f (char * (*g) (char **, int), char **p, ...)
2731{
2732 char *s;
2733 va_list v;
2734 va_start (v,p);
2735 s = g (p, va_arg (v,int));
2736 va_end (v);
2737 return s;
2738}
57aa50d4 2739
54445dc2
TT
2740/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
2741 function prototypes and stuff, but not \xHH hex character constants.
2742 These do not provoke an error unfortunately, instead are silently treated
2743 as an "x". The following induces an error, until -std is added to get
2744 proper ANSI mode. Curiously \x00 != x always comes out true, for an
2745 array size at least. It is necessary to write \x00 == 0 to get something
2746 that is true only with -std. */
2747int osf4_cc_array ['\''\x00'\'' == 0 ? 1 : -1];
57aa50d4 2748
54445dc2
TT
2749/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
2750 inside strings and character constants. */
2751#define FOO(x) '\''x'\''
2752int xlc6_cc_array[FOO(a) == '\''x'\'' ? 1 : -1];
57aa50d4 2753
54445dc2
TT
2754int test (int i, double x);
2755struct s1 {int (*f) (int a);};
2756struct s2 {int (*f) (double a);};
2757int pairnames (int, char **, int *(*)(struct buf *, struct stat *, int),
2758 int, int);'
57aa50d4 2759
54445dc2
TT
2760# Test code for whether the C compiler supports C89 (body of main).
2761ac_c_conftest_c89_main='
2762ok |= (argc == 0 || f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]);
2763'
57aa50d4 2764
54445dc2
TT
2765# Test code for whether the C compiler supports C99 (global declarations)
2766ac_c_conftest_c99_globals='
2767// Does the compiler advertise C99 conformance?
2768#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 199901L
2769# error "Compiler does not advertise C99 conformance"
2770#endif
57aa50d4 2771
54445dc2
TT
2772#include <stdbool.h>
2773extern int puts (const char *);
2774extern int printf (const char *, ...);
2775extern int dprintf (int, const char *, ...);
2776extern void *malloc (size_t);
2777
2778// Check varargs macros. These examples are taken from C99 6.10.3.5.
2779// dprintf is used instead of fprintf to avoid needing to declare
2780// FILE and stderr.
2781#define debug(...) dprintf (2, __VA_ARGS__)
2782#define showlist(...) puts (#__VA_ARGS__)
2783#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
2784static void
2785test_varargs_macros (void)
2786{
2787 int x = 1234;
2788 int y = 5678;
2789 debug ("Flag");
2790 debug ("X = %d\n", x);
2791 showlist (The first, second, and third items.);
2792 report (x>y, "x is %d but y is %d", x, y);
2793}
d1154eb4 2794
54445dc2
TT
2795// Check long long types.
2796#define BIG64 18446744073709551615ull
2797#define BIG32 4294967295ul
2798#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
2799#if !BIG_OK
2800 #error "your preprocessor is broken"
2801#endif
2802#if BIG_OK
2803#else
2804 #error "your preprocessor is broken"
2805#endif
2806static long long int bignum = -9223372036854775807LL;
2807static unsigned long long int ubignum = BIG64;
d1154eb4 2808
54445dc2
TT
2809struct incomplete_array
2810{
2811 int datasize;
2812 double data[];
2813};
57aa50d4 2814
54445dc2
TT
2815struct named_init {
2816 int number;
2817 const wchar_t *name;
2818 double average;
2819};
57aa50d4 2820
54445dc2 2821typedef const char *ccp;
57aa50d4 2822
54445dc2
TT
2823static inline int
2824test_restrict (ccp restrict text)
2825{
2826 // See if C++-style comments work.
2827 // Iterate through items via the restricted pointer.
2828 // Also check for declarations in for loops.
2829 for (unsigned int i = 0; *(text+i) != '\''\0'\''; ++i)
2830 continue;
2831 return 0;
2832}
57aa50d4 2833
54445dc2
TT
2834// Check varargs and va_copy.
2835static bool
2836test_varargs (const char *format, ...)
2837{
2838 va_list args;
2839 va_start (args, format);
2840 va_list args_copy;
2841 va_copy (args_copy, args);
57aa50d4 2842
54445dc2
TT
2843 const char *str = "";
2844 int number = 0;
2845 float fnumber = 0;
57aa50d4 2846
54445dc2
TT
2847 while (*format)
2848 {
2849 switch (*format++)
2850 {
2851 case '\''s'\'': // string
2852 str = va_arg (args_copy, const char *);
2853 break;
2854 case '\''d'\'': // int
2855 number = va_arg (args_copy, int);
2856 break;
2857 case '\''f'\'': // float
2858 fnumber = va_arg (args_copy, double);
2859 break;
2860 default:
2861 break;
2862 }
2863 }
2864 va_end (args_copy);
2865 va_end (args);
57aa50d4 2866
54445dc2
TT
2867 return *str && number && fnumber;
2868}
2869'
57aa50d4 2870
54445dc2
TT
2871# Test code for whether the C compiler supports C99 (body of main).
2872ac_c_conftest_c99_main='
2873 // Check bool.
2874 _Bool success = false;
2875 success |= (argc != 0);
2876
2877 // Check restrict.
2878 if (test_restrict ("String literal") == 0)
2879 success = true;
2880 char *restrict newvar = "Another string";
2881
2882 // Check varargs.
2883 success &= test_varargs ("s, d'\'' f .", "string", 65, 34.234);
2884 test_varargs_macros ();
2885
2886 // Check flexible array members.
2887 struct incomplete_array *ia =
2888 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
2889 ia->datasize = 10;
2890 for (int i = 0; i < ia->datasize; ++i)
2891 ia->data[i] = i * 1.234;
2892
2893 // Check named initializers.
2894 struct named_init ni = {
2895 .number = 34,
2896 .name = L"Test wide string",
2897 .average = 543.34343,
2898 };
2899
2900 ni.number = 58;
2901
2902 int dynamic_array[ni.number];
2903 dynamic_array[0] = argv[0][0];
2904 dynamic_array[ni.number - 1] = 543;
2905
2906 // work around unused variable warnings
2907 ok |= (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == '\''x'\''
2908 || dynamic_array[ni.number - 1] != 543);
2909'
57aa50d4 2910
54445dc2
TT
2911# Test code for whether the C compiler supports C11 (global declarations)
2912ac_c_conftest_c11_globals='
2913// Does the compiler advertise C11 conformance?
2914#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 201112L
2915# error "Compiler does not advertise C11 conformance"
2916#endif
57aa50d4 2917
54445dc2
TT
2918// Check _Alignas.
2919char _Alignas (double) aligned_as_double;
2920char _Alignas (0) no_special_alignment;
2921extern char aligned_as_int;
2922char _Alignas (0) _Alignas (int) aligned_as_int;
57aa50d4 2923
54445dc2
TT
2924// Check _Alignof.
2925enum
2926{
2927 int_alignment = _Alignof (int),
2928 int_array_alignment = _Alignof (int[100]),
2929 char_alignment = _Alignof (char)
2930};
2931_Static_assert (0 < -_Alignof (int), "_Alignof is signed");
57aa50d4 2932
54445dc2
TT
2933// Check _Noreturn.
2934int _Noreturn does_not_return (void) { for (;;) continue; }
5ce368f0 2935
54445dc2
TT
2936// Check _Static_assert.
2937struct test_static_assert
2938{
2939 int x;
2940 _Static_assert (sizeof (int) <= sizeof (long int),
2941 "_Static_assert does not work in struct");
2942 long int y;
2943};
2944
2945// Check UTF-8 literals.
2946#define u8 syntax error!
2947char const utf8_literal[] = u8"happens to be ASCII" "another string";
2948
2949// Check duplicate typedefs.
2950typedef long *long_ptr;
2951typedef long int *long_ptr;
2952typedef long_ptr long_ptr;
2953
2954// Anonymous structures and unions -- taken from C11 6.7.2.1 Example 1.
2955struct anonymous
2956{
2957 union {
2958 struct { int i; int j; };
2959 struct { int k; long int l; } w;
2960 };
2961 int m;
2962} v1;
2963'
6c59a665 2964
54445dc2
TT
2965# Test code for whether the C compiler supports C11 (body of main).
2966ac_c_conftest_c11_main='
2967 _Static_assert ((offsetof (struct anonymous, i)
2968 == offsetof (struct anonymous, w.k)),
2969 "Anonymous union alignment botch");
2970 v1.i = 2;
2971 v1.w.k = 5;
2972 ok |= v1.i != 5;
2973'
57aa50d4 2974
54445dc2
TT
2975# Test code for whether the C compiler supports C11 (complete).
2976ac_c_conftest_c11_program="${ac_c_conftest_c89_globals}
2977${ac_c_conftest_c99_globals}
2978${ac_c_conftest_c11_globals}
57aa50d4 2979
54445dc2
TT
2980int
2981main (int argc, char **argv)
2982{
2983 int ok = 0;
2984 ${ac_c_conftest_c89_main}
2985 ${ac_c_conftest_c99_main}
2986 ${ac_c_conftest_c11_main}
2987 return ok;
2988}
2989"
73ae2d4a 2990
54445dc2
TT
2991# Test code for whether the C compiler supports C99 (complete).
2992ac_c_conftest_c99_program="${ac_c_conftest_c89_globals}
2993${ac_c_conftest_c99_globals}
e1052144 2994
54445dc2
TT
2995int
2996main (int argc, char **argv)
2997{
2998 int ok = 0;
2999 ${ac_c_conftest_c89_main}
3000 ${ac_c_conftest_c99_main}
3001 return ok;
3002}
3003"
57aa50d4 3004
54445dc2
TT
3005# Test code for whether the C compiler supports C89 (complete).
3006ac_c_conftest_c89_program="${ac_c_conftest_c89_globals}
57aa50d4 3007
54445dc2
TT
3008int
3009main (int argc, char **argv)
3010{
3011 int ok = 0;
3012 ${ac_c_conftest_c89_main}
3013 return ok;
3014}
3015"
57aa50d4 3016
54445dc2
TT
3017as_fn_append ac_header_c_list " stdlib.h stdlib_h HAVE_STDLIB_H"
3018as_fn_append ac_header_c_list " string.h string_h HAVE_STRING_H"
3019as_fn_append ac_header_c_list " inttypes.h inttypes_h HAVE_INTTYPES_H"
3020as_fn_append ac_header_c_list " stdint.h stdint_h HAVE_STDINT_H"
3021as_fn_append ac_header_c_list " strings.h strings_h HAVE_STRINGS_H"
3022as_fn_append ac_header_c_list " sys/stat.h sys_stat_h HAVE_SYS_STAT_H"
3023as_fn_append ac_header_c_list " sys/types.h sys_types_h HAVE_SYS_TYPES_H"
3024as_fn_append ac_header_c_list " unistd.h unistd_h HAVE_UNISTD_H"
3025as_fn_append ac_header_c_list " wchar.h wchar_h HAVE_WCHAR_H"
3026as_fn_append ac_header_c_list " minix/config.h minix_config_h HAVE_MINIX_CONFIG_H"
3027gt_needs="$gt_needs "
3028as_fn_append ac_func_c_list " vprintf HAVE_VPRINTF"
2869485b
TT
3029# Test code for whether the C++ compiler supports C++98 (global declarations)
3030ac_cxx_conftest_cxx98_globals='
3031// Does the compiler advertise C++98 conformance?
3032#if !defined __cplusplus || __cplusplus < 199711L
3033# error "Compiler does not advertise C++98 conformance"
3034#endif
3035
3036// These inclusions are to reject old compilers that
3037// lack the unsuffixed header files.
3038#include <cstdlib>
3039#include <exception>
3040
3041// <cassert> and <cstring> are *not* freestanding headers in C++98.
3042extern void assert (int);
3043namespace std {
3044 extern int strcmp (const char *, const char *);
3045}
3046
3047// Namespaces, exceptions, and templates were all added after "C++ 2.0".
3048using std::exception;
3049using std::strcmp;
3050
3051namespace {
3052
3053void test_exception_syntax()
3054{
3055 try {
3056 throw "test";
3057 } catch (const char *s) {
3058 // Extra parentheses suppress a warning when building autoconf itself,
3059 // due to lint rules shared with more typical C programs.
3060 assert (!(strcmp) (s, "test"));
3061 }
3062}
3063
3064template <typename T> struct test_template
3065{
3066 T const val;
3067 explicit test_template(T t) : val(t) {}
3068 template <typename U> T add(U u) { return static_cast<T>(u) + val; }
3069};
3070
3071} // anonymous namespace
3072'
3073
3074# Test code for whether the C++ compiler supports C++98 (body of main)
3075ac_cxx_conftest_cxx98_main='
3076 assert (argc);
3077 assert (! argv[0]);
3078{
3079 test_exception_syntax ();
3080 test_template<double> tt (2.0);
3081 assert (tt.add (4) == 6.0);
3082 assert (true && !false);
3083}
3084'
3085
3086# Test code for whether the C++ compiler supports C++11 (global declarations)
3087ac_cxx_conftest_cxx11_globals='
3088// Does the compiler advertise C++ 2011 conformance?
3089#if !defined __cplusplus || __cplusplus < 201103L
3090# error "Compiler does not advertise C++11 conformance"
3091#endif
3092
3093namespace cxx11test
3094{
3095 constexpr int get_val() { return 20; }
3096
3097 struct testinit
3098 {
3099 int i;
3100 double d;
3101 };
3102
3103 class delegate
3104 {
3105 public:
3106 delegate(int n) : n(n) {}
3107 delegate(): delegate(2354) {}
3108
3109 virtual int getval() { return this->n; };
3110 protected:
3111 int n;
3112 };
3113
3114 class overridden : public delegate
3115 {
3116 public:
3117 overridden(int n): delegate(n) {}
3118 virtual int getval() override final { return this->n * 2; }
3119 };
3120
3121 class nocopy
3122 {
3123 public:
3124 nocopy(int i): i(i) {}
3125 nocopy() = default;
3126 nocopy(const nocopy&) = delete;
3127 nocopy & operator=(const nocopy&) = delete;
3128 private:
3129 int i;
3130 };
3131
3132 // for testing lambda expressions
3133 template <typename Ret, typename Fn> Ret eval(Fn f, Ret v)
3134 {
3135 return f(v);
3136 }
3137
3138 // for testing variadic templates and trailing return types
3139 template <typename V> auto sum(V first) -> V
3140 {
3141 return first;
3142 }
3143 template <typename V, typename... Args> auto sum(V first, Args... rest) -> V
3144 {
3145 return first + sum(rest...);
3146 }
3147}
3148'
3149
3150# Test code for whether the C++ compiler supports C++11 (body of main)
3151ac_cxx_conftest_cxx11_main='
3152{
3153 // Test auto and decltype
3154 auto a1 = 6538;
3155 auto a2 = 48573953.4;
3156 auto a3 = "String literal";
3157
3158 int total = 0;
3159 for (auto i = a3; *i; ++i) { total += *i; }
3160
3161 decltype(a2) a4 = 34895.034;
3162}
3163{
3164 // Test constexpr
3165 short sa[cxx11test::get_val()] = { 0 };
3166}
3167{
3168 // Test initializer lists
3169 cxx11test::testinit il = { 4323, 435234.23544 };
3170}
3171{
3172 // Test range-based for
3173 int array[] = {9, 7, 13, 15, 4, 18, 12, 10, 5, 3,
3174 14, 19, 17, 8, 6, 20, 16, 2, 11, 1};
3175 for (auto &x : array) { x += 23; }
3176}
3177{
3178 // Test lambda expressions
3179 using cxx11test::eval;
3180 assert (eval ([](int x) { return x*2; }, 21) == 42);
3181 double d = 2.0;
3182 assert (eval ([&](double x) { return d += x; }, 3.0) == 5.0);
3183 assert (d == 5.0);
3184 assert (eval ([=](double x) mutable { return d += x; }, 4.0) == 9.0);
3185 assert (d == 5.0);
3186}
3187{
3188 // Test use of variadic templates
3189 using cxx11test::sum;
3190 auto a = sum(1);
3191 auto b = sum(1, 2);
3192 auto c = sum(1.0, 2.0, 3.0);
3193}
3194{
3195 // Test constructor delegation
3196 cxx11test::delegate d1;
3197 cxx11test::delegate d2();
3198 cxx11test::delegate d3(45);
3199}
3200{
3201 // Test override and final
3202 cxx11test::overridden o1(55464);
3203}
3204{
3205 // Test nullptr
3206 char *c = nullptr;
3207}
3208{
3209 // Test template brackets
3210 test_template<::test_template<int>> v(test_template<int>(12));
3211}
3212{
3213 // Unicode literals
3214 char const *utf8 = u8"UTF-8 string \u2500";
3215 char16_t const *utf16 = u"UTF-8 string \u2500";
3216 char32_t const *utf32 = U"UTF-32 string \u2500";
3217}
3218'
3219
3220# Test code for whether the C compiler supports C++11 (complete).
3221ac_cxx_conftest_cxx11_program="${ac_cxx_conftest_cxx98_globals}
3222${ac_cxx_conftest_cxx11_globals}
3223
3224int
3225main (int argc, char **argv)
3226{
3227 int ok = 0;
3228 ${ac_cxx_conftest_cxx98_main}
3229 ${ac_cxx_conftest_cxx11_main}
3230 return ok;
3231}
3232"
3233
3234# Test code for whether the C compiler supports C++98 (complete).
3235ac_cxx_conftest_cxx98_program="${ac_cxx_conftest_cxx98_globals}
3236int
3237main (int argc, char **argv)
3238{
3239 int ok = 0;
3240 ${ac_cxx_conftest_cxx98_main}
3241 return ok;
3242}
3243"
3244
54445dc2
TT
3245
3246# Auxiliary files required by this configure script.
3247ac_aux_files="config.rpath install-sh config.guess config.sub"
3248
3249# Locations in which to look for auxiliary files.
3250ac_aux_dir_candidates="${srcdir}/config"
3251
3252# Search for a directory containing all of the required auxiliary files,
3253# $ac_aux_files, from the $PATH-style list $ac_aux_dir_candidates.
3254# If we don't find one directory that contains all the files we need,
3255# we report the set of missing files from the *first* directory in
3256# $ac_aux_dir_candidates and give up.
3257ac_missing_aux_files=""
3258ac_first_candidate=:
3259printf "%s\n" "$as_me:${as_lineno-$LINENO}: looking for aux files: $ac_aux_files" >&5
b0cacab0 3260as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
54445dc2
TT
3261as_found=false
3262for as_dir in $ac_aux_dir_candidates
b0cacab0
TT
3263do
3264 IFS=$as_save_IFS
54445dc2
TT
3265 case $as_dir in #(((
3266 '') as_dir=./ ;;
3267 */) ;;
3268 *) as_dir=$as_dir/ ;;
3269 esac
3270 as_found=:
3271
3272 printf "%s\n" "$as_me:${as_lineno-$LINENO}: trying $as_dir" >&5
3273 ac_aux_dir_found=yes
3274 ac_install_sh=
3275 for ac_aux in $ac_aux_files
3276 do
3277 # As a special case, if "install-sh" is required, that requirement
3278 # can be satisfied by any of "install-sh", "install.sh", or "shtool",
3279 # and $ac_install_sh is set appropriately for whichever one is found.
3280 if test x"$ac_aux" = x"install-sh"
3281 then
3282 if test -f "${as_dir}install-sh"; then
3283 printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}install-sh found" >&5
3284 ac_install_sh="${as_dir}install-sh -c"
3285 elif test -f "${as_dir}install.sh"; then
3286 printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}install.sh found" >&5
3287 ac_install_sh="${as_dir}install.sh -c"
3288 elif test -f "${as_dir}shtool"; then
3289 printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}shtool found" >&5
3290 ac_install_sh="${as_dir}shtool install -c"
3291 else
3292 ac_aux_dir_found=no
3293 if $ac_first_candidate; then
3294 ac_missing_aux_files="${ac_missing_aux_files} install-sh"
3295 else
3296 break
3297 fi
3298 fi
3299 else
3300 if test -f "${as_dir}${ac_aux}"; then
3301 printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}${ac_aux} found" >&5
3302 else
3303 ac_aux_dir_found=no
3304 if $ac_first_candidate; then
3305 ac_missing_aux_files="${ac_missing_aux_files} ${ac_aux}"
3306 else
3307 break
3308 fi
3309 fi
3310 fi
3311 done
3312 if test "$ac_aux_dir_found" = yes; then
3313 ac_aux_dir="$as_dir"
3314 break
b0cacab0 3315 fi
54445dc2
TT
3316 ac_first_candidate=false
3317
3318 as_found=false
b0cacab0 3319done
e1052144 3320IFS=$as_save_IFS
54445dc2
TT
3321if $as_found
3322then :
b0cacab0 3323
54445dc2
TT
3324else $as_nop
3325 as_fn_error $? "cannot find required auxiliary files:$ac_missing_aux_files" "$LINENO" 5
73ae2d4a 3326fi
b0cacab0 3327
e1052144 3328
54445dc2
TT
3329# These three variables are undocumented and unsupported,
3330# and are intended to be withdrawn in a future Autoconf release.
3331# They can cause serious problems if a builder's source tree is in a directory
3332# whose full name contains unusual characters.
3333if test -f "${ac_aux_dir}config.guess"; then
3334 ac_config_guess="$SHELL ${ac_aux_dir}config.guess"
b0cacab0 3335fi
54445dc2
TT
3336if test -f "${ac_aux_dir}config.sub"; then
3337 ac_config_sub="$SHELL ${ac_aux_dir}config.sub"
b0cacab0 3338fi
54445dc2
TT
3339if test -f "$ac_aux_dir/configure"; then
3340 ac_configure="$SHELL ${ac_aux_dir}configure"
07a0db15 3341fi
73ae2d4a 3342
54445dc2
TT
3343# Check that the precious variables saved in the cache have kept the same
3344# value.
3345ac_cache_corrupted=false
3346for ac_var in $ac_precious_vars; do
3347 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3348 eval ac_new_set=\$ac_env_${ac_var}_set
3349 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3350 eval ac_new_val=\$ac_env_${ac_var}_value
3351 case $ac_old_set,$ac_new_set in
3352 set,)
3353 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3354printf "%s\n" "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3355 ac_cache_corrupted=: ;;
3356 ,set)
3357 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3358printf "%s\n" "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3359 ac_cache_corrupted=: ;;
3360 ,);;
3361 *)
3362 if test "x$ac_old_val" != "x$ac_new_val"; then
3363 # differences in whitespace do not lead to failure.
3364 ac_old_val_w=`echo x $ac_old_val`
3365 ac_new_val_w=`echo x $ac_new_val`
3366 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3367 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3368printf "%s\n" "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3369 ac_cache_corrupted=:
3370 else
3371 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3372printf "%s\n" "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3373 eval $ac_var=\$ac_old_val
3374 fi
3375 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3376printf "%s\n" "$as_me: former value: \`$ac_old_val'" >&2;}
3377 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3378printf "%s\n" "$as_me: current value: \`$ac_new_val'" >&2;}
3379 fi;;
3380 esac
3381 # Pass precious variables to config.status.
3382 if test "$ac_new_set" = set; then
3383 case $ac_new_val in
3384 *\'*) ac_arg=$ac_var=`printf "%s\n" "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3385 *) ac_arg=$ac_var=$ac_new_val ;;
3386 esac
3387 case " $ac_configure_args " in
3388 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3389 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3390 esac
3391 fi
3392done
3393if $ac_cache_corrupted; then
3394 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3395printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
3396 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3397printf "%s\n" "$as_me: error: changes in the environment can compromise the build" >&2;}
3398 as_fn_error $? "run \`${MAKE-make} distclean' and/or \`rm $cache_file'
3399 and start over" "$LINENO" 5
3400fi
3401## -------------------- ##
3402## Main body of script. ##
3403## -------------------- ##
3404
3405ac_ext=c
3406ac_cpp='$CPP $CPPFLAGS'
3407ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3408ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3409ac_compiler_gnu=$ac_cv_c_compiler_gnu
3410
3411
3412
3413
3414
3415ac_config_headers="$ac_config_headers lib/config.h"
3416
3417
3418
3419
3420
3421
3422
3423
3424
3425
3426
3427ac_ext=c
3428ac_cpp='$CPP $CPPFLAGS'
3429ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3430ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3431ac_compiler_gnu=$ac_cv_c_compiler_gnu
3432if test -n "$ac_tool_prefix"; then
3433 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3434set dummy ${ac_tool_prefix}gcc; ac_word=$2
3435{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3436printf %s "checking for $ac_word... " >&6; }
3437if test ${ac_cv_prog_CC+y}
3438then :
3439 printf %s "(cached) " >&6
3440else $as_nop
3441 if test -n "$CC"; then
3442 ac_cv_prog_CC="$CC" # Let the user override the test.
3443else
3444as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3445for as_dir in $PATH
3446do
3447 IFS=$as_save_IFS
3448 case $as_dir in #(((
3449 '') as_dir=./ ;;
3450 */) ;;
3451 *) as_dir=$as_dir/ ;;
3452 esac
3453 for ac_exec_ext in '' $ac_executable_extensions; do
3454 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3455 ac_cv_prog_CC="${ac_tool_prefix}gcc"
3456 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3457 break 2
3458 fi
3459done
3460 done
3461IFS=$as_save_IFS
3462
3463fi
3464fi
3465CC=$ac_cv_prog_CC
3466if test -n "$CC"; then
3467 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3468printf "%s\n" "$CC" >&6; }
3469else
3470 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3471printf "%s\n" "no" >&6; }
3472fi
3473
3474
3475fi
3476if test -z "$ac_cv_prog_CC"; then
3477 ac_ct_CC=$CC
3478 # Extract the first word of "gcc", so it can be a program name with args.
3479set dummy gcc; ac_word=$2
3480{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3481printf %s "checking for $ac_word... " >&6; }
3482if test ${ac_cv_prog_ac_ct_CC+y}
3483then :
3484 printf %s "(cached) " >&6
3485else $as_nop
3486 if test -n "$ac_ct_CC"; then
3487 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3488else
3489as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3490for as_dir in $PATH
3491do
3492 IFS=$as_save_IFS
3493 case $as_dir in #(((
3494 '') as_dir=./ ;;
3495 */) ;;
3496 *) as_dir=$as_dir/ ;;
3497 esac
3498 for ac_exec_ext in '' $ac_executable_extensions; do
3499 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3500 ac_cv_prog_ac_ct_CC="gcc"
3501 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3502 break 2
3503 fi
3504done
3505 done
3506IFS=$as_save_IFS
3507
3508fi
3509fi
3510ac_ct_CC=$ac_cv_prog_ac_ct_CC
3511if test -n "$ac_ct_CC"; then
3512 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3513printf "%s\n" "$ac_ct_CC" >&6; }
3514else
3515 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3516printf "%s\n" "no" >&6; }
3517fi
3518
3519 if test "x$ac_ct_CC" = x; then
3520 CC=""
3521 else
3522 case $cross_compiling:$ac_tool_warned in
3523yes:)
3524{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3525printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3526ac_tool_warned=yes ;;
3527esac
3528 CC=$ac_ct_CC
e1052144 3529 fi
57aa50d4
TT
3530else
3531 CC="$ac_cv_prog_CC"
b0cacab0
TT
3532fi
3533
57aa50d4
TT
3534if test -z "$CC"; then
3535 if test -n "$ac_tool_prefix"; then
3536 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3537set dummy ${ac_tool_prefix}cc; ac_word=$2
54445dc2
TT
3538{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3539printf %s "checking for $ac_word... " >&6; }
3540if test ${ac_cv_prog_CC+y}
3541then :
3542 printf %s "(cached) " >&6
3543else $as_nop
57aa50d4
TT
3544 if test -n "$CC"; then
3545 ac_cv_prog_CC="$CC" # Let the user override the test.
3546else
3547as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3548for as_dir in $PATH
3549do
3550 IFS=$as_save_IFS
54445dc2
TT
3551 case $as_dir in #(((
3552 '') as_dir=./ ;;
3553 */) ;;
3554 *) as_dir=$as_dir/ ;;
3555 esac
57aa50d4 3556 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 3557 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 3558 ac_cv_prog_CC="${ac_tool_prefix}cc"
54445dc2 3559 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
3560 break 2
3561 fi
3562done
3563 done
3564IFS=$as_save_IFS
3565
3566fi
3567fi
3568CC=$ac_cv_prog_CC
3569if test -n "$CC"; then
54445dc2
TT
3570 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3571printf "%s\n" "$CC" >&6; }
57aa50d4 3572else
54445dc2
TT
3573 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3574printf "%s\n" "no" >&6; }
57aa50d4
TT
3575fi
3576
3577
3578 fi
3579fi
3580if test -z "$CC"; then
3581 # Extract the first word of "cc", so it can be a program name with args.
3582set dummy cc; ac_word=$2
54445dc2
TT
3583{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3584printf %s "checking for $ac_word... " >&6; }
3585if test ${ac_cv_prog_CC+y}
3586then :
3587 printf %s "(cached) " >&6
3588else $as_nop
57aa50d4
TT
3589 if test -n "$CC"; then
3590 ac_cv_prog_CC="$CC" # Let the user override the test.
3591else
3592 ac_prog_rejected=no
3593as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3594for as_dir in $PATH
3595do
3596 IFS=$as_save_IFS
54445dc2
TT
3597 case $as_dir in #(((
3598 '') as_dir=./ ;;
3599 */) ;;
3600 *) as_dir=$as_dir/ ;;
3601 esac
57aa50d4 3602 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
3603 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3604 if test "$as_dir$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
57aa50d4
TT
3605 ac_prog_rejected=yes
3606 continue
3607 fi
3608 ac_cv_prog_CC="cc"
54445dc2 3609 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
3610 break 2
3611 fi
3612done
3613 done
3614IFS=$as_save_IFS
3615
3616if test $ac_prog_rejected = yes; then
3617 # We found a bogon in the path, so make sure we never use it.
3618 set dummy $ac_cv_prog_CC
3619 shift
3620 if test $# != 0; then
3621 # We chose a different compiler from the bogus one.
3622 # However, it has the same basename, so the bogon will be chosen
3623 # first if we set CC to just the basename; use the full file name.
3624 shift
54445dc2 3625 ac_cv_prog_CC="$as_dir$ac_word${1+' '}$@"
57aa50d4
TT
3626 fi
3627fi
3628fi
3629fi
3630CC=$ac_cv_prog_CC
3631if test -n "$CC"; then
54445dc2
TT
3632 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3633printf "%s\n" "$CC" >&6; }
57aa50d4 3634else
54445dc2
TT
3635 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3636printf "%s\n" "no" >&6; }
57aa50d4
TT
3637fi
3638
3639
3640fi
3641if test -z "$CC"; then
3642 if test -n "$ac_tool_prefix"; then
3643 for ac_prog in cl.exe
3644 do
3645 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3646set dummy $ac_tool_prefix$ac_prog; ac_word=$2
54445dc2
TT
3647{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3648printf %s "checking for $ac_word... " >&6; }
3649if test ${ac_cv_prog_CC+y}
3650then :
3651 printf %s "(cached) " >&6
3652else $as_nop
57aa50d4
TT
3653 if test -n "$CC"; then
3654 ac_cv_prog_CC="$CC" # Let the user override the test.
3655else
3656as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3657for as_dir in $PATH
3658do
3659 IFS=$as_save_IFS
54445dc2
TT
3660 case $as_dir in #(((
3661 '') as_dir=./ ;;
3662 */) ;;
3663 *) as_dir=$as_dir/ ;;
3664 esac
57aa50d4 3665 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 3666 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 3667 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
54445dc2 3668 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
3669 break 2
3670 fi
3671done
3672 done
3673IFS=$as_save_IFS
3674
3675fi
3676fi
3677CC=$ac_cv_prog_CC
3678if test -n "$CC"; then
54445dc2
TT
3679 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3680printf "%s\n" "$CC" >&6; }
57aa50d4 3681else
54445dc2
TT
3682 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3683printf "%s\n" "no" >&6; }
57aa50d4
TT
3684fi
3685
3686
3687 test -n "$CC" && break
3688 done
3689fi
3690if test -z "$CC"; then
3691 ac_ct_CC=$CC
3692 for ac_prog in cl.exe
3693do
3694 # Extract the first word of "$ac_prog", so it can be a program name with args.
3695set dummy $ac_prog; ac_word=$2
54445dc2
TT
3696{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3697printf %s "checking for $ac_word... " >&6; }
3698if test ${ac_cv_prog_ac_ct_CC+y}
3699then :
3700 printf %s "(cached) " >&6
3701else $as_nop
57aa50d4
TT
3702 if test -n "$ac_ct_CC"; then
3703 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3704else
3705as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3706for as_dir in $PATH
3707do
3708 IFS=$as_save_IFS
54445dc2
TT
3709 case $as_dir in #(((
3710 '') as_dir=./ ;;
3711 */) ;;
3712 *) as_dir=$as_dir/ ;;
3713 esac
57aa50d4 3714 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 3715 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 3716 ac_cv_prog_ac_ct_CC="$ac_prog"
54445dc2 3717 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
3718 break 2
3719 fi
3720done
3721 done
3722IFS=$as_save_IFS
3723
3724fi
3725fi
3726ac_ct_CC=$ac_cv_prog_ac_ct_CC
3727if test -n "$ac_ct_CC"; then
54445dc2
TT
3728 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3729printf "%s\n" "$ac_ct_CC" >&6; }
57aa50d4 3730else
54445dc2
TT
3731 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3732printf "%s\n" "no" >&6; }
57aa50d4
TT
3733fi
3734
3735
3736 test -n "$ac_ct_CC" && break
3737done
3738
3739 if test "x$ac_ct_CC" = x; then
3740 CC=""
3741 else
3742 case $cross_compiling:$ac_tool_warned in
3743yes:)
54445dc2
TT
3744{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3745printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3746ac_tool_warned=yes ;;
3747esac
3748 CC=$ac_ct_CC
3749 fi
3750fi
3751
3752fi
3753if test -z "$CC"; then
3754 if test -n "$ac_tool_prefix"; then
3755 # Extract the first word of "${ac_tool_prefix}clang", so it can be a program name with args.
3756set dummy ${ac_tool_prefix}clang; ac_word=$2
3757{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3758printf %s "checking for $ac_word... " >&6; }
3759if test ${ac_cv_prog_CC+y}
3760then :
3761 printf %s "(cached) " >&6
3762else $as_nop
3763 if test -n "$CC"; then
3764 ac_cv_prog_CC="$CC" # Let the user override the test.
3765else
3766as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3767for as_dir in $PATH
3768do
3769 IFS=$as_save_IFS
3770 case $as_dir in #(((
3771 '') as_dir=./ ;;
3772 */) ;;
3773 *) as_dir=$as_dir/ ;;
3774 esac
3775 for ac_exec_ext in '' $ac_executable_extensions; do
3776 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3777 ac_cv_prog_CC="${ac_tool_prefix}clang"
3778 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3779 break 2
3780 fi
3781done
3782 done
3783IFS=$as_save_IFS
3784
3785fi
3786fi
3787CC=$ac_cv_prog_CC
3788if test -n "$CC"; then
3789 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3790printf "%s\n" "$CC" >&6; }
3791else
3792 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3793printf "%s\n" "no" >&6; }
3794fi
3795
3796
3797fi
3798if test -z "$ac_cv_prog_CC"; then
3799 ac_ct_CC=$CC
3800 # Extract the first word of "clang", so it can be a program name with args.
3801set dummy clang; ac_word=$2
3802{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3803printf %s "checking for $ac_word... " >&6; }
3804if test ${ac_cv_prog_ac_ct_CC+y}
3805then :
3806 printf %s "(cached) " >&6
3807else $as_nop
3808 if test -n "$ac_ct_CC"; then
3809 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3810else
3811as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3812for as_dir in $PATH
3813do
3814 IFS=$as_save_IFS
3815 case $as_dir in #(((
3816 '') as_dir=./ ;;
3817 */) ;;
3818 *) as_dir=$as_dir/ ;;
3819 esac
3820 for ac_exec_ext in '' $ac_executable_extensions; do
3821 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3822 ac_cv_prog_ac_ct_CC="clang"
3823 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3824 break 2
3825 fi
3826done
3827 done
3828IFS=$as_save_IFS
3829
3830fi
3831fi
3832ac_ct_CC=$ac_cv_prog_ac_ct_CC
3833if test -n "$ac_ct_CC"; then
3834 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3835printf "%s\n" "$ac_ct_CC" >&6; }
3836else
3837 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3838printf "%s\n" "no" >&6; }
3839fi
3840
3841 if test "x$ac_ct_CC" = x; then
3842 CC=""
3843 else
3844 case $cross_compiling:$ac_tool_warned in
3845yes:)
3846{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3847printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
57aa50d4
TT
3848ac_tool_warned=yes ;;
3849esac
3850 CC=$ac_ct_CC
3851 fi
54445dc2
TT
3852else
3853 CC="$ac_cv_prog_CC"
57aa50d4
TT
3854fi
3855
3856fi
3857
3858
54445dc2
TT
3859test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3860printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
d6a4bcb5
TB
3861as_fn_error $? "no acceptable C compiler found in \$PATH
3862See \`config.log' for more details" "$LINENO" 5; }
b0cacab0
TT
3863
3864# Provide some information about the compiler.
54445dc2 3865printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
39fd3d4f
SJR
3866set X $ac_compile
3867ac_compiler=$2
54445dc2 3868for ac_option in --version -v -V -qversion -version; do
57aa50d4 3869 { { ac_try="$ac_compiler $ac_option >&5"
e1052144
TT
3870case "(($ac_try" in
3871 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3872 *) ac_try_echo=$ac_try;;
3873esac
57aa50d4 3874eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
54445dc2 3875printf "%s\n" "$ac_try_echo"; } >&5
57aa50d4 3876 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
b0cacab0 3877 ac_status=$?
57aa50d4
TT
3878 if test -s conftest.err; then
3879 sed '10a\
3880... rest of stderr output deleted ...
3881 10q' conftest.err >conftest.er1
3882 cat conftest.er1 >&5
57aa50d4 3883 fi
61ef2474 3884 rm -f conftest.er1 conftest.err
54445dc2 3885 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
57aa50d4
TT
3886 test $ac_status = 0; }
3887done
b0cacab0 3888
57aa50d4 3889cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b0cacab0 3890/* end confdefs.h. */
61ef2474 3891
b0cacab0 3892int
54445dc2 3893main (void)
b0cacab0
TT
3894{
3895
3896 ;
3897 return 0;
3898}
3899_ACEOF
3900ac_clean_files_save=$ac_clean_files
61ef2474 3901ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
b0cacab0
TT
3902# Try to create an executable without -o first, disregard a.out.
3903# It will help us diagnose broken compilers, and finding out an intuition
3904# of exeext.
54445dc2
TT
3905{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3906printf %s "checking whether the C compiler works... " >&6; }
3907ac_link_default=`printf "%s\n" "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
39fd3d4f
SJR
3908
3909# The possible output files:
3910ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3911
e1052144
TT
3912ac_rmfiles=
3913for ac_file in $ac_files
3914do
3915 case $ac_file in
39fd3d4f 3916 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
e1052144
TT
3917 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3918 esac
3919done
3920rm -f $ac_rmfiles
3921
57aa50d4 3922if { { ac_try="$ac_link_default"
e1052144
TT
3923case "(($ac_try" in
3924 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3925 *) ac_try_echo=$ac_try;;
3926esac
57aa50d4 3927eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
54445dc2 3928printf "%s\n" "$ac_try_echo"; } >&5
e1052144 3929 (eval "$ac_link_default") 2>&5
b0cacab0 3930 ac_status=$?
54445dc2
TT
3931 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3932 test $ac_status = 0; }
3933then :
e1052144
TT
3934 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3935# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3936# in a Makefile. We should not override ac_cv_exeext if it was cached,
3937# so that the user can short-circuit this test for compilers unknown to
3938# Autoconf.
29a5deed 3939for ac_file in $ac_files ''
b0cacab0
TT
3940do
3941 test -f "$ac_file" || continue
3942 case $ac_file in
39fd3d4f 3943 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
b0cacab0
TT
3944 ;;
3945 [ab].out )
3946 # We found the default executable, but exeext='' is most
3947 # certainly right.
3948 break;;
3949 *.* )
54445dc2 3950 if test ${ac_cv_exeext+y} && test "$ac_cv_exeext" != no;
e1052144
TT
3951 then :; else
3952 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3953 fi
3954 # We set ac_cv_exeext here because the later test for it is not
3955 # safe: cross compilers may not add the suffix if given an `-o'
3956 # argument, so we may need to know it at that point already.
3957 # Even if this section looks crufty: it has the advantage of
3958 # actually working.
b0cacab0
TT
3959 break;;
3960 * )
3961 break;;
3962 esac
3963done
e1052144
TT
3964test "$ac_cv_exeext" = no && ac_cv_exeext=
3965
54445dc2 3966else $as_nop
29a5deed
TT
3967 ac_file=''
3968fi
54445dc2
TT
3969if test -z "$ac_file"
3970then :
3971 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
3972printf "%s\n" "no" >&6; }
3973printf "%s\n" "$as_me: failed program was:" >&5
b0cacab0
TT
3974sed 's/^/| /' conftest.$ac_ext >&5
3975
54445dc2
TT
3976{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3977printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
d6a4bcb5
TB
3978as_fn_error 77 "C compiler cannot create executables
3979See \`config.log' for more details" "$LINENO" 5; }
54445dc2
TT
3980else $as_nop
3981 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3982printf "%s\n" "yes" >&6; }
3983fi
3984{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3985printf %s "checking for C compiler default output file name... " >&6; }
3986{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3987printf "%s\n" "$ac_file" >&6; }
b0cacab0 3988ac_exeext=$ac_cv_exeext
b0cacab0 3989
61ef2474 3990rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
b0cacab0 3991ac_clean_files=$ac_clean_files_save
54445dc2
TT
3992{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3993printf %s "checking for suffix of executables... " >&6; }
57aa50d4 3994if { { ac_try="$ac_link"
e1052144
TT
3995case "(($ac_try" in
3996 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3997 *) ac_try_echo=$ac_try;;
3998esac
57aa50d4 3999eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
54445dc2 4000printf "%s\n" "$ac_try_echo"; } >&5
e1052144 4001 (eval "$ac_link") 2>&5
b0cacab0 4002 ac_status=$?
54445dc2
TT
4003 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4004 test $ac_status = 0; }
4005then :
b0cacab0
TT
4006 # If both `conftest.exe' and `conftest' are `present' (well, observable)
4007# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
4008# work properly (i.e., refer to `conftest.exe'), while it won't with
4009# `rm'.
4010for ac_file in conftest.exe conftest conftest.*; do
4011 test -f "$ac_file" || continue
4012 case $ac_file in
39fd3d4f 4013 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
b0cacab0 4014 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
b0cacab0
TT
4015 break;;
4016 * ) break;;
4017 esac
4018done
54445dc2
TT
4019else $as_nop
4020 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4021printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
d6a4bcb5
TB
4022as_fn_error $? "cannot compute suffix of executables: cannot compile and link
4023See \`config.log' for more details" "$LINENO" 5; }
73ae2d4a 4024fi
61ef2474 4025rm -f conftest conftest$ac_cv_exeext
54445dc2
TT
4026{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4027printf "%s\n" "$ac_cv_exeext" >&6; }
73ae2d4a 4028
b0cacab0
TT
4029rm -f conftest.$ac_ext
4030EXEEXT=$ac_cv_exeext
4031ac_exeext=$EXEEXT
61ef2474
TT
4032cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4033/* end confdefs.h. */
4034#include <stdio.h>
4035int
54445dc2 4036main (void)
61ef2474
TT
4037{
4038FILE *f = fopen ("conftest.out", "w");
4039 return ferror (f) || fclose (f) != 0;
4040
4041 ;
4042 return 0;
4043}
4044_ACEOF
4045ac_clean_files="$ac_clean_files conftest.out"
4046# Check that the compiler produces executables we can run. If not, either
4047# the compiler is broken, or we cross compile.
54445dc2
TT
4048{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4049printf %s "checking whether we are cross compiling... " >&6; }
61ef2474
TT
4050if test "$cross_compiling" != yes; then
4051 { { ac_try="$ac_link"
4052case "(($ac_try" in
4053 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4054 *) ac_try_echo=$ac_try;;
4055esac
4056eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
54445dc2 4057printf "%s\n" "$ac_try_echo"; } >&5
61ef2474
TT
4058 (eval "$ac_link") 2>&5
4059 ac_status=$?
54445dc2 4060 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
61ef2474
TT
4061 test $ac_status = 0; }
4062 if { ac_try='./conftest$ac_cv_exeext'
4063 { { case "(($ac_try" in
4064 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4065 *) ac_try_echo=$ac_try;;
4066esac
4067eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
54445dc2 4068printf "%s\n" "$ac_try_echo"; } >&5
61ef2474
TT
4069 (eval "$ac_try") 2>&5
4070 ac_status=$?
54445dc2 4071 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
61ef2474
TT
4072 test $ac_status = 0; }; }; then
4073 cross_compiling=no
4074 else
4075 if test "$cross_compiling" = maybe; then
4076 cross_compiling=yes
4077 else
54445dc2
TT
4078 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4079printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
4080as_fn_error 77 "cannot run C compiled programs.
61ef2474 4081If you meant to cross compile, use \`--host'.
d6a4bcb5 4082See \`config.log' for more details" "$LINENO" 5; }
61ef2474
TT
4083 fi
4084 fi
4085fi
54445dc2
TT
4086{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4087printf "%s\n" "$cross_compiling" >&6; }
61ef2474
TT
4088
4089rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4090ac_clean_files=$ac_clean_files_save
54445dc2
TT
4091{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4092printf %s "checking for suffix of object files... " >&6; }
4093if test ${ac_cv_objext+y}
4094then :
4095 printf %s "(cached) " >&6
4096else $as_nop
57aa50d4 4097 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b0cacab0 4098/* end confdefs.h. */
07a0db15 4099
b0cacab0 4100int
54445dc2 4101main (void)
b0cacab0 4102{
07a0db15 4103
b0cacab0
TT
4104 ;
4105 return 0;
4106}
4107_ACEOF
4108rm -f conftest.o conftest.obj
57aa50d4 4109if { { ac_try="$ac_compile"
e1052144
TT
4110case "(($ac_try" in
4111 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4112 *) ac_try_echo=$ac_try;;
4113esac
57aa50d4 4114eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
54445dc2 4115printf "%s\n" "$ac_try_echo"; } >&5
e1052144 4116 (eval "$ac_compile") 2>&5
b0cacab0 4117 ac_status=$?
54445dc2
TT
4118 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4119 test $ac_status = 0; }
4120then :
e1052144
TT
4121 for ac_file in conftest.o conftest.obj conftest.*; do
4122 test -f "$ac_file" || continue;
b0cacab0 4123 case $ac_file in
39fd3d4f 4124 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
b0cacab0
TT
4125 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4126 break;;
4127 esac
4128done
54445dc2
TT
4129else $as_nop
4130 printf "%s\n" "$as_me: failed program was:" >&5
b0cacab0 4131sed 's/^/| /' conftest.$ac_ext >&5
07a0db15 4132
54445dc2
TT
4133{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4134printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
d6a4bcb5
TB
4135as_fn_error $? "cannot compute suffix of object files: cannot compile
4136See \`config.log' for more details" "$LINENO" 5; }
73ae2d4a 4137fi
b0cacab0 4138rm -f conftest.$ac_cv_objext conftest.$ac_ext
73ae2d4a 4139fi
54445dc2
TT
4140{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4141printf "%s\n" "$ac_cv_objext" >&6; }
b0cacab0
TT
4142OBJEXT=$ac_cv_objext
4143ac_objext=$OBJEXT
54445dc2
TT
4144{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C" >&5
4145printf %s "checking whether the compiler supports GNU C... " >&6; }
4146if test ${ac_cv_c_compiler_gnu+y}
4147then :
4148 printf %s "(cached) " >&6
4149else $as_nop
57aa50d4 4150 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b0cacab0
TT
4151/* end confdefs.h. */
4152
4153int
54445dc2 4154main (void)
b0cacab0
TT
4155{
4156#ifndef __GNUC__
4157 choke me
4158#endif
4159
4160 ;
4161 return 0;
4162}
4163_ACEOF
54445dc2
TT
4164if ac_fn_c_try_compile "$LINENO"
4165then :
b0cacab0 4166 ac_compiler_gnu=yes
54445dc2 4167else $as_nop
57aa50d4 4168 ac_compiler_gnu=no
b0cacab0 4169fi
54445dc2 4170rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
b0cacab0
TT
4171ac_cv_c_compiler_gnu=$ac_compiler_gnu
4172
4173fi
54445dc2
TT
4174{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4175printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; }
4176ac_compiler_gnu=$ac_cv_c_compiler_gnu
4177
39fd3d4f
SJR
4178if test $ac_compiler_gnu = yes; then
4179 GCC=yes
4180else
4181 GCC=
4182fi
54445dc2 4183ac_test_CFLAGS=${CFLAGS+y}
b0cacab0 4184ac_save_CFLAGS=$CFLAGS
54445dc2
TT
4185{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4186printf %s "checking whether $CC accepts -g... " >&6; }
4187if test ${ac_cv_prog_cc_g+y}
4188then :
4189 printf %s "(cached) " >&6
4190else $as_nop
e1052144
TT
4191 ac_save_c_werror_flag=$ac_c_werror_flag
4192 ac_c_werror_flag=yes
4193 ac_cv_prog_cc_g=no
4194 CFLAGS="-g"
57aa50d4 4195 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
e1052144
TT
4196/* end confdefs.h. */
4197
4198int
54445dc2 4199main (void)
e1052144
TT
4200{
4201
4202 ;
4203 return 0;
4204}
4205_ACEOF
54445dc2
TT
4206if ac_fn_c_try_compile "$LINENO"
4207then :
e1052144 4208 ac_cv_prog_cc_g=yes
54445dc2 4209else $as_nop
57aa50d4
TT
4210 CFLAGS=""
4211 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
e1052144
TT
4212/* end confdefs.h. */
4213
4214int
54445dc2 4215main (void)
e1052144
TT
4216{
4217
4218 ;
4219 return 0;
4220}
4221_ACEOF
54445dc2
TT
4222if ac_fn_c_try_compile "$LINENO"
4223then :
e1052144 4224
54445dc2 4225else $as_nop
57aa50d4 4226 ac_c_werror_flag=$ac_save_c_werror_flag
e1052144 4227 CFLAGS="-g"
57aa50d4 4228 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b0cacab0
TT
4229/* end confdefs.h. */
4230
4231int
54445dc2 4232main (void)
b0cacab0
TT
4233{
4234
4235 ;
4236 return 0;
4237}
4238_ACEOF
54445dc2
TT
4239if ac_fn_c_try_compile "$LINENO"
4240then :
b0cacab0 4241 ac_cv_prog_cc_g=yes
e1052144 4242fi
54445dc2 4243rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
e1052144 4244fi
54445dc2 4245rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
b0cacab0 4246fi
54445dc2 4247rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
e1052144 4248 ac_c_werror_flag=$ac_save_c_werror_flag
b0cacab0 4249fi
54445dc2
TT
4250{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4251printf "%s\n" "$ac_cv_prog_cc_g" >&6; }
4252if test $ac_test_CFLAGS; then
b0cacab0
TT
4253 CFLAGS=$ac_save_CFLAGS
4254elif test $ac_cv_prog_cc_g = yes; then
4255 if test "$GCC" = yes; then
4256 CFLAGS="-g -O2"
4257 else
4258 CFLAGS="-g"
4259 fi
73ae2d4a
TT
4260else
4261 if test "$GCC" = yes; then
4262 CFLAGS="-O2"
4263 else
4264 CFLAGS=
4265 fi
4266fi
54445dc2
TT
4267ac_prog_cc_stdc=no
4268if test x$ac_prog_cc_stdc = xno
4269then :
4270 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5
4271printf %s "checking for $CC option to enable C11 features... " >&6; }
4272if test ${ac_cv_prog_cc_c11+y}
4273then :
4274 printf %s "(cached) " >&6
4275else $as_nop
4276 ac_cv_prog_cc_c11=no
b0cacab0 4277ac_save_CC=$CC
57aa50d4 4278cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b0cacab0 4279/* end confdefs.h. */
54445dc2 4280$ac_c_conftest_c11_program
b0cacab0 4281_ACEOF
54445dc2 4282for ac_arg in '' -std=gnu11
b0cacab0
TT
4283do
4284 CC="$ac_save_CC $ac_arg"
54445dc2
TT
4285 if ac_fn_c_try_compile "$LINENO"
4286then :
4287 ac_cv_prog_cc_c11=$ac_arg
4288fi
4289rm -f core conftest.err conftest.$ac_objext conftest.beam
4290 test "x$ac_cv_prog_cc_c11" != "xno" && break
4291done
4292rm -f conftest.$ac_ext
4293CC=$ac_save_CC
4294fi
4295
4296if test "x$ac_cv_prog_cc_c11" = xno
4297then :
4298 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4299printf "%s\n" "unsupported" >&6; }
4300else $as_nop
4301 if test "x$ac_cv_prog_cc_c11" = x
4302then :
4303 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4304printf "%s\n" "none needed" >&6; }
4305else $as_nop
4306 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5
4307printf "%s\n" "$ac_cv_prog_cc_c11" >&6; }
4308 CC="$CC $ac_cv_prog_cc_c11"
4309fi
4310 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11
4311 ac_prog_cc_stdc=c11
4312fi
4313fi
4314if test x$ac_prog_cc_stdc = xno
4315then :
4316 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5
4317printf %s "checking for $CC option to enable C99 features... " >&6; }
4318if test ${ac_cv_prog_cc_c99+y}
4319then :
4320 printf %s "(cached) " >&6
4321else $as_nop
4322 ac_cv_prog_cc_c99=no
4323ac_save_CC=$CC
4324cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4325/* end confdefs.h. */
4326$ac_c_conftest_c99_program
4327_ACEOF
4328for ac_arg in '' -std=gnu99 -std=c99 -c99 -qlanglvl=extc1x -qlanglvl=extc99 -AC99 -D_STDC_C99=
4329do
4330 CC="$ac_save_CC $ac_arg"
4331 if ac_fn_c_try_compile "$LINENO"
4332then :
4333 ac_cv_prog_cc_c99=$ac_arg
4334fi
4335rm -f core conftest.err conftest.$ac_objext conftest.beam
4336 test "x$ac_cv_prog_cc_c99" != "xno" && break
4337done
4338rm -f conftest.$ac_ext
4339CC=$ac_save_CC
4340fi
4341
4342if test "x$ac_cv_prog_cc_c99" = xno
4343then :
4344 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4345printf "%s\n" "unsupported" >&6; }
4346else $as_nop
4347 if test "x$ac_cv_prog_cc_c99" = x
4348then :
4349 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4350printf "%s\n" "none needed" >&6; }
4351else $as_nop
4352 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
4353printf "%s\n" "$ac_cv_prog_cc_c99" >&6; }
4354 CC="$CC $ac_cv_prog_cc_c99"
4355fi
4356 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
4357 ac_prog_cc_stdc=c99
4358fi
4359fi
4360if test x$ac_prog_cc_stdc = xno
4361then :
4362 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5
4363printf %s "checking for $CC option to enable C89 features... " >&6; }
4364if test ${ac_cv_prog_cc_c89+y}
4365then :
4366 printf %s "(cached) " >&6
4367else $as_nop
4368 ac_cv_prog_cc_c89=no
4369ac_save_CC=$CC
4370cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4371/* end confdefs.h. */
4372$ac_c_conftest_c89_program
4373_ACEOF
4374for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4375do
4376 CC="$ac_save_CC $ac_arg"
4377 if ac_fn_c_try_compile "$LINENO"
4378then :
e1052144 4379 ac_cv_prog_cc_c89=$ac_arg
b0cacab0 4380fi
54445dc2 4381rm -f core conftest.err conftest.$ac_objext conftest.beam
e1052144 4382 test "x$ac_cv_prog_cc_c89" != "xno" && break
b0cacab0 4383done
e1052144 4384rm -f conftest.$ac_ext
b0cacab0 4385CC=$ac_save_CC
b0cacab0 4386fi
b0cacab0 4387
54445dc2
TT
4388if test "x$ac_cv_prog_cc_c89" = xno
4389then :
4390 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4391printf "%s\n" "unsupported" >&6; }
4392else $as_nop
4393 if test "x$ac_cv_prog_cc_c89" = x
4394then :
4395 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4396printf "%s\n" "none needed" >&6; }
4397else $as_nop
4398 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4399printf "%s\n" "$ac_cv_prog_cc_c89" >&6; }
4400 CC="$CC $ac_cv_prog_cc_c89"
4401fi
4402 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
4403 ac_prog_cc_stdc=c89
4404fi
57aa50d4 4405fi
b0cacab0 4406
b0cacab0
TT
4407ac_ext=c
4408ac_cpp='$CPP $CPPFLAGS'
4409ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4410ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4411ac_compiler_gnu=$ac_cv_c_compiler_gnu
4412
57aa50d4 4413
54445dc2
TT
4414ac_header= ac_cache=
4415for ac_item in $ac_header_c_list
4416do
4417 if test $ac_cache; then
4418 ac_fn_c_check_header_compile "$LINENO" $ac_header ac_cv_header_$ac_cache "$ac_includes_default"
4419 if eval test \"x\$ac_cv_header_$ac_cache\" = xyes; then
4420 printf "%s\n" "#define $ac_item 1" >> confdefs.h
4421 fi
4422 ac_header= ac_cache=
4423 elif test $ac_header; then
4424 ac_cache=$ac_item
4425 else
4426 ac_header=$ac_item
4427 fi
4428done
4429
4430
4431
4432
4433
4434
4435
4436
4437if test $ac_cv_header_stdlib_h = yes && test $ac_cv_header_string_h = yes
4438then :
4439
4440printf "%s\n" "#define STDC_HEADERS 1" >>confdefs.h
4441
4442fi
4443
4444
4445
4446
4447
4448
4449 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4450printf %s "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4451if test ${ac_cv_safe_to_define___extensions__+y}
4452then :
4453 printf %s "(cached) " >&6
4454else $as_nop
4455 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4456/* end confdefs.h. */
4457
4458# define __EXTENSIONS__ 1
4459 $ac_includes_default
4460int
4461main (void)
4462{
4463
4464 ;
4465 return 0;
4466}
4467_ACEOF
4468if ac_fn_c_try_compile "$LINENO"
4469then :
4470 ac_cv_safe_to_define___extensions__=yes
4471else $as_nop
4472 ac_cv_safe_to_define___extensions__=no
4473fi
4474rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
4475fi
4476{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
4477printf "%s\n" "$ac_cv_safe_to_define___extensions__" >&6; }
4478
4479 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
4480printf %s "checking whether _XOPEN_SOURCE should be defined... " >&6; }
4481if test ${ac_cv_should_define__xopen_source+y}
4482then :
4483 printf %s "(cached) " >&6
4484else $as_nop
4485 ac_cv_should_define__xopen_source=no
4486 if test $ac_cv_header_wchar_h = yes
4487then :
4488 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4489/* end confdefs.h. */
4490
4491 #include <wchar.h>
4492 mbstate_t x;
4493int
4494main (void)
4495{
4496
4497 ;
4498 return 0;
4499}
4500_ACEOF
4501if ac_fn_c_try_compile "$LINENO"
4502then :
4503
4504else $as_nop
4505 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4506/* end confdefs.h. */
4507
4508 #define _XOPEN_SOURCE 500
4509 #include <wchar.h>
4510 mbstate_t x;
4511int
4512main (void)
4513{
4514
4515 ;
4516 return 0;
4517}
4518_ACEOF
4519if ac_fn_c_try_compile "$LINENO"
4520then :
4521 ac_cv_should_define__xopen_source=yes
4522fi
4523rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
4524fi
4525rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
4526fi
4527fi
4528{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
4529printf "%s\n" "$ac_cv_should_define__xopen_source" >&6; }
4530
4531 printf "%s\n" "#define _ALL_SOURCE 1" >>confdefs.h
4532
4533 printf "%s\n" "#define _DARWIN_C_SOURCE 1" >>confdefs.h
4534
4535 printf "%s\n" "#define _GNU_SOURCE 1" >>confdefs.h
4536
4537 printf "%s\n" "#define _HPUX_ALT_XOPEN_SOCKET_API 1" >>confdefs.h
4538
4539 printf "%s\n" "#define _NETBSD_SOURCE 1" >>confdefs.h
4540
4541 printf "%s\n" "#define _OPENBSD_SOURCE 1" >>confdefs.h
4542
4543 printf "%s\n" "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
4544
4545 printf "%s\n" "#define __STDC_WANT_IEC_60559_ATTRIBS_EXT__ 1" >>confdefs.h
4546
4547 printf "%s\n" "#define __STDC_WANT_IEC_60559_BFP_EXT__ 1" >>confdefs.h
4548
4549 printf "%s\n" "#define __STDC_WANT_IEC_60559_DFP_EXT__ 1" >>confdefs.h
4550
4551 printf "%s\n" "#define __STDC_WANT_IEC_60559_FUNCS_EXT__ 1" >>confdefs.h
4552
4553 printf "%s\n" "#define __STDC_WANT_IEC_60559_TYPES_EXT__ 1" >>confdefs.h
4554
4555 printf "%s\n" "#define __STDC_WANT_LIB_EXT2__ 1" >>confdefs.h
4556
4557 printf "%s\n" "#define __STDC_WANT_MATH_SPEC_FUNCS__ 1" >>confdefs.h
4558
4559 printf "%s\n" "#define _TANDEM_SOURCE 1" >>confdefs.h
4560
4561 if test $ac_cv_header_minix_config_h = yes
4562then :
4563 MINIX=yes
4564 printf "%s\n" "#define _MINIX 1" >>confdefs.h
4565
4566 printf "%s\n" "#define _POSIX_SOURCE 1" >>confdefs.h
4567
4568 printf "%s\n" "#define _POSIX_1_SOURCE 2" >>confdefs.h
4569
4570else $as_nop
4571 MINIX=
4572fi
4573 if test $ac_cv_safe_to_define___extensions__ = yes
4574then :
4575 printf "%s\n" "#define __EXTENSIONS__ 1" >>confdefs.h
4576
4577fi
4578 if test $ac_cv_should_define__xopen_source = yes
4579then :
4580 printf "%s\n" "#define _XOPEN_SOURCE 500" >>confdefs.h
4581
4582fi
4583
4584MCONFIG=./MCONFIG
4585
4586BINARY_TYPE=bin
1ac00616
AD
4587E2FSPROGS_VERSION=`awk -F\" '/E2FSPROGS_VERS/ { print $2 }' ${srcdir}/version.h`
4588E2FSPROGS_DATE=`awk -F\" '/E2FSPROGS_DATE/ { print $2 }' ${srcdir}/version.h`
4589E2FSPROGS_DAY=$(echo $E2FSPROGS_DATE | awk -F- '{ printf "%02d", $1 }')
54445dc2
TT
4590MONTH=`echo $E2FSPROGS_DATE | awk -F- '{print $2}'`
4591YEAR=`echo $E2FSPROGS_DATE | awk -F- '{print $3}'`
4592
4593if expr $YEAR ">" 1900 > /dev/null ; then
4594 E2FSPROGS_YEAR=$YEAR
4595elif expr $YEAR ">" 90 >/dev/null ; then
4596 E2FSPROGS_YEAR=19$YEAR
4597else
4598 E2FSPROGS_YEAR=20$YEAR
4599fi
4600
4601case $MONTH in
4602Jan) MONTH_NUM=01; E2FSPROGS_MONTH="January" ;;
4603Feb) MONTH_NUM=02; E2FSPROGS_MONTH="February" ;;
4604Mar) MONTH_NUM=03; E2FSPROGS_MONTH="March" ;;
4605Apr) MONTH_NUM=04; E2FSPROGS_MONTH="April" ;;
4606May) MONTH_NUM=05; E2FSPROGS_MONTH="May" ;;
4607Jun) MONTH_NUM=06; E2FSPROGS_MONTH="June" ;;
4608Jul) MONTH_NUM=07; E2FSPROGS_MONTH="July" ;;
4609Aug) MONTH_NUM=08; E2FSPROGS_MONTH="August" ;;
4610Sep) MONTH_NUM=09; E2FSPROGS_MONTH="September" ;;
4611Oct) MONTH_NUM=10; E2FSPROGS_MONTH="October" ;;
4612Nov) MONTH_NUM=11; E2FSPROGS_MONTH="November" ;;
4613Dec) MONTH_NUM=12; E2FSPROGS_MONTH="December" ;;
4614*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Unknown month $MONTH??" >&5
4615printf "%s\n" "$as_me: WARNING: Unknown month $MONTH??" >&2;} ;;
4616esac
4617
1ac00616
AD
4618base_ver=`echo $E2FSPROGS_VERSION | sed -e 's/pre-//' -e 's/-.*//'`
4619base_rel=`echo $E2FSPROGS_VERSION | awk -F- '{ print $2 }'`
54445dc2
TT
4620
4621date_spec=${E2FSPROGS_YEAR}.${MONTH_NUM}.${E2FSPROGS_DAY}
4622
4623case $E2FSPROGS_VERSION in
4624*-WIP|pre-*)
1ac00616
AD
4625 E2FSPROGS_PKGVER="$base_ver"
4626 E2FSPROGS_PKGREL="WIP.$date_spec"
54445dc2
TT
4627 ;;
4628*)
4629 E2FSPROGS_PKGVER="$base_ver"
1ac00616 4630 E2FSPROGS_PKGREL="$base_rel"
54445dc2
TT
4631 ;;
4632esac
4633
4634unset DATE MONTH YEAR base_ver pre_vers date_spec
4635{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Generating configuration file for e2fsprogs version $E2FSPROGS_VERSION" >&5
4636printf "%s\n" "Generating configuration file for e2fsprogs version $E2FSPROGS_VERSION" >&6; }
4637{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Release date is ${E2FSPROGS_MONTH}, ${E2FSPROGS_YEAR}" >&5
4638printf "%s\n" "Release date is ${E2FSPROGS_MONTH}, ${E2FSPROGS_YEAR}" >&6; }
4639
4640
4641
4642
4643
4644
4645WITH_DIET_LIBC=
4646
4647# Check whether --with-diet-libc was given.
4648if test ${with_diet_libc+y}
4649then :
4650 withval=$with_diet_libc; CC="diet cc -nostdinc"
4651WITH_DIET_LIBC=yes
4652if test -z "$LIBS"
4653then
4654 LIBS="-lcompat"
4655else
4656 LIBS="$LIBS -lcompat"
4657fi
4658{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: CC=$CC" >&5
4659printf "%s\n" "CC=$CC" >&6; }
4660fi
4661
4662
4663
4664 # Make sure we can run config.sub.
4665$SHELL "${ac_aux_dir}config.sub" sun4 >/dev/null 2>&1 ||
4666 as_fn_error $? "cannot run $SHELL ${ac_aux_dir}config.sub" "$LINENO" 5
4667
4668{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4669printf %s "checking build system type... " >&6; }
4670if test ${ac_cv_build+y}
4671then :
4672 printf %s "(cached) " >&6
4673else $as_nop
4674 ac_build_alias=$build_alias
4675test "x$ac_build_alias" = x &&
4676 ac_build_alias=`$SHELL "${ac_aux_dir}config.guess"`
4677test "x$ac_build_alias" = x &&
4678 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
4679ac_cv_build=`$SHELL "${ac_aux_dir}config.sub" $ac_build_alias` ||
4680 as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $ac_build_alias failed" "$LINENO" 5
4681
4682fi
4683{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4684printf "%s\n" "$ac_cv_build" >&6; }
4685case $ac_cv_build in
4686*-*-*) ;;
4687*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
4688esac
4689build=$ac_cv_build
4690ac_save_IFS=$IFS; IFS='-'
4691set x $ac_cv_build
4692shift
4693build_cpu=$1
4694build_vendor=$2
4695shift; shift
4696# Remember, the first character of IFS is used to create $*,
4697# except with old shells:
4698build_os=$*
4699IFS=$ac_save_IFS
4700case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4701
4702
4703{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4704printf %s "checking host system type... " >&6; }
4705if test ${ac_cv_host+y}
4706then :
4707 printf %s "(cached) " >&6
4708else $as_nop
4709 if test "x$host_alias" = x; then
4710 ac_cv_host=$ac_cv_build
b0cacab0 4711else
54445dc2
TT
4712 ac_cv_host=`$SHELL "${ac_aux_dir}config.sub" $host_alias` ||
4713 as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $host_alias failed" "$LINENO" 5
4714fi
4715
4716fi
4717{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4718printf "%s\n" "$ac_cv_host" >&6; }
4719case $ac_cv_host in
4720*-*-*) ;;
4721*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
4722esac
4723host=$ac_cv_host
4724ac_save_IFS=$IFS; IFS='-'
4725set x $ac_cv_host
4726shift
4727host_cpu=$1
4728host_vendor=$2
4729shift; shift
4730# Remember, the first character of IFS is used to create $*,
4731# except with old shells:
4732host_os=$*
4733IFS=$ac_save_IFS
4734case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4735
4736
4737DLOPEN_LIB=''
4738{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
4739printf %s "checking for dlopen in -ldl... " >&6; }
4740if test ${ac_cv_lib_dl_dlopen+y}
4741then :
4742 printf %s "(cached) " >&6
4743else $as_nop
57aa50d4
TT
4744 ac_check_lib_save_LIBS=$LIBS
4745LIBS="-ldl $LIBS"
4746cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b0cacab0 4747/* end confdefs.h. */
57aa50d4
TT
4748
4749/* Override any GCC internal prototype to avoid an error.
4750 Use char because int might match the return type of a GCC
4751 builtin and then its argument prototype would still apply. */
57aa50d4
TT
4752char dlopen ();
4753int
54445dc2 4754main (void)
57aa50d4
TT
4755{
4756return dlopen ();
4757 ;
4758 return 0;
4759}
b0cacab0 4760_ACEOF
54445dc2
TT
4761if ac_fn_c_try_link "$LINENO"
4762then :
57aa50d4 4763 ac_cv_lib_dl_dlopen=yes
54445dc2 4764else $as_nop
57aa50d4 4765 ac_cv_lib_dl_dlopen=no
b0cacab0 4766fi
54445dc2 4767rm -f core conftest.err conftest.$ac_objext conftest.beam \
57aa50d4
TT
4768 conftest$ac_exeext conftest.$ac_ext
4769LIBS=$ac_check_lib_save_LIBS
b0cacab0 4770fi
54445dc2
TT
4771{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
4772printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; }
4773if test "x$ac_cv_lib_dl_dlopen" = xyes
4774then :
57aa50d4 4775 DLOPEN_LIB=-ldl
b0cacab0
TT
4776fi
4777
b0cacab0 4778
e1052144 4779
57aa50d4 4780# Check whether --with-cc was given.
54445dc2
TT
4781if test ${with_cc+y}
4782then :
d6a4bcb5 4783 withval=$with_cc; as_fn_error $? "--with-cc no longer supported; use CC= instead" "$LINENO" 5
57aa50d4 4784fi
b0cacab0 4785
b0cacab0 4786
57aa50d4 4787# Check whether --with-ccopts was given.
54445dc2
TT
4788if test ${with_ccopts+y}
4789then :
d6a4bcb5 4790 withval=$with_ccopts; as_fn_error $? "--with-ccopts no longer supported; use CFLAGS= instead" "$LINENO" 5
b0cacab0 4791fi
e1052144 4792
b0cacab0 4793
57aa50d4 4794# Check whether --with-ldopts was given.
54445dc2
TT
4795if test ${with_ldopts+y}
4796then :
d6a4bcb5 4797 withval=$with_ldopts; as_fn_error $? "--with-ldopts no longer supported; use LDFLAGS= instead" "$LINENO" 5
b0cacab0
TT
4798fi
4799
4800ac_ext=c
4801ac_cpp='$CPP $CPPFLAGS'
4802ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4803ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4804ac_compiler_gnu=$ac_cv_c_compiler_gnu
57aa50d4
TT
4805if test -n "$ac_tool_prefix"; then
4806 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4807set dummy ${ac_tool_prefix}gcc; ac_word=$2
54445dc2
TT
4808{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4809printf %s "checking for $ac_word... " >&6; }
4810if test ${ac_cv_prog_CC+y}
4811then :
4812 printf %s "(cached) " >&6
4813else $as_nop
57aa50d4
TT
4814 if test -n "$CC"; then
4815 ac_cv_prog_CC="$CC" # Let the user override the test.
4816else
4817as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4818for as_dir in $PATH
e1052144
TT
4819do
4820 IFS=$as_save_IFS
54445dc2
TT
4821 case $as_dir in #(((
4822 '') as_dir=./ ;;
4823 */) ;;
4824 *) as_dir=$as_dir/ ;;
4825 esac
39fd3d4f 4826 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 4827 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 4828 ac_cv_prog_CC="${ac_tool_prefix}gcc"
54445dc2 4829 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
4830 break 2
4831 fi
e1052144 4832done
57aa50d4 4833 done
e1052144 4834IFS=$as_save_IFS
e1052144 4835
e1052144 4836fi
57aa50d4
TT
4837fi
4838CC=$ac_cv_prog_CC
4839if test -n "$CC"; then
54445dc2
TT
4840 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4841printf "%s\n" "$CC" >&6; }
57aa50d4 4842else
54445dc2
TT
4843 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4844printf "%s\n" "no" >&6; }
57aa50d4 4845fi
e1052144
TT
4846
4847
57aa50d4
TT
4848fi
4849if test -z "$ac_cv_prog_CC"; then
4850 ac_ct_CC=$CC
4851 # Extract the first word of "gcc", so it can be a program name with args.
4852set dummy gcc; ac_word=$2
54445dc2
TT
4853{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4854printf %s "checking for $ac_word... " >&6; }
4855if test ${ac_cv_prog_ac_ct_CC+y}
4856then :
4857 printf %s "(cached) " >&6
4858else $as_nop
57aa50d4
TT
4859 if test -n "$ac_ct_CC"; then
4860 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4861else
4862as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4863for as_dir in $PATH
e1052144
TT
4864do
4865 IFS=$as_save_IFS
54445dc2
TT
4866 case $as_dir in #(((
4867 '') as_dir=./ ;;
4868 */) ;;
4869 *) as_dir=$as_dir/ ;;
4870 esac
39fd3d4f 4871 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 4872 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 4873 ac_cv_prog_ac_ct_CC="gcc"
54445dc2 4874 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
4875 break 2
4876 fi
e1052144 4877done
57aa50d4 4878 done
e1052144 4879IFS=$as_save_IFS
b0cacab0 4880
e1052144 4881fi
57aa50d4
TT
4882fi
4883ac_ct_CC=$ac_cv_prog_ac_ct_CC
4884if test -n "$ac_ct_CC"; then
54445dc2
TT
4885 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4886printf "%s\n" "$ac_ct_CC" >&6; }
b0cacab0 4887else
54445dc2
TT
4888 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4889printf "%s\n" "no" >&6; }
57aa50d4 4890fi
b0cacab0 4891
57aa50d4
TT
4892 if test "x$ac_ct_CC" = x; then
4893 CC=""
4894 else
4895 case $cross_compiling:$ac_tool_warned in
4896yes:)
54445dc2
TT
4897{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4898printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
57aa50d4 4899ac_tool_warned=yes ;;
e1052144 4900esac
57aa50d4
TT
4901 CC=$ac_ct_CC
4902 fi
b0cacab0 4903else
57aa50d4 4904 CC="$ac_cv_prog_CC"
b0cacab0 4905fi
e1052144 4906
57aa50d4
TT
4907if test -z "$CC"; then
4908 if test -n "$ac_tool_prefix"; then
4909 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4910set dummy ${ac_tool_prefix}cc; ac_word=$2
54445dc2
TT
4911{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4912printf %s "checking for $ac_word... " >&6; }
4913if test ${ac_cv_prog_CC+y}
4914then :
4915 printf %s "(cached) " >&6
4916else $as_nop
57aa50d4
TT
4917 if test -n "$CC"; then
4918 ac_cv_prog_CC="$CC" # Let the user override the test.
4919else
4920as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4921for as_dir in $PATH
4922do
4923 IFS=$as_save_IFS
54445dc2
TT
4924 case $as_dir in #(((
4925 '') as_dir=./ ;;
4926 */) ;;
4927 *) as_dir=$as_dir/ ;;
4928 esac
57aa50d4 4929 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 4930 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 4931 ac_cv_prog_CC="${ac_tool_prefix}cc"
54445dc2 4932 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
4933 break 2
4934 fi
4935done
4936 done
4937IFS=$as_save_IFS
b0cacab0 4938
a64c9c13 4939fi
57aa50d4
TT
4940fi
4941CC=$ac_cv_prog_CC
4942if test -n "$CC"; then
54445dc2
TT
4943 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4944printf "%s\n" "$CC" >&6; }
b0cacab0 4945else
54445dc2
TT
4946 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4947printf "%s\n" "no" >&6; }
a64c9c13 4948fi
b0cacab0 4949
b0cacab0 4950
57aa50d4
TT
4951 fi
4952fi
4953if test -z "$CC"; then
4954 # Extract the first word of "cc", so it can be a program name with args.
4955set dummy cc; ac_word=$2
54445dc2
TT
4956{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4957printf %s "checking for $ac_word... " >&6; }
4958if test ${ac_cv_prog_CC+y}
4959then :
4960 printf %s "(cached) " >&6
4961else $as_nop
57aa50d4
TT
4962 if test -n "$CC"; then
4963 ac_cv_prog_CC="$CC" # Let the user override the test.
a64c9c13 4964else
57aa50d4
TT
4965 ac_prog_rejected=no
4966as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4967for as_dir in $PATH
4968do
4969 IFS=$as_save_IFS
54445dc2
TT
4970 case $as_dir in #(((
4971 '') as_dir=./ ;;
4972 */) ;;
4973 *) as_dir=$as_dir/ ;;
4974 esac
57aa50d4 4975 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
4976 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4977 if test "$as_dir$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
57aa50d4
TT
4978 ac_prog_rejected=yes
4979 continue
4980 fi
4981 ac_cv_prog_CC="cc"
54445dc2 4982 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
4983 break 2
4984 fi
4985done
4986 done
4987IFS=$as_save_IFS
b0cacab0 4988
57aa50d4
TT
4989if test $ac_prog_rejected = yes; then
4990 # We found a bogon in the path, so make sure we never use it.
4991 set dummy $ac_cv_prog_CC
4992 shift
4993 if test $# != 0; then
4994 # We chose a different compiler from the bogus one.
4995 # However, it has the same basename, so the bogon will be chosen
4996 # first if we set CC to just the basename; use the full file name.
4997 shift
54445dc2 4998 ac_cv_prog_CC="$as_dir$ac_word${1+' '}$@"
57aa50d4 4999 fi
b0cacab0 5000fi
b0cacab0
TT
5001fi
5002fi
57aa50d4
TT
5003CC=$ac_cv_prog_CC
5004if test -n "$CC"; then
54445dc2
TT
5005 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5006printf "%s\n" "$CC" >&6; }
57aa50d4 5007else
54445dc2
TT
5008 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5009printf "%s\n" "no" >&6; }
b0cacab0 5010fi
b0cacab0 5011
b0cacab0
TT
5012
5013fi
57aa50d4
TT
5014if test -z "$CC"; then
5015 if test -n "$ac_tool_prefix"; then
5016 for ac_prog in cl.exe
5017 do
5018 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5019set dummy $ac_tool_prefix$ac_prog; ac_word=$2
54445dc2
TT
5020{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5021printf %s "checking for $ac_word... " >&6; }
5022if test ${ac_cv_prog_CC+y}
5023then :
5024 printf %s "(cached) " >&6
5025else $as_nop
57aa50d4
TT
5026 if test -n "$CC"; then
5027 ac_cv_prog_CC="$CC" # Let the user override the test.
5028else
5029as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5030for as_dir in $PATH
5031do
5032 IFS=$as_save_IFS
54445dc2
TT
5033 case $as_dir in #(((
5034 '') as_dir=./ ;;
5035 */) ;;
5036 *) as_dir=$as_dir/ ;;
5037 esac
57aa50d4 5038 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 5039 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 5040 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
54445dc2 5041 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
5042 break 2
5043 fi
5044done
5045 done
5046IFS=$as_save_IFS
b0cacab0 5047
57aa50d4
TT
5048fi
5049fi
5050CC=$ac_cv_prog_CC
5051if test -n "$CC"; then
54445dc2
TT
5052 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5053printf "%s\n" "$CC" >&6; }
57aa50d4 5054else
54445dc2
TT
5055 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5056printf "%s\n" "no" >&6; }
57aa50d4 5057fi
b0cacab0
TT
5058
5059
57aa50d4
TT
5060 test -n "$CC" && break
5061 done
5062fi
5063if test -z "$CC"; then
5064 ac_ct_CC=$CC
5065 for ac_prog in cl.exe
b0cacab0 5066do
57aa50d4
TT
5067 # Extract the first word of "$ac_prog", so it can be a program name with args.
5068set dummy $ac_prog; ac_word=$2
54445dc2
TT
5069{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5070printf %s "checking for $ac_word... " >&6; }
5071if test ${ac_cv_prog_ac_ct_CC+y}
5072then :
5073 printf %s "(cached) " >&6
5074else $as_nop
57aa50d4
TT
5075 if test -n "$ac_ct_CC"; then
5076 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
b0cacab0 5077else
57aa50d4
TT
5078as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5079for as_dir in $PATH
5080do
5081 IFS=$as_save_IFS
54445dc2
TT
5082 case $as_dir in #(((
5083 '') as_dir=./ ;;
5084 */) ;;
5085 *) as_dir=$as_dir/ ;;
5086 esac
57aa50d4 5087 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 5088 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 5089 ac_cv_prog_ac_ct_CC="$ac_prog"
54445dc2 5090 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
5091 break 2
5092 fi
5093done
5094 done
5095IFS=$as_save_IFS
b0cacab0 5096
b0cacab0 5097fi
b0cacab0 5098fi
57aa50d4
TT
5099ac_ct_CC=$ac_cv_prog_ac_ct_CC
5100if test -n "$ac_ct_CC"; then
54445dc2
TT
5101 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5102printf "%s\n" "$ac_ct_CC" >&6; }
57aa50d4 5103else
54445dc2
TT
5104 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5105printf "%s\n" "no" >&6; }
b0cacab0
TT
5106fi
5107
b0cacab0 5108
57aa50d4
TT
5109 test -n "$ac_ct_CC" && break
5110done
b0cacab0 5111
57aa50d4
TT
5112 if test "x$ac_ct_CC" = x; then
5113 CC=""
5114 else
5115 case $cross_compiling:$ac_tool_warned in
5116yes:)
54445dc2
TT
5117{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5118printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
57aa50d4 5119ac_tool_warned=yes ;;
e1052144 5120esac
57aa50d4
TT
5121 CC=$ac_ct_CC
5122 fi
5123fi
b0cacab0 5124
b0cacab0 5125fi
54445dc2
TT
5126if test -z "$CC"; then
5127 if test -n "$ac_tool_prefix"; then
5128 # Extract the first word of "${ac_tool_prefix}clang", so it can be a program name with args.
5129set dummy ${ac_tool_prefix}clang; ac_word=$2
5130{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5131printf %s "checking for $ac_word... " >&6; }
5132if test ${ac_cv_prog_CC+y}
5133then :
5134 printf %s "(cached) " >&6
5135else $as_nop
5136 if test -n "$CC"; then
5137 ac_cv_prog_CC="$CC" # Let the user override the test.
cdf186e4 5138else
54445dc2
TT
5139as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5140for as_dir in $PATH
57aa50d4 5141do
54445dc2
TT
5142 IFS=$as_save_IFS
5143 case $as_dir in #(((
5144 '') as_dir=./ ;;
5145 */) ;;
5146 *) as_dir=$as_dir/ ;;
5147 esac
5148 for ac_exec_ext in '' $ac_executable_extensions; do
5149 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
5150 ac_cv_prog_CC="${ac_tool_prefix}clang"
5151 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
5152 break 2
5153 fi
57aa50d4 5154done
54445dc2
TT
5155 done
5156IFS=$as_save_IFS
2a29f135 5157
e1052144 5158fi
14b596d4 5159fi
54445dc2
TT
5160CC=$ac_cv_prog_CC
5161if test -n "$CC"; then
5162 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5163printf "%s\n" "$CC" >&6; }
14b596d4 5164else
54445dc2
TT
5165 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5166printf "%s\n" "no" >&6; }
14b596d4
TT
5167fi
5168
57aa50d4 5169
14b596d4 5170fi
54445dc2
TT
5171if test -z "$ac_cv_prog_CC"; then
5172 ac_ct_CC=$CC
5173 # Extract the first word of "clang", so it can be a program name with args.
5174set dummy clang; ac_word=$2
5175{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5176printf %s "checking for $ac_word... " >&6; }
5177if test ${ac_cv_prog_ac_ct_CC+y}
5178then :
5179 printf %s "(cached) " >&6
5180else $as_nop
5181 if test -n "$ac_ct_CC"; then
5182 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5aa6c3f6 5183else
54445dc2
TT
5184as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5185for as_dir in $PATH
93613951
TT
5186do
5187 IFS=$as_save_IFS
54445dc2
TT
5188 case $as_dir in #(((
5189 '') as_dir=./ ;;
5190 */) ;;
5191 *) as_dir=$as_dir/ ;;
5192 esac
93613951 5193 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
5194 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
5195 ac_cv_prog_ac_ct_CC="clang"
5196 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
5197 break 2
5198 fi
5199done
93613951
TT
5200 done
5201IFS=$as_save_IFS
54445dc2
TT
5202
5203fi
5204fi
5205ac_ct_CC=$ac_cv_prog_ac_ct_CC
5206if test -n "$ac_ct_CC"; then
5207 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5208printf "%s\n" "$ac_ct_CC" >&6; }
5209else
5210 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
5211printf "%s\n" "no" >&6; }
5212fi
5213
5214 if test "x$ac_ct_CC" = x; then
5215 CC=""
5216 else
5217 case $cross_compiling:$ac_tool_warned in
5218yes:)
5219{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5220printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5221ac_tool_warned=yes ;;
5222esac
5223 CC=$ac_ct_CC
93613951 5224 fi
5aa6c3f6 5225else
54445dc2 5226 CC="$ac_cv_prog_CC"
93613951 5227fi
183c73b0
TT
5228
5229fi
5230
5231
54445dc2
TT
5232test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5233printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
5234as_fn_error $? "no acceptable C compiler found in \$PATH
5235See \`config.log' for more details" "$LINENO" 5; }
5236
5237# Provide some information about the compiler.
5238printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
5239set X $ac_compile
5240ac_compiler=$2
5241for ac_option in --version -v -V -qversion -version; do
5242 { { ac_try="$ac_compiler $ac_option >&5"
5243case "(($ac_try" in
5244 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5245 *) ac_try_echo=$ac_try;;
5246esac
5247eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5248printf "%s\n" "$ac_try_echo"; } >&5
5249 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
5250 ac_status=$?
5251 if test -s conftest.err; then
5252 sed '10a\
5253... rest of stderr output deleted ...
5254 10q' conftest.err >conftest.er1
5255 cat conftest.er1 >&5
5256 fi
5257 rm -f conftest.er1 conftest.err
5258 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5259 test $ac_status = 0; }
5260done
5261
5262{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C" >&5
5263printf %s "checking whether the compiler supports GNU C... " >&6; }
5264if test ${ac_cv_c_compiler_gnu+y}
5265then :
5266 printf %s "(cached) " >&6
5267else $as_nop
93613951
TT
5268 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5269/* end confdefs.h. */
91d11da1 5270
93613951 5271int
54445dc2 5272main (void)
93613951 5273{
54445dc2
TT
5274#ifndef __GNUC__
5275 choke me
5276#endif
183c73b0 5277
93613951
TT
5278 ;
5279 return 0;
5280}
5281_ACEOF
54445dc2
TT
5282if ac_fn_c_try_compile "$LINENO"
5283then :
5284 ac_compiler_gnu=yes
5285else $as_nop
5286 ac_compiler_gnu=no
5aa6c3f6 5287fi
54445dc2
TT
5288rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5289ac_cv_c_compiler_gnu=$ac_compiler_gnu
93613951 5290
93613951 5291fi
54445dc2
TT
5292{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5293printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; }
5294ac_compiler_gnu=$ac_cv_c_compiler_gnu
93613951 5295
54445dc2
TT
5296if test $ac_compiler_gnu = yes; then
5297 GCC=yes
5298else
5299 GCC=
93613951 5300fi
54445dc2
TT
5301ac_test_CFLAGS=${CFLAGS+y}
5302ac_save_CFLAGS=$CFLAGS
5303{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5304printf %s "checking whether $CC accepts -g... " >&6; }
5305if test ${ac_cv_prog_cc_g+y}
5306then :
5307 printf %s "(cached) " >&6
5308else $as_nop
5309 ac_save_c_werror_flag=$ac_c_werror_flag
5310 ac_c_werror_flag=yes
5311 ac_cv_prog_cc_g=no
5312 CFLAGS="-g"
5313 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
93613951 5314/* end confdefs.h. */
93613951 5315
54445dc2
TT
5316int
5317main (void)
5318{
5319
5320 ;
5321 return 0;
5322}
93613951 5323_ACEOF
54445dc2
TT
5324if ac_fn_c_try_compile "$LINENO"
5325then :
5326 ac_cv_prog_cc_g=yes
5327else $as_nop
5328 CFLAGS=""
5329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5330/* end confdefs.h. */
93613951 5331
54445dc2
TT
5332int
5333main (void)
5334{
93613951 5335
54445dc2
TT
5336 ;
5337 return 0;
5338}
5339_ACEOF
5340if ac_fn_c_try_compile "$LINENO"
5341then :
93613951 5342
54445dc2
TT
5343else $as_nop
5344 ac_c_werror_flag=$ac_save_c_werror_flag
5345 CFLAGS="-g"
5346 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
93613951 5347/* end confdefs.h. */
93613951 5348
93613951 5349int
54445dc2 5350main (void)
93613951 5351{
54445dc2
TT
5352
5353 ;
93613951
TT
5354 return 0;
5355}
5356_ACEOF
54445dc2
TT
5357if ac_fn_c_try_compile "$LINENO"
5358then :
5359 ac_cv_prog_cc_g=yes
5360fi
5361rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5362fi
5363rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5364fi
5365rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5366 ac_c_werror_flag=$ac_save_c_werror_flag
5367fi
5368{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5369printf "%s\n" "$ac_cv_prog_cc_g" >&6; }
5370if test $ac_test_CFLAGS; then
5371 CFLAGS=$ac_save_CFLAGS
5372elif test $ac_cv_prog_cc_g = yes; then
5373 if test "$GCC" = yes; then
5374 CFLAGS="-g -O2"
5375 else
5376 CFLAGS="-g"
5377 fi
93613951 5378else
54445dc2
TT
5379 if test "$GCC" = yes; then
5380 CFLAGS="-O2"
5381 else
5382 CFLAGS=
5383 fi
93613951 5384fi
54445dc2
TT
5385ac_prog_cc_stdc=no
5386if test x$ac_prog_cc_stdc = xno
5387then :
5388 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5
5389printf %s "checking for $CC option to enable C11 features... " >&6; }
5390if test ${ac_cv_prog_cc_c11+y}
5391then :
5392 printf %s "(cached) " >&6
5393else $as_nop
5394 ac_cv_prog_cc_c11=no
5395ac_save_CC=$CC
5396cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5397/* end confdefs.h. */
5398$ac_c_conftest_c11_program
5399_ACEOF
5400for ac_arg in '' -std=gnu11
5401do
5402 CC="$ac_save_CC $ac_arg"
5403 if ac_fn_c_try_compile "$LINENO"
5404then :
5405 ac_cv_prog_cc_c11=$ac_arg
5406fi
5407rm -f core conftest.err conftest.$ac_objext conftest.beam
5408 test "x$ac_cv_prog_cc_c11" != "xno" && break
5409done
5410rm -f conftest.$ac_ext
5411CC=$ac_save_CC
5412fi
5413
5414if test "x$ac_cv_prog_cc_c11" = xno
5415then :
5416 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5417printf "%s\n" "unsupported" >&6; }
5418else $as_nop
5419 if test "x$ac_cv_prog_cc_c11" = x
5420then :
5421 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5422printf "%s\n" "none needed" >&6; }
5423else $as_nop
5424 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5
5425printf "%s\n" "$ac_cv_prog_cc_c11" >&6; }
5426 CC="$CC $ac_cv_prog_cc_c11"
5427fi
5428 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11
5429 ac_prog_cc_stdc=c11
5430fi
5431fi
5432if test x$ac_prog_cc_stdc = xno
5433then :
5434 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5
5435printf %s "checking for $CC option to enable C99 features... " >&6; }
5436if test ${ac_cv_prog_cc_c99+y}
5437then :
5438 printf %s "(cached) " >&6
5439else $as_nop
5440 ac_cv_prog_cc_c99=no
5441ac_save_CC=$CC
5442cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5443/* end confdefs.h. */
5444$ac_c_conftest_c99_program
5445_ACEOF
5446for ac_arg in '' -std=gnu99 -std=c99 -c99 -qlanglvl=extc1x -qlanglvl=extc99 -AC99 -D_STDC_C99=
5447do
5448 CC="$ac_save_CC $ac_arg"
5449 if ac_fn_c_try_compile "$LINENO"
5450then :
5451 ac_cv_prog_cc_c99=$ac_arg
5452fi
5453rm -f core conftest.err conftest.$ac_objext conftest.beam
5454 test "x$ac_cv_prog_cc_c99" != "xno" && break
5455done
5456rm -f conftest.$ac_ext
5457CC=$ac_save_CC
5458fi
5459
5460if test "x$ac_cv_prog_cc_c99" = xno
5461then :
5462 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5463printf "%s\n" "unsupported" >&6; }
5464else $as_nop
5465 if test "x$ac_cv_prog_cc_c99" = x
5466then :
5467 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5468printf "%s\n" "none needed" >&6; }
5469else $as_nop
5470 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
5471printf "%s\n" "$ac_cv_prog_cc_c99" >&6; }
5472 CC="$CC $ac_cv_prog_cc_c99"
5473fi
5474 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
5475 ac_prog_cc_stdc=c99
5476fi
5477fi
5478if test x$ac_prog_cc_stdc = xno
5479then :
5480 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5
5481printf %s "checking for $CC option to enable C89 features... " >&6; }
5482if test ${ac_cv_prog_cc_c89+y}
5483then :
5484 printf %s "(cached) " >&6
5485else $as_nop
5486 ac_cv_prog_cc_c89=no
5487ac_save_CC=$CC
5488cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5489/* end confdefs.h. */
5490$ac_c_conftest_c89_program
5491_ACEOF
5492for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5493do
5494 CC="$ac_save_CC $ac_arg"
5495 if ac_fn_c_try_compile "$LINENO"
5496then :
5497 ac_cv_prog_cc_c89=$ac_arg
5498fi
5499rm -f core conftest.err conftest.$ac_objext conftest.beam
5500 test "x$ac_cv_prog_cc_c89" != "xno" && break
5501done
5502rm -f conftest.$ac_ext
5503CC=$ac_save_CC
93613951
TT
5504fi
5505
54445dc2
TT
5506if test "x$ac_cv_prog_cc_c89" = xno
5507then :
5508 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5509printf "%s\n" "unsupported" >&6; }
5510else $as_nop
5511 if test "x$ac_cv_prog_cc_c89" = x
5512then :
5513 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5514printf "%s\n" "none needed" >&6; }
5515else $as_nop
5516 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5517printf "%s\n" "$ac_cv_prog_cc_c89" >&6; }
5518 CC="$CC $ac_cv_prog_cc_c89"
5519fi
5520 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
5521 ac_prog_cc_stdc=c89
93613951
TT
5522fi
5523fi
93613951 5524
54445dc2
TT
5525ac_ext=c
5526ac_cpp='$CPP $CPPFLAGS'
5527ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5528ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5529ac_compiler_gnu=$ac_cv_c_compiler_gnu
5530
5531if test "$GCC" = yes; then
5532 RDYNAMIC="-rdynamic"
5533
5534fi
5535ac_ext=c
5536ac_cpp='$CPP $CPPFLAGS'
5537ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5538ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5539ac_compiler_gnu=$ac_cv_c_compiler_gnu
5540{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5541printf %s "checking how to run the C preprocessor... " >&6; }
5542# On Suns, sometimes $CPP names a directory.
5543if test -n "$CPP" && test -d "$CPP"; then
5544 CPP=
5545fi
5546if test -z "$CPP"; then
5547 if test ${ac_cv_prog_CPP+y}
5548then :
5549 printf %s "(cached) " >&6
5550else $as_nop
5551 # Double quotes because $CC needs to be expanded
5552 for CPP in "$CC -E" "$CC -E -traditional-cpp" cpp /lib/cpp
5553 do
5554 ac_preproc_ok=false
5555for ac_c_preproc_warn_flag in '' yes
5556do
5557 # Use a header file that comes with gcc, so configuring glibc
5558 # with a fresh cross-compiler works.
5559 # On the NeXT, cc -E runs the code through the compiler's parser,
5560 # not just through cpp. "Syntax error" is here to catch this case.
5561 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5562/* end confdefs.h. */
5563#include <limits.h>
5564 Syntax error
5565_ACEOF
5566if ac_fn_c_try_cpp "$LINENO"
5567then :
93613951 5568
54445dc2
TT
5569else $as_nop
5570 # Broken: fails on valid input.
5571continue
93613951 5572fi
54445dc2 5573rm -f conftest.err conftest.i conftest.$ac_ext
93613951 5574
54445dc2
TT
5575 # OK, works on sane cases. Now check whether nonexistent headers
5576 # can be detected and how.
5577 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5578/* end confdefs.h. */
5579#include <ac_nonexistent.h>
93613951 5580_ACEOF
54445dc2
TT
5581if ac_fn_c_try_cpp "$LINENO"
5582then :
5583 # Broken: success on invalid input.
5584continue
5585else $as_nop
5586 # Passes both tests.
5587ac_preproc_ok=:
5588break
93613951 5589fi
54445dc2 5590rm -f conftest.err conftest.i conftest.$ac_ext
93613951
TT
5591
5592done
54445dc2
TT
5593# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5594rm -f conftest.i conftest.err conftest.$ac_ext
5595if $ac_preproc_ok
5596then :
5597 break
93613951
TT
5598fi
5599
54445dc2
TT
5600 done
5601 ac_cv_prog_CPP=$CPP
93613951 5602
54445dc2
TT
5603fi
5604 CPP=$ac_cv_prog_CPP
93613951 5605else
54445dc2
TT
5606 ac_cv_prog_CPP=$CPP
5607fi
5608{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5609printf "%s\n" "$CPP" >&6; }
5610ac_preproc_ok=false
5611for ac_c_preproc_warn_flag in '' yes
5612do
5613 # Use a header file that comes with gcc, so configuring glibc
5614 # with a fresh cross-compiler works.
5615 # On the NeXT, cc -E runs the code through the compiler's parser,
5616 # not just through cpp. "Syntax error" is here to catch this case.
93613951
TT
5617 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5618/* end confdefs.h. */
54445dc2
TT
5619#include <limits.h>
5620 Syntax error
5621_ACEOF
5622if ac_fn_c_try_cpp "$LINENO"
5623then :
93613951 5624
54445dc2
TT
5625else $as_nop
5626 # Broken: fails on valid input.
5627continue
5628fi
5629rm -f conftest.err conftest.i conftest.$ac_ext
93613951 5630
54445dc2
TT
5631 # OK, works on sane cases. Now check whether nonexistent headers
5632 # can be detected and how.
5633 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5634/* end confdefs.h. */
5635#include <ac_nonexistent.h>
93613951 5636_ACEOF
54445dc2
TT
5637if ac_fn_c_try_cpp "$LINENO"
5638then :
5639 # Broken: success on invalid input.
5640continue
5641else $as_nop
5642 # Passes both tests.
5643ac_preproc_ok=:
5644break
93613951 5645fi
54445dc2 5646rm -f conftest.err conftest.i conftest.$ac_ext
93613951 5647
54445dc2
TT
5648done
5649# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5650rm -f conftest.i conftest.err conftest.$ac_ext
5651if $ac_preproc_ok
5652then :
93613951 5653
54445dc2
TT
5654else $as_nop
5655 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5656printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
5657as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
5658See \`config.log' for more details" "$LINENO" 5; }
5659fi
93613951 5660
54445dc2
TT
5661ac_ext=c
5662ac_cpp='$CPP $CPPFLAGS'
5663ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5664ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5665ac_compiler_gnu=$ac_cv_c_compiler_gnu
93613951 5666
54445dc2
TT
5667{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for additional special compiler flags" >&5
5668printf %s "checking for additional special compiler flags... " >&6; }
5669if test "$GCC" = yes
5670then
5671 case "$host_cpu" in
5672 alpha) addcflags="-mieee" ;;
5673 esac
5674fi
5675if test "x$addcflags" != x
5676then
5677 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $addcflags" >&5
5678printf "%s\n" "$addcflags" >&6; }
5679 CFLAGS="$addcflags $CFLAGS"
5680else
5681 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: (none)" >&5
5682printf "%s\n" "(none)" >&6; }
5683fi
93613951
TT
5684LIB_EXT=.a
5685STATIC_LIB_EXT=.a
5686PROFILED_LIB_EXT=.a
5687
5688# Check whether --with-root-prefix was given.
54445dc2
TT
5689if test ${with_root_prefix+y}
5690then :
93613951 5691 withval=$with_root_prefix; root_prefix=$withval
54445dc2 5692else $as_nop
93613951
TT
5693 root_prefix=NONE
5694fi
5695# Check whether --enable-maintainer-mode was given.
54445dc2
TT
5696if test ${enable_maintainer_mode+y}
5697then :
93613951
TT
5698 enableval=$enable_maintainer_mode; if test "$enableval" = "no"
5699then
5700 MAINTAINER_CMT=#
54445dc2
TT
5701 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling maintainer mode" >&5
5702printf "%s\n" "Disabling maintainer mode" >&6; }
93613951
TT
5703else
5704 MAINTAINER_CMT=
54445dc2
TT
5705 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling maintainer mode" >&5
5706printf "%s\n" "Enabling maintainer mode" >&6; }
93613951
TT
5707fi
5708
54445dc2 5709else $as_nop
93613951 5710 MAINTAINER_CMT=#
54445dc2
TT
5711{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling maintainer mode by default" >&5
5712printf "%s\n" "Disabling maintainer mode by default" >&6; }
93613951
TT
5713
5714fi
5715
5716
5717# Check whether --enable-symlink-install was given.
54445dc2
TT
5718if test ${enable_symlink_install+y}
5719then :
93613951
TT
5720 enableval=$enable_symlink_install; if test "$enableval" = "no"
5721then
5722 LINK_INSTALL_FLAGS=-f
54445dc2
TT
5723 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling symlinks for install" >&5
5724printf "%s\n" "Disabling symlinks for install" >&6; }
93613951
TT
5725else
5726 LINK_INSTALL_FLAGS=-sf
54445dc2
TT
5727 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling symlinks for install" >&5
5728printf "%s\n" "Enabling symlinks for install" >&6; }
93613951
TT
5729fi
5730
54445dc2 5731else $as_nop
93613951 5732 LINK_INSTALL_FLAGS=-f
54445dc2
TT
5733{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling symlinks for install by default" >&5
5734printf "%s\n" "Disabling symlinks for install by default" >&6; }
93613951
TT
5735
5736fi
5737
5738
5739relative_symlink_defined=
5740# Check whether --enable-relative-symlinks was given.
54445dc2
TT
5741if test ${enable_relative_symlinks+y}
5742then :
93613951
TT
5743 enableval=$enable_relative_symlinks; if test "$enableval" = "no"
5744then
5745 SYMLINK_RELATIVE=
5746 relative_symlink_defined=yes
54445dc2
TT
5747 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling relative symlinks for install" >&5
5748printf "%s\n" "Disabling relative symlinks for install" >&6; }
93613951
TT
5749else
5750 SYMLINK_RELATIVE=--relative
5751 relative_symlink_defined=yes
54445dc2
TT
5752 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling relative symlinks for install" >&5
5753printf "%s\n" "Enabling relative symlinks for install" >&6; }
93613951
TT
5754fi
5755fi
5756
5757# Check whether --enable-symlink-relative-symlinks was given.
54445dc2
TT
5758if test ${enable_symlink_relative_symlinks+y}
5759then :
93613951
TT
5760 enableval=$enable_symlink_relative_symlinks; if test "$enableval" = "no"
5761then
5762 SYMLINK_RELATIVE=yes
54445dc2
TT
5763 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling relative symlinks for install" >&5
5764printf "%s\n" "Disabling relative symlinks for install" >&6; }
93613951
TT
5765else
5766 SYMLINK_RELATIVE=--relative
54445dc2
TT
5767 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling relative symlinks for install" >&5
5768printf "%s\n" "Enabling relative symlinks for install" >&6; }
93613951
TT
5769fi
5770
54445dc2 5771else $as_nop
93613951
TT
5772 if test -z "$relative_symlink_defined"
5773then
5774 SYMLINK_RELATIVE=
54445dc2
TT
5775{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling relative symlinks for install by default" >&5
5776printf "%s\n" "Disabling relative symlinks for install by default" >&6; }
93613951
TT
5777fi
5778
5779fi
5780
5781
5782# Check whether --enable-symlink-build was given.
54445dc2
TT
5783if test ${enable_symlink_build+y}
5784then :
5aa6c3f6
TT
5785 enableval=$enable_symlink_build; if test "$enableval" = "no"
5786then
5787 LINK_BUILD_FLAGS=
54445dc2
TT
5788 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling symlinks for build" >&5
5789printf "%s\n" "Disabling symlinks for build" >&6; }
5aa6c3f6
TT
5790else
5791 LINK_BUILD_FLAGS=-s
54445dc2
TT
5792 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling symlinks for build" >&5
5793printf "%s\n" "Enabling symlinks for build" >&6; }
5aa6c3f6
TT
5794fi
5795
54445dc2 5796else $as_nop
5aa6c3f6 5797 LINK_BUILD_FLAGS=
54445dc2
TT
5798{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling symlinks for build by default" >&5
5799printf "%s\n" "Disabling symlinks for build by default" >&6; }
5aa6c3f6
TT
5800
5801fi
5802
5803
57aa50d4 5804# Check whether --enable-verbose-makecmds was given.
54445dc2
TT
5805if test ${enable_verbose_makecmds+y}
5806then :
57aa50d4
TT
5807 enableval=$enable_verbose_makecmds; if test "$enableval" = "no"
5808then
54445dc2
TT
5809 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling verbose make commands" >&5
5810printf "%s\n" "Disabling verbose make commands" >&6; }
57aa50d4 5811 E=@echo
c1986ecb 5812 ES=echo
57aa50d4 5813 Q=@
14b596d4 5814else
54445dc2
TT
5815 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling verbose make commands" >&5
5816printf "%s\n" "Enabling verbose make commands" >&6; }
57aa50d4 5817 E=@\\#
c1986ecb 5818 ES=\\#
57aa50d4
TT
5819 Q=
5820fi
14b596d4 5821
54445dc2
TT
5822else $as_nop
5823 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling verbose make commands" >&5
5824printf "%s\n" "Disabling verbose make commands" >&6; }
57aa50d4 5825E=@echo
c1986ecb 5826ES=echo
57aa50d4 5827Q=@
14b596d4 5828
14b596d4
TT
5829fi
5830
14b596d4 5831
57aa50d4 5832
c1986ecb 5833
57aa50d4
TT
5834E2_PKG_CONFIG_STATIC=--static
5835LDFLAG_DYNAMIC=
5836PRIVATE_LIBS_CMT=
5837# Check whether --enable-elf-shlibs was given.
54445dc2
TT
5838if test ${enable_elf_shlibs+y}
5839then :
57aa50d4 5840 enableval=$enable_elf_shlibs; if test "$enableval" = "no"
cdf186e4 5841then
57aa50d4
TT
5842 ELF_CMT=#
5843 MAKEFILE_ELF=/dev/null
54445dc2
TT
5844 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling ELF shared libraries" >&5
5845printf "%s\n" "Disabling ELF shared libraries" >&6; }
cdf186e4 5846else
57aa50d4
TT
5847 E2_PKG_CONFIG_STATIC=
5848 ELF_CMT=
5849 MAKEFILE_ELF=$srcdir/lib/Makefile.elf-lib
5850 case "$host_os" in
5851 solaris2.*)
5852 MAKEFILE_ELF=$srcdir/lib/Makefile.solaris-lib
5853 ;;
5854 esac
5855 BINARY_TYPE=elfbin
5856 LIB_EXT=.so
5857 PRIVATE_LIBS_CMT=#
5858 LDFLAG_DYNAMIC='-Wl,-rpath-link,$(top_builddir)/lib'
54445dc2
TT
5859 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling ELF shared libraries" >&5
5860printf "%s\n" "Enabling ELF shared libraries" >&6; }
cdf186e4
TT
5861fi
5862
54445dc2 5863else $as_nop
57aa50d4
TT
5864 MAKEFILE_ELF=/dev/null
5865ELF_CMT=#
54445dc2
TT
5866{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling ELF shared libraries by default" >&5
5867printf "%s\n" "Disabling ELF shared libraries by default" >&6; }
cdf186e4 5868
e1052144
TT
5869fi
5870
cdf186e4 5871
57aa50d4
TT
5872
5873# Check whether --enable-bsd-shlibs was given.
54445dc2
TT
5874if test ${enable_bsd_shlibs+y}
5875then :
57aa50d4 5876 enableval=$enable_bsd_shlibs; if test "$enableval" = "no"
cdf186e4 5877then
57aa50d4
TT
5878 BSDLIB_CMT=#
5879 MAKEFILE_BSDLIB=/dev/null
54445dc2
TT
5880 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling BSD shared libraries" >&5
5881printf "%s\n" "Disabling BSD shared libraries" >&6; }
cdf186e4 5882else
57aa50d4
TT
5883 E2_PKG_CONFIG_STATIC=
5884 BSDLIB_CMT=
5885 MAKEFILE_BSDLIB=$srcdir/lib/Makefile.bsd-lib
5886 LIB_EXT=.so
5887 case "$host_os" in
5888 darwin*)
5889 MAKEFILE_BSDLIB=$srcdir/lib/Makefile.darwin-lib
5890 LIB_EXT=.dylib
5891 ;;
5892 esac
54445dc2
TT
5893 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling BSD shared libraries" >&5
5894printf "%s\n" "Enabling BSD shared libraries" >&6; }
cdf186e4
TT
5895fi
5896
54445dc2 5897else $as_nop
57aa50d4
TT
5898 MAKEFILE_BSDLIB=/dev/null
5899BSDLIB_CMT=#
54445dc2
TT
5900{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling BSD shared libraries by default" >&5
5901printf "%s\n" "Disabling BSD shared libraries by default" >&6; }
cdf186e4 5902
e1052144
TT
5903fi
5904
cdf186e4 5905
57aa50d4
TT
5906
5907# Check whether --enable-profile was given.
54445dc2
TT
5908if test ${enable_profile+y}
5909then :
57aa50d4 5910 enableval=$enable_profile; if test "$enableval" = "no"
cdf186e4 5911then
57aa50d4
TT
5912 PROFILE_CMT=#
5913 MAKEFILE_PROFILE=/dev/null
54445dc2
TT
5914 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling profiling libraries" >&5
5915printf "%s\n" "Disabling profiling libraries" >&6; }
cdf186e4 5916else
57aa50d4
TT
5917 PROFILE_CMT=
5918 MAKEFILE_PROFILE=$srcdir/lib/Makefile.profile
5919 PROFILED_LIB_EXT=_p.a
54445dc2
TT
5920 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Building profiling libraries" >&5
5921printf "%s\n" "Building profiling libraries" >&6; }
cdf186e4
TT
5922fi
5923
54445dc2 5924else $as_nop
57aa50d4
TT
5925 PROFILE_CMT=#
5926MAKEFILE_PROFILE=/dev/null
54445dc2
TT
5927{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling profiling libraries by default" >&5
5928printf "%s\n" "Disabling profiling libraries by default" >&6; }
cdf186e4 5929
e1052144
TT
5930fi
5931
cdf186e4 5932
57aa50d4 5933
fedfb27f 5934# Check whether --enable-gcov was given.
54445dc2
TT
5935if test ${enable_gcov+y}
5936then :
fedfb27f
TT
5937 enableval=$enable_gcov; if test "$enableval" = "yes"
5938then
5939 CFLAGS="-g -fprofile-arcs -ftest-coverage"
5940 LDFLAGS="-fprofile-arcs -ftest-coverage"
54445dc2
TT
5941 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling gcov support" >&5
5942printf "%s\n" "Enabling gcov support" >&6; }
fedfb27f
TT
5943fi
5944
5945fi
5946
fd1677e8
TT
5947CFLAGS_SHLIB="${CFLAGS_SHLIB:-$CFLAGS}"
5948CFLAGS_STLIB="${CFLAGS_STLIB:-$CFLAGS}"
5949LDFLAGS_SHLIB=${LDFLAGS_SHLIB:-$LDFLAGS}
5950LDFLAGS_STATIC=${LDFLAGS_STATIC:-$LDFLAGS}
5951# Check whether --enable-hardening was given.
54445dc2
TT
5952if test ${enable_hardening+y}
5953then :
fd1677e8
TT
5954 enableval=$enable_hardening; if test "$enableval" = "yes"
5955then
5956 HARDEN_CFLAGS="-D_FORTIFY_SOURCE=2 -fstack-protector-strong"
5957 HARDEN_LDFLAGS="-Wl,-z,relro -Wl,-z,now"
5958 CFLAGS="$CFLAGS $HARDEN_CFLAGS -fPIE"
5959 CFLAGS_SHLIB="$CFLAGS_SHLIB $HARDEN_CFLAGS"
5960 CFLAGS_STLIB="$CFLAGS_STLIB $HARDEN_CFLAGS -fPIE"
5961 LDFLAGS="$LDFLAGS $HARDEN_LDFLAGS -fPIE -pie"
5962 LDFLAGS_STATIC="$LDFLAGS_STATIC $HARDEN_LDFLAGS"
5963 LDFLAGS_SHLIB="$LDFLAGS_SHLIB $HARDEN_LDFLAGS"
54445dc2
TT
5964 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling hardening support" >&5
5965printf "%s\n" "Enabling hardening support" >&6; }
fd1677e8
TT
5966fi
5967
5968fi
cdf186e4 5969
57aa50d4
TT
5970
5971
5972
5973
5974
5975# Check whether --enable-jbd-debug was given.
54445dc2
TT
5976if test ${enable_jbd_debug+y}
5977then :
57aa50d4 5978 enableval=$enable_jbd_debug; if test "$enableval" = "no"
5d40773b 5979then
54445dc2
TT
5980 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling journal debugging" >&5
5981printf "%s\n" "Disabling journal debugging" >&6; }
5d40773b 5982else
d1154eb4 5983
54445dc2 5984printf "%s\n" "#define CONFIG_JBD_DEBUG 1" >>confdefs.h
57aa50d4 5985
54445dc2
TT
5986 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling journal debugging" >&5
5987printf "%s\n" "Enabling journal debugging" >&6; }
5d40773b
TT
5988fi
5989
54445dc2
TT
5990else $as_nop
5991 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling journal debugging by default" >&5
5992printf "%s\n" "Disabling journal debugging by default" >&6; }
5d40773b 5993
e1052144
TT
5994fi
5995
57aa50d4 5996# Check whether --enable-blkid-debug was given.
54445dc2
TT
5997if test ${enable_blkid_debug+y}
5998then :
57aa50d4 5999 enableval=$enable_blkid_debug; if test "$enableval" = "no"
3249394d 6000then
54445dc2
TT
6001 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling blkid debugging" >&5
6002printf "%s\n" "Disabling blkid debugging" >&6; }
3249394d 6003else
d1154eb4 6004
54445dc2 6005printf "%s\n" "#define CONFIG_BLKID_DEBUG 1" >>confdefs.h
57aa50d4 6006
54445dc2
TT
6007 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling blkid debugging" >&5
6008printf "%s\n" "Enabling blkid debugging" >&6; }
3249394d
TT
6009fi
6010
54445dc2
TT
6011else $as_nop
6012 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling blkid debugging by default" >&5
6013printf "%s\n" "Disabling blkid debugging by default" >&6; }
3249394d
TT
6014
6015fi
6016
57aa50d4 6017# Check whether --enable-testio-debug was given.
54445dc2
TT
6018if test ${enable_testio_debug+y}
6019then :
d1154eb4
TT
6020 enableval=$enable_testio_debug;
6021if test "$enableval" = "no"
3249394d 6022then
54445dc2
TT
6023 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling testio debugging" >&5
6024printf "%s\n" "Disabling testio debugging" >&6; }
57aa50d4 6025 TEST_IO_CMT="#"
3249394d 6026else
57aa50d4 6027 TEST_IO_CMT=
54445dc2 6028 printf "%s\n" "#define CONFIG_TESTIO_DEBUG 1" >>confdefs.h
3249394d 6029
54445dc2
TT
6030 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling testio debugging" >&5
6031printf "%s\n" "Enabling testio debugging" >&6; }
57aa50d4 6032fi
3249394d 6033
54445dc2
TT
6034else $as_nop
6035 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling testio debugging by default" >&5
6036printf "%s\n" "Enabling testio debugging by default" >&6; }
6037printf "%s\n" "#define CONFIG_TESTIO_DEBUG 1" >>confdefs.h
3249394d 6038
57aa50d4 6039TEST_IO_CMT=
3249394d
TT
6040
6041fi
6042
3249394d 6043
b9e66a18 6044# Check whether --enable-developer-features was given.
54445dc2
TT
6045if test ${enable_developer_features+y}
6046then :
b9e66a18
TT
6047 enableval=$enable_developer_features;
6048if test "$enableval" = "yes"
6049then
6050 DEV_FEATURES_CMT=
54445dc2 6051 printf "%s\n" "#define CONFIG_DEVELOPER_FEATURES 1" >>confdefs.h
b9e66a18 6052
54445dc2
TT
6053 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling ext4 developer features" >&5
6054printf "%s\n" "Enabling ext4 developer features" >&6; }
b9e66a18 6055else
54445dc2
TT
6056 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling ext4 developer features" >&5
6057printf "%s\n" "Disabling ext4 developer features" >&6; }
b9e66a18
TT
6058 DEV_FEATURES_CMT="#"
6059fi
6060
54445dc2
TT
6061else $as_nop
6062 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling ext4 developer features by default" >&5
6063printf "%s\n" "Disabling ext4 developer features by default" >&6; }
b9e66a18
TT
6064DEV_FEATURES_CMT=
6065
6066fi
6067
6068
57aa50d4
TT
6069
6070
93613951
TT
6071
6072
6073
6074
6075
57aa50d4 6076if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
93613951 6077 if test -n "$ac_tool_prefix"; then
57aa50d4
TT
6078 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
6079set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
54445dc2
TT
6080{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6081printf %s "checking for $ac_word... " >&6; }
6082if test ${ac_cv_path_PKG_CONFIG+y}
6083then :
6084 printf %s "(cached) " >&6
6085else $as_nop
57aa50d4
TT
6086 case $PKG_CONFIG in
6087 [\\/]* | ?:[\\/]*)
6088 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
6089 ;;
6090 *)
6091 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6092for as_dir in $PATH
6093do
6094 IFS=$as_save_IFS
54445dc2
TT
6095 case $as_dir in #(((
6096 '') as_dir=./ ;;
6097 */) ;;
6098 *) as_dir=$as_dir/ ;;
6099 esac
57aa50d4 6100 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
6101 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6102 ac_cv_path_PKG_CONFIG="$as_dir$ac_word$ac_exec_ext"
6103 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
6104 break 2
6105 fi
6106done
6107 done
6108IFS=$as_save_IFS
6109
6110 ;;
6111esac
6112fi
6113PKG_CONFIG=$ac_cv_path_PKG_CONFIG
6114if test -n "$PKG_CONFIG"; then
54445dc2
TT
6115 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
6116printf "%s\n" "$PKG_CONFIG" >&6; }
57aa50d4 6117else
54445dc2
TT
6118 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6119printf "%s\n" "no" >&6; }
3249394d
TT
6120fi
6121
6122
57aa50d4
TT
6123fi
6124if test -z "$ac_cv_path_PKG_CONFIG"; then
6125 ac_pt_PKG_CONFIG=$PKG_CONFIG
6126 # Extract the first word of "pkg-config", so it can be a program name with args.
6127set dummy pkg-config; ac_word=$2
54445dc2
TT
6128{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6129printf %s "checking for $ac_word... " >&6; }
6130if test ${ac_cv_path_ac_pt_PKG_CONFIG+y}
6131then :
6132 printf %s "(cached) " >&6
6133else $as_nop
57aa50d4
TT
6134 case $ac_pt_PKG_CONFIG in
6135 [\\/]* | ?:[\\/]*)
6136 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
6137 ;;
6138 *)
6139 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6140for as_dir in $PATH
6141do
6142 IFS=$as_save_IFS
54445dc2
TT
6143 case $as_dir in #(((
6144 '') as_dir=./ ;;
6145 */) ;;
6146 *) as_dir=$as_dir/ ;;
6147 esac
57aa50d4 6148 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
6149 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6150 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir$ac_word$ac_exec_ext"
6151 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
6152 break 2
6153 fi
6154done
6155 done
6156IFS=$as_save_IFS
3249394d 6157
57aa50d4
TT
6158 ;;
6159esac
6160fi
6161ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
6162if test -n "$ac_pt_PKG_CONFIG"; then
54445dc2
TT
6163 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
6164printf "%s\n" "$ac_pt_PKG_CONFIG" >&6; }
57aa50d4 6165else
54445dc2
TT
6166 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6167printf "%s\n" "no" >&6; }
57aa50d4 6168fi
3249394d 6169
57aa50d4
TT
6170 if test "x$ac_pt_PKG_CONFIG" = x; then
6171 PKG_CONFIG=""
6172 else
6173 case $cross_compiling:$ac_tool_warned in
6174yes:)
54445dc2
TT
6175{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6176printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
57aa50d4
TT
6177ac_tool_warned=yes ;;
6178esac
6179 PKG_CONFIG=$ac_pt_PKG_CONFIG
3249394d 6180 fi
57aa50d4
TT
6181else
6182 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
6183fi
3249394d
TT
6184
6185fi
57aa50d4 6186if test -n "$PKG_CONFIG"; then
93613951 6187 _pkg_min_version=0.9.0
54445dc2
TT
6188 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
6189printf %s "checking pkg-config is at least version $_pkg_min_version... " >&6; }
93613951 6190 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
54445dc2
TT
6191 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6192printf "%s\n" "yes" >&6; }
93613951 6193 else
54445dc2
TT
6194 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6195printf "%s\n" "no" >&6; }
93613951
TT
6196 PKG_CONFIG=""
6197 fi
57aa50d4
TT
6198fi
6199LIBUUID=
6200DEPLIBUUID=
6201STATIC_LIBUUID=
6202DEPSTATIC_LIBUUID=
6203PROFILED_LIBUUID=
6204DEPPROFILED_LIBUUID=
6205UUID_CMT=
6206# Check whether --enable-libuuid was given.
54445dc2
TT
6207if test ${enable_libuuid+y}
6208then :
57aa50d4 6209 enableval=$enable_libuuid; if test "$enableval" = "no"
5610f992 6210then
57aa50d4 6211 if test -z "$PKG_CONFIG"; then
d6a4bcb5 6212 as_fn_error $? "pkg-config not installed; please install it." "$LINENO" 5
57aa50d4
TT
6213 fi
6214
54445dc2
TT
6215 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for uuid_generate in -luuid" >&5
6216printf %s "checking for uuid_generate in -luuid... " >&6; }
6217if test ${ac_cv_lib_uuid_uuid_generate+y}
6218then :
6219 printf %s "(cached) " >&6
6220else $as_nop
57aa50d4 6221 ac_check_lib_save_LIBS=$LIBS
2d7583bd 6222LIBS="-luuid $LIBS"
57aa50d4
TT
6223cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6224/* end confdefs.h. */
5610f992 6225
57aa50d4
TT
6226/* Override any GCC internal prototype to avoid an error.
6227 Use char because int might match the return type of a GCC
6228 builtin and then its argument prototype would still apply. */
57aa50d4
TT
6229char uuid_generate ();
6230int
54445dc2 6231main (void)
57aa50d4
TT
6232{
6233return uuid_generate ();
6234 ;
6235 return 0;
6236}
6237_ACEOF
54445dc2
TT
6238if ac_fn_c_try_link "$LINENO"
6239then :
57aa50d4 6240 ac_cv_lib_uuid_uuid_generate=yes
54445dc2 6241else $as_nop
57aa50d4
TT
6242 ac_cv_lib_uuid_uuid_generate=no
6243fi
54445dc2 6244rm -f core conftest.err conftest.$ac_objext conftest.beam \
57aa50d4
TT
6245 conftest$ac_exeext conftest.$ac_ext
6246LIBS=$ac_check_lib_save_LIBS
6247fi
54445dc2
TT
6248{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_uuid_uuid_generate" >&5
6249printf "%s\n" "$ac_cv_lib_uuid_uuid_generate" >&6; }
6250if test "x$ac_cv_lib_uuid_uuid_generate" = xyes
6251then :
57aa50d4
TT
6252 LIBUUID=`$PKG_CONFIG --libs uuid`;
6253 STATIC_LIBUUID=`$PKG_CONFIG --static --libs uuid`
54445dc2 6254else $as_nop
d6a4bcb5 6255 as_fn_error $? "external uuid library not found" "$LINENO" 5
5610f992
TT
6256fi
6257
5afdf37b 6258 PROFILED_LIBUUID=$LIBUUID
57aa50d4 6259 UUID_CMT=#
54445dc2
TT
6260 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling private uuid library" >&5
6261printf "%s\n" "Disabling private uuid library" >&6; }
5610f992 6262else
57aa50d4
TT
6263 LIBUUID='$(LIB)/libuuid'$LIB_EXT
6264 DEPLIBUUID=$LIBUUID
6265 STATIC_LIBUUID='$(LIB)/libuuid'$STATIC_LIB_EXT
6266 DEPSTATIC_LIBUUID=$STATIC_LIBUUID
6267 PROFILED_LIBUUID='$(LIB)/libuuid'$PROFILED_LIB_EXT
6268 DEPPROFILED_LIBUUID=$PROFILED_LIBUUID
54445dc2
TT
6269 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling private uuid library" >&5
6270printf "%s\n" "Enabling private uuid library" >&6; }
57aa50d4 6271fi
5610f992 6272
54445dc2 6273else $as_nop
f5dffb81 6274 if test -n "$PKG_CONFIG"; then
54445dc2
TT
6275 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for uuid_generate in -luuid" >&5
6276printf %s "checking for uuid_generate in -luuid... " >&6; }
6277if test ${ac_cv_lib_uuid_uuid_generate+y}
6278then :
6279 printf %s "(cached) " >&6
6280else $as_nop
f5dffb81
TT
6281 ac_check_lib_save_LIBS=$LIBS
6282LIBS="-luuid $LIBS"
6283cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6284/* end confdefs.h. */
6285
6286/* Override any GCC internal prototype to avoid an error.
6287 Use char because int might match the return type of a GCC
6288 builtin and then its argument prototype would still apply. */
f5dffb81
TT
6289char uuid_generate ();
6290int
54445dc2 6291main (void)
f5dffb81
TT
6292{
6293return uuid_generate ();
6294 ;
6295 return 0;
6296}
6297_ACEOF
54445dc2
TT
6298if ac_fn_c_try_link "$LINENO"
6299then :
f5dffb81 6300 ac_cv_lib_uuid_uuid_generate=yes
54445dc2 6301else $as_nop
f5dffb81
TT
6302 ac_cv_lib_uuid_uuid_generate=no
6303fi
54445dc2 6304rm -f core conftest.err conftest.$ac_objext conftest.beam \
f5dffb81
TT
6305 conftest$ac_exeext conftest.$ac_ext
6306LIBS=$ac_check_lib_save_LIBS
6307fi
54445dc2
TT
6308{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_uuid_uuid_generate" >&5
6309printf "%s\n" "$ac_cv_lib_uuid_uuid_generate" >&6; }
6310if test "x$ac_cv_lib_uuid_uuid_generate" = xyes
6311then :
f5dffb81
TT
6312 LIBUUID=`$PKG_CONFIG --libs uuid`;
6313 STATIC_LIBUUID=`$PKG_CONFIG --static --libs uuid`
6314fi
6315
6316fi
6317if test -n "$LIBUUID"; then
6318 PROFILED_LIBUUID=$LIBUUID
6319 UUID_CMT=#
54445dc2
TT
6320 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Using system uuid by default" >&5
6321printf "%s\n" "Using system uuid by default" >&6; }
f5dffb81
TT
6322else
6323 LIBUUID='$(LIB)/libuuid'$LIB_EXT
6324 DEPLIBUUID=$LIBUUID
6325 STATIC_LIBUUID='$(LIB)/libuuid'$STATIC_LIB_EXT
6326 DEPSTATIC_LIBUUID=$STATIC_LIBUUID
6327 PROFILED_LIBUUID='$(LIB)/libuuid'$PROFILED_LIB_EXT
6328 DEPPROFILED_LIBUUID=$PROFILED_LIBUUID
54445dc2
TT
6329 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling private uuid library by default" >&5
6330printf "%s\n" "Enabling private uuid library by default" >&6; }
f5dffb81 6331fi
5610f992
TT
6332
6333fi
6334
6335
cdf186e4 6336
a64c9c13 6337
93636bde
TT
6338
6339
93636bde 6340
93636bde
TT
6341
6342
57aa50d4 6343
93613951
TT
6344
6345
6346
6347
6348
57aa50d4 6349if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
93613951 6350 if test -n "$ac_tool_prefix"; then
57aa50d4
TT
6351 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
6352set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
54445dc2
TT
6353{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6354printf %s "checking for $ac_word... " >&6; }
6355if test ${ac_cv_path_PKG_CONFIG+y}
6356then :
6357 printf %s "(cached) " >&6
6358else $as_nop
57aa50d4
TT
6359 case $PKG_CONFIG in
6360 [\\/]* | ?:[\\/]*)
6361 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
6362 ;;
e1052144 6363 *)
b0cacab0
TT
6364 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6365for as_dir in $PATH
6366do
6367 IFS=$as_save_IFS
54445dc2
TT
6368 case $as_dir in #(((
6369 '') as_dir=./ ;;
6370 */) ;;
6371 *) as_dir=$as_dir/ ;;
6372 esac
57aa50d4 6373 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
6374 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6375 ac_cv_path_PKG_CONFIG="$as_dir$ac_word$ac_exec_ext"
6376 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
6377 break 2
6378 fi
b0cacab0 6379done
57aa50d4 6380 done
e1052144 6381IFS=$as_save_IFS
b0cacab0 6382
57aa50d4 6383 ;;
b0cacab0
TT
6384esac
6385fi
57aa50d4
TT
6386PKG_CONFIG=$ac_cv_path_PKG_CONFIG
6387if test -n "$PKG_CONFIG"; then
54445dc2
TT
6388 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
6389printf "%s\n" "$PKG_CONFIG" >&6; }
07a0db15 6390else
54445dc2
TT
6391 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6392printf "%s\n" "no" >&6; }
07a0db15 6393fi
07a0db15 6394
57aa50d4
TT
6395
6396fi
6397if test -z "$ac_cv_path_PKG_CONFIG"; then
6398 ac_pt_PKG_CONFIG=$PKG_CONFIG
6399 # Extract the first word of "pkg-config", so it can be a program name with args.
6400set dummy pkg-config; ac_word=$2
54445dc2
TT
6401{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6402printf %s "checking for $ac_word... " >&6; }
6403if test ${ac_cv_path_ac_pt_PKG_CONFIG+y}
6404then :
6405 printf %s "(cached) " >&6
6406else $as_nop
57aa50d4 6407 case $ac_pt_PKG_CONFIG in
b0cacab0 6408 [\\/]* | ?:[\\/]*)
57aa50d4 6409 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
b0cacab0
TT
6410 ;;
6411 *)
6412 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6413for as_dir in $PATH
6414do
6415 IFS=$as_save_IFS
54445dc2
TT
6416 case $as_dir in #(((
6417 '') as_dir=./ ;;
6418 */) ;;
6419 *) as_dir=$as_dir/ ;;
6420 esac
57aa50d4 6421 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
6422 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6423 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir$ac_word$ac_exec_ext"
6424 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
b0cacab0
TT
6425 break 2
6426 fi
6427done
57aa50d4 6428 done
e1052144 6429IFS=$as_save_IFS
a64c9c13 6430
b0cacab0
TT
6431 ;;
6432esac
a64c9c13 6433fi
57aa50d4
TT
6434ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
6435if test -n "$ac_pt_PKG_CONFIG"; then
54445dc2
TT
6436 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
6437printf "%s\n" "$ac_pt_PKG_CONFIG" >&6; }
a64c9c13 6438else
54445dc2
TT
6439 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6440printf "%s\n" "no" >&6; }
a64c9c13 6441fi
a64c9c13 6442
57aa50d4
TT
6443 if test "x$ac_pt_PKG_CONFIG" = x; then
6444 PKG_CONFIG=""
b0cacab0 6445 else
57aa50d4
TT
6446 case $cross_compiling:$ac_tool_warned in
6447yes:)
54445dc2
TT
6448{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6449printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
57aa50d4
TT
6450ac_tool_warned=yes ;;
6451esac
6452 PKG_CONFIG=$ac_pt_PKG_CONFIG
b0cacab0 6453 fi
57aa50d4
TT
6454else
6455 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
a64c9c13 6456fi
93636bde 6457
a64c9c13 6458fi
57aa50d4 6459if test -n "$PKG_CONFIG"; then
93613951 6460 _pkg_min_version=0.9.0
54445dc2
TT
6461 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
6462printf %s "checking pkg-config is at least version $_pkg_min_version... " >&6; }
93613951 6463 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
54445dc2
TT
6464 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6465printf "%s\n" "yes" >&6; }
93613951 6466 else
54445dc2
TT
6467 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6468printf "%s\n" "no" >&6; }
93613951
TT
6469 PKG_CONFIG=""
6470 fi
57aa50d4
TT
6471fi
6472LIBBLKID=
6473DEPLIBBLKID=
6474STATIC_LIBBLKID=
6475DEPSTATIC_LIBBLKID=
6476PROFILED_LIBBLKID=
6477DEPPROFILED_LIBBLKID=
6478BLKID_CMT=
d1154eb4 6479
57aa50d4 6480# Check whether --enable-libblkid was given.
54445dc2
TT
6481if test ${enable_libblkid+y}
6482then :
57aa50d4
TT
6483 enableval=$enable_libblkid; if test "$enableval" = "no"
6484then
6485 if test -z "$PKG_CONFIG"; then
d6a4bcb5 6486 as_fn_error $? "pkg-config not installed; please install it." "$LINENO" 5
57aa50d4
TT
6487 fi
6488
54445dc2
TT
6489 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for blkid_get_cache in -lblkid" >&5
6490printf %s "checking for blkid_get_cache in -lblkid... " >&6; }
6491if test ${ac_cv_lib_blkid_blkid_get_cache+y}
6492then :
6493 printf %s "(cached) " >&6
6494else $as_nop
57aa50d4 6495 ac_check_lib_save_LIBS=$LIBS
2d7583bd 6496LIBS="-lblkid -luuid $LIBS"
57aa50d4
TT
6497cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6498/* end confdefs.h. */
6499
6500/* Override any GCC internal prototype to avoid an error.
6501 Use char because int might match the return type of a GCC
6502 builtin and then its argument prototype would still apply. */
57aa50d4
TT
6503char blkid_get_cache ();
6504int
54445dc2 6505main (void)
57aa50d4
TT
6506{
6507return blkid_get_cache ();
6508 ;
6509 return 0;
6510}
6511_ACEOF
54445dc2
TT
6512if ac_fn_c_try_link "$LINENO"
6513then :
57aa50d4 6514 ac_cv_lib_blkid_blkid_get_cache=yes
54445dc2 6515else $as_nop
57aa50d4 6516 ac_cv_lib_blkid_blkid_get_cache=no
a64c9c13 6517fi
54445dc2 6518rm -f core conftest.err conftest.$ac_objext conftest.beam \
57aa50d4
TT
6519 conftest$ac_exeext conftest.$ac_ext
6520LIBS=$ac_check_lib_save_LIBS
a64c9c13 6521fi
54445dc2
TT
6522{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_blkid_blkid_get_cache" >&5
6523printf "%s\n" "$ac_cv_lib_blkid_blkid_get_cache" >&6; }
6524if test "x$ac_cv_lib_blkid_blkid_get_cache" = xyes
6525then :
57aa50d4
TT
6526 LIBBLKID=`$PKG_CONFIG --libs blkid`;
6527 STATIC_LIBBLKID=`$PKG_CONFIG --static --libs blkid`
54445dc2 6528else $as_nop
d6a4bcb5 6529 as_fn_error $? "external blkid library not found" "$LINENO" 5
a64c9c13 6530fi
93636bde 6531
57aa50d4 6532 BLKID_CMT=#
5afdf37b 6533 PROFILED_LIBBLKID=$LIBBLKID
54445dc2
TT
6534 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling private blkid library" >&5
6535printf "%s\n" "Disabling private blkid library" >&6; }
07a0db15 6536else
57aa50d4
TT
6537 LIBBLKID='$(LIB)/libblkid'$LIB_EXT
6538 DEPLIBBLKID=$LIBBLKID
6539 STATIC_LIBBLKID='$(LIB)/libblkid'$STATIC_LIB_EXT
6540 DEPSTATIC_LIBBLKID=$STATIC_LIBBLKID
6541 PROFILED_LIBBLKID='$(LIB)/libblkid'$PROFILED_LIB_EXT
6542 DEPPROFILED_LIBBLKID=$PROFILED_LIBBLKID
54445dc2 6543 printf "%s\n" "#define CONFIG_BUILD_FINDFS 1" >>confdefs.h
57aa50d4 6544
54445dc2
TT
6545 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling private blkid library" >&5
6546printf "%s\n" "Enabling private blkid library" >&6; }
b0cacab0 6547fi
57aa50d4 6548
54445dc2 6549else $as_nop
f5dffb81 6550 if test -n "$PKG_CONFIG"; then
54445dc2
TT
6551 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for blkid_get_cache in -lblkid" >&5
6552printf %s "checking for blkid_get_cache in -lblkid... " >&6; }
6553if test ${ac_cv_lib_blkid_blkid_get_cache+y}
6554then :
6555 printf %s "(cached) " >&6
6556else $as_nop
f5dffb81
TT
6557 ac_check_lib_save_LIBS=$LIBS
6558LIBS="-lblkid $LIBS"
6559cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6560/* end confdefs.h. */
6561
6562/* Override any GCC internal prototype to avoid an error.
6563 Use char because int might match the return type of a GCC
6564 builtin and then its argument prototype would still apply. */
f5dffb81
TT
6565char blkid_get_cache ();
6566int
54445dc2 6567main (void)
f5dffb81
TT
6568{
6569return blkid_get_cache ();
6570 ;
6571 return 0;
6572}
6573_ACEOF
54445dc2
TT
6574if ac_fn_c_try_link "$LINENO"
6575then :
f5dffb81 6576 ac_cv_lib_blkid_blkid_get_cache=yes
54445dc2 6577else $as_nop
f5dffb81
TT
6578 ac_cv_lib_blkid_blkid_get_cache=no
6579fi
54445dc2 6580rm -f core conftest.err conftest.$ac_objext conftest.beam \
f5dffb81
TT
6581 conftest$ac_exeext conftest.$ac_ext
6582LIBS=$ac_check_lib_save_LIBS
6583fi
54445dc2
TT
6584{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_blkid_blkid_get_cache" >&5
6585printf "%s\n" "$ac_cv_lib_blkid_blkid_get_cache" >&6; }
6586if test "x$ac_cv_lib_blkid_blkid_get_cache" = xyes
6587then :
f5dffb81
TT
6588 LIBBLKID=`$PKG_CONFIG --libs blkid`;
6589 STATIC_LIBBLKID=`$PKG_CONFIG --static --libs blkid`
6590fi
6591
6592fi
6593if test -n "$LIBBLKID"; then
6594 BLKID_CMT=#
6595 PROFILED_LIBBLKID=$LIBBLKID
54445dc2
TT
6596 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Using system blkid library by default" >&5
6597printf "%s\n" "Using system blkid library by default" >&6; }
f5dffb81
TT
6598else
6599 LIBBLKID='$(LIB)/libblkid'$LIB_EXT
6600 DEPLIBBLKID=$LIBBLKID
6601 STATIC_LIBBLKID='$(LIB)/libblkid'$STATIC_LIB_EXT
6602 DEPSTATIC_LIBBLKID=$STATIC_LIBBLKID
6603 PROFILED_LIBBLKID='$(LIB)/libblkid'$PROFILED_LIB_EXT
6604 DEPPROFILED_LIBBLKID=$PROFILED_LIBBLKID
54445dc2 6605 printf "%s\n" "#define CONFIG_BUILD_FINDFS 1" >>confdefs.h
57aa50d4 6606
54445dc2
TT
6607 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling private blkid library by default" >&5
6608printf "%s\n" "Enabling private blkid library by default" >&6; }
f5dffb81 6609fi
57aa50d4 6610
a64c9c13 6611fi
07a0db15 6612
a64c9c13 6613
b0cacab0 6614
b0cacab0 6615
a64c9c13 6616
b0cacab0 6617
07a0db15 6618
57aa50d4 6619
0afb9be6 6620ALL_CMT=
feb235e0 6621SUBSET_CMT=
0afb9be6 6622# Check whether --enable-subset was given.
54445dc2
TT
6623if test ${enable_subset+y}
6624then :
0afb9be6
TT
6625 enableval=$enable_subset; if test "$enableval" = "no"
6626then
feb235e0 6627 SUBSET_CMT=#
54445dc2
TT
6628 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling subset-only build" >&5
6629printf "%s\n" "Disabling subset-only build" >&6; }
0afb9be6
TT
6630else
6631 ALL_CMT=#
54445dc2
TT
6632 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling subset-only-build" >&5
6633printf "%s\n" "Enabling subset-only-build" >&6; }
0afb9be6
TT
6634fi
6635
6636fi
6637
6638
3df6014a 6639
feb235e0 6640
3df6014a 6641# Check whether --enable-backtrace was given.
54445dc2
TT
6642if test ${enable_backtrace+y}
6643then :
3df6014a
TT
6644 enableval=$enable_backtrace; if test "$enableval" = "no"
6645then
54445dc2
TT
6646 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling use of backtrace" >&5
6647printf "%s\n" "Disabling use of backtrace" >&6; }
6648 printf "%s\n" "#define DISABLE_BACKTRACE 1" >>confdefs.h
3df6014a
TT
6649
6650else
54445dc2
TT
6651 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling use of backtrace" >&5
6652printf "%s\n" "Enabling use of backtrace" >&6; }
3df6014a
TT
6653fi
6654
54445dc2
TT
6655else $as_nop
6656 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling use of backtrace by default" >&5
6657printf "%s\n" "Enabling use of backtrace by default" >&6; }
3df6014a
TT
6658
6659fi
6660
57aa50d4 6661# Check whether --enable-debugfs was given.
54445dc2
TT
6662if test ${enable_debugfs+y}
6663then :
57aa50d4
TT
6664 enableval=$enable_debugfs; if test "$enableval" = "no"
6665then
54445dc2
TT
6666 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling debugfs support" >&5
6667printf "%s\n" "Disabling debugfs support" >&6; }
57aa50d4 6668 DEBUGFS_CMT="#"
b0cacab0 6669else
57aa50d4 6670 DEBUGFS_CMT=
54445dc2
TT
6671 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling debugfs support" >&5
6672printf "%s\n" "Enabling debugfs support" >&6; }
b0cacab0 6673fi
a64c9c13 6674
54445dc2
TT
6675else $as_nop
6676 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling debugfs support by default" >&5
6677printf "%s\n" "Enabling debugfs support by default" >&6; }
57aa50d4 6678DEBUGFS_CMT=
a64c9c13 6679
93636bde 6680fi
57aa50d4
TT
6681
6682
6683# Check whether --enable-imager was given.
54445dc2
TT
6684if test ${enable_imager+y}
6685then :
57aa50d4
TT
6686 enableval=$enable_imager; if test "$enableval" = "no"
6687then
54445dc2
TT
6688 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling e2image support" >&5
6689printf "%s\n" "Disabling e2image support" >&6; }
57aa50d4 6690 IMAGER_CMT="#"
b0cacab0 6691else
57aa50d4 6692 IMAGER_CMT=
54445dc2
TT
6693 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling e2image support" >&5
6694printf "%s\n" "Enabling e2image support" >&6; }
b0cacab0
TT
6695fi
6696
54445dc2
TT
6697else $as_nop
6698 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling e2image support by default" >&5
6699printf "%s\n" "Enabling e2image support by default" >&6; }
57aa50d4
TT
6700IMAGER_CMT=
6701
93636bde
TT
6702fi
6703
a64c9c13 6704
57aa50d4 6705# Check whether --enable-resizer was given.
54445dc2
TT
6706if test ${enable_resizer+y}
6707then :
57aa50d4
TT
6708 enableval=$enable_resizer; if test "$enableval" = "no"
6709then
54445dc2
TT
6710 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling e2resize support" >&5
6711printf "%s\n" "Disabling e2resize support" >&6; }
57aa50d4 6712 RESIZER_CMT="#"
b0cacab0 6713else
57aa50d4 6714 RESIZER_CMT=
54445dc2
TT
6715 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling e2resize support" >&5
6716printf "%s\n" "Enabling e2resize support" >&6; }
57aa50d4 6717fi
b0cacab0 6718
54445dc2
TT
6719else $as_nop
6720 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling e2resize support by default" >&5
6721printf "%s\n" "Enabling e2resize support by default" >&6; }
57aa50d4 6722RESIZER_CMT=
b0cacab0 6723
b0cacab0 6724fi
e1052144 6725
57aa50d4 6726
8d9c50c5 6727# Check whether --enable-defrag was given.
54445dc2
TT
6728if test ${enable_defrag+y}
6729then :
8d9c50c5
TT
6730 enableval=$enable_defrag; if test "$enableval" = "no"
6731then
54445dc2
TT
6732 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling e4defrag support" >&5
6733printf "%s\n" "Disabling e4defrag support" >&6; }
8d9c50c5
TT
6734 DEFRAG_CMT="#"
6735else
6736 DEFRAG_CMT=
54445dc2
TT
6737 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling e4defrag support" >&5
6738printf "%s\n" "Enabling e4defrag support" >&6; }
8d9c50c5
TT
6739fi
6740
54445dc2 6741else $as_nop
6c59a665
TT
6742 if test -z "$WITH_DIET_LIBC"
6743then
54445dc2
TT
6744 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling e4defrag support by default" >&5
6745printf "%s\n" "Enabling e4defrag support by default" >&6; }
6c59a665
TT
6746 DEFRAG_CMT=
6747else
54445dc2
TT
6748 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling e4defrag support by default" >&5
6749printf "%s\n" "Disabling e4defrag support by default" >&6; }
6c59a665
TT
6750 DEFRAG_CMT="#"
6751fi
8d9c50c5
TT
6752
6753fi
6754
6755
57aa50d4 6756# Check whether --enable-fsck was given.
54445dc2
TT
6757if test ${enable_fsck+y}
6758then :
57aa50d4
TT
6759 enableval=$enable_fsck; if test "$enableval" = "no"
6760then
6761 FSCK_PROG='' FSCK_MAN=''
54445dc2
TT
6762 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Not building fsck wrapper" >&5
6763printf "%s\n" "Not building fsck wrapper" >&6; }
57aa50d4
TT
6764else
6765 FSCK_PROG=fsck FSCK_MAN=fsck.8
54445dc2
TT
6766 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Building fsck wrapper" >&5
6767printf "%s\n" "Building fsck wrapper" >&6; }
a64c9c13
TT
6768fi
6769
54445dc2 6770else $as_nop
57aa50d4
TT
6771 case "$host_os" in
6772 gnu*)
6773 FSCK_PROG='' FSCK_MAN=''
54445dc2
TT
6774 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Not building fsck wrapper by default" >&5
6775printf "%s\n" "Not building fsck wrapper by default" >&6; }
57aa50d4
TT
6776 ;;
6777 *)
6778 FSCK_PROG=fsck FSCK_MAN=fsck.8
54445dc2
TT
6779 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Building fsck wrapper by default" >&5
6780printf "%s\n" "Building fsck wrapper by default" >&6; }
57aa50d4 6781esac
b0cacab0 6782
57aa50d4 6783fi
b0cacab0 6784
93636bde 6785
b0cacab0 6786
57aa50d4 6787# Check whether --enable-e2initrd-helper was given.
54445dc2
TT
6788if test ${enable_e2initrd_helper+y}
6789then :
57aa50d4
TT
6790 enableval=$enable_e2initrd_helper; if test "$enableval" = "no"
6791then
6792 E2INITRD_PROG='' E2INITRD_MAN=''
54445dc2
TT
6793 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Not building e2initrd helper" >&5
6794printf "%s\n" "Not building e2initrd helper" >&6; }
57aa50d4
TT
6795else
6796 E2INITRD_PROG=e2initrd_helper E2INITRD_MAN=e2initrd_helper.8
54445dc2
TT
6797 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Building e2initrd helper" >&5
6798printf "%s\n" "Building e2initrd helper" >&6; }
57aa50d4 6799fi
a64c9c13 6800
54445dc2 6801else $as_nop
57aa50d4 6802 E2INITRD_PROG=e2initrd_helper E2INITRD_MAN=e2initrd_helper.8
54445dc2
TT
6803{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Building e2initrd helper by default" >&5
6804printf "%s\n" "Building e2initrd helper by default" >&6; }
b0cacab0 6805
a64c9c13 6806fi
e1052144 6807
57aa50d4
TT
6808
6809
6810# Check whether --enable-tls was given.
54445dc2
TT
6811if test ${enable_tls+y}
6812then :
57aa50d4
TT
6813 enableval=$enable_tls; if test "$enableval" = "no"
6814then
6815 try_tls=""
54445dc2
TT
6816 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling thread local support" >&5
6817printf "%s\n" "Disabling thread local support" >&6; }
57aa50d4
TT
6818else
6819 try_tls="yes"
54445dc2
TT
6820 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling thread local support" >&5
6821printf "%s\n" "Enabling thread local support" >&6; }
a64c9c13
TT
6822fi
6823
54445dc2 6824else $as_nop
57aa50d4
TT
6825 if test -n "$WITH_DIET_LIBC"
6826then
6827 try_tls=""
54445dc2
TT
6828 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Diet libc does not support thread local support" >&5
6829printf "%s\n" "Diet libc does not support thread local support" >&6; }
57aa50d4
TT
6830else
6831 try_tls="yes"
54445dc2
TT
6832 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Try using thread local support by default" >&5
6833printf "%s\n" "Try using thread local support by default" >&6; }
57aa50d4 6834fi
a64c9c13 6835
93636bde 6836fi
07a0db15 6837
57aa50d4
TT
6838if test "$try_tls" = "yes"
6839then
a64c9c13 6840
54445dc2
TT
6841 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for thread local storage (TLS) class" >&5
6842printf %s "checking for thread local storage (TLS) class... " >&6; }
6843 if test ${ac_cv_tls+y}
6844then :
6845 printf %s "(cached) " >&6
6846else $as_nop
b0cacab0 6847
57aa50d4
TT
6848 ax_tls_keywords="__thread __declspec(thread) none"
6849 for ax_tls_keyword in $ax_tls_keywords; do
6850 case $ax_tls_keyword in
6851 none) ac_cv_tls=none ; break ;;
6852 *)
6853 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6854/* end confdefs.h. */
6855#include <stdlib.h>
6856 static void
6857 foo(void) {
6858 static $ax_tls_keyword int bar;
6859 exit(1);
6860 }
b0cacab0 6861int
54445dc2 6862main (void)
b0cacab0 6863{
57aa50d4 6864
b0cacab0
TT
6865 ;
6866 return 0;
6867}
6868_ACEOF
54445dc2
TT
6869if ac_fn_c_try_compile "$LINENO"
6870then :
57aa50d4 6871 ac_cv_tls=$ax_tls_keyword ; break
54445dc2 6872else $as_nop
57aa50d4 6873 ac_cv_tls=none
b0cacab0 6874
b0cacab0 6875fi
54445dc2 6876rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
57aa50d4
TT
6877 esac
6878 done
6879
b0cacab0 6880fi
b0cacab0 6881
57aa50d4
TT
6882
6883 if test "$ac_cv_tls" != "none"; then
6884
54445dc2 6885printf "%s\n" "#define TLS $ac_cv_tls" >>confdefs.h
93636bde 6886
b0cacab0 6887 fi
54445dc2
TT
6888 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_tls" >&5
6889printf "%s\n" "$ac_cv_tls" >&6; }
b0cacab0 6890
57aa50d4 6891fi
d1154eb4 6892
bdcd5f22 6893# Check whether --with-pthread was given.
54445dc2
TT
6894if test ${with_pthread+y}
6895then :
bdcd5f22 6896 withval=$with_pthread; if test "$withval" = "no"
57aa50d4 6897then
bdcd5f22 6898 try_pthread=""
54445dc2
TT
6899 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling pthread support" >&5
6900printf "%s\n" "Disabling pthread support" >&6; }
a64c9c13 6901else
bdcd5f22 6902 try_pthread="yes"
54445dc2
TT
6903 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Testing for pthread support" >&5
6904printf "%s\n" "Testing for pthread support" >&6; }
57aa50d4 6905fi
a64c9c13 6906
54445dc2 6907else $as_nop
bdcd5f22 6908 try_pthread="yes"
54445dc2
TT
6909{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Try testing for pthread support by default" >&5
6910printf "%s\n" "Try testing for pthread support by default" >&6; }
a64c9c13 6911
bdcd5f22
TT
6912fi
6913
6914if test "$try_pthread" = "yes"
e3d10158 6915then
54445dc2
TT
6916{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
6917printf %s "checking for a sed that does not truncate output... " >&6; }
6918if test ${ac_cv_path_SED+y}
6919then :
6920 printf %s "(cached) " >&6
6921else $as_nop
bdcd5f22
TT
6922 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
6923 for ac_i in 1 2 3 4 5 6 7; do
6924 ac_script="$ac_script$as_nl$ac_script"
6925 done
6926 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
6927 { ac_script=; unset ac_script;}
6928 if test -z "$SED"; then
6929 ac_path_SED_found=false
6930 # Loop through the user's path and test for each of PROGNAME-LIST
6931 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
54445dc2
TT
6932for as_dir in $PATH
6933do
6934 IFS=$as_save_IFS
6935 case $as_dir in #(((
6936 '') as_dir=./ ;;
6937 */) ;;
6938 *) as_dir=$as_dir/ ;;
6939 esac
6940 for ac_prog in sed gsed
6941 do
6942 for ac_exec_ext in '' $ac_executable_extensions; do
6943 ac_path_SED="$as_dir$ac_prog$ac_exec_ext"
6944 as_fn_executable_p "$ac_path_SED" || continue
6945# Check for GNU ac_path_SED and select it if it is found.
6946 # Check for GNU $ac_path_SED
6947case `"$ac_path_SED" --version 2>&1` in
6948*GNU*)
6949 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
6950*)
6951 ac_count=0
6952 printf %s 0123456789 >"conftest.in"
6953 while :
6954 do
6955 cat "conftest.in" "conftest.in" >"conftest.tmp"
6956 mv "conftest.tmp" "conftest.in"
6957 cp "conftest.in" "conftest.nl"
6958 printf "%s\n" '' >> "conftest.nl"
6959 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
6960 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6961 as_fn_arith $ac_count + 1 && ac_count=$as_val
6962 if test $ac_count -gt ${ac_path_SED_max-0}; then
6963 # Best one so far, save it but keep looking for a better one
6964 ac_cv_path_SED="$ac_path_SED"
6965 ac_path_SED_max=$ac_count
6966 fi
6967 # 10*(2^10) chars as input seems more than enough
6968 test $ac_count -gt 10 && break
6969 done
6970 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6971esac
6972
6973 $ac_path_SED_found && break 3
6974 done
6975 done
6976 done
6977IFS=$as_save_IFS
6978 if test -z "$ac_cv_path_SED"; then
6979 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
6980 fi
6981else
6982 ac_cv_path_SED=$SED
6983fi
6984
6985fi
6986{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
6987printf "%s\n" "$ac_cv_path_SED" >&6; }
6988 SED="$ac_cv_path_SED"
6989 rm -f conftest.sed
6990
6991
6992{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
6993printf %s "checking for grep that handles long lines and -e... " >&6; }
6994if test ${ac_cv_path_GREP+y}
6995then :
6996 printf %s "(cached) " >&6
6997else $as_nop
6998 if test -z "$GREP"; then
6999 ac_path_GREP_found=false
7000 # Loop through the user's path and test for each of PROGNAME-LIST
7001 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7002for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
7003do
7004 IFS=$as_save_IFS
7005 case $as_dir in #(((
7006 '') as_dir=./ ;;
7007 */) ;;
7008 *) as_dir=$as_dir/ ;;
7009 esac
7010 for ac_prog in grep ggrep
7011 do
7012 for ac_exec_ext in '' $ac_executable_extensions; do
7013 ac_path_GREP="$as_dir$ac_prog$ac_exec_ext"
7014 as_fn_executable_p "$ac_path_GREP" || continue
7015# Check for GNU ac_path_GREP and select it if it is found.
7016 # Check for GNU $ac_path_GREP
7017case `"$ac_path_GREP" --version 2>&1` in
7018*GNU*)
7019 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
7020*)
7021 ac_count=0
7022 printf %s 0123456789 >"conftest.in"
7023 while :
7024 do
7025 cat "conftest.in" "conftest.in" >"conftest.tmp"
7026 mv "conftest.tmp" "conftest.in"
7027 cp "conftest.in" "conftest.nl"
7028 printf "%s\n" 'GREP' >> "conftest.nl"
7029 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
7030 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7031 as_fn_arith $ac_count + 1 && ac_count=$as_val
7032 if test $ac_count -gt ${ac_path_GREP_max-0}; then
7033 # Best one so far, save it but keep looking for a better one
7034 ac_cv_path_GREP="$ac_path_GREP"
7035 ac_path_GREP_max=$ac_count
7036 fi
7037 # 10*(2^10) chars as input seems more than enough
7038 test $ac_count -gt 10 && break
7039 done
7040 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7041esac
7042
7043 $ac_path_GREP_found && break 3
7044 done
7045 done
7046 done
7047IFS=$as_save_IFS
7048 if test -z "$ac_cv_path_GREP"; then
7049 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
7050 fi
7051else
7052 ac_cv_path_GREP=$GREP
7053fi
7054
7055fi
7056{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
7057printf "%s\n" "$ac_cv_path_GREP" >&6; }
7058 GREP="$ac_cv_path_GREP"
7059
7060
7061{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
7062printf %s "checking for egrep... " >&6; }
7063if test ${ac_cv_path_EGREP+y}
7064then :
7065 printf %s "(cached) " >&6
7066else $as_nop
7067 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
7068 then ac_cv_path_EGREP="$GREP -E"
7069 else
7070 if test -z "$EGREP"; then
7071 ac_path_EGREP_found=false
7072 # Loop through the user's path and test for each of PROGNAME-LIST
7073 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7074for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
bdcd5f22
TT
7075do
7076 IFS=$as_save_IFS
54445dc2
TT
7077 case $as_dir in #(((
7078 '') as_dir=./ ;;
7079 */) ;;
7080 *) as_dir=$as_dir/ ;;
7081 esac
7082 for ac_prog in egrep
7083 do
bdcd5f22 7084 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
7085 ac_path_EGREP="$as_dir$ac_prog$ac_exec_ext"
7086 as_fn_executable_p "$ac_path_EGREP" || continue
7087# Check for GNU ac_path_EGREP and select it if it is found.
7088 # Check for GNU $ac_path_EGREP
7089case `"$ac_path_EGREP" --version 2>&1` in
bdcd5f22 7090*GNU*)
54445dc2 7091 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
bdcd5f22
TT
7092*)
7093 ac_count=0
54445dc2 7094 printf %s 0123456789 >"conftest.in"
bdcd5f22
TT
7095 while :
7096 do
7097 cat "conftest.in" "conftest.in" >"conftest.tmp"
7098 mv "conftest.tmp" "conftest.in"
7099 cp "conftest.in" "conftest.nl"
54445dc2
TT
7100 printf "%s\n" 'EGREP' >> "conftest.nl"
7101 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
bdcd5f22
TT
7102 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7103 as_fn_arith $ac_count + 1 && ac_count=$as_val
54445dc2 7104 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
bdcd5f22 7105 # Best one so far, save it but keep looking for a better one
54445dc2
TT
7106 ac_cv_path_EGREP="$ac_path_EGREP"
7107 ac_path_EGREP_max=$ac_count
bdcd5f22
TT
7108 fi
7109 # 10*(2^10) chars as input seems more than enough
7110 test $ac_count -gt 10 && break
7111 done
7112 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7113esac
7114
54445dc2 7115 $ac_path_EGREP_found && break 3
bdcd5f22
TT
7116 done
7117 done
7118 done
7119IFS=$as_save_IFS
54445dc2
TT
7120 if test -z "$ac_cv_path_EGREP"; then
7121 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
bdcd5f22
TT
7122 fi
7123else
54445dc2 7124 ac_cv_path_EGREP=$EGREP
e3d10158 7125fi
e1052144 7126
54445dc2 7127 fi
a64c9c13 7128fi
54445dc2
TT
7129{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
7130printf "%s\n" "$ac_cv_path_EGREP" >&6; }
7131 EGREP="$ac_cv_path_EGREP"
7132
e1052144 7133
93636bde 7134
d6a4bcb5 7135
d6a4bcb5 7136
d6a4bcb5 7137
bdcd5f22
TT
7138ac_ext=c
7139ac_cpp='$CPP $CPPFLAGS'
7140ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7141ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7142ac_compiler_gnu=$ac_cv_c_compiler_gnu
d6a4bcb5 7143
bdcd5f22
TT
7144ax_pthread_ok=no
7145
7146# We used to check for pthread.h first, but this fails if pthread.h
7147# requires special compiler flags (e.g. on Tru64 or Sequent).
7148# It gets checked for in the link test anyway.
7149
7150# First of all, check if the user has set any of the PTHREAD_LIBS,
7151# etcetera environment variables, and if threads linking works using
7152# them:
7153if test "x$PTHREAD_CFLAGS$PTHREAD_LIBS" != "x"; then
7154 ax_pthread_save_CC="$CC"
7155 ax_pthread_save_CFLAGS="$CFLAGS"
7156 ax_pthread_save_LIBS="$LIBS"
54445dc2
TT
7157 if test "x$PTHREAD_CC" != "x"
7158then :
bdcd5f22 7159 CC="$PTHREAD_CC"
54445dc2
TT
7160fi
7161 if test "x$PTHREAD_CXX" != "x"
7162then :
7163 CXX="$PTHREAD_CXX"
bdcd5f22
TT
7164fi
7165 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
7166 LIBS="$PTHREAD_LIBS $LIBS"
54445dc2
TT
7167 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS" >&5
7168printf %s "checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS... " >&6; }
bdcd5f22
TT
7169 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7170/* end confdefs.h. */
d6a4bcb5 7171
bdcd5f22
TT
7172/* Override any GCC internal prototype to avoid an error.
7173 Use char because int might match the return type of a GCC
7174 builtin and then its argument prototype would still apply. */
bdcd5f22
TT
7175char pthread_join ();
7176int
54445dc2 7177main (void)
bdcd5f22
TT
7178{
7179return pthread_join ();
7180 ;
7181 return 0;
7182}
7183_ACEOF
54445dc2
TT
7184if ac_fn_c_try_link "$LINENO"
7185then :
bdcd5f22 7186 ax_pthread_ok=yes
1625bf42 7187fi
54445dc2 7188rm -f core conftest.err conftest.$ac_objext conftest.beam \
bdcd5f22 7189 conftest$ac_exeext conftest.$ac_ext
54445dc2
TT
7190 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
7191printf "%s\n" "$ax_pthread_ok" >&6; }
bdcd5f22
TT
7192 if test "x$ax_pthread_ok" = "xno"; then
7193 PTHREAD_LIBS=""
7194 PTHREAD_CFLAGS=""
7195 fi
7196 CC="$ax_pthread_save_CC"
7197 CFLAGS="$ax_pthread_save_CFLAGS"
7198 LIBS="$ax_pthread_save_LIBS"
7199fi
7200
7201# We must check for the threads library under a number of different
7202# names; the ordering is very important because some systems
7203# (e.g. DEC) have both -lpthread and -lpthreads, where one of the
7204# libraries is broken (non-POSIX).
7205
54445dc2
TT
7206# Create a list of thread flags to try. Items with a "," contain both
7207# C compiler flags (before ",") and linker flags (after ","). Other items
7208# starting with a "-" are C compiler flags, and remaining items are
7209# library names, except for "none" which indicates that we try without
7210# any flags at all, and "pthread-config" which is a program returning
7211# the flags for the Pth emulation library.
bdcd5f22
TT
7212
7213ax_pthread_flags="pthreads none -Kthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
7214
7215# The ordering *is* (sometimes) important. Some notes on the
7216# individual items follow:
7217
7218# pthreads: AIX (must check this before -lpthread)
7219# none: in case threads are in libc; should be tried before -Kthread and
7220# other compiler flags to prevent continual compiler warnings
7221# -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
7222# -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads), Tru64
7223# (Note: HP C rejects this with "bad form for `-t' option")
7224# -pthreads: Solaris/gcc (Note: HP C also rejects)
7225# -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
7226# doesn't hurt to check since this sometimes defines pthreads and
7227# -D_REENTRANT too), HP C (must be checked before -lpthread, which
7228# is present but should not be used directly; and before -mthreads,
7229# because the compiler interprets this as "-mt" + "-hreads")
7230# -mthreads: Mingw32/gcc, Lynx/gcc
7231# pthread: Linux, etcetera
7232# --thread-safe: KAI C++
7233# pthread-config: use pthread-config program (for GNU Pth library)
7234
7235case $host_os in
7236
7237 freebsd*)
7238
7239 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
7240 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
7241
7242 ax_pthread_flags="-kthread lthread $ax_pthread_flags"
7243 ;;
1625bf42 7244
bdcd5f22 7245 hpux*)
1625bf42 7246
bdcd5f22
TT
7247 # From the cc(1) man page: "[-mt] Sets various -D flags to enable
7248 # multi-threading and also sets -lpthread."
749f0712 7249
bdcd5f22
TT
7250 ax_pthread_flags="-mt -pthread pthread $ax_pthread_flags"
7251 ;;
749f0712 7252
bdcd5f22 7253 openedition*)
749f0712 7254
bdcd5f22
TT
7255 # IBM z/OS requires a feature-test macro to be defined in order to
7256 # enable POSIX threads at all, so give the user a hint if this is
7257 # not set. (We don't define these ourselves, as they can affect
7258 # other portions of the system API in unpredictable ways.)
749f0712 7259
bdcd5f22
TT
7260 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7261/* end confdefs.h. */
7262
7263# if !defined(_OPEN_THREADS) && !defined(_UNIX03_THREADS)
7264 AX_PTHREAD_ZOS_MISSING
7265# endif
7266
7267_ACEOF
7268if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
54445dc2
TT
7269 $EGREP "AX_PTHREAD_ZOS_MISSING" >/dev/null 2>&1
7270then :
7271 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&5
7272printf "%s\n" "$as_me: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&2;}
749f0712 7273fi
54445dc2 7274rm -rf conftest*
749f0712 7275
bdcd5f22 7276 ;;
749f0712 7277
bdcd5f22 7278 solaris*)
749f0712 7279
bdcd5f22
TT
7280 # On Solaris (at least, for some versions), libc contains stubbed
7281 # (non-functional) versions of the pthreads routines, so link-based
7282 # tests will erroneously succeed. (N.B.: The stubs are missing
7283 # pthread_cleanup_push, or rather a function called by this macro,
7284 # so we could check for that, but who knows whether they'll stub
7285 # that too in a future libc.) So we'll check first for the
7286 # standard Solaris way of linking pthreads (-mt -lpthread).
749f0712 7287
54445dc2 7288 ax_pthread_flags="-mt,-lpthread pthread $ax_pthread_flags"
bdcd5f22
TT
7289 ;;
7290esac
1625bf42 7291
bdcd5f22 7292# Are we compiling with Clang?
1625bf42 7293
54445dc2
TT
7294{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC is Clang" >&5
7295printf %s "checking whether $CC is Clang... " >&6; }
7296if test ${ax_cv_PTHREAD_CLANG+y}
7297then :
7298 printf %s "(cached) " >&6
7299else $as_nop
bdcd5f22
TT
7300 ax_cv_PTHREAD_CLANG=no
7301 # Note that Autoconf sets GCC=yes for Clang as well as GCC
7302 if test "x$GCC" = "xyes"; then
7303 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7304/* end confdefs.h. */
7305/* Note: Clang 2.7 lacks __clang_[a-z]+__ */
7306# if defined(__clang__) && defined(__llvm__)
7307 AX_PTHREAD_CC_IS_CLANG
7308# endif
7309
7310_ACEOF
7311if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
54445dc2
TT
7312 $EGREP "AX_PTHREAD_CC_IS_CLANG" >/dev/null 2>&1
7313then :
bdcd5f22 7314 ax_cv_PTHREAD_CLANG=yes
1625bf42 7315fi
54445dc2 7316rm -rf conftest*
1625bf42 7317
bdcd5f22 7318 fi
1625bf42
TB
7319
7320fi
54445dc2
TT
7321{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG" >&5
7322printf "%s\n" "$ax_cv_PTHREAD_CLANG" >&6; }
bdcd5f22
TT
7323ax_pthread_clang="$ax_cv_PTHREAD_CLANG"
7324
bdcd5f22 7325
54445dc2 7326# GCC generally uses -pthread, or -pthreads on some platforms (e.g. SPARC)
bdcd5f22 7327
54445dc2
TT
7328# Note that for GCC and Clang -pthread generally implies -lpthread,
7329# except when -nostdlib is passed.
7330# This is problematic using libtool to build C++ shared libraries with pthread:
7331# [1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=25460
7332# [2] https://bugzilla.redhat.com/show_bug.cgi?id=661333
7333# [3] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=468555
7334# To solve this, first try -pthread together with -lpthread for GCC
bdcd5f22 7335
54445dc2
TT
7336if test "x$GCC" = "xyes"
7337then :
7338 ax_pthread_flags="-pthread,-lpthread -pthread -pthreads $ax_pthread_flags"
7339fi
bdcd5f22 7340
54445dc2 7341# Clang takes -pthread (never supported any other flag), but we'll try with -lpthread first
bdcd5f22 7342
54445dc2
TT
7343if test "x$ax_pthread_clang" = "xyes"
7344then :
7345 ax_pthread_flags="-pthread,-lpthread -pthread"
7346fi
bdcd5f22 7347
bdcd5f22 7348
54445dc2
TT
7349# The presence of a feature test macro requesting re-entrant function
7350# definitions is, on some systems, a strong hint that pthreads support is
7351# correctly enabled
bdcd5f22 7352
54445dc2
TT
7353case $host_os in
7354 darwin* | hpux* | linux* | osf* | solaris*)
7355 ax_pthread_check_macro="_REENTRANT"
7356 ;;
d6a4bcb5 7357
54445dc2
TT
7358 aix*)
7359 ax_pthread_check_macro="_THREAD_SAFE"
7360 ;;
d1154eb4 7361
54445dc2
TT
7362 *)
7363 ax_pthread_check_macro="--"
7364 ;;
7365esac
7366if test "x$ax_pthread_check_macro" = "x--"
7367then :
7368 ax_pthread_check_cond=0
7369else $as_nop
7370 ax_pthread_check_cond="!defined($ax_pthread_check_macro)"
bdcd5f22 7371fi
d1154eb4 7372
57aa50d4 7373
bdcd5f22
TT
7374if test "x$ax_pthread_ok" = "xno"; then
7375for ax_pthread_try_flag in $ax_pthread_flags; do
57aa50d4 7376
bdcd5f22
TT
7377 case $ax_pthread_try_flag in
7378 none)
54445dc2
TT
7379 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
7380printf %s "checking whether pthreads work without any flags... " >&6; }
bdcd5f22 7381 ;;
57aa50d4 7382
54445dc2
TT
7383 *,*)
7384 PTHREAD_CFLAGS=`echo $ax_pthread_try_flag | sed "s/^\(.*\),\(.*\)$/\1/"`
7385 PTHREAD_LIBS=`echo $ax_pthread_try_flag | sed "s/^\(.*\),\(.*\)$/\2/"`
7386 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with \"$PTHREAD_CFLAGS\" and \"$PTHREAD_LIBS\"" >&5
7387printf %s "checking whether pthreads work with \"$PTHREAD_CFLAGS\" and \"$PTHREAD_LIBS\"... " >&6; }
bdcd5f22 7388 ;;
57aa50d4 7389
bdcd5f22 7390 -*)
54445dc2
TT
7391 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $ax_pthread_try_flag" >&5
7392printf %s "checking whether pthreads work with $ax_pthread_try_flag... " >&6; }
bdcd5f22
TT
7393 PTHREAD_CFLAGS="$ax_pthread_try_flag"
7394 ;;
57aa50d4 7395
bdcd5f22
TT
7396 pthread-config)
7397 # Extract the first word of "pthread-config", so it can be a program name with args.
7398set dummy pthread-config; ac_word=$2
54445dc2
TT
7399{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7400printf %s "checking for $ac_word... " >&6; }
7401if test ${ac_cv_prog_ax_pthread_config+y}
7402then :
7403 printf %s "(cached) " >&6
7404else $as_nop
bdcd5f22
TT
7405 if test -n "$ax_pthread_config"; then
7406 ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test.
7407else
7408as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7409for as_dir in $PATH
7410do
7411 IFS=$as_save_IFS
54445dc2
TT
7412 case $as_dir in #(((
7413 '') as_dir=./ ;;
7414 */) ;;
7415 *) as_dir=$as_dir/ ;;
7416 esac
bdcd5f22 7417 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 7418 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
bdcd5f22 7419 ac_cv_prog_ax_pthread_config="yes"
54445dc2 7420 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
bdcd5f22
TT
7421 break 2
7422 fi
7423done
7424 done
7425IFS=$as_save_IFS
7426
7427 test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no"
7428fi
7429fi
7430ax_pthread_config=$ac_cv_prog_ax_pthread_config
7431if test -n "$ax_pthread_config"; then
54445dc2
TT
7432 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5
7433printf "%s\n" "$ax_pthread_config" >&6; }
bdcd5f22 7434else
54445dc2
TT
7435 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7436printf "%s\n" "no" >&6; }
bdcd5f22
TT
7437fi
7438
7439
54445dc2
TT
7440 if test "x$ax_pthread_config" = "xno"
7441then :
bdcd5f22
TT
7442 continue
7443fi
7444 PTHREAD_CFLAGS="`pthread-config --cflags`"
7445 PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
7446 ;;
7447
7448 *)
54445dc2
TT
7449 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$ax_pthread_try_flag" >&5
7450printf %s "checking for the pthreads library -l$ax_pthread_try_flag... " >&6; }
bdcd5f22
TT
7451 PTHREAD_LIBS="-l$ax_pthread_try_flag"
7452 ;;
7453 esac
7454
7455 ax_pthread_save_CFLAGS="$CFLAGS"
7456 ax_pthread_save_LIBS="$LIBS"
7457 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
7458 LIBS="$PTHREAD_LIBS $LIBS"
7459
7460 # Check for various functions. We must include pthread.h,
7461 # since some functions may be macros. (On the Sequent, we
7462 # need a special flag -Kthread to make this header compile.)
7463 # We check for pthread_join because it is in -lpthread on IRIX
7464 # while pthread_create is in libc. We check for pthread_attr_init
7465 # due to DEC craziness with -lpthreads. We check for
7466 # pthread_cleanup_push because it is one of the few pthread
7467 # functions on Solaris that doesn't have a non-functional libc stub.
7468 # We try pthread_create on general principles.
7469
7470 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7471/* end confdefs.h. */
7472#include <pthread.h>
7473# if $ax_pthread_check_cond
7474# error "$ax_pthread_check_macro must be defined"
7475# endif
54445dc2
TT
7476 static void *some_global = NULL;
7477 static void routine(void *a)
7478 {
7479 /* To avoid any unused-parameter or
7480 unused-but-set-parameter warning. */
7481 some_global = a;
7482 }
bdcd5f22
TT
7483 static void *start_routine(void *a) { return a; }
7484int
54445dc2 7485main (void)
bdcd5f22
TT
7486{
7487pthread_t th; pthread_attr_t attr;
7488 pthread_create(&th, 0, start_routine, 0);
7489 pthread_join(th, 0);
7490 pthread_attr_init(&attr);
7491 pthread_cleanup_push(routine, 0);
7492 pthread_cleanup_pop(0) /* ; */
7493 ;
7494 return 0;
7495}
7496_ACEOF
54445dc2
TT
7497if ac_fn_c_try_link "$LINENO"
7498then :
bdcd5f22
TT
7499 ax_pthread_ok=yes
7500fi
54445dc2 7501rm -f core conftest.err conftest.$ac_objext conftest.beam \
bdcd5f22
TT
7502 conftest$ac_exeext conftest.$ac_ext
7503
7504 CFLAGS="$ax_pthread_save_CFLAGS"
7505 LIBS="$ax_pthread_save_LIBS"
7506
54445dc2
TT
7507 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
7508printf "%s\n" "$ax_pthread_ok" >&6; }
7509 if test "x$ax_pthread_ok" = "xyes"
7510then :
bdcd5f22
TT
7511 break
7512fi
7513
7514 PTHREAD_LIBS=""
7515 PTHREAD_CFLAGS=""
7516done
7517fi
7518
54445dc2
TT
7519
7520# Clang needs special handling, because older versions handle the -pthread
7521# option in a rather... idiosyncratic way
7522
7523if test "x$ax_pthread_clang" = "xyes"; then
7524
7525 # Clang takes -pthread; it has never supported any other flag
7526
7527 # (Note 1: This will need to be revisited if a system that Clang
7528 # supports has POSIX threads in a separate library. This tends not
7529 # to be the way of modern systems, but it's conceivable.)
7530
7531 # (Note 2: On some systems, notably Darwin, -pthread is not needed
7532 # to get POSIX threads support; the API is always present and
7533 # active. We could reasonably leave PTHREAD_CFLAGS empty. But
7534 # -pthread does define _REENTRANT, and while the Darwin headers
7535 # ignore this macro, third-party headers might not.)
7536
7537 # However, older versions of Clang make a point of warning the user
7538 # that, in an invocation where only linking and no compilation is
7539 # taking place, the -pthread option has no effect ("argument unused
7540 # during compilation"). They expect -pthread to be passed in only
7541 # when source code is being compiled.
7542 #
7543 # Problem is, this is at odds with the way Automake and most other
7544 # C build frameworks function, which is that the same flags used in
7545 # compilation (CFLAGS) are also used in linking. Many systems
7546 # supported by AX_PTHREAD require exactly this for POSIX threads
7547 # support, and in fact it is often not straightforward to specify a
7548 # flag that is used only in the compilation phase and not in
7549 # linking. Such a scenario is extremely rare in practice.
7550 #
7551 # Even though use of the -pthread flag in linking would only print
7552 # a warning, this can be a nuisance for well-run software projects
7553 # that build with -Werror. So if the active version of Clang has
7554 # this misfeature, we search for an option to squash it.
7555
7556 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread" >&5
7557printf %s "checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread... " >&6; }
7558if test ${ax_cv_PTHREAD_CLANG_NO_WARN_FLAG+y}
7559then :
7560 printf %s "(cached) " >&6
7561else $as_nop
7562 ax_cv_PTHREAD_CLANG_NO_WARN_FLAG=unknown
7563 # Create an alternate version of $ac_link that compiles and
7564 # links in two steps (.c -> .o, .o -> exe) instead of one
7565 # (.c -> exe), because the warning occurs only in the second
7566 # step
7567 ax_pthread_save_ac_link="$ac_link"
7568 ax_pthread_sed='s/conftest\.\$ac_ext/conftest.$ac_objext/g'
7569 ax_pthread_link_step=`printf "%s\n" "$ac_link" | sed "$ax_pthread_sed"`
7570 ax_pthread_2step_ac_link="($ac_compile) && (echo ==== >&5) && ($ax_pthread_link_step)"
7571 ax_pthread_save_CFLAGS="$CFLAGS"
7572 for ax_pthread_try in '' -Qunused-arguments -Wno-unused-command-line-argument unknown; do
7573 if test "x$ax_pthread_try" = "xunknown"
7574then :
7575 break
7576fi
7577 CFLAGS="-Werror -Wunknown-warning-option $ax_pthread_try -pthread $ax_pthread_save_CFLAGS"
7578 ac_link="$ax_pthread_save_ac_link"
7579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7580/* end confdefs.h. */
7581int main(void){return 0;}
7582_ACEOF
7583if ac_fn_c_try_link "$LINENO"
7584then :
7585 ac_link="$ax_pthread_2step_ac_link"
7586 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7587/* end confdefs.h. */
7588int main(void){return 0;}
7589_ACEOF
7590if ac_fn_c_try_link "$LINENO"
7591then :
7592 break
7593fi
7594rm -f core conftest.err conftest.$ac_objext conftest.beam \
7595 conftest$ac_exeext conftest.$ac_ext
7596
7597fi
7598rm -f core conftest.err conftest.$ac_objext conftest.beam \
7599 conftest$ac_exeext conftest.$ac_ext
7600 done
7601 ac_link="$ax_pthread_save_ac_link"
7602 CFLAGS="$ax_pthread_save_CFLAGS"
7603 if test "x$ax_pthread_try" = "x"
7604then :
7605 ax_pthread_try=no
7606fi
7607 ax_cv_PTHREAD_CLANG_NO_WARN_FLAG="$ax_pthread_try"
7608
7609fi
7610{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&5
7611printf "%s\n" "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&6; }
7612
7613 case "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" in
7614 no | unknown) ;;
7615 *) PTHREAD_CFLAGS="$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG $PTHREAD_CFLAGS" ;;
7616 esac
7617
7618fi # $ax_pthread_clang = yes
7619
7620
7621
bdcd5f22
TT
7622# Various other checks:
7623if test "x$ax_pthread_ok" = "xyes"; then
7624 ax_pthread_save_CFLAGS="$CFLAGS"
7625 ax_pthread_save_LIBS="$LIBS"
7626 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
7627 LIBS="$PTHREAD_LIBS $LIBS"
7628
7629 # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
54445dc2
TT
7630 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
7631printf %s "checking for joinable pthread attribute... " >&6; }
7632if test ${ax_cv_PTHREAD_JOINABLE_ATTR+y}
7633then :
7634 printf %s "(cached) " >&6
7635else $as_nop
bdcd5f22
TT
7636 ax_cv_PTHREAD_JOINABLE_ATTR=unknown
7637 for ax_pthread_attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
7638 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7639/* end confdefs.h. */
7640#include <pthread.h>
7641int
54445dc2 7642main (void)
bdcd5f22
TT
7643{
7644int attr = $ax_pthread_attr; return attr /* ; */
7645 ;
7646 return 0;
7647}
7648_ACEOF
54445dc2
TT
7649if ac_fn_c_try_link "$LINENO"
7650then :
bdcd5f22
TT
7651 ax_cv_PTHREAD_JOINABLE_ATTR=$ax_pthread_attr; break
7652fi
54445dc2 7653rm -f core conftest.err conftest.$ac_objext conftest.beam \
bdcd5f22
TT
7654 conftest$ac_exeext conftest.$ac_ext
7655 done
7656
7657fi
54445dc2
TT
7658{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_JOINABLE_ATTR" >&5
7659printf "%s\n" "$ax_cv_PTHREAD_JOINABLE_ATTR" >&6; }
bdcd5f22
TT
7660 if test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xunknown" && \
7661 test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xPTHREAD_CREATE_JOINABLE" && \
54445dc2
TT
7662 test "x$ax_pthread_joinable_attr_defined" != "xyes"
7663then :
bdcd5f22 7664
54445dc2 7665printf "%s\n" "#define PTHREAD_CREATE_JOINABLE $ax_cv_PTHREAD_JOINABLE_ATTR" >>confdefs.h
bdcd5f22
TT
7666
7667 ax_pthread_joinable_attr_defined=yes
7668
7669fi
7670
54445dc2
TT
7671 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether more special flags are required for pthreads" >&5
7672printf %s "checking whether more special flags are required for pthreads... " >&6; }
7673if test ${ax_cv_PTHREAD_SPECIAL_FLAGS+y}
7674then :
7675 printf %s "(cached) " >&6
7676else $as_nop
bdcd5f22
TT
7677 ax_cv_PTHREAD_SPECIAL_FLAGS=no
7678 case $host_os in
7679 solaris*)
7680 ax_cv_PTHREAD_SPECIAL_FLAGS="-D_POSIX_PTHREAD_SEMANTICS"
7681 ;;
7682 esac
7683
7684fi
54445dc2
TT
7685{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_SPECIAL_FLAGS" >&5
7686printf "%s\n" "$ax_cv_PTHREAD_SPECIAL_FLAGS" >&6; }
bdcd5f22 7687 if test "x$ax_cv_PTHREAD_SPECIAL_FLAGS" != "xno" && \
54445dc2
TT
7688 test "x$ax_pthread_special_flags_added" != "xyes"
7689then :
bdcd5f22
TT
7690 PTHREAD_CFLAGS="$ax_cv_PTHREAD_SPECIAL_FLAGS $PTHREAD_CFLAGS"
7691 ax_pthread_special_flags_added=yes
7692fi
7693
54445dc2
TT
7694 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5
7695printf %s "checking for PTHREAD_PRIO_INHERIT... " >&6; }
7696if test ${ax_cv_PTHREAD_PRIO_INHERIT+y}
7697then :
7698 printf %s "(cached) " >&6
7699else $as_nop
bdcd5f22
TT
7700 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7701/* end confdefs.h. */
7702#include <pthread.h>
7703int
54445dc2 7704main (void)
bdcd5f22
TT
7705{
7706int i = PTHREAD_PRIO_INHERIT;
54445dc2 7707 return i;
bdcd5f22
TT
7708 ;
7709 return 0;
7710}
7711_ACEOF
54445dc2
TT
7712if ac_fn_c_try_link "$LINENO"
7713then :
bdcd5f22 7714 ax_cv_PTHREAD_PRIO_INHERIT=yes
54445dc2 7715else $as_nop
bdcd5f22
TT
7716 ax_cv_PTHREAD_PRIO_INHERIT=no
7717fi
54445dc2 7718rm -f core conftest.err conftest.$ac_objext conftest.beam \
bdcd5f22
TT
7719 conftest$ac_exeext conftest.$ac_ext
7720
7721fi
54445dc2
TT
7722{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5
7723printf "%s\n" "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; }
bdcd5f22 7724 if test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes" && \
54445dc2
TT
7725 test "x$ax_pthread_prio_inherit_defined" != "xyes"
7726then :
bdcd5f22 7727
54445dc2 7728printf "%s\n" "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h
bdcd5f22
TT
7729
7730 ax_pthread_prio_inherit_defined=yes
7731
7732fi
7733
7734 CFLAGS="$ax_pthread_save_CFLAGS"
7735 LIBS="$ax_pthread_save_LIBS"
7736
7737 # More AIX lossage: compile with *_r variant
7738 if test "x$GCC" != "xyes"; then
7739 case $host_os in
7740 aix*)
7741 case "x/$CC" in #(
7742 x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6) :
7743 #handle absolute path differently from PATH based program lookup
7744 case "x$CC" in #(
7745 x/*) :
54445dc2
TT
7746
7747 if as_fn_executable_p ${CC}_r
7748then :
bdcd5f22 7749 PTHREAD_CC="${CC}_r"
54445dc2
TT
7750fi
7751 if test "x${CXX}" != "x"
7752then :
7753 if as_fn_executable_p ${CXX}_r
7754then :
7755 PTHREAD_CXX="${CXX}_r"
7756fi
7757fi
7758 ;; #(
bdcd5f22 7759 *) :
54445dc2
TT
7760
7761 for ac_prog in ${CC}_r
bdcd5f22
TT
7762do
7763 # Extract the first word of "$ac_prog", so it can be a program name with args.
7764set dummy $ac_prog; ac_word=$2
54445dc2
TT
7765{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7766printf %s "checking for $ac_word... " >&6; }
7767if test ${ac_cv_prog_PTHREAD_CC+y}
7768then :
7769 printf %s "(cached) " >&6
7770else $as_nop
bdcd5f22
TT
7771 if test -n "$PTHREAD_CC"; then
7772 ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
7773else
7774as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7775for as_dir in $PATH
7776do
7777 IFS=$as_save_IFS
54445dc2
TT
7778 case $as_dir in #(((
7779 '') as_dir=./ ;;
7780 */) ;;
7781 *) as_dir=$as_dir/ ;;
7782 esac
bdcd5f22 7783 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 7784 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
bdcd5f22 7785 ac_cv_prog_PTHREAD_CC="$ac_prog"
54445dc2 7786 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
bdcd5f22
TT
7787 break 2
7788 fi
7789done
7790 done
7791IFS=$as_save_IFS
7792
7793fi
7794fi
7795PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
7796if test -n "$PTHREAD_CC"; then
54445dc2
TT
7797 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
7798printf "%s\n" "$PTHREAD_CC" >&6; }
bdcd5f22 7799else
54445dc2
TT
7800 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7801printf "%s\n" "no" >&6; }
bdcd5f22
TT
7802fi
7803
7804
7805 test -n "$PTHREAD_CC" && break
7806done
7807test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
54445dc2
TT
7808
7809 if test "x${CXX}" != "x"
7810then :
7811 for ac_prog in ${CXX}_r
7812do
7813 # Extract the first word of "$ac_prog", so it can be a program name with args.
7814set dummy $ac_prog; ac_word=$2
7815{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7816printf %s "checking for $ac_word... " >&6; }
7817if test ${ac_cv_prog_PTHREAD_CXX+y}
7818then :
7819 printf %s "(cached) " >&6
7820else $as_nop
7821 if test -n "$PTHREAD_CXX"; then
7822 ac_cv_prog_PTHREAD_CXX="$PTHREAD_CXX" # Let the user override the test.
7823else
7824as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7825for as_dir in $PATH
7826do
7827 IFS=$as_save_IFS
7828 case $as_dir in #(((
7829 '') as_dir=./ ;;
7830 */) ;;
7831 *) as_dir=$as_dir/ ;;
7832 esac
7833 for ac_exec_ext in '' $ac_executable_extensions; do
7834 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
7835 ac_cv_prog_PTHREAD_CXX="$ac_prog"
7836 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
7837 break 2
7838 fi
7839done
7840 done
7841IFS=$as_save_IFS
7842
7843fi
7844fi
7845PTHREAD_CXX=$ac_cv_prog_PTHREAD_CXX
7846if test -n "$PTHREAD_CXX"; then
7847 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CXX" >&5
7848printf "%s\n" "$PTHREAD_CXX" >&6; }
7849else
7850 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7851printf "%s\n" "no" >&6; }
7852fi
7853
7854
7855 test -n "$PTHREAD_CXX" && break
7856done
7857test -n "$PTHREAD_CXX" || PTHREAD_CXX="$CXX"
7858
7859fi
7860
7861 ;;
7862esac
7863 ;; #(
bdcd5f22
TT
7864 *) :
7865 ;;
7866esac
7867 ;;
7868 esac
7869 fi
7870fi
7871
7872test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
54445dc2
TT
7873test -n "$PTHREAD_CXX" || PTHREAD_CXX="$CXX"
7874
bdcd5f22
TT
7875
7876
7877
7878
7879
7880# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
7881if test "x$ax_pthread_ok" = "xyes"; then
7882
54445dc2 7883printf "%s\n" "#define HAVE_PTHREAD 1" >>confdefs.h
bdcd5f22
TT
7884
7885 :
7886else
7887 ax_pthread_ok=no
7888
7889fi
7890ac_ext=c
7891ac_cpp='$CPP $CPPFLAGS'
7892ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7893ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7894ac_compiler_gnu=$ac_cv_c_compiler_gnu
7895
7896
7897else
7898test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
7899
7900fi
7901
7902# Check whether --enable-uuidd was given.
54445dc2
TT
7903if test ${enable_uuidd+y}
7904then :
bdcd5f22
TT
7905 enableval=$enable_uuidd; if test "$enableval" = "no"
7906then
54445dc2
TT
7907 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Not building uuidd" >&5
7908printf "%s\n" "Not building uuidd" >&6; }
bdcd5f22
TT
7909 UUIDD_CMT="#"
7910else
54445dc2 7911 printf "%s\n" "#define USE_UUIDD 1" >>confdefs.h
bdcd5f22
TT
7912
7913 UUIDD_CMT=""
54445dc2
TT
7914 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Building uuidd" >&5
7915printf "%s\n" "Building uuidd" >&6; }
bdcd5f22
TT
7916fi
7917
54445dc2
TT
7918else $as_nop
7919 printf "%s\n" "#define USE_UUIDD 1" >>confdefs.h
bdcd5f22
TT
7920
7921if test -z "$UUID_CMT"
7922then
7923 UUIDD_CMT=""
54445dc2
TT
7924 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Building uuidd by default" >&5
7925printf "%s\n" "Building uuidd by default" >&6; }
bdcd5f22
TT
7926else
7927 UUIDD_CMT="#"
54445dc2
TT
7928 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling uuidd by default" >&5
7929printf "%s\n" "Disabling uuidd by default" >&6; }
bdcd5f22
TT
7930fi
7931
7932fi
7933
7934
7935
7936# Check whether --enable-mmp was given.
54445dc2
TT
7937if test ${enable_mmp+y}
7938then :
bdcd5f22
TT
7939 enableval=$enable_mmp; if test "$enableval" = "no"
7940then
54445dc2
TT
7941 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling mmp support" >&5
7942printf "%s\n" "Disabling mmp support" >&6; }
bdcd5f22 7943else
54445dc2
TT
7944 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling mmp support" >&5
7945printf "%s\n" "Enabling mmp support" >&6; }
7946 printf "%s\n" "#define CONFIG_MMP 1" >>confdefs.h
bdcd5f22
TT
7947
7948fi
7949
54445dc2
TT
7950else $as_nop
7951 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling mmp support by default" >&5
7952printf "%s\n" "Enabling mmp support by default" >&6; }
7953printf "%s\n" "#define CONFIG_MMP 1" >>confdefs.h
bdcd5f22
TT
7954
7955
7956fi
7957
7958
7959# Check whether --enable-tdb was given.
54445dc2
TT
7960if test ${enable_tdb+y}
7961then :
6eb00fb7
EB
7962 enableval=$enable_tdb;
7963if test "$enableval" = "no"
bdcd5f22 7964then
54445dc2
TT
7965 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling tdb support" >&5
7966printf "%s\n" "Disabling tdb support" >&6; }
6eb00fb7 7967 CONFIG_TDB=0
bdcd5f22 7968else
54445dc2
TT
7969 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling tdb support" >&5
7970printf "%s\n" "Enabling tdb support" >&6; }
6eb00fb7 7971 CONFIG_TDB=1
bdcd5f22
TT
7972fi
7973
6eb00fb7 7974
54445dc2 7975else $as_nop
bdcd5f22 7976
6eb00fb7
EB
7977case "$host_os" in
7978mingw*)
7979 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling tdb support by default" >&5
7980printf "%s\n" "Disabling tdb support by default" >&6; }
7981 CONFIG_TDB=0
7982 ;;
7983*)
7984 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling tdb support by default" >&5
7985printf "%s\n" "Enabling tdb support by default" >&6; }
7986 CONFIG_TDB=1
7987 ;;
7988esac
7989
bdcd5f22
TT
7990
7991fi
7992
6eb00fb7
EB
7993if test "$CONFIG_TDB" = "1"
7994then
7995 printf "%s\n" "#define CONFIG_TDB 1" >>confdefs.h
7996
7997 TDB_CMT=""
7998 TDB_MAN_COMMENT=""
7999else
8000 TDB_CMT="#"
8001 TDB_MAN_COMMENT='.\"'
8002fi
bdcd5f22
TT
8003
8004
8005
8006# Check whether --enable-bmap-stats was given.
54445dc2
TT
8007if test ${enable_bmap_stats+y}
8008then :
bdcd5f22
TT
8009 enableval=$enable_bmap_stats; if test "$enableval" = "no"
8010then
54445dc2
TT
8011 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling bitmap statistics support" >&5
8012printf "%s\n" "Disabling bitmap statistics support" >&6; }
bdcd5f22 8013else
54445dc2
TT
8014 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling bitmap statistics support" >&5
8015printf "%s\n" "Enabling bitmap statistics support" >&6; }
8016 printf "%s\n" "#define ENABLE_BMAP_STATS 1" >>confdefs.h
bdcd5f22
TT
8017
8018fi
8019
54445dc2
TT
8020else $as_nop
8021 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling bitmap statistics support by default" >&5
8022printf "%s\n" "Enabling bitmap statistics support by default" >&6; }
8023printf "%s\n" "#define ENABLE_BMAP_STATS 1" >>confdefs.h
bdcd5f22
TT
8024
8025
8026fi
8027
8028
8029# Check whether --enable-bmap-stats-ops was given.
54445dc2
TT
8030if test ${enable_bmap_stats_ops+y}
8031then :
bdcd5f22
TT
8032 enableval=$enable_bmap_stats_ops; if test "$enableval" = "no"
8033then
54445dc2
TT
8034 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling additional bitmap statistics" >&5
8035printf "%s\n" "Disabling additional bitmap statistics" >&6; }
bdcd5f22 8036else
54445dc2
TT
8037 if test "x${enable_bmap_stats}" = "xno"
8038then :
8039 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
8040printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
bdcd5f22
TT
8041as_fn_error $? "Error --enable-bmap-stats-ops requires bmap-stats
8042See \`config.log' for more details" "$LINENO" 5; }
8043fi
8044
54445dc2
TT
8045 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling additional bitmap statistics" >&5
8046printf "%s\n" "Enabling additional bitmap statistics" >&6; }
8047 printf "%s\n" "#define ENABLE_BMAP_STATS_OPS 1" >>confdefs.h
bdcd5f22
TT
8048
8049fi
8050
54445dc2
TT
8051else $as_nop
8052 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling additional bitmap statistics by default" >&5
8053printf "%s\n" "Disabling additional bitmap statistics by default" >&6; }
bdcd5f22
TT
8054
8055fi
8056
8057MAKEFILE_LIBRARY=$srcdir/lib/Makefile.library
8058
8059GETTEXT_PACKAGE=e2fsprogs
8060PACKAGE=e2fsprogs
8061VERSION="$E2FSPROGS_VERSION"
8062VERSION=0.14.1
8063
54445dc2 8064printf "%s\n" "#define PACKAGE \"$PACKAGE\"" >>confdefs.h
bdcd5f22
TT
8065
8066
54445dc2 8067printf "%s\n" "#define VERSION \"$VERSION\"" >>confdefs.h
bdcd5f22
TT
8068
8069
8070
8071
8072
54445dc2
TT
8073{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
8074printf %s "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
bdcd5f22 8075set x ${MAKE-make}
54445dc2
TT
8076ac_make=`printf "%s\n" "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
8077if eval test \${ac_cv_prog_make_${ac_make}_set+y}
8078then :
8079 printf %s "(cached) " >&6
8080else $as_nop
bdcd5f22
TT
8081 cat >conftest.make <<\_ACEOF
8082SHELL = /bin/sh
8083all:
8084 @echo '@@@%%%=$(MAKE)=@@@%%%'
8085_ACEOF
8086# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
8087case `${MAKE-make} -f conftest.make 2>/dev/null` in
8088 *@@@%%%=?*=@@@%%%*)
8089 eval ac_cv_prog_make_${ac_make}_set=yes;;
8090 *)
8091 eval ac_cv_prog_make_${ac_make}_set=no;;
8092esac
57aa50d4
TT
8093rm -f conftest.make
8094fi
8095if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
54445dc2
TT
8096 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8097printf "%s\n" "yes" >&6; }
57aa50d4 8098 SET_MAKE=
39fd3d4f 8099else
54445dc2
TT
8100 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8101printf "%s\n" "no" >&6; }
57aa50d4 8102 SET_MAKE="MAKE=${MAKE-make}"
39fd3d4f
SJR
8103fi
8104
54445dc2
TT
8105
8106 # Find a good install program. We prefer a C program (faster),
57aa50d4
TT
8107# so one script is as good as another. But avoid the broken or
8108# incompatible versions:
8109# SysV /etc/install, /usr/sbin/install
8110# SunOS /usr/etc/install
8111# IRIX /sbin/install
8112# AIX /bin/install
8113# AmigaOS /C/install, which installs bootblocks on floppy discs
8114# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
8115# AFS /usr/afsws/bin/install, which mishandles nonexistent args
8116# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
8117# OS/2's system install, which has a completely different semantic
8118# ./install, which can be erroneously created by make from ./install.sh.
8119# Reject install programs that cannot install multiple files.
54445dc2
TT
8120{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
8121printf %s "checking for a BSD-compatible install... " >&6; }
57aa50d4 8122if test -z "$INSTALL"; then
54445dc2
TT
8123if test ${ac_cv_path_install+y}
8124then :
8125 printf %s "(cached) " >&6
8126else $as_nop
57aa50d4
TT
8127 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8128for as_dir in $PATH
8129do
8130 IFS=$as_save_IFS
54445dc2
TT
8131 case $as_dir in #(((
8132 '') as_dir=./ ;;
8133 */) ;;
8134 *) as_dir=$as_dir/ ;;
8135 esac
8136 # Account for fact that we put trailing slashes in our PATH walk.
8137case $as_dir in #((
8138 ./ | /[cC]/* | \
57aa50d4
TT
8139 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
8140 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
8141 /usr/ucb/* ) ;;
8142 *)
8143 # OSF1 and SCO ODT 3.0 have their own names for install.
8144 # Don't use installbsd from OSF since it installs stuff as root
8145 # by default.
8146 for ac_prog in ginstall scoinst install; do
8147 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 8148 if as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext"; then
57aa50d4 8149 if test $ac_prog = install &&
54445dc2 8150 grep dspmsg "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
57aa50d4
TT
8151 # AIX install. It has an incompatible calling convention.
8152 :
8153 elif test $ac_prog = install &&
54445dc2 8154 grep pwplus "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
57aa50d4
TT
8155 # program-specific install script used by HP pwplus--don't use.
8156 :
8157 else
8158 rm -rf conftest.one conftest.two conftest.dir
8159 echo one > conftest.one
8160 echo two > conftest.two
8161 mkdir conftest.dir
54445dc2 8162 if "$as_dir$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir/" &&
57aa50d4
TT
8163 test -s conftest.one && test -s conftest.two &&
8164 test -s conftest.dir/conftest.one &&
8165 test -s conftest.dir/conftest.two
8166 then
54445dc2 8167 ac_cv_path_install="$as_dir$ac_prog$ac_exec_ext -c"
57aa50d4
TT
8168 break 3
8169 fi
8170 fi
8171 fi
8172 done
8173 done
8174 ;;
8175esac
8176
8177 done
8178IFS=$as_save_IFS
b0cacab0 8179
57aa50d4 8180rm -rf conftest.one conftest.two conftest.dir
39fd3d4f 8181
93636bde 8182fi
54445dc2 8183 if test ${ac_cv_path_install+y}; then
57aa50d4
TT
8184 INSTALL=$ac_cv_path_install
8185 else
8186 # As a last resort, use the slow shell script. Don't cache a
8187 # value for INSTALL within a source directory, because that will
8188 # break other packages using the cache if that directory is
8189 # removed, or if the value is a relative name.
8190 INSTALL=$ac_install_sh
8191 fi
93636bde 8192fi
54445dc2
TT
8193{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
8194printf "%s\n" "$INSTALL" >&6; }
a64c9c13 8195
57aa50d4
TT
8196# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
8197# It thinks the first close brace ends the variable substitution.
8198test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
b0cacab0 8199
57aa50d4 8200test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
a64c9c13 8201
57aa50d4 8202test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
39fd3d4f 8203
54445dc2
TT
8204
8205 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a race-free mkdir -p" >&5
8206printf %s "checking for a race-free mkdir -p... " >&6; }
93613951 8207if test -z "$MKDIR_P"; then
54445dc2
TT
8208 if test ${ac_cv_path_mkdir+y}
8209then :
8210 printf %s "(cached) " >&6
8211else $as_nop
93613951
TT
8212 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8213for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
8214do
8215 IFS=$as_save_IFS
54445dc2
TT
8216 case $as_dir in #(((
8217 '') as_dir=./ ;;
8218 */) ;;
8219 *) as_dir=$as_dir/ ;;
8220 esac
93613951
TT
8221 for ac_prog in mkdir gmkdir; do
8222 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
8223 as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext" || continue
8224 case `"$as_dir$ac_prog$ac_exec_ext" --version 2>&1` in #(
8225 'mkdir ('*'coreutils) '* | \
8226 'BusyBox '* | \
93613951 8227 'mkdir (fileutils) '4.1*)
54445dc2 8228 ac_cv_path_mkdir=$as_dir$ac_prog$ac_exec_ext
93613951
TT
8229 break 3;;
8230 esac
8231 done
8232 done
8233 done
8234IFS=$as_save_IFS
8235
8236fi
39fd3d4f 8237
93613951 8238 test -d ./--version && rmdir ./--version
54445dc2 8239 if test ${ac_cv_path_mkdir+y}; then
93613951
TT
8240 MKDIR_P="$ac_cv_path_mkdir -p"
8241 else
8242 # As a last resort, use the slow shell script. Don't cache a
8243 # value for MKDIR_P within a source directory, because that will
8244 # break other packages using the cache if that directory is
8245 # removed, or if the value is a relative name.
8246 MKDIR_P="$ac_install_sh -d"
57aa50d4 8247 fi
93613951 8248fi
54445dc2
TT
8249{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
8250printf "%s\n" "$MKDIR_P" >&6; }
93613951 8251
e1052144 8252
54445dc2
TT
8253 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
8254printf %s "checking whether NLS is requested... " >&6; }
57aa50d4 8255 # Check whether --enable-nls was given.
54445dc2
TT
8256if test ${enable_nls+y}
8257then :
57aa50d4 8258 enableval=$enable_nls; USE_NLS=$enableval
54445dc2 8259else $as_nop
57aa50d4
TT
8260 USE_NLS=yes
8261fi
b0cacab0 8262
54445dc2
TT
8263 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
8264printf "%s\n" "$USE_NLS" >&6; }
93636bde 8265
a64c9c13 8266
a64c9c13 8267
b0cacab0 8268
bdcd5f22 8269 GETTEXT_MACRO_VERSION=0.20
93613951
TT
8270
8271
b0cacab0 8272
a64c9c13 8273
57aa50d4
TT
8274# Prepare PATH_SEPARATOR.
8275# The user is always right.
8276if test "${PATH_SEPARATOR+set}" != set; then
93613951
TT
8277 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
8278 # contains only /bin. Note that ksh looks also at the FPATH variable,
8279 # so we have to set that as well for the test.
8280 PATH_SEPARATOR=:
8281 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8282 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8283 || PATH_SEPARATOR=';'
8284 }
57aa50d4 8285fi
b0cacab0 8286
57aa50d4
TT
8287# Find out how to test for executable files. Don't use a zero-byte file,
8288# as systems may use methods other than mode bits to determine executability.
8289cat >conf$$.file <<_ASEOF
8290#! /bin/sh
8291exit 0
8292_ASEOF
8293chmod +x conf$$.file
8294if test -x conf$$.file >/dev/null 2>&1; then
8295 ac_executable_p="test -x"
8296else
8297 ac_executable_p="test -f"
8298fi
8299rm -f conf$$.file
b0cacab0 8300
57aa50d4
TT
8301# Extract the first word of "msgfmt", so it can be a program name with args.
8302set dummy msgfmt; ac_word=$2
54445dc2
TT
8303{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8304printf %s "checking for $ac_word... " >&6; }
8305if test ${ac_cv_path_MSGFMT+y}
8306then :
8307 printf %s "(cached) " >&6
8308else $as_nop
57aa50d4
TT
8309 case "$MSGFMT" in
8310 [\\/]* | ?:[\\/]*)
8311 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
8312 ;;
8313 *)
8314 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
8315 for ac_dir in $PATH; do
8316 IFS="$ac_save_IFS"
8317 test -z "$ac_dir" && ac_dir=.
8318 for ac_exec_ext in '' $ac_executable_extensions; do
8319 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
93613951
TT
8320 echo "$as_me: trying $ac_dir/$ac_word..." >&5
8321 if $ac_dir/$ac_word --statistics /dev/null >&5 2>&1 &&
57aa50d4
TT
8322 (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
8323 ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
8324 break 2
8325 fi
8326 fi
8327 done
8328 done
8329 IFS="$ac_save_IFS"
8330 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
8331 ;;
e1052144 8332esac
b0cacab0 8333fi
57aa50d4
TT
8334MSGFMT="$ac_cv_path_MSGFMT"
8335if test "$MSGFMT" != ":"; then
54445dc2
TT
8336 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
8337printf "%s\n" "$MSGFMT" >&6; }
57aa50d4 8338else
54445dc2
TT
8339 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8340printf "%s\n" "no" >&6; }
b0cacab0 8341fi
a64c9c13 8342
57aa50d4
TT
8343 # Extract the first word of "gmsgfmt", so it can be a program name with args.
8344set dummy gmsgfmt; ac_word=$2
54445dc2
TT
8345{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8346printf %s "checking for $ac_word... " >&6; }
8347if test ${ac_cv_path_GMSGFMT+y}
8348then :
8349 printf %s "(cached) " >&6
8350else $as_nop
57aa50d4
TT
8351 case $GMSGFMT in
8352 [\\/]* | ?:[\\/]*)
8353 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
8354 ;;
8355 *)
8356 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8357for as_dir in $PATH
8358do
8359 IFS=$as_save_IFS
54445dc2
TT
8360 case $as_dir in #(((
8361 '') as_dir=./ ;;
8362 */) ;;
8363 *) as_dir=$as_dir/ ;;
8364 esac
57aa50d4 8365 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
8366 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
8367 ac_cv_path_GMSGFMT="$as_dir$ac_word$ac_exec_ext"
8368 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
8369 break 2
8370 fi
8371done
8372 done
8373IFS=$as_save_IFS
a64c9c13 8374
57aa50d4
TT
8375 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
8376 ;;
e1052144 8377esac
57aa50d4
TT
8378fi
8379GMSGFMT=$ac_cv_path_GMSGFMT
8380if test -n "$GMSGFMT"; then
54445dc2
TT
8381 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
8382printf "%s\n" "$GMSGFMT" >&6; }
b0cacab0 8383else
54445dc2
TT
8384 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8385printf "%s\n" "no" >&6; }
b0cacab0 8386fi
e1052144 8387
b0cacab0 8388
b0cacab0 8389
bdcd5f22 8390 case `$GMSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
93613951
TT
8391 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) GMSGFMT_015=: ;;
8392 *) GMSGFMT_015=$GMSGFMT ;;
8393 esac
8394
8395
57aa50d4
TT
8396
8397# Prepare PATH_SEPARATOR.
8398# The user is always right.
8399if test "${PATH_SEPARATOR+set}" != set; then
93613951
TT
8400 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
8401 # contains only /bin. Note that ksh looks also at the FPATH variable,
8402 # so we have to set that as well for the test.
8403 PATH_SEPARATOR=:
8404 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8405 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8406 || PATH_SEPARATOR=';'
8407 }
57aa50d4 8408fi
b0cacab0 8409
57aa50d4
TT
8410# Find out how to test for executable files. Don't use a zero-byte file,
8411# as systems may use methods other than mode bits to determine executability.
8412cat >conf$$.file <<_ASEOF
8413#! /bin/sh
8414exit 0
8415_ASEOF
8416chmod +x conf$$.file
8417if test -x conf$$.file >/dev/null 2>&1; then
8418 ac_executable_p="test -x"
8419else
8420 ac_executable_p="test -f"
8421fi
8422rm -f conf$$.file
b0cacab0 8423
57aa50d4
TT
8424# Extract the first word of "xgettext", so it can be a program name with args.
8425set dummy xgettext; ac_word=$2
54445dc2
TT
8426{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8427printf %s "checking for $ac_word... " >&6; }
8428if test ${ac_cv_path_XGETTEXT+y}
8429then :
8430 printf %s "(cached) " >&6
8431else $as_nop
57aa50d4
TT
8432 case "$XGETTEXT" in
8433 [\\/]* | ?:[\\/]*)
8434 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
8435 ;;
8436 *)
8437 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
8438 for ac_dir in $PATH; do
8439 IFS="$ac_save_IFS"
8440 test -z "$ac_dir" && ac_dir=.
8441 for ac_exec_ext in '' $ac_executable_extensions; do
8442 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
93613951
TT
8443 echo "$as_me: trying $ac_dir/$ac_word..." >&5
8444 if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >&5 2>&1 &&
57aa50d4
TT
8445 (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
8446 ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
8447 break 2
8448 fi
8449 fi
8450 done
8451 done
8452 IFS="$ac_save_IFS"
8453 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
8454 ;;
e1052144 8455esac
b0cacab0 8456fi
57aa50d4
TT
8457XGETTEXT="$ac_cv_path_XGETTEXT"
8458if test "$XGETTEXT" != ":"; then
54445dc2
TT
8459 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
8460printf "%s\n" "$XGETTEXT" >&6; }
57aa50d4 8461else
54445dc2
TT
8462 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8463printf "%s\n" "no" >&6; }
b0cacab0 8464fi
b0cacab0 8465
57aa50d4 8466 rm -f messages.po
a64c9c13 8467
93613951
TT
8468 case `$XGETTEXT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
8469 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) XGETTEXT_015=: ;;
8470 *) XGETTEXT_015=$XGETTEXT ;;
8471 esac
8472
8473
b0cacab0 8474
57aa50d4
TT
8475# Prepare PATH_SEPARATOR.
8476# The user is always right.
8477if test "${PATH_SEPARATOR+set}" != set; then
93613951
TT
8478 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
8479 # contains only /bin. Note that ksh looks also at the FPATH variable,
8480 # so we have to set that as well for the test.
8481 PATH_SEPARATOR=:
8482 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8483 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8484 || PATH_SEPARATOR=';'
8485 }
57aa50d4 8486fi
b0cacab0 8487
57aa50d4
TT
8488# Find out how to test for executable files. Don't use a zero-byte file,
8489# as systems may use methods other than mode bits to determine executability.
8490cat >conf$$.file <<_ASEOF
8491#! /bin/sh
8492exit 0
8493_ASEOF
8494chmod +x conf$$.file
8495if test -x conf$$.file >/dev/null 2>&1; then
8496 ac_executable_p="test -x"
8497else
8498 ac_executable_p="test -f"
8499fi
8500rm -f conf$$.file
8501
8502# Extract the first word of "msgmerge", so it can be a program name with args.
8503set dummy msgmerge; ac_word=$2
54445dc2
TT
8504{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8505printf %s "checking for $ac_word... " >&6; }
8506if test ${ac_cv_path_MSGMERGE+y}
8507then :
8508 printf %s "(cached) " >&6
8509else $as_nop
57aa50d4
TT
8510 case "$MSGMERGE" in
8511 [\\/]* | ?:[\\/]*)
8512 ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
8513 ;;
8514 *)
8515 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
8516 for ac_dir in $PATH; do
8517 IFS="$ac_save_IFS"
8518 test -z "$ac_dir" && ac_dir=.
8519 for ac_exec_ext in '' $ac_executable_extensions; do
8520 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
93613951
TT
8521 echo "$as_me: trying $ac_dir/$ac_word..." >&5
8522 if $ac_dir/$ac_word --update -q /dev/null /dev/null >&5 2>&1; then
57aa50d4
TT
8523 ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
8524 break 2
8525 fi
8526 fi
8527 done
8528 done
8529 IFS="$ac_save_IFS"
8530 test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
8531 ;;
e1052144 8532esac
57aa50d4
TT
8533fi
8534MSGMERGE="$ac_cv_path_MSGMERGE"
8535if test "$MSGMERGE" != ":"; then
54445dc2
TT
8536 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
8537printf "%s\n" "$MSGMERGE" >&6; }
b0cacab0 8538else
54445dc2
TT
8539 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8540printf "%s\n" "no" >&6; }
b0cacab0 8541fi
e1052144 8542
93636bde 8543
bdcd5f22
TT
8544 if LC_ALL=C $MSGMERGE --help | grep ' --for-msgfmt ' >/dev/null; then
8545 MSGMERGE_FOR_MSGFMT_OPTION='--for-msgfmt'
8546 else
8547 if LC_ALL=C $MSGMERGE --help | grep ' --no-fuzzy-matching ' >/dev/null; then
8548 MSGMERGE_FOR_MSGFMT_OPTION='--no-fuzzy-matching --no-location --quiet'
8549 else
8550 MSGMERGE_FOR_MSGFMT_OPTION='--no-location --quiet'
8551 fi
8552 fi
93613951
TT
8553
8554
8555 test -n "${XGETTEXT_EXTRA_OPTIONS+set}" || XGETTEXT_EXTRA_OPTIONS=
8556
8557
8558 ac_config_commands="$ac_config_commands po-directories"
a64c9c13 8559
a64c9c13 8560
93613951 8561
e598c29b
TT
8562 if test "X$prefix" = "XNONE"; then
8563 acl_final_prefix="$ac_default_prefix"
8564 else
8565 acl_final_prefix="$prefix"
8566 fi
8567 if test "X$exec_prefix" = "XNONE"; then
8568 acl_final_exec_prefix='${prefix}'
8569 else
8570 acl_final_exec_prefix="$exec_prefix"
8571 fi
8572 acl_save_prefix="$prefix"
8573 prefix="$acl_final_prefix"
8574 eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
8575 prefix="$acl_save_prefix"
93613951 8576
93613951 8577
e598c29b
TT
8578
8579# Check whether --with-gnu-ld was given.
54445dc2
TT
8580if test ${with_gnu_ld+y}
8581then :
e598c29b 8582 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
54445dc2 8583else $as_nop
e598c29b 8584 with_gnu_ld=no
93613951 8585fi
a64c9c13 8586
e598c29b
TT
8587# Prepare PATH_SEPARATOR.
8588# The user is always right.
8589if test "${PATH_SEPARATOR+set}" != set; then
8590 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
8591 # contains only /bin. Note that ksh looks also at the FPATH variable,
8592 # so we have to set that as well for the test.
8593 PATH_SEPARATOR=:
8594 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8595 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8596 || PATH_SEPARATOR=';'
8597 }
d1154eb4
TT
8598fi
8599
bdcd5f22 8600if test -n "$LD"; then
54445dc2
TT
8601 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ld" >&5
8602printf %s "checking for ld... " >&6; }
bdcd5f22 8603elif test "$GCC" = yes; then
54445dc2
TT
8604 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
8605printf %s "checking for ld used by $CC... " >&6; }
e598c29b 8606elif test "$with_gnu_ld" = yes; then
54445dc2
TT
8607 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
8608printf %s "checking for GNU ld... " >&6; }
e598c29b 8609else
54445dc2
TT
8610 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
8611printf %s "checking for non-GNU ld... " >&6; }
d1154eb4 8612fi
bdcd5f22
TT
8613if test -n "$LD"; then
8614 # Let the user override the test with a path.
8615 :
8616else
54445dc2
TT
8617 if test ${acl_cv_path_LD+y}
8618then :
8619 printf %s "(cached) " >&6
8620else $as_nop
bdcd5f22
TT
8621
8622 acl_cv_path_LD= # Final result of this test
8623 ac_prog=ld # Program to search in $PATH
8624 if test "$GCC" = yes; then
8625 # Check if gcc -print-prog-name=ld gives a path.
8626 case $host in
8627 *-*-mingw*)
8628 # gcc leaves a trailing carriage return which upsets mingw
8629 acl_output=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
8630 *)
8631 acl_output=`($CC -print-prog-name=ld) 2>&5` ;;
8632 esac
8633 case $acl_output in
8634 # Accept absolute paths.
8635 [\\/]* | ?:[\\/]*)
8636 re_direlt='/[^/][^/]*/\.\./'
8637 # Canonicalize the pathname of ld
8638 acl_output=`echo "$acl_output" | sed 's%\\\\%/%g'`
8639 while echo "$acl_output" | grep "$re_direlt" > /dev/null 2>&1; do
8640 acl_output=`echo $acl_output | sed "s%$re_direlt%/%"`
8641 done
8642 # Got the pathname. No search in PATH is needed.
8643 acl_cv_path_LD="$acl_output"
8644 ac_prog=
8645 ;;
8646 "")
8647 # If it fails, then pretend we aren't using GCC.
8648 ;;
8649 *)
8650 # If it is relative, then search for the first ld in PATH.
8651 with_gnu_ld=unknown
8652 ;;
e598c29b
TT
8653 esac
8654 fi
bdcd5f22
TT
8655 if test -n "$ac_prog"; then
8656 # Search for $ac_prog in $PATH.
8657 acl_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
8658 for ac_dir in $PATH; do
8659 IFS="$acl_save_ifs"
8660 test -z "$ac_dir" && ac_dir=.
8661 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
8662 acl_cv_path_LD="$ac_dir/$ac_prog"
8663 # Check to see if the program is GNU ld. I'd rather use --version,
8664 # but apparently some variants of GNU ld only accept -v.
8665 # Break only if it was the GNU/non-GNU ld that we prefer.
8666 case `"$acl_cv_path_LD" -v 2>&1 </dev/null` in
8667 *GNU* | *'with BFD'*)
8668 test "$with_gnu_ld" != no && break
8669 ;;
8670 *)
8671 test "$with_gnu_ld" != yes && break
8672 ;;
8673 esac
8674 fi
8675 done
8676 IFS="$acl_save_ifs"
8677 fi
8678 case $host in
8679 *-*-aix*)
8680 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8681/* end confdefs.h. */
5598a968 8682#if defined __powerpc64__ || defined __LP64__
bdcd5f22
TT
8683 int ok;
8684 #else
8685 error fail
8686 #endif
8687
8688_ACEOF
54445dc2
TT
8689if ac_fn_c_try_compile "$LINENO"
8690then :
bdcd5f22
TT
8691 # The compiler produces 64-bit code. Add option '-b64' so that the
8692 # linker groks 64-bit object files.
8693 case "$acl_cv_path_LD " in
8694 *" -b64 "*) ;;
8695 *) acl_cv_path_LD="$acl_cv_path_LD -b64" ;;
8696 esac
8697
8698fi
54445dc2 8699rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
bdcd5f22
TT
8700 ;;
8701 sparc64-*-netbsd*)
8702 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8703/* end confdefs.h. */
8704#if defined __sparcv9 || defined __arch64__
8705 int ok;
8706 #else
8707 error fail
8708 #endif
8709
8710_ACEOF
54445dc2
TT
8711if ac_fn_c_try_compile "$LINENO"
8712then :
bdcd5f22 8713
54445dc2 8714else $as_nop
bdcd5f22
TT
8715 # The compiler produces 32-bit code. Add option '-m elf32_sparc'
8716 # so that the linker groks 32-bit object files.
8717 case "$acl_cv_path_LD " in
8718 *" -m elf32_sparc "*) ;;
8719 *) acl_cv_path_LD="$acl_cv_path_LD -m elf32_sparc" ;;
8720 esac
8721
d1154eb4 8722fi
54445dc2 8723rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
bdcd5f22
TT
8724 ;;
8725 esac
8726
d1154eb4 8727fi
e598c29b 8728
bdcd5f22
TT
8729 LD="$acl_cv_path_LD"
8730fi
e598c29b 8731if test -n "$LD"; then
54445dc2
TT
8732 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
8733printf "%s\n" "$LD" >&6; }
d1154eb4 8734else
54445dc2
TT
8735 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8736printf "%s\n" "no" >&6; }
bdcd5f22 8737 as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
d1154eb4 8738fi
54445dc2
TT
8739{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
8740printf %s "checking if the linker ($LD) is GNU ld... " >&6; }
8741if test ${acl_cv_prog_gnu_ld+y}
8742then :
8743 printf %s "(cached) " >&6
8744else $as_nop
e598c29b
TT
8745 # I'd rather use --version here, but apparently some GNU lds only accept -v.
8746case `$LD -v 2>&1 </dev/null` in
8747*GNU* | *'with BFD'*)
8748 acl_cv_prog_gnu_ld=yes
8749 ;;
8750*)
8751 acl_cv_prog_gnu_ld=no
8752 ;;
8753esac
8754fi
54445dc2
TT
8755{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
8756printf "%s\n" "$acl_cv_prog_gnu_ld" >&6; }
e598c29b 8757with_gnu_ld=$acl_cv_prog_gnu_ld
93613951 8758
d1154eb4 8759
93613951 8760
d1154eb4 8761
54445dc2
TT
8762
8763
8764 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
8765printf %s "checking for shared library run path origin... " >&6; }
8766if test ${acl_cv_rpath+y}
8767then :
8768 printf %s "(cached) " >&6
8769else $as_nop
d1154eb4 8770
e598c29b
TT
8771 CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
8772 ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
8773 . ./conftest.sh
8774 rm -f ./conftest.sh
8775 acl_cv_rpath=done
d1154eb4 8776
93613951 8777fi
54445dc2
TT
8778{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
8779printf "%s\n" "$acl_cv_rpath" >&6; }
e598c29b
TT
8780 wl="$acl_cv_wl"
8781 acl_libext="$acl_cv_libext"
8782 acl_shlibext="$acl_cv_shlibext"
8783 acl_libname_spec="$acl_cv_libname_spec"
8784 acl_library_names_spec="$acl_cv_library_names_spec"
8785 acl_hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
8786 acl_hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
8787 acl_hardcode_direct="$acl_cv_hardcode_direct"
8788 acl_hardcode_minus_L="$acl_cv_hardcode_minus_L"
8789 # Check whether --enable-rpath was given.
54445dc2
TT
8790if test ${enable_rpath+y}
8791then :
e598c29b 8792 enableval=$enable_rpath; :
54445dc2 8793else $as_nop
e598c29b 8794 enable_rpath=yes
93613951 8795fi
d1154eb4 8796
d1154eb4
TT
8797
8798
93613951 8799
54445dc2
TT
8800 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking 32-bit host C ABI" >&5
8801printf %s "checking 32-bit host C ABI... " >&6; }
8802if test ${gl_cv_host_cpu_c_abi_32bit+y}
8803then :
8804 printf %s "(cached) " >&6
8805else $as_nop
bdcd5f22
TT
8806 if test -n "$gl_cv_host_cpu_c_abi"; then
8807 case "$gl_cv_host_cpu_c_abi" in
8808 i386 | x86_64-x32 | arm | armhf | arm64-ilp32 | hppa | ia64-ilp32 | mips | mipsn32 | powerpc | riscv*-ilp32* | s390 | sparc)
8809 gl_cv_host_cpu_c_abi_32bit=yes ;;
8810 x86_64 | alpha | arm64 | hppa64 | ia64 | mips64 | powerpc64 | powerpc64-elfv2 | riscv*-lp64* | s390x | sparc64 )
8811 gl_cv_host_cpu_c_abi_32bit=no ;;
8812 *)
8813 gl_cv_host_cpu_c_abi_32bit=unknown ;;
8814 esac
8815 else
8816 case "$host_cpu" in
8817
8818 # CPUs that only support a 32-bit ABI.
8819 arc \
8820 | bfin \
8821 | cris* \
8822 | csky \
8823 | epiphany \
8824 | ft32 \
8825 | h8300 \
8826 | m68k \
8827 | microblaze | microblazeel \
8828 | nds32 | nds32le | nds32be \
8829 | nios2 | nios2eb | nios2el \
8830 | or1k* \
8831 | or32 \
8832 | sh | sh1234 | sh1234elb \
8833 | tic6x \
8834 | xtensa* )
8835 gl_cv_host_cpu_c_abi_32bit=yes
8836 ;;
8837
8838 # CPUs that only support a 64-bit ABI.
8839 alpha | alphaev[4-8] | alphaev56 | alphapca5[67] | alphaev6[78] \
8840 | mmix )
8841 gl_cv_host_cpu_c_abi_32bit=no
8842 ;;
8843
8844 i[34567]86 )
8845 gl_cv_host_cpu_c_abi_32bit=yes
8846 ;;
8847
8848 x86_64 )
8849 # On x86_64 systems, the C compiler may be generating code in one of
8850 # these ABIs:
8851 # - 64-bit instruction set, 64-bit pointers, 64-bit 'long': x86_64.
8852 # - 64-bit instruction set, 64-bit pointers, 32-bit 'long': x86_64
8853 # with native Windows (mingw, MSVC).
8854 # - 64-bit instruction set, 32-bit pointers, 32-bit 'long': x86_64-x32.
8855 # - 32-bit instruction set, 32-bit pointers, 32-bit 'long': i386.
8856 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
d1154eb4 8857/* end confdefs.h. */
bdcd5f22
TT
8858#if (defined __x86_64__ || defined __amd64__ \
8859 || defined _M_X64 || defined _M_AMD64) \
8860 && !(defined __ILP32__ || defined _ILP32)
8861 int ok;
8862 #else
8863 error fail
8864 #endif
e598c29b 8865
bdcd5f22 8866_ACEOF
54445dc2
TT
8867if ac_fn_c_try_compile "$LINENO"
8868then :
bdcd5f22 8869 gl_cv_host_cpu_c_abi_32bit=no
54445dc2 8870else $as_nop
bdcd5f22
TT
8871 gl_cv_host_cpu_c_abi_32bit=yes
8872fi
54445dc2 8873rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
bdcd5f22
TT
8874 ;;
8875
8876 arm* | aarch64 )
8877 # Assume arm with EABI.
8878 # On arm64 systems, the C compiler may be generating code in one of
8879 # these ABIs:
8880 # - aarch64 instruction set, 64-bit pointers, 64-bit 'long': arm64.
8881 # - aarch64 instruction set, 32-bit pointers, 32-bit 'long': arm64-ilp32.
8882 # - 32-bit instruction set, 32-bit pointers, 32-bit 'long': arm or armhf.
8883 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8884/* end confdefs.h. */
8885#if defined __aarch64__ && !(defined __ILP32__ || defined _ILP32)
8886 int ok;
8887 #else
8888 error fail
8889 #endif
8890
8891_ACEOF
54445dc2
TT
8892if ac_fn_c_try_compile "$LINENO"
8893then :
bdcd5f22 8894 gl_cv_host_cpu_c_abi_32bit=no
54445dc2 8895else $as_nop
bdcd5f22
TT
8896 gl_cv_host_cpu_c_abi_32bit=yes
8897fi
54445dc2 8898rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
bdcd5f22
TT
8899 ;;
8900
8901 hppa1.0 | hppa1.1 | hppa2.0* | hppa64 )
8902 # On hppa, the C compiler may be generating 32-bit code or 64-bit
8903 # code. In the latter case, it defines _LP64 and __LP64__.
8904 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8905/* end confdefs.h. */
8906#ifdef __LP64__
8907 int ok;
8908 #else
8909 error fail
8910 #endif
8911
8912_ACEOF
54445dc2
TT
8913if ac_fn_c_try_compile "$LINENO"
8914then :
bdcd5f22 8915 gl_cv_host_cpu_c_abi_32bit=no
54445dc2 8916else $as_nop
bdcd5f22
TT
8917 gl_cv_host_cpu_c_abi_32bit=yes
8918fi
54445dc2 8919rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
bdcd5f22
TT
8920 ;;
8921
8922 ia64* )
8923 # On ia64 on HP-UX, the C compiler may be generating 64-bit code or
8924 # 32-bit code. In the latter case, it defines _ILP32.
8925 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8926/* end confdefs.h. */
8927#ifdef _ILP32
8928 int ok;
8929 #else
8930 error fail
8931 #endif
8932
8933_ACEOF
54445dc2
TT
8934if ac_fn_c_try_compile "$LINENO"
8935then :
bdcd5f22 8936 gl_cv_host_cpu_c_abi_32bit=yes
54445dc2 8937else $as_nop
bdcd5f22
TT
8938 gl_cv_host_cpu_c_abi_32bit=no
8939fi
54445dc2 8940rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
bdcd5f22
TT
8941 ;;
8942
8943 mips* )
8944 # We should also check for (_MIPS_SZPTR == 64), but gcc keeps this
8945 # at 32.
8946 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8947/* end confdefs.h. */
8948#if defined _MIPS_SZLONG && (_MIPS_SZLONG == 64)
8949 int ok;
8950 #else
8951 error fail
8952 #endif
8953
8954_ACEOF
54445dc2
TT
8955if ac_fn_c_try_compile "$LINENO"
8956then :
bdcd5f22 8957 gl_cv_host_cpu_c_abi_32bit=no
54445dc2 8958else $as_nop
bdcd5f22
TT
8959 gl_cv_host_cpu_c_abi_32bit=yes
8960fi
54445dc2 8961rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
bdcd5f22
TT
8962 ;;
8963
8964 powerpc* )
8965 # Different ABIs are in use on AIX vs. Mac OS X vs. Linux,*BSD.
8966 # No need to distinguish them here; the caller may distinguish
8967 # them based on the OS.
8968 # On powerpc64 systems, the C compiler may still be generating
8969 # 32-bit code. And on powerpc-ibm-aix systems, the C compiler may
8970 # be generating 64-bit code.
8971 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8972/* end confdefs.h. */
5598a968 8973#if defined __powerpc64__ || defined __LP64__
bdcd5f22
TT
8974 int ok;
8975 #else
8976 error fail
8977 #endif
8978
8979_ACEOF
54445dc2
TT
8980if ac_fn_c_try_compile "$LINENO"
8981then :
bdcd5f22 8982 gl_cv_host_cpu_c_abi_32bit=no
54445dc2 8983else $as_nop
bdcd5f22
TT
8984 gl_cv_host_cpu_c_abi_32bit=yes
8985fi
54445dc2 8986rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
bdcd5f22
TT
8987 ;;
8988
8989 rs6000 )
8990 gl_cv_host_cpu_c_abi_32bit=yes
8991 ;;
8992
8993 riscv32 | riscv64 )
8994 # There are 6 ABIs: ilp32, ilp32f, ilp32d, lp64, lp64f, lp64d.
8995 # Size of 'long' and 'void *':
8996 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8997/* end confdefs.h. */
8998#if defined __LP64__
8999 int ok;
9000 #else
9001 error fail
9002 #endif
9003
9004_ACEOF
54445dc2
TT
9005if ac_fn_c_try_compile "$LINENO"
9006then :
bdcd5f22 9007 gl_cv_host_cpu_c_abi_32bit=no
54445dc2 9008else $as_nop
bdcd5f22
TT
9009 gl_cv_host_cpu_c_abi_32bit=yes
9010fi
54445dc2 9011rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
bdcd5f22
TT
9012 ;;
9013
9014 s390* )
9015 # On s390x, the C compiler may be generating 64-bit (= s390x) code
9016 # or 31-bit (= s390) code.
9017 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9018/* end confdefs.h. */
9019#if defined __LP64__ || defined __s390x__
9020 int ok;
9021 #else
9022 error fail
9023 #endif
9024
9025_ACEOF
54445dc2
TT
9026if ac_fn_c_try_compile "$LINENO"
9027then :
bdcd5f22 9028 gl_cv_host_cpu_c_abi_32bit=no
54445dc2 9029else $as_nop
bdcd5f22
TT
9030 gl_cv_host_cpu_c_abi_32bit=yes
9031fi
54445dc2 9032rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
bdcd5f22
TT
9033 ;;
9034
9035 sparc | sparc64 )
9036 # UltraSPARCs running Linux have `uname -m` = "sparc64", but the
9037 # C compiler still generates 32-bit code.
9038 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9039/* end confdefs.h. */
9040#if defined __sparcv9 || defined __arch64__
9041 int ok;
9042 #else
9043 error fail
9044 #endif
9045
9046_ACEOF
54445dc2
TT
9047if ac_fn_c_try_compile "$LINENO"
9048then :
bdcd5f22 9049 gl_cv_host_cpu_c_abi_32bit=no
54445dc2 9050else $as_nop
bdcd5f22
TT
9051 gl_cv_host_cpu_c_abi_32bit=yes
9052fi
54445dc2 9053rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
bdcd5f22
TT
9054 ;;
9055
9056 *)
9057 gl_cv_host_cpu_c_abi_32bit=unknown
9058 ;;
9059 esac
9060 fi
9061
9062fi
54445dc2
TT
9063{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_host_cpu_c_abi_32bit" >&5
9064printf "%s\n" "$gl_cv_host_cpu_c_abi_32bit" >&6; }
bdcd5f22
TT
9065
9066 HOST_CPU_C_ABI_32BIT="$gl_cv_host_cpu_c_abi_32bit"
9067
9068
9069
9070
9071
54445dc2
TT
9072 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ELF binary format" >&5
9073printf %s "checking for ELF binary format... " >&6; }
9074if test ${gl_cv_elf+y}
9075then :
9076 printf %s "(cached) " >&6
9077else $as_nop
bdcd5f22
TT
9078 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9079/* end confdefs.h. */
5598a968 9080#if defined __ELF__ || (defined __linux__ && defined __EDG__)
bdcd5f22
TT
9081 Extensible Linking Format
9082 #endif
d1154eb4 9083
d1154eb4 9084_ACEOF
e598c29b 9085if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
54445dc2
TT
9086 $EGREP "Extensible Linking Format" >/dev/null 2>&1
9087then :
bdcd5f22 9088 gl_cv_elf=yes
54445dc2 9089else $as_nop
bdcd5f22 9090 gl_cv_elf=no
57aa50d4 9091fi
54445dc2 9092rm -rf conftest*
d1154eb4 9093
d1154eb4 9094
e598c29b 9095fi
54445dc2
TT
9096{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_elf" >&5
9097printf "%s\n" "$gl_cv_elf" >&6; }
5598a968 9098 if test $gl_cv_elf = yes; then
bdcd5f22
TT
9099 # Extract the ELF class of a file (5th byte) in decimal.
9100 # Cf. https://en.wikipedia.org/wiki/Executable_and_Linkable_Format#File_header
9101 if od -A x < /dev/null >/dev/null 2>/dev/null; then
9102 # Use POSIX od.
9103 func_elfclass ()
9104 {
9105 od -A n -t d1 -j 4 -N 1
9106 }
9107 else
9108 # Use BSD hexdump.
9109 func_elfclass ()
9110 {
9111 dd bs=1 count=1 skip=4 2>/dev/null | hexdump -e '1/1 "%3d "'
9112 echo
9113 }
9114 fi
5598a968
EB
9115 # Use 'expr', not 'test', to compare the values of func_elfclass, because on
9116 # Solaris 11 OpenIndiana and Solaris 11 OmniOS, the result is 001 or 002,
9117 # not 1 or 2.
bdcd5f22
TT
9118 case $HOST_CPU_C_ABI_32BIT in
9119 yes)
9120 # 32-bit ABI.
9121 acl_is_expected_elfclass ()
9122 {
5598a968 9123 expr "`func_elfclass | sed -e 's/[ ]//g'`" = 1 > /dev/null
bdcd5f22
TT
9124 }
9125 ;;
9126 no)
9127 # 64-bit ABI.
9128 acl_is_expected_elfclass ()
9129 {
5598a968 9130 expr "`func_elfclass | sed -e 's/[ ]//g'`" = 2 > /dev/null
bdcd5f22
TT
9131 }
9132 ;;
9133 *)
9134 # Unknown.
9135 acl_is_expected_elfclass ()
9136 {
9137 :
9138 }
9139 ;;
9140 esac
9141 else
9142 acl_is_expected_elfclass ()
9143 {
9144 :
9145 }
9146 fi
d1154eb4 9147
54445dc2
TT
9148 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for the common suffixes of directories in the library search path" >&5
9149printf %s "checking for the common suffixes of directories in the library search path... " >&6; }
9150if test ${acl_cv_libdirstems+y}
9151then :
9152 printf %s "(cached) " >&6
9153else $as_nop
bdcd5f22
TT
9154 acl_libdirstem=lib
9155 acl_libdirstem2=
9156 acl_libdirstem3=
9157 case "$host_os" in
9158 solaris*)
9159 if test $HOST_CPU_C_ABI_32BIT = no; then
9160 acl_libdirstem2=lib/64
9161 case "$host_cpu" in
9162 sparc*) acl_libdirstem3=lib/sparcv9 ;;
9163 i*86 | x86_64) acl_libdirstem3=lib/amd64 ;;
9164 esac
9165 fi
9166 ;;
9167 *)
9168 searchpath=`(LC_ALL=C $CC $CPPFLAGS $CFLAGS -print-search-dirs) 2>/dev/null \
9169 | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`
9170 if test $HOST_CPU_C_ABI_32BIT != no; then
9171 # 32-bit or unknown ABI.
9172 if test -d /usr/lib32; then
9173 acl_libdirstem2=lib32
9174 fi
9175 fi
9176 if test $HOST_CPU_C_ABI_32BIT != yes; then
9177 # 64-bit or unknown ABI.
9178 if test -d /usr/lib64; then
9179 acl_libdirstem3=lib64
9180 fi
9181 fi
9182 if test -n "$searchpath"; then
9183 acl_save_IFS="${IFS= }"; IFS=":"
9184 for searchdir in $searchpath; do
9185 if test -d "$searchdir"; then
9186 case "$searchdir" in
9187 */lib32/ | */lib32 ) acl_libdirstem2=lib32 ;;
9188 */lib64/ | */lib64 ) acl_libdirstem3=lib64 ;;
9189 */../ | */.. )
9190 # Better ignore directories of this form. They are misleading.
9191 ;;
9192 *) searchdir=`cd "$searchdir" && pwd`
9193 case "$searchdir" in
9194 */lib32 ) acl_libdirstem2=lib32 ;;
9195 */lib64 ) acl_libdirstem3=lib64 ;;
9196 esac ;;
9197 esac
9198 fi
9199 done
9200 IFS="$acl_save_IFS"
9201 if test $HOST_CPU_C_ABI_32BIT = yes; then
9202 # 32-bit ABI.
9203 acl_libdirstem3=
9204 fi
9205 if test $HOST_CPU_C_ABI_32BIT = no; then
9206 # 64-bit ABI.
9207 acl_libdirstem2=
9208 fi
9209 fi
9210 ;;
9211 esac
9212 test -n "$acl_libdirstem2" || acl_libdirstem2="$acl_libdirstem"
9213 test -n "$acl_libdirstem3" || acl_libdirstem3="$acl_libdirstem"
9214 acl_cv_libdirstems="$acl_libdirstem,$acl_libdirstem2,$acl_libdirstem3"
9215
9216fi
54445dc2
TT
9217{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $acl_cv_libdirstems" >&5
9218printf "%s\n" "$acl_cv_libdirstems" >&6; }
bdcd5f22
TT
9219 acl_libdirstem=`echo "$acl_cv_libdirstems" | sed -e 's/,.*//'`
9220 acl_libdirstem2=`echo "$acl_cv_libdirstems" | sed -e 's/^[^,]*,//' -e 's/,.*//'`
9221 acl_libdirstem3=`echo "$acl_cv_libdirstems" | sed -e 's/^[^,]*,[^,]*,//' -e 's/,.*//'`
d1154eb4 9222
d1154eb4 9223
b0cacab0
TT
9224
9225
9226
b0cacab0
TT
9227
9228
9229
57aa50d4 9230
57aa50d4 9231
b0cacab0 9232
e598c29b 9233 use_additional=yes
b0cacab0 9234
e598c29b
TT
9235 acl_save_prefix="$prefix"
9236 prefix="$acl_final_prefix"
9237 acl_save_exec_prefix="$exec_prefix"
9238 exec_prefix="$acl_final_exec_prefix"
57aa50d4 9239
e598c29b
TT
9240 eval additional_includedir=\"$includedir\"
9241 eval additional_libdir=\"$libdir\"
bdcd5f22
TT
9242 eval additional_libdir2=\"$exec_prefix/$acl_libdirstem2\"
9243 eval additional_libdir3=\"$exec_prefix/$acl_libdirstem3\"
57aa50d4 9244
e598c29b
TT
9245 exec_prefix="$acl_save_exec_prefix"
9246 prefix="$acl_save_prefix"
57aa50d4 9247
b0cacab0 9248
e598c29b 9249# Check whether --with-libiconv-prefix was given.
54445dc2
TT
9250if test ${with_libiconv_prefix+y}
9251then :
e598c29b
TT
9252 withval=$with_libiconv_prefix;
9253 if test "X$withval" = "Xno"; then
9254 use_additional=no
9255 else
9256 if test "X$withval" = "X"; then
57aa50d4 9257
e598c29b
TT
9258 acl_save_prefix="$prefix"
9259 prefix="$acl_final_prefix"
9260 acl_save_exec_prefix="$exec_prefix"
9261 exec_prefix="$acl_final_exec_prefix"
57aa50d4 9262
e598c29b
TT
9263 eval additional_includedir=\"$includedir\"
9264 eval additional_libdir=\"$libdir\"
bdcd5f22
TT
9265 eval additional_libdir2=\"$exec_prefix/$acl_libdirstem2\"
9266 eval additional_libdir3=\"$exec_prefix/$acl_libdirstem3\"
57aa50d4 9267
e598c29b
TT
9268 exec_prefix="$acl_save_exec_prefix"
9269 prefix="$acl_save_prefix"
b0cacab0 9270
e598c29b
TT
9271 else
9272 additional_includedir="$withval/include"
9273 additional_libdir="$withval/$acl_libdirstem"
bdcd5f22
TT
9274 additional_libdir2="$withval/$acl_libdirstem2"
9275 additional_libdir3="$withval/$acl_libdirstem3"
e598c29b
TT
9276 fi
9277 fi
d1154eb4
TT
9278
9279fi
e1052144 9280
bdcd5f22
TT
9281 if test "X$additional_libdir2" = "X$additional_libdir"; then
9282 additional_libdir2=
9283 fi
9284 if test "X$additional_libdir3" = "X$additional_libdir"; then
9285 additional_libdir3=
9286 fi
e598c29b
TT
9287 LIBICONV=
9288 LTLIBICONV=
9289 INCICONV=
9290 LIBICONV_PREFIX=
9291 HAVE_LIBICONV=
9292 rpathdirs=
9293 ltrpathdirs=
9294 names_already_handled=
9295 names_next_round='iconv '
9296 while test -n "$names_next_round"; do
9297 names_this_round="$names_next_round"
9298 names_next_round=
9299 for name in $names_this_round; do
9300 already_handled=
9301 for n in $names_already_handled; do
9302 if test "$n" = "$name"; then
9303 already_handled=yes
9304 break
9305 fi
9306 done
9307 if test -z "$already_handled"; then
9308 names_already_handled="$names_already_handled $name"
9309 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'`
9310 eval value=\"\$HAVE_LIB$uppername\"
9311 if test -n "$value"; then
9312 if test "$value" = yes; then
9313 eval value=\"\$LIB$uppername\"
9314 test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
9315 eval value=\"\$LTLIB$uppername\"
9316 test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
9317 else
9318 :
9319 fi
9320 else
9321 found_dir=
9322 found_la=
9323 found_so=
9324 found_a=
9325 eval libname=\"$acl_libname_spec\" # typically: libname=lib$name
9326 if test -n "$acl_shlibext"; then
9327 shrext=".$acl_shlibext" # typically: shrext=.so
9328 else
9329 shrext=
9330 fi
9331 if test $use_additional = yes; then
bdcd5f22
TT
9332 for additional_libdir_variable in additional_libdir additional_libdir2 additional_libdir3; do
9333 if test "X$found_dir" = "X"; then
9334 eval dir=\$$additional_libdir_variable
9335 if test -n "$dir"; then
9336 if test -n "$acl_shlibext"; then
9337 if test -f "$dir/$libname$shrext" && acl_is_expected_elfclass < "$dir/$libname$shrext"; then
9338 found_dir="$dir"
9339 found_so="$dir/$libname$shrext"
9340 else
9341 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
9342 ver=`(cd "$dir" && \
9343 for f in "$libname$shrext".*; do echo "$f"; done \
9344 | sed -e "s,^$libname$shrext\\\\.,," \
9345 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
9346 | sed 1q ) 2>/dev/null`
9347 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver" && acl_is_expected_elfclass < "$dir/$libname$shrext.$ver"; then
9348 found_dir="$dir"
9349 found_so="$dir/$libname$shrext.$ver"
9350 fi
9351 else
9352 eval library_names=\"$acl_library_names_spec\"
9353 for f in $library_names; do
9354 if test -f "$dir/$f" && acl_is_expected_elfclass < "$dir/$f"; then
9355 found_dir="$dir"
9356 found_so="$dir/$f"
9357 break
9358 fi
9359 done
9360 fi
9361 fi
e598c29b 9362 fi
bdcd5f22
TT
9363 if test "X$found_dir" = "X"; then
9364 if test -f "$dir/$libname.$acl_libext" && ${AR-ar} -p "$dir/$libname.$acl_libext" | acl_is_expected_elfclass; then
e598c29b 9365 found_dir="$dir"
bdcd5f22 9366 found_a="$dir/$libname.$acl_libext"
e598c29b 9367 fi
bdcd5f22
TT
9368 fi
9369 if test "X$found_dir" != "X"; then
9370 if test -f "$dir/$libname.la"; then
9371 found_la="$dir/$libname.la"
9372 fi
9373 fi
e598c29b
TT
9374 fi
9375 fi
bdcd5f22 9376 done
e598c29b
TT
9377 fi
9378 if test "X$found_dir" = "X"; then
9379 for x in $LDFLAGS $LTLIBICONV; do
07a0db15 9380
e598c29b
TT
9381 acl_save_prefix="$prefix"
9382 prefix="$acl_final_prefix"
9383 acl_save_exec_prefix="$exec_prefix"
9384 exec_prefix="$acl_final_exec_prefix"
9385 eval x=\"$x\"
9386 exec_prefix="$acl_save_exec_prefix"
9387 prefix="$acl_save_prefix"
50e1e10f 9388
e598c29b
TT
9389 case "$x" in
9390 -L*)
9391 dir=`echo "X$x" | sed -e 's/^X-L//'`
9392 if test -n "$acl_shlibext"; then
bdcd5f22 9393 if test -f "$dir/$libname$shrext" && acl_is_expected_elfclass < "$dir/$libname$shrext"; then
e598c29b
TT
9394 found_dir="$dir"
9395 found_so="$dir/$libname$shrext"
9396 else
9397 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
9398 ver=`(cd "$dir" && \
9399 for f in "$libname$shrext".*; do echo "$f"; done \
9400 | sed -e "s,^$libname$shrext\\\\.,," \
9401 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
9402 | sed 1q ) 2>/dev/null`
bdcd5f22 9403 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver" && acl_is_expected_elfclass < "$dir/$libname$shrext.$ver"; then
e598c29b
TT
9404 found_dir="$dir"
9405 found_so="$dir/$libname$shrext.$ver"
9406 fi
9407 else
9408 eval library_names=\"$acl_library_names_spec\"
9409 for f in $library_names; do
bdcd5f22 9410 if test -f "$dir/$f" && acl_is_expected_elfclass < "$dir/$f"; then
e598c29b
TT
9411 found_dir="$dir"
9412 found_so="$dir/$f"
9413 break
9414 fi
9415 done
9416 fi
9417 fi
9418 fi
9419 if test "X$found_dir" = "X"; then
bdcd5f22 9420 if test -f "$dir/$libname.$acl_libext" && ${AR-ar} -p "$dir/$libname.$acl_libext" | acl_is_expected_elfclass; then
e598c29b
TT
9421 found_dir="$dir"
9422 found_a="$dir/$libname.$acl_libext"
9423 fi
9424 fi
9425 if test "X$found_dir" != "X"; then
9426 if test -f "$dir/$libname.la"; then
9427 found_la="$dir/$libname.la"
9428 fi
9429 fi
9430 ;;
9431 esac
9432 if test "X$found_dir" != "X"; then
9433 break
9434 fi
9435 done
9436 fi
9437 if test "X$found_dir" != "X"; then
9438 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
9439 if test "X$found_so" != "X"; then
9440 if test "$enable_rpath" = no \
9441 || test "X$found_dir" = "X/usr/$acl_libdirstem" \
bdcd5f22
TT
9442 || test "X$found_dir" = "X/usr/$acl_libdirstem2" \
9443 || test "X$found_dir" = "X/usr/$acl_libdirstem3"; then
e598c29b
TT
9444 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
9445 else
9446 haveit=
9447 for x in $ltrpathdirs; do
9448 if test "X$x" = "X$found_dir"; then
9449 haveit=yes
9450 break
9451 fi
9452 done
9453 if test -z "$haveit"; then
9454 ltrpathdirs="$ltrpathdirs $found_dir"
9455 fi
9456 if test "$acl_hardcode_direct" = yes; then
9457 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
9458 else
9459 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
9460 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
9461 haveit=
9462 for x in $rpathdirs; do
9463 if test "X$x" = "X$found_dir"; then
9464 haveit=yes
9465 break
9466 fi
9467 done
9468 if test -z "$haveit"; then
9469 rpathdirs="$rpathdirs $found_dir"
9470 fi
9471 else
9472 haveit=
9473 for x in $LDFLAGS $LIBICONV; do
93613951 9474
e598c29b
TT
9475 acl_save_prefix="$prefix"
9476 prefix="$acl_final_prefix"
9477 acl_save_exec_prefix="$exec_prefix"
9478 exec_prefix="$acl_final_exec_prefix"
9479 eval x=\"$x\"
9480 exec_prefix="$acl_save_exec_prefix"
9481 prefix="$acl_save_prefix"
b0cacab0 9482
e598c29b
TT
9483 if test "X$x" = "X-L$found_dir"; then
9484 haveit=yes
9485 break
9486 fi
9487 done
9488 if test -z "$haveit"; then
9489 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
9490 fi
9491 if test "$acl_hardcode_minus_L" != no; then
9492 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
9493 else
9494 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
9495 fi
9496 fi
9497 fi
9498 fi
9499 else
9500 if test "X$found_a" != "X"; then
9501 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
9502 else
9503 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
9504 fi
9505 fi
9506 additional_includedir=
9507 case "$found_dir" in
9508 */$acl_libdirstem | */$acl_libdirstem/)
9509 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
9510 if test "$name" = 'iconv'; then
9511 LIBICONV_PREFIX="$basedir"
9512 fi
9513 additional_includedir="$basedir/include"
9514 ;;
9515 */$acl_libdirstem2 | */$acl_libdirstem2/)
9516 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
9517 if test "$name" = 'iconv'; then
9518 LIBICONV_PREFIX="$basedir"
9519 fi
9520 additional_includedir="$basedir/include"
9521 ;;
bdcd5f22
TT
9522 */$acl_libdirstem3 | */$acl_libdirstem3/)
9523 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem3/"'*$,,'`
9524 if test "$name" = 'iconv'; then
9525 LIBICONV_PREFIX="$basedir"
9526 fi
9527 additional_includedir="$basedir/include"
9528 ;;
e598c29b
TT
9529 esac
9530 if test "X$additional_includedir" != "X"; then
9531 if test "X$additional_includedir" != "X/usr/include"; then
9532 haveit=
9533 if test "X$additional_includedir" = "X/usr/local/include"; then
9534 if test -n "$GCC"; then
9535 case $host_os in
9536 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
9537 esac
9538 fi
9539 fi
9540 if test -z "$haveit"; then
9541 for x in $CPPFLAGS $INCICONV; do
93613951 9542
e598c29b
TT
9543 acl_save_prefix="$prefix"
9544 prefix="$acl_final_prefix"
9545 acl_save_exec_prefix="$exec_prefix"
9546 exec_prefix="$acl_final_exec_prefix"
9547 eval x=\"$x\"
9548 exec_prefix="$acl_save_exec_prefix"
9549 prefix="$acl_save_prefix"
93613951 9550
e598c29b
TT
9551 if test "X$x" = "X-I$additional_includedir"; then
9552 haveit=yes
9553 break
9554 fi
9555 done
9556 if test -z "$haveit"; then
9557 if test -d "$additional_includedir"; then
9558 INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
9559 fi
9560 fi
9561 fi
9562 fi
9563 fi
9564 if test -n "$found_la"; then
9565 save_libdir="$libdir"
9566 case "$found_la" in
9567 */* | *\\*) . "$found_la" ;;
9568 *) . "./$found_la" ;;
9569 esac
9570 libdir="$save_libdir"
9571 for dep in $dependency_libs; do
9572 case "$dep" in
9573 -L*)
bdcd5f22
TT
9574 dependency_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
9575 if test "X$dependency_libdir" != "X/usr/$acl_libdirstem" \
9576 && test "X$dependency_libdir" != "X/usr/$acl_libdirstem2" \
9577 && test "X$dependency_libdir" != "X/usr/$acl_libdirstem3"; then
e598c29b 9578 haveit=
bdcd5f22
TT
9579 if test "X$dependency_libdir" = "X/usr/local/$acl_libdirstem" \
9580 || test "X$dependency_libdir" = "X/usr/local/$acl_libdirstem2" \
9581 || test "X$dependency_libdir" = "X/usr/local/$acl_libdirstem3"; then
e598c29b
TT
9582 if test -n "$GCC"; then
9583 case $host_os in
9584 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
9585 esac
9586 fi
9587 fi
9588 if test -z "$haveit"; then
9589 haveit=
9590 for x in $LDFLAGS $LIBICONV; do
b0cacab0 9591
e598c29b
TT
9592 acl_save_prefix="$prefix"
9593 prefix="$acl_final_prefix"
9594 acl_save_exec_prefix="$exec_prefix"
9595 exec_prefix="$acl_final_exec_prefix"
9596 eval x=\"$x\"
9597 exec_prefix="$acl_save_exec_prefix"
9598 prefix="$acl_save_prefix"
50e1e10f 9599
bdcd5f22 9600 if test "X$x" = "X-L$dependency_libdir"; then
e598c29b
TT
9601 haveit=yes
9602 break
9603 fi
9604 done
9605 if test -z "$haveit"; then
bdcd5f22
TT
9606 if test -d "$dependency_libdir"; then
9607 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$dependency_libdir"
e598c29b
TT
9608 fi
9609 fi
9610 haveit=
9611 for x in $LDFLAGS $LTLIBICONV; do
e1052144 9612
e598c29b
TT
9613 acl_save_prefix="$prefix"
9614 prefix="$acl_final_prefix"
9615 acl_save_exec_prefix="$exec_prefix"
9616 exec_prefix="$acl_final_exec_prefix"
9617 eval x=\"$x\"
9618 exec_prefix="$acl_save_exec_prefix"
9619 prefix="$acl_save_prefix"
9620
bdcd5f22 9621 if test "X$x" = "X-L$dependency_libdir"; then
e598c29b
TT
9622 haveit=yes
9623 break
9624 fi
9625 done
9626 if test -z "$haveit"; then
bdcd5f22
TT
9627 if test -d "$dependency_libdir"; then
9628 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$dependency_libdir"
e598c29b
TT
9629 fi
9630 fi
9631 fi
9632 fi
9633 ;;
9634 -R*)
9635 dir=`echo "X$dep" | sed -e 's/^X-R//'`
9636 if test "$enable_rpath" != no; then
9637 haveit=
9638 for x in $rpathdirs; do
9639 if test "X$x" = "X$dir"; then
9640 haveit=yes
9641 break
9642 fi
9643 done
9644 if test -z "$haveit"; then
9645 rpathdirs="$rpathdirs $dir"
9646 fi
9647 haveit=
9648 for x in $ltrpathdirs; do
9649 if test "X$x" = "X$dir"; then
9650 haveit=yes
9651 break
9652 fi
9653 done
9654 if test -z "$haveit"; then
9655 ltrpathdirs="$ltrpathdirs $dir"
9656 fi
9657 fi
9658 ;;
9659 -l*)
5598a968
EB
9660 dep=`echo "X$dep" | sed -e 's/^X-l//'`
9661 if test "X$dep" != Xc \
9662 || case $host_os in
9663 linux* | gnu* | k*bsd*-gnu) false ;;
9664 *) true ;;
9665 esac; then
9666 names_next_round="$names_next_round $dep"
9667 fi
e598c29b
TT
9668 ;;
9669 *.la)
9670 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
9671 ;;
9672 *)
9673 LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
9674 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
9675 ;;
9676 esac
9677 done
9678 fi
9679 else
9680 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
9681 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
9682 fi
9683 fi
9684 fi
9685 done
93613951 9686 done
e598c29b
TT
9687 if test "X$rpathdirs" != "X"; then
9688 if test -n "$acl_hardcode_libdir_separator"; then
9689 alldirs=
9690 for found_dir in $rpathdirs; do
9691 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
9692 done
9693 acl_save_libdir="$libdir"
9694 libdir="$alldirs"
9695 eval flag=\"$acl_hardcode_libdir_flag_spec\"
9696 libdir="$acl_save_libdir"
9697 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
9698 else
9699 for found_dir in $rpathdirs; do
9700 acl_save_libdir="$libdir"
9701 libdir="$found_dir"
9702 eval flag=\"$acl_hardcode_libdir_flag_spec\"
9703 libdir="$acl_save_libdir"
9704 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
9705 done
9706 fi
9707 fi
9708 if test "X$ltrpathdirs" != "X"; then
9709 for found_dir in $ltrpathdirs; do
9710 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
9711 done
9712 fi
b0cacab0 9713
93613951 9714
93613951 9715
57aa50d4
TT
9716
9717
9718
9719
9720
9721
9722
9723
9724
9725
9726
b0cacab0 9727
740837de 9728
b0cacab0
TT
9729
9730
9731
93613951
TT
9732
9733
9734
9735
9736
9737
9738
93613951
TT
9739
9740
9741
54445dc2
TT
9742 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
9743printf %s "checking for CFPreferencesCopyAppValue... " >&6; }
9744if test ${gt_cv_func_CFPreferencesCopyAppValue+y}
9745then :
9746 printf %s "(cached) " >&6
9747else $as_nop
93613951
TT
9748 gt_save_LIBS="$LIBS"
9749 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
9750 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9751/* end confdefs.h. */
9752#include <CoreFoundation/CFPreferences.h>
9753int
54445dc2 9754main (void)
93613951
TT
9755{
9756CFPreferencesCopyAppValue(NULL, NULL)
9757 ;
9758 return 0;
9759}
9760_ACEOF
54445dc2
TT
9761if ac_fn_c_try_link "$LINENO"
9762then :
93613951 9763 gt_cv_func_CFPreferencesCopyAppValue=yes
54445dc2 9764else $as_nop
93613951 9765 gt_cv_func_CFPreferencesCopyAppValue=no
50e1e10f 9766fi
54445dc2 9767rm -f core conftest.err conftest.$ac_objext conftest.beam \
93613951
TT
9768 conftest$ac_exeext conftest.$ac_ext
9769 LIBS="$gt_save_LIBS"
50e1e10f 9770fi
54445dc2
TT
9771{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
9772printf "%s\n" "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
93613951
TT
9773 if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
9774
54445dc2 9775printf "%s\n" "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
93613951
TT
9776
9777 fi
54445dc2
TT
9778 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyPreferredLanguages" >&5
9779printf %s "checking for CFLocaleCopyPreferredLanguages... " >&6; }
9780if test ${gt_cv_func_CFLocaleCopyPreferredLanguages+y}
9781then :
9782 printf %s "(cached) " >&6
9783else $as_nop
93613951
TT
9784 gt_save_LIBS="$LIBS"
9785 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
9786 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9787/* end confdefs.h. */
9788#include <CoreFoundation/CFLocale.h>
9789int
54445dc2 9790main (void)
93613951 9791{
bdcd5f22 9792CFLocaleCopyPreferredLanguages();
93613951
TT
9793 ;
9794 return 0;
9795}
9796_ACEOF
54445dc2
TT
9797if ac_fn_c_try_link "$LINENO"
9798then :
bdcd5f22 9799 gt_cv_func_CFLocaleCopyPreferredLanguages=yes
54445dc2 9800else $as_nop
bdcd5f22 9801 gt_cv_func_CFLocaleCopyPreferredLanguages=no
93613951 9802fi
54445dc2 9803rm -f core conftest.err conftest.$ac_objext conftest.beam \
93613951
TT
9804 conftest$ac_exeext conftest.$ac_ext
9805 LIBS="$gt_save_LIBS"
9806fi
54445dc2
TT
9807{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyPreferredLanguages" >&5
9808printf "%s\n" "$gt_cv_func_CFLocaleCopyPreferredLanguages" >&6; }
bdcd5f22 9809 if test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
93613951 9810
54445dc2 9811printf "%s\n" "#define HAVE_CFLOCALECOPYPREFERREDLANGUAGES 1" >>confdefs.h
93613951
TT
9812
9813 fi
9814 INTL_MACOSX_LIBS=
bdcd5f22
TT
9815 if test $gt_cv_func_CFPreferencesCopyAppValue = yes \
9816 || test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
93613951
TT
9817 INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation"
9818 fi
9819
50e1e10f 9820
b0cacab0
TT
9821
9822
9823
9824
57aa50d4
TT
9825 LIBINTL=
9826 LTLIBINTL=
9827 POSUB=
9828
93613951
TT
9829 case " $gt_needs " in
9830 *" need-formatstring-macros "*) gt_api_version=3 ;;
9831 *" need-ngettext "*) gt_api_version=2 ;;
9832 *) gt_api_version=1 ;;
9833 esac
9834 gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
9835 gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
9836
57aa50d4
TT
9837 if test "$USE_NLS" = "yes"; then
9838 gt_use_preinstalled_gnugettext=no
b0cacab0
TT
9839
9840
e598c29b
TT
9841 if test $gt_api_version -ge 3; then
9842 gt_revision_test_code='
9843#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
9844#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
9845#endif
9846typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
9847'
9848 else
9849 gt_revision_test_code=
9850 fi
9851 if test $gt_api_version -ge 2; then
9852 gt_expression_test_code=' + * ngettext ("", "", 0)'
9853 else
9854 gt_expression_test_code=
9855 fi
9856
54445dc2
TT
9857 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5
9858printf %s "checking for GNU gettext in libc... " >&6; }
9859if eval test \${$gt_func_gnugettext_libc+y}
9860then :
9861 printf %s "(cached) " >&6
9862else $as_nop
e598c29b
TT
9863 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9864/* end confdefs.h. */
9865
9866#include <libintl.h>
9867#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
9868extern int _nl_msg_cat_cntr;
9869extern int *_nl_domain_bindings;
9870#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_domain_bindings)
9871#else
9872#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
9873#endif
9874$gt_revision_test_code
9875
9876int
54445dc2 9877main (void)
e598c29b
TT
9878{
9879
9880bindtextdomain ("", "");
9881return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
9882
9883 ;
9884 return 0;
9885}
9886_ACEOF
54445dc2
TT
9887if ac_fn_c_try_link "$LINENO"
9888then :
e598c29b 9889 eval "$gt_func_gnugettext_libc=yes"
54445dc2 9890else $as_nop
e598c29b
TT
9891 eval "$gt_func_gnugettext_libc=no"
9892fi
54445dc2 9893rm -f core conftest.err conftest.$ac_objext conftest.beam \
e598c29b 9894 conftest$ac_exeext conftest.$ac_ext
50e1e10f 9895fi
e598c29b 9896eval ac_res=\$$gt_func_gnugettext_libc
54445dc2
TT
9897 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
9898printf "%s\n" "$ac_res" >&6; }
50e1e10f 9899
e598c29b
TT
9900 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
9901
9902
9903
9904
9905
9906 am_save_CPPFLAGS="$CPPFLAGS"
9907
9908 for element in $INCICONV; do
9909 haveit=
9910 for x in $CPPFLAGS; do
9911
9912 acl_save_prefix="$prefix"
9913 prefix="$acl_final_prefix"
9914 acl_save_exec_prefix="$exec_prefix"
9915 exec_prefix="$acl_final_exec_prefix"
9916 eval x=\"$x\"
9917 exec_prefix="$acl_save_exec_prefix"
9918 prefix="$acl_save_prefix"
9919
9920 if test "X$x" = "X$element"; then
9921 haveit=yes
9922 break
9923 fi
9924 done
9925 if test -z "$haveit"; then
9926 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
9927 fi
9928 done
9929
9930
54445dc2
TT
9931 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
9932printf %s "checking for iconv... " >&6; }
9933if test ${am_cv_func_iconv+y}
9934then :
9935 printf %s "(cached) " >&6
9936else $as_nop
e598c29b
TT
9937
9938 am_cv_func_iconv="no, consider installing GNU libiconv"
9939 am_cv_lib_iconv=no
9940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9941/* end confdefs.h. */
9942
9943#include <stdlib.h>
9944#include <iconv.h>
b0cacab0 9945
e598c29b 9946int
54445dc2 9947main (void)
e598c29b
TT
9948{
9949iconv_t cd = iconv_open("","");
9950 iconv(cd,NULL,NULL,NULL,NULL);
9951 iconv_close(cd);
9952 ;
9953 return 0;
9954}
9955_ACEOF
54445dc2
TT
9956if ac_fn_c_try_link "$LINENO"
9957then :
e598c29b
TT
9958 am_cv_func_iconv=yes
9959fi
54445dc2 9960rm -f core conftest.err conftest.$ac_objext conftest.beam \
e598c29b
TT
9961 conftest$ac_exeext conftest.$ac_ext
9962 if test "$am_cv_func_iconv" != yes; then
9963 am_save_LIBS="$LIBS"
9964 LIBS="$LIBS $LIBICONV"
9965 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9966/* end confdefs.h. */
b0cacab0 9967
e598c29b
TT
9968#include <stdlib.h>
9969#include <iconv.h>
b0cacab0 9970
e598c29b 9971int
54445dc2 9972main (void)
e598c29b
TT
9973{
9974iconv_t cd = iconv_open("","");
9975 iconv(cd,NULL,NULL,NULL,NULL);
9976 iconv_close(cd);
9977 ;
9978 return 0;
9979}
9980_ACEOF
54445dc2
TT
9981if ac_fn_c_try_link "$LINENO"
9982then :
e598c29b
TT
9983 am_cv_lib_iconv=yes
9984 am_cv_func_iconv=yes
9985fi
54445dc2 9986rm -f core conftest.err conftest.$ac_objext conftest.beam \
e598c29b
TT
9987 conftest$ac_exeext conftest.$ac_ext
9988 LIBS="$am_save_LIBS"
9989 fi
b0cacab0 9990
e598c29b 9991fi
54445dc2
TT
9992{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
9993printf "%s\n" "$am_cv_func_iconv" >&6; }
e598c29b 9994 if test "$am_cv_func_iconv" = yes; then
54445dc2
TT
9995 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
9996printf %s "checking for working iconv... " >&6; }
9997if test ${am_cv_func_iconv_works+y}
9998then :
9999 printf %s "(cached) " >&6
10000else $as_nop
e598c29b
TT
10001
10002 am_save_LIBS="$LIBS"
10003 if test $am_cv_lib_iconv = yes; then
10004 LIBS="$LIBS $LIBICONV"
10005 fi
10006 am_cv_func_iconv_works=no
10007 for ac_iconv_const in '' 'const'; do
54445dc2
TT
10008 if test "$cross_compiling" = yes
10009then :
e598c29b
TT
10010 case "$host_os" in
10011 aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
10012 *) am_cv_func_iconv_works="guessing yes" ;;
10013 esac
54445dc2 10014else $as_nop
57aa50d4
TT
10015 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10016/* end confdefs.h. */
93613951 10017
e598c29b
TT
10018#include <iconv.h>
10019#include <string.h>
10020
10021#ifndef ICONV_CONST
10022# define ICONV_CONST $ac_iconv_const
10023#endif
93613951 10024
57aa50d4 10025int
54445dc2 10026main (void)
57aa50d4 10027{
e598c29b 10028int result = 0;
5598a968
EB
10029 /* Test against AIX 5.1...7.2 bug: Failures are not distinguishable from
10030 successful returns. This is even documented in
10031 <https://www.ibm.com/support/knowledgecenter/ssw_aix_72/i_bostechref/iconv.html> */
e598c29b
TT
10032 {
10033 iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
10034 if (cd_utf8_to_88591 != (iconv_t)(-1))
10035 {
10036 static ICONV_CONST char input[] = "\342\202\254"; /* EURO SIGN */
10037 char buf[10];
10038 ICONV_CONST char *inptr = input;
10039 size_t inbytesleft = strlen (input);
10040 char *outptr = buf;
10041 size_t outbytesleft = sizeof (buf);
10042 size_t res = iconv (cd_utf8_to_88591,
10043 &inptr, &inbytesleft,
10044 &outptr, &outbytesleft);
10045 if (res == 0)
10046 result |= 1;
10047 iconv_close (cd_utf8_to_88591);
10048 }
10049 }
10050 /* Test against Solaris 10 bug: Failures are not distinguishable from
10051 successful returns. */
10052 {
10053 iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
10054 if (cd_ascii_to_88591 != (iconv_t)(-1))
10055 {
10056 static ICONV_CONST char input[] = "\263";
10057 char buf[10];
10058 ICONV_CONST char *inptr = input;
10059 size_t inbytesleft = strlen (input);
10060 char *outptr = buf;
10061 size_t outbytesleft = sizeof (buf);
10062 size_t res = iconv (cd_ascii_to_88591,
10063 &inptr, &inbytesleft,
10064 &outptr, &outbytesleft);
10065 if (res == 0)
10066 result |= 2;
10067 iconv_close (cd_ascii_to_88591);
10068 }
10069 }
10070 /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
10071 {
10072 iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
10073 if (cd_88591_to_utf8 != (iconv_t)(-1))
10074 {
10075 static ICONV_CONST char input[] = "\304";
10076 static char buf[2] = { (char)0xDE, (char)0xAD };
10077 ICONV_CONST char *inptr = input;
10078 size_t inbytesleft = 1;
10079 char *outptr = buf;
10080 size_t outbytesleft = 1;
10081 size_t res = iconv (cd_88591_to_utf8,
10082 &inptr, &inbytesleft,
10083 &outptr, &outbytesleft);
10084 if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
10085 result |= 4;
10086 iconv_close (cd_88591_to_utf8);
10087 }
10088 }
10089#if 0 /* This bug could be worked around by the caller. */
10090 /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
10091 {
10092 iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
10093 if (cd_88591_to_utf8 != (iconv_t)(-1))
10094 {
10095 static ICONV_CONST char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
10096 char buf[50];
10097 ICONV_CONST char *inptr = input;
10098 size_t inbytesleft = strlen (input);
10099 char *outptr = buf;
10100 size_t outbytesleft = sizeof (buf);
10101 size_t res = iconv (cd_88591_to_utf8,
10102 &inptr, &inbytesleft,
10103 &outptr, &outbytesleft);
10104 if ((int)res > 0)
10105 result |= 8;
10106 iconv_close (cd_88591_to_utf8);
10107 }
10108 }
10109#endif
10110 /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
10111 provided. */
bdcd5f22
TT
10112 {
10113 /* Try standardized names. */
10114 iconv_t cd1 = iconv_open ("UTF-8", "EUC-JP");
10115 /* Try IRIX, OSF/1 names. */
10116 iconv_t cd2 = iconv_open ("UTF-8", "eucJP");
10117 /* Try AIX names. */
10118 iconv_t cd3 = iconv_open ("UTF-8", "IBM-eucJP");
10119 /* Try HP-UX names. */
10120 iconv_t cd4 = iconv_open ("utf8", "eucJP");
10121 if (cd1 == (iconv_t)(-1) && cd2 == (iconv_t)(-1)
10122 && cd3 == (iconv_t)(-1) && cd4 == (iconv_t)(-1))
10123 result |= 16;
10124 if (cd1 != (iconv_t)(-1))
10125 iconv_close (cd1);
10126 if (cd2 != (iconv_t)(-1))
10127 iconv_close (cd2);
10128 if (cd3 != (iconv_t)(-1))
10129 iconv_close (cd3);
10130 if (cd4 != (iconv_t)(-1))
10131 iconv_close (cd4);
10132 }
e598c29b 10133 return result;
93613951 10134
57aa50d4
TT
10135 ;
10136 return 0;
10137}
10138_ACEOF
54445dc2
TT
10139if ac_fn_c_try_run "$LINENO"
10140then :
e598c29b 10141 am_cv_func_iconv_works=yes
57aa50d4 10142fi
e598c29b
TT
10143rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10144 conftest.$ac_objext conftest.beam conftest.$ac_ext
57aa50d4 10145fi
93613951 10146
e598c29b
TT
10147 test "$am_cv_func_iconv_works" = no || break
10148 done
10149 LIBS="$am_save_LIBS"
10150
10151fi
54445dc2
TT
10152{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
10153printf "%s\n" "$am_cv_func_iconv_works" >&6; }
e598c29b
TT
10154 case "$am_cv_func_iconv_works" in
10155 *no) am_func_iconv=no am_cv_lib_iconv=no ;;
10156 *) am_func_iconv=yes ;;
10157 esac
10158 else
10159 am_func_iconv=no am_cv_lib_iconv=no
10160 fi
10161 if test "$am_func_iconv" = yes; then
10162
54445dc2 10163printf "%s\n" "#define HAVE_ICONV 1" >>confdefs.h
e598c29b
TT
10164
10165 fi
10166 if test "$am_cv_lib_iconv" = yes; then
54445dc2
TT
10167 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
10168printf %s "checking how to link with libiconv... " >&6; }
10169 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
10170printf "%s\n" "$LIBICONV" >&6; }
e598c29b
TT
10171 else
10172 CPPFLAGS="$am_save_CPPFLAGS"
10173 LIBICONV=
10174 LTLIBICONV=
10175 fi
10176
10177
10178
93613951
TT
10179
10180
10181
10182
b0cacab0
TT
10183
10184
10185
57aa50d4 10186 use_additional=yes
b0cacab0 10187
57aa50d4
TT
10188 acl_save_prefix="$prefix"
10189 prefix="$acl_final_prefix"
10190 acl_save_exec_prefix="$exec_prefix"
10191 exec_prefix="$acl_final_exec_prefix"
b0cacab0 10192
57aa50d4
TT
10193 eval additional_includedir=\"$includedir\"
10194 eval additional_libdir=\"$libdir\"
bdcd5f22
TT
10195 eval additional_libdir2=\"$exec_prefix/$acl_libdirstem2\"
10196 eval additional_libdir3=\"$exec_prefix/$acl_libdirstem3\"
b0cacab0 10197
57aa50d4
TT
10198 exec_prefix="$acl_save_exec_prefix"
10199 prefix="$acl_save_prefix"
b0cacab0
TT
10200
10201
57aa50d4 10202# Check whether --with-libintl-prefix was given.
54445dc2
TT
10203if test ${with_libintl_prefix+y}
10204then :
57aa50d4
TT
10205 withval=$with_libintl_prefix;
10206 if test "X$withval" = "Xno"; then
10207 use_additional=no
10208 else
10209 if test "X$withval" = "X"; then
b0cacab0 10210
57aa50d4
TT
10211 acl_save_prefix="$prefix"
10212 prefix="$acl_final_prefix"
10213 acl_save_exec_prefix="$exec_prefix"
10214 exec_prefix="$acl_final_exec_prefix"
b0cacab0 10215
57aa50d4
TT
10216 eval additional_includedir=\"$includedir\"
10217 eval additional_libdir=\"$libdir\"
bdcd5f22
TT
10218 eval additional_libdir2=\"$exec_prefix/$acl_libdirstem2\"
10219 eval additional_libdir3=\"$exec_prefix/$acl_libdirstem3\"
7321d94e 10220
57aa50d4
TT
10221 exec_prefix="$acl_save_exec_prefix"
10222 prefix="$acl_save_prefix"
7321d94e 10223
57aa50d4
TT
10224 else
10225 additional_includedir="$withval/include"
93613951 10226 additional_libdir="$withval/$acl_libdirstem"
bdcd5f22
TT
10227 additional_libdir2="$withval/$acl_libdirstem2"
10228 additional_libdir3="$withval/$acl_libdirstem3"
57aa50d4
TT
10229 fi
10230 fi
7321d94e 10231
7321d94e
MK
10232fi
10233
bdcd5f22
TT
10234 if test "X$additional_libdir2" = "X$additional_libdir"; then
10235 additional_libdir2=
10236 fi
10237 if test "X$additional_libdir3" = "X$additional_libdir"; then
10238 additional_libdir3=
10239 fi
57aa50d4
TT
10240 LIBINTL=
10241 LTLIBINTL=
10242 INCINTL=
93613951
TT
10243 LIBINTL_PREFIX=
10244 HAVE_LIBINTL=
57aa50d4
TT
10245 rpathdirs=
10246 ltrpathdirs=
10247 names_already_handled=
10248 names_next_round='intl '
10249 while test -n "$names_next_round"; do
10250 names_this_round="$names_next_round"
10251 names_next_round=
10252 for name in $names_this_round; do
10253 already_handled=
10254 for n in $names_already_handled; do
10255 if test "$n" = "$name"; then
10256 already_handled=yes
10257 break
10258 fi
50e1e10f 10259 done
57aa50d4
TT
10260 if test -z "$already_handled"; then
10261 names_already_handled="$names_already_handled $name"
93613951 10262 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'`
57aa50d4
TT
10263 eval value=\"\$HAVE_LIB$uppername\"
10264 if test -n "$value"; then
10265 if test "$value" = yes; then
10266 eval value=\"\$LIB$uppername\"
10267 test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value"
10268 eval value=\"\$LTLIB$uppername\"
10269 test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value"
10270 else
10271 :
10272 fi
10273 else
10274 found_dir=
10275 found_la=
10276 found_so=
10277 found_a=
93613951
TT
10278 eval libname=\"$acl_libname_spec\" # typically: libname=lib$name
10279 if test -n "$acl_shlibext"; then
10280 shrext=".$acl_shlibext" # typically: shrext=.so
10281 else
10282 shrext=
10283 fi
57aa50d4 10284 if test $use_additional = yes; then
bdcd5f22
TT
10285 for additional_libdir_variable in additional_libdir additional_libdir2 additional_libdir3; do
10286 if test "X$found_dir" = "X"; then
10287 eval dir=\$$additional_libdir_variable
10288 if test -n "$dir"; then
10289 if test -n "$acl_shlibext"; then
10290 if test -f "$dir/$libname$shrext" && acl_is_expected_elfclass < "$dir/$libname$shrext"; then
10291 found_dir="$dir"
10292 found_so="$dir/$libname$shrext"
10293 else
10294 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
10295 ver=`(cd "$dir" && \
10296 for f in "$libname$shrext".*; do echo "$f"; done \
10297 | sed -e "s,^$libname$shrext\\\\.,," \
10298 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
10299 | sed 1q ) 2>/dev/null`
10300 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver" && acl_is_expected_elfclass < "$dir/$libname$shrext.$ver"; then
10301 found_dir="$dir"
10302 found_so="$dir/$libname$shrext.$ver"
10303 fi
10304 else
10305 eval library_names=\"$acl_library_names_spec\"
10306 for f in $library_names; do
10307 if test -f "$dir/$f" && acl_is_expected_elfclass < "$dir/$f"; then
10308 found_dir="$dir"
10309 found_so="$dir/$f"
10310 break
10311 fi
10312 done
10313 fi
10314 fi
93613951 10315 fi
bdcd5f22
TT
10316 if test "X$found_dir" = "X"; then
10317 if test -f "$dir/$libname.$acl_libext" && ${AR-ar} -p "$dir/$libname.$acl_libext" | acl_is_expected_elfclass; then
93613951 10318 found_dir="$dir"
bdcd5f22 10319 found_a="$dir/$libname.$acl_libext"
93613951 10320 fi
bdcd5f22
TT
10321 fi
10322 if test "X$found_dir" != "X"; then
10323 if test -f "$dir/$libname.la"; then
10324 found_la="$dir/$libname.la"
10325 fi
10326 fi
57aa50d4
TT
10327 fi
10328 fi
bdcd5f22 10329 done
57aa50d4
TT
10330 fi
10331 if test "X$found_dir" = "X"; then
10332 for x in $LDFLAGS $LTLIBINTL; do
39fd3d4f 10333
57aa50d4
TT
10334 acl_save_prefix="$prefix"
10335 prefix="$acl_final_prefix"
10336 acl_save_exec_prefix="$exec_prefix"
10337 exec_prefix="$acl_final_exec_prefix"
10338 eval x=\"$x\"
10339 exec_prefix="$acl_save_exec_prefix"
10340 prefix="$acl_save_prefix"
3d05802f 10341
57aa50d4
TT
10342 case "$x" in
10343 -L*)
10344 dir=`echo "X$x" | sed -e 's/^X-L//'`
93613951 10345 if test -n "$acl_shlibext"; then
bdcd5f22 10346 if test -f "$dir/$libname$shrext" && acl_is_expected_elfclass < "$dir/$libname$shrext"; then
57aa50d4 10347 found_dir="$dir"
93613951
TT
10348 found_so="$dir/$libname$shrext"
10349 else
10350 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
10351 ver=`(cd "$dir" && \
10352 for f in "$libname$shrext".*; do echo "$f"; done \
10353 | sed -e "s,^$libname$shrext\\\\.,," \
10354 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
10355 | sed 1q ) 2>/dev/null`
bdcd5f22 10356 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver" && acl_is_expected_elfclass < "$dir/$libname$shrext.$ver"; then
93613951
TT
10357 found_dir="$dir"
10358 found_so="$dir/$libname$shrext.$ver"
10359 fi
10360 else
10361 eval library_names=\"$acl_library_names_spec\"
10362 for f in $library_names; do
bdcd5f22 10363 if test -f "$dir/$f" && acl_is_expected_elfclass < "$dir/$f"; then
93613951
TT
10364 found_dir="$dir"
10365 found_so="$dir/$f"
10366 break
10367 fi
10368 done
57aa50d4
TT
10369 fi
10370 fi
93613951
TT
10371 fi
10372 if test "X$found_dir" = "X"; then
bdcd5f22 10373 if test -f "$dir/$libname.$acl_libext" && ${AR-ar} -p "$dir/$libname.$acl_libext" | acl_is_expected_elfclass; then
93613951
TT
10374 found_dir="$dir"
10375 found_a="$dir/$libname.$acl_libext"
10376 fi
10377 fi
10378 if test "X$found_dir" != "X"; then
10379 if test -f "$dir/$libname.la"; then
10380 found_la="$dir/$libname.la"
10381 fi
57aa50d4
TT
10382 fi
10383 ;;
10384 esac
10385 if test "X$found_dir" != "X"; then
10386 break
10387 fi
10388 done
10389 fi
10390 if test "X$found_dir" != "X"; then
10391 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
10392 if test "X$found_so" != "X"; then
93613951
TT
10393 if test "$enable_rpath" = no \
10394 || test "X$found_dir" = "X/usr/$acl_libdirstem" \
bdcd5f22
TT
10395 || test "X$found_dir" = "X/usr/$acl_libdirstem2" \
10396 || test "X$found_dir" = "X/usr/$acl_libdirstem3"; then
57aa50d4
TT
10397 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
10398 else
10399 haveit=
10400 for x in $ltrpathdirs; do
10401 if test "X$x" = "X$found_dir"; then
10402 haveit=yes
10403 break
10404 fi
10405 done
10406 if test -z "$haveit"; then
10407 ltrpathdirs="$ltrpathdirs $found_dir"
10408 fi
93613951 10409 if test "$acl_hardcode_direct" = yes; then
57aa50d4
TT
10410 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
10411 else
93613951 10412 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
57aa50d4
TT
10413 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
10414 haveit=
10415 for x in $rpathdirs; do
10416 if test "X$x" = "X$found_dir"; then
10417 haveit=yes
10418 break
10419 fi
10420 done
10421 if test -z "$haveit"; then
10422 rpathdirs="$rpathdirs $found_dir"
10423 fi
10424 else
10425 haveit=
10426 for x in $LDFLAGS $LIBINTL; do
6ec9ef18 10427
57aa50d4
TT
10428 acl_save_prefix="$prefix"
10429 prefix="$acl_final_prefix"
10430 acl_save_exec_prefix="$exec_prefix"
10431 exec_prefix="$acl_final_exec_prefix"
10432 eval x=\"$x\"
10433 exec_prefix="$acl_save_exec_prefix"
10434 prefix="$acl_save_prefix"
d7f45af8 10435
57aa50d4
TT
10436 if test "X$x" = "X-L$found_dir"; then
10437 haveit=yes
10438 break
10439 fi
10440 done
10441 if test -z "$haveit"; then
10442 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir"
10443 fi
93613951 10444 if test "$acl_hardcode_minus_L" != no; then
57aa50d4
TT
10445 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
10446 else
10447 LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
10448 fi
10449 fi
10450 fi
10451 fi
10452 else
10453 if test "X$found_a" != "X"; then
10454 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a"
10455 else
10456 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name"
10457 fi
10458 fi
10459 additional_includedir=
10460 case "$found_dir" in
93613951
TT
10461 */$acl_libdirstem | */$acl_libdirstem/)
10462 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
10463 if test "$name" = 'intl'; then
10464 LIBINTL_PREFIX="$basedir"
10465 fi
10466 additional_includedir="$basedir/include"
10467 ;;
10468 */$acl_libdirstem2 | */$acl_libdirstem2/)
10469 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
10470 if test "$name" = 'intl'; then
10471 LIBINTL_PREFIX="$basedir"
10472 fi
57aa50d4
TT
10473 additional_includedir="$basedir/include"
10474 ;;
bdcd5f22
TT
10475 */$acl_libdirstem3 | */$acl_libdirstem3/)
10476 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem3/"'*$,,'`
10477 if test "$name" = 'intl'; then
10478 LIBINTL_PREFIX="$basedir"
10479 fi
10480 additional_includedir="$basedir/include"
10481 ;;
57aa50d4
TT
10482 esac
10483 if test "X$additional_includedir" != "X"; then
10484 if test "X$additional_includedir" != "X/usr/include"; then
10485 haveit=
10486 if test "X$additional_includedir" = "X/usr/local/include"; then
10487 if test -n "$GCC"; then
10488 case $host_os in
93613951 10489 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
57aa50d4
TT
10490 esac
10491 fi
10492 fi
10493 if test -z "$haveit"; then
10494 for x in $CPPFLAGS $INCINTL; do
b0cacab0 10495
57aa50d4
TT
10496 acl_save_prefix="$prefix"
10497 prefix="$acl_final_prefix"
10498 acl_save_exec_prefix="$exec_prefix"
10499 exec_prefix="$acl_final_exec_prefix"
10500 eval x=\"$x\"
10501 exec_prefix="$acl_save_exec_prefix"
10502 prefix="$acl_save_prefix"
21c84b71 10503
57aa50d4
TT
10504 if test "X$x" = "X-I$additional_includedir"; then
10505 haveit=yes
10506 break
10507 fi
10508 done
10509 if test -z "$haveit"; then
10510 if test -d "$additional_includedir"; then
10511 INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir"
10512 fi
10513 fi
10514 fi
10515 fi
10516 fi
10517 if test -n "$found_la"; then
10518 save_libdir="$libdir"
10519 case "$found_la" in
10520 */* | *\\*) . "$found_la" ;;
10521 *) . "./$found_la" ;;
10522 esac
10523 libdir="$save_libdir"
10524 for dep in $dependency_libs; do
10525 case "$dep" in
10526 -L*)
bdcd5f22
TT
10527 dependency_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
10528 if test "X$dependency_libdir" != "X/usr/$acl_libdirstem" \
10529 && test "X$dependency_libdir" != "X/usr/$acl_libdirstem2" \
10530 && test "X$dependency_libdir" != "X/usr/$acl_libdirstem3"; then
57aa50d4 10531 haveit=
bdcd5f22
TT
10532 if test "X$dependency_libdir" = "X/usr/local/$acl_libdirstem" \
10533 || test "X$dependency_libdir" = "X/usr/local/$acl_libdirstem2" \
10534 || test "X$dependency_libdir" = "X/usr/local/$acl_libdirstem3"; then
57aa50d4
TT
10535 if test -n "$GCC"; then
10536 case $host_os in
93613951 10537 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
57aa50d4
TT
10538 esac
10539 fi
10540 fi
10541 if test -z "$haveit"; then
10542 haveit=
10543 for x in $LDFLAGS $LIBINTL; do
50e1e10f 10544
57aa50d4
TT
10545 acl_save_prefix="$prefix"
10546 prefix="$acl_final_prefix"
10547 acl_save_exec_prefix="$exec_prefix"
10548 exec_prefix="$acl_final_exec_prefix"
10549 eval x=\"$x\"
10550 exec_prefix="$acl_save_exec_prefix"
10551 prefix="$acl_save_prefix"
50e1e10f 10552
bdcd5f22 10553 if test "X$x" = "X-L$dependency_libdir"; then
57aa50d4
TT
10554 haveit=yes
10555 break
10556 fi
10557 done
10558 if test -z "$haveit"; then
bdcd5f22
TT
10559 if test -d "$dependency_libdir"; then
10560 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$dependency_libdir"
57aa50d4
TT
10561 fi
10562 fi
10563 haveit=
10564 for x in $LDFLAGS $LTLIBINTL; do
a4bf69d9 10565
57aa50d4
TT
10566 acl_save_prefix="$prefix"
10567 prefix="$acl_final_prefix"
10568 acl_save_exec_prefix="$exec_prefix"
10569 exec_prefix="$acl_final_exec_prefix"
10570 eval x=\"$x\"
10571 exec_prefix="$acl_save_exec_prefix"
10572 prefix="$acl_save_prefix"
50e1e10f 10573
bdcd5f22 10574 if test "X$x" = "X-L$dependency_libdir"; then
57aa50d4
TT
10575 haveit=yes
10576 break
10577 fi
10578 done
10579 if test -z "$haveit"; then
bdcd5f22
TT
10580 if test -d "$dependency_libdir"; then
10581 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$dependency_libdir"
57aa50d4
TT
10582 fi
10583 fi
10584 fi
10585 fi
10586 ;;
10587 -R*)
10588 dir=`echo "X$dep" | sed -e 's/^X-R//'`
10589 if test "$enable_rpath" != no; then
10590 haveit=
10591 for x in $rpathdirs; do
10592 if test "X$x" = "X$dir"; then
10593 haveit=yes
10594 break
10595 fi
10596 done
10597 if test -z "$haveit"; then
10598 rpathdirs="$rpathdirs $dir"
10599 fi
10600 haveit=
10601 for x in $ltrpathdirs; do
10602 if test "X$x" = "X$dir"; then
10603 haveit=yes
10604 break
10605 fi
10606 done
10607 if test -z "$haveit"; then
10608 ltrpathdirs="$ltrpathdirs $dir"
10609 fi
10610 fi
10611 ;;
10612 -l*)
5598a968
EB
10613 dep=`echo "X$dep" | sed -e 's/^X-l//'`
10614 if test "X$dep" != Xc \
10615 || case $host_os in
10616 linux* | gnu* | k*bsd*-gnu) false ;;
10617 *) true ;;
10618 esac; then
10619 names_next_round="$names_next_round $dep"
10620 fi
57aa50d4
TT
10621 ;;
10622 *.la)
10623 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
10624 ;;
10625 *)
10626 LIBINTL="${LIBINTL}${LIBINTL:+ }$dep"
10627 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep"
10628 ;;
10629 esac
10630 done
10631 fi
10632 else
10633 LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
10634 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name"
10635 fi
10636 fi
10637 fi
10638 done
10639 done
10640 if test "X$rpathdirs" != "X"; then
93613951 10641 if test -n "$acl_hardcode_libdir_separator"; then
57aa50d4
TT
10642 alldirs=
10643 for found_dir in $rpathdirs; do
93613951 10644 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
57aa50d4
TT
10645 done
10646 acl_save_libdir="$libdir"
10647 libdir="$alldirs"
93613951 10648 eval flag=\"$acl_hardcode_libdir_flag_spec\"
57aa50d4
TT
10649 libdir="$acl_save_libdir"
10650 LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
10651 else
10652 for found_dir in $rpathdirs; do
10653 acl_save_libdir="$libdir"
10654 libdir="$found_dir"
93613951 10655 eval flag=\"$acl_hardcode_libdir_flag_spec\"
57aa50d4
TT
10656 libdir="$acl_save_libdir"
10657 LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
10658 done
10659 fi
10660 fi
10661 if test "X$ltrpathdirs" != "X"; then
10662 for found_dir in $ltrpathdirs; do
10663 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir"
10664 done
10665 fi
b0cacab0 10666
93613951
TT
10667
10668
10669
10670
54445dc2
TT
10671 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5
10672printf %s "checking for GNU gettext in libintl... " >&6; }
10673if eval test \${$gt_func_gnugettext_libintl+y}
10674then :
10675 printf %s "(cached) " >&6
10676else $as_nop
57aa50d4
TT
10677 gt_save_CPPFLAGS="$CPPFLAGS"
10678 CPPFLAGS="$CPPFLAGS $INCINTL"
10679 gt_save_LIBS="$LIBS"
10680 LIBS="$LIBS $LIBINTL"
10681 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10682/* end confdefs.h. */
93613951 10683
57aa50d4 10684#include <libintl.h>
e598c29b 10685#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
57aa50d4
TT
10686extern int _nl_msg_cat_cntr;
10687extern
10688#ifdef __cplusplus
10689"C"
10690#endif
93613951 10691const char *_nl_expand_alias (const char *);
e598c29b
TT
10692#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
10693#else
10694#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
10695#endif
10696$gt_revision_test_code
93613951 10697
57aa50d4 10698int
54445dc2 10699main (void)
57aa50d4 10700{
93613951 10701
57aa50d4 10702bindtextdomain ("", "");
e598c29b 10703return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
93613951 10704
57aa50d4
TT
10705 ;
10706 return 0;
10707}
b0cacab0 10708_ACEOF
54445dc2
TT
10709if ac_fn_c_try_link "$LINENO"
10710then :
93613951 10711 eval "$gt_func_gnugettext_libintl=yes"
54445dc2 10712else $as_nop
93613951 10713 eval "$gt_func_gnugettext_libintl=no"
6c133523 10714fi
54445dc2 10715rm -f core conftest.err conftest.$ac_objext conftest.beam \
57aa50d4 10716 conftest$ac_exeext conftest.$ac_ext
93613951 10717 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
57aa50d4
TT
10718 LIBS="$LIBS $LIBICONV"
10719 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
da76d6b7 10720/* end confdefs.h. */
93613951 10721
57aa50d4 10722#include <libintl.h>
e598c29b 10723#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
57aa50d4
TT
10724extern int _nl_msg_cat_cntr;
10725extern
10726#ifdef __cplusplus
10727"C"
da76d6b7 10728#endif
93613951 10729const char *_nl_expand_alias (const char *);
e598c29b
TT
10730#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
10731#else
10732#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
10733#endif
10734$gt_revision_test_code
93613951 10735
57aa50d4 10736int
54445dc2 10737main (void)
57aa50d4 10738{
93613951 10739
57aa50d4 10740bindtextdomain ("", "");
e598c29b 10741return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
93613951 10742
57aa50d4
TT
10743 ;
10744 return 0;
10745}
da76d6b7 10746_ACEOF
54445dc2
TT
10747if ac_fn_c_try_link "$LINENO"
10748then :
57aa50d4 10749 LIBINTL="$LIBINTL $LIBICONV"
93613951
TT
10750 LTLIBINTL="$LTLIBINTL $LTLIBICONV"
10751 eval "$gt_func_gnugettext_libintl=yes"
6c133523
TT
10752
10753fi
54445dc2 10754rm -f core conftest.err conftest.$ac_objext conftest.beam \
57aa50d4
TT
10755 conftest$ac_exeext conftest.$ac_ext
10756 fi
10757 CPPFLAGS="$gt_save_CPPFLAGS"
10758 LIBS="$gt_save_LIBS"
da76d6b7 10759fi
93613951 10760eval ac_res=\$$gt_func_gnugettext_libintl
54445dc2
TT
10761 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10762printf "%s\n" "$ac_res" >&6; }
57aa50d4 10763 fi
b0cacab0 10764
93613951
TT
10765 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
10766 || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
57aa50d4
TT
10767 && test "$PACKAGE" != gettext-runtime \
10768 && test "$PACKAGE" != gettext-tools; }; then
10769 gt_use_preinstalled_gnugettext=yes
10770 else
10771 LIBINTL=
10772 LTLIBINTL=
10773 INCINTL=
10774 fi
740837de 10775
b0cacab0 10776
b0cacab0 10777
93613951
TT
10778 if test -n "$INTL_MACOSX_LIBS"; then
10779 if test "$gt_use_preinstalled_gnugettext" = "yes" \
10780 || test "$nls_cv_use_gnu_gettext" = "yes"; then
10781 LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
10782 LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
10783 fi
10784 fi
10785
57aa50d4
TT
10786 if test "$gt_use_preinstalled_gnugettext" = "yes" \
10787 || test "$nls_cv_use_gnu_gettext" = "yes"; then
b0cacab0 10788
54445dc2 10789printf "%s\n" "#define ENABLE_NLS 1" >>confdefs.h
b0cacab0 10790
57aa50d4
TT
10791 else
10792 USE_NLS=no
10793 fi
10794 fi
b0cacab0 10795
54445dc2
TT
10796 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5
10797printf %s "checking whether to use NLS... " >&6; }
10798 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
10799printf "%s\n" "$USE_NLS" >&6; }
57aa50d4 10800 if test "$USE_NLS" = "yes"; then
54445dc2
TT
10801 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5
10802printf %s "checking where the gettext function comes from... " >&6; }
57aa50d4 10803 if test "$gt_use_preinstalled_gnugettext" = "yes"; then
93613951 10804 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
57aa50d4
TT
10805 gt_source="external libintl"
10806 else
10807 gt_source="libc"
10808 fi
10809 else
10810 gt_source="included intl directory"
10811 fi
54445dc2
TT
10812 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5
10813printf "%s\n" "$gt_source" >&6; }
57aa50d4 10814 fi
b0cacab0 10815
57aa50d4 10816 if test "$USE_NLS" = "yes"; then
b0cacab0 10817
57aa50d4 10818 if test "$gt_use_preinstalled_gnugettext" = "yes"; then
93613951 10819 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
54445dc2
TT
10820 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5
10821printf %s "checking how to link with libintl... " >&6; }
10822 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5
10823printf "%s\n" "$LIBINTL" >&6; }
b0cacab0 10824
57aa50d4
TT
10825 for element in $INCINTL; do
10826 haveit=
10827 for x in $CPPFLAGS; do
b0cacab0 10828
57aa50d4
TT
10829 acl_save_prefix="$prefix"
10830 prefix="$acl_final_prefix"
10831 acl_save_exec_prefix="$exec_prefix"
10832 exec_prefix="$acl_final_exec_prefix"
10833 eval x=\"$x\"
10834 exec_prefix="$acl_save_exec_prefix"
10835 prefix="$acl_save_prefix"
b0cacab0 10836
57aa50d4
TT
10837 if test "X$x" = "X$element"; then
10838 haveit=yes
10839 break
10840 fi
10841 done
10842 if test -z "$haveit"; then
10843 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
10844 fi
10845 done
b0cacab0 10846
57aa50d4 10847 fi
b0cacab0
TT
10848
10849
54445dc2 10850printf "%s\n" "#define HAVE_GETTEXT 1" >>confdefs.h
b0cacab0
TT
10851
10852
54445dc2 10853printf "%s\n" "#define HAVE_DCGETTEXT 1" >>confdefs.h
b0cacab0 10854
57aa50d4 10855 fi
b0cacab0 10856
57aa50d4
TT
10857 POSUB=po
10858 fi
b0cacab0
TT
10859
10860
b0cacab0 10861
57aa50d4 10862 INTLLIBS="$LIBINTL"
e1052144 10863
b0cacab0 10864
93636bde 10865
93636bde 10866
b0cacab0 10867
93636bde 10868
50e1e10f 10869
54445dc2
TT
10870{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
10871printf %s "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
57aa50d4 10872set x ${MAKE-make}
54445dc2
TT
10873ac_make=`printf "%s\n" "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
10874if eval test \${ac_cv_prog_make_${ac_make}_set+y}
10875then :
10876 printf %s "(cached) " >&6
10877else $as_nop
57aa50d4
TT
10878 cat >conftest.make <<\_ACEOF
10879SHELL = /bin/sh
10880all:
10881 @echo '@@@%%%=$(MAKE)=@@@%%%'
b0cacab0 10882_ACEOF
d6a4bcb5 10883# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
57aa50d4
TT
10884case `${MAKE-make} -f conftest.make 2>/dev/null` in
10885 *@@@%%%=?*=@@@%%%*)
10886 eval ac_cv_prog_make_${ac_make}_set=yes;;
10887 *)
10888 eval ac_cv_prog_make_${ac_make}_set=no;;
e1052144 10889esac
57aa50d4 10890rm -f conftest.make
b0cacab0 10891fi
57aa50d4 10892if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
54445dc2
TT
10893 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10894printf "%s\n" "yes" >&6; }
57aa50d4 10895 SET_MAKE=
b0b9c4de 10896else
54445dc2
TT
10897 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
10898printf "%s\n" "no" >&6; }
57aa50d4 10899 SET_MAKE="MAKE=${MAKE-make}"
b0cacab0 10900fi
b0cacab0 10901
54445dc2
TT
10902 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU make" >&5
10903printf %s "checking for GNU make... " >&6; }
10904if test ${_cv_gnu_make_command+y}
10905then :
10906 printf %s "(cached) " >&6
10907else $as_nop
57aa50d4 10908 _cv_gnu_make_command='' ;
e703ba4b 10909 if test -n "$FORCE_NATIVE_MAKE" ; then
f3bc1561
TT
10910 MAKES="make"
10911 else
10912 MAKES="make gmake gnumake"
10913 fi
10914 for a in "$MAKE" $MAKES ; do
57aa50d4
TT
10915 if test -z "$a" ; then continue ; fi ;
10916 if ( sh -c "$a --version" 2> /dev/null | grep GNU 2>&1 > /dev/null ) ; then
10917 _cv_gnu_make_command=$a ;
10918 break;
10919 fi
10920 done ;
50e1e10f 10921
50e1e10f 10922fi
54445dc2
TT
10923{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $_cv_gnu_make_command" >&5
10924printf "%s\n" "$_cv_gnu_make_command" >&6; } ;
57aa50d4
TT
10925 if test "x$_cv_gnu_make_command" != "x" ; then
10926 ifGNUmake='' ;
10927 ifNotGNUmake='#' ;
10928 else
10929 ifGNUmake='#' ;
10930 ifNotGNUmake='' ;
54445dc2
TT
10931 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: \"Not found\"" >&5
10932printf "%s\n" "\"Not found\"" >&6; };
57aa50d4 10933 fi
50e1e10f 10934
50e1e10f 10935
b0cacab0 10936
57aa50d4
TT
10937# Extract the first word of "ln", so it can be a program name with args.
10938set dummy ln; ac_word=$2
54445dc2
TT
10939{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10940printf %s "checking for $ac_word... " >&6; }
10941if test ${ac_cv_path_LN+y}
10942then :
10943 printf %s "(cached) " >&6
10944else $as_nop
57aa50d4
TT
10945 case $LN in
10946 [\\/]* | ?:[\\/]*)
10947 ac_cv_path_LN="$LN" # Let the user override the test with a path.
10948 ;;
10949 *)
10950 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10951for as_dir in $PATH
10952do
10953 IFS=$as_save_IFS
54445dc2
TT
10954 case $as_dir in #(((
10955 '') as_dir=./ ;;
10956 */) ;;
10957 *) as_dir=$as_dir/ ;;
10958 esac
57aa50d4 10959 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
10960 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
10961 ac_cv_path_LN="$as_dir$ac_word$ac_exec_ext"
10962 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
10963 break 2
10964 fi
10965done
10966 done
10967IFS=$as_save_IFS
6c65d251 10968
57aa50d4
TT
10969 test -z "$ac_cv_path_LN" && ac_cv_path_LN="ln"
10970 ;;
e1052144 10971esac
fff45483 10972fi
57aa50d4
TT
10973LN=$ac_cv_path_LN
10974if test -n "$LN"; then
54445dc2
TT
10975 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
10976printf "%s\n" "$LN" >&6; }
57aa50d4 10977else
54445dc2
TT
10978 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
10979printf "%s\n" "no" >&6; }
fff45483 10980fi
e1052144 10981
fff45483 10982
5abc0414 10983
3fb16e74
TT
10984mkdir_p=$MKDIR_P
10985
54445dc2
TT
10986{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
10987printf %s "checking whether ln -s works... " >&6; }
57aa50d4
TT
10988LN_S=$as_ln_s
10989if test "$LN_S" = "ln -s"; then
54445dc2
TT
10990 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10991printf "%s\n" "yes" >&6; }
57aa50d4 10992else
54445dc2
TT
10993 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
10994printf "%s\n" "no, using $LN_S" >&6; }
fff45483 10995fi
6c65d251 10996
57aa50d4
TT
10997# Extract the first word of "mv", so it can be a program name with args.
10998set dummy mv; ac_word=$2
54445dc2
TT
10999{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11000printf %s "checking for $ac_word... " >&6; }
11001if test ${ac_cv_path_MV+y}
11002then :
11003 printf %s "(cached) " >&6
11004else $as_nop
57aa50d4
TT
11005 case $MV in
11006 [\\/]* | ?:[\\/]*)
11007 ac_cv_path_MV="$MV" # Let the user override the test with a path.
11008 ;;
11009 *)
11010 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11011for as_dir in $PATH
11012do
11013 IFS=$as_save_IFS
54445dc2
TT
11014 case $as_dir in #(((
11015 '') as_dir=./ ;;
11016 */) ;;
11017 *) as_dir=$as_dir/ ;;
11018 esac
57aa50d4 11019 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
11020 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
11021 ac_cv_path_MV="$as_dir$ac_word$ac_exec_ext"
11022 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
11023 break 2
11024 fi
11025done
11026 done
11027IFS=$as_save_IFS
6c65d251 11028
57aa50d4
TT
11029 test -z "$ac_cv_path_MV" && ac_cv_path_MV="mv"
11030 ;;
e1052144 11031esac
b0cacab0 11032fi
57aa50d4
TT
11033MV=$ac_cv_path_MV
11034if test -n "$MV"; then
54445dc2
TT
11035 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MV" >&5
11036printf "%s\n" "$MV" >&6; }
b0b9c4de 11037else
54445dc2
TT
11038 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11039printf "%s\n" "no" >&6; }
39fd3d4f
SJR
11040fi
11041
39fd3d4f 11042
57aa50d4
TT
11043# Extract the first word of "cp", so it can be a program name with args.
11044set dummy cp; ac_word=$2
54445dc2
TT
11045{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11046printf %s "checking for $ac_word... " >&6; }
11047if test ${ac_cv_path_CP+y}
11048then :
11049 printf %s "(cached) " >&6
11050else $as_nop
57aa50d4
TT
11051 case $CP in
11052 [\\/]* | ?:[\\/]*)
11053 ac_cv_path_CP="$CP" # Let the user override the test with a path.
11054 ;;
11055 *)
11056 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11057for as_dir in $PATH
11058do
11059 IFS=$as_save_IFS
54445dc2
TT
11060 case $as_dir in #(((
11061 '') as_dir=./ ;;
11062 */) ;;
11063 *) as_dir=$as_dir/ ;;
11064 esac
57aa50d4 11065 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
11066 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
11067 ac_cv_path_CP="$as_dir$ac_word$ac_exec_ext"
11068 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
11069 break 2
11070 fi
11071done
11072 done
11073IFS=$as_save_IFS
39fd3d4f 11074
57aa50d4
TT
11075 test -z "$ac_cv_path_CP" && ac_cv_path_CP="cp"
11076 ;;
e1052144 11077esac
b0b9c4de 11078fi
57aa50d4
TT
11079CP=$ac_cv_path_CP
11080if test -n "$CP"; then
54445dc2
TT
11081 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CP" >&5
11082printf "%s\n" "$CP" >&6; }
b0cacab0 11083else
54445dc2
TT
11084 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11085printf "%s\n" "no" >&6; }
b0b9c4de 11086fi
b0b9c4de 11087
6c65d251 11088
57aa50d4
TT
11089# Extract the first word of "rm", so it can be a program name with args.
11090set dummy rm; ac_word=$2
54445dc2
TT
11091{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11092printf %s "checking for $ac_word... " >&6; }
11093if test ${ac_cv_path_RM+y}
11094then :
11095 printf %s "(cached) " >&6
11096else $as_nop
57aa50d4
TT
11097 case $RM in
11098 [\\/]* | ?:[\\/]*)
11099 ac_cv_path_RM="$RM" # Let the user override the test with a path.
11100 ;;
11101 *)
11102 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11103for as_dir in $PATH
11104do
11105 IFS=$as_save_IFS
54445dc2
TT
11106 case $as_dir in #(((
11107 '') as_dir=./ ;;
11108 */) ;;
11109 *) as_dir=$as_dir/ ;;
11110 esac
57aa50d4 11111 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
11112 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
11113 ac_cv_path_RM="$as_dir$ac_word$ac_exec_ext"
11114 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
11115 break 2
11116 fi
11117done
b0cacab0 11118 done
57aa50d4 11119IFS=$as_save_IFS
6c65d251 11120
57aa50d4
TT
11121 test -z "$ac_cv_path_RM" && ac_cv_path_RM="rm"
11122 ;;
e1052144 11123esac
6928adc9 11124fi
57aa50d4
TT
11125RM=$ac_cv_path_RM
11126if test -n "$RM"; then
54445dc2
TT
11127 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $RM" >&5
11128printf "%s\n" "$RM" >&6; }
b0cacab0 11129else
54445dc2
TT
11130 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11131printf "%s\n" "no" >&6; }
6928adc9 11132fi
6928adc9 11133
6c65d251 11134
57aa50d4
TT
11135# Extract the first word of "chmod", so it can be a program name with args.
11136set dummy chmod; ac_word=$2
54445dc2
TT
11137{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11138printf %s "checking for $ac_word... " >&6; }
11139if test ${ac_cv_path_CHMOD+y}
11140then :
11141 printf %s "(cached) " >&6
11142else $as_nop
57aa50d4
TT
11143 case $CHMOD in
11144 [\\/]* | ?:[\\/]*)
11145 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
11146 ;;
11147 *)
11148 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11149for as_dir in $PATH
11150do
11151 IFS=$as_save_IFS
54445dc2
TT
11152 case $as_dir in #(((
11153 '') as_dir=./ ;;
11154 */) ;;
11155 *) as_dir=$as_dir/ ;;
11156 esac
57aa50d4 11157 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
11158 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
11159 ac_cv_path_CHMOD="$as_dir$ac_word$ac_exec_ext"
11160 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
11161 break 2
11162 fi
11163done
11164 done
11165IFS=$as_save_IFS
39fd3d4f 11166
57aa50d4
TT
11167 test -z "$ac_cv_path_CHMOD" && ac_cv_path_CHMOD=":"
11168 ;;
e1052144 11169esac
b0cacab0 11170fi
57aa50d4
TT
11171CHMOD=$ac_cv_path_CHMOD
11172if test -n "$CHMOD"; then
54445dc2
TT
11173 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5
11174printf "%s\n" "$CHMOD" >&6; }
b0cacab0 11175else
54445dc2
TT
11176 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11177printf "%s\n" "no" >&6; }
b0cacab0 11178fi
39fd3d4f 11179
b0cacab0 11180
57aa50d4
TT
11181for ac_prog in gawk mawk nawk awk
11182do
11183 # Extract the first word of "$ac_prog", so it can be a program name with args.
11184set dummy $ac_prog; ac_word=$2
54445dc2
TT
11185{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11186printf %s "checking for $ac_word... " >&6; }
11187if test ${ac_cv_prog_AWK+y}
11188then :
11189 printf %s "(cached) " >&6
11190else $as_nop
57aa50d4
TT
11191 if test -n "$AWK"; then
11192 ac_cv_prog_AWK="$AWK" # Let the user override the test.
b0cacab0 11193else
57aa50d4
TT
11194as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11195for as_dir in $PATH
11196do
11197 IFS=$as_save_IFS
54445dc2
TT
11198 case $as_dir in #(((
11199 '') as_dir=./ ;;
11200 */) ;;
11201 *) as_dir=$as_dir/ ;;
11202 esac
57aa50d4 11203 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 11204 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 11205 ac_cv_prog_AWK="$ac_prog"
54445dc2 11206 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
11207 break 2
11208 fi
11209done
11210 done
11211IFS=$as_save_IFS
b0cacab0 11212
b0cacab0 11213fi
57aa50d4
TT
11214fi
11215AWK=$ac_cv_prog_AWK
11216if test -n "$AWK"; then
54445dc2
TT
11217 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
11218printf "%s\n" "$AWK" >&6; }
b0cacab0 11219else
54445dc2
TT
11220 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11221printf "%s\n" "no" >&6; }
b0cacab0 11222fi
b0cacab0 11223
b0cacab0 11224
57aa50d4
TT
11225 test -n "$AWK" && break
11226done
b0cacab0 11227
54445dc2
TT
11228{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
11229printf %s "checking for egrep... " >&6; }
11230if test ${ac_cv_path_EGREP+y}
11231then :
11232 printf %s "(cached) " >&6
11233else $as_nop
57aa50d4
TT
11234 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
11235 then ac_cv_path_EGREP="$GREP -E"
11236 else
11237 if test -z "$EGREP"; then
11238 ac_path_EGREP_found=false
11239 # Loop through the user's path and test for each of PROGNAME-LIST
11240 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11241for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11242do
11243 IFS=$as_save_IFS
54445dc2
TT
11244 case $as_dir in #(((
11245 '') as_dir=./ ;;
11246 */) ;;
11247 *) as_dir=$as_dir/ ;;
11248 esac
11249 for ac_prog in egrep
11250 do
57aa50d4 11251 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 11252 ac_path_EGREP="$as_dir$ac_prog$ac_exec_ext"
d6a4bcb5 11253 as_fn_executable_p "$ac_path_EGREP" || continue
57aa50d4
TT
11254# Check for GNU ac_path_EGREP and select it if it is found.
11255 # Check for GNU $ac_path_EGREP
11256case `"$ac_path_EGREP" --version 2>&1` in
11257*GNU*)
11258 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
11259*)
11260 ac_count=0
54445dc2 11261 printf %s 0123456789 >"conftest.in"
57aa50d4
TT
11262 while :
11263 do
11264 cat "conftest.in" "conftest.in" >"conftest.tmp"
11265 mv "conftest.tmp" "conftest.in"
11266 cp "conftest.in" "conftest.nl"
54445dc2 11267 printf "%s\n" 'EGREP' >> "conftest.nl"
57aa50d4
TT
11268 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11269 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11270 as_fn_arith $ac_count + 1 && ac_count=$as_val
11271 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
11272 # Best one so far, save it but keep looking for a better one
11273 ac_cv_path_EGREP="$ac_path_EGREP"
11274 ac_path_EGREP_max=$ac_count
11275 fi
11276 # 10*(2^10) chars as input seems more than enough
11277 test $ac_count -gt 10 && break
11278 done
11279 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
e1052144 11280esac
e1052144 11281
57aa50d4
TT
11282 $ac_path_EGREP_found && break 3
11283 done
b0cacab0 11284 done
57aa50d4
TT
11285 done
11286IFS=$as_save_IFS
11287 if test -z "$ac_cv_path_EGREP"; then
d6a4bcb5 11288 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
57aa50d4 11289 fi
b0cacab0 11290else
57aa50d4 11291 ac_cv_path_EGREP=$EGREP
b0cacab0 11292fi
e1052144 11293
57aa50d4 11294 fi
b0cacab0 11295fi
54445dc2
TT
11296{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
11297printf "%s\n" "$ac_cv_path_EGREP" >&6; }
57aa50d4 11298 EGREP="$ac_cv_path_EGREP"
e1052144 11299
b0cacab0 11300
57aa50d4
TT
11301# Extract the first word of "sed", so it can be a program name with args.
11302set dummy sed; ac_word=$2
54445dc2
TT
11303{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11304printf %s "checking for $ac_word... " >&6; }
11305if test ${ac_cv_path_SED+y}
11306then :
11307 printf %s "(cached) " >&6
11308else $as_nop
57aa50d4
TT
11309 case $SED in
11310 [\\/]* | ?:[\\/]*)
11311 ac_cv_path_SED="$SED" # Let the user override the test with a path.
11312 ;;
11313 *)
11314 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11315for as_dir in $PATH
11316do
11317 IFS=$as_save_IFS
54445dc2
TT
11318 case $as_dir in #(((
11319 '') as_dir=./ ;;
11320 */) ;;
11321 *) as_dir=$as_dir/ ;;
11322 esac
57aa50d4 11323 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
11324 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
11325 ac_cv_path_SED="$as_dir$ac_word$ac_exec_ext"
11326 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
11327 break 2
11328 fi
b0cacab0 11329done
57aa50d4
TT
11330 done
11331IFS=$as_save_IFS
b0cacab0 11332
57aa50d4
TT
11333 test -z "$ac_cv_path_SED" && ac_cv_path_SED="sed"
11334 ;;
b0cacab0 11335esac
57aa50d4
TT
11336fi
11337SED=$ac_cv_path_SED
11338if test -n "$SED"; then
54445dc2
TT
11339 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $SED" >&5
11340printf "%s\n" "$SED" >&6; }
b0cacab0 11341else
54445dc2
TT
11342 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11343printf "%s\n" "no" >&6; }
b0cacab0 11344fi
e1052144 11345
b0cacab0 11346
57aa50d4
TT
11347# Extract the first word of "perl", so it can be a program name with args.
11348set dummy perl; ac_word=$2
54445dc2
TT
11349{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11350printf %s "checking for $ac_word... " >&6; }
11351if test ${ac_cv_path_PERL+y}
11352then :
11353 printf %s "(cached) " >&6
11354else $as_nop
57aa50d4
TT
11355 case $PERL in
11356 [\\/]* | ?:[\\/]*)
11357 ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
11358 ;;
11359 *)
11360 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11361for as_dir in $PATH
11362do
11363 IFS=$as_save_IFS
54445dc2
TT
11364 case $as_dir in #(((
11365 '') as_dir=./ ;;
11366 */) ;;
11367 *) as_dir=$as_dir/ ;;
11368 esac
57aa50d4 11369 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
11370 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
11371 ac_cv_path_PERL="$as_dir$ac_word$ac_exec_ext"
11372 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
11373 break 2
11374 fi
b0cacab0 11375done
57aa50d4
TT
11376 done
11377IFS=$as_save_IFS
11378
11379 test -z "$ac_cv_path_PERL" && ac_cv_path_PERL="perl"
11380 ;;
b0cacab0 11381esac
57aa50d4
TT
11382fi
11383PERL=$ac_cv_path_PERL
11384if test -n "$PERL"; then
54445dc2
TT
11385 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
11386printf "%s\n" "$PERL" >&6; }
b0cacab0 11387else
54445dc2
TT
11388 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11389printf "%s\n" "no" >&6; }
57aa50d4 11390fi
b0cacab0 11391
b0cacab0 11392
57aa50d4
TT
11393# Extract the first word of "ldconfig", so it can be a program name with args.
11394set dummy ldconfig; ac_word=$2
54445dc2
TT
11395{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11396printf %s "checking for $ac_word... " >&6; }
11397if test ${ac_cv_path_LDCONFIG+y}
11398then :
11399 printf %s "(cached) " >&6
11400else $as_nop
57aa50d4
TT
11401 case $LDCONFIG in
11402 [\\/]* | ?:[\\/]*)
11403 ac_cv_path_LDCONFIG="$LDCONFIG" # Let the user override the test with a path.
11404 ;;
11405 *)
11406 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11407for as_dir in $PATH
11408do
11409 IFS=$as_save_IFS
54445dc2
TT
11410 case $as_dir in #(((
11411 '') as_dir=./ ;;
11412 */) ;;
11413 *) as_dir=$as_dir/ ;;
11414 esac
57aa50d4 11415 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
11416 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
11417 ac_cv_path_LDCONFIG="$as_dir$ac_word$ac_exec_ext"
11418 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
11419 break 2
11420 fi
11421done
11422 done
11423IFS=$as_save_IFS
b0cacab0 11424
57aa50d4
TT
11425 test -z "$ac_cv_path_LDCONFIG" && ac_cv_path_LDCONFIG=":"
11426 ;;
11427esac
39fd3d4f 11428fi
57aa50d4
TT
11429LDCONFIG=$ac_cv_path_LDCONFIG
11430if test -n "$LDCONFIG"; then
54445dc2
TT
11431 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LDCONFIG" >&5
11432printf "%s\n" "$LDCONFIG" >&6; }
57aa50d4 11433else
54445dc2
TT
11434 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11435printf "%s\n" "no" >&6; }
b0cacab0 11436fi
39fd3d4f
SJR
11437
11438
57aa50d4
TT
11439if test -n "$ac_tool_prefix"; then
11440 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
11441set dummy ${ac_tool_prefix}ar; ac_word=$2
54445dc2
TT
11442{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11443printf %s "checking for $ac_word... " >&6; }
11444if test ${ac_cv_prog_AR+y}
11445then :
11446 printf %s "(cached) " >&6
11447else $as_nop
57aa50d4
TT
11448 if test -n "$AR"; then
11449 ac_cv_prog_AR="$AR" # Let the user override the test.
11450else
11451as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11452for as_dir in $PATH
11453do
11454 IFS=$as_save_IFS
54445dc2
TT
11455 case $as_dir in #(((
11456 '') as_dir=./ ;;
11457 */) ;;
11458 *) as_dir=$as_dir/ ;;
11459 esac
57aa50d4 11460 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 11461 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 11462 ac_cv_prog_AR="${ac_tool_prefix}ar"
54445dc2 11463 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
11464 break 2
11465 fi
11466done
11467 done
11468IFS=$as_save_IFS
39fd3d4f 11469
57aa50d4
TT
11470fi
11471fi
11472AR=$ac_cv_prog_AR
11473if test -n "$AR"; then
54445dc2
TT
11474 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
11475printf "%s\n" "$AR" >&6; }
57aa50d4 11476else
54445dc2
TT
11477 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11478printf "%s\n" "no" >&6; }
57aa50d4 11479fi
39fd3d4f 11480
b0cacab0 11481
57aa50d4
TT
11482fi
11483if test -z "$ac_cv_prog_AR"; then
11484 ac_ct_AR=$AR
11485 # Extract the first word of "ar", so it can be a program name with args.
11486set dummy ar; ac_word=$2
54445dc2
TT
11487{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11488printf %s "checking for $ac_word... " >&6; }
11489if test ${ac_cv_prog_ac_ct_AR+y}
11490then :
11491 printf %s "(cached) " >&6
11492else $as_nop
57aa50d4
TT
11493 if test -n "$ac_ct_AR"; then
11494 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
b0cacab0 11495else
57aa50d4
TT
11496as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11497for as_dir in $PATH
11498do
11499 IFS=$as_save_IFS
54445dc2
TT
11500 case $as_dir in #(((
11501 '') as_dir=./ ;;
11502 */) ;;
11503 *) as_dir=$as_dir/ ;;
11504 esac
57aa50d4 11505 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 11506 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 11507 ac_cv_prog_ac_ct_AR="ar"
54445dc2 11508 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
11509 break 2
11510 fi
11511done
11512 done
11513IFS=$as_save_IFS
b0cacab0 11514
b0cacab0 11515fi
57aa50d4
TT
11516fi
11517ac_ct_AR=$ac_cv_prog_ac_ct_AR
11518if test -n "$ac_ct_AR"; then
54445dc2
TT
11519 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
11520printf "%s\n" "$ac_ct_AR" >&6; }
b0cacab0 11521else
54445dc2
TT
11522 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11523printf "%s\n" "no" >&6; }
57aa50d4 11524fi
b0cacab0 11525
57aa50d4
TT
11526 if test "x$ac_ct_AR" = x; then
11527 AR="ar"
11528 else
11529 case $cross_compiling:$ac_tool_warned in
11530yes:)
54445dc2
TT
11531{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
11532printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
57aa50d4 11533ac_tool_warned=yes ;;
e1052144 11534esac
57aa50d4
TT
11535 AR=$ac_ct_AR
11536 fi
b0cacab0 11537else
57aa50d4 11538 AR="$ac_cv_prog_AR"
b0cacab0 11539fi
e1052144 11540
57aa50d4
TT
11541if test -n "$ac_tool_prefix"; then
11542 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
11543set dummy ${ac_tool_prefix}ranlib; ac_word=$2
54445dc2
TT
11544{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11545printf %s "checking for $ac_word... " >&6; }
11546if test ${ac_cv_prog_RANLIB+y}
11547then :
11548 printf %s "(cached) " >&6
11549else $as_nop
57aa50d4
TT
11550 if test -n "$RANLIB"; then
11551 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
11552else
11553as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11554for as_dir in $PATH
11555do
11556 IFS=$as_save_IFS
54445dc2
TT
11557 case $as_dir in #(((
11558 '') as_dir=./ ;;
11559 */) ;;
11560 *) as_dir=$as_dir/ ;;
11561 esac
57aa50d4 11562 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 11563 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 11564 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
54445dc2 11565 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
11566 break 2
11567 fi
11568done
b0cacab0 11569 done
57aa50d4 11570IFS=$as_save_IFS
b0cacab0 11571
b0cacab0 11572fi
57aa50d4
TT
11573fi
11574RANLIB=$ac_cv_prog_RANLIB
11575if test -n "$RANLIB"; then
54445dc2
TT
11576 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
11577printf "%s\n" "$RANLIB" >&6; }
b0cacab0 11578else
54445dc2
TT
11579 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11580printf "%s\n" "no" >&6; }
b0cacab0 11581fi
b0cacab0 11582
b0cacab0 11583
57aa50d4
TT
11584fi
11585if test -z "$ac_cv_prog_RANLIB"; then
11586 ac_ct_RANLIB=$RANLIB
11587 # Extract the first word of "ranlib", so it can be a program name with args.
11588set dummy ranlib; ac_word=$2
54445dc2
TT
11589{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11590printf %s "checking for $ac_word... " >&6; }
11591if test ${ac_cv_prog_ac_ct_RANLIB+y}
11592then :
11593 printf %s "(cached) " >&6
11594else $as_nop
57aa50d4
TT
11595 if test -n "$ac_ct_RANLIB"; then
11596 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
b0cacab0 11597else
57aa50d4
TT
11598as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11599for as_dir in $PATH
11600do
11601 IFS=$as_save_IFS
54445dc2
TT
11602 case $as_dir in #(((
11603 '') as_dir=./ ;;
11604 */) ;;
11605 *) as_dir=$as_dir/ ;;
11606 esac
57aa50d4 11607 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 11608 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 11609 ac_cv_prog_ac_ct_RANLIB="ranlib"
54445dc2 11610 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
11611 break 2
11612 fi
11613done
11614 done
11615IFS=$as_save_IFS
29a5deed 11616
b0cacab0 11617fi
57aa50d4
TT
11618fi
11619ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
11620if test -n "$ac_ct_RANLIB"; then
54445dc2
TT
11621 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
11622printf "%s\n" "$ac_ct_RANLIB" >&6; }
b0cacab0 11623else
54445dc2
TT
11624 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11625printf "%s\n" "no" >&6; }
57aa50d4 11626fi
b0cacab0 11627
57aa50d4
TT
11628 if test "x$ac_ct_RANLIB" = x; then
11629 RANLIB=":"
b0cacab0 11630 else
57aa50d4
TT
11631 case $cross_compiling:$ac_tool_warned in
11632yes:)
54445dc2
TT
11633{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
11634printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
57aa50d4 11635ac_tool_warned=yes ;;
e1052144 11636esac
57aa50d4
TT
11637 RANLIB=$ac_ct_RANLIB
11638 fi
b0cacab0 11639else
57aa50d4 11640 RANLIB="$ac_cv_prog_RANLIB"
b0cacab0 11641fi
e1052144 11642
57aa50d4
TT
11643if test -n "$ac_tool_prefix"; then
11644 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
11645set dummy ${ac_tool_prefix}strip; ac_word=$2
54445dc2
TT
11646{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11647printf %s "checking for $ac_word... " >&6; }
11648if test ${ac_cv_prog_STRIP+y}
11649then :
11650 printf %s "(cached) " >&6
11651else $as_nop
57aa50d4
TT
11652 if test -n "$STRIP"; then
11653 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
11654else
11655as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11656for as_dir in $PATH
11657do
11658 IFS=$as_save_IFS
54445dc2
TT
11659 case $as_dir in #(((
11660 '') as_dir=./ ;;
11661 */) ;;
11662 *) as_dir=$as_dir/ ;;
11663 esac
57aa50d4 11664 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 11665 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 11666 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
54445dc2 11667 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
11668 break 2
11669 fi
11670done
11671 done
11672IFS=$as_save_IFS
b0cacab0 11673
b0cacab0 11674fi
b0cacab0 11675fi
57aa50d4
TT
11676STRIP=$ac_cv_prog_STRIP
11677if test -n "$STRIP"; then
54445dc2
TT
11678 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
11679printf "%s\n" "$STRIP" >&6; }
57aa50d4 11680else
54445dc2
TT
11681 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11682printf "%s\n" "no" >&6; }
b0cacab0 11683fi
e1052144 11684
b0cacab0 11685
57aa50d4
TT
11686fi
11687if test -z "$ac_cv_prog_STRIP"; then
11688 ac_ct_STRIP=$STRIP
11689 # Extract the first word of "strip", so it can be a program name with args.
11690set dummy strip; ac_word=$2
54445dc2
TT
11691{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11692printf %s "checking for $ac_word... " >&6; }
11693if test ${ac_cv_prog_ac_ct_STRIP+y}
11694then :
11695 printf %s "(cached) " >&6
11696else $as_nop
57aa50d4
TT
11697 if test -n "$ac_ct_STRIP"; then
11698 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
11699else
11700as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11701for as_dir in $PATH
11702do
11703 IFS=$as_save_IFS
54445dc2
TT
11704 case $as_dir in #(((
11705 '') as_dir=./ ;;
11706 */) ;;
11707 *) as_dir=$as_dir/ ;;
11708 esac
57aa50d4 11709 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 11710 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 11711 ac_cv_prog_ac_ct_STRIP="strip"
54445dc2 11712 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
11713 break 2
11714 fi
11715done
11716 done
11717IFS=$as_save_IFS
b0cacab0 11718
b0cacab0 11719fi
57aa50d4
TT
11720fi
11721ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
11722if test -n "$ac_ct_STRIP"; then
54445dc2
TT
11723 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
11724printf "%s\n" "$ac_ct_STRIP" >&6; }
b0cacab0 11725else
54445dc2
TT
11726 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11727printf "%s\n" "no" >&6; }
57aa50d4 11728fi
b0cacab0 11729
57aa50d4
TT
11730 if test "x$ac_ct_STRIP" = x; then
11731 STRIP=":"
b0cacab0 11732 else
57aa50d4
TT
11733 case $cross_compiling:$ac_tool_warned in
11734yes:)
54445dc2
TT
11735{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
11736printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
57aa50d4 11737ac_tool_warned=yes ;;
e1052144 11738esac
57aa50d4
TT
11739 STRIP=$ac_ct_STRIP
11740 fi
b0cacab0 11741else
57aa50d4 11742 STRIP="$ac_cv_prog_STRIP"
b0cacab0 11743fi
e1052144 11744
57aa50d4
TT
11745# Extract the first word of "makeinfo", so it can be a program name with args.
11746set dummy makeinfo; ac_word=$2
54445dc2
TT
11747{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11748printf %s "checking for $ac_word... " >&6; }
11749if test ${ac_cv_prog_MAKEINFO+y}
11750then :
11751 printf %s "(cached) " >&6
11752else $as_nop
57aa50d4
TT
11753 if test -n "$MAKEINFO"; then
11754 ac_cv_prog_MAKEINFO="$MAKEINFO" # Let the user override the test.
11755else
11756as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11757for as_dir in $PATH
11758do
11759 IFS=$as_save_IFS
54445dc2
TT
11760 case $as_dir in #(((
11761 '') as_dir=./ ;;
11762 */) ;;
11763 *) as_dir=$as_dir/ ;;
11764 esac
57aa50d4 11765 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 11766 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 11767 ac_cv_prog_MAKEINFO="makeinfo"
54445dc2 11768 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
11769 break 2
11770 fi
11771done
11772 done
11773IFS=$as_save_IFS
b0cacab0 11774
b0cacab0
TT
11775fi
11776fi
57aa50d4
TT
11777MAKEINFO=$ac_cv_prog_MAKEINFO
11778if test -n "$MAKEINFO"; then
54445dc2
TT
11779 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
11780printf "%s\n" "$MAKEINFO" >&6; }
b0cacab0 11781else
54445dc2
TT
11782 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11783printf "%s\n" "no" >&6; }
07a0db15 11784fi
29a5deed
TT
11785
11786
57aa50d4 11787if test "_$MAKEINFO" = "_"; then
ca1de98a 11788 MAKEINFO="echo Makeinfo is missing. Info documentation will not be built."
57aa50d4
TT
11789else
11790 case "$MAKEINFO" in
11791 */missing.*)
54445dc2 11792 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING:
57aa50d4 11793*** Makeinfo is missing. Info documentation will not be built." >&5
54445dc2 11794printf "%s\n" "$as_me: WARNING:
57aa50d4
TT
11795*** Makeinfo is missing. Info documentation will not be built." >&2;}
11796 ;;
11797 *)
11798 ;;
11799 esac
b0cacab0 11800fi
29a5deed 11801
b0cacab0 11802
57aa50d4
TT
11803# See if we need a separate native compiler.
11804if test $cross_compiling = no; then
11805 BUILD_CC="$CC"
b0cacab0 11806
b0cacab0 11807else
57aa50d4
TT
11808 for ac_prog in gcc cc
11809do
11810 # Extract the first word of "$ac_prog", so it can be a program name with args.
11811set dummy $ac_prog; ac_word=$2
54445dc2
TT
11812{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11813printf %s "checking for $ac_word... " >&6; }
11814if test ${ac_cv_prog_BUILD_CC+y}
11815then :
11816 printf %s "(cached) " >&6
11817else $as_nop
57aa50d4
TT
11818 if test -n "$BUILD_CC"; then
11819 ac_cv_prog_BUILD_CC="$BUILD_CC" # Let the user override the test.
11820else
11821as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11822for as_dir in $PATH
11823do
11824 IFS=$as_save_IFS
54445dc2
TT
11825 case $as_dir in #(((
11826 '') as_dir=./ ;;
11827 */) ;;
11828 *) as_dir=$as_dir/ ;;
11829 esac
57aa50d4 11830 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2 11831 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
57aa50d4 11832 ac_cv_prog_BUILD_CC="$ac_prog"
54445dc2 11833 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
57aa50d4
TT
11834 break 2
11835 fi
11836done
11837 done
11838IFS=$as_save_IFS
b0cacab0 11839
b0cacab0 11840fi
57aa50d4
TT
11841fi
11842BUILD_CC=$ac_cv_prog_BUILD_CC
11843if test -n "$BUILD_CC"; then
54445dc2
TT
11844 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
11845printf "%s\n" "$BUILD_CC" >&6; }
07a0db15 11846else
54445dc2
TT
11847 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
11848printf "%s\n" "no" >&6; }
b0cacab0 11849fi
b0cacab0 11850
b0cacab0 11851
57aa50d4
TT
11852 test -n "$BUILD_CC" && break
11853done
b0cacab0 11854
57aa50d4 11855fi
54445dc2
TT
11856ac_fn_c_check_header_compile "$LINENO" "dirent.h" "ac_cv_header_dirent_h" "$ac_includes_default"
11857if test "x$ac_cv_header_dirent_h" = xyes
11858then :
11859 printf "%s\n" "#define HAVE_DIRENT_H 1" >>confdefs.h
b0cacab0 11860
b0cacab0 11861fi
54445dc2
TT
11862ac_fn_c_check_header_compile "$LINENO" "errno.h" "ac_cv_header_errno_h" "$ac_includes_default"
11863if test "x$ac_cv_header_errno_h" = xyes
11864then :
11865 printf "%s\n" "#define HAVE_ERRNO_H 1" >>confdefs.h
e1052144 11866
54445dc2
TT
11867fi
11868ac_fn_c_check_header_compile "$LINENO" "execinfo.h" "ac_cv_header_execinfo_h" "$ac_includes_default"
11869if test "x$ac_cv_header_execinfo_h" = xyes
11870then :
11871 printf "%s\n" "#define HAVE_EXECINFO_H 1" >>confdefs.h
11872
11873fi
11874ac_fn_c_check_header_compile "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
11875if test "x$ac_cv_header_getopt_h" = xyes
11876then :
11877 printf "%s\n" "#define HAVE_GETOPT_H 1" >>confdefs.h
93636bde 11878
54445dc2
TT
11879fi
11880ac_fn_c_check_header_compile "$LINENO" "malloc.h" "ac_cv_header_malloc_h" "$ac_includes_default"
11881if test "x$ac_cv_header_malloc_h" = xyes
11882then :
11883 printf "%s\n" "#define HAVE_MALLOC_H 1" >>confdefs.h
11884
11885fi
11886ac_fn_c_check_header_compile "$LINENO" "mntent.h" "ac_cv_header_mntent_h" "$ac_includes_default"
11887if test "x$ac_cv_header_mntent_h" = xyes
11888then :
11889 printf "%s\n" "#define HAVE_MNTENT_H 1" >>confdefs.h
11890
11891fi
11892ac_fn_c_check_header_compile "$LINENO" "paths.h" "ac_cv_header_paths_h" "$ac_includes_default"
11893if test "x$ac_cv_header_paths_h" = xyes
11894then :
11895 printf "%s\n" "#define HAVE_PATHS_H 1" >>confdefs.h
11896
11897fi
11898ac_fn_c_check_header_compile "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
11899if test "x$ac_cv_header_pthread_h" = xyes
11900then :
11901 printf "%s\n" "#define HAVE_PTHREAD_H 1" >>confdefs.h
11902
11903fi
11904ac_fn_c_check_header_compile "$LINENO" "semaphore.h" "ac_cv_header_semaphore_h" "$ac_includes_default"
11905if test "x$ac_cv_header_semaphore_h" = xyes
11906then :
11907 printf "%s\n" "#define HAVE_SEMAPHORE_H 1" >>confdefs.h
11908
11909fi
11910ac_fn_c_check_header_compile "$LINENO" "setjmp.h" "ac_cv_header_setjmp_h" "$ac_includes_default"
11911if test "x$ac_cv_header_setjmp_h" = xyes
11912then :
11913 printf "%s\n" "#define HAVE_SETJMP_H 1" >>confdefs.h
11914
11915fi
11916ac_fn_c_check_header_compile "$LINENO" "signal.h" "ac_cv_header_signal_h" "$ac_includes_default"
11917if test "x$ac_cv_header_signal_h" = xyes
11918then :
11919 printf "%s\n" "#define HAVE_SIGNAL_H 1" >>confdefs.h
11920
11921fi
11922ac_fn_c_check_header_compile "$LINENO" "stdarg.h" "ac_cv_header_stdarg_h" "$ac_includes_default"
11923if test "x$ac_cv_header_stdarg_h" = xyes
11924then :
11925 printf "%s\n" "#define HAVE_STDARG_H 1" >>confdefs.h
11926
11927fi
11928ac_fn_c_check_header_compile "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default"
11929if test "x$ac_cv_header_stdint_h" = xyes
11930then :
11931 printf "%s\n" "#define HAVE_STDINT_H 1" >>confdefs.h
11932
11933fi
11934ac_fn_c_check_header_compile "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
11935if test "x$ac_cv_header_stdlib_h" = xyes
11936then :
11937 printf "%s\n" "#define HAVE_STDLIB_H 1" >>confdefs.h
11938
11939fi
11940ac_fn_c_check_header_compile "$LINENO" "termios.h" "ac_cv_header_termios_h" "$ac_includes_default"
11941if test "x$ac_cv_header_termios_h" = xyes
11942then :
11943 printf "%s\n" "#define HAVE_TERMIOS_H 1" >>confdefs.h
11944
11945fi
11946ac_fn_c_check_header_compile "$LINENO" "termio.h" "ac_cv_header_termio_h" "$ac_includes_default"
11947if test "x$ac_cv_header_termio_h" = xyes
11948then :
11949 printf "%s\n" "#define HAVE_TERMIO_H 1" >>confdefs.h
11950
11951fi
11952ac_fn_c_check_header_compile "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default"
11953if test "x$ac_cv_header_unistd_h" = xyes
11954then :
11955 printf "%s\n" "#define HAVE_UNISTD_H 1" >>confdefs.h
11956
11957fi
11958ac_fn_c_check_header_compile "$LINENO" "utime.h" "ac_cv_header_utime_h" "$ac_includes_default"
11959if test "x$ac_cv_header_utime_h" = xyes
11960then :
11961 printf "%s\n" "#define HAVE_UTIME_H 1" >>confdefs.h
11962
11963fi
11964ac_fn_c_check_header_compile "$LINENO" "attr/xattr.h" "ac_cv_header_attr_xattr_h" "$ac_includes_default"
11965if test "x$ac_cv_header_attr_xattr_h" = xyes
11966then :
11967 printf "%s\n" "#define HAVE_ATTR_XATTR_H 1" >>confdefs.h
11968
11969fi
11970ac_fn_c_check_header_compile "$LINENO" "linux/falloc.h" "ac_cv_header_linux_falloc_h" "$ac_includes_default"
11971if test "x$ac_cv_header_linux_falloc_h" = xyes
11972then :
11973 printf "%s\n" "#define HAVE_LINUX_FALLOC_H 1" >>confdefs.h
11974
11975fi
11976ac_fn_c_check_header_compile "$LINENO" "linux/fd.h" "ac_cv_header_linux_fd_h" "$ac_includes_default"
11977if test "x$ac_cv_header_linux_fd_h" = xyes
11978then :
11979 printf "%s\n" "#define HAVE_LINUX_FD_H 1" >>confdefs.h
11980
11981fi
11982ac_fn_c_check_header_compile "$LINENO" "linux/fsmap.h" "ac_cv_header_linux_fsmap_h" "$ac_includes_default"
11983if test "x$ac_cv_header_linux_fsmap_h" = xyes
11984then :
11985 printf "%s\n" "#define HAVE_LINUX_FSMAP_H 1" >>confdefs.h
11986
11987fi
11988ac_fn_c_check_header_compile "$LINENO" "linux/major.h" "ac_cv_header_linux_major_h" "$ac_includes_default"
11989if test "x$ac_cv_header_linux_major_h" = xyes
11990then :
11991 printf "%s\n" "#define HAVE_LINUX_MAJOR_H 1" >>confdefs.h
11992
11993fi
11994ac_fn_c_check_header_compile "$LINENO" "linux/loop.h" "ac_cv_header_linux_loop_h" "$ac_includes_default"
11995if test "x$ac_cv_header_linux_loop_h" = xyes
11996then :
11997 printf "%s\n" "#define HAVE_LINUX_LOOP_H 1" >>confdefs.h
11998
11999fi
12000ac_fn_c_check_header_compile "$LINENO" "linux/types.h" "ac_cv_header_linux_types_h" "$ac_includes_default"
12001if test "x$ac_cv_header_linux_types_h" = xyes
12002then :
12003 printf "%s\n" "#define HAVE_LINUX_TYPES_H 1" >>confdefs.h
12004
12005fi
12006ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default"
12007if test "x$ac_cv_header_net_if_dl_h" = xyes
12008then :
12009 printf "%s\n" "#define HAVE_NET_IF_DL_H 1" >>confdefs.h
12010
12011fi
12012ac_fn_c_check_header_compile "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
12013if test "x$ac_cv_header_netinet_in_h" = xyes
12014then :
12015 printf "%s\n" "#define HAVE_NETINET_IN_H 1" >>confdefs.h
12016
12017fi
12018ac_fn_c_check_header_compile "$LINENO" "sys/acl.h" "ac_cv_header_sys_acl_h" "$ac_includes_default"
12019if test "x$ac_cv_header_sys_acl_h" = xyes
12020then :
12021 printf "%s\n" "#define HAVE_SYS_ACL_H 1" >>confdefs.h
12022
12023fi
12024ac_fn_c_check_header_compile "$LINENO" "sys/disklabel.h" "ac_cv_header_sys_disklabel_h" "$ac_includes_default"
12025if test "x$ac_cv_header_sys_disklabel_h" = xyes
12026then :
12027 printf "%s\n" "#define HAVE_SYS_DISKLABEL_H 1" >>confdefs.h
12028
12029fi
12030ac_fn_c_check_header_compile "$LINENO" "sys/disk.h" "ac_cv_header_sys_disk_h" "$ac_includes_default"
12031if test "x$ac_cv_header_sys_disk_h" = xyes
12032then :
12033 printf "%s\n" "#define HAVE_SYS_DISK_H 1" >>confdefs.h
12034
12035fi
12036ac_fn_c_check_header_compile "$LINENO" "sys/file.h" "ac_cv_header_sys_file_h" "$ac_includes_default"
12037if test "x$ac_cv_header_sys_file_h" = xyes
12038then :
12039 printf "%s\n" "#define HAVE_SYS_FILE_H 1" >>confdefs.h
12040
12041fi
12042ac_fn_c_check_header_compile "$LINENO" "sys/ioctl.h" "ac_cv_header_sys_ioctl_h" "$ac_includes_default"
12043if test "x$ac_cv_header_sys_ioctl_h" = xyes
12044then :
12045 printf "%s\n" "#define HAVE_SYS_IOCTL_H 1" >>confdefs.h
12046
12047fi
12048ac_fn_c_check_header_compile "$LINENO" "sys/key.h" "ac_cv_header_sys_key_h" "$ac_includes_default"
12049if test "x$ac_cv_header_sys_key_h" = xyes
12050then :
12051 printf "%s\n" "#define HAVE_SYS_KEY_H 1" >>confdefs.h
12052
12053fi
12054ac_fn_c_check_header_compile "$LINENO" "sys/mkdev.h" "ac_cv_header_sys_mkdev_h" "$ac_includes_default"
12055if test "x$ac_cv_header_sys_mkdev_h" = xyes
12056then :
12057 printf "%s\n" "#define HAVE_SYS_MKDEV_H 1" >>confdefs.h
12058
12059fi
12060ac_fn_c_check_header_compile "$LINENO" "sys/mman.h" "ac_cv_header_sys_mman_h" "$ac_includes_default"
12061if test "x$ac_cv_header_sys_mman_h" = xyes
12062then :
12063 printf "%s\n" "#define HAVE_SYS_MMAN_H 1" >>confdefs.h
12064
12065fi
12066ac_fn_c_check_header_compile "$LINENO" "sys/mount.h" "ac_cv_header_sys_mount_h" "$ac_includes_default"
12067if test "x$ac_cv_header_sys_mount_h" = xyes
12068then :
12069 printf "%s\n" "#define HAVE_SYS_MOUNT_H 1" >>confdefs.h
12070
12071fi
12072ac_fn_c_check_header_compile "$LINENO" "sys/prctl.h" "ac_cv_header_sys_prctl_h" "$ac_includes_default"
12073if test "x$ac_cv_header_sys_prctl_h" = xyes
12074then :
12075 printf "%s\n" "#define HAVE_SYS_PRCTL_H 1" >>confdefs.h
12076
12077fi
12078ac_fn_c_check_header_compile "$LINENO" "sys/random.h" "ac_cv_header_sys_random_h" "$ac_includes_default"
12079if test "x$ac_cv_header_sys_random_h" = xyes
12080then :
12081 printf "%s\n" "#define HAVE_SYS_RANDOM_H 1" >>confdefs.h
12082
12083fi
12084ac_fn_c_check_header_compile "$LINENO" "sys/resource.h" "ac_cv_header_sys_resource_h" "$ac_includes_default"
12085if test "x$ac_cv_header_sys_resource_h" = xyes
12086then :
12087 printf "%s\n" "#define HAVE_SYS_RESOURCE_H 1" >>confdefs.h
12088
12089fi
12090ac_fn_c_check_header_compile "$LINENO" "sys/select.h" "ac_cv_header_sys_select_h" "$ac_includes_default"
12091if test "x$ac_cv_header_sys_select_h" = xyes
12092then :
12093 printf "%s\n" "#define HAVE_SYS_SELECT_H 1" >>confdefs.h
12094
12095fi
12096ac_fn_c_check_header_compile "$LINENO" "sys/socket.h" "ac_cv_header_sys_socket_h" "$ac_includes_default"
12097if test "x$ac_cv_header_sys_socket_h" = xyes
12098then :
12099 printf "%s\n" "#define HAVE_SYS_SOCKET_H 1" >>confdefs.h
12100
12101fi
12102ac_fn_c_check_header_compile "$LINENO" "sys/sockio.h" "ac_cv_header_sys_sockio_h" "$ac_includes_default"
12103if test "x$ac_cv_header_sys_sockio_h" = xyes
12104then :
12105 printf "%s\n" "#define HAVE_SYS_SOCKIO_H 1" >>confdefs.h
12106
12107fi
12108ac_fn_c_check_header_compile "$LINENO" "sys/stat.h" "ac_cv_header_sys_stat_h" "$ac_includes_default"
12109if test "x$ac_cv_header_sys_stat_h" = xyes
12110then :
12111 printf "%s\n" "#define HAVE_SYS_STAT_H 1" >>confdefs.h
12112
12113fi
12114ac_fn_c_check_header_compile "$LINENO" "sys/syscall.h" "ac_cv_header_sys_syscall_h" "$ac_includes_default"
12115if test "x$ac_cv_header_sys_syscall_h" = xyes
12116then :
12117 printf "%s\n" "#define HAVE_SYS_SYSCALL_H 1" >>confdefs.h
12118
12119fi
12120ac_fn_c_check_header_compile "$LINENO" "sys/sysmacros.h" "ac_cv_header_sys_sysmacros_h" "$ac_includes_default"
12121if test "x$ac_cv_header_sys_sysmacros_h" = xyes
12122then :
12123 printf "%s\n" "#define HAVE_SYS_SYSMACROS_H 1" >>confdefs.h
12124
12125fi
12126ac_fn_c_check_header_compile "$LINENO" "sys/time.h" "ac_cv_header_sys_time_h" "$ac_includes_default"
12127if test "x$ac_cv_header_sys_time_h" = xyes
12128then :
12129 printf "%s\n" "#define HAVE_SYS_TIME_H 1" >>confdefs.h
12130
12131fi
12132ac_fn_c_check_header_compile "$LINENO" "sys/types.h" "ac_cv_header_sys_types_h" "$ac_includes_default"
12133if test "x$ac_cv_header_sys_types_h" = xyes
12134then :
12135 printf "%s\n" "#define HAVE_SYS_TYPES_H 1" >>confdefs.h
12136
12137fi
12138ac_fn_c_check_header_compile "$LINENO" "sys/un.h" "ac_cv_header_sys_un_h" "$ac_includes_default"
12139if test "x$ac_cv_header_sys_un_h" = xyes
12140then :
12141 printf "%s\n" "#define HAVE_SYS_UN_H 1" >>confdefs.h
12142
12143fi
12144ac_fn_c_check_header_compile "$LINENO" "sys/wait.h" "ac_cv_header_sys_wait_h" "$ac_includes_default"
12145if test "x$ac_cv_header_sys_wait_h" = xyes
12146then :
12147 printf "%s\n" "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
12148
12149fi
12150ac_fn_c_check_header_compile "$LINENO" "sys/xattr.h" "ac_cv_header_sys_xattr_h" "$ac_includes_default"
12151if test "x$ac_cv_header_sys_xattr_h" = xyes
12152then :
12153 printf "%s\n" "#define HAVE_SYS_XATTR_H 1" >>confdefs.h
12154
12155fi
12156
6eb00fb7
EB
12157case "$host_os" in
12158mingw*)
12159 # The above checks only detect system headers, not the headers in
12160 # ./include/mingw/, so explicitly define them to be available.
12161 printf "%s\n" "#define HAVE_LINUX_TYPES_H 1" >>confdefs.h
12162
12163 printf "%s\n" "#define HAVE_SYS_STAT_H 1" >>confdefs.h
12164
12165 printf "%s\n" "#define HAVE_SYS_SYSMACROS_H 1" >>confdefs.h
12166
12167 printf "%s\n" "#define HAVE_SYS_TYPES_H 1" >>confdefs.h
12168
12169 printf "%s\n" "#define HAVE_UNISTD_H 1" >>confdefs.h
12170
12171 ;;
12172esac
54445dc2
TT
12173{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a dd(1) program that supports iflag=fullblock" >&5
12174printf %s "checking for a dd(1) program that supports iflag=fullblock... " >&6; }
ec3a69bb
MA
12175DD=
12176for i in dd gdd ; do
12177 if "$i" if=/dev/null of=/dev/null count=1 bs=10k 2>/dev/null iflag=fullblock oflag=append ; then
12178 DD=$i
12179 break
12180 fi
12181done
12182if test -n "$DD" ; then
54445dc2
TT
12183 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DD" >&5
12184printf "%s\n" "$DD" >&6; }
ec3a69bb 12185else
54445dc2
TT
12186 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found, using dd" >&5
12187printf "%s\n" "not found, using dd" >&6; }
ec3a69bb 12188 DD=dd
54445dc2
TT
12189 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: No GNU-compatible dd(1) program found, expect some self-test failures." >&5
12190printf "%s\n" "$as_me: WARNING: No GNU-compatible dd(1) program found, expect some self-test failures." >&2;}
ec3a69bb
MA
12191fi
12192
12193
54445dc2 12194ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "
57aa50d4
TT
12195#if HAVE_SYS_TYPES_H
12196#include <sys/types.h>
12197#endif
12198#if HAVE_SYS_SOCKET
12199#include <sys/socket.h>
12200#endif
29a5deed 12201
57aa50d4 12202"
54445dc2
TT
12203if test "x$ac_cv_header_net_if_h" = xyes
12204then :
12205 printf "%s\n" "#define HAVE_NET_IF_H 1" >>confdefs.h
b0cacab0 12206
b0cacab0 12207fi
e1052144 12208
54445dc2
TT
12209ac_func=
12210for ac_item in $ac_func_c_list
12211do
12212 if test $ac_func; then
12213 ac_fn_c_check_func "$LINENO" $ac_func ac_cv_func_$ac_func
12214 if eval test \"x\$ac_cv_func_$ac_func\" = xyes; then
12215 echo "#define $ac_item 1" >> confdefs.h
12216 fi
12217 ac_func=
12218 else
12219 ac_func=$ac_item
12220 fi
b0cacab0 12221done
b0cacab0 12222
54445dc2
TT
12223if test "x$ac_cv_func_vprintf" = xno
12224then :
12225 ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt"
12226if test "x$ac_cv_func__doprnt" = xyes
12227then :
b0cacab0 12228
54445dc2 12229printf "%s\n" "#define HAVE_DOPRNT 1" >>confdefs.h
b0cacab0 12230
54445dc2 12231fi
b0cacab0 12232
50e1e10f 12233fi
54445dc2
TT
12234ac_fn_c_check_member "$LINENO" "struct dirent" "d_reclen" "ac_cv_member_struct_dirent_d_reclen" "#include <dirent.h>
12235"
12236if test "x$ac_cv_member_struct_dirent_d_reclen" = xyes
12237then :
12238
12239printf "%s\n" "#define HAVE_RECLEN_DIRENT 1" >>confdefs.h
29a5deed 12240
57aa50d4 12241fi
29a5deed 12242
54445dc2
TT
12243ac_fn_c_check_member "$LINENO" "struct stat" "st_atim" "ac_cv_member_struct_stat_st_atim" "$ac_includes_default"
12244if test "x$ac_cv_member_struct_stat_st_atim" = xyes
12245then :
12246
12247printf "%s\n" "#define HAVE_STRUCT_STAT_ST_ATIM 1" >>confdefs.h
29a5deed 12248
54445dc2
TT
12249
12250fi
12251
12252ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "#include <sys/types.h>
57aa50d4 12253"
54445dc2
TT
12254if test "x$ac_cv_type_ssize_t" = xyes
12255then :
12256
12257printf "%s\n" "#define HAVE_TYPE_SSIZE_T 1" >>confdefs.h
12258
12259fi
12260
12261{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC options needed to detect all undeclared functions" >&5
12262printf %s "checking for $CC options needed to detect all undeclared functions... " >&6; }
12263if test ${ac_cv_c_undeclared_builtin_options+y}
12264then :
12265 printf %s "(cached) " >&6
12266else $as_nop
12267 ac_save_CFLAGS=$CFLAGS
12268 ac_cv_c_undeclared_builtin_options='cannot detect'
12269 for ac_arg in '' -fno-builtin; do
12270 CFLAGS="$ac_save_CFLAGS $ac_arg"
12271 # This test program should *not* compile successfully.
12272 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12273/* end confdefs.h. */
d1154eb4 12274
54445dc2
TT
12275int
12276main (void)
12277{
12278(void) strchr;
12279 ;
12280 return 0;
12281}
12282_ACEOF
12283if ac_fn_c_try_compile "$LINENO"
12284then :
50e1e10f 12285
54445dc2
TT
12286else $as_nop
12287 # This test program should compile successfully.
12288 # No library function is consistently available on
12289 # freestanding implementations, so test against a dummy
12290 # declaration. Include always-available headers on the
12291 # off chance that they somehow elicit warnings.
12292 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12293/* end confdefs.h. */
12294#include <float.h>
12295#include <limits.h>
12296#include <stdarg.h>
12297#include <stddef.h>
12298extern void ac_decl (int, char *);
2873927d 12299
54445dc2
TT
12300int
12301main (void)
12302{
12303(void) ac_decl (0, (char *) 0);
12304 (void) ac_decl;
2873927d 12305
54445dc2
TT
12306 ;
12307 return 0;
12308}
2873927d 12309_ACEOF
54445dc2
TT
12310if ac_fn_c_try_compile "$LINENO"
12311then :
12312 if test x"$ac_arg" = x
12313then :
12314 ac_cv_c_undeclared_builtin_options='none needed'
12315else $as_nop
12316 ac_cv_c_undeclared_builtin_options=$ac_arg
b0cacab0 12317fi
54445dc2 12318 break
57aa50d4 12319fi
54445dc2
TT
12320rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
12321fi
12322rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
12323 done
12324 CFLAGS=$ac_save_CFLAGS
12325
12326fi
12327{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_undeclared_builtin_options" >&5
12328printf "%s\n" "$ac_cv_c_undeclared_builtin_options" >&6; }
12329 case $ac_cv_c_undeclared_builtin_options in #(
12330 'cannot detect') :
12331 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
12332printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
12333as_fn_error $? "cannot make $CC report undeclared builtins
12334See \`config.log' for more details" "$LINENO" 5; } ;; #(
12335 'none needed') :
12336 ac_c_undeclared_builtin_options='' ;; #(
12337 *) :
12338 ac_c_undeclared_builtin_options=$ac_cv_c_undeclared_builtin_options ;;
12339esac
b0cacab0 12340
54445dc2
TT
12341ac_fn_check_decl "$LINENO" "llseek" "ac_cv_have_decl_llseek" "#include <unistd.h>
12342" "$ac_c_undeclared_builtin_options" "CFLAGS"
12343if test "x$ac_cv_have_decl_llseek" = xyes
12344then :
d1154eb4 12345
54445dc2 12346printf "%s\n" "#define HAVE_LLSEEK_PROTOTYPE 1" >>confdefs.h
b0cacab0 12347
b0cacab0 12348fi
54445dc2 12349ac_fn_check_decl "$LINENO" "lseek64" "ac_cv_have_decl_lseek64" "#define _LARGEFILE_SOURCE
57aa50d4
TT
12350 #define _LARGEFILE64_SOURCE
12351 #include <unistd.h>
54445dc2
TT
12352" "$ac_c_undeclared_builtin_options" "CFLAGS"
12353if test "x$ac_cv_have_decl_lseek64" = xyes
12354then :
d1154eb4 12355
54445dc2 12356printf "%s\n" "#define HAVE_LSEEK64_PROTOTYPE 1" >>confdefs.h
b0cacab0 12357
5598a968
EB
12358fi
12359
12360ac_fn_check_decl "$LINENO" "fsmap_sizeof" "ac_cv_have_decl_fsmap_sizeof" "#include <linux/fsmap.h>
12361" "$ac_c_undeclared_builtin_options" "CFLAGS"
12362if test "x$ac_cv_have_decl_fsmap_sizeof" = xyes
12363then :
12364
12365printf "%s\n" "#define HAVE_FSMAP_SIZEOF 1" >>confdefs.h
12366
b0cacab0 12367fi
57aa50d4
TT
12368# The cast to long int works around a bug in the HP C Compiler
12369# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
12370# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
12371# This bug is HP SR number 8606223364.
54445dc2
TT
12372{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of short" >&5
12373printf %s "checking size of short... " >&6; }
12374if test ${ac_cv_sizeof_short+y}
12375then :
12376 printf %s "(cached) " >&6
12377else $as_nop
12378 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"
12379then :
12380
12381else $as_nop
57aa50d4 12382 if test "$ac_cv_type_short" = yes; then
54445dc2
TT
12383 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
12384printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
d6a4bcb5
TB
12385as_fn_error 77 "cannot compute sizeof (short)
12386See \`config.log' for more details" "$LINENO" 5; }
57aa50d4
TT
12387 else
12388 ac_cv_sizeof_short=0
12389 fi
07a0db15 12390fi
b0cacab0 12391
b0cacab0 12392fi
54445dc2
TT
12393{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5
12394printf "%s\n" "$ac_cv_sizeof_short" >&6; }
e1052144 12395
93636bde 12396
57aa50d4 12397
54445dc2 12398printf "%s\n" "#define SIZEOF_SHORT $ac_cv_sizeof_short" >>confdefs.h
57aa50d4
TT
12399
12400
12401# The cast to long int works around a bug in the HP C Compiler
12402# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
12403# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
12404# This bug is HP SR number 8606223364.
54445dc2
TT
12405{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
12406printf %s "checking size of int... " >&6; }
12407if test ${ac_cv_sizeof_int+y}
12408then :
12409 printf %s "(cached) " >&6
12410else $as_nop
12411 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"
12412then :
12413
12414else $as_nop
57aa50d4 12415 if test "$ac_cv_type_int" = yes; then
54445dc2
TT
12416 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
12417printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
d6a4bcb5
TB
12418as_fn_error 77 "cannot compute sizeof (int)
12419See \`config.log' for more details" "$LINENO" 5; }
57aa50d4
TT
12420 else
12421 ac_cv_sizeof_int=0
12422 fi
07a0db15 12423fi
e1052144 12424
b0cacab0 12425fi
54445dc2
TT
12426{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
12427printf "%s\n" "$ac_cv_sizeof_int" >&6; }
e1052144 12428
93636bde 12429
57aa50d4 12430
54445dc2 12431printf "%s\n" "#define SIZEOF_INT $ac_cv_sizeof_int" >>confdefs.h
b0cacab0 12432
e1052144 12433
57aa50d4
TT
12434# The cast to long int works around a bug in the HP C Compiler
12435# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
12436# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
12437# This bug is HP SR number 8606223364.
54445dc2
TT
12438{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
12439printf %s "checking size of long... " >&6; }
12440if test ${ac_cv_sizeof_long+y}
12441then :
12442 printf %s "(cached) " >&6
12443else $as_nop
12444 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"
12445then :
12446
12447else $as_nop
57aa50d4 12448 if test "$ac_cv_type_long" = yes; then
54445dc2
TT
12449 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
12450printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
d6a4bcb5
TB
12451as_fn_error 77 "cannot compute sizeof (long)
12452See \`config.log' for more details" "$LINENO" 5; }
29a5deed 12453 else
57aa50d4
TT
12454 ac_cv_sizeof_long=0
12455 fi
12456fi
39fd3d4f 12457
57aa50d4 12458fi
54445dc2
TT
12459{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
12460printf "%s\n" "$ac_cv_sizeof_long" >&6; }
39fd3d4f 12461
57aa50d4
TT
12462
12463
54445dc2 12464printf "%s\n" "#define SIZEOF_LONG $ac_cv_sizeof_long" >>confdefs.h
57aa50d4
TT
12465
12466
12467# The cast to long int works around a bug in the HP C Compiler
12468# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
12469# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
12470# This bug is HP SR number 8606223364.
54445dc2
TT
12471{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
12472printf %s "checking size of long long... " >&6; }
12473if test ${ac_cv_sizeof_long_long+y}
12474then :
12475 printf %s "(cached) " >&6
12476else $as_nop
12477 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"
12478then :
12479
12480else $as_nop
57aa50d4 12481 if test "$ac_cv_type_long_long" = yes; then
54445dc2
TT
12482 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
12483printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
d6a4bcb5
TB
12484as_fn_error 77 "cannot compute sizeof (long long)
12485See \`config.log' for more details" "$LINENO" 5; }
39fd3d4f
SJR
12486 else
12487 ac_cv_sizeof_long_long=0
12488 fi
12489fi
57aa50d4 12490
39fd3d4f 12491fi
54445dc2
TT
12492{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
12493printf "%s\n" "$ac_cv_sizeof_long_long" >&6; }
39fd3d4f
SJR
12494
12495
12496
54445dc2 12497printf "%s\n" "#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long" >>confdefs.h
39fd3d4f
SJR
12498
12499
cc68e8a6
TT
12500# The cast to long int works around a bug in the HP C Compiler
12501# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
12502# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
12503# This bug is HP SR number 8606223364.
54445dc2
TT
12504{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5
12505printf %s "checking size of off_t... " >&6; }
12506if test ${ac_cv_sizeof_off_t+y}
12507then :
12508 printf %s "(cached) " >&6
12509else $as_nop
12510 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (off_t))" "ac_cv_sizeof_off_t" "$ac_includes_default"
12511then :
12512
12513else $as_nop
cc68e8a6 12514 if test "$ac_cv_type_off_t" = yes; then
54445dc2
TT
12515 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
12516printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
cc68e8a6
TT
12517as_fn_error 77 "cannot compute sizeof (off_t)
12518See \`config.log' for more details" "$LINENO" 5; }
12519 else
12520 ac_cv_sizeof_off_t=0
12521 fi
12522fi
12523
12524fi
54445dc2
TT
12525{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5
12526printf "%s\n" "$ac_cv_sizeof_off_t" >&6; }
cc68e8a6
TT
12527
12528
12529
54445dc2 12530printf "%s\n" "#define SIZEOF_OFF_T $ac_cv_sizeof_off_t" >>confdefs.h
cc68e8a6
TT
12531
12532
2dd680f3
TT
12533# The cast to long int works around a bug in the HP C Compiler
12534# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
12535# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
12536# This bug is HP SR number 8606223364.
54445dc2
TT
12537{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5
12538printf %s "checking size of time_t... " >&6; }
12539if test ${ac_cv_sizeof_time_t+y}
12540then :
12541 printf %s "(cached) " >&6
12542else $as_nop
12543 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t" "$ac_includes_default"
12544then :
12545
12546else $as_nop
2dd680f3 12547 if test "$ac_cv_type_time_t" = yes; then
54445dc2
TT
12548 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
12549printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
2dd680f3
TT
12550as_fn_error 77 "cannot compute sizeof (time_t)
12551See \`config.log' for more details" "$LINENO" 5; }
12552 else
12553 ac_cv_sizeof_time_t=0
12554 fi
12555fi
12556
12557fi
54445dc2
TT
12558{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5
12559printf "%s\n" "$ac_cv_sizeof_time_t" >&6; }
2dd680f3
TT
12560
12561
12562
54445dc2 12563printf "%s\n" "#define SIZEOF_TIME_T $ac_cv_sizeof_time_t" >>confdefs.h
2dd680f3
TT
12564
12565
39fd3d4f
SJR
12566SIZEOF_SHORT=$ac_cv_sizeof_short
12567SIZEOF_INT=$ac_cv_sizeof_int
12568SIZEOF_LONG=$ac_cv_sizeof_long
12569SIZEOF_LONG_LONG=$ac_cv_sizeof_long_long
cc68e8a6 12570SIZEOF_OFF_T=$ac_cv_sizeof_off_t
2dd680f3
TT
12571SIZEOF_TIME_T=$ac_cv_sizeof_time_t
12572
cc68e8a6 12573
39fd3d4f
SJR
12574
12575
12576
12577
54445dc2
TT
12578 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
12579printf %s "checking whether byte ordering is bigendian... " >&6; }
12580if test ${ac_cv_c_bigendian+y}
12581then :
12582 printf %s "(cached) " >&6
12583else $as_nop
39fd3d4f
SJR
12584 ac_cv_c_bigendian=unknown
12585 # See if we're dealing with a universal compiler.
57aa50d4 12586 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39fd3d4f
SJR
12587/* end confdefs.h. */
12588#ifndef __APPLE_CC__
12589 not a universal capable compiler
12590 #endif
12591 typedef int dummy;
12592
12593_ACEOF
54445dc2
TT
12594if ac_fn_c_try_compile "$LINENO"
12595then :
39fd3d4f
SJR
12596
12597 # Check for potential -arch flags. It is not universal unless
57aa50d4
TT
12598 # there are at least two -arch flags with different values.
12599 ac_arch=
12600 ac_prev=
12601 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
12602 if test -n "$ac_prev"; then
12603 case $ac_word in
12604 i?86 | x86_64 | ppc | ppc64)
12605 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
12606 ac_arch=$ac_word
12607 else
12608 ac_cv_c_bigendian=universal
12609 break
12610 fi
12611 ;;
12612 esac
12613 ac_prev=
12614 elif test "x$ac_word" = "x-arch"; then
12615 ac_prev=arch
12616 fi
12617 done
39fd3d4f 12618fi
54445dc2 12619rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
39fd3d4f
SJR
12620 if test $ac_cv_c_bigendian = unknown; then
12621 # See if sys/param.h defines the BYTE_ORDER macro.
57aa50d4 12622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39fd3d4f
SJR
12623/* end confdefs.h. */
12624#include <sys/types.h>
12625 #include <sys/param.h>
12626
12627int
54445dc2 12628main (void)
39fd3d4f
SJR
12629{
12630#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
12631 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
12632 && LITTLE_ENDIAN)
12633 bogus endian macros
12634 #endif
12635
12636 ;
12637 return 0;
12638}
12639_ACEOF
54445dc2
TT
12640if ac_fn_c_try_compile "$LINENO"
12641then :
39fd3d4f 12642 # It does; now see whether it defined to BIG_ENDIAN or not.
57aa50d4 12643 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39fd3d4f
SJR
12644/* end confdefs.h. */
12645#include <sys/types.h>
12646 #include <sys/param.h>
12647
b0cacab0 12648int
54445dc2 12649main (void)
07a0db15 12650{
39fd3d4f
SJR
12651#if BYTE_ORDER != BIG_ENDIAN
12652 not big endian
12653 #endif
b0cacab0
TT
12654
12655 ;
12656 return 0;
07a0db15 12657}
b0cacab0 12658_ACEOF
54445dc2
TT
12659if ac_fn_c_try_compile "$LINENO"
12660then :
39fd3d4f 12661 ac_cv_c_bigendian=yes
54445dc2 12662else $as_nop
57aa50d4 12663 ac_cv_c_bigendian=no
fc6d9d51 12664fi
54445dc2 12665rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
39fd3d4f 12666fi
54445dc2 12667rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
39fd3d4f
SJR
12668 fi
12669 if test $ac_cv_c_bigendian = unknown; then
12670 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
57aa50d4 12671 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b0cacab0 12672/* end confdefs.h. */
39fd3d4f 12673#include <limits.h>
877eb6d9 12674
b0cacab0 12675int
54445dc2 12676main (void)
b0cacab0 12677{
39fd3d4f
SJR
12678#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
12679 bogus endian macros
12680 #endif
b0cacab0
TT
12681
12682 ;
12683 return 0;
12684}
b0cacab0 12685_ACEOF
54445dc2
TT
12686if ac_fn_c_try_compile "$LINENO"
12687then :
57aa50d4
TT
12688 # It does; now see whether it defined to _BIG_ENDIAN or not.
12689 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b0cacab0 12690/* end confdefs.h. */
39fd3d4f 12691#include <limits.h>
877eb6d9 12692
b0cacab0 12693int
54445dc2 12694main (void)
b0cacab0 12695{
39fd3d4f
SJR
12696#ifndef _BIG_ENDIAN
12697 not big endian
12698 #endif
b0cacab0
TT
12699
12700 ;
12701 return 0;
12702}
12703_ACEOF
54445dc2
TT
12704if ac_fn_c_try_compile "$LINENO"
12705then :
877eb6d9 12706 ac_cv_c_bigendian=yes
54445dc2 12707else $as_nop
57aa50d4 12708 ac_cv_c_bigendian=no
877eb6d9 12709fi
54445dc2 12710rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
39fd3d4f 12711fi
54445dc2 12712rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
39fd3d4f
SJR
12713 fi
12714 if test $ac_cv_c_bigendian = unknown; then
12715 # Compile a test program.
54445dc2
TT
12716 if test "$cross_compiling" = yes
12717then :
39fd3d4f 12718 # Try to guess by grepping values from an object file.
57aa50d4 12719 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b0cacab0 12720/* end confdefs.h. */
54445dc2 12721unsigned short int ascii_mm[] =
39fd3d4f 12722 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
54445dc2 12723 unsigned short int ascii_ii[] =
39fd3d4f
SJR
12724 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
12725 int use_ascii (int i) {
12726 return ascii_mm[i] + ascii_ii[i];
12727 }
54445dc2 12728 unsigned short int ebcdic_ii[] =
39fd3d4f 12729 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
54445dc2 12730 unsigned short int ebcdic_mm[] =
39fd3d4f
SJR
12731 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
12732 int use_ebcdic (int i) {
12733 return ebcdic_mm[i] + ebcdic_ii[i];
12734 }
12735 extern int foo;
12736
b0cacab0 12737int
54445dc2 12738main (void)
b0cacab0 12739{
39fd3d4f 12740return use_ascii (foo) == use_ebcdic (foo);
b0cacab0
TT
12741 ;
12742 return 0;
12743}
12744_ACEOF
54445dc2
TT
12745if ac_fn_c_try_compile "$LINENO"
12746then :
39fd3d4f
SJR
12747 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
12748 ac_cv_c_bigendian=yes
12749 fi
12750 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
12751 if test "$ac_cv_c_bigendian" = unknown; then
12752 ac_cv_c_bigendian=no
12753 else
12754 # finding both strings is unlikely to happen, but who knows?
12755 ac_cv_c_bigendian=unknown
12756 fi
12757 fi
b0cacab0 12758fi
54445dc2
TT
12759rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
12760else $as_nop
57aa50d4 12761 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b0cacab0 12762/* end confdefs.h. */
e1052144 12763$ac_includes_default
b0cacab0 12764int
54445dc2 12765main (void)
b0cacab0 12766{
e1052144 12767
39fd3d4f
SJR
12768 /* Are we little or big endian? From Harbison&Steele. */
12769 union
12770 {
12771 long int l;
12772 char c[sizeof (long int)];
12773 } u;
12774 u.l = 1;
12775 return u.c[sizeof (long int) - 1] == 1;
e1052144
TT
12776
12777 ;
12778 return 0;
877eb6d9 12779}
b0cacab0 12780_ACEOF
54445dc2
TT
12781if ac_fn_c_try_run "$LINENO"
12782then :
877eb6d9 12783 ac_cv_c_bigendian=no
54445dc2 12784else $as_nop
57aa50d4 12785 ac_cv_c_bigendian=yes
877eb6d9 12786fi
57aa50d4
TT
12787rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12788 conftest.$ac_objext conftest.beam conftest.$ac_ext
877eb6d9 12789fi
e1052144 12790
39fd3d4f 12791 fi
877eb6d9 12792fi
54445dc2
TT
12793{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
12794printf "%s\n" "$ac_cv_c_bigendian" >&6; }
39fd3d4f
SJR
12795 case $ac_cv_c_bigendian in #(
12796 yes)
54445dc2 12797 printf "%s\n" "#define WORDS_BIGENDIAN 1" >>confdefs.h
39fd3d4f
SJR
12798;; #(
12799 no)
12800 ;; #(
12801 universal)
07a0db15 12802
54445dc2 12803printf "%s\n" "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
39fd3d4f
SJR
12804
12805 ;; #(
12806 *)
d6a4bcb5 12807 as_fn_error $? "unknown endianness
57aa50d4 12808 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
39fd3d4f 12809 esac
877eb6d9 12810
91f04685
CQ
12811if test $cross_compiling = no; then
12812 BUILD_CC="$BUILD_CC" CPP="$CPP" /bin/sh $ac_aux_dir/parse-types.sh
12813else
12814 CROSS_COMPILE="1" BUILD_CC="$BUILD_CC" CPP="$CPP" /bin/sh $ac_aux_dir/parse-types.sh
12815fi
4ea7ea00
TT
12816ASM_TYPES_HEADER=./asm_types.h
12817
488c75a6
TT
12818echo "/* These defines are needed for the public ext2fs.h header file */" \
12819 > public_config.h
12820if grep HAVE_SYS_TYPES_H confdefs.h > tmp_config.$$; then
12821 uniq tmp_config.$$ >> public_config.h
12822else
12823 echo "#undef HAVE_SYS_TYPES_H" >> public_config.h
12824fi
12825if grep WORDS_BIGENDIAN confdefs.h > tmp_config.$$; then
12826 uniq tmp_config.$$ >> public_config.h
12827else
12828 echo "#undef WORDS_BIGENDIAN" >> public_config.h
12829fi
12830rm -f tmp_config.$$
12831PUBLIC_CONFIG_HEADER=./public_config.h
12832
54445dc2
TT
12833ac_fn_c_check_header_compile "$LINENO" "inttypes.h" "ac_cv_header_inttypes_h" "$ac_includes_default"
12834if test "x$ac_cv_header_inttypes_h" = xyes
12835then :
12836 printf "%s\n" "#define HAVE_INTTYPES_H 1" >>confdefs.h
b0cacab0
TT
12837
12838fi
12839
57aa50d4 12840ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default"
54445dc2
TT
12841if test "x$ac_cv_type_intptr_t" = xyes
12842then :
b0cacab0 12843
54445dc2 12844printf "%s\n" "#define HAVE_INTPTR_T 1" >>confdefs.h
0c193f82 12845
d2ee56d8 12846
0c193f82
TT
12847fi
12848
54445dc2
TT
12849{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether struct stat has a st_flags field" >&5
12850printf %s "checking whether struct stat has a st_flags field... " >&6; }
12851if test ${e2fsprogs_cv_struct_st_flags+y}
12852then :
12853 printf %s "(cached) " >&6
12854else $as_nop
57aa50d4 12855 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b0cacab0 12856/* end confdefs.h. */
50e1e10f 12857#include <sys/stat.h>
b0cacab0 12858int
54445dc2 12859main (void)
b0cacab0 12860{
50e1e10f 12861struct stat stat; stat.st_flags = 0;
b0cacab0
TT
12862 ;
12863 return 0;
12864}
12865_ACEOF
54445dc2
TT
12866if ac_fn_c_try_compile "$LINENO"
12867then :
50e1e10f 12868 e2fsprogs_cv_struct_st_flags=yes
54445dc2 12869else $as_nop
57aa50d4 12870 e2fsprogs_cv_struct_st_flags=no
50e1e10f 12871fi
54445dc2
TT
12872rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
12873fi
12874
12875{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $e2fsprogs_cv_struct_st_flags" >&5
12876printf "%s\n" "$e2fsprogs_cv_struct_st_flags" >&6; }
12877if test "$e2fsprogs_cv_struct_st_flags" = yes; then
12878 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether st_flags field is useful" >&5
12879printf %s "checking whether st_flags field is useful... " >&6; }
12880 if test ${e2fsprogs_cv_struct_st_flags_immut+y}
12881then :
12882 printf %s "(cached) " >&6
12883else $as_nop
12884 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12885/* end confdefs.h. */
12886#include <sys/stat.h>
12887int
12888main (void)
12889{
12890struct stat stat; stat.st_flags |= UF_IMMUTABLE;
12891 ;
12892 return 0;
12893}
12894_ACEOF
12895if ac_fn_c_try_compile "$LINENO"
12896then :
12897 e2fsprogs_cv_struct_st_flags_immut=yes
12898else $as_nop
12899 e2fsprogs_cv_struct_st_flags_immut=no
12900fi
12901rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
12902fi
12903
12904 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $e2fsprogs_cv_struct_st_flags_immut" >&5
12905printf "%s\n" "$e2fsprogs_cv_struct_st_flags_immut" >&6; }
12906 if test "$e2fsprogs_cv_struct_st_flags_immut" = yes; then
12907
12908printf "%s\n" "#define HAVE_STAT_FLAGS 1" >>confdefs.h
12909
12910 fi
12911fi
12912ac_fn_c_check_member "$LINENO" "struct sockaddr" "sa_len" "ac_cv_member_struct_sockaddr_sa_len" "#include <sys/types.h>
12913 #include <sys/socket.h>
12914"
12915if test "x$ac_cv_member_struct_sockaddr_sa_len" = xyes
12916then :
12917
12918printf "%s\n" "#define HAVE_SA_LEN 1" >>confdefs.h
12919
12920fi
12921
12922if test -n "$BLKID_CMT"; then
12923 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for blkid_probe_get_topology in -lblkid" >&5
12924printf %s "checking for blkid_probe_get_topology in -lblkid... " >&6; }
12925if test ${ac_cv_lib_blkid_blkid_probe_get_topology+y}
12926then :
12927 printf %s "(cached) " >&6
12928else $as_nop
12929 ac_check_lib_save_LIBS=$LIBS
12930LIBS="-lblkid $LIBS"
12931cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12932/* end confdefs.h. */
12933
12934/* Override any GCC internal prototype to avoid an error.
12935 Use char because int might match the return type of a GCC
12936 builtin and then its argument prototype would still apply. */
12937char blkid_probe_get_topology ();
12938int
12939main (void)
12940{
12941return blkid_probe_get_topology ();
12942 ;
12943 return 0;
12944}
12945_ACEOF
12946if ac_fn_c_try_link "$LINENO"
12947then :
12948 ac_cv_lib_blkid_blkid_probe_get_topology=yes
12949else $as_nop
12950 ac_cv_lib_blkid_blkid_probe_get_topology=no
12951fi
12952rm -f core conftest.err conftest.$ac_objext conftest.beam \
12953 conftest$ac_exeext conftest.$ac_ext
12954LIBS=$ac_check_lib_save_LIBS
12955fi
12956{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_blkid_blkid_probe_get_topology" >&5
12957printf "%s\n" "$ac_cv_lib_blkid_blkid_probe_get_topology" >&6; }
12958if test "x$ac_cv_lib_blkid_blkid_probe_get_topology" = xyes
12959then :
12960
12961printf "%s\n" "#define HAVE_BLKID_PROBE_GET_TOPOLOGY 1" >>confdefs.h
12962
12963fi
12964
12965 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for blkid_topology_get_dax in -lblkid" >&5
12966printf %s "checking for blkid_topology_get_dax in -lblkid... " >&6; }
12967if test ${ac_cv_lib_blkid_blkid_topology_get_dax+y}
12968then :
12969 printf %s "(cached) " >&6
12970else $as_nop
12971 ac_check_lib_save_LIBS=$LIBS
12972LIBS="-lblkid $LIBS"
12973cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12974/* end confdefs.h. */
12975
12976/* Override any GCC internal prototype to avoid an error.
12977 Use char because int might match the return type of a GCC
12978 builtin and then its argument prototype would still apply. */
12979char blkid_topology_get_dax ();
12980int
12981main (void)
12982{
12983return blkid_topology_get_dax ();
12984 ;
12985 return 0;
12986}
12987_ACEOF
12988if ac_fn_c_try_link "$LINENO"
12989then :
12990 ac_cv_lib_blkid_blkid_topology_get_dax=yes
12991else $as_nop
12992 ac_cv_lib_blkid_blkid_topology_get_dax=no
12993fi
12994rm -f core conftest.err conftest.$ac_objext conftest.beam \
12995 conftest$ac_exeext conftest.$ac_ext
12996LIBS=$ac_check_lib_save_LIBS
12997fi
12998{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_blkid_blkid_topology_get_dax" >&5
12999printf "%s\n" "$ac_cv_lib_blkid_blkid_topology_get_dax" >&6; }
13000if test "x$ac_cv_lib_blkid_blkid_topology_get_dax" = xyes
13001then :
13002
13003printf "%s\n" "#define HAVE_BLKID_TOPOLOGY_GET_DAX 1" >>confdefs.h
13004
13005fi
13006
13007 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for blkid_probe_enable_partitions in -lblkid" >&5
13008printf %s "checking for blkid_probe_enable_partitions in -lblkid... " >&6; }
13009if test ${ac_cv_lib_blkid_blkid_probe_enable_partitions+y}
13010then :
13011 printf %s "(cached) " >&6
13012else $as_nop
13013 ac_check_lib_save_LIBS=$LIBS
13014LIBS="-lblkid $LIBS"
13015cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13016/* end confdefs.h. */
13017
13018/* Override any GCC internal prototype to avoid an error.
13019 Use char because int might match the return type of a GCC
13020 builtin and then its argument prototype would still apply. */
13021char blkid_probe_enable_partitions ();
13022int
13023main (void)
13024{
13025return blkid_probe_enable_partitions ();
13026 ;
13027 return 0;
13028}
13029_ACEOF
13030if ac_fn_c_try_link "$LINENO"
13031then :
13032 ac_cv_lib_blkid_blkid_probe_enable_partitions=yes
13033else $as_nop
13034 ac_cv_lib_blkid_blkid_probe_enable_partitions=no
13035fi
13036rm -f core conftest.err conftest.$ac_objext conftest.beam \
13037 conftest$ac_exeext conftest.$ac_ext
13038LIBS=$ac_check_lib_save_LIBS
13039fi
13040{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_blkid_blkid_probe_enable_partitions" >&5
13041printf "%s\n" "$ac_cv_lib_blkid_blkid_probe_enable_partitions" >&6; }
13042if test "x$ac_cv_lib_blkid_blkid_probe_enable_partitions" = xyes
13043then :
13044
13045printf "%s\n" "#define HAVE_BLKID_PROBE_ENABLE_PARTITIONS 1" >>confdefs.h
13046
13047fi
13048
13049fi
13050if test -n "$DLOPEN_LIB" ; then
13051 ac_cv_func_dlopen=yes
13052fi
13053ac_fn_c_check_func "$LINENO" "__secure_getenv" "ac_cv_func___secure_getenv"
13054if test "x$ac_cv_func___secure_getenv" = xyes
13055then :
13056 printf "%s\n" "#define HAVE___SECURE_GETENV 1" >>confdefs.h
13057
13058fi
13059ac_fn_c_check_func "$LINENO" "add_key" "ac_cv_func_add_key"
13060if test "x$ac_cv_func_add_key" = xyes
13061then :
13062 printf "%s\n" "#define HAVE_ADD_KEY 1" >>confdefs.h
13063
13064fi
13065ac_fn_c_check_func "$LINENO" "backtrace" "ac_cv_func_backtrace"
13066if test "x$ac_cv_func_backtrace" = xyes
13067then :
13068 printf "%s\n" "#define HAVE_BACKTRACE 1" >>confdefs.h
13069
13070fi
13071ac_fn_c_check_func "$LINENO" "chflags" "ac_cv_func_chflags"
13072if test "x$ac_cv_func_chflags" = xyes
13073then :
13074 printf "%s\n" "#define HAVE_CHFLAGS 1" >>confdefs.h
13075
13076fi
13077ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
13078if test "x$ac_cv_func_dlopen" = xyes
13079then :
13080 printf "%s\n" "#define HAVE_DLOPEN 1" >>confdefs.h
13081
13082fi
13083ac_fn_c_check_func "$LINENO" "fadvise64" "ac_cv_func_fadvise64"
13084if test "x$ac_cv_func_fadvise64" = xyes
13085then :
13086 printf "%s\n" "#define HAVE_FADVISE64 1" >>confdefs.h
13087
13088fi
13089ac_fn_c_check_func "$LINENO" "fallocate" "ac_cv_func_fallocate"
13090if test "x$ac_cv_func_fallocate" = xyes
13091then :
13092 printf "%s\n" "#define HAVE_FALLOCATE 1" >>confdefs.h
13093
13094fi
13095ac_fn_c_check_func "$LINENO" "fallocate64" "ac_cv_func_fallocate64"
13096if test "x$ac_cv_func_fallocate64" = xyes
13097then :
13098 printf "%s\n" "#define HAVE_FALLOCATE64 1" >>confdefs.h
13099
13100fi
13101ac_fn_c_check_func "$LINENO" "fchown" "ac_cv_func_fchown"
13102if test "x$ac_cv_func_fchown" = xyes
13103then :
13104 printf "%s\n" "#define HAVE_FCHOWN 1" >>confdefs.h
13105
13106fi
13107ac_fn_c_check_func "$LINENO" "fcntl" "ac_cv_func_fcntl"
13108if test "x$ac_cv_func_fcntl" = xyes
13109then :
13110 printf "%s\n" "#define HAVE_FCNTL 1" >>confdefs.h
13111
13112fi
13113ac_fn_c_check_func "$LINENO" "fdatasync" "ac_cv_func_fdatasync"
13114if test "x$ac_cv_func_fdatasync" = xyes
13115then :
13116 printf "%s\n" "#define HAVE_FDATASYNC 1" >>confdefs.h
13117
13118fi
13119ac_fn_c_check_func "$LINENO" "fstat64" "ac_cv_func_fstat64"
13120if test "x$ac_cv_func_fstat64" = xyes
13121then :
13122 printf "%s\n" "#define HAVE_FSTAT64 1" >>confdefs.h
13123
13124fi
13125ac_fn_c_check_func "$LINENO" "fsync" "ac_cv_func_fsync"
13126if test "x$ac_cv_func_fsync" = xyes
13127then :
13128 printf "%s\n" "#define HAVE_FSYNC 1" >>confdefs.h
13129
13130fi
13131ac_fn_c_check_func "$LINENO" "ftruncate64" "ac_cv_func_ftruncate64"
13132if test "x$ac_cv_func_ftruncate64" = xyes
13133then :
13134 printf "%s\n" "#define HAVE_FTRUNCATE64 1" >>confdefs.h
13135
13136fi
13137ac_fn_c_check_func "$LINENO" "futimes" "ac_cv_func_futimes"
13138if test "x$ac_cv_func_futimes" = xyes
13139then :
13140 printf "%s\n" "#define HAVE_FUTIMES 1" >>confdefs.h
13141
13142fi
13143ac_fn_c_check_func "$LINENO" "getcwd" "ac_cv_func_getcwd"
13144if test "x$ac_cv_func_getcwd" = xyes
13145then :
13146 printf "%s\n" "#define HAVE_GETCWD 1" >>confdefs.h
13147
13148fi
13149ac_fn_c_check_func "$LINENO" "getdtablesize" "ac_cv_func_getdtablesize"
13150if test "x$ac_cv_func_getdtablesize" = xyes
13151then :
13152 printf "%s\n" "#define HAVE_GETDTABLESIZE 1" >>confdefs.h
13153
13154fi
13155ac_fn_c_check_func "$LINENO" "getentropy" "ac_cv_func_getentropy"
13156if test "x$ac_cv_func_getentropy" = xyes
13157then :
13158 printf "%s\n" "#define HAVE_GETENTROPY 1" >>confdefs.h
13159
13160fi
13161ac_fn_c_check_func "$LINENO" "gethostname" "ac_cv_func_gethostname"
13162if test "x$ac_cv_func_gethostname" = xyes
13163then :
13164 printf "%s\n" "#define HAVE_GETHOSTNAME 1" >>confdefs.h
13165
13166fi
13167ac_fn_c_check_func "$LINENO" "getmntinfo" "ac_cv_func_getmntinfo"
13168if test "x$ac_cv_func_getmntinfo" = xyes
13169then :
13170 printf "%s\n" "#define HAVE_GETMNTINFO 1" >>confdefs.h
13171
13172fi
13173ac_fn_c_check_func "$LINENO" "getpwuid_r" "ac_cv_func_getpwuid_r"
13174if test "x$ac_cv_func_getpwuid_r" = xyes
13175then :
13176 printf "%s\n" "#define HAVE_GETPWUID_R 1" >>confdefs.h
13177
13178fi
13179ac_fn_c_check_func "$LINENO" "getrandom" "ac_cv_func_getrandom"
13180if test "x$ac_cv_func_getrandom" = xyes
13181then :
13182 printf "%s\n" "#define HAVE_GETRANDOM 1" >>confdefs.h
13183
13184fi
13185ac_fn_c_check_func "$LINENO" "getrlimit" "ac_cv_func_getrlimit"
13186if test "x$ac_cv_func_getrlimit" = xyes
13187then :
13188 printf "%s\n" "#define HAVE_GETRLIMIT 1" >>confdefs.h
13189
13190fi
13191ac_fn_c_check_func "$LINENO" "getrusage" "ac_cv_func_getrusage"
13192if test "x$ac_cv_func_getrusage" = xyes
13193then :
13194 printf "%s\n" "#define HAVE_GETRUSAGE 1" >>confdefs.h
13195
13196fi
13197ac_fn_c_check_func "$LINENO" "jrand48" "ac_cv_func_jrand48"
13198if test "x$ac_cv_func_jrand48" = xyes
13199then :
13200 printf "%s\n" "#define HAVE_JRAND48 1" >>confdefs.h
13201
13202fi
13203ac_fn_c_check_func "$LINENO" "keyctl" "ac_cv_func_keyctl"
13204if test "x$ac_cv_func_keyctl" = xyes
13205then :
13206 printf "%s\n" "#define HAVE_KEYCTL 1" >>confdefs.h
13207
13208fi
13209ac_fn_c_check_func "$LINENO" "llistxattr" "ac_cv_func_llistxattr"
13210if test "x$ac_cv_func_llistxattr" = xyes
13211then :
13212 printf "%s\n" "#define HAVE_LLISTXATTR 1" >>confdefs.h
13213
13214fi
13215ac_fn_c_check_func "$LINENO" "llseek" "ac_cv_func_llseek"
13216if test "x$ac_cv_func_llseek" = xyes
13217then :
13218 printf "%s\n" "#define HAVE_LLSEEK 1" >>confdefs.h
13219
13220fi
13221ac_fn_c_check_func "$LINENO" "lseek64" "ac_cv_func_lseek64"
13222if test "x$ac_cv_func_lseek64" = xyes
13223then :
13224 printf "%s\n" "#define HAVE_LSEEK64 1" >>confdefs.h
13225
13226fi
13227ac_fn_c_check_func "$LINENO" "mallinfo" "ac_cv_func_mallinfo"
13228if test "x$ac_cv_func_mallinfo" = xyes
13229then :
13230 printf "%s\n" "#define HAVE_MALLINFO 1" >>confdefs.h
13231
13232fi
13233ac_fn_c_check_func "$LINENO" "mallinfo2" "ac_cv_func_mallinfo2"
13234if test "x$ac_cv_func_mallinfo2" = xyes
13235then :
13236 printf "%s\n" "#define HAVE_MALLINFO2 1" >>confdefs.h
13237
13238fi
13239ac_fn_c_check_func "$LINENO" "mbstowcs" "ac_cv_func_mbstowcs"
13240if test "x$ac_cv_func_mbstowcs" = xyes
13241then :
13242 printf "%s\n" "#define HAVE_MBSTOWCS 1" >>confdefs.h
13243
13244fi
13245ac_fn_c_check_func "$LINENO" "memalign" "ac_cv_func_memalign"
13246if test "x$ac_cv_func_memalign" = xyes
13247then :
13248 printf "%s\n" "#define HAVE_MEMALIGN 1" >>confdefs.h
13249
13250fi
13251ac_fn_c_check_func "$LINENO" "mempcpy" "ac_cv_func_mempcpy"
13252if test "x$ac_cv_func_mempcpy" = xyes
13253then :
13254 printf "%s\n" "#define HAVE_MEMPCPY 1" >>confdefs.h
13255
13256fi
13257ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
13258if test "x$ac_cv_func_mmap" = xyes
13259then :
13260 printf "%s\n" "#define HAVE_MMAP 1" >>confdefs.h
13261
13262fi
13263ac_fn_c_check_func "$LINENO" "msync" "ac_cv_func_msync"
13264if test "x$ac_cv_func_msync" = xyes
13265then :
13266 printf "%s\n" "#define HAVE_MSYNC 1" >>confdefs.h
13267
13268fi
13269ac_fn_c_check_func "$LINENO" "nanosleep" "ac_cv_func_nanosleep"
13270if test "x$ac_cv_func_nanosleep" = xyes
13271then :
13272 printf "%s\n" "#define HAVE_NANOSLEEP 1" >>confdefs.h
13273
13274fi
13275ac_fn_c_check_func "$LINENO" "open64" "ac_cv_func_open64"
13276if test "x$ac_cv_func_open64" = xyes
13277then :
13278 printf "%s\n" "#define HAVE_OPEN64 1" >>confdefs.h
13279
13280fi
13281ac_fn_c_check_func "$LINENO" "pathconf" "ac_cv_func_pathconf"
13282if test "x$ac_cv_func_pathconf" = xyes
13283then :
13284 printf "%s\n" "#define HAVE_PATHCONF 1" >>confdefs.h
13285
13286fi
13287ac_fn_c_check_func "$LINENO" "posix_fadvise" "ac_cv_func_posix_fadvise"
13288if test "x$ac_cv_func_posix_fadvise" = xyes
13289then :
13290 printf "%s\n" "#define HAVE_POSIX_FADVISE 1" >>confdefs.h
13291
50e1e10f 13292fi
54445dc2
TT
13293ac_fn_c_check_func "$LINENO" "posix_fadvise64" "ac_cv_func_posix_fadvise64"
13294if test "x$ac_cv_func_posix_fadvise64" = xyes
13295then :
13296 printf "%s\n" "#define HAVE_POSIX_FADVISE64 1" >>confdefs.h
50e1e10f 13297
84ea6e70 13298fi
54445dc2
TT
13299ac_fn_c_check_func "$LINENO" "posix_memalign" "ac_cv_func_posix_memalign"
13300if test "x$ac_cv_func_posix_memalign" = xyes
13301then :
13302 printf "%s\n" "#define HAVE_POSIX_MEMALIGN 1" >>confdefs.h
13303
84ea6e70 13304fi
54445dc2
TT
13305ac_fn_c_check_func "$LINENO" "prctl" "ac_cv_func_prctl"
13306if test "x$ac_cv_func_prctl" = xyes
13307then :
13308 printf "%s\n" "#define HAVE_PRCTL 1" >>confdefs.h
e1052144 13309
54445dc2
TT
13310fi
13311ac_fn_c_check_func "$LINENO" "pread" "ac_cv_func_pread"
13312if test "x$ac_cv_func_pread" = xyes
13313then :
13314 printf "%s\n" "#define HAVE_PREAD 1" >>confdefs.h
d1154eb4 13315
54445dc2
TT
13316fi
13317ac_fn_c_check_func "$LINENO" "pwrite" "ac_cv_func_pwrite"
13318if test "x$ac_cv_func_pwrite" = xyes
13319then :
13320 printf "%s\n" "#define HAVE_PWRITE 1" >>confdefs.h
57aa50d4 13321
6c65d251 13322fi
54445dc2
TT
13323ac_fn_c_check_func "$LINENO" "pread64" "ac_cv_func_pread64"
13324if test "x$ac_cv_func_pread64" = xyes
13325then :
13326 printf "%s\n" "#define HAVE_PREAD64 1" >>confdefs.h
b0cacab0 13327
54445dc2
TT
13328fi
13329ac_fn_c_check_func "$LINENO" "pwrite64" "ac_cv_func_pwrite64"
13330if test "x$ac_cv_func_pwrite64" = xyes
13331then :
13332 printf "%s\n" "#define HAVE_PWRITE64 1" >>confdefs.h
84ea6e70 13333
4e5f24ae
TT
13334fi
13335ac_fn_c_check_func "$LINENO" "qsort_r" "ac_cv_func_qsort_r"
13336if test "x$ac_cv_func_qsort_r" = xyes
13337then :
13338 printf "%s\n" "#define HAVE_QSORT_R 1" >>confdefs.h
13339
50e1e10f 13340fi
54445dc2
TT
13341ac_fn_c_check_func "$LINENO" "secure_getenv" "ac_cv_func_secure_getenv"
13342if test "x$ac_cv_func_secure_getenv" = xyes
13343then :
13344 printf "%s\n" "#define HAVE_SECURE_GETENV 1" >>confdefs.h
b0cacab0 13345
54445dc2
TT
13346fi
13347ac_fn_c_check_func "$LINENO" "setmntent" "ac_cv_func_setmntent"
13348if test "x$ac_cv_func_setmntent" = xyes
13349then :
13350 printf "%s\n" "#define HAVE_SETMNTENT 1" >>confdefs.h
9ed8e5fe 13351
9ed8e5fe 13352fi
54445dc2
TT
13353ac_fn_c_check_func "$LINENO" "setresgid" "ac_cv_func_setresgid"
13354if test "x$ac_cv_func_setresgid" = xyes
13355then :
13356 printf "%s\n" "#define HAVE_SETRESGID 1" >>confdefs.h
13357
9ed8e5fe 13358fi
54445dc2
TT
13359ac_fn_c_check_func "$LINENO" "setresuid" "ac_cv_func_setresuid"
13360if test "x$ac_cv_func_setresuid" = xyes
13361then :
13362 printf "%s\n" "#define HAVE_SETRESUID 1" >>confdefs.h
188bf39a 13363
54445dc2
TT
13364fi
13365ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
13366if test "x$ac_cv_func_snprintf" = xyes
13367then :
13368 printf "%s\n" "#define HAVE_SNPRINTF 1" >>confdefs.h
7154d974 13369
e598c29b 13370fi
54445dc2
TT
13371ac_fn_c_check_func "$LINENO" "srandom" "ac_cv_func_srandom"
13372if test "x$ac_cv_func_srandom" = xyes
13373then :
13374 printf "%s\n" "#define HAVE_SRANDOM 1" >>confdefs.h
e598c29b 13375
54445dc2
TT
13376fi
13377ac_fn_c_check_func "$LINENO" "stpcpy" "ac_cv_func_stpcpy"
13378if test "x$ac_cv_func_stpcpy" = xyes
13379then :
13380 printf "%s\n" "#define HAVE_STPCPY 1" >>confdefs.h
e598c29b 13381
e598c29b 13382fi
54445dc2
TT
13383ac_fn_c_check_func "$LINENO" "strcasecmp" "ac_cv_func_strcasecmp"
13384if test "x$ac_cv_func_strcasecmp" = xyes
13385then :
13386 printf "%s\n" "#define HAVE_STRCASECMP 1" >>confdefs.h
13387
e598c29b 13388fi
54445dc2
TT
13389ac_fn_c_check_func "$LINENO" "strdup" "ac_cv_func_strdup"
13390if test "x$ac_cv_func_strdup" = xyes
13391then :
13392 printf "%s\n" "#define HAVE_STRDUP 1" >>confdefs.h
e598c29b 13393
54445dc2
TT
13394fi
13395ac_fn_c_check_func "$LINENO" "strnlen" "ac_cv_func_strnlen"
13396if test "x$ac_cv_func_strnlen" = xyes
13397then :
13398 printf "%s\n" "#define HAVE_STRNLEN 1" >>confdefs.h
e598c29b 13399
7154d974 13400fi
54445dc2
TT
13401ac_fn_c_check_func "$LINENO" "strptime" "ac_cv_func_strptime"
13402if test "x$ac_cv_func_strptime" = xyes
13403then :
13404 printf "%s\n" "#define HAVE_STRPTIME 1" >>confdefs.h
7154d974 13405
54445dc2
TT
13406fi
13407ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
13408if test "x$ac_cv_func_strtoull" = xyes
13409then :
13410 printf "%s\n" "#define HAVE_STRTOULL 1" >>confdefs.h
57aa50d4 13411
9ed8e5fe 13412fi
54445dc2
TT
13413ac_fn_c_check_func "$LINENO" "sync_file_range" "ac_cv_func_sync_file_range"
13414if test "x$ac_cv_func_sync_file_range" = xyes
13415then :
13416 printf "%s\n" "#define HAVE_SYNC_FILE_RANGE 1" >>confdefs.h
13417
9ed8e5fe 13418fi
54445dc2
TT
13419ac_fn_c_check_func "$LINENO" "sysconf" "ac_cv_func_sysconf"
13420if test "x$ac_cv_func_sysconf" = xyes
13421then :
13422 printf "%s\n" "#define HAVE_SYSCONF 1" >>confdefs.h
188bf39a 13423
54445dc2
TT
13424fi
13425ac_fn_c_check_func "$LINENO" "usleep" "ac_cv_func_usleep"
13426if test "x$ac_cv_func_usleep" = xyes
13427then :
13428 printf "%s\n" "#define HAVE_USLEEP 1" >>confdefs.h
9ed8e5fe
ES
13429
13430fi
54445dc2
TT
13431ac_fn_c_check_func "$LINENO" "utime" "ac_cv_func_utime"
13432if test "x$ac_cv_func_utime" = xyes
13433then :
13434 printf "%s\n" "#define HAVE_UTIME 1" >>confdefs.h
9ed8e5fe
ES
13435
13436fi
54445dc2
TT
13437ac_fn_c_check_func "$LINENO" "utimes" "ac_cv_func_utimes"
13438if test "x$ac_cv_func_utimes" = xyes
13439then :
13440 printf "%s\n" "#define HAVE_UTIMES 1" >>confdefs.h
13441
32179ce2 13442fi
54445dc2
TT
13443ac_fn_c_check_func "$LINENO" "valloc" "ac_cv_func_valloc"
13444if test "x$ac_cv_func_valloc" = xyes
13445then :
13446 printf "%s\n" "#define HAVE_VALLOC 1" >>confdefs.h
21c84b71 13447
50e1e10f 13448fi
50e1e10f 13449
fc6d9d51 13450SOCKET_LIB=''
54445dc2
TT
13451{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for socket in -lsocket" >&5
13452printf %s "checking for socket in -lsocket... " >&6; }
13453if test ${ac_cv_lib_socket_socket+y}
13454then :
13455 printf %s "(cached) " >&6
13456else $as_nop
b0cacab0 13457 ac_check_lib_save_LIBS=$LIBS
fc6d9d51 13458LIBS="-lsocket $LIBS"
57aa50d4 13459cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b0cacab0 13460/* end confdefs.h. */
93636bde 13461
e1052144
TT
13462/* Override any GCC internal prototype to avoid an error.
13463 Use char because int might match the return type of a GCC
13464 builtin and then its argument prototype would still apply. */
b0cacab0
TT
13465char socket ();
13466int
54445dc2 13467main (void)
b0cacab0 13468{
e1052144 13469return socket ();
b0cacab0
TT
13470 ;
13471 return 0;
13472}
13473_ACEOF
54445dc2
TT
13474if ac_fn_c_try_link "$LINENO"
13475then :
b0cacab0 13476 ac_cv_lib_socket_socket=yes
54445dc2 13477else $as_nop
57aa50d4 13478 ac_cv_lib_socket_socket=no
b0cacab0 13479fi
54445dc2 13480rm -f core conftest.err conftest.$ac_objext conftest.beam \
57aa50d4 13481 conftest$ac_exeext conftest.$ac_ext
b0cacab0
TT
13482LIBS=$ac_check_lib_save_LIBS
13483fi
54445dc2
TT
13484{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_socket" >&5
13485printf "%s\n" "$ac_cv_lib_socket_socket" >&6; }
13486if test "x$ac_cv_lib_socket_socket" = xyes
13487then :
fc6d9d51 13488 SOCKET_LIB=-lsocket
50e1e10f 13489fi
fc6d9d51 13490
93636bde 13491
54445dc2
TT
13492{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for magic_file in -lmagic" >&5
13493printf %s "checking for magic_file in -lmagic... " >&6; }
13494if test ${ac_cv_lib_magic_magic_file+y}
13495then :
13496 printf %s "(cached) " >&6
13497else $as_nop
b291c11f
DW
13498 ac_check_lib_save_LIBS=$LIBS
13499LIBS="-lmagic $LIBS"
13500cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13501/* end confdefs.h. */
13502
13503/* Override any GCC internal prototype to avoid an error.
13504 Use char because int might match the return type of a GCC
13505 builtin and then its argument prototype would still apply. */
b291c11f
DW
13506char magic_file ();
13507int
54445dc2 13508main (void)
b291c11f
DW
13509{
13510return magic_file ();
13511 ;
13512 return 0;
13513}
13514_ACEOF
54445dc2
TT
13515if ac_fn_c_try_link "$LINENO"
13516then :
b291c11f 13517 ac_cv_lib_magic_magic_file=yes
54445dc2 13518else $as_nop
b291c11f
DW
13519 ac_cv_lib_magic_magic_file=no
13520fi
54445dc2 13521rm -f core conftest.err conftest.$ac_objext conftest.beam \
b291c11f
DW
13522 conftest$ac_exeext conftest.$ac_ext
13523LIBS=$ac_check_lib_save_LIBS
13524fi
54445dc2
TT
13525{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_magic_magic_file" >&5
13526printf "%s\n" "$ac_cv_lib_magic_magic_file" >&6; }
13527if test "x$ac_cv_lib_magic_magic_file" = xyes
13528then :
b291c11f 13529 MAGIC_LIB=-lmagic
54445dc2
TT
13530ac_fn_c_check_header_compile "$LINENO" "magic.h" "ac_cv_header_magic_h" "$ac_includes_default"
13531if test "x$ac_cv_header_magic_h" = xyes
13532then :
13533 printf "%s\n" "#define HAVE_MAGIC_H 1" >>confdefs.h
b291c11f
DW
13534
13535fi
13536
b291c11f
DW
13537fi
13538
32179ce2 13539if test "$ac_cv_func_dlopen" = yes ; then
d2e3c0dc
TT
13540 MAGIC_LIB=$DLOPEN_LIB
13541fi
b291c11f 13542
54445dc2
TT
13543{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for clock_gettime in -lrt" >&5
13544printf %s "checking for clock_gettime in -lrt... " >&6; }
13545if test ${ac_cv_lib_rt_clock_gettime+y}
13546then :
13547 printf %s "(cached) " >&6
13548else $as_nop
c94da047
TT
13549 ac_check_lib_save_LIBS=$LIBS
13550LIBS="-lrt $LIBS"
13551cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13552/* end confdefs.h. */
13553
13554/* Override any GCC internal prototype to avoid an error.
13555 Use char because int might match the return type of a GCC
13556 builtin and then its argument prototype would still apply. */
c94da047
TT
13557char clock_gettime ();
13558int
54445dc2 13559main (void)
c94da047
TT
13560{
13561return clock_gettime ();
13562 ;
13563 return 0;
13564}
13565_ACEOF
54445dc2
TT
13566if ac_fn_c_try_link "$LINENO"
13567then :
c94da047 13568 ac_cv_lib_rt_clock_gettime=yes
54445dc2 13569else $as_nop
c94da047
TT
13570 ac_cv_lib_rt_clock_gettime=no
13571fi
54445dc2 13572rm -f core conftest.err conftest.$ac_objext conftest.beam \
c94da047
TT
13573 conftest$ac_exeext conftest.$ac_ext
13574LIBS=$ac_check_lib_save_LIBS
13575fi
54445dc2
TT
13576{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_clock_gettime" >&5
13577printf "%s\n" "$ac_cv_lib_rt_clock_gettime" >&6; }
13578if test "x$ac_cv_lib_rt_clock_gettime" = xyes
13579then :
c94da047
TT
13580 CLOCK_GETTIME_LIB=-lrt
13581fi
13582
13583
81cbf1ef
DW
13584FUSE_CMT=
13585FUSE_LIB=
13586# Check whether --enable-fuse2fs was given.
54445dc2
TT
13587if test ${enable_fuse2fs+y}
13588then :
81cbf1ef
DW
13589 enableval=$enable_fuse2fs; if test "$enableval" = "no"
13590then
13591 FUSE_CMT="#"
54445dc2
TT
13592 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Disabling fuse2fs" >&5
13593printf "%s\n" "Disabling fuse2fs" >&6; }
81cbf1ef 13594else
54445dc2 13595 for ac_header in pthread.h fuse.h
81cbf1ef 13596do :
54445dc2 13597 as_ac_Header=`printf "%s\n" "ac_cv_header_$ac_header" | $as_tr_sh`
81cbf1ef
DW
13598ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "#define _FILE_OFFSET_BITS 64
13599#define FUSE_USE_VERSION 29
13600"
54445dc2
TT
13601if eval test \"x\$"$as_ac_Header"\" = x"yes"
13602then :
81cbf1ef 13603 cat >>confdefs.h <<_ACEOF
54445dc2 13604#define `printf "%s\n" "HAVE_$ac_header" | $as_tr_cpp` 1
81cbf1ef
DW
13605_ACEOF
13606
54445dc2
TT
13607else $as_nop
13608 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
13609printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
81cbf1ef
DW
13610as_fn_error $? "Cannot find fuse2fs headers.
13611See \`config.log' for more details" "$LINENO" 5; }
13612fi
13613
13614done
13615
81cbf1ef
DW
13616 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13617/* end confdefs.h. */
13618#define FUSE_USE_VERSION 29
13619#ifdef __linux__
13620#include <linux/fs.h>
13621#include <linux/falloc.h>
13622#include <linux/xattr.h>
13623#endif
13624
13625int
54445dc2 13626main (void)
81cbf1ef
DW
13627{
13628
13629 ;
13630 return 0;
13631}
13632_ACEOF
54445dc2
TT
13633if ac_fn_c_try_cpp "$LINENO"
13634then :
81cbf1ef 13635
54445dc2
TT
13636else $as_nop
13637 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
13638printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
81cbf1ef
DW
13639as_fn_error $? "Cannot find fuse2fs Linux headers.
13640See \`config.log' for more details" "$LINENO" 5; }
13641fi
13642rm -f conftest.err conftest.i conftest.$ac_ext
13643
54445dc2
TT
13644 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fuse_main in -losxfuse" >&5
13645printf %s "checking for fuse_main in -losxfuse... " >&6; }
13646if test ${ac_cv_lib_osxfuse_fuse_main+y}
13647then :
13648 printf %s "(cached) " >&6
13649else $as_nop
81cbf1ef
DW
13650 ac_check_lib_save_LIBS=$LIBS
13651LIBS="-losxfuse $LIBS"
13652cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13653/* end confdefs.h. */
13654
13655/* Override any GCC internal prototype to avoid an error.
13656 Use char because int might match the return type of a GCC
13657 builtin and then its argument prototype would still apply. */
81cbf1ef
DW
13658char fuse_main ();
13659int
54445dc2 13660main (void)
81cbf1ef
DW
13661{
13662return fuse_main ();
13663 ;
13664 return 0;
13665}
13666_ACEOF
54445dc2
TT
13667if ac_fn_c_try_link "$LINENO"
13668then :
81cbf1ef 13669 ac_cv_lib_osxfuse_fuse_main=yes
54445dc2 13670else $as_nop
81cbf1ef
DW
13671 ac_cv_lib_osxfuse_fuse_main=no
13672fi
54445dc2 13673rm -f core conftest.err conftest.$ac_objext conftest.beam \
81cbf1ef
DW
13674 conftest$ac_exeext conftest.$ac_ext
13675LIBS=$ac_check_lib_save_LIBS
13676fi
54445dc2
TT
13677{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_osxfuse_fuse_main" >&5
13678printf "%s\n" "$ac_cv_lib_osxfuse_fuse_main" >&6; }
13679if test "x$ac_cv_lib_osxfuse_fuse_main" = xyes
13680then :
81cbf1ef 13681 FUSE_LIB=-losxfuse
54445dc2
TT
13682else $as_nop
13683 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fuse_main in -lfuse" >&5
13684printf %s "checking for fuse_main in -lfuse... " >&6; }
13685if test ${ac_cv_lib_fuse_fuse_main+y}
13686then :
13687 printf %s "(cached) " >&6
13688else $as_nop
81cbf1ef
DW
13689 ac_check_lib_save_LIBS=$LIBS
13690LIBS="-lfuse $LIBS"
13691cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13692/* end confdefs.h. */
13693
13694/* Override any GCC internal prototype to avoid an error.
13695 Use char because int might match the return type of a GCC
13696 builtin and then its argument prototype would still apply. */
81cbf1ef
DW
13697char fuse_main ();
13698int
54445dc2 13699main (void)
81cbf1ef
DW
13700{
13701return fuse_main ();
13702 ;
13703 return 0;
13704}
13705_ACEOF
54445dc2
TT
13706if ac_fn_c_try_link "$LINENO"
13707then :
81cbf1ef 13708 ac_cv_lib_fuse_fuse_main=yes
54445dc2 13709else $as_nop
81cbf1ef
DW
13710 ac_cv_lib_fuse_fuse_main=no
13711fi
54445dc2 13712rm -f core conftest.err conftest.$ac_objext conftest.beam \
81cbf1ef
DW
13713 conftest$ac_exeext conftest.$ac_ext
13714LIBS=$ac_check_lib_save_LIBS
13715fi
54445dc2
TT
13716{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fuse_fuse_main" >&5
13717printf "%s\n" "$ac_cv_lib_fuse_fuse_main" >&6; }
13718if test "x$ac_cv_lib_fuse_fuse_main" = xyes
13719then :
81cbf1ef 13720 FUSE_LIB=-lfuse
54445dc2
TT
13721else $as_nop
13722 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
13723printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
81cbf1ef
DW
13724as_fn_error $? "Cannot find fuse library.
13725See \`config.log' for more details" "$LINENO" 5; }
13726fi
13727
13728fi
13729
54445dc2
TT
13730 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling fuse2fs" >&5
13731printf "%s\n" "Enabling fuse2fs" >&6; }
81cbf1ef
DW
13732fi
13733
54445dc2
TT
13734else $as_nop
13735 for ac_header in pthread.h fuse.h
81cbf1ef 13736do :
54445dc2 13737 as_ac_Header=`printf "%s\n" "ac_cv_header_$ac_header" | $as_tr_sh`
81cbf1ef
DW
13738ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "#define _FILE_OFFSET_BITS 64
13739#define FUSE_USE_VERSION 29
13740#ifdef __linux__
13741# include <linux/fs.h>
13742# include <linux/falloc.h>
13743# include <linux/xattr.h>
13744#endif
13745"
54445dc2
TT
13746if eval test \"x\$"$as_ac_Header"\" = x"yes"
13747then :
81cbf1ef 13748 cat >>confdefs.h <<_ACEOF
54445dc2 13749#define `printf "%s\n" "HAVE_$ac_header" | $as_tr_cpp` 1
81cbf1ef
DW
13750_ACEOF
13751
54445dc2 13752else $as_nop
81cbf1ef
DW
13753 FUSE_CMT="#"
13754fi
13755
13756done
81cbf1ef
DW
13757if test -z "$FUSE_CMT"
13758then
54445dc2
TT
13759 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fuse_main in -losxfuse" >&5
13760printf %s "checking for fuse_main in -losxfuse... " >&6; }
13761if test ${ac_cv_lib_osxfuse_fuse_main+y}
13762then :
13763 printf %s "(cached) " >&6
13764else $as_nop
81cbf1ef
DW
13765 ac_check_lib_save_LIBS=$LIBS
13766LIBS="-losxfuse $LIBS"
13767cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13768/* end confdefs.h. */
13769
13770/* Override any GCC internal prototype to avoid an error.
13771 Use char because int might match the return type of a GCC
13772 builtin and then its argument prototype would still apply. */
81cbf1ef
DW
13773char fuse_main ();
13774int
54445dc2 13775main (void)
81cbf1ef
DW
13776{
13777return fuse_main ();
13778 ;
13779 return 0;
13780}
13781_ACEOF
54445dc2
TT
13782if ac_fn_c_try_link "$LINENO"
13783then :
81cbf1ef 13784 ac_cv_lib_osxfuse_fuse_main=yes
54445dc2 13785else $as_nop
81cbf1ef
DW
13786 ac_cv_lib_osxfuse_fuse_main=no
13787fi
54445dc2 13788rm -f core conftest.err conftest.$ac_objext conftest.beam \
81cbf1ef
DW
13789 conftest$ac_exeext conftest.$ac_ext
13790LIBS=$ac_check_lib_save_LIBS
13791fi
54445dc2
TT
13792{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_osxfuse_fuse_main" >&5
13793printf "%s\n" "$ac_cv_lib_osxfuse_fuse_main" >&6; }
13794if test "x$ac_cv_lib_osxfuse_fuse_main" = xyes
13795then :
81cbf1ef 13796 FUSE_LIB=-losxfuse
54445dc2
TT
13797else $as_nop
13798 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fuse_main in -lfuse" >&5
13799printf %s "checking for fuse_main in -lfuse... " >&6; }
13800if test ${ac_cv_lib_fuse_fuse_main+y}
13801then :
13802 printf %s "(cached) " >&6
13803else $as_nop
81cbf1ef
DW
13804 ac_check_lib_save_LIBS=$LIBS
13805LIBS="-lfuse $LIBS"
13806cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13807/* end confdefs.h. */
13808
13809/* Override any GCC internal prototype to avoid an error.
13810 Use char because int might match the return type of a GCC
13811 builtin and then its argument prototype would still apply. */
81cbf1ef
DW
13812char fuse_main ();
13813int
54445dc2 13814main (void)
81cbf1ef
DW
13815{
13816return fuse_main ();
13817 ;
13818 return 0;
13819}
13820_ACEOF
54445dc2
TT
13821if ac_fn_c_try_link "$LINENO"
13822then :
81cbf1ef 13823 ac_cv_lib_fuse_fuse_main=yes
54445dc2 13824else $as_nop
81cbf1ef
DW
13825 ac_cv_lib_fuse_fuse_main=no
13826fi
54445dc2 13827rm -f core conftest.err conftest.$ac_objext conftest.beam \
81cbf1ef
DW
13828 conftest$ac_exeext conftest.$ac_ext
13829LIBS=$ac_check_lib_save_LIBS
13830fi
54445dc2
TT
13831{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fuse_fuse_main" >&5
13832printf "%s\n" "$ac_cv_lib_fuse_fuse_main" >&6; }
13833if test "x$ac_cv_lib_fuse_fuse_main" = xyes
13834then :
81cbf1ef 13835 FUSE_LIB=-lfuse
54445dc2 13836else $as_nop
81cbf1ef
DW
13837 FUSE_CMT="#"
13838fi
13839
13840fi
13841
13842fi
13843if test -z "$FUSE_CMT"
13844then
54445dc2
TT
13845 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Enabling fuse2fs by default." >&5
13846printf "%s\n" "Enabling fuse2fs by default." >&6; }
81cbf1ef
DW
13847fi
13848
13849fi
13850
13851
13852
54445dc2
TT
13853{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for optreset" >&5
13854printf %s "checking for optreset... " >&6; }
13855if test ${ac_cv_have_optreset+y}
13856then :
13857 printf %s "(cached) " >&6
13858else $as_nop
57aa50d4 13859 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
d7f45af8 13860/* end confdefs.h. */
57aa50d4
TT
13861#include <unistd.h>
13862
13863_ACEOF
13864if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
54445dc2
TT
13865 $EGREP "optreset" >/dev/null 2>&1
13866then :
57aa50d4 13867 ac_cv_have_optreset=yes
54445dc2 13868else $as_nop
57aa50d4
TT
13869 ac_cv_have_optreset=no
13870fi
54445dc2 13871rm -rf conftest*
d7f45af8 13872
d7f45af8 13873fi
54445dc2
TT
13874{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_optreset" >&5
13875printf "%s\n" "$ac_cv_have_optreset" >&6; }
57aa50d4 13876if test $ac_cv_have_optreset = yes; then
d1154eb4 13877
54445dc2 13878printf "%s\n" "#define HAVE_OPTRESET 1" >>confdefs.h
d7f45af8 13879
d7f45af8 13880fi
d1154eb4 13881
57aa50d4 13882SEM_INIT_LIB=''
cfb8e0bd
TT
13883echo GL_THREADS_API: ${gl_threads_api}
13884if test "${gl_threads_api}" != none
13885then
13886 ac_fn_c_check_func "$LINENO" "sem_init" "ac_cv_func_sem_init"
54445dc2
TT
13887if test "x$ac_cv_func_sem_init" = xyes
13888then :
13889
13890else $as_nop
13891 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sem_init in -lpthread" >&5
13892printf %s "checking for sem_init in -lpthread... " >&6; }
13893if test ${ac_cv_lib_pthread_sem_init+y}
13894then :
13895 printf %s "(cached) " >&6
13896else $as_nop
d7f45af8
TT
13897 ac_check_lib_save_LIBS=$LIBS
13898LIBS="-lpthread $LIBS"
57aa50d4 13899cat confdefs.h - <<_ACEOF >conftest.$ac_ext
d7f45af8
TT
13900/* end confdefs.h. */
13901
13902/* Override any GCC internal prototype to avoid an error.
13903 Use char because int might match the return type of a GCC
13904 builtin and then its argument prototype would still apply. */
d7f45af8
TT
13905char sem_init ();
13906int
54445dc2 13907main (void)
d7f45af8
TT
13908{
13909return sem_init ();
13910 ;
13911 return 0;
13912}
13913_ACEOF
54445dc2
TT
13914if ac_fn_c_try_link "$LINENO"
13915then :
d7f45af8 13916 ac_cv_lib_pthread_sem_init=yes
54445dc2 13917else $as_nop
57aa50d4 13918 ac_cv_lib_pthread_sem_init=no
d7f45af8 13919fi
54445dc2 13920rm -f core conftest.err conftest.$ac_objext conftest.beam \
57aa50d4 13921 conftest$ac_exeext conftest.$ac_ext
d7f45af8
TT
13922LIBS=$ac_check_lib_save_LIBS
13923fi
54445dc2
TT
13924{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_sem_init" >&5
13925printf "%s\n" "$ac_cv_lib_pthread_sem_init" >&6; }
13926if test "x$ac_cv_lib_pthread_sem_init" = xyes
13927then :
13928 printf "%s\n" "#define HAVE_SEM_INIT 1" >>confdefs.h
d7f45af8
TT
13929
13930 SEM_INIT_LIB=-lpthread
54445dc2
TT
13931else $as_nop
13932 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sem_init in -lrt" >&5
13933printf %s "checking for sem_init in -lrt... " >&6; }
13934if test ${ac_cv_lib_rt_sem_init+y}
13935then :
13936 printf %s "(cached) " >&6
13937else $as_nop
d7f45af8
TT
13938 ac_check_lib_save_LIBS=$LIBS
13939LIBS="-lrt $LIBS"
57aa50d4 13940cat confdefs.h - <<_ACEOF >conftest.$ac_ext
d7f45af8
TT
13941/* end confdefs.h. */
13942
13943/* Override any GCC internal prototype to avoid an error.
13944 Use char because int might match the return type of a GCC
13945 builtin and then its argument prototype would still apply. */
d7f45af8
TT
13946char sem_init ();
13947int
54445dc2 13948main (void)
d7f45af8
TT
13949{
13950return sem_init ();
13951 ;
13952 return 0;
13953}
13954_ACEOF
54445dc2
TT
13955if ac_fn_c_try_link "$LINENO"
13956then :
d7f45af8 13957 ac_cv_lib_rt_sem_init=yes
54445dc2 13958else $as_nop
57aa50d4 13959 ac_cv_lib_rt_sem_init=no
d7f45af8 13960fi
54445dc2 13961rm -f core conftest.err conftest.$ac_objext conftest.beam \
57aa50d4 13962 conftest$ac_exeext conftest.$ac_ext
d7f45af8
TT
13963LIBS=$ac_check_lib_save_LIBS
13964fi
54445dc2
TT
13965{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_sem_init" >&5
13966printf "%s\n" "$ac_cv_lib_rt_sem_init" >&6; }
13967if test "x$ac_cv_lib_rt_sem_init" = xyes
13968then :
13969 printf "%s\n" "#define HAVE_SEM_INIT 1" >>confdefs.h
d7f45af8
TT
13970
13971 SEM_INIT_LIB=-lrt
54445dc2
TT
13972else $as_nop
13973 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sem_init in -lposix4" >&5
13974printf %s "checking for sem_init in -lposix4... " >&6; }
13975if test ${ac_cv_lib_posix4_sem_init+y}
13976then :
13977 printf %s "(cached) " >&6
13978else $as_nop
d7f45af8
TT
13979 ac_check_lib_save_LIBS=$LIBS
13980LIBS="-lposix4 $LIBS"
57aa50d4 13981cat confdefs.h - <<_ACEOF >conftest.$ac_ext
d7f45af8
TT
13982/* end confdefs.h. */
13983
13984/* Override any GCC internal prototype to avoid an error.
13985 Use char because int might match the return type of a GCC
13986 builtin and then its argument prototype would still apply. */
d7f45af8
TT
13987char sem_init ();
13988int
54445dc2 13989main (void)
d7f45af8
TT
13990{
13991return sem_init ();
13992 ;
13993 return 0;
13994}
13995_ACEOF
54445dc2
TT
13996if ac_fn_c_try_link "$LINENO"
13997then :
d7f45af8 13998 ac_cv_lib_posix4_sem_init=yes
54445dc2 13999else $as_nop
57aa50d4 14000 ac_cv_lib_posix4_sem_init=no
d7f45af8 14001fi
54445dc2 14002rm -f core conftest.err conftest.$ac_objext conftest.beam \
57aa50d4 14003 conftest$ac_exeext conftest.$ac_ext
d7f45af8
TT
14004LIBS=$ac_check_lib_save_LIBS
14005fi
54445dc2
TT
14006{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix4_sem_init" >&5
14007printf "%s\n" "$ac_cv_lib_posix4_sem_init" >&6; }
14008if test "x$ac_cv_lib_posix4_sem_init" = xyes
14009then :
14010 printf "%s\n" "#define HAVE_SEM_INIT 1" >>confdefs.h
d7f45af8
TT
14011
14012 SEM_INIT_LIB=-lposix4
14013fi
14014
14015fi
14016
14017fi
14018
cfb8e0bd 14019fi
d7f45af8
TT
14020fi
14021
4e5f24ae
TT
14022if test "$ac_cv_func_qsort_r" != no
14023then :
14024
14025 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether qsort_r is GNU version" >&5
14026printf %s "checking whether qsort_r is GNU version... " >&6; }
14027if test ${e2_cv_gnu_qsort_r+y}
14028then :
14029 printf %s "(cached) " >&6
14030else $as_nop
14031 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14032/* end confdefs.h. */
14033
14034#include <stdlib.h>
14035void (qsort_r)(void *base, size_t nmemb, size_t size,
14036 int (*compar)(const void *, const void *, void *),
14037 void *arg);
14038
14039int
14040main (void)
14041{
14042
14043 ;
14044 return 0;
14045}
14046_ACEOF
14047if ac_fn_c_try_compile "$LINENO"
14048then :
14049 e2_cv_gnu_qsort_r=yes
14050else $as_nop
14051 e2_cv_gnu_qsort_r=no
14052fi
14053rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14054
14055fi
14056{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $e2_cv_gnu_qsort_r" >&5
14057printf "%s\n" "$e2_cv_gnu_qsort_r" >&6; }
14058 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether qsort_r is BSD version" >&5
14059printf %s "checking whether qsort_r is BSD version... " >&6; }
14060if test ${e2_cv_bsd_qsort_r+y}
14061then :
14062 printf %s "(cached) " >&6
14063else $as_nop
14064 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14065/* end confdefs.h. */
14066
14067#include <stdlib.h>
14068void (qsort_r)(void *base, size_t nmemb, size_t size,
14069 void *arg, int (*compar)(void *, const void *, const void *));
14070
14071int
14072main (void)
14073{
14074
14075 ;
14076 return 0;
14077}
14078_ACEOF
14079if ac_fn_c_try_compile "$LINENO"
14080then :
14081 e2_cv_bsd_qsort_r=yes
14082else $as_nop
14083 e2_cv_bsd_qsort_r=no
14084fi
14085rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14086
14087fi
14088{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $e2_cv_bsd_qsort_r" >&5
14089printf "%s\n" "$e2_cv_bsd_qsort_r" >&6; }
14090 case "$e2_cv_gnu_qsort_r:$e2_cv_bsd_qsort_r" in #(
14091 yes:no) :
14092
6eb00fb7
EB
14093
14094printf "%s\n" "#define HAVE_GNU_QSORT_R 1" >>confdefs.h
4e5f24ae
TT
14095
14096 ;; #(
14097 no:yes) :
14098
6eb00fb7
EB
14099
14100printf "%s\n" "#define HAVE_BSD_QSORT_R 1" >>confdefs.h
4e5f24ae
TT
14101
14102 ;; #(
14103 *) :
14104 ;;
14105esac
14106
14107fi
54445dc2
TT
14108{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for unified diff option" >&5
14109printf %s "checking for unified diff option... " >&6; }
27f991b0 14110if diff -u $0 $0 > /dev/null 2>&1 ; then
e54635de
TT
14111 UNI_DIFF_OPTS=-u
14112else
14113 UNI_DIFF_OPTS=-c
14114fi
54445dc2
TT
14115{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $UNI_DIFF_OPTS" >&5
14116printf "%s\n" "$UNI_DIFF_OPTS" >&6; }
e54635de 14117
8f3f29d3
TT
14118case "$host_os" in
14119linux*)
d1154eb4 14120
54445dc2 14121printf "%s\n" "#define HAVE_EXT2_IOCTLS 1" >>confdefs.h
50e1e10f 14122
8f3f29d3
TT
14123 ;;
14124esac
ea1a3fa2 14125
54445dc2 14126 printf %s "checking for mount 'nosuid' option... "
ea1a3fa2
NC
14127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14128/* end confdefs.h. */
14129#include <sys/mount.h>
14130int
54445dc2 14131main (void)
ea1a3fa2
NC
14132{
14133void *temp = (void *)(MS_NOSUID); (void) temp;
14134 ;
14135 return 0;
14136}
14137_ACEOF
54445dc2
TT
14138if ac_fn_c_try_compile "$LINENO"
14139then :
ea1a3fa2 14140
54445dc2 14141printf "%s\n" "#define HAVE_MOUNT_NOSUID 1" >>confdefs.h
ea1a3fa2
NC
14142
14143 ac_cv_mount_nosuid=yes
54445dc2
TT
14144 printf "%s\n" "yes"
14145else $as_nop
ea1a3fa2
NC
14146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14147/* end confdefs.h. */
14148#include <sys/mount.h>
14149int
54445dc2 14150main (void)
ea1a3fa2
NC
14151{
14152void *temp = (void *)(MNT_NOSUID); (void) temp;
14153 ;
14154 return 0;
14155}
14156_ACEOF
54445dc2
TT
14157if ac_fn_c_try_compile "$LINENO"
14158then :
ea1a3fa2 14159
54445dc2 14160printf "%s\n" "#define HAVE_MOUNT_NOSUID 1" >>confdefs.h
ea1a3fa2
NC
14161
14162 ac_cv_mount_nosuid=yes
54445dc2
TT
14163 printf "%s\n" "yes"
14164else $as_nop
ea1a3fa2 14165 ac_cv_mount_nosuid=no
54445dc2 14166 printf "%s\n" "no"
ea1a3fa2
NC
14167
14168fi
54445dc2 14169rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ea1a3fa2
NC
14170
14171fi
54445dc2 14172rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ea1a3fa2
NC
14173
14174
54445dc2 14175 printf %s "checking for mount 'nodev' option... "
ea1a3fa2
NC
14176 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14177/* end confdefs.h. */
14178#include <sys/mount.h>
14179int
54445dc2 14180main (void)
ea1a3fa2
NC
14181{
14182void *temp = (void *)(MS_NODEV); (void) temp;
14183 ;
14184 return 0;
14185}
14186_ACEOF
54445dc2
TT
14187if ac_fn_c_try_compile "$LINENO"
14188then :
ea1a3fa2 14189
54445dc2 14190printf "%s\n" "#define HAVE_MOUNT_NODEV 1" >>confdefs.h
ea1a3fa2
NC
14191
14192 ac_cv_mount_nodev=yes
54445dc2
TT
14193 printf "%s\n" "yes"
14194else $as_nop
ea1a3fa2
NC
14195 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14196/* end confdefs.h. */
14197#include <sys/mount.h>
14198int
54445dc2 14199main (void)
ea1a3fa2
NC
14200{
14201void *temp = (void *)(MNT_NODEV); (void) temp;
14202 ;
14203 return 0;
14204}
14205_ACEOF
54445dc2
TT
14206if ac_fn_c_try_compile "$LINENO"
14207then :
ea1a3fa2 14208
54445dc2 14209printf "%s\n" "#define HAVE_MOUNT_NODEV 1" >>confdefs.h
ea1a3fa2
NC
14210
14211 ac_cv_mount_nodev=yes
54445dc2
TT
14212 printf "%s\n" "yes"
14213else $as_nop
ea1a3fa2 14214 ac_cv_mount_nodev=no
54445dc2 14215 printf "%s\n" "no"
ea1a3fa2
NC
14216
14217fi
54445dc2 14218rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ea1a3fa2
NC
14219
14220fi
54445dc2 14221rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
ea1a3fa2 14222
4aece328 14223# Check whether --enable-lto was given.
54445dc2
TT
14224if test ${enable_lto+y}
14225then :
4aece328 14226 enableval=$enable_lto;
54445dc2 14227else $as_nop
139a3092 14228 enable_lto=no
4aece328
DW
14229fi
14230
14231if test "$enable_lto" = "yes" || test "$enable_lto" = "probe"; then
54445dc2
TT
14232 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if C compiler supports LTO" >&5
14233printf %s "checking if C compiler supports LTO... " >&6; }
4aece328
DW
14234 OLD_CFLAGS="$CFLAGS"
14235 OLD_LDFLAGS="$LDFLAGS"
49715704 14236 LTO_FLAGS="-g -flto -ffat-lto-objects"
4aece328
DW
14237 CFLAGS="$CFLAGS $LTO_FLAGS"
14238 LDFLAGS="$LDFLAGS $LTO_FLAGS"
14239 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14240/* end confdefs.h. */
14241
14242int
54445dc2 14243main (void)
4aece328
DW
14244{
14245
14246 ;
14247 return 0;
14248}
14249_ACEOF
54445dc2
TT
14250if ac_fn_c_try_link "$LINENO"
14251then :
14252 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14253printf "%s\n" "yes" >&6; }
4aece328
DW
14254 lto_cflags=$LTO_FLAGS
14255 lto_ldflags=$LTO_FLAGS
14256 # Extract the first word of "gcc-ar", so it can be a program name with args.
14257set dummy gcc-ar; ac_word=$2
54445dc2
TT
14258{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14259printf %s "checking for $ac_word... " >&6; }
14260if test ${ac_cv_path_gcc_ar+y}
14261then :
14262 printf %s "(cached) " >&6
14263else $as_nop
4aece328
DW
14264 case $gcc_ar in
14265 [\\/]* | ?:[\\/]*)
14266 ac_cv_path_gcc_ar="$gcc_ar" # Let the user override the test with a path.
14267 ;;
14268 *)
14269 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14270for as_dir in $PATH
14271do
14272 IFS=$as_save_IFS
54445dc2
TT
14273 case $as_dir in #(((
14274 '') as_dir=./ ;;
14275 */) ;;
14276 *) as_dir=$as_dir/ ;;
14277 esac
4aece328 14278 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
14279 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
14280 ac_cv_path_gcc_ar="$as_dir$ac_word$ac_exec_ext"
14281 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4aece328
DW
14282 break 2
14283 fi
14284done
14285 done
14286IFS=$as_save_IFS
14287
14288 ;;
14289esac
14290fi
14291gcc_ar=$ac_cv_path_gcc_ar
14292if test -n "$gcc_ar"; then
54445dc2
TT
14293 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gcc_ar" >&5
14294printf "%s\n" "$gcc_ar" >&6; }
4aece328 14295else
54445dc2
TT
14296 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14297printf "%s\n" "no" >&6; }
4aece328
DW
14298fi
14299
14300
14301 # Extract the first word of "gcc-ranlib", so it can be a program name with args.
14302set dummy gcc-ranlib; ac_word=$2
54445dc2
TT
14303{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14304printf %s "checking for $ac_word... " >&6; }
14305if test ${ac_cv_path_gcc_ranlib+y}
14306then :
14307 printf %s "(cached) " >&6
14308else $as_nop
4aece328
DW
14309 case $gcc_ranlib in
14310 [\\/]* | ?:[\\/]*)
14311 ac_cv_path_gcc_ranlib="$gcc_ranlib" # Let the user override the test with a path.
14312 ;;
14313 *)
14314 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14315for as_dir in $PATH
14316do
14317 IFS=$as_save_IFS
54445dc2
TT
14318 case $as_dir in #(((
14319 '') as_dir=./ ;;
14320 */) ;;
14321 *) as_dir=$as_dir/ ;;
14322 esac
4aece328 14323 for ac_exec_ext in '' $ac_executable_extensions; do
54445dc2
TT
14324 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
14325 ac_cv_path_gcc_ranlib="$as_dir$ac_word$ac_exec_ext"
14326 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4aece328
DW
14327 break 2
14328 fi
14329done
14330 done
14331IFS=$as_save_IFS
14332
14333 ;;
14334esac
14335fi
14336gcc_ranlib=$ac_cv_path_gcc_ranlib
14337if test -n "$gcc_ranlib"; then
54445dc2
TT
14338 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gcc_ranlib" >&5
14339printf "%s\n" "$gcc_ranlib" >&6; }
4aece328 14340else
54445dc2
TT
14341 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14342printf "%s\n" "no" >&6; }
4aece328
DW
14343fi
14344
14345
54445dc2
TT
14346else $as_nop
14347 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14348printf "%s\n" "no" >&6; }
4aece328 14349fi
54445dc2 14350rm -f core conftest.err conftest.$ac_objext conftest.beam \
4aece328
DW
14351 conftest$ac_exeext conftest.$ac_ext
14352 if test -x "$gcc_ar" && test -x "$gcc_ranlib"; then
14353 have_lto=yes
14354 AR="${gcc_ar}"
14355 RANLIB="${gcc_ranlib}"
14356 fi
14357 CFLAGS="${OLD_CFLAGS}"
14358 LDFLAGS="${OLD_LDFLAGS}"
14359
14360
14361
14362fi
14363if test "$enable_lto" = "yes" && test "$have_lto" != "yes"; then
14364 as_fn_error $? "LTO not supported by compiler." "$LINENO" 5
14365fi
1c2a76ae 14366# Check whether --enable-ubsan was given.
54445dc2
TT
14367if test ${enable_ubsan+y}
14368then :
1c2a76ae 14369 enableval=$enable_ubsan;
54445dc2 14370else $as_nop
1c2a76ae
DW
14371 enable_ubsan=no
14372fi
14373
14374if test "$enable_ubsan" = "yes" || test "$enable_ubsan" = "probe"; then
54445dc2
TT
14375 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if C compiler supports UBSAN" >&5
14376printf %s "checking if C compiler supports UBSAN... " >&6; }
1c2a76ae
DW
14377 OLD_CFLAGS="$CFLAGS"
14378 OLD_LDFLAGS="$LDFLAGS"
14379 UBSAN_FLAGS="-fsanitize=undefined"
14380 CFLAGS="$CFLAGS $UBSAN_FLAGS"
14381 LDFLAGS="$LDFLAGS $UBSAN_FLAGS"
14382 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14383/* end confdefs.h. */
14384
14385int
54445dc2 14386main (void)
1c2a76ae
DW
14387{
14388
14389 ;
14390 return 0;
14391}
14392_ACEOF
54445dc2
TT
14393if ac_fn_c_try_link "$LINENO"
14394then :
14395 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14396printf "%s\n" "yes" >&6; }
1c2a76ae
DW
14397 ubsan_cflags=$UBSAN_FLAGS
14398 ubsan_ldflags=$UBSAN_FLAGS
14399 have_ubsan=yes
54445dc2
TT
14400else $as_nop
14401 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14402printf "%s\n" "no" >&6; }
1c2a76ae 14403fi
54445dc2 14404rm -f core conftest.err conftest.$ac_objext conftest.beam \
1c2a76ae
DW
14405 conftest$ac_exeext conftest.$ac_ext
14406 CFLAGS="${OLD_CFLAGS}"
14407 LDFLAGS="${OLD_LDFLAGS}"
14408
14409
14410
14411fi
14412if test "$enable_ubsan" = "yes" && test "$have_ubsan" != "yes"; then
14413 as_fn_error $? "UBSAN not supported by compiler." "$LINENO" 5
14414fi
5e666e3d 14415# Check whether --enable-addrsan was given.
54445dc2
TT
14416if test ${enable_addrsan+y}
14417then :
5e666e3d 14418 enableval=$enable_addrsan;
54445dc2 14419else $as_nop
5e666e3d
DW
14420 enable_addrsan=no
14421fi
14422
14423if test "$enable_addrsan" = "yes" || test "$enable_addrsan" = "probe"; then
54445dc2
TT
14424 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if C compiler supports ADDRSAN" >&5
14425printf %s "checking if C compiler supports ADDRSAN... " >&6; }
5e666e3d
DW
14426 OLD_CFLAGS="$CFLAGS"
14427 OLD_LDFLAGS="$LDFLAGS"
14428 ADDRSAN_FLAGS="-fsanitize=address"
14429 CFLAGS="$CFLAGS $ADDRSAN_FLAGS"
14430 LDFLAGS="$LDFLAGS $ADDRSAN_FLAGS"
14431 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14432/* end confdefs.h. */
14433
14434int
54445dc2 14435main (void)
5e666e3d
DW
14436{
14437
14438 ;
14439 return 0;
14440}
14441_ACEOF
54445dc2
TT
14442if ac_fn_c_try_link "$LINENO"
14443then :
14444 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14445printf "%s\n" "yes" >&6; }
5e666e3d
DW
14446 addrsan_cflags=$ADDRSAN_FLAGS
14447 addrsan_ldflags=$ADDRSAN_FLAGS
14448 have_addrsan=yes
54445dc2
TT
14449else $as_nop
14450 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14451printf "%s\n" "no" >&6; }
5e666e3d 14452fi
54445dc2 14453rm -f core conftest.err conftest.$ac_objext conftest.beam \
5e666e3d
DW
14454 conftest$ac_exeext conftest.$ac_ext
14455 CFLAGS="${OLD_CFLAGS}"
14456 LDFLAGS="${OLD_LDFLAGS}"
14457
14458
14459
14460fi
14461if test "$enable_addrsan" = "yes" && test "$have_addrsan" != "yes"; then
14462 as_fn_error $? "ADDRSAN not supported by compiler." "$LINENO" 5
14463fi
bcca786b 14464# Check whether --enable-threadsan was given.
54445dc2
TT
14465if test ${enable_threadsan+y}
14466then :
bcca786b 14467 enableval=$enable_threadsan;
54445dc2 14468else $as_nop
bcca786b
DW
14469 enable_threadsan=no
14470fi
14471
14472if test "$enable_threadsan" = "yes" || test "$enable_threadsan" = "probe"; then
54445dc2
TT
14473 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if C compiler supports THREADSAN" >&5
14474printf %s "checking if C compiler supports THREADSAN... " >&6; }
bcca786b
DW
14475 OLD_CFLAGS="$CFLAGS"
14476 OLD_LDFLAGS="$LDFLAGS"
14477 THREADSAN_FLAGS="-fsanitize=thread"
14478 CFLAGS="$CFLAGS $THREADSAN_FLAGS"
14479 LDFLAGS="$LDFLAGS $THREADSAN_FLAGS"
14480 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14481/* end confdefs.h. */
14482
14483int
54445dc2 14484main (void)
bcca786b
DW
14485{
14486
14487 ;
14488 return 0;
14489}
14490_ACEOF
54445dc2
TT
14491if ac_fn_c_try_link "$LINENO"
14492then :
14493 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14494printf "%s\n" "yes" >&6; }
bcca786b
DW
14495 threadsan_cflags=$THREADSAN_FLAGS
14496 threadsan_ldflags=$THREADSAN_FLAGS
14497 have_threadsan=yes
54445dc2
TT
14498else $as_nop
14499 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14500printf "%s\n" "no" >&6; }
bcca786b 14501fi
54445dc2 14502rm -f core conftest.err conftest.$ac_objext conftest.beam \
bcca786b
DW
14503 conftest$ac_exeext conftest.$ac_ext
14504 CFLAGS="${OLD_CFLAGS}"
14505 LDFLAGS="${OLD_LDFLAGS}"
14506
14507
14508
14509fi
14510if test "$enable_threadsan" = "yes" && test "$have_threadsan" != "yes"; then
14511 as_fn_error $? "THREADSAN not supported by compiler." "$LINENO" 5
14512fi
14513if test "$have_threadsan" = "yes" && test "$have_addrsan" = "yes"; then
54445dc2
TT
14514 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: ADDRSAN and THREADSAN are not known to work together." >&5
14515printf "%s\n" "$as_me: WARNING: ADDRSAN and THREADSAN are not known to work together." >&2;}
bcca786b 14516fi
2869485b
TT
14517FUZZING_CMT="#"
14518# Check whether --enable-fuzzing was given.
14519if test ${enable_fuzzing+y}
14520then :
14521 enableval=$enable_fuzzing;
14522else $as_nop
14523 enable_fuzzing=no
14524fi
14525
14526if test "$enable_fuzzing" = "yes" || test "$enable_fuzzing" = "probe"; then
14527
14528
14529
14530
14531
14532
14533ac_ext=cpp
14534ac_cpp='$CXXCPP $CPPFLAGS'
14535ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14536ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14537ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
14538if test -z "$CXX"; then
14539 if test -n "$CCC"; then
14540 CXX=$CCC
14541 else
14542 if test -n "$ac_tool_prefix"; then
14543 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC clang++
14544 do
14545 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
14546set dummy $ac_tool_prefix$ac_prog; ac_word=$2
14547{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14548printf %s "checking for $ac_word... " >&6; }
14549if test ${ac_cv_prog_CXX+y}
14550then :
14551 printf %s "(cached) " >&6
14552else $as_nop
14553 if test -n "$CXX"; then
14554 ac_cv_prog_CXX="$CXX" # Let the user override the test.
14555else
14556as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14557for as_dir in $PATH
14558do
14559 IFS=$as_save_IFS
14560 case $as_dir in #(((
14561 '') as_dir=./ ;;
14562 */) ;;
14563 *) as_dir=$as_dir/ ;;
14564 esac
14565 for ac_exec_ext in '' $ac_executable_extensions; do
14566 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
14567 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
14568 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
14569 break 2
14570 fi
14571done
14572 done
14573IFS=$as_save_IFS
14574
14575fi
14576fi
14577CXX=$ac_cv_prog_CXX
14578if test -n "$CXX"; then
14579 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
14580printf "%s\n" "$CXX" >&6; }
14581else
14582 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14583printf "%s\n" "no" >&6; }
14584fi
14585
14586
14587 test -n "$CXX" && break
14588 done
14589fi
14590if test -z "$CXX"; then
14591 ac_ct_CXX=$CXX
14592 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC clang++
14593do
14594 # Extract the first word of "$ac_prog", so it can be a program name with args.
14595set dummy $ac_prog; ac_word=$2
14596{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14597printf %s "checking for $ac_word... " >&6; }
14598if test ${ac_cv_prog_ac_ct_CXX+y}
14599then :
14600 printf %s "(cached) " >&6
14601else $as_nop
14602 if test -n "$ac_ct_CXX"; then
14603 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
14604else
14605as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14606for as_dir in $PATH
14607do
14608 IFS=$as_save_IFS
14609 case $as_dir in #(((
14610 '') as_dir=./ ;;
14611 */) ;;
14612 *) as_dir=$as_dir/ ;;
14613 esac
14614 for ac_exec_ext in '' $ac_executable_extensions; do
14615 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
14616 ac_cv_prog_ac_ct_CXX="$ac_prog"
14617 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
14618 break 2
14619 fi
14620done
14621 done
14622IFS=$as_save_IFS
14623
14624fi
14625fi
14626ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
14627if test -n "$ac_ct_CXX"; then
14628 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
14629printf "%s\n" "$ac_ct_CXX" >&6; }
14630else
14631 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14632printf "%s\n" "no" >&6; }
14633fi
14634
14635
14636 test -n "$ac_ct_CXX" && break
14637done
14638
14639 if test "x$ac_ct_CXX" = x; then
14640 CXX="g++"
14641 else
14642 case $cross_compiling:$ac_tool_warned in
14643yes:)
14644{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
14645printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
14646ac_tool_warned=yes ;;
14647esac
14648 CXX=$ac_ct_CXX
14649 fi
14650fi
14651
14652 fi
14653fi
14654# Provide some information about the compiler.
14655printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
14656set X $ac_compile
14657ac_compiler=$2
14658for ac_option in --version -v -V -qversion; do
14659 { { ac_try="$ac_compiler $ac_option >&5"
14660case "(($ac_try" in
14661 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14662 *) ac_try_echo=$ac_try;;
14663esac
14664eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
14665printf "%s\n" "$ac_try_echo"; } >&5
14666 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
14667 ac_status=$?
14668 if test -s conftest.err; then
14669 sed '10a\
14670... rest of stderr output deleted ...
14671 10q' conftest.err >conftest.er1
14672 cat conftest.er1 >&5
14673 fi
14674 rm -f conftest.er1 conftest.err
14675 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14676 test $ac_status = 0; }
14677done
14678
14679{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C++" >&5
14680printf %s "checking whether the compiler supports GNU C++... " >&6; }
14681if test ${ac_cv_cxx_compiler_gnu+y}
14682then :
14683 printf %s "(cached) " >&6
14684else $as_nop
14685 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14686/* end confdefs.h. */
14687
14688int
14689main (void)
14690{
14691#ifndef __GNUC__
14692 choke me
14693#endif
14694
14695 ;
14696 return 0;
14697}
14698_ACEOF
14699if ac_fn_cxx_try_compile "$LINENO"
14700then :
14701 ac_compiler_gnu=yes
14702else $as_nop
14703 ac_compiler_gnu=no
14704fi
14705rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14706ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
14707
14708fi
14709{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
14710printf "%s\n" "$ac_cv_cxx_compiler_gnu" >&6; }
14711ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
14712
14713if test $ac_compiler_gnu = yes; then
14714 GXX=yes
14715else
14716 GXX=
14717fi
14718ac_test_CXXFLAGS=${CXXFLAGS+y}
14719ac_save_CXXFLAGS=$CXXFLAGS
14720{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
14721printf %s "checking whether $CXX accepts -g... " >&6; }
14722if test ${ac_cv_prog_cxx_g+y}
14723then :
14724 printf %s "(cached) " >&6
14725else $as_nop
14726 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
14727 ac_cxx_werror_flag=yes
14728 ac_cv_prog_cxx_g=no
14729 CXXFLAGS="-g"
14730 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14731/* end confdefs.h. */
14732
14733int
14734main (void)
14735{
14736
14737 ;
14738 return 0;
14739}
14740_ACEOF
14741if ac_fn_cxx_try_compile "$LINENO"
14742then :
14743 ac_cv_prog_cxx_g=yes
14744else $as_nop
14745 CXXFLAGS=""
14746 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14747/* end confdefs.h. */
14748
14749int
14750main (void)
14751{
14752
14753 ;
14754 return 0;
14755}
14756_ACEOF
14757if ac_fn_cxx_try_compile "$LINENO"
14758then :
14759
14760else $as_nop
14761 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
14762 CXXFLAGS="-g"
14763 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14764/* end confdefs.h. */
14765
14766int
14767main (void)
14768{
14769
14770 ;
14771 return 0;
14772}
14773_ACEOF
14774if ac_fn_cxx_try_compile "$LINENO"
14775then :
14776 ac_cv_prog_cxx_g=yes
14777fi
14778rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14779fi
14780rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14781fi
14782rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14783 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
14784fi
14785{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
14786printf "%s\n" "$ac_cv_prog_cxx_g" >&6; }
14787if test $ac_test_CXXFLAGS; then
14788 CXXFLAGS=$ac_save_CXXFLAGS
14789elif test $ac_cv_prog_cxx_g = yes; then
14790 if test "$GXX" = yes; then
14791 CXXFLAGS="-g -O2"
14792 else
14793 CXXFLAGS="-g"
14794 fi
14795else
14796 if test "$GXX" = yes; then
14797 CXXFLAGS="-O2"
14798 else
14799 CXXFLAGS=
14800 fi
14801fi
14802ac_prog_cxx_stdcxx=no
14803if test x$ac_prog_cxx_stdcxx = xno
14804then :
14805 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CXX option to enable C++11 features" >&5
14806printf %s "checking for $CXX option to enable C++11 features... " >&6; }
5598a968 14807if test ${ac_cv_prog_cxx_11+y}
2869485b
TT
14808then :
14809 printf %s "(cached) " >&6
14810else $as_nop
5598a968 14811 ac_cv_prog_cxx_11=no
2869485b
TT
14812ac_save_CXX=$CXX
14813cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14814/* end confdefs.h. */
14815$ac_cxx_conftest_cxx11_program
14816_ACEOF
14817for ac_arg in '' -std=gnu++11 -std=gnu++0x -std=c++11 -std=c++0x -qlanglvl=extended0x -AA
14818do
14819 CXX="$ac_save_CXX $ac_arg"
14820 if ac_fn_cxx_try_compile "$LINENO"
14821then :
14822 ac_cv_prog_cxx_cxx11=$ac_arg
14823fi
14824rm -f core conftest.err conftest.$ac_objext conftest.beam
14825 test "x$ac_cv_prog_cxx_cxx11" != "xno" && break
14826done
14827rm -f conftest.$ac_ext
14828CXX=$ac_save_CXX
14829fi
14830
14831if test "x$ac_cv_prog_cxx_cxx11" = xno
14832then :
14833 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
14834printf "%s\n" "unsupported" >&6; }
14835else $as_nop
14836 if test "x$ac_cv_prog_cxx_cxx11" = x
14837then :
14838 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
14839printf "%s\n" "none needed" >&6; }
14840else $as_nop
14841 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_cxx11" >&5
14842printf "%s\n" "$ac_cv_prog_cxx_cxx11" >&6; }
14843 CXX="$CXX $ac_cv_prog_cxx_cxx11"
14844fi
14845 ac_cv_prog_cxx_stdcxx=$ac_cv_prog_cxx_cxx11
14846 ac_prog_cxx_stdcxx=cxx11
14847fi
14848fi
14849if test x$ac_prog_cxx_stdcxx = xno
14850then :
14851 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CXX option to enable C++98 features" >&5
14852printf %s "checking for $CXX option to enable C++98 features... " >&6; }
5598a968 14853if test ${ac_cv_prog_cxx_98+y}
2869485b
TT
14854then :
14855 printf %s "(cached) " >&6
14856else $as_nop
5598a968 14857 ac_cv_prog_cxx_98=no
2869485b
TT
14858ac_save_CXX=$CXX
14859cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14860/* end confdefs.h. */
14861$ac_cxx_conftest_cxx98_program
14862_ACEOF
14863for ac_arg in '' -std=gnu++98 -std=c++98 -qlanglvl=extended -AA
14864do
14865 CXX="$ac_save_CXX $ac_arg"
14866 if ac_fn_cxx_try_compile "$LINENO"
14867then :
14868 ac_cv_prog_cxx_cxx98=$ac_arg
14869fi
14870rm -f core conftest.err conftest.$ac_objext conftest.beam
14871 test "x$ac_cv_prog_cxx_cxx98" != "xno" && break
14872done
14873rm -f conftest.$ac_ext
14874CXX=$ac_save_CXX
14875fi
14876
14877if test "x$ac_cv_prog_cxx_cxx98" = xno
14878then :
14879 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
14880printf "%s\n" "unsupported" >&6; }
14881else $as_nop
14882 if test "x$ac_cv_prog_cxx_cxx98" = x
14883then :
14884 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
14885printf "%s\n" "none needed" >&6; }
14886else $as_nop
14887 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_cxx98" >&5
14888printf "%s\n" "$ac_cv_prog_cxx_cxx98" >&6; }
14889 CXX="$CXX $ac_cv_prog_cxx_cxx98"
14890fi
14891 ac_cv_prog_cxx_stdcxx=$ac_cv_prog_cxx_cxx98
14892 ac_prog_cxx_stdcxx=cxx98
14893fi
14894fi
14895
14896ac_ext=c
14897ac_cpp='$CPP $CPPFLAGS'
14898ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14899ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14900ac_compiler_gnu=$ac_cv_c_compiler_gnu
14901
14902 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if C compiler supports fuzzing sanitizer" >&5
14903printf %s "checking if C compiler supports fuzzing sanitizer... " >&6; }
14904 ac_ext=cpp
14905ac_cpp='$CXXCPP $CPPFLAGS'
14906ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14907ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14908ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
14909
14910 OLD_CXXFLAGS="$CXXFLAGS"
14911 OLD_LDFLAGS="$LDFLAGS"
14912 FUZZER_FLAGS="-fsanitize=fuzzer"
14913 CXXFLAGS="$CXXFLAGS $FUZZER_FLAGS"
14914 LDFLAGS="$LDFLAGS $FUZZER_FLAGS"
14915
14916cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14917/* end confdefs.h. */
14918
14919 #include <stddef.h>
14920 #include <stdint.h>
14921
14922int
14923main (void)
14924{
14925 return 0;
14926 ;
14927 return 0;
14928}
14929_ACEOF
14930if ac_fn_cxx_try_compile "$LINENO"
14931then :
14932 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14933printf "%s\n" "yes" >&6; }
14934 fuzzer_cflags=$FUZZER_FLAGS
14935 fuzzer_ldflags=$FUZZER_FLAGS
14936 FUZZING_CMT=
14937 have_fuzzer=yes
14938else $as_nop
14939 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
14940printf "%s\n" "no" >&6; }
14941 as_fn_error $? "fuzzing requested but not available" "$LINENO" 5
14942fi
14943rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
14944 CXXFLAGS="${OLD_CXXFLAGS}"
14945 LDFLAGS="${OLD_LDFLAGS}"
14946 ac_ext=c
14947ac_cpp='$CPP $CPPFLAGS'
14948ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14949ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14950ac_compiler_gnu=$ac_cv_c_compiler_gnu
14951
14952
14953
14954
14955fi
14956if test "$enable_fuzzer" = "yes" && test "$have_fuzzer" != "yes"; then
14957 as_fn_error $? "Fuzzing not supported by compiler." "$LINENO" 5
14958fi
14959
e6f2bda3 14960LINUX_CMT="#"
fff45483
TT
14961CYGWIN_CMT="#"
14962UNIX_CMT=
e6f2bda3
TT
14963case "$host_os" in
14964linux*)
14965 LINUX_CMT=
fff45483
TT
14966 ;;
14967cygwin)
14968 CYGWIN_CMT=
14969 UNIX_CMT="#"
e6f2bda3
TT
14970 ;;
14971esac
14972
93636bde
TT
14973
14974
5ce368f0
DW
14975E2SCRUB_CMT="$LINUX_CMT"
14976
50e1e10f 14977case "$host_os" in
93636bde 14978linux* | gnu* | k*bsd*-gnu)
a4b2d3ce
TT
14979 if test "$prefix" = NONE -a "$root_prefix" = NONE ; then
14980 root_prefix="";
54445dc2
TT
14981 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: On $host_os systems, root_prefix defaults to ''" >&5
14982printf "%s\n" "On $host_os systems, root_prefix defaults to ''" >&6; }
fc6d9d51
TT
14983 fi
14984 ;;
14985esac
fc6d9d51 14986case "$host_os" in
93636bde 14987linux* | gnu* | k*bsd*-gnu)
fc6d9d51 14988 if test "$prefix" = NONE ; then
a4b2d3ce 14989 prefix="/usr";
54445dc2
TT
14990 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: On $host_os systems, prefix defaults to /usr" >&5
14991printf "%s\n" "On $host_os systems, prefix defaults to /usr" >&6; }
bff61a7a 14992 if test "$mandir" = '${prefix}/man' ; then
54445dc2
TT
14993 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ...and mandir defaults to /usr/share/man" >&5
14994printf "%s\n" "...and mandir defaults to /usr/share/man" >&6; }
bff61a7a
TT
14995 mandir=/usr/share/man
14996 fi
50e1e10f
TT
14997 fi
14998;;
14999esac
a4b2d3ce 15000if test "$root_prefix" = NONE ; then
ffe1991f 15001 if test "$prefix" = NONE ; then
a4b2d3ce
TT
15002 root_prefix="$ac_default_prefix"
15003 else
15004 root_prefix="$prefix"
15005 fi
b5ffeade
TT
15006 root_bindir=$bindir
15007 root_sbindir=$sbindir
15008 root_libdir=$libdir
15009 root_sysconfdir=$sysconfdir
15010else
15011 root_bindir='${root_prefix}/bin'
15012 root_sbindir='${root_prefix}/sbin'
15013 root_libdir='${root_prefix}/lib'
15014 root_sysconfdir='${root_prefix}/etc'
a4b2d3ce 15015fi
c4ef11c5
TT
15016if test "$bindir" != '${exec_prefix}/bin'; then
15017 root_bindir=$bindir
54445dc2
TT
15018 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Setting root_bindir to $root_bindir" >&5
15019printf "%s\n" "Setting root_bindir to $root_bindir" >&6; }
c4ef11c5
TT
15020fi
15021if test "$sbindir" != '${exec_prefix}/sbin'; then
15022 root_sbindir=$sbindir
54445dc2
TT
15023 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Setting root_sbindir to $root_sbindir" >&5
15024printf "%s\n" "Setting root_sbindir to $root_sbindir" >&6; }
c4ef11c5
TT
15025fi
15026if test "$libdir" != '${exec_prefix}/lib'; then
15027 root_libdir=$libdir
54445dc2
TT
15028 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Setting root_libdir to $root_libdir" >&5
15029printf "%s\n" "Setting root_libdir to $root_libdir" >&6; }
c4ef11c5
TT
15030fi
15031if test "$sysconfdir" != '${prefix}/etc'; then
15032 root_sysconfdir=$sysconfdir
54445dc2
TT
15033 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Setting root_sysconfdir to $root_sysconfdir" >&5
15034printf "%s\n" "Setting root_sysconfdir to $root_sysconfdir" >&6; }
c4ef11c5 15035fi
a4b2d3ce 15036
93636bde
TT
15037
15038
15039
15040
55e00a25
TT
15041
15042# Check whether --with-multiarch was given.
54445dc2
TT
15043if test ${with_multiarch+y}
15044then :
d7fa4103
TT
15045 withval=$with_multiarch; if test "$withval" = "lib64"; then
15046 libdir=/usr/lib64
15047 root_libdir=/lib64
15048else
15049 libdir=$libdir/$withval
15050 root_libdir=$root_libdir/$withval
15051fi
55e00a25
TT
15052
15053fi
a2df5894 15054
54445dc2
TT
15055{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we can link with -static" >&5
15056printf %s "checking whether we can link with -static... " >&6; }
15057if test ${ac_cv_e2fsprogs_use_static+y}
15058then :
15059 printf %s "(cached) " >&6
15060else $as_nop
fd1677e8 15061 SAVE_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS_STATIC -static"
57aa50d4 15062cat confdefs.h - <<_ACEOF >conftest.$ac_ext
b0cacab0 15063/* end confdefs.h. */
ae851482 15064#include <stdio.h>
b0cacab0 15065int
54445dc2 15066main (void)
b0cacab0 15067{
ae851482 15068fflush(stdout);
b0cacab0
TT
15069 ;
15070 return 0;
15071}
15072_ACEOF
54445dc2
TT
15073if ac_fn_c_try_link "$LINENO"
15074then :
ae851482 15075 ac_cv_e2fsprogs_use_static=yes
54445dc2 15076else $as_nop
57aa50d4 15077 ac_cv_e2fsprogs_use_static=no
ae851482 15078fi
54445dc2 15079rm -f core conftest.err conftest.$ac_objext conftest.beam \
57aa50d4 15080 conftest$ac_exeext conftest.$ac_ext
ae851482
TT
15081LDFLAGS=$SAVE_LDFLAGS
15082fi
50e1e10f 15083
defde784
TT
15084case "$host_os" in
15085solaris2.*)
b0cacab0 15086 ac_cv_e2fsprogs_use_static=no
defde784
TT
15087;;
15088esac
54445dc2
TT
15089{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_e2fsprogs_use_static" >&5
15090printf "%s\n" "$ac_cv_e2fsprogs_use_static" >&6; }
ae851482 15091if test $ac_cv_e2fsprogs_use_static = yes; then
fd1677e8 15092 LDFLAGS_STATIC="$LDFLAGS_STATIC -static"
ae851482 15093fi
50e1e10f 15094
07a0db15
TT
15095case "$host_os" in
15096darwin*)
54445dc2
TT
15097 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Using Apple Darwin / GNU libintl workaround" >&5
15098printf "%s\n" "Using Apple Darwin / GNU libintl workaround" >&6; }
d1154eb4 15099
54445dc2 15100printf "%s\n" "#define _INTL_REDIRECT_MACROS 1" >>confdefs.h
07a0db15
TT
15101
15102 ;;
15103esac
50e1e10f
TT
15104if test "$cross_compiling" = yes ; then
15105 DO_TEST_SUITE=
15106else
15107 DO_TEST_SUITE=check
15108fi
15109
d1154eb4
TT
15110INCLUDES='-I. -I$(top_builddir)/lib -I$(top_srcdir)/lib'
15111if test -n "$CPPFLAGS" ; then
15112 INCLUDES="$INCLUDES $CPPFLAGS"
15113fi
c6f35b8a 15114if test "$USE_INCLUDED_LIBINTL" = "yes" ; then
d1154eb4 15115 INCLUDES=$INCLUDES' -I$(top_builddir)/intl -I$(top_srcdir)/intl'
c6f35b8a 15116fi
6c59a665
TT
15117if test -n "$WITH_DIET_LIBC" ; then
15118 INCLUDES="$INCLUDES -D_REENTRANT"
15119fi
6eb00fb7
EB
15120case "$host_os" in
15121mingw*)
15122 INCLUDES=$INCLUDES' -I$(top_srcdir)/include/mingw'
15123 ;;
15124esac
c6f35b8a 15125
dd947da2 15126if test $cross_compiling = no; then
2873927d 15127 BUILD_CFLAGS="$CFLAGS $CPPFLAGS $INCLUDES -DHAVE_CONFIG_H"
dd947da2 15128 BUILD_LDFLAGS="$LDFLAGS"
dd947da2
TT
15129fi
15130
15131
fd1677e8
TT
15132CFLAGS_SHLIB=${CFLAGS_SHLIB:-$CFLAGS}
15133CFLAGS_STLIB=${CFLAGS_STLIB:-$CFLAGS}
15134LDFLAGS_SHLIB=${LDFLAGS_SHLIB:-$LDFLAGS}
15135
15136
15137
5ce368f0
DW
15138
15139
15140# Check whether --with-udev_rules_dir was given.
54445dc2
TT
15141if test ${with_udev_rules_dir+y}
15142then :
5ce368f0 15143 withval=$with_udev_rules_dir;
54445dc2 15144else $as_nop
5ce368f0
DW
15145 with_udev_rules_dir=yes
15146fi
15147
54445dc2
TT
15148if test "x${with_udev_rules_dir}" != "xno"
15149then :
5ce368f0 15150
54445dc2
TT
15151 if test "x${with_udev_rules_dir}" = "xyes"
15152then :
5ce368f0
DW
15153
15154
15155pkg_failed=no
54445dc2
TT
15156{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for udev" >&5
15157printf %s "checking for udev... " >&6; }
5ce368f0
DW
15158
15159if test -n "$udev_CFLAGS"; then
15160 pkg_cv_udev_CFLAGS="$udev_CFLAGS"
15161 elif test -n "$PKG_CONFIG"; then
15162 if test -n "$PKG_CONFIG" && \
54445dc2 15163 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"udev\""; } >&5
5ce368f0
DW
15164 ($PKG_CONFIG --exists --print-errors "udev") 2>&5
15165 ac_status=$?
54445dc2 15166 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5ce368f0
DW
15167 test $ac_status = 0; }; then
15168 pkg_cv_udev_CFLAGS=`$PKG_CONFIG --cflags "udev" 2>/dev/null`
15169 test "x$?" != "x0" && pkg_failed=yes
15170else
15171 pkg_failed=yes
15172fi
15173 else
15174 pkg_failed=untried
15175fi
15176if test -n "$udev_LIBS"; then
15177 pkg_cv_udev_LIBS="$udev_LIBS"
15178 elif test -n "$PKG_CONFIG"; then
15179 if test -n "$PKG_CONFIG" && \
54445dc2 15180 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"udev\""; } >&5
5ce368f0
DW
15181 ($PKG_CONFIG --exists --print-errors "udev") 2>&5
15182 ac_status=$?
54445dc2 15183 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5ce368f0
DW
15184 test $ac_status = 0; }; then
15185 pkg_cv_udev_LIBS=`$PKG_CONFIG --libs "udev" 2>/dev/null`
15186 test "x$?" != "x0" && pkg_failed=yes
15187else
15188 pkg_failed=yes
15189fi
15190 else
15191 pkg_failed=untried
15192fi
15193
15194
15195
15196if test $pkg_failed = yes; then
5598a968 15197 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
54445dc2 15198printf "%s\n" "no" >&6; }
5ce368f0
DW
15199
15200if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
15201 _pkg_short_errors_supported=yes
15202else
15203 _pkg_short_errors_supported=no
15204fi
15205 if test $_pkg_short_errors_supported = yes; then
5598a968 15206 udev_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "udev" 2>&1`
5ce368f0 15207 else
5598a968 15208 udev_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "udev" 2>&1`
5ce368f0 15209 fi
5598a968
EB
15210 # Put the nasty error message in config.log where it belongs
15211 echo "$udev_PKG_ERRORS" >&5
5ce368f0
DW
15212
15213
15214 with_udev_rules_dir=""
15215
15216elif test $pkg_failed = untried; then
5598a968 15217 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
54445dc2 15218printf "%s\n" "no" >&6; }
5ce368f0
DW
15219
15220 with_udev_rules_dir=""
15221
15222else
5598a968
EB
15223 udev_CFLAGS=$pkg_cv_udev_CFLAGS
15224 udev_LIBS=$pkg_cv_udev_LIBS
54445dc2
TT
15225 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15226printf "%s\n" "yes" >&6; }
5ce368f0
DW
15227
15228 with_udev_rules_dir="$($PKG_CONFIG --variable=udevdir udev)/rules.d"
15229
15230fi
15231
15232fi
54445dc2
TT
15233 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for udev rules dir" >&5
15234printf %s "checking for udev rules dir... " >&6; }
5ce368f0 15235 pkg_udev_rules_dir="${with_udev_rules_dir}"
54445dc2
TT
15236 if test -n "${pkg_udev_rules_dir}"
15237then :
5ce368f0 15238
54445dc2
TT
15239 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${pkg_udev_rules_dir}" >&5
15240printf "%s\n" "${pkg_udev_rules_dir}" >&6; }
5ce368f0
DW
15241 have_udev="yes"
15242
54445dc2 15243else $as_nop
5ce368f0 15244
54445dc2
TT
15245 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
15246printf "%s\n" "no" >&6; }
5ce368f0
DW
15247 have_udev="no"
15248
15249fi
15250
54445dc2 15251else $as_nop
5ce368f0
DW
15252
15253 have_udev="disabled"
15254
15255fi
15256
15257
15258
a2df5894
DW
15259
15260# Check whether --with-crond_dir was given.
54445dc2
TT
15261if test ${with_crond_dir+y}
15262then :
a2df5894 15263 withval=$with_crond_dir;
54445dc2 15264else $as_nop
a2df5894
DW
15265 with_crond_dir=yes
15266fi
15267
54445dc2
TT
15268if test "x${with_crond_dir}" != "xno"
15269then :
a2df5894 15270
54445dc2
TT
15271 if test "x${with_crond_dir}" = "xyes"
15272then :
a2df5894 15273
54445dc2
TT
15274 if test -d "/etc/cron.d"
15275then :
a2df5894 15276 with_crond_dir="/etc/cron.d"
54445dc2 15277else $as_nop
188bf39a 15278 have_crond="no"; with_crond_dir=""
a2df5894
DW
15279fi
15280
15281fi
54445dc2
TT
15282 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for system crontab dir" >&5
15283printf %s "checking for system crontab dir... " >&6; }
a2df5894 15284 crond_dir="${with_crond_dir}"
54445dc2
TT
15285 if test -n "${crond_dir}"
15286then :
a2df5894 15287
54445dc2
TT
15288 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${crond_dir}" >&5
15289printf "%s\n" "${crond_dir}" >&6; }
a2df5894
DW
15290 have_crond="yes"
15291
54445dc2 15292else $as_nop
a2df5894 15293
54445dc2
TT
15294 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
15295printf "%s\n" "no" >&6; }
a2df5894
DW
15296 have_crond="no"
15297
15298fi
15299
54445dc2 15300else $as_nop
a2df5894
DW
15301
15302 have_crond="disabled"
15303
15304fi
15305
15306
15307
15308
15309# Check whether --with-systemd_unit_dir was given.
54445dc2
TT
15310if test ${with_systemd_unit_dir+y}
15311then :
a2df5894 15312 withval=$with_systemd_unit_dir;
54445dc2 15313else $as_nop
a2df5894
DW
15314 with_systemd_unit_dir=yes
15315fi
15316
54445dc2
TT
15317if test "x${with_systemd_unit_dir}" != "xno"
15318then :
a2df5894 15319
54445dc2
TT
15320 if test "x${with_systemd_unit_dir}" = "xyes"
15321then :
a2df5894
DW
15322
15323
15324pkg_failed=no
54445dc2
TT
15325{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for systemd" >&5
15326printf %s "checking for systemd... " >&6; }
a2df5894
DW
15327
15328if test -n "$systemd_CFLAGS"; then
15329 pkg_cv_systemd_CFLAGS="$systemd_CFLAGS"
15330 elif test -n "$PKG_CONFIG"; then
15331 if test -n "$PKG_CONFIG" && \
54445dc2 15332 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"systemd\""; } >&5
a2df5894
DW
15333 ($PKG_CONFIG --exists --print-errors "systemd") 2>&5
15334 ac_status=$?
54445dc2 15335 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
a2df5894
DW
15336 test $ac_status = 0; }; then
15337 pkg_cv_systemd_CFLAGS=`$PKG_CONFIG --cflags "systemd" 2>/dev/null`
15338 test "x$?" != "x0" && pkg_failed=yes
15339else
15340 pkg_failed=yes
15341fi
15342 else
15343 pkg_failed=untried
15344fi
15345if test -n "$systemd_LIBS"; then
15346 pkg_cv_systemd_LIBS="$systemd_LIBS"
15347 elif test -n "$PKG_CONFIG"; then
15348 if test -n "$PKG_CONFIG" && \
54445dc2 15349 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"systemd\""; } >&5
a2df5894
DW
15350 ($PKG_CONFIG --exists --print-errors "systemd") 2>&5
15351 ac_status=$?
54445dc2 15352 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
a2df5894
DW
15353 test $ac_status = 0; }; then
15354 pkg_cv_systemd_LIBS=`$PKG_CONFIG --libs "systemd" 2>/dev/null`
15355 test "x$?" != "x0" && pkg_failed=yes
15356else
15357 pkg_failed=yes
15358fi
15359 else
15360 pkg_failed=untried
15361fi
15362
15363
15364
15365if test $pkg_failed = yes; then
5598a968 15366 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
54445dc2 15367printf "%s\n" "no" >&6; }
a2df5894
DW
15368
15369if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
15370 _pkg_short_errors_supported=yes
15371else
15372 _pkg_short_errors_supported=no
15373fi
15374 if test $_pkg_short_errors_supported = yes; then
5598a968 15375 systemd_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "systemd" 2>&1`
a2df5894 15376 else
5598a968 15377 systemd_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "systemd" 2>&1`
a2df5894 15378 fi
5598a968
EB
15379 # Put the nasty error message in config.log where it belongs
15380 echo "$systemd_PKG_ERRORS" >&5
a2df5894
DW
15381
15382
15383 with_systemd_unit_dir=""
15384
15385elif test $pkg_failed = untried; then
5598a968 15386 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
54445dc2 15387printf "%s\n" "no" >&6; }
a2df5894
DW
15388
15389 with_systemd_unit_dir=""
15390
15391else
5598a968
EB
15392 systemd_CFLAGS=$pkg_cv_systemd_CFLAGS
15393 systemd_LIBS=$pkg_cv_systemd_LIBS
54445dc2
TT
15394 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15395printf "%s\n" "yes" >&6; }
a2df5894
DW
15396
15397 with_systemd_unit_dir="$($PKG_CONFIG --variable=systemdsystemunitdir systemd)"
15398
15399fi
15400
15401
15402fi
54445dc2
TT
15403 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for systemd system unit dir" >&5
15404printf %s "checking for systemd system unit dir... " >&6; }
a2df5894 15405 systemd_system_unit_dir="${with_systemd_unit_dir}"
54445dc2
TT
15406 if test -n "${systemd_system_unit_dir}"
15407then :
a2df5894 15408
54445dc2
TT
15409 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${systemd_system_unit_dir}" >&5
15410printf "%s\n" "${systemd_system_unit_dir}" >&6; }
a2df5894
DW
15411 have_systemd="yes"
15412
54445dc2 15413else $as_nop
a2df5894 15414
54445dc2
TT
15415 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
15416printf "%s\n" "no" >&6; }
a2df5894
DW
15417 have_systemd="no"
15418
15419fi
15420
54445dc2 15421else $as_nop
a2df5894
DW
15422
15423 have_systemd="disabled"
15424
15425fi
15426
15427
d1d44c14
PAA
15428OS_IO_FILE=""
15429case "$host_os" in
6eb00fb7 15430 mingw*)
d1d44c14
PAA
15431 OS_IO_FILE=windows_io
15432 ;;
15433 *)
15434 OS_IO_FILE=unix_io
15435 ;;
15436esac
a2df5894 15437
a22e7f16
KR
15438
15439# Check whether --enable-largefile was given.
15440if test ${enable_largefile+y}
15441then :
15442 enableval=$enable_largefile;
15443fi
15444
15445if test "$enable_largefile" != no; then
15446
15447 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
15448printf %s "checking for special C compiler options needed for large files... " >&6; }
15449if test ${ac_cv_sys_largefile_CC+y}
15450then :
15451 printf %s "(cached) " >&6
15452else $as_nop
15453 ac_cv_sys_largefile_CC=no
15454 if test "$GCC" != yes; then
15455 ac_save_CC=$CC
15456 while :; do
15457 # IRIX 6.2 and later do not support large files by default,
15458 # so use the C compiler's -n32 option if that helps.
15459 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15460/* end confdefs.h. */
15461#include <sys/types.h>
15462 /* Check that off_t can represent 2**63 - 1 correctly.
15463 We can't simply define LARGE_OFF_T to be 9223372036854775807,
15464 since some C++ compilers masquerading as C compilers
15465 incorrectly reject 9223372036854775807. */
15466#define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31))
15467 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15468 && LARGE_OFF_T % 2147483647 == 1)
15469 ? 1 : -1];
15470int
15471main (void)
15472{
15473
15474 ;
15475 return 0;
15476}
15477_ACEOF
15478 if ac_fn_c_try_compile "$LINENO"
15479then :
15480 break
15481fi
15482rm -f core conftest.err conftest.$ac_objext conftest.beam
15483 CC="$CC -n32"
15484 if ac_fn_c_try_compile "$LINENO"
15485then :
15486 ac_cv_sys_largefile_CC=' -n32'; break
15487fi
15488rm -f core conftest.err conftest.$ac_objext conftest.beam
15489 break
15490 done
15491 CC=$ac_save_CC
15492 rm -f conftest.$ac_ext
15493 fi
15494fi
15495{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
15496printf "%s\n" "$ac_cv_sys_largefile_CC" >&6; }
15497 if test "$ac_cv_sys_largefile_CC" != no; then
15498 CC=$CC$ac_cv_sys_largefile_CC
15499 fi
15500
15501 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
15502printf %s "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
15503if test ${ac_cv_sys_file_offset_bits+y}
15504then :
15505 printf %s "(cached) " >&6
15506else $as_nop
15507 while :; do
15508 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15509/* end confdefs.h. */
15510#include <sys/types.h>
15511 /* Check that off_t can represent 2**63 - 1 correctly.
15512 We can't simply define LARGE_OFF_T to be 9223372036854775807,
15513 since some C++ compilers masquerading as C compilers
15514 incorrectly reject 9223372036854775807. */
15515#define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31))
15516 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15517 && LARGE_OFF_T % 2147483647 == 1)
15518 ? 1 : -1];
15519int
15520main (void)
15521{
15522
15523 ;
15524 return 0;
15525}
15526_ACEOF
15527if ac_fn_c_try_compile "$LINENO"
15528then :
15529 ac_cv_sys_file_offset_bits=no; break
15530fi
15531rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
15532 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15533/* end confdefs.h. */
15534#define _FILE_OFFSET_BITS 64
15535#include <sys/types.h>
15536 /* Check that off_t can represent 2**63 - 1 correctly.
15537 We can't simply define LARGE_OFF_T to be 9223372036854775807,
15538 since some C++ compilers masquerading as C compilers
15539 incorrectly reject 9223372036854775807. */
15540#define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31))
15541 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15542 && LARGE_OFF_T % 2147483647 == 1)
15543 ? 1 : -1];
15544int
15545main (void)
15546{
15547
15548 ;
15549 return 0;
15550}
15551_ACEOF
15552if ac_fn_c_try_compile "$LINENO"
15553then :
15554 ac_cv_sys_file_offset_bits=64; break
15555fi
15556rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
15557 ac_cv_sys_file_offset_bits=unknown
15558 break
15559done
15560fi
15561{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
15562printf "%s\n" "$ac_cv_sys_file_offset_bits" >&6; }
15563case $ac_cv_sys_file_offset_bits in #(
15564 no | unknown) ;;
15565 *)
15566printf "%s\n" "#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits" >>confdefs.h
15567;;
15568esac
15569rm -rf conftest*
15570 if test $ac_cv_sys_file_offset_bits = unknown; then
15571 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
15572printf %s "checking for _LARGE_FILES value needed for large files... " >&6; }
15573if test ${ac_cv_sys_large_files+y}
15574then :
15575 printf %s "(cached) " >&6
15576else $as_nop
15577 while :; do
15578 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15579/* end confdefs.h. */
15580#include <sys/types.h>
15581 /* Check that off_t can represent 2**63 - 1 correctly.
15582 We can't simply define LARGE_OFF_T to be 9223372036854775807,
15583 since some C++ compilers masquerading as C compilers
15584 incorrectly reject 9223372036854775807. */
15585#define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31))
15586 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15587 && LARGE_OFF_T % 2147483647 == 1)
15588 ? 1 : -1];
15589int
15590main (void)
15591{
15592
15593 ;
15594 return 0;
15595}
15596_ACEOF
15597if ac_fn_c_try_compile "$LINENO"
15598then :
15599 ac_cv_sys_large_files=no; break
15600fi
15601rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
15602 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15603/* end confdefs.h. */
15604#define _LARGE_FILES 1
15605#include <sys/types.h>
15606 /* Check that off_t can represent 2**63 - 1 correctly.
15607 We can't simply define LARGE_OFF_T to be 9223372036854775807,
15608 since some C++ compilers masquerading as C compilers
15609 incorrectly reject 9223372036854775807. */
15610#define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31))
15611 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15612 && LARGE_OFF_T % 2147483647 == 1)
15613 ? 1 : -1];
15614int
15615main (void)
15616{
15617
15618 ;
15619 return 0;
15620}
15621_ACEOF
15622if ac_fn_c_try_compile "$LINENO"
15623then :
15624 ac_cv_sys_large_files=1; break
15625fi
15626rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
15627 ac_cv_sys_large_files=unknown
15628 break
15629done
15630fi
15631{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
15632printf "%s\n" "$ac_cv_sys_large_files" >&6; }
15633case $ac_cv_sys_large_files in #(
15634 no | unknown) ;;
15635 *)
15636printf "%s\n" "#define _LARGE_FILES $ac_cv_sys_large_files" >>confdefs.h
15637;;
15638esac
15639rm -rf conftest*
15640 fi
15641fi
15642
15643
50e1e10f
TT
15644test -d lib || mkdir lib
15645test -d include || mkdir include
15646test -d include/linux || mkdir include/linux
defde784 15647test -d include/asm || mkdir include/asm
44dfb378
TT
15648if test -z "$UUID_CMT" ; then
15649 uuid_out_list="lib/uuid/Makefile lib/uuid/uuid.pc \
15650 lib/uuid/uuid_types.h"
15651fi
15652if test -z "$BLKID_CMT" ; then
15653 blkid_out_list="lib/blkid/Makefile lib/blkid/blkid.pc \
15654 lib/blkid/blkid_types.h"
15655fi
e5f0f3ee 15656for i in MCONFIG Makefile \
183c73b0 15657 util/Makefile util/subst.conf util/gen-tarball util/install-symlink \
4ea7ea00
TT
15658 lib/et/Makefile lib/ss/Makefile lib/e2p/Makefile \
15659 lib/ext2fs/Makefile lib/ext2fs/ext2_types.h \
f34af41b 15660 $uuid_out_list $blkid_out_list lib/support/Makefile \
44dfb378 15661 lib/ss/ss.pc lib/et/com_err.pc lib/e2p/e2p.pc lib/ext2fs/ext2fs.pc \
921f4ad5 15662 misc/Makefile ext2ed/Makefile e2fsck/Makefile \
94ba8c75 15663 debugfs/Makefile tests/Makefile tests/progs/Makefile \
2869485b
TT
15664 tests/fuzz/Makefile resize/Makefile doc/Makefile \
15665 po/Makefile.in scrub/Makefile; do
94ba8c75
TT
15666 if test -d `dirname ${srcdir}/$i` ; then
15667 outlist="$outlist $i"
15668 fi
15669done
e1052144
TT
15670ac_config_files="$ac_config_files $outlist"
15671
b0cacab0 15672cat >confcache <<\_ACEOF
50e1e10f
TT
15673# This file is a shell script that caches the results of configure
15674# tests run on this system so they can be shared between configure
b0cacab0
TT
15675# scripts and configure runs, see configure's option --config-cache.
15676# It is not useful on other systems. If it contains results you don't
15677# want to keep, you may remove or edit it.
50e1e10f 15678#
b0cacab0
TT
15679# config.status only pays attention to the cache file if you give it
15680# the --recheck option to rerun configure.
50e1e10f 15681#
b0cacab0
TT
15682# `ac_cv_env_foo' variables (set or unset) will be overridden when
15683# loading this file, other *unset* `ac_cv_foo' will be assigned the
15684# following values.
15685
15686_ACEOF
15687
21c84b71
TT
15688# The following way of writing the cache mishandles newlines in values,
15689# but we know of no workaround that is simple, portable, and efficient.
e1052144 15690# So, we kill variables containing newlines.
50e1e10f
TT
15691# Ultrix sh set writes to stderr and can't be redirected directly,
15692# and sets the high bit in the cache file unless we assign to the vars.
e1052144
TT
15693(
15694 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
15695 eval ac_val=\$$ac_var
15696 case $ac_val in #(
15697 *${as_nl}*)
15698 case $ac_var in #(
54445dc2
TT
15699 *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
15700printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
e1052144
TT
15701 esac
15702 case $ac_var in #(
15703 _ | IFS | as_nl) ;; #(
39fd3d4f 15704 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
57aa50d4 15705 *) { eval $ac_var=; unset $ac_var;} ;;
e1052144
TT
15706 esac ;;
15707 esac
15708 done
15709
b0cacab0 15710 (set) 2>&1 |
e1052144
TT
15711 case $as_nl`(ac_space=' '; set) 2>&1` in #(
15712 *${as_nl}ac_space=\ *)
57aa50d4
TT
15713 # `set' does not quote correctly, so add quotes: double-quote
15714 # substitution turns \\\\ into \\, and sed turns \\ into \.
b0cacab0
TT
15715 sed -n \
15716 "s/'/'\\\\''/g;
15717 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
e1052144 15718 ;; #(
b0cacab0
TT
15719 *)
15720 # `set' quotes correctly as required by POSIX, so do not add quotes.
e1052144 15721 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
b0cacab0 15722 ;;
e1052144
TT
15723 esac |
15724 sort
15725) |
b0cacab0 15726 sed '
e1052144 15727 /^ac_cv_env_/b end
b0cacab0 15728 t clear
e1052144 15729 :clear
54445dc2 15730 s/^\([^=]*\)=\(.*[{}].*\)$/test ${\1+y} || &/
b0cacab0 15731 t end
e1052144
TT
15732 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
15733 :end' >>confcache
15734if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
15735 if test -w "$cache_file"; then
d6a4bcb5 15736 if test "x$cache_file" != "x/dev/null"; then
54445dc2
TT
15737 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
15738printf "%s\n" "$as_me: updating cache $cache_file" >&6;}
d6a4bcb5
TB
15739 if test ! -f "$cache_file" || test -h "$cache_file"; then
15740 cat confcache >"$cache_file"
15741 else
15742 case $cache_file in #(
15743 */* | ?:*)
15744 mv -f confcache "$cache_file"$$ &&
15745 mv -f "$cache_file"$$ "$cache_file" ;; #(
15746 *)
15747 mv -f confcache "$cache_file" ;;
15748 esac
15749 fi
15750 fi
50e1e10f 15751 else
54445dc2
TT
15752 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
15753printf "%s\n" "$as_me: not updating unwritable cache $cache_file" >&6;}
50e1e10f
TT
15754 fi
15755fi
15756rm -f confcache
15757
50e1e10f
TT
15758test "x$prefix" = xNONE && prefix=$ac_default_prefix
15759# Let make expand exec_prefix.
15760test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
15761
d1154eb4 15762DEFS=-DHAVE_CONFIG_H
b0cacab0
TT
15763
15764ac_libobjs=
15765ac_ltlibobjs=
d6a4bcb5 15766U=
b0cacab0
TT
15767for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
15768 # 1. Remove the extension, and $U if already installed.
e1052144 15769 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
54445dc2 15770 ac_i=`printf "%s\n" "$ac_i" | sed "$ac_script"`
e1052144
TT
15771 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
15772 # will be set to the directory where LIBOBJS objects are built.
57aa50d4
TT
15773 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
15774 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
b0cacab0
TT
15775done
15776LIBOBJS=$ac_libobjs
50e1e10f 15777
b0cacab0
TT
15778LTLIBOBJS=$ac_ltlibobjs
15779
15780
15781
39fd3d4f 15782
d6a4bcb5 15783: "${CONFIG_STATUS=./config.status}"
39fd3d4f 15784ac_write_fail=0
b0cacab0
TT
15785ac_clean_files_save=$ac_clean_files
15786ac_clean_files="$ac_clean_files $CONFIG_STATUS"
54445dc2
TT
15787{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
15788printf "%s\n" "$as_me: creating $CONFIG_STATUS" >&6;}
57aa50d4
TT
15789as_write_fail=0
15790cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
b0cacab0
TT
15791#! $SHELL
15792# Generated by $as_me.
93636bde 15793# Run this file to recreate the current configuration.
93636bde 15794# Compiler output produced by configure, useful for debugging
b0cacab0 15795# configure, is in config.log if it exists.
07a0db15 15796
b0cacab0
TT
15797debug=false
15798ac_cs_recheck=false
15799ac_cs_silent=false
b0cacab0 15800
57aa50d4
TT
15801SHELL=\${CONFIG_SHELL-$SHELL}
15802export SHELL
15803_ASEOF
15804cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
15805## -------------------- ##
15806## M4sh Initialization. ##
15807## -------------------- ##
b0cacab0 15808
29a5deed
TT
15809# Be more Bourne compatible
15810DUALCASE=1; export DUALCASE # for MKS sh
54445dc2
TT
15811as_nop=:
15812if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
15813then :
b0cacab0
TT
15814 emulate sh
15815 NULLCMD=:
39fd3d4f 15816 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
b0cacab0
TT
15817 # is contrary to our usage. Disable this feature.
15818 alias -g '${1+"$@"}'='"$@"'
e1052144 15819 setopt NO_GLOB_SUBST
54445dc2 15820else $as_nop
57aa50d4
TT
15821 case `(set -o) 2>/dev/null` in #(
15822 *posix*) :
15823 set -o posix ;; #(
15824 *) :
15825 ;;
29a5deed 15826esac
b0cacab0 15827fi
29a5deed
TT
15828
15829
54445dc2
TT
15830
15831# Reset variables that may have inherited troublesome values from
15832# the environment.
15833
15834# IFS needs to be set, to space, tab, and newline, in precisely that order.
15835# (If _AS_PATH_WALK were called with IFS unset, it would have the
15836# side effect of setting IFS to empty, thus disabling word splitting.)
15837# Quoting is to prevent editors from complaining about space-tab.
39fd3d4f
SJR
15838as_nl='
15839'
15840export as_nl
54445dc2
TT
15841IFS=" "" $as_nl"
15842
15843PS1='$ '
15844PS2='> '
15845PS4='+ '
15846
15847# Ensure predictable behavior from utilities with locale-dependent output.
15848LC_ALL=C
15849export LC_ALL
15850LANGUAGE=C
15851export LANGUAGE
15852
15853# We cannot yet rely on "unset" to work, but we need these variables
15854# to be unset--not just set to an empty or harmless value--now, to
15855# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct
15856# also avoids known problems related to "unset" and subshell syntax
15857# in other old shells (e.g. bash 2.01 and pdksh 5.2.14).
15858for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH
15859do eval test \${$as_var+y} \
15860 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
15861done
15862
15863# Ensure that fds 0, 1, and 2 are open.
15864if (exec 3>&0) 2>/dev/null; then :; else exec 0</dev/null; fi
15865if (exec 3>&1) 2>/dev/null; then :; else exec 1>/dev/null; fi
15866if (exec 3>&2) ; then :; else exec 2>/dev/null; fi
39fd3d4f
SJR
15867
15868# The user is always right.
54445dc2 15869if ${PATH_SEPARATOR+false} :; then
39fd3d4f
SJR
15870 PATH_SEPARATOR=:
15871 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
15872 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
15873 PATH_SEPARATOR=';'
15874 }
e1052144
TT
15875fi
15876
b0cacab0 15877
e1052144 15878# Find who we are. Look in the path if we contain no directory separator.
d6a4bcb5 15879as_myself=
57aa50d4 15880case $0 in #((
e1052144
TT
15881 *[\\/]* ) as_myself=$0 ;;
15882 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15883for as_dir in $PATH
15884do
15885 IFS=$as_save_IFS
54445dc2
TT
15886 case $as_dir in #(((
15887 '') as_dir=./ ;;
15888 */) ;;
15889 *) as_dir=$as_dir/ ;;
15890 esac
15891 test -r "$as_dir$0" && as_myself=$as_dir$0 && break
57aa50d4 15892 done
e1052144
TT
15893IFS=$as_save_IFS
15894
15895 ;;
15896esac
15897# We did not find ourselves, most probably we were run as `sh COMMAND'
15898# in which case we are not to be found in the path.
15899if test "x$as_myself" = x; then
15900 as_myself=$0
15901fi
15902if test ! -f "$as_myself"; then
54445dc2 15903 printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
57aa50d4 15904 exit 1
e1052144
TT
15905fi
15906
57aa50d4
TT
15907
15908
d6a4bcb5
TB
15909# as_fn_error STATUS ERROR [LINENO LOG_FD]
15910# ----------------------------------------
57aa50d4
TT
15911# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
15912# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
d6a4bcb5 15913# script with STATUS, using 1 if that was 0.
57aa50d4
TT
15914as_fn_error ()
15915{
d6a4bcb5
TB
15916 as_status=$1; test $as_status -eq 0 && as_status=1
15917 if test "$4"; then
15918 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
54445dc2 15919 printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
57aa50d4 15920 fi
54445dc2 15921 printf "%s\n" "$as_me: error: $2" >&2
57aa50d4
TT
15922 as_fn_exit $as_status
15923} # as_fn_error
15924
15925
54445dc2 15926
57aa50d4
TT
15927# as_fn_set_status STATUS
15928# -----------------------
15929# Set $? to STATUS, without forking.
15930as_fn_set_status ()
15931{
15932 return $1
15933} # as_fn_set_status
15934
15935# as_fn_exit STATUS
15936# -----------------
15937# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
15938as_fn_exit ()
15939{
15940 set +e
15941 as_fn_set_status $1
15942 exit $1
15943} # as_fn_exit
15944
15945# as_fn_unset VAR
15946# ---------------
15947# Portably unset VAR.
15948as_fn_unset ()
15949{
15950 { eval $1=; unset $1;}
15951}
15952as_unset=as_fn_unset
54445dc2 15953
57aa50d4
TT
15954# as_fn_append VAR VALUE
15955# ----------------------
15956# Append the text in VALUE to the end of the definition contained in VAR. Take
15957# advantage of any shell optimizations that allow amortized linear growth over
15958# repeated appends, instead of the typical quadratic growth present in naive
15959# implementations.
54445dc2
TT
15960if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null
15961then :
57aa50d4
TT
15962 eval 'as_fn_append ()
15963 {
15964 eval $1+=\$2
15965 }'
54445dc2 15966else $as_nop
57aa50d4
TT
15967 as_fn_append ()
15968 {
15969 eval $1=\$$1\$2
15970 }
15971fi # as_fn_append
15972
15973# as_fn_arith ARG...
15974# ------------------
15975# Perform arithmetic evaluation on the ARGs, and store the result in the
15976# global $as_val. Take advantage of shells that can avoid forks. The arguments
15977# must be portable across $(()) and expr.
54445dc2
TT
15978if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null
15979then :
57aa50d4
TT
15980 eval 'as_fn_arith ()
15981 {
15982 as_val=$(( $* ))
15983 }'
54445dc2 15984else $as_nop
57aa50d4
TT
15985 as_fn_arith ()
15986 {
15987 as_val=`expr "$@" || test $? -eq 1`
15988 }
15989fi # as_fn_arith
15990
15991
e1052144
TT
15992if expr a : '\(a\)' >/dev/null 2>&1 &&
15993 test "X`expr 00001 : '.*\(...\)'`" = X001; then
b0cacab0
TT
15994 as_expr=expr
15995else
15996 as_expr=false
15997fi
15998
e1052144 15999if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
b0cacab0
TT
16000 as_basename=basename
16001else
16002 as_basename=false
16003fi
16004
57aa50d4
TT
16005if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
16006 as_dirname=dirname
16007else
16008 as_dirname=false
16009fi
b0cacab0 16010
e1052144 16011as_me=`$as_basename -- "$0" ||
b0cacab0
TT
16012$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
16013 X"$0" : 'X\(//\)$' \| \
e1052144 16014 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
54445dc2 16015printf "%s\n" X/"$0" |
e1052144
TT
16016 sed '/^.*\/\([^/][^/]*\)\/*$/{
16017 s//\1/
16018 q
16019 }
16020 /^X\/\(\/\/\)$/{
16021 s//\1/
16022 q
16023 }
16024 /^X\/\(\/\).*/{
16025 s//\1/
16026 q
16027 }
16028 s/.*/./; q'`
b0cacab0 16029
57aa50d4
TT
16030# Avoid depending upon Character Ranges.
16031as_cr_letters='abcdefghijklmnopqrstuvwxyz'
16032as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
16033as_cr_Letters=$as_cr_letters$as_cr_LETTERS
16034as_cr_digits='0123456789'
16035as_cr_alnum=$as_cr_Letters$as_cr_digits
e1052144 16036
54445dc2
TT
16037
16038# Determine whether it's possible to make 'echo' print without a newline.
16039# These variables are no longer used directly by Autoconf, but are AC_SUBSTed
16040# for compatibility with existing Makefiles.
e1052144 16041ECHO_C= ECHO_N= ECHO_T=
57aa50d4 16042case `echo -n x` in #(((((
e1052144 16043-n*)
57aa50d4 16044 case `echo 'xy\c'` in
e1052144 16045 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
57aa50d4
TT
16046 xy) ECHO_C='\c';;
16047 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
16048 ECHO_T=' ';;
e1052144
TT
16049 esac;;
16050*)
16051 ECHO_N='-n';;
b0cacab0 16052esac
b0cacab0 16053
54445dc2
TT
16054# For backward compatibility with old third-party macros, we provide
16055# the shell variables $as_echo and $as_echo_n. New code should use
16056# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively.
16057as_echo='printf %s\n'
16058as_echo_n='printf %s'
16059
b0cacab0 16060rm -f conf$$ conf$$.exe conf$$.file
e1052144
TT
16061if test -d conf$$.dir; then
16062 rm -f conf$$.dir/conf$$.file
16063else
16064 rm -f conf$$.dir
39fd3d4f
SJR
16065 mkdir conf$$.dir 2>/dev/null
16066fi
16067if (echo >conf$$.file) 2>/dev/null; then
16068 if ln -s conf$$.file conf$$ 2>/dev/null; then
16069 as_ln_s='ln -s'
16070 # ... but there are two gotchas:
16071 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
16072 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
d6a4bcb5 16073 # In both cases, we have to default to `cp -pR'.
39fd3d4f 16074 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
d6a4bcb5 16075 as_ln_s='cp -pR'
39fd3d4f
SJR
16076 elif ln conf$$.file conf$$ 2>/dev/null; then
16077 as_ln_s=ln
16078 else
d6a4bcb5 16079 as_ln_s='cp -pR'
39fd3d4f 16080 fi
b0cacab0 16081else
d6a4bcb5 16082 as_ln_s='cp -pR'
b0cacab0 16083fi
e1052144
TT
16084rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
16085rmdir conf$$.dir 2>/dev/null
b0cacab0 16086
57aa50d4
TT
16087
16088# as_fn_mkdir_p
16089# -------------
16090# Create "$as_dir" as a directory, including parents if necessary.
16091as_fn_mkdir_p ()
16092{
16093
16094 case $as_dir in #(
16095 -*) as_dir=./$as_dir;;
16096 esac
16097 test -d "$as_dir" || eval $as_mkdir_p || {
16098 as_dirs=
16099 while :; do
16100 case $as_dir in #(
54445dc2 16101 *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
57aa50d4
TT
16102 *) as_qdir=$as_dir;;
16103 esac
16104 as_dirs="'$as_qdir' $as_dirs"
16105 as_dir=`$as_dirname -- "$as_dir" ||
16106$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
16107 X"$as_dir" : 'X\(//\)[^/]' \| \
16108 X"$as_dir" : 'X\(//\)$' \| \
16109 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
54445dc2 16110printf "%s\n" X"$as_dir" |
57aa50d4
TT
16111 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
16112 s//\1/
16113 q
16114 }
16115 /^X\(\/\/\)[^/].*/{
16116 s//\1/
16117 q
16118 }
16119 /^X\(\/\/\)$/{
16120 s//\1/
16121 q
16122 }
16123 /^X\(\/\).*/{
16124 s//\1/
16125 q
16126 }
16127 s/.*/./; q'`
16128 test -d "$as_dir" && break
16129 done
16130 test -z "$as_dirs" || eval "mkdir $as_dirs"
d6a4bcb5 16131 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
57aa50d4
TT
16132
16133
16134} # as_fn_mkdir_p
b0cacab0 16135if mkdir -p . 2>/dev/null; then
57aa50d4 16136 as_mkdir_p='mkdir -p "$as_dir"'
b0cacab0
TT
16137else
16138 test -d ./-p && rmdir ./-p
16139 as_mkdir_p=false
16140fi
16141
d6a4bcb5
TB
16142
16143# as_fn_executable_p FILE
16144# -----------------------
16145# Test if FILE is an executable regular file.
16146as_fn_executable_p ()
16147{
16148 test -f "$1" && test -x "$1"
16149} # as_fn_executable_p
16150as_test_x='test -x'
16151as_executable_p=as_fn_executable_p
b0cacab0
TT
16152
16153# Sed expression to map a string onto a valid CPP name.
16154as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
16155
16156# Sed expression to map a string onto a valid variable name.
16157as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
16158
16159
b0cacab0 16160exec 6>&1
57aa50d4
TT
16161## ----------------------------------- ##
16162## Main body of $CONFIG_STATUS script. ##
16163## ----------------------------------- ##
16164_ASEOF
16165test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
b0cacab0 16166
57aa50d4
TT
16167cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16168# Save the log message, to keep $0 and so on meaningful, and to
b0cacab0 16169# report actual input values of CONFIG_FILES etc. instead of their
e1052144
TT
16170# values after options handling.
16171ac_log="
b0cacab0 16172This file was extended by $as_me, which was
54445dc2 16173generated by GNU Autoconf 2.71. Invocation command line was
b0cacab0
TT
16174
16175 CONFIG_FILES = $CONFIG_FILES
16176 CONFIG_HEADERS = $CONFIG_HEADERS
16177 CONFIG_LINKS = $CONFIG_LINKS
16178 CONFIG_COMMANDS = $CONFIG_COMMANDS
16179 $ $0 $@
16180
e1052144
TT
16181on `(hostname || uname -n) 2>/dev/null | sed 1q`
16182"
16183
b0cacab0
TT
16184_ACEOF
16185
39fd3d4f
SJR
16186case $ac_config_files in *"
16187"*) set x $ac_config_files; shift; ac_config_files=$*;;
16188esac
16189
d1154eb4
TT
16190case $ac_config_headers in *"
16191"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
16192esac
39fd3d4f
SJR
16193
16194
16195cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
b0cacab0 16196# Files that config.status was made for.
e1052144 16197config_files="$ac_config_files"
d1154eb4 16198config_headers="$ac_config_headers"
e1052144 16199config_commands="$ac_config_commands"
b0cacab0 16200
e1052144 16201_ACEOF
b0cacab0 16202
39fd3d4f 16203cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
b0cacab0 16204ac_cs_usage="\
57aa50d4
TT
16205\`$as_me' instantiates files and other configuration actions
16206from templates according to the current configuration. Unless the files
16207and actions are specified as TAGs, all are instantiated by default.
b0cacab0 16208
57aa50d4 16209Usage: $0 [OPTION]... [TAG]...
b0cacab0
TT
16210
16211 -h, --help print this help, then exit
29a5deed 16212 -V, --version print version number and configuration settings, then exit
61ef2474 16213 --config print configuration, then exit
39fd3d4f
SJR
16214 -q, --quiet, --silent
16215 do not print progress messages
b0cacab0
TT
16216 -d, --debug don't remove temporary files
16217 --recheck update $as_me by reconfiguring in the same conditions
39fd3d4f
SJR
16218 --file=FILE[:TEMPLATE]
16219 instantiate the configuration file FILE
d1154eb4
TT
16220 --header=FILE[:TEMPLATE]
16221 instantiate the configuration header FILE
b0cacab0
TT
16222
16223Configuration files:
16224$config_files
16225
d1154eb4
TT
16226Configuration headers:
16227$config_headers
16228
b0cacab0
TT
16229Configuration commands:
16230$config_commands
16231
57aa50d4 16232Report bugs to the package provider."
b0cacab0 16233
e1052144 16234_ACEOF
54445dc2
TT
16235ac_cs_config=`printf "%s\n" "$ac_configure_args" | sed "$ac_safe_unquote"`
16236ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\''/g"`
39fd3d4f 16237cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
54445dc2 16238ac_cs_config='$ac_cs_config_escaped'
b0cacab0
TT
16239ac_cs_version="\\
16240config.status
54445dc2 16241configured by $0, generated by GNU Autoconf 2.71,
61ef2474 16242 with options \\"\$ac_cs_config\\"
b0cacab0 16243
54445dc2 16244Copyright (C) 2021 Free Software Foundation, Inc.
b0cacab0
TT
16245This config.status script is free software; the Free Software Foundation
16246gives unlimited permission to copy, distribute and modify it."
e1052144
TT
16247
16248ac_pwd='$ac_pwd'
16249srcdir='$srcdir'
16250INSTALL='$INSTALL'
93613951 16251MKDIR_P='$MKDIR_P'
39fd3d4f
SJR
16252AWK='$AWK'
16253test -n "\$AWK" || AWK=awk
b0cacab0
TT
16254_ACEOF
16255
39fd3d4f
SJR
16256cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16257# The default lists apply if the user does not specify any file.
b0cacab0
TT
16258ac_need_defaults=:
16259while test $# != 0
07a0db15 16260do
b0cacab0 16261 case $1 in
d6a4bcb5 16262 --*=?*)
e1052144
TT
16263 ac_option=`expr "X$1" : 'X\([^=]*\)='`
16264 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
b0cacab0
TT
16265 ac_shift=:
16266 ;;
d6a4bcb5
TB
16267 --*=)
16268 ac_option=`expr "X$1" : 'X\([^=]*\)='`
16269 ac_optarg=
16270 ac_shift=:
16271 ;;
e1052144 16272 *)
b0cacab0
TT
16273 ac_option=$1
16274 ac_optarg=$2
16275 ac_shift=shift
16276 ;;
b0cacab0
TT
16277 esac
16278
16279 case $ac_option in
16280 # Handling of the options.
93636bde 16281 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
b0cacab0 16282 ac_cs_recheck=: ;;
e1052144 16283 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
54445dc2 16284 printf "%s\n" "$ac_cs_version"; exit ;;
61ef2474 16285 --config | --confi | --conf | --con | --co | --c )
54445dc2 16286 printf "%s\n" "$ac_cs_config"; exit ;;
e1052144 16287 --debug | --debu | --deb | --de | --d | -d )
b0cacab0
TT
16288 debug=: ;;
16289 --file | --fil | --fi | --f )
16290 $ac_shift
39fd3d4f 16291 case $ac_optarg in
54445dc2 16292 *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
d6a4bcb5 16293 '') as_fn_error $? "missing file argument" ;;
39fd3d4f 16294 esac
57aa50d4 16295 as_fn_append CONFIG_FILES " '$ac_optarg'"
b0cacab0 16296 ac_need_defaults=false;;
d1154eb4
TT
16297 --header | --heade | --head | --hea )
16298 $ac_shift
16299 case $ac_optarg in
54445dc2 16300 *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
d1154eb4
TT
16301 esac
16302 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
16303 ac_need_defaults=false;;
16304 --he | --h)
16305 # Conflict between --help and --header
d6a4bcb5 16306 as_fn_error $? "ambiguous option: \`$1'
d1154eb4
TT
16307Try \`$0 --help' for more information.";;
16308 --help | --hel | -h )
54445dc2 16309 printf "%s\n" "$ac_cs_usage"; exit ;;
b0cacab0
TT
16310 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
16311 | -silent | --silent | --silen | --sile | --sil | --si | --s)
16312 ac_cs_silent=: ;;
16313
16314 # This is an error.
d6a4bcb5 16315 -*) as_fn_error $? "unrecognized option: \`$1'
57aa50d4 16316Try \`$0 --help' for more information." ;;
b0cacab0 16317
57aa50d4 16318 *) as_fn_append ac_config_targets " $1"
e1052144 16319 ac_need_defaults=false ;;
b0cacab0 16320
07a0db15 16321 esac
b0cacab0 16322 shift
07a0db15
TT
16323done
16324
b0cacab0
TT
16325ac_configure_extra_args=
16326
16327if $ac_cs_silent; then
16328 exec 6>/dev/null
16329 ac_configure_extra_args="$ac_configure_extra_args --silent"
16330fi
16331
16332_ACEOF
39fd3d4f 16333cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
b0cacab0 16334if \$ac_cs_recheck; then
d6a4bcb5 16335 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
39fd3d4f 16336 shift
54445dc2 16337 \printf "%s\n" "running CONFIG_SHELL=$SHELL \$*" >&6
39fd3d4f 16338 CONFIG_SHELL='$SHELL'
e1052144 16339 export CONFIG_SHELL
39fd3d4f 16340 exec "\$@"
b0cacab0 16341fi
07a0db15 16342
b0cacab0 16343_ACEOF
39fd3d4f 16344cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
e1052144
TT
16345exec 5>>config.log
16346{
16347 echo
16348 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
16349## Running $as_me. ##
16350_ASBOX
54445dc2 16351 printf "%s\n" "$ac_log"
e1052144 16352} >&5
07a0db15 16353
e1052144 16354_ACEOF
39fd3d4f 16355cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
b0cacab0 16356#
e1052144 16357# INIT-COMMANDS
b0cacab0 16358#
b0cacab0 16359# Capture the value of obsolete ALL_LINGUAS because we need it to compute
bdcd5f22
TT
16360 # POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES, CATALOGS.
16361 OBSOLETE_ALL_LINGUAS="$ALL_LINGUAS"
b0cacab0
TT
16362 # Capture the value of LINGUAS because we need it to compute CATALOGS.
16363 LINGUAS="${LINGUAS-%UNSET%}"
16364
16365
16366_ACEOF
16367
39fd3d4f 16368cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
e1052144
TT
16369
16370# Handling of arguments.
b0cacab0
TT
16371for ac_config_target in $ac_config_targets
16372do
e1052144 16373 case $ac_config_target in
d1154eb4 16374 "lib/config.h") CONFIG_HEADERS="$CONFIG_HEADERS lib/config.h" ;;
93613951 16375 "po-directories") CONFIG_COMMANDS="$CONFIG_COMMANDS po-directories" ;;
e1052144
TT
16376 "$outlist") CONFIG_FILES="$CONFIG_FILES $outlist" ;;
16377
d6a4bcb5 16378 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
b0cacab0
TT
16379 esac
16380done
16381
e1052144 16382
b0cacab0
TT
16383# If the user did not use the arguments to specify the items to instantiate,
16384# then the envvar interface is used. Set only those that are not.
16385# We use the long form for the default assignment because of an extremely
16386# bizarre bug on SunOS 4.1.3.
16387if $ac_need_defaults; then
54445dc2
TT
16388 test ${CONFIG_FILES+y} || CONFIG_FILES=$config_files
16389 test ${CONFIG_HEADERS+y} || CONFIG_HEADERS=$config_headers
16390 test ${CONFIG_COMMANDS+y} || CONFIG_COMMANDS=$config_commands
b0cacab0
TT
16391fi
16392
16393# Have a temporary directory for convenience. Make it in the build tree
e1052144 16394# simply because there is no reason against having it here, and in addition,
b0cacab0 16395# creating and moving files from /tmp can sometimes cause problems.
e1052144
TT
16396# Hook for its removal unless debugging.
16397# Note that there is a small window in which the directory will not be cleaned:
16398# after its creation but before its name has been assigned to `$tmp'.
b0cacab0
TT
16399$debug ||
16400{
d6a4bcb5 16401 tmp= ac_tmp=
e1052144 16402 trap 'exit_status=$?
d6a4bcb5
TB
16403 : "${ac_tmp:=$tmp}"
16404 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
e1052144 16405' 0
57aa50d4 16406 trap 'as_fn_exit 1' 1 2 13 15
b0cacab0 16407}
b0cacab0
TT
16408# Create a (secure) tmp directory for tmp files.
16409
16410{
e1052144 16411 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
d6a4bcb5 16412 test -d "$tmp"
b0cacab0
TT
16413} ||
16414{
e1052144
TT
16415 tmp=./conf$$-$RANDOM
16416 (umask 077 && mkdir "$tmp")
d6a4bcb5
TB
16417} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
16418ac_tmp=$tmp
b0cacab0 16419
39fd3d4f
SJR
16420# Set up the scripts for CONFIG_FILES section.
16421# No need to generate them if there are no CONFIG_FILES.
16422# This happens for instance with `./config.status config.h'.
e1052144
TT
16423if test -n "$CONFIG_FILES"; then
16424
39fd3d4f
SJR
16425if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
16426 ac_cs_awk_getline=:
16427 ac_cs_awk_pipe_init=
16428 ac_cs_awk_read_file='
16429 while ((getline aline < (F[key])) > 0)
16430 print(aline)
16431 close(F[key])'
16432 ac_cs_awk_pipe_fini=
16433else
16434 ac_cs_awk_getline=false
16435 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
16436 ac_cs_awk_read_file='
16437 print "|#_!!_#|"
16438 print "cat " F[key] " &&"
16439 '$ac_cs_awk_pipe_init
16440 # The final `:' finishes the AND list.
16441 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
16442fi
57aa50d4
TT
16443ac_cr=`echo X | tr X '\015'`
16444# On cygwin, bash can eat \r inside `` if the user requested igncr.
16445# But we know of no other shell where ac_cr would be empty at this
16446# point, so we can use a bashism as a fallback.
16447if test "x$ac_cr" = x; then
16448 eval ac_cr=\$\'\\r\'
16449fi
39fd3d4f
SJR
16450ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
16451if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
d6a4bcb5 16452 ac_cs_awk_cr='\\r'
39fd3d4f
SJR
16453else
16454 ac_cs_awk_cr=$ac_cr
16455fi
e1052144 16456
d6a4bcb5 16457echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
39fd3d4f 16458_ACEOF
e1052144 16459
39fd3d4f
SJR
16460# Create commands to substitute file output variables.
16461{
16462 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
d6a4bcb5 16463 echo 'cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&' &&
39fd3d4f
SJR
16464 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
16465 echo "_ACAWK" &&
16466 echo "_ACEOF"
16467} >conf$$files.sh &&
16468. ./conf$$files.sh ||
d6a4bcb5 16469 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
39fd3d4f 16470rm -f conf$$files.sh
e1052144 16471
39fd3d4f
SJR
16472{
16473 echo "cat >conf$$subs.awk <<_ACEOF" &&
16474 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
16475 echo "_ACEOF"
16476} >conf$$subs.sh ||
d6a4bcb5
TB
16477 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
16478ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
e1052144
TT
16479ac_delim='%!_!# '
16480for ac_last_try in false false false false false :; do
39fd3d4f 16481 . ./conf$$subs.sh ||
d6a4bcb5 16482 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
39fd3d4f
SJR
16483
16484 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
16485 if test $ac_delim_n = $ac_delim_num; then
e1052144
TT
16486 break
16487 elif $ac_last_try; then
d6a4bcb5 16488 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
e1052144
TT
16489 else
16490 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
21c84b71 16491 fi
e1052144 16492done
39fd3d4f
SJR
16493rm -f conf$$subs.sh
16494
16495cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
d6a4bcb5 16496cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
39fd3d4f
SJR
16497_ACEOF
16498sed -n '
16499h
16500s/^/S["/; s/!.*/"]=/
16501p
16502g
16503s/^[^!]*!//
16504:repl
16505t repl
16506s/'"$ac_delim"'$//
16507t delim
16508:nl
16509h
61ef2474 16510s/\(.\{148\}\)..*/\1/
39fd3d4f
SJR
16511t more1
16512s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
16513p
16514n
16515b repl
16516:more1
16517s/["\\]/\\&/g; s/^/"/; s/$/"\\/
16518p
16519g
16520s/.\{148\}//
16521t nl
16522:delim
16523h
61ef2474 16524s/\(.\{148\}\)..*/\1/
39fd3d4f
SJR
16525t more2
16526s/["\\]/\\&/g; s/^/"/; s/$/"/
16527p
16528b
16529:more2
16530s/["\\]/\\&/g; s/^/"/; s/$/"\\/
16531p
16532g
16533s/.\{148\}//
16534t delim
16535' <conf$$subs.awk | sed '
16536/^[^""]/{
16537 N
16538 s/\n//
e1052144 16539}
39fd3d4f
SJR
16540' >>$CONFIG_STATUS || ac_write_fail=1
16541rm -f conf$$subs.awk
16542cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16543_ACAWK
d6a4bcb5 16544cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
39fd3d4f
SJR
16545 for (key in S) S_is_set[key] = 1
16546 FS = "\a"
16547 \$ac_cs_awk_pipe_init
e1052144 16548}
39fd3d4f
SJR
16549{
16550 line = $ 0
16551 nfields = split(line, field, "@")
16552 substed = 0
16553 len = length(field[1])
16554 for (i = 2; i < nfields; i++) {
16555 key = field[i]
16556 keylen = length(key)
16557 if (S_is_set[key]) {
16558 value = S[key]
16559 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
16560 len += length(value) + length(field[++i])
16561 substed = 1
16562 } else
16563 len += 1 + keylen
16564 }
16565 if (nfields == 3 && !substed) {
16566 key = field[2]
16567 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
16568 \$ac_cs_awk_read_file
16569 next
16570 }
16571 }
16572 print line
488c75a6 16573}
39fd3d4f
SJR
16574\$ac_cs_awk_pipe_fini
16575_ACAWK
e1052144 16576_ACEOF
39fd3d4f
SJR
16577cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16578if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
16579 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
16580else
16581 cat
d6a4bcb5
TB
16582fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
16583 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
b0cacab0 16584_ACEOF
e1052144 16585
d6a4bcb5
TB
16586# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
16587# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
e1052144
TT
16588# trailing colons and then remove the whole line if VPATH becomes empty
16589# (actually we leave an empty line to preserve line numbers).
16590if test "x$srcdir" = x.; then
d6a4bcb5
TB
16591 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
16592h
16593s///
16594s/^/:/
16595s/[ ]*$/:/
16596s/:\$(srcdir):/:/g
16597s/:\${srcdir}:/:/g
16598s/:@srcdir@:/:/g
16599s/^:*//
e1052144 16600s/:*$//
d6a4bcb5
TB
16601x
16602s/\(=[ ]*\).*/\1/
16603G
16604s/\n//
e1052144
TT
16605s/^[^=]*=[ ]*$//
16606}'
16607fi
16608
39fd3d4f 16609cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
e1052144
TT
16610fi # test -n "$CONFIG_FILES"
16611
d1154eb4
TT
16612# Set up the scripts for CONFIG_HEADERS section.
16613# No need to generate them if there are no CONFIG_HEADERS.
16614# This happens for instance with `./config.status Makefile'.
16615if test -n "$CONFIG_HEADERS"; then
d6a4bcb5 16616cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
d1154eb4
TT
16617BEGIN {
16618_ACEOF
16619
16620# Transform confdefs.h into an awk script `defines.awk', embedded as
16621# here-document in config.status, that substitutes the proper values into
16622# config.h.in to produce config.h.
16623
16624# Create a delimiter string that does not exist in confdefs.h, to ease
16625# handling of long lines.
16626ac_delim='%!_!# '
16627for ac_last_try in false false :; do
d6a4bcb5
TB
16628 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
16629 if test -z "$ac_tt"; then
d1154eb4
TT
16630 break
16631 elif $ac_last_try; then
d6a4bcb5 16632 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
d1154eb4
TT
16633 else
16634 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
16635 fi
16636done
16637
16638# For the awk script, D is an array of macro values keyed by name,
16639# likewise P contains macro parameters if any. Preserve backslash
16640# newline sequences.
16641
16642ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
16643sed -n '
16644s/.\{148\}/&'"$ac_delim"'/g
16645t rset
16646:rset
16647s/^[ ]*#[ ]*define[ ][ ]*/ /
16648t def
16649d
16650:def
16651s/\\$//
16652t bsnl
16653s/["\\]/\\&/g
16654s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
16655D["\1"]=" \3"/p
16656s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
16657d
16658:bsnl
16659s/["\\]/\\&/g
16660s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
16661D["\1"]=" \3\\\\\\n"\\/p
16662t cont
16663s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
16664t cont
16665d
16666:cont
16667n
16668s/.\{148\}/&'"$ac_delim"'/g
16669t clear
16670:clear
16671s/\\$//
16672t bsnlc
16673s/["\\]/\\&/g; s/^/"/; s/$/"/p
16674d
16675:bsnlc
16676s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
16677b cont
16678' <confdefs.h | sed '
16679s/'"$ac_delim"'/"\\\
16680"/g' >>$CONFIG_STATUS || ac_write_fail=1
16681
16682cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16683 for (key in D) D_is_set[key] = 1
16684 FS = "\a"
16685}
16686/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
16687 line = \$ 0
16688 split(line, arg, " ")
16689 if (arg[1] == "#") {
16690 defundef = arg[2]
16691 mac1 = arg[3]
16692 } else {
16693 defundef = substr(arg[1], 2)
16694 mac1 = arg[2]
16695 }
16696 split(mac1, mac2, "(") #)
16697 macro = mac2[1]
16698 prefix = substr(line, 1, index(line, defundef) - 1)
16699 if (D_is_set[macro]) {
16700 # Preserve the white space surrounding the "#".
16701 print prefix "define", macro P[macro] D[macro]
16702 next
16703 } else {
16704 # Replace #undef with comments. This is necessary, for example,
16705 # in the case of _POSIX_SOURCE, which is predefined and required
16706 # on some systems where configure will not decide to define it.
16707 if (defundef == "undef") {
16708 print "/*", prefix defundef, macro, "*/"
16709 next
16710 }
16711 }
16712}
16713{ print }
16714_ACAWK
16715_ACEOF
16716cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
d6a4bcb5 16717 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
d1154eb4
TT
16718fi # test -n "$CONFIG_HEADERS"
16719
e1052144 16720
d1154eb4 16721eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
39fd3d4f
SJR
16722shift
16723for ac_tag
e1052144
TT
16724do
16725 case $ac_tag in
16726 :[FHLC]) ac_mode=$ac_tag; continue;;
16727 esac
16728 case $ac_mode$ac_tag in
16729 :[FHL]*:*);;
d6a4bcb5 16730 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
e1052144
TT
16731 :[FH]-) ac_tag=-:-;;
16732 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
16733 esac
16734 ac_save_IFS=$IFS
16735 IFS=:
16736 set x $ac_tag
16737 IFS=$ac_save_IFS
16738 shift
16739 ac_file=$1
16740 shift
16741
16742 case $ac_mode in
16743 :L) ac_source=$1;;
16744 :[FH])
16745 ac_file_inputs=
16746 for ac_f
16747 do
16748 case $ac_f in
d6a4bcb5 16749 -) ac_f="$ac_tmp/stdin";;
e1052144
TT
16750 *) # Look for the file first in the build tree, then in the source tree
16751 # (if the path is not absolute). The absolute path cannot be DOS-style,
16752 # because $ac_f cannot contain `:'.
16753 test -f "$ac_f" ||
16754 case $ac_f in
16755 [\\/$]*) false;;
16756 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
16757 esac ||
d6a4bcb5 16758 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
e1052144 16759 esac
54445dc2 16760 case $ac_f in *\'*) ac_f=`printf "%s\n" "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
57aa50d4 16761 as_fn_append ac_file_inputs " '$ac_f'"
e1052144
TT
16762 done
16763
16764 # Let's still pretend it is `configure' which instantiates (i.e., don't
16765 # use $as_me), people would be surprised to read:
16766 # /* config.h. Generated by config.status. */
39fd3d4f 16767 configure_input='Generated from '`
54445dc2 16768 printf "%s\n" "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
39fd3d4f 16769 `' by configure.'
e1052144
TT
16770 if test x"$ac_file" != x-; then
16771 configure_input="$ac_file. $configure_input"
54445dc2
TT
16772 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
16773printf "%s\n" "$as_me: creating $ac_file" >&6;}
e1052144 16774 fi
39fd3d4f
SJR
16775 # Neutralize special characters interpreted by sed in replacement strings.
16776 case $configure_input in #(
16777 *\&* | *\|* | *\\* )
54445dc2 16778 ac_sed_conf_input=`printf "%s\n" "$configure_input" |
39fd3d4f
SJR
16779 sed 's/[\\\\&|]/\\\\&/g'`;; #(
16780 *) ac_sed_conf_input=$configure_input;;
16781 esac
e1052144
TT
16782
16783 case $ac_tag in
d6a4bcb5
TB
16784 *:-:* | *:-) cat >"$ac_tmp/stdin" \
16785 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
e1052144
TT
16786 esac
16787 ;;
b0cacab0
TT
16788 esac
16789
e1052144 16790 ac_dir=`$as_dirname -- "$ac_file" ||
b0cacab0
TT
16791$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
16792 X"$ac_file" : 'X\(//\)[^/]' \| \
16793 X"$ac_file" : 'X\(//\)$' \| \
e1052144 16794 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
54445dc2 16795printf "%s\n" X"$ac_file" |
e1052144
TT
16796 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
16797 s//\1/
16798 q
16799 }
16800 /^X\(\/\/\)[^/].*/{
16801 s//\1/
16802 q
16803 }
16804 /^X\(\/\/\)$/{
16805 s//\1/
16806 q
16807 }
16808 /^X\(\/\).*/{
16809 s//\1/
16810 q
16811 }
16812 s/.*/./; q'`
57aa50d4 16813 as_dir="$ac_dir"; as_fn_mkdir_p
b0cacab0
TT
16814 ac_builddir=.
16815
e1052144
TT
16816case "$ac_dir" in
16817.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
16818*)
54445dc2 16819 ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'`
e1052144 16820 # A ".." for each directory in $ac_dir_suffix.
54445dc2 16821 ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
e1052144
TT
16822 case $ac_top_builddir_sub in
16823 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
16824 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
16825 esac ;;
16826esac
16827ac_abs_top_builddir=$ac_pwd
16828ac_abs_builddir=$ac_pwd$ac_dir_suffix
16829# for backward compatibility:
16830ac_top_builddir=$ac_top_build_prefix
93636bde 16831
b0cacab0 16832case $srcdir in
e1052144 16833 .) # We are building in place.
b0cacab0 16834 ac_srcdir=.
e1052144
TT
16835 ac_top_srcdir=$ac_top_builddir_sub
16836 ac_abs_top_srcdir=$ac_pwd ;;
16837 [\\/]* | ?:[\\/]* ) # Absolute name.
b0cacab0 16838 ac_srcdir=$srcdir$ac_dir_suffix;
e1052144
TT
16839 ac_top_srcdir=$srcdir
16840 ac_abs_top_srcdir=$srcdir ;;
16841 *) # Relative name.
16842 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
16843 ac_top_srcdir=$ac_top_build_prefix$srcdir
16844 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
b0cacab0 16845esac
e1052144 16846ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
b0cacab0 16847
b0cacab0 16848
e1052144
TT
16849 case $ac_mode in
16850 :F)
16851 #
16852 # CONFIG_FILE
16853 #
50e1e10f 16854
b0cacab0
TT
16855 case $INSTALL in
16856 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
e1052144 16857 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
50e1e10f 16858 esac
93613951
TT
16859 ac_MKDIR_P=$MKDIR_P
16860 case $MKDIR_P in
16861 [\\/$]* | ?:[\\/]* ) ;;
16862 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
16863 esac
e1052144 16864_ACEOF
50e1e10f 16865
39fd3d4f 16866cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
e1052144
TT
16867# If the template does not know about datarootdir, expand it.
16868# FIXME: This hack should be removed a few years after 2.60.
16869ac_datarootdir_hack=; ac_datarootdir_seen=
39fd3d4f
SJR
16870ac_sed_dataroot='
16871/datarootdir/ {
e1052144
TT
16872 p
16873 q
16874}
16875/@datadir@/p
16876/@docdir@/p
16877/@infodir@/p
16878/@localedir@/p
57aa50d4 16879/@mandir@/p'
39fd3d4f 16880case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
e1052144
TT
16881*datarootdir*) ac_datarootdir_seen=yes;;
16882*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
54445dc2
TT
16883 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
16884printf "%s\n" "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
b0cacab0 16885_ACEOF
39fd3d4f 16886cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
e1052144
TT
16887 ac_datarootdir_hack='
16888 s&@datadir@&$datadir&g
16889 s&@docdir@&$docdir&g
16890 s&@infodir@&$infodir&g
16891 s&@localedir@&$localedir&g
16892 s&@mandir@&$mandir&g
57aa50d4 16893 s&\\\${datarootdir}&$datarootdir&g' ;;
e1052144
TT
16894esac
16895_ACEOF
16896
16897# Neutralize VPATH when `$srcdir' = `.'.
16898# Shell code in configure.ac might set extrasub.
16899# FIXME: do we really want to maintain this feature?
39fd3d4f
SJR
16900cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16901ac_sed_extra="$ac_vpsub
b0cacab0
TT
16902$extrasub
16903_ACEOF
39fd3d4f 16904cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
b0cacab0
TT
16905:t
16906/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
39fd3d4f 16907s|@configure_input@|$ac_sed_conf_input|;t t
e1052144 16908s&@top_builddir@&$ac_top_builddir_sub&;t t
39fd3d4f 16909s&@top_build_prefix@&$ac_top_build_prefix&;t t
e1052144
TT
16910s&@srcdir@&$ac_srcdir&;t t
16911s&@abs_srcdir@&$ac_abs_srcdir&;t t
16912s&@top_srcdir@&$ac_top_srcdir&;t t
16913s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
16914s&@builddir@&$ac_builddir&;t t
16915s&@abs_builddir@&$ac_abs_builddir&;t t
16916s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
16917s&@INSTALL@&$ac_INSTALL&;t t
93613951 16918s&@MKDIR_P@&$ac_MKDIR_P&;t t
e1052144 16919$ac_datarootdir_hack
39fd3d4f
SJR
16920"
16921eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
16922if $ac_cs_awk_getline; then
d6a4bcb5 16923 $AWK -f "$ac_tmp/subs.awk"
39fd3d4f 16924else
d6a4bcb5
TB
16925 $AWK -f "$ac_tmp/subs.awk" | $SHELL
16926fi \
16927 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
e1052144
TT
16928
16929test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
d6a4bcb5
TB
16930 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
16931 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
16932 "$ac_tmp/out"`; test -z "$ac_out"; } &&
54445dc2 16933 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
d6a4bcb5 16934which seems to be undefined. Please make sure it is defined" >&5
54445dc2 16935printf "%s\n" "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
d6a4bcb5 16936which seems to be undefined. Please make sure it is defined" >&2;}
e1052144 16937
d6a4bcb5 16938 rm -f "$ac_tmp/stdin"
e1052144 16939 case $ac_file in
d6a4bcb5
TB
16940 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
16941 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
39fd3d4f 16942 esac \
d6a4bcb5 16943 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
e1052144 16944 ;;
d1154eb4
TT
16945 :H)
16946 #
16947 # CONFIG_HEADER
16948 #
16949 if test x"$ac_file" != x-; then
16950 {
54445dc2 16951 printf "%s\n" "/* $configure_input */" >&1 \
d6a4bcb5
TB
16952 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
16953 } >"$ac_tmp/config.h" \
16954 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
16955 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
54445dc2
TT
16956 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
16957printf "%s\n" "$as_me: $ac_file is unchanged" >&6;}
d1154eb4
TT
16958 else
16959 rm -f "$ac_file"
d6a4bcb5
TB
16960 mv "$ac_tmp/config.h" "$ac_file" \
16961 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
d1154eb4
TT
16962 fi
16963 else
54445dc2 16964 printf "%s\n" "/* $configure_input */" >&1 \
d6a4bcb5
TB
16965 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
16966 || as_fn_error $? "could not create -" "$LINENO" 5
d1154eb4
TT
16967 fi
16968 ;;
07a0db15 16969
54445dc2
TT
16970 :C) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
16971printf "%s\n" "$as_me: executing $ac_file commands" >&6;}
e1052144
TT
16972 ;;
16973 esac
a04eba3f 16974
b0cacab0 16975
e1052144 16976 case $ac_file$ac_mode in
93613951 16977 "po-directories":C)
a04eba3f
TT
16978 for ac_file in $CONFIG_FILES; do
16979 # Support "outfile[:infile[:infile...]]"
16980 case "$ac_file" in
16981 *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
16982 esac
16983 # PO directories have a Makefile.in generated from Makefile.in.in.
16984 case "$ac_file" in */Makefile.in)
16985 # Adjust a relative srcdir.
16986 ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
93613951 16987 ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
a04eba3f
TT
16988 ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
16989 # In autoconf-2.13 it is called $ac_given_srcdir.
16990 # In autoconf-2.50 it is called $srcdir.
16991 test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
16992 case "$ac_given_srcdir" in
16993 .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
16994 /*) top_srcdir="$ac_given_srcdir" ;;
16995 *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
16996 esac
93613951
TT
16997 # Treat a directory as a PO directory if and only if it has a
16998 # POTFILES.in file. This allows packages to have multiple PO
16999 # directories under different names or in different locations.
a04eba3f
TT
17000 if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
17001 rm -f "$ac_dir/POTFILES"
17002 test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
93613951
TT
17003 gt_tab=`printf '\t'`
17004 cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ${gt_tab}]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
b0cacab0
TT
17005 POMAKEFILEDEPS="POTFILES.in"
17006 # ALL_LINGUAS, POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES depend
a04eba3f
TT
17007 # on $ac_dir but don't depend on user-specified configuration
17008 # parameters.
17009 if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
17010 # The LINGUAS file contains the set of available languages.
b0cacab0 17011 if test -n "$OBSOLETE_ALL_LINGUAS"; then
a04eba3f
TT
17012 test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete"
17013 fi
bdcd5f22 17014 ALL_LINGUAS=`sed -e "/^#/d" -e "s/#.*//" "$ac_given_srcdir/$ac_dir/LINGUAS"`
b0cacab0
TT
17015 POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
17016 else
17017 # The set of available languages was given in configure.in.
bdcd5f22 17018 ALL_LINGUAS=$OBSOLETE_ALL_LINGUAS
a04eba3f 17019 fi
b0cacab0
TT
17020 # Compute POFILES
17021 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po)
17022 # Compute UPDATEPOFILES
17023 # as $(foreach lang, $(ALL_LINGUAS), $(lang).po-update)
17024 # Compute DUMMYPOFILES
17025 # as $(foreach lang, $(ALL_LINGUAS), $(lang).nop)
17026 # Compute GMOFILES
17027 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo)
a04eba3f
TT
17028 case "$ac_given_srcdir" in
17029 .) srcdirpre= ;;
17030 *) srcdirpre='$(srcdir)/' ;;
17031 esac
17032 POFILES=
a04eba3f
TT
17033 UPDATEPOFILES=
17034 DUMMYPOFILES=
b0cacab0 17035 GMOFILES=
a04eba3f
TT
17036 for lang in $ALL_LINGUAS; do
17037 POFILES="$POFILES $srcdirpre$lang.po"
a04eba3f
TT
17038 UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
17039 DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
b0cacab0 17040 GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
a04eba3f
TT
17041 done
17042 # CATALOGS depends on both $ac_dir and the user's LINGUAS
17043 # environment variable.
17044 INST_LINGUAS=
17045 if test -n "$ALL_LINGUAS"; then
17046 for presentlang in $ALL_LINGUAS; do
17047 useit=no
17048 if test "%UNSET%" != "$LINGUAS"; then
17049 desiredlanguages="$LINGUAS"
17050 else
17051 desiredlanguages="$ALL_LINGUAS"
17052 fi
17053 for desiredlang in $desiredlanguages; do
17054 # Use the presentlang catalog if desiredlang is
17055 # a. equal to presentlang, or
17056 # b. a variant of presentlang (because in this case,
17057 # presentlang can be used as a fallback for messages
17058 # which are not translated in the desiredlang catalog).
17059 case "$desiredlang" in
5598a968
EB
17060 "$presentlang" | "$presentlang"_* | "$presentlang".* | "$presentlang"@*)
17061 useit=yes
17062 ;;
a04eba3f
TT
17063 esac
17064 done
17065 if test $useit = yes; then
17066 INST_LINGUAS="$INST_LINGUAS $presentlang"
17067 fi
17068 done
17069 fi
17070 CATALOGS=
17071 if test -n "$INST_LINGUAS"; then
17072 for lang in $INST_LINGUAS; do
17073 CATALOGS="$CATALOGS $lang.gmo"
17074 done
17075 fi
17076 test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
b0cacab0 17077 sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
a04eba3f
TT
17078 for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
17079 if test -f "$f"; then
17080 case "$f" in
17081 *.orig | *.bak | *~) ;;
17082 *) cat "$f" >> "$ac_dir/Makefile" ;;
17083 esac
17084 fi
17085 done
17086 fi
17087 ;;
a64c9c13 17088 esac
b0cacab0 17089 done ;;
e1052144 17090
b0cacab0 17091 esac
e1052144 17092done # for ac_tag
07a0db15 17093
b0cacab0 17094
57aa50d4 17095as_fn_exit 0
b0cacab0 17096_ACEOF
b0cacab0
TT
17097ac_clean_files=$ac_clean_files_save
17098
39fd3d4f 17099test $ac_write_fail = 0 ||
d6a4bcb5 17100 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
39fd3d4f 17101
b0cacab0
TT
17102
17103# configure is writing to config.log, and then calls config.status.
17104# config.status does its own redirection, appending to config.log.
17105# Unfortunately, on DOS this fails, as config.log is still kept open
17106# by configure, so config.status won't be able to write to it; its
17107# output is simply discarded. So we exec the FD to /dev/null,
17108# effectively closing config.log, so it can be properly (re)opened and
17109# appended to by config.status. When coming back to configure, we
17110# need to make the FD available again.
17111if test "$no_create" != yes; then
17112 ac_cs_success=:
17113 ac_config_status_args=
17114 test "$silent" = yes &&
17115 ac_config_status_args="$ac_config_status_args --quiet"
17116 exec 5>/dev/null
17117 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
17118 exec 5>>config.log
17119 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
17120 # would make configure fail if this is the last instruction.
d6a4bcb5 17121 $ac_cs_success || as_fn_exit 1
b0cacab0 17122fi
39fd3d4f 17123if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
54445dc2
TT
17124 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
17125printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
39fd3d4f 17126fi
50e1e10f 17127
ee683a13 17128if test -f util/gen-tarball; then chmod +x util/gen-tarball; fi
54445dc2 17129