]> git.saurik.com Git - apple/icu.git/blame - icuSources/configure
ICU-64243.0.1.tar.gz
[apple/icu.git] / icuSources / configure
CommitLineData
b75a7d8f 1#! /bin/sh
b75a7d8f 2# Guess values for system-dependent variables and create Makefiles.
3d1f044b 3# Generated by GNU Autoconf 2.69 for ICU 64.2.
729e4ab9 4#
b331163b 5# Report bugs to <http://icu-project.org/bugs>.
729e4ab9 6#
f3c0d7a5 7# Copyright (C) 2016 and later: Unicode, Inc. and others. License & terms of use: http://www.unicode.org/copyright.html
729e4ab9 8#
b331163b
A
9#
10# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
729e4ab9 11#
b75a7d8f
A
12#
13# This configure script is free software; the Free Software Foundation
14# gives unlimited permission to copy, distribute and modify it.
729e4ab9
A
15## -------------------- ##
16## M4sh Initialization. ##
17## -------------------- ##
73c04bcf 18
729e4ab9
A
19# Be more Bourne compatible
20DUALCASE=1; export DUALCASE # for MKS sh
21if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
73c04bcf
A
22 emulate sh
23 NULLCMD=:
729e4ab9 24 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
73c04bcf
A
25 # is contrary to our usage. Disable this feature.
26 alias -g '${1+"$@"}'='"$@"'
729e4ab9
A
27 setopt NO_GLOB_SUBST
28else
29 case `(set -o) 2>/dev/null` in #(
30 *posix*) :
31 set -o posix ;; #(
32 *) :
33 ;;
34esac
73c04bcf 35fi
73c04bcf 36
729e4ab9
A
37
38as_nl='
39'
40export as_nl
41# Printing a long string crashes Solaris 7 /usr/bin/printf.
42as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
43as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
44as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
45# Prefer a ksh shell builtin over an external printf program on Solaris,
46# but without wasting forks for bash or zsh.
47if test -z "$BASH_VERSION$ZSH_VERSION" \
48 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
49 as_echo='print -r --'
50 as_echo_n='print -rn --'
51elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
52 as_echo='printf %s\n'
53 as_echo_n='printf %s'
54else
55 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
56 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
57 as_echo_n='/usr/ucb/echo -n'
58 else
59 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
60 as_echo_n_body='eval
61 arg=$1;
62 case $arg in #(
63 *"$as_nl"*)
64 expr "X$arg" : "X\\(.*\\)$as_nl";
65 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
66 esac;
67 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
68 '
69 export as_echo_n_body
70 as_echo_n='sh -c $as_echo_n_body as_echo'
71 fi
72 export as_echo_body
73 as_echo='sh -c $as_echo_body as_echo'
74fi
75
76# The user is always right.
77if test "${PATH_SEPARATOR+set}" != set; then
78 PATH_SEPARATOR=:
79 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
80 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
81 PATH_SEPARATOR=';'
82 }
73c04bcf
A
83fi
84
85
729e4ab9
A
86# IFS
87# We need space, tab and new line, in precisely that order. Quoting is
88# there to prevent editors from complaining about space-tab.
89# (If _AS_PATH_WALK were called with IFS unset, it would disable word
90# splitting by setting IFS to empty value.)
91IFS=" "" $as_nl"
92
93# Find who we are. Look in the path if we contain no directory separator.
4388f060 94as_myself=
729e4ab9
A
95case $0 in #((
96 *[\\/]* ) as_myself=$0 ;;
97 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
98for as_dir in $PATH
99do
100 IFS=$as_save_IFS
101 test -z "$as_dir" && as_dir=.
102 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
103 done
104IFS=$as_save_IFS
105
106 ;;
107esac
108# We did not find ourselves, most probably we were run as `sh COMMAND'
109# in which case we are not to be found in the path.
110if test "x$as_myself" = x; then
111 as_myself=$0
112fi
113if test ! -f "$as_myself"; then
114 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
115 exit 1
116fi
117
118# Unset variables that we do not need and which cause bugs (e.g. in
119# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
120# suppresses any "Segmentation fault" message there. '((' could
121# trigger a bug in pdksh 5.2.14.
122for as_var in BASH_ENV ENV MAIL MAILPATH
123do eval test x\${$as_var+set} = xset \
124 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
125done
73c04bcf
A
126PS1='$ '
127PS2='> '
128PS4='+ '
129
130# NLS nuisances.
729e4ab9
A
131LC_ALL=C
132export LC_ALL
133LANGUAGE=C
134export LANGUAGE
135
136# CDPATH.
137(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
138
b331163b
A
139# Use a proper internal environment variable to ensure we don't fall
140 # into an infinite loop, continuously re-executing ourselves.
141 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
142 _as_can_reexec=no; export _as_can_reexec;
143 # We cannot yet assume a decent shell, so we have to provide a
144# neutralization value for shells without unset; and this also
145# works around shells that cannot unset nonexistent variables.
146# Preserve -v and -x to the replacement shell.
147BASH_ENV=/dev/null
148ENV=/dev/null
149(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
150case $- in # ((((
151 *v*x* | *x*v* ) as_opts=-vx ;;
152 *v* ) as_opts=-v ;;
153 *x* ) as_opts=-x ;;
154 * ) as_opts= ;;
155esac
156exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
157# Admittedly, this is quite paranoid, since all the known shells bail
158# out after a failed `exec'.
159$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
160as_fn_exit 255
161 fi
162 # We don't want this to propagate to other subprocesses.
163 { _as_can_reexec=; unset _as_can_reexec;}
729e4ab9
A
164if test "x$CONFIG_SHELL" = x; then
165 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
166 emulate sh
167 NULLCMD=:
168 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
169 # is contrary to our usage. Disable this feature.
170 alias -g '\${1+\"\$@\"}'='\"\$@\"'
171 setopt NO_GLOB_SUBST
172else
173 case \`(set -o) 2>/dev/null\` in #(
174 *posix*) :
175 set -o posix ;; #(
176 *) :
177 ;;
178esac
179fi
180"
181 as_required="as_fn_return () { (exit \$1); }
182as_fn_success () { as_fn_return 0; }
183as_fn_failure () { as_fn_return 1; }
184as_fn_ret_success () { return 0; }
185as_fn_ret_failure () { return 1; }
186
187exitcode=0
188as_fn_success || { exitcode=1; echo as_fn_success failed.; }
189as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
190as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
191as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
192if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
193
194else
195 exitcode=1; echo positional parameters were not saved.
196fi
b331163b
A
197test x\$exitcode = x0 || exit 1
198test -x / || exit 1"
729e4ab9
A
199 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
200 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
201 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
202 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
203test \$(( 1 + 1 )) = 2 || exit 1"
204 if (eval "$as_required") 2>/dev/null; then :
205 as_have_required=yes
206else
207 as_have_required=no
208fi
209 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
210
211else
212 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
213as_found=false
214for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
73c04bcf 215do
729e4ab9
A
216 IFS=$as_save_IFS
217 test -z "$as_dir" && as_dir=.
218 as_found=:
219 case $as_dir in #(
220 /*)
221 for as_base in sh bash ksh sh5; do
222 # Try only shells that exist, to save several forks.
223 as_shell=$as_dir/$as_base
224 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
225 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
226 CONFIG_SHELL=$as_shell as_have_required=yes
227 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
228 break 2
229fi
230fi
231 done;;
232 esac
233 as_found=false
234done
235$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
236 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
237 CONFIG_SHELL=$SHELL as_have_required=yes
238fi; }
239IFS=$as_save_IFS
240
241
242 if test "x$CONFIG_SHELL" != x; then :
b331163b
A
243 export CONFIG_SHELL
244 # We cannot yet assume a decent shell, so we have to provide a
245# neutralization value for shells without unset; and this also
246# works around shells that cannot unset nonexistent variables.
247# Preserve -v and -x to the replacement shell.
248BASH_ENV=/dev/null
249ENV=/dev/null
250(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
251case $- in # ((((
252 *v*x* | *x*v* ) as_opts=-vx ;;
253 *v* ) as_opts=-v ;;
254 *x* ) as_opts=-x ;;
255 * ) as_opts= ;;
256esac
257exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
258# Admittedly, this is quite paranoid, since all the known shells bail
259# out after a failed `exec'.
260$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
261exit 255
729e4ab9
A
262fi
263
264 if test x$as_have_required = xno; then :
265 $as_echo "$0: This script requires a shell more modern than all"
266 $as_echo "$0: the shells that I found on your system."
267 if test x${ZSH_VERSION+set} = xset ; then
268 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
269 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
73c04bcf 270 else
b331163b
A
271 $as_echo "$0: Please tell bug-autoconf@gnu.org and
272$0: http://icu-project.org/bugs about your system,
729e4ab9
A
273$0: including any error possibly output before this
274$0: message. Then install a modern shell, or manually run
275$0: the script under such a shell if you do have one."
73c04bcf 276 fi
729e4ab9
A
277 exit 1
278fi
279fi
280fi
281SHELL=${CONFIG_SHELL-/bin/sh}
282export SHELL
283# Unset more variables known to interfere with behavior of common tools.
284CLICOLOR_FORCE= GREP_OPTIONS=
285unset CLICOLOR_FORCE GREP_OPTIONS
286
287## --------------------- ##
288## M4sh Shell Functions. ##
289## --------------------- ##
290# as_fn_unset VAR
291# ---------------
292# Portably unset VAR.
293as_fn_unset ()
294{
295 { eval $1=; unset $1;}
296}
297as_unset=as_fn_unset
298
299# as_fn_set_status STATUS
300# -----------------------
301# Set $? to STATUS, without forking.
302as_fn_set_status ()
303{
304 return $1
305} # as_fn_set_status
306
307# as_fn_exit STATUS
308# -----------------
309# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
310as_fn_exit ()
311{
312 set +e
313 as_fn_set_status $1
314 exit $1
315} # as_fn_exit
316
317# as_fn_mkdir_p
318# -------------
319# Create "$as_dir" as a directory, including parents if necessary.
320as_fn_mkdir_p ()
321{
322
323 case $as_dir in #(
324 -*) as_dir=./$as_dir;;
325 esac
326 test -d "$as_dir" || eval $as_mkdir_p || {
327 as_dirs=
328 while :; do
329 case $as_dir in #(
330 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
331 *) as_qdir=$as_dir;;
332 esac
333 as_dirs="'$as_qdir' $as_dirs"
334 as_dir=`$as_dirname -- "$as_dir" ||
335$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
336 X"$as_dir" : 'X\(//\)[^/]' \| \
337 X"$as_dir" : 'X\(//\)$' \| \
338 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
339$as_echo X"$as_dir" |
340 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
341 s//\1/
342 q
343 }
344 /^X\(\/\/\)[^/].*/{
345 s//\1/
346 q
347 }
348 /^X\(\/\/\)$/{
349 s//\1/
350 q
351 }
352 /^X\(\/\).*/{
353 s//\1/
354 q
355 }
356 s/.*/./; q'`
357 test -d "$as_dir" && break
358 done
359 test -z "$as_dirs" || eval "mkdir $as_dirs"
360 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
361
362
363} # as_fn_mkdir_p
b331163b
A
364
365# as_fn_executable_p FILE
366# -----------------------
367# Test if FILE is an executable regular file.
368as_fn_executable_p ()
369{
370 test -f "$1" && test -x "$1"
371} # as_fn_executable_p
729e4ab9
A
372# as_fn_append VAR VALUE
373# ----------------------
374# Append the text in VALUE to the end of the definition contained in VAR. Take
375# advantage of any shell optimizations that allow amortized linear growth over
376# repeated appends, instead of the typical quadratic growth present in naive
377# implementations.
378if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
379 eval 'as_fn_append ()
380 {
381 eval $1+=\$2
382 }'
383else
384 as_fn_append ()
385 {
386 eval $1=\$$1\$2
387 }
388fi # as_fn_append
389
390# as_fn_arith ARG...
391# ------------------
392# Perform arithmetic evaluation on the ARGs, and store the result in the
393# global $as_val. Take advantage of shells that can avoid forks. The arguments
394# must be portable across $(()) and expr.
395if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
396 eval 'as_fn_arith ()
397 {
398 as_val=$(( $* ))
399 }'
400else
401 as_fn_arith ()
402 {
403 as_val=`expr "$@" || test $? -eq 1`
404 }
405fi # as_fn_arith
406
407
408# as_fn_error STATUS ERROR [LINENO LOG_FD]
409# ----------------------------------------
410# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
411# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
412# script with STATUS, using 1 if that was 0.
413as_fn_error ()
414{
415 as_status=$1; test $as_status -eq 0 && as_status=1
416 if test "$4"; then
417 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
418 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
419 fi
420 $as_echo "$as_me: error: $2" >&2
421 as_fn_exit $as_status
422} # as_fn_error
73c04bcf 423
729e4ab9
A
424if expr a : '\(a\)' >/dev/null 2>&1 &&
425 test "X`expr 00001 : '.*\(...\)'`" = X001; then
73c04bcf
A
426 as_expr=expr
427else
428 as_expr=false
429fi
430
729e4ab9 431if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
73c04bcf
A
432 as_basename=basename
433else
434 as_basename=false
435fi
436
729e4ab9
A
437if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
438 as_dirname=dirname
439else
440 as_dirname=false
441fi
73c04bcf 442
729e4ab9 443as_me=`$as_basename -- "$0" ||
73c04bcf
A
444$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
445 X"$0" : 'X\(//\)$' \| \
729e4ab9
A
446 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
447$as_echo X/"$0" |
448 sed '/^.*\/\([^/][^/]*\)\/*$/{
449 s//\1/
450 q
451 }
452 /^X\/\(\/\/\)$/{
453 s//\1/
454 q
455 }
456 /^X\/\(\/\).*/{
457 s//\1/
458 q
459 }
460 s/.*/./; q'`
73c04bcf 461
73c04bcf
A
462# Avoid depending upon Character Ranges.
463as_cr_letters='abcdefghijklmnopqrstuvwxyz'
464as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
465as_cr_Letters=$as_cr_letters$as_cr_LETTERS
466as_cr_digits='0123456789'
467as_cr_alnum=$as_cr_Letters$as_cr_digits
468
73c04bcf 469
729e4ab9
A
470 as_lineno_1=$LINENO as_lineno_1a=$LINENO
471 as_lineno_2=$LINENO as_lineno_2a=$LINENO
472 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
473 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
474 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
475 sed -n '
476 p
477 /[$]LINENO/=
478 ' <$as_myself |
73c04bcf 479 sed '
729e4ab9
A
480 s/[$]LINENO.*/&-/
481 t lineno
482 b
483 :lineno
73c04bcf 484 N
729e4ab9
A
485 :loop
486 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
73c04bcf 487 t loop
729e4ab9 488 s/-\n.*//
73c04bcf 489 ' >$as_me.lineno &&
729e4ab9
A
490 chmod +x "$as_me.lineno" ||
491 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
73c04bcf 492
b331163b
A
493 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
494 # already done that, so ensure we don't try to do so again and fall
495 # in an infinite loop. This has already happened in practice.
496 _as_can_reexec=no; export _as_can_reexec
73c04bcf
A
497 # Don't try to exec as it changes $[0], causing all sort of problems
498 # (the dirname of $[0] is not the place where we might find the
729e4ab9
A
499 # original and so on. Autoconf is especially sensitive to this).
500 . "./$as_me.lineno"
73c04bcf
A
501 # Exit status is that of the last command.
502 exit
503}
504
729e4ab9
A
505ECHO_C= ECHO_N= ECHO_T=
506case `echo -n x` in #(((((
507-n*)
508 case `echo 'xy\c'` in
509 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
510 xy) ECHO_C='\c';;
511 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
512 ECHO_T=' ';;
513 esac;;
514*)
515 ECHO_N='-n';;
73c04bcf
A
516esac
517
729e4ab9
A
518rm -f conf$$ conf$$.exe conf$$.file
519if test -d conf$$.dir; then
520 rm -f conf$$.dir/conf$$.file
73c04bcf 521else
729e4ab9
A
522 rm -f conf$$.dir
523 mkdir conf$$.dir 2>/dev/null
73c04bcf 524fi
729e4ab9
A
525if (echo >conf$$.file) 2>/dev/null; then
526 if ln -s conf$$.file conf$$ 2>/dev/null; then
73c04bcf 527 as_ln_s='ln -s'
729e4ab9
A
528 # ... but there are two gotchas:
529 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
530 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
b331163b 531 # In both cases, we have to default to `cp -pR'.
729e4ab9 532 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
b331163b 533 as_ln_s='cp -pR'
729e4ab9
A
534 elif ln conf$$.file conf$$ 2>/dev/null; then
535 as_ln_s=ln
536 else
b331163b 537 as_ln_s='cp -pR'
73c04bcf 538 fi
73c04bcf 539else
b331163b 540 as_ln_s='cp -pR'
73c04bcf 541fi
729e4ab9
A
542rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
543rmdir conf$$.dir 2>/dev/null
73c04bcf
A
544
545if mkdir -p . 2>/dev/null; then
729e4ab9 546 as_mkdir_p='mkdir -p "$as_dir"'
73c04bcf
A
547else
548 test -d ./-p && rmdir ./-p
549 as_mkdir_p=false
550fi
551
b331163b
A
552as_test_x='test -x'
553as_executable_p=as_fn_executable_p
73c04bcf
A
554
555# Sed expression to map a string onto a valid CPP name.
556as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
557
558# Sed expression to map a string onto a valid variable name.
559as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
560
561
729e4ab9
A
562test -n "$DJDIR" || exec 7<&0 </dev/null
563exec 6>&1
73c04bcf
A
564
565# Name of the host.
729e4ab9 566# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
73c04bcf
A
567# so uname gets run too.
568ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
b75a7d8f 569
73c04bcf
A
570#
571# Initializations.
572#
b75a7d8f 573ac_default_prefix=/usr/local
729e4ab9 574ac_clean_files=
73c04bcf 575ac_config_libobj_dir=.
729e4ab9 576LIBOBJS=
73c04bcf
A
577cross_compiling=no
578subdirs=
579MFLAGS=
580MAKEFLAGS=
73c04bcf
A
581
582# Identity of this package.
b331163b
A
583PACKAGE_NAME='ICU'
584PACKAGE_TARNAME='International Components for Unicode'
3d1f044b
A
585PACKAGE_VERSION='64.2'
586PACKAGE_STRING='ICU 64.2'
b331163b
A
587PACKAGE_BUGREPORT='http://icu-project.org/bugs'
588PACKAGE_URL='http://icu-project.org'
589
73c04bcf
A
590ac_unique_file="common/unicode/utypes.h"
591# Factoring default headers for most tests.
592ac_includes_default="\
593#include <stdio.h>
729e4ab9 594#ifdef HAVE_SYS_TYPES_H
73c04bcf
A
595# include <sys/types.h>
596#endif
729e4ab9 597#ifdef HAVE_SYS_STAT_H
73c04bcf
A
598# include <sys/stat.h>
599#endif
729e4ab9 600#ifdef STDC_HEADERS
73c04bcf
A
601# include <stdlib.h>
602# include <stddef.h>
603#else
729e4ab9 604# ifdef HAVE_STDLIB_H
73c04bcf
A
605# include <stdlib.h>
606# endif
607#endif
729e4ab9
A
608#ifdef HAVE_STRING_H
609# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
73c04bcf
A
610# include <memory.h>
611# endif
612# include <string.h>
613#endif
729e4ab9 614#ifdef HAVE_STRINGS_H
73c04bcf
A
615# include <strings.h>
616#endif
729e4ab9 617#ifdef HAVE_INTTYPES_H
73c04bcf 618# include <inttypes.h>
73c04bcf 619#endif
729e4ab9
A
620#ifdef HAVE_STDINT_H
621# include <stdint.h>
622#endif
623#ifdef HAVE_UNISTD_H
73c04bcf
A
624# include <unistd.h>
625#endif"
626
57a6839d
A
627ac_subst_vars='UCONFIG_CXXFLAGS
628UCONFIG_CFLAGS
629UCONFIG_CPPFLAGS
630LTLIBOBJS
729e4ab9 631LIBOBJS
4388f060
A
632LIBCXXFLAGS
633LIBCFLAGS
729e4ab9
A
634platform_make_fragment
635platform_make_fragment_name
636platform
637ICUDATA_CHAR
2ca993e8 638U_HAVE_SAMPLES
729e4ab9 639SAMPLES_TRUE
2ca993e8 640U_HAVE_TESTS
729e4ab9
A
641TESTS_TRUE
642ICULIBSUFFIXCNAME
643U_HAVE_LIB_SUFFIX
644ICULIBSUFFIX
645DATA_PACKAGING_MODE
646thepkgicudatadir
647pkgicudatadir
2ca993e8 648U_HAVE_TOOLS
57a6839d 649TOOLS_TRUE
2ca993e8 650U_HAVE_LAYOUTEX
b331163b 651LAYOUTEX_TRUE
2ca993e8 652U_HAVE_ICUIO
729e4ab9 653ICUIO_TRUE
2ca993e8 654U_HAVE_EXTRAS
729e4ab9 655EXTRAS_TRUE
729e4ab9
A
656U_HAVE_WCSCPY
657U_HAVE_WCHAR_H
f3c0d7a5 658U_HAVE_STRTOD_L
729e4ab9
A
659U_TIMEZONE
660U_HAVE_TIMEZONE
661U_TZNAME
662U_HAVE_TZNAME
663U_TZSET
664U_HAVE_TZSET
665U_HAVE_POPEN
729e4ab9
A
666U_HAVE_PLACEMENT_NEW
667U_OVERRIDE_CXX_ALLOCATION
729e4ab9
A
668U_NL_LANGINFO_CODESET
669U_HAVE_NL_LANGINFO_CODESET
670U_IS_BIG_ENDIAN
729e4ab9
A
671U_HAVE_DIRENT_H
672U_HAVE_INTTYPES_H
673GENCCODE_ASSEMBLY
674HAVE_MMAP
675LIB_THREAD
729e4ab9 676ENABLE_RPATH
729e4ab9 677U_ENABLE_DYLOAD
2ca993e8
A
678U_HAVE_PLUGINS
679PLUGINS_TRUE
729e4ab9
A
680U_ENABLE_TRACING
681U_DISABLE_RENAMING
682AR
f3c0d7a5 683SED
729e4ab9 684RANLIB
729e4ab9
A
685U_DEFAULT_SHOW_DRAFT
686UCLN_NO_AUTO_CLEANUP
687ENABLE_STATIC
688ENABLE_SHARED
689LIB_M
690COMPILE_LINK_ENVVAR
691ARFLAGS
692EGREP
693GREP
694DOXYGEN
695cross_buildroot
696U_MAKE
3d1f044b 697PYTHON
729e4ab9
A
698cross_compiling
699INSTALL_DATA
700INSTALL_SCRIPT
701INSTALL_PROGRAM
702CPP
b331163b
A
703ICULEHB_LIBS
704ICULEHB_CFLAGS
2ca993e8
A
705PKG_CONFIG_LIBDIR
706PKG_CONFIG_PATH
b331163b 707PKG_CONFIG
729e4ab9
A
708ac_ct_CXX
709CXXFLAGS
710CXX
711OBJEXT
712EXEEXT
713ac_ct_CC
714LDFLAGS
715CFLAGS
716CC
717ENABLE_RELEASE
718ENABLE_DEBUG
3d1f044b 719INSTALL_ICU_CONFIG
729e4ab9 720CPPFLAGS
729e4ab9
A
721host_os
722host_vendor
723host_cpu
724host
725build_os
726build_vendor
727build_cpu
728build
729UNICODE_VERSION
730LIB_VERSION_MAJOR
731LIB_VERSION
732VERSION
733ICU_ECHO_T
734ICU_ECHO_C
735ICU_ECHO_N
736PACKAGE
737target_alias
738host_alias
739build_alias
740LIBS
741ECHO_T
742ECHO_N
743ECHO_C
744DEFS
745mandir
746localedir
747libdir
748psdir
749pdfdir
750dvidir
751htmldir
752infodir
753docdir
754oldincludedir
755includedir
756localstatedir
757sharedstatedir
758sysconfdir
759datadir
760datarootdir
761libexecdir
762sbindir
763bindir
764program_transform_name
765prefix
766exec_prefix
767PACKAGE_URL
768PACKAGE_BUGREPORT
769PACKAGE_STRING
770PACKAGE_VERSION
771PACKAGE_TARNAME
772PACKAGE_NAME
773PATH_SEPARATOR
774SHELL'
73c04bcf 775ac_subst_files=''
729e4ab9
A
776ac_user_opts='
777enable_option_checking
3d1f044b 778enable_icu_config
729e4ab9
A
779enable_debug
780enable_release
781with_cross_build
782enable_strict
783enable_64bit_libs
784with_library_bits
785enable_shared
786enable_static
787enable_auto_cleanup
788enable_draft
789enable_renaming
790enable_tracing
2ca993e8 791enable_plugins
729e4ab9
A
792enable_dyload
793enable_rpath
729e4ab9 794enable_weak_threads
729e4ab9
A
795enable_extras
796enable_icuio
b331163b 797enable_layoutex
f3c0d7a5 798enable_layout
57a6839d 799enable_tools
729e4ab9
A
800with_data_packaging
801with_library_suffix
802enable_tests
803enable_samples
804'
805 ac_precious_vars='build_alias
806host_alias
807target_alias
808CC
809CFLAGS
810LDFLAGS
811LIBS
812CPPFLAGS
813CXX
814CXXFLAGS
815CCC
b331163b 816PKG_CONFIG
2ca993e8
A
817PKG_CONFIG_PATH
818PKG_CONFIG_LIBDIR
b331163b
A
819ICULEHB_CFLAGS
820ICULEHB_LIBS
729e4ab9
A
821CPP'
822
b75a7d8f
A
823
824# Initialize some variables set by options.
73c04bcf
A
825ac_init_help=
826ac_init_version=false
729e4ab9
A
827ac_unrecognized_opts=
828ac_unrecognized_sep=
b75a7d8f
A
829# The variables have the same names as the options, with
830# dashes changed to underlines.
73c04bcf 831cache_file=/dev/null
b75a7d8f 832exec_prefix=NONE
b75a7d8f 833no_create=
b75a7d8f
A
834no_recursion=
835prefix=NONE
836program_prefix=NONE
837program_suffix=NONE
838program_transform_name=s,x,x,
839silent=
840site=
841srcdir=
b75a7d8f
A
842verbose=
843x_includes=NONE
844x_libraries=NONE
73c04bcf
A
845
846# Installation directory options.
847# These are left unexpanded so users can "make install exec_prefix=/foo"
848# and all the variables that are supposed to be based on exec_prefix
849# by default will actually change.
850# Use braces instead of parens because sh, perl, etc. also accept them.
729e4ab9 851# (The list follows the same order as the GNU Coding Standards.)
b75a7d8f
A
852bindir='${exec_prefix}/bin'
853sbindir='${exec_prefix}/sbin'
854libexecdir='${exec_prefix}/libexec'
46f4442e
A
855datarootdir='${prefix}/share'
856datadir='${datarootdir}'
b75a7d8f
A
857sysconfdir='${prefix}/etc'
858sharedstatedir='${prefix}/com'
859localstatedir='${prefix}/var'
b75a7d8f
A
860includedir='${prefix}/include'
861oldincludedir='/usr/include'
b331163b 862docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
729e4ab9
A
863infodir='${datarootdir}/info'
864htmldir='${docdir}'
865dvidir='${docdir}'
866pdfdir='${docdir}'
867psdir='${docdir}'
868libdir='${exec_prefix}/lib'
869localedir='${datarootdir}/locale'
870mandir='${datarootdir}/man'
b75a7d8f 871
b75a7d8f 872ac_prev=
729e4ab9 873ac_dashdash=
b75a7d8f
A
874for ac_option
875do
b75a7d8f
A
876 # If the previous option needs an argument, assign it.
877 if test -n "$ac_prev"; then
729e4ab9 878 eval $ac_prev=\$ac_option
b75a7d8f
A
879 ac_prev=
880 continue
881 fi
882
729e4ab9
A
883 case $ac_option in
884 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
885 *=) ac_optarg= ;;
886 *) ac_optarg=yes ;;
887 esac
b75a7d8f
A
888
889 # Accept the important Cygnus configure options, so we can diagnose typos.
890
729e4ab9
A
891 case $ac_dashdash$ac_option in
892 --)
893 ac_dashdash=yes ;;
b75a7d8f
A
894
895 -bindir | --bindir | --bindi | --bind | --bin | --bi)
896 ac_prev=bindir ;;
897 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
73c04bcf 898 bindir=$ac_optarg ;;
b75a7d8f
A
899
900 -build | --build | --buil | --bui | --bu)
73c04bcf 901 ac_prev=build_alias ;;
b75a7d8f 902 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
73c04bcf 903 build_alias=$ac_optarg ;;
b75a7d8f
A
904
905 -cache-file | --cache-file | --cache-fil | --cache-fi \
906 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
907 ac_prev=cache_file ;;
908 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
909 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
73c04bcf
A
910 cache_file=$ac_optarg ;;
911
912 --config-cache | -C)
913 cache_file=config.cache ;;
729e4ab9
A
914
915 -datadir | --datadir | --datadi | --datad)
916 ac_prev=datadir ;;
917 -datadir=* | --datadir=* | --datadi=* | --datad=*)
918 datadir=$ac_optarg ;;
919
46f4442e
A
920 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
921 | --dataroo | --dataro | --datar)
922 ac_prev=datarootdir ;;
729e4ab9 923 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
46f4442e
A
924 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
925 datarootdir=$ac_optarg ;;
729e4ab9 926
b75a7d8f 927 -disable-* | --disable-*)
729e4ab9 928 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
b75a7d8f 929 # Reject names that are not valid shell variable names.
729e4ab9
A
930 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
931 as_fn_error $? "invalid feature name: $ac_useropt"
932 ac_useropt_orig=$ac_useropt
933 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
934 case $ac_user_opts in
935 *"
936"enable_$ac_useropt"
937"*) ;;
938 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
939 ac_unrecognized_sep=', ';;
940 esac
941 eval enable_$ac_useropt=no ;;
942
943 -docdir | --docdir | --docdi | --doc | --do)
944 ac_prev=docdir ;;
945 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
946 docdir=$ac_optarg ;;
947
948 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
949 ac_prev=dvidir ;;
950 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
951 dvidir=$ac_optarg ;;
b75a7d8f
A
952
953 -enable-* | --enable-*)
729e4ab9 954 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
b75a7d8f 955 # Reject names that are not valid shell variable names.
729e4ab9
A
956 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
957 as_fn_error $? "invalid feature name: $ac_useropt"
958 ac_useropt_orig=$ac_useropt
959 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
960 case $ac_user_opts in
961 *"
962"enable_$ac_useropt"
963"*) ;;
964 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
965 ac_unrecognized_sep=', ';;
b75a7d8f 966 esac
729e4ab9 967 eval enable_$ac_useropt=\$ac_optarg ;;
b75a7d8f
A
968
969 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
970 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
971 | --exec | --exe | --ex)
972 ac_prev=exec_prefix ;;
973 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
974 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
975 | --exec=* | --exe=* | --ex=*)
73c04bcf 976 exec_prefix=$ac_optarg ;;
b75a7d8f
A
977
978 -gas | --gas | --ga | --g)
979 # Obsolete; use --with-gas.
980 with_gas=yes ;;
981
73c04bcf
A
982 -help | --help | --hel | --he | -h)
983 ac_init_help=long ;;
984 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
985 ac_init_help=recursive ;;
986 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
987 ac_init_help=short ;;
b75a7d8f
A
988
989 -host | --host | --hos | --ho)
73c04bcf 990 ac_prev=host_alias ;;
b75a7d8f 991 -host=* | --host=* | --hos=* | --ho=*)
73c04bcf 992 host_alias=$ac_optarg ;;
b75a7d8f 993
729e4ab9
A
994 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
995 ac_prev=htmldir ;;
996 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
997 | --ht=*)
998 htmldir=$ac_optarg ;;
999
b75a7d8f
A
1000 -includedir | --includedir | --includedi | --included | --include \
1001 | --includ | --inclu | --incl | --inc)
1002 ac_prev=includedir ;;
1003 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1004 | --includ=* | --inclu=* | --incl=* | --inc=*)
73c04bcf 1005 includedir=$ac_optarg ;;
b75a7d8f
A
1006
1007 -infodir | --infodir | --infodi | --infod | --info | --inf)
1008 ac_prev=infodir ;;
1009 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
73c04bcf 1010 infodir=$ac_optarg ;;
b75a7d8f
A
1011
1012 -libdir | --libdir | --libdi | --libd)
1013 ac_prev=libdir ;;
1014 -libdir=* | --libdir=* | --libdi=* | --libd=*)
73c04bcf 1015 libdir=$ac_optarg ;;
b75a7d8f
A
1016
1017 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1018 | --libexe | --libex | --libe)
1019 ac_prev=libexecdir ;;
1020 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1021 | --libexe=* | --libex=* | --libe=*)
73c04bcf 1022 libexecdir=$ac_optarg ;;
b75a7d8f 1023
729e4ab9
A
1024 -localedir | --localedir | --localedi | --localed | --locale)
1025 ac_prev=localedir ;;
1026 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1027 localedir=$ac_optarg ;;
1028
b75a7d8f 1029 -localstatedir | --localstatedir | --localstatedi | --localstated \
729e4ab9 1030 | --localstate | --localstat | --localsta | --localst | --locals)
b75a7d8f
A
1031 ac_prev=localstatedir ;;
1032 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
729e4ab9 1033 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
73c04bcf 1034 localstatedir=$ac_optarg ;;
b75a7d8f
A
1035
1036 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1037 ac_prev=mandir ;;
1038 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
73c04bcf 1039 mandir=$ac_optarg ;;
b75a7d8f
A
1040
1041 -nfp | --nfp | --nf)
1042 # Obsolete; use --without-fp.
1043 with_fp=no ;;
1044
1045 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
73c04bcf 1046 | --no-cr | --no-c | -n)
b75a7d8f
A
1047 no_create=yes ;;
1048
1049 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1050 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1051 no_recursion=yes ;;
1052
1053 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1054 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1055 | --oldin | --oldi | --old | --ol | --o)
1056 ac_prev=oldincludedir ;;
1057 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1058 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1059 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
73c04bcf 1060 oldincludedir=$ac_optarg ;;
b75a7d8f
A
1061
1062 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1063 ac_prev=prefix ;;
1064 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
73c04bcf 1065 prefix=$ac_optarg ;;
b75a7d8f
A
1066
1067 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1068 | --program-pre | --program-pr | --program-p)
1069 ac_prev=program_prefix ;;
1070 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1071 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
73c04bcf 1072 program_prefix=$ac_optarg ;;
b75a7d8f
A
1073
1074 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1075 | --program-suf | --program-su | --program-s)
1076 ac_prev=program_suffix ;;
1077 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1078 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
73c04bcf 1079 program_suffix=$ac_optarg ;;
b75a7d8f
A
1080
1081 -program-transform-name | --program-transform-name \
1082 | --program-transform-nam | --program-transform-na \
1083 | --program-transform-n | --program-transform- \
1084 | --program-transform | --program-transfor \
1085 | --program-transfo | --program-transf \
1086 | --program-trans | --program-tran \
1087 | --progr-tra | --program-tr | --program-t)
1088 ac_prev=program_transform_name ;;
1089 -program-transform-name=* | --program-transform-name=* \
1090 | --program-transform-nam=* | --program-transform-na=* \
1091 | --program-transform-n=* | --program-transform-=* \
1092 | --program-transform=* | --program-transfor=* \
1093 | --program-transfo=* | --program-transf=* \
1094 | --program-trans=* | --program-tran=* \
1095 | --progr-tra=* | --program-tr=* | --program-t=*)
73c04bcf 1096 program_transform_name=$ac_optarg ;;
b75a7d8f 1097
729e4ab9
A
1098 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1099 ac_prev=pdfdir ;;
1100 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1101 pdfdir=$ac_optarg ;;
1102
1103 -psdir | --psdir | --psdi | --psd | --ps)
1104 ac_prev=psdir ;;
1105 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1106 psdir=$ac_optarg ;;
1107
b75a7d8f
A
1108 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1109 | -silent | --silent | --silen | --sile | --sil)
1110 silent=yes ;;
1111
1112 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1113 ac_prev=sbindir ;;
1114 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1115 | --sbi=* | --sb=*)
73c04bcf 1116 sbindir=$ac_optarg ;;
b75a7d8f
A
1117
1118 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1119 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1120 | --sharedst | --shareds | --shared | --share | --shar \
1121 | --sha | --sh)
1122 ac_prev=sharedstatedir ;;
1123 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1124 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1125 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1126 | --sha=* | --sh=*)
73c04bcf 1127 sharedstatedir=$ac_optarg ;;
b75a7d8f
A
1128
1129 -site | --site | --sit)
1130 ac_prev=site ;;
1131 -site=* | --site=* | --sit=*)
73c04bcf 1132 site=$ac_optarg ;;
b75a7d8f
A
1133
1134 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1135 ac_prev=srcdir ;;
1136 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
73c04bcf 1137 srcdir=$ac_optarg ;;
b75a7d8f
A
1138
1139 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1140 | --syscon | --sysco | --sysc | --sys | --sy)
1141 ac_prev=sysconfdir ;;
1142 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1143 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
73c04bcf 1144 sysconfdir=$ac_optarg ;;
b75a7d8f
A
1145
1146 -target | --target | --targe | --targ | --tar | --ta | --t)
73c04bcf 1147 ac_prev=target_alias ;;
b75a7d8f 1148 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
73c04bcf 1149 target_alias=$ac_optarg ;;
b75a7d8f
A
1150
1151 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1152 verbose=yes ;;
1153
73c04bcf
A
1154 -version | --version | --versio | --versi | --vers | -V)
1155 ac_init_version=: ;;
b75a7d8f
A
1156
1157 -with-* | --with-*)
729e4ab9 1158 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
b75a7d8f 1159 # Reject names that are not valid shell variable names.
729e4ab9
A
1160 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1161 as_fn_error $? "invalid package name: $ac_useropt"
1162 ac_useropt_orig=$ac_useropt
1163 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1164 case $ac_user_opts in
1165 *"
1166"with_$ac_useropt"
1167"*) ;;
1168 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1169 ac_unrecognized_sep=', ';;
b75a7d8f 1170 esac
729e4ab9 1171 eval with_$ac_useropt=\$ac_optarg ;;
b75a7d8f
A
1172
1173 -without-* | --without-*)
729e4ab9 1174 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
b75a7d8f 1175 # Reject names that are not valid shell variable names.
729e4ab9
A
1176 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1177 as_fn_error $? "invalid package name: $ac_useropt"
1178 ac_useropt_orig=$ac_useropt
1179 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1180 case $ac_user_opts in
1181 *"
1182"with_$ac_useropt"
1183"*) ;;
1184 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1185 ac_unrecognized_sep=', ';;
1186 esac
1187 eval with_$ac_useropt=no ;;
b75a7d8f
A
1188
1189 --x)
1190 # Obsolete; use --with-x.
1191 with_x=yes ;;
1192
1193 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1194 | --x-incl | --x-inc | --x-in | --x-i)
1195 ac_prev=x_includes ;;
1196 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1197 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
73c04bcf 1198 x_includes=$ac_optarg ;;
b75a7d8f
A
1199
1200 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1201 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1202 ac_prev=x_libraries ;;
1203 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1204 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
73c04bcf 1205 x_libraries=$ac_optarg ;;
b75a7d8f 1206
729e4ab9
A
1207 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1208Try \`$0 --help' for more information"
b75a7d8f
A
1209 ;;
1210
73c04bcf
A
1211 *=*)
1212 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1213 # Reject names that are not valid shell variable names.
729e4ab9
A
1214 case $ac_envvar in #(
1215 '' | [0-9]* | *[!_$as_cr_alnum]* )
1216 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1217 esac
1218 eval $ac_envvar=\$ac_optarg
73c04bcf
A
1219 export $ac_envvar ;;
1220
b75a7d8f 1221 *)
73c04bcf 1222 # FIXME: should be removed in autoconf 3.0.
729e4ab9 1223 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
73c04bcf 1224 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
729e4ab9 1225 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
4388f060 1226 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
b75a7d8f
A
1227 ;;
1228
1229 esac
1230done
1231
1232if test -n "$ac_prev"; then
73c04bcf 1233 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
729e4ab9 1234 as_fn_error $? "missing argument to $ac_option"
b75a7d8f 1235fi
b75a7d8f 1236
729e4ab9
A
1237if test -n "$ac_unrecognized_opts"; then
1238 case $enable_option_checking in
1239 no) ;;
1240 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1241 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
73c04bcf 1242 esac
729e4ab9 1243fi
b75a7d8f 1244
729e4ab9
A
1245# Check all directory arguments for consistency.
1246for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1247 datadir sysconfdir sharedstatedir localstatedir includedir \
1248 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
3d1f044b 1249 libdir localedir mandir
b75a7d8f 1250do
729e4ab9
A
1251 eval ac_val=\$$ac_var
1252 # Remove trailing slashes.
1253 case $ac_val in
1254 */ )
1255 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1256 eval $ac_var=\$ac_val;;
1257 esac
1258 # Be sure to have absolute directory names.
73c04bcf 1259 case $ac_val in
729e4ab9
A
1260 [\\/$]* | ?:[\\/]* ) continue;;
1261 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
b75a7d8f 1262 esac
729e4ab9 1263 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
b75a7d8f
A
1264done
1265
73c04bcf
A
1266# There might be people who depend on the old broken behavior: `$host'
1267# used to hold the argument of --host etc.
1268# FIXME: To remove some day.
1269build=$build_alias
1270host=$host_alias
1271target=$target_alias
1272
1273# FIXME: To remove some day.
1274if test "x$host_alias" != x; then
1275 if test "x$build_alias" = x; then
1276 cross_compiling=maybe
73c04bcf
A
1277 elif test "x$build_alias" != "x$host_alias"; then
1278 cross_compiling=yes
1279 fi
1280fi
b75a7d8f 1281
73c04bcf
A
1282ac_tool_prefix=
1283test -n "$host_alias" && ac_tool_prefix=$host_alias-
1284
1285test "$silent" = yes && exec 6>/dev/null
b75a7d8f 1286
b75a7d8f 1287
729e4ab9
A
1288ac_pwd=`pwd` && test -n "$ac_pwd" &&
1289ac_ls_di=`ls -di .` &&
1290ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1291 as_fn_error $? "working directory cannot be determined"
1292test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1293 as_fn_error $? "pwd does not report name of working directory"
1294
1295
b75a7d8f
A
1296# Find the source files, if location was not specified.
1297if test -z "$srcdir"; then
1298 ac_srcdir_defaulted=yes
729e4ab9
A
1299 # Try the directory containing this script, then the parent directory.
1300 ac_confdir=`$as_dirname -- "$as_myself" ||
1301$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1302 X"$as_myself" : 'X\(//\)[^/]' \| \
1303 X"$as_myself" : 'X\(//\)$' \| \
1304 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1305$as_echo X"$as_myself" |
1306 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1307 s//\1/
1308 q
1309 }
1310 /^X\(\/\/\)[^/].*/{
1311 s//\1/
1312 q
1313 }
1314 /^X\(\/\/\)$/{
1315 s//\1/
1316 q
1317 }
1318 /^X\(\/\).*/{
1319 s//\1/
1320 q
1321 }
1322 s/.*/./; q'`
b75a7d8f 1323 srcdir=$ac_confdir
729e4ab9 1324 if test ! -r "$srcdir/$ac_unique_file"; then
b75a7d8f
A
1325 srcdir=..
1326 fi
1327else
1328 ac_srcdir_defaulted=no
1329fi
729e4ab9
A
1330if test ! -r "$srcdir/$ac_unique_file"; then
1331 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1332 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1333fi
1334ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1335ac_abs_confdir=`(
1336 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1337 pwd)`
1338# When building in place, set srcdir=.
1339if test "$ac_abs_confdir" = "$ac_pwd"; then
1340 srcdir=.
1341fi
1342# Remove unnecessary trailing slashes from srcdir.
1343# Double slashes in file names in object file debugging info
1344# mess up M-x gdb in Emacs.
1345case $srcdir in
1346*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1347esac
1348for ac_var in $ac_precious_vars; do
1349 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1350 eval ac_env_${ac_var}_value=\$${ac_var}
1351 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1352 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1353done
b75a7d8f 1354
73c04bcf
A
1355#
1356# Report the --help message.
1357#
1358if test "$ac_init_help" = "long"; then
1359 # Omit some internal or obsolete options to make the list less imposing.
1360 # This message is too long to be a string in the A/UX 3.1 sh.
1361 cat <<_ACEOF
3d1f044b 1362\`configure' configures ICU 64.2 to adapt to many kinds of systems.
73c04bcf
A
1363
1364Usage: $0 [OPTION]... [VAR=VALUE]...
1365
1366To assign environment variables (e.g., CC, CFLAGS...), specify them as
1367VAR=VALUE. See below for descriptions of some of the useful variables.
1368
1369Defaults for the options are specified in brackets.
1370
1371Configuration:
1372 -h, --help display this help and exit
1373 --help=short display options specific to this package
1374 --help=recursive display the short help of all the included packages
1375 -V, --version display version information and exit
729e4ab9 1376 -q, --quiet, --silent do not print \`checking ...' messages
73c04bcf
A
1377 --cache-file=FILE cache test results in FILE [disabled]
1378 -C, --config-cache alias for \`--cache-file=config.cache'
1379 -n, --no-create do not create output files
1380 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1381
73c04bcf
A
1382Installation directories:
1383 --prefix=PREFIX install architecture-independent files in PREFIX
729e4ab9 1384 [$ac_default_prefix]
73c04bcf 1385 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
729e4ab9 1386 [PREFIX]
73c04bcf
A
1387
1388By default, \`make install' will install all the files in
1389\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1390an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1391for instance \`--prefix=\$HOME'.
1392
1393For better control, use the options below.
1394
1395Fine tuning of the installation directories:
729e4ab9
A
1396 --bindir=DIR user executables [EPREFIX/bin]
1397 --sbindir=DIR system admin executables [EPREFIX/sbin]
1398 --libexecdir=DIR program executables [EPREFIX/libexec]
1399 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1400 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1401 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1402 --libdir=DIR object code libraries [EPREFIX/lib]
1403 --includedir=DIR C header files [PREFIX/include]
1404 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1405 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1406 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1407 --infodir=DIR info documentation [DATAROOTDIR/info]
1408 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1409 --mandir=DIR man documentation [DATAROOTDIR/man]
b331163b
A
1410 --docdir=DIR documentation root [DATAROOTDIR/doc/International
1411 Components for Unicode]
729e4ab9
A
1412 --htmldir=DIR html documentation [DOCDIR]
1413 --dvidir=DIR dvi documentation [DOCDIR]
1414 --pdfdir=DIR pdf documentation [DOCDIR]
1415 --psdir=DIR ps documentation [DOCDIR]
73c04bcf
A
1416_ACEOF
1417
1418 cat <<\_ACEOF
1419
1420System types:
1421 --build=BUILD configure for building on BUILD [guessed]
1422 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1423_ACEOF
1424fi
1425
1426if test -n "$ac_init_help"; then
b331163b 1427 case $ac_init_help in
3d1f044b 1428 short | recursive ) echo "Configuration of ICU 64.2:";;
b331163b 1429 esac
73c04bcf
A
1430 cat <<\_ACEOF
1431
1432Optional Features:
729e4ab9 1433 --disable-option-checking ignore unrecognized --enable/--with options
73c04bcf
A
1434 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1435 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
3d1f044b 1436 --enable-icu-config install icu-config
4388f060 1437 --enable-debug build debug libraries and enable the U_DEBUG define default=no
73c04bcf 1438 --enable-release build release libraries default=yes
729e4ab9
A
1439 --enable-strict compile with strict compiler options default=yes
1440 --enable-64bit-libs (deprecated, use --with-library-bits) build 64-bit libraries default= platform default
1441 --enable-shared build shared libraries default=yes
1442 --enable-static build static libraries default=no
1443 --enable-auto-cleanup enable auto cleanup of libraries default=no
1444 --enable-draft enable draft APIs (and internal APIs) default=yes
73c04bcf 1445 --enable-renaming add a version suffix to symbols default=yes
46f4442e 1446 --enable-tracing enable function and data tracing default=no
2ca993e8 1447 --enable-plugins enable plugins default=no
729e4ab9 1448 --disable-dyload disable dynamic loading default=no
73c04bcf 1449 --enable-rpath use rpath when linking default is only if necessary
46f4442e 1450 --enable-weak-threads weakly reference the threading library default=no
73c04bcf
A
1451 --enable-extras build ICU extras default=yes
1452 --enable-icuio build ICU's icuio library default=yes
f3c0d7a5
A
1453 --enable-layoutex build ICU's Paragraph Layout library default=yes.
1454 icu-le-hb must be installed via pkg-config. See http://harfbuzz.org
1455
57a6839d 1456 --enable-tools build ICU's tools default=yes
73c04bcf
A
1457 --enable-tests build ICU tests default=yes
1458 --enable-samples build ICU samples default=yes
46f4442e
A
1459
1460Additionally, the variable FORCE_LIBS may be set before calling configure.
1461If set, it will REPLACE any automatic list of libraries.
73c04bcf
A
1462
1463Optional Packages:
1464 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1465 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
729e4ab9
A
1466 --with-cross-build=dir specify an absolute path to the build directory of an ICU built for the current platform default=no cross dir
1467 --with-library-bits=bits specify how many bits to use for the library (32, 64, 64else32, nochange) default=nochange
b331163b
A
1468 --with-data-packaging specify how to package ICU data. Possible values:
1469 files raw files (.res, etc)
1470 archive build a single icudtXX.dat file
1471 library shared library (.dll/.so/etc.)
1472 static static library (.a/.lib/etc.)
1473 auto build shared if possible (default)
1474 See http://userguide.icu-project.org/icudata for more info.
73c04bcf
A
1475 --with-library-suffix=suffix tag a suffix to the library names default=
1476
1477Some influential environment variables:
1478 CC C compiler command
1479 CFLAGS C compiler flags
1480 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1481 nonstandard directory <lib dir>
729e4ab9
A
1482 LIBS libraries to pass to the linker, e.g. -l<library>
1483 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1484 you have headers in a nonstandard directory <include dir>
73c04bcf
A
1485 CXX C++ compiler command
1486 CXXFLAGS C++ compiler flags
b331163b 1487 PKG_CONFIG path to pkg-config utility
2ca993e8
A
1488 PKG_CONFIG_PATH
1489 directories to add to pkg-config's search path
1490 PKG_CONFIG_LIBDIR
1491 path overriding pkg-config's built-in search path
b331163b
A
1492 ICULEHB_CFLAGS
1493 C compiler flags for ICULEHB, overriding pkg-config
1494 ICULEHB_LIBS
1495 linker flags for ICULEHB, overriding pkg-config
73c04bcf
A
1496 CPP C preprocessor
1497
1498Use these variables to override the choices made by `configure' or to help
1499it to find libraries and programs with nonstandard names/locations.
1500
b331163b
A
1501Report bugs to <http://icu-project.org/bugs>.
1502ICU home page: <http://icu-project.org>.
73c04bcf 1503_ACEOF
729e4ab9 1504ac_status=$?
73c04bcf
A
1505fi
1506
1507if test "$ac_init_help" = "recursive"; then
1508 # If there are subdirs, report their specific --help.
73c04bcf 1509 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
729e4ab9
A
1510 test -d "$ac_dir" ||
1511 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1512 continue
73c04bcf
A
1513 ac_builddir=.
1514
729e4ab9
A
1515case "$ac_dir" in
1516.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1517*)
1518 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1519 # A ".." for each directory in $ac_dir_suffix.
1520 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1521 case $ac_top_builddir_sub in
1522 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1523 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1524 esac ;;
1525esac
1526ac_abs_top_builddir=$ac_pwd
1527ac_abs_builddir=$ac_pwd$ac_dir_suffix
1528# for backward compatibility:
1529ac_top_builddir=$ac_top_build_prefix
73c04bcf
A
1530
1531case $srcdir in
729e4ab9 1532 .) # We are building in place.
73c04bcf 1533 ac_srcdir=.
729e4ab9
A
1534 ac_top_srcdir=$ac_top_builddir_sub
1535 ac_abs_top_srcdir=$ac_pwd ;;
1536 [\\/]* | ?:[\\/]* ) # Absolute name.
73c04bcf 1537 ac_srcdir=$srcdir$ac_dir_suffix;
729e4ab9
A
1538 ac_top_srcdir=$srcdir
1539 ac_abs_top_srcdir=$srcdir ;;
1540 *) # Relative name.
1541 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1542 ac_top_srcdir=$ac_top_build_prefix$srcdir
1543 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
73c04bcf 1544esac
729e4ab9
A
1545ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1546
1547 cd "$ac_dir" || { ac_status=$?; continue; }
1548 # Check for guested configure.
1549 if test -f "$ac_srcdir/configure.gnu"; then
1550 echo &&
1551 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1552 elif test -f "$ac_srcdir/configure"; then
1553 echo &&
1554 $SHELL "$ac_srcdir/configure" --help=recursive
73c04bcf 1555 else
729e4ab9
A
1556 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1557 fi || ac_status=$?
1558 cd "$ac_pwd" || { ac_status=$?; break; }
73c04bcf
A
1559 done
1560fi
1561
729e4ab9 1562test -n "$ac_init_help" && exit $ac_status
73c04bcf
A
1563if $ac_init_version; then
1564 cat <<\_ACEOF
3d1f044b 1565ICU configure 64.2
b331163b 1566generated by GNU Autoconf 2.69
73c04bcf 1567
b331163b 1568Copyright (C) 2012 Free Software Foundation, Inc.
73c04bcf
A
1569This configure script is free software; the Free Software Foundation
1570gives unlimited permission to copy, distribute and modify it.
729e4ab9 1571
f3c0d7a5 1572 Copyright (C) 2016 and later: Unicode, Inc. and others. License & terms of use: http://www.unicode.org/copyright.html
73c04bcf 1573_ACEOF
729e4ab9 1574 exit
73c04bcf 1575fi
73c04bcf 1576
729e4ab9
A
1577## ------------------------ ##
1578## Autoconf initialization. ##
1579## ------------------------ ##
73c04bcf 1580
729e4ab9
A
1581# ac_fn_c_try_compile LINENO
1582# --------------------------
1583# Try to compile conftest.$ac_ext, and return whether this succeeded.
1584ac_fn_c_try_compile ()
1585{
1586 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1587 rm -f conftest.$ac_objext
1588 if { { ac_try="$ac_compile"
1589case "(($ac_try" in
1590 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1591 *) ac_try_echo=$ac_try;;
1592esac
1593eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1594$as_echo "$ac_try_echo"; } >&5
1595 (eval "$ac_compile") 2>conftest.err
1596 ac_status=$?
1597 if test -s conftest.err; then
1598 grep -v '^ *+' conftest.err >conftest.er1
1599 cat conftest.er1 >&5
1600 mv -f conftest.er1 conftest.err
1601 fi
1602 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1603 test $ac_status = 0; } && {
1604 test -z "$ac_c_werror_flag" ||
1605 test ! -s conftest.err
1606 } && test -s conftest.$ac_objext; then :
1607 ac_retval=0
1608else
1609 $as_echo "$as_me: failed program was:" >&5
1610sed 's/^/| /' conftest.$ac_ext >&5
73c04bcf 1611
729e4ab9
A
1612 ac_retval=1
1613fi
4388f060 1614 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
729e4ab9
A
1615 as_fn_set_status $ac_retval
1616
1617} # ac_fn_c_try_compile
1618
1619# ac_fn_cxx_try_compile LINENO
1620# ----------------------------
1621# Try to compile conftest.$ac_ext, and return whether this succeeded.
1622ac_fn_cxx_try_compile ()
73c04bcf 1623{
729e4ab9
A
1624 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1625 rm -f conftest.$ac_objext
1626 if { { ac_try="$ac_compile"
1627case "(($ac_try" in
1628 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1629 *) ac_try_echo=$ac_try;;
1630esac
1631eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1632$as_echo "$ac_try_echo"; } >&5
1633 (eval "$ac_compile") 2>conftest.err
1634 ac_status=$?
1635 if test -s conftest.err; then
1636 grep -v '^ *+' conftest.err >conftest.er1
1637 cat conftest.er1 >&5
1638 mv -f conftest.er1 conftest.err
1639 fi
1640 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1641 test $ac_status = 0; } && {
1642 test -z "$ac_cxx_werror_flag" ||
1643 test ! -s conftest.err
1644 } && test -s conftest.$ac_objext; then :
1645 ac_retval=0
1646else
1647 $as_echo "$as_me: failed program was:" >&5
1648sed 's/^/| /' conftest.$ac_ext >&5
73c04bcf 1649
729e4ab9
A
1650 ac_retval=1
1651fi
4388f060 1652 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
729e4ab9 1653 as_fn_set_status $ac_retval
73c04bcf 1654
729e4ab9 1655} # ac_fn_cxx_try_compile
73c04bcf 1656
729e4ab9
A
1657# ac_fn_c_try_cpp LINENO
1658# ----------------------
1659# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1660ac_fn_c_try_cpp ()
1661{
1662 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1663 if { { ac_try="$ac_cpp conftest.$ac_ext"
1664case "(($ac_try" in
1665 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1666 *) ac_try_echo=$ac_try;;
1667esac
1668eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1669$as_echo "$ac_try_echo"; } >&5
1670 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1671 ac_status=$?
1672 if test -s conftest.err; then
1673 grep -v '^ *+' conftest.err >conftest.er1
1674 cat conftest.er1 >&5
1675 mv -f conftest.er1 conftest.err
1676 fi
1677 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1678 test $ac_status = 0; } > conftest.i && {
1679 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1680 test ! -s conftest.err
1681 }; then :
1682 ac_retval=0
1683else
1684 $as_echo "$as_me: failed program was:" >&5
1685sed 's/^/| /' conftest.$ac_ext >&5
1686
1687 ac_retval=1
1688fi
4388f060 1689 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
729e4ab9
A
1690 as_fn_set_status $ac_retval
1691
1692} # ac_fn_c_try_cpp
1693
1694# ac_fn_cxx_try_link LINENO
1695# -------------------------
1696# Try to link conftest.$ac_ext, and return whether this succeeded.
1697ac_fn_cxx_try_link ()
1698{
1699 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1700 rm -f conftest.$ac_objext conftest$ac_exeext
1701 if { { ac_try="$ac_link"
1702case "(($ac_try" in
1703 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1704 *) ac_try_echo=$ac_try;;
1705esac
1706eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1707$as_echo "$ac_try_echo"; } >&5
1708 (eval "$ac_link") 2>conftest.err
1709 ac_status=$?
1710 if test -s conftest.err; then
1711 grep -v '^ *+' conftest.err >conftest.er1
1712 cat conftest.er1 >&5
1713 mv -f conftest.er1 conftest.err
1714 fi
1715 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1716 test $ac_status = 0; } && {
1717 test -z "$ac_cxx_werror_flag" ||
1718 test ! -s conftest.err
1719 } && test -s conftest$ac_exeext && {
1720 test "$cross_compiling" = yes ||
b331163b 1721 test -x conftest$ac_exeext
729e4ab9
A
1722 }; then :
1723 ac_retval=0
1724else
1725 $as_echo "$as_me: failed program was:" >&5
1726sed 's/^/| /' conftest.$ac_ext >&5
1727
1728 ac_retval=1
1729fi
1730 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1731 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1732 # interfere with the next link command; also delete a directory that is
1733 # left behind by Apple's compiler. We do this before executing the actions.
1734 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
4388f060 1735 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
729e4ab9
A
1736 as_fn_set_status $ac_retval
1737
1738} # ac_fn_cxx_try_link
1739
1740# ac_fn_c_try_run LINENO
1741# ----------------------
1742# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1743# that executables *can* be run.
1744ac_fn_c_try_run ()
1745{
1746 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1747 if { { ac_try="$ac_link"
1748case "(($ac_try" in
1749 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1750 *) ac_try_echo=$ac_try;;
1751esac
1752eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1753$as_echo "$ac_try_echo"; } >&5
1754 (eval "$ac_link") 2>&5
1755 ac_status=$?
1756 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1757 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1758 { { case "(($ac_try" in
1759 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1760 *) ac_try_echo=$ac_try;;
1761esac
1762eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1763$as_echo "$ac_try_echo"; } >&5
1764 (eval "$ac_try") 2>&5
1765 ac_status=$?
1766 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1767 test $ac_status = 0; }; }; then :
1768 ac_retval=0
1769else
1770 $as_echo "$as_me: program exited with status $ac_status" >&5
1771 $as_echo "$as_me: failed program was:" >&5
1772sed 's/^/| /' conftest.$ac_ext >&5
1773
1774 ac_retval=$ac_status
1775fi
1776 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
4388f060 1777 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
729e4ab9
A
1778 as_fn_set_status $ac_retval
1779
1780} # ac_fn_c_try_run
1781
1782# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
1783# --------------------------------------------
1784# Tries to find the compile-time value of EXPR in a program that includes
1785# INCLUDES, setting VAR accordingly. Returns whether the value could be
1786# computed
1787ac_fn_c_compute_int ()
1788{
1789 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1790 if test "$cross_compiling" = yes; then
1791 # Depending upon the size, compute the lo and hi bounds.
1792cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1793/* end confdefs.h. */
1794$4
1795int
1796main ()
1797{
1798static int test_array [1 - 2 * !(($2) >= 0)];
b331163b
A
1799test_array [0] = 0;
1800return test_array [0];
729e4ab9
A
1801
1802 ;
1803 return 0;
1804}
1805_ACEOF
1806if ac_fn_c_try_compile "$LINENO"; then :
1807 ac_lo=0 ac_mid=0
1808 while :; do
1809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1810/* end confdefs.h. */
1811$4
1812int
1813main ()
1814{
1815static int test_array [1 - 2 * !(($2) <= $ac_mid)];
b331163b
A
1816test_array [0] = 0;
1817return test_array [0];
729e4ab9
A
1818
1819 ;
1820 return 0;
1821}
1822_ACEOF
1823if ac_fn_c_try_compile "$LINENO"; then :
1824 ac_hi=$ac_mid; break
1825else
1826 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
1827 if test $ac_lo -le $ac_mid; then
1828 ac_lo= ac_hi=
1829 break
1830 fi
1831 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
1832fi
1833rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1834 done
1835else
1836 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1837/* end confdefs.h. */
1838$4
1839int
1840main ()
1841{
1842static int test_array [1 - 2 * !(($2) < 0)];
b331163b
A
1843test_array [0] = 0;
1844return test_array [0];
729e4ab9
A
1845
1846 ;
1847 return 0;
1848}
1849_ACEOF
1850if ac_fn_c_try_compile "$LINENO"; then :
1851 ac_hi=-1 ac_mid=-1
1852 while :; do
1853 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1854/* end confdefs.h. */
1855$4
1856int
1857main ()
1858{
1859static int test_array [1 - 2 * !(($2) >= $ac_mid)];
b331163b
A
1860test_array [0] = 0;
1861return test_array [0];
729e4ab9
A
1862
1863 ;
1864 return 0;
1865}
1866_ACEOF
1867if ac_fn_c_try_compile "$LINENO"; then :
1868 ac_lo=$ac_mid; break
1869else
1870 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
1871 if test $ac_mid -le $ac_hi; then
1872 ac_lo= ac_hi=
1873 break
1874 fi
1875 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
1876fi
1877rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1878 done
1879else
1880 ac_lo= ac_hi=
1881fi
1882rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1883fi
1884rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1885# Binary search between lo and hi bounds.
1886while test "x$ac_lo" != "x$ac_hi"; do
1887 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
1888 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1889/* end confdefs.h. */
1890$4
1891int
1892main ()
1893{
1894static int test_array [1 - 2 * !(($2) <= $ac_mid)];
b331163b
A
1895test_array [0] = 0;
1896return test_array [0];
729e4ab9
A
1897
1898 ;
1899 return 0;
1900}
1901_ACEOF
1902if ac_fn_c_try_compile "$LINENO"; then :
1903 ac_hi=$ac_mid
1904else
1905 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
1906fi
1907rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1908done
1909case $ac_lo in #((
1910?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
1911'') ac_retval=1 ;;
1912esac
1913 else
1914 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1915/* end confdefs.h. */
1916$4
1917static long int longval () { return $2; }
1918static unsigned long int ulongval () { return $2; }
1919#include <stdio.h>
1920#include <stdlib.h>
1921int
1922main ()
1923{
1924
1925 FILE *f = fopen ("conftest.val", "w");
1926 if (! f)
1927 return 1;
1928 if (($2) < 0)
1929 {
1930 long int i = longval ();
1931 if (i != ($2))
1932 return 1;
1933 fprintf (f, "%ld", i);
1934 }
1935 else
1936 {
1937 unsigned long int i = ulongval ();
1938 if (i != ($2))
1939 return 1;
1940 fprintf (f, "%lu", i);
1941 }
1942 /* Do not output a trailing newline, as this causes \r\n confusion
1943 on some platforms. */
1944 return ferror (f) || fclose (f) != 0;
1945
1946 ;
1947 return 0;
1948}
1949_ACEOF
1950if ac_fn_c_try_run "$LINENO"; then :
1951 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
1952else
1953 ac_retval=1
1954fi
1955rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
1956 conftest.$ac_objext conftest.beam conftest.$ac_ext
1957rm -f conftest.val
1958
1959 fi
4388f060 1960 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
729e4ab9
A
1961 as_fn_set_status $ac_retval
1962
1963} # ac_fn_c_compute_int
1964
1965# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1966# -------------------------------------------------------
1967# Tests whether HEADER exists and can be compiled using the include files in
1968# INCLUDES, setting the cache variable VAR accordingly.
1969ac_fn_c_check_header_compile ()
1970{
1971 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1973$as_echo_n "checking for $2... " >&6; }
4388f060 1974if eval \${$3+:} false; then :
729e4ab9
A
1975 $as_echo_n "(cached) " >&6
1976else
1977 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1978/* end confdefs.h. */
1979$4
1980#include <$2>
1981_ACEOF
1982if ac_fn_c_try_compile "$LINENO"; then :
1983 eval "$3=yes"
1984else
1985 eval "$3=no"
1986fi
1987rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1988fi
1989eval ac_res=\$$3
1990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1991$as_echo "$ac_res" >&6; }
4388f060 1992 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
729e4ab9
A
1993
1994} # ac_fn_c_check_header_compile
1995
1996# ac_fn_c_try_link LINENO
1997# -----------------------
1998# Try to link conftest.$ac_ext, and return whether this succeeded.
1999ac_fn_c_try_link ()
2000{
2001 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2002 rm -f conftest.$ac_objext conftest$ac_exeext
2003 if { { ac_try="$ac_link"
2004case "(($ac_try" in
2005 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2006 *) ac_try_echo=$ac_try;;
2007esac
2008eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2009$as_echo "$ac_try_echo"; } >&5
2010 (eval "$ac_link") 2>conftest.err
2011 ac_status=$?
2012 if test -s conftest.err; then
2013 grep -v '^ *+' conftest.err >conftest.er1
2014 cat conftest.er1 >&5
2015 mv -f conftest.er1 conftest.err
2016 fi
2017 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2018 test $ac_status = 0; } && {
2019 test -z "$ac_c_werror_flag" ||
2020 test ! -s conftest.err
2021 } && test -s conftest$ac_exeext && {
2022 test "$cross_compiling" = yes ||
b331163b 2023 test -x conftest$ac_exeext
729e4ab9
A
2024 }; then :
2025 ac_retval=0
2026else
2027 $as_echo "$as_me: failed program was:" >&5
2028sed 's/^/| /' conftest.$ac_ext >&5
2029
2030 ac_retval=1
2031fi
2032 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2033 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2034 # interfere with the next link command; also delete a directory that is
2035 # left behind by Apple's compiler. We do this before executing the actions.
2036 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
4388f060 2037 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
729e4ab9
A
2038 as_fn_set_status $ac_retval
2039
2040} # ac_fn_c_try_link
2041
2042# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2043# -------------------------------------------------------
2044# Tests whether HEADER exists, giving a warning if it cannot be compiled using
2045# the include files in INCLUDES and setting the cache variable VAR
2046# accordingly.
2047ac_fn_c_check_header_mongrel ()
2048{
2049 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
4388f060 2050 if eval \${$3+:} false; then :
729e4ab9
A
2051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2052$as_echo_n "checking for $2... " >&6; }
4388f060 2053if eval \${$3+:} false; then :
729e4ab9
A
2054 $as_echo_n "(cached) " >&6
2055fi
2056eval ac_res=\$$3
2057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2058$as_echo "$ac_res" >&6; }
2059else
2060 # Is the header compilable?
2061{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2062$as_echo_n "checking $2 usability... " >&6; }
2063cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2064/* end confdefs.h. */
2065$4
2066#include <$2>
2067_ACEOF
2068if ac_fn_c_try_compile "$LINENO"; then :
2069 ac_header_compiler=yes
2070else
2071 ac_header_compiler=no
2072fi
2073rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2074{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2075$as_echo "$ac_header_compiler" >&6; }
2076
2077# Is the header present?
2078{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2079$as_echo_n "checking $2 presence... " >&6; }
2080cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2081/* end confdefs.h. */
2082#include <$2>
2083_ACEOF
2084if ac_fn_c_try_cpp "$LINENO"; then :
2085 ac_header_preproc=yes
2086else
2087 ac_header_preproc=no
2088fi
2089rm -f conftest.err conftest.i conftest.$ac_ext
2090{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2091$as_echo "$ac_header_preproc" >&6; }
2092
2093# So? What about this header?
2094case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2095 yes:no: )
2096 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2097$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2098 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2099$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2100 ;;
2101 no:yes:* )
2102 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2103$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2104 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2105$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2106 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2107$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2108 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2109$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2110 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2111$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
b331163b
A
2112( $as_echo "## ------------------------------------------ ##
2113## Report this to http://icu-project.org/bugs ##
2114## ------------------------------------------ ##"
2115 ) | sed "s/^/$as_me: WARNING: /" >&2
729e4ab9
A
2116 ;;
2117esac
2118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2119$as_echo_n "checking for $2... " >&6; }
4388f060 2120if eval \${$3+:} false; then :
729e4ab9
A
2121 $as_echo_n "(cached) " >&6
2122else
2123 eval "$3=\$ac_header_compiler"
2124fi
2125eval ac_res=\$$3
2126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2127$as_echo "$ac_res" >&6; }
2128fi
4388f060 2129 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
729e4ab9
A
2130
2131} # ac_fn_c_check_header_mongrel
2132
2133# ac_fn_c_check_func LINENO FUNC VAR
2134# ----------------------------------
2135# Tests whether FUNC exists, setting the cache variable VAR accordingly
2136ac_fn_c_check_func ()
2137{
2138 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2140$as_echo_n "checking for $2... " >&6; }
4388f060 2141if eval \${$3+:} false; then :
729e4ab9
A
2142 $as_echo_n "(cached) " >&6
2143else
2144 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2145/* end confdefs.h. */
2146/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2147 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2148#define $2 innocuous_$2
2149
2150/* System header to define __stub macros and hopefully few prototypes,
2151 which can conflict with char $2 (); below.
2152 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2153 <limits.h> exists even on freestanding compilers. */
2154
2155#ifdef __STDC__
2156# include <limits.h>
2157#else
2158# include <assert.h>
2159#endif
2160
2161#undef $2
2162
2163/* Override any GCC internal prototype to avoid an error.
2164 Use char because int might match the return type of a GCC
2165 builtin and then its argument prototype would still apply. */
2166#ifdef __cplusplus
2167extern "C"
2168#endif
2169char $2 ();
2170/* The GNU C library defines this for functions which it implements
2171 to always fail with ENOSYS. Some functions are actually named
2172 something starting with __ and the normal name is an alias. */
2173#if defined __stub_$2 || defined __stub___$2
2174choke me
2175#endif
2176
2177int
2178main ()
2179{
2180return $2 ();
2181 ;
2182 return 0;
2183}
2184_ACEOF
2185if ac_fn_c_try_link "$LINENO"; then :
2186 eval "$3=yes"
2187else
2188 eval "$3=no"
2189fi
2190rm -f core conftest.err conftest.$ac_objext \
2191 conftest$ac_exeext conftest.$ac_ext
2192fi
2193eval ac_res=\$$3
2194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2195$as_echo "$ac_res" >&6; }
4388f060 2196 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
729e4ab9
A
2197
2198} # ac_fn_c_check_func
2199
2200# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2201# -------------------------------------------
2202# Tests whether TYPE exists after having included INCLUDES, setting cache
2203# variable VAR accordingly.
2204ac_fn_c_check_type ()
2205{
2206 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2208$as_echo_n "checking for $2... " >&6; }
4388f060 2209if eval \${$3+:} false; then :
729e4ab9
A
2210 $as_echo_n "(cached) " >&6
2211else
2212 eval "$3=no"
2213 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2214/* end confdefs.h. */
2215$4
2216int
2217main ()
2218{
2219if (sizeof ($2))
2220 return 0;
2221 ;
2222 return 0;
2223}
2224_ACEOF
2225if ac_fn_c_try_compile "$LINENO"; then :
2226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2227/* end confdefs.h. */
2228$4
2229int
2230main ()
2231{
2232if (sizeof (($2)))
2233 return 0;
2234 ;
2235 return 0;
2236}
2237_ACEOF
2238if ac_fn_c_try_compile "$LINENO"; then :
2239
2240else
2241 eval "$3=yes"
2242fi
2243rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2244fi
2245rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2246fi
2247eval ac_res=\$$3
2248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2249$as_echo "$ac_res" >&6; }
4388f060 2250 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
729e4ab9
A
2251
2252} # ac_fn_c_check_type
2253cat >config.log <<_ACEOF
2254This file contains any messages produced by compilers while
2255running configure, to aid debugging if configure makes a mistake.
2256
3d1f044b 2257It was created by ICU $as_me 64.2, which was
b331163b 2258generated by GNU Autoconf 2.69. Invocation command line was
729e4ab9
A
2259
2260 $ $0 $@
2261
2262_ACEOF
2263exec 5>>config.log
2264{
2265cat <<_ASUNAME
2266## --------- ##
2267## Platform. ##
2268## --------- ##
2269
2270hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2271uname -m = `(uname -m) 2>/dev/null || echo unknown`
2272uname -r = `(uname -r) 2>/dev/null || echo unknown`
2273uname -s = `(uname -s) 2>/dev/null || echo unknown`
2274uname -v = `(uname -v) 2>/dev/null || echo unknown`
2275
2276/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2277/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2278
2279/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2280/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2281/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2282/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
73c04bcf
A
2283/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2284/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2285/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2286
2287_ASUNAME
2288
2289as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2290for as_dir in $PATH
2291do
2292 IFS=$as_save_IFS
2293 test -z "$as_dir" && as_dir=.
729e4ab9
A
2294 $as_echo "PATH: $as_dir"
2295 done
2296IFS=$as_save_IFS
73c04bcf
A
2297
2298} >&5
2299
2300cat >&5 <<_ACEOF
2301
2302
2303## ----------- ##
2304## Core tests. ##
2305## ----------- ##
2306
2307_ACEOF
2308
2309
2310# Keep a trace of the command line.
2311# Strip out --no-create and --no-recursion so they do not pile up.
2312# Strip out --silent because we don't want to record it for future runs.
2313# Also quote any args containing shell meta-characters.
2314# Make two passes to allow for proper duplicate-argument suppression.
2315ac_configure_args=
2316ac_configure_args0=
2317ac_configure_args1=
73c04bcf
A
2318ac_must_keep_next=false
2319for ac_pass in 1 2
2320do
2321 for ac_arg
2322 do
2323 case $ac_arg in
2324 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2325 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2326 | -silent | --silent | --silen | --sile | --sil)
2327 continue ;;
729e4ab9
A
2328 *\'*)
2329 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
73c04bcf
A
2330 esac
2331 case $ac_pass in
729e4ab9 2332 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
73c04bcf 2333 2)
729e4ab9 2334 as_fn_append ac_configure_args1 " '$ac_arg'"
73c04bcf
A
2335 if test $ac_must_keep_next = true; then
2336 ac_must_keep_next=false # Got value, back to normal.
2337 else
2338 case $ac_arg in
2339 *=* | --config-cache | -C | -disable-* | --disable-* \
2340 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2341 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2342 | -with-* | --with-* | -without-* | --without-* | --x)
2343 case "$ac_configure_args0 " in
2344 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2345 esac
2346 ;;
2347 -* ) ac_must_keep_next=true ;;
2348 esac
2349 fi
729e4ab9 2350 as_fn_append ac_configure_args " '$ac_arg'"
73c04bcf
A
2351 ;;
2352 esac
2353 done
2354done
729e4ab9
A
2355{ ac_configure_args0=; unset ac_configure_args0;}
2356{ ac_configure_args1=; unset ac_configure_args1;}
73c04bcf
A
2357
2358# When interrupted or exit'd, cleanup temporary files, and complete
2359# config.log. We remove comments because anyway the quotes in there
2360# would cause problems or look ugly.
729e4ab9
A
2361# WARNING: Use '\'' to represent an apostrophe within the trap.
2362# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
73c04bcf
A
2363trap 'exit_status=$?
2364 # Save into config.log some information that might help in debugging.
2365 {
2366 echo
2367
729e4ab9 2368 $as_echo "## ---------------- ##
73c04bcf 2369## Cache variables. ##
729e4ab9 2370## ---------------- ##"
73c04bcf
A
2371 echo
2372 # The following way of writing the cache mishandles newlines in values,
729e4ab9
A
2373(
2374 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2375 eval ac_val=\$$ac_var
2376 case $ac_val in #(
2377 *${as_nl}*)
2378 case $ac_var in #(
2379 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2380$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2381 esac
2382 case $ac_var in #(
2383 _ | IFS | as_nl) ;; #(
2384 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2385 *) { eval $ac_var=; unset $ac_var;} ;;
2386 esac ;;
2387 esac
2388 done
73c04bcf 2389 (set) 2>&1 |
729e4ab9
A
2390 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2391 *${as_nl}ac_space=\ *)
73c04bcf 2392 sed -n \
729e4ab9
A
2393 "s/'\''/'\''\\\\'\'''\''/g;
2394 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2395 ;; #(
73c04bcf 2396 *)
729e4ab9 2397 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
73c04bcf 2398 ;;
729e4ab9
A
2399 esac |
2400 sort
2401)
73c04bcf
A
2402 echo
2403
729e4ab9 2404 $as_echo "## ----------------- ##
73c04bcf 2405## Output variables. ##
729e4ab9 2406## ----------------- ##"
73c04bcf
A
2407 echo
2408 for ac_var in $ac_subst_vars
2409 do
729e4ab9
A
2410 eval ac_val=\$$ac_var
2411 case $ac_val in
2412 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2413 esac
2414 $as_echo "$ac_var='\''$ac_val'\''"
73c04bcf
A
2415 done | sort
2416 echo
2417
2418 if test -n "$ac_subst_files"; then
729e4ab9
A
2419 $as_echo "## ------------------- ##
2420## File substitutions. ##
2421## ------------------- ##"
73c04bcf
A
2422 echo
2423 for ac_var in $ac_subst_files
2424 do
729e4ab9
A
2425 eval ac_val=\$$ac_var
2426 case $ac_val in
2427 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2428 esac
2429 $as_echo "$ac_var='\''$ac_val'\''"
73c04bcf
A
2430 done | sort
2431 echo
2432 fi
2433
2434 if test -s confdefs.h; then
729e4ab9 2435 $as_echo "## ----------- ##
73c04bcf 2436## confdefs.h. ##
729e4ab9 2437## ----------- ##"
73c04bcf 2438 echo
729e4ab9 2439 cat confdefs.h
73c04bcf
A
2440 echo
2441 fi
2442 test "$ac_signal" != 0 &&
729e4ab9
A
2443 $as_echo "$as_me: caught signal $ac_signal"
2444 $as_echo "$as_me: exit $exit_status"
73c04bcf 2445 } >&5
729e4ab9
A
2446 rm -f core *.core core.conftest.* &&
2447 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
73c04bcf 2448 exit $exit_status
729e4ab9 2449' 0
73c04bcf 2450for ac_signal in 1 2 13 15; do
729e4ab9 2451 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
73c04bcf
A
2452done
2453ac_signal=0
2454
2455# confdefs.h avoids OS command line length limits that DEFS can exceed.
729e4ab9
A
2456rm -f -r conftest* confdefs.h
2457
2458$as_echo "/* confdefs.h */" > confdefs.h
73c04bcf
A
2459
2460# Predefined preprocessor variables.
2461
2462cat >>confdefs.h <<_ACEOF
2463#define PACKAGE_NAME "$PACKAGE_NAME"
2464_ACEOF
2465
73c04bcf
A
2466cat >>confdefs.h <<_ACEOF
2467#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2468_ACEOF
2469
729e4ab9
A
2470cat >>confdefs.h <<_ACEOF
2471#define PACKAGE_VERSION "$PACKAGE_VERSION"
2472_ACEOF
73c04bcf 2473
729e4ab9
A
2474cat >>confdefs.h <<_ACEOF
2475#define PACKAGE_STRING "$PACKAGE_STRING"
2476_ACEOF
73c04bcf 2477
729e4ab9
A
2478cat >>confdefs.h <<_ACEOF
2479#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2480_ACEOF
73c04bcf 2481
729e4ab9
A
2482cat >>confdefs.h <<_ACEOF
2483#define PACKAGE_URL "$PACKAGE_URL"
2484_ACEOF
73c04bcf 2485
73c04bcf 2486
729e4ab9
A
2487# Let the site file select an alternate cache file if it wants to.
2488# Prefer an explicitly selected file to automatically selected ones.
2489ac_site_file1=NONE
2490ac_site_file2=NONE
2491if test -n "$CONFIG_SITE"; then
2492 # We do not want a PATH search for config.site.
2493 case $CONFIG_SITE in #((
2494 -*) ac_site_file1=./$CONFIG_SITE;;
2495 */*) ac_site_file1=$CONFIG_SITE;;
2496 *) ac_site_file1=./$CONFIG_SITE;;
2497 esac
2498elif test "x$prefix" != xNONE; then
2499 ac_site_file1=$prefix/share/config.site
2500 ac_site_file2=$prefix/etc/config.site
b75a7d8f 2501else
729e4ab9
A
2502 ac_site_file1=$ac_default_prefix/share/config.site
2503 ac_site_file2=$ac_default_prefix/etc/config.site
2504fi
2505for ac_site_file in "$ac_site_file1" "$ac_site_file2"
73c04bcf 2506do
729e4ab9
A
2507 test "x$ac_site_file" = xNONE && continue
2508 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2509 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2510$as_echo "$as_me: loading site script $ac_site_file" >&6;}
2511 sed 's/^/| /' "$ac_site_file" >&5
2512 . "$ac_site_file" \
2513 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2514$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2515as_fn_error $? "failed to load site script $ac_site_file
2516See \`config.log' for more details" "$LINENO" 5; }
73c04bcf
A
2517 fi
2518done
73c04bcf 2519
729e4ab9
A
2520if test -r "$cache_file"; then
2521 # Some versions of bash will fail to source /dev/null (special files
2522 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2523 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2524 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2525$as_echo "$as_me: loading cache $cache_file" >&6;}
2526 case $cache_file in
2527 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2528 *) . "./$cache_file";;
2529 esac
b75a7d8f 2530 fi
b75a7d8f 2531else
729e4ab9
A
2532 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2533$as_echo "$as_me: creating cache $cache_file" >&6;}
2534 >$cache_file
b75a7d8f
A
2535fi
2536
729e4ab9
A
2537# Check that the precious variables saved in the cache have kept the same
2538# value.
2539ac_cache_corrupted=false
2540for ac_var in $ac_precious_vars; do
2541 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2542 eval ac_new_set=\$ac_env_${ac_var}_set
2543 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2544 eval ac_new_val=\$ac_env_${ac_var}_value
2545 case $ac_old_set,$ac_new_set in
2546 set,)
2547 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2548$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2549 ac_cache_corrupted=: ;;
2550 ,set)
2551 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2552$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2553 ac_cache_corrupted=: ;;
2554 ,);;
2555 *)
2556 if test "x$ac_old_val" != "x$ac_new_val"; then
2557 # differences in whitespace do not lead to failure.
2558 ac_old_val_w=`echo x $ac_old_val`
2559 ac_new_val_w=`echo x $ac_new_val`
2560 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2561 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2562$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2563 ac_cache_corrupted=:
2564 else
2565 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2566$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2567 eval $ac_var=\$ac_old_val
2568 fi
2569 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2570$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2571 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2572$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2573 fi;;
2574 esac
2575 # Pass precious variables to config.status.
2576 if test "$ac_new_set" = set; then
2577 case $ac_new_val in
2578 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2579 *) ac_arg=$ac_var=$ac_new_val ;;
2580 esac
2581 case " $ac_configure_args " in
2582 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2583 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2584 esac
73c04bcf
A
2585 fi
2586done
729e4ab9
A
2587if $ac_cache_corrupted; then
2588 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2589$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2590 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2591$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2592 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
b75a7d8f 2593fi
729e4ab9
A
2594## -------------------- ##
2595## Main body of script. ##
2596## -------------------- ##
73c04bcf 2597
729e4ab9
A
2598ac_ext=c
2599ac_cpp='$CPP $CPPFLAGS'
2600ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2601ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2602ac_compiler_gnu=$ac_cv_c_compiler_gnu
73c04bcf 2603
73c04bcf 2604
b75a7d8f 2605
3d1f044b
A
2606# Instruct Python to never write any byte code to the ICU source tree.
2607PYTHONDONTWRITEBYTECODE=1
2608export PYTHONDONTWRITEBYTECODE
2609
4388f060 2610
73c04bcf 2611
73c04bcf 2612
729e4ab9 2613PACKAGE="icu"
73c04bcf 2614
73c04bcf 2615
729e4ab9
A
2616# Use custom echo test for newline option
2617# Current autoconf (2.65) gives incorrect echo newline option
2618# for icu-config
2619# This may be removed later - mow (June 17, 2010)
2620ICU_ECHO_C= ICU_ECHO_N= ICU_ECHO_T=
2621case `/bin/sh -c "echo -n x"` in
2622-n*)
2623 case `/bin/sh -c "echo 'x\c'"` in
2624 *c*) ICU_ECHO_T=' ';; # ECHO_T is single tab character.
2625 *) ICU_ECHO_C='\c';;
2626 esac;;
2627*)
2628 ICU_ECHO_N='-n';;
2629esac
73c04bcf 2630
73c04bcf 2631
b75a7d8f 2632
73c04bcf 2633
729e4ab9
A
2634{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICU version numbers" >&5
2635$as_echo_n "checking for ICU version numbers... " >&6; }
73c04bcf 2636
729e4ab9
A
2637# Get the ICU version from uversion.h or other headers
2638geticuversion() {
2639 sed -n 's/^[ ]*#[ ]*define[ ]*U_ICU_VERSION[ ]*"\([^"]*\)".*/\1/p' "$@"
2640}
2641getuversion() {
2642 sed -n 's/^[ ]*#[ ]*define[ ]*U_UNICODE_VERSION[ ]*"\([^"]*\)".*/\1/p' "$@"
2643}
2644VERSION=`geticuversion $srcdir/common/unicode/uvernum.h`
2645if test x"$VERSION" = x; then
4388f060 2646 as_fn_error $? "Cannot determine ICU version number from uvernum.h header file" "$LINENO" 5
729e4ab9 2647fi
73c04bcf 2648
4388f060
A
2649#TODO: IcuBug:8502
2650#if test "$VERSION" != "$PACKAGE_VERSION"; then
2651# AC_MSG_ERROR([configure was generated for $PACKAGE_VERSION but uvernum.h has $VERSION - please rerun autoconf])
2652#fi
2653
729e4ab9
A
2654UNICODE_VERSION=`getuversion $srcdir/common/unicode/uchar.h`
2655if test x"$UNICODE_VERSION" = x; then
4388f060 2656 as_fn_error $? "Cannot determine Unicode version number from uchar.h header file" "$LINENO" 5
b75a7d8f 2657fi
729e4ab9
A
2658# Compute a reasonable library version from the release version. This is
2659# very bad, but that's wanted... We want to make sure that the LIB_VERSION
2660# has at least a dot in it, so we'll add a .0 if needed.
4388f060
A
2661#[LIB_VERSION=`echo $VERSION | sed -e 's/\.//' -e 's/^\([^.]*\)$/\1.0/'`]
2662LIB_VERSION=$VERSION
729e4ab9 2663LIB_VERSION_MAJOR=`echo $LIB_VERSION | sed 's/\..*//'`
73c04bcf 2664
729e4ab9
A
2665
2666
2667{ $as_echo "$as_me:${as_lineno-$LINENO}: result: release $VERSION, library $LIB_VERSION, unicode version $UNICODE_VERSION" >&5
2668$as_echo "release $VERSION, library $LIB_VERSION, unicode version $UNICODE_VERSION" >&6; }
2669
2670
2671
2672# Determine the host system
2673ac_aux_dir=
2674for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
2675 if test -f "$ac_dir/install-sh"; then
2676 ac_aux_dir=$ac_dir
2677 ac_install_sh="$ac_aux_dir/install-sh -c"
2678 break
2679 elif test -f "$ac_dir/install.sh"; then
2680 ac_aux_dir=$ac_dir
2681 ac_install_sh="$ac_aux_dir/install.sh -c"
2682 break
2683 elif test -f "$ac_dir/shtool"; then
2684 ac_aux_dir=$ac_dir
2685 ac_install_sh="$ac_aux_dir/shtool install -c"
2686 break
2687 fi
73c04bcf 2688done
729e4ab9
A
2689if test -z "$ac_aux_dir"; then
2690 as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
b75a7d8f
A
2691fi
2692
729e4ab9
A
2693# These three variables are undocumented and unsupported,
2694# and are intended to be withdrawn in a future Autoconf release.
2695# They can cause serious problems if a builder's source tree is in a directory
2696# whose full name contains unusual characters.
2697ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
2698ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
2699ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
73c04bcf 2700
73c04bcf 2701
729e4ab9
A
2702# Make sure we can run config.sub.
2703$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2704 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
2705
2706{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
2707$as_echo_n "checking build system type... " >&6; }
4388f060 2708if ${ac_cv_build+:} false; then :
729e4ab9
A
2709 $as_echo_n "(cached) " >&6
2710else
2711 ac_build_alias=$build_alias
2712test "x$ac_build_alias" = x &&
2713 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2714test "x$ac_build_alias" = x &&
2715 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
2716ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2717 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
2718
2719fi
2720{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
2721$as_echo "$ac_cv_build" >&6; }
2722case $ac_cv_build in
2723*-*-*) ;;
2724*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
2725esac
2726build=$ac_cv_build
2727ac_save_IFS=$IFS; IFS='-'
2728set x $ac_cv_build
2729shift
2730build_cpu=$1
2731build_vendor=$2
2732shift; shift
2733# Remember, the first character of IFS is used to create $*,
2734# except with old shells:
2735build_os=$*
2736IFS=$ac_save_IFS
2737case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
b75a7d8f 2738
73c04bcf 2739
729e4ab9
A
2740{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
2741$as_echo_n "checking host system type... " >&6; }
4388f060 2742if ${ac_cv_host+:} false; then :
729e4ab9
A
2743 $as_echo_n "(cached) " >&6
2744else
2745 if test "x$host_alias" = x; then
2746 ac_cv_host=$ac_cv_build
2747else
2748 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2749 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
b75a7d8f
A
2750fi
2751
73c04bcf 2752fi
729e4ab9
A
2753{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
2754$as_echo "$ac_cv_host" >&6; }
2755case $ac_cv_host in
2756*-*-*) ;;
2757*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
2758esac
2759host=$ac_cv_host
2760ac_save_IFS=$IFS; IFS='-'
2761set x $ac_cv_host
2762shift
2763host_cpu=$1
2764host_vendor=$2
2765shift; shift
2766# Remember, the first character of IFS is used to create $*,
2767# except with old shells:
2768host_os=$*
2769IFS=$ac_save_IFS
2770case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
73c04bcf 2771
73c04bcf 2772
b75a7d8f 2773
73c04bcf 2774
b75a7d8f 2775
729e4ab9
A
2776# This variable is needed on z/OS because the C++ compiler only recognizes .C
2777_CXX_CXXSUFFIX=cpp
2778export _CXX_CXXSUFFIX
b75a7d8f 2779
4388f060 2780# Accumulate #defines
57a6839d
A
2781
2782# CONFIG_CPPFLAGS: These are defines that are set for ICU Build time only.
2783# They are only needed for building ICU itself. Example: platform stuff
4388f060 2784CONFIG_CPPFLAGS=""
57a6839d
A
2785# UCONFIG_CPPFLAGS: These are defines which are set for ICU build time,
2786# and also a notice is output that they need to be set
2787# for end-users of ICU also. uconfig.h.prepend is generated
2788# with, for example, "#define U_DISABLE_RENAMING 1"
2789# Example: ICU configuration stuff
4388f060 2790UCONFIG_CPPFLAGS=""
57a6839d
A
2791# UCONFIG_CFLAGS: contains a copy of anything that needs to be set by end users
2792# such as -std
2793UCONFIG_CFLAGS=""
4388f060 2794
3d1f044b
A
2795# Check whether to install icu-config
2796# Check whether --enable-icu-config was given.
2797if test "${enable_icu_config+set}" = set; then :
2798 enableval=$enable_icu_config; case "${enableval}" in
2799 yes) enable_icu_config=true ;;
2800 no) enable_icu_config=false ;;
2801 *) as_fn_error $? "bad value '${enableval}' for --enable-icu-config" "$LINENO" 5 ;;
2802 esac
2803else
2804 enable_icu_config=true
2805fi
2806
2807INSTALL_ICU_CONFIG=$enable_icu_config
2808
2809
729e4ab9
A
2810# Check whether to build debug libraries
2811{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build debug libraries" >&5
2812$as_echo_n "checking whether to build debug libraries... " >&6; }
2813enabled=no
2814ENABLE_DEBUG=0
2815# Check whether --enable-debug was given.
2816if test "${enable_debug+set}" = set; then :
2817 enableval=$enable_debug; case "${enableval}" in
4388f060 2818 yes|"") enabled=yes; ENABLE_DEBUG=1; CONFIG_CPPFLAGS="$CONFIG_CPPFLAGS -DU_DEBUG=1" ;;
729e4ab9
A
2819 *) ;;
2820 esac
73c04bcf 2821fi
b75a7d8f 2822
729e4ab9
A
2823{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enabled" >&5
2824$as_echo "$enabled" >&6; }
b75a7d8f 2825
73c04bcf 2826
729e4ab9
A
2827# Check whether to build release libraries
2828{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build release libraries" >&5
2829$as_echo_n "checking whether to build release libraries... " >&6; }
2830enabled=yes
2831ENABLE_RELEASE=1
2832# Check whether --enable-release was given.
2833if test "${enable_release+set}" = set; then :
2834 enableval=$enable_release; case "${enableval}" in
2835 no) enabled=no; ENABLE_RELEASE=0 ;;
2836 *) ;;
2837 esac
73c04bcf 2838fi
73c04bcf 2839
729e4ab9
A
2840{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enabled" >&5
2841$as_echo "$enabled" >&6; }
73c04bcf 2842
73c04bcf 2843
729e4ab9
A
2844# Don't use the default C/CXXFLags
2845: ${CFLAGS=""}
2846: ${CXXFLAGS=""}
2847
51004dcb 2848# Checks for compilers
b75a7d8f 2849ac_ext=c
b75a7d8f 2850ac_cpp='$CPP $CPPFLAGS'
73c04bcf
A
2851ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2852ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2853ac_compiler_gnu=$ac_cv_c_compiler_gnu
73c04bcf 2854if test -n "$ac_tool_prefix"; then
51004dcb 2855 for ac_prog in clang gcc cc c99 c89 xlc_r xlc cl.exe icc
729e4ab9
A
2856 do
2857 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2858set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2859{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2860$as_echo_n "checking for $ac_word... " >&6; }
4388f060 2861if ${ac_cv_prog_CC+:} false; then :
729e4ab9 2862 $as_echo_n "(cached) " >&6
b75a7d8f 2863else
729e4ab9
A
2864 if test -n "$CC"; then
2865 ac_cv_prog_CC="$CC" # Let the user override the test.
2866else
2867as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
73c04bcf
A
2868for as_dir in $PATH
2869do
2870 IFS=$as_save_IFS
2871 test -z "$as_dir" && as_dir=.
729e4ab9 2872 for ac_exec_ext in '' $ac_executable_extensions; do
b331163b 2873 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
729e4ab9
A
2874 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2875 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
73c04bcf
A
2876 break 2
2877 fi
2878done
729e4ab9
A
2879 done
2880IFS=$as_save_IFS
73c04bcf 2881
b75a7d8f 2882fi
729e4ab9
A
2883fi
2884CC=$ac_cv_prog_CC
2885if test -n "$CC"; then
2886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2887$as_echo "$CC" >&6; }
b75a7d8f 2888else
729e4ab9
A
2889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2890$as_echo "no" >&6; }
b75a7d8f
A
2891fi
2892
b75a7d8f 2893
729e4ab9
A
2894 test -n "$CC" && break
2895 done
2896fi
2897if test -z "$CC"; then
2898 ac_ct_CC=$CC
51004dcb 2899 for ac_prog in clang gcc cc c99 c89 xlc_r xlc cl.exe icc
729e4ab9
A
2900do
2901 # Extract the first word of "$ac_prog", so it can be a program name with args.
2902set dummy $ac_prog; ac_word=$2
2903{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2904$as_echo_n "checking for $ac_word... " >&6; }
4388f060 2905if ${ac_cv_prog_ac_ct_CC+:} false; then :
729e4ab9 2906 $as_echo_n "(cached) " >&6
b75a7d8f 2907else
729e4ab9
A
2908 if test -n "$ac_ct_CC"; then
2909 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2910else
2911as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2912for as_dir in $PATH
73c04bcf
A
2913do
2914 IFS=$as_save_IFS
2915 test -z "$as_dir" && as_dir=.
729e4ab9 2916 for ac_exec_ext in '' $ac_executable_extensions; do
b331163b 2917 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
729e4ab9
A
2918 ac_cv_prog_ac_ct_CC="$ac_prog"
2919 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
73c04bcf
A
2920 break 2
2921 fi
2922done
729e4ab9
A
2923 done
2924IFS=$as_save_IFS
73c04bcf 2925
b75a7d8f 2926fi
729e4ab9
A
2927fi
2928ac_ct_CC=$ac_cv_prog_ac_ct_CC
2929if test -n "$ac_ct_CC"; then
2930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2931$as_echo "$ac_ct_CC" >&6; }
b75a7d8f 2932else
729e4ab9
A
2933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2934$as_echo "no" >&6; }
b75a7d8f
A
2935fi
2936
2937
729e4ab9
A
2938 test -n "$ac_ct_CC" && break
2939done
b75a7d8f 2940
729e4ab9
A
2941 if test "x$ac_ct_CC" = x; then
2942 CC=""
2943 else
2944 case $cross_compiling:$ac_tool_warned in
2945yes:)
2946{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2947$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2948ac_tool_warned=yes ;;
73c04bcf 2949esac
729e4ab9
A
2950 CC=$ac_ct_CC
2951 fi
73c04bcf 2952fi
73c04bcf 2953
73c04bcf 2954
729e4ab9
A
2955test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2956$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2957as_fn_error $? "no acceptable C compiler found in \$PATH
2958See \`config.log' for more details" "$LINENO" 5; }
73c04bcf 2959
729e4ab9
A
2960# Provide some information about the compiler.
2961$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
2962set X $ac_compile
2963ac_compiler=$2
2964for ac_option in --version -v -V -qversion; do
2965 { { ac_try="$ac_compiler $ac_option >&5"
2966case "(($ac_try" in
2967 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2968 *) ac_try_echo=$ac_try;;
2969esac
2970eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2971$as_echo "$ac_try_echo"; } >&5
2972 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
73c04bcf 2973 ac_status=$?
729e4ab9
A
2974 if test -s conftest.err; then
2975 sed '10a\
2976... rest of stderr output deleted ...
2977 10q' conftest.err >conftest.er1
2978 cat conftest.er1 >&5
2979 fi
2980 rm -f conftest.er1 conftest.err
2981 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2982 test $ac_status = 0; }
2983done
73c04bcf 2984
729e4ab9 2985cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 2986/* end confdefs.h. */
729e4ab9
A
2987
2988int
2989main ()
2990{
2991
2992 ;
2993 return 0;
2994}
73c04bcf 2995_ACEOF
729e4ab9
A
2996ac_clean_files_save=$ac_clean_files
2997ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
2998# Try to create an executable without -o first, disregard a.out.
2999# It will help us diagnose broken compilers, and finding out an intuition
3000# of exeext.
3001{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3002$as_echo_n "checking whether the C compiler works... " >&6; }
3003ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
73c04bcf 3004
729e4ab9
A
3005# The possible output files:
3006ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
b75a7d8f 3007
729e4ab9
A
3008ac_rmfiles=
3009for ac_file in $ac_files
3010do
3011 case $ac_file in
3012 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3013 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3014 esac
3015done
3016rm -f $ac_rmfiles
b75a7d8f 3017
729e4ab9
A
3018if { { ac_try="$ac_link_default"
3019case "(($ac_try" in
3020 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3021 *) ac_try_echo=$ac_try;;
3022esac
3023eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3024$as_echo "$ac_try_echo"; } >&5
3025 (eval "$ac_link_default") 2>&5
3026 ac_status=$?
3027 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3028 test $ac_status = 0; }; then :
3029 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3030# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3031# in a Makefile. We should not override ac_cv_exeext if it was cached,
3032# so that the user can short-circuit this test for compilers unknown to
3033# Autoconf.
3034for ac_file in $ac_files ''
3035do
3036 test -f "$ac_file" || continue
3037 case $ac_file in
3038 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3039 ;;
3040 [ab].out )
3041 # We found the default executable, but exeext='' is most
3042 # certainly right.
3043 break;;
3044 *.* )
3045 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3046 then :; else
3047 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3048 fi
3049 # We set ac_cv_exeext here because the later test for it is not
3050 # safe: cross compilers may not add the suffix if given an `-o'
3051 # argument, so we may need to know it at that point already.
3052 # Even if this section looks crufty: it has the advantage of
3053 # actually working.
3054 break;;
3055 * )
3056 break;;
3057 esac
3058done
3059test "$ac_cv_exeext" = no && ac_cv_exeext=
b75a7d8f 3060
729e4ab9
A
3061else
3062 ac_file=''
3063fi
3064if test -z "$ac_file"; then :
3065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3066$as_echo "no" >&6; }
3067$as_echo "$as_me: failed program was:" >&5
3068sed 's/^/| /' conftest.$ac_ext >&5
b75a7d8f 3069
729e4ab9
A
3070{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3071$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3072as_fn_error 77 "C compiler cannot create executables
3073See \`config.log' for more details" "$LINENO" 5; }
3074else
3075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3076$as_echo "yes" >&6; }
3077fi
3078{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3079$as_echo_n "checking for C compiler default output file name... " >&6; }
3080{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3081$as_echo "$ac_file" >&6; }
3082ac_exeext=$ac_cv_exeext
b75a7d8f 3083
729e4ab9
A
3084rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3085ac_clean_files=$ac_clean_files_save
3086{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3087$as_echo_n "checking for suffix of executables... " >&6; }
3088if { { ac_try="$ac_link"
3089case "(($ac_try" in
3090 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3091 *) ac_try_echo=$ac_try;;
3092esac
3093eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3094$as_echo "$ac_try_echo"; } >&5
3095 (eval "$ac_link") 2>&5
3096 ac_status=$?
3097 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3098 test $ac_status = 0; }; then :
3099 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3100# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3101# work properly (i.e., refer to `conftest.exe'), while it won't with
3102# `rm'.
3103for ac_file in conftest.exe conftest conftest.*; do
3104 test -f "$ac_file" || continue
3105 case $ac_file in
3106 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3107 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3108 break;;
3109 * ) break;;
3110 esac
3111done
b75a7d8f 3112else
729e4ab9
A
3113 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3114$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3115as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3116See \`config.log' for more details" "$LINENO" 5; }
3117fi
3118rm -f conftest conftest$ac_cv_exeext
3119{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3120$as_echo "$ac_cv_exeext" >&6; }
73c04bcf 3121
729e4ab9
A
3122rm -f conftest.$ac_ext
3123EXEEXT=$ac_cv_exeext
3124ac_exeext=$EXEEXT
3125cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46f4442e 3126/* end confdefs.h. */
729e4ab9 3127#include <stdio.h>
46f4442e
A
3128int
3129main ()
3130{
729e4ab9
A
3131FILE *f = fopen ("conftest.out", "w");
3132 return ferror (f) || fclose (f) != 0;
46f4442e
A
3133
3134 ;
3135 return 0;
3136}
3137_ACEOF
729e4ab9
A
3138ac_clean_files="$ac_clean_files conftest.out"
3139# Check that the compiler produces executables we can run. If not, either
3140# the compiler is broken, or we cross compile.
3141{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3142$as_echo_n "checking whether we are cross compiling... " >&6; }
3143if test "$cross_compiling" != yes; then
3144 { { ac_try="$ac_link"
3145case "(($ac_try" in
3146 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3147 *) ac_try_echo=$ac_try;;
b75a7d8f 3148esac
729e4ab9
A
3149eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3150$as_echo "$ac_try_echo"; } >&5
3151 (eval "$ac_link") 2>&5
3152 ac_status=$?
3153 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3154 test $ac_status = 0; }
3155 if { ac_try='./conftest$ac_cv_exeext'
3156 { { case "(($ac_try" in
3157 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3158 *) ac_try_echo=$ac_try;;
3159esac
3160eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3161$as_echo "$ac_try_echo"; } >&5
3162 (eval "$ac_try") 2>&5
3163 ac_status=$?
3164 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3165 test $ac_status = 0; }; }; then
3166 cross_compiling=no
3167 else
3168 if test "$cross_compiling" = maybe; then
3169 cross_compiling=yes
3170 else
3171 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3172$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3173as_fn_error $? "cannot run C compiled programs.
3174If you meant to cross compile, use \`--host'.
3175See \`config.log' for more details" "$LINENO" 5; }
3176 fi
3177 fi
73c04bcf 3178fi
729e4ab9
A
3179{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3180$as_echo "$cross_compiling" >&6; }
b75a7d8f 3181
729e4ab9
A
3182rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3183ac_clean_files=$ac_clean_files_save
3184{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3185$as_echo_n "checking for suffix of object files... " >&6; }
4388f060 3186if ${ac_cv_objext+:} false; then :
729e4ab9 3187 $as_echo_n "(cached) " >&6
b75a7d8f 3188else
729e4ab9 3189 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf
A
3190/* end confdefs.h. */
3191
73c04bcf
A
3192int
3193main ()
3194{
729e4ab9 3195
73c04bcf
A
3196 ;
3197 return 0;
3198}
3199_ACEOF
729e4ab9
A
3200rm -f conftest.o conftest.obj
3201if { { ac_try="$ac_compile"
3202case "(($ac_try" in
3203 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3204 *) ac_try_echo=$ac_try;;
3205esac
3206eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3207$as_echo "$ac_try_echo"; } >&5
3208 (eval "$ac_compile") 2>&5
3209 ac_status=$?
3210 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3211 test $ac_status = 0; }; then :
3212 for ac_file in conftest.o conftest.obj conftest.*; do
3213 test -f "$ac_file" || continue;
3214 case $ac_file in
3215 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3216 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3217 break;;
3218 esac
3219done
73c04bcf 3220else
729e4ab9 3221 $as_echo "$as_me: failed program was:" >&5
73c04bcf
A
3222sed 's/^/| /' conftest.$ac_ext >&5
3223
729e4ab9
A
3224{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3225$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3226as_fn_error $? "cannot compute suffix of object files: cannot compile
3227See \`config.log' for more details" "$LINENO" 5; }
73c04bcf 3228fi
729e4ab9 3229rm -f conftest.$ac_cv_objext conftest.$ac_ext
b75a7d8f 3230fi
729e4ab9
A
3231{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3232$as_echo "$ac_cv_objext" >&6; }
3233OBJEXT=$ac_cv_objext
3234ac_objext=$OBJEXT
3235{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3236$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4388f060 3237if ${ac_cv_c_compiler_gnu+:} false; then :
729e4ab9 3238 $as_echo_n "(cached) " >&6
73c04bcf 3239else
729e4ab9 3240 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf
A
3241/* end confdefs.h. */
3242
73c04bcf
A
3243int
3244main ()
3245{
729e4ab9
A
3246#ifndef __GNUC__
3247 choke me
3248#endif
3249
73c04bcf
A
3250 ;
3251 return 0;
3252}
3253_ACEOF
729e4ab9
A
3254if ac_fn_c_try_compile "$LINENO"; then :
3255 ac_compiler_gnu=yes
73c04bcf 3256else
729e4ab9 3257 ac_compiler_gnu=no
73c04bcf 3258fi
729e4ab9
A
3259rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3260ac_cv_c_compiler_gnu=$ac_compiler_gnu
b75a7d8f 3261
b75a7d8f 3262fi
729e4ab9
A
3263{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3264$as_echo "$ac_cv_c_compiler_gnu" >&6; }
3265if test $ac_compiler_gnu = yes; then
3266 GCC=yes
b75a7d8f 3267else
729e4ab9 3268 GCC=
374ca955 3269fi
729e4ab9
A
3270ac_test_CFLAGS=${CFLAGS+set}
3271ac_save_CFLAGS=$CFLAGS
3272{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3273$as_echo_n "checking whether $CC accepts -g... " >&6; }
4388f060 3274if ${ac_cv_prog_cc_g+:} false; then :
729e4ab9
A
3275 $as_echo_n "(cached) " >&6
3276else
3277 ac_save_c_werror_flag=$ac_c_werror_flag
3278 ac_c_werror_flag=yes
3279 ac_cv_prog_cc_g=no
3280 CFLAGS="-g"
3281 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3282/* end confdefs.h. */
374ca955 3283
729e4ab9
A
3284int
3285main ()
3286{
374ca955 3287
729e4ab9
A
3288 ;
3289 return 0;
3290}
46f4442e 3291_ACEOF
729e4ab9
A
3292if ac_fn_c_try_compile "$LINENO"; then :
3293 ac_cv_prog_cc_g=yes
3294else
3295 CFLAGS=""
3296 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46f4442e 3297/* end confdefs.h. */
729e4ab9 3298
46f4442e
A
3299int
3300main ()
3301{
729e4ab9 3302
46f4442e
A
3303 ;
3304 return 0;
3305}
3306_ACEOF
729e4ab9
A
3307if ac_fn_c_try_compile "$LINENO"; then :
3308
b75a7d8f 3309else
729e4ab9
A
3310 ac_c_werror_flag=$ac_save_c_werror_flag
3311 CFLAGS="-g"
3312 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3313/* end confdefs.h. */
73c04bcf 3314
729e4ab9
A
3315int
3316main ()
3317{
3318
3319 ;
3320 return 0;
3321}
3322_ACEOF
3323if ac_fn_c_try_compile "$LINENO"; then :
3324 ac_cv_prog_cc_g=yes
3325fi
3326rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3327fi
3328rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3329fi
3330rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3331 ac_c_werror_flag=$ac_save_c_werror_flag
3332fi
3333{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3334$as_echo "$ac_cv_prog_cc_g" >&6; }
3335if test "$ac_test_CFLAGS" = set; then
3336 CFLAGS=$ac_save_CFLAGS
3337elif test $ac_cv_prog_cc_g = yes; then
3338 if test "$GCC" = yes; then
3339 CFLAGS="-g -O2"
3340 else
3341 CFLAGS="-g"
3342 fi
3343else
3344 if test "$GCC" = yes; then
3345 CFLAGS="-O2"
3346 else
3347 CFLAGS=
3348 fi
b75a7d8f 3349fi
729e4ab9
A
3350{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3351$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4388f060 3352if ${ac_cv_prog_cc_c89+:} false; then :
729e4ab9 3353 $as_echo_n "(cached) " >&6
73c04bcf 3354else
729e4ab9
A
3355 ac_cv_prog_cc_c89=no
3356ac_save_CC=$CC
3357cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46f4442e 3358/* end confdefs.h. */
729e4ab9
A
3359#include <stdarg.h>
3360#include <stdio.h>
b331163b 3361struct stat;
729e4ab9
A
3362/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3363struct buf { int x; };
3364FILE * (*rcsopen) (struct buf *, struct stat *, int);
3365static char *e (p, i)
3366 char **p;
3367 int i;
3368{
3369 return p[i];
3370}
3371static char *f (char * (*g) (char **, int), char **p, ...)
3372{
3373 char *s;
3374 va_list v;
3375 va_start (v,p);
3376 s = g (p, va_arg (v,int));
3377 va_end (v);
3378 return s;
3379}
3380
3381/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3382 function prototypes and stuff, but not '\xHH' hex character constants.
3383 These don't provoke an error unfortunately, instead are silently treated
3384 as 'x'. The following induces an error, until -std is added to get
3385 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3386 array size at least. It's necessary to write '\x00'==0 to get something
3387 that's true only with -std. */
3388int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3389
3390/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3391 inside strings and character constants. */
3392#define FOO(x) 'x'
3393int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3394
3395int test (int i, double x);
3396struct s1 {int (*f) (int a);};
3397struct s2 {int (*f) (double a);};
3398int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3399int argc;
3400char **argv;
46f4442e
A
3401int
3402main ()
3403{
729e4ab9 3404return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
46f4442e
A
3405 ;
3406 return 0;
3407}
3408_ACEOF
729e4ab9
A
3409for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3410 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3411do
3412 CC="$ac_save_CC $ac_arg"
3413 if ac_fn_c_try_compile "$LINENO"; then :
3414 ac_cv_prog_cc_c89=$ac_arg
46f4442e 3415fi
729e4ab9
A
3416rm -f core conftest.err conftest.$ac_objext
3417 test "x$ac_cv_prog_cc_c89" != "xno" && break
3418done
3419rm -f conftest.$ac_ext
3420CC=$ac_save_CC
46f4442e 3421
729e4ab9
A
3422fi
3423# AC_CACHE_VAL
3424case "x$ac_cv_prog_cc_c89" in
3425 x)
3426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3427$as_echo "none needed" >&6; } ;;
3428 xno)
3429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3430$as_echo "unsupported" >&6; } ;;
3431 *)
3432 CC="$CC $ac_cv_prog_cc_c89"
3433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3434$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3435esac
3436if test "x$ac_cv_prog_cc_c89" != xno; then :
46f4442e 3437
729e4ab9 3438fi
46f4442e 3439
729e4ab9
A
3440ac_ext=c
3441ac_cpp='$CPP $CPPFLAGS'
3442ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3443ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3444ac_compiler_gnu=$ac_cv_c_compiler_gnu
46f4442e 3445
51004dcb
A
3446# Make sure that we try clang++ first, which provides C++11 support.
3447# The g++ compiler is less likely to support C++11.
729e4ab9
A
3448ac_ext=cpp
3449ac_cpp='$CXXCPP $CPPFLAGS'
3450ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3451ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3452ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
3453if test -z "$CXX"; then
3454 if test -n "$CCC"; then
3455 CXX=$CCC
3456 else
3457 if test -n "$ac_tool_prefix"; then
51004dcb 3458 for ac_prog in clang++ g++ c++ gpp xlC_r xlC aCC CC cxx cc++ cl.exe icc FCC KCC RCC
729e4ab9
A
3459 do
3460 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3461set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3462{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3463$as_echo_n "checking for $ac_word... " >&6; }
4388f060 3464if ${ac_cv_prog_CXX+:} false; then :
729e4ab9 3465 $as_echo_n "(cached) " >&6
46f4442e 3466else
729e4ab9
A
3467 if test -n "$CXX"; then
3468 ac_cv_prog_CXX="$CXX" # Let the user override the test.
46f4442e
A
3469else
3470as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3471for as_dir in $PATH
3472do
3473 IFS=$as_save_IFS
3474 test -z "$as_dir" && as_dir=.
729e4ab9 3475 for ac_exec_ext in '' $ac_executable_extensions; do
b331163b 3476 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
729e4ab9
A
3477 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
3478 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
46f4442e
A
3479 break 2
3480 fi
3481done
729e4ab9
A
3482 done
3483IFS=$as_save_IFS
46f4442e
A
3484
3485fi
3486fi
729e4ab9
A
3487CXX=$ac_cv_prog_CXX
3488if test -n "$CXX"; then
3489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
3490$as_echo "$CXX" >&6; }
46f4442e 3491else
729e4ab9
A
3492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3493$as_echo "no" >&6; }
46f4442e
A
3494fi
3495
729e4ab9
A
3496
3497 test -n "$CXX" && break
3498 done
46f4442e 3499fi
729e4ab9
A
3500if test -z "$CXX"; then
3501 ac_ct_CXX=$CXX
51004dcb 3502 for ac_prog in clang++ g++ c++ gpp xlC_r xlC aCC CC cxx cc++ cl.exe icc FCC KCC RCC
729e4ab9
A
3503do
3504 # Extract the first word of "$ac_prog", so it can be a program name with args.
3505set dummy $ac_prog; ac_word=$2
3506{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3507$as_echo_n "checking for $ac_word... " >&6; }
4388f060 3508if ${ac_cv_prog_ac_ct_CXX+:} false; then :
729e4ab9 3509 $as_echo_n "(cached) " >&6
b75a7d8f 3510else
729e4ab9
A
3511 if test -n "$ac_ct_CXX"; then
3512 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
73c04bcf
A
3513else
3514as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3515for as_dir in $PATH
3516do
3517 IFS=$as_save_IFS
3518 test -z "$as_dir" && as_dir=.
729e4ab9 3519 for ac_exec_ext in '' $ac_executable_extensions; do
b331163b 3520 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
729e4ab9
A
3521 ac_cv_prog_ac_ct_CXX="$ac_prog"
3522 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
73c04bcf
A
3523 break 2
3524 fi
3525done
729e4ab9
A
3526 done
3527IFS=$as_save_IFS
73c04bcf 3528
73c04bcf
A
3529fi
3530fi
729e4ab9
A
3531ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
3532if test -n "$ac_ct_CXX"; then
3533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
3534$as_echo "$ac_ct_CXX" >&6; }
73c04bcf 3535else
729e4ab9
A
3536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3537$as_echo "no" >&6; }
73c04bcf
A
3538fi
3539
b75a7d8f 3540
729e4ab9 3541 test -n "$ac_ct_CXX" && break
73c04bcf
A
3542done
3543
729e4ab9
A
3544 if test "x$ac_ct_CXX" = x; then
3545 CXX="g++"
3546 else
3547 case $cross_compiling:$ac_tool_warned in
3548yes:)
3549{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3550$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3551ac_tool_warned=yes ;;
b75a7d8f 3552esac
729e4ab9
A
3553 CXX=$ac_ct_CXX
3554 fi
b75a7d8f 3555fi
73c04bcf 3556
729e4ab9 3557 fi
b75a7d8f 3558fi
729e4ab9
A
3559# Provide some information about the compiler.
3560$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
3561set X $ac_compile
3562ac_compiler=$2
3563for ac_option in --version -v -V -qversion; do
3564 { { ac_try="$ac_compiler $ac_option >&5"
3565case "(($ac_try" in
3566 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3567 *) ac_try_echo=$ac_try;;
3568esac
3569eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3570$as_echo "$ac_try_echo"; } >&5
3571 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3572 ac_status=$?
3573 if test -s conftest.err; then
3574 sed '10a\
3575... rest of stderr output deleted ...
3576 10q' conftest.err >conftest.er1
3577 cat conftest.er1 >&5
3578 fi
3579 rm -f conftest.er1 conftest.err
3580 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3581 test $ac_status = 0; }
3582done
b75a7d8f 3583
729e4ab9
A
3584{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
3585$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
4388f060 3586if ${ac_cv_cxx_compiler_gnu+:} false; then :
729e4ab9 3587 $as_echo_n "(cached) " >&6
b75a7d8f 3588else
729e4ab9 3589 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf
A
3590/* end confdefs.h. */
3591
3592int
3593main ()
3594{
729e4ab9
A
3595#ifndef __GNUC__
3596 choke me
3597#endif
3598
73c04bcf
A
3599 ;
3600 return 0;
3601}
3602_ACEOF
729e4ab9
A
3603if ac_fn_cxx_try_compile "$LINENO"; then :
3604 ac_compiler_gnu=yes
b75a7d8f 3605else
729e4ab9 3606 ac_compiler_gnu=no
b75a7d8f 3607fi
729e4ab9
A
3608rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3609ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
b75a7d8f 3610
73c04bcf 3611fi
729e4ab9
A
3612{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
3613$as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
3614if test $ac_compiler_gnu = yes; then
3615 GXX=yes
b75a7d8f 3616else
729e4ab9 3617 GXX=
b75a7d8f 3618fi
729e4ab9
A
3619ac_test_CXXFLAGS=${CXXFLAGS+set}
3620ac_save_CXXFLAGS=$CXXFLAGS
3621{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
3622$as_echo_n "checking whether $CXX accepts -g... " >&6; }
4388f060 3623if ${ac_cv_prog_cxx_g+:} false; then :
729e4ab9
A
3624 $as_echo_n "(cached) " >&6
3625else
3626 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
3627 ac_cxx_werror_flag=yes
3628 ac_cv_prog_cxx_g=no
3629 CXXFLAGS="-g"
3630 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3631/* end confdefs.h. */
3632
73c04bcf
A
3633int
3634main ()
3635{
729e4ab9 3636
73c04bcf
A
3637 ;
3638 return 0;
3639}
3640_ACEOF
729e4ab9
A
3641if ac_fn_cxx_try_compile "$LINENO"; then :
3642 ac_cv_prog_cxx_g=yes
b75a7d8f 3643else
729e4ab9
A
3644 CXXFLAGS=""
3645 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf
A
3646/* end confdefs.h. */
3647
73c04bcf
A
3648int
3649main ()
3650{
729e4ab9 3651
73c04bcf
A
3652 ;
3653 return 0;
3654}
3655_ACEOF
729e4ab9 3656if ac_fn_cxx_try_compile "$LINENO"; then :
73c04bcf 3657
729e4ab9
A
3658else
3659 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
3660 CXXFLAGS="-g"
3661 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf
A
3662/* end confdefs.h. */
3663
73c04bcf
A
3664int
3665main ()
3666{
729e4ab9 3667
73c04bcf
A
3668 ;
3669 return 0;
3670}
3671_ACEOF
729e4ab9
A
3672if ac_fn_cxx_try_compile "$LINENO"; then :
3673 ac_cv_prog_cxx_g=yes
3674fi
3675rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3676fi
3677rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3678fi
3679rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3680 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
3681fi
3682{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
3683$as_echo "$ac_cv_prog_cxx_g" >&6; }
3684if test "$ac_test_CXXFLAGS" = set; then
3685 CXXFLAGS=$ac_save_CXXFLAGS
3686elif test $ac_cv_prog_cxx_g = yes; then
3687 if test "$GXX" = yes; then
3688 CXXFLAGS="-g -O2"
3689 else
3690 CXXFLAGS="-g"
3691 fi
b75a7d8f 3692else
729e4ab9
A
3693 if test "$GXX" = yes; then
3694 CXXFLAGS="-O2"
3695 else
3696 CXXFLAGS=
3697 fi
3698fi
3699ac_ext=c
3700ac_cpp='$CPP $CPPFLAGS'
3701ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3702ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3703ac_compiler_gnu=$ac_cv_c_compiler_gnu
73c04bcf 3704
729e4ab9 3705
b331163b
A
3706# pkg-config is needed for harfbuzz support
3707
3708
2ca993e8
A
3709
3710
3711
3712
3713
b331163b
A
3714if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
3715 if test -n "$ac_tool_prefix"; then
3716 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
3717set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
3718{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3719$as_echo_n "checking for $ac_word... " >&6; }
3720if ${ac_cv_path_PKG_CONFIG+:} false; then :
3721 $as_echo_n "(cached) " >&6
3722else
3723 case $PKG_CONFIG in
3724 [\\/]* | ?:[\\/]*)
3725 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
3726 ;;
3727 *)
3728 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3729for as_dir in $PATH
3730do
3731 IFS=$as_save_IFS
3732 test -z "$as_dir" && as_dir=.
3733 for ac_exec_ext in '' $ac_executable_extensions; do
3734 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3735 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
3736 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3737 break 2
3738 fi
3739done
3740 done
3741IFS=$as_save_IFS
3742
3743 ;;
3744esac
3745fi
3746PKG_CONFIG=$ac_cv_path_PKG_CONFIG
3747if test -n "$PKG_CONFIG"; then
3748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
3749$as_echo "$PKG_CONFIG" >&6; }
3750else
3751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3752$as_echo "no" >&6; }
3753fi
3754
3755
3756fi
3757if test -z "$ac_cv_path_PKG_CONFIG"; then
3758 ac_pt_PKG_CONFIG=$PKG_CONFIG
3759 # Extract the first word of "pkg-config", so it can be a program name with args.
3760set dummy pkg-config; ac_word=$2
3761{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3762$as_echo_n "checking for $ac_word... " >&6; }
3763if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
3764 $as_echo_n "(cached) " >&6
3765else
3766 case $ac_pt_PKG_CONFIG in
3767 [\\/]* | ?:[\\/]*)
3768 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
3769 ;;
3770 *)
3771 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3772for as_dir in $PATH
3773do
3774 IFS=$as_save_IFS
3775 test -z "$as_dir" && as_dir=.
3776 for ac_exec_ext in '' $ac_executable_extensions; do
3777 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3778 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
3779 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3780 break 2
3781 fi
3782done
3783 done
3784IFS=$as_save_IFS
3785
3786 ;;
3787esac
3788fi
3789ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
3790if test -n "$ac_pt_PKG_CONFIG"; then
3791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
3792$as_echo "$ac_pt_PKG_CONFIG" >&6; }
3793else
3794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3795$as_echo "no" >&6; }
3796fi
3797
3798 if test "x$ac_pt_PKG_CONFIG" = x; then
3799 PKG_CONFIG=""
3800 else
3801 case $cross_compiling:$ac_tool_warned in
3802yes:)
3803{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3804$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3805ac_tool_warned=yes ;;
3806esac
3807 PKG_CONFIG=$ac_pt_PKG_CONFIG
3808 fi
3809else
3810 PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
3811fi
3812
3813fi
3814if test -n "$PKG_CONFIG"; then
3815 _pkg_min_version=0.20
3816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
3817$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
3818 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
3819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3820$as_echo "yes" >&6; }
3821 else
3822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3823$as_echo "no" >&6; }
3824 PKG_CONFIG=""
3825 fi
b331163b
A
3826fi
3827
3828pkg_failed=no
3829{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICULEHB" >&5
3830$as_echo_n "checking for ICULEHB... " >&6; }
3831
3832if test -n "$ICULEHB_CFLAGS"; then
3833 pkg_cv_ICULEHB_CFLAGS="$ICULEHB_CFLAGS"
3834 elif test -n "$PKG_CONFIG"; then
3835 if test -n "$PKG_CONFIG" && \
3836 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"icu-le-hb\""; } >&5
3837 ($PKG_CONFIG --exists --print-errors "icu-le-hb") 2>&5
3838 ac_status=$?
3839 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3840 test $ac_status = 0; }; then
3841 pkg_cv_ICULEHB_CFLAGS=`$PKG_CONFIG --cflags "icu-le-hb" 2>/dev/null`
2ca993e8 3842 test "x$?" != "x0" && pkg_failed=yes
b331163b
A
3843else
3844 pkg_failed=yes
3845fi
3846 else
3847 pkg_failed=untried
3848fi
3849if test -n "$ICULEHB_LIBS"; then
3850 pkg_cv_ICULEHB_LIBS="$ICULEHB_LIBS"
3851 elif test -n "$PKG_CONFIG"; then
3852 if test -n "$PKG_CONFIG" && \
3853 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"icu-le-hb\""; } >&5
3854 ($PKG_CONFIG --exists --print-errors "icu-le-hb") 2>&5
3855 ac_status=$?
3856 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3857 test $ac_status = 0; }; then
3858 pkg_cv_ICULEHB_LIBS=`$PKG_CONFIG --libs "icu-le-hb" 2>/dev/null`
2ca993e8 3859 test "x$?" != "x0" && pkg_failed=yes
b331163b
A
3860else
3861 pkg_failed=yes
3862fi
3863 else
3864 pkg_failed=untried
3865fi
3866
3867
3868
3869if test $pkg_failed = yes; then
2ca993e8
A
3870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3871$as_echo "no" >&6; }
b331163b
A
3872
3873if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
3874 _pkg_short_errors_supported=yes
3875else
3876 _pkg_short_errors_supported=no
3877fi
3878 if test $_pkg_short_errors_supported = yes; then
2ca993e8 3879 ICULEHB_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "icu-le-hb" 2>&1`
b331163b 3880 else
2ca993e8 3881 ICULEHB_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "icu-le-hb" 2>&1`
b331163b
A
3882 fi
3883 # Put the nasty error message in config.log where it belongs
3884 echo "$ICULEHB_PKG_ERRORS" >&5
3885
2ca993e8 3886 :
b331163b 3887elif test $pkg_failed = untried; then
2ca993e8
A
3888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3889$as_echo "no" >&6; }
b331163b
A
3890 :
3891else
3892 ICULEHB_CFLAGS=$pkg_cv_ICULEHB_CFLAGS
3893 ICULEHB_LIBS=$pkg_cv_ICULEHB_LIBS
3894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3895$as_echo "yes" >&6; }
3896 have_icu_le_hb=true
3897fi
3898
729e4ab9
A
3899# Ensure that if CXXFLAGS/CFLAGS were not set when calling configure, set it correctly based on (enable/disable) debug or release option
3900# The release mode use is the default one for autoconf
3901if test "$GCC" = yes; then
3902 if test "$CFLAGS" = ""; then
3903 if test "$ENABLE_DEBUG" = 1; then
3904 CFLAGS=-g
3905 fi
3906 if test "$ENABLE_RELEASE" = 1; then
3907 CFLAGS="$CFLAGS -O2"
3908 fi
3909 fi
3910 if test "$CXXFLAGS" = ""; then
3911 if test "$ENABLE_DEBUG" = 1; then
3912 CXXFLAGS=-g
3913 fi
3914 if test "$ENABLE_RELEASE" = 1; then
3915 CXXFLAGS="$CXXFLAGS -O2"
3916 fi
3917 fi
b75a7d8f 3918fi
729e4ab9
A
3919
3920ac_ext=c
3921ac_cpp='$CPP $CPPFLAGS'
3922ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3923ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3924ac_compiler_gnu=$ac_cv_c_compiler_gnu
3925{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3926$as_echo_n "checking how to run the C preprocessor... " >&6; }
3927# On Suns, sometimes $CPP names a directory.
3928if test -n "$CPP" && test -d "$CPP"; then
3929 CPP=
b75a7d8f 3930fi
729e4ab9 3931if test -z "$CPP"; then
4388f060 3932 if ${ac_cv_prog_CPP+:} false; then :
729e4ab9
A
3933 $as_echo_n "(cached) " >&6
3934else
3935 # Double quotes because CPP needs to be expanded
3936 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3937 do
3938 ac_preproc_ok=false
3939for ac_c_preproc_warn_flag in '' yes
3940do
3941 # Use a header file that comes with gcc, so configuring glibc
3942 # with a fresh cross-compiler works.
3943 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3944 # <limits.h> exists even on freestanding compilers.
3945 # On the NeXT, cc -E runs the code through the compiler's parser,
3946 # not just through cpp. "Syntax error" is here to catch this case.
3947 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3948/* end confdefs.h. */
3949#ifdef __STDC__
3950# include <limits.h>
3951#else
3952# include <assert.h>
3953#endif
3954 Syntax error
3955_ACEOF
3956if ac_fn_c_try_cpp "$LINENO"; then :
3957
3958else
3959 # Broken: fails on valid input.
3960continue
b75a7d8f 3961fi
729e4ab9 3962rm -f conftest.err conftest.i conftest.$ac_ext
73c04bcf 3963
729e4ab9
A
3964 # OK, works on sane cases. Now check whether nonexistent headers
3965 # can be detected and how.
3966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3967/* end confdefs.h. */
3968#include <ac_nonexistent.h>
3969_ACEOF
3970if ac_fn_c_try_cpp "$LINENO"; then :
3971 # Broken: success on invalid input.
3972continue
3973else
3974 # Passes both tests.
3975ac_preproc_ok=:
3976break
3977fi
3978rm -f conftest.err conftest.i conftest.$ac_ext
73c04bcf 3979
729e4ab9
A
3980done
3981# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3982rm -f conftest.i conftest.err conftest.$ac_ext
3983if $ac_preproc_ok; then :
3984 break
b75a7d8f
A
3985fi
3986
729e4ab9
A
3987 done
3988 ac_cv_prog_CPP=$CPP
73c04bcf 3989
729e4ab9
A
3990fi
3991 CPP=$ac_cv_prog_CPP
73c04bcf 3992else
729e4ab9
A
3993 ac_cv_prog_CPP=$CPP
3994fi
3995{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3996$as_echo "$CPP" >&6; }
3997ac_preproc_ok=false
3998for ac_c_preproc_warn_flag in '' yes
3999do
4000 # Use a header file that comes with gcc, so configuring glibc
4001 # with a fresh cross-compiler works.
4002 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4003 # <limits.h> exists even on freestanding compilers.
4004 # On the NeXT, cc -E runs the code through the compiler's parser,
4005 # not just through cpp. "Syntax error" is here to catch this case.
4006 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 4007/* end confdefs.h. */
729e4ab9
A
4008#ifdef __STDC__
4009# include <limits.h>
4010#else
4011# include <assert.h>
73c04bcf 4012#endif
729e4ab9 4013 Syntax error
73c04bcf 4014_ACEOF
729e4ab9
A
4015if ac_fn_c_try_cpp "$LINENO"; then :
4016
73c04bcf 4017else
729e4ab9
A
4018 # Broken: fails on valid input.
4019continue
4020fi
4021rm -f conftest.err conftest.i conftest.$ac_ext
4022
4023 # OK, works on sane cases. Now check whether nonexistent headers
4024 # can be detected and how.
4025 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4026/* end confdefs.h. */
4027#include <ac_nonexistent.h>
4028_ACEOF
4029if ac_fn_c_try_cpp "$LINENO"; then :
4030 # Broken: success on invalid input.
4031continue
4032else
4033 # Passes both tests.
4034ac_preproc_ok=:
4035break
4036fi
4037rm -f conftest.err conftest.i conftest.$ac_ext
4038
4039done
4040# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4041rm -f conftest.i conftest.err conftest.$ac_ext
4042if $ac_preproc_ok; then :
4043
4044else
4045 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4046$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4047as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
4048See \`config.log' for more details" "$LINENO" 5; }
4049fi
4050
4051ac_ext=c
4052ac_cpp='$CPP $CPPFLAGS'
4053ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4054ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4055ac_compiler_gnu=$ac_cv_c_compiler_gnu
4056
4057
4058# Find a good install program. We prefer a C program (faster),
4059# so one script is as good as another. But avoid the broken or
4060# incompatible versions:
4061# SysV /etc/install, /usr/sbin/install
4062# SunOS /usr/etc/install
4063# IRIX /sbin/install
4064# AIX /bin/install
4065# AmigaOS /C/install, which installs bootblocks on floppy discs
4066# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
4067# AFS /usr/afsws/bin/install, which mishandles nonexistent args
4068# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
4069# OS/2's system install, which has a completely different semantic
4070# ./install, which can be erroneously created by make from ./install.sh.
4071# Reject install programs that cannot install multiple files.
4072{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
4073$as_echo_n "checking for a BSD-compatible install... " >&6; }
4074if test -z "$INSTALL"; then
4388f060 4075if ${ac_cv_path_install+:} false; then :
729e4ab9
A
4076 $as_echo_n "(cached) " >&6
4077else
4078 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4079for as_dir in $PATH
4080do
4081 IFS=$as_save_IFS
4082 test -z "$as_dir" && as_dir=.
4083 # Account for people who put trailing slashes in PATH elements.
4084case $as_dir/ in #((
4085 ./ | .// | /[cC]/* | \
4086 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
4087 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
4088 /usr/ucb/* ) ;;
4089 *)
4090 # OSF1 and SCO ODT 3.0 have their own names for install.
4091 # Don't use installbsd from OSF since it installs stuff as root
4092 # by default.
4093 for ac_prog in ginstall scoinst install; do
4094 for ac_exec_ext in '' $ac_executable_extensions; do
b331163b 4095 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
729e4ab9
A
4096 if test $ac_prog = install &&
4097 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4098 # AIX install. It has an incompatible calling convention.
4099 :
4100 elif test $ac_prog = install &&
4101 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4102 # program-specific install script used by HP pwplus--don't use.
4103 :
4104 else
4105 rm -rf conftest.one conftest.two conftest.dir
4106 echo one > conftest.one
4107 echo two > conftest.two
4108 mkdir conftest.dir
4109 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
4110 test -s conftest.one && test -s conftest.two &&
4111 test -s conftest.dir/conftest.one &&
4112 test -s conftest.dir/conftest.two
4113 then
4114 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
4115 break 3
4116 fi
4117 fi
4118 fi
4119 done
4120 done
4121 ;;
4122esac
4123
4124 done
4125IFS=$as_save_IFS
4126
4127rm -rf conftest.one conftest.two conftest.dir
73c04bcf 4128
73c04bcf 4129fi
729e4ab9
A
4130 if test "${ac_cv_path_install+set}" = set; then
4131 INSTALL=$ac_cv_path_install
4132 else
4133 # As a last resort, use the slow shell script. Don't cache a
4134 # value for INSTALL within a source directory, because that will
4135 # break other packages using the cache if that directory is
4136 # removed, or if the value is a relative name.
4137 INSTALL=$ac_install_sh
4138 fi
73c04bcf 4139fi
729e4ab9
A
4140{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
4141$as_echo "$INSTALL" >&6; }
73c04bcf 4142
729e4ab9
A
4143# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
4144# It thinks the first close brace ends the variable substitution.
4145test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
73c04bcf 4146
729e4ab9 4147test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
73c04bcf 4148
729e4ab9 4149test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
73c04bcf 4150
73c04bcf 4151
73c04bcf 4152
73c04bcf 4153
729e4ab9
A
4154ac_ext=cpp
4155ac_cpp='$CXXCPP $CPPFLAGS'
4156ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4157ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4158ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
73c04bcf 4159
729e4ab9
A
4160
4161cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4162/* end confdefs.h. */
73c04bcf
A
4163
4164int
4165main ()
4166{
729e4ab9 4167
73c04bcf
A
4168 ;
4169 return 0;
4170}
4171_ACEOF
729e4ab9 4172if ac_fn_cxx_try_link "$LINENO"; then :
73c04bcf 4173
73c04bcf 4174fi
729e4ab9
A
4175rm -f core conftest.err conftest.$ac_objext \
4176 conftest$ac_exeext conftest.$ac_ext
4177ac_ext=c
4178ac_cpp='$CPP $CPPFLAGS'
4179ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4180ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4181ac_compiler_gnu=$ac_cv_c_compiler_gnu
73c04bcf
A
4182
4183
729e4ab9
A
4184# make sure install is relative to srcdir - if a script
4185if test "$srcdir" = "."; then
4186 # If srcdir isn't just ., then (srcdir) is already prepended.
4187 if test "${ac_install_sh}" = "${INSTALL}"; then
4188 INSTALL="\\\$(top_srcdir)/${ac_install_sh}"
73c04bcf 4189 fi
73c04bcf
A
4190fi
4191
729e4ab9
A
4192#AC_CHECK_PROG(AUTOCONF, autoconf, autoconf, true)
4193#AC_CHECK_PROG(STRIP, strip, strip, true)
73c04bcf 4194
3d1f044b
A
4195# TODO(ICU-20301): Remove fallback to Python 2.
4196for ac_prog in python3 "py -3" python "py"
4197do
4198 # Extract the first word of "$ac_prog", so it can be a program name with args.
4199set dummy $ac_prog; ac_word=$2
4200{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4201$as_echo_n "checking for $ac_word... " >&6; }
4202if ${ac_cv_prog_PYTHON+:} false; then :
4203 $as_echo_n "(cached) " >&6
4204else
4205 if test -n "$PYTHON"; then
4206 ac_cv_prog_PYTHON="$PYTHON" # Let the user override the test.
4207else
4208as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4209for as_dir in $PATH
4210do
4211 IFS=$as_save_IFS
4212 test -z "$as_dir" && as_dir=.
4213 for ac_exec_ext in '' $ac_executable_extensions; do
4214 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4215 ac_cv_prog_PYTHON="$ac_prog"
4216 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4217 break 2
4218 fi
4219done
4220 done
4221IFS=$as_save_IFS
4222
4223fi
4224fi
4225PYTHON=$ac_cv_prog_PYTHON
4226if test -n "$PYTHON"; then
4227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
4228$as_echo "$PYTHON" >&6; }
4229else
4230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4231$as_echo "no" >&6; }
4232fi
4233
4234
4235 test -n "$PYTHON" && break
4236done
4237
4238
4239
729e4ab9
A
4240# Check for the platform make
4241for ac_prog in gmake gnumake
4242do
4243 # Extract the first word of "$ac_prog", so it can be a program name with args.
4244set dummy $ac_prog; ac_word=$2
4245{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4246$as_echo_n "checking for $ac_word... " >&6; }
4388f060 4247if ${ac_cv_path_U_MAKE+:} false; then :
729e4ab9
A
4248 $as_echo_n "(cached) " >&6
4249else
4250 case $U_MAKE in
4251 [\\/]* | ?:[\\/]*)
4252 ac_cv_path_U_MAKE="$U_MAKE" # Let the user override the test with a path.
4253 ;;
4254 *)
4255 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4256for as_dir in $PATH
4257do
4258 IFS=$as_save_IFS
4259 test -z "$as_dir" && as_dir=.
4260 for ac_exec_ext in '' $ac_executable_extensions; do
b331163b 4261 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
729e4ab9
A
4262 ac_cv_path_U_MAKE="$as_dir/$ac_word$ac_exec_ext"
4263 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4264 break 2
4265 fi
4266done
4267 done
4268IFS=$as_save_IFS
73c04bcf 4269
729e4ab9
A
4270 ;;
4271esac
4272fi
4273U_MAKE=$ac_cv_path_U_MAKE
4274if test -n "$U_MAKE"; then
4275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $U_MAKE" >&5
4276$as_echo "$U_MAKE" >&6; }
4277else
4278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4279$as_echo "no" >&6; }
4280fi
46f4442e
A
4281
4282
729e4ab9
A
4283 test -n "$U_MAKE" && break
4284done
4285test -n "$U_MAKE" || U_MAKE="make"
73c04bcf 4286
73c04bcf 4287
73c04bcf 4288
73c04bcf 4289
73c04bcf 4290
729e4ab9
A
4291# Check whether --with-cross-build was given.
4292if test "${with_cross_build+set}" = set; then :
4293 withval=$with_cross_build; cross_buildroot="${withval}"
4294else
4295 cross_buildroot=""
73c04bcf
A
4296fi
4297
4298
729e4ab9
A
4299if test "X$cross_buildroot" = "X"; then
4300 if test "$cross_compiling" = "yes"; then
4301 as_fn_error $? "Error! Cross compiling but no --with-cross-build option specified - please supply the path to an executable ICU's build root" "$LINENO" 5
4302 fi
4303else
4304 if test -f "${cross_buildroot}/config/icucross.mk"; then
4305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Using cross buildroot: $cross_buildroot" >&5
4306$as_echo "Using cross buildroot: $cross_buildroot" >&6; }
46f4442e 4307 else
729e4ab9
A
4308 if test -d "${cross_buildroot}"; then
4309 as_fn_error $? "${cross_buildroot}/config/icucross.mk not found. Please build ICU in ${cross_buildroot} first." "$LINENO" 5
4310 else
4311 as_fn_error $? "No such directory ${cross_buildroot} supplied as the argument to --with-cross-build. Use an absolute path." "$LINENO" 5
4312 fi
4313 fi
4314fi
73c04bcf
A
4315
4316
729e4ab9
A
4317# Check for doxygen to generate documentation
4318# Extract the first word of "doxygen", so it can be a program name with args.
4319set dummy doxygen; ac_word=$2
4320{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4321$as_echo_n "checking for $ac_word... " >&6; }
4388f060 4322if ${ac_cv_path_DOXYGEN+:} false; then :
729e4ab9 4323 $as_echo_n "(cached) " >&6
73c04bcf 4324else
729e4ab9
A
4325 case $DOXYGEN in
4326 [\\/]* | ?:[\\/]*)
4327 ac_cv_path_DOXYGEN="$DOXYGEN" # Let the user override the test with a path.
4328 ;;
4329 *)
4330 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4331as_dummy="$PATH:/usr/local/bin:/usr/bin"
4332for as_dir in $as_dummy
73c04bcf 4333do
729e4ab9
A
4334 IFS=$as_save_IFS
4335 test -z "$as_dir" && as_dir=.
4336 for ac_exec_ext in '' $ac_executable_extensions; do
b331163b 4337 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
729e4ab9
A
4338 ac_cv_path_DOXYGEN="$as_dir/$ac_word$ac_exec_ext"
4339 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4340 break 2
73c04bcf 4341 fi
729e4ab9
A
4342done
4343 done
4344IFS=$as_save_IFS
4345
4346 ;;
4347esac
73c04bcf 4348fi
729e4ab9
A
4349DOXYGEN=$ac_cv_path_DOXYGEN
4350if test -n "$DOXYGEN"; then
4351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOXYGEN" >&5
4352$as_echo "$DOXYGEN" >&6; }
73c04bcf 4353else
729e4ab9
A
4354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4355$as_echo "no" >&6; }
4356fi
4357
4358
4359
4360# Check that the linker is usable
4361
4362case "${host}" in
4363 *-*-cygwin*|*-*-mingw*)
4364 if test "$GCC" != yes && test -n "`link --version 2>&1 | grep 'GNU coreutils'`"; then
4365 as_fn_error $? "link.exe is not a valid linker. Your PATH is incorrect.
4366 Please follow the directions in ICU's readme." "$LINENO" 5
4367 fi;;
4368 *);;
4369esac
4370
4371# Determine the executable suffix
4372# We don't use AC_EXEEXT because some compilers output separate debugging
4373# files, which confuses the AC_EXEEXT macro.
4374{ $as_echo "$as_me:${as_lineno-$LINENO}: checking checking for executable suffix" >&5
4375$as_echo_n "checking checking for executable suffix... " >&6; }
4376case "${host}" in
4377 *-*-cygwin*|*-*-mingw*) EXEEXT=.exe ;;
4378 *) EXEEXT="" ;;
4379esac
4380ac_exeext=$EXEEXT
4381{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXEEXT" >&5
4382$as_echo "$EXEEXT" >&6; }
73c04bcf 4383
73c04bcf 4384
729e4ab9
A
4385# Determine how strict we want to be when compiling
4386
4387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strict compiling is on" >&5
4388$as_echo_n "checking whether strict compiling is on... " >&6; }
4389 # Check whether --enable-strict was given.
4390if test "${enable_strict+set}" = set; then :
4391 enableval=$enable_strict;
4392 if test "$enableval" = no
4393 then
4394 ac_use_strict_options=no
4395 else
4396 ac_use_strict_options=yes
4397 fi
4398
73c04bcf 4399else
729e4ab9 4400 ac_use_strict_options=yes
73c04bcf 4401fi
73c04bcf 4402
729e4ab9
A
4403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_use_strict_options" >&5
4404$as_echo "$ac_use_strict_options" >&6; }
73c04bcf 4405
729e4ab9
A
4406 if test "$ac_use_strict_options" = yes
4407 then
4408 if test "$GCC" = yes
4409 then
57a6839d 4410 case "${host}" in
f3c0d7a5 4411 *-*-solaris*)
0f5d89e8 4412 # Don't use -std=c11 on Solaris because of timezone check fails
f3c0d7a5 4413 ;;
57a6839d
A
4414 *)
4415 # Do not use -ansi. It limits us to C90, and it breaks some platforms.
0f5d89e8
A
4416 # We use -std=c11 to disable the gnu99 defaults and its associated warnings
4417 CFLAGS="$CFLAGS -std=c11"
57a6839d
A
4418 ;;
4419 esac
4420
4421 CFLAGS="$CFLAGS -Wall -pedantic -Wshadow -Wpointer-arith -Wmissing-prototypes -Wwrite-strings"
729e4ab9
A
4422 else
4423 case "${host}" in
4424 *-*-cygwin)
4425 if test "`$CC /help 2>&1 | head -c9`" = "Microsoft"
4426 then
4427 CFLAGS="$CFLAGS /W4"
b331163b
A
4428 fi ;;
4429 *-*-mingw*)
4430 CFLAGS="$CFLAGS -W4" ;;
729e4ab9
A
4431 esac
4432 fi
4433 if test "$GXX" = yes
4434 then
51004dcb 4435 CXXFLAGS="$CXXFLAGS -W -Wall -pedantic -Wpointer-arith -Wwrite-strings -Wno-long-long"
729e4ab9
A
4436 else
4437 case "${host}" in
4438 *-*-cygwin)
4439 if test "`$CXX /help 2>&1 | head -c9`" = "Microsoft"
4440 then
4441 CXXFLAGS="$CXXFLAGS /W4"
b331163b
A
4442 fi ;;
4443 *-*-mingw*)
4444 CFLAGS="$CFLAGS -W4" ;;
729e4ab9
A
4445 esac
4446 fi
4447 fi
73c04bcf 4448
73c04bcf 4449
729e4ab9
A
4450# Check if we can build and use 64-bit libraries
4451
4452
4453{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4454$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4388f060 4455if ${ac_cv_path_GREP+:} false; then :
729e4ab9 4456 $as_echo_n "(cached) " >&6
73c04bcf 4457else
729e4ab9
A
4458 if test -z "$GREP"; then
4459 ac_path_GREP_found=false
4460 # Loop through the user's path and test for each of PROGNAME-LIST
4461 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4462for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
73c04bcf 4463do
729e4ab9
A
4464 IFS=$as_save_IFS
4465 test -z "$as_dir" && as_dir=.
4466 for ac_prog in grep ggrep; do
4467 for ac_exec_ext in '' $ac_executable_extensions; do
4468 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
b331163b 4469 as_fn_executable_p "$ac_path_GREP" || continue
729e4ab9
A
4470# Check for GNU ac_path_GREP and select it if it is found.
4471 # Check for GNU $ac_path_GREP
4472case `"$ac_path_GREP" --version 2>&1` in
4473*GNU*)
4474 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4475*)
4476 ac_count=0
4477 $as_echo_n 0123456789 >"conftest.in"
4478 while :
4479 do
4480 cat "conftest.in" "conftest.in" >"conftest.tmp"
4481 mv "conftest.tmp" "conftest.in"
4482 cp "conftest.in" "conftest.nl"
4483 $as_echo 'GREP' >> "conftest.nl"
4484 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4485 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4486 as_fn_arith $ac_count + 1 && ac_count=$as_val
4487 if test $ac_count -gt ${ac_path_GREP_max-0}; then
4488 # Best one so far, save it but keep looking for a better one
4489 ac_cv_path_GREP="$ac_path_GREP"
4490 ac_path_GREP_max=$ac_count
4491 fi
4492 # 10*(2^10) chars as input seems more than enough
4493 test $ac_count -gt 10 && break
4494 done
4495 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4496esac
4497
4498 $ac_path_GREP_found && break 3
4499 done
4500 done
4501 done
4502IFS=$as_save_IFS
4503 if test -z "$ac_cv_path_GREP"; then
4504 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
73c04bcf
A
4505 fi
4506else
729e4ab9 4507 ac_cv_path_GREP=$GREP
73c04bcf 4508fi
73c04bcf 4509
73c04bcf 4510fi
729e4ab9
A
4511{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4512$as_echo "$ac_cv_path_GREP" >&6; }
4513 GREP="$ac_cv_path_GREP"
73c04bcf 4514
73c04bcf 4515
729e4ab9
A
4516{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4517$as_echo_n "checking for egrep... " >&6; }
4388f060 4518if ${ac_cv_path_EGREP+:} false; then :
729e4ab9
A
4519 $as_echo_n "(cached) " >&6
4520else
4521 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4522 then ac_cv_path_EGREP="$GREP -E"
4523 else
4524 if test -z "$EGREP"; then
4525 ac_path_EGREP_found=false
4526 # Loop through the user's path and test for each of PROGNAME-LIST
4527 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4528for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4529do
4530 IFS=$as_save_IFS
4531 test -z "$as_dir" && as_dir=.
4532 for ac_prog in egrep; do
4533 for ac_exec_ext in '' $ac_executable_extensions; do
4534 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
b331163b 4535 as_fn_executable_p "$ac_path_EGREP" || continue
729e4ab9
A
4536# Check for GNU ac_path_EGREP and select it if it is found.
4537 # Check for GNU $ac_path_EGREP
4538case `"$ac_path_EGREP" --version 2>&1` in
4539*GNU*)
4540 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4541*)
4542 ac_count=0
4543 $as_echo_n 0123456789 >"conftest.in"
4544 while :
4545 do
4546 cat "conftest.in" "conftest.in" >"conftest.tmp"
4547 mv "conftest.tmp" "conftest.in"
4548 cp "conftest.in" "conftest.nl"
4549 $as_echo 'EGREP' >> "conftest.nl"
4550 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4551 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4552 as_fn_arith $ac_count + 1 && ac_count=$as_val
4553 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4554 # Best one so far, save it but keep looking for a better one
4555 ac_cv_path_EGREP="$ac_path_EGREP"
4556 ac_path_EGREP_max=$ac_count
4557 fi
4558 # 10*(2^10) chars as input seems more than enough
4559 test $ac_count -gt 10 && break
4560 done
4561 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4562esac
73c04bcf 4563
729e4ab9
A
4564 $ac_path_EGREP_found && break 3
4565 done
4566 done
4567 done
4568IFS=$as_save_IFS
4569 if test -z "$ac_cv_path_EGREP"; then
4570 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4571 fi
73c04bcf 4572else
729e4ab9 4573 ac_cv_path_EGREP=$EGREP
73c04bcf
A
4574fi
4575
729e4ab9 4576 fi
73c04bcf 4577fi
729e4ab9
A
4578{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4579$as_echo "$ac_cv_path_EGREP" >&6; }
4580 EGREP="$ac_cv_path_EGREP"
73c04bcf
A
4581
4582
729e4ab9
A
4583{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4584$as_echo_n "checking for ANSI C header files... " >&6; }
4388f060 4585if ${ac_cv_header_stdc+:} false; then :
729e4ab9 4586 $as_echo_n "(cached) " >&6
73c04bcf 4587else
729e4ab9 4588 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf
A
4589/* end confdefs.h. */
4590#include <stdlib.h>
4591#include <stdarg.h>
4592#include <string.h>
4593#include <float.h>
4594
4595int
4596main ()
4597{
4598
4599 ;
4600 return 0;
4601}
4602_ACEOF
729e4ab9 4603if ac_fn_c_try_compile "$LINENO"; then :
73c04bcf
A
4604 ac_cv_header_stdc=yes
4605else
729e4ab9 4606 ac_cv_header_stdc=no
73c04bcf 4607fi
729e4ab9 4608rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
73c04bcf
A
4609
4610if test $ac_cv_header_stdc = yes; then
4611 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
729e4ab9 4612 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf
A
4613/* end confdefs.h. */
4614#include <string.h>
4615
4616_ACEOF
4617if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
729e4ab9
A
4618 $EGREP "memchr" >/dev/null 2>&1; then :
4619
73c04bcf
A
4620else
4621 ac_cv_header_stdc=no
b75a7d8f
A
4622fi
4623rm -f conftest*
b75a7d8f
A
4624
4625fi
b75a7d8f 4626
73c04bcf
A
4627if test $ac_cv_header_stdc = yes; then
4628 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
729e4ab9 4629 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf
A
4630/* end confdefs.h. */
4631#include <stdlib.h>
b75a7d8f 4632
73c04bcf
A
4633_ACEOF
4634if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
729e4ab9
A
4635 $EGREP "free" >/dev/null 2>&1; then :
4636
b75a7d8f 4637else
73c04bcf 4638 ac_cv_header_stdc=no
b75a7d8f 4639fi
73c04bcf 4640rm -f conftest*
b75a7d8f 4641
73c04bcf 4642fi
b75a7d8f 4643
73c04bcf
A
4644if test $ac_cv_header_stdc = yes; then
4645 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
729e4ab9 4646 if test "$cross_compiling" = yes; then :
73c04bcf 4647 :
b75a7d8f 4648else
729e4ab9 4649 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf
A
4650/* end confdefs.h. */
4651#include <ctype.h>
729e4ab9 4652#include <stdlib.h>
73c04bcf
A
4653#if ((' ' & 0x0FF) == 0x020)
4654# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4655# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
b75a7d8f 4656#else
73c04bcf
A
4657# define ISLOWER(c) \
4658 (('a' <= (c) && (c) <= 'i') \
4659 || ('j' <= (c) && (c) <= 'r') \
4660 || ('s' <= (c) && (c) <= 'z'))
4661# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
b75a7d8f
A
4662#endif
4663
73c04bcf
A
4664#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4665int
4666main ()
4667{
4668 int i;
4669 for (i = 0; i < 256; i++)
4670 if (XOR (islower (i), ISLOWER (i))
4671 || toupper (i) != TOUPPER (i))
729e4ab9
A
4672 return 2;
4673 return 0;
73c04bcf
A
4674}
4675_ACEOF
729e4ab9 4676if ac_fn_c_try_run "$LINENO"; then :
73c04bcf 4677
729e4ab9
A
4678else
4679 ac_cv_header_stdc=no
73c04bcf 4680fi
729e4ab9
A
4681rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4682 conftest.$ac_objext conftest.beam conftest.$ac_ext
b75a7d8f 4683fi
729e4ab9 4684
b75a7d8f 4685fi
b75a7d8f 4686fi
729e4ab9
A
4687{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4688$as_echo "$ac_cv_header_stdc" >&6; }
73c04bcf 4689if test $ac_cv_header_stdc = yes; then
b75a7d8f 4690
729e4ab9 4691$as_echo "#define STDC_HEADERS 1" >>confdefs.h
b75a7d8f 4692
b75a7d8f
A
4693fi
4694
73c04bcf 4695# On IRIX 5.3, sys/types and inttypes.h are conflicting.
729e4ab9
A
4696for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4697 inttypes.h stdint.h unistd.h
4698do :
4699 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4700ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4701"
4702if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4703 cat >>confdefs.h <<_ACEOF
4704#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4705_ACEOF
b75a7d8f 4706
729e4ab9 4707fi
b75a7d8f 4708
729e4ab9 4709done
b75a7d8f 4710
b75a7d8f 4711
b75a7d8f 4712
729e4ab9
A
4713 BITS_REQ=nochange
4714 ENABLE_64BIT_LIBS=unknown
4715 ## revisit this for cross-compile.
b75a7d8f 4716
729e4ab9
A
4717 # Check whether --enable-64bit-libs was given.
4718if test "${enable_64bit_libs+set}" = set; then :
4719 enableval=$enable_64bit_libs; echo "note, use --with-library-bits instead of --*-64bit-libs"
4720 case "${enableval}" in
4721 no|false|32) with_library_bits=32; ;;
4722 yes|true|64) with_library_bits=64else32 ;;
4723 nochange) with_library_bits=nochange; ;;
4724 *) as_fn_error $? "bad value ${enableval} for '--*-64bit-libs'" "$LINENO" 5 ;;
4725 esac
4726fi
374ca955
A
4727
4728
4729
73c04bcf 4730
729e4ab9
A
4731# Check whether --with-library-bits was given.
4732if test "${with_library_bits+set}" = set; then :
4733 withval=$with_library_bits; case "${withval}" in
4734 ""|nochange) BITS_REQ=$withval ;;
4735 32|64|64else32) BITS_REQ=$withval ;;
4736 *) as_fn_error $? "bad value ${withval} for --with-library-bits" "$LINENO" 5 ;;
4737 esac
4738fi
4739
4740
4741 # don't use these for cross compiling
4742 if test "$cross_compiling" = "yes" -a "${BITS_REQ}" != "nochange"; then
4743 as_fn_error $? "Don't specify bitness when cross compiling. See readme.html for help with cross compilation., and set compiler options manually." "$LINENO" 5
4744 fi
4745 # The cast to long int works around a bug in the HP C Compiler
4746# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
4747# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
4748# This bug is HP SR number 8606223364.
4749{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5
4750$as_echo_n "checking size of void *... " >&6; }
4388f060 4751if ${ac_cv_sizeof_void_p+:} false; then :
729e4ab9 4752 $as_echo_n "(cached) " >&6
73c04bcf 4753else
729e4ab9 4754 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"; then :
73c04bcf 4755
729e4ab9
A
4756else
4757 if test "$ac_cv_type_void_p" = yes; then
4758 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4759$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4760as_fn_error 77 "cannot compute sizeof (void *)
4761See \`config.log' for more details" "$LINENO" 5; }
4762 else
4763 ac_cv_sizeof_void_p=0
4764 fi
73c04bcf 4765fi
73c04bcf 4766
b75a7d8f 4767fi
729e4ab9
A
4768{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5
4769$as_echo "$ac_cv_sizeof_void_p" >&6; }
73c04bcf
A
4770
4771
4772
729e4ab9
A
4773cat >>confdefs.h <<_ACEOF
4774#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
73c04bcf 4775_ACEOF
729e4ab9
A
4776
4777
4778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether runnable 64 bit binaries are built by default" >&5
4779$as_echo_n "checking whether runnable 64 bit binaries are built by default... " >&6; }
4780 case $ac_cv_sizeof_void_p in
4781 8) DEFAULT_64BIT=yes ;;
4782 4) DEFAULT_64BIT=no ;;
4783 *) DEFAULT_64BIT=unknown
4784 esac
4785 BITS_GOT=unknown
4786
4787 # 'OK' here means, we can exit any further checking, everything's copa
4788 BITS_OK=yes
4789
4790 # do we need to check for buildable/runnable 32 or 64 bit?
4791 BITS_CHECK_32=no
4792 BITS_CHECK_64=no
4793
4794 # later, can we run the 32/64 bit binaries so made?
4795 BITS_RUN_32=no
4796 BITS_RUN_64=no
4797
4798 if test "$DEFAULT_64BIT" = "yes"; then
4799 # we get 64 bits by default.
4800 BITS_GOT=64
4801 case "$BITS_REQ" in
4802 32)
4803 # need to look for 32 bit support.
4804 BITS_CHECK_32=yes
4805 # not copa.
4806 BITS_OK=no;;
4807 # everyone else is happy.
4808 nochange) ;;
4809 *) ;;
4810 esac
4811 elif test "$DEFAULT_64BIT" = "no"; then
4812 # not 64 bit by default.
4813 BITS_GOT=32
4814 case "$BITS_REQ" in
4815 64|64else32)
4816 BITS_CHECK_64=yes
4817 #BITS_CHECK_32=yes
4818 BITS_OK=no;;
4819 nochange) ;;
4820 *) ;;
4821 esac
4822 elif test "$DEFAULT_64BIT" = "unknown"; then
4823 # cross compiling.
4824 BITS_GOT=unknown
4825 case "$BITS_REQ" in
4826 64|64else32) BITS_OK=no
4827 BITS_CHECK_32=yes
4828 BITS_CHECK_64=yes ;;
4829 32) BITS_OK=no;;
4830 nochange) ;;
4831 *) ;;
4832 esac
4833 fi
4834
4835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEFAULT_64BIT" >&5
4836$as_echo "$DEFAULT_64BIT" >&6; };
4837
4838 if test "$BITS_OK" != "yes"; then
4839 # not copa. back these up.
4840 CFLAGS_OLD="${CFLAGS}"
4841 CXXFLAGS_OLD="${CXXFLAGS}"
4842 LDFLAGS_OLD="${LDFLAGS}"
4843 ARFLAGS_OLD="${ARFLAGS}"
4844
4845 CFLAGS_32="${CFLAGS}"
4846 CXXFLAGS_32="${CXXFLAGS}"
4847 LDFLAGS_32="${LDFLAGS}"
4848 ARFLAGS_32="${ARFLAGS}"
4849
4850 CFLAGS_64="${CFLAGS}"
4851 CXXFLAGS_64="${CXXFLAGS}"
4852 LDFLAGS_64="${LDFLAGS}"
4853 ARFLAGS_64="${ARFLAGS}"
4854
4855 CAN_BUILD_64=unknown
4856 CAN_BUILD_32=unknown
4857 # These results can't be cached because is sets compiler flags.
4858 if test "$BITS_CHECK_64" = "yes"; then
4859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to build 64-bit executables" >&5
4860$as_echo_n "checking how to build 64-bit executables... " >&6; }
4861 CAN_BUILD_64=no
4862 ####
4863 # Find out if we think we can *build* for 64 bit. Doesn't check whether we can run it.
4864 # Note, we don't have to actually check if the options work- we'll try them before using them.
4865 # So, only try actually testing the options, if you are trying to decide between multiple options.
4866 # On exit from the following clauses:
4867 # if CAN_BUILD_64=yes:
4868 # *FLAGS are assumed to contain the right settings for 64bit
4869 # else if CAN_BUILD_64=no: (default)
4870 # *FLAGS are assumed to be trashed, and will be reset from *FLAGS_OLD
4871
4872 if test "$GCC" = yes; then
4873 CFLAGS="${CFLAGS} -m64"
4874 CXXFLAGS="${CXXFLAGS} -m64"
4875 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 4876/* end confdefs.h. */
729e4ab9 4877int main(void) {return (sizeof(void*)*8==64)?0:1;}
73c04bcf 4878_ACEOF
729e4ab9
A
4879if ac_fn_c_try_compile "$LINENO"; then :
4880 CAN_BUILD_64=yes
73c04bcf 4881else
729e4ab9 4882 CAN_BUILD_64=no
73c04bcf 4883fi
729e4ab9
A
4884rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4885 else
4886 case "${host}" in
4887 sparc*-*-solaris*)
4888 # 1. try -m64
4889 CFLAGS="${CFLAGS} -m64"
4890 CXXFLAGS="${CXXFLAGS} -m64"
4388f060
A
4891 if test "$cross_compiling" = yes; then :
4892 CAN_BUILD_64=unknown
4893else
4894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
729e4ab9
A
4895/* end confdefs.h. */
4896int main(void) {return (sizeof(void*)*8==64)?0:1;}
4897_ACEOF
4388f060 4898if ac_fn_c_try_run "$LINENO"; then :
729e4ab9
A
4899 CAN_BUILD_64=yes
4900else
4901 CAN_BUILD_64=no
4902fi
4388f060
A
4903rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4904 conftest.$ac_objext conftest.beam conftest.$ac_ext
4905fi
4906
729e4ab9
A
4907 if test "$CAN_BUILD_64" != yes; then
4908 # Nope. back out changes.
4909 CFLAGS="${CFLAGS_OLD}"
b331163b 4910 CXXFLAGS="${CXXFLAGS_OLD}"
729e4ab9
A
4911 # 2. try xarch=v9 [deprecated]
4912 ## TODO: cross compile: the following won't work.
4913 SPARCV9=`isainfo -n 2>&1 | grep sparcv9`
4914 SOL64=`$CXX -xarch=v9 2>&1 && $CC -xarch=v9 2>&1 | grep -v usage:`
4915 # "Warning: -xarch=v9 is deprecated, use -m64 to create 64-bit programs"
4916 if test -z "$SOL64" && test -n "$SPARCV9"; then
4917 CFLAGS="${CFLAGS} -xtarget=ultra -xarch=v9"
4918 CXXFLAGS="${CXXFLAGS} -xtarget=ultra -xarch=v9"
4919 LDFLAGS="${LDFLAGS} -xtarget=ultra -xarch=v9"
4920 CAN_BUILD_64=yes
4921 fi
4922 fi
4923 ;;
4924 i386-*-solaris*)
4925 # 1. try -m64
4926 CFLAGS="${CFLAGS} -m64"
4927 CXXFLAGS="${CXXFLAGS} -m64"
4388f060
A
4928 if test "$cross_compiling" = yes; then :
4929 CAN_BUILD_64=unknown
4930else
4931 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
729e4ab9
A
4932/* end confdefs.h. */
4933int main(void) {return (sizeof(void*)*8==64)?0:1;}
4934_ACEOF
4388f060 4935if ac_fn_c_try_run "$LINENO"; then :
729e4ab9
A
4936 CAN_BUILD_64=yes
4937else
4938 CAN_BUILD_64=no
4939fi
4388f060
A
4940rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4941 conftest.$ac_objext conftest.beam conftest.$ac_ext
4942fi
4943
729e4ab9
A
4944 if test "$CAN_BUILD_64" != yes; then
4945 # Nope. back out changes.
4946 CFLAGS="${CFLAGS_OLD}"
4947 CXXFLAGS="${CXXFLAGS_OLD}"
4948 # 2. try the older compiler option
4949 ## TODO: cross compile problem
4388f060 4950 AMD64=`isainfo -n 2>&1 | grep amd64`
729e4ab9
A
4951 SOL64=`$CXX -xtarget=generic64 2>&1 && $CC -xtarget=generic64 2>&1 | grep -v usage:`
4952 if test -z "$SOL64" && test -n "$AMD64"; then
4953 CFLAGS="${CFLAGS} -xtarget=generic64"
4954 CXXFLAGS="${CXXFLAGS} -xtarget=generic64"
4955 CAN_BUILD_64=yes
4956 fi
4957 fi
4958 ;;
4959 ia64-*-linux*)
4960 # check for ecc/ecpc compiler support
4961 ## TODO: cross compiler problem
4962 if test -n "`$CXX --help 2>&1 && $CC --help 2>&1 | grep -v Intel`"; then
4963 if test -n "`$CXX --help 2>&1 && $CC --help 2>&1 | grep -v Itanium`"; then
4964 CAN_BUILD_64=yes
4965 fi
4966 fi
4967 ;;
4968 *-*-cygwin)
4969 # vcvarsamd64.bat should have been used to enable 64-bit builds.
4970 # We only do this check to display the correct answer.
4971 ## TODO: cross compiler problem
4972 if test -n "`$CXX -help 2>&1 | grep 'for x64'`"; then
4973 CAN_BUILD_64=yes
4974 fi
4975 ;;
4976 *-*-aix*|powerpc64-*-linux*)
4977 CFLAGS="${CFLAGS} -q64"
4978 CXXFLAGS="${CXXFLAGS} -q64"
4979 LDFLAGS="${LDFLAGS} -q64"
4980 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4981/* end confdefs.h. */
4982int main(void) {return (sizeof(void*)*8==64)?0:1;}
73c04bcf 4983_ACEOF
729e4ab9
A
4984if ac_fn_c_try_compile "$LINENO"; then :
4985 CAN_BUILD_64=yes
4986else
4987 CAN_BUILD_64=no
4988fi
4989rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4990 if test "$CAN_BUILD_64" = yes; then
4991 # worked- set other options.
4992 case "${host}" in
4993 *-*-aix*)
4994 # tell AIX what executable mode to use.
4995 ARFLAGS="${ARFLAGS} -X64"
4996 esac
4997 fi
4998 ;;
4999 *-*-hpux*)
5000 # First we try the newer +DD64, if that doesn't work,
5001 # try other options.
5002
5003 CFLAGS="${CFLAGS} +DD64"
5004 CXXFLAGS="${CXXFLAGS} +DD64"
5005 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 5006/* end confdefs.h. */
729e4ab9
A
5007int main(void) {return (sizeof(void*)*8==64)?0:1;}
5008_ACEOF
5009if ac_fn_c_try_compile "$LINENO"; then :
5010 CAN_BUILD_64=yes
5011else
5012 CAN_BUILD_64=no
5013fi
5014rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5015 if test "$CAN_BUILD_64" != yes; then
5016 # reset
5017 CFLAGS="${CFLAGS_OLD}"
5018 CXXFLAGS="${CXXFLAGS_OLD}"
5019 # append
5020 CFLAGS="${CFLAGS} +DA2.0W"
5021 CXXFLAGS="${CXXFLAGS} +DA2.0W"
5022 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5023/* end confdefs.h. */
5024int main(void) {return (sizeof(void*)*8==64)?0:1;}
73c04bcf 5025_ACEOF
729e4ab9
A
5026if ac_fn_c_try_compile "$LINENO"; then :
5027 CAN_BUILD_64=yes
b75a7d8f 5028else
729e4ab9 5029 CAN_BUILD_64=no
b75a7d8f 5030fi
729e4ab9
A
5031rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5032 fi
5033 ;;
5034 *-*ibm-openedition*|*-*-os390*)
5035 CFLAGS="${CFLAGS} -Wc,lp64"
5036 CXXFLAGS="${CXXFLAGS} -Wc,lp64"
5037 LDFLAGS="${LDFLAGS} -Wl,lp64"
5038 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5039/* end confdefs.h. */
5040int main(void) {return (sizeof(void*)*8==64)?0:1;}
5041_ACEOF
5042if ac_fn_c_try_compile "$LINENO"; then :
5043 CAN_BUILD_64=yes
b75a7d8f 5044else
729e4ab9 5045 CAN_BUILD_64=no
b75a7d8f 5046fi
729e4ab9
A
5047rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5048 ;;
5049 *)
5050 # unknown platform.
5051 ;;
5052 esac
5053 fi
5054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAN_BUILD_64" >&5
5055$as_echo "$CAN_BUILD_64" >&6; }
5056 if test "$CAN_BUILD_64" = yes; then
5057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether runnable 64-bit binaries are being built " >&5
5058$as_echo_n "checking whether runnable 64-bit binaries are being built ... " >&6; }
5059 if test "$cross_compiling" = yes; then :
5060 BITS_RUN_64=unknown
5061else
5062 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5063/* end confdefs.h. */
5064int main(void) {return (sizeof(void*)*8==64)?0:1;}
5065_ACEOF
5066if ac_fn_c_try_run "$LINENO"; then :
5067 BITS_RUN_64=yes
73c04bcf 5068else
729e4ab9 5069 BITS_RUN_64=no
b75a7d8f 5070fi
729e4ab9
A
5071rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
5072 conftest.$ac_objext conftest.beam conftest.$ac_ext
b75a7d8f 5073fi
73c04bcf 5074
729e4ab9
A
5075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BITS_RUN_64" >&5
5076$as_echo "$BITS_RUN_64" >&6; };
b75a7d8f 5077
729e4ab9
A
5078 CFLAGS_64="${CFLAGS}"
5079 CXXFLAGS_64="${CXXFLAGS}"
5080 LDFLAGS_64="${LDFLAGS}"
5081 ARFLAGS_64="${ARFLAGS}"
5082 fi
5083 # put it back.
5084 CFLAGS="${CFLAGS_OLD}"
5085 CXXFLAGS="${CXXFLAGS_OLD}"
5086 LDFLAGS="${LDFLAGS_OLD}"
5087 ARFLAGS="${ARFLAGS_OLD}"
5088 fi
5089 if test "$BITS_CHECK_32" = "yes"; then
5090 # see comment under 'if BITS_CHECK_64', above.
5091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to build 32-bit executables" >&5
5092$as_echo_n "checking how to build 32-bit executables... " >&6; }
5093 if test "$GCC" = yes; then
5094 CFLAGS="${CFLAGS} -m32"
5095 CXXFLAGS="${CXXFLAGS} -m32"
5096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5097/* end confdefs.h. */
5098int main(void) {return (sizeof(void*)*8==32)?0:1;}
5099_ACEOF
5100if ac_fn_c_try_compile "$LINENO"; then :
5101 CAN_BUILD_32=yes
b75a7d8f 5102else
729e4ab9 5103 CAN_BUILD_32=no
b75a7d8f 5104fi
729e4ab9
A
5105rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5106 fi
5107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAN_BUILD_32" >&5
5108$as_echo "$CAN_BUILD_32" >&6; }
5109 if test "$CAN_BUILD_32" = yes; then
5110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether runnable 32-bit binaries are being built " >&5
5111$as_echo_n "checking whether runnable 32-bit binaries are being built ... " >&6; }
5112 if test "$cross_compiling" = yes; then :
5113 BITS_RUN_32=unknown
5114else
5115 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5116/* end confdefs.h. */
5117int main(void) {return (sizeof(void*)*8==32)?0:1;}
5118_ACEOF
5119if ac_fn_c_try_run "$LINENO"; then :
5120 BITS_RUN_32=yes
5121else
5122 BITS_RUN_32=no
5123fi
5124rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
5125 conftest.$ac_objext conftest.beam conftest.$ac_ext
b75a7d8f
A
5126fi
5127
729e4ab9
A
5128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BITS_RUN_32" >&5
5129$as_echo "$BITS_RUN_32" >&6; };
5130 CFLAGS_32="${CFLAGS}"
5131 CXXFLAGS_32="${CXXFLAGS}"
5132 LDFLAGS_32="${LDFLAGS}"
5133 ARFLAGS_32="${ARFLAGS}"
5134 fi
5135 # put it back.
5136 CFLAGS="${CFLAGS_OLD}"
5137 CXXFLAGS="${CXXFLAGS_OLD}"
5138 LDFLAGS="${LDFLAGS_OLD}"
5139 ARFLAGS="${ARFLAGS_OLD}"
5140 fi
b75a7d8f 5141
729e4ab9
A
5142 ##
5143 # OK. Now, we've tested for 32 and 64 bitness. Let's see what we'll do.
5144 #
b75a7d8f 5145
729e4ab9
A
5146 # First, implement 64else32
5147 if test "$BITS_REQ" = "64else32"; then
5148 if test "$BITS_RUN_64" = "yes"; then
5149 BITS_REQ=64
5150 else
5151 # no changes.
5152 BITS_OK=yes
5153 fi
5154 fi
73c04bcf 5155
729e4ab9
A
5156 # implement.
5157 if test "$BITS_REQ" = "32" -a "$BITS_RUN_32" = "yes"; then
5158 CFLAGS="${CFLAGS_32}"
5159 CXXFLAGS="${CXXFLAGS_32}"
5160 LDFLAGS="${LDFLAGS_32}"
5161 ARFLAGS="${ARFLAGS_32}"
5162 BITS_OK=yes
5163 elif test "$BITS_REQ" = "64" -a "$BITS_RUN_64" = "yes"; then
5164 CFLAGS="${CFLAGS_64}"
5165 CXXFLAGS="${CXXFLAGS_64}"
5166 LDFLAGS="${LDFLAGS_64}"
5167 ARFLAGS="${ARFLAGS_64}"
5168 BITS_OK=yes
5169 elif test "$BITS_OK" != "yes"; then
5170 as_fn_error $? "Requested $BITS_REQ bit binaries but could not compile and execute them. See readme.html for help with cross compilation., and set compiler options manually." "$LINENO" 5
5171 fi
5172 fi
b75a7d8f 5173
73c04bcf
A
5174
5175
b75a7d8f 5176
729e4ab9 5177# Determine the Makefile fragment
73c04bcf 5178
729e4ab9
A
5179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which Makefile fragment to use for ${host}" >&5
5180$as_echo_n "checking which Makefile fragment to use for ${host}... " >&6; }
4388f060 5181if ${icu_cv_host_frag+:} false; then :
729e4ab9
A
5182 $as_echo_n "(cached) " >&6
5183else
5184
5185case "${host}" in
5186*-*-solaris*)
5187 if test "$GCC" = yes; then
5188 icu_cv_host_frag=mh-solaris-gcc
5189 else
5190 icu_cv_host_frag=mh-solaris
5191 fi ;;
5192alpha*-*-linux-gnu)
5193 if test "$GCC" = yes; then
5194 icu_cv_host_frag=mh-alpha-linux-gcc
5195 else
5196 icu_cv_host_frag=mh-alpha-linux-cc
5197 fi ;;
5198powerpc*-*-linux*)
5199 if test "$GCC" = yes; then
5200 icu_cv_host_frag=mh-linux
5201 else
5202 icu_cv_host_frag=mh-linux-va
5203 fi ;;
5204*-*-linux*|*-*-gnu|*-*-k*bsd*-gnu|*-*-kopensolaris*-gnu) icu_cv_host_frag=mh-linux ;;
b331163b 5205i[34567]86-*-cygwin)
729e4ab9 5206 if test "$GCC" = yes; then
b331163b
A
5207 icu_cv_host_frag=mh-cygwin
5208 else
5209 icu_cv_host_frag=mh-cygwin-msvc
5210 fi ;;
5211x86_64-*-cygwin)
5212 if test "$GCC" = yes; then
5213 icu_cv_host_frag=mh-cygwin64
5214 else
5215 icu_cv_host_frag=mh-cygwin-msvc
5216 fi ;;
5217*-*-mingw*)
5218 if test "$GCC" = yes; then
5219 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
51004dcb
A
5220/* end confdefs.h. */
5221
5222#ifndef __MINGW64__
5223#error This is not MinGW64
5224#endif
5225int
5226main ()
5227{
5228
5229 ;
5230 return 0;
5231}
5232_ACEOF
5233if ac_fn_c_try_compile "$LINENO"; then :
5234 icu_cv_host_frag=mh-mingw64
5235else
729e4ab9 5236 icu_cv_host_frag=mh-mingw
51004dcb 5237fi
729e4ab9
A
5238rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5239 else
b331163b
A
5240 case "${host}" in
5241 *-*-mingw*) icu_cv_host_frag=mh-msys-msvc ;;
5242 *-*-cygwin) icu_cv_host_frag=mh-cygwin-msvc ;;
5243 esac
729e4ab9
A
5244 fi ;;
5245*-*-*bsd*|*-*-dragonfly*) icu_cv_host_frag=mh-bsd-gcc ;;
5246*-*-aix*)
5247 if test "$GCC" = yes; then
5248 icu_cv_host_frag=mh-aix-gcc
5249 else
5250 icu_cv_host_frag=mh-aix-va
5251 fi ;;
5252*-*-hpux*)
5253 if test "$GCC" = yes; then
5254 icu_cv_host_frag=mh-hpux-gcc
5255 else
5256 case "$CXX" in
5257 *aCC) icu_cv_host_frag=mh-hpux-acc ;;
5258 esac
5259 fi ;;
5260*-*ibm-openedition*|*-*-os390*) icu_cv_host_frag=mh-os390 ;;
5261*-*-os400*) icu_cv_host_frag=mh-os400 ;;
5262*-apple-rhapsody*) icu_cv_host_frag=mh-darwin ;;
5263*-apple-darwin*) icu_cv_host_frag=mh-darwin ;;
5264*-*-beos) icu_cv_host_frag=mh-beos ;;
5265*-*-haiku) icu_cv_host_frag=mh-haiku ;;
5266*-*-irix*) icu_cv_host_frag=mh-irix ;;
5267*-dec-osf*) icu_cv_host_frag=mh-alpha-osf ;;
5268*-*-nto*) icu_cv_host_frag=mh-qnx ;;
5269*-ncr-*) icu_cv_host_frag=mh-mpras ;;
5270*) icu_cv_host_frag=mh-unknown ;;
5271esac
5272
73c04bcf 5273
b75a7d8f 5274fi
729e4ab9
A
5275{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $icu_cv_host_frag" >&5
5276$as_echo "$icu_cv_host_frag" >&6; }
5277
5278
5279# Checks for libraries and other host specific stuff
5280# On HP/UX, don't link to -lm from a shared lib because it isn't
5281# PIC (at least on 10.2)
5282case "${host}" in
5283 *-*-hpux*) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for floor in -lm" >&5
5284$as_echo_n "checking for floor in -lm... " >&6; }
4388f060 5285if ${ac_cv_lib_m_floor+:} false; then :
729e4ab9 5286 $as_echo_n "(cached) " >&6
73c04bcf 5287else
729e4ab9
A
5288 ac_check_lib_save_LIBS=$LIBS
5289LIBS="-lm $LIBS"
5290cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 5291/* end confdefs.h. */
729e4ab9
A
5292
5293/* Override any GCC internal prototype to avoid an error.
5294 Use char because int might match the return type of a GCC
5295 builtin and then its argument prototype would still apply. */
5296#ifdef __cplusplus
5297extern "C"
5298#endif
5299char floor ();
73c04bcf
A
5300int
5301main ()
5302{
729e4ab9 5303return floor ();
73c04bcf
A
5304 ;
5305 return 0;
5306}
5307_ACEOF
729e4ab9
A
5308if ac_fn_c_try_link "$LINENO"; then :
5309 ac_cv_lib_m_floor=yes
b75a7d8f 5310else
729e4ab9 5311 ac_cv_lib_m_floor=no
b75a7d8f 5312fi
729e4ab9
A
5313rm -f core conftest.err conftest.$ac_objext \
5314 conftest$ac_exeext conftest.$ac_ext
5315LIBS=$ac_check_lib_save_LIBS
b75a7d8f 5316fi
729e4ab9
A
5317{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_floor" >&5
5318$as_echo "$ac_cv_lib_m_floor" >&6; }
4388f060 5319if test "x$ac_cv_lib_m_floor" = xyes; then :
729e4ab9 5320 LIB_M="-lm"
b75a7d8f 5321fi
729e4ab9 5322 ;;
b75a7d8f 5323
729e4ab9
A
5324 *) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for floor in -lm" >&5
5325$as_echo_n "checking for floor in -lm... " >&6; }
4388f060 5326if ${ac_cv_lib_m_floor+:} false; then :
729e4ab9 5327 $as_echo_n "(cached) " >&6
73c04bcf 5328else
729e4ab9
A
5329 ac_check_lib_save_LIBS=$LIBS
5330LIBS="-lm $LIBS"
5331cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 5332/* end confdefs.h. */
b75a7d8f 5333
729e4ab9
A
5334/* Override any GCC internal prototype to avoid an error.
5335 Use char because int might match the return type of a GCC
5336 builtin and then its argument prototype would still apply. */
5337#ifdef __cplusplus
5338extern "C"
5339#endif
5340char floor ();
73c04bcf
A
5341int
5342main ()
5343{
729e4ab9 5344return floor ();
73c04bcf
A
5345 ;
5346 return 0;
5347}
5348_ACEOF
729e4ab9
A
5349if ac_fn_c_try_link "$LINENO"; then :
5350 ac_cv_lib_m_floor=yes
5351else
5352 ac_cv_lib_m_floor=no
5353fi
5354rm -f core conftest.err conftest.$ac_objext \
5355 conftest$ac_exeext conftest.$ac_ext
5356LIBS=$ac_check_lib_save_LIBS
5357fi
5358{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_floor" >&5
5359$as_echo "$ac_cv_lib_m_floor" >&6; }
4388f060 5360if test "x$ac_cv_lib_m_floor" = xyes; then :
729e4ab9
A
5361 cat >>confdefs.h <<_ACEOF
5362#define HAVE_LIBM 1
73c04bcf 5363_ACEOF
729e4ab9
A
5364
5365 LIBS="-lm $LIBS"
5366
5367fi
5368
5369 LIB_M="" ;;
5370esac
5371
5372
5373# Check whether to build shared libraries
5374{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
5375$as_echo_n "checking whether to build shared libraries... " >&6; }
5376enabled=no
5377# Check whether --enable-shared was given.
5378if test "${enable_shared+set}" = set; then :
5379 enableval=$enable_shared; case "${enableval}" in
5380 yes|"") enabled=yes; ENABLE_SHARED=YES ;;
5381 no);;
5382 *) ;;
5383 esac
5384else
5385 enabled=yes; ENABLE_SHARED=YES
5386
5387fi
5388
5389{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enabled" >&5
5390$as_echo "$enabled" >&6; }
5391
5392
5393# Check whether to build static libraries
5394{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
5395$as_echo_n "checking whether to build static libraries... " >&6; }
5396enabled=no
5397# Check whether --enable-static was given.
5398if test "${enable_static+set}" = set; then :
5399 enableval=$enable_static; case "${enableval}" in
5400 yes|"") enabled=yes; ENABLE_STATIC=YES ;;
5401 no) ;;
5402 *) ;;
5403 esac
5404fi
5405
5406{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enabled" >&5
5407$as_echo "$enabled" >&6; }
5408
5409
4388f060
A
5410# When building release static library, there might be some optimization flags we can use
5411if test "$ENABLE_STATIC" = "YES"; then
5412 if test "$ENABLE_SHARED" != "YES"; then
5413 if test "$ENABLE_RELEASE" = 1; then
5414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can use static library optimization option" >&5
5415$as_echo_n "checking whether we can use static library optimization option... " >&6; }
5416 CHECK_STATIC_OPT_FLAG=no
5417
5418 OLD_CPPFLAGS="${CPPFLAGS}"
5419 OLD_LDFLAGS="${LDFLAGS}"
5420
5421 case "${host}" in
5422 *-linux*|i*86-*-*bsd*|i*86-pc-gnu)
51004dcb 5423 if test "$GCC" = yes; then
4388f060
A
5424 CPPFLAGS="${CPPFLAGS} -ffunction-sections -fdata-sections"
5425 LDFLAGS="${LDFLAGS} -Wl,--gc-sections"
5426 fi
5427 ;;
5428 *)
5429 ;;
5430 esac
5431
5432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5433/* end confdefs.h. */
5434
5435int
5436main ()
5437{
5438
5439 ;
5440 return 0;
5441}
5442_ACEOF
5443if ac_fn_c_try_link "$LINENO"; then :
5444 CHECK_STATIC_OPT_FLAG=yes
5445else
5446 CHECK_STATIC_OPT_FLAG=no
5447fi
5448rm -f core conftest.err conftest.$ac_objext \
5449 conftest$ac_exeext conftest.$ac_ext
5450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_STATIC_OPT_FLAG" >&5
5451$as_echo "$CHECK_STATIC_OPT_FLAG" >&6; }
5452 if test "$CHECK_STATIC_OPT_FLAG" = no; then
5453 CPPFLAGS="${OLD_CPPFLAGS}"
5454 LDFLAGS="${OLD_LDFLAGS}"
5455 fi
5456 fi
5457 fi
5458fi
5459
5460
729e4ab9
A
5461# Check whether to enable auto cleanup of libraries
5462{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable auto cleanup of libraries" >&5
5463$as_echo_n "checking whether to enable auto cleanup of libraries... " >&6; }
5464enabled=no
5465UCLN_NO_AUTO_CLEANUP=1
5466# Check whether --enable-auto-cleanup was given.
5467if test "${enable_auto_cleanup+set}" = set; then :
5468 enableval=$enable_auto_cleanup; case "${enableval}" in
4388f060
A
5469 yes) enabled=yes;
5470 CONFIG_CPPFLAGS="$CONFIG_CPPFLAGS -DUCLN_NO_AUTO_CLEANUP=0";
5471 UCLN_NO_AUTO_CLEANUP=0
5472 ;;
729e4ab9
A
5473 *) ;;
5474 esac
5475fi
5476
5477{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enabled" >&5
5478$as_echo "$enabled" >&6; }
5479
5480
5481# MSVC floating-point option
5482MSVC_RELEASE_FLAG=""
5483if test $enabled = yes
5484then
b331163b 5485 if test $icu_cv_host_frag = mh-cygwin-msvc -o $icu_cv_host_frag = mh-msys-msvc
729e4ab9
A
5486 then
5487 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 5488/* end confdefs.h. */
729e4ab9
A
5489
5490 #if defined _MSC_VER && _MSC_VER >= 1400
5491 #else
5492 Microsoft Visual C++ < 2005
5493 #endif
b75a7d8f 5494
73c04bcf
A
5495int
5496main ()
5497{
73c04bcf
A
5498
5499 ;
5500 return 0;
5501}
5502_ACEOF
729e4ab9
A
5503if ac_fn_c_try_compile "$LINENO"; then :
5504 MSVC_RELEASE_FLAG="/fp:precise"
b75a7d8f 5505else
729e4ab9
A
5506 MSVC_RELEASE_FLAG="/Op"
5507fi
5508rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
73c04bcf 5509
729e4ab9
A
5510 CFLAGS="${CFLAGS} ${MSVC_RELEASE_FLAG}"
5511 CXXFLAGS="${CXXFLAGS} ${MSVC_RELEASE_FLAG}"
5512 fi
b75a7d8f 5513fi
73c04bcf 5514
729e4ab9
A
5515# Check whether to enabled draft APIs
5516{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable draft APIs" >&5
5517$as_echo_n "checking whether to enable draft APIs... " >&6; }
5518enabled=yes
5519U_DEFAULT_SHOW_DRAFT=1
5520# Check whether --enable-draft was given.
5521if test "${enable_draft+set}" = set; then :
5522 enableval=$enable_draft; case "${enableval}" in
4388f060
A
5523 no) enabled=no; U_DEFAULT_SHOW_DRAFT=0;
5524 CONFIG_CPPFLAGS="$CONFIG_CPPFLAGS -DU_DEFAULT_SHOW_DRAFT=0"
5525 ;;
729e4ab9
A
5526 *) ;;
5527 esac
5528fi
5529
5530{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enabled" >&5
5531$as_echo "$enabled" >&6; }
5532# Make sure that we can use draft API in ICU.
5533if test "$U_DEFAULT_SHOW_DRAFT" = 0; then
0f5d89e8 5534 CONFIG_CPPFLAGS="$CONFIG_CPPFLAGS -DU_SHOW_DRAFT_API -DU_SHOW_INTERNAL_API"
729e4ab9 5535fi
729e4ab9
A
5536
5537
5538if test -n "$ac_tool_prefix"; then
5539 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5540set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5541{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5542$as_echo_n "checking for $ac_word... " >&6; }
4388f060 5543if ${ac_cv_prog_RANLIB+:} false; then :
729e4ab9
A
5544 $as_echo_n "(cached) " >&6
5545else
5546 if test -n "$RANLIB"; then
5547 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5548else
5549as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5550for as_dir in $PATH
5551do
5552 IFS=$as_save_IFS
5553 test -z "$as_dir" && as_dir=.
5554 for ac_exec_ext in '' $ac_executable_extensions; do
b331163b 5555 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
729e4ab9
A
5556 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5557 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5558 break 2
5559 fi
5560done
5561 done
5562IFS=$as_save_IFS
5563
5564fi
5565fi
5566RANLIB=$ac_cv_prog_RANLIB
5567if test -n "$RANLIB"; then
5568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
5569$as_echo "$RANLIB" >&6; }
5570else
5571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5572$as_echo "no" >&6; }
5573fi
5574
73c04bcf 5575
b75a7d8f 5576fi
729e4ab9
A
5577if test -z "$ac_cv_prog_RANLIB"; then
5578 ac_ct_RANLIB=$RANLIB
5579 # Extract the first word of "ranlib", so it can be a program name with args.
5580set dummy ranlib; ac_word=$2
5581{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5582$as_echo_n "checking for $ac_word... " >&6; }
4388f060 5583if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
729e4ab9
A
5584 $as_echo_n "(cached) " >&6
5585else
5586 if test -n "$ac_ct_RANLIB"; then
5587 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5588else
5589as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5590for as_dir in $PATH
5591do
5592 IFS=$as_save_IFS
5593 test -z "$as_dir" && as_dir=.
5594 for ac_exec_ext in '' $ac_executable_extensions; do
b331163b 5595 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
729e4ab9
A
5596 ac_cv_prog_ac_ct_RANLIB="ranlib"
5597 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5598 break 2
5599 fi
5600done
5601 done
5602IFS=$as_save_IFS
5603
b75a7d8f 5604fi
b75a7d8f 5605fi
729e4ab9
A
5606ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5607if test -n "$ac_ct_RANLIB"; then
5608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
5609$as_echo "$ac_ct_RANLIB" >&6; }
5610else
5611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5612$as_echo "no" >&6; }
b75a7d8f
A
5613fi
5614
729e4ab9
A
5615 if test "x$ac_ct_RANLIB" = x; then
5616 RANLIB=":"
5617 else
5618 case $cross_compiling:$ac_tool_warned in
5619yes:)
5620{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5621$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5622ac_tool_warned=yes ;;
73c04bcf 5623esac
729e4ab9
A
5624 RANLIB=$ac_ct_RANLIB
5625 fi
5626else
5627 RANLIB="$ac_cv_prog_RANLIB"
5628fi
b75a7d8f 5629
729e4ab9 5630
f3c0d7a5
A
5631# need sed
5632{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
5633$as_echo_n "checking for a sed that does not truncate output... " >&6; }
5634if ${ac_cv_path_SED+:} false; then :
5635 $as_echo_n "(cached) " >&6
5636else
5637 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
5638 for ac_i in 1 2 3 4 5 6 7; do
5639 ac_script="$ac_script$as_nl$ac_script"
5640 done
5641 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
5642 { ac_script=; unset ac_script;}
5643 if test -z "$SED"; then
5644 ac_path_SED_found=false
5645 # Loop through the user's path and test for each of PROGNAME-LIST
5646 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5647for as_dir in $PATH
5648do
5649 IFS=$as_save_IFS
5650 test -z "$as_dir" && as_dir=.
5651 for ac_prog in sed gsed; do
5652 for ac_exec_ext in '' $ac_executable_extensions; do
5653 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
5654 as_fn_executable_p "$ac_path_SED" || continue
5655# Check for GNU ac_path_SED and select it if it is found.
5656 # Check for GNU $ac_path_SED
5657case `"$ac_path_SED" --version 2>&1` in
5658*GNU*)
5659 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
5660*)
5661 ac_count=0
5662 $as_echo_n 0123456789 >"conftest.in"
5663 while :
5664 do
5665 cat "conftest.in" "conftest.in" >"conftest.tmp"
5666 mv "conftest.tmp" "conftest.in"
5667 cp "conftest.in" "conftest.nl"
5668 $as_echo '' >> "conftest.nl"
5669 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
5670 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5671 as_fn_arith $ac_count + 1 && ac_count=$as_val
5672 if test $ac_count -gt ${ac_path_SED_max-0}; then
5673 # Best one so far, save it but keep looking for a better one
5674 ac_cv_path_SED="$ac_path_SED"
5675 ac_path_SED_max=$ac_count
5676 fi
5677 # 10*(2^10) chars as input seems more than enough
5678 test $ac_count -gt 10 && break
5679 done
5680 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5681esac
5682
5683 $ac_path_SED_found && break 3
5684 done
5685 done
5686 done
5687IFS=$as_save_IFS
5688 if test -z "$ac_cv_path_SED"; then
5689 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
5690 fi
5691else
5692 ac_cv_path_SED=$SED
5693fi
5694
5695fi
5696{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
5697$as_echo "$ac_cv_path_SED" >&6; }
5698 SED="$ac_cv_path_SED"
5699 rm -f conftest.sed
5700
5701
729e4ab9 5702# look for 'ar' the proper way
729e4ab9
A
5703if test -n "$ac_tool_prefix"; then
5704 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
5705set dummy ${ac_tool_prefix}ar; ac_word=$2
5706{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5707$as_echo_n "checking for $ac_word... " >&6; }
4388f060 5708if ${ac_cv_prog_AR+:} false; then :
729e4ab9 5709 $as_echo_n "(cached) " >&6
b75a7d8f 5710else
729e4ab9
A
5711 if test -n "$AR"; then
5712 ac_cv_prog_AR="$AR" # Let the user override the test.
5713else
5714as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5715for as_dir in $PATH
5716do
5717 IFS=$as_save_IFS
5718 test -z "$as_dir" && as_dir=.
5719 for ac_exec_ext in '' $ac_executable_extensions; do
b331163b 5720 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
729e4ab9
A
5721 ac_cv_prog_AR="${ac_tool_prefix}ar"
5722 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5723 break 2
5724 fi
5725done
5726 done
5727IFS=$as_save_IFS
5728
5729fi
5730fi
5731AR=$ac_cv_prog_AR
5732if test -n "$AR"; then
5733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
5734$as_echo "$AR" >&6; }
5735else
5736 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5737$as_echo "no" >&6; }
b75a7d8f
A
5738fi
5739
5740
729e4ab9
A
5741fi
5742if test -z "$ac_cv_prog_AR"; then
5743 ac_ct_AR=$AR
5744 # Extract the first word of "ar", so it can be a program name with args.
5745set dummy ar; ac_word=$2
5746{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5747$as_echo_n "checking for $ac_word... " >&6; }
4388f060 5748if ${ac_cv_prog_ac_ct_AR+:} false; then :
729e4ab9
A
5749 $as_echo_n "(cached) " >&6
5750else
5751 if test -n "$ac_ct_AR"; then
5752 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
5753else
5754as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5755for as_dir in $PATH
5756do
5757 IFS=$as_save_IFS
5758 test -z "$as_dir" && as_dir=.
5759 for ac_exec_ext in '' $ac_executable_extensions; do
b331163b 5760 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
729e4ab9
A
5761 ac_cv_prog_ac_ct_AR="ar"
5762 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5763 break 2
5764 fi
5765done
5766 done
5767IFS=$as_save_IFS
5768
5769fi
5770fi
5771ac_ct_AR=$ac_cv_prog_ac_ct_AR
5772if test -n "$ac_ct_AR"; then
5773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
5774$as_echo "$ac_ct_AR" >&6; }
5775else
5776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5777$as_echo "no" >&6; }
5778fi
5779
5780 if test "x$ac_ct_AR" = x; then
4388f060 5781 AR="false"
729e4ab9
A
5782 else
5783 case $cross_compiling:$ac_tool_warned in
5784yes:)
5785{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5786$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5787ac_tool_warned=yes ;;
5788esac
5789 AR=$ac_ct_AR
5790 fi
73c04bcf 5791else
729e4ab9
A
5792 AR="$ac_cv_prog_AR"
5793fi
5794
729e4ab9
A
5795
5796{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable renaming of symbols" >&5
5797$as_echo_n "checking whether to enable renaming of symbols... " >&6; }
5798enabled=yes
5799U_DISABLE_RENAMING=0
5800# Check whether --enable-renaming was given.
5801if test "${enable_renaming+set}" = set; then :
5802 enableval=$enable_renaming; case "${enableval}" in
5803 yes|"") enabled=yes ;;
4388f060
A
5804 no) enabled=no; U_DISABLE_RENAMING=1;
5805 UCONFIG_CPPFLAGS="${UCONFIG_CPPFLAGS} -DU_DISABLE_RENAMING=1"
5806 ;;
729e4ab9
A
5807 *) ;;
5808 esac
5809fi
5810
5811{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enabled" >&5
5812$as_echo "$enabled" >&6; }
5813
5814
5815{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable function and data tracing" >&5
5816$as_echo_n "checking whether to enable function and data tracing... " >&6; }
5817enabled=no
5818U_ENABLE_TRACING=0
5819# Check whether --enable-tracing was given.
5820if test "${enable_tracing+set}" = set; then :
5821 enableval=$enable_tracing; case "${enableval}" in
4388f060
A
5822 yes|"") enabled=yes;
5823 CONFIG_CPPFLAGS="$CONFIG_CPPFLAGS -DU_ENABLE_TRACING=1";
5824 U_ENABLE_TRACING=1 ;;
729e4ab9
A
5825 no) enabled=no; U_ENABLE_TRACING=0 ;;
5826 *) ;;
5827 esac
5828fi
5829
5830{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enabled" >&5
5831$as_echo "$enabled" >&6; }
5832
5833
57a6839d
A
5834# check if elf.h is present.
5835for ac_header in elf.h
5836do :
5837 ac_fn_c_check_header_mongrel "$LINENO" "elf.h" "ac_cv_header_elf_h" "$ac_includes_default"
5838if test "x$ac_cv_header_elf_h" = xyes; then :
5839 cat >>confdefs.h <<_ACEOF
5840#define HAVE_ELF_H 1
5841_ACEOF
5842
5843fi
5844
5845done
5846
5847if test "x$ac_cv_header_elf_h" = "xyes"; then
5848 CONFIG_CPPFLAGS="$CONFIG_CPPFLAGS -DU_HAVE_ELF_H=1";
5849fi
729e4ab9 5850
2ca993e8
A
5851# Enable/disable plugins
5852# Check whether --enable-plugins was given.
5853if test "${enable_plugins+set}" = set; then :
5854 enableval=$enable_plugins; case "${enableval}" in
5855 yes) plugins=true ;;
5856 no) plugins=false ;;
5857 *) as_fn_error $? "bad value ${enableval} for --enable-plugins" "$LINENO" 5 ;;
5858 esac
5859else
5860 plugins=false
5861fi
5862
5863
5864
5865if test "$plugins" = true; then
5866 PLUGINS_TRUE=
5867 U_HAVE_PLUGINS=1
5868else
5869 PLUGINS_TRUE='#'
5870 U_HAVE_PLUGINS=0
5871fi
5872
5873if test "x$plugins" = "xtrue"; then
5874 UCONFIG_CPPFLAGS="$UCONFIG_CPPFLAGS -DUCONFIG_ENABLE_PLUGINS=1"
5875fi
5876
5877
729e4ab9 5878U_ENABLE_DYLOAD=1
4388f060 5879enable=yes
2ca993e8
A
5880{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable dynamic loading of plugins. Ignored if plugins disabled." >&5
5881$as_echo_n "checking whether to enable dynamic loading of plugins. Ignored if plugins disabled.... " >&6; }
729e4ab9
A
5882# Check whether --enable-dyload was given.
5883if test "${enable_dyload+set}" = set; then :
5884 enableval=$enable_dyload; case "${enableval}" in
5885 yes|"")
5886 U_ENABLE_DYLOAD=1
4388f060
A
5887 enable=yes
5888 ;;
729e4ab9
A
5889 no)
5890 U_ENABLE_DYLOAD=0;
4388f060
A
5891 enable=no;
5892 CONFIG_CPPFLAGS="$CONFIG_CPPFLAGS -DU_ENABLE_DYLOAD=0";
5893 ;;
729e4ab9
A
5894 *) ;;
5895 esac
5896fi
5897
4388f060
A
5898{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable" >&5
5899$as_echo "$enable" >&6; }
729e4ab9
A
5900
5901
4388f060
A
5902if test "$enable" = "yes"; then
5903 for ac_header in dlfcn.h
729e4ab9
A
5904do :
5905 ac_fn_c_check_header_mongrel "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default"
4388f060 5906if test "x$ac_cv_header_dlfcn_h" = xyes; then :
729e4ab9
A
5907 cat >>confdefs.h <<_ACEOF
5908#define HAVE_DLFCN_H 1
73c04bcf 5909_ACEOF
73c04bcf 5910
729e4ab9 5911fi
73c04bcf 5912
729e4ab9 5913done
b75a7d8f 5914
4388f060
A
5915 #AC_MSG_RESULT($enabled)
5916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
729e4ab9 5917$as_echo_n "checking for library containing dlopen... " >&6; }
4388f060 5918if ${ac_cv_search_dlopen+:} false; then :
729e4ab9
A
5919 $as_echo_n "(cached) " >&6
5920else
5921 ac_func_search_save_LIBS=$LIBS
5922cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5923/* end confdefs.h. */
b75a7d8f 5924
729e4ab9
A
5925/* Override any GCC internal prototype to avoid an error.
5926 Use char because int might match the return type of a GCC
73c04bcf 5927 builtin and then its argument prototype would still apply. */
73c04bcf 5928#ifdef __cplusplus
729e4ab9 5929extern "C"
b75a7d8f 5930#endif
729e4ab9 5931char dlopen ();
73c04bcf
A
5932int
5933main ()
5934{
729e4ab9 5935return dlopen ();
73c04bcf
A
5936 ;
5937 return 0;
5938}
5939_ACEOF
729e4ab9
A
5940for ac_lib in '' dl; do
5941 if test -z "$ac_lib"; then
5942 ac_res="none required"
5943 else
5944 ac_res=-l$ac_lib
5945 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
5946 fi
5947 if ac_fn_c_try_link "$LINENO"; then :
5948 ac_cv_search_dlopen=$ac_res
5949fi
5950rm -f core conftest.err conftest.$ac_objext \
5951 conftest$ac_exeext
4388f060 5952 if ${ac_cv_search_dlopen+:} false; then :
729e4ab9
A
5953 break
5954fi
5955done
4388f060 5956if ${ac_cv_search_dlopen+:} false; then :
729e4ab9 5957
73c04bcf 5958else
729e4ab9
A
5959 ac_cv_search_dlopen=no
5960fi
5961rm conftest.$ac_ext
5962LIBS=$ac_func_search_save_LIBS
5963fi
5964{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
5965$as_echo "$ac_cv_search_dlopen" >&6; }
5966ac_res=$ac_cv_search_dlopen
5967if test "$ac_res" != no; then :
5968 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
73c04bcf 5969
73c04bcf 5970fi
729e4ab9 5971
4388f060 5972 for ac_func in dlopen
729e4ab9
A
5973do :
5974 ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
4388f060 5975if test "x$ac_cv_func_dlopen" = xyes; then :
729e4ab9
A
5976 cat >>confdefs.h <<_ACEOF
5977#define HAVE_DLOPEN 1
5978_ACEOF
5979
73c04bcf 5980fi
729e4ab9
A
5981done
5982
729e4ab9 5983
4388f060
A
5984 if test "x$ac_cv_func_dlopen" != xyes; then
5985 CONFIG_CPPFLAGS="$CONFIG_CPPFLAGS -DHAVE_DLOPEN=0"
5986 fi
5987fi
729e4ab9
A
5988
5989# Check for miscellanous functions.
729e4ab9
A
5990# So, use for putil / tools only.
5991# Note that this will generate HAVE_GETTIMEOFDAY, not U_HAVE_GETTIMEOFDAY
729e4ab9
A
5992for ac_func in gettimeofday
5993do :
5994 ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday"
4388f060 5995if test "x$ac_cv_func_gettimeofday" = xyes; then :
729e4ab9
A
5996 cat >>confdefs.h <<_ACEOF
5997#define HAVE_GETTIMEOFDAY 1
5998_ACEOF
5999
6000fi
6001done
6002
6003
4388f060 6004
729e4ab9
A
6005# Check whether to use the evil rpath or not
6006# Check whether --enable-rpath was given.
6007if test "${enable_rpath+set}" = set; then :
6008 enableval=$enable_rpath; case "${enableval}" in
6009 yes|"") ENABLE_RPATH=YES ;;
6010 no) ;;
6011 *) ;;
6012 esac
b75a7d8f 6013else
729e4ab9
A
6014 ENABLE_RPATH=NO
6015
b75a7d8f
A
6016fi
6017
729e4ab9
A
6018
6019
6020
b75a7d8f 6021
729e4ab9 6022ac_ext=cpp
b75a7d8f 6023ac_cpp='$CXXCPP $CPPFLAGS'
73c04bcf
A
6024ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6025ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6026ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6027
729e4ab9
A
6028{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have a C++ compiler" >&5
6029$as_echo_n "checking if we have a C++ compiler... " >&6; }
6030cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 6031/* end confdefs.h. */
73c04bcf
A
6032
6033int
6034main ()
6035{
729e4ab9 6036
73c04bcf
A
6037 ;
6038 return 0;
6039}
6040_ACEOF
729e4ab9
A
6041if ac_fn_cxx_try_compile "$LINENO"; then :
6042 cxx_okay=yes
b75a7d8f 6043else
729e4ab9 6044 cxx_okay=no
b75a7d8f 6045fi
729e4ab9
A
6046rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6047if test $cxx_okay = yes
b75a7d8f 6048then
4388f060
A
6049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Good" >&5
6050$as_echo "Good" >&6; }
729e4ab9
A
6051else
6052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6053$as_echo "no" >&6; }
6054 as_fn_error $? "C++ compiler $CXX does not work or no compiler found" "$LINENO" 5
b75a7d8f
A
6055fi
6056
57a6839d 6057if [ "$GXX" = yes ]; then
f3c0d7a5 6058 # if CXXFLAGS does not have a "-std=" setting, set it now to -std=c++11,
57a6839d
A
6059 # and check that the compiler still works.
6060 if ! echo "$CXXFLAGS" | grep '\-std=' >/dev/null 2>&1; then
6061 OLD_CXXFLAGS="${CXXFLAGS}"
f3c0d7a5 6062 CXXFLAGS="$CXXFLAGS -std=c++11"
57a6839d
A
6063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have a C++11 compiler" >&5
6064$as_echo_n "checking if we have a C++11 compiler... " >&6; }
6065 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6066/* end confdefs.h. */
6067
6068int
6069main ()
6070{
6071
6072 ;
6073 return 0;
6074}
6075_ACEOF
6076if ac_fn_cxx_try_compile "$LINENO"; then :
6077 cxx11_okay=yes
6078else
6079 cxx11_okay=no
6080fi
6081rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cxx11_okay" >&5
6083$as_echo "$cxx11_okay" >&6; }
6084 if [ $cxx11_okay = yes ]; then
f3c0d7a5
A
6085 { $as_echo "$as_me:${as_lineno-$LINENO}: Adding CXXFLAGS option -std=c++11" >&5
6086$as_echo "$as_me: Adding CXXFLAGS option -std=c++11" >&6;}
6087 UCONFIG_CXXFLAGS="${UCONFIG_CXXFLAGS} -std=c++11"
57a6839d
A
6088 else
6089 CXXFLAGS="$OLD_CXXFLAGS"
6090 fi
f3c0d7a5
A
6091 case "${host}" in
6092 *-*-solaris*)
6093 CXXFLAGS="$OLD_CXXFLAGS"
6094 ;;
6095 esac
57a6839d
A
6096 fi
6097fi
6098
729e4ab9
A
6099ac_ext=c
6100ac_cpp='$CPP $CPPFLAGS'
6101ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6102ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6103ac_compiler_gnu=$ac_cv_c_compiler_gnu
6104
6105
51004dcb 6106# Always build ICU with multi-threading support.
729e4ab9
A
6107OLD_LIBS=${LIBS}
6108
2ca993e8
A
6109# For Compaq Tru64 (OSF1), we must look for pthread_attr_init
6110# and must do this before seaching for pthread_mutex_destroy, or
6111# we will pick up libpthreads.so not libpthread.so
6112# If this fails, then we must test for HPUX specials, before
6113# moving on to a more generic test
729e4ab9 6114
2ca993e8 6115{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_attr_init in -lpthread" >&5
729e4ab9 6116$as_echo_n "checking for pthread_attr_init in -lpthread... " >&6; }
4388f060 6117if ${ac_cv_lib_pthread_pthread_attr_init+:} false; then :
729e4ab9 6118 $as_echo_n "(cached) " >&6
73c04bcf 6119else
729e4ab9
A
6120 ac_check_lib_save_LIBS=$LIBS
6121LIBS="-lpthread $LIBS"
6122cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 6123/* end confdefs.h. */
73c04bcf 6124
729e4ab9
A
6125/* Override any GCC internal prototype to avoid an error.
6126 Use char because int might match the return type of a GCC
6127 builtin and then its argument prototype would still apply. */
6128#ifdef __cplusplus
6129extern "C"
6130#endif
6131char pthread_attr_init ();
73c04bcf
A
6132int
6133main ()
6134{
729e4ab9 6135return pthread_attr_init ();
73c04bcf
A
6136 ;
6137 return 0;
6138}
6139_ACEOF
729e4ab9
A
6140if ac_fn_c_try_link "$LINENO"; then :
6141 ac_cv_lib_pthread_pthread_attr_init=yes
b75a7d8f 6142else
729e4ab9 6143 ac_cv_lib_pthread_pthread_attr_init=no
b75a7d8f 6144fi
729e4ab9
A
6145rm -f core conftest.err conftest.$ac_objext \
6146 conftest$ac_exeext conftest.$ac_ext
6147LIBS=$ac_check_lib_save_LIBS
b75a7d8f 6148fi
729e4ab9
A
6149{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_attr_init" >&5
6150$as_echo "$ac_cv_lib_pthread_pthread_attr_init" >&6; }
4388f060 6151if test "x$ac_cv_lib_pthread_pthread_attr_init" = xyes; then :
729e4ab9
A
6152 cat >>confdefs.h <<_ACEOF
6153#define HAVE_LIBPTHREAD 1
6154_ACEOF
b75a7d8f 6155
729e4ab9 6156 LIBS="-lpthread $LIBS"
b75a7d8f 6157
729e4ab9 6158fi
b75a7d8f 6159
2ca993e8
A
6160if test $ac_cv_lib_pthread_pthread_attr_init = yes; then
6161 :
6162else
6163 # Locate the right library for POSIX threads. We look for the
6164 # symbols in the libraries first, because on Solaris libc provides
6165 # pthread_create but libpthread has the real code :(
6166 # AIX uses libpthreads instead of libpthread, and HP/UX uses libpthread
6167 # FreeBSD users may need libpthread if they do not have libc_r.
b75a7d8f 6168
73c04bcf 6169
729e4ab9
A
6170{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing pthread_mutex_destroy" >&5
6171$as_echo_n "checking for library containing pthread_mutex_destroy... " >&6; }
4388f060 6172if ${ac_cv_search_pthread_mutex_destroy+:} false; then :
729e4ab9 6173 $as_echo_n "(cached) " >&6
73c04bcf 6174else
729e4ab9
A
6175 ac_func_search_save_LIBS="$LIBS"
6176ac_cv_search_pthread_mutex_destroy="no"
6177for i in pthread pthreads c_r ; do
6178LIBS="-l$i $ac_func_search_save_LIBS"
6179cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 6180/* end confdefs.h. */
b75a7d8f 6181
729e4ab9
A
6182/* Override any GCC internal prototype to avoid an error.
6183 Use char because int might match the return type of a GCC
6184 builtin and then its argument prototype would still apply. */
73c04bcf
A
6185#ifdef __cplusplus
6186extern "C"
73c04bcf 6187#endif
729e4ab9
A
6188char pthread_mutex_destroy ();
6189int
6190main ()
6191{
6192return pthread_mutex_destroy ();
6193 ;
6194 return 0;
6195}
6196_ACEOF
6197if ac_fn_c_try_link "$LINENO"; then :
6198 ac_cv_search_pthread_mutex_destroy="-l$i"
6199break
6200fi
6201rm -f core conftest.err conftest.$ac_objext \
6202 conftest$ac_exeext conftest.$ac_ext
6203done
6204if test "$ac_cv_search_pthread_mutex_destroy" = "no"; then
6205cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6206/* end confdefs.h. */
6207
6208/* Override any GCC internal prototype to avoid an error.
6209 Use char because int might match the return type of a GCC
73c04bcf 6210 builtin and then its argument prototype would still apply. */
729e4ab9
A
6211#ifdef __cplusplus
6212extern "C"
73c04bcf 6213#endif
729e4ab9
A
6214char pthread_mutex_destroy ();
6215int
6216main ()
6217{
6218return pthread_mutex_destroy ();
6219 ;
6220 return 0;
6221}
6222_ACEOF
6223if ac_fn_c_try_link "$LINENO"; then :
6224 ac_cv_search_pthread_mutex_destroy="none required"
6225fi
6226rm -f core conftest.err conftest.$ac_objext \
6227 conftest$ac_exeext conftest.$ac_ext
6228fi
6229LIBS="$ac_func_search_save_LIBS"
6230fi
6231{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_pthread_mutex_destroy" >&5
6232$as_echo "$ac_cv_search_pthread_mutex_destroy" >&6; }
6233if test "$ac_cv_search_pthread_mutex_destroy" != "no"; then
6234 test "$ac_cv_search_pthread_mutex_destroy" = "none required" || LIBS="$ac_cv_search_pthread_mutex_destroy $LIBS"
6235
6236else :
6237
6238fi
6239
2ca993e8
A
6240 if test "$ac_cv_search_pthread_mutex_destroy" != no; then
6241 :
6242 else
6243 # For HP 11
6244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_mutex_init in -lpthread" >&5
729e4ab9 6245$as_echo_n "checking for pthread_mutex_init in -lpthread... " >&6; }
4388f060 6246if ${ac_cv_lib_pthread_pthread_mutex_init+:} false; then :
729e4ab9
A
6247 $as_echo_n "(cached) " >&6
6248else
6249 ac_check_lib_save_LIBS=$LIBS
6250LIBS="-lpthread $LIBS"
6251cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6252/* end confdefs.h. */
6253
6254/* Override any GCC internal prototype to avoid an error.
6255 Use char because int might match the return type of a GCC
6256 builtin and then its argument prototype would still apply. */
73c04bcf 6257#ifdef __cplusplus
729e4ab9 6258extern "C"
b75a7d8f 6259#endif
729e4ab9 6260char pthread_mutex_init ();
73c04bcf
A
6261int
6262main ()
6263{
729e4ab9 6264return pthread_mutex_init ();
73c04bcf
A
6265 ;
6266 return 0;
6267}
6268_ACEOF
729e4ab9
A
6269if ac_fn_c_try_link "$LINENO"; then :
6270 ac_cv_lib_pthread_pthread_mutex_init=yes
73c04bcf 6271else
729e4ab9
A
6272 ac_cv_lib_pthread_pthread_mutex_init=no
6273fi
6274rm -f core conftest.err conftest.$ac_objext \
6275 conftest$ac_exeext conftest.$ac_ext
6276LIBS=$ac_check_lib_save_LIBS
6277fi
6278{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_mutex_init" >&5
6279$as_echo "$ac_cv_lib_pthread_pthread_mutex_init" >&6; }
4388f060 6280if test "x$ac_cv_lib_pthread_pthread_mutex_init" = xyes; then :
729e4ab9
A
6281 cat >>confdefs.h <<_ACEOF
6282#define HAVE_LIBPTHREAD 1
6283_ACEOF
6284
6285 LIBS="-lpthread $LIBS"
73c04bcf 6286
73c04bcf 6287fi
729e4ab9 6288
2ca993e8
A
6289 if test $ac_cv_lib_pthread_pthread_mutex_init = yes; then
6290 :
729e4ab9 6291 fi
2ca993e8 6292 fi
729e4ab9 6293
2ca993e8 6294 ac_fn_c_check_func "$LINENO" "pthread_mutex_lock" "ac_cv_func_pthread_mutex_lock"
4388f060 6295if test "x$ac_cv_func_pthread_mutex_lock" = xyes; then :
729e4ab9 6296
73c04bcf 6297fi
b75a7d8f 6298
729e4ab9 6299
2ca993e8
A
6300 if test $ac_cv_func_pthread_mutex_lock = yes; then
6301 :
729e4ab9 6302 fi
2ca993e8
A
6303fi
6304# Check to see if we are using CygWin with MSVC
6305case "${host}" in
6306*-pc-cygwin*|*-pc-mingw*)
6307 # For gcc, the thread options are set by mh-mingw/mh-cygwin
6308 # For msvc, the thread options are set by runConfigureICU
6309 :
6310 ;;
6311*-*-hpux*)
6312 # Add -mt because it does several nice things on newer compilers.
6313 case "${icu_cv_host_frag}" in
6314 mh-hpux-acc)
6315 OLD_CXXFLAGS="${CXXFLAGS}"
6316 CXXFLAGS="${CXXFLAGS} -mt"
6317 if test x"`${CXX} ${CXXFLAGS} 2>&1`" != x""; then
6318 CXXFLAGS="${OLD_CXXFLAGS}"
6319 else
6320 UCONFIG_CXXFLAGS="${UCONFIG_CXXFLAGS} -mt"
6321 fi
729e4ab9 6322 ;;
2ca993e8
A
6323 esac
6324 ;;
6325*-*-solaris*)
6326 case "${icu_cv_host_frag}" in
6327 mh-solaris)
6328 LIBS="${LIBS} -mt"
729e4ab9
A
6329 ;;
6330 esac
2ca993e8
A
6331 ;;
6332esac
b75a7d8f 6333
729e4ab9
A
6334# Check whether --enable-weak-threads was given.
6335if test "${enable_weak_threads+set}" = set; then :
6336 enableval=$enable_weak_threads; case "${enableval}" in
6337 yes)
6338 LIB_THREAD="${LIBS%${OLD_LIBS}}"
6339 LIBS=${OLD_LIBS}
6340 ;;
6341 no) ;;
6342 *) as_fn_error $? "bad value ${enableval} for --enable-weak-threads" "$LINENO" 5 ;;
6343 esac
6344fi
73c04bcf 6345
b75a7d8f 6346
b75a7d8f 6347
729e4ab9 6348# Check for mmap()
b75a7d8f 6349
729e4ab9
A
6350# The AC_FUNC_MMAP macro doesn't work properly. It seems to be too specific.
6351# Do this check instead.
6352HAVE_MMAP=0
6353{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for mmap" >&5
6354$as_echo_n "checking for mmap... " >&6; }
4388f060 6355if ${ac_cv_func_mmap_ok+:} false; then :
729e4ab9
A
6356 $as_echo_n "(cached) " >&6
6357else
6358 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6359/* end confdefs.h. */
6360#include <unistd.h>
6361#include <sys/mman.h>
6362#include <sys/stat.h>
6363#include <fcntl.h>
73c04bcf
A
6364int
6365main ()
6366{
729e4ab9 6367mmap((void *)0, 0, PROT_READ, 0, 0, 0);
73c04bcf
A
6368 ;
6369 return 0;
6370}
6371_ACEOF
729e4ab9
A
6372if ac_fn_c_try_link "$LINENO"; then :
6373 ac_cv_func_mmap_ok=yes
73c04bcf 6374else
729e4ab9 6375 ac_cv_func_mmap_ok=no
73c04bcf 6376fi
729e4ab9
A
6377rm -f core conftest.err conftest.$ac_objext \
6378 conftest$ac_exeext conftest.$ac_ext
73c04bcf 6379fi
b75a7d8f 6380
729e4ab9
A
6381{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_ok" >&5
6382$as_echo "$ac_cv_func_mmap_ok" >&6; }
6383if test $ac_cv_func_mmap_ok = yes
b75a7d8f 6384then
729e4ab9 6385 HAVE_MMAP=1
4388f060
A
6386else
6387 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_MMAP=0"
729e4ab9 6388fi
73c04bcf 6389
73c04bcf 6390
729e4ab9
A
6391{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for genccode assembly" >&5
6392$as_echo_n "checking for genccode assembly... " >&6; }
6393
6394# Check to see if genccode can generate simple assembly.
6395GENCCODE_ASSEMBLY=
6396case "${host}" in
4388f060 6397*-linux*|*-kfreebsd*-gnu*|i*86-*-*bsd*|i*86-pc-gnu)
729e4ab9
A
6398 if test "$GCC" = yes; then
6399 # We're using gcc, and the simple -a gcc command line works for genccode
6400 GENCCODE_ASSEMBLY="-a gcc"
6401 fi ;;
6402i*86-*-solaris*)
6403 if test "$GCC" = yes; then
6404 # When using gcc, look if we're also using GNU as.
6405 # When using GNU as, the simple -a gcc command line works for genccode.
6406 asv=`"${CC}" -print-prog-name=as 2>/dev/null`
6407 asv=`"${asv}" --version 2>/dev/null`
6408 case "X${asv}" in
6409 X*GNU*) GENCCODE_ASSEMBLY="-a gcc" ;;
6410 X*) GENCCODE_ASSEMBLY="-a sun-x86" ;;
6411 esac
6412 unset asv
6413 else
6414 GENCCODE_ASSEMBLY="-a sun-x86"
6415 fi ;;
6416sparc-*-solaris*)
6417 GENCCODE_ASSEMBLY="-a sun"
6418 ;;
6419ia64-*-hpux*)
2ca993e8
A
6420# There has been some issues with building ICU data on HPUX ia64 aCC
6421# when using the assemble code setting below. For now, build without
6422# assemble code for this platform. This will increase the build time.
6423# GENCCODE_ASSEMBLY="-a aCC-ia64"
729e4ab9
A
6424 ;;
6425esac
b75a7d8f 6426
b75a7d8f 6427
729e4ab9
A
6428{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $GENCCODE_ASSEMBLY" >&5
6429$as_echo "$GENCCODE_ASSEMBLY" >&6; }
b75a7d8f 6430
729e4ab9
A
6431# Checks for header files
6432for ac_header in inttypes.h
6433do :
6434 ac_fn_c_check_header_mongrel "$LINENO" "inttypes.h" "ac_cv_header_inttypes_h" "$ac_includes_default"
4388f060 6435if test "x$ac_cv_header_inttypes_h" = xyes; then :
729e4ab9
A
6436 cat >>confdefs.h <<_ACEOF
6437#define HAVE_INTTYPES_H 1
73c04bcf 6438_ACEOF
73c04bcf 6439
73c04bcf 6440fi
729e4ab9
A
6441
6442done
6443
6444if test $ac_cv_header_inttypes_h = no; then
6445 U_HAVE_INTTYPES_H=0
4388f060 6446 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_INTTYPES_H=0"
729e4ab9
A
6447else
6448 U_HAVE_INTTYPES_H=1
6449fi
6450if test "$CC" = ccc; then
6451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: \"C compiler set to CCC ${CC}\" " >&5
6452$as_echo "\"C compiler set to CCC ${CC}\" " >&6; }
6453 case "${host}" in
6454 alpha*-*-*) U_HAVE_INTTYPES_H=0;
4388f060 6455 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_INTTYPES_H=0"
729e4ab9
A
6456 esac
6457fi
6458
6459
6460
6461for ac_header in dirent.h
6462do :
6463 ac_fn_c_check_header_mongrel "$LINENO" "dirent.h" "ac_cv_header_dirent_h" "$ac_includes_default"
4388f060 6464if test "x$ac_cv_header_dirent_h" = xyes; then :
729e4ab9
A
6465 cat >>confdefs.h <<_ACEOF
6466#define HAVE_DIRENT_H 1
6467_ACEOF
6468
73c04bcf 6469fi
b75a7d8f 6470
729e4ab9
A
6471done
6472
6473if test $ac_cv_header_dirent_h = no; then
6474 U_HAVE_DIRENT_H=0
4388f060 6475 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_DIRENT_H=0"
729e4ab9
A
6476else
6477 U_HAVE_DIRENT_H=1
b75a7d8f
A
6478fi
6479
374ca955
A
6480
6481
729e4ab9
A
6482# Check for endianness
6483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
6484$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
4388f060 6485if ${ac_cv_c_bigendian+:} false; then :
729e4ab9 6486 $as_echo_n "(cached) " >&6
b75a7d8f 6487else
729e4ab9
A
6488 ac_cv_c_bigendian=unknown
6489 # See if we're dealing with a universal compiler.
6490 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 6491/* end confdefs.h. */
729e4ab9
A
6492#ifndef __APPLE_CC__
6493 not a universal capable compiler
6494 #endif
6495 typedef int dummy;
6496
6497_ACEOF
6498if ac_fn_c_try_compile "$LINENO"; then :
6499
6500 # Check for potential -arch flags. It is not universal unless
6501 # there are at least two -arch flags with different values.
6502 ac_arch=
6503 ac_prev=
6504 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
6505 if test -n "$ac_prev"; then
6506 case $ac_word in
6507 i?86 | x86_64 | ppc | ppc64)
6508 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
6509 ac_arch=$ac_word
6510 else
6511 ac_cv_c_bigendian=universal
6512 break
6513 fi
6514 ;;
6515 esac
6516 ac_prev=
6517 elif test "x$ac_word" = "x-arch"; then
6518 ac_prev=arch
6519 fi
6520 done
6521fi
6522rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6523 if test $ac_cv_c_bigendian = unknown; then
6524 # See if sys/param.h defines the BYTE_ORDER macro.
6525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6526/* end confdefs.h. */
6527#include <sys/types.h>
6528 #include <sys/param.h>
b75a7d8f 6529
73c04bcf
A
6530int
6531main ()
6532{
729e4ab9
A
6533#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
6534 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
6535 && LITTLE_ENDIAN)
6536 bogus endian macros
6537 #endif
6538
73c04bcf
A
6539 ;
6540 return 0;
6541}
6542_ACEOF
729e4ab9
A
6543if ac_fn_c_try_compile "$LINENO"; then :
6544 # It does; now see whether it defined to BIG_ENDIAN or not.
6545 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 6546/* end confdefs.h. */
729e4ab9
A
6547#include <sys/types.h>
6548 #include <sys/param.h>
6549
73c04bcf
A
6550int
6551main ()
6552{
729e4ab9
A
6553#if BYTE_ORDER != BIG_ENDIAN
6554 not big endian
6555 #endif
6556
73c04bcf
A
6557 ;
6558 return 0;
6559}
6560_ACEOF
729e4ab9
A
6561if ac_fn_c_try_compile "$LINENO"; then :
6562 ac_cv_c_bigendian=yes
b75a7d8f 6563else
729e4ab9 6564 ac_cv_c_bigendian=no
b75a7d8f 6565fi
729e4ab9 6566rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
b75a7d8f 6567fi
729e4ab9
A
6568rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6569 fi
6570 if test $ac_cv_c_bigendian = unknown; then
6571 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
6572 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 6573/* end confdefs.h. */
729e4ab9
A
6574#include <limits.h>
6575
73c04bcf
A
6576int
6577main ()
6578{
729e4ab9
A
6579#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
6580 bogus endian macros
6581 #endif
6582
73c04bcf
A
6583 ;
6584 return 0;
6585}
6586_ACEOF
729e4ab9
A
6587if ac_fn_c_try_compile "$LINENO"; then :
6588 # It does; now see whether it defined to _BIG_ENDIAN or not.
6589 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 6590/* end confdefs.h. */
729e4ab9
A
6591#include <limits.h>
6592
73c04bcf
A
6593int
6594main ()
6595{
729e4ab9
A
6596#ifndef _BIG_ENDIAN
6597 not big endian
6598 #endif
6599
73c04bcf
A
6600 ;
6601 return 0;
6602}
6603_ACEOF
729e4ab9
A
6604if ac_fn_c_try_compile "$LINENO"; then :
6605 ac_cv_c_bigendian=yes
b75a7d8f 6606else
729e4ab9 6607 ac_cv_c_bigendian=no
b75a7d8f 6608fi
729e4ab9 6609rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
b75a7d8f 6610fi
729e4ab9
A
6611rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6612 fi
6613 if test $ac_cv_c_bigendian = unknown; then
6614 # Compile a test program.
6615 if test "$cross_compiling" = yes; then :
6616 # Try to guess by grepping values from an object file.
6617 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 6618/* end confdefs.h. */
729e4ab9
A
6619short int ascii_mm[] =
6620 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
6621 short int ascii_ii[] =
6622 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
6623 int use_ascii (int i) {
6624 return ascii_mm[i] + ascii_ii[i];
6625 }
6626 short int ebcdic_ii[] =
6627 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
6628 short int ebcdic_mm[] =
6629 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
6630 int use_ebcdic (int i) {
6631 return ebcdic_mm[i] + ebcdic_ii[i];
6632 }
6633 extern int foo;
6634
73c04bcf
A
6635int
6636main ()
6637{
729e4ab9 6638return use_ascii (foo) == use_ebcdic (foo);
73c04bcf
A
6639 ;
6640 return 0;
6641}
6642_ACEOF
729e4ab9
A
6643if ac_fn_c_try_compile "$LINENO"; then :
6644 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
6645 ac_cv_c_bigendian=yes
6646 fi
6647 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
6648 if test "$ac_cv_c_bigendian" = unknown; then
6649 ac_cv_c_bigendian=no
6650 else
6651 # finding both strings is unlikely to happen, but who knows?
6652 ac_cv_c_bigendian=unknown
6653 fi
6654 fi
6655fi
6656rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6657else
6658 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf
A
6659/* end confdefs.h. */
6660$ac_includes_default
6661int
6662main ()
6663{
729e4ab9
A
6664
6665 /* Are we little or big endian? From Harbison&Steele. */
6666 union
6667 {
6668 long int l;
6669 char c[sizeof (long int)];
6670 } u;
6671 u.l = 1;
6672 return u.c[sizeof (long int) - 1] == 1;
6673
73c04bcf
A
6674 ;
6675 return 0;
6676}
6677_ACEOF
729e4ab9
A
6678if ac_fn_c_try_run "$LINENO"; then :
6679 ac_cv_c_bigendian=no
b75a7d8f 6680else
729e4ab9 6681 ac_cv_c_bigendian=yes
b75a7d8f 6682fi
729e4ab9
A
6683rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6684 conftest.$ac_objext conftest.beam conftest.$ac_ext
73c04bcf 6685fi
b75a7d8f 6686
729e4ab9 6687 fi
b75a7d8f 6688fi
729e4ab9
A
6689{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
6690$as_echo "$ac_cv_c_bigendian" >&6; }
6691 case $ac_cv_c_bigendian in #(
6692 yes)
6693 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
6694;; #(
6695 no)
6696 ;; #(
6697 universal)
6698
6699$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
6700
6701 ;; #(
6702 *)
6703 as_fn_error $? "unknown endianness
6704 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
6705 esac
b75a7d8f 6706
729e4ab9
A
6707if test $ac_cv_c_bigendian = no; then
6708U_IS_BIG_ENDIAN=0
6709U_ENDIAN_CHAR="l"
b75a7d8f 6710else
729e4ab9
A
6711U_IS_BIG_ENDIAN=1
6712U_ENDIAN_CHAR="b"
73c04bcf 6713fi
73c04bcf 6714
b75a7d8f 6715
729e4ab9
A
6716# Do various POSIX related checks
6717U_HAVE_NL_LANGINFO_CODESET=0
6718U_NL_LANGINFO_CODESET=-1
6719ac_fn_c_check_func "$LINENO" "nl_langinfo" "ac_cv_func_nl_langinfo"
4388f060 6720if test "x$ac_cv_func_nl_langinfo" = xyes; then :
729e4ab9
A
6721 U_HAVE_NL_LANGINFO=1
6722else
6723 U_HAVE_NL_LANGINFO=0
b75a7d8f
A
6724fi
6725
729e4ab9
A
6726if test $U_HAVE_NL_LANGINFO -eq 1; then
6727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo's argument to obtain the codeset" >&5
6728$as_echo_n "checking for nl_langinfo's argument to obtain the codeset... " >&6; }
4388f060 6729if ${ac_cv_nl_langinfo_codeset+:} false; then :
729e4ab9 6730 $as_echo_n "(cached) " >&6
b75a7d8f 6731else
729e4ab9
A
6732 ac_cv_nl_langinfo_codeset="unknown"
6733 for a in CODESET _NL_CTYPE_CODESET_NAME; do
6734 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 6735/* end confdefs.h. */
729e4ab9 6736#include <langinfo.h>
73c04bcf
A
6737int
6738main ()
6739{
729e4ab9 6740nl_langinfo($a);
73c04bcf
A
6741 ;
6742 return 0;
6743}
6744_ACEOF
729e4ab9
A
6745if ac_fn_c_try_link "$LINENO"; then :
6746 ac_cv_nl_langinfo_codeset="$a"; break
b75a7d8f 6747fi
729e4ab9
A
6748rm -f core conftest.err conftest.$ac_objext \
6749 conftest$ac_exeext conftest.$ac_ext
6750 done
6751fi
6752{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_nl_langinfo_codeset" >&5
6753$as_echo "$ac_cv_nl_langinfo_codeset" >&6; }
6754 if test x$ac_cv_nl_langinfo_codeset != xunknown
6755 then
6756 U_HAVE_NL_LANGINFO_CODESET=1
6757 U_NL_LANGINFO_CODESET=$ac_cv_nl_langinfo_codeset
4388f060
A
6758 if test "x${ac_cv_nl_langinfo_codeset}" != "xCODESET"
6759 then
6760 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DNL_LANGINFO_CODESET=${ac_cv_nl_langinfo_codeset}"
6761 fi
6762 else
6763 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_NL_LANGINFO_CODESET=0"
729e4ab9 6764 fi
73c04bcf 6765fi
73c04bcf 6766
b75a7d8f 6767
b75a7d8f 6768
729e4ab9
A
6769# Namespace support checks
6770ac_ext=cpp
6771ac_cpp='$CXXCPP $CPPFLAGS'
6772ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6773ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6774ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
6775
6776{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for namespace support" >&5
6777$as_echo_n "checking for namespace support... " >&6; }
4388f060 6778if ${ac_cv_namespace_ok+:} false; then :
729e4ab9 6779 $as_echo_n "(cached) " >&6
b75a7d8f 6780else
729e4ab9 6781 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 6782/* end confdefs.h. */
729e4ab9
A
6783namespace x_version {void f(){}}
6784 namespace x = x_version;
6785 using namespace x_version;
6786
73c04bcf
A
6787int
6788main ()
729e4ab9
A
6789{
6790f();
73c04bcf
A
6791 ;
6792 return 0;
6793}
6794_ACEOF
729e4ab9
A
6795if ac_fn_cxx_try_link "$LINENO"; then :
6796 ac_cv_namespace_ok=yes
b75a7d8f 6797else
729e4ab9 6798 ac_cv_namespace_ok=no
b75a7d8f 6799fi
729e4ab9
A
6800rm -f core conftest.err conftest.$ac_objext \
6801 conftest$ac_exeext conftest.$ac_ext
73c04bcf 6802fi
b75a7d8f 6803
729e4ab9
A
6804{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_namespace_ok" >&5
6805$as_echo "$ac_cv_namespace_ok" >&6; }
729e4ab9
A
6806if test $ac_cv_namespace_ok = no
6807then
4388f060 6808 as_fn_error $? "Namespace support is required to build ICU." "$LINENO" 5
b75a7d8f
A
6809fi
6810
729e4ab9
A
6811{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for properly overriding new and delete" >&5
6812$as_echo_n "checking for properly overriding new and delete... " >&6; }
6813U_OVERRIDE_CXX_ALLOCATION=0
6814U_HAVE_PLACEMENT_NEW=0
4388f060 6815if ${ac_cv_override_cxx_allocation_ok+:} false; then :
729e4ab9 6816 $as_echo_n "(cached) " >&6
b75a7d8f 6817else
729e4ab9 6818 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 6819/* end confdefs.h. */
729e4ab9
A
6820#include <stdlib.h>
6821 class UMemory {
6822 public:
6823 void *operator new(size_t size) {return malloc(size);}
6824 void *operator new[](size_t size) {return malloc(size);}
6825 void operator delete(void *p) {free(p);}
6826 void operator delete[](void *p) {free(p);}
6827 };
6828
73c04bcf
A
6829int
6830main ()
6831{
729e4ab9 6832
73c04bcf
A
6833 ;
6834 return 0;
6835}
6836_ACEOF
729e4ab9
A
6837if ac_fn_cxx_try_link "$LINENO"; then :
6838 ac_cv_override_cxx_allocation_ok=yes
b75a7d8f 6839else
729e4ab9 6840 ac_cv_override_cxx_allocation_ok=no
b75a7d8f 6841fi
729e4ab9
A
6842rm -f core conftest.err conftest.$ac_objext \
6843 conftest$ac_exeext conftest.$ac_ext
b75a7d8f
A
6844fi
6845
729e4ab9
A
6846{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_override_cxx_allocation_ok" >&5
6847$as_echo "$ac_cv_override_cxx_allocation_ok" >&6; }
6848if test $ac_cv_override_cxx_allocation_ok = yes
6849then
6850 U_OVERRIDE_CXX_ALLOCATION=1
6851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for placement new and delete" >&5
6852$as_echo_n "checking for placement new and delete... " >&6; }
4388f060 6853 if ${ac_cv_override_placement_new_ok+:} false; then :
729e4ab9 6854 $as_echo_n "(cached) " >&6
b75a7d8f 6855else
729e4ab9 6856 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 6857/* end confdefs.h. */
729e4ab9
A
6858#include <stdlib.h>
6859 class UMemory {
6860 public:
6861 void *operator new(size_t size) {return malloc(size);}
6862 void *operator new[](size_t size) {return malloc(size);}
6863 void operator delete(void *p) {free(p);}
6864 void operator delete[](void *p) {free(p);}
6865 void * operator new(size_t, void *ptr) { return ptr; }
6866 void operator delete(void *, void *) {}
6867 };
6868
73c04bcf
A
6869int
6870main ()
6871{
729e4ab9 6872
73c04bcf
A
6873 ;
6874 return 0;
6875}
6876_ACEOF
729e4ab9
A
6877if ac_fn_cxx_try_link "$LINENO"; then :
6878 ac_cv_override_placement_new_ok=yes
b75a7d8f 6879else
729e4ab9 6880 ac_cv_override_placement_new_ok=no
b75a7d8f 6881fi
729e4ab9
A
6882rm -f core conftest.err conftest.$ac_objext \
6883 conftest$ac_exeext conftest.$ac_ext
73c04bcf 6884fi
b75a7d8f 6885
729e4ab9
A
6886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_override_placement_new_ok" >&5
6887$as_echo "$ac_cv_override_placement_new_ok" >&6; }
6888 if test $ac_cv_override_placement_new_ok = yes
6889 then
6890 U_HAVE_PLACEMENT_NEW=1
4388f060
A
6891 else
6892 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_PLACEMENT_NEW=0"
729e4ab9 6893 fi
b75a7d8f 6894else
4388f060 6895 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_OVERRIDE_CXX_ALLOCATION=0"
b75a7d8f 6896fi
4388f060 6897
b75a7d8f
A
6898
6899
729e4ab9
A
6900ac_ext=c
6901ac_cpp='$CPP $CPPFLAGS'
6902ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6903ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6904ac_compiler_gnu=$ac_cv_c_compiler_gnu
b75a7d8f 6905
729e4ab9 6906ac_fn_c_check_func "$LINENO" "popen" "ac_cv_func_popen"
4388f060 6907if test "x$ac_cv_func_popen" = xyes; then :
b75a7d8f 6908
b75a7d8f
A
6909fi
6910
729e4ab9
A
6911if test x$ac_cv_func_popen = xyes
6912then
6913 U_HAVE_POPEN=1
b75a7d8f 6914else
4388f060 6915 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_POPEN=0"
729e4ab9 6916 U_HAVE_POPEN=0
b75a7d8f
A
6917fi
6918
6919
729e4ab9 6920ac_fn_c_check_func "$LINENO" "tzset" "ac_cv_func_tzset"
4388f060 6921if test "x$ac_cv_func_tzset" = xyes; then :
73c04bcf 6922
73c04bcf 6923fi
73c04bcf 6924
729e4ab9
A
6925U_HAVE_TZSET=0
6926if test x$ac_cv_func_tzset = xyes
6927then
6928 U_TZSET=tzset
6929 U_HAVE_TZSET=1
73c04bcf 6930else
729e4ab9 6931 ac_fn_c_check_func "$LINENO" "_tzset" "ac_cv_func__tzset"
4388f060 6932if test "x$ac_cv_func__tzset" = xyes; then :
73c04bcf 6933
73c04bcf 6934fi
73c04bcf 6935
729e4ab9
A
6936 if test x$ac_cv_func__tzset = xyes
6937 then
6938 U_TZSET=_tzset
6939 U_HAVE_TZSET=1
4388f060
A
6940 else
6941 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_TZSET=0"
729e4ab9 6942 fi
b75a7d8f
A
6943fi
6944
73c04bcf 6945
b75a7d8f 6946
729e4ab9
A
6947U_HAVE_TZNAME=0
6948{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
6949$as_echo_n "checking for tzname... " >&6; }
4388f060 6950if ${ac_cv_var_tzname+:} false; then :
729e4ab9 6951 $as_echo_n "(cached) " >&6
73c04bcf 6952else
729e4ab9 6953 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 6954/* end confdefs.h. */
f3c0d7a5
A
6955#ifndef _XOPEN_SOURCE
6956#define _XOPEN_SOURCE
729e4ab9
A
6957#endif
6958#include <stdlib.h>
6959#include <time.h>
6960#ifndef tzname /* For SGI. */
6961extern char *tzname[]; /* RS6000 and others reject char **tzname. */
73c04bcf 6962#endif
73c04bcf
A
6963int
6964main ()
6965{
729e4ab9 6966atoi(*tzname);
73c04bcf
A
6967 ;
6968 return 0;
6969}
6970_ACEOF
729e4ab9
A
6971if ac_fn_c_try_link "$LINENO"; then :
6972 ac_cv_var_tzname=yes
b75a7d8f 6973else
729e4ab9 6974 ac_cv_var_tzname=no
b75a7d8f 6975fi
729e4ab9
A
6976rm -f core conftest.err conftest.$ac_objext \
6977 conftest$ac_exeext conftest.$ac_ext
6978fi
6979{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
6980$as_echo "$ac_cv_var_tzname" >&6; }
6981if test $ac_cv_var_tzname = yes; then
6982 U_TZNAME=tzname
6983 U_HAVE_TZNAME=1
6984else
6985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _tzname" >&5
6986$as_echo_n "checking for _tzname... " >&6; }
4388f060 6987if ${ac_cv_var__tzname+:} false; then :
729e4ab9
A
6988 $as_echo_n "(cached) " >&6
6989else
6990 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 6991/* end confdefs.h. */
729e4ab9
A
6992#include <stdlib.h>
6993 #include <time.h>
6994 extern char *_tzname[];
73c04bcf
A
6995int
6996main ()
6997{
729e4ab9 6998atoi(*_tzname);
73c04bcf
A
6999 ;
7000 return 0;
7001}
7002_ACEOF
729e4ab9
A
7003if ac_fn_c_try_link "$LINENO"; then :
7004 ac_cv_var__tzname=yes
b75a7d8f 7005else
729e4ab9 7006 ac_cv_var__tzname=no
73c04bcf 7007fi
729e4ab9
A
7008rm -f core conftest.err conftest.$ac_objext \
7009 conftest$ac_exeext conftest.$ac_ext
b75a7d8f 7010fi
729e4ab9
A
7011{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var__tzname" >&5
7012$as_echo "$ac_cv_var__tzname" >&6; }
7013 if test $ac_cv_var__tzname = yes; then
7014 U_TZNAME=_tzname
7015 U_HAVE_TZNAME=1
4388f060
A
7016 else
7017 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_TZNAME=0"
b75a7d8f
A
7018 fi
7019fi
7020
7021
7022
729e4ab9
A
7023{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for timezone" >&5
7024$as_echo_n "checking for timezone... " >&6; }
4388f060 7025if ${ac_cv_var_timezone+:} false; then :
729e4ab9 7026 $as_echo_n "(cached) " >&6
b75a7d8f 7027else
729e4ab9 7028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
73c04bcf 7029/* end confdefs.h. */
f3c0d7a5
A
7030#ifndef _XOPEN_SOURCE
7031#define _XOPEN_SOURCE
b75a7d8f 7032#endif
729e4ab9 7033#include <time.h>
46f4442e
A
7034
7035int
7036main ()
b75a7d8f 7037{
729e4ab9 7038timezone = 1;
46f4442e
A
7039 ;
7040 return 0;
b75a7d8f 7041}
73c04bcf 7042_ACEOF
729e4ab9
A
7043if ac_fn_c_try_link "$LINENO"; then :
7044 ac_cv_var_timezone=yes
b75a7d8f 7045else
729e4ab9 7046 ac_cv_var_timezone=no
b75a7d8f 7047fi
729e4ab9
A
7048rm -f core conftest.err conftest.$ac_objext \
7049 conftest$ac_exeext conftest.$ac_ext
b75a7d8f 7050fi
729e4ab9
A
7051{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_timezone" >&5
7052$as_echo "$ac_cv_var_timezone" >&6; }
7053U_HAVE_TIMEZONE=0
7054if test $ac_cv_var_timezone = yes; then
7055 U_TIMEZONE=timezone
7056 U_HAVE_TIMEZONE=1
46f4442e 7057else
729e4ab9
A
7058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __timezone" >&5
7059$as_echo_n "checking for __timezone... " >&6; }
4388f060 7060if ${ac_cv_var___timezone+:} false; then :
729e4ab9
A
7061 $as_echo_n "(cached) " >&6
7062else
7063 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46f4442e 7064/* end confdefs.h. */
729e4ab9 7065#include <time.h>
46f4442e
A
7066int
7067main ()
7068{
729e4ab9 7069__timezone = 1;
46f4442e
A
7070 ;
7071 return 0;
7072}
7073_ACEOF
729e4ab9
A
7074if ac_fn_c_try_link "$LINENO"; then :
7075 ac_cv_var___timezone=yes
7076else
7077 ac_cv_var___timezone=no
7078fi
7079rm -f core conftest.err conftest.$ac_objext \
7080 conftest$ac_exeext conftest.$ac_ext
7081fi
7082{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var___timezone" >&5
7083$as_echo "$ac_cv_var___timezone" >&6; }
7084 if test $ac_cv_var___timezone = yes; then
7085 U_TIMEZONE=__timezone
7086 U_HAVE_TIMEZONE=1
7087 else
7088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _timezone" >&5
7089$as_echo_n "checking for _timezone... " >&6; }
4388f060 7090if ${ac_cv_var__timezone+:} false; then :
729e4ab9
A
7091 $as_echo_n "(cached) " >&6
7092else
7093 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46f4442e 7094/* end confdefs.h. */
729e4ab9 7095#include <time.h>
46f4442e
A
7096int
7097main ()
7098{
729e4ab9 7099_timezone = 1;
46f4442e
A
7100 ;
7101 return 0;
7102}
7103_ACEOF
729e4ab9
A
7104if ac_fn_c_try_link "$LINENO"; then :
7105 ac_cv_var__timezone=yes
46f4442e 7106else
729e4ab9
A
7107 ac_cv_var__timezone=no
7108fi
7109rm -f core conftest.err conftest.$ac_objext \
7110 conftest$ac_exeext conftest.$ac_ext
7111fi
7112{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var__timezone" >&5
7113$as_echo "$ac_cv_var__timezone" >&6; }
7114 if test $ac_cv_var__timezone = yes; then
7115 U_TIMEZONE=_timezone
7116 U_HAVE_TIMEZONE=1
4388f060
A
7117 else
7118 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_TIMEZONE=0"
729e4ab9
A
7119 fi
7120 fi
7121fi
7122
7123
7124
f3c0d7a5
A
7125ac_fn_c_check_func "$LINENO" "strtod_l" "ac_cv_func_strtod_l"
7126if test "x$ac_cv_func_strtod_l" = xyes; then :
7127
7128fi
7129
7130if test x$ac_cv_func_strtod_l = xyes
7131then
0f5d89e8
A
7132 U_HAVE_STRTOD_L=1
7133 ac_fn_c_check_header_mongrel "$LINENO" "xlocale.h" "ac_cv_header_xlocale_h" "$ac_includes_default"
7134if test "x$ac_cv_header_xlocale_h" = xyes; then :
7135
7136fi
7137
7138
7139 if test "$ac_cv_header_xlocale_h" = yes; then
7140 U_HAVE_XLOCALE_H=1
7141 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_STRTOD_L=1 -DU_HAVE_XLOCALE_H=1"
7142 else
7143 U_HAVE_XLOCALE_H=0
7144 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_STRTOD_L=1 -DU_HAVE_XLOCALE_H=0"
7145 fi
f3c0d7a5 7146else
0f5d89e8
A
7147 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_STRTOD_L=0"
7148 U_HAVE_STRTOD_L=0
f3c0d7a5
A
7149fi
7150
7151
729e4ab9
A
7152# Checks for typedefs
7153ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default"
4388f060 7154if test "x$ac_cv_type_int8_t" = xyes; then :
729e4ab9
A
7155
7156else
7157
7158cat >>confdefs.h <<_ACEOF
7159#define int8_t signed char
7160_ACEOF
46f4442e 7161
46f4442e 7162fi
729e4ab9
A
7163
7164ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default"
4388f060 7165if test "x$ac_cv_type_uint8_t" = xyes; then :
729e4ab9 7166
46f4442e 7167else
46f4442e 7168
729e4ab9
A
7169cat >>confdefs.h <<_ACEOF
7170#define uint8_t unsigned char
46f4442e 7171_ACEOF
46f4442e 7172
729e4ab9 7173fi
46f4442e 7174
729e4ab9 7175ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default"
4388f060 7176if test "x$ac_cv_type_int16_t" = xyes; then :
46f4442e 7177
729e4ab9
A
7178else
7179
7180cat >>confdefs.h <<_ACEOF
7181#define int16_t signed short
46f4442e 7182_ACEOF
729e4ab9
A
7183
7184fi
7185
7186ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default"
4388f060 7187if test "x$ac_cv_type_uint16_t" = xyes; then :
729e4ab9
A
7188
7189else
7190
7191cat >>confdefs.h <<_ACEOF
7192#define uint16_t unsigned short
46f4442e 7193_ACEOF
46f4442e 7194
729e4ab9 7195fi
46f4442e 7196
729e4ab9 7197ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default"
4388f060 7198if test "x$ac_cv_type_int32_t" = xyes; then :
46f4442e 7199
729e4ab9
A
7200else
7201
7202cat >>confdefs.h <<_ACEOF
7203#define int32_t signed long
46f4442e 7204_ACEOF
729e4ab9
A
7205
7206fi
7207
7208ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default"
4388f060 7209if test "x$ac_cv_type_uint32_t" = xyes; then :
729e4ab9
A
7210
7211else
7212
7213cat >>confdefs.h <<_ACEOF
7214#define uint32_t unsigned long
7215_ACEOF
7216
7217fi
7218
7219ac_fn_c_check_type "$LINENO" "int64_t" "ac_cv_type_int64_t" "$ac_includes_default"
4388f060 7220if test "x$ac_cv_type_int64_t" = xyes; then :
729e4ab9
A
7221
7222else
7223
7224cat >>confdefs.h <<_ACEOF
7225#define int64_t signed long long
7226_ACEOF
7227
7228fi
7229
7230ac_fn_c_check_type "$LINENO" "uint64_t" "ac_cv_type_uint64_t" "$ac_includes_default"
4388f060 7231if test "x$ac_cv_type_uint64_t" = xyes; then :
729e4ab9
A
7232
7233else
7234
7235cat >>confdefs.h <<_ACEOF
7236#define uint64_t unsigned long long
7237_ACEOF
7238
7239fi
7240
7241
7242if test $ac_cv_type_int8_t = no; then
4388f060 7243CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_INT8_T=0"
729e4ab9
A
7244fi
7245
729e4ab9 7246if test $ac_cv_type_uint8_t = no; then
4388f060 7247CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_UINT8_T=0"
729e4ab9
A
7248fi
7249
729e4ab9 7250if test $ac_cv_type_int16_t = no; then
4388f060 7251CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_INT16_T=0"
729e4ab9
A
7252fi
7253
729e4ab9 7254if test $ac_cv_type_uint16_t = no; then
4388f060 7255CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_UINT16_T=0"
729e4ab9
A
7256fi
7257
729e4ab9 7258if test $ac_cv_type_int32_t = no; then
4388f060 7259CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_INT32_T=0"
729e4ab9
A
7260fi
7261
729e4ab9 7262if test $ac_cv_type_uint32_t = no; then
4388f060 7263CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_UINT32_T=0"
729e4ab9
A
7264fi
7265
729e4ab9 7266if test $ac_cv_type_int64_t = no; then
4388f060 7267CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_INT64_T=0"
729e4ab9
A
7268fi
7269
729e4ab9 7270if test $ac_cv_type_uint64_t = no; then
4388f060 7271CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_UINT64_T=0"
729e4ab9
A
7272fi
7273
729e4ab9
A
7274# Do various wchar_t related checks
7275ac_fn_c_check_header_mongrel "$LINENO" "wchar.h" "ac_cv_header_wchar_h" "$ac_includes_default"
4388f060 7276if test "x$ac_cv_header_wchar_h" = xyes; then :
729e4ab9
A
7277
7278fi
7279
7280
7281if test "$ac_cv_header_wchar_h" = no
7282then
7283 U_HAVE_WCHAR_H=0
7284 U_HAVE_WCSCPY=0
4388f060 7285 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_WCHAR_H=0 -DU_HAVE_WCSCPY=0"
46f4442e 7286else
46f4442e 7287
729e4ab9 7288$as_echo "#define HAVE_WCHAR_H 1" >>confdefs.h
46f4442e 7289
729e4ab9
A
7290 U_HAVE_WCHAR_H=1
7291 # Some broken systems have wchar.h but not some of its functions...
7292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing wcscpy" >&5
7293$as_echo_n "checking for library containing wcscpy... " >&6; }
4388f060 7294if ${ac_cv_search_wcscpy+:} false; then :
729e4ab9
A
7295 $as_echo_n "(cached) " >&6
7296else
7297 ac_func_search_save_LIBS=$LIBS
7298cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46f4442e
A
7299/* end confdefs.h. */
7300
729e4ab9
A
7301/* Override any GCC internal prototype to avoid an error.
7302 Use char because int might match the return type of a GCC
7303 builtin and then its argument prototype would still apply. */
7304#ifdef __cplusplus
7305extern "C"
46f4442e 7306#endif
729e4ab9 7307char wcscpy ();
46f4442e
A
7308int
7309main ()
7310{
729e4ab9 7311return wcscpy ();
46f4442e
A
7312 ;
7313 return 0;
7314}
7315_ACEOF
729e4ab9
A
7316for ac_lib in '' wcs w; do
7317 if test -z "$ac_lib"; then
7318 ac_res="none required"
7319 else
7320 ac_res=-l$ac_lib
7321 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
7322 fi
7323 if ac_fn_c_try_link "$LINENO"; then :
7324 ac_cv_search_wcscpy=$ac_res
7325fi
7326rm -f core conftest.err conftest.$ac_objext \
7327 conftest$ac_exeext
4388f060 7328 if ${ac_cv_search_wcscpy+:} false; then :
729e4ab9 7329 break
46f4442e 7330fi
46f4442e 7331done
4388f060 7332if ${ac_cv_search_wcscpy+:} false; then :
729e4ab9 7333
46f4442e 7334else
729e4ab9
A
7335 ac_cv_search_wcscpy=no
7336fi
7337rm conftest.$ac_ext
7338LIBS=$ac_func_search_save_LIBS
7339fi
7340{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_wcscpy" >&5
7341$as_echo "$ac_cv_search_wcscpy" >&6; }
7342ac_res=$ac_cv_search_wcscpy
7343if test "$ac_res" != no; then :
7344 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7345
7346fi
7347
7348 if test "$ac_cv_search_wcscpy" != no; then
7349 U_HAVE_WCSCPY=1
7350 else
7351 U_HAVE_WCSCPY=0
4388f060 7352 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_HAVE_WCSCPY=0"
729e4ab9
A
7353 fi
7354fi
7355
7356
46f4442e 7357
729e4ab9
A
7358# The cast to long int works around a bug in the HP C Compiler
7359# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7360# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7361# This bug is HP SR number 8606223364.
7362{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of wchar_t" >&5
7363$as_echo_n "checking size of wchar_t... " >&6; }
4388f060 7364if ${ac_cv_sizeof_wchar_t+:} false; then :
729e4ab9
A
7365 $as_echo_n "(cached) " >&6
7366else
7367 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (wchar_t))" "ac_cv_sizeof_wchar_t" "
46f4442e
A
7368#if STDC_HEADERS
7369#include <stddef.h>
7370#endif
7371#include <stdlib.h>
7372#if HAVE_WCHAR_H
7373#include <string.h>
7374#include <wchar.h>
7375#endif
729e4ab9 7376"; then :
46f4442e 7377
46f4442e 7378else
729e4ab9
A
7379 if test "$ac_cv_type_wchar_t" = yes; then
7380 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7381$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
7382as_fn_error 77 "cannot compute sizeof (wchar_t)
7383See \`config.log' for more details" "$LINENO" 5; }
7384 else
7385 ac_cv_sizeof_wchar_t=0
7386 fi
46f4442e 7387fi
729e4ab9 7388
46f4442e 7389fi
729e4ab9
A
7390{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_wchar_t" >&5
7391$as_echo "$ac_cv_sizeof_wchar_t" >&6; }
7392
7393
7394
46f4442e
A
7395cat >>confdefs.h <<_ACEOF
7396#define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t
7397_ACEOF
7398
7399
7400U_SIZEOF_WCHAR_T=$ac_cv_sizeof_wchar_t
7401# We do this check to verify that everything is okay.
7402if test $U_SIZEOF_WCHAR_T = 0; then
7403 if test $U_HAVE_WCHAR_H=1; then
729e4ab9 7404 as_fn_error $? "There is wchar.h but the size of wchar_t is 0" "$LINENO" 5
46f4442e
A
7405 fi
7406fi
7407
729e4ab9
A
7408{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for UTF-16 string literal support" >&5
7409$as_echo_n "checking for UTF-16 string literal support... " >&6; }
46f4442e
A
7410U_CHECK_UTF16_STRING=1
7411CHECK_UTF16_STRING_RESULT="unknown"
729e4ab9 7412
46f4442e
A
7413case "${host}" in
7414*-*-aix*|powerpc64-*-linux*)
51004dcb 7415 if test "$GCC" = no; then
46f4442e
A
7416 OLD_CFLAGS="${CFLAGS}"
7417 OLD_CXXFLAGS="${CXXFLAGS}"
7418 CFLAGS="${CFLAGS} -qutf"
7419 CXXFLAGS="${CXXFLAGS} -qutf"
729e4ab9 7420 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46f4442e
A
7421/* end confdefs.h. */
7422const unsigned short hello[] = u"hello";
7423int
7424main ()
7425{
7426
7427 ;
7428 return 0;
7429}
7430_ACEOF
729e4ab9 7431if ac_fn_c_try_compile "$LINENO"; then :
46f4442e
A
7432 U_CHECK_UTF16_STRING=1
7433else
729e4ab9 7434 U_CHECK_UTF16_STRING=0
46f4442e 7435fi
729e4ab9 7436rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
46f4442e
A
7437 if test "$U_CHECK_UTF16_STRING" = 0; then
7438 CFLAGS="${OLD_CFLAGS}"
7439 CXXFLAGS="${OLD_CXXFLAGS}"
7440 else
57a6839d 7441 UCONFIG_CXXFLAGS="${UCONFIG_CXXFLAGS} -qutf"
46f4442e
A
7442 CHECK_UTF16_STRING_RESULT="-qutf"
7443 fi
7444 fi
7445 ;;
7446*-*-solaris*)
51004dcb 7447 if test "$GCC" = no; then
46f4442e
A
7448 OLD_CFLAGS="${CFLAGS}"
7449 OLD_CXXFLAGS="${CXXFLAGS}"
7450 CFLAGS="${CFLAGS} -xustr=ascii_utf16_ushort"
7451 CXXFLAGS="${CXXFLAGS} -xustr=ascii_utf16_ushort"
729e4ab9 7452 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46f4442e
A
7453/* end confdefs.h. */
7454const unsigned short hello[] = U"hello";
7455int
7456main ()
7457{
7458
7459 ;
7460 return 0;
7461}
7462_ACEOF
729e4ab9 7463if ac_fn_c_try_compile "$LINENO"; then :
46f4442e
A
7464 U_CHECK_UTF16_STRING=1
7465else
729e4ab9 7466 U_CHECK_UTF16_STRING=0
46f4442e 7467fi
729e4ab9 7468rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
46f4442e
A
7469 if test "$U_CHECK_UTF16_STRING" = 0; then
7470 CFLAGS="${OLD_CFLAGS}"
7471 CXXFLAGS="${OLD_CXXFLAGS}"
7472 else
7473 CHECK_UTF16_STRING_RESULT="-xustr=ascii_utf16_ushort"
57a6839d
A
7474 UCONFIG_CXXFLAGS="${UCONFIG_CXXFLAGS} -xustr=ascii_utf16_ushort"
7475 UCONFIG_CFLAGS="${UCONFIG_CFLAGS} -xustr=ascii_utf16_ushort"
46f4442e
A
7476 # Since we can't detect the availability of this UTF-16 syntax at compile time,
7477 # we depend on configure telling us that we can use it.
7478 # Since we can't ensure ICU users use -xustr=ascii_utf16_ushort,
7479 # we only use this macro within ICU.
7480 # If an ICU user uses icu-config, this feature will be enabled.
4388f060 7481 CONFIG_CPPFLAGS="${CONFIG_CPPFLAGS} -DU_CHECK_UTF16_STRING=1"
46f4442e
A
7482 U_CHECK_UTF16_STRING=0
7483 fi
7484 fi
7485 ;;
7486*-*-hpux*)
51004dcb 7487 if test "$GCC" = no; then
729e4ab9
A
7488 # The option will be detected at compile time without additional compiler options.
7489 CHECK_UTF16_STRING_RESULT="available"
46f4442e
A
7490 fi
7491 ;;
7492*-*-cygwin)
729e4ab9
A
7493 # wchar_t can be used
7494 CHECK_UTF16_STRING_RESULT="available"
46f4442e
A
7495 ;;
7496*)
7497 ;;
7498esac
729e4ab9 7499
0f5d89e8 7500# GCC >= 4.4 supports UTF16 string literals. As of ICU 62, both C and C++ files require them.
51004dcb
A
7501if test "$CHECK_UTF16_STRING_RESULT" = "unknown"; then
7502 if test "$GCC" = yes; then
729e4ab9
A
7503 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7504/* end confdefs.h. */
7505
0f5d89e8 7506static const unsigned short test[] = u"This is a UTF16 literal string.";
729e4ab9
A
7507
7508int
7509main ()
7510{
7511
7512 ;
7513 return 0;
7514}
7515_ACEOF
7516if ac_fn_c_try_compile "$LINENO"; then :
51004dcb 7517 CC_UTF16_STRING=1
729e4ab9 7518else
51004dcb 7519 CC_UTF16_STRING=0
729e4ab9
A
7520fi
7521rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
51004dcb
A
7522 if test "$CC_UTF16_STRING" = 1; then
7523 CHECK_UTF16_STRING_RESULT="C only";
729e4ab9
A
7524 fi
7525 fi
51004dcb 7526 if test "$GXX" = yes; then
51004dcb 7527 # -Wno-return-type-c-linkage is desired so that stable ICU API is not warned about.
51004dcb
A
7528 ac_ext=cpp
7529ac_cpp='$CXXCPP $CPPFLAGS'
7530ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7531ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7532ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
729e4ab9 7533
51004dcb
A
7534 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7535/* end confdefs.h. */
729e4ab9 7536
51004dcb
A
7537static const char16_t test[] = u"This is a UTF16 literal string.";
7538
7539int
7540main ()
7541{
7542
7543 ;
7544 return 0;
7545}
7546_ACEOF
7547if ac_fn_cxx_try_compile "$LINENO"; then :
7548 CXX_UTF16_STRING=1
7549else
7550 CXX_UTF16_STRING=0
7551fi
7552rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7553 ac_ext=c
7554ac_cpp='$CPP $CPPFLAGS'
7555ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7556ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7557ac_compiler_gnu=$ac_cv_c_compiler_gnu
7558
7559 if test "$CXX_UTF16_STRING" = 1; then
7560 if test "$CC_UTF16_STRING" = 1; then
7561 CHECK_UTF16_STRING_RESULT="available";
7562 else
7563 CHECK_UTF16_STRING_RESULT="C++ only";
7564 fi
51004dcb
A
7565 fi
7566 fi
7567fi
729e4ab9
A
7568{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_UTF16_STRING_RESULT" >&5
7569$as_echo "$CHECK_UTF16_STRING_RESULT" >&6; }
46f4442e 7570
729e4ab9
A
7571# Enable/disable extras
7572# Check whether --enable-extras was given.
7573if test "${enable_extras+set}" = set; then :
7574 enableval=$enable_extras; case "${enableval}" in
46f4442e
A
7575 yes) extras=true ;;
7576 no) extras=false ;;
729e4ab9 7577 *) as_fn_error $? "bad value ${enableval} for --enable-extras" "$LINENO" 5 ;;
46f4442e
A
7578 esac
7579else
7580 extras=true
729e4ab9
A
7581fi
7582
46f4442e 7583
2ca993e8 7584
46f4442e
A
7585if test "$extras" = true; then
7586 EXTRAS_TRUE=
2ca993e8 7587 U_HAVE_EXTRAS=1
46f4442e
A
7588else
7589 EXTRAS_TRUE='#'
2ca993e8 7590 U_HAVE_EXTRAS=0
46f4442e 7591fi
729e4ab9
A
7592# Check whether --enable-icuio was given.
7593if test "${enable_icuio+set}" = set; then :
7594 enableval=$enable_icuio; case "${enableval}" in
46f4442e
A
7595 yes) icuio=true ;;
7596 no) icuio=false ;;
729e4ab9 7597 *) as_fn_error $? "bad value ${enableval} for --enable-icuio" "$LINENO" 5 ;;
46f4442e
A
7598 esac
7599else
374ca955 7600 icuio=true
729e4ab9
A
7601fi
7602
b75a7d8f 7603
2ca993e8 7604
374ca955
A
7605if test "$icuio" = true; then
7606 ICUIO_TRUE=
2ca993e8 7607 U_HAVE_ICUIO=1
b75a7d8f 7608else
374ca955 7609 ICUIO_TRUE='#'
2ca993e8 7610 U_HAVE_ICUIO=0
b75a7d8f
A
7611fi
7612
b331163b
A
7613# Enable/disable layoutex
7614# Check whether --enable-layoutex was given.
7615if test "${enable_layoutex+set}" = set; then :
7616 enableval=$enable_layoutex; case "${enableval}" in
f3c0d7a5 7617 yes) layoutex=$have_icu_le_hb ;;
b331163b
A
7618 no) layoutex=false ;;
7619 *) as_fn_error $? "bad value ${enableval} for --enable-layoutex" "$LINENO" 5 ;;
7620 esac
7621else
f3c0d7a5 7622 layoutex=$have_icu_le_hb
b331163b
A
7623fi
7624
7625
2ca993e8 7626
b331163b
A
7627if test "$layoutex" = true; then
7628 LAYOUTEX_TRUE=
2ca993e8 7629 U_HAVE_LAYOUTEX=1
b331163b
A
7630else
7631 LAYOUTEX_TRUE='#'
2ca993e8 7632 U_HAVE_LAYOUTEX=0
b331163b
A
7633fi
7634
f3c0d7a5
A
7635# Enable/disable layout
7636# Check whether --enable-layout was given.
7637if test "${enable_layout+set}" = set; then :
7638 enableval=$enable_layout; case "${enableval}" in
7639 yes) as_fn_error $? "The ICU Layout Engine has been removed." "$LINENO" 5 ;;
7640 no) ;;
7641 *) ;;
7642 esac
7643fi
7644
7645
57a6839d
A
7646# Enable/disable tools
7647# Check whether --enable-tools was given.
7648if test "${enable_tools+set}" = set; then :
7649 enableval=$enable_tools; case "${enableval}" in
7650 yes) tools=true ;;
7651 no) tools=false ;;
7652 *) as_fn_error $? "bad value ${enableval} for --enable-tools" "$LINENO" 5 ;;
7653 esac
7654else
7655 tools=true
7656fi
7657
7658
2ca993e8 7659
57a6839d
A
7660if test "$tools" = true; then
7661 TOOLS_TRUE=
2ca993e8 7662 U_HAVE_TOOLS=1
57a6839d
A
7663else
7664 TOOLS_TRUE='#'
2ca993e8 7665 U_HAVE_TOOLS=0
57a6839d
A
7666fi
7667
73c04bcf 7668
729e4ab9
A
7669# Check whether --with-data-packaging was given.
7670if test "${with_data_packaging+set}" = set; then :
7671 withval=$with_data_packaging; case "${withval}" in
b75a7d8f
A
7672 files|archive|library) datapackaging=$withval ;;
7673 auto) datapackaging=$withval ;;
7674 common) datapackaging=archive ;;
7675 dll) datapackaging=library ;;
374ca955 7676 static) datapackaging=static ;;
729e4ab9 7677 *) as_fn_error $? "bad value ${withval} for --with-data-packaging" "$LINENO" 5 ;;
b75a7d8f
A
7678 esac
7679else
7680 datapackaging=
729e4ab9
A
7681fi
7682
b75a7d8f 7683
729e4ab9
A
7684# Note: 'thesysconfdir' is an evaluated version, for Man pages, so also for thedatadir, thelibdir, etc..
7685# thesysconfdir=`eval echo $sysconfdir`
b75a7d8f 7686thedatadir=`eval echo $datadir`
729e4ab9 7687# Always put raw data files in share/icu/{version}, etc. Never use lib/icu/{version} for data files.. Actual shared libraries will go in {libdir}.
374ca955
A
7688pkgicudatadir=$datadir
7689thepkgicudatadir=$thedatadir
b75a7d8f
A
7690
7691
7692
7693
b75a7d8f 7694if test x"$datapackaging" = x -o x"$datapackaging" = xauto; then
729e4ab9 7695 # default to library
b75a7d8f 7696 datapackaging=library
729e4ab9
A
7697 if test "$ENABLE_STATIC" = "YES"; then
7698 if test "$ENABLE_SHARED" != "YES"; then
7699 datapackaging=static
7700 fi
7701 fi
b75a7d8f
A
7702fi
7703
729e4ab9
A
7704datapackaging_dir=`eval echo $thedatadir`"/icu/${VERSION}"
7705
7706datapackaging_msg="(No explaination for mode $datapackaging.)"
7707
7708datapackaging_msg_path="ICU will look in $datapackaging_dir which is the installation location. Call u_setDataDirectory() or use the ICU_DATA environment variable to override."
7709datapackaging_msg_set="ICU will use the linked data library. If linked with the stub library located in stubdata/, the application can use udata_setCommonData() or set a data path to override."
7710datapackaging_howfound="(unknown)"
7711
b75a7d8f
A
7712case "$datapackaging" in
7713 files)
729e4ab9
A
7714 DATA_PACKAGING_MODE=files
7715 datapackaging_msg="ICU data will be stored in individual files."
7716 datapackaging_howfound="$datapackaging_msg_path"
7717 ;;
b75a7d8f 7718 archive)
729e4ab9
A
7719 DATA_PACKAGING_MODE=common
7720 datapackaging_msg="ICU data will be stored in a single .dat file."
7721 datapackaging_howfound="$datapackaging_msg_path"
7722 ;;
b75a7d8f 7723 library)
729e4ab9
A
7724 DATA_PACKAGING_MODE=dll
7725 datapackaging_msg="ICU data will be linked with ICU."
7726 if test "$ENABLE_STATIC" = "YES"; then
7727 datapackaging_msg="$datapackaging_msg A static data library will be built. "
7728 fi
7729 if test "$ENABLE_SHARED" = "YES"; then
7730 datapackaging_msg="$datapackaging_msg A shared data library will be built. "
7731 fi
7732 datapackaging_howfound="$datapackaging_msg_set"
7733 ;;
7734 static)
7735 DATA_PACKAGING_MODE=static
7736 datapackaging_msg="ICU data will be stored in a static library."
7737 datapackaging_howfound="$datapackaging_msg_set"
7738 ;;
b75a7d8f
A
7739esac
7740
7741
729e4ab9
A
7742# Sets a library suffix
7743{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a library suffix to use" >&5
7744$as_echo_n "checking for a library suffix to use... " >&6; }
b75a7d8f 7745
729e4ab9
A
7746# Check whether --with-library-suffix was given.
7747if test "${with_library_suffix+set}" = set; then :
7748 withval=$with_library_suffix; ICULIBSUFFIX="${withval}"
b75a7d8f
A
7749else
7750 ICULIBSUFFIX=
729e4ab9
A
7751fi
7752
b75a7d8f
A
7753msg=$ICULIBSUFFIX
7754if test "$msg" = ""; then
7755 msg=none
7756fi
729e4ab9
A
7757{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $msg" >&5
7758$as_echo "$msg" >&6; }
b75a7d8f
A
7759
7760if test "$ICULIBSUFFIX" != ""
7761then
7762 U_HAVE_LIB_SUFFIX=1
729e4ab9 7763 ICULIBSUFFIXCNAME=`echo _$ICULIBSUFFIX | sed 's/^A-Za-z0-9_/_/g'`
4388f060 7764 UCONFIG_CPPFLAGS="${UCONFIG_CPPFLAGS} -DU_HAVE_LIB_SUFFIX=1 -DU_LIB_SUFFIX_C_NAME=${ICULIBSUFFIXCNAME} "
b75a7d8f
A
7765else
7766 U_HAVE_LIB_SUFFIX=0
7767fi
7768
7769
7770
729e4ab9
A
7771# Enable/disable tests
7772# Check whether --enable-tests was given.
7773if test "${enable_tests+set}" = set; then :
7774 enableval=$enable_tests; case "${enableval}" in
b75a7d8f
A
7775 yes) tests=true ;;
7776 no) tests=false ;;
729e4ab9 7777 *) as_fn_error $? "bad value ${enableval} for --enable-tests" "$LINENO" 5 ;;
b75a7d8f
A
7778 esac
7779else
7780 tests=true
729e4ab9
A
7781fi
7782
b75a7d8f 7783
2ca993e8 7784
b75a7d8f
A
7785if test "$tests" = true; then
7786 TESTS_TRUE=
2ca993e8 7787 U_HAVE_TESTS=1
b75a7d8f
A
7788else
7789 TESTS_TRUE='#'
2ca993e8 7790 U_HAVE_TESTS=0
b75a7d8f
A
7791fi
7792
729e4ab9
A
7793# Enable/disable samples
7794# Check whether --enable-samples was given.
7795if test "${enable_samples+set}" = set; then :
7796 enableval=$enable_samples; case "${enableval}" in
b75a7d8f
A
7797 yes) samples=true ;;
7798 no) samples=false ;;
729e4ab9 7799 *) as_fn_error $? "bad value ${enableval} for --enable-samples" "$LINENO" 5 ;;
b75a7d8f
A
7800 esac
7801else
7802 samples=true
729e4ab9
A
7803fi
7804
b75a7d8f 7805
2ca993e8 7806
b75a7d8f
A
7807if test "$samples" = true; then
7808 SAMPLES_TRUE=
2ca993e8 7809 U_HAVE_SAMPLES=1
b75a7d8f
A
7810else
7811 SAMPLES_TRUE='#'
2ca993e8 7812 U_HAVE_SAMPLES=0
b75a7d8f
A
7813fi
7814
7815ICUDATA_CHAR=$U_ENDIAN_CHAR
7816
729e4ab9
A
7817# Platform-specific Makefile setup
7818# set ICUDATA_CHAR to 'e' for any EBCDIC (which should be big endian) platform.
b75a7d8f
A
7819case "${host}" in
7820 *-*-solaris*) platform=U_SOLARIS ;;
729e4ab9 7821 *-*-linux*|*-*-gnu|*-*-k*bsd*-gnu|*-*-kopensolaris*-gnu) platform=U_LINUX ;;
73c04bcf 7822 *-*-*bsd*|*-*-dragonfly*) platform=U_BSD ;;
374ca955
A
7823 *-*-aix*) platform=U_AIX ;;
7824 *-*-hpux*) platform=U_HPUX ;;
b75a7d8f 7825 *-apple-darwin*|*-apple-rhapsody*) platform=U_DARWIN ;;
4388f060
A
7826 *-*-cygwin*) platform=U_CYGWIN ;;
7827 *-*-mingw*) platform=U_MINGW ;;
b75a7d8f 7828 *-*ibm-openedition*|*-*-os390*) platform=OS390
73c04bcf
A
7829 if test "${ICU_ENABLE_ASCII_STRINGS}" != "1"; then
7830 ICUDATA_CHAR="e"
7831 fi ;;
b75a7d8f 7832 *-*-os400*) platform=OS400
73c04bcf
A
7833 if test "${ICU_ENABLE_ASCII_STRINGS}" != "1"; then
7834 ICUDATA_CHAR="e"
7835 fi ;;
b75a7d8f
A
7836 *-*-nto*) platform=U_QNX ;;
7837 *-dec-osf*) platform=U_OSF ;;
374ca955
A
7838 *-*-beos) platform=U_BEOS ;;
7839 *-*-irix*) platform=U_IRIX ;;
7840 *-ncr-*) platform=U_MPRAS ;;
b75a7d8f
A
7841 *) platform=U_UNKNOWN_PLATFORM ;;
7842esac
7843
7844
7845platform_make_fragment_name="$icu_cv_host_frag"
7846platform_make_fragment='$(top_srcdir)/config/'"$platform_make_fragment_name"
7847
7848
7849
b75a7d8f
A
7850if test "${FORCE_LIBS}" != ""; then
7851 echo " *** Overriding automatically chosen LIBS=$LIBS, using instead FORCE_LIBS=${FORCE_LIBS}" 1>&6
7852 LIBS=${FORCE_LIBS}
7853fi
7854
729e4ab9
A
7855# Now that we're done using CPPFLAGS etc. for tests, we can change it
7856# for build.
b75a7d8f 7857
3d1f044b 7858if test "${CC}" = "clang"; then
57a6839d
A
7859 CLANGCFLAGS="-Qunused-arguments -Wno-parentheses-equality"
7860else
7861 CLANGCFLAGS=""
7862fi
7863
3d1f044b 7864if test "${CXX}" = "clang++"; then
57a6839d
A
7865 CLANGCXXFLAGS="-Qunused-arguments -Wno-parentheses-equality"
7866else
7867 CLANGCXXFLAGS=""
7868fi
7869
51004dcb 7870CPPFLAGS="$CPPFLAGS \$(THREADSCPPFLAGS)"
57a6839d
A
7871CFLAGS="$CFLAGS \$(THREADSCFLAGS) $CLANGCFLAGS"
7872CXXFLAGS="$CXXFLAGS \$(THREADSCXXFLAGS) $CLANGCXXFLAGS"
b75a7d8f 7873
4388f060
A
7874
7875
7876
7877# append all config cppflags
7878CPPFLAGS="$CPPFLAGS $CONFIG_CPPFLAGS $UCONFIG_CPPFLAGS"
7879
7880echo "CPPFLAGS=$CPPFLAGS"
7881echo "CFLAGS=$CFLAGS"
7882echo "CXXFLAGS=$CXXFLAGS"
7883
7884
729e4ab9 7885# output the Makefiles
f3c0d7a5 7886ac_config_files="$ac_config_files icudefs.mk Makefile data/pkgdataMakefile config/Makefile.inc config/icu.pc config/pkgdataMakefile data/Makefile stubdata/Makefile common/Makefile i18n/Makefile layoutex/Makefile io/Makefile extra/Makefile extra/uconv/Makefile extra/uconv/pkgdataMakefile extra/scrptrun/Makefile tools/Makefile tools/ctestfw/Makefile tools/toolutil/Makefile tools/makeconv/Makefile tools/genrb/Makefile tools/genccode/Makefile tools/gencmn/Makefile tools/gencnval/Makefile tools/gendict/Makefile tools/gentest/Makefile tools/gennorm2/Makefile tools/genbrk/Makefile tools/gensprep/Makefile tools/icuinfo/Makefile tools/icupkg/Makefile tools/icuswap/Makefile tools/pkgdata/Makefile tools/tzcode/Makefile tools/gencfu/Makefile tools/escapesrc/Makefile test/Makefile test/compat/Makefile test/testdata/Makefile test/testdata/pkgdataMakefile test/hdrtst/Makefile test/intltest/Makefile test/cintltst/Makefile test/iotest/Makefile test/letest/Makefile test/perf/Makefile test/perf/collationperf/Makefile test/perf/collperf/Makefile test/perf/collperf2/Makefile test/perf/dicttrieperf/Makefile test/perf/ubrkperf/Makefile test/perf/charperf/Makefile test/perf/convperf/Makefile test/perf/normperf/Makefile test/perf/DateFmtPerf/Makefile test/perf/howExpensiveIs/Makefile test/perf/strsrchperf/Makefile test/perf/unisetperf/Makefile test/perf/usetperf/Makefile test/perf/ustrperf/Makefile test/perf/utfperf/Makefile test/perf/utrie2perf/Makefile test/perf/leperf/Makefile samples/Makefile samples/date/Makefile samples/cal/Makefile samples/layout/Makefile"
729e4ab9 7887
73c04bcf 7888cat >confcache <<\_ACEOF
b75a7d8f
A
7889# This file is a shell script that caches the results of configure
7890# tests run on this system so they can be shared between configure
73c04bcf
A
7891# scripts and configure runs, see configure's option --config-cache.
7892# It is not useful on other systems. If it contains results you don't
7893# want to keep, you may remove or edit it.
b75a7d8f 7894#
73c04bcf
A
7895# config.status only pays attention to the cache file if you give it
7896# the --recheck option to rerun configure.
b75a7d8f 7897#
73c04bcf
A
7898# `ac_cv_env_foo' variables (set or unset) will be overridden when
7899# loading this file, other *unset* `ac_cv_foo' will be assigned the
7900# following values.
7901
7902_ACEOF
7903
b75a7d8f
A
7904# The following way of writing the cache mishandles newlines in values,
7905# but we know of no workaround that is simple, portable, and efficient.
729e4ab9 7906# So, we kill variables containing newlines.
b75a7d8f
A
7907# Ultrix sh set writes to stderr and can't be redirected directly,
7908# and sets the high bit in the cache file unless we assign to the vars.
729e4ab9
A
7909(
7910 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
7911 eval ac_val=\$$ac_var
7912 case $ac_val in #(
7913 *${as_nl}*)
7914 case $ac_var in #(
7915 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
7916$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
7917 esac
7918 case $ac_var in #(
7919 _ | IFS | as_nl) ;; #(
7920 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
7921 *) { eval $ac_var=; unset $ac_var;} ;;
7922 esac ;;
7923 esac
7924 done
7925
73c04bcf 7926 (set) 2>&1 |
729e4ab9
A
7927 case $as_nl`(ac_space=' '; set) 2>&1` in #(
7928 *${as_nl}ac_space=\ *)
7929 # `set' does not quote correctly, so add quotes: double-quote
7930 # substitution turns \\\\ into \\, and sed turns \\ into \.
73c04bcf
A
7931 sed -n \
7932 "s/'/'\\\\''/g;
7933 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
729e4ab9 7934 ;; #(
73c04bcf
A
7935 *)
7936 # `set' quotes correctly as required by POSIX, so do not add quotes.
729e4ab9 7937 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
73c04bcf 7938 ;;
729e4ab9
A
7939 esac |
7940 sort
7941) |
73c04bcf 7942 sed '
729e4ab9 7943 /^ac_cv_env_/b end
73c04bcf 7944 t clear
729e4ab9 7945 :clear
73c04bcf
A
7946 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
7947 t end
729e4ab9
A
7948 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
7949 :end' >>confcache
7950if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
7951 if test -w "$cache_file"; then
4388f060 7952 if test "x$cache_file" != "x/dev/null"; then
729e4ab9
A
7953 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
7954$as_echo "$as_me: updating cache $cache_file" >&6;}
4388f060
A
7955 if test ! -f "$cache_file" || test -h "$cache_file"; then
7956 cat confcache >"$cache_file"
7957 else
7958 case $cache_file in #(
7959 */* | ?:*)
7960 mv -f confcache "$cache_file"$$ &&
7961 mv -f "$cache_file"$$ "$cache_file" ;; #(
7962 *)
7963 mv -f confcache "$cache_file" ;;
7964 esac
7965 fi
7966 fi
b75a7d8f 7967 else
729e4ab9
A
7968 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
7969$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
b75a7d8f
A
7970 fi
7971fi
7972rm -f confcache
7973
b75a7d8f
A
7974test "x$prefix" = xNONE && prefix=$ac_default_prefix
7975# Let make expand exec_prefix.
7976test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
7977
4388f060
A
7978# Transform confdefs.h into DEFS.
7979# Protect against shell expansion while executing Makefile rules.
7980# Protect against Makefile macro expansion.
7981#
7982# If the first sed substitution is executed (which looks for macros that
7983# take arguments), then branch to the quote section. Otherwise,
7984# look for a macro that doesn't take arguments.
7985ac_script='
7986:mline
7987/\\$/{
7988 N
7989 s,\\\n,,
7990 b mline
7991}
7992t clear
7993:clear
7994s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g
7995t quote
7996s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g
7997t quote
7998b any
7999:quote
8000s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g
8001s/\[/\\&/g
8002s/\]/\\&/g
8003s/\$/$$/g
8004H
8005:any
8006${
8007 g
8008 s/^\n//
8009 s/\n/ /g
8010 p
8011}
8012'
8013DEFS=`sed -n "$ac_script" confdefs.h`
8014
b75a7d8f 8015
73c04bcf
A
8016ac_libobjs=
8017ac_ltlibobjs=
729e4ab9 8018U=
73c04bcf
A
8019for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
8020 # 1. Remove the extension, and $U if already installed.
729e4ab9
A
8021 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
8022 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
8023 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
8024 # will be set to the directory where LIBOBJS objects are built.
8025 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
8026 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
73c04bcf
A
8027done
8028LIBOBJS=$ac_libobjs
b75a7d8f 8029
73c04bcf
A
8030LTLIBOBJS=$ac_ltlibobjs
8031
8032
8033
729e4ab9 8034
4388f060 8035: "${CONFIG_STATUS=./config.status}"
729e4ab9 8036ac_write_fail=0
73c04bcf
A
8037ac_clean_files_save=$ac_clean_files
8038ac_clean_files="$ac_clean_files $CONFIG_STATUS"
729e4ab9
A
8039{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
8040$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
8041as_write_fail=0
8042cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
73c04bcf
A
8043#! $SHELL
8044# Generated by $as_me.
b75a7d8f 8045# Run this file to recreate the current configuration.
b75a7d8f 8046# Compiler output produced by configure, useful for debugging
73c04bcf 8047# configure, is in config.log if it exists.
b75a7d8f 8048
73c04bcf
A
8049debug=false
8050ac_cs_recheck=false
8051ac_cs_silent=false
73c04bcf 8052
729e4ab9
A
8053SHELL=\${CONFIG_SHELL-$SHELL}
8054export SHELL
8055_ASEOF
8056cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
8057## -------------------- ##
8058## M4sh Initialization. ##
8059## -------------------- ##
8060
8061# Be more Bourne compatible
8062DUALCASE=1; export DUALCASE # for MKS sh
8063if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
73c04bcf
A
8064 emulate sh
8065 NULLCMD=:
729e4ab9 8066 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
73c04bcf
A
8067 # is contrary to our usage. Disable this feature.
8068 alias -g '${1+"$@"}'='"$@"'
729e4ab9 8069 setopt NO_GLOB_SUBST
73c04bcf 8070else
729e4ab9
A
8071 case `(set -o) 2>/dev/null` in #(
8072 *posix*) :
8073 set -o posix ;; #(
8074 *) :
8075 ;;
8076esac
73c04bcf
A
8077fi
8078
8079
729e4ab9
A
8080as_nl='
8081'
8082export as_nl
8083# Printing a long string crashes Solaris 7 /usr/bin/printf.
8084as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
8085as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
8086as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
8087# Prefer a ksh shell builtin over an external printf program on Solaris,
8088# but without wasting forks for bash or zsh.
8089if test -z "$BASH_VERSION$ZSH_VERSION" \
8090 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
8091 as_echo='print -r --'
8092 as_echo_n='print -rn --'
8093elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
8094 as_echo='printf %s\n'
8095 as_echo_n='printf %s'
8096else
8097 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
8098 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
8099 as_echo_n='/usr/ucb/echo -n'
73c04bcf 8100 else
729e4ab9
A
8101 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
8102 as_echo_n_body='eval
8103 arg=$1;
8104 case $arg in #(
8105 *"$as_nl"*)
8106 expr "X$arg" : "X\\(.*\\)$as_nl";
8107 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
8108 esac;
8109 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
8110 '
8111 export as_echo_n_body
8112 as_echo_n='sh -c $as_echo_n_body as_echo'
73c04bcf 8113 fi
729e4ab9
A
8114 export as_echo_body
8115 as_echo='sh -c $as_echo_body as_echo'
73c04bcf
A
8116fi
8117
73c04bcf
A
8118# The user is always right.
8119if test "${PATH_SEPARATOR+set}" != set; then
729e4ab9
A
8120 PATH_SEPARATOR=:
8121 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
8122 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
8123 PATH_SEPARATOR=';'
8124 }
73c04bcf
A
8125fi
8126
8127
729e4ab9
A
8128# IFS
8129# We need space, tab and new line, in precisely that order. Quoting is
8130# there to prevent editors from complaining about space-tab.
8131# (If _AS_PATH_WALK were called with IFS unset, it would disable word
8132# splitting by setting IFS to empty value.)
8133IFS=" "" $as_nl"
8134
8135# Find who we are. Look in the path if we contain no directory separator.
4388f060 8136as_myself=
729e4ab9
A
8137case $0 in #((
8138 *[\\/]* ) as_myself=$0 ;;
8139 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
73c04bcf
A
8140for as_dir in $PATH
8141do
8142 IFS=$as_save_IFS
8143 test -z "$as_dir" && as_dir=.
729e4ab9
A
8144 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
8145 done
8146IFS=$as_save_IFS
8147
8148 ;;
8149esac
8150# We did not find ourselves, most probably we were run as `sh COMMAND'
8151# in which case we are not to be found in the path.
8152if test "x$as_myself" = x; then
8153 as_myself=$0
8154fi
8155if test ! -f "$as_myself"; then
8156 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
8157 exit 1
8158fi
8159
8160# Unset variables that we do not need and which cause bugs (e.g. in
8161# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
8162# suppresses any "Segmentation fault" message there. '((' could
8163# trigger a bug in pdksh 5.2.14.
8164for as_var in BASH_ENV ENV MAIL MAILPATH
8165do eval test x\${$as_var+set} = xset \
8166 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
73c04bcf 8167done
729e4ab9
A
8168PS1='$ '
8169PS2='> '
8170PS4='+ '
73c04bcf 8171
729e4ab9
A
8172# NLS nuisances.
8173LC_ALL=C
8174export LC_ALL
8175LANGUAGE=C
8176export LANGUAGE
8177
8178# CDPATH.
8179(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
8180
8181
8182# as_fn_error STATUS ERROR [LINENO LOG_FD]
8183# ----------------------------------------
8184# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
8185# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
8186# script with STATUS, using 1 if that was 0.
8187as_fn_error ()
8188{
8189 as_status=$1; test $as_status -eq 0 && as_status=1
8190 if test "$4"; then
8191 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
8192 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
b75a7d8f 8193 fi
729e4ab9
A
8194 $as_echo "$as_me: error: $2" >&2
8195 as_fn_exit $as_status
8196} # as_fn_error
b75a7d8f 8197
73c04bcf 8198
729e4ab9
A
8199# as_fn_set_status STATUS
8200# -----------------------
8201# Set $? to STATUS, without forking.
8202as_fn_set_status ()
8203{
8204 return $1
8205} # as_fn_set_status
73c04bcf 8206
729e4ab9
A
8207# as_fn_exit STATUS
8208# -----------------
8209# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
8210as_fn_exit ()
8211{
8212 set +e
8213 as_fn_set_status $1
8214 exit $1
8215} # as_fn_exit
8216
8217# as_fn_unset VAR
8218# ---------------
8219# Portably unset VAR.
8220as_fn_unset ()
8221{
8222 { eval $1=; unset $1;}
8223}
8224as_unset=as_fn_unset
8225# as_fn_append VAR VALUE
8226# ----------------------
8227# Append the text in VALUE to the end of the definition contained in VAR. Take
8228# advantage of any shell optimizations that allow amortized linear growth over
8229# repeated appends, instead of the typical quadratic growth present in naive
8230# implementations.
8231if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
8232 eval 'as_fn_append ()
8233 {
8234 eval $1+=\$2
8235 }'
8236else
8237 as_fn_append ()
8238 {
8239 eval $1=\$$1\$2
8240 }
8241fi # as_fn_append
8242
8243# as_fn_arith ARG...
8244# ------------------
8245# Perform arithmetic evaluation on the ARGs, and store the result in the
8246# global $as_val. Take advantage of shells that can avoid forks. The arguments
8247# must be portable across $(()) and expr.
8248if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
8249 eval 'as_fn_arith ()
8250 {
8251 as_val=$(( $* ))
8252 }'
8253else
8254 as_fn_arith ()
8255 {
8256 as_val=`expr "$@" || test $? -eq 1`
8257 }
8258fi # as_fn_arith
b75a7d8f 8259
73c04bcf 8260
729e4ab9
A
8261if expr a : '\(a\)' >/dev/null 2>&1 &&
8262 test "X`expr 00001 : '.*\(...\)'`" = X001; then
73c04bcf
A
8263 as_expr=expr
8264else
8265 as_expr=false
8266fi
8267
729e4ab9
A
8268if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
8269 as_basename=basename
8270else
8271 as_basename=false
8272fi
8273
8274if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
8275 as_dirname=dirname
8276else
8277 as_dirname=false
8278fi
8279
8280as_me=`$as_basename -- "$0" ||
8281$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
8282 X"$0" : 'X\(//\)$' \| \
8283 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
8284$as_echo X/"$0" |
8285 sed '/^.*\/\([^/][^/]*\)\/*$/{
8286 s//\1/
8287 q
8288 }
8289 /^X\/\(\/\/\)$/{
8290 s//\1/
8291 q
8292 }
8293 /^X\/\(\/\).*/{
8294 s//\1/
8295 q
8296 }
8297 s/.*/./; q'`
8298
8299# Avoid depending upon Character Ranges.
8300as_cr_letters='abcdefghijklmnopqrstuvwxyz'
8301as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
8302as_cr_Letters=$as_cr_letters$as_cr_LETTERS
8303as_cr_digits='0123456789'
8304as_cr_alnum=$as_cr_Letters$as_cr_digits
8305
8306ECHO_C= ECHO_N= ECHO_T=
8307case `echo -n x` in #(((((
8308-n*)
8309 case `echo 'xy\c'` in
8310 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
8311 xy) ECHO_C='\c';;
8312 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
8313 ECHO_T=' ';;
8314 esac;;
8315*)
8316 ECHO_N='-n';;
8317esac
8318
73c04bcf 8319rm -f conf$$ conf$$.exe conf$$.file
729e4ab9
A
8320if test -d conf$$.dir; then
8321 rm -f conf$$.dir/conf$$.file
8322else
8323 rm -f conf$$.dir
8324 mkdir conf$$.dir 2>/dev/null
8325fi
8326if (echo >conf$$.file) 2>/dev/null; then
8327 if ln -s conf$$.file conf$$ 2>/dev/null; then
73c04bcf 8328 as_ln_s='ln -s'
729e4ab9
A
8329 # ... but there are two gotchas:
8330 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
8331 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
b331163b 8332 # In both cases, we have to default to `cp -pR'.
729e4ab9 8333 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
b331163b 8334 as_ln_s='cp -pR'
729e4ab9
A
8335 elif ln conf$$.file conf$$ 2>/dev/null; then
8336 as_ln_s=ln
8337 else
b331163b 8338 as_ln_s='cp -pR'
b75a7d8f 8339 fi
73c04bcf 8340else
b331163b 8341 as_ln_s='cp -pR'
73c04bcf 8342fi
729e4ab9
A
8343rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
8344rmdir conf$$.dir 2>/dev/null
8345
8346
8347# as_fn_mkdir_p
8348# -------------
8349# Create "$as_dir" as a directory, including parents if necessary.
8350as_fn_mkdir_p ()
8351{
8352
8353 case $as_dir in #(
8354 -*) as_dir=./$as_dir;;
8355 esac
8356 test -d "$as_dir" || eval $as_mkdir_p || {
8357 as_dirs=
8358 while :; do
8359 case $as_dir in #(
8360 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
8361 *) as_qdir=$as_dir;;
8362 esac
8363 as_dirs="'$as_qdir' $as_dirs"
8364 as_dir=`$as_dirname -- "$as_dir" ||
8365$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
8366 X"$as_dir" : 'X\(//\)[^/]' \| \
8367 X"$as_dir" : 'X\(//\)$' \| \
8368 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
8369$as_echo X"$as_dir" |
8370 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
8371 s//\1/
8372 q
8373 }
8374 /^X\(\/\/\)[^/].*/{
8375 s//\1/
8376 q
8377 }
8378 /^X\(\/\/\)$/{
8379 s//\1/
8380 q
8381 }
8382 /^X\(\/\).*/{
8383 s//\1/
8384 q
8385 }
8386 s/.*/./; q'`
8387 test -d "$as_dir" && break
8388 done
8389 test -z "$as_dirs" || eval "mkdir $as_dirs"
8390 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
b75a7d8f 8391
729e4ab9
A
8392
8393} # as_fn_mkdir_p
73c04bcf 8394if mkdir -p . 2>/dev/null; then
729e4ab9 8395 as_mkdir_p='mkdir -p "$as_dir"'
73c04bcf
A
8396else
8397 test -d ./-p && rmdir ./-p
8398 as_mkdir_p=false
8399fi
8400
b331163b
A
8401
8402# as_fn_executable_p FILE
8403# -----------------------
8404# Test if FILE is an executable regular file.
8405as_fn_executable_p ()
8406{
8407 test -f "$1" && test -x "$1"
8408} # as_fn_executable_p
8409as_test_x='test -x'
8410as_executable_p=as_fn_executable_p
73c04bcf
A
8411
8412# Sed expression to map a string onto a valid CPP name.
8413as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
8414
8415# Sed expression to map a string onto a valid variable name.
8416as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
8417
8418
73c04bcf 8419exec 6>&1
729e4ab9
A
8420## ----------------------------------- ##
8421## Main body of $CONFIG_STATUS script. ##
8422## ----------------------------------- ##
8423_ASEOF
8424test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
8425
8426cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
8427# Save the log message, to keep $0 and so on meaningful, and to
73c04bcf 8428# report actual input values of CONFIG_FILES etc. instead of their
729e4ab9
A
8429# values after options handling.
8430ac_log="
3d1f044b 8431This file was extended by ICU $as_me 64.2, which was
b331163b 8432generated by GNU Autoconf 2.69. Invocation command line was
73c04bcf
A
8433
8434 CONFIG_FILES = $CONFIG_FILES
8435 CONFIG_HEADERS = $CONFIG_HEADERS
8436 CONFIG_LINKS = $CONFIG_LINKS
8437 CONFIG_COMMANDS = $CONFIG_COMMANDS
8438 $ $0 $@
8439
729e4ab9
A
8440on `(hostname || uname -n) 2>/dev/null | sed 1q`
8441"
8442
73c04bcf
A
8443_ACEOF
8444
729e4ab9
A
8445case $ac_config_files in *"
8446"*) set x $ac_config_files; shift; ac_config_files=$*;;
8447esac
73c04bcf 8448
73c04bcf 8449
73c04bcf 8450
729e4ab9
A
8451cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
8452# Files that config.status was made for.
8453config_files="$ac_config_files"
73c04bcf 8454
729e4ab9 8455_ACEOF
73c04bcf 8456
729e4ab9 8457cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
73c04bcf 8458ac_cs_usage="\
729e4ab9
A
8459\`$as_me' instantiates files and other configuration actions
8460from templates according to the current configuration. Unless the files
8461and actions are specified as TAGs, all are instantiated by default.
73c04bcf 8462
729e4ab9 8463Usage: $0 [OPTION]... [TAG]...
73c04bcf
A
8464
8465 -h, --help print this help, then exit
729e4ab9
A
8466 -V, --version print version number and configuration settings, then exit
8467 --config print configuration, then exit
8468 -q, --quiet, --silent
8469 do not print progress messages
73c04bcf
A
8470 -d, --debug don't remove temporary files
8471 --recheck update $as_me by reconfiguring in the same conditions
729e4ab9
A
8472 --file=FILE[:TEMPLATE]
8473 instantiate the configuration file FILE
73c04bcf
A
8474
8475Configuration files:
8476$config_files
8477
b331163b
A
8478Report bugs to <http://icu-project.org/bugs>.
8479ICU home page: <http://icu-project.org>."
73c04bcf 8480
729e4ab9
A
8481_ACEOF
8482cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
8483ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
73c04bcf 8484ac_cs_version="\\
3d1f044b 8485ICU config.status 64.2
b331163b 8486configured by $0, generated by GNU Autoconf 2.69,
729e4ab9 8487 with options \\"\$ac_cs_config\\"
73c04bcf 8488
b331163b 8489Copyright (C) 2012 Free Software Foundation, Inc.
73c04bcf
A
8490This config.status script is free software; the Free Software Foundation
8491gives unlimited permission to copy, distribute and modify it."
729e4ab9
A
8492
8493ac_pwd='$ac_pwd'
8494srcdir='$srcdir'
8495INSTALL='$INSTALL'
8496test -n "\$AWK" || AWK=awk
73c04bcf
A
8497_ACEOF
8498
729e4ab9
A
8499cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
8500# The default lists apply if the user does not specify any file.
73c04bcf
A
8501ac_need_defaults=:
8502while test $# != 0
8503do
8504 case $1 in
729e4ab9
A
8505 --*=?*)
8506 ac_option=`expr "X$1" : 'X\([^=]*\)='`
8507 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
73c04bcf
A
8508 ac_shift=:
8509 ;;
729e4ab9
A
8510 --*=)
8511 ac_option=`expr "X$1" : 'X\([^=]*\)='`
8512 ac_optarg=
8513 ac_shift=:
8514 ;;
8515 *)
73c04bcf
A
8516 ac_option=$1
8517 ac_optarg=$2
8518 ac_shift=shift
8519 ;;
73c04bcf
A
8520 esac
8521
8522 case $ac_option in
8523 # Handling of the options.
73c04bcf
A
8524 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
8525 ac_cs_recheck=: ;;
729e4ab9
A
8526 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
8527 $as_echo "$ac_cs_version"; exit ;;
8528 --config | --confi | --conf | --con | --co | --c )
8529 $as_echo "$ac_cs_config"; exit ;;
8530 --debug | --debu | --deb | --de | --d | -d )
73c04bcf
A
8531 debug=: ;;
8532 --file | --fil | --fi | --f )
8533 $ac_shift
729e4ab9
A
8534 case $ac_optarg in
8535 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
8536 '') as_fn_error $? "missing file argument" ;;
8537 esac
8538 as_fn_append CONFIG_FILES " '$ac_optarg'"
73c04bcf 8539 ac_need_defaults=false;;
4388f060 8540 --he | --h | --help | --hel | -h )
729e4ab9 8541 $as_echo "$ac_cs_usage"; exit ;;
73c04bcf
A
8542 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
8543 | -silent | --silent | --silen | --sile | --sil | --si | --s)
8544 ac_cs_silent=: ;;
8545
8546 # This is an error.
729e4ab9
A
8547 -*) as_fn_error $? "unrecognized option: \`$1'
8548Try \`$0 --help' for more information." ;;
73c04bcf 8549
729e4ab9
A
8550 *) as_fn_append ac_config_targets " $1"
8551 ac_need_defaults=false ;;
73c04bcf
A
8552
8553 esac
8554 shift
8555done
8556
8557ac_configure_extra_args=
8558
8559if $ac_cs_silent; then
8560 exec 6>/dev/null
8561 ac_configure_extra_args="$ac_configure_extra_args --silent"
8562fi
8563
8564_ACEOF
729e4ab9 8565cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
73c04bcf 8566if \$ac_cs_recheck; then
b331163b 8567 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
729e4ab9
A
8568 shift
8569 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
8570 CONFIG_SHELL='$SHELL'
8571 export CONFIG_SHELL
8572 exec "\$@"
73c04bcf
A
8573fi
8574
8575_ACEOF
729e4ab9
A
8576cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
8577exec 5>>config.log
8578{
8579 echo
8580 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
8581## Running $as_me. ##
8582_ASBOX
8583 $as_echo "$ac_log"
8584} >&5
73c04bcf 8585
729e4ab9
A
8586_ACEOF
8587cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
8588_ACEOF
73c04bcf 8589
729e4ab9 8590cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
73c04bcf 8591
729e4ab9 8592# Handling of arguments.
73c04bcf
A
8593for ac_config_target in $ac_config_targets
8594do
729e4ab9 8595 case $ac_config_target in
729e4ab9
A
8596 "icudefs.mk") CONFIG_FILES="$CONFIG_FILES icudefs.mk" ;;
8597 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
8598 "data/pkgdataMakefile") CONFIG_FILES="$CONFIG_FILES data/pkgdataMakefile" ;;
8599 "config/Makefile.inc") CONFIG_FILES="$CONFIG_FILES config/Makefile.inc" ;;
8600 "config/icu.pc") CONFIG_FILES="$CONFIG_FILES config/icu.pc" ;;
8601 "config/pkgdataMakefile") CONFIG_FILES="$CONFIG_FILES config/pkgdataMakefile" ;;
8602 "data/Makefile") CONFIG_FILES="$CONFIG_FILES data/Makefile" ;;
8603 "stubdata/Makefile") CONFIG_FILES="$CONFIG_FILES stubdata/Makefile" ;;
8604 "common/Makefile") CONFIG_FILES="$CONFIG_FILES common/Makefile" ;;
8605 "i18n/Makefile") CONFIG_FILES="$CONFIG_FILES i18n/Makefile" ;;
729e4ab9
A
8606 "layoutex/Makefile") CONFIG_FILES="$CONFIG_FILES layoutex/Makefile" ;;
8607 "io/Makefile") CONFIG_FILES="$CONFIG_FILES io/Makefile" ;;
8608 "extra/Makefile") CONFIG_FILES="$CONFIG_FILES extra/Makefile" ;;
8609 "extra/uconv/Makefile") CONFIG_FILES="$CONFIG_FILES extra/uconv/Makefile" ;;
8610 "extra/uconv/pkgdataMakefile") CONFIG_FILES="$CONFIG_FILES extra/uconv/pkgdataMakefile" ;;
8611 "extra/scrptrun/Makefile") CONFIG_FILES="$CONFIG_FILES extra/scrptrun/Makefile" ;;
8612 "tools/Makefile") CONFIG_FILES="$CONFIG_FILES tools/Makefile" ;;
8613 "tools/ctestfw/Makefile") CONFIG_FILES="$CONFIG_FILES tools/ctestfw/Makefile" ;;
8614 "tools/toolutil/Makefile") CONFIG_FILES="$CONFIG_FILES tools/toolutil/Makefile" ;;
8615 "tools/makeconv/Makefile") CONFIG_FILES="$CONFIG_FILES tools/makeconv/Makefile" ;;
8616 "tools/genrb/Makefile") CONFIG_FILES="$CONFIG_FILES tools/genrb/Makefile" ;;
8617 "tools/genccode/Makefile") CONFIG_FILES="$CONFIG_FILES tools/genccode/Makefile" ;;
8618 "tools/gencmn/Makefile") CONFIG_FILES="$CONFIG_FILES tools/gencmn/Makefile" ;;
8619 "tools/gencnval/Makefile") CONFIG_FILES="$CONFIG_FILES tools/gencnval/Makefile" ;;
51004dcb 8620 "tools/gendict/Makefile") CONFIG_FILES="$CONFIG_FILES tools/gendict/Makefile" ;;
729e4ab9
A
8621 "tools/gentest/Makefile") CONFIG_FILES="$CONFIG_FILES tools/gentest/Makefile" ;;
8622 "tools/gennorm2/Makefile") CONFIG_FILES="$CONFIG_FILES tools/gennorm2/Makefile" ;;
8623 "tools/genbrk/Makefile") CONFIG_FILES="$CONFIG_FILES tools/genbrk/Makefile" ;;
8624 "tools/gensprep/Makefile") CONFIG_FILES="$CONFIG_FILES tools/gensprep/Makefile" ;;
8625 "tools/icuinfo/Makefile") CONFIG_FILES="$CONFIG_FILES tools/icuinfo/Makefile" ;;
8626 "tools/icupkg/Makefile") CONFIG_FILES="$CONFIG_FILES tools/icupkg/Makefile" ;;
8627 "tools/icuswap/Makefile") CONFIG_FILES="$CONFIG_FILES tools/icuswap/Makefile" ;;
8628 "tools/pkgdata/Makefile") CONFIG_FILES="$CONFIG_FILES tools/pkgdata/Makefile" ;;
8629 "tools/tzcode/Makefile") CONFIG_FILES="$CONFIG_FILES tools/tzcode/Makefile" ;;
8630 "tools/gencfu/Makefile") CONFIG_FILES="$CONFIG_FILES tools/gencfu/Makefile" ;;
f3c0d7a5 8631 "tools/escapesrc/Makefile") CONFIG_FILES="$CONFIG_FILES tools/escapesrc/Makefile" ;;
729e4ab9
A
8632 "test/Makefile") CONFIG_FILES="$CONFIG_FILES test/Makefile" ;;
8633 "test/compat/Makefile") CONFIG_FILES="$CONFIG_FILES test/compat/Makefile" ;;
8634 "test/testdata/Makefile") CONFIG_FILES="$CONFIG_FILES test/testdata/Makefile" ;;
8635 "test/testdata/pkgdataMakefile") CONFIG_FILES="$CONFIG_FILES test/testdata/pkgdataMakefile" ;;
8636 "test/hdrtst/Makefile") CONFIG_FILES="$CONFIG_FILES test/hdrtst/Makefile" ;;
8637 "test/intltest/Makefile") CONFIG_FILES="$CONFIG_FILES test/intltest/Makefile" ;;
8638 "test/cintltst/Makefile") CONFIG_FILES="$CONFIG_FILES test/cintltst/Makefile" ;;
8639 "test/iotest/Makefile") CONFIG_FILES="$CONFIG_FILES test/iotest/Makefile" ;;
8640 "test/letest/Makefile") CONFIG_FILES="$CONFIG_FILES test/letest/Makefile" ;;
8641 "test/perf/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/Makefile" ;;
8642 "test/perf/collationperf/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/collationperf/Makefile" ;;
51004dcb 8643 "test/perf/collperf/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/collperf/Makefile" ;;
57a6839d 8644 "test/perf/collperf2/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/collperf2/Makefile" ;;
4388f060 8645 "test/perf/dicttrieperf/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/dicttrieperf/Makefile" ;;
729e4ab9
A
8646 "test/perf/ubrkperf/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/ubrkperf/Makefile" ;;
8647 "test/perf/charperf/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/charperf/Makefile" ;;
8648 "test/perf/convperf/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/convperf/Makefile" ;;
8649 "test/perf/normperf/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/normperf/Makefile" ;;
8650 "test/perf/DateFmtPerf/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/DateFmtPerf/Makefile" ;;
4388f060 8651 "test/perf/howExpensiveIs/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/howExpensiveIs/Makefile" ;;
729e4ab9
A
8652 "test/perf/strsrchperf/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/strsrchperf/Makefile" ;;
8653 "test/perf/unisetperf/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/unisetperf/Makefile" ;;
8654 "test/perf/usetperf/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/usetperf/Makefile" ;;
8655 "test/perf/ustrperf/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/ustrperf/Makefile" ;;
8656 "test/perf/utfperf/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/utfperf/Makefile" ;;
8657 "test/perf/utrie2perf/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/utrie2perf/Makefile" ;;
57a6839d 8658 "test/perf/leperf/Makefile") CONFIG_FILES="$CONFIG_FILES test/perf/leperf/Makefile" ;;
729e4ab9
A
8659 "samples/Makefile") CONFIG_FILES="$CONFIG_FILES samples/Makefile" ;;
8660 "samples/date/Makefile") CONFIG_FILES="$CONFIG_FILES samples/date/Makefile" ;;
8661 "samples/cal/Makefile") CONFIG_FILES="$CONFIG_FILES samples/cal/Makefile" ;;
8662 "samples/layout/Makefile") CONFIG_FILES="$CONFIG_FILES samples/layout/Makefile" ;;
729e4ab9
A
8663
8664 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
b75a7d8f 8665 esac
73c04bcf
A
8666done
8667
729e4ab9 8668
73c04bcf
A
8669# If the user did not use the arguments to specify the items to instantiate,
8670# then the envvar interface is used. Set only those that are not.
8671# We use the long form for the default assignment because of an extremely
8672# bizarre bug on SunOS 4.1.3.
8673if $ac_need_defaults; then
8674 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
73c04bcf
A
8675fi
8676
8677# Have a temporary directory for convenience. Make it in the build tree
729e4ab9 8678# simply because there is no reason against having it here, and in addition,
73c04bcf 8679# creating and moving files from /tmp can sometimes cause problems.
729e4ab9
A
8680# Hook for its removal unless debugging.
8681# Note that there is a small window in which the directory will not be cleaned:
8682# after its creation but before its name has been assigned to `$tmp'.
73c04bcf
A
8683$debug ||
8684{
4388f060 8685 tmp= ac_tmp=
729e4ab9 8686 trap 'exit_status=$?
4388f060
A
8687 : "${ac_tmp:=$tmp}"
8688 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
729e4ab9
A
8689' 0
8690 trap 'as_fn_exit 1' 1 2 13 15
73c04bcf 8691}
73c04bcf
A
8692# Create a (secure) tmp directory for tmp files.
8693
8694{
729e4ab9 8695 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
4388f060 8696 test -d "$tmp"
73c04bcf
A
8697} ||
8698{
729e4ab9
A
8699 tmp=./conf$$-$RANDOM
8700 (umask 077 && mkdir "$tmp")
8701} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
4388f060 8702ac_tmp=$tmp
729e4ab9
A
8703
8704# Set up the scripts for CONFIG_FILES section.
8705# No need to generate them if there are no CONFIG_FILES.
8706# This happens for instance with `./config.status config.h'.
8707if test -n "$CONFIG_FILES"; then
8708
8709
8710ac_cr=`echo X | tr X '\015'`
8711# On cygwin, bash can eat \r inside `` if the user requested igncr.
8712# But we know of no other shell where ac_cr would be empty at this
8713# point, so we can use a bashism as a fallback.
8714if test "x$ac_cr" = x; then
8715 eval ac_cr=\$\'\\r\'
8716fi
8717ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
8718if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
8719 ac_cs_awk_cr='\\r'
8720else
8721 ac_cs_awk_cr=$ac_cr
8722fi
8723
4388f060 8724echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
729e4ab9
A
8725_ACEOF
8726
8727
8728{
8729 echo "cat >conf$$subs.awk <<_ACEOF" &&
8730 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
8731 echo "_ACEOF"
8732} >conf$$subs.sh ||
8733 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
8734ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
8735ac_delim='%!_!# '
8736for ac_last_try in false false false false false :; do
8737 . ./conf$$subs.sh ||
8738 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
8739
8740 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
8741 if test $ac_delim_n = $ac_delim_num; then
8742 break
8743 elif $ac_last_try; then
8744 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
8745 else
8746 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
8747 fi
8748done
8749rm -f conf$$subs.sh
8750
8751cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
4388f060 8752cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
729e4ab9
A
8753_ACEOF
8754sed -n '
8755h
8756s/^/S["/; s/!.*/"]=/
8757p
8758g
8759s/^[^!]*!//
8760:repl
8761t repl
8762s/'"$ac_delim"'$//
8763t delim
8764:nl
8765h
8766s/\(.\{148\}\)..*/\1/
8767t more1
8768s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
8769p
8770n
8771b repl
8772:more1
8773s/["\\]/\\&/g; s/^/"/; s/$/"\\/
8774p
8775g
8776s/.\{148\}//
8777t nl
8778:delim
8779h
8780s/\(.\{148\}\)..*/\1/
8781t more2
8782s/["\\]/\\&/g; s/^/"/; s/$/"/
8783p
8784b
8785:more2
8786s/["\\]/\\&/g; s/^/"/; s/$/"\\/
8787p
8788g
8789s/.\{148\}//
8790t delim
8791' <conf$$subs.awk | sed '
8792/^[^""]/{
8793 N
8794 s/\n//
8795}
8796' >>$CONFIG_STATUS || ac_write_fail=1
8797rm -f conf$$subs.awk
8798cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
8799_ACAWK
4388f060 8800cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
729e4ab9
A
8801 for (key in S) S_is_set[key] = 1
8802 FS = "\a"
8803
8804}
73c04bcf 8805{
729e4ab9
A
8806 line = $ 0
8807 nfields = split(line, field, "@")
8808 substed = 0
8809 len = length(field[1])
8810 for (i = 2; i < nfields; i++) {
8811 key = field[i]
8812 keylen = length(key)
8813 if (S_is_set[key]) {
8814 value = S[key]
8815 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
8816 len += length(value) + length(field[++i])
8817 substed = 1
8818 } else
8819 len += 1 + keylen
8820 }
8821
8822 print line
73c04bcf
A
8823}
8824
729e4ab9
A
8825_ACAWK
8826_ACEOF
8827cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
8828if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
8829 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
8830else
8831 cat
4388f060 8832fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
729e4ab9 8833 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
73c04bcf
A
8834_ACEOF
8835
729e4ab9
A
8836# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
8837# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
8838# trailing colons and then remove the whole line if VPATH becomes empty
8839# (actually we leave an empty line to preserve line numbers).
8840if test "x$srcdir" = x.; then
8841 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
8842h
8843s///
8844s/^/:/
8845s/[ ]*$/:/
8846s/:\$(srcdir):/:/g
8847s/:\${srcdir}:/:/g
8848s/:@srcdir@:/:/g
8849s/^:*//
8850s/:*$//
8851x
8852s/\(=[ ]*\).*/\1/
8853G
8854s/\n//
8855s/^[^=]*=[ ]*$//
8856}'
8857fi
b75a7d8f 8858
729e4ab9
A
8859cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
8860fi # test -n "$CONFIG_FILES"
73c04bcf 8861
729e4ab9 8862
4388f060 8863eval set X " :F $CONFIG_FILES "
729e4ab9
A
8864shift
8865for ac_tag
8866do
8867 case $ac_tag in
8868 :[FHLC]) ac_mode=$ac_tag; continue;;
8869 esac
8870 case $ac_mode$ac_tag in
8871 :[FHL]*:*);;
8872 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
8873 :[FH]-) ac_tag=-:-;;
8874 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
8875 esac
8876 ac_save_IFS=$IFS
8877 IFS=:
8878 set x $ac_tag
8879 IFS=$ac_save_IFS
8880 shift
8881 ac_file=$1
8882 shift
8883
8884 case $ac_mode in
8885 :L) ac_source=$1;;
8886 :[FH])
8887 ac_file_inputs=
8888 for ac_f
8889 do
8890 case $ac_f in
4388f060 8891 -) ac_f="$ac_tmp/stdin";;
729e4ab9
A
8892 *) # Look for the file first in the build tree, then in the source tree
8893 # (if the path is not absolute). The absolute path cannot be DOS-style,
8894 # because $ac_f cannot contain `:'.
8895 test -f "$ac_f" ||
8896 case $ac_f in
8897 [\\/$]*) false;;
8898 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
8899 esac ||
8900 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
8901 esac
8902 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
8903 as_fn_append ac_file_inputs " '$ac_f'"
8904 done
8905
8906 # Let's still pretend it is `configure' which instantiates (i.e., don't
8907 # use $as_me), people would be surprised to read:
8908 # /* config.h. Generated by config.status. */
8909 configure_input='Generated from '`
8910 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
8911 `' by configure.'
8912 if test x"$ac_file" != x-; then
8913 configure_input="$ac_file. $configure_input"
8914 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
8915$as_echo "$as_me: creating $ac_file" >&6;}
8916 fi
8917 # Neutralize special characters interpreted by sed in replacement strings.
8918 case $configure_input in #(
8919 *\&* | *\|* | *\\* )
8920 ac_sed_conf_input=`$as_echo "$configure_input" |
8921 sed 's/[\\\\&|]/\\\\&/g'`;; #(
8922 *) ac_sed_conf_input=$configure_input;;
8923 esac
8924
8925 case $ac_tag in
4388f060 8926 *:-:* | *:-) cat >"$ac_tmp/stdin" \
729e4ab9
A
8927 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
8928 esac
8929 ;;
b75a7d8f
A
8930 esac
8931
729e4ab9 8932 ac_dir=`$as_dirname -- "$ac_file" ||
73c04bcf
A
8933$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
8934 X"$ac_file" : 'X\(//\)[^/]' \| \
8935 X"$ac_file" : 'X\(//\)$' \| \
729e4ab9
A
8936 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
8937$as_echo X"$ac_file" |
8938 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
8939 s//\1/
8940 q
8941 }
8942 /^X\(\/\/\)[^/].*/{
8943 s//\1/
8944 q
8945 }
8946 /^X\(\/\/\)$/{
8947 s//\1/
8948 q
8949 }
8950 /^X\(\/\).*/{
8951 s//\1/
8952 q
8953 }
8954 s/.*/./; q'`
8955 as_dir="$ac_dir"; as_fn_mkdir_p
73c04bcf
A
8956 ac_builddir=.
8957
729e4ab9
A
8958case "$ac_dir" in
8959.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
8960*)
8961 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
8962 # A ".." for each directory in $ac_dir_suffix.
8963 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
8964 case $ac_top_builddir_sub in
8965 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
8966 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
8967 esac ;;
8968esac
8969ac_abs_top_builddir=$ac_pwd
8970ac_abs_builddir=$ac_pwd$ac_dir_suffix
8971# for backward compatibility:
8972ac_top_builddir=$ac_top_build_prefix
73c04bcf
A
8973
8974case $srcdir in
729e4ab9 8975 .) # We are building in place.
73c04bcf 8976 ac_srcdir=.
729e4ab9
A
8977 ac_top_srcdir=$ac_top_builddir_sub
8978 ac_abs_top_srcdir=$ac_pwd ;;
8979 [\\/]* | ?:[\\/]* ) # Absolute name.
73c04bcf 8980 ac_srcdir=$srcdir$ac_dir_suffix;
729e4ab9
A
8981 ac_top_srcdir=$srcdir
8982 ac_abs_top_srcdir=$srcdir ;;
8983 *) # Relative name.
8984 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
8985 ac_top_srcdir=$ac_top_build_prefix$srcdir
8986 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
73c04bcf 8987esac
729e4ab9 8988ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
73c04bcf 8989
73c04bcf 8990
729e4ab9
A
8991 case $ac_mode in
8992 :F)
8993 #
8994 # CONFIG_FILE
8995 #
73c04bcf
A
8996
8997 case $INSTALL in
8998 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
729e4ab9 8999 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
b75a7d8f 9000 esac
729e4ab9 9001_ACEOF
b75a7d8f 9002
729e4ab9
A
9003cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
9004# If the template does not know about datarootdir, expand it.
9005# FIXME: This hack should be removed a few years after 2.60.
9006ac_datarootdir_hack=; ac_datarootdir_seen=
9007ac_sed_dataroot='
9008/datarootdir/ {
9009 p
9010 q
9011}
9012/@datadir@/p
9013/@docdir@/p
9014/@infodir@/p
9015/@localedir@/p
9016/@mandir@/p'
9017case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
9018*datarootdir*) ac_datarootdir_seen=yes;;
9019*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
9020 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
9021$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
9022_ACEOF
9023cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9024 ac_datarootdir_hack='
9025 s&@datadir@&$datadir&g
9026 s&@docdir@&$docdir&g
9027 s&@infodir@&$infodir&g
9028 s&@localedir@&$localedir&g
9029 s&@mandir@&$mandir&g
9030 s&\\\${datarootdir}&$datarootdir&g' ;;
9031esac
73c04bcf 9032_ACEOF
729e4ab9
A
9033
9034# Neutralize VPATH when `$srcdir' = `.'.
9035# Shell code in configure.ac might set extrasub.
9036# FIXME: do we really want to maintain this feature?
9037cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
9038ac_sed_extra="$ac_vpsub
73c04bcf
A
9039$extrasub
9040_ACEOF
729e4ab9 9041cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
73c04bcf
A
9042:t
9043/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
729e4ab9
A
9044s|@configure_input@|$ac_sed_conf_input|;t t
9045s&@top_builddir@&$ac_top_builddir_sub&;t t
9046s&@top_build_prefix@&$ac_top_build_prefix&;t t
9047s&@srcdir@&$ac_srcdir&;t t
9048s&@abs_srcdir@&$ac_abs_srcdir&;t t
9049s&@top_srcdir@&$ac_top_srcdir&;t t
9050s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
9051s&@builddir@&$ac_builddir&;t t
9052s&@abs_builddir@&$ac_abs_builddir&;t t
9053s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
9054s&@INSTALL@&$ac_INSTALL&;t t
9055$ac_datarootdir_hack
9056"
4388f060
A
9057eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
9058 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
729e4ab9
A
9059
9060test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
4388f060
A
9061 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
9062 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
9063 "$ac_tmp/out"`; test -z "$ac_out"; } &&
729e4ab9
A
9064 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
9065which seems to be undefined. Please make sure it is defined" >&5
9066$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
9067which seems to be undefined. Please make sure it is defined" >&2;}
9068
4388f060 9069 rm -f "$ac_tmp/stdin"
729e4ab9 9070 case $ac_file in
4388f060
A
9071 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
9072 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
729e4ab9
A
9073 esac \
9074 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
9075 ;;
4388f060 9076
73c04bcf 9077
b75a7d8f 9078
b75a7d8f
A
9079 esac
9080
729e4ab9 9081done # for ac_tag
b75a7d8f 9082
b75a7d8f 9083
729e4ab9 9084as_fn_exit 0
73c04bcf 9085_ACEOF
73c04bcf
A
9086ac_clean_files=$ac_clean_files_save
9087
729e4ab9
A
9088test $ac_write_fail = 0 ||
9089 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
9090
73c04bcf
A
9091
9092# configure is writing to config.log, and then calls config.status.
9093# config.status does its own redirection, appending to config.log.
9094# Unfortunately, on DOS this fails, as config.log is still kept open
9095# by configure, so config.status won't be able to write to it; its
9096# output is simply discarded. So we exec the FD to /dev/null,
9097# effectively closing config.log, so it can be properly (re)opened and
9098# appended to by config.status. When coming back to configure, we
9099# need to make the FD available again.
9100if test "$no_create" != yes; then
9101 ac_cs_success=:
9102 ac_config_status_args=
9103 test "$silent" = yes &&
9104 ac_config_status_args="$ac_config_status_args --quiet"
9105 exec 5>/dev/null
9106 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
9107 exec 5>>config.log
9108 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
9109 # would make configure fail if this is the last instruction.
729e4ab9 9110 $ac_cs_success || as_fn_exit 1
73c04bcf 9111fi
729e4ab9
A
9112if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
9113 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
9114$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
9115fi
9116
b75a7d8f 9117
3d1f044b
A
9118if test -z "$PYTHON";
9119then
9120 echo "" > data/rules.mk
9121 echo "" > test/testdata/rules.mk
9122else
9123 if test -f "$srcdir/data/locales/root.txt";
9124 then
9125 echo "Spawning Python to generate data/rules.mk..."
9126 PYTHONPATH="$srcdir/data" $PYTHON -m buildtool \
9127 --mode gnumake \
9128 --seqmode parallel \
9129 --src_dir "$srcdir/data" \
9130 --filter_file "$ICU_DATA_FILTER_FILE" \
9131 $ICU_DATA_BUILDTOOL_OPTS \
9132 > data/rules.mk
9133 if test "$?" != "0"; then
9134 as_fn_error $? "Python failed to run; see above error." "$LINENO" 5
9135 fi
9136 else
9137 echo "Not rebuilding data/rules.mk, assuming prebuilt data in data/in"
9138 touch data/rules.mk
9139 fi
9140 echo "Spawning Python to generate test/testdata/rules.mk..."
9141 PYTHONPATH="$srcdir/test/testdata:$srcdir/data" $PYTHON -m buildtool \
9142 --mode gnumake \
9143 --seqmode parallel \
9144 --src_dir "$srcdir/test/testdata" \
9145 > test/testdata/rules.mk
9146 if test "$?" != "0"; then
9147 as_fn_error $? "Python failed to run; see above error." "$LINENO" 5
9148 fi
9149fi
9150
729e4ab9
A
9151echo
9152echo "ICU for C/C++ $VERSION is ready to be built."
9153echo "=== Important Notes: ==="
b75a7d8f 9154
729e4ab9
A
9155echo "Data Packaging: $datapackaging"
9156echo " This means: $datapackaging_msg"
9157echo " To locate data: $datapackaging_howfound"
9158
73c04bcf 9159if test -n "`$U_MAKE -v 2>&1 | grep '^GNU Make'`"; then
729e4ab9 9160echo "Building ICU: Use a GNU make such as $U_MAKE to build ICU."
73c04bcf 9161else
729e4ab9 9162echo "** WARNING: $U_MAKE may not be GNU make."
73c04bcf 9163echo "This may cause ICU to fail to build. Please make sure that GNU make"
729e4ab9
A
9164echo "is in your PATH so that the configure script can detect its location."
9165fi
4388f060
A
9166if test "x$AR" = "xfalse"; then
9167 echo "*** WARNING: Archiver ar not found. Set AR= or fix PATH. Some builds (such as static) may fail."
9168fi
729e4ab9
A
9169
9170{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the version of \"$U_MAKE\"" >&5
9171$as_echo_n "checking the version of \"$U_MAKE\"... " >&6; }
9172if "$U_MAKE" -f "$srcdir/config/gmakever.mk" PLATFORM="$platform"; then
9173{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
9174$as_echo "ok" >&6; }
9175else
9176{ $as_echo "$as_me:${as_lineno-$LINENO}: result: too old or test failed - try upgrading GNU Make" >&5
9177$as_echo "too old or test failed - try upgrading GNU Make" >&6; }
73c04bcf
A
9178fi
9179
57a6839d 9180
4388f060
A
9181if test -n "$UCONFIG_CPPFLAGS"; then
9182 HDRFILE="uconfig.h.prepend"
9183 echo "*** WARNING: You must set the following flags before code compiled against this ICU will function properly:"
9184 echo
9185 echo " ${UCONFIG_CPPFLAGS}"
9186 echo
9187 echo 'The recommended way to do this is to prepend the following lines to source/common/unicode/uconfig.h or #include them near the top of that file.'
9188 echo "Creating the file ${HDRFILE}"
9189 echo
9190 echo '--------------- ' "${HDRFILE}"
9191 echo > "${HDRFILE}"
9192 echo '/* ICU customizations: put these lines at the top of uconfig.h */' >> "${HDRFILE}"
9193 echo >> "${HDRFILE}"
9194 for flag in ${UCONFIG_CPPFLAGS};
9195 do
9196 echo " /* $flag */" >> "${HDRFILE}"
9197 case "${flag}" in
9198 -D*=*)
9199 \echo "${flag}" | sed -n 's%-D\([^=]*\)=%#define \1 %p' >> "${HDRFILE}"
9200 \echo >> "${HDRFILE}"
9201 ;;
9202 -D*)
9203 \echo "${flag}" | sed -n 's%-D\([^=]*\)%#define \1 %p' >> "${HDRFILE}"
9204 \echo >> "${HDRFILE}"
9205 ;;
9206 *)
9207 \echo "/* Not sure how to handle this argument: ${flag} */" >> "${HDRFILE}"
9208 \echo >> "${HDRFILE}"
9209 ;;
9210 esac
9211 done
9212 cat "${HDRFILE}"
9213 \echo "/* End of ${HDRFILE} ------------ */" >> "${HDRFILE}"
9214 echo >> "${HDRFILE}"
9215 echo '--------------- end ' "${HDRFILE}"
9216fi
9217
57a6839d
A
9218
9219if test -n "$UCONFIG_CFLAGS"; then
9220 echo "C apps may want to build with CFLAGS = ${UCONFIG_CFLAGS}"
9221fi
9222
9223if test -n "$UCONFIG_CXXFLAGS"; then
9224 echo "C++ apps may want to build with CXXFLAGS = ${UCONFIG_CXXFLAGS}"
9225fi
9226
9227if test "$tools" = false;
9228then
9229 echo "## Note: you have disabled ICU's tools. This ICU cannot build its own data or tests."
9230 echo "## Expect build failures in the 'data', 'test', and other directories."
9231fi
9232
3d1f044b
A
9233if test -z "$PYTHON";
9234then
9235 echo "** Note: Python not found. You will not be able to build data from source or run tests."
9236fi
9237
73c04bcf 9238$as_unset _CXX_CXXSUFFIX