1 #!/bin/bash
   2 #
   3 # ##########################################################
   4 # ### THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT. ###
   5 # ##########################################################
   6 #
   7 #! /bin/sh
   8 # Guess values for system-dependent variables and create Makefiles.
   9 # Generated by GNU Autoconf 2.69 for OpenJDK jdk8.
  10 #
  11 # Report bugs to <build-dev@openjdk.java.net>.
  12 #
  13 #
  14 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
  15 #
  16 #
  17 # This configure script is free software; the Free Software Foundation
  18 # gives unlimited permission to copy, distribute and modify it.
  19 ## -------------------- ##
  20 ## M4sh Initialization. ##
  21 ## -------------------- ##
  22 
  23 # Be more Bourne compatible
  24 DUALCASE=1; export DUALCASE # for MKS sh
  25 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
  26   emulate sh
  27   NULLCMD=:
  28   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
  29   # is contrary to our usage.  Disable this feature.
  30   alias -g '${1+"$@"}'='"$@"'
  31   setopt NO_GLOB_SUBST
  32 else
  33   case `(set -o) 2>/dev/null` in #(
  34   *posix*) :
  35     set -o posix ;; #(
  36   *) :
  37      ;;
  38 esac
  39 fi
  40 
  41 
  42 as_nl='
  43 '
  44 export as_nl
  45 # Printing a long string crashes Solaris 7 /usr/bin/printf.
  46 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
  47 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
  48 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
  49 # Prefer a ksh shell builtin over an external printf program on Solaris,
  50 # but without wasting forks for bash or zsh.
  51 if test -z "$BASH_VERSION$ZSH_VERSION" \
  52     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
  53   as_echo='print -r --'
  54   as_echo_n='print -rn --'
  55 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
  56   as_echo='printf %s\n'
  57   as_echo_n='printf %s'
  58 else
  59   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
  60     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
  61     as_echo_n='/usr/ucb/echo -n'
  62   else
  63     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
  64     as_echo_n_body='eval
  65       arg=$1;
  66       case $arg in #(
  67       *"$as_nl"*)
  68         expr "X$arg" : "X\\(.*\\)$as_nl";
  69         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
  70       esac;
  71       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
  72     '
  73     export as_echo_n_body
  74     as_echo_n='sh -c $as_echo_n_body as_echo'
  75   fi
  76   export as_echo_body
  77   as_echo='sh -c $as_echo_body as_echo'
  78 fi
  79 
  80 # The user is always right.
  81 if test "${PATH_SEPARATOR+set}" != set; then
  82   PATH_SEPARATOR=:
  83   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
  84     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
  85       PATH_SEPARATOR=';'
  86   }
  87 fi
  88 
  89 
  90 # IFS
  91 # We need space, tab and new line, in precisely that order.  Quoting is
  92 # there to prevent editors from complaining about space-tab.
  93 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
  94 # splitting by setting IFS to empty value.)
  95 IFS=" ""        $as_nl"
  96 
  97 # Find who we are.  Look in the path if we contain no directory separator.
  98 as_myself=
  99 case $0 in #((
 100   *[\\/]* ) as_myself=$0 ;;
 101   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
 102 for as_dir in $PATH
 103 do
 104   IFS=$as_save_IFS
 105   test -z "$as_dir" && as_dir=.
 106     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
 107   done
 108 IFS=$as_save_IFS
 109 
 110      ;;
 111 esac
 112 # We did not find ourselves, most probably we were run as `sh COMMAND'
 113 # in which case we are not to be found in the path.
 114 if test "x$as_myself" = x; then
 115   as_myself=$0
 116 fi
 117 if test ! -f "$as_myself"; then
 118   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
 119   exit 1
 120 fi
 121 
 122 # Unset variables that we do not need and which cause bugs (e.g. in
 123 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
 124 # suppresses any "Segmentation fault" message there.  '((' could
 125 # trigger a bug in pdksh 5.2.14.
 126 for as_var in BASH_ENV ENV MAIL MAILPATH
 127 do eval test x\${$as_var+set} = xset \
 128   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
 129 done
 130 PS1='$ '
 131 PS2='> '
 132 PS4='+ '
 133 
 134 # NLS nuisances.
 135 LC_ALL=C
 136 export LC_ALL
 137 LANGUAGE=C
 138 export LANGUAGE
 139 
 140 # CDPATH.
 141 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
 142 
 143 # Use a proper internal environment variable to ensure we don't fall
 144   # into an infinite loop, continuously re-executing ourselves.
 145   if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
 146     _as_can_reexec=no; export _as_can_reexec;
 147     # We cannot yet assume a decent shell, so we have to provide a
 148 # neutralization value for shells without unset; and this also
 149 # works around shells that cannot unset nonexistent variables.
 150 # Preserve -v and -x to the replacement shell.
 151 BASH_ENV=/dev/null
 152 ENV=/dev/null
 153 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
 154 case $- in # ((((
 155   *v*x* | *x*v* ) as_opts=-vx ;;
 156   *v* ) as_opts=-v ;;
 157   *x* ) as_opts=-x ;;
 158   * ) as_opts= ;;
 159 esac
 160 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
 161 # Admittedly, this is quite paranoid, since all the known shells bail
 162 # out after a failed `exec'.
 163 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
 164 as_fn_exit 255
 165   fi
 166   # We don't want this to propagate to other subprocesses.
 167           { _as_can_reexec=; unset _as_can_reexec;}
 168 if test "x$CONFIG_SHELL" = x; then
 169   as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
 170   emulate sh
 171   NULLCMD=:
 172   # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
 173   # is contrary to our usage.  Disable this feature.
 174   alias -g '\${1+\"\$@\"}'='\"\$@\"'
 175   setopt NO_GLOB_SUBST
 176 else
 177   case \`(set -o) 2>/dev/null\` in #(
 178   *posix*) :
 179     set -o posix ;; #(
 180   *) :
 181      ;;
 182 esac
 183 fi
 184 "
 185   as_required="as_fn_return () { (exit \$1); }
 186 as_fn_success () { as_fn_return 0; }
 187 as_fn_failure () { as_fn_return 1; }
 188 as_fn_ret_success () { return 0; }
 189 as_fn_ret_failure () { return 1; }
 190 
 191 exitcode=0
 192 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
 193 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
 194 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
 195 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
 196 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
 197 
 198 else
 199   exitcode=1; echo positional parameters were not saved.
 200 fi
 201 test x\$exitcode = x0 || exit 1
 202 test -x / || exit 1"
 203   as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
 204   as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
 205   eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
 206   test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
 207 test \$(( 1 + 1 )) = 2 || exit 1"
 208   if (eval "$as_required") 2>/dev/null; then :
 209   as_have_required=yes
 210 else
 211   as_have_required=no
 212 fi
 213   if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
 214 
 215 else
 216   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
 217 as_found=false
 218 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
 219 do
 220   IFS=$as_save_IFS
 221   test -z "$as_dir" && as_dir=.
 222   as_found=:
 223   case $as_dir in #(
 224          /*)
 225            for as_base in sh bash ksh sh5; do
 226              # Try only shells that exist, to save several forks.
 227              as_shell=$as_dir/$as_base
 228              if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
 229                     { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
 230   CONFIG_SHELL=$as_shell as_have_required=yes
 231                    if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
 232   break 2
 233 fi
 234 fi
 235            done;;
 236        esac
 237   as_found=false
 238 done
 239 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
 240               { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
 241   CONFIG_SHELL=$SHELL as_have_required=yes
 242 fi; }
 243 IFS=$as_save_IFS
 244 
 245 
 246       if test "x$CONFIG_SHELL" != x; then :
 247   export CONFIG_SHELL
 248              # We cannot yet assume a decent shell, so we have to provide a
 249 # neutralization value for shells without unset; and this also
 250 # works around shells that cannot unset nonexistent variables.
 251 # Preserve -v and -x to the replacement shell.
 252 BASH_ENV=/dev/null
 253 ENV=/dev/null
 254 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
 255 case $- in # ((((
 256   *v*x* | *x*v* ) as_opts=-vx ;;
 257   *v* ) as_opts=-v ;;
 258   *x* ) as_opts=-x ;;
 259   * ) as_opts= ;;
 260 esac
 261 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
 262 # Admittedly, this is quite paranoid, since all the known shells bail
 263 # out after a failed `exec'.
 264 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
 265 exit 255
 266 fi
 267 
 268     if test x$as_have_required = xno; then :
 269   $as_echo "$0: This script requires a shell more modern than all"
 270   $as_echo "$0: the shells that I found on your system."
 271   if test x${ZSH_VERSION+set} = xset ; then
 272     $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
 273     $as_echo "$0: be upgraded to zsh 4.3.4 or later."
 274   else
 275     $as_echo "$0: Please tell bug-autoconf@gnu.org and
 276 $0: build-dev@openjdk.java.net about your system, including
 277 $0: any error possibly output before this message. Then
 278 $0: install a modern shell, or manually run the script
 279 $0: under such a shell if you do have one."
 280   fi
 281   exit 1
 282 fi
 283 fi
 284 fi
 285 SHELL=${CONFIG_SHELL-/bin/sh}
 286 export SHELL
 287 # Unset more variables known to interfere with behavior of common tools.
 288 CLICOLOR_FORCE= GREP_OPTIONS=
 289 unset CLICOLOR_FORCE GREP_OPTIONS
 290 
 291 ## --------------------- ##
 292 ## M4sh Shell Functions. ##
 293 ## --------------------- ##
 294 # as_fn_unset VAR
 295 # ---------------
 296 # Portably unset VAR.
 297 as_fn_unset ()
 298 {
 299   { eval $1=; unset $1;}
 300 }
 301 as_unset=as_fn_unset
 302 
 303 # as_fn_set_status STATUS
 304 # -----------------------
 305 # Set $? to STATUS, without forking.
 306 as_fn_set_status ()
 307 {
 308   return $1
 309 } # as_fn_set_status
 310 
 311 # as_fn_exit STATUS
 312 # -----------------
 313 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
 314 as_fn_exit ()
 315 {
 316   set +e
 317   as_fn_set_status $1
 318   exit $1
 319 } # as_fn_exit
 320 
 321 # as_fn_mkdir_p
 322 # -------------
 323 # Create "$as_dir" as a directory, including parents if necessary.
 324 as_fn_mkdir_p ()
 325 {
 326 
 327   case $as_dir in #(
 328   -*) as_dir=./$as_dir;;
 329   esac
 330   test -d "$as_dir" || eval $as_mkdir_p || {
 331     as_dirs=
 332     while :; do
 333       case $as_dir in #(
 334       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
 335       *) as_qdir=$as_dir;;
 336       esac
 337       as_dirs="'$as_qdir' $as_dirs"
 338       as_dir=`$as_dirname -- "$as_dir" ||
 339 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
 340          X"$as_dir" : 'X\(//\)[^/]' \| \
 341          X"$as_dir" : 'X\(//\)$' \| \
 342          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
 343 $as_echo X"$as_dir" |
 344     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
 345             s//\1/
 346             q
 347           }
 348           /^X\(\/\/\)[^/].*/{
 349             s//\1/
 350             q
 351           }
 352           /^X\(\/\/\)$/{
 353             s//\1/
 354             q
 355           }
 356           /^X\(\/\).*/{
 357             s//\1/
 358             q
 359           }
 360           s/.*/./; q'`
 361       test -d "$as_dir" && break
 362     done
 363     test -z "$as_dirs" || eval "mkdir $as_dirs"
 364   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
 365 
 366 
 367 } # as_fn_mkdir_p
 368 
 369 # as_fn_executable_p FILE
 370 # -----------------------
 371 # Test if FILE is an executable regular file.
 372 as_fn_executable_p ()
 373 {
 374   test -f "$1" && test -x "$1"
 375 } # as_fn_executable_p
 376 # as_fn_append VAR VALUE
 377 # ----------------------
 378 # Append the text in VALUE to the end of the definition contained in VAR. Take
 379 # advantage of any shell optimizations that allow amortized linear growth over
 380 # repeated appends, instead of the typical quadratic growth present in naive
 381 # implementations.
 382 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
 383   eval 'as_fn_append ()
 384   {
 385     eval $1+=\$2
 386   }'
 387 else
 388   as_fn_append ()
 389   {
 390     eval $1=\$$1\$2
 391   }
 392 fi # as_fn_append
 393 
 394 # as_fn_arith ARG...
 395 # ------------------
 396 # Perform arithmetic evaluation on the ARGs, and store the result in the
 397 # global $as_val. Take advantage of shells that can avoid forks. The arguments
 398 # must be portable across $(()) and expr.
 399 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
 400   eval 'as_fn_arith ()
 401   {
 402     as_val=$(( $* ))
 403   }'
 404 else
 405   as_fn_arith ()
 406   {
 407     as_val=`expr "$@" || test $? -eq 1`
 408   }
 409 fi # as_fn_arith
 410 
 411 
 412 # as_fn_error STATUS ERROR [LINENO LOG_FD]
 413 # ----------------------------------------
 414 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
 415 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
 416 # script with STATUS, using 1 if that was 0.
 417 as_fn_error ()
 418 {
 419   as_status=$1; test $as_status -eq 0 && as_status=1
 420   if test "$4"; then
 421     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
 422     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
 423   fi
 424   $as_echo "$as_me: error: $2" >&2
 425   as_fn_exit $as_status
 426 } # as_fn_error
 427 
 428 if expr a : '\(a\)' >/dev/null 2>&1 &&
 429    test "X`expr 00001 : '.*\(...\)'`" = X001; then
 430   as_expr=expr
 431 else
 432   as_expr=false
 433 fi
 434 
 435 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
 436   as_basename=basename
 437 else
 438   as_basename=false
 439 fi
 440 
 441 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
 442   as_dirname=dirname
 443 else
 444   as_dirname=false
 445 fi
 446 
 447 as_me=`$as_basename -- "$0" ||
 448 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
 449          X"$0" : 'X\(//\)$' \| \
 450          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
 451 $as_echo X/"$0" |
 452     sed '/^.*\/\([^/][^/]*\)\/*$/{
 453             s//\1/
 454             q
 455           }
 456           /^X\/\(\/\/\)$/{
 457             s//\1/
 458             q
 459           }
 460           /^X\/\(\/\).*/{
 461             s//\1/
 462             q
 463           }
 464           s/.*/./; q'`
 465 
 466 # Avoid depending upon Character Ranges.
 467 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
 468 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
 469 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
 470 as_cr_digits='0123456789'
 471 as_cr_alnum=$as_cr_Letters$as_cr_digits
 472 
 473 
 474   as_lineno_1=$LINENO as_lineno_1a=$LINENO
 475   as_lineno_2=$LINENO as_lineno_2a=$LINENO
 476   eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
 477   test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
 478   # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
 479   sed -n '
 480     p
 481     /[$]LINENO/=
 482   ' <$as_myself |
 483     sed '
 484       s/[$]LINENO.*/&-/
 485       t lineno
 486       b
 487       :lineno
 488       N
 489       :loop
 490       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
 491       t loop
 492       s/-\n.*//
 493     ' >$as_me.lineno &&
 494   chmod +x "$as_me.lineno" ||
 495     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
 496 
 497   # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
 498   # already done that, so ensure we don't try to do so again and fall
 499   # in an infinite loop.  This has already happened in practice.
 500   _as_can_reexec=no; export _as_can_reexec
 501   # Don't try to exec as it changes $[0], causing all sort of problems
 502   # (the dirname of $[0] is not the place where we might find the
 503   # original and so on.  Autoconf is especially sensitive to this).
 504   . "./$as_me.lineno"
 505   # Exit status is that of the last command.
 506   exit
 507 }
 508 
 509 ECHO_C= ECHO_N= ECHO_T=
 510 case `echo -n x` in #(((((
 511 -n*)
 512   case `echo 'xy\c'` in
 513   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
 514   xy)  ECHO_C='\c';;
 515   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
 516        ECHO_T=' ';;
 517   esac;;
 518 *)
 519   ECHO_N='-n';;
 520 esac
 521 
 522 rm -f conf$$ conf$$.exe conf$$.file
 523 if test -d conf$$.dir; then
 524   rm -f conf$$.dir/conf$$.file
 525 else
 526   rm -f conf$$.dir
 527   mkdir conf$$.dir 2>/dev/null
 528 fi
 529 if (echo >conf$$.file) 2>/dev/null; then
 530   if ln -s conf$$.file conf$$ 2>/dev/null; then
 531     as_ln_s='ln -s'
 532     # ... but there are two gotchas:
 533     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
 534     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
 535     # In both cases, we have to default to `cp -pR'.
 536     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
 537       as_ln_s='cp -pR'
 538   elif ln conf$$.file conf$$ 2>/dev/null; then
 539     as_ln_s=ln
 540   else
 541     as_ln_s='cp -pR'
 542   fi
 543 else
 544   as_ln_s='cp -pR'
 545 fi
 546 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
 547 rmdir conf$$.dir 2>/dev/null
 548 
 549 if mkdir -p . 2>/dev/null; then
 550   as_mkdir_p='mkdir -p "$as_dir"'
 551 else
 552   test -d ./-p && rmdir ./-p
 553   as_mkdir_p=false
 554 fi
 555 
 556 as_test_x='test -x'
 557 as_executable_p=as_fn_executable_p
 558 
 559 # Sed expression to map a string onto a valid CPP name.
 560 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
 561 
 562 # Sed expression to map a string onto a valid variable name.
 563 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
 564 
 565 
 566 test -n "$DJDIR" || exec 7<&0 </dev/null
 567 exec 6>&1
 568 
 569 # Name of the host.
 570 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
 571 # so uname gets run too.
 572 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
 573 
 574 #
 575 # Initializations.
 576 #
 577 ac_default_prefix=/usr/local
 578 ac_clean_files=
 579 ac_config_libobj_dir=.
 580 LIBOBJS=
 581 cross_compiling=no
 582 subdirs=
 583 MFLAGS=
 584 MAKEFLAGS=
 585 
 586 # Identity of this package.
 587 PACKAGE_NAME='OpenJDK'
 588 PACKAGE_TARNAME='openjdk'
 589 PACKAGE_VERSION='jdk8'
 590 PACKAGE_STRING='OpenJDK jdk8'
 591 PACKAGE_BUGREPORT='build-dev@openjdk.java.net'
 592 PACKAGE_URL='http://openjdk.java.net'
 593 
 594 # Factoring default headers for most tests.
 595 ac_includes_default="\
 596 #include <stdio.h>
 597 #ifdef HAVE_SYS_TYPES_H
 598 # include <sys/types.h>
 599 #endif
 600 #ifdef HAVE_SYS_STAT_H
 601 # include <sys/stat.h>
 602 #endif
 603 #ifdef STDC_HEADERS
 604 # include <stdlib.h>
 605 # include <stddef.h>
 606 #else
 607 # ifdef HAVE_STDLIB_H
 608 #  include <stdlib.h>
 609 # endif
 610 #endif
 611 #ifdef HAVE_STRING_H
 612 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
 613 #  include <memory.h>
 614 # endif
 615 # include <string.h>
 616 #endif
 617 #ifdef HAVE_STRINGS_H
 618 # include <strings.h>
 619 #endif
 620 #ifdef HAVE_INTTYPES_H
 621 # include <inttypes.h>
 622 #endif
 623 #ifdef HAVE_STDINT_H
 624 # include <stdint.h>
 625 #endif
 626 #ifdef HAVE_UNISTD_H
 627 # include <unistd.h>
 628 #endif"
 629 
 630 ac_subst_vars='LTLIBOBJS
 631 LIBOBJS
 632 CCACHE
 633 USE_PRECOMPILED_HEADER
 634 SJAVAC_SERVER_DIR
 635 ENABLE_SJAVAC
 636 SJAVAC_SERVER_JAVA
 637 JOBS
 638 MEMORY_SIZE
 639 NUM_CORES
 640 ENABLE_INTREE_EC
 641 SALIB_NAME
 642 HOTSPOT_MAKE_ARGS
 643 LIBCXX
 644 LLVM_LIBS
 645 LLVM_LDFLAGS
 646 LLVM_CFLAGS
 647 LLVM_CONFIG
 648 LIBFFI_LIBS
 649 LIBFFI_CFLAGS
 650 STATIC_CXX_SETTING
 651 LIBDL
 652 LIBM
 653 LIBZIP_CAN_USE_MMAP
 654 USE_EXTERNAL_LIBZ
 655 USE_EXTERNAL_LIBGIF
 656 USE_EXTERNAL_LIBJPEG
 657 ALSA_LIBS
 658 ALSA_CFLAGS
 659 FREETYPE_BUNDLE_LIB_PATH
 660 FREETYPE_LIBS
 661 FREETYPE_CFLAGS
 662 CUPS_CFLAGS
 663 OPENWIN_HOME
 664 X_EXTRA_LIBS
 665 X_LIBS
 666 X_PRE_LIBS
 667 X_CFLAGS
 668 XMKMF
 669 FIXPATH
 670 CXXFLAGS_DEBUG_SYMBOLS
 671 CFLAGS_DEBUG_SYMBOLS
 672 ZIP_DEBUGINFO_FILES
 673 ENABLE_DEBUG_SYMBOLS
 674 USING_BROKEN_SUSE_LD
 675 COMPILER_SUPPORTS_TARGET_BITS_FLAG
 676 ZERO_ARCHFLAG
 677 LDFLAGS_CXX_JDK
 678 LDFLAGS_JDKEXE_SUFFIX
 679 LDFLAGS_JDKLIB_SUFFIX
 680 LDFLAGS_JDKEXE
 681 LDFLAGS_JDKLIB
 682 CXXFLAGS_JDKEXE
 683 CXXFLAGS_JDKLIB
 684 CFLAGS_JDKEXE
 685 CFLAGS_JDKLIB
 686 MACOSX_VERSION_MIN
 687 PACKAGE_PATH
 688 LEGACY_EXTRA_LDFLAGS
 689 LEGACY_EXTRA_CXXFLAGS
 690 LEGACY_EXTRA_CFLAGS
 691 CXX_FLAG_DEPS
 692 C_FLAG_DEPS
 693 CXX_O_FLAG_NONE
 694 CXX_O_FLAG_NORM
 695 CXX_O_FLAG_HI
 696 CXX_O_FLAG_HIGHEST
 697 C_O_FLAG_NONE
 698 C_O_FLAG_NORM
 699 C_O_FLAG_HI
 700 C_O_FLAG_HIGHEST
 701 POST_MCS_CMD
 702 POST_STRIP_CMD
 703 SET_EXECUTABLE_ORIGIN
 704 SET_SHARED_LIBRARY_ORIGIN
 705 CXX_FLAG_REORDER
 706 C_FLAG_REORDER
 707 SET_SHARED_LIBRARY_MAPFILE
 708 SET_SHARED_LIBRARY_NAME
 709 SHARED_LIBRARY_FLAGS
 710 EXE_SUFFIX
 711 STATIC_LIBRARY_SUFFIX
 712 SHARED_LIBRARY_SUFFIX
 713 LIBRARY_PREFIX
 714 STATIC_LIBRARY
 715 SHARED_LIBRARY
 716 OBJ_SUFFIX
 717 COMPILER_NAME
 718 JT_HOME
 719 JTREGEXE
 720 LIPO
 721 ac_ct_OBJDUMP
 722 OBJDUMP
 723 ac_ct_OBJCOPY
 724 OBJCOPY
 725 ac_ct_STRIP
 726 ac_ct_NM
 727 MCS
 728 STRIP
 729 GNM
 730 NM
 731 AS
 732 CXXCPP
 733 CPP
 734 COMPILER_TYPE
 735 RC_FLAGS
 736 DUMPBIN
 737 WINAR
 738 HOTSPOT_RC
 739 HOTSPOT_MT
 740 RC
 741 MT
 742 WINLD
 743 HOTSPOT_LD
 744 HOTSPOT_CXX
 745 ARFLAGS
 746 ac_ct_AR
 747 AR
 748 LDEXECXX
 749 LDCXX
 750 LDEXE
 751 LD
 752 ac_ct_OBJC
 753 OBJCFLAGS
 754 OBJC
 755 ac_ct_CXX
 756 CXXFLAGS
 757 CXX
 758 ac_ct_PROPER_COMPILER_CXX
 759 PROPER_COMPILER_CXX
 760 TOOLS_DIR_CXX
 761 POTENTIAL_CXX
 762 COMPILER_TARGET_BITS_FLAG
 763 OBJEXT
 764 EXEEXT
 765 ac_ct_CC
 766 CPPFLAGS
 767 LDFLAGS
 768 CFLAGS
 769 CC
 770 ac_ct_PROPER_COMPILER_CC
 771 PROPER_COMPILER_CC
 772 TOOLS_DIR_CC
 773 POTENTIAL_CC
 774 BUILD_LD
 775 BUILD_CXX
 776 BUILD_CC
 777 MSVCR_DLL
 778 VS_PATH
 779 VS_LIB
 780 VS_INCLUDE
 781 CYGWIN_LINK
 782 AR_OUT_OPTION
 783 LD_OUT_OPTION
 784 EXE_OUT_OPTION
 785 CC_OUT_OPTION
 786 BUILD_HOTSPOT
 787 HOTSPOT_DIST
 788 BUILD_OUTPUT
 789 OVERRIDE_SRC_ROOT
 790 ADD_SRC_ROOT
 791 JDK_TOPDIR
 792 NASHORN_TOPDIR
 793 HOTSPOT_TOPDIR
 794 JAXWS_TOPDIR
 795 JAXP_TOPDIR
 796 CORBA_TOPDIR
 797 LANGTOOLS_TOPDIR
 798 BOOT_JDK_JVMARGS
 799 JAVAC_FLAGS
 800 BOOT_JDK_SOURCETARGET
 801 JARSIGNER
 802 NATIVE2ASCII
 803 JAR
 804 JAVAH
 805 JAVAC
 806 JAVA
 807 BOOT_JDK
 808 BOOT_TOOLSJAR
 809 BOOT_RTJAR
 810 JAVA_CHECK
 811 JAVAC_CHECK
 812 COOKED_BUILD_NUMBER
 813 JDK_VERSION
 814 COPYRIGHT_YEAR
 815 MACOSX_BUNDLE_ID_BASE
 816 MACOSX_BUNDLE_NAME_BASE
 817 COMPANY_NAME
 818 JDK_RC_PLATFORM_NAME
 819 PRODUCT_SUFFIX
 820 PRODUCT_NAME
 821 LAUNCHER_NAME
 822 MILESTONE
 823 JDK_BUILD_NUMBER
 824 JDK_UPDATE_VERSION
 825 JDK_MICRO_VERSION
 826 JDK_MINOR_VERSION
 827 JDK_MAJOR_VERSION
 828 USER_RELEASE_SUFFIX
 829 COMPRESS_JARS
 830 RMICONNECTOR_IIOP
 831 UNLIMITED_CRYPTO
 832 CACERTS_FILE
 833 TEST_IN_BUILD
 834 BUILD_HEADLESS
 835 SUPPORT_HEADFUL
 836 SUPPORT_HEADLESS
 837 BDEPS_FTP
 838 BDEPS_UNZIP
 839 OS_VERSION_MICRO
 840 OS_VERSION_MINOR
 841 OS_VERSION_MAJOR
 842 PKG_CONFIG
 843 CODESIGN
 844 XATTR
 845 DSYMUTIL
 846 IS_GNU_TIME
 847 TIME
 848 STAT
 849 HG
 850 READELF
 851 OTOOL
 852 LDD
 853 ZIP
 854 UNZIP
 855 FIND_DELETE
 856 MAKE
 857 CHECK_TOOLSDIR_MAKE
 858 CHECK_TOOLSDIR_GMAKE
 859 CHECK_MAKE
 860 CHECK_GMAKE
 861 PKGHANDLER
 862 OUTPUT_ROOT
 863 CONF_NAME
 864 SPEC
 865 BUILD_VARIANT_RELEASE
 866 DEBUG_CLASSFILES
 867 FASTDEBUG
 868 VARIANT
 869 DEBUG_LEVEL
 870 MACOSX_UNIVERSAL
 871 INCLUDE_SA
 872 JVM_VARIANT_CORE
 873 JVM_VARIANT_ZEROSHARK
 874 JVM_VARIANT_ZERO
 875 JVM_VARIANT_KERNEL
 876 JVM_VARIANT_MINIMAL1
 877 JVM_VARIANT_CLIENT
 878 JVM_VARIANT_SERVER
 879 JVM_VARIANTS
 880 JVM_INTERPRETER
 881 JDK_VARIANT
 882 SET_OPENJDK
 883 BUILD_LOG_WRAPPER
 884 BUILD_LOG_PREVIOUS
 885 BUILD_LOG
 886 SYS_ROOT
 887 PATH_SEP
 888 TOPDIR
 889 ZERO_ARCHDEF
 890 DEFINE_CROSS_COMPILE_ARCH
 891 LP64
 892 OPENJDK_TARGET_OS_EXPORT_DIR
 893 OPENJDK_TARGET_OS_API_DIR
 894 OPENJDK_TARGET_CPU_JLI_CFLAGS
 895 OPENJDK_TARGET_CPU_OSARCH
 896 OPENJDK_TARGET_CPU_ISADIR
 897 OPENJDK_TARGET_CPU_LIBDIR
 898 OPENJDK_TARGET_CPU_LEGACY_LIB
 899 OPENJDK_TARGET_CPU_LEGACY
 900 REQUIRED_OS_VERSION
 901 REQUIRED_OS_NAME
 902 COMPILE_TYPE
 903 OPENJDK_TARGET_CPU_ENDIAN
 904 OPENJDK_TARGET_CPU_BITS
 905 OPENJDK_TARGET_CPU_ARCH
 906 OPENJDK_TARGET_CPU
 907 OPENJDK_TARGET_OS_API
 908 OPENJDK_TARGET_OS
 909 OPENJDK_BUILD_CPU_ENDIAN
 910 OPENJDK_BUILD_CPU_BITS
 911 OPENJDK_BUILD_CPU_ARCH
 912 OPENJDK_BUILD_CPU
 913 OPENJDK_BUILD_OS_API
 914 OPENJDK_BUILD_OS
 915 OPENJDK_BUILD_AUTOCONF_NAME
 916 OPENJDK_TARGET_AUTOCONF_NAME
 917 target_os
 918 target_vendor
 919 target_cpu
 920 target
 921 host_os
 922 host_vendor
 923 host_cpu
 924 host
 925 build_os
 926 build_vendor
 927 build_cpu
 928 build
 929 SETFILE
 930 DF
 931 READLINK
 932 CYGPATH
 933 SED
 934 FGREP
 935 EGREP
 936 GREP
 937 AWK
 938 XARGS
 939 WHICH
 940 WC
 941 UNIQ
 942 UNAME
 943 TR
 944 TOUCH
 945 TEE
 946 TAR
 947 TAIL
 948 SORT
 949 SH
 950 RM
 951 PRINTF
 952 NAWK
 953 MV
 954 MKTEMP
 955 MKDIR
 956 LS
 957 LN
 958 HEAD
 959 FIND
 960 FILE
 961 EXPR
 962 ECHO
 963 DIRNAME
 964 DIFF
 965 DATE
 966 CUT
 967 CPIO
 968 CP
 969 COMM
 970 CMP
 971 CHMOD
 972 CAT
 973 BASH
 974 BASENAME
 975 DATE_WHEN_CONFIGURED
 976 CONFIGURE_COMMAND_LINE
 977 target_alias
 978 host_alias
 979 build_alias
 980 LIBS
 981 ECHO_T
 982 ECHO_N
 983 ECHO_C
 984 DEFS
 985 mandir
 986 localedir
 987 libdir
 988 psdir
 989 pdfdir
 990 dvidir
 991 htmldir
 992 infodir
 993 docdir
 994 oldincludedir
 995 includedir
 996 localstatedir
 997 sharedstatedir
 998 sysconfdir
 999 datadir
1000 datarootdir
1001 libexecdir
1002 sbindir
1003 bindir
1004 program_transform_name
1005 prefix
1006 exec_prefix
1007 PACKAGE_URL
1008 PACKAGE_BUGREPORT
1009 PACKAGE_STRING
1010 PACKAGE_VERSION
1011 PACKAGE_TARNAME
1012 PACKAGE_NAME
1013 PATH_SEPARATOR
1014 SHELL'
1015 ac_subst_files=''
1016 ac_user_opts='
1017 enable_option_checking
1018 with_target_bits
1019 with_sys_root
1020 with_tools_dir
1021 with_devkit
1022 enable_openjdk_only
1023 with_custom_make_dir
1024 with_jdk_variant
1025 with_jvm_interpreter
1026 with_jvm_variants
1027 enable_debug
1028 with_debug_level
1029 with_conf_name
1030 with_builddeps_conf
1031 with_builddeps_server
1032 with_builddeps_dir
1033 with_builddeps_group
1034 enable_headful
1035 enable_hotspot_test_in_build
1036 with_cacerts_file
1037 enable_unlimited_crypto
1038 enable_rmiconnector_iiop
1039 with_milestone
1040 with_update_version
1041 with_user_release_suffix
1042 with_build_number
1043 with_boot_jdk
1044 with_boot_jdk_jvmargs
1045 with_add_source_root
1046 with_override_source_root
1047 with_adds_and_overrides
1048 with_override_langtools
1049 with_override_corba
1050 with_override_jaxp
1051 with_override_jaxws
1052 with_override_hotspot
1053 with_override_nashorn
1054 with_override_jdk
1055 with_import_hotspot
1056 with_msvcr_dll
1057 with_dxsdk
1058 with_dxsdk_lib
1059 with_dxsdk_include
1060 with_jtreg
1061 with_extra_cflags
1062 with_extra_cxxflags
1063 with_extra_ldflags
1064 enable_debug_symbols
1065 enable_zip_debug_info
1066 enable_macosx_runtime_support
1067 with_x
1068 with_cups
1069 with_cups_include
1070 with_freetype
1071 with_freetype_include
1072 with_freetype_lib
1073 enable_freetype_bundling
1074 with_alsa
1075 with_alsa_include
1076 with_alsa_lib
1077 with_giflib
1078 with_zlib
1079 with_stdc__lib
1080 with_num_cores
1081 with_memory_size
1082 with_jobs
1083 with_sjavac_server_java
1084 enable_sjavac
1085 enable_precompiled_headers
1086 enable_ccache
1087 with_ccache_dir
1088 '
1089       ac_precious_vars='build_alias
1090 host_alias
1091 target_alias
1092 BASENAME
1093 BASH
1094 CAT
1095 CHMOD
1096 CMP
1097 COMM
1098 CP
1099 CPIO
1100 CUT
1101 DATE
1102 DIFF
1103 DIRNAME
1104 ECHO
1105 EXPR
1106 FILE
1107 FIND
1108 HEAD
1109 LN
1110 LS
1111 MKDIR
1112 MKTEMP
1113 MV
1114 NAWK
1115 PRINTF
1116 RM
1117 SH
1118 SORT
1119 TAIL
1120 TAR
1121 TEE
1122 TOUCH
1123 TR
1124 UNAME
1125 UNIQ
1126 WC
1127 WHICH
1128 XARGS
1129 AWK
1130 GREP
1131 EGREP
1132 FGREP
1133 SED
1134 CYGPATH
1135 READLINK
1136 DF
1137 SETFILE
1138 UNZIP
1139 ZIP
1140 LDD
1141 OTOOL
1142 READELF
1143 HG
1144 STAT
1145 TIME
1146 DSYMUTIL
1147 XATTR
1148 CODESIGN
1149 PKG_CONFIG
1150 JAVA
1151 JAVAC
1152 JAVAH
1153 JAR
1154 NATIVE2ASCII
1155 JARSIGNER
1156 BUILD_CC
1157 BUILD_CXX
1158 BUILD_LD
1159 CC
1160 CFLAGS
1161 LDFLAGS
1162 LIBS
1163 CPPFLAGS
1164 CXX
1165 CXXFLAGS
1166 CCC
1167 OBJC
1168 OBJCFLAGS
1169 AR
1170 CPP
1171 CXXCPP
1172 AS
1173 NM
1174 GNM
1175 STRIP
1176 MCS
1177 OBJCOPY
1178 OBJDUMP
1179 LIPO
1180 JTREGEXE
1181 XMKMF
1182 FREETYPE_CFLAGS
1183 FREETYPE_LIBS
1184 ALSA_CFLAGS
1185 ALSA_LIBS
1186 LIBFFI_CFLAGS
1187 LIBFFI_LIBS
1188 CCACHE'
1189 
1190 
1191 # Initialize some variables set by options.
1192 ac_init_help=
1193 ac_init_version=false
1194 ac_unrecognized_opts=
1195 ac_unrecognized_sep=
1196 # The variables have the same names as the options, with
1197 # dashes changed to underlines.
1198 cache_file=/dev/null
1199 exec_prefix=NONE
1200 no_create=
1201 no_recursion=
1202 prefix=NONE
1203 program_prefix=NONE
1204 program_suffix=NONE
1205 program_transform_name=s,x,x,
1206 silent=
1207 site=
1208 srcdir=
1209 verbose=
1210 x_includes=NONE
1211 x_libraries=NONE
1212 
1213 # Installation directory options.
1214 # These are left unexpanded so users can "make install exec_prefix=/foo"
1215 # and all the variables that are supposed to be based on exec_prefix
1216 # by default will actually change.
1217 # Use braces instead of parens because sh, perl, etc. also accept them.
1218 # (The list follows the same order as the GNU Coding Standards.)
1219 bindir='${exec_prefix}/bin'
1220 sbindir='${exec_prefix}/sbin'
1221 libexecdir='${exec_prefix}/libexec'
1222 datarootdir='${prefix}/share'
1223 datadir='${datarootdir}'
1224 sysconfdir='${prefix}/etc'
1225 sharedstatedir='${prefix}/com'
1226 localstatedir='${prefix}/var'
1227 includedir='${prefix}/include'
1228 oldincludedir='/usr/include'
1229 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1230 infodir='${datarootdir}/info'
1231 htmldir='${docdir}'
1232 dvidir='${docdir}'
1233 pdfdir='${docdir}'
1234 psdir='${docdir}'
1235 libdir='${exec_prefix}/lib'
1236 localedir='${datarootdir}/locale'
1237 mandir='${datarootdir}/man'
1238 
1239 ac_prev=
1240 ac_dashdash=
1241 for ac_option
1242 do
1243   # If the previous option needs an argument, assign it.
1244   if test -n "$ac_prev"; then
1245     eval $ac_prev=\$ac_option
1246     ac_prev=
1247     continue
1248   fi
1249 
1250   case $ac_option in
1251   *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1252   *=)   ac_optarg= ;;
1253   *)    ac_optarg=yes ;;
1254   esac
1255 
1256   # Accept the important Cygnus configure options, so we can diagnose typos.
1257 
1258   case $ac_dashdash$ac_option in
1259   --)
1260     ac_dashdash=yes ;;
1261 
1262   -bindir | --bindir | --bindi | --bind | --bin | --bi)
1263     ac_prev=bindir ;;
1264   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1265     bindir=$ac_optarg ;;
1266 
1267   -build | --build | --buil | --bui | --bu)
1268     ac_prev=build_alias ;;
1269   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1270     build_alias=$ac_optarg ;;
1271 
1272   -cache-file | --cache-file | --cache-fil | --cache-fi \
1273   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1274     ac_prev=cache_file ;;
1275   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1276   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1277     cache_file=$ac_optarg ;;
1278 
1279   --config-cache | -C)
1280     cache_file=config.cache ;;
1281 
1282   -datadir | --datadir | --datadi | --datad)
1283     ac_prev=datadir ;;
1284   -datadir=* | --datadir=* | --datadi=* | --datad=*)
1285     datadir=$ac_optarg ;;
1286 
1287   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1288   | --dataroo | --dataro | --datar)
1289     ac_prev=datarootdir ;;
1290   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1291   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1292     datarootdir=$ac_optarg ;;
1293 
1294   -disable-* | --disable-*)
1295     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1296     # Reject names that are not valid shell variable names.
1297     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1298       as_fn_error $? "invalid feature name: $ac_useropt"
1299     ac_useropt_orig=$ac_useropt
1300     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1301     case $ac_user_opts in
1302       *"
1303 "enable_$ac_useropt"
1304 "*) ;;
1305       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1306          ac_unrecognized_sep=', ';;
1307     esac
1308     eval enable_$ac_useropt=no ;;
1309 
1310   -docdir | --docdir | --docdi | --doc | --do)
1311     ac_prev=docdir ;;
1312   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1313     docdir=$ac_optarg ;;
1314 
1315   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1316     ac_prev=dvidir ;;
1317   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1318     dvidir=$ac_optarg ;;
1319 
1320   -enable-* | --enable-*)
1321     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1322     # Reject names that are not valid shell variable names.
1323     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1324       as_fn_error $? "invalid feature name: $ac_useropt"
1325     ac_useropt_orig=$ac_useropt
1326     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1327     case $ac_user_opts in
1328       *"
1329 "enable_$ac_useropt"
1330 "*) ;;
1331       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1332          ac_unrecognized_sep=', ';;
1333     esac
1334     eval enable_$ac_useropt=\$ac_optarg ;;
1335 
1336   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1337   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1338   | --exec | --exe | --ex)
1339     ac_prev=exec_prefix ;;
1340   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1341   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1342   | --exec=* | --exe=* | --ex=*)
1343     exec_prefix=$ac_optarg ;;
1344 
1345   -gas | --gas | --ga | --g)
1346     # Obsolete; use --with-gas.
1347     with_gas=yes ;;
1348 
1349   -help | --help | --hel | --he | -h)
1350     ac_init_help=long ;;
1351   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1352     ac_init_help=recursive ;;
1353   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1354     ac_init_help=short ;;
1355 
1356   -host | --host | --hos | --ho)
1357     ac_prev=host_alias ;;
1358   -host=* | --host=* | --hos=* | --ho=*)
1359     host_alias=$ac_optarg ;;
1360 
1361   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1362     ac_prev=htmldir ;;
1363   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1364   | --ht=*)
1365     htmldir=$ac_optarg ;;
1366 
1367   -includedir | --includedir | --includedi | --included | --include \
1368   | --includ | --inclu | --incl | --inc)
1369     ac_prev=includedir ;;
1370   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1371   | --includ=* | --inclu=* | --incl=* | --inc=*)
1372     includedir=$ac_optarg ;;
1373 
1374   -infodir | --infodir | --infodi | --infod | --info | --inf)
1375     ac_prev=infodir ;;
1376   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1377     infodir=$ac_optarg ;;
1378 
1379   -libdir | --libdir | --libdi | --libd)
1380     ac_prev=libdir ;;
1381   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1382     libdir=$ac_optarg ;;
1383 
1384   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1385   | --libexe | --libex | --libe)
1386     ac_prev=libexecdir ;;
1387   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1388   | --libexe=* | --libex=* | --libe=*)
1389     libexecdir=$ac_optarg ;;
1390 
1391   -localedir | --localedir | --localedi | --localed | --locale)
1392     ac_prev=localedir ;;
1393   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1394     localedir=$ac_optarg ;;
1395 
1396   -localstatedir | --localstatedir | --localstatedi | --localstated \
1397   | --localstate | --localstat | --localsta | --localst | --locals)
1398     ac_prev=localstatedir ;;
1399   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1400   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1401     localstatedir=$ac_optarg ;;
1402 
1403   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1404     ac_prev=mandir ;;
1405   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1406     mandir=$ac_optarg ;;
1407 
1408   -nfp | --nfp | --nf)
1409     # Obsolete; use --without-fp.
1410     with_fp=no ;;
1411 
1412   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1413   | --no-cr | --no-c | -n)
1414     no_create=yes ;;
1415 
1416   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1417   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1418     no_recursion=yes ;;
1419 
1420   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1421   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1422   | --oldin | --oldi | --old | --ol | --o)
1423     ac_prev=oldincludedir ;;
1424   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1425   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1426   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1427     oldincludedir=$ac_optarg ;;
1428 
1429   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1430     ac_prev=prefix ;;
1431   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1432     prefix=$ac_optarg ;;
1433 
1434   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1435   | --program-pre | --program-pr | --program-p)
1436     ac_prev=program_prefix ;;
1437   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1438   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1439     program_prefix=$ac_optarg ;;
1440 
1441   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1442   | --program-suf | --program-su | --program-s)
1443     ac_prev=program_suffix ;;
1444   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1445   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1446     program_suffix=$ac_optarg ;;
1447 
1448   -program-transform-name | --program-transform-name \
1449   | --program-transform-nam | --program-transform-na \
1450   | --program-transform-n | --program-transform- \
1451   | --program-transform | --program-transfor \
1452   | --program-transfo | --program-transf \
1453   | --program-trans | --program-tran \
1454   | --progr-tra | --program-tr | --program-t)
1455     ac_prev=program_transform_name ;;
1456   -program-transform-name=* | --program-transform-name=* \
1457   | --program-transform-nam=* | --program-transform-na=* \
1458   | --program-transform-n=* | --program-transform-=* \
1459   | --program-transform=* | --program-transfor=* \
1460   | --program-transfo=* | --program-transf=* \
1461   | --program-trans=* | --program-tran=* \
1462   | --progr-tra=* | --program-tr=* | --program-t=*)
1463     program_transform_name=$ac_optarg ;;
1464 
1465   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1466     ac_prev=pdfdir ;;
1467   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1468     pdfdir=$ac_optarg ;;
1469 
1470   -psdir | --psdir | --psdi | --psd | --ps)
1471     ac_prev=psdir ;;
1472   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1473     psdir=$ac_optarg ;;
1474 
1475   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1476   | -silent | --silent | --silen | --sile | --sil)
1477     silent=yes ;;
1478 
1479   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1480     ac_prev=sbindir ;;
1481   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1482   | --sbi=* | --sb=*)
1483     sbindir=$ac_optarg ;;
1484 
1485   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1486   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1487   | --sharedst | --shareds | --shared | --share | --shar \
1488   | --sha | --sh)
1489     ac_prev=sharedstatedir ;;
1490   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1491   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1492   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1493   | --sha=* | --sh=*)
1494     sharedstatedir=$ac_optarg ;;
1495 
1496   -site | --site | --sit)
1497     ac_prev=site ;;
1498   -site=* | --site=* | --sit=*)
1499     site=$ac_optarg ;;
1500 
1501   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1502     ac_prev=srcdir ;;
1503   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1504     srcdir=$ac_optarg ;;
1505 
1506   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1507   | --syscon | --sysco | --sysc | --sys | --sy)
1508     ac_prev=sysconfdir ;;
1509   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1510   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1511     sysconfdir=$ac_optarg ;;
1512 
1513   -target | --target | --targe | --targ | --tar | --ta | --t)
1514     ac_prev=target_alias ;;
1515   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1516     target_alias=$ac_optarg ;;
1517 
1518   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1519     verbose=yes ;;
1520 
1521   -version | --version | --versio | --versi | --vers | -V)
1522     ac_init_version=: ;;
1523 
1524   -with-* | --with-*)
1525     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1526     # Reject names that are not valid shell variable names.
1527     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1528       as_fn_error $? "invalid package name: $ac_useropt"
1529     ac_useropt_orig=$ac_useropt
1530     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1531     case $ac_user_opts in
1532       *"
1533 "with_$ac_useropt"
1534 "*) ;;
1535       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1536          ac_unrecognized_sep=', ';;
1537     esac
1538     eval with_$ac_useropt=\$ac_optarg ;;
1539 
1540   -without-* | --without-*)
1541     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1542     # Reject names that are not valid shell variable names.
1543     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1544       as_fn_error $? "invalid package name: $ac_useropt"
1545     ac_useropt_orig=$ac_useropt
1546     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1547     case $ac_user_opts in
1548       *"
1549 "with_$ac_useropt"
1550 "*) ;;
1551       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1552          ac_unrecognized_sep=', ';;
1553     esac
1554     eval with_$ac_useropt=no ;;
1555 
1556   --x)
1557     # Obsolete; use --with-x.
1558     with_x=yes ;;
1559 
1560   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1561   | --x-incl | --x-inc | --x-in | --x-i)
1562     ac_prev=x_includes ;;
1563   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1564   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1565     x_includes=$ac_optarg ;;
1566 
1567   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1568   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1569     ac_prev=x_libraries ;;
1570   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1571   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1572     x_libraries=$ac_optarg ;;
1573 
1574   -*) as_fn_error $? "unrecognized option: \`$ac_option'
1575 Try \`$0 --help' for more information"
1576     ;;
1577 
1578   *=*)
1579     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1580     # Reject names that are not valid shell variable names.
1581     case $ac_envvar in #(
1582       '' | [0-9]* | *[!_$as_cr_alnum]* )
1583       as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1584     esac
1585     eval $ac_envvar=\$ac_optarg
1586     export $ac_envvar ;;
1587 
1588   *)
1589     # FIXME: should be removed in autoconf 3.0.
1590     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1591     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1592       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1593     : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1594     ;;
1595 
1596   esac
1597 done
1598 
1599 if test -n "$ac_prev"; then
1600   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1601   as_fn_error $? "missing argument to $ac_option"
1602 fi
1603 
1604 if test -n "$ac_unrecognized_opts"; then
1605   case $enable_option_checking in
1606     no) ;;
1607     fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1608     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1609   esac
1610 fi
1611 
1612 # Check all directory arguments for consistency.
1613 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1614                 datadir sysconfdir sharedstatedir localstatedir includedir \
1615                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1616                 libdir localedir mandir
1617 do
1618   eval ac_val=\$$ac_var
1619   # Remove trailing slashes.
1620   case $ac_val in
1621     */ )
1622       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1623       eval $ac_var=\$ac_val;;
1624   esac
1625   # Be sure to have absolute directory names.
1626   case $ac_val in
1627     [\\/$]* | ?:[\\/]* )  continue;;
1628     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1629   esac
1630   as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1631 done
1632 
1633 # There might be people who depend on the old broken behavior: `$host'
1634 # used to hold the argument of --host etc.
1635 # FIXME: To remove some day.
1636 build=$build_alias
1637 host=$host_alias
1638 target=$target_alias
1639 
1640 # FIXME: To remove some day.
1641 if test "x$host_alias" != x; then
1642   if test "x$build_alias" = x; then
1643     cross_compiling=maybe
1644   elif test "x$build_alias" != "x$host_alias"; then
1645     cross_compiling=yes
1646   fi
1647 fi
1648 
1649 ac_tool_prefix=
1650 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1651 
1652 test "$silent" = yes && exec 6>/dev/null
1653 
1654 
1655 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1656 ac_ls_di=`ls -di .` &&
1657 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1658   as_fn_error $? "working directory cannot be determined"
1659 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1660   as_fn_error $? "pwd does not report name of working directory"
1661 
1662 
1663 # Find the source files, if location was not specified.
1664 if test -z "$srcdir"; then
1665   ac_srcdir_defaulted=yes
1666   # Try the directory containing this script, then the parent directory.
1667   ac_confdir=`$as_dirname -- "$as_myself" ||
1668 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1669          X"$as_myself" : 'X\(//\)[^/]' \| \
1670          X"$as_myself" : 'X\(//\)$' \| \
1671          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1672 $as_echo X"$as_myself" |
1673     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1674             s//\1/
1675             q
1676           }
1677           /^X\(\/\/\)[^/].*/{
1678             s//\1/
1679             q
1680           }
1681           /^X\(\/\/\)$/{
1682             s//\1/
1683             q
1684           }
1685           /^X\(\/\).*/{
1686             s//\1/
1687             q
1688           }
1689           s/.*/./; q'`
1690   srcdir=$ac_confdir
1691   if test ! -r "$srcdir/$ac_unique_file"; then
1692     srcdir=..
1693   fi
1694 else
1695   ac_srcdir_defaulted=no
1696 fi
1697 if test ! -r "$srcdir/$ac_unique_file"; then
1698   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1699   as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1700 fi
1701 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1702 ac_abs_confdir=`(
1703         cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1704         pwd)`
1705 # When building in place, set srcdir=.
1706 if test "$ac_abs_confdir" = "$ac_pwd"; then
1707   srcdir=.
1708 fi
1709 # Remove unnecessary trailing slashes from srcdir.
1710 # Double slashes in file names in object file debugging info
1711 # mess up M-x gdb in Emacs.
1712 case $srcdir in
1713 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1714 esac
1715 for ac_var in $ac_precious_vars; do
1716   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1717   eval ac_env_${ac_var}_value=\$${ac_var}
1718   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1719   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1720 done
1721 
1722 #
1723 # Report the --help message.
1724 #
1725 if test "$ac_init_help" = "long"; then
1726   # Omit some internal or obsolete options to make the list less imposing.
1727   # This message is too long to be a string in the A/UX 3.1 sh.
1728   cat <<_ACEOF
1729 \`configure' configures OpenJDK jdk8 to adapt to many kinds of systems.
1730 
1731 Usage: $0 [OPTION]... [VAR=VALUE]...
1732 
1733 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1734 VAR=VALUE.  See below for descriptions of some of the useful variables.
1735 
1736 Defaults for the options are specified in brackets.
1737 
1738 Configuration:
1739   -h, --help              display this help and exit
1740       --help=short        display options specific to this package
1741       --help=recursive    display the short help of all the included packages
1742   -V, --version           display version information and exit
1743   -q, --quiet, --silent   do not print \`checking ...' messages
1744       --cache-file=FILE   cache test results in FILE [disabled]
1745   -C, --config-cache      alias for \`--cache-file=config.cache'
1746   -n, --no-create         do not create output files
1747       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1748 
1749 Installation directories:
1750   --prefix=PREFIX         install architecture-independent files in PREFIX
1751                           [$ac_default_prefix]
1752   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1753                           [PREFIX]
1754 
1755 By default, \`make install' will install all the files in
1756 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1757 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1758 for instance \`--prefix=\$HOME'.
1759 
1760 For better control, use the options below.
1761 
1762 Fine tuning of the installation directories:
1763   --bindir=DIR            user executables [EPREFIX/bin]
1764   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1765   --libexecdir=DIR        program executables [EPREFIX/libexec]
1766   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1767   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1768   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1769   --libdir=DIR            object code libraries [EPREFIX/lib]
1770   --includedir=DIR        C header files [PREFIX/include]
1771   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1772   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1773   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1774   --infodir=DIR           info documentation [DATAROOTDIR/info]
1775   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1776   --mandir=DIR            man documentation [DATAROOTDIR/man]
1777   --docdir=DIR            documentation root [DATAROOTDIR/doc/openjdk]
1778   --htmldir=DIR           html documentation [DOCDIR]
1779   --dvidir=DIR            dvi documentation [DOCDIR]
1780   --pdfdir=DIR            pdf documentation [DOCDIR]
1781   --psdir=DIR             ps documentation [DOCDIR]
1782 _ACEOF
1783 
1784   cat <<\_ACEOF
1785 
1786 X features:
1787   --x-includes=DIR    X include files are in DIR
1788   --x-libraries=DIR   X library files are in DIR
1789 
1790 System types:
1791   --build=BUILD     configure for building on BUILD [guessed]
1792   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1793   --target=TARGET   configure for building compilers for TARGET [HOST]
1794 _ACEOF
1795 fi
1796 
1797 if test -n "$ac_init_help"; then
1798   case $ac_init_help in
1799      short | recursive ) echo "Configuration of OpenJDK jdk8:";;
1800    esac
1801   cat <<\_ACEOF
1802 
1803 Optional Features:
1804   --disable-option-checking  ignore unrecognized --enable/--with options
1805   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1806   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1807   --enable-openjdk-only   suppress building custom source even if present
1808                           [disabled]
1809   --enable-debug          set the debug level to fastdebug (shorthand for
1810                           --with-debug-level=fastdebug) [disabled]
1811   --disable-headful       disable building headful support (graphical UI
1812                           support) [enabled]
1813   --enable-hotspot-test-in-build
1814                           run the Queens test after Hotspot build [disabled]
1815   --enable-unlimited-crypto
1816                           Enable unlimited crypto policy [disabled]
1817   --enable-rmiconnector-iiop
1818                           enable the JMX RMIConnector iiop transport
1819                           [disabled]
1820   --disable-debug-symbols disable generation of debug symbols [enabled]
1821   --disable-zip-debug-info
1822                           disable zipping of debug-info files [enabled]
1823   --enable-macosx-runtime-support
1824                           Deprecated. Option is kept for backwards
1825                           compatibility and is ignored
1826   --disable-freetype-bundling
1827                           disable bundling of the freetype library with the
1828                           build result [enabled on Windows or when using
1829                           --with-freetype, disabled otherwise]
1830   --enable-sjavac         use sjavac to do fast incremental compiles
1831                           [disabled]
1832   --disable-precompiled-headers
1833                           disable using precompiled headers when compiling C++
1834                           [enabled]
1835   --enable-ccache         enable using ccache to speed up recompilations
1836                           [disabled]
1837 
1838 Optional Packages:
1839   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1840   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1841   --with-target-bits      build 32-bit or 64-bit binaries (for platforms that
1842                           support it), e.g. --with-target-bits=32 [guessed]
1843   --with-sys-root         pass this sys-root to the compilers and tools (for
1844                           cross-compiling)
1845   --with-tools-dir        search this directory for compilers and tools (for
1846                           cross-compiling)
1847   --with-devkit           use this directory as base for tools-dir and
1848                           sys-root (for cross-compiling)
1849   --with-custom-make-dir  Deprecated. Option is kept for backwards
1850                           compatibility and is ignored
1851   --with-jdk-variant      JDK variant to build (normal) [normal]
1852   --with-jvm-interpreter  JVM interpreter to build (template, cpp) [template]
1853   --with-jvm-variants     JVM variants (separated by commas) to build (server,
1854                           client, minimal1, kernel, zero, zeroshark, core)
1855                           [server]
1856   --with-debug-level      set the debug level (release, fastdebug, slowdebug)
1857                           [release]
1858   --with-conf-name        use this as the name of the configuration [generated
1859                           from important configuration options]
1860   --with-builddeps-conf   use this configuration file for the builddeps
1861   --with-builddeps-server download and use build dependencies from this server
1862                           url
1863   --with-builddeps-dir    store downloaded build dependencies here
1864                           [/localhome/builddeps]
1865   --with-builddeps-group  chgrp the downloaded build dependencies to this
1866                           group
1867   --with-cacerts-file     specify alternative cacerts file
1868   --with-milestone        Set milestone value for build [internal]
1869   --with-update-version   Set update version value for build [b00]
1870   --with-user-release-suffix
1871                           Add a custom string to the version string if build
1872                           number is not set.[username_builddateb00]
1873   --with-build-number     Set build number value for build [b00]
1874   --with-boot-jdk         path to Boot JDK (used to bootstrap build) [probed]
1875   --with-boot-jdk-jvmargs specify JVM arguments to be passed to all
1876                           invocations of the Boot JDK, overriding the default
1877                           values, e.g --with-boot-jdk-jvmargs="-Xmx8G
1878                           -enableassertions"
1879   --with-add-source-root  for each and every source directory, look in this
1880                           additional source root for the same directory; if it
1881                           exists and have files in it, include it in the build
1882   --with-override-source-root
1883                           for each and every source directory, look in this
1884                           override source root for the same directory; if it
1885                           exists, use that directory instead and ignore the
1886                           directory in the original source root
1887   --with-adds-and-overrides
1888                           use the subdirs 'adds' and 'overrides' in the
1889                           specified directory as add-source-root and
1890                           override-source-root
1891   --with-override-langtools
1892                           use this langtools dir for the build
1893   --with-override-corba   use this corba dir for the build
1894   --with-override-jaxp    use this jaxp dir for the build
1895   --with-override-jaxws   use this jaxws dir for the build
1896   --with-override-hotspot use this hotspot dir for the build
1897   --with-override-nashorn use this nashorn dir for the build
1898   --with-override-jdk     use this jdk dir for the build
1899   --with-import-hotspot   import hotspot binaries from this jdk image or
1900                           hotspot build dist dir instead of building from
1901                           source
1902   --with-msvcr-dll        copy this msvcr100.dll into the built JDK (Windows
1903                           only) [probed]
1904   --with-dxsdk            Deprecated. Option is kept for backwards
1905                           compatibility and is ignored
1906   --with-dxsdk-lib        Deprecated. Option is kept for backwards
1907                           compatibility and is ignored
1908   --with-dxsdk-include    Deprecated. Option is kept for backwards
1909                           compatibility and is ignored
1910   --with-jtreg            Regression Test Harness [probed]
1911   --with-extra-cflags     extra flags to be used when compiling jdk c-files
1912   --with-extra-cxxflags   extra flags to be used when compiling jdk c++-files
1913   --with-extra-ldflags    extra flags to be used when linking jdk
1914   --with-x                use the X Window System
1915   --with-cups             specify prefix directory for the cups package
1916                           (expecting the headers under PATH/include)
1917   --with-cups-include     specify directory for the cups include files
1918   --with-freetype         specify prefix directory for the freetype package
1919                           (expecting the libraries under PATH/lib and the
1920                           headers under PATH/include)
1921   --with-freetype-include specify directory for the freetype include files
1922   --with-freetype-lib     specify directory for the freetype library
1923   --with-alsa             specify prefix directory for the alsa package
1924                           (expecting the libraries under PATH/lib and the
1925                           headers under PATH/include)
1926   --with-alsa-include     specify directory for the alsa include files
1927   --with-alsa-lib         specify directory for the alsa library
1928   --with-giflib           use giflib from build system or OpenJDK source
1929                           (system, bundled) [bundled]
1930   --with-zlib             use zlib from build system or OpenJDK source
1931                           (system, bundled) [bundled]
1932   --with-stdc++lib=<static>,<dynamic>,<default>
1933                           force linking of the C++ runtime on Linux to either
1934                           static or dynamic, default is static with dynamic as
1935                           fallback
1936   --with-num-cores        number of cores in the build system, e.g.
1937                           --with-num-cores=8 [probed]
1938   --with-memory-size      memory (in MB) available in the build system, e.g.
1939                           --with-memory-size=1024 [probed]
1940   --with-jobs             number of parallel jobs to let make run [calculated
1941                           based on cores and memory]
1942   --with-sjavac-server-java
1943                           use this java binary for running the sjavac
1944                           background server [Boot JDK java]
1945   --with-ccache-dir       where to store ccache files [~/.ccache]
1946 
1947 Some influential environment variables:
1948   BASENAME    Override default value for BASENAME
1949   BASH        Override default value for BASH
1950   CAT         Override default value for CAT
1951   CHMOD       Override default value for CHMOD
1952   CMP         Override default value for CMP
1953   COMM        Override default value for COMM
1954   CP          Override default value for CP
1955   CPIO        Override default value for CPIO
1956   CUT         Override default value for CUT
1957   DATE        Override default value for DATE
1958   DIFF        Override default value for DIFF
1959   DIRNAME     Override default value for DIRNAME
1960   ECHO        Override default value for ECHO
1961   EXPR        Override default value for EXPR
1962   FILE        Override default value for FILE
1963   FIND        Override default value for FIND
1964   HEAD        Override default value for HEAD
1965   LN          Override default value for LN
1966   LS          Override default value for LS
1967   MKDIR       Override default value for MKDIR
1968   MKTEMP      Override default value for MKTEMP
1969   MV          Override default value for MV
1970   NAWK        Override default value for NAWK
1971   PRINTF      Override default value for PRINTF
1972   RM          Override default value for RM
1973   SH          Override default value for SH
1974   SORT        Override default value for SORT
1975   TAIL        Override default value for TAIL
1976   TAR         Override default value for TAR
1977   TEE         Override default value for TEE
1978   TOUCH       Override default value for TOUCH
1979   TR          Override default value for TR
1980   UNAME       Override default value for UNAME
1981   UNIQ        Override default value for UNIQ
1982   WC          Override default value for WC
1983   WHICH       Override default value for WHICH
1984   XARGS       Override default value for XARGS
1985   AWK         Override default value for AWK
1986   GREP        Override default value for GREP
1987   EGREP       Override default value for EGREP
1988   FGREP       Override default value for FGREP
1989   SED         Override default value for SED
1990   CYGPATH     Override default value for CYGPATH
1991   READLINK    Override default value for READLINK
1992   DF          Override default value for DF
1993   SETFILE     Override default value for SETFILE
1994   UNZIP       Override default value for UNZIP
1995   ZIP         Override default value for ZIP
1996   LDD         Override default value for LDD
1997   OTOOL       Override default value for OTOOL
1998   READELF     Override default value for READELF
1999   HG          Override default value for HG
2000   STAT        Override default value for STAT
2001   TIME        Override default value for TIME
2002   DSYMUTIL    Override default value for DSYMUTIL
2003   XATTR       Override default value for XATTR
2004   CODESIGN    Override default value for CODESIGN
2005   PKG_CONFIG  path to pkg-config utility
2006   JAVA        Override default value for JAVA
2007   JAVAC       Override default value for JAVAC
2008   JAVAH       Override default value for JAVAH
2009   JAR         Override default value for JAR
2010   NATIVE2ASCII
2011               Override default value for NATIVE2ASCII
2012   JARSIGNER   Override default value for JARSIGNER
2013   BUILD_CC    Override default value for BUILD_CC
2014   BUILD_CXX   Override default value for BUILD_CXX
2015   BUILD_LD    Override default value for BUILD_LD
2016   CC          C compiler command
2017   CFLAGS      C compiler flags
2018   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
2019               nonstandard directory <lib dir>
2020   LIBS        libraries to pass to the linker, e.g. -l<library>
2021   CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2022               you have headers in a nonstandard directory <include dir>
2023   CXX         C++ compiler command
2024   CXXFLAGS    C++ compiler flags
2025   OBJC        Objective C compiler command
2026   OBJCFLAGS   Objective C compiler flags
2027   AR          Override default value for AR
2028   CPP         C preprocessor
2029   CXXCPP      C++ preprocessor
2030   AS          Override default value for AS
2031   NM          Override default value for NM
2032   GNM         Override default value for GNM
2033   STRIP       Override default value for STRIP
2034   MCS         Override default value for MCS
2035   OBJCOPY     Override default value for OBJCOPY
2036   OBJDUMP     Override default value for OBJDUMP
2037   LIPO        Override default value for LIPO
2038   JTREGEXE    Override default value for JTREGEXE
2039   XMKMF       Path to xmkmf, Makefile generator for X Window System
2040   FREETYPE_CFLAGS
2041               C compiler flags for FREETYPE, overriding pkg-config
2042   FREETYPE_LIBS
2043               linker flags for FREETYPE, overriding pkg-config
2044   ALSA_CFLAGS C compiler flags for ALSA, overriding pkg-config
2045   ALSA_LIBS   linker flags for ALSA, overriding pkg-config
2046   LIBFFI_CFLAGS
2047               C compiler flags for LIBFFI, overriding pkg-config
2048   LIBFFI_LIBS linker flags for LIBFFI, overriding pkg-config
2049   CCACHE      Override default value for CCACHE
2050 
2051 Use these variables to override the choices made by `configure' or to help
2052 it to find libraries and programs with nonstandard names/locations.
2053 
2054 Report bugs to <build-dev@openjdk.java.net>.
2055 OpenJDK home page: <http://openjdk.java.net>.
2056 _ACEOF
2057 ac_status=$?
2058 fi
2059 
2060 if test "$ac_init_help" = "recursive"; then
2061   # If there are subdirs, report their specific --help.
2062   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2063     test -d "$ac_dir" ||
2064       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2065       continue
2066     ac_builddir=.
2067 
2068 case "$ac_dir" in
2069 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2070 *)
2071   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2072   # A ".." for each directory in $ac_dir_suffix.
2073   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2074   case $ac_top_builddir_sub in
2075   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2076   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2077   esac ;;
2078 esac
2079 ac_abs_top_builddir=$ac_pwd
2080 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2081 # for backward compatibility:
2082 ac_top_builddir=$ac_top_build_prefix
2083 
2084 case $srcdir in
2085   .)  # We are building in place.
2086     ac_srcdir=.
2087     ac_top_srcdir=$ac_top_builddir_sub
2088     ac_abs_top_srcdir=$ac_pwd ;;
2089   [\\/]* | ?:[\\/]* )  # Absolute name.
2090     ac_srcdir=$srcdir$ac_dir_suffix;
2091     ac_top_srcdir=$srcdir
2092     ac_abs_top_srcdir=$srcdir ;;
2093   *) # Relative name.
2094     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2095     ac_top_srcdir=$ac_top_build_prefix$srcdir
2096     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2097 esac
2098 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2099 
2100     cd "$ac_dir" || { ac_status=$?; continue; }
2101     # Check for guested configure.
2102     if test -f "$ac_srcdir/configure.gnu"; then
2103       echo &&
2104       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2105     elif test -f "$ac_srcdir/configure"; then
2106       echo &&
2107       $SHELL "$ac_srcdir/configure" --help=recursive
2108     else
2109       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2110     fi || ac_status=$?
2111     cd "$ac_pwd" || { ac_status=$?; break; }
2112   done
2113 fi
2114 
2115 test -n "$ac_init_help" && exit $ac_status
2116 if $ac_init_version; then
2117   cat <<\_ACEOF
2118 OpenJDK configure jdk8
2119 generated by GNU Autoconf 2.69
2120 
2121 Copyright (C) 2012 Free Software Foundation, Inc.
2122 This configure script is free software; the Free Software Foundation
2123 gives unlimited permission to copy, distribute and modify it.
2124 _ACEOF
2125   exit
2126 fi
2127 
2128 ## ------------------------ ##
2129 ## Autoconf initialization. ##
2130 ## ------------------------ ##
2131 
2132 # ac_fn_c_try_compile LINENO
2133 # --------------------------
2134 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2135 ac_fn_c_try_compile ()
2136 {
2137   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2138   rm -f conftest.$ac_objext
2139   if { { ac_try="$ac_compile"
2140 case "(($ac_try" in
2141   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2142   *) ac_try_echo=$ac_try;;
2143 esac
2144 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2145 $as_echo "$ac_try_echo"; } >&5
2146   (eval "$ac_compile") 2>conftest.err
2147   ac_status=$?
2148   if test -s conftest.err; then
2149     grep -v '^ *+' conftest.err >conftest.er1
2150     cat conftest.er1 >&5
2151     mv -f conftest.er1 conftest.err
2152   fi
2153   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2154   test $ac_status = 0; } && {
2155          test -z "$ac_c_werror_flag" ||
2156          test ! -s conftest.err
2157        } && test -s conftest.$ac_objext; then :
2158   ac_retval=0
2159 else
2160   $as_echo "$as_me: failed program was:" >&5
2161 sed 's/^/| /' conftest.$ac_ext >&5
2162 
2163         ac_retval=1
2164 fi
2165   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2166   as_fn_set_status $ac_retval
2167 
2168 } # ac_fn_c_try_compile
2169 
2170 # ac_fn_cxx_try_compile LINENO
2171 # ----------------------------
2172 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2173 ac_fn_cxx_try_compile ()
2174 {
2175   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2176   rm -f conftest.$ac_objext
2177   if { { ac_try="$ac_compile"
2178 case "(($ac_try" in
2179   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2180   *) ac_try_echo=$ac_try;;
2181 esac
2182 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2183 $as_echo "$ac_try_echo"; } >&5
2184   (eval "$ac_compile") 2>conftest.err
2185   ac_status=$?
2186   if test -s conftest.err; then
2187     grep -v '^ *+' conftest.err >conftest.er1
2188     cat conftest.er1 >&5
2189     mv -f conftest.er1 conftest.err
2190   fi
2191   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2192   test $ac_status = 0; } && {
2193          test -z "$ac_cxx_werror_flag" ||
2194          test ! -s conftest.err
2195        } && test -s conftest.$ac_objext; then :
2196   ac_retval=0
2197 else
2198   $as_echo "$as_me: failed program was:" >&5
2199 sed 's/^/| /' conftest.$ac_ext >&5
2200 
2201         ac_retval=1
2202 fi
2203   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2204   as_fn_set_status $ac_retval
2205 
2206 } # ac_fn_cxx_try_compile
2207 
2208 # ac_fn_objc_try_compile LINENO
2209 # -----------------------------
2210 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2211 ac_fn_objc_try_compile ()
2212 {
2213   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2214   rm -f conftest.$ac_objext
2215   if { { ac_try="$ac_compile"
2216 case "(($ac_try" in
2217   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2218   *) ac_try_echo=$ac_try;;
2219 esac
2220 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2221 $as_echo "$ac_try_echo"; } >&5
2222   (eval "$ac_compile") 2>conftest.err
2223   ac_status=$?
2224   if test -s conftest.err; then
2225     grep -v '^ *+' conftest.err >conftest.er1
2226     cat conftest.er1 >&5
2227     mv -f conftest.er1 conftest.err
2228   fi
2229   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2230   test $ac_status = 0; } && {
2231          test -z "$ac_objc_werror_flag" ||
2232          test ! -s conftest.err
2233        } && test -s conftest.$ac_objext; then :
2234   ac_retval=0
2235 else
2236   $as_echo "$as_me: failed program was:" >&5
2237 sed 's/^/| /' conftest.$ac_ext >&5
2238 
2239         ac_retval=1
2240 fi
2241   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2242   as_fn_set_status $ac_retval
2243 
2244 } # ac_fn_objc_try_compile
2245 
2246 # ac_fn_c_try_cpp LINENO
2247 # ----------------------
2248 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2249 ac_fn_c_try_cpp ()
2250 {
2251   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2252   if { { ac_try="$ac_cpp conftest.$ac_ext"
2253 case "(($ac_try" in
2254   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2255   *) ac_try_echo=$ac_try;;
2256 esac
2257 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2258 $as_echo "$ac_try_echo"; } >&5
2259   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2260   ac_status=$?
2261   if test -s conftest.err; then
2262     grep -v '^ *+' conftest.err >conftest.er1
2263     cat conftest.er1 >&5
2264     mv -f conftest.er1 conftest.err
2265   fi
2266   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2267   test $ac_status = 0; } > conftest.i && {
2268          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2269          test ! -s conftest.err
2270        }; then :
2271   ac_retval=0
2272 else
2273   $as_echo "$as_me: failed program was:" >&5
2274 sed 's/^/| /' conftest.$ac_ext >&5
2275 
2276     ac_retval=1
2277 fi
2278   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2279   as_fn_set_status $ac_retval
2280 
2281 } # ac_fn_c_try_cpp
2282 
2283 # ac_fn_cxx_try_cpp LINENO
2284 # ------------------------
2285 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2286 ac_fn_cxx_try_cpp ()
2287 {
2288   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2289   if { { ac_try="$ac_cpp conftest.$ac_ext"
2290 case "(($ac_try" in
2291   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2292   *) ac_try_echo=$ac_try;;
2293 esac
2294 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2295 $as_echo "$ac_try_echo"; } >&5
2296   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2297   ac_status=$?
2298   if test -s conftest.err; then
2299     grep -v '^ *+' conftest.err >conftest.er1
2300     cat conftest.er1 >&5
2301     mv -f conftest.er1 conftest.err
2302   fi
2303   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2304   test $ac_status = 0; } > conftest.i && {
2305          test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
2306          test ! -s conftest.err
2307        }; then :
2308   ac_retval=0
2309 else
2310   $as_echo "$as_me: failed program was:" >&5
2311 sed 's/^/| /' conftest.$ac_ext >&5
2312 
2313     ac_retval=1
2314 fi
2315   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2316   as_fn_set_status $ac_retval
2317 
2318 } # ac_fn_cxx_try_cpp
2319 
2320 # ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES
2321 # ---------------------------------------------------------
2322 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2323 # the include files in INCLUDES and setting the cache variable VAR
2324 # accordingly.
2325 ac_fn_cxx_check_header_mongrel ()
2326 {
2327   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2328   if eval \${$3+:} false; then :
2329   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2330 $as_echo_n "checking for $2... " >&6; }
2331 if eval \${$3+:} false; then :
2332   $as_echo_n "(cached) " >&6
2333 fi
2334 eval ac_res=\$$3
2335                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2336 $as_echo "$ac_res" >&6; }
2337 else
2338   # Is the header compilable?
2339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2340 $as_echo_n "checking $2 usability... " >&6; }
2341 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2342 /* end confdefs.h.  */
2343 $4
2344 #include <$2>
2345 _ACEOF
2346 if ac_fn_cxx_try_compile "$LINENO"; then :
2347   ac_header_compiler=yes
2348 else
2349   ac_header_compiler=no
2350 fi
2351 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2353 $as_echo "$ac_header_compiler" >&6; }
2354 
2355 # Is the header present?
2356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2357 $as_echo_n "checking $2 presence... " >&6; }
2358 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2359 /* end confdefs.h.  */
2360 #include <$2>
2361 _ACEOF
2362 if ac_fn_cxx_try_cpp "$LINENO"; then :
2363   ac_header_preproc=yes
2364 else
2365   ac_header_preproc=no
2366 fi
2367 rm -f conftest.err conftest.i conftest.$ac_ext
2368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2369 $as_echo "$ac_header_preproc" >&6; }
2370 
2371 # So?  What about this header?
2372 case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #((
2373   yes:no: )
2374     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2375 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2376     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2377 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2378     ;;
2379   no:yes:* )
2380     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2381 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2382     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
2383 $as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
2384     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2385 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2386     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
2387 $as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
2388     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2389 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2390 ( $as_echo "## ----------------------------------------- ##
2391 ## Report this to build-dev@openjdk.java.net ##
2392 ## ----------------------------------------- ##"
2393      ) | sed "s/^/$as_me: WARNING:     /" >&2
2394     ;;
2395 esac
2396   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2397 $as_echo_n "checking for $2... " >&6; }
2398 if eval \${$3+:} false; then :
2399   $as_echo_n "(cached) " >&6
2400 else
2401   eval "$3=\$ac_header_compiler"
2402 fi
2403 eval ac_res=\$$3
2404                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2405 $as_echo "$ac_res" >&6; }
2406 fi
2407   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2408 
2409 } # ac_fn_cxx_check_header_mongrel
2410 
2411 # ac_fn_cxx_try_run LINENO
2412 # ------------------------
2413 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2414 # that executables *can* be run.
2415 ac_fn_cxx_try_run ()
2416 {
2417   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2418   if { { ac_try="$ac_link"
2419 case "(($ac_try" in
2420   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2421   *) ac_try_echo=$ac_try;;
2422 esac
2423 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2424 $as_echo "$ac_try_echo"; } >&5
2425   (eval "$ac_link") 2>&5
2426   ac_status=$?
2427   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2428   test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2429   { { case "(($ac_try" in
2430   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2431   *) ac_try_echo=$ac_try;;
2432 esac
2433 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2434 $as_echo "$ac_try_echo"; } >&5
2435   (eval "$ac_try") 2>&5
2436   ac_status=$?
2437   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2438   test $ac_status = 0; }; }; then :
2439   ac_retval=0
2440 else
2441   $as_echo "$as_me: program exited with status $ac_status" >&5
2442        $as_echo "$as_me: failed program was:" >&5
2443 sed 's/^/| /' conftest.$ac_ext >&5
2444 
2445        ac_retval=$ac_status
2446 fi
2447   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2448   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2449   as_fn_set_status $ac_retval
2450 
2451 } # ac_fn_cxx_try_run
2452 
2453 # ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES
2454 # ---------------------------------------------------------
2455 # Tests whether HEADER exists and can be compiled using the include files in
2456 # INCLUDES, setting the cache variable VAR accordingly.
2457 ac_fn_cxx_check_header_compile ()
2458 {
2459   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2460   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2461 $as_echo_n "checking for $2... " >&6; }
2462 if eval \${$3+:} false; then :
2463   $as_echo_n "(cached) " >&6
2464 else
2465   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2466 /* end confdefs.h.  */
2467 $4
2468 #include <$2>
2469 _ACEOF
2470 if ac_fn_cxx_try_compile "$LINENO"; then :
2471   eval "$3=yes"
2472 else
2473   eval "$3=no"
2474 fi
2475 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2476 fi
2477 eval ac_res=\$$3
2478                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2479 $as_echo "$ac_res" >&6; }
2480   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2481 
2482 } # ac_fn_cxx_check_header_compile
2483 
2484 # ac_fn_cxx_compute_int LINENO EXPR VAR INCLUDES
2485 # ----------------------------------------------
2486 # Tries to find the compile-time value of EXPR in a program that includes
2487 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2488 # computed
2489 ac_fn_cxx_compute_int ()
2490 {
2491   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2492   if test "$cross_compiling" = yes; then
2493     # Depending upon the size, compute the lo and hi bounds.
2494 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2495 /* end confdefs.h.  */
2496 $4
2497 int
2498 main ()
2499 {
2500 static int test_array [1 - 2 * !(($2) >= 0)];
2501 test_array [0] = 0;
2502 return test_array [0];
2503 
2504   ;
2505   return 0;
2506 }
2507 _ACEOF
2508 if ac_fn_cxx_try_compile "$LINENO"; then :
2509   ac_lo=0 ac_mid=0
2510   while :; do
2511     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2512 /* end confdefs.h.  */
2513 $4
2514 int
2515 main ()
2516 {
2517 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2518 test_array [0] = 0;
2519 return test_array [0];
2520 
2521   ;
2522   return 0;
2523 }
2524 _ACEOF
2525 if ac_fn_cxx_try_compile "$LINENO"; then :
2526   ac_hi=$ac_mid; break
2527 else
2528   as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2529                         if test $ac_lo -le $ac_mid; then
2530                           ac_lo= ac_hi=
2531                           break
2532                         fi
2533                         as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2534 fi
2535 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2536   done
2537 else
2538   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2539 /* end confdefs.h.  */
2540 $4
2541 int
2542 main ()
2543 {
2544 static int test_array [1 - 2 * !(($2) < 0)];
2545 test_array [0] = 0;
2546 return test_array [0];
2547 
2548   ;
2549   return 0;
2550 }
2551 _ACEOF
2552 if ac_fn_cxx_try_compile "$LINENO"; then :
2553   ac_hi=-1 ac_mid=-1
2554   while :; do
2555     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2556 /* end confdefs.h.  */
2557 $4
2558 int
2559 main ()
2560 {
2561 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2562 test_array [0] = 0;
2563 return test_array [0];
2564 
2565   ;
2566   return 0;
2567 }
2568 _ACEOF
2569 if ac_fn_cxx_try_compile "$LINENO"; then :
2570   ac_lo=$ac_mid; break
2571 else
2572   as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2573                         if test $ac_mid -le $ac_hi; then
2574                           ac_lo= ac_hi=
2575                           break
2576                         fi
2577                         as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2578 fi
2579 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2580   done
2581 else
2582   ac_lo= ac_hi=
2583 fi
2584 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2585 fi
2586 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2587 # Binary search between lo and hi bounds.
2588 while test "x$ac_lo" != "x$ac_hi"; do
2589   as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2590   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2591 /* end confdefs.h.  */
2592 $4
2593 int
2594 main ()
2595 {
2596 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2597 test_array [0] = 0;
2598 return test_array [0];
2599 
2600   ;
2601   return 0;
2602 }
2603 _ACEOF
2604 if ac_fn_cxx_try_compile "$LINENO"; then :
2605   ac_hi=$ac_mid
2606 else
2607   as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2608 fi
2609 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2610 done
2611 case $ac_lo in #((
2612 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2613 '') ac_retval=1 ;;
2614 esac
2615   else
2616     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2617 /* end confdefs.h.  */
2618 $4
2619 static long int longval () { return $2; }
2620 static unsigned long int ulongval () { return $2; }
2621 #include <stdio.h>
2622 #include <stdlib.h>
2623 int
2624 main ()
2625 {
2626 
2627   FILE *f = fopen ("conftest.val", "w");
2628   if (! f)
2629     return 1;
2630   if (($2) < 0)
2631     {
2632       long int i = longval ();
2633       if (i != ($2))
2634         return 1;
2635       fprintf (f, "%ld", i);
2636     }
2637   else
2638     {
2639       unsigned long int i = ulongval ();
2640       if (i != ($2))
2641         return 1;
2642       fprintf (f, "%lu", i);
2643     }
2644   /* Do not output a trailing newline, as this causes \r\n confusion
2645      on some platforms.  */
2646   return ferror (f) || fclose (f) != 0;
2647 
2648   ;
2649   return 0;
2650 }
2651 _ACEOF
2652 if ac_fn_cxx_try_run "$LINENO"; then :
2653   echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2654 else
2655   ac_retval=1
2656 fi
2657 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2658   conftest.$ac_objext conftest.beam conftest.$ac_ext
2659 rm -f conftest.val
2660 
2661   fi
2662   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2663   as_fn_set_status $ac_retval
2664 
2665 } # ac_fn_cxx_compute_int
2666 
2667 # ac_fn_cxx_try_link LINENO
2668 # -------------------------
2669 # Try to link conftest.$ac_ext, and return whether this succeeded.
2670 ac_fn_cxx_try_link ()
2671 {
2672   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2673   rm -f conftest.$ac_objext conftest$ac_exeext
2674   if { { ac_try="$ac_link"
2675 case "(($ac_try" in
2676   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2677   *) ac_try_echo=$ac_try;;
2678 esac
2679 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2680 $as_echo "$ac_try_echo"; } >&5
2681   (eval "$ac_link") 2>conftest.err
2682   ac_status=$?
2683   if test -s conftest.err; then
2684     grep -v '^ *+' conftest.err >conftest.er1
2685     cat conftest.er1 >&5
2686     mv -f conftest.er1 conftest.err
2687   fi
2688   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2689   test $ac_status = 0; } && {
2690          test -z "$ac_cxx_werror_flag" ||
2691          test ! -s conftest.err
2692        } && test -s conftest$ac_exeext && {
2693          test "$cross_compiling" = yes ||
2694          test -x conftest$ac_exeext
2695        }; then :
2696   ac_retval=0
2697 else
2698   $as_echo "$as_me: failed program was:" >&5
2699 sed 's/^/| /' conftest.$ac_ext >&5
2700 
2701         ac_retval=1
2702 fi
2703   # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2704   # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2705   # interfere with the next link command; also delete a directory that is
2706   # left behind by Apple's compiler.  We do this before executing the actions.
2707   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2708   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2709   as_fn_set_status $ac_retval
2710 
2711 } # ac_fn_cxx_try_link
2712 
2713 # ac_fn_cxx_check_func LINENO FUNC VAR
2714 # ------------------------------------
2715 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2716 ac_fn_cxx_check_func ()
2717 {
2718   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2719   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2720 $as_echo_n "checking for $2... " >&6; }
2721 if eval \${$3+:} false; then :
2722   $as_echo_n "(cached) " >&6
2723 else
2724   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2725 /* end confdefs.h.  */
2726 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2727    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
2728 #define $2 innocuous_$2
2729 
2730 /* System header to define __stub macros and hopefully few prototypes,
2731     which can conflict with char $2 (); below.
2732     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2733     <limits.h> exists even on freestanding compilers.  */
2734 
2735 #ifdef __STDC__
2736 # include <limits.h>
2737 #else
2738 # include <assert.h>
2739 #endif
2740 
2741 #undef $2
2742 
2743 /* Override any GCC internal prototype to avoid an error.
2744    Use char because int might match the return type of a GCC
2745    builtin and then its argument prototype would still apply.  */
2746 #ifdef __cplusplus
2747 extern "C"
2748 #endif
2749 char $2 ();
2750 /* The GNU C library defines this for functions which it implements
2751     to always fail with ENOSYS.  Some functions are actually named
2752     something starting with __ and the normal name is an alias.  */
2753 #if defined __stub_$2 || defined __stub___$2
2754 choke me
2755 #endif
2756 
2757 int
2758 main ()
2759 {
2760 return $2 ();
2761   ;
2762   return 0;
2763 }
2764 _ACEOF
2765 if ac_fn_cxx_try_link "$LINENO"; then :
2766   eval "$3=yes"
2767 else
2768   eval "$3=no"
2769 fi
2770 rm -f core conftest.err conftest.$ac_objext \
2771     conftest$ac_exeext conftest.$ac_ext
2772 fi
2773 eval ac_res=\$$3
2774                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2775 $as_echo "$ac_res" >&6; }
2776   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2777 
2778 } # ac_fn_cxx_check_func
2779 
2780 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2781 # -------------------------------------------------------
2782 # Tests whether HEADER exists and can be compiled using the include files in
2783 # INCLUDES, setting the cache variable VAR accordingly.
2784 ac_fn_c_check_header_compile ()
2785 {
2786   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2787   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2788 $as_echo_n "checking for $2... " >&6; }
2789 if eval \${$3+:} false; then :
2790   $as_echo_n "(cached) " >&6
2791 else
2792   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2793 /* end confdefs.h.  */
2794 $4
2795 #include <$2>
2796 _ACEOF
2797 if ac_fn_c_try_compile "$LINENO"; then :
2798   eval "$3=yes"
2799 else
2800   eval "$3=no"
2801 fi
2802 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2803 fi
2804 eval ac_res=\$$3
2805                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2806 $as_echo "$ac_res" >&6; }
2807   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2808 
2809 } # ac_fn_c_check_header_compile
2810 cat >config.log <<_ACEOF
2811 This file contains any messages produced by compilers while
2812 running configure, to aid debugging if configure makes a mistake.
2813 
2814 It was created by OpenJDK $as_me jdk8, which was
2815 generated by GNU Autoconf 2.69.  Invocation command line was
2816 
2817   $ $0 $@
2818 
2819 _ACEOF
2820 exec 5>>config.log
2821 {
2822 cat <<_ASUNAME
2823 ## --------- ##
2824 ## Platform. ##
2825 ## --------- ##
2826 
2827 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2828 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2829 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2830 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2831 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2832 
2833 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2834 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2835 
2836 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2837 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2838 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2839 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2840 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2841 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2842 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2843 
2844 _ASUNAME
2845 
2846 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2847 for as_dir in $PATH
2848 do
2849   IFS=$as_save_IFS
2850   test -z "$as_dir" && as_dir=.
2851     $as_echo "PATH: $as_dir"
2852   done
2853 IFS=$as_save_IFS
2854 
2855 } >&5
2856 
2857 cat >&5 <<_ACEOF
2858 
2859 
2860 ## ----------- ##
2861 ## Core tests. ##
2862 ## ----------- ##
2863 
2864 _ACEOF
2865 
2866 
2867 # Keep a trace of the command line.
2868 # Strip out --no-create and --no-recursion so they do not pile up.
2869 # Strip out --silent because we don't want to record it for future runs.
2870 # Also quote any args containing shell meta-characters.
2871 # Make two passes to allow for proper duplicate-argument suppression.
2872 ac_configure_args=
2873 ac_configure_args0=
2874 ac_configure_args1=
2875 ac_must_keep_next=false
2876 for ac_pass in 1 2
2877 do
2878   for ac_arg
2879   do
2880     case $ac_arg in
2881     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2882     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2883     | -silent | --silent | --silen | --sile | --sil)
2884       continue ;;
2885     *\'*)
2886       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2887     esac
2888     case $ac_pass in
2889     1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2890     2)
2891       as_fn_append ac_configure_args1 " '$ac_arg'"
2892       if test $ac_must_keep_next = true; then
2893         ac_must_keep_next=false # Got value, back to normal.
2894       else
2895         case $ac_arg in
2896           *=* | --config-cache | -C | -disable-* | --disable-* \
2897           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2898           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2899           | -with-* | --with-* | -without-* | --without-* | --x)
2900             case "$ac_configure_args0 " in
2901               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2902             esac
2903             ;;
2904           -* ) ac_must_keep_next=true ;;
2905         esac
2906       fi
2907       as_fn_append ac_configure_args " '$ac_arg'"
2908       ;;
2909     esac
2910   done
2911 done
2912 { ac_configure_args0=; unset ac_configure_args0;}
2913 { ac_configure_args1=; unset ac_configure_args1;}
2914 
2915 # When interrupted or exit'd, cleanup temporary files, and complete
2916 # config.log.  We remove comments because anyway the quotes in there
2917 # would cause problems or look ugly.
2918 # WARNING: Use '\'' to represent an apostrophe within the trap.
2919 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2920 trap 'exit_status=$?
2921   # Save into config.log some information that might help in debugging.
2922   {
2923     echo
2924 
2925     $as_echo "## ---------------- ##
2926 ## Cache variables. ##
2927 ## ---------------- ##"
2928     echo
2929     # The following way of writing the cache mishandles newlines in values,
2930 (
2931   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2932     eval ac_val=\$$ac_var
2933     case $ac_val in #(
2934     *${as_nl}*)
2935       case $ac_var in #(
2936       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2937 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2938       esac
2939       case $ac_var in #(
2940       _ | IFS | as_nl) ;; #(
2941       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2942       *) { eval $ac_var=; unset $ac_var;} ;;
2943       esac ;;
2944     esac
2945   done
2946   (set) 2>&1 |
2947     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2948     *${as_nl}ac_space=\ *)
2949       sed -n \
2950         "s/'\''/'\''\\\\'\'''\''/g;
2951           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2952       ;; #(
2953     *)
2954       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2955       ;;
2956     esac |
2957     sort
2958 )
2959     echo
2960 
2961     $as_echo "## ----------------- ##
2962 ## Output variables. ##
2963 ## ----------------- ##"
2964     echo
2965     for ac_var in $ac_subst_vars
2966     do
2967       eval ac_val=\$$ac_var
2968       case $ac_val in
2969       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2970       esac
2971       $as_echo "$ac_var='\''$ac_val'\''"
2972     done | sort
2973     echo
2974 
2975     if test -n "$ac_subst_files"; then
2976       $as_echo "## ------------------- ##
2977 ## File substitutions. ##
2978 ## ------------------- ##"
2979       echo
2980       for ac_var in $ac_subst_files
2981       do
2982         eval ac_val=\$$ac_var
2983         case $ac_val in
2984         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2985         esac
2986         $as_echo "$ac_var='\''$ac_val'\''"
2987       done | sort
2988       echo
2989     fi
2990 
2991     if test -s confdefs.h; then
2992       $as_echo "## ----------- ##
2993 ## confdefs.h. ##
2994 ## ----------- ##"
2995       echo
2996       cat confdefs.h
2997       echo
2998     fi
2999     test "$ac_signal" != 0 &&
3000       $as_echo "$as_me: caught signal $ac_signal"
3001     $as_echo "$as_me: exit $exit_status"
3002   } >&5
3003   rm -f core *.core core.conftest.* &&
3004     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3005     exit $exit_status
3006 ' 0
3007 for ac_signal in 1 2 13 15; do
3008   trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3009 done
3010 ac_signal=0
3011 
3012 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3013 rm -f -r conftest* confdefs.h
3014 
3015 $as_echo "/* confdefs.h */" > confdefs.h
3016 
3017 # Predefined preprocessor variables.
3018 
3019 cat >>confdefs.h <<_ACEOF
3020 #define PACKAGE_NAME "$PACKAGE_NAME"
3021 _ACEOF
3022 
3023 cat >>confdefs.h <<_ACEOF
3024 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3025 _ACEOF
3026 
3027 cat >>confdefs.h <<_ACEOF
3028 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3029 _ACEOF
3030 
3031 cat >>confdefs.h <<_ACEOF
3032 #define PACKAGE_STRING "$PACKAGE_STRING"
3033 _ACEOF
3034 
3035 cat >>confdefs.h <<_ACEOF
3036 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3037 _ACEOF
3038 
3039 cat >>confdefs.h <<_ACEOF
3040 #define PACKAGE_URL "$PACKAGE_URL"
3041 _ACEOF
3042 
3043 
3044 # Let the site file select an alternate cache file if it wants to.
3045 # Prefer an explicitly selected file to automatically selected ones.
3046 ac_site_file1=NONE
3047 ac_site_file2=NONE
3048 if test -n "$CONFIG_SITE"; then
3049   # We do not want a PATH search for config.site.
3050   case $CONFIG_SITE in #((
3051     -*)  ac_site_file1=./$CONFIG_SITE;;
3052     */*) ac_site_file1=$CONFIG_SITE;;
3053     *)   ac_site_file1=./$CONFIG_SITE;;
3054   esac
3055 elif test "x$prefix" != xNONE; then
3056   ac_site_file1=$prefix/share/config.site
3057   ac_site_file2=$prefix/etc/config.site
3058 else
3059   ac_site_file1=$ac_default_prefix/share/config.site
3060   ac_site_file2=$ac_default_prefix/etc/config.site
3061 fi
3062 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3063 do
3064   test "x$ac_site_file" = xNONE && continue
3065   if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3066     { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3067 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3068     sed 's/^/| /' "$ac_site_file" >&5
3069     . "$ac_site_file" \
3070       || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3071 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3072 as_fn_error $? "failed to load site script $ac_site_file
3073 See \`config.log' for more details" "$LINENO" 5; }
3074   fi
3075 done
3076 
3077 if test -r "$cache_file"; then
3078   # Some versions of bash will fail to source /dev/null (special files
3079   # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
3080   if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3081     { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3082 $as_echo "$as_me: loading cache $cache_file" >&6;}
3083     case $cache_file in
3084       [\\/]* | ?:[\\/]* ) . "$cache_file";;
3085       *)                      . "./$cache_file";;
3086     esac
3087   fi
3088 else
3089   { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3090 $as_echo "$as_me: creating cache $cache_file" >&6;}
3091   >$cache_file
3092 fi
3093 
3094 # Check that the precious variables saved in the cache have kept the same
3095 # value.
3096 ac_cache_corrupted=false
3097 for ac_var in $ac_precious_vars; do
3098   eval ac_old_set=\$ac_cv_env_${ac_var}_set
3099   eval ac_new_set=\$ac_env_${ac_var}_set
3100   eval ac_old_val=\$ac_cv_env_${ac_var}_value
3101   eval ac_new_val=\$ac_env_${ac_var}_value
3102   case $ac_old_set,$ac_new_set in
3103     set,)
3104       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3105 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3106       ac_cache_corrupted=: ;;
3107     ,set)
3108       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3109 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3110       ac_cache_corrupted=: ;;
3111     ,);;
3112     *)
3113       if test "x$ac_old_val" != "x$ac_new_val"; then
3114         # differences in whitespace do not lead to failure.
3115         ac_old_val_w=`echo x $ac_old_val`
3116         ac_new_val_w=`echo x $ac_new_val`
3117         if test "$ac_old_val_w" != "$ac_new_val_w"; then
3118           { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3119 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3120           ac_cache_corrupted=:
3121         else
3122           { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3123 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3124           eval $ac_var=\$ac_old_val
3125         fi
3126         { $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
3127 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
3128         { $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
3129 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
3130       fi;;
3131   esac
3132   # Pass precious variables to config.status.
3133   if test "$ac_new_set" = set; then
3134     case $ac_new_val in
3135     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3136     *) ac_arg=$ac_var=$ac_new_val ;;
3137     esac
3138     case " $ac_configure_args " in
3139       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
3140       *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3141     esac
3142   fi
3143 done
3144 if $ac_cache_corrupted; then
3145   { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3146 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3147   { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3148 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3149   as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3150 fi
3151 ## -------------------- ##
3152 ## Main body of script. ##
3153 ## -------------------- ##
3154 
3155 ac_ext=c
3156 ac_cpp='$CPP $CPPFLAGS'
3157 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3158 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3159 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3160 
3161 
3162 
3163 ac_aux_dir=
3164 for ac_dir in common/autoconf/build-aux "$srcdir"/common/autoconf/build-aux; do
3165   if test -f "$ac_dir/install-sh"; then
3166     ac_aux_dir=$ac_dir
3167     ac_install_sh="$ac_aux_dir/install-sh -c"
3168     break
3169   elif test -f "$ac_dir/install.sh"; then
3170     ac_aux_dir=$ac_dir
3171     ac_install_sh="$ac_aux_dir/install.sh -c"
3172     break
3173   elif test -f "$ac_dir/shtool"; then
3174     ac_aux_dir=$ac_dir
3175     ac_install_sh="$ac_aux_dir/shtool install -c"
3176     break
3177   fi
3178 done
3179 if test -z "$ac_aux_dir"; then
3180   as_fn_error $? "cannot find install-sh, install.sh, or shtool in common/autoconf/build-aux \"$srcdir\"/common/autoconf/build-aux" "$LINENO" 5
3181 fi
3182 
3183 # These three variables are undocumented and unsupported,
3184 # and are intended to be withdrawn in a future Autoconf release.
3185 # They can cause serious problems if a builder's source tree is in a directory
3186 # whose full name contains unusual characters.
3187 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
3188 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
3189 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
3190 
3191 
3192 # pkg.m4 - Macros to locate and utilise pkg-config.            -*- Autoconf -*-
3193 
3194 #
3195 # Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
3196 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3197 #
3198 # This code is free software; you can redistribute it and/or modify it
3199 # under the terms of the GNU General Public License version 2 only, as
3200 # published by the Free Software Foundation.  Oracle designates this
3201 # particular file as subject to the "Classpath" exception as provided
3202 # by Oracle in the LICENSE file that accompanied this code.
3203 #
3204 # This code is distributed in the hope that it will be useful, but WITHOUT
3205 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3206 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3207 # version 2 for more details (a copy is included in the LICENSE file that
3208 # accompanied this code).
3209 #
3210 # You should have received a copy of the GNU General Public License version
3211 # 2 along with this work; if not, write to the Free Software Foundation,
3212 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3213 #
3214 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3215 # or visit www.oracle.com if you need additional information or have any
3216 # questions.
3217 #
3218 
3219 #
3220 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>.
3221 #
3222 # This program is free software; you can redistribute it and/or modify
3223 # it under the terms of the GNU General Public License as published by
3224 # the Free Software Foundation; either version 2 of the License, or
3225 # (at your option) any later version.
3226 #
3227 # This program is distributed in the hope that it will be useful, but
3228 # WITHOUT ANY WARRANTY; without even the implied warranty of
3229 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
3230 # General Public License for more details.
3231 #
3232 # You should have received a copy of the GNU General Public License
3233 # along with this program; if not, write to the Free Software
3234 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
3235 #
3236 # As a special exception to the GNU General Public License, if you
3237 # distribute this file as part of a program that contains a
3238 # configuration script generated by Autoconf, you may include it under
3239 # the same distribution terms that you use for the rest of that program.
3240 
3241 # PKG_PROG_PKG_CONFIG([MIN-VERSION])
3242 # ----------------------------------
3243 # PKG_PROG_PKG_CONFIG
3244 
3245 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
3246 #
3247 # Check to see whether a particular set of modules exists.  Similar
3248 # to PKG_CHECK_MODULES(), but does not set variables or print errors.
3249 #
3250 #
3251 # Similar to PKG_CHECK_MODULES, make sure that the first instance of
3252 # this or PKG_CHECK_MODULES is called, or make sure to call
3253 # PKG_CHECK_EXISTS manually
3254 # --------------------------------------------------------------
3255 
3256 
3257 
3258 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
3259 # ---------------------------------------------
3260 # _PKG_CONFIG
3261 
3262 # _PKG_SHORT_ERRORS_SUPPORTED
3263 # -----------------------------
3264 # _PKG_SHORT_ERRORS_SUPPORTED
3265 
3266 
3267 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
3268 # [ACTION-IF-NOT-FOUND])
3269 #
3270 #
3271 # Note that if there is a possibility the first call to
3272 # PKG_CHECK_MODULES might not happen, you should be sure to include an
3273 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
3274 #
3275 #
3276 # --------------------------------------------------------------
3277 # PKG_CHECK_MODULES
3278 
3279 
3280 # Include these first...
3281 #
3282 # Copyright (c) 2011, 2013, Oracle and/or its affiliates. All rights reserved.
3283 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3284 #
3285 # This code is free software; you can redistribute it and/or modify it
3286 # under the terms of the GNU General Public License version 2 only, as
3287 # published by the Free Software Foundation.  Oracle designates this
3288 # particular file as subject to the "Classpath" exception as provided
3289 # by Oracle in the LICENSE file that accompanied this code.
3290 #
3291 # This code is distributed in the hope that it will be useful, but WITHOUT
3292 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3293 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3294 # version 2 for more details (a copy is included in the LICENSE file that
3295 # accompanied this code).
3296 #
3297 # You should have received a copy of the GNU General Public License version
3298 # 2 along with this work; if not, write to the Free Software Foundation,
3299 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3300 #
3301 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3302 # or visit www.oracle.com if you need additional information or have any
3303 # questions.
3304 #
3305 
3306 # Test if $1 is a valid argument to $3 (often is $JAVA passed as $3)
3307 # If so, then append $1 to $2 \
3308 # Also set JVM_ARG_OK to true/false depending on outcome.
3309 
3310 
3311 # Appends a string to a path variable, only adding the : when needed.
3312 
3313 
3314 # This will make sure the given variable points to a full and proper
3315 # path. This means:
3316 # 1) There will be no spaces in the path. On posix platforms,
3317 #    spaces in the path will result in an error. On Windows,
3318 #    the path will be rewritten using short-style to be space-free.
3319 # 2) The path will be absolute, and it will be in unix-style (on
3320 #     cygwin).
3321 # $1: The name of the variable to fix
3322 
3323 
3324 # This will make sure the given variable points to a executable
3325 # with a full and proper path. This means:
3326 # 1) There will be no spaces in the path. On posix platforms,
3327 #    spaces in the path will result in an error. On Windows,
3328 #    the path will be rewritten using short-style to be space-free.
3329 # 2) The path will be absolute, and it will be in unix-style (on
3330 #     cygwin).
3331 # Any arguments given to the executable is preserved.
3332 # If the input variable does not have a directory specification, then
3333 # it need to be in the PATH.
3334 # $1: The name of the variable to fix
3335 
3336 
3337 
3338 
3339 # Register a --with argument but mark it as deprecated
3340 # $1: The name of the with argument to deprecate, not including --with-
3341 
3342 
3343 # Register a --enable argument but mark it as deprecated
3344 # $1: The name of the with argument to deprecate, not including --enable-
3345 # $2: The name of the argument to deprecate, in shell variable style (i.e. with _ instead of -)
3346 
3347 
3348 
3349 
3350 # Test that variable $1 denoting a program is not empty. If empty, exit with an error.
3351 # $1: variable to check
3352 
3353 
3354 # Check that there are no unprocessed overridden variables left.
3355 # If so, they are an incorrect argument and we will exit with an error.
3356 
3357 
3358 # Setup a tool for the given variable. If correctly specified by the user,
3359 # use that value, otherwise search for the tool using the supplied code snippet.
3360 # $1: variable to set
3361 # $2: code snippet to call to look for the tool
3362 
3363 
3364 # Call BASIC_SETUP_TOOL with AC_PATH_PROGS to locate the tool
3365 # $1: variable to set
3366 # $2: executable name (or list of names) to look for
3367 
3368 
3369 # Call BASIC_SETUP_TOOL with AC_CHECK_TOOLS to locate the tool
3370 # $1: variable to set
3371 # $2: executable name (or list of names) to look for
3372 
3373 
3374 # Like BASIC_PATH_PROGS but fails if no tool was found.
3375 # $1: variable to set
3376 # $2: executable name (or list of names) to look for
3377 
3378 
3379 # Like BASIC_SETUP_TOOL but fails if no tool was found.
3380 # $1: variable to set
3381 # $2: autoconf macro to call to look for the special tool
3382 
3383 
3384 # Setup the most fundamental tools that relies on not much else to set up,
3385 # but is used by much of the early bootstrap code.
3386 
3387 
3388 # Setup basic configuration paths, and platform-specific stuff related to PATHs.
3389 
3390 
3391 
3392 
3393 
3394 
3395 
3396 #%%% Simple tools %%%
3397 
3398 # Check if we have found a usable version of make
3399 # $1: the path to a potential make binary (or empty)
3400 # $2: the description on how we found this
3401 
3402 
3403 # Goes looking for a usable version of GNU make.
3404 
3405 
3406 
3407 
3408 
3409 
3410 # Check if build directory is on local disk. If not possible to determine,
3411 # we prefer to claim it's local.
3412 # Argument 1: directory to test
3413 # Argument 2: what to do if it is on local disk
3414 # Argument 3: what to do otherwise (remote disk or failure)
3415 
3416 
3417 # Check that source files have basic read permissions set. This might
3418 # not be the case in cygwin in certain conditions.
3419 
3420 
3421 
3422 
3423 #
3424 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3425 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3426 #
3427 # This code is free software; you can redistribute it and/or modify it
3428 # under the terms of the GNU General Public License version 2 only, as
3429 # published by the Free Software Foundation.  Oracle designates this
3430 # particular file as subject to the "Classpath" exception as provided
3431 # by Oracle in the LICENSE file that accompanied this code.
3432 #
3433 # This code is distributed in the hope that it will be useful, but WITHOUT
3434 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3435 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3436 # version 2 for more details (a copy is included in the LICENSE file that
3437 # accompanied this code).
3438 #
3439 # You should have received a copy of the GNU General Public License version
3440 # 2 along with this work; if not, write to the Free Software Foundation,
3441 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3442 #
3443 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3444 # or visit www.oracle.com if you need additional information or have any
3445 # questions.
3446 #
3447 
3448 
3449 
3450 
3451 
3452 # Helper function which possibly converts a path using DOS-style short mode.
3453 # If so, the updated path is stored in $new_path.
3454 # $1: The path to check
3455 
3456 
3457 # Helper function which possibly converts a path using DOS-style short mode.
3458 # If so, the updated path is stored in $new_path.
3459 # $1: The path to check
3460 
3461 
3462 # FIXME: The BASIC_FIXUP_*_CYGWIN/MSYS is most likely too convoluted
3463 # and could probably be heavily simplified. However, all changes in this
3464 # area tend to need lot of testing in different scenarios, and in lack of
3465 # proper unit testing, cleaning this up has not been deemed worth the effort
3466 # at the moment.
3467 
3468 
3469 
3470 
3471 
3472 
3473 
3474 
3475 
3476 # Setup basic configuration paths, and platform-specific stuff related to PATHs.
3477 
3478 
3479 
3480 
3481 #
3482 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3483 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3484 #
3485 # This code is free software; you can redistribute it and/or modify it
3486 # under the terms of the GNU General Public License version 2 only, as
3487 # published by the Free Software Foundation.  Oracle designates this
3488 # particular file as subject to the "Classpath" exception as provided
3489 # by Oracle in the LICENSE file that accompanied this code.
3490 #
3491 # This code is distributed in the hope that it will be useful, but WITHOUT
3492 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3493 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3494 # version 2 for more details (a copy is included in the LICENSE file that
3495 # accompanied this code).
3496 #
3497 # You should have received a copy of the GNU General Public License version
3498 # 2 along with this work; if not, write to the Free Software Foundation,
3499 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3500 #
3501 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3502 # or visit www.oracle.com if you need additional information or have any
3503 # questions.
3504 #
3505 
3506 
3507 
3508 
3509 
3510 
3511 
3512 
3513 
3514 
3515 
3516 # ... then the rest
3517 #
3518 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3519 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3520 #
3521 # This code is free software; you can redistribute it and/or modify it
3522 # under the terms of the GNU General Public License version 2 only, as
3523 # published by the Free Software Foundation.  Oracle designates this
3524 # particular file as subject to the "Classpath" exception as provided
3525 # by Oracle in the LICENSE file that accompanied this code.
3526 #
3527 # This code is distributed in the hope that it will be useful, but WITHOUT
3528 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3529 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3530 # version 2 for more details (a copy is included in the LICENSE file that
3531 # accompanied this code).
3532 #
3533 # You should have received a copy of the GNU General Public License version
3534 # 2 along with this work; if not, write to the Free Software Foundation,
3535 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3536 #
3537 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3538 # or visit www.oracle.com if you need additional information or have any
3539 # questions.
3540 #
3541 
3542 ########################################################################
3543 # This file handles detection of the Boot JDK. The Boot JDK detection
3544 # process has been developed as a response to solve a complex real-world
3545 # problem. Initially, it was simple, but it has grown as platform after
3546 # platform, idiosyncracy after idiosyncracy has been supported.
3547 #
3548 # The basic idea is this:
3549 # 1) You need an acceptable *) JDK to use as a Boot JDK
3550 # 2) There are several ways to locate a JDK, that are mostly platform
3551 #    dependent **)
3552 # 3) You can have multiple JDKs installed
3553 # 4) If possible, configure should try to dig out an acceptable JDK
3554 #    automatically, without having to resort to command-line options
3555 #
3556 # *)  acceptable means e.g. JDK7 for building JDK8, a complete JDK (with
3557 #     javac) and not a JRE, etc.
3558 #
3559 # **) On Windows we typically use a well-known path.
3560 #     On MacOSX we typically use the tool java_home.
3561 #     On Linux we typically find javac in the $PATH, and then follow a
3562 #     chain of symlinks that often ends up in a real JDK.
3563 #
3564 # This leads to the code where we check in different ways to locate a
3565 # JDK, and if one is found, check if it is acceptable. If not, we print
3566 # our reasons for rejecting it (useful when debugging non-working
3567 # configure situations) and continue checking the next one.
3568 ########################################################################
3569 
3570 # Execute the check given as argument, and verify the result
3571 # If the Boot JDK was previously found, do nothing
3572 # $1 A command line (typically autoconf macro) to execute
3573 
3574 
3575 # Test: Is bootjdk explicitely set by command line arguments?
3576 
3577 
3578 # Test: Is bootjdk available from builddeps?
3579 
3580 
3581 # Test: Is $JAVA_HOME set?
3582 
3583 
3584 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK?
3585 
3586 
3587 # Test: Is there a /usr/libexec/java_home? (Typically on MacOSX)
3588 # $1: Argument to the java_home binary (optional)
3589 
3590 
3591 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home?
3592 
3593 
3594 # Look for a jdk in the given path. If there are multiple, try to select the newest.
3595 # If found, set BOOT_JDK and BOOT_JDK_FOUND.
3596 # $1 = Path to directory containing jdk installations.
3597 # $2 = String to append to the found JDK directory to get the proper JDK home
3598 
3599 
3600 # Call BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY, but use the given
3601 # environmental variable as base for where to look.
3602 # $1 Name of an environmal variable, assumed to point to the Program Files directory.
3603 
3604 
3605 # Test: Is there a JDK installed in default, well-known locations?
3606 
3607 
3608 # Check that a command-line tool in the Boot JDK is correct
3609 # $1 = name of variable to assign
3610 # $2 = name of binary
3611 
3612 
3613 ###############################################################################
3614 #
3615 # We need a Boot JDK to bootstrap the build.
3616 #
3617 
3618 
3619 
3620 
3621 
3622 #
3623 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3624 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3625 #
3626 # This code is free software; you can redistribute it and/or modify it
3627 # under the terms of the GNU General Public License version 2 only, as
3628 # published by the Free Software Foundation.  Oracle designates this
3629 # particular file as subject to the "Classpath" exception as provided
3630 # by Oracle in the LICENSE file that accompanied this code.
3631 #
3632 # This code is distributed in the hope that it will be useful, but WITHOUT
3633 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3634 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3635 # version 2 for more details (a copy is included in the LICENSE file that
3636 # accompanied this code).
3637 #
3638 # You should have received a copy of the GNU General Public License version
3639 # 2 along with this work; if not, write to the Free Software Foundation,
3640 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3641 #
3642 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3643 # or visit www.oracle.com if you need additional information or have any
3644 # questions.
3645 #
3646 
3647 
3648 
3649 
3650 
3651 
3652 
3653 
3654 
3655 
3656 
3657 
3658 
3659 
3660 
3661 
3662 
3663 
3664 
3665 
3666 #
3667 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3668 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3669 #
3670 # This code is free software; you can redistribute it and/or modify it
3671 # under the terms of the GNU General Public License version 2 only, as
3672 # published by the Free Software Foundation.  Oracle designates this
3673 # particular file as subject to the "Classpath" exception as provided
3674 # by Oracle in the LICENSE file that accompanied this code.
3675 #
3676 # This code is distributed in the hope that it will be useful, but WITHOUT
3677 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3678 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3679 # version 2 for more details (a copy is included in the LICENSE file that
3680 # accompanied this code).
3681 #
3682 # You should have received a copy of the GNU General Public License version
3683 # 2 along with this work; if not, write to the Free Software Foundation,
3684 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3685 #
3686 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3687 # or visit www.oracle.com if you need additional information or have any
3688 # questions.
3689 #
3690 
3691 
3692 
3693 
3694 
3695 cygwin_help() {
3696   case $1 in
3697     unzip)
3698       PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P unzip )"
3699       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
3700       ;;
3701     zip)
3702       PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P zip )"
3703       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
3704       ;;
3705     make)
3706       PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P make )"
3707       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
3708       ;;
3709     freetype)
3710       if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
3711         HELP_MSG="To install freetype, run:
3712 wget \"http://gnuwin32.sourceforge.net/downlinks/freetype.php\" -O /tmp/freetype-setup.exe
3713 chmod +x /tmp/freetype-setup.exe
3714 /tmp/freetype-setup.exe
3715 Follow GUI prompts, and install to default directory \"C:\Program Files (x86)\GnuWin32\".
3716 After installation, locate lib/libfreetype.dll.a and make a copy with the name freetype.dll."
3717       else
3718         HELP_MSG="You need to build a 64-bit version of freetype.
3719 This is not readily available.
3720 You can find source code and build instructions on
3721 http://www.freetype.org/
3722 If you put the resulting build in \"C:\Program Files\GnuWin32\", it will be found automatically."
3723       fi
3724       ;;
3725   esac
3726 }
3727 
3728 msys_help() {
3729   PKGHANDLER_COMMAND=""
3730 }
3731 
3732 apt_help() {
3733   case $1 in
3734     devkit)
3735       PKGHANDLER_COMMAND="sudo apt-get install build-essential" ;;
3736     openjdk)
3737       PKGHANDLER_COMMAND="sudo apt-get install openjdk-7-jdk" ;;
3738     alsa)
3739       PKGHANDLER_COMMAND="sudo apt-get install libasound2-dev" ;;
3740     cups)
3741       PKGHANDLER_COMMAND="sudo apt-get install libcups2-dev" ;;
3742     freetype)
3743       PKGHANDLER_COMMAND="sudo apt-get install libfreetype6-dev" ;;
3744     pulse)
3745       PKGHANDLER_COMMAND="sudo apt-get install libpulse-dev" ;;
3746     x11)
3747       PKGHANDLER_COMMAND="sudo apt-get install libX11-dev libxext-dev libxrender-dev libxtst-dev libxt-dev" ;;
3748     ccache)
3749       PKGHANDLER_COMMAND="sudo apt-get install ccache" ;;
3750   esac
3751 }
3752 
3753 yum_help() {
3754   case $1 in
3755     devkit)
3756       PKGHANDLER_COMMAND="sudo yum groupinstall \"Development Tools\"" ;;
3757     openjdk)
3758       PKGHANDLER_COMMAND="sudo yum install java-1.7.0-openjdk" ;;
3759     alsa)
3760       PKGHANDLER_COMMAND="sudo yum install alsa-lib-devel" ;;
3761     cups)
3762       PKGHANDLER_COMMAND="sudo yum install cups-devel" ;;
3763     freetype)
3764       PKGHANDLER_COMMAND="sudo yum install freetype-devel" ;;
3765     pulse)
3766       PKGHANDLER_COMMAND="sudo yum install pulseaudio-libs-devel" ;;
3767     x11)
3768       PKGHANDLER_COMMAND="sudo yum install libXtst-devel libXt-devel libXrender-devel" ;;
3769     ccache)
3770       PKGHANDLER_COMMAND="sudo yum install ccache" ;;
3771   esac
3772 }
3773 
3774 port_help() {
3775   PKGHANDLER_COMMAND=""
3776 }
3777 
3778 pkgutil_help() {
3779   PKGHANDLER_COMMAND=""
3780 }
3781 
3782 pkgadd_help() {
3783   PKGHANDLER_COMMAND=""
3784 }
3785 
3786 
3787 
3788 #
3789 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3790 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3791 #
3792 # This code is free software; you can redistribute it and/or modify it
3793 # under the terms of the GNU General Public License version 2 only, as
3794 # published by the Free Software Foundation.  Oracle designates this
3795 # particular file as subject to the "Classpath" exception as provided
3796 # by Oracle in the LICENSE file that accompanied this code.
3797 #
3798 # This code is distributed in the hope that it will be useful, but WITHOUT
3799 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3800 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3801 # version 2 for more details (a copy is included in the LICENSE file that
3802 # accompanied this code).
3803 #
3804 # You should have received a copy of the GNU General Public License version
3805 # 2 along with this work; if not, write to the Free Software Foundation,
3806 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3807 #
3808 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3809 # or visit www.oracle.com if you need additional information or have any
3810 # questions.
3811 #
3812 
3813 
3814 
3815 
3816 
3817 
3818 
3819 
3820 
3821 
3822 ###############################################################################
3823 #
3824 # Should we build only OpenJDK even if closed sources are present?
3825 #
3826 
3827 
3828 
3829 
3830 ###############################################################################
3831 #
3832 # Setup version numbers
3833 #
3834 
3835 
3836 
3837 
3838 
3839 
3840 #
3841 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3842 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3843 #
3844 # This code is free software; you can redistribute it and/or modify it
3845 # under the terms of the GNU General Public License version 2 only, as
3846 # published by the Free Software Foundation.  Oracle designates this
3847 # particular file as subject to the "Classpath" exception as provided
3848 # by Oracle in the LICENSE file that accompanied this code.
3849 #
3850 # This code is distributed in the hope that it will be useful, but WITHOUT
3851 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3852 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3853 # version 2 for more details (a copy is included in the LICENSE file that
3854 # accompanied this code).
3855 #
3856 # You should have received a copy of the GNU General Public License version
3857 # 2 along with this work; if not, write to the Free Software Foundation,
3858 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3859 #
3860 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3861 # or visit www.oracle.com if you need additional information or have any
3862 # questions.
3863 #
3864 
3865 
3866 
3867 
3868 
3869 
3870 
3871 
3872 
3873 
3874 
3875 
3876 
3877 
3878 
3879 
3880 
3881 #
3882 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3883 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3884 #
3885 # This code is free software; you can redistribute it and/or modify it
3886 # under the terms of the GNU General Public License version 2 only, as
3887 # published by the Free Software Foundation.  Oracle designates this
3888 # particular file as subject to the "Classpath" exception as provided
3889 # by Oracle in the LICENSE file that accompanied this code.
3890 #
3891 # This code is distributed in the hope that it will be useful, but WITHOUT
3892 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3893 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3894 # version 2 for more details (a copy is included in the LICENSE file that
3895 # accompanied this code).
3896 #
3897 # You should have received a copy of the GNU General Public License version
3898 # 2 along with this work; if not, write to the Free Software Foundation,
3899 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3900 #
3901 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3902 # or visit www.oracle.com if you need additional information or have any
3903 # questions.
3904 #
3905 
3906 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD.
3907 # Converts autoconf style CPU name to OpenJDK style, into
3908 # VAR_CPU, VAR_CPU_ARCH, VAR_CPU_BITS and VAR_CPU_ENDIAN.
3909 
3910 
3911 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD.
3912 # Converts autoconf style OS name to OpenJDK style, into
3913 # VAR_OS and VAR_OS_API.
3914 
3915 
3916 # Expects $host_os $host_cpu $build_os and $build_cpu
3917 # and $with_target_bits to have been setup!
3918 #
3919 # Translate the standard triplet(quadruplet) definition
3920 # of the target/build system into OPENJDK_TARGET_OS, OPENJDK_TARGET_CPU,
3921 # OPENJDK_BUILD_OS, etc.
3922 
3923 
3924 # Check if a reduced build (32-bit on 64-bit platforms) is requested, and modify behaviour
3925 # accordingly. Must be done after setting up build and target system, but before
3926 # doing anything else with these values.
3927 
3928 
3929 # Setup the legacy variables, for controlling the old makefiles.
3930 #
3931 
3932 
3933 
3934 
3935 #%%% Build and target systems %%%
3936 
3937 
3938 
3939 
3940 # Support macro for PLATFORM_SETUP_OPENJDK_TARGET_BITS.
3941 # Add -mX to various FLAGS variables.
3942 
3943 
3944 
3945 
3946 
3947 
3948 #
3949 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3950 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3951 #
3952 # This code is free software; you can redistribute it and/or modify it
3953 # under the terms of the GNU General Public License version 2 only, as
3954 # published by the Free Software Foundation.  Oracle designates this
3955 # particular file as subject to the "Classpath" exception as provided
3956 # by Oracle in the LICENSE file that accompanied this code.
3957 #
3958 # This code is distributed in the hope that it will be useful, but WITHOUT
3959 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3960 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3961 # version 2 for more details (a copy is included in the LICENSE file that
3962 # accompanied this code).
3963 #
3964 # You should have received a copy of the GNU General Public License version
3965 # 2 along with this work; if not, write to the Free Software Foundation,
3966 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3967 #
3968 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3969 # or visit www.oracle.com if you need additional information or have any
3970 # questions.
3971 #
3972 
3973 
3974 
3975 
3976 
3977 
3978 
3979 
3980 #
3981 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3982 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3983 #
3984 # This code is free software; you can redistribute it and/or modify it
3985 # under the terms of the GNU General Public License version 2 only, as
3986 # published by the Free Software Foundation.  Oracle designates this
3987 # particular file as subject to the "Classpath" exception as provided
3988 # by Oracle in the LICENSE file that accompanied this code.
3989 #
3990 # This code is distributed in the hope that it will be useful, but WITHOUT
3991 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3992 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3993 # version 2 for more details (a copy is included in the LICENSE file that
3994 # accompanied this code).
3995 #
3996 # You should have received a copy of the GNU General Public License version
3997 # 2 along with this work; if not, write to the Free Software Foundation,
3998 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3999 #
4000 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4001 # or visit www.oracle.com if you need additional information or have any
4002 # questions.
4003 #
4004 
4005 # $1 = compiler to test (CC or CXX)
4006 # $2 = human readable name of compiler (C or C++)
4007 
4008 
4009 
4010 
4011 
4012 # $1 = compiler to test (CC or CXX)
4013 # $2 = human readable name of compiler (C or C++)
4014 # $3 = list of compiler names to search for
4015 
4016 
4017 
4018 
4019 
4020 
4021 
4022 
4023 
4024 
4025 
4026 
4027 
4028 # TOOLCHAIN_COMPILER_CHECK_ARGUMENTS([ARGUMENT], [RUN-IF-TRUE],
4029 #                                   [RUN-IF-FALSE])
4030 # ------------------------------------------------------------
4031 # Check that the c and c++ compilers support an argument
4032 
4033 
4034 
4035 
4036 # Setup the JTREG paths
4037 
4038 
4039 #
4040 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
4041 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4042 #
4043 # This code is free software; you can redistribute it and/or modify it
4044 # under the terms of the GNU General Public License version 2 only, as
4045 # published by the Free Software Foundation.  Oracle designates this
4046 # particular file as subject to the "Classpath" exception as provided
4047 # by Oracle in the LICENSE file that accompanied this code.
4048 #
4049 # This code is distributed in the hope that it will be useful, but WITHOUT
4050 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4051 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4052 # version 2 for more details (a copy is included in the LICENSE file that
4053 # accompanied this code).
4054 #
4055 # You should have received a copy of the GNU General Public License version
4056 # 2 along with this work; if not, write to the Free Software Foundation,
4057 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4058 #
4059 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4060 # or visit www.oracle.com if you need additional information or have any
4061 # questions.
4062 #
4063 
4064 
4065 
4066 
4067 
4068 
4069 
4070 # Check if the VS env variables were setup prior to running configure.
4071 # If not, then find vcvarsall.bat and run it automatically, and integrate
4072 # the set env variables into the spec file.
4073 
4074 
4075 
4076 
4077 
4078 
4079 
4080 
4081 
4082 
4083 # This line needs to be here, verbatim, after all includes and the dummy hook
4084 # definitions. It is replaced with custom functionality when building
4085 # custom sources.
4086 #CUSTOM_AUTOCONF_INCLUDE
4087 
4088 # Do not change or remove the following line, it is needed for consistency checks:
4089 DATE_WHEN_GENERATED=1392986016
4090 
4091 ###############################################################################
4092 #
4093 # Initialization / Boot-strapping
4094 #
4095 # The bootstrapping process needs to solve the "chicken or the egg" problem,
4096 # thus it jumps back and forth, each time gaining something needed later on.
4097 #
4098 ###############################################################################
4099 
4100 # Basic initialization that must happen first of all
4101 
4102   # Save the original command line. This is passed to us by the wrapper configure script.
4103 
4104   DATE_WHEN_CONFIGURED=`LANG=C date`
4105 
4106   { $as_echo "$as_me:${as_lineno-$LINENO}: Configuration created at $DATE_WHEN_CONFIGURED." >&5
4107 $as_echo "$as_me: Configuration created at $DATE_WHEN_CONFIGURED." >&6;}
4108   { $as_echo "$as_me:${as_lineno-$LINENO}: configure script generated at timestamp $DATE_WHEN_GENERATED." >&5
4109 $as_echo "$as_me: configure script generated at timestamp $DATE_WHEN_GENERATED." >&6;}
4110 
4111 
4112   # Start with tools that do not need have cross compilation support
4113   # and can be expected to be found in the default PATH. These tools are
4114   # used by configure. Nor are these tools expected to be found in the
4115   # devkit from the builddeps server either, since they are
4116   # needed to download the devkit.
4117 
4118   # First are all the simple required tools.
4119 
4120 
4121 
4122   # Publish this variable in the help.
4123 
4124 
4125   if test "x$BASENAME" = x; then
4126     # The variable is not set by user, try to locate tool using the code snippet
4127     for ac_prog in basename
4128 do
4129   # Extract the first word of "$ac_prog", so it can be a program name with args.
4130 set dummy $ac_prog; ac_word=$2
4131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4132 $as_echo_n "checking for $ac_word... " >&6; }
4133 if ${ac_cv_path_BASENAME+:} false; then :
4134   $as_echo_n "(cached) " >&6
4135 else
4136   case $BASENAME in
4137   [\\/]* | ?:[\\/]*)
4138   ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
4139   ;;
4140   *)
4141   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4142 for as_dir in $PATH
4143 do
4144   IFS=$as_save_IFS
4145   test -z "$as_dir" && as_dir=.
4146     for ac_exec_ext in '' $ac_executable_extensions; do
4147   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4148     ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
4149     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4150     break 2
4151   fi
4152 done
4153   done
4154 IFS=$as_save_IFS
4155 
4156   ;;
4157 esac
4158 fi
4159 BASENAME=$ac_cv_path_BASENAME
4160 if test -n "$BASENAME"; then
4161   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
4162 $as_echo "$BASENAME" >&6; }
4163 else
4164   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4165 $as_echo "no" >&6; }
4166 fi
4167 
4168 
4169   test -n "$BASENAME" && break
4170 done
4171 
4172   else
4173     # The variable is set, but is it from the command line or the environment?
4174 
4175     # Try to remove the string !BASENAME! from our list.
4176     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASENAME!/}
4177     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4178       # If it failed, the variable was not from the command line. Ignore it,
4179       # but warn the user (except for BASH, which is always set by the calling BASH).
4180       if test "xBASENAME" != xBASH; then
4181         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&5
4182 $as_echo "$as_me: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&2;}
4183       fi
4184       # Try to locate tool using the code snippet
4185       for ac_prog in basename
4186 do
4187   # Extract the first word of "$ac_prog", so it can be a program name with args.
4188 set dummy $ac_prog; ac_word=$2
4189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4190 $as_echo_n "checking for $ac_word... " >&6; }
4191 if ${ac_cv_path_BASENAME+:} false; then :
4192   $as_echo_n "(cached) " >&6
4193 else
4194   case $BASENAME in
4195   [\\/]* | ?:[\\/]*)
4196   ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
4197   ;;
4198   *)
4199   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4200 for as_dir in $PATH
4201 do
4202   IFS=$as_save_IFS
4203   test -z "$as_dir" && as_dir=.
4204     for ac_exec_ext in '' $ac_executable_extensions; do
4205   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4206     ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
4207     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4208     break 2
4209   fi
4210 done
4211   done
4212 IFS=$as_save_IFS
4213 
4214   ;;
4215 esac
4216 fi
4217 BASENAME=$ac_cv_path_BASENAME
4218 if test -n "$BASENAME"; then
4219   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
4220 $as_echo "$BASENAME" >&6; }
4221 else
4222   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4223 $as_echo "no" >&6; }
4224 fi
4225 
4226 
4227   test -n "$BASENAME" && break
4228 done
4229 
4230     else
4231       # If it succeeded, then it was overridden by the user. We will use it
4232       # for the tool.
4233 
4234       # First remove it from the list of overridden variables, so we can test
4235       # for unknown variables in the end.
4236       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4237 
4238       # Check if the provided tool contains a complete path.
4239       tool_specified="$BASENAME"
4240       tool_basename="${tool_specified##*/}"
4241       if test "x$tool_basename" = "x$tool_specified"; then
4242         # A command without a complete path is provided, search $PATH.
4243         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASENAME=$tool_basename" >&5
4244 $as_echo "$as_me: Will search for user supplied tool BASENAME=$tool_basename" >&6;}
4245         # Extract the first word of "$tool_basename", so it can be a program name with args.
4246 set dummy $tool_basename; ac_word=$2
4247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4248 $as_echo_n "checking for $ac_word... " >&6; }
4249 if ${ac_cv_path_BASENAME+:} false; then :
4250   $as_echo_n "(cached) " >&6
4251 else
4252   case $BASENAME in
4253   [\\/]* | ?:[\\/]*)
4254   ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
4255   ;;
4256   *)
4257   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4258 for as_dir in $PATH
4259 do
4260   IFS=$as_save_IFS
4261   test -z "$as_dir" && as_dir=.
4262     for ac_exec_ext in '' $ac_executable_extensions; do
4263   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4264     ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
4265     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4266     break 2
4267   fi
4268 done
4269   done
4270 IFS=$as_save_IFS
4271 
4272   ;;
4273 esac
4274 fi
4275 BASENAME=$ac_cv_path_BASENAME
4276 if test -n "$BASENAME"; then
4277   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
4278 $as_echo "$BASENAME" >&6; }
4279 else
4280   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4281 $as_echo "no" >&6; }
4282 fi
4283 
4284 
4285         if test "x$BASENAME" = x; then
4286           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
4287         fi
4288       else
4289         # Otherwise we believe it is a complete path. Use it as it is.
4290         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASENAME=$tool_specified" >&5
4291 $as_echo "$as_me: Will use user supplied tool BASENAME=$tool_specified" >&6;}
4292         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5
4293 $as_echo_n "checking for BASENAME... " >&6; }
4294         if test ! -x "$tool_specified"; then
4295           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4296 $as_echo "not found" >&6; }
4297           as_fn_error $? "User supplied tool BASENAME=$tool_specified does not exist or is not executable" "$LINENO" 5
4298         fi
4299         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
4300 $as_echo "$tool_specified" >&6; }
4301       fi
4302     fi
4303   fi
4304 
4305 
4306 
4307   if test "x$BASENAME" = x; then
4308     as_fn_error $? "Could not find required tool for BASENAME" "$LINENO" 5
4309   fi
4310 
4311 
4312 
4313 
4314 
4315   # Publish this variable in the help.
4316 
4317 
4318   if test "x$BASH" = x; then
4319     # The variable is not set by user, try to locate tool using the code snippet
4320     for ac_prog in bash
4321 do
4322   # Extract the first word of "$ac_prog", so it can be a program name with args.
4323 set dummy $ac_prog; ac_word=$2
4324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4325 $as_echo_n "checking for $ac_word... " >&6; }
4326 if ${ac_cv_path_BASH+:} false; then :
4327   $as_echo_n "(cached) " >&6
4328 else
4329   case $BASH in
4330   [\\/]* | ?:[\\/]*)
4331   ac_cv_path_BASH="$BASH" # Let the user override the test with a path.
4332   ;;
4333   *)
4334   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4335 for as_dir in $PATH
4336 do
4337   IFS=$as_save_IFS
4338   test -z "$as_dir" && as_dir=.
4339     for ac_exec_ext in '' $ac_executable_extensions; do
4340   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4341     ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext"
4342     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4343     break 2
4344   fi
4345 done
4346   done
4347 IFS=$as_save_IFS
4348 
4349   ;;
4350 esac
4351 fi
4352 BASH=$ac_cv_path_BASH
4353 if test -n "$BASH"; then
4354   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5
4355 $as_echo "$BASH" >&6; }
4356 else
4357   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4358 $as_echo "no" >&6; }
4359 fi
4360 
4361 
4362   test -n "$BASH" && break
4363 done
4364 
4365   else
4366     # The variable is set, but is it from the command line or the environment?
4367 
4368     # Try to remove the string !BASH! from our list.
4369     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASH!/}
4370     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4371       # If it failed, the variable was not from the command line. Ignore it,
4372       # but warn the user (except for BASH, which is always set by the calling BASH).
4373       if test "xBASH" != xBASH; then
4374         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&5
4375 $as_echo "$as_me: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&2;}
4376       fi
4377       # Try to locate tool using the code snippet
4378       for ac_prog in bash
4379 do
4380   # Extract the first word of "$ac_prog", so it can be a program name with args.
4381 set dummy $ac_prog; ac_word=$2
4382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4383 $as_echo_n "checking for $ac_word... " >&6; }
4384 if ${ac_cv_path_BASH+:} false; then :
4385   $as_echo_n "(cached) " >&6
4386 else
4387   case $BASH in
4388   [\\/]* | ?:[\\/]*)
4389   ac_cv_path_BASH="$BASH" # Let the user override the test with a path.
4390   ;;
4391   *)
4392   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4393 for as_dir in $PATH
4394 do
4395   IFS=$as_save_IFS
4396   test -z "$as_dir" && as_dir=.
4397     for ac_exec_ext in '' $ac_executable_extensions; do
4398   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4399     ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext"
4400     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4401     break 2
4402   fi
4403 done
4404   done
4405 IFS=$as_save_IFS
4406 
4407   ;;
4408 esac
4409 fi
4410 BASH=$ac_cv_path_BASH
4411 if test -n "$BASH"; then
4412   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5
4413 $as_echo "$BASH" >&6; }
4414 else
4415   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4416 $as_echo "no" >&6; }
4417 fi
4418 
4419 
4420   test -n "$BASH" && break
4421 done
4422 
4423     else
4424       # If it succeeded, then it was overridden by the user. We will use it
4425       # for the tool.
4426 
4427       # First remove it from the list of overridden variables, so we can test
4428       # for unknown variables in the end.
4429       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4430 
4431       # Check if the provided tool contains a complete path.
4432       tool_specified="$BASH"
4433       tool_basename="${tool_specified##*/}"
4434       if test "x$tool_basename" = "x$tool_specified"; then
4435         # A command without a complete path is provided, search $PATH.
4436         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASH=$tool_basename" >&5
4437 $as_echo "$as_me: Will search for user supplied tool BASH=$tool_basename" >&6;}
4438         # Extract the first word of "$tool_basename", so it can be a program name with args.
4439 set dummy $tool_basename; ac_word=$2
4440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4441 $as_echo_n "checking for $ac_word... " >&6; }
4442 if ${ac_cv_path_BASH+:} false; then :
4443   $as_echo_n "(cached) " >&6
4444 else
4445   case $BASH in
4446   [\\/]* | ?:[\\/]*)
4447   ac_cv_path_BASH="$BASH" # Let the user override the test with a path.
4448   ;;
4449   *)
4450   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4451 for as_dir in $PATH
4452 do
4453   IFS=$as_save_IFS
4454   test -z "$as_dir" && as_dir=.
4455     for ac_exec_ext in '' $ac_executable_extensions; do
4456   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4457     ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext"
4458     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4459     break 2
4460   fi
4461 done
4462   done
4463 IFS=$as_save_IFS
4464 
4465   ;;
4466 esac
4467 fi
4468 BASH=$ac_cv_path_BASH
4469 if test -n "$BASH"; then
4470   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5
4471 $as_echo "$BASH" >&6; }
4472 else
4473   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4474 $as_echo "no" >&6; }
4475 fi
4476 
4477 
4478         if test "x$BASH" = x; then
4479           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
4480         fi
4481       else
4482         # Otherwise we believe it is a complete path. Use it as it is.
4483         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASH=$tool_specified" >&5
4484 $as_echo "$as_me: Will use user supplied tool BASH=$tool_specified" >&6;}
4485         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5
4486 $as_echo_n "checking for BASH... " >&6; }
4487         if test ! -x "$tool_specified"; then
4488           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4489 $as_echo "not found" >&6; }
4490           as_fn_error $? "User supplied tool BASH=$tool_specified does not exist or is not executable" "$LINENO" 5
4491         fi
4492         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
4493 $as_echo "$tool_specified" >&6; }
4494       fi
4495     fi
4496   fi
4497 
4498 
4499 
4500   if test "x$BASH" = x; then
4501     as_fn_error $? "Could not find required tool for BASH" "$LINENO" 5
4502   fi
4503 
4504 
4505 
4506 
4507 
4508   # Publish this variable in the help.
4509 
4510 
4511   if test "x$CAT" = x; then
4512     # The variable is not set by user, try to locate tool using the code snippet
4513     for ac_prog in cat
4514 do
4515   # Extract the first word of "$ac_prog", so it can be a program name with args.
4516 set dummy $ac_prog; ac_word=$2
4517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4518 $as_echo_n "checking for $ac_word... " >&6; }
4519 if ${ac_cv_path_CAT+:} false; then :
4520   $as_echo_n "(cached) " >&6
4521 else
4522   case $CAT in
4523   [\\/]* | ?:[\\/]*)
4524   ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4525   ;;
4526   *)
4527   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4528 for as_dir in $PATH
4529 do
4530   IFS=$as_save_IFS
4531   test -z "$as_dir" && as_dir=.
4532     for ac_exec_ext in '' $ac_executable_extensions; do
4533   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4534     ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4535     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4536     break 2
4537   fi
4538 done
4539   done
4540 IFS=$as_save_IFS
4541 
4542   ;;
4543 esac
4544 fi
4545 CAT=$ac_cv_path_CAT
4546 if test -n "$CAT"; then
4547   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5
4548 $as_echo "$CAT" >&6; }
4549 else
4550   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4551 $as_echo "no" >&6; }
4552 fi
4553 
4554 
4555   test -n "$CAT" && break
4556 done
4557 
4558   else
4559     # The variable is set, but is it from the command line or the environment?
4560 
4561     # Try to remove the string !CAT! from our list.
4562     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CAT!/}
4563     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4564       # If it failed, the variable was not from the command line. Ignore it,
4565       # but warn the user (except for BASH, which is always set by the calling BASH).
4566       if test "xCAT" != xBASH; then
4567         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&5
4568 $as_echo "$as_me: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&2;}
4569       fi
4570       # Try to locate tool using the code snippet
4571       for ac_prog in cat
4572 do
4573   # Extract the first word of "$ac_prog", so it can be a program name with args.
4574 set dummy $ac_prog; ac_word=$2
4575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4576 $as_echo_n "checking for $ac_word... " >&6; }
4577 if ${ac_cv_path_CAT+:} false; then :
4578   $as_echo_n "(cached) " >&6
4579 else
4580   case $CAT in
4581   [\\/]* | ?:[\\/]*)
4582   ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4583   ;;
4584   *)
4585   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4586 for as_dir in $PATH
4587 do
4588   IFS=$as_save_IFS
4589   test -z "$as_dir" && as_dir=.
4590     for ac_exec_ext in '' $ac_executable_extensions; do
4591   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4592     ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4593     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4594     break 2
4595   fi
4596 done
4597   done
4598 IFS=$as_save_IFS
4599 
4600   ;;
4601 esac
4602 fi
4603 CAT=$ac_cv_path_CAT
4604 if test -n "$CAT"; then
4605   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5
4606 $as_echo "$CAT" >&6; }
4607 else
4608   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4609 $as_echo "no" >&6; }
4610 fi
4611 
4612 
4613   test -n "$CAT" && break
4614 done
4615 
4616     else
4617       # If it succeeded, then it was overridden by the user. We will use it
4618       # for the tool.
4619 
4620       # First remove it from the list of overridden variables, so we can test
4621       # for unknown variables in the end.
4622       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4623 
4624       # Check if the provided tool contains a complete path.
4625       tool_specified="$CAT"
4626       tool_basename="${tool_specified##*/}"
4627       if test "x$tool_basename" = "x$tool_specified"; then
4628         # A command without a complete path is provided, search $PATH.
4629         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CAT=$tool_basename" >&5
4630 $as_echo "$as_me: Will search for user supplied tool CAT=$tool_basename" >&6;}
4631         # Extract the first word of "$tool_basename", so it can be a program name with args.
4632 set dummy $tool_basename; ac_word=$2
4633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4634 $as_echo_n "checking for $ac_word... " >&6; }
4635 if ${ac_cv_path_CAT+:} false; then :
4636   $as_echo_n "(cached) " >&6
4637 else
4638   case $CAT in
4639   [\\/]* | ?:[\\/]*)
4640   ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4641   ;;
4642   *)
4643   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4644 for as_dir in $PATH
4645 do
4646   IFS=$as_save_IFS
4647   test -z "$as_dir" && as_dir=.
4648     for ac_exec_ext in '' $ac_executable_extensions; do
4649   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4650     ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4651     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4652     break 2
4653   fi
4654 done
4655   done
4656 IFS=$as_save_IFS
4657 
4658   ;;
4659 esac
4660 fi
4661 CAT=$ac_cv_path_CAT
4662 if test -n "$CAT"; then
4663   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5
4664 $as_echo "$CAT" >&6; }
4665 else
4666   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4667 $as_echo "no" >&6; }
4668 fi
4669 
4670 
4671         if test "x$CAT" = x; then
4672           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
4673         fi
4674       else
4675         # Otherwise we believe it is a complete path. Use it as it is.
4676         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CAT=$tool_specified" >&5
4677 $as_echo "$as_me: Will use user supplied tool CAT=$tool_specified" >&6;}
4678         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5
4679 $as_echo_n "checking for CAT... " >&6; }
4680         if test ! -x "$tool_specified"; then
4681           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4682 $as_echo "not found" >&6; }
4683           as_fn_error $? "User supplied tool CAT=$tool_specified does not exist or is not executable" "$LINENO" 5
4684         fi
4685         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
4686 $as_echo "$tool_specified" >&6; }
4687       fi
4688     fi
4689   fi
4690 
4691 
4692 
4693   if test "x$CAT" = x; then
4694     as_fn_error $? "Could not find required tool for CAT" "$LINENO" 5
4695   fi
4696 
4697 
4698 
4699 
4700 
4701   # Publish this variable in the help.
4702 
4703 
4704   if test "x$CHMOD" = x; then
4705     # The variable is not set by user, try to locate tool using the code snippet
4706     for ac_prog in chmod
4707 do
4708   # Extract the first word of "$ac_prog", so it can be a program name with args.
4709 set dummy $ac_prog; ac_word=$2
4710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4711 $as_echo_n "checking for $ac_word... " >&6; }
4712 if ${ac_cv_path_CHMOD+:} false; then :
4713   $as_echo_n "(cached) " >&6
4714 else
4715   case $CHMOD in
4716   [\\/]* | ?:[\\/]*)
4717   ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
4718   ;;
4719   *)
4720   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4721 for as_dir in $PATH
4722 do
4723   IFS=$as_save_IFS
4724   test -z "$as_dir" && as_dir=.
4725     for ac_exec_ext in '' $ac_executable_extensions; do
4726   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4727     ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext"
4728     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4729     break 2
4730   fi
4731 done
4732   done
4733 IFS=$as_save_IFS
4734 
4735   ;;
4736 esac
4737 fi
4738 CHMOD=$ac_cv_path_CHMOD
4739 if test -n "$CHMOD"; then
4740   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5
4741 $as_echo "$CHMOD" >&6; }
4742 else
4743   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4744 $as_echo "no" >&6; }
4745 fi
4746 
4747 
4748   test -n "$CHMOD" && break
4749 done
4750 
4751   else
4752     # The variable is set, but is it from the command line or the environment?
4753 
4754     # Try to remove the string !CHMOD! from our list.
4755     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CHMOD!/}
4756     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4757       # If it failed, the variable was not from the command line. Ignore it,
4758       # but warn the user (except for BASH, which is always set by the calling BASH).
4759       if test "xCHMOD" != xBASH; then
4760         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&5
4761 $as_echo "$as_me: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&2;}
4762       fi
4763       # Try to locate tool using the code snippet
4764       for ac_prog in chmod
4765 do
4766   # Extract the first word of "$ac_prog", so it can be a program name with args.
4767 set dummy $ac_prog; ac_word=$2
4768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4769 $as_echo_n "checking for $ac_word... " >&6; }
4770 if ${ac_cv_path_CHMOD+:} false; then :
4771   $as_echo_n "(cached) " >&6
4772 else
4773   case $CHMOD in
4774   [\\/]* | ?:[\\/]*)
4775   ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
4776   ;;
4777   *)
4778   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4779 for as_dir in $PATH
4780 do
4781   IFS=$as_save_IFS
4782   test -z "$as_dir" && as_dir=.
4783     for ac_exec_ext in '' $ac_executable_extensions; do
4784   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4785     ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext"
4786     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4787     break 2
4788   fi
4789 done
4790   done
4791 IFS=$as_save_IFS
4792 
4793   ;;
4794 esac
4795 fi
4796 CHMOD=$ac_cv_path_CHMOD
4797 if test -n "$CHMOD"; then
4798   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5
4799 $as_echo "$CHMOD" >&6; }
4800 else
4801   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4802 $as_echo "no" >&6; }
4803 fi
4804 
4805 
4806   test -n "$CHMOD" && break
4807 done
4808 
4809     else
4810       # If it succeeded, then it was overridden by the user. We will use it
4811       # for the tool.
4812 
4813       # First remove it from the list of overridden variables, so we can test
4814       # for unknown variables in the end.
4815       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4816 
4817       # Check if the provided tool contains a complete path.
4818       tool_specified="$CHMOD"
4819       tool_basename="${tool_specified##*/}"
4820       if test "x$tool_basename" = "x$tool_specified"; then
4821         # A command without a complete path is provided, search $PATH.
4822         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CHMOD=$tool_basename" >&5
4823 $as_echo "$as_me: Will search for user supplied tool CHMOD=$tool_basename" >&6;}
4824         # Extract the first word of "$tool_basename", so it can be a program name with args.
4825 set dummy $tool_basename; ac_word=$2
4826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4827 $as_echo_n "checking for $ac_word... " >&6; }
4828 if ${ac_cv_path_CHMOD+:} false; then :
4829   $as_echo_n "(cached) " >&6
4830 else
4831   case $CHMOD in
4832   [\\/]* | ?:[\\/]*)
4833   ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
4834   ;;
4835   *)
4836   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4837 for as_dir in $PATH
4838 do
4839   IFS=$as_save_IFS
4840   test -z "$as_dir" && as_dir=.
4841     for ac_exec_ext in '' $ac_executable_extensions; do
4842   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4843     ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext"
4844     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4845     break 2
4846   fi
4847 done
4848   done
4849 IFS=$as_save_IFS
4850 
4851   ;;
4852 esac
4853 fi
4854 CHMOD=$ac_cv_path_CHMOD
4855 if test -n "$CHMOD"; then
4856   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5
4857 $as_echo "$CHMOD" >&6; }
4858 else
4859   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4860 $as_echo "no" >&6; }
4861 fi
4862 
4863 
4864         if test "x$CHMOD" = x; then
4865           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
4866         fi
4867       else
4868         # Otherwise we believe it is a complete path. Use it as it is.
4869         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CHMOD=$tool_specified" >&5
4870 $as_echo "$as_me: Will use user supplied tool CHMOD=$tool_specified" >&6;}
4871         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5
4872 $as_echo_n "checking for CHMOD... " >&6; }
4873         if test ! -x "$tool_specified"; then
4874           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4875 $as_echo "not found" >&6; }
4876           as_fn_error $? "User supplied tool CHMOD=$tool_specified does not exist or is not executable" "$LINENO" 5
4877         fi
4878         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
4879 $as_echo "$tool_specified" >&6; }
4880       fi
4881     fi
4882   fi
4883 
4884 
4885 
4886   if test "x$CHMOD" = x; then
4887     as_fn_error $? "Could not find required tool for CHMOD" "$LINENO" 5
4888   fi
4889 
4890 
4891 
4892 
4893 
4894   # Publish this variable in the help.
4895 
4896 
4897   if test "x$CMP" = x; then
4898     # The variable is not set by user, try to locate tool using the code snippet
4899     for ac_prog in cmp
4900 do
4901   # Extract the first word of "$ac_prog", so it can be a program name with args.
4902 set dummy $ac_prog; ac_word=$2
4903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4904 $as_echo_n "checking for $ac_word... " >&6; }
4905 if ${ac_cv_path_CMP+:} false; then :
4906   $as_echo_n "(cached) " >&6
4907 else
4908   case $CMP in
4909   [\\/]* | ?:[\\/]*)
4910   ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
4911   ;;
4912   *)
4913   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4914 for as_dir in $PATH
4915 do
4916   IFS=$as_save_IFS
4917   test -z "$as_dir" && as_dir=.
4918     for ac_exec_ext in '' $ac_executable_extensions; do
4919   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4920     ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
4921     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4922     break 2
4923   fi
4924 done
4925   done
4926 IFS=$as_save_IFS
4927 
4928   ;;
4929 esac
4930 fi
4931 CMP=$ac_cv_path_CMP
4932 if test -n "$CMP"; then
4933   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
4934 $as_echo "$CMP" >&6; }
4935 else
4936   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4937 $as_echo "no" >&6; }
4938 fi
4939 
4940 
4941   test -n "$CMP" && break
4942 done
4943 
4944   else
4945     # The variable is set, but is it from the command line or the environment?
4946 
4947     # Try to remove the string !CMP! from our list.
4948     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CMP!/}
4949     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4950       # If it failed, the variable was not from the command line. Ignore it,
4951       # but warn the user (except for BASH, which is always set by the calling BASH).
4952       if test "xCMP" != xBASH; then
4953         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&5
4954 $as_echo "$as_me: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&2;}
4955       fi
4956       # Try to locate tool using the code snippet
4957       for ac_prog in cmp
4958 do
4959   # Extract the first word of "$ac_prog", so it can be a program name with args.
4960 set dummy $ac_prog; ac_word=$2
4961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4962 $as_echo_n "checking for $ac_word... " >&6; }
4963 if ${ac_cv_path_CMP+:} false; then :
4964   $as_echo_n "(cached) " >&6
4965 else
4966   case $CMP in
4967   [\\/]* | ?:[\\/]*)
4968   ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
4969   ;;
4970   *)
4971   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4972 for as_dir in $PATH
4973 do
4974   IFS=$as_save_IFS
4975   test -z "$as_dir" && as_dir=.
4976     for ac_exec_ext in '' $ac_executable_extensions; do
4977   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4978     ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
4979     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4980     break 2
4981   fi
4982 done
4983   done
4984 IFS=$as_save_IFS
4985 
4986   ;;
4987 esac
4988 fi
4989 CMP=$ac_cv_path_CMP
4990 if test -n "$CMP"; then
4991   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
4992 $as_echo "$CMP" >&6; }
4993 else
4994   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4995 $as_echo "no" >&6; }
4996 fi
4997 
4998 
4999   test -n "$CMP" && break
5000 done
5001 
5002     else
5003       # If it succeeded, then it was overridden by the user. We will use it
5004       # for the tool.
5005 
5006       # First remove it from the list of overridden variables, so we can test
5007       # for unknown variables in the end.
5008       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5009 
5010       # Check if the provided tool contains a complete path.
5011       tool_specified="$CMP"
5012       tool_basename="${tool_specified##*/}"
5013       if test "x$tool_basename" = "x$tool_specified"; then
5014         # A command without a complete path is provided, search $PATH.
5015         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CMP=$tool_basename" >&5
5016 $as_echo "$as_me: Will search for user supplied tool CMP=$tool_basename" >&6;}
5017         # Extract the first word of "$tool_basename", so it can be a program name with args.
5018 set dummy $tool_basename; ac_word=$2
5019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5020 $as_echo_n "checking for $ac_word... " >&6; }
5021 if ${ac_cv_path_CMP+:} false; then :
5022   $as_echo_n "(cached) " >&6
5023 else
5024   case $CMP in
5025   [\\/]* | ?:[\\/]*)
5026   ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
5027   ;;
5028   *)
5029   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5030 for as_dir in $PATH
5031 do
5032   IFS=$as_save_IFS
5033   test -z "$as_dir" && as_dir=.
5034     for ac_exec_ext in '' $ac_executable_extensions; do
5035   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5036     ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
5037     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5038     break 2
5039   fi
5040 done
5041   done
5042 IFS=$as_save_IFS
5043 
5044   ;;
5045 esac
5046 fi
5047 CMP=$ac_cv_path_CMP
5048 if test -n "$CMP"; then
5049   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
5050 $as_echo "$CMP" >&6; }
5051 else
5052   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5053 $as_echo "no" >&6; }
5054 fi
5055 
5056 
5057         if test "x$CMP" = x; then
5058           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5059         fi
5060       else
5061         # Otherwise we believe it is a complete path. Use it as it is.
5062         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CMP=$tool_specified" >&5
5063 $as_echo "$as_me: Will use user supplied tool CMP=$tool_specified" >&6;}
5064         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5
5065 $as_echo_n "checking for CMP... " >&6; }
5066         if test ! -x "$tool_specified"; then
5067           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5068 $as_echo "not found" >&6; }
5069           as_fn_error $? "User supplied tool CMP=$tool_specified does not exist or is not executable" "$LINENO" 5
5070         fi
5071         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5072 $as_echo "$tool_specified" >&6; }
5073       fi
5074     fi
5075   fi
5076 
5077 
5078 
5079   if test "x$CMP" = x; then
5080     as_fn_error $? "Could not find required tool for CMP" "$LINENO" 5
5081   fi
5082 
5083 
5084 
5085 
5086 
5087   # Publish this variable in the help.
5088 
5089 
5090   if test "x$COMM" = x; then
5091     # The variable is not set by user, try to locate tool using the code snippet
5092     for ac_prog in comm
5093 do
5094   # Extract the first word of "$ac_prog", so it can be a program name with args.
5095 set dummy $ac_prog; ac_word=$2
5096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5097 $as_echo_n "checking for $ac_word... " >&6; }
5098 if ${ac_cv_path_COMM+:} false; then :
5099   $as_echo_n "(cached) " >&6
5100 else
5101   case $COMM in
5102   [\\/]* | ?:[\\/]*)
5103   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
5104   ;;
5105   *)
5106   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5107 for as_dir in $PATH
5108 do
5109   IFS=$as_save_IFS
5110   test -z "$as_dir" && as_dir=.
5111     for ac_exec_ext in '' $ac_executable_extensions; do
5112   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5113     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
5114     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5115     break 2
5116   fi
5117 done
5118   done
5119 IFS=$as_save_IFS
5120 
5121   ;;
5122 esac
5123 fi
5124 COMM=$ac_cv_path_COMM
5125 if test -n "$COMM"; then
5126   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
5127 $as_echo "$COMM" >&6; }
5128 else
5129   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5130 $as_echo "no" >&6; }
5131 fi
5132 
5133 
5134   test -n "$COMM" && break
5135 done
5136 
5137   else
5138     # The variable is set, but is it from the command line or the environment?
5139 
5140     # Try to remove the string !COMM! from our list.
5141     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/}
5142     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5143       # If it failed, the variable was not from the command line. Ignore it,
5144       # but warn the user (except for BASH, which is always set by the calling BASH).
5145       if test "xCOMM" != xBASH; then
5146         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5
5147 $as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;}
5148       fi
5149       # Try to locate tool using the code snippet
5150       for ac_prog in comm
5151 do
5152   # Extract the first word of "$ac_prog", so it can be a program name with args.
5153 set dummy $ac_prog; ac_word=$2
5154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5155 $as_echo_n "checking for $ac_word... " >&6; }
5156 if ${ac_cv_path_COMM+:} false; then :
5157   $as_echo_n "(cached) " >&6
5158 else
5159   case $COMM in
5160   [\\/]* | ?:[\\/]*)
5161   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
5162   ;;
5163   *)
5164   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5165 for as_dir in $PATH
5166 do
5167   IFS=$as_save_IFS
5168   test -z "$as_dir" && as_dir=.
5169     for ac_exec_ext in '' $ac_executable_extensions; do
5170   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5171     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
5172     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5173     break 2
5174   fi
5175 done
5176   done
5177 IFS=$as_save_IFS
5178 
5179   ;;
5180 esac
5181 fi
5182 COMM=$ac_cv_path_COMM
5183 if test -n "$COMM"; then
5184   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
5185 $as_echo "$COMM" >&6; }
5186 else
5187   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5188 $as_echo "no" >&6; }
5189 fi
5190 
5191 
5192   test -n "$COMM" && break
5193 done
5194 
5195     else
5196       # If it succeeded, then it was overridden by the user. We will use it
5197       # for the tool.
5198 
5199       # First remove it from the list of overridden variables, so we can test
5200       # for unknown variables in the end.
5201       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5202 
5203       # Check if the provided tool contains a complete path.
5204       tool_specified="$COMM"
5205       tool_basename="${tool_specified##*/}"
5206       if test "x$tool_basename" = "x$tool_specified"; then
5207         # A command without a complete path is provided, search $PATH.
5208         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5
5209 $as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;}
5210         # Extract the first word of "$tool_basename", so it can be a program name with args.
5211 set dummy $tool_basename; ac_word=$2
5212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5213 $as_echo_n "checking for $ac_word... " >&6; }
5214 if ${ac_cv_path_COMM+:} false; then :
5215   $as_echo_n "(cached) " >&6
5216 else
5217   case $COMM in
5218   [\\/]* | ?:[\\/]*)
5219   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
5220   ;;
5221   *)
5222   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5223 for as_dir in $PATH
5224 do
5225   IFS=$as_save_IFS
5226   test -z "$as_dir" && as_dir=.
5227     for ac_exec_ext in '' $ac_executable_extensions; do
5228   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5229     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
5230     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5231     break 2
5232   fi
5233 done
5234   done
5235 IFS=$as_save_IFS
5236 
5237   ;;
5238 esac
5239 fi
5240 COMM=$ac_cv_path_COMM
5241 if test -n "$COMM"; then
5242   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
5243 $as_echo "$COMM" >&6; }
5244 else
5245   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5246 $as_echo "no" >&6; }
5247 fi
5248 
5249 
5250         if test "x$COMM" = x; then
5251           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5252         fi
5253       else
5254         # Otherwise we believe it is a complete path. Use it as it is.
5255         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5
5256 $as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;}
5257         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5
5258 $as_echo_n "checking for COMM... " >&6; }
5259         if test ! -x "$tool_specified"; then
5260           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5261 $as_echo "not found" >&6; }
5262           as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5
5263         fi
5264         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5265 $as_echo "$tool_specified" >&6; }
5266       fi
5267     fi
5268   fi
5269 
5270 
5271 
5272   if test "x$COMM" = x; then
5273     as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5
5274   fi
5275 
5276 
5277 
5278 
5279 
5280   # Publish this variable in the help.
5281 
5282 
5283   if test "x$CP" = x; then
5284     # The variable is not set by user, try to locate tool using the code snippet
5285     for ac_prog in cp
5286 do
5287   # Extract the first word of "$ac_prog", so it can be a program name with args.
5288 set dummy $ac_prog; ac_word=$2
5289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5290 $as_echo_n "checking for $ac_word... " >&6; }
5291 if ${ac_cv_path_CP+:} false; then :
5292   $as_echo_n "(cached) " >&6
5293 else
5294   case $CP in
5295   [\\/]* | ?:[\\/]*)
5296   ac_cv_path_CP="$CP" # Let the user override the test with a path.
5297   ;;
5298   *)
5299   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5300 for as_dir in $PATH
5301 do
5302   IFS=$as_save_IFS
5303   test -z "$as_dir" && as_dir=.
5304     for ac_exec_ext in '' $ac_executable_extensions; do
5305   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5306     ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext"
5307     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5308     break 2
5309   fi
5310 done
5311   done
5312 IFS=$as_save_IFS
5313 
5314   ;;
5315 esac
5316 fi
5317 CP=$ac_cv_path_CP
5318 if test -n "$CP"; then
5319   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5
5320 $as_echo "$CP" >&6; }
5321 else
5322   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5323 $as_echo "no" >&6; }
5324 fi
5325 
5326 
5327   test -n "$CP" && break
5328 done
5329 
5330   else
5331     # The variable is set, but is it from the command line or the environment?
5332 
5333     # Try to remove the string !CP! from our list.
5334     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CP!/}
5335     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5336       # If it failed, the variable was not from the command line. Ignore it,
5337       # but warn the user (except for BASH, which is always set by the calling BASH).
5338       if test "xCP" != xBASH; then
5339         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&5
5340 $as_echo "$as_me: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&2;}
5341       fi
5342       # Try to locate tool using the code snippet
5343       for ac_prog in cp
5344 do
5345   # Extract the first word of "$ac_prog", so it can be a program name with args.
5346 set dummy $ac_prog; ac_word=$2
5347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5348 $as_echo_n "checking for $ac_word... " >&6; }
5349 if ${ac_cv_path_CP+:} false; then :
5350   $as_echo_n "(cached) " >&6
5351 else
5352   case $CP in
5353   [\\/]* | ?:[\\/]*)
5354   ac_cv_path_CP="$CP" # Let the user override the test with a path.
5355   ;;
5356   *)
5357   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5358 for as_dir in $PATH
5359 do
5360   IFS=$as_save_IFS
5361   test -z "$as_dir" && as_dir=.
5362     for ac_exec_ext in '' $ac_executable_extensions; do
5363   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5364     ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext"
5365     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5366     break 2
5367   fi
5368 done
5369   done
5370 IFS=$as_save_IFS
5371 
5372   ;;
5373 esac
5374 fi
5375 CP=$ac_cv_path_CP
5376 if test -n "$CP"; then
5377   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5
5378 $as_echo "$CP" >&6; }
5379 else
5380   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5381 $as_echo "no" >&6; }
5382 fi
5383 
5384 
5385   test -n "$CP" && break
5386 done
5387 
5388     else
5389       # If it succeeded, then it was overridden by the user. We will use it
5390       # for the tool.
5391 
5392       # First remove it from the list of overridden variables, so we can test
5393       # for unknown variables in the end.
5394       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5395 
5396       # Check if the provided tool contains a complete path.
5397       tool_specified="$CP"
5398       tool_basename="${tool_specified##*/}"
5399       if test "x$tool_basename" = "x$tool_specified"; then
5400         # A command without a complete path is provided, search $PATH.
5401         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CP=$tool_basename" >&5
5402 $as_echo "$as_me: Will search for user supplied tool CP=$tool_basename" >&6;}
5403         # Extract the first word of "$tool_basename", so it can be a program name with args.
5404 set dummy $tool_basename; ac_word=$2
5405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5406 $as_echo_n "checking for $ac_word... " >&6; }
5407 if ${ac_cv_path_CP+:} false; then :
5408   $as_echo_n "(cached) " >&6
5409 else
5410   case $CP in
5411   [\\/]* | ?:[\\/]*)
5412   ac_cv_path_CP="$CP" # Let the user override the test with a path.
5413   ;;
5414   *)
5415   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5416 for as_dir in $PATH
5417 do
5418   IFS=$as_save_IFS
5419   test -z "$as_dir" && as_dir=.
5420     for ac_exec_ext in '' $ac_executable_extensions; do
5421   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5422     ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext"
5423     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5424     break 2
5425   fi
5426 done
5427   done
5428 IFS=$as_save_IFS
5429 
5430   ;;
5431 esac
5432 fi
5433 CP=$ac_cv_path_CP
5434 if test -n "$CP"; then
5435   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5
5436 $as_echo "$CP" >&6; }
5437 else
5438   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5439 $as_echo "no" >&6; }
5440 fi
5441 
5442 
5443         if test "x$CP" = x; then
5444           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5445         fi
5446       else
5447         # Otherwise we believe it is a complete path. Use it as it is.
5448         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CP=$tool_specified" >&5
5449 $as_echo "$as_me: Will use user supplied tool CP=$tool_specified" >&6;}
5450         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5
5451 $as_echo_n "checking for CP... " >&6; }
5452         if test ! -x "$tool_specified"; then
5453           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5454 $as_echo "not found" >&6; }
5455           as_fn_error $? "User supplied tool CP=$tool_specified does not exist or is not executable" "$LINENO" 5
5456         fi
5457         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5458 $as_echo "$tool_specified" >&6; }
5459       fi
5460     fi
5461   fi
5462 
5463 
5464 
5465   if test "x$CP" = x; then
5466     as_fn_error $? "Could not find required tool for CP" "$LINENO" 5
5467   fi
5468 
5469 
5470 
5471 
5472 
5473   # Publish this variable in the help.
5474 
5475 
5476   if test "x$CPIO" = x; then
5477     # The variable is not set by user, try to locate tool using the code snippet
5478     for ac_prog in cpio
5479 do
5480   # Extract the first word of "$ac_prog", so it can be a program name with args.
5481 set dummy $ac_prog; ac_word=$2
5482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5483 $as_echo_n "checking for $ac_word... " >&6; }
5484 if ${ac_cv_path_CPIO+:} false; then :
5485   $as_echo_n "(cached) " >&6
5486 else
5487   case $CPIO in
5488   [\\/]* | ?:[\\/]*)
5489   ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path.
5490   ;;
5491   *)
5492   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5493 for as_dir in $PATH
5494 do
5495   IFS=$as_save_IFS
5496   test -z "$as_dir" && as_dir=.
5497     for ac_exec_ext in '' $ac_executable_extensions; do
5498   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5499     ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext"
5500     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5501     break 2
5502   fi
5503 done
5504   done
5505 IFS=$as_save_IFS
5506 
5507   ;;
5508 esac
5509 fi
5510 CPIO=$ac_cv_path_CPIO
5511 if test -n "$CPIO"; then
5512   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5
5513 $as_echo "$CPIO" >&6; }
5514 else
5515   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5516 $as_echo "no" >&6; }
5517 fi
5518 
5519 
5520   test -n "$CPIO" && break
5521 done
5522 
5523   else
5524     # The variable is set, but is it from the command line or the environment?
5525 
5526     # Try to remove the string !CPIO! from our list.
5527     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CPIO!/}
5528     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5529       # If it failed, the variable was not from the command line. Ignore it,
5530       # but warn the user (except for BASH, which is always set by the calling BASH).
5531       if test "xCPIO" != xBASH; then
5532         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&5
5533 $as_echo "$as_me: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&2;}
5534       fi
5535       # Try to locate tool using the code snippet
5536       for ac_prog in cpio
5537 do
5538   # Extract the first word of "$ac_prog", so it can be a program name with args.
5539 set dummy $ac_prog; ac_word=$2
5540 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5541 $as_echo_n "checking for $ac_word... " >&6; }
5542 if ${ac_cv_path_CPIO+:} false; then :
5543   $as_echo_n "(cached) " >&6
5544 else
5545   case $CPIO in
5546   [\\/]* | ?:[\\/]*)
5547   ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path.
5548   ;;
5549   *)
5550   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5551 for as_dir in $PATH
5552 do
5553   IFS=$as_save_IFS
5554   test -z "$as_dir" && as_dir=.
5555     for ac_exec_ext in '' $ac_executable_extensions; do
5556   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5557     ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext"
5558     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5559     break 2
5560   fi
5561 done
5562   done
5563 IFS=$as_save_IFS
5564 
5565   ;;
5566 esac
5567 fi
5568 CPIO=$ac_cv_path_CPIO
5569 if test -n "$CPIO"; then
5570   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5
5571 $as_echo "$CPIO" >&6; }
5572 else
5573   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5574 $as_echo "no" >&6; }
5575 fi
5576 
5577 
5578   test -n "$CPIO" && break
5579 done
5580 
5581     else
5582       # If it succeeded, then it was overridden by the user. We will use it
5583       # for the tool.
5584 
5585       # First remove it from the list of overridden variables, so we can test
5586       # for unknown variables in the end.
5587       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5588 
5589       # Check if the provided tool contains a complete path.
5590       tool_specified="$CPIO"
5591       tool_basename="${tool_specified##*/}"
5592       if test "x$tool_basename" = "x$tool_specified"; then
5593         # A command without a complete path is provided, search $PATH.
5594         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CPIO=$tool_basename" >&5
5595 $as_echo "$as_me: Will search for user supplied tool CPIO=$tool_basename" >&6;}
5596         # Extract the first word of "$tool_basename", so it can be a program name with args.
5597 set dummy $tool_basename; ac_word=$2
5598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5599 $as_echo_n "checking for $ac_word... " >&6; }
5600 if ${ac_cv_path_CPIO+:} false; then :
5601   $as_echo_n "(cached) " >&6
5602 else
5603   case $CPIO in
5604   [\\/]* | ?:[\\/]*)
5605   ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path.
5606   ;;
5607   *)
5608   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5609 for as_dir in $PATH
5610 do
5611   IFS=$as_save_IFS
5612   test -z "$as_dir" && as_dir=.
5613     for ac_exec_ext in '' $ac_executable_extensions; do
5614   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5615     ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext"
5616     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5617     break 2
5618   fi
5619 done
5620   done
5621 IFS=$as_save_IFS
5622 
5623   ;;
5624 esac
5625 fi
5626 CPIO=$ac_cv_path_CPIO
5627 if test -n "$CPIO"; then
5628   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5
5629 $as_echo "$CPIO" >&6; }
5630 else
5631   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5632 $as_echo "no" >&6; }
5633 fi
5634 
5635 
5636         if test "x$CPIO" = x; then
5637           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5638         fi
5639       else
5640         # Otherwise we believe it is a complete path. Use it as it is.
5641         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CPIO=$tool_specified" >&5
5642 $as_echo "$as_me: Will use user supplied tool CPIO=$tool_specified" >&6;}
5643         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5
5644 $as_echo_n "checking for CPIO... " >&6; }
5645         if test ! -x "$tool_specified"; then
5646           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5647 $as_echo "not found" >&6; }
5648           as_fn_error $? "User supplied tool CPIO=$tool_specified does not exist or is not executable" "$LINENO" 5
5649         fi
5650         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5651 $as_echo "$tool_specified" >&6; }
5652       fi
5653     fi
5654   fi
5655 
5656 
5657 
5658   if test "x$CPIO" = x; then
5659     as_fn_error $? "Could not find required tool for CPIO" "$LINENO" 5
5660   fi
5661 
5662 
5663 
5664 
5665 
5666   # Publish this variable in the help.
5667 
5668 
5669   if test "x$CUT" = x; then
5670     # The variable is not set by user, try to locate tool using the code snippet
5671     for ac_prog in cut
5672 do
5673   # Extract the first word of "$ac_prog", so it can be a program name with args.
5674 set dummy $ac_prog; ac_word=$2
5675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5676 $as_echo_n "checking for $ac_word... " >&6; }
5677 if ${ac_cv_path_CUT+:} false; then :
5678   $as_echo_n "(cached) " >&6
5679 else
5680   case $CUT in
5681   [\\/]* | ?:[\\/]*)
5682   ac_cv_path_CUT="$CUT" # Let the user override the test with a path.
5683   ;;
5684   *)
5685   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5686 for as_dir in $PATH
5687 do
5688   IFS=$as_save_IFS
5689   test -z "$as_dir" && as_dir=.
5690     for ac_exec_ext in '' $ac_executable_extensions; do
5691   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5692     ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext"
5693     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5694     break 2
5695   fi
5696 done
5697   done
5698 IFS=$as_save_IFS
5699 
5700   ;;
5701 esac
5702 fi
5703 CUT=$ac_cv_path_CUT
5704 if test -n "$CUT"; then
5705   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5
5706 $as_echo "$CUT" >&6; }
5707 else
5708   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5709 $as_echo "no" >&6; }
5710 fi
5711 
5712 
5713   test -n "$CUT" && break
5714 done
5715 
5716   else
5717     # The variable is set, but is it from the command line or the environment?
5718 
5719     # Try to remove the string !CUT! from our list.
5720     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CUT!/}
5721     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5722       # If it failed, the variable was not from the command line. Ignore it,
5723       # but warn the user (except for BASH, which is always set by the calling BASH).
5724       if test "xCUT" != xBASH; then
5725         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&5
5726 $as_echo "$as_me: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&2;}
5727       fi
5728       # Try to locate tool using the code snippet
5729       for ac_prog in cut
5730 do
5731   # Extract the first word of "$ac_prog", so it can be a program name with args.
5732 set dummy $ac_prog; ac_word=$2
5733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5734 $as_echo_n "checking for $ac_word... " >&6; }
5735 if ${ac_cv_path_CUT+:} false; then :
5736   $as_echo_n "(cached) " >&6
5737 else
5738   case $CUT in
5739   [\\/]* | ?:[\\/]*)
5740   ac_cv_path_CUT="$CUT" # Let the user override the test with a path.
5741   ;;
5742   *)
5743   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5744 for as_dir in $PATH
5745 do
5746   IFS=$as_save_IFS
5747   test -z "$as_dir" && as_dir=.
5748     for ac_exec_ext in '' $ac_executable_extensions; do
5749   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5750     ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext"
5751     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5752     break 2
5753   fi
5754 done
5755   done
5756 IFS=$as_save_IFS
5757 
5758   ;;
5759 esac
5760 fi
5761 CUT=$ac_cv_path_CUT
5762 if test -n "$CUT"; then
5763   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5
5764 $as_echo "$CUT" >&6; }
5765 else
5766   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5767 $as_echo "no" >&6; }
5768 fi
5769 
5770 
5771   test -n "$CUT" && break
5772 done
5773 
5774     else
5775       # If it succeeded, then it was overridden by the user. We will use it
5776       # for the tool.
5777 
5778       # First remove it from the list of overridden variables, so we can test
5779       # for unknown variables in the end.
5780       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5781 
5782       # Check if the provided tool contains a complete path.
5783       tool_specified="$CUT"
5784       tool_basename="${tool_specified##*/}"
5785       if test "x$tool_basename" = "x$tool_specified"; then
5786         # A command without a complete path is provided, search $PATH.
5787         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CUT=$tool_basename" >&5
5788 $as_echo "$as_me: Will search for user supplied tool CUT=$tool_basename" >&6;}
5789         # Extract the first word of "$tool_basename", so it can be a program name with args.
5790 set dummy $tool_basename; ac_word=$2
5791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5792 $as_echo_n "checking for $ac_word... " >&6; }
5793 if ${ac_cv_path_CUT+:} false; then :
5794   $as_echo_n "(cached) " >&6
5795 else
5796   case $CUT in
5797   [\\/]* | ?:[\\/]*)
5798   ac_cv_path_CUT="$CUT" # Let the user override the test with a path.
5799   ;;
5800   *)
5801   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5802 for as_dir in $PATH
5803 do
5804   IFS=$as_save_IFS
5805   test -z "$as_dir" && as_dir=.
5806     for ac_exec_ext in '' $ac_executable_extensions; do
5807   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5808     ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext"
5809     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5810     break 2
5811   fi
5812 done
5813   done
5814 IFS=$as_save_IFS
5815 
5816   ;;
5817 esac
5818 fi
5819 CUT=$ac_cv_path_CUT
5820 if test -n "$CUT"; then
5821   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5
5822 $as_echo "$CUT" >&6; }
5823 else
5824   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5825 $as_echo "no" >&6; }
5826 fi
5827 
5828 
5829         if test "x$CUT" = x; then
5830           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5831         fi
5832       else
5833         # Otherwise we believe it is a complete path. Use it as it is.
5834         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CUT=$tool_specified" >&5
5835 $as_echo "$as_me: Will use user supplied tool CUT=$tool_specified" >&6;}
5836         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5
5837 $as_echo_n "checking for CUT... " >&6; }
5838         if test ! -x "$tool_specified"; then
5839           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5840 $as_echo "not found" >&6; }
5841           as_fn_error $? "User supplied tool CUT=$tool_specified does not exist or is not executable" "$LINENO" 5
5842         fi
5843         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5844 $as_echo "$tool_specified" >&6; }
5845       fi
5846     fi
5847   fi
5848 
5849 
5850 
5851   if test "x$CUT" = x; then
5852     as_fn_error $? "Could not find required tool for CUT" "$LINENO" 5
5853   fi
5854 
5855 
5856 
5857 
5858 
5859   # Publish this variable in the help.
5860 
5861 
5862   if test "x$DATE" = x; then
5863     # The variable is not set by user, try to locate tool using the code snippet
5864     for ac_prog in date
5865 do
5866   # Extract the first word of "$ac_prog", so it can be a program name with args.
5867 set dummy $ac_prog; ac_word=$2
5868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5869 $as_echo_n "checking for $ac_word... " >&6; }
5870 if ${ac_cv_path_DATE+:} false; then :
5871   $as_echo_n "(cached) " >&6
5872 else
5873   case $DATE in
5874   [\\/]* | ?:[\\/]*)
5875   ac_cv_path_DATE="$DATE" # Let the user override the test with a path.
5876   ;;
5877   *)
5878   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5879 for as_dir in $PATH
5880 do
5881   IFS=$as_save_IFS
5882   test -z "$as_dir" && as_dir=.
5883     for ac_exec_ext in '' $ac_executable_extensions; do
5884   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5885     ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext"
5886     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5887     break 2
5888   fi
5889 done
5890   done
5891 IFS=$as_save_IFS
5892 
5893   ;;
5894 esac
5895 fi
5896 DATE=$ac_cv_path_DATE
5897 if test -n "$DATE"; then
5898   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5
5899 $as_echo "$DATE" >&6; }
5900 else
5901   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5902 $as_echo "no" >&6; }
5903 fi
5904 
5905 
5906   test -n "$DATE" && break
5907 done
5908 
5909   else
5910     # The variable is set, but is it from the command line or the environment?
5911 
5912     # Try to remove the string !DATE! from our list.
5913     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DATE!/}
5914     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5915       # If it failed, the variable was not from the command line. Ignore it,
5916       # but warn the user (except for BASH, which is always set by the calling BASH).
5917       if test "xDATE" != xBASH; then
5918         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&5
5919 $as_echo "$as_me: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&2;}
5920       fi
5921       # Try to locate tool using the code snippet
5922       for ac_prog in date
5923 do
5924   # Extract the first word of "$ac_prog", so it can be a program name with args.
5925 set dummy $ac_prog; ac_word=$2
5926 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5927 $as_echo_n "checking for $ac_word... " >&6; }
5928 if ${ac_cv_path_DATE+:} false; then :
5929   $as_echo_n "(cached) " >&6
5930 else
5931   case $DATE in
5932   [\\/]* | ?:[\\/]*)
5933   ac_cv_path_DATE="$DATE" # Let the user override the test with a path.
5934   ;;
5935   *)
5936   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5937 for as_dir in $PATH
5938 do
5939   IFS=$as_save_IFS
5940   test -z "$as_dir" && as_dir=.
5941     for ac_exec_ext in '' $ac_executable_extensions; do
5942   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5943     ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext"
5944     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5945     break 2
5946   fi
5947 done
5948   done
5949 IFS=$as_save_IFS
5950 
5951   ;;
5952 esac
5953 fi
5954 DATE=$ac_cv_path_DATE
5955 if test -n "$DATE"; then
5956   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5
5957 $as_echo "$DATE" >&6; }
5958 else
5959   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5960 $as_echo "no" >&6; }
5961 fi
5962 
5963 
5964   test -n "$DATE" && break
5965 done
5966 
5967     else
5968       # If it succeeded, then it was overridden by the user. We will use it
5969       # for the tool.
5970 
5971       # First remove it from the list of overridden variables, so we can test
5972       # for unknown variables in the end.
5973       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5974 
5975       # Check if the provided tool contains a complete path.
5976       tool_specified="$DATE"
5977       tool_basename="${tool_specified##*/}"
5978       if test "x$tool_basename" = "x$tool_specified"; then
5979         # A command without a complete path is provided, search $PATH.
5980         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DATE=$tool_basename" >&5
5981 $as_echo "$as_me: Will search for user supplied tool DATE=$tool_basename" >&6;}
5982         # Extract the first word of "$tool_basename", so it can be a program name with args.
5983 set dummy $tool_basename; ac_word=$2
5984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5985 $as_echo_n "checking for $ac_word... " >&6; }
5986 if ${ac_cv_path_DATE+:} false; then :
5987   $as_echo_n "(cached) " >&6
5988 else
5989   case $DATE in
5990   [\\/]* | ?:[\\/]*)
5991   ac_cv_path_DATE="$DATE" # Let the user override the test with a path.
5992   ;;
5993   *)
5994   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5995 for as_dir in $PATH
5996 do
5997   IFS=$as_save_IFS
5998   test -z "$as_dir" && as_dir=.
5999     for ac_exec_ext in '' $ac_executable_extensions; do
6000   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6001     ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext"
6002     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6003     break 2
6004   fi
6005 done
6006   done
6007 IFS=$as_save_IFS
6008 
6009   ;;
6010 esac
6011 fi
6012 DATE=$ac_cv_path_DATE
6013 if test -n "$DATE"; then
6014   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5
6015 $as_echo "$DATE" >&6; }
6016 else
6017   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6018 $as_echo "no" >&6; }
6019 fi
6020 
6021 
6022         if test "x$DATE" = x; then
6023           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6024         fi
6025       else
6026         # Otherwise we believe it is a complete path. Use it as it is.
6027         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DATE=$tool_specified" >&5
6028 $as_echo "$as_me: Will use user supplied tool DATE=$tool_specified" >&6;}
6029         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5
6030 $as_echo_n "checking for DATE... " >&6; }
6031         if test ! -x "$tool_specified"; then
6032           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6033 $as_echo "not found" >&6; }
6034           as_fn_error $? "User supplied tool DATE=$tool_specified does not exist or is not executable" "$LINENO" 5
6035         fi
6036         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6037 $as_echo "$tool_specified" >&6; }
6038       fi
6039     fi
6040   fi
6041 
6042 
6043 
6044   if test "x$DATE" = x; then
6045     as_fn_error $? "Could not find required tool for DATE" "$LINENO" 5
6046   fi
6047 
6048 
6049 
6050 
6051 
6052   # Publish this variable in the help.
6053 
6054 
6055   if test "x$DIFF" = x; then
6056     # The variable is not set by user, try to locate tool using the code snippet
6057     for ac_prog in gdiff diff
6058 do
6059   # Extract the first word of "$ac_prog", so it can be a program name with args.
6060 set dummy $ac_prog; ac_word=$2
6061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6062 $as_echo_n "checking for $ac_word... " >&6; }
6063 if ${ac_cv_path_DIFF+:} false; then :
6064   $as_echo_n "(cached) " >&6
6065 else
6066   case $DIFF in
6067   [\\/]* | ?:[\\/]*)
6068   ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path.
6069   ;;
6070   *)
6071   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6072 for as_dir in $PATH
6073 do
6074   IFS=$as_save_IFS
6075   test -z "$as_dir" && as_dir=.
6076     for ac_exec_ext in '' $ac_executable_extensions; do
6077   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6078     ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext"
6079     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6080     break 2
6081   fi
6082 done
6083   done
6084 IFS=$as_save_IFS
6085 
6086   ;;
6087 esac
6088 fi
6089 DIFF=$ac_cv_path_DIFF
6090 if test -n "$DIFF"; then
6091   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5
6092 $as_echo "$DIFF" >&6; }
6093 else
6094   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6095 $as_echo "no" >&6; }
6096 fi
6097 
6098 
6099   test -n "$DIFF" && break
6100 done
6101 
6102   else
6103     # The variable is set, but is it from the command line or the environment?
6104 
6105     # Try to remove the string !DIFF! from our list.
6106     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIFF!/}
6107     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6108       # If it failed, the variable was not from the command line. Ignore it,
6109       # but warn the user (except for BASH, which is always set by the calling BASH).
6110       if test "xDIFF" != xBASH; then
6111         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&5
6112 $as_echo "$as_me: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&2;}
6113       fi
6114       # Try to locate tool using the code snippet
6115       for ac_prog in gdiff diff
6116 do
6117   # Extract the first word of "$ac_prog", so it can be a program name with args.
6118 set dummy $ac_prog; ac_word=$2
6119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6120 $as_echo_n "checking for $ac_word... " >&6; }
6121 if ${ac_cv_path_DIFF+:} false; then :
6122   $as_echo_n "(cached) " >&6
6123 else
6124   case $DIFF in
6125   [\\/]* | ?:[\\/]*)
6126   ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path.
6127   ;;
6128   *)
6129   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6130 for as_dir in $PATH
6131 do
6132   IFS=$as_save_IFS
6133   test -z "$as_dir" && as_dir=.
6134     for ac_exec_ext in '' $ac_executable_extensions; do
6135   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6136     ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext"
6137     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6138     break 2
6139   fi
6140 done
6141   done
6142 IFS=$as_save_IFS
6143 
6144   ;;
6145 esac
6146 fi
6147 DIFF=$ac_cv_path_DIFF
6148 if test -n "$DIFF"; then
6149   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5
6150 $as_echo "$DIFF" >&6; }
6151 else
6152   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6153 $as_echo "no" >&6; }
6154 fi
6155 
6156 
6157   test -n "$DIFF" && break
6158 done
6159 
6160     else
6161       # If it succeeded, then it was overridden by the user. We will use it
6162       # for the tool.
6163 
6164       # First remove it from the list of overridden variables, so we can test
6165       # for unknown variables in the end.
6166       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6167 
6168       # Check if the provided tool contains a complete path.
6169       tool_specified="$DIFF"
6170       tool_basename="${tool_specified##*/}"
6171       if test "x$tool_basename" = "x$tool_specified"; then
6172         # A command without a complete path is provided, search $PATH.
6173         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIFF=$tool_basename" >&5
6174 $as_echo "$as_me: Will search for user supplied tool DIFF=$tool_basename" >&6;}
6175         # Extract the first word of "$tool_basename", so it can be a program name with args.
6176 set dummy $tool_basename; ac_word=$2
6177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6178 $as_echo_n "checking for $ac_word... " >&6; }
6179 if ${ac_cv_path_DIFF+:} false; then :
6180   $as_echo_n "(cached) " >&6
6181 else
6182   case $DIFF in
6183   [\\/]* | ?:[\\/]*)
6184   ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path.
6185   ;;
6186   *)
6187   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6188 for as_dir in $PATH
6189 do
6190   IFS=$as_save_IFS
6191   test -z "$as_dir" && as_dir=.
6192     for ac_exec_ext in '' $ac_executable_extensions; do
6193   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6194     ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext"
6195     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6196     break 2
6197   fi
6198 done
6199   done
6200 IFS=$as_save_IFS
6201 
6202   ;;
6203 esac
6204 fi
6205 DIFF=$ac_cv_path_DIFF
6206 if test -n "$DIFF"; then
6207   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5
6208 $as_echo "$DIFF" >&6; }
6209 else
6210   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6211 $as_echo "no" >&6; }
6212 fi
6213 
6214 
6215         if test "x$DIFF" = x; then
6216           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6217         fi
6218       else
6219         # Otherwise we believe it is a complete path. Use it as it is.
6220         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIFF=$tool_specified" >&5
6221 $as_echo "$as_me: Will use user supplied tool DIFF=$tool_specified" >&6;}
6222         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5
6223 $as_echo_n "checking for DIFF... " >&6; }
6224         if test ! -x "$tool_specified"; then
6225           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6226 $as_echo "not found" >&6; }
6227           as_fn_error $? "User supplied tool DIFF=$tool_specified does not exist or is not executable" "$LINENO" 5
6228         fi
6229         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6230 $as_echo "$tool_specified" >&6; }
6231       fi
6232     fi
6233   fi
6234 
6235 
6236 
6237   if test "x$DIFF" = x; then
6238     as_fn_error $? "Could not find required tool for DIFF" "$LINENO" 5
6239   fi
6240 
6241 
6242 
6243 
6244 
6245   # Publish this variable in the help.
6246 
6247 
6248   if test "x$DIRNAME" = x; then
6249     # The variable is not set by user, try to locate tool using the code snippet
6250     for ac_prog in dirname
6251 do
6252   # Extract the first word of "$ac_prog", so it can be a program name with args.
6253 set dummy $ac_prog; ac_word=$2
6254 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6255 $as_echo_n "checking for $ac_word... " >&6; }
6256 if ${ac_cv_path_DIRNAME+:} false; then :
6257   $as_echo_n "(cached) " >&6
6258 else
6259   case $DIRNAME in
6260   [\\/]* | ?:[\\/]*)
6261   ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
6262   ;;
6263   *)
6264   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6265 for as_dir in $PATH
6266 do
6267   IFS=$as_save_IFS
6268   test -z "$as_dir" && as_dir=.
6269     for ac_exec_ext in '' $ac_executable_extensions; do
6270   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6271     ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
6272     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6273     break 2
6274   fi
6275 done
6276   done
6277 IFS=$as_save_IFS
6278 
6279   ;;
6280 esac
6281 fi
6282 DIRNAME=$ac_cv_path_DIRNAME
6283 if test -n "$DIRNAME"; then
6284   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
6285 $as_echo "$DIRNAME" >&6; }
6286 else
6287   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6288 $as_echo "no" >&6; }
6289 fi
6290 
6291 
6292   test -n "$DIRNAME" && break
6293 done
6294 
6295   else
6296     # The variable is set, but is it from the command line or the environment?
6297 
6298     # Try to remove the string !DIRNAME! from our list.
6299     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIRNAME!/}
6300     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6301       # If it failed, the variable was not from the command line. Ignore it,
6302       # but warn the user (except for BASH, which is always set by the calling BASH).
6303       if test "xDIRNAME" != xBASH; then
6304         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&5
6305 $as_echo "$as_me: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&2;}
6306       fi
6307       # Try to locate tool using the code snippet
6308       for ac_prog in dirname
6309 do
6310   # Extract the first word of "$ac_prog", so it can be a program name with args.
6311 set dummy $ac_prog; ac_word=$2
6312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6313 $as_echo_n "checking for $ac_word... " >&6; }
6314 if ${ac_cv_path_DIRNAME+:} false; then :
6315   $as_echo_n "(cached) " >&6
6316 else
6317   case $DIRNAME in
6318   [\\/]* | ?:[\\/]*)
6319   ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
6320   ;;
6321   *)
6322   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6323 for as_dir in $PATH
6324 do
6325   IFS=$as_save_IFS
6326   test -z "$as_dir" && as_dir=.
6327     for ac_exec_ext in '' $ac_executable_extensions; do
6328   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6329     ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
6330     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6331     break 2
6332   fi
6333 done
6334   done
6335 IFS=$as_save_IFS
6336 
6337   ;;
6338 esac
6339 fi
6340 DIRNAME=$ac_cv_path_DIRNAME
6341 if test -n "$DIRNAME"; then
6342   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
6343 $as_echo "$DIRNAME" >&6; }
6344 else
6345   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6346 $as_echo "no" >&6; }
6347 fi
6348 
6349 
6350   test -n "$DIRNAME" && break
6351 done
6352 
6353     else
6354       # If it succeeded, then it was overridden by the user. We will use it
6355       # for the tool.
6356 
6357       # First remove it from the list of overridden variables, so we can test
6358       # for unknown variables in the end.
6359       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6360 
6361       # Check if the provided tool contains a complete path.
6362       tool_specified="$DIRNAME"
6363       tool_basename="${tool_specified##*/}"
6364       if test "x$tool_basename" = "x$tool_specified"; then
6365         # A command without a complete path is provided, search $PATH.
6366         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIRNAME=$tool_basename" >&5
6367 $as_echo "$as_me: Will search for user supplied tool DIRNAME=$tool_basename" >&6;}
6368         # Extract the first word of "$tool_basename", so it can be a program name with args.
6369 set dummy $tool_basename; ac_word=$2
6370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6371 $as_echo_n "checking for $ac_word... " >&6; }
6372 if ${ac_cv_path_DIRNAME+:} false; then :
6373   $as_echo_n "(cached) " >&6
6374 else
6375   case $DIRNAME in
6376   [\\/]* | ?:[\\/]*)
6377   ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
6378   ;;
6379   *)
6380   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6381 for as_dir in $PATH
6382 do
6383   IFS=$as_save_IFS
6384   test -z "$as_dir" && as_dir=.
6385     for ac_exec_ext in '' $ac_executable_extensions; do
6386   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6387     ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
6388     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6389     break 2
6390   fi
6391 done
6392   done
6393 IFS=$as_save_IFS
6394 
6395   ;;
6396 esac
6397 fi
6398 DIRNAME=$ac_cv_path_DIRNAME
6399 if test -n "$DIRNAME"; then
6400   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
6401 $as_echo "$DIRNAME" >&6; }
6402 else
6403   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6404 $as_echo "no" >&6; }
6405 fi
6406 
6407 
6408         if test "x$DIRNAME" = x; then
6409           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6410         fi
6411       else
6412         # Otherwise we believe it is a complete path. Use it as it is.
6413         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIRNAME=$tool_specified" >&5
6414 $as_echo "$as_me: Will use user supplied tool DIRNAME=$tool_specified" >&6;}
6415         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5
6416 $as_echo_n "checking for DIRNAME... " >&6; }
6417         if test ! -x "$tool_specified"; then
6418           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6419 $as_echo "not found" >&6; }
6420           as_fn_error $? "User supplied tool DIRNAME=$tool_specified does not exist or is not executable" "$LINENO" 5
6421         fi
6422         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6423 $as_echo "$tool_specified" >&6; }
6424       fi
6425     fi
6426   fi
6427 
6428 
6429 
6430   if test "x$DIRNAME" = x; then
6431     as_fn_error $? "Could not find required tool for DIRNAME" "$LINENO" 5
6432   fi
6433 
6434 
6435 
6436 
6437 
6438   # Publish this variable in the help.
6439 
6440 
6441   if test "x$ECHO" = x; then
6442     # The variable is not set by user, try to locate tool using the code snippet
6443     for ac_prog in echo
6444 do
6445   # Extract the first word of "$ac_prog", so it can be a program name with args.
6446 set dummy $ac_prog; ac_word=$2
6447 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6448 $as_echo_n "checking for $ac_word... " >&6; }
6449 if ${ac_cv_path_ECHO+:} false; then :
6450   $as_echo_n "(cached) " >&6
6451 else
6452   case $ECHO in
6453   [\\/]* | ?:[\\/]*)
6454   ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path.
6455   ;;
6456   *)
6457   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6458 for as_dir in $PATH
6459 do
6460   IFS=$as_save_IFS
6461   test -z "$as_dir" && as_dir=.
6462     for ac_exec_ext in '' $ac_executable_extensions; do
6463   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6464     ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext"
6465     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6466     break 2
6467   fi
6468 done
6469   done
6470 IFS=$as_save_IFS
6471 
6472   ;;
6473 esac
6474 fi
6475 ECHO=$ac_cv_path_ECHO
6476 if test -n "$ECHO"; then
6477   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5
6478 $as_echo "$ECHO" >&6; }
6479 else
6480   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6481 $as_echo "no" >&6; }
6482 fi
6483 
6484 
6485   test -n "$ECHO" && break
6486 done
6487 
6488   else
6489     # The variable is set, but is it from the command line or the environment?
6490 
6491     # Try to remove the string !ECHO! from our list.
6492     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ECHO!/}
6493     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6494       # If it failed, the variable was not from the command line. Ignore it,
6495       # but warn the user (except for BASH, which is always set by the calling BASH).
6496       if test "xECHO" != xBASH; then
6497         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&5
6498 $as_echo "$as_me: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&2;}
6499       fi
6500       # Try to locate tool using the code snippet
6501       for ac_prog in echo
6502 do
6503   # Extract the first word of "$ac_prog", so it can be a program name with args.
6504 set dummy $ac_prog; ac_word=$2
6505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6506 $as_echo_n "checking for $ac_word... " >&6; }
6507 if ${ac_cv_path_ECHO+:} false; then :
6508   $as_echo_n "(cached) " >&6
6509 else
6510   case $ECHO in
6511   [\\/]* | ?:[\\/]*)
6512   ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path.
6513   ;;
6514   *)
6515   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6516 for as_dir in $PATH
6517 do
6518   IFS=$as_save_IFS
6519   test -z "$as_dir" && as_dir=.
6520     for ac_exec_ext in '' $ac_executable_extensions; do
6521   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6522     ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext"
6523     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6524     break 2
6525   fi
6526 done
6527   done
6528 IFS=$as_save_IFS
6529 
6530   ;;
6531 esac
6532 fi
6533 ECHO=$ac_cv_path_ECHO
6534 if test -n "$ECHO"; then
6535   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5
6536 $as_echo "$ECHO" >&6; }
6537 else
6538   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6539 $as_echo "no" >&6; }
6540 fi
6541 
6542 
6543   test -n "$ECHO" && break
6544 done
6545 
6546     else
6547       # If it succeeded, then it was overridden by the user. We will use it
6548       # for the tool.
6549 
6550       # First remove it from the list of overridden variables, so we can test
6551       # for unknown variables in the end.
6552       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6553 
6554       # Check if the provided tool contains a complete path.
6555       tool_specified="$ECHO"
6556       tool_basename="${tool_specified##*/}"
6557       if test "x$tool_basename" = "x$tool_specified"; then
6558         # A command without a complete path is provided, search $PATH.
6559         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ECHO=$tool_basename" >&5
6560 $as_echo "$as_me: Will search for user supplied tool ECHO=$tool_basename" >&6;}
6561         # Extract the first word of "$tool_basename", so it can be a program name with args.
6562 set dummy $tool_basename; ac_word=$2
6563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6564 $as_echo_n "checking for $ac_word... " >&6; }
6565 if ${ac_cv_path_ECHO+:} false; then :
6566   $as_echo_n "(cached) " >&6
6567 else
6568   case $ECHO in
6569   [\\/]* | ?:[\\/]*)
6570   ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path.
6571   ;;
6572   *)
6573   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6574 for as_dir in $PATH
6575 do
6576   IFS=$as_save_IFS
6577   test -z "$as_dir" && as_dir=.
6578     for ac_exec_ext in '' $ac_executable_extensions; do
6579   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6580     ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext"
6581     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6582     break 2
6583   fi
6584 done
6585   done
6586 IFS=$as_save_IFS
6587 
6588   ;;
6589 esac
6590 fi
6591 ECHO=$ac_cv_path_ECHO
6592 if test -n "$ECHO"; then
6593   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5
6594 $as_echo "$ECHO" >&6; }
6595 else
6596   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6597 $as_echo "no" >&6; }
6598 fi
6599 
6600 
6601         if test "x$ECHO" = x; then
6602           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6603         fi
6604       else
6605         # Otherwise we believe it is a complete path. Use it as it is.
6606         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ECHO=$tool_specified" >&5
6607 $as_echo "$as_me: Will use user supplied tool ECHO=$tool_specified" >&6;}
6608         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5
6609 $as_echo_n "checking for ECHO... " >&6; }
6610         if test ! -x "$tool_specified"; then
6611           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6612 $as_echo "not found" >&6; }
6613           as_fn_error $? "User supplied tool ECHO=$tool_specified does not exist or is not executable" "$LINENO" 5
6614         fi
6615         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6616 $as_echo "$tool_specified" >&6; }
6617       fi
6618     fi
6619   fi
6620 
6621 
6622 
6623   if test "x$ECHO" = x; then
6624     as_fn_error $? "Could not find required tool for ECHO" "$LINENO" 5
6625   fi
6626 
6627 
6628 
6629 
6630 
6631   # Publish this variable in the help.
6632 
6633 
6634   if test "x$EXPR" = x; then
6635     # The variable is not set by user, try to locate tool using the code snippet
6636     for ac_prog in expr
6637 do
6638   # Extract the first word of "$ac_prog", so it can be a program name with args.
6639 set dummy $ac_prog; ac_word=$2
6640 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6641 $as_echo_n "checking for $ac_word... " >&6; }
6642 if ${ac_cv_path_EXPR+:} false; then :
6643   $as_echo_n "(cached) " >&6
6644 else
6645   case $EXPR in
6646   [\\/]* | ?:[\\/]*)
6647   ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path.
6648   ;;
6649   *)
6650   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6651 for as_dir in $PATH
6652 do
6653   IFS=$as_save_IFS
6654   test -z "$as_dir" && as_dir=.
6655     for ac_exec_ext in '' $ac_executable_extensions; do
6656   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6657     ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext"
6658     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6659     break 2
6660   fi
6661 done
6662   done
6663 IFS=$as_save_IFS
6664 
6665   ;;
6666 esac
6667 fi
6668 EXPR=$ac_cv_path_EXPR
6669 if test -n "$EXPR"; then
6670   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5
6671 $as_echo "$EXPR" >&6; }
6672 else
6673   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6674 $as_echo "no" >&6; }
6675 fi
6676 
6677 
6678   test -n "$EXPR" && break
6679 done
6680 
6681   else
6682     # The variable is set, but is it from the command line or the environment?
6683 
6684     # Try to remove the string !EXPR! from our list.
6685     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EXPR!/}
6686     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6687       # If it failed, the variable was not from the command line. Ignore it,
6688       # but warn the user (except for BASH, which is always set by the calling BASH).
6689       if test "xEXPR" != xBASH; then
6690         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&5
6691 $as_echo "$as_me: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&2;}
6692       fi
6693       # Try to locate tool using the code snippet
6694       for ac_prog in expr
6695 do
6696   # Extract the first word of "$ac_prog", so it can be a program name with args.
6697 set dummy $ac_prog; ac_word=$2
6698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6699 $as_echo_n "checking for $ac_word... " >&6; }
6700 if ${ac_cv_path_EXPR+:} false; then :
6701   $as_echo_n "(cached) " >&6
6702 else
6703   case $EXPR in
6704   [\\/]* | ?:[\\/]*)
6705   ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path.
6706   ;;
6707   *)
6708   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6709 for as_dir in $PATH
6710 do
6711   IFS=$as_save_IFS
6712   test -z "$as_dir" && as_dir=.
6713     for ac_exec_ext in '' $ac_executable_extensions; do
6714   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6715     ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext"
6716     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6717     break 2
6718   fi
6719 done
6720   done
6721 IFS=$as_save_IFS
6722 
6723   ;;
6724 esac
6725 fi
6726 EXPR=$ac_cv_path_EXPR
6727 if test -n "$EXPR"; then
6728   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5
6729 $as_echo "$EXPR" >&6; }
6730 else
6731   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6732 $as_echo "no" >&6; }
6733 fi
6734 
6735 
6736   test -n "$EXPR" && break
6737 done
6738 
6739     else
6740       # If it succeeded, then it was overridden by the user. We will use it
6741       # for the tool.
6742 
6743       # First remove it from the list of overridden variables, so we can test
6744       # for unknown variables in the end.
6745       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6746 
6747       # Check if the provided tool contains a complete path.
6748       tool_specified="$EXPR"
6749       tool_basename="${tool_specified##*/}"
6750       if test "x$tool_basename" = "x$tool_specified"; then
6751         # A command without a complete path is provided, search $PATH.
6752         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EXPR=$tool_basename" >&5
6753 $as_echo "$as_me: Will search for user supplied tool EXPR=$tool_basename" >&6;}
6754         # Extract the first word of "$tool_basename", so it can be a program name with args.
6755 set dummy $tool_basename; ac_word=$2
6756 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6757 $as_echo_n "checking for $ac_word... " >&6; }
6758 if ${ac_cv_path_EXPR+:} false; then :
6759   $as_echo_n "(cached) " >&6
6760 else
6761   case $EXPR in
6762   [\\/]* | ?:[\\/]*)
6763   ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path.
6764   ;;
6765   *)
6766   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6767 for as_dir in $PATH
6768 do
6769   IFS=$as_save_IFS
6770   test -z "$as_dir" && as_dir=.
6771     for ac_exec_ext in '' $ac_executable_extensions; do
6772   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6773     ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext"
6774     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6775     break 2
6776   fi
6777 done
6778   done
6779 IFS=$as_save_IFS
6780 
6781   ;;
6782 esac
6783 fi
6784 EXPR=$ac_cv_path_EXPR
6785 if test -n "$EXPR"; then
6786   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5
6787 $as_echo "$EXPR" >&6; }
6788 else
6789   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6790 $as_echo "no" >&6; }
6791 fi
6792 
6793 
6794         if test "x$EXPR" = x; then
6795           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6796         fi
6797       else
6798         # Otherwise we believe it is a complete path. Use it as it is.
6799         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EXPR=$tool_specified" >&5
6800 $as_echo "$as_me: Will use user supplied tool EXPR=$tool_specified" >&6;}
6801         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5
6802 $as_echo_n "checking for EXPR... " >&6; }
6803         if test ! -x "$tool_specified"; then
6804           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6805 $as_echo "not found" >&6; }
6806           as_fn_error $? "User supplied tool EXPR=$tool_specified does not exist or is not executable" "$LINENO" 5
6807         fi
6808         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6809 $as_echo "$tool_specified" >&6; }
6810       fi
6811     fi
6812   fi
6813 
6814 
6815 
6816   if test "x$EXPR" = x; then
6817     as_fn_error $? "Could not find required tool for EXPR" "$LINENO" 5
6818   fi
6819 
6820 
6821 
6822 
6823 
6824   # Publish this variable in the help.
6825 
6826 
6827   if test "x$FILE" = x; then
6828     # The variable is not set by user, try to locate tool using the code snippet
6829     for ac_prog in file
6830 do
6831   # Extract the first word of "$ac_prog", so it can be a program name with args.
6832 set dummy $ac_prog; ac_word=$2
6833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6834 $as_echo_n "checking for $ac_word... " >&6; }
6835 if ${ac_cv_path_FILE+:} false; then :
6836   $as_echo_n "(cached) " >&6
6837 else
6838   case $FILE in
6839   [\\/]* | ?:[\\/]*)
6840   ac_cv_path_FILE="$FILE" # Let the user override the test with a path.
6841   ;;
6842   *)
6843   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6844 for as_dir in $PATH
6845 do
6846   IFS=$as_save_IFS
6847   test -z "$as_dir" && as_dir=.
6848     for ac_exec_ext in '' $ac_executable_extensions; do
6849   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6850     ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext"
6851     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6852     break 2
6853   fi
6854 done
6855   done
6856 IFS=$as_save_IFS
6857 
6858   ;;
6859 esac
6860 fi
6861 FILE=$ac_cv_path_FILE
6862 if test -n "$FILE"; then
6863   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5
6864 $as_echo "$FILE" >&6; }
6865 else
6866   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6867 $as_echo "no" >&6; }
6868 fi
6869 
6870 
6871   test -n "$FILE" && break
6872 done
6873 
6874   else
6875     # The variable is set, but is it from the command line or the environment?
6876 
6877     # Try to remove the string !FILE! from our list.
6878     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FILE!/}
6879     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6880       # If it failed, the variable was not from the command line. Ignore it,
6881       # but warn the user (except for BASH, which is always set by the calling BASH).
6882       if test "xFILE" != xBASH; then
6883         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&5
6884 $as_echo "$as_me: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&2;}
6885       fi
6886       # Try to locate tool using the code snippet
6887       for ac_prog in file
6888 do
6889   # Extract the first word of "$ac_prog", so it can be a program name with args.
6890 set dummy $ac_prog; ac_word=$2
6891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6892 $as_echo_n "checking for $ac_word... " >&6; }
6893 if ${ac_cv_path_FILE+:} false; then :
6894   $as_echo_n "(cached) " >&6
6895 else
6896   case $FILE in
6897   [\\/]* | ?:[\\/]*)
6898   ac_cv_path_FILE="$FILE" # Let the user override the test with a path.
6899   ;;
6900   *)
6901   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6902 for as_dir in $PATH
6903 do
6904   IFS=$as_save_IFS
6905   test -z "$as_dir" && as_dir=.
6906     for ac_exec_ext in '' $ac_executable_extensions; do
6907   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6908     ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext"
6909     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6910     break 2
6911   fi
6912 done
6913   done
6914 IFS=$as_save_IFS
6915 
6916   ;;
6917 esac
6918 fi
6919 FILE=$ac_cv_path_FILE
6920 if test -n "$FILE"; then
6921   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5
6922 $as_echo "$FILE" >&6; }
6923 else
6924   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6925 $as_echo "no" >&6; }
6926 fi
6927 
6928 
6929   test -n "$FILE" && break
6930 done
6931 
6932     else
6933       # If it succeeded, then it was overridden by the user. We will use it
6934       # for the tool.
6935 
6936       # First remove it from the list of overridden variables, so we can test
6937       # for unknown variables in the end.
6938       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6939 
6940       # Check if the provided tool contains a complete path.
6941       tool_specified="$FILE"
6942       tool_basename="${tool_specified##*/}"
6943       if test "x$tool_basename" = "x$tool_specified"; then
6944         # A command without a complete path is provided, search $PATH.
6945         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FILE=$tool_basename" >&5
6946 $as_echo "$as_me: Will search for user supplied tool FILE=$tool_basename" >&6;}
6947         # Extract the first word of "$tool_basename", so it can be a program name with args.
6948 set dummy $tool_basename; ac_word=$2
6949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6950 $as_echo_n "checking for $ac_word... " >&6; }
6951 if ${ac_cv_path_FILE+:} false; then :
6952   $as_echo_n "(cached) " >&6
6953 else
6954   case $FILE in
6955   [\\/]* | ?:[\\/]*)
6956   ac_cv_path_FILE="$FILE" # Let the user override the test with a path.
6957   ;;
6958   *)
6959   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6960 for as_dir in $PATH
6961 do
6962   IFS=$as_save_IFS
6963   test -z "$as_dir" && as_dir=.
6964     for ac_exec_ext in '' $ac_executable_extensions; do
6965   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6966     ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext"
6967     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6968     break 2
6969   fi
6970 done
6971   done
6972 IFS=$as_save_IFS
6973 
6974   ;;
6975 esac
6976 fi
6977 FILE=$ac_cv_path_FILE
6978 if test -n "$FILE"; then
6979   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5
6980 $as_echo "$FILE" >&6; }
6981 else
6982   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6983 $as_echo "no" >&6; }
6984 fi
6985 
6986 
6987         if test "x$FILE" = x; then
6988           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6989         fi
6990       else
6991         # Otherwise we believe it is a complete path. Use it as it is.
6992         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FILE=$tool_specified" >&5
6993 $as_echo "$as_me: Will use user supplied tool FILE=$tool_specified" >&6;}
6994         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5
6995 $as_echo_n "checking for FILE... " >&6; }
6996         if test ! -x "$tool_specified"; then
6997           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6998 $as_echo "not found" >&6; }
6999           as_fn_error $? "User supplied tool FILE=$tool_specified does not exist or is not executable" "$LINENO" 5
7000         fi
7001         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7002 $as_echo "$tool_specified" >&6; }
7003       fi
7004     fi
7005   fi
7006 
7007 
7008 
7009   if test "x$FILE" = x; then
7010     as_fn_error $? "Could not find required tool for FILE" "$LINENO" 5
7011   fi
7012 
7013 
7014 
7015 
7016 
7017   # Publish this variable in the help.
7018 
7019 
7020   if test "x$FIND" = x; then
7021     # The variable is not set by user, try to locate tool using the code snippet
7022     for ac_prog in find
7023 do
7024   # Extract the first word of "$ac_prog", so it can be a program name with args.
7025 set dummy $ac_prog; ac_word=$2
7026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7027 $as_echo_n "checking for $ac_word... " >&6; }
7028 if ${ac_cv_path_FIND+:} false; then :
7029   $as_echo_n "(cached) " >&6
7030 else
7031   case $FIND in
7032   [\\/]* | ?:[\\/]*)
7033   ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
7034   ;;
7035   *)
7036   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7037 for as_dir in $PATH
7038 do
7039   IFS=$as_save_IFS
7040   test -z "$as_dir" && as_dir=.
7041     for ac_exec_ext in '' $ac_executable_extensions; do
7042   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7043     ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
7044     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7045     break 2
7046   fi
7047 done
7048   done
7049 IFS=$as_save_IFS
7050 
7051   ;;
7052 esac
7053 fi
7054 FIND=$ac_cv_path_FIND
7055 if test -n "$FIND"; then
7056   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
7057 $as_echo "$FIND" >&6; }
7058 else
7059   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7060 $as_echo "no" >&6; }
7061 fi
7062 
7063 
7064   test -n "$FIND" && break
7065 done
7066 
7067   else
7068     # The variable is set, but is it from the command line or the environment?
7069 
7070     # Try to remove the string !FIND! from our list.
7071     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FIND!/}
7072     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7073       # If it failed, the variable was not from the command line. Ignore it,
7074       # but warn the user (except for BASH, which is always set by the calling BASH).
7075       if test "xFIND" != xBASH; then
7076         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&5
7077 $as_echo "$as_me: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&2;}
7078       fi
7079       # Try to locate tool using the code snippet
7080       for ac_prog in find
7081 do
7082   # Extract the first word of "$ac_prog", so it can be a program name with args.
7083 set dummy $ac_prog; ac_word=$2
7084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7085 $as_echo_n "checking for $ac_word... " >&6; }
7086 if ${ac_cv_path_FIND+:} false; then :
7087   $as_echo_n "(cached) " >&6
7088 else
7089   case $FIND in
7090   [\\/]* | ?:[\\/]*)
7091   ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
7092   ;;
7093   *)
7094   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7095 for as_dir in $PATH
7096 do
7097   IFS=$as_save_IFS
7098   test -z "$as_dir" && as_dir=.
7099     for ac_exec_ext in '' $ac_executable_extensions; do
7100   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7101     ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
7102     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7103     break 2
7104   fi
7105 done
7106   done
7107 IFS=$as_save_IFS
7108 
7109   ;;
7110 esac
7111 fi
7112 FIND=$ac_cv_path_FIND
7113 if test -n "$FIND"; then
7114   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
7115 $as_echo "$FIND" >&6; }
7116 else
7117   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7118 $as_echo "no" >&6; }
7119 fi
7120 
7121 
7122   test -n "$FIND" && break
7123 done
7124 
7125     else
7126       # If it succeeded, then it was overridden by the user. We will use it
7127       # for the tool.
7128 
7129       # First remove it from the list of overridden variables, so we can test
7130       # for unknown variables in the end.
7131       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7132 
7133       # Check if the provided tool contains a complete path.
7134       tool_specified="$FIND"
7135       tool_basename="${tool_specified##*/}"
7136       if test "x$tool_basename" = "x$tool_specified"; then
7137         # A command without a complete path is provided, search $PATH.
7138         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FIND=$tool_basename" >&5
7139 $as_echo "$as_me: Will search for user supplied tool FIND=$tool_basename" >&6;}
7140         # Extract the first word of "$tool_basename", so it can be a program name with args.
7141 set dummy $tool_basename; ac_word=$2
7142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7143 $as_echo_n "checking for $ac_word... " >&6; }
7144 if ${ac_cv_path_FIND+:} false; then :
7145   $as_echo_n "(cached) " >&6
7146 else
7147   case $FIND in
7148   [\\/]* | ?:[\\/]*)
7149   ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
7150   ;;
7151   *)
7152   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7153 for as_dir in $PATH
7154 do
7155   IFS=$as_save_IFS
7156   test -z "$as_dir" && as_dir=.
7157     for ac_exec_ext in '' $ac_executable_extensions; do
7158   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7159     ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
7160     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7161     break 2
7162   fi
7163 done
7164   done
7165 IFS=$as_save_IFS
7166 
7167   ;;
7168 esac
7169 fi
7170 FIND=$ac_cv_path_FIND
7171 if test -n "$FIND"; then
7172   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
7173 $as_echo "$FIND" >&6; }
7174 else
7175   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7176 $as_echo "no" >&6; }
7177 fi
7178 
7179 
7180         if test "x$FIND" = x; then
7181           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7182         fi
7183       else
7184         # Otherwise we believe it is a complete path. Use it as it is.
7185         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FIND=$tool_specified" >&5
7186 $as_echo "$as_me: Will use user supplied tool FIND=$tool_specified" >&6;}
7187         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5
7188 $as_echo_n "checking for FIND... " >&6; }
7189         if test ! -x "$tool_specified"; then
7190           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7191 $as_echo "not found" >&6; }
7192           as_fn_error $? "User supplied tool FIND=$tool_specified does not exist or is not executable" "$LINENO" 5
7193         fi
7194         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7195 $as_echo "$tool_specified" >&6; }
7196       fi
7197     fi
7198   fi
7199 
7200 
7201 
7202   if test "x$FIND" = x; then
7203     as_fn_error $? "Could not find required tool for FIND" "$LINENO" 5
7204   fi
7205 
7206 
7207 
7208 
7209 
7210   # Publish this variable in the help.
7211 
7212 
7213   if test "x$HEAD" = x; then
7214     # The variable is not set by user, try to locate tool using the code snippet
7215     for ac_prog in head
7216 do
7217   # Extract the first word of "$ac_prog", so it can be a program name with args.
7218 set dummy $ac_prog; ac_word=$2
7219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7220 $as_echo_n "checking for $ac_word... " >&6; }
7221 if ${ac_cv_path_HEAD+:} false; then :
7222   $as_echo_n "(cached) " >&6
7223 else
7224   case $HEAD in
7225   [\\/]* | ?:[\\/]*)
7226   ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path.
7227   ;;
7228   *)
7229   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7230 for as_dir in $PATH
7231 do
7232   IFS=$as_save_IFS
7233   test -z "$as_dir" && as_dir=.
7234     for ac_exec_ext in '' $ac_executable_extensions; do
7235   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7236     ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext"
7237     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7238     break 2
7239   fi
7240 done
7241   done
7242 IFS=$as_save_IFS
7243 
7244   ;;
7245 esac
7246 fi
7247 HEAD=$ac_cv_path_HEAD
7248 if test -n "$HEAD"; then
7249   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5
7250 $as_echo "$HEAD" >&6; }
7251 else
7252   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7253 $as_echo "no" >&6; }
7254 fi
7255 
7256 
7257   test -n "$HEAD" && break
7258 done
7259 
7260   else
7261     # The variable is set, but is it from the command line or the environment?
7262 
7263     # Try to remove the string !HEAD! from our list.
7264     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HEAD!/}
7265     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7266       # If it failed, the variable was not from the command line. Ignore it,
7267       # but warn the user (except for BASH, which is always set by the calling BASH).
7268       if test "xHEAD" != xBASH; then
7269         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&5
7270 $as_echo "$as_me: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&2;}
7271       fi
7272       # Try to locate tool using the code snippet
7273       for ac_prog in head
7274 do
7275   # Extract the first word of "$ac_prog", so it can be a program name with args.
7276 set dummy $ac_prog; ac_word=$2
7277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7278 $as_echo_n "checking for $ac_word... " >&6; }
7279 if ${ac_cv_path_HEAD+:} false; then :
7280   $as_echo_n "(cached) " >&6
7281 else
7282   case $HEAD in
7283   [\\/]* | ?:[\\/]*)
7284   ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path.
7285   ;;
7286   *)
7287   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7288 for as_dir in $PATH
7289 do
7290   IFS=$as_save_IFS
7291   test -z "$as_dir" && as_dir=.
7292     for ac_exec_ext in '' $ac_executable_extensions; do
7293   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7294     ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext"
7295     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7296     break 2
7297   fi
7298 done
7299   done
7300 IFS=$as_save_IFS
7301 
7302   ;;
7303 esac
7304 fi
7305 HEAD=$ac_cv_path_HEAD
7306 if test -n "$HEAD"; then
7307   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5
7308 $as_echo "$HEAD" >&6; }
7309 else
7310   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7311 $as_echo "no" >&6; }
7312 fi
7313 
7314 
7315   test -n "$HEAD" && break
7316 done
7317 
7318     else
7319       # If it succeeded, then it was overridden by the user. We will use it
7320       # for the tool.
7321 
7322       # First remove it from the list of overridden variables, so we can test
7323       # for unknown variables in the end.
7324       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7325 
7326       # Check if the provided tool contains a complete path.
7327       tool_specified="$HEAD"
7328       tool_basename="${tool_specified##*/}"
7329       if test "x$tool_basename" = "x$tool_specified"; then
7330         # A command without a complete path is provided, search $PATH.
7331         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HEAD=$tool_basename" >&5
7332 $as_echo "$as_me: Will search for user supplied tool HEAD=$tool_basename" >&6;}
7333         # Extract the first word of "$tool_basename", so it can be a program name with args.
7334 set dummy $tool_basename; ac_word=$2
7335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7336 $as_echo_n "checking for $ac_word... " >&6; }
7337 if ${ac_cv_path_HEAD+:} false; then :
7338   $as_echo_n "(cached) " >&6
7339 else
7340   case $HEAD in
7341   [\\/]* | ?:[\\/]*)
7342   ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path.
7343   ;;
7344   *)
7345   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7346 for as_dir in $PATH
7347 do
7348   IFS=$as_save_IFS
7349   test -z "$as_dir" && as_dir=.
7350     for ac_exec_ext in '' $ac_executable_extensions; do
7351   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7352     ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext"
7353     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7354     break 2
7355   fi
7356 done
7357   done
7358 IFS=$as_save_IFS
7359 
7360   ;;
7361 esac
7362 fi
7363 HEAD=$ac_cv_path_HEAD
7364 if test -n "$HEAD"; then
7365   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5
7366 $as_echo "$HEAD" >&6; }
7367 else
7368   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7369 $as_echo "no" >&6; }
7370 fi
7371 
7372 
7373         if test "x$HEAD" = x; then
7374           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7375         fi
7376       else
7377         # Otherwise we believe it is a complete path. Use it as it is.
7378         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HEAD=$tool_specified" >&5
7379 $as_echo "$as_me: Will use user supplied tool HEAD=$tool_specified" >&6;}
7380         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5
7381 $as_echo_n "checking for HEAD... " >&6; }
7382         if test ! -x "$tool_specified"; then
7383           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7384 $as_echo "not found" >&6; }
7385           as_fn_error $? "User supplied tool HEAD=$tool_specified does not exist or is not executable" "$LINENO" 5
7386         fi
7387         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7388 $as_echo "$tool_specified" >&6; }
7389       fi
7390     fi
7391   fi
7392 
7393 
7394 
7395   if test "x$HEAD" = x; then
7396     as_fn_error $? "Could not find required tool for HEAD" "$LINENO" 5
7397   fi
7398 
7399 
7400 
7401 
7402 
7403   # Publish this variable in the help.
7404 
7405 
7406   if test "x$LN" = x; then
7407     # The variable is not set by user, try to locate tool using the code snippet
7408     for ac_prog in ln
7409 do
7410   # Extract the first word of "$ac_prog", so it can be a program name with args.
7411 set dummy $ac_prog; ac_word=$2
7412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7413 $as_echo_n "checking for $ac_word... " >&6; }
7414 if ${ac_cv_path_LN+:} false; then :
7415   $as_echo_n "(cached) " >&6
7416 else
7417   case $LN in
7418   [\\/]* | ?:[\\/]*)
7419   ac_cv_path_LN="$LN" # Let the user override the test with a path.
7420   ;;
7421   *)
7422   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7423 for as_dir in $PATH
7424 do
7425   IFS=$as_save_IFS
7426   test -z "$as_dir" && as_dir=.
7427     for ac_exec_ext in '' $ac_executable_extensions; do
7428   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7429     ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
7430     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7431     break 2
7432   fi
7433 done
7434   done
7435 IFS=$as_save_IFS
7436 
7437   ;;
7438 esac
7439 fi
7440 LN=$ac_cv_path_LN
7441 if test -n "$LN"; then
7442   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
7443 $as_echo "$LN" >&6; }
7444 else
7445   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7446 $as_echo "no" >&6; }
7447 fi
7448 
7449 
7450   test -n "$LN" && break
7451 done
7452 
7453   else
7454     # The variable is set, but is it from the command line or the environment?
7455 
7456     # Try to remove the string !LN! from our list.
7457     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LN!/}
7458     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7459       # If it failed, the variable was not from the command line. Ignore it,
7460       # but warn the user (except for BASH, which is always set by the calling BASH).
7461       if test "xLN" != xBASH; then
7462         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&5
7463 $as_echo "$as_me: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&2;}
7464       fi
7465       # Try to locate tool using the code snippet
7466       for ac_prog in ln
7467 do
7468   # Extract the first word of "$ac_prog", so it can be a program name with args.
7469 set dummy $ac_prog; ac_word=$2
7470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7471 $as_echo_n "checking for $ac_word... " >&6; }
7472 if ${ac_cv_path_LN+:} false; then :
7473   $as_echo_n "(cached) " >&6
7474 else
7475   case $LN in
7476   [\\/]* | ?:[\\/]*)
7477   ac_cv_path_LN="$LN" # Let the user override the test with a path.
7478   ;;
7479   *)
7480   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7481 for as_dir in $PATH
7482 do
7483   IFS=$as_save_IFS
7484   test -z "$as_dir" && as_dir=.
7485     for ac_exec_ext in '' $ac_executable_extensions; do
7486   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7487     ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
7488     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7489     break 2
7490   fi
7491 done
7492   done
7493 IFS=$as_save_IFS
7494 
7495   ;;
7496 esac
7497 fi
7498 LN=$ac_cv_path_LN
7499 if test -n "$LN"; then
7500   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
7501 $as_echo "$LN" >&6; }
7502 else
7503   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7504 $as_echo "no" >&6; }
7505 fi
7506 
7507 
7508   test -n "$LN" && break
7509 done
7510 
7511     else
7512       # If it succeeded, then it was overridden by the user. We will use it
7513       # for the tool.
7514 
7515       # First remove it from the list of overridden variables, so we can test
7516       # for unknown variables in the end.
7517       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7518 
7519       # Check if the provided tool contains a complete path.
7520       tool_specified="$LN"
7521       tool_basename="${tool_specified##*/}"
7522       if test "x$tool_basename" = "x$tool_specified"; then
7523         # A command without a complete path is provided, search $PATH.
7524         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LN=$tool_basename" >&5
7525 $as_echo "$as_me: Will search for user supplied tool LN=$tool_basename" >&6;}
7526         # Extract the first word of "$tool_basename", so it can be a program name with args.
7527 set dummy $tool_basename; ac_word=$2
7528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7529 $as_echo_n "checking for $ac_word... " >&6; }
7530 if ${ac_cv_path_LN+:} false; then :
7531   $as_echo_n "(cached) " >&6
7532 else
7533   case $LN in
7534   [\\/]* | ?:[\\/]*)
7535   ac_cv_path_LN="$LN" # Let the user override the test with a path.
7536   ;;
7537   *)
7538   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7539 for as_dir in $PATH
7540 do
7541   IFS=$as_save_IFS
7542   test -z "$as_dir" && as_dir=.
7543     for ac_exec_ext in '' $ac_executable_extensions; do
7544   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7545     ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
7546     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7547     break 2
7548   fi
7549 done
7550   done
7551 IFS=$as_save_IFS
7552 
7553   ;;
7554 esac
7555 fi
7556 LN=$ac_cv_path_LN
7557 if test -n "$LN"; then
7558   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
7559 $as_echo "$LN" >&6; }
7560 else
7561   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7562 $as_echo "no" >&6; }
7563 fi
7564 
7565 
7566         if test "x$LN" = x; then
7567           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7568         fi
7569       else
7570         # Otherwise we believe it is a complete path. Use it as it is.
7571         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LN=$tool_specified" >&5
7572 $as_echo "$as_me: Will use user supplied tool LN=$tool_specified" >&6;}
7573         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5
7574 $as_echo_n "checking for LN... " >&6; }
7575         if test ! -x "$tool_specified"; then
7576           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7577 $as_echo "not found" >&6; }
7578           as_fn_error $? "User supplied tool LN=$tool_specified does not exist or is not executable" "$LINENO" 5
7579         fi
7580         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7581 $as_echo "$tool_specified" >&6; }
7582       fi
7583     fi
7584   fi
7585 
7586 
7587 
7588   if test "x$LN" = x; then
7589     as_fn_error $? "Could not find required tool for LN" "$LINENO" 5
7590   fi
7591 
7592 
7593 
7594 
7595 
7596   # Publish this variable in the help.
7597 
7598 
7599   if test "x$LS" = x; then
7600     # The variable is not set by user, try to locate tool using the code snippet
7601     for ac_prog in ls
7602 do
7603   # Extract the first word of "$ac_prog", so it can be a program name with args.
7604 set dummy $ac_prog; ac_word=$2
7605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7606 $as_echo_n "checking for $ac_word... " >&6; }
7607 if ${ac_cv_path_LS+:} false; then :
7608   $as_echo_n "(cached) " >&6
7609 else
7610   case $LS in
7611   [\\/]* | ?:[\\/]*)
7612   ac_cv_path_LS="$LS" # Let the user override the test with a path.
7613   ;;
7614   *)
7615   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7616 for as_dir in $PATH
7617 do
7618   IFS=$as_save_IFS
7619   test -z "$as_dir" && as_dir=.
7620     for ac_exec_ext in '' $ac_executable_extensions; do
7621   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7622     ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext"
7623     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7624     break 2
7625   fi
7626 done
7627   done
7628 IFS=$as_save_IFS
7629 
7630   ;;
7631 esac
7632 fi
7633 LS=$ac_cv_path_LS
7634 if test -n "$LS"; then
7635   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5
7636 $as_echo "$LS" >&6; }
7637 else
7638   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7639 $as_echo "no" >&6; }
7640 fi
7641 
7642 
7643   test -n "$LS" && break
7644 done
7645 
7646   else
7647     # The variable is set, but is it from the command line or the environment?
7648 
7649     # Try to remove the string !LS! from our list.
7650     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LS!/}
7651     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7652       # If it failed, the variable was not from the command line. Ignore it,
7653       # but warn the user (except for BASH, which is always set by the calling BASH).
7654       if test "xLS" != xBASH; then
7655         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&5
7656 $as_echo "$as_me: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&2;}
7657       fi
7658       # Try to locate tool using the code snippet
7659       for ac_prog in ls
7660 do
7661   # Extract the first word of "$ac_prog", so it can be a program name with args.
7662 set dummy $ac_prog; ac_word=$2
7663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7664 $as_echo_n "checking for $ac_word... " >&6; }
7665 if ${ac_cv_path_LS+:} false; then :
7666   $as_echo_n "(cached) " >&6
7667 else
7668   case $LS in
7669   [\\/]* | ?:[\\/]*)
7670   ac_cv_path_LS="$LS" # Let the user override the test with a path.
7671   ;;
7672   *)
7673   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7674 for as_dir in $PATH
7675 do
7676   IFS=$as_save_IFS
7677   test -z "$as_dir" && as_dir=.
7678     for ac_exec_ext in '' $ac_executable_extensions; do
7679   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7680     ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext"
7681     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7682     break 2
7683   fi
7684 done
7685   done
7686 IFS=$as_save_IFS
7687 
7688   ;;
7689 esac
7690 fi
7691 LS=$ac_cv_path_LS
7692 if test -n "$LS"; then
7693   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5
7694 $as_echo "$LS" >&6; }
7695 else
7696   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7697 $as_echo "no" >&6; }
7698 fi
7699 
7700 
7701   test -n "$LS" && break
7702 done
7703 
7704     else
7705       # If it succeeded, then it was overridden by the user. We will use it
7706       # for the tool.
7707 
7708       # First remove it from the list of overridden variables, so we can test
7709       # for unknown variables in the end.
7710       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7711 
7712       # Check if the provided tool contains a complete path.
7713       tool_specified="$LS"
7714       tool_basename="${tool_specified##*/}"
7715       if test "x$tool_basename" = "x$tool_specified"; then
7716         # A command without a complete path is provided, search $PATH.
7717         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LS=$tool_basename" >&5
7718 $as_echo "$as_me: Will search for user supplied tool LS=$tool_basename" >&6;}
7719         # Extract the first word of "$tool_basename", so it can be a program name with args.
7720 set dummy $tool_basename; ac_word=$2
7721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7722 $as_echo_n "checking for $ac_word... " >&6; }
7723 if ${ac_cv_path_LS+:} false; then :
7724   $as_echo_n "(cached) " >&6
7725 else
7726   case $LS in
7727   [\\/]* | ?:[\\/]*)
7728   ac_cv_path_LS="$LS" # Let the user override the test with a path.
7729   ;;
7730   *)
7731   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7732 for as_dir in $PATH
7733 do
7734   IFS=$as_save_IFS
7735   test -z "$as_dir" && as_dir=.
7736     for ac_exec_ext in '' $ac_executable_extensions; do
7737   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7738     ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext"
7739     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7740     break 2
7741   fi
7742 done
7743   done
7744 IFS=$as_save_IFS
7745 
7746   ;;
7747 esac
7748 fi
7749 LS=$ac_cv_path_LS
7750 if test -n "$LS"; then
7751   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5
7752 $as_echo "$LS" >&6; }
7753 else
7754   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7755 $as_echo "no" >&6; }
7756 fi
7757 
7758 
7759         if test "x$LS" = x; then
7760           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7761         fi
7762       else
7763         # Otherwise we believe it is a complete path. Use it as it is.
7764         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LS=$tool_specified" >&5
7765 $as_echo "$as_me: Will use user supplied tool LS=$tool_specified" >&6;}
7766         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5
7767 $as_echo_n "checking for LS... " >&6; }
7768         if test ! -x "$tool_specified"; then
7769           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7770 $as_echo "not found" >&6; }
7771           as_fn_error $? "User supplied tool LS=$tool_specified does not exist or is not executable" "$LINENO" 5
7772         fi
7773         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7774 $as_echo "$tool_specified" >&6; }
7775       fi
7776     fi
7777   fi
7778 
7779 
7780 
7781   if test "x$LS" = x; then
7782     as_fn_error $? "Could not find required tool for LS" "$LINENO" 5
7783   fi
7784 
7785 
7786 
7787 
7788 
7789   # Publish this variable in the help.
7790 
7791 
7792   if test "x$MKDIR" = x; then
7793     # The variable is not set by user, try to locate tool using the code snippet
7794     for ac_prog in mkdir
7795 do
7796   # Extract the first word of "$ac_prog", so it can be a program name with args.
7797 set dummy $ac_prog; ac_word=$2
7798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7799 $as_echo_n "checking for $ac_word... " >&6; }
7800 if ${ac_cv_path_MKDIR+:} false; then :
7801   $as_echo_n "(cached) " >&6
7802 else
7803   case $MKDIR in
7804   [\\/]* | ?:[\\/]*)
7805   ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path.
7806   ;;
7807   *)
7808   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7809 for as_dir in $PATH
7810 do
7811   IFS=$as_save_IFS
7812   test -z "$as_dir" && as_dir=.
7813     for ac_exec_ext in '' $ac_executable_extensions; do
7814   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7815     ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext"
7816     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7817     break 2
7818   fi
7819 done
7820   done
7821 IFS=$as_save_IFS
7822 
7823   ;;
7824 esac
7825 fi
7826 MKDIR=$ac_cv_path_MKDIR
7827 if test -n "$MKDIR"; then
7828   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5
7829 $as_echo "$MKDIR" >&6; }
7830 else
7831   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7832 $as_echo "no" >&6; }
7833 fi
7834 
7835 
7836   test -n "$MKDIR" && break
7837 done
7838 
7839   else
7840     # The variable is set, but is it from the command line or the environment?
7841 
7842     # Try to remove the string !MKDIR! from our list.
7843     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKDIR!/}
7844     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7845       # If it failed, the variable was not from the command line. Ignore it,
7846       # but warn the user (except for BASH, which is always set by the calling BASH).
7847       if test "xMKDIR" != xBASH; then
7848         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&5
7849 $as_echo "$as_me: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&2;}
7850       fi
7851       # Try to locate tool using the code snippet
7852       for ac_prog in mkdir
7853 do
7854   # Extract the first word of "$ac_prog", so it can be a program name with args.
7855 set dummy $ac_prog; ac_word=$2
7856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7857 $as_echo_n "checking for $ac_word... " >&6; }
7858 if ${ac_cv_path_MKDIR+:} false; then :
7859   $as_echo_n "(cached) " >&6
7860 else
7861   case $MKDIR in
7862   [\\/]* | ?:[\\/]*)
7863   ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path.
7864   ;;
7865   *)
7866   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7867 for as_dir in $PATH
7868 do
7869   IFS=$as_save_IFS
7870   test -z "$as_dir" && as_dir=.
7871     for ac_exec_ext in '' $ac_executable_extensions; do
7872   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7873     ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext"
7874     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7875     break 2
7876   fi
7877 done
7878   done
7879 IFS=$as_save_IFS
7880 
7881   ;;
7882 esac
7883 fi
7884 MKDIR=$ac_cv_path_MKDIR
7885 if test -n "$MKDIR"; then
7886   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5
7887 $as_echo "$MKDIR" >&6; }
7888 else
7889   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7890 $as_echo "no" >&6; }
7891 fi
7892 
7893 
7894   test -n "$MKDIR" && break
7895 done
7896 
7897     else
7898       # If it succeeded, then it was overridden by the user. We will use it
7899       # for the tool.
7900 
7901       # First remove it from the list of overridden variables, so we can test
7902       # for unknown variables in the end.
7903       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7904 
7905       # Check if the provided tool contains a complete path.
7906       tool_specified="$MKDIR"
7907       tool_basename="${tool_specified##*/}"
7908       if test "x$tool_basename" = "x$tool_specified"; then
7909         # A command without a complete path is provided, search $PATH.
7910         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKDIR=$tool_basename" >&5
7911 $as_echo "$as_me: Will search for user supplied tool MKDIR=$tool_basename" >&6;}
7912         # Extract the first word of "$tool_basename", so it can be a program name with args.
7913 set dummy $tool_basename; ac_word=$2
7914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7915 $as_echo_n "checking for $ac_word... " >&6; }
7916 if ${ac_cv_path_MKDIR+:} false; then :
7917   $as_echo_n "(cached) " >&6
7918 else
7919   case $MKDIR in
7920   [\\/]* | ?:[\\/]*)
7921   ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path.
7922   ;;
7923   *)
7924   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7925 for as_dir in $PATH
7926 do
7927   IFS=$as_save_IFS
7928   test -z "$as_dir" && as_dir=.
7929     for ac_exec_ext in '' $ac_executable_extensions; do
7930   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7931     ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext"
7932     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7933     break 2
7934   fi
7935 done
7936   done
7937 IFS=$as_save_IFS
7938 
7939   ;;
7940 esac
7941 fi
7942 MKDIR=$ac_cv_path_MKDIR
7943 if test -n "$MKDIR"; then
7944   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5
7945 $as_echo "$MKDIR" >&6; }
7946 else
7947   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7948 $as_echo "no" >&6; }
7949 fi
7950 
7951 
7952         if test "x$MKDIR" = x; then
7953           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7954         fi
7955       else
7956         # Otherwise we believe it is a complete path. Use it as it is.
7957         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKDIR=$tool_specified" >&5
7958 $as_echo "$as_me: Will use user supplied tool MKDIR=$tool_specified" >&6;}
7959         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5
7960 $as_echo_n "checking for MKDIR... " >&6; }
7961         if test ! -x "$tool_specified"; then
7962           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7963 $as_echo "not found" >&6; }
7964           as_fn_error $? "User supplied tool MKDIR=$tool_specified does not exist or is not executable" "$LINENO" 5
7965         fi
7966         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7967 $as_echo "$tool_specified" >&6; }
7968       fi
7969     fi
7970   fi
7971 
7972 
7973 
7974   if test "x$MKDIR" = x; then
7975     as_fn_error $? "Could not find required tool for MKDIR" "$LINENO" 5
7976   fi
7977 
7978 
7979 
7980 
7981 
7982   # Publish this variable in the help.
7983 
7984 
7985   if test "x$MKTEMP" = x; then
7986     # The variable is not set by user, try to locate tool using the code snippet
7987     for ac_prog in mktemp
7988 do
7989   # Extract the first word of "$ac_prog", so it can be a program name with args.
7990 set dummy $ac_prog; ac_word=$2
7991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7992 $as_echo_n "checking for $ac_word... " >&6; }
7993 if ${ac_cv_path_MKTEMP+:} false; then :
7994   $as_echo_n "(cached) " >&6
7995 else
7996   case $MKTEMP in
7997   [\\/]* | ?:[\\/]*)
7998   ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path.
7999   ;;
8000   *)
8001   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8002 for as_dir in $PATH
8003 do
8004   IFS=$as_save_IFS
8005   test -z "$as_dir" && as_dir=.
8006     for ac_exec_ext in '' $ac_executable_extensions; do
8007   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8008     ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext"
8009     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8010     break 2
8011   fi
8012 done
8013   done
8014 IFS=$as_save_IFS
8015 
8016   ;;
8017 esac
8018 fi
8019 MKTEMP=$ac_cv_path_MKTEMP
8020 if test -n "$MKTEMP"; then
8021   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5
8022 $as_echo "$MKTEMP" >&6; }
8023 else
8024   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8025 $as_echo "no" >&6; }
8026 fi
8027 
8028 
8029   test -n "$MKTEMP" && break
8030 done
8031 
8032   else
8033     # The variable is set, but is it from the command line or the environment?
8034 
8035     # Try to remove the string !MKTEMP! from our list.
8036     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKTEMP!/}
8037     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8038       # If it failed, the variable was not from the command line. Ignore it,
8039       # but warn the user (except for BASH, which is always set by the calling BASH).
8040       if test "xMKTEMP" != xBASH; then
8041         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&5
8042 $as_echo "$as_me: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&2;}
8043       fi
8044       # Try to locate tool using the code snippet
8045       for ac_prog in mktemp
8046 do
8047   # Extract the first word of "$ac_prog", so it can be a program name with args.
8048 set dummy $ac_prog; ac_word=$2
8049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8050 $as_echo_n "checking for $ac_word... " >&6; }
8051 if ${ac_cv_path_MKTEMP+:} false; then :
8052   $as_echo_n "(cached) " >&6
8053 else
8054   case $MKTEMP in
8055   [\\/]* | ?:[\\/]*)
8056   ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path.
8057   ;;
8058   *)
8059   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8060 for as_dir in $PATH
8061 do
8062   IFS=$as_save_IFS
8063   test -z "$as_dir" && as_dir=.
8064     for ac_exec_ext in '' $ac_executable_extensions; do
8065   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8066     ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext"
8067     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8068     break 2
8069   fi
8070 done
8071   done
8072 IFS=$as_save_IFS
8073 
8074   ;;
8075 esac
8076 fi
8077 MKTEMP=$ac_cv_path_MKTEMP
8078 if test -n "$MKTEMP"; then
8079   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5
8080 $as_echo "$MKTEMP" >&6; }
8081 else
8082   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8083 $as_echo "no" >&6; }
8084 fi
8085 
8086 
8087   test -n "$MKTEMP" && break
8088 done
8089 
8090     else
8091       # If it succeeded, then it was overridden by the user. We will use it
8092       # for the tool.
8093 
8094       # First remove it from the list of overridden variables, so we can test
8095       # for unknown variables in the end.
8096       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8097 
8098       # Check if the provided tool contains a complete path.
8099       tool_specified="$MKTEMP"
8100       tool_basename="${tool_specified##*/}"
8101       if test "x$tool_basename" = "x$tool_specified"; then
8102         # A command without a complete path is provided, search $PATH.
8103         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKTEMP=$tool_basename" >&5
8104 $as_echo "$as_me: Will search for user supplied tool MKTEMP=$tool_basename" >&6;}
8105         # Extract the first word of "$tool_basename", so it can be a program name with args.
8106 set dummy $tool_basename; ac_word=$2
8107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8108 $as_echo_n "checking for $ac_word... " >&6; }
8109 if ${ac_cv_path_MKTEMP+:} false; then :
8110   $as_echo_n "(cached) " >&6
8111 else
8112   case $MKTEMP in
8113   [\\/]* | ?:[\\/]*)
8114   ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path.
8115   ;;
8116   *)
8117   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8118 for as_dir in $PATH
8119 do
8120   IFS=$as_save_IFS
8121   test -z "$as_dir" && as_dir=.
8122     for ac_exec_ext in '' $ac_executable_extensions; do
8123   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8124     ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext"
8125     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8126     break 2
8127   fi
8128 done
8129   done
8130 IFS=$as_save_IFS
8131 
8132   ;;
8133 esac
8134 fi
8135 MKTEMP=$ac_cv_path_MKTEMP
8136 if test -n "$MKTEMP"; then
8137   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5
8138 $as_echo "$MKTEMP" >&6; }
8139 else
8140   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8141 $as_echo "no" >&6; }
8142 fi
8143 
8144 
8145         if test "x$MKTEMP" = x; then
8146           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8147         fi
8148       else
8149         # Otherwise we believe it is a complete path. Use it as it is.
8150         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKTEMP=$tool_specified" >&5
8151 $as_echo "$as_me: Will use user supplied tool MKTEMP=$tool_specified" >&6;}
8152         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5
8153 $as_echo_n "checking for MKTEMP... " >&6; }
8154         if test ! -x "$tool_specified"; then
8155           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8156 $as_echo "not found" >&6; }
8157           as_fn_error $? "User supplied tool MKTEMP=$tool_specified does not exist or is not executable" "$LINENO" 5
8158         fi
8159         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8160 $as_echo "$tool_specified" >&6; }
8161       fi
8162     fi
8163   fi
8164 
8165 
8166 
8167   if test "x$MKTEMP" = x; then
8168     as_fn_error $? "Could not find required tool for MKTEMP" "$LINENO" 5
8169   fi
8170 
8171 
8172 
8173 
8174 
8175   # Publish this variable in the help.
8176 
8177 
8178   if test "x$MV" = x; then
8179     # The variable is not set by user, try to locate tool using the code snippet
8180     for ac_prog in mv
8181 do
8182   # Extract the first word of "$ac_prog", so it can be a program name with args.
8183 set dummy $ac_prog; ac_word=$2
8184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8185 $as_echo_n "checking for $ac_word... " >&6; }
8186 if ${ac_cv_path_MV+:} false; then :
8187   $as_echo_n "(cached) " >&6
8188 else
8189   case $MV in
8190   [\\/]* | ?:[\\/]*)
8191   ac_cv_path_MV="$MV" # Let the user override the test with a path.
8192   ;;
8193   *)
8194   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8195 for as_dir in $PATH
8196 do
8197   IFS=$as_save_IFS
8198   test -z "$as_dir" && as_dir=.
8199     for ac_exec_ext in '' $ac_executable_extensions; do
8200   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8201     ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext"
8202     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8203     break 2
8204   fi
8205 done
8206   done
8207 IFS=$as_save_IFS
8208 
8209   ;;
8210 esac
8211 fi
8212 MV=$ac_cv_path_MV
8213 if test -n "$MV"; then
8214   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5
8215 $as_echo "$MV" >&6; }
8216 else
8217   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8218 $as_echo "no" >&6; }
8219 fi
8220 
8221 
8222   test -n "$MV" && break
8223 done
8224 
8225   else
8226     # The variable is set, but is it from the command line or the environment?
8227 
8228     # Try to remove the string !MV! from our list.
8229     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MV!/}
8230     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8231       # If it failed, the variable was not from the command line. Ignore it,
8232       # but warn the user (except for BASH, which is always set by the calling BASH).
8233       if test "xMV" != xBASH; then
8234         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&5
8235 $as_echo "$as_me: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&2;}
8236       fi
8237       # Try to locate tool using the code snippet
8238       for ac_prog in mv
8239 do
8240   # Extract the first word of "$ac_prog", so it can be a program name with args.
8241 set dummy $ac_prog; ac_word=$2
8242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8243 $as_echo_n "checking for $ac_word... " >&6; }
8244 if ${ac_cv_path_MV+:} false; then :
8245   $as_echo_n "(cached) " >&6
8246 else
8247   case $MV in
8248   [\\/]* | ?:[\\/]*)
8249   ac_cv_path_MV="$MV" # Let the user override the test with a path.
8250   ;;
8251   *)
8252   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8253 for as_dir in $PATH
8254 do
8255   IFS=$as_save_IFS
8256   test -z "$as_dir" && as_dir=.
8257     for ac_exec_ext in '' $ac_executable_extensions; do
8258   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8259     ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext"
8260     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8261     break 2
8262   fi
8263 done
8264   done
8265 IFS=$as_save_IFS
8266 
8267   ;;
8268 esac
8269 fi
8270 MV=$ac_cv_path_MV
8271 if test -n "$MV"; then
8272   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5
8273 $as_echo "$MV" >&6; }
8274 else
8275   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8276 $as_echo "no" >&6; }
8277 fi
8278 
8279 
8280   test -n "$MV" && break
8281 done
8282 
8283     else
8284       # If it succeeded, then it was overridden by the user. We will use it
8285       # for the tool.
8286 
8287       # First remove it from the list of overridden variables, so we can test
8288       # for unknown variables in the end.
8289       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8290 
8291       # Check if the provided tool contains a complete path.
8292       tool_specified="$MV"
8293       tool_basename="${tool_specified##*/}"
8294       if test "x$tool_basename" = "x$tool_specified"; then
8295         # A command without a complete path is provided, search $PATH.
8296         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MV=$tool_basename" >&5
8297 $as_echo "$as_me: Will search for user supplied tool MV=$tool_basename" >&6;}
8298         # Extract the first word of "$tool_basename", so it can be a program name with args.
8299 set dummy $tool_basename; ac_word=$2
8300 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8301 $as_echo_n "checking for $ac_word... " >&6; }
8302 if ${ac_cv_path_MV+:} false; then :
8303   $as_echo_n "(cached) " >&6
8304 else
8305   case $MV in
8306   [\\/]* | ?:[\\/]*)
8307   ac_cv_path_MV="$MV" # Let the user override the test with a path.
8308   ;;
8309   *)
8310   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8311 for as_dir in $PATH
8312 do
8313   IFS=$as_save_IFS
8314   test -z "$as_dir" && as_dir=.
8315     for ac_exec_ext in '' $ac_executable_extensions; do
8316   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8317     ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext"
8318     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8319     break 2
8320   fi
8321 done
8322   done
8323 IFS=$as_save_IFS
8324 
8325   ;;
8326 esac
8327 fi
8328 MV=$ac_cv_path_MV
8329 if test -n "$MV"; then
8330   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5
8331 $as_echo "$MV" >&6; }
8332 else
8333   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8334 $as_echo "no" >&6; }
8335 fi
8336 
8337 
8338         if test "x$MV" = x; then
8339           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8340         fi
8341       else
8342         # Otherwise we believe it is a complete path. Use it as it is.
8343         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MV=$tool_specified" >&5
8344 $as_echo "$as_me: Will use user supplied tool MV=$tool_specified" >&6;}
8345         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5
8346 $as_echo_n "checking for MV... " >&6; }
8347         if test ! -x "$tool_specified"; then
8348           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8349 $as_echo "not found" >&6; }
8350           as_fn_error $? "User supplied tool MV=$tool_specified does not exist or is not executable" "$LINENO" 5
8351         fi
8352         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8353 $as_echo "$tool_specified" >&6; }
8354       fi
8355     fi
8356   fi
8357 
8358 
8359 
8360   if test "x$MV" = x; then
8361     as_fn_error $? "Could not find required tool for MV" "$LINENO" 5
8362   fi
8363 
8364 
8365 
8366 
8367 
8368   # Publish this variable in the help.
8369 
8370 
8371   if test "x$NAWK" = x; then
8372     # The variable is not set by user, try to locate tool using the code snippet
8373     for ac_prog in nawk gawk awk
8374 do
8375   # Extract the first word of "$ac_prog", so it can be a program name with args.
8376 set dummy $ac_prog; ac_word=$2
8377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8378 $as_echo_n "checking for $ac_word... " >&6; }
8379 if ${ac_cv_path_NAWK+:} false; then :
8380   $as_echo_n "(cached) " >&6
8381 else
8382   case $NAWK in
8383   [\\/]* | ?:[\\/]*)
8384   ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path.
8385   ;;
8386   *)
8387   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8388 for as_dir in $PATH
8389 do
8390   IFS=$as_save_IFS
8391   test -z "$as_dir" && as_dir=.
8392     for ac_exec_ext in '' $ac_executable_extensions; do
8393   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8394     ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext"
8395     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8396     break 2
8397   fi
8398 done
8399   done
8400 IFS=$as_save_IFS
8401 
8402   ;;
8403 esac
8404 fi
8405 NAWK=$ac_cv_path_NAWK
8406 if test -n "$NAWK"; then
8407   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5
8408 $as_echo "$NAWK" >&6; }
8409 else
8410   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8411 $as_echo "no" >&6; }
8412 fi
8413 
8414 
8415   test -n "$NAWK" && break
8416 done
8417 
8418   else
8419     # The variable is set, but is it from the command line or the environment?
8420 
8421     # Try to remove the string !NAWK! from our list.
8422     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NAWK!/}
8423     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8424       # If it failed, the variable was not from the command line. Ignore it,
8425       # but warn the user (except for BASH, which is always set by the calling BASH).
8426       if test "xNAWK" != xBASH; then
8427         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&5
8428 $as_echo "$as_me: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&2;}
8429       fi
8430       # Try to locate tool using the code snippet
8431       for ac_prog in nawk gawk awk
8432 do
8433   # Extract the first word of "$ac_prog", so it can be a program name with args.
8434 set dummy $ac_prog; ac_word=$2
8435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8436 $as_echo_n "checking for $ac_word... " >&6; }
8437 if ${ac_cv_path_NAWK+:} false; then :
8438   $as_echo_n "(cached) " >&6
8439 else
8440   case $NAWK in
8441   [\\/]* | ?:[\\/]*)
8442   ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path.
8443   ;;
8444   *)
8445   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8446 for as_dir in $PATH
8447 do
8448   IFS=$as_save_IFS
8449   test -z "$as_dir" && as_dir=.
8450     for ac_exec_ext in '' $ac_executable_extensions; do
8451   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8452     ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext"
8453     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8454     break 2
8455   fi
8456 done
8457   done
8458 IFS=$as_save_IFS
8459 
8460   ;;
8461 esac
8462 fi
8463 NAWK=$ac_cv_path_NAWK
8464 if test -n "$NAWK"; then
8465   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5
8466 $as_echo "$NAWK" >&6; }
8467 else
8468   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8469 $as_echo "no" >&6; }
8470 fi
8471 
8472 
8473   test -n "$NAWK" && break
8474 done
8475 
8476     else
8477       # If it succeeded, then it was overridden by the user. We will use it
8478       # for the tool.
8479 
8480       # First remove it from the list of overridden variables, so we can test
8481       # for unknown variables in the end.
8482       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8483 
8484       # Check if the provided tool contains a complete path.
8485       tool_specified="$NAWK"
8486       tool_basename="${tool_specified##*/}"
8487       if test "x$tool_basename" = "x$tool_specified"; then
8488         # A command without a complete path is provided, search $PATH.
8489         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NAWK=$tool_basename" >&5
8490 $as_echo "$as_me: Will search for user supplied tool NAWK=$tool_basename" >&6;}
8491         # Extract the first word of "$tool_basename", so it can be a program name with args.
8492 set dummy $tool_basename; ac_word=$2
8493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8494 $as_echo_n "checking for $ac_word... " >&6; }
8495 if ${ac_cv_path_NAWK+:} false; then :
8496   $as_echo_n "(cached) " >&6
8497 else
8498   case $NAWK in
8499   [\\/]* | ?:[\\/]*)
8500   ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path.
8501   ;;
8502   *)
8503   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8504 for as_dir in $PATH
8505 do
8506   IFS=$as_save_IFS
8507   test -z "$as_dir" && as_dir=.
8508     for ac_exec_ext in '' $ac_executable_extensions; do
8509   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8510     ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext"
8511     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8512     break 2
8513   fi
8514 done
8515   done
8516 IFS=$as_save_IFS
8517 
8518   ;;
8519 esac
8520 fi
8521 NAWK=$ac_cv_path_NAWK
8522 if test -n "$NAWK"; then
8523   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5
8524 $as_echo "$NAWK" >&6; }
8525 else
8526   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8527 $as_echo "no" >&6; }
8528 fi
8529 
8530 
8531         if test "x$NAWK" = x; then
8532           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8533         fi
8534       else
8535         # Otherwise we believe it is a complete path. Use it as it is.
8536         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NAWK=$tool_specified" >&5
8537 $as_echo "$as_me: Will use user supplied tool NAWK=$tool_specified" >&6;}
8538         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5
8539 $as_echo_n "checking for NAWK... " >&6; }
8540         if test ! -x "$tool_specified"; then
8541           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8542 $as_echo "not found" >&6; }
8543           as_fn_error $? "User supplied tool NAWK=$tool_specified does not exist or is not executable" "$LINENO" 5
8544         fi
8545         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8546 $as_echo "$tool_specified" >&6; }
8547       fi
8548     fi
8549   fi
8550 
8551 
8552 
8553   if test "x$NAWK" = x; then
8554     as_fn_error $? "Could not find required tool for NAWK" "$LINENO" 5
8555   fi
8556 
8557 
8558 
8559 
8560 
8561   # Publish this variable in the help.
8562 
8563 
8564   if test "x$PRINTF" = x; then
8565     # The variable is not set by user, try to locate tool using the code snippet
8566     for ac_prog in printf
8567 do
8568   # Extract the first word of "$ac_prog", so it can be a program name with args.
8569 set dummy $ac_prog; ac_word=$2
8570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8571 $as_echo_n "checking for $ac_word... " >&6; }
8572 if ${ac_cv_path_PRINTF+:} false; then :
8573   $as_echo_n "(cached) " >&6
8574 else
8575   case $PRINTF in
8576   [\\/]* | ?:[\\/]*)
8577   ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path.
8578   ;;
8579   *)
8580   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8581 for as_dir in $PATH
8582 do
8583   IFS=$as_save_IFS
8584   test -z "$as_dir" && as_dir=.
8585     for ac_exec_ext in '' $ac_executable_extensions; do
8586   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8587     ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext"
8588     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8589     break 2
8590   fi
8591 done
8592   done
8593 IFS=$as_save_IFS
8594 
8595   ;;
8596 esac
8597 fi
8598 PRINTF=$ac_cv_path_PRINTF
8599 if test -n "$PRINTF"; then
8600   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5
8601 $as_echo "$PRINTF" >&6; }
8602 else
8603   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8604 $as_echo "no" >&6; }
8605 fi
8606 
8607 
8608   test -n "$PRINTF" && break
8609 done
8610 
8611   else
8612     # The variable is set, but is it from the command line or the environment?
8613 
8614     # Try to remove the string !PRINTF! from our list.
8615     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PRINTF!/}
8616     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8617       # If it failed, the variable was not from the command line. Ignore it,
8618       # but warn the user (except for BASH, which is always set by the calling BASH).
8619       if test "xPRINTF" != xBASH; then
8620         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&5
8621 $as_echo "$as_me: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&2;}
8622       fi
8623       # Try to locate tool using the code snippet
8624       for ac_prog in printf
8625 do
8626   # Extract the first word of "$ac_prog", so it can be a program name with args.
8627 set dummy $ac_prog; ac_word=$2
8628 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8629 $as_echo_n "checking for $ac_word... " >&6; }
8630 if ${ac_cv_path_PRINTF+:} false; then :
8631   $as_echo_n "(cached) " >&6
8632 else
8633   case $PRINTF in
8634   [\\/]* | ?:[\\/]*)
8635   ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path.
8636   ;;
8637   *)
8638   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8639 for as_dir in $PATH
8640 do
8641   IFS=$as_save_IFS
8642   test -z "$as_dir" && as_dir=.
8643     for ac_exec_ext in '' $ac_executable_extensions; do
8644   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8645     ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext"
8646     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8647     break 2
8648   fi
8649 done
8650   done
8651 IFS=$as_save_IFS
8652 
8653   ;;
8654 esac
8655 fi
8656 PRINTF=$ac_cv_path_PRINTF
8657 if test -n "$PRINTF"; then
8658   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5
8659 $as_echo "$PRINTF" >&6; }
8660 else
8661   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8662 $as_echo "no" >&6; }
8663 fi
8664 
8665 
8666   test -n "$PRINTF" && break
8667 done
8668 
8669     else
8670       # If it succeeded, then it was overridden by the user. We will use it
8671       # for the tool.
8672 
8673       # First remove it from the list of overridden variables, so we can test
8674       # for unknown variables in the end.
8675       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8676 
8677       # Check if the provided tool contains a complete path.
8678       tool_specified="$PRINTF"
8679       tool_basename="${tool_specified##*/}"
8680       if test "x$tool_basename" = "x$tool_specified"; then
8681         # A command without a complete path is provided, search $PATH.
8682         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PRINTF=$tool_basename" >&5
8683 $as_echo "$as_me: Will search for user supplied tool PRINTF=$tool_basename" >&6;}
8684         # Extract the first word of "$tool_basename", so it can be a program name with args.
8685 set dummy $tool_basename; ac_word=$2
8686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8687 $as_echo_n "checking for $ac_word... " >&6; }
8688 if ${ac_cv_path_PRINTF+:} false; then :
8689   $as_echo_n "(cached) " >&6
8690 else
8691   case $PRINTF in
8692   [\\/]* | ?:[\\/]*)
8693   ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path.
8694   ;;
8695   *)
8696   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8697 for as_dir in $PATH
8698 do
8699   IFS=$as_save_IFS
8700   test -z "$as_dir" && as_dir=.
8701     for ac_exec_ext in '' $ac_executable_extensions; do
8702   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8703     ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext"
8704     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8705     break 2
8706   fi
8707 done
8708   done
8709 IFS=$as_save_IFS
8710 
8711   ;;
8712 esac
8713 fi
8714 PRINTF=$ac_cv_path_PRINTF
8715 if test -n "$PRINTF"; then
8716   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5
8717 $as_echo "$PRINTF" >&6; }
8718 else
8719   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8720 $as_echo "no" >&6; }
8721 fi
8722 
8723 
8724         if test "x$PRINTF" = x; then
8725           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8726         fi
8727       else
8728         # Otherwise we believe it is a complete path. Use it as it is.
8729         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PRINTF=$tool_specified" >&5
8730 $as_echo "$as_me: Will use user supplied tool PRINTF=$tool_specified" >&6;}
8731         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5
8732 $as_echo_n "checking for PRINTF... " >&6; }
8733         if test ! -x "$tool_specified"; then
8734           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8735 $as_echo "not found" >&6; }
8736           as_fn_error $? "User supplied tool PRINTF=$tool_specified does not exist or is not executable" "$LINENO" 5
8737         fi
8738         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8739 $as_echo "$tool_specified" >&6; }
8740       fi
8741     fi
8742   fi
8743 
8744 
8745 
8746   if test "x$PRINTF" = x; then
8747     as_fn_error $? "Could not find required tool for PRINTF" "$LINENO" 5
8748   fi
8749 
8750 
8751 
8752 
8753 
8754   # Publish this variable in the help.
8755 
8756 
8757   if test "x$RM" = x; then
8758     # The variable is not set by user, try to locate tool using the code snippet
8759     for ac_prog in rm
8760 do
8761   # Extract the first word of "$ac_prog", so it can be a program name with args.
8762 set dummy $ac_prog; ac_word=$2
8763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8764 $as_echo_n "checking for $ac_word... " >&6; }
8765 if ${ac_cv_path_RM+:} false; then :
8766   $as_echo_n "(cached) " >&6
8767 else
8768   case $RM in
8769   [\\/]* | ?:[\\/]*)
8770   ac_cv_path_RM="$RM" # Let the user override the test with a path.
8771   ;;
8772   *)
8773   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8774 for as_dir in $PATH
8775 do
8776   IFS=$as_save_IFS
8777   test -z "$as_dir" && as_dir=.
8778     for ac_exec_ext in '' $ac_executable_extensions; do
8779   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8780     ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext"
8781     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8782     break 2
8783   fi
8784 done
8785   done
8786 IFS=$as_save_IFS
8787 
8788   ;;
8789 esac
8790 fi
8791 RM=$ac_cv_path_RM
8792 if test -n "$RM"; then
8793   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5
8794 $as_echo "$RM" >&6; }
8795 else
8796   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8797 $as_echo "no" >&6; }
8798 fi
8799 
8800 
8801   test -n "$RM" && break
8802 done
8803 
8804   else
8805     # The variable is set, but is it from the command line or the environment?
8806 
8807     # Try to remove the string !RM! from our list.
8808     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RM!/}
8809     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8810       # If it failed, the variable was not from the command line. Ignore it,
8811       # but warn the user (except for BASH, which is always set by the calling BASH).
8812       if test "xRM" != xBASH; then
8813         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&5
8814 $as_echo "$as_me: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&2;}
8815       fi
8816       # Try to locate tool using the code snippet
8817       for ac_prog in rm
8818 do
8819   # Extract the first word of "$ac_prog", so it can be a program name with args.
8820 set dummy $ac_prog; ac_word=$2
8821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8822 $as_echo_n "checking for $ac_word... " >&6; }
8823 if ${ac_cv_path_RM+:} false; then :
8824   $as_echo_n "(cached) " >&6
8825 else
8826   case $RM in
8827   [\\/]* | ?:[\\/]*)
8828   ac_cv_path_RM="$RM" # Let the user override the test with a path.
8829   ;;
8830   *)
8831   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8832 for as_dir in $PATH
8833 do
8834   IFS=$as_save_IFS
8835   test -z "$as_dir" && as_dir=.
8836     for ac_exec_ext in '' $ac_executable_extensions; do
8837   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8838     ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext"
8839     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8840     break 2
8841   fi
8842 done
8843   done
8844 IFS=$as_save_IFS
8845 
8846   ;;
8847 esac
8848 fi
8849 RM=$ac_cv_path_RM
8850 if test -n "$RM"; then
8851   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5
8852 $as_echo "$RM" >&6; }
8853 else
8854   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8855 $as_echo "no" >&6; }
8856 fi
8857 
8858 
8859   test -n "$RM" && break
8860 done
8861 
8862     else
8863       # If it succeeded, then it was overridden by the user. We will use it
8864       # for the tool.
8865 
8866       # First remove it from the list of overridden variables, so we can test
8867       # for unknown variables in the end.
8868       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8869 
8870       # Check if the provided tool contains a complete path.
8871       tool_specified="$RM"
8872       tool_basename="${tool_specified##*/}"
8873       if test "x$tool_basename" = "x$tool_specified"; then
8874         # A command without a complete path is provided, search $PATH.
8875         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RM=$tool_basename" >&5
8876 $as_echo "$as_me: Will search for user supplied tool RM=$tool_basename" >&6;}
8877         # Extract the first word of "$tool_basename", so it can be a program name with args.
8878 set dummy $tool_basename; ac_word=$2
8879 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8880 $as_echo_n "checking for $ac_word... " >&6; }
8881 if ${ac_cv_path_RM+:} false; then :
8882   $as_echo_n "(cached) " >&6
8883 else
8884   case $RM in
8885   [\\/]* | ?:[\\/]*)
8886   ac_cv_path_RM="$RM" # Let the user override the test with a path.
8887   ;;
8888   *)
8889   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8890 for as_dir in $PATH
8891 do
8892   IFS=$as_save_IFS
8893   test -z "$as_dir" && as_dir=.
8894     for ac_exec_ext in '' $ac_executable_extensions; do
8895   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8896     ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext"
8897     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8898     break 2
8899   fi
8900 done
8901   done
8902 IFS=$as_save_IFS
8903 
8904   ;;
8905 esac
8906 fi
8907 RM=$ac_cv_path_RM
8908 if test -n "$RM"; then
8909   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5
8910 $as_echo "$RM" >&6; }
8911 else
8912   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8913 $as_echo "no" >&6; }
8914 fi
8915 
8916 
8917         if test "x$RM" = x; then
8918           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8919         fi
8920       else
8921         # Otherwise we believe it is a complete path. Use it as it is.
8922         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RM=$tool_specified" >&5
8923 $as_echo "$as_me: Will use user supplied tool RM=$tool_specified" >&6;}
8924         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5
8925 $as_echo_n "checking for RM... " >&6; }
8926         if test ! -x "$tool_specified"; then
8927           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8928 $as_echo "not found" >&6; }
8929           as_fn_error $? "User supplied tool RM=$tool_specified does not exist or is not executable" "$LINENO" 5
8930         fi
8931         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8932 $as_echo "$tool_specified" >&6; }
8933       fi
8934     fi
8935   fi
8936 
8937 
8938 
8939   if test "x$RM" = x; then
8940     as_fn_error $? "Could not find required tool for RM" "$LINENO" 5
8941   fi
8942 
8943 
8944 
8945 
8946 
8947   # Publish this variable in the help.
8948 
8949 
8950   if test "x$SH" = x; then
8951     # The variable is not set by user, try to locate tool using the code snippet
8952     for ac_prog in sh
8953 do
8954   # Extract the first word of "$ac_prog", so it can be a program name with args.
8955 set dummy $ac_prog; ac_word=$2
8956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8957 $as_echo_n "checking for $ac_word... " >&6; }
8958 if ${ac_cv_path_SH+:} false; then :
8959   $as_echo_n "(cached) " >&6
8960 else
8961   case $SH in
8962   [\\/]* | ?:[\\/]*)
8963   ac_cv_path_SH="$SH" # Let the user override the test with a path.
8964   ;;
8965   *)
8966   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8967 for as_dir in $PATH
8968 do
8969   IFS=$as_save_IFS
8970   test -z "$as_dir" && as_dir=.
8971     for ac_exec_ext in '' $ac_executable_extensions; do
8972   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8973     ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
8974     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8975     break 2
8976   fi
8977 done
8978   done
8979 IFS=$as_save_IFS
8980 
8981   ;;
8982 esac
8983 fi
8984 SH=$ac_cv_path_SH
8985 if test -n "$SH"; then
8986   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5
8987 $as_echo "$SH" >&6; }
8988 else
8989   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8990 $as_echo "no" >&6; }
8991 fi
8992 
8993 
8994   test -n "$SH" && break
8995 done
8996 
8997   else
8998     # The variable is set, but is it from the command line or the environment?
8999 
9000     # Try to remove the string !SH! from our list.
9001     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SH!/}
9002     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9003       # If it failed, the variable was not from the command line. Ignore it,
9004       # but warn the user (except for BASH, which is always set by the calling BASH).
9005       if test "xSH" != xBASH; then
9006         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&5
9007 $as_echo "$as_me: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&2;}
9008       fi
9009       # Try to locate tool using the code snippet
9010       for ac_prog in sh
9011 do
9012   # Extract the first word of "$ac_prog", so it can be a program name with args.
9013 set dummy $ac_prog; ac_word=$2
9014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9015 $as_echo_n "checking for $ac_word... " >&6; }
9016 if ${ac_cv_path_SH+:} false; then :
9017   $as_echo_n "(cached) " >&6
9018 else
9019   case $SH in
9020   [\\/]* | ?:[\\/]*)
9021   ac_cv_path_SH="$SH" # Let the user override the test with a path.
9022   ;;
9023   *)
9024   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9025 for as_dir in $PATH
9026 do
9027   IFS=$as_save_IFS
9028   test -z "$as_dir" && as_dir=.
9029     for ac_exec_ext in '' $ac_executable_extensions; do
9030   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9031     ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
9032     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9033     break 2
9034   fi
9035 done
9036   done
9037 IFS=$as_save_IFS
9038 
9039   ;;
9040 esac
9041 fi
9042 SH=$ac_cv_path_SH
9043 if test -n "$SH"; then
9044   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5
9045 $as_echo "$SH" >&6; }
9046 else
9047   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9048 $as_echo "no" >&6; }
9049 fi
9050 
9051 
9052   test -n "$SH" && break
9053 done
9054 
9055     else
9056       # If it succeeded, then it was overridden by the user. We will use it
9057       # for the tool.
9058 
9059       # First remove it from the list of overridden variables, so we can test
9060       # for unknown variables in the end.
9061       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9062 
9063       # Check if the provided tool contains a complete path.
9064       tool_specified="$SH"
9065       tool_basename="${tool_specified##*/}"
9066       if test "x$tool_basename" = "x$tool_specified"; then
9067         # A command without a complete path is provided, search $PATH.
9068         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SH=$tool_basename" >&5
9069 $as_echo "$as_me: Will search for user supplied tool SH=$tool_basename" >&6;}
9070         # Extract the first word of "$tool_basename", so it can be a program name with args.
9071 set dummy $tool_basename; ac_word=$2
9072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9073 $as_echo_n "checking for $ac_word... " >&6; }
9074 if ${ac_cv_path_SH+:} false; then :
9075   $as_echo_n "(cached) " >&6
9076 else
9077   case $SH in
9078   [\\/]* | ?:[\\/]*)
9079   ac_cv_path_SH="$SH" # Let the user override the test with a path.
9080   ;;
9081   *)
9082   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9083 for as_dir in $PATH
9084 do
9085   IFS=$as_save_IFS
9086   test -z "$as_dir" && as_dir=.
9087     for ac_exec_ext in '' $ac_executable_extensions; do
9088   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9089     ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
9090     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9091     break 2
9092   fi
9093 done
9094   done
9095 IFS=$as_save_IFS
9096 
9097   ;;
9098 esac
9099 fi
9100 SH=$ac_cv_path_SH
9101 if test -n "$SH"; then
9102   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5
9103 $as_echo "$SH" >&6; }
9104 else
9105   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9106 $as_echo "no" >&6; }
9107 fi
9108 
9109 
9110         if test "x$SH" = x; then
9111           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9112         fi
9113       else
9114         # Otherwise we believe it is a complete path. Use it as it is.
9115         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SH=$tool_specified" >&5
9116 $as_echo "$as_me: Will use user supplied tool SH=$tool_specified" >&6;}
9117         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5
9118 $as_echo_n "checking for SH... " >&6; }
9119         if test ! -x "$tool_specified"; then
9120           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9121 $as_echo "not found" >&6; }
9122           as_fn_error $? "User supplied tool SH=$tool_specified does not exist or is not executable" "$LINENO" 5
9123         fi
9124         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9125 $as_echo "$tool_specified" >&6; }
9126       fi
9127     fi
9128   fi
9129 
9130 
9131 
9132   if test "x$SH" = x; then
9133     as_fn_error $? "Could not find required tool for SH" "$LINENO" 5
9134   fi
9135 
9136 
9137 
9138 
9139 
9140   # Publish this variable in the help.
9141 
9142 
9143   if test "x$SORT" = x; then
9144     # The variable is not set by user, try to locate tool using the code snippet
9145     for ac_prog in sort
9146 do
9147   # Extract the first word of "$ac_prog", so it can be a program name with args.
9148 set dummy $ac_prog; ac_word=$2
9149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9150 $as_echo_n "checking for $ac_word... " >&6; }
9151 if ${ac_cv_path_SORT+:} false; then :
9152   $as_echo_n "(cached) " >&6
9153 else
9154   case $SORT in
9155   [\\/]* | ?:[\\/]*)
9156   ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
9157   ;;
9158   *)
9159   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9160 for as_dir in $PATH
9161 do
9162   IFS=$as_save_IFS
9163   test -z "$as_dir" && as_dir=.
9164     for ac_exec_ext in '' $ac_executable_extensions; do
9165   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9166     ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext"
9167     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9168     break 2
9169   fi
9170 done
9171   done
9172 IFS=$as_save_IFS
9173 
9174   ;;
9175 esac
9176 fi
9177 SORT=$ac_cv_path_SORT
9178 if test -n "$SORT"; then
9179   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5
9180 $as_echo "$SORT" >&6; }
9181 else
9182   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9183 $as_echo "no" >&6; }
9184 fi
9185 
9186 
9187   test -n "$SORT" && break
9188 done
9189 
9190   else
9191     # The variable is set, but is it from the command line or the environment?
9192 
9193     # Try to remove the string !SORT! from our list.
9194     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SORT!/}
9195     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9196       # If it failed, the variable was not from the command line. Ignore it,
9197       # but warn the user (except for BASH, which is always set by the calling BASH).
9198       if test "xSORT" != xBASH; then
9199         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&5
9200 $as_echo "$as_me: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&2;}
9201       fi
9202       # Try to locate tool using the code snippet
9203       for ac_prog in sort
9204 do
9205   # Extract the first word of "$ac_prog", so it can be a program name with args.
9206 set dummy $ac_prog; ac_word=$2
9207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9208 $as_echo_n "checking for $ac_word... " >&6; }
9209 if ${ac_cv_path_SORT+:} false; then :
9210   $as_echo_n "(cached) " >&6
9211 else
9212   case $SORT in
9213   [\\/]* | ?:[\\/]*)
9214   ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
9215   ;;
9216   *)
9217   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9218 for as_dir in $PATH
9219 do
9220   IFS=$as_save_IFS
9221   test -z "$as_dir" && as_dir=.
9222     for ac_exec_ext in '' $ac_executable_extensions; do
9223   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9224     ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext"
9225     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9226     break 2
9227   fi
9228 done
9229   done
9230 IFS=$as_save_IFS
9231 
9232   ;;
9233 esac
9234 fi
9235 SORT=$ac_cv_path_SORT
9236 if test -n "$SORT"; then
9237   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5
9238 $as_echo "$SORT" >&6; }
9239 else
9240   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9241 $as_echo "no" >&6; }
9242 fi
9243 
9244 
9245   test -n "$SORT" && break
9246 done
9247 
9248     else
9249       # If it succeeded, then it was overridden by the user. We will use it
9250       # for the tool.
9251 
9252       # First remove it from the list of overridden variables, so we can test
9253       # for unknown variables in the end.
9254       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9255 
9256       # Check if the provided tool contains a complete path.
9257       tool_specified="$SORT"
9258       tool_basename="${tool_specified##*/}"
9259       if test "x$tool_basename" = "x$tool_specified"; then
9260         # A command without a complete path is provided, search $PATH.
9261         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SORT=$tool_basename" >&5
9262 $as_echo "$as_me: Will search for user supplied tool SORT=$tool_basename" >&6;}
9263         # Extract the first word of "$tool_basename", so it can be a program name with args.
9264 set dummy $tool_basename; ac_word=$2
9265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9266 $as_echo_n "checking for $ac_word... " >&6; }
9267 if ${ac_cv_path_SORT+:} false; then :
9268   $as_echo_n "(cached) " >&6
9269 else
9270   case $SORT in
9271   [\\/]* | ?:[\\/]*)
9272   ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
9273   ;;
9274   *)
9275   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9276 for as_dir in $PATH
9277 do
9278   IFS=$as_save_IFS
9279   test -z "$as_dir" && as_dir=.
9280     for ac_exec_ext in '' $ac_executable_extensions; do
9281   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9282     ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext"
9283     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9284     break 2
9285   fi
9286 done
9287   done
9288 IFS=$as_save_IFS
9289 
9290   ;;
9291 esac
9292 fi
9293 SORT=$ac_cv_path_SORT
9294 if test -n "$SORT"; then
9295   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5
9296 $as_echo "$SORT" >&6; }
9297 else
9298   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9299 $as_echo "no" >&6; }
9300 fi
9301 
9302 
9303         if test "x$SORT" = x; then
9304           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9305         fi
9306       else
9307         # Otherwise we believe it is a complete path. Use it as it is.
9308         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SORT=$tool_specified" >&5
9309 $as_echo "$as_me: Will use user supplied tool SORT=$tool_specified" >&6;}
9310         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5
9311 $as_echo_n "checking for SORT... " >&6; }
9312         if test ! -x "$tool_specified"; then
9313           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9314 $as_echo "not found" >&6; }
9315           as_fn_error $? "User supplied tool SORT=$tool_specified does not exist or is not executable" "$LINENO" 5
9316         fi
9317         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9318 $as_echo "$tool_specified" >&6; }
9319       fi
9320     fi
9321   fi
9322 
9323 
9324 
9325   if test "x$SORT" = x; then
9326     as_fn_error $? "Could not find required tool for SORT" "$LINENO" 5
9327   fi
9328 
9329 
9330 
9331 
9332 
9333   # Publish this variable in the help.
9334 
9335 
9336   if test "x$TAIL" = x; then
9337     # The variable is not set by user, try to locate tool using the code snippet
9338     for ac_prog in tail
9339 do
9340   # Extract the first word of "$ac_prog", so it can be a program name with args.
9341 set dummy $ac_prog; ac_word=$2
9342 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9343 $as_echo_n "checking for $ac_word... " >&6; }
9344 if ${ac_cv_path_TAIL+:} false; then :
9345   $as_echo_n "(cached) " >&6
9346 else
9347   case $TAIL in
9348   [\\/]* | ?:[\\/]*)
9349   ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path.
9350   ;;
9351   *)
9352   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9353 for as_dir in $PATH
9354 do
9355   IFS=$as_save_IFS
9356   test -z "$as_dir" && as_dir=.
9357     for ac_exec_ext in '' $ac_executable_extensions; do
9358   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9359     ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext"
9360     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9361     break 2
9362   fi
9363 done
9364   done
9365 IFS=$as_save_IFS
9366 
9367   ;;
9368 esac
9369 fi
9370 TAIL=$ac_cv_path_TAIL
9371 if test -n "$TAIL"; then
9372   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5
9373 $as_echo "$TAIL" >&6; }
9374 else
9375   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9376 $as_echo "no" >&6; }
9377 fi
9378 
9379 
9380   test -n "$TAIL" && break
9381 done
9382 
9383   else
9384     # The variable is set, but is it from the command line or the environment?
9385 
9386     # Try to remove the string !TAIL! from our list.
9387     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAIL!/}
9388     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9389       # If it failed, the variable was not from the command line. Ignore it,
9390       # but warn the user (except for BASH, which is always set by the calling BASH).
9391       if test "xTAIL" != xBASH; then
9392         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&5
9393 $as_echo "$as_me: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&2;}
9394       fi
9395       # Try to locate tool using the code snippet
9396       for ac_prog in tail
9397 do
9398   # Extract the first word of "$ac_prog", so it can be a program name with args.
9399 set dummy $ac_prog; ac_word=$2
9400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9401 $as_echo_n "checking for $ac_word... " >&6; }
9402 if ${ac_cv_path_TAIL+:} false; then :
9403   $as_echo_n "(cached) " >&6
9404 else
9405   case $TAIL in
9406   [\\/]* | ?:[\\/]*)
9407   ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path.
9408   ;;
9409   *)
9410   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9411 for as_dir in $PATH
9412 do
9413   IFS=$as_save_IFS
9414   test -z "$as_dir" && as_dir=.
9415     for ac_exec_ext in '' $ac_executable_extensions; do
9416   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9417     ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext"
9418     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9419     break 2
9420   fi
9421 done
9422   done
9423 IFS=$as_save_IFS
9424 
9425   ;;
9426 esac
9427 fi
9428 TAIL=$ac_cv_path_TAIL
9429 if test -n "$TAIL"; then
9430   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5
9431 $as_echo "$TAIL" >&6; }
9432 else
9433   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9434 $as_echo "no" >&6; }
9435 fi
9436 
9437 
9438   test -n "$TAIL" && break
9439 done
9440 
9441     else
9442       # If it succeeded, then it was overridden by the user. We will use it
9443       # for the tool.
9444 
9445       # First remove it from the list of overridden variables, so we can test
9446       # for unknown variables in the end.
9447       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9448 
9449       # Check if the provided tool contains a complete path.
9450       tool_specified="$TAIL"
9451       tool_basename="${tool_specified##*/}"
9452       if test "x$tool_basename" = "x$tool_specified"; then
9453         # A command without a complete path is provided, search $PATH.
9454         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAIL=$tool_basename" >&5
9455 $as_echo "$as_me: Will search for user supplied tool TAIL=$tool_basename" >&6;}
9456         # Extract the first word of "$tool_basename", so it can be a program name with args.
9457 set dummy $tool_basename; ac_word=$2
9458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9459 $as_echo_n "checking for $ac_word... " >&6; }
9460 if ${ac_cv_path_TAIL+:} false; then :
9461   $as_echo_n "(cached) " >&6
9462 else
9463   case $TAIL in
9464   [\\/]* | ?:[\\/]*)
9465   ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path.
9466   ;;
9467   *)
9468   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9469 for as_dir in $PATH
9470 do
9471   IFS=$as_save_IFS
9472   test -z "$as_dir" && as_dir=.
9473     for ac_exec_ext in '' $ac_executable_extensions; do
9474   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9475     ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext"
9476     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9477     break 2
9478   fi
9479 done
9480   done
9481 IFS=$as_save_IFS
9482 
9483   ;;
9484 esac
9485 fi
9486 TAIL=$ac_cv_path_TAIL
9487 if test -n "$TAIL"; then
9488   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5
9489 $as_echo "$TAIL" >&6; }
9490 else
9491   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9492 $as_echo "no" >&6; }
9493 fi
9494 
9495 
9496         if test "x$TAIL" = x; then
9497           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9498         fi
9499       else
9500         # Otherwise we believe it is a complete path. Use it as it is.
9501         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAIL=$tool_specified" >&5
9502 $as_echo "$as_me: Will use user supplied tool TAIL=$tool_specified" >&6;}
9503         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5
9504 $as_echo_n "checking for TAIL... " >&6; }
9505         if test ! -x "$tool_specified"; then
9506           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9507 $as_echo "not found" >&6; }
9508           as_fn_error $? "User supplied tool TAIL=$tool_specified does not exist or is not executable" "$LINENO" 5
9509         fi
9510         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9511 $as_echo "$tool_specified" >&6; }
9512       fi
9513     fi
9514   fi
9515 
9516 
9517 
9518   if test "x$TAIL" = x; then
9519     as_fn_error $? "Could not find required tool for TAIL" "$LINENO" 5
9520   fi
9521 
9522 
9523 
9524 
9525 
9526   # Publish this variable in the help.
9527 
9528 
9529   if test "x$TAR" = x; then
9530     # The variable is not set by user, try to locate tool using the code snippet
9531     for ac_prog in tar
9532 do
9533   # Extract the first word of "$ac_prog", so it can be a program name with args.
9534 set dummy $ac_prog; ac_word=$2
9535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9536 $as_echo_n "checking for $ac_word... " >&6; }
9537 if ${ac_cv_path_TAR+:} false; then :
9538   $as_echo_n "(cached) " >&6
9539 else
9540   case $TAR in
9541   [\\/]* | ?:[\\/]*)
9542   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9543   ;;
9544   *)
9545   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9546 for as_dir in $PATH
9547 do
9548   IFS=$as_save_IFS
9549   test -z "$as_dir" && as_dir=.
9550     for ac_exec_ext in '' $ac_executable_extensions; do
9551   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9552     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9553     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9554     break 2
9555   fi
9556 done
9557   done
9558 IFS=$as_save_IFS
9559 
9560   ;;
9561 esac
9562 fi
9563 TAR=$ac_cv_path_TAR
9564 if test -n "$TAR"; then
9565   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9566 $as_echo "$TAR" >&6; }
9567 else
9568   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9569 $as_echo "no" >&6; }
9570 fi
9571 
9572 
9573   test -n "$TAR" && break
9574 done
9575 
9576   else
9577     # The variable is set, but is it from the command line or the environment?
9578 
9579     # Try to remove the string !TAR! from our list.
9580     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAR!/}
9581     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9582       # If it failed, the variable was not from the command line. Ignore it,
9583       # but warn the user (except for BASH, which is always set by the calling BASH).
9584       if test "xTAR" != xBASH; then
9585         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&5
9586 $as_echo "$as_me: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&2;}
9587       fi
9588       # Try to locate tool using the code snippet
9589       for ac_prog in tar
9590 do
9591   # Extract the first word of "$ac_prog", so it can be a program name with args.
9592 set dummy $ac_prog; ac_word=$2
9593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9594 $as_echo_n "checking for $ac_word... " >&6; }
9595 if ${ac_cv_path_TAR+:} false; then :
9596   $as_echo_n "(cached) " >&6
9597 else
9598   case $TAR in
9599   [\\/]* | ?:[\\/]*)
9600   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9601   ;;
9602   *)
9603   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9604 for as_dir in $PATH
9605 do
9606   IFS=$as_save_IFS
9607   test -z "$as_dir" && as_dir=.
9608     for ac_exec_ext in '' $ac_executable_extensions; do
9609   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9610     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9611     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9612     break 2
9613   fi
9614 done
9615   done
9616 IFS=$as_save_IFS
9617 
9618   ;;
9619 esac
9620 fi
9621 TAR=$ac_cv_path_TAR
9622 if test -n "$TAR"; then
9623   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9624 $as_echo "$TAR" >&6; }
9625 else
9626   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9627 $as_echo "no" >&6; }
9628 fi
9629 
9630 
9631   test -n "$TAR" && break
9632 done
9633 
9634     else
9635       # If it succeeded, then it was overridden by the user. We will use it
9636       # for the tool.
9637 
9638       # First remove it from the list of overridden variables, so we can test
9639       # for unknown variables in the end.
9640       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9641 
9642       # Check if the provided tool contains a complete path.
9643       tool_specified="$TAR"
9644       tool_basename="${tool_specified##*/}"
9645       if test "x$tool_basename" = "x$tool_specified"; then
9646         # A command without a complete path is provided, search $PATH.
9647         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAR=$tool_basename" >&5
9648 $as_echo "$as_me: Will search for user supplied tool TAR=$tool_basename" >&6;}
9649         # Extract the first word of "$tool_basename", so it can be a program name with args.
9650 set dummy $tool_basename; ac_word=$2
9651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9652 $as_echo_n "checking for $ac_word... " >&6; }
9653 if ${ac_cv_path_TAR+:} false; then :
9654   $as_echo_n "(cached) " >&6
9655 else
9656   case $TAR in
9657   [\\/]* | ?:[\\/]*)
9658   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9659   ;;
9660   *)
9661   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9662 for as_dir in $PATH
9663 do
9664   IFS=$as_save_IFS
9665   test -z "$as_dir" && as_dir=.
9666     for ac_exec_ext in '' $ac_executable_extensions; do
9667   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9668     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9669     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9670     break 2
9671   fi
9672 done
9673   done
9674 IFS=$as_save_IFS
9675 
9676   ;;
9677 esac
9678 fi
9679 TAR=$ac_cv_path_TAR
9680 if test -n "$TAR"; then
9681   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9682 $as_echo "$TAR" >&6; }
9683 else
9684   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9685 $as_echo "no" >&6; }
9686 fi
9687 
9688 
9689         if test "x$TAR" = x; then
9690           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9691         fi
9692       else
9693         # Otherwise we believe it is a complete path. Use it as it is.
9694         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAR=$tool_specified" >&5
9695 $as_echo "$as_me: Will use user supplied tool TAR=$tool_specified" >&6;}
9696         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5
9697 $as_echo_n "checking for TAR... " >&6; }
9698         if test ! -x "$tool_specified"; then
9699           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9700 $as_echo "not found" >&6; }
9701           as_fn_error $? "User supplied tool TAR=$tool_specified does not exist or is not executable" "$LINENO" 5
9702         fi
9703         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9704 $as_echo "$tool_specified" >&6; }
9705       fi
9706     fi
9707   fi
9708 
9709 
9710 
9711   if test "x$TAR" = x; then
9712     as_fn_error $? "Could not find required tool for TAR" "$LINENO" 5
9713   fi
9714 
9715 
9716 
9717 
9718 
9719   # Publish this variable in the help.
9720 
9721 
9722   if test "x$TEE" = x; then
9723     # The variable is not set by user, try to locate tool using the code snippet
9724     for ac_prog in tee
9725 do
9726   # Extract the first word of "$ac_prog", so it can be a program name with args.
9727 set dummy $ac_prog; ac_word=$2
9728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9729 $as_echo_n "checking for $ac_word... " >&6; }
9730 if ${ac_cv_path_TEE+:} false; then :
9731   $as_echo_n "(cached) " >&6
9732 else
9733   case $TEE in
9734   [\\/]* | ?:[\\/]*)
9735   ac_cv_path_TEE="$TEE" # Let the user override the test with a path.
9736   ;;
9737   *)
9738   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9739 for as_dir in $PATH
9740 do
9741   IFS=$as_save_IFS
9742   test -z "$as_dir" && as_dir=.
9743     for ac_exec_ext in '' $ac_executable_extensions; do
9744   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9745     ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext"
9746     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9747     break 2
9748   fi
9749 done
9750   done
9751 IFS=$as_save_IFS
9752 
9753   ;;
9754 esac
9755 fi
9756 TEE=$ac_cv_path_TEE
9757 if test -n "$TEE"; then
9758   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5
9759 $as_echo "$TEE" >&6; }
9760 else
9761   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9762 $as_echo "no" >&6; }
9763 fi
9764 
9765 
9766   test -n "$TEE" && break
9767 done
9768 
9769   else
9770     # The variable is set, but is it from the command line or the environment?
9771 
9772     # Try to remove the string !TEE! from our list.
9773     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TEE!/}
9774     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9775       # If it failed, the variable was not from the command line. Ignore it,
9776       # but warn the user (except for BASH, which is always set by the calling BASH).
9777       if test "xTEE" != xBASH; then
9778         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&5
9779 $as_echo "$as_me: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&2;}
9780       fi
9781       # Try to locate tool using the code snippet
9782       for ac_prog in tee
9783 do
9784   # Extract the first word of "$ac_prog", so it can be a program name with args.
9785 set dummy $ac_prog; ac_word=$2
9786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9787 $as_echo_n "checking for $ac_word... " >&6; }
9788 if ${ac_cv_path_TEE+:} false; then :
9789   $as_echo_n "(cached) " >&6
9790 else
9791   case $TEE in
9792   [\\/]* | ?:[\\/]*)
9793   ac_cv_path_TEE="$TEE" # Let the user override the test with a path.
9794   ;;
9795   *)
9796   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9797 for as_dir in $PATH
9798 do
9799   IFS=$as_save_IFS
9800   test -z "$as_dir" && as_dir=.
9801     for ac_exec_ext in '' $ac_executable_extensions; do
9802   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9803     ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext"
9804     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9805     break 2
9806   fi
9807 done
9808   done
9809 IFS=$as_save_IFS
9810 
9811   ;;
9812 esac
9813 fi
9814 TEE=$ac_cv_path_TEE
9815 if test -n "$TEE"; then
9816   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5
9817 $as_echo "$TEE" >&6; }
9818 else
9819   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9820 $as_echo "no" >&6; }
9821 fi
9822 
9823 
9824   test -n "$TEE" && break
9825 done
9826 
9827     else
9828       # If it succeeded, then it was overridden by the user. We will use it
9829       # for the tool.
9830 
9831       # First remove it from the list of overridden variables, so we can test
9832       # for unknown variables in the end.
9833       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9834 
9835       # Check if the provided tool contains a complete path.
9836       tool_specified="$TEE"
9837       tool_basename="${tool_specified##*/}"
9838       if test "x$tool_basename" = "x$tool_specified"; then
9839         # A command without a complete path is provided, search $PATH.
9840         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TEE=$tool_basename" >&5
9841 $as_echo "$as_me: Will search for user supplied tool TEE=$tool_basename" >&6;}
9842         # Extract the first word of "$tool_basename", so it can be a program name with args.
9843 set dummy $tool_basename; ac_word=$2
9844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9845 $as_echo_n "checking for $ac_word... " >&6; }
9846 if ${ac_cv_path_TEE+:} false; then :
9847   $as_echo_n "(cached) " >&6
9848 else
9849   case $TEE in
9850   [\\/]* | ?:[\\/]*)
9851   ac_cv_path_TEE="$TEE" # Let the user override the test with a path.
9852   ;;
9853   *)
9854   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9855 for as_dir in $PATH
9856 do
9857   IFS=$as_save_IFS
9858   test -z "$as_dir" && as_dir=.
9859     for ac_exec_ext in '' $ac_executable_extensions; do
9860   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9861     ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext"
9862     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9863     break 2
9864   fi
9865 done
9866   done
9867 IFS=$as_save_IFS
9868 
9869   ;;
9870 esac
9871 fi
9872 TEE=$ac_cv_path_TEE
9873 if test -n "$TEE"; then
9874   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5
9875 $as_echo "$TEE" >&6; }
9876 else
9877   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9878 $as_echo "no" >&6; }
9879 fi
9880 
9881 
9882         if test "x$TEE" = x; then
9883           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9884         fi
9885       else
9886         # Otherwise we believe it is a complete path. Use it as it is.
9887         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TEE=$tool_specified" >&5
9888 $as_echo "$as_me: Will use user supplied tool TEE=$tool_specified" >&6;}
9889         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5
9890 $as_echo_n "checking for TEE... " >&6; }
9891         if test ! -x "$tool_specified"; then
9892           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9893 $as_echo "not found" >&6; }
9894           as_fn_error $? "User supplied tool TEE=$tool_specified does not exist or is not executable" "$LINENO" 5
9895         fi
9896         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9897 $as_echo "$tool_specified" >&6; }
9898       fi
9899     fi
9900   fi
9901 
9902 
9903 
9904   if test "x$TEE" = x; then
9905     as_fn_error $? "Could not find required tool for TEE" "$LINENO" 5
9906   fi
9907 
9908 
9909 
9910 
9911 
9912   # Publish this variable in the help.
9913 
9914 
9915   if test "x$TOUCH" = x; then
9916     # The variable is not set by user, try to locate tool using the code snippet
9917     for ac_prog in touch
9918 do
9919   # Extract the first word of "$ac_prog", so it can be a program name with args.
9920 set dummy $ac_prog; ac_word=$2
9921 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9922 $as_echo_n "checking for $ac_word... " >&6; }
9923 if ${ac_cv_path_TOUCH+:} false; then :
9924   $as_echo_n "(cached) " >&6
9925 else
9926   case $TOUCH in
9927   [\\/]* | ?:[\\/]*)
9928   ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path.
9929   ;;
9930   *)
9931   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9932 for as_dir in $PATH
9933 do
9934   IFS=$as_save_IFS
9935   test -z "$as_dir" && as_dir=.
9936     for ac_exec_ext in '' $ac_executable_extensions; do
9937   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9938     ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext"
9939     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9940     break 2
9941   fi
9942 done
9943   done
9944 IFS=$as_save_IFS
9945 
9946   ;;
9947 esac
9948 fi
9949 TOUCH=$ac_cv_path_TOUCH
9950 if test -n "$TOUCH"; then
9951   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5
9952 $as_echo "$TOUCH" >&6; }
9953 else
9954   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9955 $as_echo "no" >&6; }
9956 fi
9957 
9958 
9959   test -n "$TOUCH" && break
9960 done
9961 
9962   else
9963     # The variable is set, but is it from the command line or the environment?
9964 
9965     # Try to remove the string !TOUCH! from our list.
9966     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TOUCH!/}
9967     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9968       # If it failed, the variable was not from the command line. Ignore it,
9969       # but warn the user (except for BASH, which is always set by the calling BASH).
9970       if test "xTOUCH" != xBASH; then
9971         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&5
9972 $as_echo "$as_me: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&2;}
9973       fi
9974       # Try to locate tool using the code snippet
9975       for ac_prog in touch
9976 do
9977   # Extract the first word of "$ac_prog", so it can be a program name with args.
9978 set dummy $ac_prog; ac_word=$2
9979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9980 $as_echo_n "checking for $ac_word... " >&6; }
9981 if ${ac_cv_path_TOUCH+:} false; then :
9982   $as_echo_n "(cached) " >&6
9983 else
9984   case $TOUCH in
9985   [\\/]* | ?:[\\/]*)
9986   ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path.
9987   ;;
9988   *)
9989   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9990 for as_dir in $PATH
9991 do
9992   IFS=$as_save_IFS
9993   test -z "$as_dir" && as_dir=.
9994     for ac_exec_ext in '' $ac_executable_extensions; do
9995   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9996     ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext"
9997     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9998     break 2
9999   fi
10000 done
10001   done
10002 IFS=$as_save_IFS
10003 
10004   ;;
10005 esac
10006 fi
10007 TOUCH=$ac_cv_path_TOUCH
10008 if test -n "$TOUCH"; then
10009   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5
10010 $as_echo "$TOUCH" >&6; }
10011 else
10012   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10013 $as_echo "no" >&6; }
10014 fi
10015 
10016 
10017   test -n "$TOUCH" && break
10018 done
10019 
10020     else
10021       # If it succeeded, then it was overridden by the user. We will use it
10022       # for the tool.
10023 
10024       # First remove it from the list of overridden variables, so we can test
10025       # for unknown variables in the end.
10026       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10027 
10028       # Check if the provided tool contains a complete path.
10029       tool_specified="$TOUCH"
10030       tool_basename="${tool_specified##*/}"
10031       if test "x$tool_basename" = "x$tool_specified"; then
10032         # A command without a complete path is provided, search $PATH.
10033         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TOUCH=$tool_basename" >&5
10034 $as_echo "$as_me: Will search for user supplied tool TOUCH=$tool_basename" >&6;}
10035         # Extract the first word of "$tool_basename", so it can be a program name with args.
10036 set dummy $tool_basename; ac_word=$2
10037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10038 $as_echo_n "checking for $ac_word... " >&6; }
10039 if ${ac_cv_path_TOUCH+:} false; then :
10040   $as_echo_n "(cached) " >&6
10041 else
10042   case $TOUCH in
10043   [\\/]* | ?:[\\/]*)
10044   ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path.
10045   ;;
10046   *)
10047   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10048 for as_dir in $PATH
10049 do
10050   IFS=$as_save_IFS
10051   test -z "$as_dir" && as_dir=.
10052     for ac_exec_ext in '' $ac_executable_extensions; do
10053   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10054     ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext"
10055     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10056     break 2
10057   fi
10058 done
10059   done
10060 IFS=$as_save_IFS
10061 
10062   ;;
10063 esac
10064 fi
10065 TOUCH=$ac_cv_path_TOUCH
10066 if test -n "$TOUCH"; then
10067   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5
10068 $as_echo "$TOUCH" >&6; }
10069 else
10070   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10071 $as_echo "no" >&6; }
10072 fi
10073 
10074 
10075         if test "x$TOUCH" = x; then
10076           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10077         fi
10078       else
10079         # Otherwise we believe it is a complete path. Use it as it is.
10080         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TOUCH=$tool_specified" >&5
10081 $as_echo "$as_me: Will use user supplied tool TOUCH=$tool_specified" >&6;}
10082         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5
10083 $as_echo_n "checking for TOUCH... " >&6; }
10084         if test ! -x "$tool_specified"; then
10085           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10086 $as_echo "not found" >&6; }
10087           as_fn_error $? "User supplied tool TOUCH=$tool_specified does not exist or is not executable" "$LINENO" 5
10088         fi
10089         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10090 $as_echo "$tool_specified" >&6; }
10091       fi
10092     fi
10093   fi
10094 
10095 
10096 
10097   if test "x$TOUCH" = x; then
10098     as_fn_error $? "Could not find required tool for TOUCH" "$LINENO" 5
10099   fi
10100 
10101 
10102 
10103 
10104 
10105   # Publish this variable in the help.
10106 
10107 
10108   if test "x$TR" = x; then
10109     # The variable is not set by user, try to locate tool using the code snippet
10110     for ac_prog in tr
10111 do
10112   # Extract the first word of "$ac_prog", so it can be a program name with args.
10113 set dummy $ac_prog; ac_word=$2
10114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10115 $as_echo_n "checking for $ac_word... " >&6; }
10116 if ${ac_cv_path_TR+:} false; then :
10117   $as_echo_n "(cached) " >&6
10118 else
10119   case $TR in
10120   [\\/]* | ?:[\\/]*)
10121   ac_cv_path_TR="$TR" # Let the user override the test with a path.
10122   ;;
10123   *)
10124   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10125 for as_dir in $PATH
10126 do
10127   IFS=$as_save_IFS
10128   test -z "$as_dir" && as_dir=.
10129     for ac_exec_ext in '' $ac_executable_extensions; do
10130   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10131     ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext"
10132     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10133     break 2
10134   fi
10135 done
10136   done
10137 IFS=$as_save_IFS
10138 
10139   ;;
10140 esac
10141 fi
10142 TR=$ac_cv_path_TR
10143 if test -n "$TR"; then
10144   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5
10145 $as_echo "$TR" >&6; }
10146 else
10147   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10148 $as_echo "no" >&6; }
10149 fi
10150 
10151 
10152   test -n "$TR" && break
10153 done
10154 
10155   else
10156     # The variable is set, but is it from the command line or the environment?
10157 
10158     # Try to remove the string !TR! from our list.
10159     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TR!/}
10160     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10161       # If it failed, the variable was not from the command line. Ignore it,
10162       # but warn the user (except for BASH, which is always set by the calling BASH).
10163       if test "xTR" != xBASH; then
10164         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&5
10165 $as_echo "$as_me: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&2;}
10166       fi
10167       # Try to locate tool using the code snippet
10168       for ac_prog in tr
10169 do
10170   # Extract the first word of "$ac_prog", so it can be a program name with args.
10171 set dummy $ac_prog; ac_word=$2
10172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10173 $as_echo_n "checking for $ac_word... " >&6; }
10174 if ${ac_cv_path_TR+:} false; then :
10175   $as_echo_n "(cached) " >&6
10176 else
10177   case $TR in
10178   [\\/]* | ?:[\\/]*)
10179   ac_cv_path_TR="$TR" # Let the user override the test with a path.
10180   ;;
10181   *)
10182   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10183 for as_dir in $PATH
10184 do
10185   IFS=$as_save_IFS
10186   test -z "$as_dir" && as_dir=.
10187     for ac_exec_ext in '' $ac_executable_extensions; do
10188   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10189     ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext"
10190     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10191     break 2
10192   fi
10193 done
10194   done
10195 IFS=$as_save_IFS
10196 
10197   ;;
10198 esac
10199 fi
10200 TR=$ac_cv_path_TR
10201 if test -n "$TR"; then
10202   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5
10203 $as_echo "$TR" >&6; }
10204 else
10205   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10206 $as_echo "no" >&6; }
10207 fi
10208 
10209 
10210   test -n "$TR" && break
10211 done
10212 
10213     else
10214       # If it succeeded, then it was overridden by the user. We will use it
10215       # for the tool.
10216 
10217       # First remove it from the list of overridden variables, so we can test
10218       # for unknown variables in the end.
10219       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10220 
10221       # Check if the provided tool contains a complete path.
10222       tool_specified="$TR"
10223       tool_basename="${tool_specified##*/}"
10224       if test "x$tool_basename" = "x$tool_specified"; then
10225         # A command without a complete path is provided, search $PATH.
10226         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TR=$tool_basename" >&5
10227 $as_echo "$as_me: Will search for user supplied tool TR=$tool_basename" >&6;}
10228         # Extract the first word of "$tool_basename", so it can be a program name with args.
10229 set dummy $tool_basename; ac_word=$2
10230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10231 $as_echo_n "checking for $ac_word... " >&6; }
10232 if ${ac_cv_path_TR+:} false; then :
10233   $as_echo_n "(cached) " >&6
10234 else
10235   case $TR in
10236   [\\/]* | ?:[\\/]*)
10237   ac_cv_path_TR="$TR" # Let the user override the test with a path.
10238   ;;
10239   *)
10240   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10241 for as_dir in $PATH
10242 do
10243   IFS=$as_save_IFS
10244   test -z "$as_dir" && as_dir=.
10245     for ac_exec_ext in '' $ac_executable_extensions; do
10246   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10247     ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext"
10248     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10249     break 2
10250   fi
10251 done
10252   done
10253 IFS=$as_save_IFS
10254 
10255   ;;
10256 esac
10257 fi
10258 TR=$ac_cv_path_TR
10259 if test -n "$TR"; then
10260   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5
10261 $as_echo "$TR" >&6; }
10262 else
10263   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10264 $as_echo "no" >&6; }
10265 fi
10266 
10267 
10268         if test "x$TR" = x; then
10269           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10270         fi
10271       else
10272         # Otherwise we believe it is a complete path. Use it as it is.
10273         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TR=$tool_specified" >&5
10274 $as_echo "$as_me: Will use user supplied tool TR=$tool_specified" >&6;}
10275         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5
10276 $as_echo_n "checking for TR... " >&6; }
10277         if test ! -x "$tool_specified"; then
10278           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10279 $as_echo "not found" >&6; }
10280           as_fn_error $? "User supplied tool TR=$tool_specified does not exist or is not executable" "$LINENO" 5
10281         fi
10282         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10283 $as_echo "$tool_specified" >&6; }
10284       fi
10285     fi
10286   fi
10287 
10288 
10289 
10290   if test "x$TR" = x; then
10291     as_fn_error $? "Could not find required tool for TR" "$LINENO" 5
10292   fi
10293 
10294 
10295 
10296 
10297 
10298   # Publish this variable in the help.
10299 
10300 
10301   if test "x$UNAME" = x; then
10302     # The variable is not set by user, try to locate tool using the code snippet
10303     for ac_prog in uname
10304 do
10305   # Extract the first word of "$ac_prog", so it can be a program name with args.
10306 set dummy $ac_prog; ac_word=$2
10307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10308 $as_echo_n "checking for $ac_word... " >&6; }
10309 if ${ac_cv_path_UNAME+:} false; then :
10310   $as_echo_n "(cached) " >&6
10311 else
10312   case $UNAME in
10313   [\\/]* | ?:[\\/]*)
10314   ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
10315   ;;
10316   *)
10317   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10318 for as_dir in $PATH
10319 do
10320   IFS=$as_save_IFS
10321   test -z "$as_dir" && as_dir=.
10322     for ac_exec_ext in '' $ac_executable_extensions; do
10323   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10324     ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
10325     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10326     break 2
10327   fi
10328 done
10329   done
10330 IFS=$as_save_IFS
10331 
10332   ;;
10333 esac
10334 fi
10335 UNAME=$ac_cv_path_UNAME
10336 if test -n "$UNAME"; then
10337   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
10338 $as_echo "$UNAME" >&6; }
10339 else
10340   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10341 $as_echo "no" >&6; }
10342 fi
10343 
10344 
10345   test -n "$UNAME" && break
10346 done
10347 
10348   else
10349     # The variable is set, but is it from the command line or the environment?
10350 
10351     # Try to remove the string !UNAME! from our list.
10352     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNAME!/}
10353     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10354       # If it failed, the variable was not from the command line. Ignore it,
10355       # but warn the user (except for BASH, which is always set by the calling BASH).
10356       if test "xUNAME" != xBASH; then
10357         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&5
10358 $as_echo "$as_me: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&2;}
10359       fi
10360       # Try to locate tool using the code snippet
10361       for ac_prog in uname
10362 do
10363   # Extract the first word of "$ac_prog", so it can be a program name with args.
10364 set dummy $ac_prog; ac_word=$2
10365 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10366 $as_echo_n "checking for $ac_word... " >&6; }
10367 if ${ac_cv_path_UNAME+:} false; then :
10368   $as_echo_n "(cached) " >&6
10369 else
10370   case $UNAME in
10371   [\\/]* | ?:[\\/]*)
10372   ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
10373   ;;
10374   *)
10375   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10376 for as_dir in $PATH
10377 do
10378   IFS=$as_save_IFS
10379   test -z "$as_dir" && as_dir=.
10380     for ac_exec_ext in '' $ac_executable_extensions; do
10381   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10382     ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
10383     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10384     break 2
10385   fi
10386 done
10387   done
10388 IFS=$as_save_IFS
10389 
10390   ;;
10391 esac
10392 fi
10393 UNAME=$ac_cv_path_UNAME
10394 if test -n "$UNAME"; then
10395   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
10396 $as_echo "$UNAME" >&6; }
10397 else
10398   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10399 $as_echo "no" >&6; }
10400 fi
10401 
10402 
10403   test -n "$UNAME" && break
10404 done
10405 
10406     else
10407       # If it succeeded, then it was overridden by the user. We will use it
10408       # for the tool.
10409 
10410       # First remove it from the list of overridden variables, so we can test
10411       # for unknown variables in the end.
10412       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10413 
10414       # Check if the provided tool contains a complete path.
10415       tool_specified="$UNAME"
10416       tool_basename="${tool_specified##*/}"
10417       if test "x$tool_basename" = "x$tool_specified"; then
10418         # A command without a complete path is provided, search $PATH.
10419         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNAME=$tool_basename" >&5
10420 $as_echo "$as_me: Will search for user supplied tool UNAME=$tool_basename" >&6;}
10421         # Extract the first word of "$tool_basename", so it can be a program name with args.
10422 set dummy $tool_basename; ac_word=$2
10423 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10424 $as_echo_n "checking for $ac_word... " >&6; }
10425 if ${ac_cv_path_UNAME+:} false; then :
10426   $as_echo_n "(cached) " >&6
10427 else
10428   case $UNAME in
10429   [\\/]* | ?:[\\/]*)
10430   ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
10431   ;;
10432   *)
10433   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10434 for as_dir in $PATH
10435 do
10436   IFS=$as_save_IFS
10437   test -z "$as_dir" && as_dir=.
10438     for ac_exec_ext in '' $ac_executable_extensions; do
10439   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10440     ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
10441     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10442     break 2
10443   fi
10444 done
10445   done
10446 IFS=$as_save_IFS
10447 
10448   ;;
10449 esac
10450 fi
10451 UNAME=$ac_cv_path_UNAME
10452 if test -n "$UNAME"; then
10453   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
10454 $as_echo "$UNAME" >&6; }
10455 else
10456   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10457 $as_echo "no" >&6; }
10458 fi
10459 
10460 
10461         if test "x$UNAME" = x; then
10462           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10463         fi
10464       else
10465         # Otherwise we believe it is a complete path. Use it as it is.
10466         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNAME=$tool_specified" >&5
10467 $as_echo "$as_me: Will use user supplied tool UNAME=$tool_specified" >&6;}
10468         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5
10469 $as_echo_n "checking for UNAME... " >&6; }
10470         if test ! -x "$tool_specified"; then
10471           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10472 $as_echo "not found" >&6; }
10473           as_fn_error $? "User supplied tool UNAME=$tool_specified does not exist or is not executable" "$LINENO" 5
10474         fi
10475         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10476 $as_echo "$tool_specified" >&6; }
10477       fi
10478     fi
10479   fi
10480 
10481 
10482 
10483   if test "x$UNAME" = x; then
10484     as_fn_error $? "Could not find required tool for UNAME" "$LINENO" 5
10485   fi
10486 
10487 
10488 
10489 
10490 
10491   # Publish this variable in the help.
10492 
10493 
10494   if test "x$UNIQ" = x; then
10495     # The variable is not set by user, try to locate tool using the code snippet
10496     for ac_prog in uniq
10497 do
10498   # Extract the first word of "$ac_prog", so it can be a program name with args.
10499 set dummy $ac_prog; ac_word=$2
10500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10501 $as_echo_n "checking for $ac_word... " >&6; }
10502 if ${ac_cv_path_UNIQ+:} false; then :
10503   $as_echo_n "(cached) " >&6
10504 else
10505   case $UNIQ in
10506   [\\/]* | ?:[\\/]*)
10507   ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path.
10508   ;;
10509   *)
10510   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10511 for as_dir in $PATH
10512 do
10513   IFS=$as_save_IFS
10514   test -z "$as_dir" && as_dir=.
10515     for ac_exec_ext in '' $ac_executable_extensions; do
10516   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10517     ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext"
10518     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10519     break 2
10520   fi
10521 done
10522   done
10523 IFS=$as_save_IFS
10524 
10525   ;;
10526 esac
10527 fi
10528 UNIQ=$ac_cv_path_UNIQ
10529 if test -n "$UNIQ"; then
10530   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5
10531 $as_echo "$UNIQ" >&6; }
10532 else
10533   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10534 $as_echo "no" >&6; }
10535 fi
10536 
10537 
10538   test -n "$UNIQ" && break
10539 done
10540 
10541   else
10542     # The variable is set, but is it from the command line or the environment?
10543 
10544     # Try to remove the string !UNIQ! from our list.
10545     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNIQ!/}
10546     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10547       # If it failed, the variable was not from the command line. Ignore it,
10548       # but warn the user (except for BASH, which is always set by the calling BASH).
10549       if test "xUNIQ" != xBASH; then
10550         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&5
10551 $as_echo "$as_me: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&2;}
10552       fi
10553       # Try to locate tool using the code snippet
10554       for ac_prog in uniq
10555 do
10556   # Extract the first word of "$ac_prog", so it can be a program name with args.
10557 set dummy $ac_prog; ac_word=$2
10558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10559 $as_echo_n "checking for $ac_word... " >&6; }
10560 if ${ac_cv_path_UNIQ+:} false; then :
10561   $as_echo_n "(cached) " >&6
10562 else
10563   case $UNIQ in
10564   [\\/]* | ?:[\\/]*)
10565   ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path.
10566   ;;
10567   *)
10568   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10569 for as_dir in $PATH
10570 do
10571   IFS=$as_save_IFS
10572   test -z "$as_dir" && as_dir=.
10573     for ac_exec_ext in '' $ac_executable_extensions; do
10574   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10575     ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext"
10576     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10577     break 2
10578   fi
10579 done
10580   done
10581 IFS=$as_save_IFS
10582 
10583   ;;
10584 esac
10585 fi
10586 UNIQ=$ac_cv_path_UNIQ
10587 if test -n "$UNIQ"; then
10588   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5
10589 $as_echo "$UNIQ" >&6; }
10590 else
10591   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10592 $as_echo "no" >&6; }
10593 fi
10594 
10595 
10596   test -n "$UNIQ" && break
10597 done
10598 
10599     else
10600       # If it succeeded, then it was overridden by the user. We will use it
10601       # for the tool.
10602 
10603       # First remove it from the list of overridden variables, so we can test
10604       # for unknown variables in the end.
10605       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10606 
10607       # Check if the provided tool contains a complete path.
10608       tool_specified="$UNIQ"
10609       tool_basename="${tool_specified##*/}"
10610       if test "x$tool_basename" = "x$tool_specified"; then
10611         # A command without a complete path is provided, search $PATH.
10612         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNIQ=$tool_basename" >&5
10613 $as_echo "$as_me: Will search for user supplied tool UNIQ=$tool_basename" >&6;}
10614         # Extract the first word of "$tool_basename", so it can be a program name with args.
10615 set dummy $tool_basename; ac_word=$2
10616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10617 $as_echo_n "checking for $ac_word... " >&6; }
10618 if ${ac_cv_path_UNIQ+:} false; then :
10619   $as_echo_n "(cached) " >&6
10620 else
10621   case $UNIQ in
10622   [\\/]* | ?:[\\/]*)
10623   ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path.
10624   ;;
10625   *)
10626   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10627 for as_dir in $PATH
10628 do
10629   IFS=$as_save_IFS
10630   test -z "$as_dir" && as_dir=.
10631     for ac_exec_ext in '' $ac_executable_extensions; do
10632   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10633     ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext"
10634     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10635     break 2
10636   fi
10637 done
10638   done
10639 IFS=$as_save_IFS
10640 
10641   ;;
10642 esac
10643 fi
10644 UNIQ=$ac_cv_path_UNIQ
10645 if test -n "$UNIQ"; then
10646   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5
10647 $as_echo "$UNIQ" >&6; }
10648 else
10649   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10650 $as_echo "no" >&6; }
10651 fi
10652 
10653 
10654         if test "x$UNIQ" = x; then
10655           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10656         fi
10657       else
10658         # Otherwise we believe it is a complete path. Use it as it is.
10659         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNIQ=$tool_specified" >&5
10660 $as_echo "$as_me: Will use user supplied tool UNIQ=$tool_specified" >&6;}
10661         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5
10662 $as_echo_n "checking for UNIQ... " >&6; }
10663         if test ! -x "$tool_specified"; then
10664           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10665 $as_echo "not found" >&6; }
10666           as_fn_error $? "User supplied tool UNIQ=$tool_specified does not exist or is not executable" "$LINENO" 5
10667         fi
10668         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10669 $as_echo "$tool_specified" >&6; }
10670       fi
10671     fi
10672   fi
10673 
10674 
10675 
10676   if test "x$UNIQ" = x; then
10677     as_fn_error $? "Could not find required tool for UNIQ" "$LINENO" 5
10678   fi
10679 
10680 
10681 
10682 
10683 
10684   # Publish this variable in the help.
10685 
10686 
10687   if test "x$WC" = x; then
10688     # The variable is not set by user, try to locate tool using the code snippet
10689     for ac_prog in wc
10690 do
10691   # Extract the first word of "$ac_prog", so it can be a program name with args.
10692 set dummy $ac_prog; ac_word=$2
10693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10694 $as_echo_n "checking for $ac_word... " >&6; }
10695 if ${ac_cv_path_WC+:} false; then :
10696   $as_echo_n "(cached) " >&6
10697 else
10698   case $WC in
10699   [\\/]* | ?:[\\/]*)
10700   ac_cv_path_WC="$WC" # Let the user override the test with a path.
10701   ;;
10702   *)
10703   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10704 for as_dir in $PATH
10705 do
10706   IFS=$as_save_IFS
10707   test -z "$as_dir" && as_dir=.
10708     for ac_exec_ext in '' $ac_executable_extensions; do
10709   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10710     ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext"
10711     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10712     break 2
10713   fi
10714 done
10715   done
10716 IFS=$as_save_IFS
10717 
10718   ;;
10719 esac
10720 fi
10721 WC=$ac_cv_path_WC
10722 if test -n "$WC"; then
10723   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5
10724 $as_echo "$WC" >&6; }
10725 else
10726   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10727 $as_echo "no" >&6; }
10728 fi
10729 
10730 
10731   test -n "$WC" && break
10732 done
10733 
10734   else
10735     # The variable is set, but is it from the command line or the environment?
10736 
10737     # Try to remove the string !WC! from our list.
10738     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WC!/}
10739     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10740       # If it failed, the variable was not from the command line. Ignore it,
10741       # but warn the user (except for BASH, which is always set by the calling BASH).
10742       if test "xWC" != xBASH; then
10743         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&5
10744 $as_echo "$as_me: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&2;}
10745       fi
10746       # Try to locate tool using the code snippet
10747       for ac_prog in wc
10748 do
10749   # Extract the first word of "$ac_prog", so it can be a program name with args.
10750 set dummy $ac_prog; ac_word=$2
10751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10752 $as_echo_n "checking for $ac_word... " >&6; }
10753 if ${ac_cv_path_WC+:} false; then :
10754   $as_echo_n "(cached) " >&6
10755 else
10756   case $WC in
10757   [\\/]* | ?:[\\/]*)
10758   ac_cv_path_WC="$WC" # Let the user override the test with a path.
10759   ;;
10760   *)
10761   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10762 for as_dir in $PATH
10763 do
10764   IFS=$as_save_IFS
10765   test -z "$as_dir" && as_dir=.
10766     for ac_exec_ext in '' $ac_executable_extensions; do
10767   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10768     ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext"
10769     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10770     break 2
10771   fi
10772 done
10773   done
10774 IFS=$as_save_IFS
10775 
10776   ;;
10777 esac
10778 fi
10779 WC=$ac_cv_path_WC
10780 if test -n "$WC"; then
10781   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5
10782 $as_echo "$WC" >&6; }
10783 else
10784   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10785 $as_echo "no" >&6; }
10786 fi
10787 
10788 
10789   test -n "$WC" && break
10790 done
10791 
10792     else
10793       # If it succeeded, then it was overridden by the user. We will use it
10794       # for the tool.
10795 
10796       # First remove it from the list of overridden variables, so we can test
10797       # for unknown variables in the end.
10798       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10799 
10800       # Check if the provided tool contains a complete path.
10801       tool_specified="$WC"
10802       tool_basename="${tool_specified##*/}"
10803       if test "x$tool_basename" = "x$tool_specified"; then
10804         # A command without a complete path is provided, search $PATH.
10805         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WC=$tool_basename" >&5
10806 $as_echo "$as_me: Will search for user supplied tool WC=$tool_basename" >&6;}
10807         # Extract the first word of "$tool_basename", so it can be a program name with args.
10808 set dummy $tool_basename; ac_word=$2
10809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10810 $as_echo_n "checking for $ac_word... " >&6; }
10811 if ${ac_cv_path_WC+:} false; then :
10812   $as_echo_n "(cached) " >&6
10813 else
10814   case $WC in
10815   [\\/]* | ?:[\\/]*)
10816   ac_cv_path_WC="$WC" # Let the user override the test with a path.
10817   ;;
10818   *)
10819   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10820 for as_dir in $PATH
10821 do
10822   IFS=$as_save_IFS
10823   test -z "$as_dir" && as_dir=.
10824     for ac_exec_ext in '' $ac_executable_extensions; do
10825   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10826     ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext"
10827     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10828     break 2
10829   fi
10830 done
10831   done
10832 IFS=$as_save_IFS
10833 
10834   ;;
10835 esac
10836 fi
10837 WC=$ac_cv_path_WC
10838 if test -n "$WC"; then
10839   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5
10840 $as_echo "$WC" >&6; }
10841 else
10842   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10843 $as_echo "no" >&6; }
10844 fi
10845 
10846 
10847         if test "x$WC" = x; then
10848           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10849         fi
10850       else
10851         # Otherwise we believe it is a complete path. Use it as it is.
10852         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WC=$tool_specified" >&5
10853 $as_echo "$as_me: Will use user supplied tool WC=$tool_specified" >&6;}
10854         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5
10855 $as_echo_n "checking for WC... " >&6; }
10856         if test ! -x "$tool_specified"; then
10857           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10858 $as_echo "not found" >&6; }
10859           as_fn_error $? "User supplied tool WC=$tool_specified does not exist or is not executable" "$LINENO" 5
10860         fi
10861         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10862 $as_echo "$tool_specified" >&6; }
10863       fi
10864     fi
10865   fi
10866 
10867 
10868 
10869   if test "x$WC" = x; then
10870     as_fn_error $? "Could not find required tool for WC" "$LINENO" 5
10871   fi
10872 
10873 
10874 
10875 
10876 
10877   # Publish this variable in the help.
10878 
10879 
10880   if test "x$WHICH" = x; then
10881     # The variable is not set by user, try to locate tool using the code snippet
10882     for ac_prog in which
10883 do
10884   # Extract the first word of "$ac_prog", so it can be a program name with args.
10885 set dummy $ac_prog; ac_word=$2
10886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10887 $as_echo_n "checking for $ac_word... " >&6; }
10888 if ${ac_cv_path_WHICH+:} false; then :
10889   $as_echo_n "(cached) " >&6
10890 else
10891   case $WHICH in
10892   [\\/]* | ?:[\\/]*)
10893   ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path.
10894   ;;
10895   *)
10896   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10897 for as_dir in $PATH
10898 do
10899   IFS=$as_save_IFS
10900   test -z "$as_dir" && as_dir=.
10901     for ac_exec_ext in '' $ac_executable_extensions; do
10902   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10903     ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext"
10904     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10905     break 2
10906   fi
10907 done
10908   done
10909 IFS=$as_save_IFS
10910 
10911   ;;
10912 esac
10913 fi
10914 WHICH=$ac_cv_path_WHICH
10915 if test -n "$WHICH"; then
10916   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5
10917 $as_echo "$WHICH" >&6; }
10918 else
10919   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10920 $as_echo "no" >&6; }
10921 fi
10922 
10923 
10924   test -n "$WHICH" && break
10925 done
10926 
10927   else
10928     # The variable is set, but is it from the command line or the environment?
10929 
10930     # Try to remove the string !WHICH! from our list.
10931     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WHICH!/}
10932     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10933       # If it failed, the variable was not from the command line. Ignore it,
10934       # but warn the user (except for BASH, which is always set by the calling BASH).
10935       if test "xWHICH" != xBASH; then
10936         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&5
10937 $as_echo "$as_me: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&2;}
10938       fi
10939       # Try to locate tool using the code snippet
10940       for ac_prog in which
10941 do
10942   # Extract the first word of "$ac_prog", so it can be a program name with args.
10943 set dummy $ac_prog; ac_word=$2
10944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10945 $as_echo_n "checking for $ac_word... " >&6; }
10946 if ${ac_cv_path_WHICH+:} false; then :
10947   $as_echo_n "(cached) " >&6
10948 else
10949   case $WHICH in
10950   [\\/]* | ?:[\\/]*)
10951   ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path.
10952   ;;
10953   *)
10954   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10955 for as_dir in $PATH
10956 do
10957   IFS=$as_save_IFS
10958   test -z "$as_dir" && as_dir=.
10959     for ac_exec_ext in '' $ac_executable_extensions; do
10960   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10961     ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext"
10962     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10963     break 2
10964   fi
10965 done
10966   done
10967 IFS=$as_save_IFS
10968 
10969   ;;
10970 esac
10971 fi
10972 WHICH=$ac_cv_path_WHICH
10973 if test -n "$WHICH"; then
10974   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5
10975 $as_echo "$WHICH" >&6; }
10976 else
10977   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10978 $as_echo "no" >&6; }
10979 fi
10980 
10981 
10982   test -n "$WHICH" && break
10983 done
10984 
10985     else
10986       # If it succeeded, then it was overridden by the user. We will use it
10987       # for the tool.
10988 
10989       # First remove it from the list of overridden variables, so we can test
10990       # for unknown variables in the end.
10991       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10992 
10993       # Check if the provided tool contains a complete path.
10994       tool_specified="$WHICH"
10995       tool_basename="${tool_specified##*/}"
10996       if test "x$tool_basename" = "x$tool_specified"; then
10997         # A command without a complete path is provided, search $PATH.
10998         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WHICH=$tool_basename" >&5
10999 $as_echo "$as_me: Will search for user supplied tool WHICH=$tool_basename" >&6;}
11000         # Extract the first word of "$tool_basename", so it can be a program name with args.
11001 set dummy $tool_basename; ac_word=$2
11002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11003 $as_echo_n "checking for $ac_word... " >&6; }
11004 if ${ac_cv_path_WHICH+:} false; then :
11005   $as_echo_n "(cached) " >&6
11006 else
11007   case $WHICH in
11008   [\\/]* | ?:[\\/]*)
11009   ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path.
11010   ;;
11011   *)
11012   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11013 for as_dir in $PATH
11014 do
11015   IFS=$as_save_IFS
11016   test -z "$as_dir" && as_dir=.
11017     for ac_exec_ext in '' $ac_executable_extensions; do
11018   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11019     ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext"
11020     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11021     break 2
11022   fi
11023 done
11024   done
11025 IFS=$as_save_IFS
11026 
11027   ;;
11028 esac
11029 fi
11030 WHICH=$ac_cv_path_WHICH
11031 if test -n "$WHICH"; then
11032   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5
11033 $as_echo "$WHICH" >&6; }
11034 else
11035   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11036 $as_echo "no" >&6; }
11037 fi
11038 
11039 
11040         if test "x$WHICH" = x; then
11041           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11042         fi
11043       else
11044         # Otherwise we believe it is a complete path. Use it as it is.
11045         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WHICH=$tool_specified" >&5
11046 $as_echo "$as_me: Will use user supplied tool WHICH=$tool_specified" >&6;}
11047         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5
11048 $as_echo_n "checking for WHICH... " >&6; }
11049         if test ! -x "$tool_specified"; then
11050           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11051 $as_echo "not found" >&6; }
11052           as_fn_error $? "User supplied tool WHICH=$tool_specified does not exist or is not executable" "$LINENO" 5
11053         fi
11054         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11055 $as_echo "$tool_specified" >&6; }
11056       fi
11057     fi
11058   fi
11059 
11060 
11061 
11062   if test "x$WHICH" = x; then
11063     as_fn_error $? "Could not find required tool for WHICH" "$LINENO" 5
11064   fi
11065 
11066 
11067 
11068 
11069 
11070   # Publish this variable in the help.
11071 
11072 
11073   if test "x$XARGS" = x; then
11074     # The variable is not set by user, try to locate tool using the code snippet
11075     for ac_prog in xargs
11076 do
11077   # Extract the first word of "$ac_prog", so it can be a program name with args.
11078 set dummy $ac_prog; ac_word=$2
11079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11080 $as_echo_n "checking for $ac_word... " >&6; }
11081 if ${ac_cv_path_XARGS+:} false; then :
11082   $as_echo_n "(cached) " >&6
11083 else
11084   case $XARGS in
11085   [\\/]* | ?:[\\/]*)
11086   ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path.
11087   ;;
11088   *)
11089   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11090 for as_dir in $PATH
11091 do
11092   IFS=$as_save_IFS
11093   test -z "$as_dir" && as_dir=.
11094     for ac_exec_ext in '' $ac_executable_extensions; do
11095   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11096     ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext"
11097     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11098     break 2
11099   fi
11100 done
11101   done
11102 IFS=$as_save_IFS
11103 
11104   ;;
11105 esac
11106 fi
11107 XARGS=$ac_cv_path_XARGS
11108 if test -n "$XARGS"; then
11109   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5
11110 $as_echo "$XARGS" >&6; }
11111 else
11112   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11113 $as_echo "no" >&6; }
11114 fi
11115 
11116 
11117   test -n "$XARGS" && break
11118 done
11119 
11120   else
11121     # The variable is set, but is it from the command line or the environment?
11122 
11123     # Try to remove the string !XARGS! from our list.
11124     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XARGS!/}
11125     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11126       # If it failed, the variable was not from the command line. Ignore it,
11127       # but warn the user (except for BASH, which is always set by the calling BASH).
11128       if test "xXARGS" != xBASH; then
11129         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&5
11130 $as_echo "$as_me: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&2;}
11131       fi
11132       # Try to locate tool using the code snippet
11133       for ac_prog in xargs
11134 do
11135   # Extract the first word of "$ac_prog", so it can be a program name with args.
11136 set dummy $ac_prog; ac_word=$2
11137 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11138 $as_echo_n "checking for $ac_word... " >&6; }
11139 if ${ac_cv_path_XARGS+:} false; then :
11140   $as_echo_n "(cached) " >&6
11141 else
11142   case $XARGS in
11143   [\\/]* | ?:[\\/]*)
11144   ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path.
11145   ;;
11146   *)
11147   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11148 for as_dir in $PATH
11149 do
11150   IFS=$as_save_IFS
11151   test -z "$as_dir" && as_dir=.
11152     for ac_exec_ext in '' $ac_executable_extensions; do
11153   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11154     ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext"
11155     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11156     break 2
11157   fi
11158 done
11159   done
11160 IFS=$as_save_IFS
11161 
11162   ;;
11163 esac
11164 fi
11165 XARGS=$ac_cv_path_XARGS
11166 if test -n "$XARGS"; then
11167   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5
11168 $as_echo "$XARGS" >&6; }
11169 else
11170   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11171 $as_echo "no" >&6; }
11172 fi
11173 
11174 
11175   test -n "$XARGS" && break
11176 done
11177 
11178     else
11179       # If it succeeded, then it was overridden by the user. We will use it
11180       # for the tool.
11181 
11182       # First remove it from the list of overridden variables, so we can test
11183       # for unknown variables in the end.
11184       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11185 
11186       # Check if the provided tool contains a complete path.
11187       tool_specified="$XARGS"
11188       tool_basename="${tool_specified##*/}"
11189       if test "x$tool_basename" = "x$tool_specified"; then
11190         # A command without a complete path is provided, search $PATH.
11191         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XARGS=$tool_basename" >&5
11192 $as_echo "$as_me: Will search for user supplied tool XARGS=$tool_basename" >&6;}
11193         # Extract the first word of "$tool_basename", so it can be a program name with args.
11194 set dummy $tool_basename; ac_word=$2
11195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11196 $as_echo_n "checking for $ac_word... " >&6; }
11197 if ${ac_cv_path_XARGS+:} false; then :
11198   $as_echo_n "(cached) " >&6
11199 else
11200   case $XARGS in
11201   [\\/]* | ?:[\\/]*)
11202   ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path.
11203   ;;
11204   *)
11205   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11206 for as_dir in $PATH
11207 do
11208   IFS=$as_save_IFS
11209   test -z "$as_dir" && as_dir=.
11210     for ac_exec_ext in '' $ac_executable_extensions; do
11211   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11212     ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext"
11213     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11214     break 2
11215   fi
11216 done
11217   done
11218 IFS=$as_save_IFS
11219 
11220   ;;
11221 esac
11222 fi
11223 XARGS=$ac_cv_path_XARGS
11224 if test -n "$XARGS"; then
11225   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5
11226 $as_echo "$XARGS" >&6; }
11227 else
11228   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11229 $as_echo "no" >&6; }
11230 fi
11231 
11232 
11233         if test "x$XARGS" = x; then
11234           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11235         fi
11236       else
11237         # Otherwise we believe it is a complete path. Use it as it is.
11238         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XARGS=$tool_specified" >&5
11239 $as_echo "$as_me: Will use user supplied tool XARGS=$tool_specified" >&6;}
11240         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5
11241 $as_echo_n "checking for XARGS... " >&6; }
11242         if test ! -x "$tool_specified"; then
11243           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11244 $as_echo "not found" >&6; }
11245           as_fn_error $? "User supplied tool XARGS=$tool_specified does not exist or is not executable" "$LINENO" 5
11246         fi
11247         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11248 $as_echo "$tool_specified" >&6; }
11249       fi
11250     fi
11251   fi
11252 
11253 
11254 
11255   if test "x$XARGS" = x; then
11256     as_fn_error $? "Could not find required tool for XARGS" "$LINENO" 5
11257   fi
11258 
11259 
11260 
11261   # Then required tools that require some special treatment.
11262 
11263 
11264   # Publish this variable in the help.
11265 
11266 
11267   if test "x$AWK" = x; then
11268     # The variable is not set by user, try to locate tool using the code snippet
11269     for ac_prog in gawk mawk nawk awk
11270 do
11271   # Extract the first word of "$ac_prog", so it can be a program name with args.
11272 set dummy $ac_prog; ac_word=$2
11273 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11274 $as_echo_n "checking for $ac_word... " >&6; }
11275 if ${ac_cv_prog_AWK+:} false; then :
11276   $as_echo_n "(cached) " >&6
11277 else
11278   if test -n "$AWK"; then
11279   ac_cv_prog_AWK="$AWK" # Let the user override the test.
11280 else
11281 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11282 for as_dir in $PATH
11283 do
11284   IFS=$as_save_IFS
11285   test -z "$as_dir" && as_dir=.
11286     for ac_exec_ext in '' $ac_executable_extensions; do
11287   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11288     ac_cv_prog_AWK="$ac_prog"
11289     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11290     break 2
11291   fi
11292 done
11293   done
11294 IFS=$as_save_IFS
11295 
11296 fi
11297 fi
11298 AWK=$ac_cv_prog_AWK
11299 if test -n "$AWK"; then
11300   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
11301 $as_echo "$AWK" >&6; }
11302 else
11303   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11304 $as_echo "no" >&6; }
11305 fi
11306 
11307 
11308   test -n "$AWK" && break
11309 done
11310 
11311   else
11312     # The variable is set, but is it from the command line or the environment?
11313 
11314     # Try to remove the string !AWK! from our list.
11315     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AWK!/}
11316     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11317       # If it failed, the variable was not from the command line. Ignore it,
11318       # but warn the user (except for BASH, which is always set by the calling BASH).
11319       if test "xAWK" != xBASH; then
11320         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&5
11321 $as_echo "$as_me: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&2;}
11322       fi
11323       # Try to locate tool using the code snippet
11324       for ac_prog in gawk mawk nawk awk
11325 do
11326   # Extract the first word of "$ac_prog", so it can be a program name with args.
11327 set dummy $ac_prog; ac_word=$2
11328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11329 $as_echo_n "checking for $ac_word... " >&6; }
11330 if ${ac_cv_prog_AWK+:} false; then :
11331   $as_echo_n "(cached) " >&6
11332 else
11333   if test -n "$AWK"; then
11334   ac_cv_prog_AWK="$AWK" # Let the user override the test.
11335 else
11336 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11337 for as_dir in $PATH
11338 do
11339   IFS=$as_save_IFS
11340   test -z "$as_dir" && as_dir=.
11341     for ac_exec_ext in '' $ac_executable_extensions; do
11342   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11343     ac_cv_prog_AWK="$ac_prog"
11344     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11345     break 2
11346   fi
11347 done
11348   done
11349 IFS=$as_save_IFS
11350 
11351 fi
11352 fi
11353 AWK=$ac_cv_prog_AWK
11354 if test -n "$AWK"; then
11355   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
11356 $as_echo "$AWK" >&6; }
11357 else
11358   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11359 $as_echo "no" >&6; }
11360 fi
11361 
11362 
11363   test -n "$AWK" && break
11364 done
11365 
11366     else
11367       # If it succeeded, then it was overridden by the user. We will use it
11368       # for the tool.
11369 
11370       # First remove it from the list of overridden variables, so we can test
11371       # for unknown variables in the end.
11372       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11373 
11374       # Check if the provided tool contains a complete path.
11375       tool_specified="$AWK"
11376       tool_basename="${tool_specified##*/}"
11377       if test "x$tool_basename" = "x$tool_specified"; then
11378         # A command without a complete path is provided, search $PATH.
11379         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AWK=$tool_basename" >&5
11380 $as_echo "$as_me: Will search for user supplied tool AWK=$tool_basename" >&6;}
11381         # Extract the first word of "$tool_basename", so it can be a program name with args.
11382 set dummy $tool_basename; ac_word=$2
11383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11384 $as_echo_n "checking for $ac_word... " >&6; }
11385 if ${ac_cv_path_AWK+:} false; then :
11386   $as_echo_n "(cached) " >&6
11387 else
11388   case $AWK in
11389   [\\/]* | ?:[\\/]*)
11390   ac_cv_path_AWK="$AWK" # Let the user override the test with a path.
11391   ;;
11392   *)
11393   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11394 for as_dir in $PATH
11395 do
11396   IFS=$as_save_IFS
11397   test -z "$as_dir" && as_dir=.
11398     for ac_exec_ext in '' $ac_executable_extensions; do
11399   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11400     ac_cv_path_AWK="$as_dir/$ac_word$ac_exec_ext"
11401     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11402     break 2
11403   fi
11404 done
11405   done
11406 IFS=$as_save_IFS
11407 
11408   ;;
11409 esac
11410 fi
11411 AWK=$ac_cv_path_AWK
11412 if test -n "$AWK"; then
11413   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
11414 $as_echo "$AWK" >&6; }
11415 else
11416   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11417 $as_echo "no" >&6; }
11418 fi
11419 
11420 
11421         if test "x$AWK" = x; then
11422           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11423         fi
11424       else
11425         # Otherwise we believe it is a complete path. Use it as it is.
11426         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AWK=$tool_specified" >&5
11427 $as_echo "$as_me: Will use user supplied tool AWK=$tool_specified" >&6;}
11428         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5
11429 $as_echo_n "checking for AWK... " >&6; }
11430         if test ! -x "$tool_specified"; then
11431           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11432 $as_echo "not found" >&6; }
11433           as_fn_error $? "User supplied tool AWK=$tool_specified does not exist or is not executable" "$LINENO" 5
11434         fi
11435         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11436 $as_echo "$tool_specified" >&6; }
11437       fi
11438     fi
11439   fi
11440 
11441 
11442   if test "x$AWK" = x; then
11443     as_fn_error $? "Could not find required tool for AWK" "$LINENO" 5
11444   fi
11445 
11446 
11447 
11448 
11449   # Publish this variable in the help.
11450 
11451 
11452   if test "x$GREP" = x; then
11453     # The variable is not set by user, try to locate tool using the code snippet
11454     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
11455 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
11456 if ${ac_cv_path_GREP+:} false; then :
11457   $as_echo_n "(cached) " >&6
11458 else
11459   if test -z "$GREP"; then
11460   ac_path_GREP_found=false
11461   # Loop through the user's path and test for each of PROGNAME-LIST
11462   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11463 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11464 do
11465   IFS=$as_save_IFS
11466   test -z "$as_dir" && as_dir=.
11467     for ac_prog in grep ggrep; do
11468     for ac_exec_ext in '' $ac_executable_extensions; do
11469       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
11470       as_fn_executable_p "$ac_path_GREP" || continue
11471 # Check for GNU ac_path_GREP and select it if it is found.
11472   # Check for GNU $ac_path_GREP
11473 case `"$ac_path_GREP" --version 2>&1` in
11474 *GNU*)
11475   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
11476 *)
11477   ac_count=0
11478   $as_echo_n 0123456789 >"conftest.in"
11479   while :
11480   do
11481     cat "conftest.in" "conftest.in" >"conftest.tmp"
11482     mv "conftest.tmp" "conftest.in"
11483     cp "conftest.in" "conftest.nl"
11484     $as_echo 'GREP' >> "conftest.nl"
11485     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11486     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11487     as_fn_arith $ac_count + 1 && ac_count=$as_val
11488     if test $ac_count -gt ${ac_path_GREP_max-0}; then
11489       # Best one so far, save it but keep looking for a better one
11490       ac_cv_path_GREP="$ac_path_GREP"
11491       ac_path_GREP_max=$ac_count
11492     fi
11493     # 10*(2^10) chars as input seems more than enough
11494     test $ac_count -gt 10 && break
11495   done
11496   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11497 esac
11498 
11499       $ac_path_GREP_found && break 3
11500     done
11501   done
11502   done
11503 IFS=$as_save_IFS
11504   if test -z "$ac_cv_path_GREP"; then
11505     as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11506   fi
11507 else
11508   ac_cv_path_GREP=$GREP
11509 fi
11510 
11511 fi
11512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
11513 $as_echo "$ac_cv_path_GREP" >&6; }
11514  GREP="$ac_cv_path_GREP"
11515 
11516 
11517   else
11518     # The variable is set, but is it from the command line or the environment?
11519 
11520     # Try to remove the string !GREP! from our list.
11521     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GREP!/}
11522     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11523       # If it failed, the variable was not from the command line. Ignore it,
11524       # but warn the user (except for BASH, which is always set by the calling BASH).
11525       if test "xGREP" != xBASH; then
11526         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&5
11527 $as_echo "$as_me: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&2;}
11528       fi
11529       # Try to locate tool using the code snippet
11530       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
11531 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
11532 if ${ac_cv_path_GREP+:} false; then :
11533   $as_echo_n "(cached) " >&6
11534 else
11535   if test -z "$GREP"; then
11536   ac_path_GREP_found=false
11537   # Loop through the user's path and test for each of PROGNAME-LIST
11538   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11539 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11540 do
11541   IFS=$as_save_IFS
11542   test -z "$as_dir" && as_dir=.
11543     for ac_prog in grep ggrep; do
11544     for ac_exec_ext in '' $ac_executable_extensions; do
11545       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
11546       as_fn_executable_p "$ac_path_GREP" || continue
11547 # Check for GNU ac_path_GREP and select it if it is found.
11548   # Check for GNU $ac_path_GREP
11549 case `"$ac_path_GREP" --version 2>&1` in
11550 *GNU*)
11551   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
11552 *)
11553   ac_count=0
11554   $as_echo_n 0123456789 >"conftest.in"
11555   while :
11556   do
11557     cat "conftest.in" "conftest.in" >"conftest.tmp"
11558     mv "conftest.tmp" "conftest.in"
11559     cp "conftest.in" "conftest.nl"
11560     $as_echo 'GREP' >> "conftest.nl"
11561     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11562     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11563     as_fn_arith $ac_count + 1 && ac_count=$as_val
11564     if test $ac_count -gt ${ac_path_GREP_max-0}; then
11565       # Best one so far, save it but keep looking for a better one
11566       ac_cv_path_GREP="$ac_path_GREP"
11567       ac_path_GREP_max=$ac_count
11568     fi
11569     # 10*(2^10) chars as input seems more than enough
11570     test $ac_count -gt 10 && break
11571   done
11572   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11573 esac
11574 
11575       $ac_path_GREP_found && break 3
11576     done
11577   done
11578   done
11579 IFS=$as_save_IFS
11580   if test -z "$ac_cv_path_GREP"; then
11581     as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11582   fi
11583 else
11584   ac_cv_path_GREP=$GREP
11585 fi
11586 
11587 fi
11588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
11589 $as_echo "$ac_cv_path_GREP" >&6; }
11590  GREP="$ac_cv_path_GREP"
11591 
11592 
11593     else
11594       # If it succeeded, then it was overridden by the user. We will use it
11595       # for the tool.
11596 
11597       # First remove it from the list of overridden variables, so we can test
11598       # for unknown variables in the end.
11599       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11600 
11601       # Check if the provided tool contains a complete path.
11602       tool_specified="$GREP"
11603       tool_basename="${tool_specified##*/}"
11604       if test "x$tool_basename" = "x$tool_specified"; then
11605         # A command without a complete path is provided, search $PATH.
11606         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GREP=$tool_basename" >&5
11607 $as_echo "$as_me: Will search for user supplied tool GREP=$tool_basename" >&6;}
11608         # Extract the first word of "$tool_basename", so it can be a program name with args.
11609 set dummy $tool_basename; ac_word=$2
11610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11611 $as_echo_n "checking for $ac_word... " >&6; }
11612 if ${ac_cv_path_GREP+:} false; then :
11613   $as_echo_n "(cached) " >&6
11614 else
11615   case $GREP in
11616   [\\/]* | ?:[\\/]*)
11617   ac_cv_path_GREP="$GREP" # Let the user override the test with a path.
11618   ;;
11619   *)
11620   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11621 for as_dir in $PATH
11622 do
11623   IFS=$as_save_IFS
11624   test -z "$as_dir" && as_dir=.
11625     for ac_exec_ext in '' $ac_executable_extensions; do
11626   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11627     ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext"
11628     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11629     break 2
11630   fi
11631 done
11632   done
11633 IFS=$as_save_IFS
11634 
11635   ;;
11636 esac
11637 fi
11638 GREP=$ac_cv_path_GREP
11639 if test -n "$GREP"; then
11640   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5
11641 $as_echo "$GREP" >&6; }
11642 else
11643   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11644 $as_echo "no" >&6; }
11645 fi
11646 
11647 
11648         if test "x$GREP" = x; then
11649           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11650         fi
11651       else
11652         # Otherwise we believe it is a complete path. Use it as it is.
11653         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GREP=$tool_specified" >&5
11654 $as_echo "$as_me: Will use user supplied tool GREP=$tool_specified" >&6;}
11655         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5
11656 $as_echo_n "checking for GREP... " >&6; }
11657         if test ! -x "$tool_specified"; then
11658           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11659 $as_echo "not found" >&6; }
11660           as_fn_error $? "User supplied tool GREP=$tool_specified does not exist or is not executable" "$LINENO" 5
11661         fi
11662         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11663 $as_echo "$tool_specified" >&6; }
11664       fi
11665     fi
11666   fi
11667 
11668 
11669   if test "x$GREP" = x; then
11670     as_fn_error $? "Could not find required tool for GREP" "$LINENO" 5
11671   fi
11672 
11673 
11674 
11675 
11676   # Publish this variable in the help.
11677 
11678 
11679   if test "x$EGREP" = x; then
11680     # The variable is not set by user, try to locate tool using the code snippet
11681     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
11682 $as_echo_n "checking for egrep... " >&6; }
11683 if ${ac_cv_path_EGREP+:} false; then :
11684   $as_echo_n "(cached) " >&6
11685 else
11686   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
11687    then ac_cv_path_EGREP="$GREP -E"
11688    else
11689      if test -z "$EGREP"; then
11690   ac_path_EGREP_found=false
11691   # Loop through the user's path and test for each of PROGNAME-LIST
11692   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11693 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11694 do
11695   IFS=$as_save_IFS
11696   test -z "$as_dir" && as_dir=.
11697     for ac_prog in egrep; do
11698     for ac_exec_ext in '' $ac_executable_extensions; do
11699       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
11700       as_fn_executable_p "$ac_path_EGREP" || continue
11701 # Check for GNU ac_path_EGREP and select it if it is found.
11702   # Check for GNU $ac_path_EGREP
11703 case `"$ac_path_EGREP" --version 2>&1` in
11704 *GNU*)
11705   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
11706 *)
11707   ac_count=0
11708   $as_echo_n 0123456789 >"conftest.in"
11709   while :
11710   do
11711     cat "conftest.in" "conftest.in" >"conftest.tmp"
11712     mv "conftest.tmp" "conftest.in"
11713     cp "conftest.in" "conftest.nl"
11714     $as_echo 'EGREP' >> "conftest.nl"
11715     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11716     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11717     as_fn_arith $ac_count + 1 && ac_count=$as_val
11718     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
11719       # Best one so far, save it but keep looking for a better one
11720       ac_cv_path_EGREP="$ac_path_EGREP"
11721       ac_path_EGREP_max=$ac_count
11722     fi
11723     # 10*(2^10) chars as input seems more than enough
11724     test $ac_count -gt 10 && break
11725   done
11726   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11727 esac
11728 
11729       $ac_path_EGREP_found && break 3
11730     done
11731   done
11732   done
11733 IFS=$as_save_IFS
11734   if test -z "$ac_cv_path_EGREP"; then
11735     as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11736   fi
11737 else
11738   ac_cv_path_EGREP=$EGREP
11739 fi
11740 
11741    fi
11742 fi
11743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
11744 $as_echo "$ac_cv_path_EGREP" >&6; }
11745  EGREP="$ac_cv_path_EGREP"
11746 
11747 
11748   else
11749     # The variable is set, but is it from the command line or the environment?
11750 
11751     # Try to remove the string !EGREP! from our list.
11752     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EGREP!/}
11753     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11754       # If it failed, the variable was not from the command line. Ignore it,
11755       # but warn the user (except for BASH, which is always set by the calling BASH).
11756       if test "xEGREP" != xBASH; then
11757         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&5
11758 $as_echo "$as_me: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&2;}
11759       fi
11760       # Try to locate tool using the code snippet
11761       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
11762 $as_echo_n "checking for egrep... " >&6; }
11763 if ${ac_cv_path_EGREP+:} false; then :
11764   $as_echo_n "(cached) " >&6
11765 else
11766   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
11767    then ac_cv_path_EGREP="$GREP -E"
11768    else
11769      if test -z "$EGREP"; then
11770   ac_path_EGREP_found=false
11771   # Loop through the user's path and test for each of PROGNAME-LIST
11772   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11773 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11774 do
11775   IFS=$as_save_IFS
11776   test -z "$as_dir" && as_dir=.
11777     for ac_prog in egrep; do
11778     for ac_exec_ext in '' $ac_executable_extensions; do
11779       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
11780       as_fn_executable_p "$ac_path_EGREP" || continue
11781 # Check for GNU ac_path_EGREP and select it if it is found.
11782   # Check for GNU $ac_path_EGREP
11783 case `"$ac_path_EGREP" --version 2>&1` in
11784 *GNU*)
11785   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
11786 *)
11787   ac_count=0
11788   $as_echo_n 0123456789 >"conftest.in"
11789   while :
11790   do
11791     cat "conftest.in" "conftest.in" >"conftest.tmp"
11792     mv "conftest.tmp" "conftest.in"
11793     cp "conftest.in" "conftest.nl"
11794     $as_echo 'EGREP' >> "conftest.nl"
11795     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11796     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11797     as_fn_arith $ac_count + 1 && ac_count=$as_val
11798     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
11799       # Best one so far, save it but keep looking for a better one
11800       ac_cv_path_EGREP="$ac_path_EGREP"
11801       ac_path_EGREP_max=$ac_count
11802     fi
11803     # 10*(2^10) chars as input seems more than enough
11804     test $ac_count -gt 10 && break
11805   done
11806   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11807 esac
11808 
11809       $ac_path_EGREP_found && break 3
11810     done
11811   done
11812   done
11813 IFS=$as_save_IFS
11814   if test -z "$ac_cv_path_EGREP"; then
11815     as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11816   fi
11817 else
11818   ac_cv_path_EGREP=$EGREP
11819 fi
11820 
11821    fi
11822 fi
11823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
11824 $as_echo "$ac_cv_path_EGREP" >&6; }
11825  EGREP="$ac_cv_path_EGREP"
11826 
11827 
11828     else
11829       # If it succeeded, then it was overridden by the user. We will use it
11830       # for the tool.
11831 
11832       # First remove it from the list of overridden variables, so we can test
11833       # for unknown variables in the end.
11834       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11835 
11836       # Check if the provided tool contains a complete path.
11837       tool_specified="$EGREP"
11838       tool_basename="${tool_specified##*/}"
11839       if test "x$tool_basename" = "x$tool_specified"; then
11840         # A command without a complete path is provided, search $PATH.
11841         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EGREP=$tool_basename" >&5
11842 $as_echo "$as_me: Will search for user supplied tool EGREP=$tool_basename" >&6;}
11843         # Extract the first word of "$tool_basename", so it can be a program name with args.
11844 set dummy $tool_basename; ac_word=$2
11845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11846 $as_echo_n "checking for $ac_word... " >&6; }
11847 if ${ac_cv_path_EGREP+:} false; then :
11848   $as_echo_n "(cached) " >&6
11849 else
11850   case $EGREP in
11851   [\\/]* | ?:[\\/]*)
11852   ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path.
11853   ;;
11854   *)
11855   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11856 for as_dir in $PATH
11857 do
11858   IFS=$as_save_IFS
11859   test -z "$as_dir" && as_dir=.
11860     for ac_exec_ext in '' $ac_executable_extensions; do
11861   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11862     ac_cv_path_EGREP="$as_dir/$ac_word$ac_exec_ext"
11863     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11864     break 2
11865   fi
11866 done
11867   done
11868 IFS=$as_save_IFS
11869 
11870   ;;
11871 esac
11872 fi
11873 EGREP=$ac_cv_path_EGREP
11874 if test -n "$EGREP"; then
11875   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5
11876 $as_echo "$EGREP" >&6; }
11877 else
11878   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11879 $as_echo "no" >&6; }
11880 fi
11881 
11882 
11883         if test "x$EGREP" = x; then
11884           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11885         fi
11886       else
11887         # Otherwise we believe it is a complete path. Use it as it is.
11888         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EGREP=$tool_specified" >&5
11889 $as_echo "$as_me: Will use user supplied tool EGREP=$tool_specified" >&6;}
11890         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5
11891 $as_echo_n "checking for EGREP... " >&6; }
11892         if test ! -x "$tool_specified"; then
11893           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11894 $as_echo "not found" >&6; }
11895           as_fn_error $? "User supplied tool EGREP=$tool_specified does not exist or is not executable" "$LINENO" 5
11896         fi
11897         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11898 $as_echo "$tool_specified" >&6; }
11899       fi
11900     fi
11901   fi
11902 
11903 
11904   if test "x$EGREP" = x; then
11905     as_fn_error $? "Could not find required tool for EGREP" "$LINENO" 5
11906   fi
11907 
11908 
11909 
11910 
11911   # Publish this variable in the help.
11912 
11913 
11914   if test "x$FGREP" = x; then
11915     # The variable is not set by user, try to locate tool using the code snippet
11916     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
11917 $as_echo_n "checking for fgrep... " >&6; }
11918 if ${ac_cv_path_FGREP+:} false; then :
11919   $as_echo_n "(cached) " >&6
11920 else
11921   if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
11922    then ac_cv_path_FGREP="$GREP -F"
11923    else
11924      if test -z "$FGREP"; then
11925   ac_path_FGREP_found=false
11926   # Loop through the user's path and test for each of PROGNAME-LIST
11927   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11928 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11929 do
11930   IFS=$as_save_IFS
11931   test -z "$as_dir" && as_dir=.
11932     for ac_prog in fgrep; do
11933     for ac_exec_ext in '' $ac_executable_extensions; do
11934       ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
11935       as_fn_executable_p "$ac_path_FGREP" || continue
11936 # Check for GNU ac_path_FGREP and select it if it is found.
11937   # Check for GNU $ac_path_FGREP
11938 case `"$ac_path_FGREP" --version 2>&1` in
11939 *GNU*)
11940   ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
11941 *)
11942   ac_count=0
11943   $as_echo_n 0123456789 >"conftest.in"
11944   while :
11945   do
11946     cat "conftest.in" "conftest.in" >"conftest.tmp"
11947     mv "conftest.tmp" "conftest.in"
11948     cp "conftest.in" "conftest.nl"
11949     $as_echo 'FGREP' >> "conftest.nl"
11950     "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
11951     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11952     as_fn_arith $ac_count + 1 && ac_count=$as_val
11953     if test $ac_count -gt ${ac_path_FGREP_max-0}; then
11954       # Best one so far, save it but keep looking for a better one
11955       ac_cv_path_FGREP="$ac_path_FGREP"
11956       ac_path_FGREP_max=$ac_count
11957     fi
11958     # 10*(2^10) chars as input seems more than enough
11959     test $ac_count -gt 10 && break
11960   done
11961   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11962 esac
11963 
11964       $ac_path_FGREP_found && break 3
11965     done
11966   done
11967   done
11968 IFS=$as_save_IFS
11969   if test -z "$ac_cv_path_FGREP"; then
11970     as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11971   fi
11972 else
11973   ac_cv_path_FGREP=$FGREP
11974 fi
11975 
11976    fi
11977 fi
11978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
11979 $as_echo "$ac_cv_path_FGREP" >&6; }
11980  FGREP="$ac_cv_path_FGREP"
11981 
11982 
11983   else
11984     # The variable is set, but is it from the command line or the environment?
11985 
11986     # Try to remove the string !FGREP! from our list.
11987     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FGREP!/}
11988     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11989       # If it failed, the variable was not from the command line. Ignore it,
11990       # but warn the user (except for BASH, which is always set by the calling BASH).
11991       if test "xFGREP" != xBASH; then
11992         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&5
11993 $as_echo "$as_me: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&2;}
11994       fi
11995       # Try to locate tool using the code snippet
11996       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
11997 $as_echo_n "checking for fgrep... " >&6; }
11998 if ${ac_cv_path_FGREP+:} false; then :
11999   $as_echo_n "(cached) " >&6
12000 else
12001   if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
12002    then ac_cv_path_FGREP="$GREP -F"
12003    else
12004      if test -z "$FGREP"; then
12005   ac_path_FGREP_found=false
12006   # Loop through the user's path and test for each of PROGNAME-LIST
12007   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12008 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
12009 do
12010   IFS=$as_save_IFS
12011   test -z "$as_dir" && as_dir=.
12012     for ac_prog in fgrep; do
12013     for ac_exec_ext in '' $ac_executable_extensions; do
12014       ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
12015       as_fn_executable_p "$ac_path_FGREP" || continue
12016 # Check for GNU ac_path_FGREP and select it if it is found.
12017   # Check for GNU $ac_path_FGREP
12018 case `"$ac_path_FGREP" --version 2>&1` in
12019 *GNU*)
12020   ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
12021 *)
12022   ac_count=0
12023   $as_echo_n 0123456789 >"conftest.in"
12024   while :
12025   do
12026     cat "conftest.in" "conftest.in" >"conftest.tmp"
12027     mv "conftest.tmp" "conftest.in"
12028     cp "conftest.in" "conftest.nl"
12029     $as_echo 'FGREP' >> "conftest.nl"
12030     "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
12031     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12032     as_fn_arith $ac_count + 1 && ac_count=$as_val
12033     if test $ac_count -gt ${ac_path_FGREP_max-0}; then
12034       # Best one so far, save it but keep looking for a better one
12035       ac_cv_path_FGREP="$ac_path_FGREP"
12036       ac_path_FGREP_max=$ac_count
12037     fi
12038     # 10*(2^10) chars as input seems more than enough
12039     test $ac_count -gt 10 && break
12040   done
12041   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12042 esac
12043 
12044       $ac_path_FGREP_found && break 3
12045     done
12046   done
12047   done
12048 IFS=$as_save_IFS
12049   if test -z "$ac_cv_path_FGREP"; then
12050     as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
12051   fi
12052 else
12053   ac_cv_path_FGREP=$FGREP
12054 fi
12055 
12056    fi
12057 fi
12058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
12059 $as_echo "$ac_cv_path_FGREP" >&6; }
12060  FGREP="$ac_cv_path_FGREP"
12061 
12062 
12063     else
12064       # If it succeeded, then it was overridden by the user. We will use it
12065       # for the tool.
12066 
12067       # First remove it from the list of overridden variables, so we can test
12068       # for unknown variables in the end.
12069       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12070 
12071       # Check if the provided tool contains a complete path.
12072       tool_specified="$FGREP"
12073       tool_basename="${tool_specified##*/}"
12074       if test "x$tool_basename" = "x$tool_specified"; then
12075         # A command without a complete path is provided, search $PATH.
12076         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FGREP=$tool_basename" >&5
12077 $as_echo "$as_me: Will search for user supplied tool FGREP=$tool_basename" >&6;}
12078         # Extract the first word of "$tool_basename", so it can be a program name with args.
12079 set dummy $tool_basename; ac_word=$2
12080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12081 $as_echo_n "checking for $ac_word... " >&6; }
12082 if ${ac_cv_path_FGREP+:} false; then :
12083   $as_echo_n "(cached) " >&6
12084 else
12085   case $FGREP in
12086   [\\/]* | ?:[\\/]*)
12087   ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path.
12088   ;;
12089   *)
12090   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12091 for as_dir in $PATH
12092 do
12093   IFS=$as_save_IFS
12094   test -z "$as_dir" && as_dir=.
12095     for ac_exec_ext in '' $ac_executable_extensions; do
12096   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12097     ac_cv_path_FGREP="$as_dir/$ac_word$ac_exec_ext"
12098     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12099     break 2
12100   fi
12101 done
12102   done
12103 IFS=$as_save_IFS
12104 
12105   ;;
12106 esac
12107 fi
12108 FGREP=$ac_cv_path_FGREP
12109 if test -n "$FGREP"; then
12110   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FGREP" >&5
12111 $as_echo "$FGREP" >&6; }
12112 else
12113   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12114 $as_echo "no" >&6; }
12115 fi
12116 
12117 
12118         if test "x$FGREP" = x; then
12119           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12120         fi
12121       else
12122         # Otherwise we believe it is a complete path. Use it as it is.
12123         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FGREP=$tool_specified" >&5
12124 $as_echo "$as_me: Will use user supplied tool FGREP=$tool_specified" >&6;}
12125         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5
12126 $as_echo_n "checking for FGREP... " >&6; }
12127         if test ! -x "$tool_specified"; then
12128           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12129 $as_echo "not found" >&6; }
12130           as_fn_error $? "User supplied tool FGREP=$tool_specified does not exist or is not executable" "$LINENO" 5
12131         fi
12132         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12133 $as_echo "$tool_specified" >&6; }
12134       fi
12135     fi
12136   fi
12137 
12138 
12139   if test "x$FGREP" = x; then
12140     as_fn_error $? "Could not find required tool for FGREP" "$LINENO" 5
12141   fi
12142 
12143 
12144 
12145 
12146   # Publish this variable in the help.
12147 
12148 
12149   if test "x$SED" = x; then
12150     # The variable is not set by user, try to locate tool using the code snippet
12151     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
12152 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
12153 if ${ac_cv_path_SED+:} false; then :
12154   $as_echo_n "(cached) " >&6
12155 else
12156             ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
12157      for ac_i in 1 2 3 4 5 6 7; do
12158        ac_script="$ac_script$as_nl$ac_script"
12159      done
12160      echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
12161      { ac_script=; unset ac_script;}
12162      if test -z "$SED"; then
12163   ac_path_SED_found=false
12164   # Loop through the user's path and test for each of PROGNAME-LIST
12165   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12166 for as_dir in $PATH
12167 do
12168   IFS=$as_save_IFS
12169   test -z "$as_dir" && as_dir=.
12170     for ac_prog in sed gsed; do
12171     for ac_exec_ext in '' $ac_executable_extensions; do
12172       ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
12173       as_fn_executable_p "$ac_path_SED" || continue
12174 # Check for GNU ac_path_SED and select it if it is found.
12175   # Check for GNU $ac_path_SED
12176 case `"$ac_path_SED" --version 2>&1` in
12177 *GNU*)
12178   ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
12179 *)
12180   ac_count=0
12181   $as_echo_n 0123456789 >"conftest.in"
12182   while :
12183   do
12184     cat "conftest.in" "conftest.in" >"conftest.tmp"
12185     mv "conftest.tmp" "conftest.in"
12186     cp "conftest.in" "conftest.nl"
12187     $as_echo '' >> "conftest.nl"
12188     "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
12189     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12190     as_fn_arith $ac_count + 1 && ac_count=$as_val
12191     if test $ac_count -gt ${ac_path_SED_max-0}; then
12192       # Best one so far, save it but keep looking for a better one
12193       ac_cv_path_SED="$ac_path_SED"
12194       ac_path_SED_max=$ac_count
12195     fi
12196     # 10*(2^10) chars as input seems more than enough
12197     test $ac_count -gt 10 && break
12198   done
12199   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12200 esac
12201 
12202       $ac_path_SED_found && break 3
12203     done
12204   done
12205   done
12206 IFS=$as_save_IFS
12207   if test -z "$ac_cv_path_SED"; then
12208     as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
12209   fi
12210 else
12211   ac_cv_path_SED=$SED
12212 fi
12213 
12214 fi
12215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
12216 $as_echo "$ac_cv_path_SED" >&6; }
12217  SED="$ac_cv_path_SED"
12218   rm -f conftest.sed
12219 
12220   else
12221     # The variable is set, but is it from the command line or the environment?
12222 
12223     # Try to remove the string !SED! from our list.
12224     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SED!/}
12225     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12226       # If it failed, the variable was not from the command line. Ignore it,
12227       # but warn the user (except for BASH, which is always set by the calling BASH).
12228       if test "xSED" != xBASH; then
12229         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&5
12230 $as_echo "$as_me: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&2;}
12231       fi
12232       # Try to locate tool using the code snippet
12233       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
12234 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
12235 if ${ac_cv_path_SED+:} false; then :
12236   $as_echo_n "(cached) " >&6
12237 else
12238             ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
12239      for ac_i in 1 2 3 4 5 6 7; do
12240        ac_script="$ac_script$as_nl$ac_script"
12241      done
12242      echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
12243      { ac_script=; unset ac_script;}
12244      if test -z "$SED"; then
12245   ac_path_SED_found=false
12246   # Loop through the user's path and test for each of PROGNAME-LIST
12247   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12248 for as_dir in $PATH
12249 do
12250   IFS=$as_save_IFS
12251   test -z "$as_dir" && as_dir=.
12252     for ac_prog in sed gsed; do
12253     for ac_exec_ext in '' $ac_executable_extensions; do
12254       ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
12255       as_fn_executable_p "$ac_path_SED" || continue
12256 # Check for GNU ac_path_SED and select it if it is found.
12257   # Check for GNU $ac_path_SED
12258 case `"$ac_path_SED" --version 2>&1` in
12259 *GNU*)
12260   ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
12261 *)
12262   ac_count=0
12263   $as_echo_n 0123456789 >"conftest.in"
12264   while :
12265   do
12266     cat "conftest.in" "conftest.in" >"conftest.tmp"
12267     mv "conftest.tmp" "conftest.in"
12268     cp "conftest.in" "conftest.nl"
12269     $as_echo '' >> "conftest.nl"
12270     "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
12271     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12272     as_fn_arith $ac_count + 1 && ac_count=$as_val
12273     if test $ac_count -gt ${ac_path_SED_max-0}; then
12274       # Best one so far, save it but keep looking for a better one
12275       ac_cv_path_SED="$ac_path_SED"
12276       ac_path_SED_max=$ac_count
12277     fi
12278     # 10*(2^10) chars as input seems more than enough
12279     test $ac_count -gt 10 && break
12280   done
12281   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12282 esac
12283 
12284       $ac_path_SED_found && break 3
12285     done
12286   done
12287   done
12288 IFS=$as_save_IFS
12289   if test -z "$ac_cv_path_SED"; then
12290     as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
12291   fi
12292 else
12293   ac_cv_path_SED=$SED
12294 fi
12295 
12296 fi
12297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
12298 $as_echo "$ac_cv_path_SED" >&6; }
12299  SED="$ac_cv_path_SED"
12300   rm -f conftest.sed
12301 
12302     else
12303       # If it succeeded, then it was overridden by the user. We will use it
12304       # for the tool.
12305 
12306       # First remove it from the list of overridden variables, so we can test
12307       # for unknown variables in the end.
12308       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12309 
12310       # Check if the provided tool contains a complete path.
12311       tool_specified="$SED"
12312       tool_basename="${tool_specified##*/}"
12313       if test "x$tool_basename" = "x$tool_specified"; then
12314         # A command without a complete path is provided, search $PATH.
12315         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SED=$tool_basename" >&5
12316 $as_echo "$as_me: Will search for user supplied tool SED=$tool_basename" >&6;}
12317         # Extract the first word of "$tool_basename", so it can be a program name with args.
12318 set dummy $tool_basename; ac_word=$2
12319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12320 $as_echo_n "checking for $ac_word... " >&6; }
12321 if ${ac_cv_path_SED+:} false; then :
12322   $as_echo_n "(cached) " >&6
12323 else
12324   case $SED in
12325   [\\/]* | ?:[\\/]*)
12326   ac_cv_path_SED="$SED" # Let the user override the test with a path.
12327   ;;
12328   *)
12329   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12330 for as_dir in $PATH
12331 do
12332   IFS=$as_save_IFS
12333   test -z "$as_dir" && as_dir=.
12334     for ac_exec_ext in '' $ac_executable_extensions; do
12335   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12336     ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext"
12337     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12338     break 2
12339   fi
12340 done
12341   done
12342 IFS=$as_save_IFS
12343 
12344   ;;
12345 esac
12346 fi
12347 SED=$ac_cv_path_SED
12348 if test -n "$SED"; then
12349   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5
12350 $as_echo "$SED" >&6; }
12351 else
12352   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12353 $as_echo "no" >&6; }
12354 fi
12355 
12356 
12357         if test "x$SED" = x; then
12358           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12359         fi
12360       else
12361         # Otherwise we believe it is a complete path. Use it as it is.
12362         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SED=$tool_specified" >&5
12363 $as_echo "$as_me: Will use user supplied tool SED=$tool_specified" >&6;}
12364         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5
12365 $as_echo_n "checking for SED... " >&6; }
12366         if test ! -x "$tool_specified"; then
12367           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12368 $as_echo "not found" >&6; }
12369           as_fn_error $? "User supplied tool SED=$tool_specified does not exist or is not executable" "$LINENO" 5
12370         fi
12371         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12372 $as_echo "$tool_specified" >&6; }
12373       fi
12374     fi
12375   fi
12376 
12377 
12378   if test "x$SED" = x; then
12379     as_fn_error $? "Could not find required tool for SED" "$LINENO" 5
12380   fi
12381 
12382 
12383 
12384   # Always force rm.
12385   RM="$RM -f"
12386 
12387   # pwd behaves differently on various platforms and some don't support the -L flag.
12388   # Always use the bash builtin pwd to get uniform behavior.
12389   THEPWDCMD=pwd
12390 
12391   # These are not required on all platforms
12392 
12393 
12394   # Publish this variable in the help.
12395 
12396 
12397   if test "x$CYGPATH" = x; then
12398     # The variable is not set by user, try to locate tool using the code snippet
12399     for ac_prog in cygpath
12400 do
12401   # Extract the first word of "$ac_prog", so it can be a program name with args.
12402 set dummy $ac_prog; ac_word=$2
12403 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12404 $as_echo_n "checking for $ac_word... " >&6; }
12405 if ${ac_cv_path_CYGPATH+:} false; then :
12406   $as_echo_n "(cached) " >&6
12407 else
12408   case $CYGPATH in
12409   [\\/]* | ?:[\\/]*)
12410   ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path.
12411   ;;
12412   *)
12413   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12414 for as_dir in $PATH
12415 do
12416   IFS=$as_save_IFS
12417   test -z "$as_dir" && as_dir=.
12418     for ac_exec_ext in '' $ac_executable_extensions; do
12419   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12420     ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext"
12421     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12422     break 2
12423   fi
12424 done
12425   done
12426 IFS=$as_save_IFS
12427 
12428   ;;
12429 esac
12430 fi
12431 CYGPATH=$ac_cv_path_CYGPATH
12432 if test -n "$CYGPATH"; then
12433   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
12434 $as_echo "$CYGPATH" >&6; }
12435 else
12436   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12437 $as_echo "no" >&6; }
12438 fi
12439 
12440 
12441   test -n "$CYGPATH" && break
12442 done
12443 
12444   else
12445     # The variable is set, but is it from the command line or the environment?
12446 
12447     # Try to remove the string !CYGPATH! from our list.
12448     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CYGPATH!/}
12449     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12450       # If it failed, the variable was not from the command line. Ignore it,
12451       # but warn the user (except for BASH, which is always set by the calling BASH).
12452       if test "xCYGPATH" != xBASH; then
12453         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&5
12454 $as_echo "$as_me: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&2;}
12455       fi
12456       # Try to locate tool using the code snippet
12457       for ac_prog in cygpath
12458 do
12459   # Extract the first word of "$ac_prog", so it can be a program name with args.
12460 set dummy $ac_prog; ac_word=$2
12461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12462 $as_echo_n "checking for $ac_word... " >&6; }
12463 if ${ac_cv_path_CYGPATH+:} false; then :
12464   $as_echo_n "(cached) " >&6
12465 else
12466   case $CYGPATH in
12467   [\\/]* | ?:[\\/]*)
12468   ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path.
12469   ;;
12470   *)
12471   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12472 for as_dir in $PATH
12473 do
12474   IFS=$as_save_IFS
12475   test -z "$as_dir" && as_dir=.
12476     for ac_exec_ext in '' $ac_executable_extensions; do
12477   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12478     ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext"
12479     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12480     break 2
12481   fi
12482 done
12483   done
12484 IFS=$as_save_IFS
12485 
12486   ;;
12487 esac
12488 fi
12489 CYGPATH=$ac_cv_path_CYGPATH
12490 if test -n "$CYGPATH"; then
12491   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
12492 $as_echo "$CYGPATH" >&6; }
12493 else
12494   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12495 $as_echo "no" >&6; }
12496 fi
12497 
12498 
12499   test -n "$CYGPATH" && break
12500 done
12501 
12502     else
12503       # If it succeeded, then it was overridden by the user. We will use it
12504       # for the tool.
12505 
12506       # First remove it from the list of overridden variables, so we can test
12507       # for unknown variables in the end.
12508       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12509 
12510       # Check if the provided tool contains a complete path.
12511       tool_specified="$CYGPATH"
12512       tool_basename="${tool_specified##*/}"
12513       if test "x$tool_basename" = "x$tool_specified"; then
12514         # A command without a complete path is provided, search $PATH.
12515         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CYGPATH=$tool_basename" >&5
12516 $as_echo "$as_me: Will search for user supplied tool CYGPATH=$tool_basename" >&6;}
12517         # Extract the first word of "$tool_basename", so it can be a program name with args.
12518 set dummy $tool_basename; ac_word=$2
12519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12520 $as_echo_n "checking for $ac_word... " >&6; }
12521 if ${ac_cv_path_CYGPATH+:} false; then :
12522   $as_echo_n "(cached) " >&6
12523 else
12524   case $CYGPATH in
12525   [\\/]* | ?:[\\/]*)
12526   ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path.
12527   ;;
12528   *)
12529   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12530 for as_dir in $PATH
12531 do
12532   IFS=$as_save_IFS
12533   test -z "$as_dir" && as_dir=.
12534     for ac_exec_ext in '' $ac_executable_extensions; do
12535   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12536     ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext"
12537     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12538     break 2
12539   fi
12540 done
12541   done
12542 IFS=$as_save_IFS
12543 
12544   ;;
12545 esac
12546 fi
12547 CYGPATH=$ac_cv_path_CYGPATH
12548 if test -n "$CYGPATH"; then
12549   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
12550 $as_echo "$CYGPATH" >&6; }
12551 else
12552   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12553 $as_echo "no" >&6; }
12554 fi
12555 
12556 
12557         if test "x$CYGPATH" = x; then
12558           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12559         fi
12560       else
12561         # Otherwise we believe it is a complete path. Use it as it is.
12562         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CYGPATH=$tool_specified" >&5
12563 $as_echo "$as_me: Will use user supplied tool CYGPATH=$tool_specified" >&6;}
12564         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5
12565 $as_echo_n "checking for CYGPATH... " >&6; }
12566         if test ! -x "$tool_specified"; then
12567           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12568 $as_echo "not found" >&6; }
12569           as_fn_error $? "User supplied tool CYGPATH=$tool_specified does not exist or is not executable" "$LINENO" 5
12570         fi
12571         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12572 $as_echo "$tool_specified" >&6; }
12573       fi
12574     fi
12575   fi
12576 
12577 
12578 
12579 
12580   # Publish this variable in the help.
12581 
12582 
12583   if test "x$READLINK" = x; then
12584     # The variable is not set by user, try to locate tool using the code snippet
12585     for ac_prog in greadlink readlink
12586 do
12587   # Extract the first word of "$ac_prog", so it can be a program name with args.
12588 set dummy $ac_prog; ac_word=$2
12589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12590 $as_echo_n "checking for $ac_word... " >&6; }
12591 if ${ac_cv_path_READLINK+:} false; then :
12592   $as_echo_n "(cached) " >&6
12593 else
12594   case $READLINK in
12595   [\\/]* | ?:[\\/]*)
12596   ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path.
12597   ;;
12598   *)
12599   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12600 for as_dir in $PATH
12601 do
12602   IFS=$as_save_IFS
12603   test -z "$as_dir" && as_dir=.
12604     for ac_exec_ext in '' $ac_executable_extensions; do
12605   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12606     ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext"
12607     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12608     break 2
12609   fi
12610 done
12611   done
12612 IFS=$as_save_IFS
12613 
12614   ;;
12615 esac
12616 fi
12617 READLINK=$ac_cv_path_READLINK
12618 if test -n "$READLINK"; then
12619   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5
12620 $as_echo "$READLINK" >&6; }
12621 else
12622   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12623 $as_echo "no" >&6; }
12624 fi
12625 
12626 
12627   test -n "$READLINK" && break
12628 done
12629 
12630   else
12631     # The variable is set, but is it from the command line or the environment?
12632 
12633     # Try to remove the string !READLINK! from our list.
12634     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READLINK!/}
12635     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12636       # If it failed, the variable was not from the command line. Ignore it,
12637       # but warn the user (except for BASH, which is always set by the calling BASH).
12638       if test "xREADLINK" != xBASH; then
12639         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&5
12640 $as_echo "$as_me: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&2;}
12641       fi
12642       # Try to locate tool using the code snippet
12643       for ac_prog in greadlink readlink
12644 do
12645   # Extract the first word of "$ac_prog", so it can be a program name with args.
12646 set dummy $ac_prog; ac_word=$2
12647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12648 $as_echo_n "checking for $ac_word... " >&6; }
12649 if ${ac_cv_path_READLINK+:} false; then :
12650   $as_echo_n "(cached) " >&6
12651 else
12652   case $READLINK in
12653   [\\/]* | ?:[\\/]*)
12654   ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path.
12655   ;;
12656   *)
12657   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12658 for as_dir in $PATH
12659 do
12660   IFS=$as_save_IFS
12661   test -z "$as_dir" && as_dir=.
12662     for ac_exec_ext in '' $ac_executable_extensions; do
12663   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12664     ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext"
12665     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12666     break 2
12667   fi
12668 done
12669   done
12670 IFS=$as_save_IFS
12671 
12672   ;;
12673 esac
12674 fi
12675 READLINK=$ac_cv_path_READLINK
12676 if test -n "$READLINK"; then
12677   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5
12678 $as_echo "$READLINK" >&6; }
12679 else
12680   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12681 $as_echo "no" >&6; }
12682 fi
12683 
12684 
12685   test -n "$READLINK" && break
12686 done
12687 
12688     else
12689       # If it succeeded, then it was overridden by the user. We will use it
12690       # for the tool.
12691 
12692       # First remove it from the list of overridden variables, so we can test
12693       # for unknown variables in the end.
12694       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12695 
12696       # Check if the provided tool contains a complete path.
12697       tool_specified="$READLINK"
12698       tool_basename="${tool_specified##*/}"
12699       if test "x$tool_basename" = "x$tool_specified"; then
12700         # A command without a complete path is provided, search $PATH.
12701         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READLINK=$tool_basename" >&5
12702 $as_echo "$as_me: Will search for user supplied tool READLINK=$tool_basename" >&6;}
12703         # Extract the first word of "$tool_basename", so it can be a program name with args.
12704 set dummy $tool_basename; ac_word=$2
12705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12706 $as_echo_n "checking for $ac_word... " >&6; }
12707 if ${ac_cv_path_READLINK+:} false; then :
12708   $as_echo_n "(cached) " >&6
12709 else
12710   case $READLINK in
12711   [\\/]* | ?:[\\/]*)
12712   ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path.
12713   ;;
12714   *)
12715   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12716 for as_dir in $PATH
12717 do
12718   IFS=$as_save_IFS
12719   test -z "$as_dir" && as_dir=.
12720     for ac_exec_ext in '' $ac_executable_extensions; do
12721   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12722     ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext"
12723     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12724     break 2
12725   fi
12726 done
12727   done
12728 IFS=$as_save_IFS
12729 
12730   ;;
12731 esac
12732 fi
12733 READLINK=$ac_cv_path_READLINK
12734 if test -n "$READLINK"; then
12735   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5
12736 $as_echo "$READLINK" >&6; }
12737 else
12738   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12739 $as_echo "no" >&6; }
12740 fi
12741 
12742 
12743         if test "x$READLINK" = x; then
12744           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12745         fi
12746       else
12747         # Otherwise we believe it is a complete path. Use it as it is.
12748         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READLINK=$tool_specified" >&5
12749 $as_echo "$as_me: Will use user supplied tool READLINK=$tool_specified" >&6;}
12750         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5
12751 $as_echo_n "checking for READLINK... " >&6; }
12752         if test ! -x "$tool_specified"; then
12753           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12754 $as_echo "not found" >&6; }
12755           as_fn_error $? "User supplied tool READLINK=$tool_specified does not exist or is not executable" "$LINENO" 5
12756         fi
12757         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12758 $as_echo "$tool_specified" >&6; }
12759       fi
12760     fi
12761   fi
12762 
12763 
12764 
12765 
12766   # Publish this variable in the help.
12767 
12768 
12769   if test "x$DF" = x; then
12770     # The variable is not set by user, try to locate tool using the code snippet
12771     for ac_prog in df
12772 do
12773   # Extract the first word of "$ac_prog", so it can be a program name with args.
12774 set dummy $ac_prog; ac_word=$2
12775 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12776 $as_echo_n "checking for $ac_word... " >&6; }
12777 if ${ac_cv_path_DF+:} false; then :
12778   $as_echo_n "(cached) " >&6
12779 else
12780   case $DF in
12781   [\\/]* | ?:[\\/]*)
12782   ac_cv_path_DF="$DF" # Let the user override the test with a path.
12783   ;;
12784   *)
12785   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12786 for as_dir in $PATH
12787 do
12788   IFS=$as_save_IFS
12789   test -z "$as_dir" && as_dir=.
12790     for ac_exec_ext in '' $ac_executable_extensions; do
12791   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12792     ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext"
12793     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12794     break 2
12795   fi
12796 done
12797   done
12798 IFS=$as_save_IFS
12799 
12800   ;;
12801 esac
12802 fi
12803 DF=$ac_cv_path_DF
12804 if test -n "$DF"; then
12805   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5
12806 $as_echo "$DF" >&6; }
12807 else
12808   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12809 $as_echo "no" >&6; }
12810 fi
12811 
12812 
12813   test -n "$DF" && break
12814 done
12815 
12816   else
12817     # The variable is set, but is it from the command line or the environment?
12818 
12819     # Try to remove the string !DF! from our list.
12820     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DF!/}
12821     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12822       # If it failed, the variable was not from the command line. Ignore it,
12823       # but warn the user (except for BASH, which is always set by the calling BASH).
12824       if test "xDF" != xBASH; then
12825         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&5
12826 $as_echo "$as_me: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&2;}
12827       fi
12828       # Try to locate tool using the code snippet
12829       for ac_prog in df
12830 do
12831   # Extract the first word of "$ac_prog", so it can be a program name with args.
12832 set dummy $ac_prog; ac_word=$2
12833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12834 $as_echo_n "checking for $ac_word... " >&6; }
12835 if ${ac_cv_path_DF+:} false; then :
12836   $as_echo_n "(cached) " >&6
12837 else
12838   case $DF in
12839   [\\/]* | ?:[\\/]*)
12840   ac_cv_path_DF="$DF" # Let the user override the test with a path.
12841   ;;
12842   *)
12843   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12844 for as_dir in $PATH
12845 do
12846   IFS=$as_save_IFS
12847   test -z "$as_dir" && as_dir=.
12848     for ac_exec_ext in '' $ac_executable_extensions; do
12849   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12850     ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext"
12851     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12852     break 2
12853   fi
12854 done
12855   done
12856 IFS=$as_save_IFS
12857 
12858   ;;
12859 esac
12860 fi
12861 DF=$ac_cv_path_DF
12862 if test -n "$DF"; then
12863   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5
12864 $as_echo "$DF" >&6; }
12865 else
12866   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12867 $as_echo "no" >&6; }
12868 fi
12869 
12870 
12871   test -n "$DF" && break
12872 done
12873 
12874     else
12875       # If it succeeded, then it was overridden by the user. We will use it
12876       # for the tool.
12877 
12878       # First remove it from the list of overridden variables, so we can test
12879       # for unknown variables in the end.
12880       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12881 
12882       # Check if the provided tool contains a complete path.
12883       tool_specified="$DF"
12884       tool_basename="${tool_specified##*/}"
12885       if test "x$tool_basename" = "x$tool_specified"; then
12886         # A command without a complete path is provided, search $PATH.
12887         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DF=$tool_basename" >&5
12888 $as_echo "$as_me: Will search for user supplied tool DF=$tool_basename" >&6;}
12889         # Extract the first word of "$tool_basename", so it can be a program name with args.
12890 set dummy $tool_basename; ac_word=$2
12891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12892 $as_echo_n "checking for $ac_word... " >&6; }
12893 if ${ac_cv_path_DF+:} false; then :
12894   $as_echo_n "(cached) " >&6
12895 else
12896   case $DF in
12897   [\\/]* | ?:[\\/]*)
12898   ac_cv_path_DF="$DF" # Let the user override the test with a path.
12899   ;;
12900   *)
12901   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12902 for as_dir in $PATH
12903 do
12904   IFS=$as_save_IFS
12905   test -z "$as_dir" && as_dir=.
12906     for ac_exec_ext in '' $ac_executable_extensions; do
12907   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12908     ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext"
12909     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12910     break 2
12911   fi
12912 done
12913   done
12914 IFS=$as_save_IFS
12915 
12916   ;;
12917 esac
12918 fi
12919 DF=$ac_cv_path_DF
12920 if test -n "$DF"; then
12921   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5
12922 $as_echo "$DF" >&6; }
12923 else
12924   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12925 $as_echo "no" >&6; }
12926 fi
12927 
12928 
12929         if test "x$DF" = x; then
12930           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12931         fi
12932       else
12933         # Otherwise we believe it is a complete path. Use it as it is.
12934         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DF=$tool_specified" >&5
12935 $as_echo "$as_me: Will use user supplied tool DF=$tool_specified" >&6;}
12936         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5
12937 $as_echo_n "checking for DF... " >&6; }
12938         if test ! -x "$tool_specified"; then
12939           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12940 $as_echo "not found" >&6; }
12941           as_fn_error $? "User supplied tool DF=$tool_specified does not exist or is not executable" "$LINENO" 5
12942         fi
12943         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12944 $as_echo "$tool_specified" >&6; }
12945       fi
12946     fi
12947   fi
12948 
12949 
12950 
12951 
12952   # Publish this variable in the help.
12953 
12954 
12955   if test "x$SETFILE" = x; then
12956     # The variable is not set by user, try to locate tool using the code snippet
12957     for ac_prog in SetFile
12958 do
12959   # Extract the first word of "$ac_prog", so it can be a program name with args.
12960 set dummy $ac_prog; ac_word=$2
12961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12962 $as_echo_n "checking for $ac_word... " >&6; }
12963 if ${ac_cv_path_SETFILE+:} false; then :
12964   $as_echo_n "(cached) " >&6
12965 else
12966   case $SETFILE in
12967   [\\/]* | ?:[\\/]*)
12968   ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path.
12969   ;;
12970   *)
12971   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12972 for as_dir in $PATH
12973 do
12974   IFS=$as_save_IFS
12975   test -z "$as_dir" && as_dir=.
12976     for ac_exec_ext in '' $ac_executable_extensions; do
12977   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12978     ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext"
12979     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12980     break 2
12981   fi
12982 done
12983   done
12984 IFS=$as_save_IFS
12985 
12986   ;;
12987 esac
12988 fi
12989 SETFILE=$ac_cv_path_SETFILE
12990 if test -n "$SETFILE"; then
12991   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5
12992 $as_echo "$SETFILE" >&6; }
12993 else
12994   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12995 $as_echo "no" >&6; }
12996 fi
12997 
12998 
12999   test -n "$SETFILE" && break
13000 done
13001 
13002   else
13003     # The variable is set, but is it from the command line or the environment?
13004 
13005     # Try to remove the string !SETFILE! from our list.
13006     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SETFILE!/}
13007     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
13008       # If it failed, the variable was not from the command line. Ignore it,
13009       # but warn the user (except for BASH, which is always set by the calling BASH).
13010       if test "xSETFILE" != xBASH; then
13011         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&5
13012 $as_echo "$as_me: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&2;}
13013       fi
13014       # Try to locate tool using the code snippet
13015       for ac_prog in SetFile
13016 do
13017   # Extract the first word of "$ac_prog", so it can be a program name with args.
13018 set dummy $ac_prog; ac_word=$2
13019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13020 $as_echo_n "checking for $ac_word... " >&6; }
13021 if ${ac_cv_path_SETFILE+:} false; then :
13022   $as_echo_n "(cached) " >&6
13023 else
13024   case $SETFILE in
13025   [\\/]* | ?:[\\/]*)
13026   ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path.
13027   ;;
13028   *)
13029   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13030 for as_dir in $PATH
13031 do
13032   IFS=$as_save_IFS
13033   test -z "$as_dir" && as_dir=.
13034     for ac_exec_ext in '' $ac_executable_extensions; do
13035   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13036     ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext"
13037     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13038     break 2
13039   fi
13040 done
13041   done
13042 IFS=$as_save_IFS
13043 
13044   ;;
13045 esac
13046 fi
13047 SETFILE=$ac_cv_path_SETFILE
13048 if test -n "$SETFILE"; then
13049   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5
13050 $as_echo "$SETFILE" >&6; }
13051 else
13052   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13053 $as_echo "no" >&6; }
13054 fi
13055 
13056 
13057   test -n "$SETFILE" && break
13058 done
13059 
13060     else
13061       # If it succeeded, then it was overridden by the user. We will use it
13062       # for the tool.
13063 
13064       # First remove it from the list of overridden variables, so we can test
13065       # for unknown variables in the end.
13066       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
13067 
13068       # Check if the provided tool contains a complete path.
13069       tool_specified="$SETFILE"
13070       tool_basename="${tool_specified##*/}"
13071       if test "x$tool_basename" = "x$tool_specified"; then
13072         # A command without a complete path is provided, search $PATH.
13073         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SETFILE=$tool_basename" >&5
13074 $as_echo "$as_me: Will search for user supplied tool SETFILE=$tool_basename" >&6;}
13075         # Extract the first word of "$tool_basename", so it can be a program name with args.
13076 set dummy $tool_basename; ac_word=$2
13077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13078 $as_echo_n "checking for $ac_word... " >&6; }
13079 if ${ac_cv_path_SETFILE+:} false; then :
13080   $as_echo_n "(cached) " >&6
13081 else
13082   case $SETFILE in
13083   [\\/]* | ?:[\\/]*)
13084   ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path.
13085   ;;
13086   *)
13087   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13088 for as_dir in $PATH
13089 do
13090   IFS=$as_save_IFS
13091   test -z "$as_dir" && as_dir=.
13092     for ac_exec_ext in '' $ac_executable_extensions; do
13093   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13094     ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext"
13095     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13096     break 2
13097   fi
13098 done
13099   done
13100 IFS=$as_save_IFS
13101 
13102   ;;
13103 esac
13104 fi
13105 SETFILE=$ac_cv_path_SETFILE
13106 if test -n "$SETFILE"; then
13107   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5
13108 $as_echo "$SETFILE" >&6; }
13109 else
13110   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13111 $as_echo "no" >&6; }
13112 fi
13113 
13114 
13115         if test "x$SETFILE" = x; then
13116           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
13117         fi
13118       else
13119         # Otherwise we believe it is a complete path. Use it as it is.
13120         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SETFILE=$tool_specified" >&5
13121 $as_echo "$as_me: Will use user supplied tool SETFILE=$tool_specified" >&6;}
13122         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5
13123 $as_echo_n "checking for SETFILE... " >&6; }
13124         if test ! -x "$tool_specified"; then
13125           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
13126 $as_echo "not found" >&6; }
13127           as_fn_error $? "User supplied tool SETFILE=$tool_specified does not exist or is not executable" "$LINENO" 5
13128         fi
13129         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
13130 $as_echo "$tool_specified" >&6; }
13131       fi
13132     fi
13133   fi
13134 
13135 
13136 
13137 
13138 # Now we can determine OpenJDK build and target platforms. This is required to
13139 # have early on.
13140 # Make sure we can run config.sub.
13141 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
13142   as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
13143 
13144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
13145 $as_echo_n "checking build system type... " >&6; }
13146 if ${ac_cv_build+:} false; then :
13147   $as_echo_n "(cached) " >&6
13148 else
13149   ac_build_alias=$build_alias
13150 test "x$ac_build_alias" = x &&
13151   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
13152 test "x$ac_build_alias" = x &&
13153   as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
13154 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
13155   as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
13156 
13157 fi
13158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
13159 $as_echo "$ac_cv_build" >&6; }
13160 case $ac_cv_build in
13161 *-*-*) ;;
13162 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
13163 esac
13164 build=$ac_cv_build
13165 ac_save_IFS=$IFS; IFS='-'
13166 set x $ac_cv_build
13167 shift
13168 build_cpu=$1
13169 build_vendor=$2
13170 shift; shift
13171 # Remember, the first character of IFS is used to create $*,
13172 # except with old shells:
13173 build_os=$*
13174 IFS=$ac_save_IFS
13175 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
13176 
13177 
13178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
13179 $as_echo_n "checking host system type... " >&6; }
13180 if ${ac_cv_host+:} false; then :
13181   $as_echo_n "(cached) " >&6
13182 else
13183   if test "x$host_alias" = x; then
13184   ac_cv_host=$ac_cv_build
13185 else
13186   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
13187     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
13188 fi
13189 
13190 fi
13191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
13192 $as_echo "$ac_cv_host" >&6; }
13193 case $ac_cv_host in
13194 *-*-*) ;;
13195 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
13196 esac
13197 host=$ac_cv_host
13198 ac_save_IFS=$IFS; IFS='-'
13199 set x $ac_cv_host
13200 shift
13201 host_cpu=$1
13202 host_vendor=$2
13203 shift; shift
13204 # Remember, the first character of IFS is used to create $*,
13205 # except with old shells:
13206 host_os=$*
13207 IFS=$ac_save_IFS
13208 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
13209 
13210 
13211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
13212 $as_echo_n "checking target system type... " >&6; }
13213 if ${ac_cv_target+:} false; then :
13214   $as_echo_n "(cached) " >&6
13215 else
13216   if test "x$target_alias" = x; then
13217   ac_cv_target=$ac_cv_host
13218 else
13219   ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
13220     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
13221 fi
13222 
13223 fi
13224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
13225 $as_echo "$ac_cv_target" >&6; }
13226 case $ac_cv_target in
13227 *-*-*) ;;
13228 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
13229 esac
13230 target=$ac_cv_target
13231 ac_save_IFS=$IFS; IFS='-'
13232 set x $ac_cv_target
13233 shift
13234 target_cpu=$1
13235 target_vendor=$2
13236 shift; shift
13237 # Remember, the first character of IFS is used to create $*,
13238 # except with old shells:
13239 target_os=$*
13240 IFS=$ac_save_IFS
13241 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
13242 
13243 
13244 # The aliases save the names the user supplied, while $host etc.
13245 # will get canonicalized.
13246 test -n "$target_alias" &&
13247   test "$program_prefix$program_suffix$program_transform_name" = \
13248     NONENONEs,x,x, &&
13249   program_prefix=${target_alias}-
13250 
13251   # Figure out the build and target systems. # Note that in autoconf terminology, "build" is obvious, but "target"
13252   # is confusing; it assumes you are cross-compiling a cross-compiler (!)  and "target" is thus the target of the
13253   # product you're building. The target of this build is called "host". Since this is confusing to most people, we
13254   # have not adopted that system, but use "target" as the platform we are building for. In some places though we need
13255   # to use the configure naming style.
13256 
13257 
13258 
13259 
13260 
13261   # Copy the autoconf trip/quadruplet verbatim to OPENJDK_TARGET_AUTOCONF_NAME
13262   # (from the autoconf "host") and OPENJDK_BUILD_AUTOCONF_NAME
13263   # Note that we might later on rewrite e.g. OPENJDK_TARGET_CPU due to reduced build,
13264   # but this will not change the value of OPENJDK_TARGET_AUTOCONF_NAME.
13265   OPENJDK_TARGET_AUTOCONF_NAME="$host"
13266   OPENJDK_BUILD_AUTOCONF_NAME="$build"
13267 
13268 
13269 
13270   # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables.
13271 
13272   case "$build_os" in
13273     *linux*)
13274       VAR_OS=linux
13275       VAR_OS_API=posix
13276       VAR_OS_ENV=linux
13277       ;;
13278     *solaris*)
13279       VAR_OS=solaris
13280       VAR_OS_API=posix
13281       VAR_OS_ENV=solaris
13282       ;;
13283     *darwin*)
13284       VAR_OS=macosx
13285       VAR_OS_API=posix
13286       VAR_OS_ENV=macosx
13287       ;;
13288     *bsd*)
13289       VAR_OS=bsd
13290       VAR_OS_API=posix
13291       VAR_OS_ENV=bsd
13292       ;;
13293     *cygwin*)
13294       VAR_OS=windows
13295       VAR_OS_API=winapi
13296       VAR_OS_ENV=windows.cygwin
13297       ;;
13298     *mingw*)
13299       VAR_OS=windows
13300       VAR_OS_API=winapi
13301       VAR_OS_ENV=windows.msys
13302       ;;
13303     *aix*)
13304       VAR_OS=aix
13305       VAR_OS_API=posix
13306       VAR_OS_ENV=aix
13307       ;;
13308     *)
13309       as_fn_error $? "unsupported operating system $build_os" "$LINENO" 5
13310       ;;
13311   esac
13312 
13313 
13314   # First argument is the cpu name from the trip/quad
13315   case "$build_cpu" in
13316     x86_64)
13317       VAR_CPU=x86_64
13318       VAR_CPU_ARCH=x86
13319       VAR_CPU_BITS=64
13320       VAR_CPU_ENDIAN=little
13321       ;;
13322     i?86)
13323       VAR_CPU=x86
13324       VAR_CPU_ARCH=x86
13325       VAR_CPU_BITS=32
13326       VAR_CPU_ENDIAN=little
13327       ;;
13328     arm*)
13329       VAR_CPU=arm
13330       VAR_CPU_ARCH=arm
13331       VAR_CPU_BITS=32
13332       VAR_CPU_ENDIAN=little
13333       ;;
13334     powerpc)
13335       VAR_CPU=ppc
13336       VAR_CPU_ARCH=ppc
13337       VAR_CPU_BITS=32
13338       VAR_CPU_ENDIAN=big
13339       ;;
13340     powerpc64)
13341       VAR_CPU=ppc64
13342       VAR_CPU_ARCH=ppc
13343       VAR_CPU_BITS=64
13344       VAR_CPU_ENDIAN=big
13345       ;;
13346     s390)
13347       VAR_CPU=s390
13348       VAR_CPU_ARCH=s390
13349       VAR_CPU_BITS=32
13350       VAR_CPU_ENDIAN=big
13351       ;;
13352     s390x)
13353       VAR_CPU=s390x
13354       VAR_CPU_ARCH=s390
13355       VAR_CPU_BITS=64
13356       VAR_CPU_ENDIAN=big
13357       ;;
13358     sparc)
13359       VAR_CPU=sparc
13360       VAR_CPU_ARCH=sparc
13361       VAR_CPU_BITS=32
13362       VAR_CPU_ENDIAN=big
13363       ;;
13364     sparcv9)
13365       VAR_CPU=sparcv9
13366       VAR_CPU_ARCH=sparc
13367       VAR_CPU_BITS=64
13368       VAR_CPU_ENDIAN=big
13369       ;;
13370     *)
13371       as_fn_error $? "unsupported cpu $build_cpu" "$LINENO" 5
13372       ;;
13373   esac
13374 
13375   # ..and setup our own variables. (Do this explicitely to facilitate searching)
13376   OPENJDK_BUILD_OS="$VAR_OS"
13377   OPENJDK_BUILD_OS_API="$VAR_OS_API"
13378   OPENJDK_BUILD_OS_ENV="$VAR_OS_ENV"
13379   OPENJDK_BUILD_CPU="$VAR_CPU"
13380   OPENJDK_BUILD_CPU_ARCH="$VAR_CPU_ARCH"
13381   OPENJDK_BUILD_CPU_BITS="$VAR_CPU_BITS"
13382   OPENJDK_BUILD_CPU_ENDIAN="$VAR_CPU_ENDIAN"
13383 
13384 
13385 
13386 
13387 
13388 
13389 
13390   { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-build os-cpu" >&5
13391 $as_echo_n "checking openjdk-build os-cpu... " >&6; }
13392   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&5
13393 $as_echo "$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&6; }
13394 
13395   # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables.
13396 
13397   case "$host_os" in
13398     *linux*)
13399       VAR_OS=linux
13400       VAR_OS_API=posix
13401       VAR_OS_ENV=linux
13402       ;;
13403     *solaris*)
13404       VAR_OS=solaris
13405       VAR_OS_API=posix
13406       VAR_OS_ENV=solaris
13407       ;;
13408     *darwin*)
13409       VAR_OS=macosx
13410       VAR_OS_API=posix
13411       VAR_OS_ENV=macosx
13412       ;;
13413     *bsd*)
13414       VAR_OS=bsd
13415       VAR_OS_API=posix
13416       VAR_OS_ENV=bsd
13417       ;;
13418     *cygwin*)
13419       VAR_OS=windows
13420       VAR_OS_API=winapi
13421       VAR_OS_ENV=windows.cygwin
13422       ;;
13423     *mingw*)
13424       VAR_OS=windows
13425       VAR_OS_API=winapi
13426       VAR_OS_ENV=windows.msys
13427       ;;
13428     *aix*)
13429       VAR_OS=aix
13430       VAR_OS_API=posix
13431       VAR_OS_ENV=aix
13432       ;;
13433     *)
13434       as_fn_error $? "unsupported operating system $host_os" "$LINENO" 5
13435       ;;
13436   esac
13437 
13438 
13439   # First argument is the cpu name from the trip/quad
13440   case "$host_cpu" in
13441     x86_64)
13442       VAR_CPU=x86_64
13443       VAR_CPU_ARCH=x86
13444       VAR_CPU_BITS=64
13445       VAR_CPU_ENDIAN=little
13446       ;;
13447     i?86)
13448       VAR_CPU=x86
13449       VAR_CPU_ARCH=x86
13450       VAR_CPU_BITS=32
13451       VAR_CPU_ENDIAN=little
13452       ;;
13453     arm*)
13454       VAR_CPU=arm
13455       VAR_CPU_ARCH=arm
13456       VAR_CPU_BITS=32
13457       VAR_CPU_ENDIAN=little
13458       ;;
13459     powerpc)
13460       VAR_CPU=ppc
13461       VAR_CPU_ARCH=ppc
13462       VAR_CPU_BITS=32
13463       VAR_CPU_ENDIAN=big
13464       ;;
13465     powerpc64)
13466       VAR_CPU=ppc64
13467       VAR_CPU_ARCH=ppc
13468       VAR_CPU_BITS=64
13469       VAR_CPU_ENDIAN=big
13470       ;;
13471     s390)
13472       VAR_CPU=s390
13473       VAR_CPU_ARCH=s390
13474       VAR_CPU_BITS=32
13475       VAR_CPU_ENDIAN=big
13476       ;;
13477     s390x)
13478       VAR_CPU=s390x
13479       VAR_CPU_ARCH=s390
13480       VAR_CPU_BITS=64
13481       VAR_CPU_ENDIAN=big
13482       ;;
13483     sparc)
13484       VAR_CPU=sparc
13485       VAR_CPU_ARCH=sparc
13486       VAR_CPU_BITS=32
13487       VAR_CPU_ENDIAN=big
13488       ;;
13489     sparcv9)
13490       VAR_CPU=sparcv9
13491       VAR_CPU_ARCH=sparc
13492       VAR_CPU_BITS=64
13493       VAR_CPU_ENDIAN=big
13494       ;;
13495     *)
13496       as_fn_error $? "unsupported cpu $host_cpu" "$LINENO" 5
13497       ;;
13498   esac
13499 
13500   # ... and setup our own variables. (Do this explicitely to facilitate searching)
13501   OPENJDK_TARGET_OS="$VAR_OS"
13502   OPENJDK_TARGET_OS_API="$VAR_OS_API"
13503   OPENJDK_TARGET_OS_ENV="$VAR_OS_ENV"
13504   OPENJDK_TARGET_CPU="$VAR_CPU"
13505   OPENJDK_TARGET_CPU_ARCH="$VAR_CPU_ARCH"
13506   OPENJDK_TARGET_CPU_BITS="$VAR_CPU_BITS"
13507   OPENJDK_TARGET_CPU_ENDIAN="$VAR_CPU_ENDIAN"
13508 
13509 
13510 
13511 
13512 
13513 
13514 
13515   { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-target os-cpu" >&5
13516 $as_echo_n "checking openjdk-target os-cpu... " >&6; }
13517   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&5
13518 $as_echo "$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&6; }
13519 
13520 
13521 
13522 # Check whether --with-target-bits was given.
13523 if test "${with_target_bits+set}" = set; then :
13524   withval=$with_target_bits;
13525 fi
13526 
13527 
13528   # We have three types of compiles:
13529   # native  == normal compilation, target system == build system
13530   # cross   == traditional cross compilation, target system != build system; special toolchain needed
13531   # reduced == using native compilers, but with special flags (e.g. -m32) to produce 32-bit builds on 64-bit machines
13532   #
13533   if test "x$OPENJDK_BUILD_AUTOCONF_NAME" != "x$OPENJDK_TARGET_AUTOCONF_NAME"; then
13534     # We're doing a proper cross-compilation
13535     COMPILE_TYPE="cross"
13536   else
13537     COMPILE_TYPE="native"
13538   fi
13539 
13540   if test "x$with_target_bits" != x; then
13541     if test "x$COMPILE_TYPE" = "xcross"; then
13542       as_fn_error $? "It is not possible to combine --with-target-bits=X and proper cross-compilation. Choose either." "$LINENO" 5
13543     fi
13544 
13545     if test "x$with_target_bits" = x32 && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
13546       # A reduced build is requested
13547       COMPILE_TYPE="reduced"
13548       OPENJDK_TARGET_CPU_BITS=32
13549       if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then
13550         OPENJDK_TARGET_CPU=x86
13551       elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then
13552         OPENJDK_TARGET_CPU=sparc
13553       else
13554         as_fn_error $? "Reduced build (--with-target-bits=32) is only supported on x86_64 and sparcv9" "$LINENO" 5
13555       fi
13556     elif test "x$with_target_bits" = x64 && test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
13557       as_fn_error $? "It is not possible to use --with-target-bits=64 on a 32 bit system. Use proper cross-compilation instead." "$LINENO" 5
13558     elif test "x$with_target_bits" = "x$OPENJDK_TARGET_CPU_BITS"; then
13559       { $as_echo "$as_me:${as_lineno-$LINENO}: --with-target-bits are set to build platform address size; argument has no meaning" >&5
13560 $as_echo "$as_me: --with-target-bits are set to build platform address size; argument has no meaning" >&6;}
13561     else
13562       as_fn_error $? "--with-target-bits can only be 32 or 64, you specified $with_target_bits!" "$LINENO" 5
13563     fi
13564   fi
13565 
13566 
13567   { $as_echo "$as_me:${as_lineno-$LINENO}: checking compilation type" >&5
13568 $as_echo_n "checking compilation type... " >&6; }
13569   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPILE_TYPE" >&5
13570 $as_echo "$COMPILE_TYPE" >&6; }
13571 
13572 
13573   if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then
13574     REQUIRED_OS_NAME=SunOS
13575     REQUIRED_OS_VERSION=5.10
13576   fi
13577   if test "x$OPENJDK_TARGET_OS" = "xlinux"; then
13578     REQUIRED_OS_NAME=Linux
13579     REQUIRED_OS_VERSION=2.6
13580   fi
13581   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
13582     REQUIRED_OS_NAME=Windows
13583     if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then
13584       REQUIRED_OS_VERSION=5.2
13585     else
13586       REQUIRED_OS_VERSION=5.1
13587     fi
13588   fi
13589   if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
13590     REQUIRED_OS_NAME=Darwin
13591     REQUIRED_OS_VERSION=11.2
13592   fi
13593 
13594 
13595 
13596 
13597 
13598   # Also store the legacy naming of the cpu.
13599   # Ie i586 and amd64 instead of x86 and x86_64
13600   OPENJDK_TARGET_CPU_LEGACY="$OPENJDK_TARGET_CPU"
13601   if test "x$OPENJDK_TARGET_CPU" = xx86; then
13602     OPENJDK_TARGET_CPU_LEGACY="i586"
13603   elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13604     # On all platforms except MacOSX replace x86_64 with amd64.
13605     OPENJDK_TARGET_CPU_LEGACY="amd64"
13606   fi
13607 
13608 
13609   # And the second legacy naming of the cpu.
13610   # Ie i386 and amd64 instead of x86 and x86_64.
13611   OPENJDK_TARGET_CPU_LEGACY_LIB="$OPENJDK_TARGET_CPU"
13612   if test "x$OPENJDK_TARGET_CPU" = xx86; then
13613     OPENJDK_TARGET_CPU_LEGACY_LIB="i386"
13614   elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13615     OPENJDK_TARGET_CPU_LEGACY_LIB="amd64"
13616   fi
13617 
13618 
13619   # This is the name of the cpu (but using i386 and amd64 instead of
13620   # x86 and x86_64, respectively), preceeded by a /, to be used when
13621   # locating libraries. On macosx, it's empty, though.
13622   OPENJDK_TARGET_CPU_LIBDIR="/$OPENJDK_TARGET_CPU_LEGACY_LIB"
13623   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
13624     OPENJDK_TARGET_CPU_LIBDIR=""
13625   fi
13626 
13627 
13628   # OPENJDK_TARGET_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to
13629   # /amd64 or /sparcv9. This string is appended to some library paths, like this:
13630   # /usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libexample.so
13631   OPENJDK_TARGET_CPU_ISADIR=""
13632   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
13633     if test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13634       OPENJDK_TARGET_CPU_ISADIR="/amd64"
13635     elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then
13636       OPENJDK_TARGET_CPU_ISADIR="/sparcv9"
13637     fi
13638   fi
13639 
13640 
13641   # Setup OPENJDK_TARGET_CPU_OSARCH, which is used to set the os.arch Java system property
13642   OPENJDK_TARGET_CPU_OSARCH="$OPENJDK_TARGET_CPU"
13643   if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$OPENJDK_TARGET_CPU" = xx86; then
13644     # On linux only, we replace x86 with i386.
13645     OPENJDK_TARGET_CPU_OSARCH="i386"
13646   elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13647     # On all platforms except macosx, we replace x86_64 with amd64.
13648     OPENJDK_TARGET_CPU_OSARCH="amd64"
13649   fi
13650 
13651 
13652   OPENJDK_TARGET_CPU_JLI="$OPENJDK_TARGET_CPU"
13653   if test "x$OPENJDK_TARGET_CPU" = xx86; then
13654     OPENJDK_TARGET_CPU_JLI="i386"
13655   elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13656     # On all platforms except macosx, we replace x86_64 with amd64.
13657     OPENJDK_TARGET_CPU_JLI="amd64"
13658   fi
13659   # Now setup the -D flags for building libjli.
13660   OPENJDK_TARGET_CPU_JLI_CFLAGS="-DLIBARCHNAME='\"$OPENJDK_TARGET_CPU_JLI\"'"
13661   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
13662     if test "x$OPENJDK_TARGET_CPU_ARCH" = xsparc; then
13663       OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"sparc\"' -DLIBARCH64NAME='\"sparcv9\"'"
13664     elif test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then
13665       OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"i386\"' -DLIBARCH64NAME='\"amd64\"'"
13666     fi
13667   fi
13668 
13669 
13670   # Setup OPENJDK_TARGET_OS_API_DIR, used in source paths.
13671   if test "x$OPENJDK_TARGET_OS_API" = xposix; then
13672     OPENJDK_TARGET_OS_API_DIR="solaris"
13673   fi
13674   if test "x$OPENJDK_TARGET_OS_API" = xwinapi; then
13675     OPENJDK_TARGET_OS_API_DIR="windows"
13676   fi
13677 
13678 
13679   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
13680       OPENJDK_TARGET_OS_EXPORT_DIR=macosx
13681   else
13682       OPENJDK_TARGET_OS_EXPORT_DIR=${OPENJDK_TARGET_OS_API_DIR}
13683   fi
13684 
13685 
13686   if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
13687     A_LP64="LP64:="
13688     # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in
13689     # unpack200.exe
13690     if test "x$OPENJDK_TARGET_OS" = xlinux || test "x$OPENJDK_TARGET_OS" = xmacosx; then
13691       ADD_LP64="-D_LP64=1"
13692     fi
13693   fi
13694   LP64=$A_LP64
13695 
13696 
13697   if test "x$COMPILE_TYPE" = "xcross"; then
13698     # FIXME: ... or should this include reduced builds..?
13699     DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_TARGET_CPU_LEGACY"
13700   else
13701     DEFINE_CROSS_COMPILE_ARCH=""
13702   fi
13703 
13704 
13705   # ZERO_ARCHDEF is used to enable architecture-specific code
13706   case "${OPENJDK_TARGET_CPU}" in
13707     ppc*)    ZERO_ARCHDEF=PPC   ;;
13708     s390*)   ZERO_ARCHDEF=S390  ;;
13709     sparc*)  ZERO_ARCHDEF=SPARC ;;
13710     x86_64*) ZERO_ARCHDEF=AMD64 ;;
13711     x86)     ZERO_ARCHDEF=IA32  ;;
13712     *)      ZERO_ARCHDEF=$(echo "${OPENJDK_TARGET_CPU_LEGACY_LIB}" | tr a-z A-Z)
13713   esac
13714 
13715 
13716 
13717 
13718 # Continue setting up basic stuff. Most remaining code require fundamental tools.
13719 
13720   # We get the top-level directory from the supporting wrappers.
13721   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for top-level directory" >&5
13722 $as_echo_n "checking for top-level directory... " >&6; }
13723   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOPDIR" >&5
13724 $as_echo "$TOPDIR" >&6; }
13725 
13726   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
13727 
13728   # Input might be given as Windows format, start by converting to
13729   # unix format.
13730   path="$TOPDIR"
13731   new_path=`$CYGPATH -u "$path"`
13732 
13733   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
13734   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
13735   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
13736   # "foo.exe" is OK but "foo" is an error.
13737   #
13738   # This test is therefore slightly more accurate than "test -f" to check for file precense.
13739   # It is also a way to make sure we got the proper file name for the real test later on.
13740   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
13741   if test "x$test_shortpath" = x; then
13742     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5
13743 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;}
13744     as_fn_error $? "Cannot locate the the path of TOPDIR" "$LINENO" 5
13745   fi
13746 
13747   # Call helper function which possibly converts this using DOS-style short mode.
13748   # If so, the updated path is stored in $new_path.
13749 
13750   input_path="$new_path"
13751   # Check if we need to convert this using DOS-style short mode. If the path
13752   # contains just simple characters, use it. Otherwise (spaces, weird characters),
13753   # take no chances and rewrite it.
13754   # Note: m4 eats our [], so we need to use [ and ] instead.
13755   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
13756   if test "x$has_forbidden_chars" != x; then
13757     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
13758     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
13759     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
13760     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
13761       # Going to short mode and back again did indeed matter. Since short mode is
13762       # case insensitive, let's make it lowercase to improve readability.
13763       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
13764       # Now convert it back to Unix-stile (cygpath)
13765       input_path=`$CYGPATH -u "$shortmode_path"`
13766       new_path="$input_path"
13767     fi
13768   fi
13769 
13770   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
13771   if test "x$test_cygdrive_prefix" = x; then
13772     # As a simple fix, exclude /usr/bin since it's not a real path.
13773     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
13774       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
13775       # a path prefixed by /cygdrive for fixpath to work.
13776       new_path="$CYGWIN_ROOT_PATH$input_path"
13777     fi
13778   fi
13779 
13780 
13781   if test "x$path" != "x$new_path"; then
13782     TOPDIR="$new_path"
13783     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5
13784 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;}
13785   fi
13786 
13787   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
13788 
13789   path="$TOPDIR"
13790   has_colon=`$ECHO $path | $GREP ^.:`
13791   new_path="$path"
13792   if test "x$has_colon" = x; then
13793     # Not in mixed or Windows style, start by that.
13794     new_path=`cmd //c echo $path`
13795   fi
13796 
13797 
13798   input_path="$new_path"
13799   # Check if we need to convert this using DOS-style short mode. If the path
13800   # contains just simple characters, use it. Otherwise (spaces, weird characters),
13801   # take no chances and rewrite it.
13802   # Note: m4 eats our [], so we need to use [ and ] instead.
13803   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
13804   if test "x$has_forbidden_chars" != x; then
13805     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
13806     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
13807   fi
13808 
13809 
13810   windows_path="$new_path"
13811   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
13812     unix_path=`$CYGPATH -u "$windows_path"`
13813     new_path="$unix_path"
13814   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
13815     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
13816     new_path="$unix_path"
13817   fi
13818 
13819   if test "x$path" != "x$new_path"; then
13820     TOPDIR="$new_path"
13821     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5
13822 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;}
13823   fi
13824 
13825   # Save the first 10 bytes of this path to the storage, so fixpath can work.
13826   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
13827 
13828   else
13829     # We're on a posix platform. Hooray! :)
13830     path="$TOPDIR"
13831     has_space=`$ECHO "$path" | $GREP " "`
13832     if test "x$has_space" != x; then
13833       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5
13834 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;}
13835       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
13836     fi
13837 
13838     # Use eval to expand a potential ~
13839     eval path="$path"
13840     if test ! -f "$path" && test ! -d "$path"; then
13841       as_fn_error $? "The path of TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5
13842     fi
13843 
13844     TOPDIR="`cd "$path"; $THEPWDCMD -L`"
13845   fi
13846 
13847 
13848 
13849   # SRC_ROOT is a traditional alias for TOPDIR.
13850   SRC_ROOT=$TOPDIR
13851 
13852   # Locate the directory of this script.
13853   AUTOCONF_DIR=$TOPDIR/common/autoconf
13854 
13855   # Save the current directory this script was started from
13856   CURDIR="$PWD"
13857 
13858   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
13859 
13860   # Input might be given as Windows format, start by converting to
13861   # unix format.
13862   path="$CURDIR"
13863   new_path=`$CYGPATH -u "$path"`
13864 
13865   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
13866   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
13867   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
13868   # "foo.exe" is OK but "foo" is an error.
13869   #
13870   # This test is therefore slightly more accurate than "test -f" to check for file precense.
13871   # It is also a way to make sure we got the proper file name for the real test later on.
13872   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
13873   if test "x$test_shortpath" = x; then
13874     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5
13875 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;}
13876     as_fn_error $? "Cannot locate the the path of CURDIR" "$LINENO" 5
13877   fi
13878 
13879   # Call helper function which possibly converts this using DOS-style short mode.
13880   # If so, the updated path is stored in $new_path.
13881 
13882   input_path="$new_path"
13883   # Check if we need to convert this using DOS-style short mode. If the path
13884   # contains just simple characters, use it. Otherwise (spaces, weird characters),
13885   # take no chances and rewrite it.
13886   # Note: m4 eats our [], so we need to use [ and ] instead.
13887   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
13888   if test "x$has_forbidden_chars" != x; then
13889     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
13890     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
13891     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
13892     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
13893       # Going to short mode and back again did indeed matter. Since short mode is
13894       # case insensitive, let's make it lowercase to improve readability.
13895       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
13896       # Now convert it back to Unix-stile (cygpath)
13897       input_path=`$CYGPATH -u "$shortmode_path"`
13898       new_path="$input_path"
13899     fi
13900   fi
13901 
13902   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
13903   if test "x$test_cygdrive_prefix" = x; then
13904     # As a simple fix, exclude /usr/bin since it's not a real path.
13905     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
13906       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
13907       # a path prefixed by /cygdrive for fixpath to work.
13908       new_path="$CYGWIN_ROOT_PATH$input_path"
13909     fi
13910   fi
13911 
13912 
13913   if test "x$path" != "x$new_path"; then
13914     CURDIR="$new_path"
13915     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5
13916 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;}
13917   fi
13918 
13919   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
13920 
13921   path="$CURDIR"
13922   has_colon=`$ECHO $path | $GREP ^.:`
13923   new_path="$path"
13924   if test "x$has_colon" = x; then
13925     # Not in mixed or Windows style, start by that.
13926     new_path=`cmd //c echo $path`
13927   fi
13928 
13929 
13930   input_path="$new_path"
13931   # Check if we need to convert this using DOS-style short mode. If the path
13932   # contains just simple characters, use it. Otherwise (spaces, weird characters),
13933   # take no chances and rewrite it.
13934   # Note: m4 eats our [], so we need to use [ and ] instead.
13935   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
13936   if test "x$has_forbidden_chars" != x; then
13937     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
13938     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
13939   fi
13940 
13941 
13942   windows_path="$new_path"
13943   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
13944     unix_path=`$CYGPATH -u "$windows_path"`
13945     new_path="$unix_path"
13946   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
13947     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
13948     new_path="$unix_path"
13949   fi
13950 
13951   if test "x$path" != "x$new_path"; then
13952     CURDIR="$new_path"
13953     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5
13954 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;}
13955   fi
13956 
13957   # Save the first 10 bytes of this path to the storage, so fixpath can work.
13958   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
13959 
13960   else
13961     # We're on a posix platform. Hooray! :)
13962     path="$CURDIR"
13963     has_space=`$ECHO "$path" | $GREP " "`
13964     if test "x$has_space" != x; then
13965       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5
13966 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;}
13967       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
13968     fi
13969 
13970     # Use eval to expand a potential ~
13971     eval path="$path"
13972     if test ! -f "$path" && test ! -d "$path"; then
13973       as_fn_error $? "The path of CURDIR, which resolves as \"$path\", is not found." "$LINENO" 5
13974     fi
13975 
13976     CURDIR="`cd "$path"; $THEPWDCMD -L`"
13977   fi
13978 
13979 
13980   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
13981     PATH_SEP=";"
13982 
13983   SRC_ROOT_LENGTH=`$THEPWDCMD -L|$WC -m`
13984   if test $SRC_ROOT_LENGTH -gt 100; then
13985     as_fn_error $? "Your base path is too long. It is $SRC_ROOT_LENGTH characters long, but only 100 is supported" "$LINENO" 5
13986   fi
13987 
13988   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
13989     { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin release" >&5
13990 $as_echo_n "checking cygwin release... " >&6; }
13991     CYGWIN_VERSION=`$UNAME -r`
13992     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_VERSION" >&5
13993 $as_echo "$CYGWIN_VERSION" >&6; }
13994     WINDOWS_ENV_VENDOR='cygwin'
13995     WINDOWS_ENV_VERSION="$CYGWIN_VERSION"
13996 
13997     CYGWIN_VERSION_OK=`$ECHO $CYGWIN_VERSION | $GREP ^1.7.`
13998     if test "x$CYGWIN_VERSION_OK" = x; then
13999       { $as_echo "$as_me:${as_lineno-$LINENO}: Your cygwin is too old. You are running $CYGWIN_VERSION, but at least cygwin 1.7 is required. Please upgrade." >&5
14000 $as_echo "$as_me: Your cygwin is too old. You are running $CYGWIN_VERSION, but at least cygwin 1.7 is required. Please upgrade." >&6;}
14001       as_fn_error $? "Cannot continue" "$LINENO" 5
14002     fi
14003     if test "x$CYGPATH" = x; then
14004       as_fn_error $? "Something is wrong with your cygwin installation since I cannot find cygpath.exe in your path" "$LINENO" 5
14005     fi
14006     { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin root directory as unix-style path" >&5
14007 $as_echo_n "checking cygwin root directory as unix-style path... " >&6; }
14008     # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away
14009     cygwin_winpath_root=`cd / ; cmd /c cd | grep ".*"`
14010     # Force cygpath to report the proper root by including a trailing space, and then stripping it off again.
14011     CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "`
14012     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_ROOT_PATH" >&5
14013 $as_echo "$CYGWIN_ROOT_PATH" >&6; }
14014     WINDOWS_ENV_ROOT_PATH="$CYGWIN_ROOT_PATH"
14015     test_cygdrive_prefix=`$ECHO $CYGWIN_ROOT_PATH | $GREP ^/cygdrive/`
14016     if test "x$test_cygdrive_prefix" = x; then
14017       as_fn_error $? "Your cygdrive prefix is not /cygdrive. This is currently not supported. Change with mount -c." "$LINENO" 5
14018     fi
14019   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14020     { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys release" >&5
14021 $as_echo_n "checking msys release... " >&6; }
14022     MSYS_VERSION=`$UNAME -r`
14023     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_VERSION" >&5
14024 $as_echo "$MSYS_VERSION" >&6; }
14025 
14026     WINDOWS_ENV_VENDOR='msys'
14027     WINDOWS_ENV_VERSION="$MSYS_VERSION"
14028 
14029     { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys root directory as unix-style path" >&5
14030 $as_echo_n "checking msys root directory as unix-style path... " >&6; }
14031     # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away
14032     MSYS_ROOT_PATH=`cd / ; cmd /c cd | grep ".*"`
14033 
14034   windows_path="$MSYS_ROOT_PATH"
14035   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14036     unix_path=`$CYGPATH -u "$windows_path"`
14037     MSYS_ROOT_PATH="$unix_path"
14038   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14039     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14040     MSYS_ROOT_PATH="$unix_path"
14041   fi
14042 
14043     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_ROOT_PATH" >&5
14044 $as_echo "$MSYS_ROOT_PATH" >&6; }
14045     WINDOWS_ENV_ROOT_PATH="$MSYS_ROOT_PATH"
14046   else
14047     as_fn_error $? "Unknown Windows environment. Neither cygwin nor msys was detected." "$LINENO" 5
14048   fi
14049 
14050   # Test if windows or unix (cygwin/msys) find is first in path.
14051   { $as_echo "$as_me:${as_lineno-$LINENO}: checking what kind of 'find' is first on the PATH" >&5
14052 $as_echo_n "checking what kind of 'find' is first on the PATH... " >&6; }
14053   FIND_BINARY_OUTPUT=`find --version 2>&1`
14054   if test "x`echo $FIND_BINARY_OUTPUT | $GREP GNU`" != x; then
14055     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unix style" >&5
14056 $as_echo "unix style" >&6; }
14057   elif test "x`echo $FIND_BINARY_OUTPUT | $GREP FIND`" != x; then
14058     { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows" >&5
14059 $as_echo "Windows" >&6; }
14060     { $as_echo "$as_me:${as_lineno-$LINENO}: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&5
14061 $as_echo "$as_me: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&6;}
14062     { $as_echo "$as_me:${as_lineno-$LINENO}: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&5
14063 $as_echo "$as_me: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&6;}
14064     as_fn_error $? "Cannot continue" "$LINENO" 5
14065   else
14066     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5
14067 $as_echo "unknown" >&6; }
14068     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: It seems that your find utility is non-standard." >&5
14069 $as_echo "$as_me: WARNING: It seems that your find utility is non-standard." >&2;}
14070   fi
14071 
14072   else
14073     PATH_SEP=":"
14074   fi
14075 
14076 
14077   if test "x$OPENJDK_BUILD_OS" = "xsolaris"; then
14078     # Add extra search paths on solaris for utilities like ar and as etc...
14079     PATH="$PATH:/usr/ccs/bin:/usr/sfw/bin:/opt/csw/bin"
14080   fi
14081 
14082   # You can force the sys-root if the sys-root encoded into the cross compiler tools
14083   # is not correct.
14084 
14085 # Check whether --with-sys-root was given.
14086 if test "${with_sys_root+set}" = set; then :
14087   withval=$with_sys_root;
14088 fi
14089 
14090 
14091   if test "x$with_sys_root" != x; then
14092     SYS_ROOT=$with_sys_root
14093   else
14094     SYS_ROOT=/
14095   fi
14096 
14097 
14098 
14099 # Check whether --with-tools-dir was given.
14100 if test "${with_tools_dir+set}" = set; then :
14101   withval=$with_tools_dir; TOOLS_DIR=$with_tools_dir
14102 
14103 fi
14104 
14105 
14106 
14107 # Check whether --with-devkit was given.
14108 if test "${with_devkit+set}" = set; then :
14109   withval=$with_devkit;
14110         if test "x$with_sys_root" != x; then
14111           as_fn_error $? "Cannot specify both --with-devkit and --with-sys-root at the same time" "$LINENO" 5
14112         fi
14113 
14114   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14115 
14116   # Input might be given as Windows format, start by converting to
14117   # unix format.
14118   path="$with_devkit"
14119   new_path=`$CYGPATH -u "$path"`
14120 
14121   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14122   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14123   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14124   # "foo.exe" is OK but "foo" is an error.
14125   #
14126   # This test is therefore slightly more accurate than "test -f" to check for file precense.
14127   # It is also a way to make sure we got the proper file name for the real test later on.
14128   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14129   if test "x$test_shortpath" = x; then
14130     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5
14131 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;}
14132     as_fn_error $? "Cannot locate the the path of with_devkit" "$LINENO" 5
14133   fi
14134 
14135   # Call helper function which possibly converts this using DOS-style short mode.
14136   # If so, the updated path is stored in $new_path.
14137 
14138   input_path="$new_path"
14139   # Check if we need to convert this using DOS-style short mode. If the path
14140   # contains just simple characters, use it. Otherwise (spaces, weird characters),
14141   # take no chances and rewrite it.
14142   # Note: m4 eats our [], so we need to use [ and ] instead.
14143   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
14144   if test "x$has_forbidden_chars" != x; then
14145     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14146     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
14147     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
14148     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
14149       # Going to short mode and back again did indeed matter. Since short mode is
14150       # case insensitive, let's make it lowercase to improve readability.
14151       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14152       # Now convert it back to Unix-stile (cygpath)
14153       input_path=`$CYGPATH -u "$shortmode_path"`
14154       new_path="$input_path"
14155     fi
14156   fi
14157 
14158   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
14159   if test "x$test_cygdrive_prefix" = x; then
14160     # As a simple fix, exclude /usr/bin since it's not a real path.
14161     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
14162       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
14163       # a path prefixed by /cygdrive for fixpath to work.
14164       new_path="$CYGWIN_ROOT_PATH$input_path"
14165     fi
14166   fi
14167 
14168 
14169   if test "x$path" != "x$new_path"; then
14170     with_devkit="$new_path"
14171     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5
14172 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;}
14173   fi
14174 
14175   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14176 
14177   path="$with_devkit"
14178   has_colon=`$ECHO $path | $GREP ^.:`
14179   new_path="$path"
14180   if test "x$has_colon" = x; then
14181     # Not in mixed or Windows style, start by that.
14182     new_path=`cmd //c echo $path`
14183   fi
14184 
14185 
14186   input_path="$new_path"
14187   # Check if we need to convert this using DOS-style short mode. If the path
14188   # contains just simple characters, use it. Otherwise (spaces, weird characters),
14189   # take no chances and rewrite it.
14190   # Note: m4 eats our [], so we need to use [ and ] instead.
14191   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
14192   if test "x$has_forbidden_chars" != x; then
14193     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14194     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14195   fi
14196 
14197 
14198   windows_path="$new_path"
14199   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14200     unix_path=`$CYGPATH -u "$windows_path"`
14201     new_path="$unix_path"
14202   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14203     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14204     new_path="$unix_path"
14205   fi
14206 
14207   if test "x$path" != "x$new_path"; then
14208     with_devkit="$new_path"
14209     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5
14210 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;}
14211   fi
14212 
14213   # Save the first 10 bytes of this path to the storage, so fixpath can work.
14214   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
14215 
14216   else
14217     # We're on a posix platform. Hooray! :)
14218     path="$with_devkit"
14219     has_space=`$ECHO "$path" | $GREP " "`
14220     if test "x$has_space" != x; then
14221       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5
14222 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;}
14223       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14224     fi
14225 
14226     # Use eval to expand a potential ~
14227     eval path="$path"
14228     if test ! -f "$path" && test ! -d "$path"; then
14229       as_fn_error $? "The path of with_devkit, which resolves as \"$path\", is not found." "$LINENO" 5
14230     fi
14231 
14232     with_devkit="`cd "$path"; $THEPWDCMD -L`"
14233   fi
14234 
14235 
14236   if test "x$TOOLS_DIR" = x; then
14237     TOOLS_DIR="$with_devkit/bin"
14238   else
14239     TOOLS_DIR="$TOOLS_DIR:$with_devkit/bin"
14240   fi
14241 
14242         if test -d "$with_devkit/$host_alias/libc"; then
14243           SYS_ROOT=$with_devkit/$host_alias/libc
14244         elif test -d "$with_devkit/$host/sys-root"; then
14245           SYS_ROOT=$with_devkit/$host/sys-root
14246         fi
14247 
14248 fi
14249 
14250 
14251 
14252   # Setup default logging of stdout and stderr to build.log in the output root.
14253   BUILD_LOG='$(OUTPUT_ROOT)/build.log'
14254   BUILD_LOG_PREVIOUS='$(OUTPUT_ROOT)/build.log.old'
14255   BUILD_LOG_WRAPPER='$(BASH) $(SRC_ROOT)/common/bin/logger.sh $(BUILD_LOG)'
14256 
14257 
14258 
14259 
14260 
14261 # Check if it's a pure open build or if custom sources are to be used.
14262 
14263   # Check whether --enable-openjdk-only was given.
14264 if test "${enable_openjdk_only+set}" = set; then :
14265   enableval=$enable_openjdk_only;
14266 else
14267   enable_openjdk_only="no"
14268 fi
14269 
14270 
14271   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of closed sources" >&5
14272 $as_echo_n "checking for presence of closed sources... " >&6; }
14273   if test -d "$SRC_ROOT/jdk/src/closed"; then
14274     CLOSED_SOURCE_PRESENT=yes
14275   else
14276     CLOSED_SOURCE_PRESENT=no
14277   fi
14278   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CLOSED_SOURCE_PRESENT" >&5
14279 $as_echo "$CLOSED_SOURCE_PRESENT" >&6; }
14280 
14281   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closed source is suppressed (openjdk-only)" >&5
14282 $as_echo_n "checking if closed source is suppressed (openjdk-only)... " >&6; }
14283   SUPPRESS_CLOSED_SOURCE="$enable_openjdk_only"
14284   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SUPPRESS_CLOSED_SOURCE" >&5
14285 $as_echo "$SUPPRESS_CLOSED_SOURCE" >&6; }
14286 
14287   if test "x$CLOSED_SOURCE_PRESENT" = xno; then
14288     OPENJDK=true
14289     if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then
14290       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: No closed source present, --enable-openjdk-only makes no sense" >&5
14291 $as_echo "$as_me: WARNING: No closed source present, --enable-openjdk-only makes no sense" >&2;}
14292     fi
14293   else
14294     if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then
14295       OPENJDK=true
14296     else
14297       OPENJDK=false
14298     fi
14299   fi
14300 
14301   if test "x$OPENJDK" = "xtrue"; then
14302     SET_OPENJDK="OPENJDK=true"
14303   fi
14304 
14305 
14306 
14307   # custom-make-dir is deprecated. Please use your custom-hook.m4 to override
14308   # the IncludeCustomExtension macro.
14309 
14310 
14311 # Check whether --with-custom-make-dir was given.
14312 if test "${with_custom_make_dir+set}" = set; then :
14313   withval=$with_custom_make_dir; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-custom-make-dir is deprecated and will be ignored." >&5
14314 $as_echo "$as_me: WARNING: Option --with-custom-make-dir is deprecated and will be ignored." >&2;}
14315 fi
14316 
14317 
14318 
14319 
14320 # These are needed to be able to create a configuration name (and thus the output directory)
14321 
14322   ###############################################################################
14323   #
14324   # Check which variant of the JDK that we want to build.
14325   # Currently we have:
14326   #    normal:   standard edition
14327   # but the custom make system may add other variants
14328   #
14329   # Effectively the JDK variant gives a name to a specific set of
14330   # modules to compile into the JDK. In the future, these modules
14331   # might even be Jigsaw modules.
14332   #
14333   { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of the JDK to build" >&5
14334 $as_echo_n "checking which variant of the JDK to build... " >&6; }
14335 
14336 # Check whether --with-jdk-variant was given.
14337 if test "${with_jdk_variant+set}" = set; then :
14338   withval=$with_jdk_variant;
14339 fi
14340 
14341 
14342   if test "x$with_jdk_variant" = xnormal || test "x$with_jdk_variant" = x; then
14343     JDK_VARIANT="normal"
14344   else
14345     as_fn_error $? "The available JDK variants are: normal" "$LINENO" 5
14346   fi
14347 
14348 
14349 
14350   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_VARIANT" >&5
14351 $as_echo "$JDK_VARIANT" >&6; }
14352 
14353 
14354 ###############################################################################
14355 #
14356 # Check which interpreter of the JVM we want to build.
14357 # Currently we have:
14358 #    template: Template interpreter (the default)
14359 #    cpp     : C++ interpreter
14360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which interpreter of the JVM to build" >&5
14361 $as_echo_n "checking which interpreter of the JVM to build... " >&6; }
14362 
14363 # Check whether --with-jvm-interpreter was given.
14364 if test "${with_jvm_interpreter+set}" = set; then :
14365   withval=$with_jvm_interpreter;
14366 fi
14367 
14368 
14369 if test "x$with_jvm_interpreter" = x; then
14370      with_jvm_interpreter="template"
14371 fi
14372 
14373 JVM_INTERPRETER="$with_jvm_interpreter"
14374 
14375 if test "x$JVM_INTERPRETER" != xtemplate && test "x$JVM_INTERPRETER" != xcpp; then
14376    as_fn_error $? "The available JVM interpreters are: template, cpp" "$LINENO" 5
14377 fi
14378 
14379 
14380 
14381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_jvm_interpreter" >&5
14382 $as_echo "$with_jvm_interpreter" >&6; }
14383 
14384 
14385 
14386   ###############################################################################
14387   #
14388   # Check which variants of the JVM that we want to build.
14389   # Currently we have:
14390   #    server: normal interpreter and a tiered C1/C2 compiler
14391   #    client: normal interpreter and C1 (no C2 compiler) (only 32-bit platforms)
14392   #    minimal1: reduced form of client with optional VM services and features stripped out
14393   #    kernel: kernel footprint JVM that passes the TCK without major performance problems,
14394   #             ie normal interpreter and C1, only the serial GC, kernel jvmti etc
14395   #    zero: no machine code interpreter, no compiler
14396   #    zeroshark: zero interpreter and shark/llvm compiler backend
14397 #    core: interpreter only, no compiler (only works on some platforms)
14398   { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variants of the JVM to build" >&5
14399 $as_echo_n "checking which variants of the JVM to build... " >&6; }
14400 
14401 # Check whether --with-jvm-variants was given.
14402 if test "${with_jvm_variants+set}" = set; then :
14403   withval=$with_jvm_variants;
14404 fi
14405 
14406 
14407   if test "x$with_jvm_variants" = x; then
14408     with_jvm_variants="server"
14409   fi
14410 
14411   JVM_VARIANTS=",$with_jvm_variants,"
14412   TEST_VARIANTS=`$ECHO "$JVM_VARIANTS" | $SED -e 's/server,//' -e 's/client,//'  -e 's/minimal1,//' -e 's/kernel,//' -e 's/zero,//' -e 's/zeroshark,//' -e 's/core,//'`
14413 
14414   if test "x$TEST_VARIANTS" != "x,"; then
14415      as_fn_error $? "The available JVM variants are: server, client, minimal1, kernel, zero, zeroshark, core" "$LINENO" 5
14416   fi
14417   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_jvm_variants" >&5
14418 $as_echo "$with_jvm_variants" >&6; }
14419 
14420   JVM_VARIANT_SERVER=`$ECHO "$JVM_VARIANTS" | $SED -e '/,server,/!s/.*/false/g' -e '/,server,/s/.*/true/g'`
14421   JVM_VARIANT_CLIENT=`$ECHO "$JVM_VARIANTS" | $SED -e '/,client,/!s/.*/false/g' -e '/,client,/s/.*/true/g'`
14422   JVM_VARIANT_MINIMAL1=`$ECHO "$JVM_VARIANTS" | $SED -e '/,minimal1,/!s/.*/false/g' -e '/,minimal1,/s/.*/true/g'`
14423   JVM_VARIANT_KERNEL=`$ECHO "$JVM_VARIANTS" | $SED -e '/,kernel,/!s/.*/false/g' -e '/,kernel,/s/.*/true/g'`
14424   JVM_VARIANT_ZERO=`$ECHO "$JVM_VARIANTS" | $SED -e '/,zero,/!s/.*/false/g' -e '/,zero,/s/.*/true/g'`
14425   JVM_VARIANT_ZEROSHARK=`$ECHO "$JVM_VARIANTS" | $SED -e '/,zeroshark,/!s/.*/false/g' -e '/,zeroshark,/s/.*/true/g'`
14426   JVM_VARIANT_CORE=`$ECHO "$JVM_VARIANTS" | $SED -e '/,core,/!s/.*/false/g' -e '/,core,/s/.*/true/g'`
14427 
14428   if test "x$JVM_VARIANT_CLIENT" = xtrue; then
14429     if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
14430       as_fn_error $? "You cannot build a client JVM for a 64-bit machine." "$LINENO" 5
14431     fi
14432   fi
14433   if test "x$JVM_VARIANT_KERNEL" = xtrue; then
14434     if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
14435       as_fn_error $? "You cannot build a kernel JVM for a 64-bit machine." "$LINENO" 5
14436     fi
14437   fi
14438   if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
14439     if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
14440       as_fn_error $? "You cannot build a minimal JVM for a 64-bit machine." "$LINENO" 5
14441     fi
14442   fi
14443 
14444   # Replace the commas with AND for use in the build directory name.
14445   ANDED_JVM_VARIANTS=`$ECHO "$JVM_VARIANTS" | $SED -e 's/^,//' -e 's/,$//' -e 's/,/AND/g'`
14446   COUNT_VARIANTS=`$ECHO "$JVM_VARIANTS" | $SED -e 's/server,/1/' -e 's/client,/1/' -e 's/minimal1,/1/' -e 's/kernel,/1/' -e 's/zero,/1/' -e 's/zeroshark,/1/' -e 's/core,/1/'`
14447   if test "x$COUNT_VARIANTS" != "x,1"; then
14448     BUILDING_MULTIPLE_JVM_VARIANTS=yes
14449   else
14450     BUILDING_MULTIPLE_JVM_VARIANTS=no
14451   fi
14452 
14453 
14454 
14455 
14456 
14457 
14458 
14459 
14460 
14461 
14462   INCLUDE_SA=true
14463   if test "x$JVM_VARIANT_ZERO" = xtrue ; then
14464     INCLUDE_SA=false
14465   fi
14466   if test "x$JVM_VARIANT_ZEROSHARK" = xtrue ; then
14467     INCLUDE_SA=false
14468   fi
14469   if test "x$VAR_CPU" = xppc64 ; then
14470     INCLUDE_SA=false
14471   fi
14472 
14473 
14474   if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
14475     MACOSX_UNIVERSAL="true"
14476   fi
14477 
14478 
14479 
14480 
14481   ###############################################################################
14482   #
14483   # Set the debug level
14484   #    release: no debug information, all optimizations, no asserts.
14485   #    fastdebug: debug information (-g), all optimizations, all asserts
14486   #    slowdebug: debug information (-g), no optimizations, all asserts
14487   #
14488   DEBUG_LEVEL="release"
14489   { $as_echo "$as_me:${as_lineno-$LINENO}: checking which debug level to use" >&5
14490 $as_echo_n "checking which debug level to use... " >&6; }
14491   # Check whether --enable-debug was given.
14492 if test "${enable_debug+set}" = set; then :
14493   enableval=$enable_debug;
14494         ENABLE_DEBUG="${enableval}"
14495         DEBUG_LEVEL="fastdebug"
14496 
14497 else
14498   ENABLE_DEBUG="no"
14499 fi
14500 
14501 
14502 
14503 # Check whether --with-debug-level was given.
14504 if test "${with_debug_level+set}" = set; then :
14505   withval=$with_debug_level;
14506         DEBUG_LEVEL="${withval}"
14507         if test "x$ENABLE_DEBUG" = xyes; then
14508           as_fn_error $? "You cannot use both --enable-debug and --with-debug-level at the same time." "$LINENO" 5
14509         fi
14510 
14511 fi
14512 
14513   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEBUG_LEVEL" >&5
14514 $as_echo "$DEBUG_LEVEL" >&6; }
14515 
14516   if test "x$DEBUG_LEVEL" != xrelease && \
14517       test "x$DEBUG_LEVEL" != xfastdebug && \
14518       test "x$DEBUG_LEVEL" != xslowdebug; then
14519     as_fn_error $? "Allowed debug levels are: release, fastdebug and slowdebug" "$LINENO" 5
14520   fi
14521 
14522 
14523   ###############################################################################
14524   #
14525   # Setup legacy vars/targets and new vars to deal with different debug levels.
14526   #
14527 
14528   case $DEBUG_LEVEL in
14529     release )
14530       VARIANT="OPT"
14531       FASTDEBUG="false"
14532       DEBUG_CLASSFILES="false"
14533       BUILD_VARIANT_RELEASE=""
14534       HOTSPOT_DEBUG_LEVEL="product"
14535       HOTSPOT_EXPORT="product"
14536       ;;
14537     fastdebug )
14538       VARIANT="DBG"
14539       FASTDEBUG="true"
14540       DEBUG_CLASSFILES="true"
14541       BUILD_VARIANT_RELEASE="-fastdebug"
14542       HOTSPOT_DEBUG_LEVEL="fastdebug"
14543       HOTSPOT_EXPORT="fastdebug"
14544       ;;
14545     slowdebug )
14546       VARIANT="DBG"
14547       FASTDEBUG="false"
14548       DEBUG_CLASSFILES="true"
14549       BUILD_VARIANT_RELEASE="-debug"
14550       HOTSPOT_DEBUG_LEVEL="jvmg"
14551       HOTSPOT_EXPORT="debug"
14552       ;;
14553   esac
14554 
14555   #####
14556   # Generate the legacy makefile targets for hotspot.
14557   # The hotspot api for selecting the build artifacts, really, needs to be improved.
14558   # JDK-7195896 will fix this on the hotspot side by using the JVM_VARIANT_* variables to
14559   # determine what needs to be built. All we will need to set here is all_product, all_fastdebug etc
14560   # But until then ...
14561   HOTSPOT_TARGET=""
14562 
14563   if test "x$JVM_VARIANT_SERVER" = xtrue; then
14564     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL} "
14565   fi
14566 
14567   if test "x$JVM_VARIANT_CLIENT" = xtrue; then
14568     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}1 "
14569   fi
14570 
14571   if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
14572     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}minimal1 "
14573   fi
14574 
14575   if test "x$JVM_VARIANT_KERNEL" = xtrue; then
14576     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}kernel "
14577   fi
14578 
14579   if test "x$JVM_VARIANT_ZERO" = xtrue; then
14580     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}zero "
14581   fi
14582 
14583   if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
14584     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}shark "
14585   fi
14586 
14587   if test "x$JVM_VARIANT_CORE" = xtrue; then
14588     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}core "
14589   fi
14590 
14591   HOTSPOT_TARGET="$HOTSPOT_TARGET docs export_$HOTSPOT_EXPORT"
14592 
14593   # On Macosx universal binaries are produced, but they only contain
14594   # 64 bit intel. This invalidates control of which jvms are built
14595   # from configure, but only server is valid anyway. Fix this
14596   # when hotspot makefiles are rewritten.
14597   if test "x$MACOSX_UNIVERSAL" = xtrue; then
14598     HOTSPOT_TARGET=universal_${HOTSPOT_EXPORT}
14599   fi
14600 
14601   #####
14602 
14603 
14604 
14605 
14606 
14607 
14608 
14609 
14610 # With basic setup done, call the custom early hook.
14611 
14612 
14613 # To properly create a configuration name, we need to have the OpenJDK target
14614 # and options (variants and debug level) parsed.
14615 
14616 
14617 
14618 # Check whether --with-conf-name was given.
14619 if test "${with_conf_name+set}" = set; then :
14620   withval=$with_conf_name;  CONF_NAME=${with_conf_name}
14621 fi
14622 
14623 
14624   # Test from where we are running configure, in or outside of src root.
14625   { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to store configuration" >&5
14626 $as_echo_n "checking where to store configuration... " >&6; }
14627   if test "x$CURDIR" = "x$SRC_ROOT" || test "x$CURDIR" = "x$SRC_ROOT/common" \
14628       || test "x$CURDIR" = "x$SRC_ROOT/common/autoconf" \
14629       || test "x$CURDIR" = "x$SRC_ROOT/make" ; then
14630     # We are running configure from the src root.
14631     # Create a default ./build/target-variant-debuglevel output root.
14632     if test "x${CONF_NAME}" = x; then
14633       { $as_echo "$as_me:${as_lineno-$LINENO}: result: in default location" >&5
14634 $as_echo "in default location" >&6; }
14635       CONF_NAME="${OPENJDK_TARGET_OS}-${OPENJDK_TARGET_CPU}-${JDK_VARIANT}-${ANDED_JVM_VARIANTS}-${DEBUG_LEVEL}"
14636     else
14637       { $as_echo "$as_me:${as_lineno-$LINENO}: result: in build directory with custom name" >&5
14638 $as_echo "in build directory with custom name" >&6; }
14639     fi
14640     OUTPUT_ROOT="$SRC_ROOT/build/${CONF_NAME}"
14641     $MKDIR -p "$OUTPUT_ROOT"
14642     if test ! -d "$OUTPUT_ROOT"; then
14643       as_fn_error $? "Could not create build directory $OUTPUT_ROOT" "$LINENO" 5
14644     fi
14645   else
14646     # We are running configure from outside of the src dir.
14647     # Then use the current directory as output dir!
14648     # If configuration is situated in normal build directory, just use the build
14649     # directory name as configuration name, otherwise use the complete path.
14650     if test "x${CONF_NAME}" = x; then
14651       CONF_NAME=`$ECHO $CURDIR | $SED -e "s!^${SRC_ROOT}/build/!!"`
14652     fi
14653     OUTPUT_ROOT="$CURDIR"
14654     { $as_echo "$as_me:${as_lineno-$LINENO}: result: in current directory" >&5
14655 $as_echo "in current directory" >&6; }
14656 
14657     # WARNING: This might be a bad thing to do. You need to be sure you want to
14658     # have a configuration in this directory. Do some sanity checks!
14659 
14660     if test ! -e "$OUTPUT_ROOT/spec.gmk"; then
14661       # If we have a spec.gmk, we have run here before and we are OK. Otherwise, check for
14662       # other files
14663       files_present=`$LS $OUTPUT_ROOT`
14664       # Configure has already touched config.log and confdefs.h in the current dir when this check
14665       # is performed.
14666       filtered_files=`$ECHO "$files_present" | $SED -e 's/config.log//g' -e 's/confdefs.h//g' -e 's/ //g' \
14667       | $TR -d '\n'`
14668       if test "x$filtered_files" != x; then
14669         { $as_echo "$as_me:${as_lineno-$LINENO}: Current directory is $CURDIR." >&5
14670 $as_echo "$as_me: Current directory is $CURDIR." >&6;}
14671         { $as_echo "$as_me:${as_lineno-$LINENO}: Since this is not the source root, configure will output the configuration here" >&5
14672 $as_echo "$as_me: Since this is not the source root, configure will output the configuration here" >&6;}
14673         { $as_echo "$as_me:${as_lineno-$LINENO}: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&5
14674 $as_echo "$as_me: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&6;}
14675         { $as_echo "$as_me:${as_lineno-$LINENO}: However, this directory is not empty. This is not allowed, since it could" >&5
14676 $as_echo "$as_me: However, this directory is not empty. This is not allowed, since it could" >&6;}
14677         { $as_echo "$as_me:${as_lineno-$LINENO}: seriously mess up just about everything." >&5
14678 $as_echo "$as_me: seriously mess up just about everything." >&6;}
14679         { $as_echo "$as_me:${as_lineno-$LINENO}: Try 'cd $SRC_ROOT' and restart configure" >&5
14680 $as_echo "$as_me: Try 'cd $SRC_ROOT' and restart configure" >&6;}
14681         { $as_echo "$as_me:${as_lineno-$LINENO}: (or create a new empty directory and cd to it)." >&5
14682 $as_echo "$as_me: (or create a new empty directory and cd to it)." >&6;}
14683         as_fn_error $? "Will not continue creating configuration in $CURDIR" "$LINENO" 5
14684       fi
14685     fi
14686   fi
14687   { $as_echo "$as_me:${as_lineno-$LINENO}: checking what configuration name to use" >&5
14688 $as_echo_n "checking what configuration name to use... " >&6; }
14689   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONF_NAME" >&5
14690 $as_echo "$CONF_NAME" >&6; }
14691 
14692 
14693   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14694 
14695   # Input might be given as Windows format, start by converting to
14696   # unix format.
14697   path="$OUTPUT_ROOT"
14698   new_path=`$CYGPATH -u "$path"`
14699 
14700   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14701   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14702   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14703   # "foo.exe" is OK but "foo" is an error.
14704   #
14705   # This test is therefore slightly more accurate than "test -f" to check for file precense.
14706   # It is also a way to make sure we got the proper file name for the real test later on.
14707   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14708   if test "x$test_shortpath" = x; then
14709     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5
14710 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;}
14711     as_fn_error $? "Cannot locate the the path of OUTPUT_ROOT" "$LINENO" 5
14712   fi
14713 
14714   # Call helper function which possibly converts this using DOS-style short mode.
14715   # If so, the updated path is stored in $new_path.
14716 
14717   input_path="$new_path"
14718   # Check if we need to convert this using DOS-style short mode. If the path
14719   # contains just simple characters, use it. Otherwise (spaces, weird characters),
14720   # take no chances and rewrite it.
14721   # Note: m4 eats our [], so we need to use [ and ] instead.
14722   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
14723   if test "x$has_forbidden_chars" != x; then
14724     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14725     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
14726     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
14727     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
14728       # Going to short mode and back again did indeed matter. Since short mode is
14729       # case insensitive, let's make it lowercase to improve readability.
14730       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14731       # Now convert it back to Unix-stile (cygpath)
14732       input_path=`$CYGPATH -u "$shortmode_path"`
14733       new_path="$input_path"
14734     fi
14735   fi
14736 
14737   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
14738   if test "x$test_cygdrive_prefix" = x; then
14739     # As a simple fix, exclude /usr/bin since it's not a real path.
14740     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
14741       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
14742       # a path prefixed by /cygdrive for fixpath to work.
14743       new_path="$CYGWIN_ROOT_PATH$input_path"
14744     fi
14745   fi
14746 
14747 
14748   if test "x$path" != "x$new_path"; then
14749     OUTPUT_ROOT="$new_path"
14750     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5
14751 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;}
14752   fi
14753 
14754   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14755 
14756   path="$OUTPUT_ROOT"
14757   has_colon=`$ECHO $path | $GREP ^.:`
14758   new_path="$path"
14759   if test "x$has_colon" = x; then
14760     # Not in mixed or Windows style, start by that.
14761     new_path=`cmd //c echo $path`
14762   fi
14763 
14764 
14765   input_path="$new_path"
14766   # Check if we need to convert this using DOS-style short mode. If the path
14767   # contains just simple characters, use it. Otherwise (spaces, weird characters),
14768   # take no chances and rewrite it.
14769   # Note: m4 eats our [], so we need to use [ and ] instead.
14770   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
14771   if test "x$has_forbidden_chars" != x; then
14772     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14773     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14774   fi
14775 
14776 
14777   windows_path="$new_path"
14778   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14779     unix_path=`$CYGPATH -u "$windows_path"`
14780     new_path="$unix_path"
14781   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14782     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14783     new_path="$unix_path"
14784   fi
14785 
14786   if test "x$path" != "x$new_path"; then
14787     OUTPUT_ROOT="$new_path"
14788     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5
14789 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;}
14790   fi
14791 
14792   # Save the first 10 bytes of this path to the storage, so fixpath can work.
14793   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
14794 
14795   else
14796     # We're on a posix platform. Hooray! :)
14797     path="$OUTPUT_ROOT"
14798     has_space=`$ECHO "$path" | $GREP " "`
14799     if test "x$has_space" != x; then
14800       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5
14801 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;}
14802       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14803     fi
14804 
14805     # Use eval to expand a potential ~
14806     eval path="$path"
14807     if test ! -f "$path" && test ! -d "$path"; then
14808       as_fn_error $? "The path of OUTPUT_ROOT, which resolves as \"$path\", is not found." "$LINENO" 5
14809     fi
14810 
14811     OUTPUT_ROOT="`cd "$path"; $THEPWDCMD -L`"
14812   fi
14813 
14814 
14815   SPEC=$OUTPUT_ROOT/spec.gmk
14816 
14817   CONF_NAME=$CONF_NAME
14818 
14819   OUTPUT_ROOT=$OUTPUT_ROOT
14820 
14821 
14822   # Most of the probed defines are put into config.h
14823   ac_config_headers="$ac_config_headers $OUTPUT_ROOT/config.h:$AUTOCONF_DIR/config.h.in"
14824 
14825   # The spec.gmk file contains all variables for the make system.
14826   ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in"
14827 
14828   # The hotspot-spec.gmk file contains legacy variables for the hotspot make system.
14829   ac_config_files="$ac_config_files $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in"
14830 
14831   # The bootcycle-spec.gmk file contains support for boot cycle builds.
14832   ac_config_files="$ac_config_files $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in"
14833 
14834   # The compare.sh is used to compare the build output to other builds.
14835   ac_config_files="$ac_config_files $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in"
14836 
14837   # Spec.sh is currently used by compare-objects.sh
14838   ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.sh:$AUTOCONF_DIR/spec.sh.in"
14839 
14840   # The generated Makefile knows where the spec.gmk is and where the source is.
14841   # You can run make from the OUTPUT_ROOT, or from the top-level Makefile
14842   # which will look for generated configurations
14843   ac_config_files="$ac_config_files $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in"
14844 
14845 
14846 
14847 # Must be done before we can call HELP_MSG_MISSING_DEPENDENCY.
14848 
14849   for ac_prog in apt-get yum port pkgutil pkgadd
14850 do
14851   # Extract the first word of "$ac_prog", so it can be a program name with args.
14852 set dummy $ac_prog; ac_word=$2
14853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14854 $as_echo_n "checking for $ac_word... " >&6; }
14855 if ${ac_cv_prog_PKGHANDLER+:} false; then :
14856   $as_echo_n "(cached) " >&6
14857 else
14858   if test -n "$PKGHANDLER"; then
14859   ac_cv_prog_PKGHANDLER="$PKGHANDLER" # Let the user override the test.
14860 else
14861 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14862 for as_dir in $PATH
14863 do
14864   IFS=$as_save_IFS
14865   test -z "$as_dir" && as_dir=.
14866     for ac_exec_ext in '' $ac_executable_extensions; do
14867   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14868     ac_cv_prog_PKGHANDLER="$ac_prog"
14869     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14870     break 2
14871   fi
14872 done
14873   done
14874 IFS=$as_save_IFS
14875 
14876 fi
14877 fi
14878 PKGHANDLER=$ac_cv_prog_PKGHANDLER
14879 if test -n "$PKGHANDLER"; then
14880   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGHANDLER" >&5
14881 $as_echo "$PKGHANDLER" >&6; }
14882 else
14883   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14884 $as_echo "no" >&6; }
14885 fi
14886 
14887 
14888   test -n "$PKGHANDLER" && break
14889 done
14890 
14891 
14892 
14893 # Setup tools that requires more complex handling, or that is not needed by the configure script.
14894 
14895 
14896   # We need to find a recent version of GNU make. Especially on Solaris, this can be tricky.
14897   if test "x$MAKE" != x; then
14898     # User has supplied a make, test it.
14899     if test ! -f "$MAKE"; then
14900       as_fn_error $? "The specified make (by MAKE=$MAKE) is not found." "$LINENO" 5
14901     fi
14902 
14903   MAKE_CANDIDATE=""$MAKE""
14904   DESCRIPTION="user supplied MAKE=$MAKE"
14905   if test "x$MAKE_CANDIDATE" != x; then
14906     { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
14907 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
14908     MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
14909     IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
14910     if test "x$IS_GNU_MAKE" = x; then
14911       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
14912 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
14913     else
14914       IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
14915       if test "x$IS_MODERN_MAKE" = x; then
14916         { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5
14917 $as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;}
14918       else
14919         if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
14920           if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14921             MAKE_EXPECTED_ENV='cygwin'
14922           elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14923             MAKE_EXPECTED_ENV='msys'
14924           else
14925             as_fn_error $? "Unknown Windows environment" "$LINENO" 5
14926           fi
14927           MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
14928           IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
14929         else
14930           # Not relevant for non-Windows
14931           IS_MAKE_CORRECT_ENV=true
14932         fi
14933         if test "x$IS_MAKE_CORRECT_ENV" = x; then
14934           { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&5
14935 $as_echo "$as_me: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&6;}
14936         else
14937           FOUND_MAKE=$MAKE_CANDIDATE
14938 
14939   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14940 
14941   # First separate the path from the arguments. This will split at the first
14942   # space.
14943   complete="$FOUND_MAKE"
14944   path="${complete%% *}"
14945   tmp="$complete EOL"
14946   arguments="${tmp#* }"
14947 
14948   # Input might be given as Windows format, start by converting to
14949   # unix format.
14950   new_path=`$CYGPATH -u "$path"`
14951 
14952   # Now try to locate executable using which
14953   new_path=`$WHICH "$new_path" 2> /dev/null`
14954   # bat and cmd files are not always considered executable in cygwin causing which
14955   # to not find them
14956   if test "x$new_path" = x \
14957       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
14958       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
14959     new_path=`$CYGPATH -u "$path"`
14960   fi
14961   if test "x$new_path" = x; then
14962     # Oops. Which didn't find the executable.
14963     # The splitting of arguments from the executable at a space might have been incorrect,
14964     # since paths with space are more likely in Windows. Give it another try with the whole
14965     # argument.
14966     path="$complete"
14967     arguments="EOL"
14968     new_path=`$CYGPATH -u "$path"`
14969     new_path=`$WHICH "$new_path" 2> /dev/null`
14970     # bat and cmd files are not always considered executable in cygwin causing which
14971     # to not find them
14972     if test "x$new_path" = x \
14973         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
14974         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
14975       new_path=`$CYGPATH -u "$path"`
14976     fi
14977     if test "x$new_path" = x; then
14978       # It's still not found. Now this is an unrecoverable error.
14979       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
14980 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
14981       has_space=`$ECHO "$complete" | $GREP " "`
14982       if test "x$has_space" != x; then
14983         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
14984 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
14985       fi
14986       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
14987     fi
14988   fi
14989 
14990   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14991   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14992   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14993   # "foo.exe" is OK but "foo" is an error.
14994   #
14995   # This test is therefore slightly more accurate than "test -f" to check for file presence.
14996   # It is also a way to make sure we got the proper file name for the real test later on.
14997   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14998   if test "x$test_shortpath" = x; then
14999     # Short path failed, file does not exist as specified.
15000     # Try adding .exe or .cmd
15001     if test -f "${new_path}.exe"; then
15002       input_to_shortpath="${new_path}.exe"
15003     elif test -f "${new_path}.cmd"; then
15004       input_to_shortpath="${new_path}.cmd"
15005     else
15006       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
15007 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
15008       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
15009 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
15010       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15011     fi
15012   else
15013     input_to_shortpath="$new_path"
15014   fi
15015 
15016   # Call helper function which possibly converts this using DOS-style short mode.
15017   # If so, the updated path is stored in $new_path.
15018   new_path="$input_to_shortpath"
15019 
15020   input_path="$input_to_shortpath"
15021   # Check if we need to convert this using DOS-style short mode. If the path
15022   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15023   # take no chances and rewrite it.
15024   # Note: m4 eats our [], so we need to use [ and ] instead.
15025   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
15026   if test "x$has_forbidden_chars" != x; then
15027     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15028     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
15029     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
15030     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
15031       # Going to short mode and back again did indeed matter. Since short mode is
15032       # case insensitive, let's make it lowercase to improve readability.
15033       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15034       # Now convert it back to Unix-stile (cygpath)
15035       input_path=`$CYGPATH -u "$shortmode_path"`
15036       new_path="$input_path"
15037     fi
15038   fi
15039 
15040   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
15041   if test "x$test_cygdrive_prefix" = x; then
15042     # As a simple fix, exclude /usr/bin since it's not a real path.
15043     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
15044       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
15045       # a path prefixed by /cygdrive for fixpath to work.
15046       new_path="$CYGWIN_ROOT_PATH$input_path"
15047     fi
15048   fi
15049 
15050   # remove trailing .exe if any
15051   new_path="${new_path/%.exe/}"
15052 
15053   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15054 
15055   # First separate the path from the arguments. This will split at the first
15056   # space.
15057   complete="$FOUND_MAKE"
15058   path="${complete%% *}"
15059   tmp="$complete EOL"
15060   arguments="${tmp#* }"
15061 
15062   # Input might be given as Windows format, start by converting to
15063   # unix format.
15064   new_path="$path"
15065 
15066   windows_path="$new_path"
15067   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15068     unix_path=`$CYGPATH -u "$windows_path"`
15069     new_path="$unix_path"
15070   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15071     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15072     new_path="$unix_path"
15073   fi
15074 
15075 
15076   # Now try to locate executable using which
15077   new_path=`$WHICH "$new_path" 2> /dev/null`
15078 
15079   if test "x$new_path" = x; then
15080     # Oops. Which didn't find the executable.
15081     # The splitting of arguments from the executable at a space might have been incorrect,
15082     # since paths with space are more likely in Windows. Give it another try with the whole
15083     # argument.
15084     path="$complete"
15085     arguments="EOL"
15086     new_path="$path"
15087 
15088   windows_path="$new_path"
15089   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15090     unix_path=`$CYGPATH -u "$windows_path"`
15091     new_path="$unix_path"
15092   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15093     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15094     new_path="$unix_path"
15095   fi
15096 
15097 
15098     new_path=`$WHICH "$new_path" 2> /dev/null`
15099 
15100     if test "x$new_path" = x; then
15101       # It's still not found. Now this is an unrecoverable error.
15102       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15103 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15104       has_space=`$ECHO "$complete" | $GREP " "`
15105       if test "x$has_space" != x; then
15106         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15107 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15108       fi
15109       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15110     fi
15111   fi
15112 
15113   # Now new_path has a complete unix path to the binary
15114   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
15115     # Keep paths in /bin as-is, but remove trailing .exe if any
15116     new_path="${new_path/%.exe/}"
15117     # Do not save /bin paths to all_fixpath_prefixes!
15118   else
15119     # Not in mixed or Windows style, start by that.
15120     new_path=`cmd //c echo $new_path`
15121 
15122   input_path="$new_path"
15123   # Check if we need to convert this using DOS-style short mode. If the path
15124   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15125   # take no chances and rewrite it.
15126   # Note: m4 eats our [], so we need to use [ and ] instead.
15127   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
15128   if test "x$has_forbidden_chars" != x; then
15129     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15130     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15131   fi
15132 
15133     # Output is in $new_path
15134 
15135   windows_path="$new_path"
15136   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15137     unix_path=`$CYGPATH -u "$windows_path"`
15138     new_path="$unix_path"
15139   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15140     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15141     new_path="$unix_path"
15142   fi
15143 
15144     # remove trailing .exe if any
15145     new_path="${new_path/%.exe/}"
15146 
15147     # Save the first 10 bytes of this path to the storage, so fixpath can work.
15148     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
15149   fi
15150 
15151   else
15152     # We're on a posix platform. Hooray! :)
15153     # First separate the path from the arguments. This will split at the first
15154     # space.
15155     complete="$FOUND_MAKE"
15156     path="${complete%% *}"
15157     tmp="$complete EOL"
15158     arguments="${tmp#* }"
15159 
15160     # Cannot rely on the command "which" here since it doesn't always work.
15161     is_absolute_path=`$ECHO "$path" | $GREP ^/`
15162     if test -z "$is_absolute_path"; then
15163       # Path to executable is not absolute. Find it.
15164       IFS_save="$IFS"
15165       IFS=:
15166       for p in $PATH; do
15167         if test -f "$p/$path" && test -x "$p/$path"; then
15168           new_path="$p/$path"
15169           break
15170         fi
15171       done
15172       IFS="$IFS_save"
15173     else
15174       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&5
15175 $as_echo "$as_me: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&6;}
15176       new_path="$path"
15177     fi
15178 
15179     if test "x$new_path" = x; then
15180       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15181 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15182       has_space=`$ECHO "$complete" | $GREP " "`
15183       if test "x$has_space" != x; then
15184         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
15185 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
15186       fi
15187       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15188     fi
15189   fi
15190 
15191   # Now join together the path and the arguments once again
15192   if test "x$arguments" != xEOL; then
15193     new_complete="$new_path ${arguments% *}"
15194   else
15195     new_complete="$new_path"
15196   fi
15197 
15198   if test "x$complete" != "x$new_complete"; then
15199     FOUND_MAKE="$new_complete"
15200     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
15201 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
15202   fi
15203 
15204         fi
15205       fi
15206     fi
15207   fi
15208 
15209     if test "x$FOUND_MAKE" = x; then
15210       as_fn_error $? "The specified make (by MAKE=$MAKE) is not GNU make 3.81 or newer." "$LINENO" 5
15211     fi
15212   else
15213     # Try our hardest to locate a correct version of GNU make
15214     for ac_prog in gmake
15215 do
15216   # Extract the first word of "$ac_prog", so it can be a program name with args.
15217 set dummy $ac_prog; ac_word=$2
15218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15219 $as_echo_n "checking for $ac_word... " >&6; }
15220 if ${ac_cv_path_CHECK_GMAKE+:} false; then :
15221   $as_echo_n "(cached) " >&6
15222 else
15223   case $CHECK_GMAKE in
15224   [\\/]* | ?:[\\/]*)
15225   ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path.
15226   ;;
15227   *)
15228   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15229 for as_dir in $PATH
15230 do
15231   IFS=$as_save_IFS
15232   test -z "$as_dir" && as_dir=.
15233     for ac_exec_ext in '' $ac_executable_extensions; do
15234   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15235     ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext"
15236     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15237     break 2
15238   fi
15239 done
15240   done
15241 IFS=$as_save_IFS
15242 
15243   ;;
15244 esac
15245 fi
15246 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE
15247 if test -n "$CHECK_GMAKE"; then
15248   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5
15249 $as_echo "$CHECK_GMAKE" >&6; }
15250 else
15251   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15252 $as_echo "no" >&6; }
15253 fi
15254 
15255 
15256   test -n "$CHECK_GMAKE" && break
15257 done
15258 
15259 
15260   MAKE_CANDIDATE=""$CHECK_GMAKE""
15261   DESCRIPTION="gmake in PATH"
15262   if test "x$MAKE_CANDIDATE" != x; then
15263     { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
15264 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
15265     MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
15266     IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
15267     if test "x$IS_GNU_MAKE" = x; then
15268       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
15269 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
15270     else
15271       IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
15272       if test "x$IS_MODERN_MAKE" = x; then
15273         { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5
15274 $as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;}
15275       else
15276         if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
15277           if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15278             MAKE_EXPECTED_ENV='cygwin'
15279           elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15280             MAKE_EXPECTED_ENV='msys'
15281           else
15282             as_fn_error $? "Unknown Windows environment" "$LINENO" 5
15283           fi
15284           MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
15285           IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
15286         else
15287           # Not relevant for non-Windows
15288           IS_MAKE_CORRECT_ENV=true
15289         fi
15290         if test "x$IS_MAKE_CORRECT_ENV" = x; then
15291           { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&5
15292 $as_echo "$as_me: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&6;}
15293         else
15294           FOUND_MAKE=$MAKE_CANDIDATE
15295 
15296   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15297 
15298   # First separate the path from the arguments. This will split at the first
15299   # space.
15300   complete="$FOUND_MAKE"
15301   path="${complete%% *}"
15302   tmp="$complete EOL"
15303   arguments="${tmp#* }"
15304 
15305   # Input might be given as Windows format, start by converting to
15306   # unix format.
15307   new_path=`$CYGPATH -u "$path"`
15308 
15309   # Now try to locate executable using which
15310   new_path=`$WHICH "$new_path" 2> /dev/null`
15311   # bat and cmd files are not always considered executable in cygwin causing which
15312   # to not find them
15313   if test "x$new_path" = x \
15314       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15315       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15316     new_path=`$CYGPATH -u "$path"`
15317   fi
15318   if test "x$new_path" = x; then
15319     # Oops. Which didn't find the executable.
15320     # The splitting of arguments from the executable at a space might have been incorrect,
15321     # since paths with space are more likely in Windows. Give it another try with the whole
15322     # argument.
15323     path="$complete"
15324     arguments="EOL"
15325     new_path=`$CYGPATH -u "$path"`
15326     new_path=`$WHICH "$new_path" 2> /dev/null`
15327     # bat and cmd files are not always considered executable in cygwin causing which
15328     # to not find them
15329     if test "x$new_path" = x \
15330         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15331         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15332       new_path=`$CYGPATH -u "$path"`
15333     fi
15334     if test "x$new_path" = x; then
15335       # It's still not found. Now this is an unrecoverable error.
15336       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15337 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15338       has_space=`$ECHO "$complete" | $GREP " "`
15339       if test "x$has_space" != x; then
15340         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15341 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15342       fi
15343       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15344     fi
15345   fi
15346 
15347   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
15348   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
15349   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
15350   # "foo.exe" is OK but "foo" is an error.
15351   #
15352   # This test is therefore slightly more accurate than "test -f" to check for file presence.
15353   # It is also a way to make sure we got the proper file name for the real test later on.
15354   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
15355   if test "x$test_shortpath" = x; then
15356     # Short path failed, file does not exist as specified.
15357     # Try adding .exe or .cmd
15358     if test -f "${new_path}.exe"; then
15359       input_to_shortpath="${new_path}.exe"
15360     elif test -f "${new_path}.cmd"; then
15361       input_to_shortpath="${new_path}.cmd"
15362     else
15363       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
15364 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
15365       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
15366 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
15367       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15368     fi
15369   else
15370     input_to_shortpath="$new_path"
15371   fi
15372 
15373   # Call helper function which possibly converts this using DOS-style short mode.
15374   # If so, the updated path is stored in $new_path.
15375   new_path="$input_to_shortpath"
15376 
15377   input_path="$input_to_shortpath"
15378   # Check if we need to convert this using DOS-style short mode. If the path
15379   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15380   # take no chances and rewrite it.
15381   # Note: m4 eats our [], so we need to use [ and ] instead.
15382   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
15383   if test "x$has_forbidden_chars" != x; then
15384     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15385     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
15386     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
15387     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
15388       # Going to short mode and back again did indeed matter. Since short mode is
15389       # case insensitive, let's make it lowercase to improve readability.
15390       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15391       # Now convert it back to Unix-stile (cygpath)
15392       input_path=`$CYGPATH -u "$shortmode_path"`
15393       new_path="$input_path"
15394     fi
15395   fi
15396 
15397   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
15398   if test "x$test_cygdrive_prefix" = x; then
15399     # As a simple fix, exclude /usr/bin since it's not a real path.
15400     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
15401       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
15402       # a path prefixed by /cygdrive for fixpath to work.
15403       new_path="$CYGWIN_ROOT_PATH$input_path"
15404     fi
15405   fi
15406 
15407   # remove trailing .exe if any
15408   new_path="${new_path/%.exe/}"
15409 
15410   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15411 
15412   # First separate the path from the arguments. This will split at the first
15413   # space.
15414   complete="$FOUND_MAKE"
15415   path="${complete%% *}"
15416   tmp="$complete EOL"
15417   arguments="${tmp#* }"
15418 
15419   # Input might be given as Windows format, start by converting to
15420   # unix format.
15421   new_path="$path"
15422 
15423   windows_path="$new_path"
15424   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15425     unix_path=`$CYGPATH -u "$windows_path"`
15426     new_path="$unix_path"
15427   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15428     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15429     new_path="$unix_path"
15430   fi
15431 
15432 
15433   # Now try to locate executable using which
15434   new_path=`$WHICH "$new_path" 2> /dev/null`
15435 
15436   if test "x$new_path" = x; then
15437     # Oops. Which didn't find the executable.
15438     # The splitting of arguments from the executable at a space might have been incorrect,
15439     # since paths with space are more likely in Windows. Give it another try with the whole
15440     # argument.
15441     path="$complete"
15442     arguments="EOL"
15443     new_path="$path"
15444 
15445   windows_path="$new_path"
15446   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15447     unix_path=`$CYGPATH -u "$windows_path"`
15448     new_path="$unix_path"
15449   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15450     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15451     new_path="$unix_path"
15452   fi
15453 
15454 
15455     new_path=`$WHICH "$new_path" 2> /dev/null`
15456 
15457     if test "x$new_path" = x; then
15458       # It's still not found. Now this is an unrecoverable error.
15459       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15460 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15461       has_space=`$ECHO "$complete" | $GREP " "`
15462       if test "x$has_space" != x; then
15463         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15464 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15465       fi
15466       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15467     fi
15468   fi
15469 
15470   # Now new_path has a complete unix path to the binary
15471   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
15472     # Keep paths in /bin as-is, but remove trailing .exe if any
15473     new_path="${new_path/%.exe/}"
15474     # Do not save /bin paths to all_fixpath_prefixes!
15475   else
15476     # Not in mixed or Windows style, start by that.
15477     new_path=`cmd //c echo $new_path`
15478 
15479   input_path="$new_path"
15480   # Check if we need to convert this using DOS-style short mode. If the path
15481   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15482   # take no chances and rewrite it.
15483   # Note: m4 eats our [], so we need to use [ and ] instead.
15484   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
15485   if test "x$has_forbidden_chars" != x; then
15486     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15487     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15488   fi
15489 
15490     # Output is in $new_path
15491 
15492   windows_path="$new_path"
15493   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15494     unix_path=`$CYGPATH -u "$windows_path"`
15495     new_path="$unix_path"
15496   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15497     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15498     new_path="$unix_path"
15499   fi
15500 
15501     # remove trailing .exe if any
15502     new_path="${new_path/%.exe/}"
15503 
15504     # Save the first 10 bytes of this path to the storage, so fixpath can work.
15505     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
15506   fi
15507 
15508   else
15509     # We're on a posix platform. Hooray! :)
15510     # First separate the path from the arguments. This will split at the first
15511     # space.
15512     complete="$FOUND_MAKE"
15513     path="${complete%% *}"
15514     tmp="$complete EOL"
15515     arguments="${tmp#* }"
15516 
15517     # Cannot rely on the command "which" here since it doesn't always work.
15518     is_absolute_path=`$ECHO "$path" | $GREP ^/`
15519     if test -z "$is_absolute_path"; then
15520       # Path to executable is not absolute. Find it.
15521       IFS_save="$IFS"
15522       IFS=:
15523       for p in $PATH; do
15524         if test -f "$p/$path" && test -x "$p/$path"; then
15525           new_path="$p/$path"
15526           break
15527         fi
15528       done
15529       IFS="$IFS_save"
15530     else
15531       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&5
15532 $as_echo "$as_me: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&6;}
15533       new_path="$path"
15534     fi
15535 
15536     if test "x$new_path" = x; then
15537       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15538 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15539       has_space=`$ECHO "$complete" | $GREP " "`
15540       if test "x$has_space" != x; then
15541         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
15542 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
15543       fi
15544       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15545     fi
15546   fi
15547 
15548   # Now join together the path and the arguments once again
15549   if test "x$arguments" != xEOL; then
15550     new_complete="$new_path ${arguments% *}"
15551   else
15552     new_complete="$new_path"
15553   fi
15554 
15555   if test "x$complete" != "x$new_complete"; then
15556     FOUND_MAKE="$new_complete"
15557     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
15558 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
15559   fi
15560 
15561         fi
15562       fi
15563     fi
15564   fi
15565 
15566 
15567     if test "x$FOUND_MAKE" = x; then
15568       for ac_prog in make
15569 do
15570   # Extract the first word of "$ac_prog", so it can be a program name with args.
15571 set dummy $ac_prog; ac_word=$2
15572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15573 $as_echo_n "checking for $ac_word... " >&6; }
15574 if ${ac_cv_path_CHECK_MAKE+:} false; then :
15575   $as_echo_n "(cached) " >&6
15576 else
15577   case $CHECK_MAKE in
15578   [\\/]* | ?:[\\/]*)
15579   ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path.
15580   ;;
15581   *)
15582   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15583 for as_dir in $PATH
15584 do
15585   IFS=$as_save_IFS
15586   test -z "$as_dir" && as_dir=.
15587     for ac_exec_ext in '' $ac_executable_extensions; do
15588   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15589     ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext"
15590     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15591     break 2
15592   fi
15593 done
15594   done
15595 IFS=$as_save_IFS
15596 
15597   ;;
15598 esac
15599 fi
15600 CHECK_MAKE=$ac_cv_path_CHECK_MAKE
15601 if test -n "$CHECK_MAKE"; then
15602   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5
15603 $as_echo "$CHECK_MAKE" >&6; }
15604 else
15605   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15606 $as_echo "no" >&6; }
15607 fi
15608 
15609 
15610   test -n "$CHECK_MAKE" && break
15611 done
15612 
15613 
15614   MAKE_CANDIDATE=""$CHECK_MAKE""
15615   DESCRIPTION="make in PATH"
15616   if test "x$MAKE_CANDIDATE" != x; then
15617     { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
15618 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
15619     MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
15620     IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
15621     if test "x$IS_GNU_MAKE" = x; then
15622       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
15623 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
15624     else
15625       IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
15626       if test "x$IS_MODERN_MAKE" = x; then
15627         { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5
15628 $as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;}
15629       else
15630         if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
15631           if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15632             MAKE_EXPECTED_ENV='cygwin'
15633           elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15634             MAKE_EXPECTED_ENV='msys'
15635           else
15636             as_fn_error $? "Unknown Windows environment" "$LINENO" 5
15637           fi
15638           MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
15639           IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
15640         else
15641           # Not relevant for non-Windows
15642           IS_MAKE_CORRECT_ENV=true
15643         fi
15644         if test "x$IS_MAKE_CORRECT_ENV" = x; then
15645           { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&5
15646 $as_echo "$as_me: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&6;}
15647         else
15648           FOUND_MAKE=$MAKE_CANDIDATE
15649 
15650   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15651 
15652   # First separate the path from the arguments. This will split at the first
15653   # space.
15654   complete="$FOUND_MAKE"
15655   path="${complete%% *}"
15656   tmp="$complete EOL"
15657   arguments="${tmp#* }"
15658 
15659   # Input might be given as Windows format, start by converting to
15660   # unix format.
15661   new_path=`$CYGPATH -u "$path"`
15662 
15663   # Now try to locate executable using which
15664   new_path=`$WHICH "$new_path" 2> /dev/null`
15665   # bat and cmd files are not always considered executable in cygwin causing which
15666   # to not find them
15667   if test "x$new_path" = x \
15668       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15669       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15670     new_path=`$CYGPATH -u "$path"`
15671   fi
15672   if test "x$new_path" = x; then
15673     # Oops. Which didn't find the executable.
15674     # The splitting of arguments from the executable at a space might have been incorrect,
15675     # since paths with space are more likely in Windows. Give it another try with the whole
15676     # argument.
15677     path="$complete"
15678     arguments="EOL"
15679     new_path=`$CYGPATH -u "$path"`
15680     new_path=`$WHICH "$new_path" 2> /dev/null`
15681     # bat and cmd files are not always considered executable in cygwin causing which
15682     # to not find them
15683     if test "x$new_path" = x \
15684         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15685         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15686       new_path=`$CYGPATH -u "$path"`
15687     fi
15688     if test "x$new_path" = x; then
15689       # It's still not found. Now this is an unrecoverable error.
15690       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15691 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15692       has_space=`$ECHO "$complete" | $GREP " "`
15693       if test "x$has_space" != x; then
15694         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15695 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15696       fi
15697       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15698     fi
15699   fi
15700 
15701   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
15702   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
15703   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
15704   # "foo.exe" is OK but "foo" is an error.
15705   #
15706   # This test is therefore slightly more accurate than "test -f" to check for file presence.
15707   # It is also a way to make sure we got the proper file name for the real test later on.
15708   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
15709   if test "x$test_shortpath" = x; then
15710     # Short path failed, file does not exist as specified.
15711     # Try adding .exe or .cmd
15712     if test -f "${new_path}.exe"; then
15713       input_to_shortpath="${new_path}.exe"
15714     elif test -f "${new_path}.cmd"; then
15715       input_to_shortpath="${new_path}.cmd"
15716     else
15717       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
15718 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
15719       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
15720 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
15721       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15722     fi
15723   else
15724     input_to_shortpath="$new_path"
15725   fi
15726 
15727   # Call helper function which possibly converts this using DOS-style short mode.
15728   # If so, the updated path is stored in $new_path.
15729   new_path="$input_to_shortpath"
15730 
15731   input_path="$input_to_shortpath"
15732   # Check if we need to convert this using DOS-style short mode. If the path
15733   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15734   # take no chances and rewrite it.
15735   # Note: m4 eats our [], so we need to use [ and ] instead.
15736   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
15737   if test "x$has_forbidden_chars" != x; then
15738     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15739     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
15740     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
15741     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
15742       # Going to short mode and back again did indeed matter. Since short mode is
15743       # case insensitive, let's make it lowercase to improve readability.
15744       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15745       # Now convert it back to Unix-stile (cygpath)
15746       input_path=`$CYGPATH -u "$shortmode_path"`
15747       new_path="$input_path"
15748     fi
15749   fi
15750 
15751   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
15752   if test "x$test_cygdrive_prefix" = x; then
15753     # As a simple fix, exclude /usr/bin since it's not a real path.
15754     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
15755       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
15756       # a path prefixed by /cygdrive for fixpath to work.
15757       new_path="$CYGWIN_ROOT_PATH$input_path"
15758     fi
15759   fi
15760 
15761   # remove trailing .exe if any
15762   new_path="${new_path/%.exe/}"
15763 
15764   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15765 
15766   # First separate the path from the arguments. This will split at the first
15767   # space.
15768   complete="$FOUND_MAKE"
15769   path="${complete%% *}"
15770   tmp="$complete EOL"
15771   arguments="${tmp#* }"
15772 
15773   # Input might be given as Windows format, start by converting to
15774   # unix format.
15775   new_path="$path"
15776 
15777   windows_path="$new_path"
15778   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15779     unix_path=`$CYGPATH -u "$windows_path"`
15780     new_path="$unix_path"
15781   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15782     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15783     new_path="$unix_path"
15784   fi
15785 
15786 
15787   # Now try to locate executable using which
15788   new_path=`$WHICH "$new_path" 2> /dev/null`
15789 
15790   if test "x$new_path" = x; then
15791     # Oops. Which didn't find the executable.
15792     # The splitting of arguments from the executable at a space might have been incorrect,
15793     # since paths with space are more likely in Windows. Give it another try with the whole
15794     # argument.
15795     path="$complete"
15796     arguments="EOL"
15797     new_path="$path"
15798 
15799   windows_path="$new_path"
15800   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15801     unix_path=`$CYGPATH -u "$windows_path"`
15802     new_path="$unix_path"
15803   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15804     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15805     new_path="$unix_path"
15806   fi
15807 
15808 
15809     new_path=`$WHICH "$new_path" 2> /dev/null`
15810 
15811     if test "x$new_path" = x; then
15812       # It's still not found. Now this is an unrecoverable error.
15813       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15814 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15815       has_space=`$ECHO "$complete" | $GREP " "`
15816       if test "x$has_space" != x; then
15817         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15818 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15819       fi
15820       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15821     fi
15822   fi
15823 
15824   # Now new_path has a complete unix path to the binary
15825   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
15826     # Keep paths in /bin as-is, but remove trailing .exe if any
15827     new_path="${new_path/%.exe/}"
15828     # Do not save /bin paths to all_fixpath_prefixes!
15829   else
15830     # Not in mixed or Windows style, start by that.
15831     new_path=`cmd //c echo $new_path`
15832 
15833   input_path="$new_path"
15834   # Check if we need to convert this using DOS-style short mode. If the path
15835   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15836   # take no chances and rewrite it.
15837   # Note: m4 eats our [], so we need to use [ and ] instead.
15838   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
15839   if test "x$has_forbidden_chars" != x; then
15840     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15841     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15842   fi
15843 
15844     # Output is in $new_path
15845 
15846   windows_path="$new_path"
15847   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15848     unix_path=`$CYGPATH -u "$windows_path"`
15849     new_path="$unix_path"
15850   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15851     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15852     new_path="$unix_path"
15853   fi
15854 
15855     # remove trailing .exe if any
15856     new_path="${new_path/%.exe/}"
15857 
15858     # Save the first 10 bytes of this path to the storage, so fixpath can work.
15859     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
15860   fi
15861 
15862   else
15863     # We're on a posix platform. Hooray! :)
15864     # First separate the path from the arguments. This will split at the first
15865     # space.
15866     complete="$FOUND_MAKE"
15867     path="${complete%% *}"
15868     tmp="$complete EOL"
15869     arguments="${tmp#* }"
15870 
15871     # Cannot rely on the command "which" here since it doesn't always work.
15872     is_absolute_path=`$ECHO "$path" | $GREP ^/`
15873     if test -z "$is_absolute_path"; then
15874       # Path to executable is not absolute. Find it.
15875       IFS_save="$IFS"
15876       IFS=:
15877       for p in $PATH; do
15878         if test -f "$p/$path" && test -x "$p/$path"; then
15879           new_path="$p/$path"
15880           break
15881         fi
15882       done
15883       IFS="$IFS_save"
15884     else
15885       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&5
15886 $as_echo "$as_me: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&6;}
15887       new_path="$path"
15888     fi
15889 
15890     if test "x$new_path" = x; then
15891       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15892 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15893       has_space=`$ECHO "$complete" | $GREP " "`
15894       if test "x$has_space" != x; then
15895         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
15896 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
15897       fi
15898       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15899     fi
15900   fi
15901 
15902   # Now join together the path and the arguments once again
15903   if test "x$arguments" != xEOL; then
15904     new_complete="$new_path ${arguments% *}"
15905   else
15906     new_complete="$new_path"
15907   fi
15908 
15909   if test "x$complete" != "x$new_complete"; then
15910     FOUND_MAKE="$new_complete"
15911     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
15912 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
15913   fi
15914 
15915         fi
15916       fi
15917     fi
15918   fi
15919 
15920     fi
15921 
15922     if test "x$FOUND_MAKE" = x; then
15923       if test "x$TOOLS_DIR" != x; then
15924         # We have a tools-dir, check that as well before giving up.
15925         OLD_PATH=$PATH
15926         PATH=$TOOLS_DIR:$PATH
15927         for ac_prog in gmake
15928 do
15929   # Extract the first word of "$ac_prog", so it can be a program name with args.
15930 set dummy $ac_prog; ac_word=$2
15931 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15932 $as_echo_n "checking for $ac_word... " >&6; }
15933 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then :
15934   $as_echo_n "(cached) " >&6
15935 else
15936   case $CHECK_TOOLSDIR_GMAKE in
15937   [\\/]* | ?:[\\/]*)
15938   ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path.
15939   ;;
15940   *)
15941   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15942 for as_dir in $PATH
15943 do
15944   IFS=$as_save_IFS
15945   test -z "$as_dir" && as_dir=.
15946     for ac_exec_ext in '' $ac_executable_extensions; do
15947   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15948     ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext"
15949     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15950     break 2
15951   fi
15952 done
15953   done
15954 IFS=$as_save_IFS
15955 
15956   ;;
15957 esac
15958 fi
15959 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE
15960 if test -n "$CHECK_TOOLSDIR_GMAKE"; then
15961   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5
15962 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; }
15963 else
15964   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15965 $as_echo "no" >&6; }
15966 fi
15967 
15968 
15969   test -n "$CHECK_TOOLSDIR_GMAKE" && break
15970 done
15971 
15972 
15973   MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE""
15974   DESCRIPTION="gmake in tools-dir"
15975   if test "x$MAKE_CANDIDATE" != x; then
15976     { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
15977 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
15978     MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
15979     IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
15980     if test "x$IS_GNU_MAKE" = x; then
15981       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
15982 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
15983     else
15984       IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
15985       if test "x$IS_MODERN_MAKE" = x; then
15986         { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5
15987 $as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;}
15988       else
15989         if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
15990           if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15991             MAKE_EXPECTED_ENV='cygwin'
15992           elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15993             MAKE_EXPECTED_ENV='msys'
15994           else
15995             as_fn_error $? "Unknown Windows environment" "$LINENO" 5
15996           fi
15997           MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
15998           IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
15999         else
16000           # Not relevant for non-Windows
16001           IS_MAKE_CORRECT_ENV=true
16002         fi
16003         if test "x$IS_MAKE_CORRECT_ENV" = x; then
16004           { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&5
16005 $as_echo "$as_me: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&6;}
16006         else
16007           FOUND_MAKE=$MAKE_CANDIDATE
16008 
16009   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16010 
16011   # First separate the path from the arguments. This will split at the first
16012   # space.
16013   complete="$FOUND_MAKE"
16014   path="${complete%% *}"
16015   tmp="$complete EOL"
16016   arguments="${tmp#* }"
16017 
16018   # Input might be given as Windows format, start by converting to
16019   # unix format.
16020   new_path=`$CYGPATH -u "$path"`
16021 
16022   # Now try to locate executable using which
16023   new_path=`$WHICH "$new_path" 2> /dev/null`
16024   # bat and cmd files are not always considered executable in cygwin causing which
16025   # to not find them
16026   if test "x$new_path" = x \
16027       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16028       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16029     new_path=`$CYGPATH -u "$path"`
16030   fi
16031   if test "x$new_path" = x; then
16032     # Oops. Which didn't find the executable.
16033     # The splitting of arguments from the executable at a space might have been incorrect,
16034     # since paths with space are more likely in Windows. Give it another try with the whole
16035     # argument.
16036     path="$complete"
16037     arguments="EOL"
16038     new_path=`$CYGPATH -u "$path"`
16039     new_path=`$WHICH "$new_path" 2> /dev/null`
16040     # bat and cmd files are not always considered executable in cygwin causing which
16041     # to not find them
16042     if test "x$new_path" = x \
16043         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16044         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16045       new_path=`$CYGPATH -u "$path"`
16046     fi
16047     if test "x$new_path" = x; then
16048       # It's still not found. Now this is an unrecoverable error.
16049       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16050 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16051       has_space=`$ECHO "$complete" | $GREP " "`
16052       if test "x$has_space" != x; then
16053         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16054 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16055       fi
16056       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16057     fi
16058   fi
16059 
16060   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
16061   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
16062   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
16063   # "foo.exe" is OK but "foo" is an error.
16064   #
16065   # This test is therefore slightly more accurate than "test -f" to check for file presence.
16066   # It is also a way to make sure we got the proper file name for the real test later on.
16067   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
16068   if test "x$test_shortpath" = x; then
16069     # Short path failed, file does not exist as specified.
16070     # Try adding .exe or .cmd
16071     if test -f "${new_path}.exe"; then
16072       input_to_shortpath="${new_path}.exe"
16073     elif test -f "${new_path}.cmd"; then
16074       input_to_shortpath="${new_path}.cmd"
16075     else
16076       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
16077 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
16078       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
16079 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
16080       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16081     fi
16082   else
16083     input_to_shortpath="$new_path"
16084   fi
16085 
16086   # Call helper function which possibly converts this using DOS-style short mode.
16087   # If so, the updated path is stored in $new_path.
16088   new_path="$input_to_shortpath"
16089 
16090   input_path="$input_to_shortpath"
16091   # Check if we need to convert this using DOS-style short mode. If the path
16092   # contains just simple characters, use it. Otherwise (spaces, weird characters),
16093   # take no chances and rewrite it.
16094   # Note: m4 eats our [], so we need to use [ and ] instead.
16095   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
16096   if test "x$has_forbidden_chars" != x; then
16097     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16098     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
16099     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
16100     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
16101       # Going to short mode and back again did indeed matter. Since short mode is
16102       # case insensitive, let's make it lowercase to improve readability.
16103       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16104       # Now convert it back to Unix-stile (cygpath)
16105       input_path=`$CYGPATH -u "$shortmode_path"`
16106       new_path="$input_path"
16107     fi
16108   fi
16109 
16110   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
16111   if test "x$test_cygdrive_prefix" = x; then
16112     # As a simple fix, exclude /usr/bin since it's not a real path.
16113     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
16114       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
16115       # a path prefixed by /cygdrive for fixpath to work.
16116       new_path="$CYGWIN_ROOT_PATH$input_path"
16117     fi
16118   fi
16119 
16120   # remove trailing .exe if any
16121   new_path="${new_path/%.exe/}"
16122 
16123   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16124 
16125   # First separate the path from the arguments. This will split at the first
16126   # space.
16127   complete="$FOUND_MAKE"
16128   path="${complete%% *}"
16129   tmp="$complete EOL"
16130   arguments="${tmp#* }"
16131 
16132   # Input might be given as Windows format, start by converting to
16133   # unix format.
16134   new_path="$path"
16135 
16136   windows_path="$new_path"
16137   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16138     unix_path=`$CYGPATH -u "$windows_path"`
16139     new_path="$unix_path"
16140   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16141     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16142     new_path="$unix_path"
16143   fi
16144 
16145 
16146   # Now try to locate executable using which
16147   new_path=`$WHICH "$new_path" 2> /dev/null`
16148 
16149   if test "x$new_path" = x; then
16150     # Oops. Which didn't find the executable.
16151     # The splitting of arguments from the executable at a space might have been incorrect,
16152     # since paths with space are more likely in Windows. Give it another try with the whole
16153     # argument.
16154     path="$complete"
16155     arguments="EOL"
16156     new_path="$path"
16157 
16158   windows_path="$new_path"
16159   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16160     unix_path=`$CYGPATH -u "$windows_path"`
16161     new_path="$unix_path"
16162   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16163     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16164     new_path="$unix_path"
16165   fi
16166 
16167 
16168     new_path=`$WHICH "$new_path" 2> /dev/null`
16169 
16170     if test "x$new_path" = x; then
16171       # It's still not found. Now this is an unrecoverable error.
16172       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16173 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16174       has_space=`$ECHO "$complete" | $GREP " "`
16175       if test "x$has_space" != x; then
16176         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16177 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16178       fi
16179       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16180     fi
16181   fi
16182 
16183   # Now new_path has a complete unix path to the binary
16184   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
16185     # Keep paths in /bin as-is, but remove trailing .exe if any
16186     new_path="${new_path/%.exe/}"
16187     # Do not save /bin paths to all_fixpath_prefixes!
16188   else
16189     # Not in mixed or Windows style, start by that.
16190     new_path=`cmd //c echo $new_path`
16191 
16192   input_path="$new_path"
16193   # Check if we need to convert this using DOS-style short mode. If the path
16194   # contains just simple characters, use it. Otherwise (spaces, weird characters),
16195   # take no chances and rewrite it.
16196   # Note: m4 eats our [], so we need to use [ and ] instead.
16197   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
16198   if test "x$has_forbidden_chars" != x; then
16199     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16200     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16201   fi
16202 
16203     # Output is in $new_path
16204 
16205   windows_path="$new_path"
16206   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16207     unix_path=`$CYGPATH -u "$windows_path"`
16208     new_path="$unix_path"
16209   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16210     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16211     new_path="$unix_path"
16212   fi
16213 
16214     # remove trailing .exe if any
16215     new_path="${new_path/%.exe/}"
16216 
16217     # Save the first 10 bytes of this path to the storage, so fixpath can work.
16218     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
16219   fi
16220 
16221   else
16222     # We're on a posix platform. Hooray! :)
16223     # First separate the path from the arguments. This will split at the first
16224     # space.
16225     complete="$FOUND_MAKE"
16226     path="${complete%% *}"
16227     tmp="$complete EOL"
16228     arguments="${tmp#* }"
16229 
16230     # Cannot rely on the command "which" here since it doesn't always work.
16231     is_absolute_path=`$ECHO "$path" | $GREP ^/`
16232     if test -z "$is_absolute_path"; then
16233       # Path to executable is not absolute. Find it.
16234       IFS_save="$IFS"
16235       IFS=:
16236       for p in $PATH; do
16237         if test -f "$p/$path" && test -x "$p/$path"; then
16238           new_path="$p/$path"
16239           break
16240         fi
16241       done
16242       IFS="$IFS_save"
16243     else
16244       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&5
16245 $as_echo "$as_me: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&6;}
16246       new_path="$path"
16247     fi
16248 
16249     if test "x$new_path" = x; then
16250       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16251 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16252       has_space=`$ECHO "$complete" | $GREP " "`
16253       if test "x$has_space" != x; then
16254         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
16255 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
16256       fi
16257       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16258     fi
16259   fi
16260 
16261   # Now join together the path and the arguments once again
16262   if test "x$arguments" != xEOL; then
16263     new_complete="$new_path ${arguments% *}"
16264   else
16265     new_complete="$new_path"
16266   fi
16267 
16268   if test "x$complete" != "x$new_complete"; then
16269     FOUND_MAKE="$new_complete"
16270     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
16271 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
16272   fi
16273 
16274         fi
16275       fi
16276     fi
16277   fi
16278 
16279         if test "x$FOUND_MAKE" = x; then
16280           for ac_prog in make
16281 do
16282   # Extract the first word of "$ac_prog", so it can be a program name with args.
16283 set dummy $ac_prog; ac_word=$2
16284 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16285 $as_echo_n "checking for $ac_word... " >&6; }
16286 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then :
16287   $as_echo_n "(cached) " >&6
16288 else
16289   case $CHECK_TOOLSDIR_MAKE in
16290   [\\/]* | ?:[\\/]*)
16291   ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path.
16292   ;;
16293   *)
16294   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16295 for as_dir in $PATH
16296 do
16297   IFS=$as_save_IFS
16298   test -z "$as_dir" && as_dir=.
16299     for ac_exec_ext in '' $ac_executable_extensions; do
16300   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16301     ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext"
16302     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16303     break 2
16304   fi
16305 done
16306   done
16307 IFS=$as_save_IFS
16308 
16309   ;;
16310 esac
16311 fi
16312 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE
16313 if test -n "$CHECK_TOOLSDIR_MAKE"; then
16314   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5
16315 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; }
16316 else
16317   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16318 $as_echo "no" >&6; }
16319 fi
16320 
16321 
16322   test -n "$CHECK_TOOLSDIR_MAKE" && break
16323 done
16324 
16325 
16326   MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE""
16327   DESCRIPTION="make in tools-dir"
16328   if test "x$MAKE_CANDIDATE" != x; then
16329     { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
16330 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
16331     MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
16332     IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
16333     if test "x$IS_GNU_MAKE" = x; then
16334       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
16335 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
16336     else
16337       IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
16338       if test "x$IS_MODERN_MAKE" = x; then
16339         { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&5
16340 $as_echo "$as_me: Found GNU make at $MAKE_CANDIDATE, however this is not version 3.81 or later. (it is: $MAKE_VERSION_STRING). Ignoring." >&6;}
16341       else
16342         if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
16343           if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16344             MAKE_EXPECTED_ENV='cygwin'
16345           elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16346             MAKE_EXPECTED_ENV='msys'
16347           else
16348             as_fn_error $? "Unknown Windows environment" "$LINENO" 5
16349           fi
16350           MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
16351           IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
16352         else
16353           # Not relevant for non-Windows
16354           IS_MAKE_CORRECT_ENV=true
16355         fi
16356         if test "x$IS_MAKE_CORRECT_ENV" = x; then
16357           { $as_echo "$as_me:${as_lineno-$LINENO}: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&5
16358 $as_echo "$as_me: Found GNU make version $MAKE_VERSION_STRING at $MAKE_CANDIDATE, but it is not for $MAKE_EXPECTED_ENV (it says: $MAKE_BUILT_FOR). Ignoring." >&6;}
16359         else
16360           FOUND_MAKE=$MAKE_CANDIDATE
16361 
16362   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16363 
16364   # First separate the path from the arguments. This will split at the first
16365   # space.
16366   complete="$FOUND_MAKE"
16367   path="${complete%% *}"
16368   tmp="$complete EOL"
16369   arguments="${tmp#* }"
16370 
16371   # Input might be given as Windows format, start by converting to
16372   # unix format.
16373   new_path=`$CYGPATH -u "$path"`
16374 
16375   # Now try to locate executable using which
16376   new_path=`$WHICH "$new_path" 2> /dev/null`
16377   # bat and cmd files are not always considered executable in cygwin causing which
16378   # to not find them
16379   if test "x$new_path" = x \
16380       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16381       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16382     new_path=`$CYGPATH -u "$path"`
16383   fi
16384   if test "x$new_path" = x; then
16385     # Oops. Which didn't find the executable.
16386     # The splitting of arguments from the executable at a space might have been incorrect,
16387     # since paths with space are more likely in Windows. Give it another try with the whole
16388     # argument.
16389     path="$complete"
16390     arguments="EOL"
16391     new_path=`$CYGPATH -u "$path"`
16392     new_path=`$WHICH "$new_path" 2> /dev/null`
16393     # bat and cmd files are not always considered executable in cygwin causing which
16394     # to not find them
16395     if test "x$new_path" = x \
16396         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16397         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16398       new_path=`$CYGPATH -u "$path"`
16399     fi
16400     if test "x$new_path" = x; then
16401       # It's still not found. Now this is an unrecoverable error.
16402       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16403 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16404       has_space=`$ECHO "$complete" | $GREP " "`
16405       if test "x$has_space" != x; then
16406         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16407 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16408       fi
16409       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16410     fi
16411   fi
16412 
16413   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
16414   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
16415   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
16416   # "foo.exe" is OK but "foo" is an error.
16417   #
16418   # This test is therefore slightly more accurate than "test -f" to check for file presence.
16419   # It is also a way to make sure we got the proper file name for the real test later on.
16420   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
16421   if test "x$test_shortpath" = x; then
16422     # Short path failed, file does not exist as specified.
16423     # Try adding .exe or .cmd
16424     if test -f "${new_path}.exe"; then
16425       input_to_shortpath="${new_path}.exe"
16426     elif test -f "${new_path}.cmd"; then
16427       input_to_shortpath="${new_path}.cmd"
16428     else
16429       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
16430 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
16431       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
16432 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
16433       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16434     fi
16435   else
16436     input_to_shortpath="$new_path"
16437   fi
16438 
16439   # Call helper function which possibly converts this using DOS-style short mode.
16440   # If so, the updated path is stored in $new_path.
16441   new_path="$input_to_shortpath"
16442 
16443   input_path="$input_to_shortpath"
16444   # Check if we need to convert this using DOS-style short mode. If the path
16445   # contains just simple characters, use it. Otherwise (spaces, weird characters),
16446   # take no chances and rewrite it.
16447   # Note: m4 eats our [], so we need to use [ and ] instead.
16448   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
16449   if test "x$has_forbidden_chars" != x; then
16450     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16451     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
16452     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
16453     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
16454       # Going to short mode and back again did indeed matter. Since short mode is
16455       # case insensitive, let's make it lowercase to improve readability.
16456       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16457       # Now convert it back to Unix-stile (cygpath)
16458       input_path=`$CYGPATH -u "$shortmode_path"`
16459       new_path="$input_path"
16460     fi
16461   fi
16462 
16463   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
16464   if test "x$test_cygdrive_prefix" = x; then
16465     # As a simple fix, exclude /usr/bin since it's not a real path.
16466     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
16467       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
16468       # a path prefixed by /cygdrive for fixpath to work.
16469       new_path="$CYGWIN_ROOT_PATH$input_path"
16470     fi
16471   fi
16472 
16473   # remove trailing .exe if any
16474   new_path="${new_path/%.exe/}"
16475 
16476   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16477 
16478   # First separate the path from the arguments. This will split at the first
16479   # space.
16480   complete="$FOUND_MAKE"
16481   path="${complete%% *}"
16482   tmp="$complete EOL"
16483   arguments="${tmp#* }"
16484 
16485   # Input might be given as Windows format, start by converting to
16486   # unix format.
16487   new_path="$path"
16488 
16489   windows_path="$new_path"
16490   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16491     unix_path=`$CYGPATH -u "$windows_path"`
16492     new_path="$unix_path"
16493   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16494     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16495     new_path="$unix_path"
16496   fi
16497 
16498 
16499   # Now try to locate executable using which
16500   new_path=`$WHICH "$new_path" 2> /dev/null`
16501 
16502   if test "x$new_path" = x; then
16503     # Oops. Which didn't find the executable.
16504     # The splitting of arguments from the executable at a space might have been incorrect,
16505     # since paths with space are more likely in Windows. Give it another try with the whole
16506     # argument.
16507     path="$complete"
16508     arguments="EOL"
16509     new_path="$path"
16510 
16511   windows_path="$new_path"
16512   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16513     unix_path=`$CYGPATH -u "$windows_path"`
16514     new_path="$unix_path"
16515   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16516     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16517     new_path="$unix_path"
16518   fi
16519 
16520 
16521     new_path=`$WHICH "$new_path" 2> /dev/null`
16522 
16523     if test "x$new_path" = x; then
16524       # It's still not found. Now this is an unrecoverable error.
16525       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16526 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16527       has_space=`$ECHO "$complete" | $GREP " "`
16528       if test "x$has_space" != x; then
16529         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16530 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16531       fi
16532       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16533     fi
16534   fi
16535 
16536   # Now new_path has a complete unix path to the binary
16537   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
16538     # Keep paths in /bin as-is, but remove trailing .exe if any
16539     new_path="${new_path/%.exe/}"
16540     # Do not save /bin paths to all_fixpath_prefixes!
16541   else
16542     # Not in mixed or Windows style, start by that.
16543     new_path=`cmd //c echo $new_path`
16544 
16545   input_path="$new_path"
16546   # Check if we need to convert this using DOS-style short mode. If the path
16547   # contains just simple characters, use it. Otherwise (spaces, weird characters),
16548   # take no chances and rewrite it.
16549   # Note: m4 eats our [], so we need to use [ and ] instead.
16550   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
16551   if test "x$has_forbidden_chars" != x; then
16552     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16553     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16554   fi
16555 
16556     # Output is in $new_path
16557 
16558   windows_path="$new_path"
16559   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16560     unix_path=`$CYGPATH -u "$windows_path"`
16561     new_path="$unix_path"
16562   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16563     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16564     new_path="$unix_path"
16565   fi
16566 
16567     # remove trailing .exe if any
16568     new_path="${new_path/%.exe/}"
16569 
16570     # Save the first 10 bytes of this path to the storage, so fixpath can work.
16571     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
16572   fi
16573 
16574   else
16575     # We're on a posix platform. Hooray! :)
16576     # First separate the path from the arguments. This will split at the first
16577     # space.
16578     complete="$FOUND_MAKE"
16579     path="${complete%% *}"
16580     tmp="$complete EOL"
16581     arguments="${tmp#* }"
16582 
16583     # Cannot rely on the command "which" here since it doesn't always work.
16584     is_absolute_path=`$ECHO "$path" | $GREP ^/`
16585     if test -z "$is_absolute_path"; then
16586       # Path to executable is not absolute. Find it.
16587       IFS_save="$IFS"
16588       IFS=:
16589       for p in $PATH; do
16590         if test -f "$p/$path" && test -x "$p/$path"; then
16591           new_path="$p/$path"
16592           break
16593         fi
16594       done
16595       IFS="$IFS_save"
16596     else
16597       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&5
16598 $as_echo "$as_me: Resolving FOUND_MAKE (as $path) failed, using $path directly." >&6;}
16599       new_path="$path"
16600     fi
16601 
16602     if test "x$new_path" = x; then
16603       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16604 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16605       has_space=`$ECHO "$complete" | $GREP " "`
16606       if test "x$has_space" != x; then
16607         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
16608 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
16609       fi
16610       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16611     fi
16612   fi
16613 
16614   # Now join together the path and the arguments once again
16615   if test "x$arguments" != xEOL; then
16616     new_complete="$new_path ${arguments% *}"
16617   else
16618     new_complete="$new_path"
16619   fi
16620 
16621   if test "x$complete" != "x$new_complete"; then
16622     FOUND_MAKE="$new_complete"
16623     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
16624 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
16625   fi
16626 
16627         fi
16628       fi
16629     fi
16630   fi
16631 
16632         fi
16633         PATH=$OLD_PATH
16634       fi
16635     fi
16636 
16637     if test "x$FOUND_MAKE" = x; then
16638       as_fn_error $? "Cannot find GNU make 3.81 or newer! Please put it in the path, or add e.g. MAKE=/opt/gmake3.81/make as argument to configure." "$LINENO" 5
16639     fi
16640   fi
16641 
16642   MAKE=$FOUND_MAKE
16643 
16644   { $as_echo "$as_me:${as_lineno-$LINENO}: Using GNU make 3.81 (or later) at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&5
16645 $as_echo "$as_me: Using GNU make 3.81 (or later) at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&6;}
16646 
16647 
16648 
16649   # Test if find supports -delete
16650   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if find supports -delete" >&5
16651 $as_echo_n "checking if find supports -delete... " >&6; }
16652   FIND_DELETE="-delete"
16653 
16654   DELETEDIR=`$MKTEMP -d tmp.XXXXXXXXXX` || (echo Could not create temporary directory!; exit $?)
16655 
16656   echo Hejsan > $DELETEDIR/TestIfFindSupportsDelete
16657 
16658   TEST_DELETE=`$FIND "$DELETEDIR" -name TestIfFindSupportsDelete $FIND_DELETE 2>&1`
16659   if test -f $DELETEDIR/TestIfFindSupportsDelete; then
16660     # No, it does not.
16661     rm $DELETEDIR/TestIfFindSupportsDelete
16662     FIND_DELETE="-exec rm \{\} \+"
16663     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16664 $as_echo "no" >&6; }
16665   else
16666     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16667 $as_echo "yes" >&6; }
16668   fi
16669   rmdir $DELETEDIR
16670 
16671 
16672 
16673   # These tools might not be installed by default,
16674   # need hint on how to install them.
16675 
16676 
16677 
16678   # Publish this variable in the help.
16679 
16680 
16681   if test "x$UNZIP" = x; then
16682     # The variable is not set by user, try to locate tool using the code snippet
16683     for ac_prog in unzip
16684 do
16685   # Extract the first word of "$ac_prog", so it can be a program name with args.
16686 set dummy $ac_prog; ac_word=$2
16687 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16688 $as_echo_n "checking for $ac_word... " >&6; }
16689 if ${ac_cv_path_UNZIP+:} false; then :
16690   $as_echo_n "(cached) " >&6
16691 else
16692   case $UNZIP in
16693   [\\/]* | ?:[\\/]*)
16694   ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path.
16695   ;;
16696   *)
16697   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16698 for as_dir in $PATH
16699 do
16700   IFS=$as_save_IFS
16701   test -z "$as_dir" && as_dir=.
16702     for ac_exec_ext in '' $ac_executable_extensions; do
16703   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16704     ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext"
16705     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16706     break 2
16707   fi
16708 done
16709   done
16710 IFS=$as_save_IFS
16711 
16712   ;;
16713 esac
16714 fi
16715 UNZIP=$ac_cv_path_UNZIP
16716 if test -n "$UNZIP"; then
16717   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5
16718 $as_echo "$UNZIP" >&6; }
16719 else
16720   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16721 $as_echo "no" >&6; }
16722 fi
16723 
16724 
16725   test -n "$UNZIP" && break
16726 done
16727 
16728   else
16729     # The variable is set, but is it from the command line or the environment?
16730 
16731     # Try to remove the string !UNZIP! from our list.
16732     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNZIP!/}
16733     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
16734       # If it failed, the variable was not from the command line. Ignore it,
16735       # but warn the user (except for BASH, which is always set by the calling BASH).
16736       if test "xUNZIP" != xBASH; then
16737         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&5
16738 $as_echo "$as_me: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&2;}
16739       fi
16740       # Try to locate tool using the code snippet
16741       for ac_prog in unzip
16742 do
16743   # Extract the first word of "$ac_prog", so it can be a program name with args.
16744 set dummy $ac_prog; ac_word=$2
16745 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16746 $as_echo_n "checking for $ac_word... " >&6; }
16747 if ${ac_cv_path_UNZIP+:} false; then :
16748   $as_echo_n "(cached) " >&6
16749 else
16750   case $UNZIP in
16751   [\\/]* | ?:[\\/]*)
16752   ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path.
16753   ;;
16754   *)
16755   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16756 for as_dir in $PATH
16757 do
16758   IFS=$as_save_IFS
16759   test -z "$as_dir" && as_dir=.
16760     for ac_exec_ext in '' $ac_executable_extensions; do
16761   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16762     ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext"
16763     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16764     break 2
16765   fi
16766 done
16767   done
16768 IFS=$as_save_IFS
16769 
16770   ;;
16771 esac
16772 fi
16773 UNZIP=$ac_cv_path_UNZIP
16774 if test -n "$UNZIP"; then
16775   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5
16776 $as_echo "$UNZIP" >&6; }
16777 else
16778   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16779 $as_echo "no" >&6; }
16780 fi
16781 
16782 
16783   test -n "$UNZIP" && break
16784 done
16785 
16786     else
16787       # If it succeeded, then it was overridden by the user. We will use it
16788       # for the tool.
16789 
16790       # First remove it from the list of overridden variables, so we can test
16791       # for unknown variables in the end.
16792       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
16793 
16794       # Check if the provided tool contains a complete path.
16795       tool_specified="$UNZIP"
16796       tool_basename="${tool_specified##*/}"
16797       if test "x$tool_basename" = "x$tool_specified"; then
16798         # A command without a complete path is provided, search $PATH.
16799         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNZIP=$tool_basename" >&5
16800 $as_echo "$as_me: Will search for user supplied tool UNZIP=$tool_basename" >&6;}
16801         # Extract the first word of "$tool_basename", so it can be a program name with args.
16802 set dummy $tool_basename; ac_word=$2
16803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16804 $as_echo_n "checking for $ac_word... " >&6; }
16805 if ${ac_cv_path_UNZIP+:} false; then :
16806   $as_echo_n "(cached) " >&6
16807 else
16808   case $UNZIP in
16809   [\\/]* | ?:[\\/]*)
16810   ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path.
16811   ;;
16812   *)
16813   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16814 for as_dir in $PATH
16815 do
16816   IFS=$as_save_IFS
16817   test -z "$as_dir" && as_dir=.
16818     for ac_exec_ext in '' $ac_executable_extensions; do
16819   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16820     ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext"
16821     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16822     break 2
16823   fi
16824 done
16825   done
16826 IFS=$as_save_IFS
16827 
16828   ;;
16829 esac
16830 fi
16831 UNZIP=$ac_cv_path_UNZIP
16832 if test -n "$UNZIP"; then
16833   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5
16834 $as_echo "$UNZIP" >&6; }
16835 else
16836   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16837 $as_echo "no" >&6; }
16838 fi
16839 
16840 
16841         if test "x$UNZIP" = x; then
16842           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
16843         fi
16844       else
16845         # Otherwise we believe it is a complete path. Use it as it is.
16846         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNZIP=$tool_specified" >&5
16847 $as_echo "$as_me: Will use user supplied tool UNZIP=$tool_specified" >&6;}
16848         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5
16849 $as_echo_n "checking for UNZIP... " >&6; }
16850         if test ! -x "$tool_specified"; then
16851           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
16852 $as_echo "not found" >&6; }
16853           as_fn_error $? "User supplied tool UNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5
16854         fi
16855         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
16856 $as_echo "$tool_specified" >&6; }
16857       fi
16858     fi
16859   fi
16860 
16861 
16862 
16863   if test "x$UNZIP" = x; then
16864     as_fn_error $? "Could not find required tool for UNZIP" "$LINENO" 5
16865   fi
16866 
16867 
16868 
16869 
16870 
16871   # Publish this variable in the help.
16872 
16873 
16874   if test "x$ZIP" = x; then
16875     # The variable is not set by user, try to locate tool using the code snippet
16876     for ac_prog in zip
16877 do
16878   # Extract the first word of "$ac_prog", so it can be a program name with args.
16879 set dummy $ac_prog; ac_word=$2
16880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16881 $as_echo_n "checking for $ac_word... " >&6; }
16882 if ${ac_cv_path_ZIP+:} false; then :
16883   $as_echo_n "(cached) " >&6
16884 else
16885   case $ZIP in
16886   [\\/]* | ?:[\\/]*)
16887   ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path.
16888   ;;
16889   *)
16890   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16891 for as_dir in $PATH
16892 do
16893   IFS=$as_save_IFS
16894   test -z "$as_dir" && as_dir=.
16895     for ac_exec_ext in '' $ac_executable_extensions; do
16896   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16897     ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext"
16898     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16899     break 2
16900   fi
16901 done
16902   done
16903 IFS=$as_save_IFS
16904 
16905   ;;
16906 esac
16907 fi
16908 ZIP=$ac_cv_path_ZIP
16909 if test -n "$ZIP"; then
16910   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5
16911 $as_echo "$ZIP" >&6; }
16912 else
16913   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16914 $as_echo "no" >&6; }
16915 fi
16916 
16917 
16918   test -n "$ZIP" && break
16919 done
16920 
16921   else
16922     # The variable is set, but is it from the command line or the environment?
16923 
16924     # Try to remove the string !ZIP! from our list.
16925     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ZIP!/}
16926     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
16927       # If it failed, the variable was not from the command line. Ignore it,
16928       # but warn the user (except for BASH, which is always set by the calling BASH).
16929       if test "xZIP" != xBASH; then
16930         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&5
16931 $as_echo "$as_me: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&2;}
16932       fi
16933       # Try to locate tool using the code snippet
16934       for ac_prog in zip
16935 do
16936   # Extract the first word of "$ac_prog", so it can be a program name with args.
16937 set dummy $ac_prog; ac_word=$2
16938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16939 $as_echo_n "checking for $ac_word... " >&6; }
16940 if ${ac_cv_path_ZIP+:} false; then :
16941   $as_echo_n "(cached) " >&6
16942 else
16943   case $ZIP in
16944   [\\/]* | ?:[\\/]*)
16945   ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path.
16946   ;;
16947   *)
16948   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16949 for as_dir in $PATH
16950 do
16951   IFS=$as_save_IFS
16952   test -z "$as_dir" && as_dir=.
16953     for ac_exec_ext in '' $ac_executable_extensions; do
16954   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16955     ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext"
16956     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16957     break 2
16958   fi
16959 done
16960   done
16961 IFS=$as_save_IFS
16962 
16963   ;;
16964 esac
16965 fi
16966 ZIP=$ac_cv_path_ZIP
16967 if test -n "$ZIP"; then
16968   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5
16969 $as_echo "$ZIP" >&6; }
16970 else
16971   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16972 $as_echo "no" >&6; }
16973 fi
16974 
16975 
16976   test -n "$ZIP" && break
16977 done
16978 
16979     else
16980       # If it succeeded, then it was overridden by the user. We will use it
16981       # for the tool.
16982 
16983       # First remove it from the list of overridden variables, so we can test
16984       # for unknown variables in the end.
16985       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
16986 
16987       # Check if the provided tool contains a complete path.
16988       tool_specified="$ZIP"
16989       tool_basename="${tool_specified##*/}"
16990       if test "x$tool_basename" = "x$tool_specified"; then
16991         # A command without a complete path is provided, search $PATH.
16992         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ZIP=$tool_basename" >&5
16993 $as_echo "$as_me: Will search for user supplied tool ZIP=$tool_basename" >&6;}
16994         # Extract the first word of "$tool_basename", so it can be a program name with args.
16995 set dummy $tool_basename; ac_word=$2
16996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16997 $as_echo_n "checking for $ac_word... " >&6; }
16998 if ${ac_cv_path_ZIP+:} false; then :
16999   $as_echo_n "(cached) " >&6
17000 else
17001   case $ZIP in
17002   [\\/]* | ?:[\\/]*)
17003   ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path.
17004   ;;
17005   *)
17006   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17007 for as_dir in $PATH
17008 do
17009   IFS=$as_save_IFS
17010   test -z "$as_dir" && as_dir=.
17011     for ac_exec_ext in '' $ac_executable_extensions; do
17012   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17013     ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext"
17014     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17015     break 2
17016   fi
17017 done
17018   done
17019 IFS=$as_save_IFS
17020 
17021   ;;
17022 esac
17023 fi
17024 ZIP=$ac_cv_path_ZIP
17025 if test -n "$ZIP"; then
17026   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5
17027 $as_echo "$ZIP" >&6; }
17028 else
17029   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17030 $as_echo "no" >&6; }
17031 fi
17032 
17033 
17034         if test "x$ZIP" = x; then
17035           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17036         fi
17037       else
17038         # Otherwise we believe it is a complete path. Use it as it is.
17039         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ZIP=$tool_specified" >&5
17040 $as_echo "$as_me: Will use user supplied tool ZIP=$tool_specified" >&6;}
17041         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIP" >&5
17042 $as_echo_n "checking for ZIP... " >&6; }
17043         if test ! -x "$tool_specified"; then
17044           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17045 $as_echo "not found" >&6; }
17046           as_fn_error $? "User supplied tool ZIP=$tool_specified does not exist or is not executable" "$LINENO" 5
17047         fi
17048         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17049 $as_echo "$tool_specified" >&6; }
17050       fi
17051     fi
17052   fi
17053 
17054 
17055 
17056   if test "x$ZIP" = x; then
17057     as_fn_error $? "Could not find required tool for ZIP" "$LINENO" 5
17058   fi
17059 
17060 
17061 
17062   # Non-required basic tools
17063 
17064 
17065 
17066   # Publish this variable in the help.
17067 
17068 
17069   if test "x$LDD" = x; then
17070     # The variable is not set by user, try to locate tool using the code snippet
17071     for ac_prog in ldd
17072 do
17073   # Extract the first word of "$ac_prog", so it can be a program name with args.
17074 set dummy $ac_prog; ac_word=$2
17075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17076 $as_echo_n "checking for $ac_word... " >&6; }
17077 if ${ac_cv_path_LDD+:} false; then :
17078   $as_echo_n "(cached) " >&6
17079 else
17080   case $LDD in
17081   [\\/]* | ?:[\\/]*)
17082   ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
17083   ;;
17084   *)
17085   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17086 for as_dir in $PATH
17087 do
17088   IFS=$as_save_IFS
17089   test -z "$as_dir" && as_dir=.
17090     for ac_exec_ext in '' $ac_executable_extensions; do
17091   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17092     ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
17093     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17094     break 2
17095   fi
17096 done
17097   done
17098 IFS=$as_save_IFS
17099 
17100   ;;
17101 esac
17102 fi
17103 LDD=$ac_cv_path_LDD
17104 if test -n "$LDD"; then
17105   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5
17106 $as_echo "$LDD" >&6; }
17107 else
17108   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17109 $as_echo "no" >&6; }
17110 fi
17111 
17112 
17113   test -n "$LDD" && break
17114 done
17115 
17116   else
17117     # The variable is set, but is it from the command line or the environment?
17118 
17119     # Try to remove the string !LDD! from our list.
17120     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LDD!/}
17121     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17122       # If it failed, the variable was not from the command line. Ignore it,
17123       # but warn the user (except for BASH, which is always set by the calling BASH).
17124       if test "xLDD" != xBASH; then
17125         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&5
17126 $as_echo "$as_me: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&2;}
17127       fi
17128       # Try to locate tool using the code snippet
17129       for ac_prog in ldd
17130 do
17131   # Extract the first word of "$ac_prog", so it can be a program name with args.
17132 set dummy $ac_prog; ac_word=$2
17133 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17134 $as_echo_n "checking for $ac_word... " >&6; }
17135 if ${ac_cv_path_LDD+:} false; then :
17136   $as_echo_n "(cached) " >&6
17137 else
17138   case $LDD in
17139   [\\/]* | ?:[\\/]*)
17140   ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
17141   ;;
17142   *)
17143   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17144 for as_dir in $PATH
17145 do
17146   IFS=$as_save_IFS
17147   test -z "$as_dir" && as_dir=.
17148     for ac_exec_ext in '' $ac_executable_extensions; do
17149   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17150     ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
17151     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17152     break 2
17153   fi
17154 done
17155   done
17156 IFS=$as_save_IFS
17157 
17158   ;;
17159 esac
17160 fi
17161 LDD=$ac_cv_path_LDD
17162 if test -n "$LDD"; then
17163   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5
17164 $as_echo "$LDD" >&6; }
17165 else
17166   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17167 $as_echo "no" >&6; }
17168 fi
17169 
17170 
17171   test -n "$LDD" && break
17172 done
17173 
17174     else
17175       # If it succeeded, then it was overridden by the user. We will use it
17176       # for the tool.
17177 
17178       # First remove it from the list of overridden variables, so we can test
17179       # for unknown variables in the end.
17180       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17181 
17182       # Check if the provided tool contains a complete path.
17183       tool_specified="$LDD"
17184       tool_basename="${tool_specified##*/}"
17185       if test "x$tool_basename" = "x$tool_specified"; then
17186         # A command without a complete path is provided, search $PATH.
17187         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LDD=$tool_basename" >&5
17188 $as_echo "$as_me: Will search for user supplied tool LDD=$tool_basename" >&6;}
17189         # Extract the first word of "$tool_basename", so it can be a program name with args.
17190 set dummy $tool_basename; ac_word=$2
17191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17192 $as_echo_n "checking for $ac_word... " >&6; }
17193 if ${ac_cv_path_LDD+:} false; then :
17194   $as_echo_n "(cached) " >&6
17195 else
17196   case $LDD in
17197   [\\/]* | ?:[\\/]*)
17198   ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
17199   ;;
17200   *)
17201   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17202 for as_dir in $PATH
17203 do
17204   IFS=$as_save_IFS
17205   test -z "$as_dir" && as_dir=.
17206     for ac_exec_ext in '' $ac_executable_extensions; do
17207   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17208     ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
17209     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17210     break 2
17211   fi
17212 done
17213   done
17214 IFS=$as_save_IFS
17215 
17216   ;;
17217 esac
17218 fi
17219 LDD=$ac_cv_path_LDD
17220 if test -n "$LDD"; then
17221   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5
17222 $as_echo "$LDD" >&6; }
17223 else
17224   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17225 $as_echo "no" >&6; }
17226 fi
17227 
17228 
17229         if test "x$LDD" = x; then
17230           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17231         fi
17232       else
17233         # Otherwise we believe it is a complete path. Use it as it is.
17234         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LDD=$tool_specified" >&5
17235 $as_echo "$as_me: Will use user supplied tool LDD=$tool_specified" >&6;}
17236         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5
17237 $as_echo_n "checking for LDD... " >&6; }
17238         if test ! -x "$tool_specified"; then
17239           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17240 $as_echo "not found" >&6; }
17241           as_fn_error $? "User supplied tool LDD=$tool_specified does not exist or is not executable" "$LINENO" 5
17242         fi
17243         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17244 $as_echo "$tool_specified" >&6; }
17245       fi
17246     fi
17247   fi
17248 
17249 
17250   if test "x$LDD" = "x"; then
17251     # List shared lib dependencies is used for
17252     # debug output and checking for forbidden dependencies.
17253     # We can build without it.
17254     LDD="true"
17255   fi
17256 
17257 
17258   # Publish this variable in the help.
17259 
17260 
17261   if test "x$OTOOL" = x; then
17262     # The variable is not set by user, try to locate tool using the code snippet
17263     for ac_prog in otool
17264 do
17265   # Extract the first word of "$ac_prog", so it can be a program name with args.
17266 set dummy $ac_prog; ac_word=$2
17267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17268 $as_echo_n "checking for $ac_word... " >&6; }
17269 if ${ac_cv_path_OTOOL+:} false; then :
17270   $as_echo_n "(cached) " >&6
17271 else
17272   case $OTOOL in
17273   [\\/]* | ?:[\\/]*)
17274   ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path.
17275   ;;
17276   *)
17277   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17278 for as_dir in $PATH
17279 do
17280   IFS=$as_save_IFS
17281   test -z "$as_dir" && as_dir=.
17282     for ac_exec_ext in '' $ac_executable_extensions; do
17283   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17284     ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext"
17285     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17286     break 2
17287   fi
17288 done
17289   done
17290 IFS=$as_save_IFS
17291 
17292   ;;
17293 esac
17294 fi
17295 OTOOL=$ac_cv_path_OTOOL
17296 if test -n "$OTOOL"; then
17297   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
17298 $as_echo "$OTOOL" >&6; }
17299 else
17300   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17301 $as_echo "no" >&6; }
17302 fi
17303 
17304 
17305   test -n "$OTOOL" && break
17306 done
17307 
17308   else
17309     # The variable is set, but is it from the command line or the environment?
17310 
17311     # Try to remove the string !OTOOL! from our list.
17312     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OTOOL!/}
17313     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17314       # If it failed, the variable was not from the command line. Ignore it,
17315       # but warn the user (except for BASH, which is always set by the calling BASH).
17316       if test "xOTOOL" != xBASH; then
17317         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&5
17318 $as_echo "$as_me: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&2;}
17319       fi
17320       # Try to locate tool using the code snippet
17321       for ac_prog in otool
17322 do
17323   # Extract the first word of "$ac_prog", so it can be a program name with args.
17324 set dummy $ac_prog; ac_word=$2
17325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17326 $as_echo_n "checking for $ac_word... " >&6; }
17327 if ${ac_cv_path_OTOOL+:} false; then :
17328   $as_echo_n "(cached) " >&6
17329 else
17330   case $OTOOL in
17331   [\\/]* | ?:[\\/]*)
17332   ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path.
17333   ;;
17334   *)
17335   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17336 for as_dir in $PATH
17337 do
17338   IFS=$as_save_IFS
17339   test -z "$as_dir" && as_dir=.
17340     for ac_exec_ext in '' $ac_executable_extensions; do
17341   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17342     ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext"
17343     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17344     break 2
17345   fi
17346 done
17347   done
17348 IFS=$as_save_IFS
17349 
17350   ;;
17351 esac
17352 fi
17353 OTOOL=$ac_cv_path_OTOOL
17354 if test -n "$OTOOL"; then
17355   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
17356 $as_echo "$OTOOL" >&6; }
17357 else
17358   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17359 $as_echo "no" >&6; }
17360 fi
17361 
17362 
17363   test -n "$OTOOL" && break
17364 done
17365 
17366     else
17367       # If it succeeded, then it was overridden by the user. We will use it
17368       # for the tool.
17369 
17370       # First remove it from the list of overridden variables, so we can test
17371       # for unknown variables in the end.
17372       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17373 
17374       # Check if the provided tool contains a complete path.
17375       tool_specified="$OTOOL"
17376       tool_basename="${tool_specified##*/}"
17377       if test "x$tool_basename" = "x$tool_specified"; then
17378         # A command without a complete path is provided, search $PATH.
17379         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OTOOL=$tool_basename" >&5
17380 $as_echo "$as_me: Will search for user supplied tool OTOOL=$tool_basename" >&6;}
17381         # Extract the first word of "$tool_basename", so it can be a program name with args.
17382 set dummy $tool_basename; ac_word=$2
17383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17384 $as_echo_n "checking for $ac_word... " >&6; }
17385 if ${ac_cv_path_OTOOL+:} false; then :
17386   $as_echo_n "(cached) " >&6
17387 else
17388   case $OTOOL in
17389   [\\/]* | ?:[\\/]*)
17390   ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path.
17391   ;;
17392   *)
17393   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17394 for as_dir in $PATH
17395 do
17396   IFS=$as_save_IFS
17397   test -z "$as_dir" && as_dir=.
17398     for ac_exec_ext in '' $ac_executable_extensions; do
17399   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17400     ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext"
17401     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17402     break 2
17403   fi
17404 done
17405   done
17406 IFS=$as_save_IFS
17407 
17408   ;;
17409 esac
17410 fi
17411 OTOOL=$ac_cv_path_OTOOL
17412 if test -n "$OTOOL"; then
17413   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
17414 $as_echo "$OTOOL" >&6; }
17415 else
17416   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17417 $as_echo "no" >&6; }
17418 fi
17419 
17420 
17421         if test "x$OTOOL" = x; then
17422           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17423         fi
17424       else
17425         # Otherwise we believe it is a complete path. Use it as it is.
17426         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OTOOL=$tool_specified" >&5
17427 $as_echo "$as_me: Will use user supplied tool OTOOL=$tool_specified" >&6;}
17428         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5
17429 $as_echo_n "checking for OTOOL... " >&6; }
17430         if test ! -x "$tool_specified"; then
17431           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17432 $as_echo "not found" >&6; }
17433           as_fn_error $? "User supplied tool OTOOL=$tool_specified does not exist or is not executable" "$LINENO" 5
17434         fi
17435         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17436 $as_echo "$tool_specified" >&6; }
17437       fi
17438     fi
17439   fi
17440 
17441 
17442   if test "x$OTOOL" = "x"; then
17443     OTOOL="true"
17444   fi
17445 
17446 
17447   # Publish this variable in the help.
17448 
17449 
17450   if test "x$READELF" = x; then
17451     # The variable is not set by user, try to locate tool using the code snippet
17452     for ac_prog in greadelf readelf
17453 do
17454   # Extract the first word of "$ac_prog", so it can be a program name with args.
17455 set dummy $ac_prog; ac_word=$2
17456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17457 $as_echo_n "checking for $ac_word... " >&6; }
17458 if ${ac_cv_path_READELF+:} false; then :
17459   $as_echo_n "(cached) " >&6
17460 else
17461   case $READELF in
17462   [\\/]* | ?:[\\/]*)
17463   ac_cv_path_READELF="$READELF" # Let the user override the test with a path.
17464   ;;
17465   *)
17466   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17467 for as_dir in $PATH
17468 do
17469   IFS=$as_save_IFS
17470   test -z "$as_dir" && as_dir=.
17471     for ac_exec_ext in '' $ac_executable_extensions; do
17472   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17473     ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext"
17474     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17475     break 2
17476   fi
17477 done
17478   done
17479 IFS=$as_save_IFS
17480 
17481   ;;
17482 esac
17483 fi
17484 READELF=$ac_cv_path_READELF
17485 if test -n "$READELF"; then
17486   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
17487 $as_echo "$READELF" >&6; }
17488 else
17489   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17490 $as_echo "no" >&6; }
17491 fi
17492 
17493 
17494   test -n "$READELF" && break
17495 done
17496 
17497   else
17498     # The variable is set, but is it from the command line or the environment?
17499 
17500     # Try to remove the string !READELF! from our list.
17501     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READELF!/}
17502     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17503       # If it failed, the variable was not from the command line. Ignore it,
17504       # but warn the user (except for BASH, which is always set by the calling BASH).
17505       if test "xREADELF" != xBASH; then
17506         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&5
17507 $as_echo "$as_me: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&2;}
17508       fi
17509       # Try to locate tool using the code snippet
17510       for ac_prog in greadelf readelf
17511 do
17512   # Extract the first word of "$ac_prog", so it can be a program name with args.
17513 set dummy $ac_prog; ac_word=$2
17514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17515 $as_echo_n "checking for $ac_word... " >&6; }
17516 if ${ac_cv_path_READELF+:} false; then :
17517   $as_echo_n "(cached) " >&6
17518 else
17519   case $READELF in
17520   [\\/]* | ?:[\\/]*)
17521   ac_cv_path_READELF="$READELF" # Let the user override the test with a path.
17522   ;;
17523   *)
17524   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17525 for as_dir in $PATH
17526 do
17527   IFS=$as_save_IFS
17528   test -z "$as_dir" && as_dir=.
17529     for ac_exec_ext in '' $ac_executable_extensions; do
17530   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17531     ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext"
17532     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17533     break 2
17534   fi
17535 done
17536   done
17537 IFS=$as_save_IFS
17538 
17539   ;;
17540 esac
17541 fi
17542 READELF=$ac_cv_path_READELF
17543 if test -n "$READELF"; then
17544   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
17545 $as_echo "$READELF" >&6; }
17546 else
17547   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17548 $as_echo "no" >&6; }
17549 fi
17550 
17551 
17552   test -n "$READELF" && break
17553 done
17554 
17555     else
17556       # If it succeeded, then it was overridden by the user. We will use it
17557       # for the tool.
17558 
17559       # First remove it from the list of overridden variables, so we can test
17560       # for unknown variables in the end.
17561       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17562 
17563       # Check if the provided tool contains a complete path.
17564       tool_specified="$READELF"
17565       tool_basename="${tool_specified##*/}"
17566       if test "x$tool_basename" = "x$tool_specified"; then
17567         # A command without a complete path is provided, search $PATH.
17568         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READELF=$tool_basename" >&5
17569 $as_echo "$as_me: Will search for user supplied tool READELF=$tool_basename" >&6;}
17570         # Extract the first word of "$tool_basename", so it can be a program name with args.
17571 set dummy $tool_basename; ac_word=$2
17572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17573 $as_echo_n "checking for $ac_word... " >&6; }
17574 if ${ac_cv_path_READELF+:} false; then :
17575   $as_echo_n "(cached) " >&6
17576 else
17577   case $READELF in
17578   [\\/]* | ?:[\\/]*)
17579   ac_cv_path_READELF="$READELF" # Let the user override the test with a path.
17580   ;;
17581   *)
17582   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17583 for as_dir in $PATH
17584 do
17585   IFS=$as_save_IFS
17586   test -z "$as_dir" && as_dir=.
17587     for ac_exec_ext in '' $ac_executable_extensions; do
17588   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17589     ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext"
17590     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17591     break 2
17592   fi
17593 done
17594   done
17595 IFS=$as_save_IFS
17596 
17597   ;;
17598 esac
17599 fi
17600 READELF=$ac_cv_path_READELF
17601 if test -n "$READELF"; then
17602   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
17603 $as_echo "$READELF" >&6; }
17604 else
17605   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17606 $as_echo "no" >&6; }
17607 fi
17608 
17609 
17610         if test "x$READELF" = x; then
17611           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17612         fi
17613       else
17614         # Otherwise we believe it is a complete path. Use it as it is.
17615         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READELF=$tool_specified" >&5
17616 $as_echo "$as_me: Will use user supplied tool READELF=$tool_specified" >&6;}
17617         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5
17618 $as_echo_n "checking for READELF... " >&6; }
17619         if test ! -x "$tool_specified"; then
17620           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17621 $as_echo "not found" >&6; }
17622           as_fn_error $? "User supplied tool READELF=$tool_specified does not exist or is not executable" "$LINENO" 5
17623         fi
17624         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17625 $as_echo "$tool_specified" >&6; }
17626       fi
17627     fi
17628   fi
17629 
17630 
17631 
17632 
17633   # Publish this variable in the help.
17634 
17635 
17636   if test "x$HG" = x; then
17637     # The variable is not set by user, try to locate tool using the code snippet
17638     for ac_prog in hg
17639 do
17640   # Extract the first word of "$ac_prog", so it can be a program name with args.
17641 set dummy $ac_prog; ac_word=$2
17642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17643 $as_echo_n "checking for $ac_word... " >&6; }
17644 if ${ac_cv_path_HG+:} false; then :
17645   $as_echo_n "(cached) " >&6
17646 else
17647   case $HG in
17648   [\\/]* | ?:[\\/]*)
17649   ac_cv_path_HG="$HG" # Let the user override the test with a path.
17650   ;;
17651   *)
17652   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17653 for as_dir in $PATH
17654 do
17655   IFS=$as_save_IFS
17656   test -z "$as_dir" && as_dir=.
17657     for ac_exec_ext in '' $ac_executable_extensions; do
17658   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17659     ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext"
17660     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17661     break 2
17662   fi
17663 done
17664   done
17665 IFS=$as_save_IFS
17666 
17667   ;;
17668 esac
17669 fi
17670 HG=$ac_cv_path_HG
17671 if test -n "$HG"; then
17672   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5
17673 $as_echo "$HG" >&6; }
17674 else
17675   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17676 $as_echo "no" >&6; }
17677 fi
17678 
17679 
17680   test -n "$HG" && break
17681 done
17682 
17683   else
17684     # The variable is set, but is it from the command line or the environment?
17685 
17686     # Try to remove the string !HG! from our list.
17687     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HG!/}
17688     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17689       # If it failed, the variable was not from the command line. Ignore it,
17690       # but warn the user (except for BASH, which is always set by the calling BASH).
17691       if test "xHG" != xBASH; then
17692         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&5
17693 $as_echo "$as_me: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&2;}
17694       fi
17695       # Try to locate tool using the code snippet
17696       for ac_prog in hg
17697 do
17698   # Extract the first word of "$ac_prog", so it can be a program name with args.
17699 set dummy $ac_prog; ac_word=$2
17700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17701 $as_echo_n "checking for $ac_word... " >&6; }
17702 if ${ac_cv_path_HG+:} false; then :
17703   $as_echo_n "(cached) " >&6
17704 else
17705   case $HG in
17706   [\\/]* | ?:[\\/]*)
17707   ac_cv_path_HG="$HG" # Let the user override the test with a path.
17708   ;;
17709   *)
17710   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17711 for as_dir in $PATH
17712 do
17713   IFS=$as_save_IFS
17714   test -z "$as_dir" && as_dir=.
17715     for ac_exec_ext in '' $ac_executable_extensions; do
17716   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17717     ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext"
17718     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17719     break 2
17720   fi
17721 done
17722   done
17723 IFS=$as_save_IFS
17724 
17725   ;;
17726 esac
17727 fi
17728 HG=$ac_cv_path_HG
17729 if test -n "$HG"; then
17730   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5
17731 $as_echo "$HG" >&6; }
17732 else
17733   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17734 $as_echo "no" >&6; }
17735 fi
17736 
17737 
17738   test -n "$HG" && break
17739 done
17740 
17741     else
17742       # If it succeeded, then it was overridden by the user. We will use it
17743       # for the tool.
17744 
17745       # First remove it from the list of overridden variables, so we can test
17746       # for unknown variables in the end.
17747       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17748 
17749       # Check if the provided tool contains a complete path.
17750       tool_specified="$HG"
17751       tool_basename="${tool_specified##*/}"
17752       if test "x$tool_basename" = "x$tool_specified"; then
17753         # A command without a complete path is provided, search $PATH.
17754         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HG=$tool_basename" >&5
17755 $as_echo "$as_me: Will search for user supplied tool HG=$tool_basename" >&6;}
17756         # Extract the first word of "$tool_basename", so it can be a program name with args.
17757 set dummy $tool_basename; ac_word=$2
17758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17759 $as_echo_n "checking for $ac_word... " >&6; }
17760 if ${ac_cv_path_HG+:} false; then :
17761   $as_echo_n "(cached) " >&6
17762 else
17763   case $HG in
17764   [\\/]* | ?:[\\/]*)
17765   ac_cv_path_HG="$HG" # Let the user override the test with a path.
17766   ;;
17767   *)
17768   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17769 for as_dir in $PATH
17770 do
17771   IFS=$as_save_IFS
17772   test -z "$as_dir" && as_dir=.
17773     for ac_exec_ext in '' $ac_executable_extensions; do
17774   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17775     ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext"
17776     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17777     break 2
17778   fi
17779 done
17780   done
17781 IFS=$as_save_IFS
17782 
17783   ;;
17784 esac
17785 fi
17786 HG=$ac_cv_path_HG
17787 if test -n "$HG"; then
17788   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5
17789 $as_echo "$HG" >&6; }
17790 else
17791   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17792 $as_echo "no" >&6; }
17793 fi
17794 
17795 
17796         if test "x$HG" = x; then
17797           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17798         fi
17799       else
17800         # Otherwise we believe it is a complete path. Use it as it is.
17801         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HG=$tool_specified" >&5
17802 $as_echo "$as_me: Will use user supplied tool HG=$tool_specified" >&6;}
17803         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5
17804 $as_echo_n "checking for HG... " >&6; }
17805         if test ! -x "$tool_specified"; then
17806           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17807 $as_echo "not found" >&6; }
17808           as_fn_error $? "User supplied tool HG=$tool_specified does not exist or is not executable" "$LINENO" 5
17809         fi
17810         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17811 $as_echo "$tool_specified" >&6; }
17812       fi
17813     fi
17814   fi
17815 
17816 
17817 
17818 
17819   # Publish this variable in the help.
17820 
17821 
17822   if test "x$STAT" = x; then
17823     # The variable is not set by user, try to locate tool using the code snippet
17824     for ac_prog in stat
17825 do
17826   # Extract the first word of "$ac_prog", so it can be a program name with args.
17827 set dummy $ac_prog; ac_word=$2
17828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17829 $as_echo_n "checking for $ac_word... " >&6; }
17830 if ${ac_cv_path_STAT+:} false; then :
17831   $as_echo_n "(cached) " >&6
17832 else
17833   case $STAT in
17834   [\\/]* | ?:[\\/]*)
17835   ac_cv_path_STAT="$STAT" # Let the user override the test with a path.
17836   ;;
17837   *)
17838   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17839 for as_dir in $PATH
17840 do
17841   IFS=$as_save_IFS
17842   test -z "$as_dir" && as_dir=.
17843     for ac_exec_ext in '' $ac_executable_extensions; do
17844   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17845     ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext"
17846     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17847     break 2
17848   fi
17849 done
17850   done
17851 IFS=$as_save_IFS
17852 
17853   ;;
17854 esac
17855 fi
17856 STAT=$ac_cv_path_STAT
17857 if test -n "$STAT"; then
17858   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5
17859 $as_echo "$STAT" >&6; }
17860 else
17861   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17862 $as_echo "no" >&6; }
17863 fi
17864 
17865 
17866   test -n "$STAT" && break
17867 done
17868 
17869   else
17870     # The variable is set, but is it from the command line or the environment?
17871 
17872     # Try to remove the string !STAT! from our list.
17873     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STAT!/}
17874     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17875       # If it failed, the variable was not from the command line. Ignore it,
17876       # but warn the user (except for BASH, which is always set by the calling BASH).
17877       if test "xSTAT" != xBASH; then
17878         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&5
17879 $as_echo "$as_me: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&2;}
17880       fi
17881       # Try to locate tool using the code snippet
17882       for ac_prog in stat
17883 do
17884   # Extract the first word of "$ac_prog", so it can be a program name with args.
17885 set dummy $ac_prog; ac_word=$2
17886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17887 $as_echo_n "checking for $ac_word... " >&6; }
17888 if ${ac_cv_path_STAT+:} false; then :
17889   $as_echo_n "(cached) " >&6
17890 else
17891   case $STAT in
17892   [\\/]* | ?:[\\/]*)
17893   ac_cv_path_STAT="$STAT" # Let the user override the test with a path.
17894   ;;
17895   *)
17896   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17897 for as_dir in $PATH
17898 do
17899   IFS=$as_save_IFS
17900   test -z "$as_dir" && as_dir=.
17901     for ac_exec_ext in '' $ac_executable_extensions; do
17902   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17903     ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext"
17904     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17905     break 2
17906   fi
17907 done
17908   done
17909 IFS=$as_save_IFS
17910 
17911   ;;
17912 esac
17913 fi
17914 STAT=$ac_cv_path_STAT
17915 if test -n "$STAT"; then
17916   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5
17917 $as_echo "$STAT" >&6; }
17918 else
17919   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17920 $as_echo "no" >&6; }
17921 fi
17922 
17923 
17924   test -n "$STAT" && break
17925 done
17926 
17927     else
17928       # If it succeeded, then it was overridden by the user. We will use it
17929       # for the tool.
17930 
17931       # First remove it from the list of overridden variables, so we can test
17932       # for unknown variables in the end.
17933       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17934 
17935       # Check if the provided tool contains a complete path.
17936       tool_specified="$STAT"
17937       tool_basename="${tool_specified##*/}"
17938       if test "x$tool_basename" = "x$tool_specified"; then
17939         # A command without a complete path is provided, search $PATH.
17940         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STAT=$tool_basename" >&5
17941 $as_echo "$as_me: Will search for user supplied tool STAT=$tool_basename" >&6;}
17942         # Extract the first word of "$tool_basename", so it can be a program name with args.
17943 set dummy $tool_basename; ac_word=$2
17944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17945 $as_echo_n "checking for $ac_word... " >&6; }
17946 if ${ac_cv_path_STAT+:} false; then :
17947   $as_echo_n "(cached) " >&6
17948 else
17949   case $STAT in
17950   [\\/]* | ?:[\\/]*)
17951   ac_cv_path_STAT="$STAT" # Let the user override the test with a path.
17952   ;;
17953   *)
17954   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17955 for as_dir in $PATH
17956 do
17957   IFS=$as_save_IFS
17958   test -z "$as_dir" && as_dir=.
17959     for ac_exec_ext in '' $ac_executable_extensions; do
17960   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17961     ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext"
17962     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17963     break 2
17964   fi
17965 done
17966   done
17967 IFS=$as_save_IFS
17968 
17969   ;;
17970 esac
17971 fi
17972 STAT=$ac_cv_path_STAT
17973 if test -n "$STAT"; then
17974   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5
17975 $as_echo "$STAT" >&6; }
17976 else
17977   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17978 $as_echo "no" >&6; }
17979 fi
17980 
17981 
17982         if test "x$STAT" = x; then
17983           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17984         fi
17985       else
17986         # Otherwise we believe it is a complete path. Use it as it is.
17987         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STAT=$tool_specified" >&5
17988 $as_echo "$as_me: Will use user supplied tool STAT=$tool_specified" >&6;}
17989         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5
17990 $as_echo_n "checking for STAT... " >&6; }
17991         if test ! -x "$tool_specified"; then
17992           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17993 $as_echo "not found" >&6; }
17994           as_fn_error $? "User supplied tool STAT=$tool_specified does not exist or is not executable" "$LINENO" 5
17995         fi
17996         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17997 $as_echo "$tool_specified" >&6; }
17998       fi
17999     fi
18000   fi
18001 
18002 
18003 
18004 
18005   # Publish this variable in the help.
18006 
18007 
18008   if test "x$TIME" = x; then
18009     # The variable is not set by user, try to locate tool using the code snippet
18010     for ac_prog in time
18011 do
18012   # Extract the first word of "$ac_prog", so it can be a program name with args.
18013 set dummy $ac_prog; ac_word=$2
18014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18015 $as_echo_n "checking for $ac_word... " >&6; }
18016 if ${ac_cv_path_TIME+:} false; then :
18017   $as_echo_n "(cached) " >&6
18018 else
18019   case $TIME in
18020   [\\/]* | ?:[\\/]*)
18021   ac_cv_path_TIME="$TIME" # Let the user override the test with a path.
18022   ;;
18023   *)
18024   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18025 for as_dir in $PATH
18026 do
18027   IFS=$as_save_IFS
18028   test -z "$as_dir" && as_dir=.
18029     for ac_exec_ext in '' $ac_executable_extensions; do
18030   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18031     ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext"
18032     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18033     break 2
18034   fi
18035 done
18036   done
18037 IFS=$as_save_IFS
18038 
18039   ;;
18040 esac
18041 fi
18042 TIME=$ac_cv_path_TIME
18043 if test -n "$TIME"; then
18044   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5
18045 $as_echo "$TIME" >&6; }
18046 else
18047   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18048 $as_echo "no" >&6; }
18049 fi
18050 
18051 
18052   test -n "$TIME" && break
18053 done
18054 
18055   else
18056     # The variable is set, but is it from the command line or the environment?
18057 
18058     # Try to remove the string !TIME! from our list.
18059     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TIME!/}
18060     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18061       # If it failed, the variable was not from the command line. Ignore it,
18062       # but warn the user (except for BASH, which is always set by the calling BASH).
18063       if test "xTIME" != xBASH; then
18064         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&5
18065 $as_echo "$as_me: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&2;}
18066       fi
18067       # Try to locate tool using the code snippet
18068       for ac_prog in time
18069 do
18070   # Extract the first word of "$ac_prog", so it can be a program name with args.
18071 set dummy $ac_prog; ac_word=$2
18072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18073 $as_echo_n "checking for $ac_word... " >&6; }
18074 if ${ac_cv_path_TIME+:} false; then :
18075   $as_echo_n "(cached) " >&6
18076 else
18077   case $TIME in
18078   [\\/]* | ?:[\\/]*)
18079   ac_cv_path_TIME="$TIME" # Let the user override the test with a path.
18080   ;;
18081   *)
18082   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18083 for as_dir in $PATH
18084 do
18085   IFS=$as_save_IFS
18086   test -z "$as_dir" && as_dir=.
18087     for ac_exec_ext in '' $ac_executable_extensions; do
18088   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18089     ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext"
18090     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18091     break 2
18092   fi
18093 done
18094   done
18095 IFS=$as_save_IFS
18096 
18097   ;;
18098 esac
18099 fi
18100 TIME=$ac_cv_path_TIME
18101 if test -n "$TIME"; then
18102   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5
18103 $as_echo "$TIME" >&6; }
18104 else
18105   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18106 $as_echo "no" >&6; }
18107 fi
18108 
18109 
18110   test -n "$TIME" && break
18111 done
18112 
18113     else
18114       # If it succeeded, then it was overridden by the user. We will use it
18115       # for the tool.
18116 
18117       # First remove it from the list of overridden variables, so we can test
18118       # for unknown variables in the end.
18119       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18120 
18121       # Check if the provided tool contains a complete path.
18122       tool_specified="$TIME"
18123       tool_basename="${tool_specified##*/}"
18124       if test "x$tool_basename" = "x$tool_specified"; then
18125         # A command without a complete path is provided, search $PATH.
18126         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TIME=$tool_basename" >&5
18127 $as_echo "$as_me: Will search for user supplied tool TIME=$tool_basename" >&6;}
18128         # Extract the first word of "$tool_basename", so it can be a program name with args.
18129 set dummy $tool_basename; ac_word=$2
18130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18131 $as_echo_n "checking for $ac_word... " >&6; }
18132 if ${ac_cv_path_TIME+:} false; then :
18133   $as_echo_n "(cached) " >&6
18134 else
18135   case $TIME in
18136   [\\/]* | ?:[\\/]*)
18137   ac_cv_path_TIME="$TIME" # Let the user override the test with a path.
18138   ;;
18139   *)
18140   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18141 for as_dir in $PATH
18142 do
18143   IFS=$as_save_IFS
18144   test -z "$as_dir" && as_dir=.
18145     for ac_exec_ext in '' $ac_executable_extensions; do
18146   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18147     ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext"
18148     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18149     break 2
18150   fi
18151 done
18152   done
18153 IFS=$as_save_IFS
18154 
18155   ;;
18156 esac
18157 fi
18158 TIME=$ac_cv_path_TIME
18159 if test -n "$TIME"; then
18160   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5
18161 $as_echo "$TIME" >&6; }
18162 else
18163   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18164 $as_echo "no" >&6; }
18165 fi
18166 
18167 
18168         if test "x$TIME" = x; then
18169           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18170         fi
18171       else
18172         # Otherwise we believe it is a complete path. Use it as it is.
18173         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TIME=$tool_specified" >&5
18174 $as_echo "$as_me: Will use user supplied tool TIME=$tool_specified" >&6;}
18175         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5
18176 $as_echo_n "checking for TIME... " >&6; }
18177         if test ! -x "$tool_specified"; then
18178           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18179 $as_echo "not found" >&6; }
18180           as_fn_error $? "User supplied tool TIME=$tool_specified does not exist or is not executable" "$LINENO" 5
18181         fi
18182         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18183 $as_echo "$tool_specified" >&6; }
18184       fi
18185     fi
18186   fi
18187 
18188 
18189   # Check if it's GNU time
18190   IS_GNU_TIME=`$TIME --version 2>&1 | $GREP 'GNU time'`
18191   if test "x$IS_GNU_TIME" != x; then
18192     IS_GNU_TIME=yes
18193   else
18194     IS_GNU_TIME=no
18195   fi
18196 
18197 
18198   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
18199 
18200 
18201 
18202   # Publish this variable in the help.
18203 
18204 
18205   if test "x$COMM" = x; then
18206     # The variable is not set by user, try to locate tool using the code snippet
18207     for ac_prog in comm
18208 do
18209   # Extract the first word of "$ac_prog", so it can be a program name with args.
18210 set dummy $ac_prog; ac_word=$2
18211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18212 $as_echo_n "checking for $ac_word... " >&6; }
18213 if ${ac_cv_path_COMM+:} false; then :
18214   $as_echo_n "(cached) " >&6
18215 else
18216   case $COMM in
18217   [\\/]* | ?:[\\/]*)
18218   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
18219   ;;
18220   *)
18221   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18222 for as_dir in $PATH
18223 do
18224   IFS=$as_save_IFS
18225   test -z "$as_dir" && as_dir=.
18226     for ac_exec_ext in '' $ac_executable_extensions; do
18227   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18228     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
18229     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18230     break 2
18231   fi
18232 done
18233   done
18234 IFS=$as_save_IFS
18235 
18236   ;;
18237 esac
18238 fi
18239 COMM=$ac_cv_path_COMM
18240 if test -n "$COMM"; then
18241   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
18242 $as_echo "$COMM" >&6; }
18243 else
18244   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18245 $as_echo "no" >&6; }
18246 fi
18247 
18248 
18249   test -n "$COMM" && break
18250 done
18251 
18252   else
18253     # The variable is set, but is it from the command line or the environment?
18254 
18255     # Try to remove the string !COMM! from our list.
18256     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/}
18257     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18258       # If it failed, the variable was not from the command line. Ignore it,
18259       # but warn the user (except for BASH, which is always set by the calling BASH).
18260       if test "xCOMM" != xBASH; then
18261         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5
18262 $as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;}
18263       fi
18264       # Try to locate tool using the code snippet
18265       for ac_prog in comm
18266 do
18267   # Extract the first word of "$ac_prog", so it can be a program name with args.
18268 set dummy $ac_prog; ac_word=$2
18269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18270 $as_echo_n "checking for $ac_word... " >&6; }
18271 if ${ac_cv_path_COMM+:} false; then :
18272   $as_echo_n "(cached) " >&6
18273 else
18274   case $COMM in
18275   [\\/]* | ?:[\\/]*)
18276   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
18277   ;;
18278   *)
18279   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18280 for as_dir in $PATH
18281 do
18282   IFS=$as_save_IFS
18283   test -z "$as_dir" && as_dir=.
18284     for ac_exec_ext in '' $ac_executable_extensions; do
18285   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18286     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
18287     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18288     break 2
18289   fi
18290 done
18291   done
18292 IFS=$as_save_IFS
18293 
18294   ;;
18295 esac
18296 fi
18297 COMM=$ac_cv_path_COMM
18298 if test -n "$COMM"; then
18299   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
18300 $as_echo "$COMM" >&6; }
18301 else
18302   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18303 $as_echo "no" >&6; }
18304 fi
18305 
18306 
18307   test -n "$COMM" && break
18308 done
18309 
18310     else
18311       # If it succeeded, then it was overridden by the user. We will use it
18312       # for the tool.
18313 
18314       # First remove it from the list of overridden variables, so we can test
18315       # for unknown variables in the end.
18316       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18317 
18318       # Check if the provided tool contains a complete path.
18319       tool_specified="$COMM"
18320       tool_basename="${tool_specified##*/}"
18321       if test "x$tool_basename" = "x$tool_specified"; then
18322         # A command without a complete path is provided, search $PATH.
18323         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5
18324 $as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;}
18325         # Extract the first word of "$tool_basename", so it can be a program name with args.
18326 set dummy $tool_basename; ac_word=$2
18327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18328 $as_echo_n "checking for $ac_word... " >&6; }
18329 if ${ac_cv_path_COMM+:} false; then :
18330   $as_echo_n "(cached) " >&6
18331 else
18332   case $COMM in
18333   [\\/]* | ?:[\\/]*)
18334   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
18335   ;;
18336   *)
18337   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18338 for as_dir in $PATH
18339 do
18340   IFS=$as_save_IFS
18341   test -z "$as_dir" && as_dir=.
18342     for ac_exec_ext in '' $ac_executable_extensions; do
18343   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18344     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
18345     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18346     break 2
18347   fi
18348 done
18349   done
18350 IFS=$as_save_IFS
18351 
18352   ;;
18353 esac
18354 fi
18355 COMM=$ac_cv_path_COMM
18356 if test -n "$COMM"; then
18357   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
18358 $as_echo "$COMM" >&6; }
18359 else
18360   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18361 $as_echo "no" >&6; }
18362 fi
18363 
18364 
18365         if test "x$COMM" = x; then
18366           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18367         fi
18368       else
18369         # Otherwise we believe it is a complete path. Use it as it is.
18370         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5
18371 $as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;}
18372         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5
18373 $as_echo_n "checking for COMM... " >&6; }
18374         if test ! -x "$tool_specified"; then
18375           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18376 $as_echo "not found" >&6; }
18377           as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5
18378         fi
18379         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18380 $as_echo "$tool_specified" >&6; }
18381       fi
18382     fi
18383   fi
18384 
18385 
18386 
18387   if test "x$COMM" = x; then
18388     as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5
18389   fi
18390 
18391 
18392   fi
18393 
18394   if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
18395 
18396 
18397 
18398   # Publish this variable in the help.
18399 
18400 
18401   if test "x$DSYMUTIL" = x; then
18402     # The variable is not set by user, try to locate tool using the code snippet
18403     for ac_prog in dsymutil
18404 do
18405   # Extract the first word of "$ac_prog", so it can be a program name with args.
18406 set dummy $ac_prog; ac_word=$2
18407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18408 $as_echo_n "checking for $ac_word... " >&6; }
18409 if ${ac_cv_path_DSYMUTIL+:} false; then :
18410   $as_echo_n "(cached) " >&6
18411 else
18412   case $DSYMUTIL in
18413   [\\/]* | ?:[\\/]*)
18414   ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path.
18415   ;;
18416   *)
18417   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18418 for as_dir in $PATH
18419 do
18420   IFS=$as_save_IFS
18421   test -z "$as_dir" && as_dir=.
18422     for ac_exec_ext in '' $ac_executable_extensions; do
18423   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18424     ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext"
18425     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18426     break 2
18427   fi
18428 done
18429   done
18430 IFS=$as_save_IFS
18431 
18432   ;;
18433 esac
18434 fi
18435 DSYMUTIL=$ac_cv_path_DSYMUTIL
18436 if test -n "$DSYMUTIL"; then
18437   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
18438 $as_echo "$DSYMUTIL" >&6; }
18439 else
18440   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18441 $as_echo "no" >&6; }
18442 fi
18443 
18444 
18445   test -n "$DSYMUTIL" && break
18446 done
18447 
18448   else
18449     # The variable is set, but is it from the command line or the environment?
18450 
18451     # Try to remove the string !DSYMUTIL! from our list.
18452     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DSYMUTIL!/}
18453     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18454       # If it failed, the variable was not from the command line. Ignore it,
18455       # but warn the user (except for BASH, which is always set by the calling BASH).
18456       if test "xDSYMUTIL" != xBASH; then
18457         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&5
18458 $as_echo "$as_me: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&2;}
18459       fi
18460       # Try to locate tool using the code snippet
18461       for ac_prog in dsymutil
18462 do
18463   # Extract the first word of "$ac_prog", so it can be a program name with args.
18464 set dummy $ac_prog; ac_word=$2
18465 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18466 $as_echo_n "checking for $ac_word... " >&6; }
18467 if ${ac_cv_path_DSYMUTIL+:} false; then :
18468   $as_echo_n "(cached) " >&6
18469 else
18470   case $DSYMUTIL in
18471   [\\/]* | ?:[\\/]*)
18472   ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path.
18473   ;;
18474   *)
18475   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18476 for as_dir in $PATH
18477 do
18478   IFS=$as_save_IFS
18479   test -z "$as_dir" && as_dir=.
18480     for ac_exec_ext in '' $ac_executable_extensions; do
18481   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18482     ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext"
18483     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18484     break 2
18485   fi
18486 done
18487   done
18488 IFS=$as_save_IFS
18489 
18490   ;;
18491 esac
18492 fi
18493 DSYMUTIL=$ac_cv_path_DSYMUTIL
18494 if test -n "$DSYMUTIL"; then
18495   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
18496 $as_echo "$DSYMUTIL" >&6; }
18497 else
18498   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18499 $as_echo "no" >&6; }
18500 fi
18501 
18502 
18503   test -n "$DSYMUTIL" && break
18504 done
18505 
18506     else
18507       # If it succeeded, then it was overridden by the user. We will use it
18508       # for the tool.
18509 
18510       # First remove it from the list of overridden variables, so we can test
18511       # for unknown variables in the end.
18512       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18513 
18514       # Check if the provided tool contains a complete path.
18515       tool_specified="$DSYMUTIL"
18516       tool_basename="${tool_specified##*/}"
18517       if test "x$tool_basename" = "x$tool_specified"; then
18518         # A command without a complete path is provided, search $PATH.
18519         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DSYMUTIL=$tool_basename" >&5
18520 $as_echo "$as_me: Will search for user supplied tool DSYMUTIL=$tool_basename" >&6;}
18521         # Extract the first word of "$tool_basename", so it can be a program name with args.
18522 set dummy $tool_basename; ac_word=$2
18523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18524 $as_echo_n "checking for $ac_word... " >&6; }
18525 if ${ac_cv_path_DSYMUTIL+:} false; then :
18526   $as_echo_n "(cached) " >&6
18527 else
18528   case $DSYMUTIL in
18529   [\\/]* | ?:[\\/]*)
18530   ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path.
18531   ;;
18532   *)
18533   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18534 for as_dir in $PATH
18535 do
18536   IFS=$as_save_IFS
18537   test -z "$as_dir" && as_dir=.
18538     for ac_exec_ext in '' $ac_executable_extensions; do
18539   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18540     ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext"
18541     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18542     break 2
18543   fi
18544 done
18545   done
18546 IFS=$as_save_IFS
18547 
18548   ;;
18549 esac
18550 fi
18551 DSYMUTIL=$ac_cv_path_DSYMUTIL
18552 if test -n "$DSYMUTIL"; then
18553   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
18554 $as_echo "$DSYMUTIL" >&6; }
18555 else
18556   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18557 $as_echo "no" >&6; }
18558 fi
18559 
18560 
18561         if test "x$DSYMUTIL" = x; then
18562           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18563         fi
18564       else
18565         # Otherwise we believe it is a complete path. Use it as it is.
18566         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DSYMUTIL=$tool_specified" >&5
18567 $as_echo "$as_me: Will use user supplied tool DSYMUTIL=$tool_specified" >&6;}
18568         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5
18569 $as_echo_n "checking for DSYMUTIL... " >&6; }
18570         if test ! -x "$tool_specified"; then
18571           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18572 $as_echo "not found" >&6; }
18573           as_fn_error $? "User supplied tool DSYMUTIL=$tool_specified does not exist or is not executable" "$LINENO" 5
18574         fi
18575         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18576 $as_echo "$tool_specified" >&6; }
18577       fi
18578     fi
18579   fi
18580 
18581 
18582 
18583   if test "x$DSYMUTIL" = x; then
18584     as_fn_error $? "Could not find required tool for DSYMUTIL" "$LINENO" 5
18585   fi
18586 
18587 
18588 
18589 
18590 
18591   # Publish this variable in the help.
18592 
18593 
18594   if test "x$XATTR" = x; then
18595     # The variable is not set by user, try to locate tool using the code snippet
18596     for ac_prog in xattr
18597 do
18598   # Extract the first word of "$ac_prog", so it can be a program name with args.
18599 set dummy $ac_prog; ac_word=$2
18600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18601 $as_echo_n "checking for $ac_word... " >&6; }
18602 if ${ac_cv_path_XATTR+:} false; then :
18603   $as_echo_n "(cached) " >&6
18604 else
18605   case $XATTR in
18606   [\\/]* | ?:[\\/]*)
18607   ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path.
18608   ;;
18609   *)
18610   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18611 for as_dir in $PATH
18612 do
18613   IFS=$as_save_IFS
18614   test -z "$as_dir" && as_dir=.
18615     for ac_exec_ext in '' $ac_executable_extensions; do
18616   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18617     ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext"
18618     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18619     break 2
18620   fi
18621 done
18622   done
18623 IFS=$as_save_IFS
18624 
18625   ;;
18626 esac
18627 fi
18628 XATTR=$ac_cv_path_XATTR
18629 if test -n "$XATTR"; then
18630   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5
18631 $as_echo "$XATTR" >&6; }
18632 else
18633   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18634 $as_echo "no" >&6; }
18635 fi
18636 
18637 
18638   test -n "$XATTR" && break
18639 done
18640 
18641   else
18642     # The variable is set, but is it from the command line or the environment?
18643 
18644     # Try to remove the string !XATTR! from our list.
18645     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XATTR!/}
18646     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18647       # If it failed, the variable was not from the command line. Ignore it,
18648       # but warn the user (except for BASH, which is always set by the calling BASH).
18649       if test "xXATTR" != xBASH; then
18650         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&5
18651 $as_echo "$as_me: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&2;}
18652       fi
18653       # Try to locate tool using the code snippet
18654       for ac_prog in xattr
18655 do
18656   # Extract the first word of "$ac_prog", so it can be a program name with args.
18657 set dummy $ac_prog; ac_word=$2
18658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18659 $as_echo_n "checking for $ac_word... " >&6; }
18660 if ${ac_cv_path_XATTR+:} false; then :
18661   $as_echo_n "(cached) " >&6
18662 else
18663   case $XATTR in
18664   [\\/]* | ?:[\\/]*)
18665   ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path.
18666   ;;
18667   *)
18668   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18669 for as_dir in $PATH
18670 do
18671   IFS=$as_save_IFS
18672   test -z "$as_dir" && as_dir=.
18673     for ac_exec_ext in '' $ac_executable_extensions; do
18674   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18675     ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext"
18676     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18677     break 2
18678   fi
18679 done
18680   done
18681 IFS=$as_save_IFS
18682 
18683   ;;
18684 esac
18685 fi
18686 XATTR=$ac_cv_path_XATTR
18687 if test -n "$XATTR"; then
18688   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5
18689 $as_echo "$XATTR" >&6; }
18690 else
18691   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18692 $as_echo "no" >&6; }
18693 fi
18694 
18695 
18696   test -n "$XATTR" && break
18697 done
18698 
18699     else
18700       # If it succeeded, then it was overridden by the user. We will use it
18701       # for the tool.
18702 
18703       # First remove it from the list of overridden variables, so we can test
18704       # for unknown variables in the end.
18705       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18706 
18707       # Check if the provided tool contains a complete path.
18708       tool_specified="$XATTR"
18709       tool_basename="${tool_specified##*/}"
18710       if test "x$tool_basename" = "x$tool_specified"; then
18711         # A command without a complete path is provided, search $PATH.
18712         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XATTR=$tool_basename" >&5
18713 $as_echo "$as_me: Will search for user supplied tool XATTR=$tool_basename" >&6;}
18714         # Extract the first word of "$tool_basename", so it can be a program name with args.
18715 set dummy $tool_basename; ac_word=$2
18716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18717 $as_echo_n "checking for $ac_word... " >&6; }
18718 if ${ac_cv_path_XATTR+:} false; then :
18719   $as_echo_n "(cached) " >&6
18720 else
18721   case $XATTR in
18722   [\\/]* | ?:[\\/]*)
18723   ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path.
18724   ;;
18725   *)
18726   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18727 for as_dir in $PATH
18728 do
18729   IFS=$as_save_IFS
18730   test -z "$as_dir" && as_dir=.
18731     for ac_exec_ext in '' $ac_executable_extensions; do
18732   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18733     ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext"
18734     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18735     break 2
18736   fi
18737 done
18738   done
18739 IFS=$as_save_IFS
18740 
18741   ;;
18742 esac
18743 fi
18744 XATTR=$ac_cv_path_XATTR
18745 if test -n "$XATTR"; then
18746   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5
18747 $as_echo "$XATTR" >&6; }
18748 else
18749   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18750 $as_echo "no" >&6; }
18751 fi
18752 
18753 
18754         if test "x$XATTR" = x; then
18755           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18756         fi
18757       else
18758         # Otherwise we believe it is a complete path. Use it as it is.
18759         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XATTR=$tool_specified" >&5
18760 $as_echo "$as_me: Will use user supplied tool XATTR=$tool_specified" >&6;}
18761         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5
18762 $as_echo_n "checking for XATTR... " >&6; }
18763         if test ! -x "$tool_specified"; then
18764           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18765 $as_echo "not found" >&6; }
18766           as_fn_error $? "User supplied tool XATTR=$tool_specified does not exist or is not executable" "$LINENO" 5
18767         fi
18768         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18769 $as_echo "$tool_specified" >&6; }
18770       fi
18771     fi
18772   fi
18773 
18774 
18775 
18776   if test "x$XATTR" = x; then
18777     as_fn_error $? "Could not find required tool for XATTR" "$LINENO" 5
18778   fi
18779 
18780 
18781 
18782 
18783   # Publish this variable in the help.
18784 
18785 
18786   if test "x$CODESIGN" = x; then
18787     # The variable is not set by user, try to locate tool using the code snippet
18788     for ac_prog in codesign
18789 do
18790   # Extract the first word of "$ac_prog", so it can be a program name with args.
18791 set dummy $ac_prog; ac_word=$2
18792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18793 $as_echo_n "checking for $ac_word... " >&6; }
18794 if ${ac_cv_path_CODESIGN+:} false; then :
18795   $as_echo_n "(cached) " >&6
18796 else
18797   case $CODESIGN in
18798   [\\/]* | ?:[\\/]*)
18799   ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path.
18800   ;;
18801   *)
18802   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18803 for as_dir in $PATH
18804 do
18805   IFS=$as_save_IFS
18806   test -z "$as_dir" && as_dir=.
18807     for ac_exec_ext in '' $ac_executable_extensions; do
18808   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18809     ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext"
18810     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18811     break 2
18812   fi
18813 done
18814   done
18815 IFS=$as_save_IFS
18816 
18817   ;;
18818 esac
18819 fi
18820 CODESIGN=$ac_cv_path_CODESIGN
18821 if test -n "$CODESIGN"; then
18822   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5
18823 $as_echo "$CODESIGN" >&6; }
18824 else
18825   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18826 $as_echo "no" >&6; }
18827 fi
18828 
18829 
18830   test -n "$CODESIGN" && break
18831 done
18832 
18833   else
18834     # The variable is set, but is it from the command line or the environment?
18835 
18836     # Try to remove the string !CODESIGN! from our list.
18837     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CODESIGN!/}
18838     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18839       # If it failed, the variable was not from the command line. Ignore it,
18840       # but warn the user (except for BASH, which is always set by the calling BASH).
18841       if test "xCODESIGN" != xBASH; then
18842         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&5
18843 $as_echo "$as_me: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&2;}
18844       fi
18845       # Try to locate tool using the code snippet
18846       for ac_prog in codesign
18847 do
18848   # Extract the first word of "$ac_prog", so it can be a program name with args.
18849 set dummy $ac_prog; ac_word=$2
18850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18851 $as_echo_n "checking for $ac_word... " >&6; }
18852 if ${ac_cv_path_CODESIGN+:} false; then :
18853   $as_echo_n "(cached) " >&6
18854 else
18855   case $CODESIGN in
18856   [\\/]* | ?:[\\/]*)
18857   ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path.
18858   ;;
18859   *)
18860   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18861 for as_dir in $PATH
18862 do
18863   IFS=$as_save_IFS
18864   test -z "$as_dir" && as_dir=.
18865     for ac_exec_ext in '' $ac_executable_extensions; do
18866   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18867     ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext"
18868     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18869     break 2
18870   fi
18871 done
18872   done
18873 IFS=$as_save_IFS
18874 
18875   ;;
18876 esac
18877 fi
18878 CODESIGN=$ac_cv_path_CODESIGN
18879 if test -n "$CODESIGN"; then
18880   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5
18881 $as_echo "$CODESIGN" >&6; }
18882 else
18883   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18884 $as_echo "no" >&6; }
18885 fi
18886 
18887 
18888   test -n "$CODESIGN" && break
18889 done
18890 
18891     else
18892       # If it succeeded, then it was overridden by the user. We will use it
18893       # for the tool.
18894 
18895       # First remove it from the list of overridden variables, so we can test
18896       # for unknown variables in the end.
18897       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18898 
18899       # Check if the provided tool contains a complete path.
18900       tool_specified="$CODESIGN"
18901       tool_basename="${tool_specified##*/}"
18902       if test "x$tool_basename" = "x$tool_specified"; then
18903         # A command without a complete path is provided, search $PATH.
18904         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CODESIGN=$tool_basename" >&5
18905 $as_echo "$as_me: Will search for user supplied tool CODESIGN=$tool_basename" >&6;}
18906         # Extract the first word of "$tool_basename", so it can be a program name with args.
18907 set dummy $tool_basename; ac_word=$2
18908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18909 $as_echo_n "checking for $ac_word... " >&6; }
18910 if ${ac_cv_path_CODESIGN+:} false; then :
18911   $as_echo_n "(cached) " >&6
18912 else
18913   case $CODESIGN in
18914   [\\/]* | ?:[\\/]*)
18915   ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path.
18916   ;;
18917   *)
18918   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18919 for as_dir in $PATH
18920 do
18921   IFS=$as_save_IFS
18922   test -z "$as_dir" && as_dir=.
18923     for ac_exec_ext in '' $ac_executable_extensions; do
18924   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18925     ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext"
18926     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18927     break 2
18928   fi
18929 done
18930   done
18931 IFS=$as_save_IFS
18932 
18933   ;;
18934 esac
18935 fi
18936 CODESIGN=$ac_cv_path_CODESIGN
18937 if test -n "$CODESIGN"; then
18938   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5
18939 $as_echo "$CODESIGN" >&6; }
18940 else
18941   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18942 $as_echo "no" >&6; }
18943 fi
18944 
18945 
18946         if test "x$CODESIGN" = x; then
18947           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18948         fi
18949       else
18950         # Otherwise we believe it is a complete path. Use it as it is.
18951         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CODESIGN=$tool_specified" >&5
18952 $as_echo "$as_me: Will use user supplied tool CODESIGN=$tool_specified" >&6;}
18953         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5
18954 $as_echo_n "checking for CODESIGN... " >&6; }
18955         if test ! -x "$tool_specified"; then
18956           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18957 $as_echo "not found" >&6; }
18958           as_fn_error $? "User supplied tool CODESIGN=$tool_specified does not exist or is not executable" "$LINENO" 5
18959         fi
18960         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18961 $as_echo "$tool_specified" >&6; }
18962       fi
18963     fi
18964   fi
18965 
18966 
18967     if test "x$CODESIGN" != "x"; then
18968       # Verify that the openjdk_codesign certificate is present
18969       { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openjdk_codesign certificate is present" >&5
18970 $as_echo_n "checking if openjdk_codesign certificate is present... " >&6; }
18971       rm -f codesign-testfile
18972       touch codesign-testfile
18973       codesign -s openjdk_codesign codesign-testfile 2>&5 >&5 || CODESIGN=
18974       rm -f codesign-testfile
18975       if test "x$CODESIGN" = x; then
18976         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18977 $as_echo "no" >&6; }
18978       else
18979         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18980 $as_echo "yes" >&6; }
18981       fi
18982     fi
18983   fi
18984 
18985 
18986 # Check if pkg-config is available.
18987 
18988 
18989 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
18990         if test -n "$ac_tool_prefix"; then
18991   # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
18992 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
18993 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18994 $as_echo_n "checking for $ac_word... " >&6; }
18995 if ${ac_cv_path_PKG_CONFIG+:} false; then :
18996   $as_echo_n "(cached) " >&6
18997 else
18998   case $PKG_CONFIG in
18999   [\\/]* | ?:[\\/]*)
19000   ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
19001   ;;
19002   *)
19003   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19004 for as_dir in $PATH
19005 do
19006   IFS=$as_save_IFS
19007   test -z "$as_dir" && as_dir=.
19008     for ac_exec_ext in '' $ac_executable_extensions; do
19009   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19010     ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
19011     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19012     break 2
19013   fi
19014 done
19015   done
19016 IFS=$as_save_IFS
19017 
19018   ;;
19019 esac
19020 fi
19021 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
19022 if test -n "$PKG_CONFIG"; then
19023   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
19024 $as_echo "$PKG_CONFIG" >&6; }
19025 else
19026   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19027 $as_echo "no" >&6; }
19028 fi
19029 
19030 
19031 fi
19032 if test -z "$ac_cv_path_PKG_CONFIG"; then
19033   ac_pt_PKG_CONFIG=$PKG_CONFIG
19034   # Extract the first word of "pkg-config", so it can be a program name with args.
19035 set dummy pkg-config; ac_word=$2
19036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19037 $as_echo_n "checking for $ac_word... " >&6; }
19038 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
19039   $as_echo_n "(cached) " >&6
19040 else
19041   case $ac_pt_PKG_CONFIG in
19042   [\\/]* | ?:[\\/]*)
19043   ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
19044   ;;
19045   *)
19046   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19047 for as_dir in $PATH
19048 do
19049   IFS=$as_save_IFS
19050   test -z "$as_dir" && as_dir=.
19051     for ac_exec_ext in '' $ac_executable_extensions; do
19052   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19053     ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
19054     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19055     break 2
19056   fi
19057 done
19058   done
19059 IFS=$as_save_IFS
19060 
19061   ;;
19062 esac
19063 fi
19064 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
19065 if test -n "$ac_pt_PKG_CONFIG"; then
19066   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
19067 $as_echo "$ac_pt_PKG_CONFIG" >&6; }
19068 else
19069   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19070 $as_echo "no" >&6; }
19071 fi
19072 
19073   if test "x$ac_pt_PKG_CONFIG" = x; then
19074     PKG_CONFIG=""
19075   else
19076     case $cross_compiling:$ac_tool_warned in
19077 yes:)
19078 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19079 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19080 ac_tool_warned=yes ;;
19081 esac
19082     PKG_CONFIG=$ac_pt_PKG_CONFIG
19083   fi
19084 else
19085   PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
19086 fi
19087 
19088 fi
19089 if test -n "$PKG_CONFIG"; then
19090         _pkg_min_version=0.9.0
19091         { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
19092 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
19093         if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
19094                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19095 $as_echo "yes" >&6; }
19096         else
19097                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19098 $as_echo "no" >&6; }
19099                 PKG_CONFIG=""
19100         fi
19101 
19102 fi
19103 
19104 # After basic tools have been setup, we can check build os specific details.
19105 
19106   ###############################################################################
19107 
19108   # Note that this is the build platform OS version!
19109 
19110   OS_VERSION="`uname -r | ${SED} 's!\.! !g' | ${SED} 's!-! !g'`"
19111   OS_VERSION_MAJOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 1 -d ' '`"
19112   OS_VERSION_MINOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 2 -d ' '`"
19113   OS_VERSION_MICRO="`${ECHO} ${OS_VERSION} | ${CUT} -f 3 -d ' '`"
19114 
19115 
19116 
19117 
19118 
19119 # Setup builddeps, for automatic downloading of tools we need.
19120 # This is needed before we can call BDEPS_CHECK_MODULE, which is done in
19121 # boot-jdk setup, but we need to have basic tools setup first.
19122 
19123 
19124 # Check whether --with-builddeps-conf was given.
19125 if test "${with_builddeps_conf+set}" = set; then :
19126   withval=$with_builddeps_conf;
19127 fi
19128 
19129 
19130 
19131 # Check whether --with-builddeps-server was given.
19132 if test "${with_builddeps_server+set}" = set; then :
19133   withval=$with_builddeps_server;
19134 fi
19135 
19136 
19137 
19138 # Check whether --with-builddeps-dir was given.
19139 if test "${with_builddeps_dir+set}" = set; then :
19140   withval=$with_builddeps_dir;
19141 else
19142   with_builddeps_dir=/localhome/builddeps
19143 fi
19144 
19145 
19146 
19147 # Check whether --with-builddeps-group was given.
19148 if test "${with_builddeps_group+set}" = set; then :
19149   withval=$with_builddeps_group;
19150 fi
19151 
19152 
19153 
19154 
19155   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
19156     if test "x$with_builddeps_conf" != x; then
19157       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for supplied builddeps configuration file" >&5
19158 $as_echo_n "checking for supplied builddeps configuration file... " >&6; }
19159       builddepsfile=$with_builddeps_conf
19160       if test -s $builddepsfile; then
19161         . $builddepsfile
19162         { $as_echo "$as_me:${as_lineno-$LINENO}: result: loaded!" >&5
19163 $as_echo "loaded!" >&6; }
19164       else
19165         as_fn_error $? "The given builddeps conf file $with_builddeps_conf could not be loaded!" "$LINENO" 5
19166       fi
19167     else
19168       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builddeps.conf files in sources..." >&5
19169 $as_echo_n "checking for builddeps.conf files in sources...... " >&6; }
19170       builddepsfile=`mktemp`
19171       touch $builddepsfile
19172       # Put all found confs into a single file.
19173       find ${SRC_ROOT} -name builddeps.conf -exec cat \{\} \; >> $builddepsfile
19174       # Source the file to acquire the variables
19175       if test -s $builddepsfile; then
19176         . $builddepsfile
19177         { $as_echo "$as_me:${as_lineno-$LINENO}: result: found at least one!" >&5
19178 $as_echo "found at least one!" >&6; }
19179       else
19180         as_fn_error $? "Could not find any builddeps.conf at all!" "$LINENO" 5
19181       fi
19182     fi
19183     # Create build and target names that use _ instead of "-" and ".".
19184     # This is necessary to use them in variable names.
19185     build_var=`echo ${OPENJDK_BUILD_AUTOCONF_NAME} | tr '-' '_' | tr '.' '_'`
19186     target_var=`echo ${OPENJDK_TARGET_AUTOCONF_NAME} | tr '-' '_' | tr '.' '_'`
19187     # Extract rewrite information for build and target
19188     eval rewritten_build=\${REWRITE_${build_var}}
19189     if test "x$rewritten_build" = x; then
19190       rewritten_build=${OPENJDK_BUILD_AUTOCONF_NAME}
19191       echo Build stays the same $rewritten_build
19192     else
19193       echo Rewriting build for builddeps into $rewritten_build
19194     fi
19195     eval rewritten_target=\${REWRITE_${target_var}}
19196     if test "x$rewritten_target" = x; then
19197       rewritten_target=${OPENJDK_TARGET_AUTOCONF_NAME}
19198       echo Target stays the same $rewritten_target
19199     else
19200       echo Rewriting target for builddeps into $rewritten_target
19201     fi
19202     rewritten_build_var=`echo ${rewritten_build} | tr '-' '_' | tr '.' '_'`
19203     rewritten_target_var=`echo ${rewritten_target} | tr '-' '_' | tr '.' '_'`
19204   fi
19205   for ac_prog in 7z unzip
19206 do
19207   # Extract the first word of "$ac_prog", so it can be a program name with args.
19208 set dummy $ac_prog; ac_word=$2
19209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19210 $as_echo_n "checking for $ac_word... " >&6; }
19211 if ${ac_cv_prog_BDEPS_UNZIP+:} false; then :
19212   $as_echo_n "(cached) " >&6
19213 else
19214   if test -n "$BDEPS_UNZIP"; then
19215   ac_cv_prog_BDEPS_UNZIP="$BDEPS_UNZIP" # Let the user override the test.
19216 else
19217 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19218 for as_dir in $PATH
19219 do
19220   IFS=$as_save_IFS
19221   test -z "$as_dir" && as_dir=.
19222     for ac_exec_ext in '' $ac_executable_extensions; do
19223   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19224     ac_cv_prog_BDEPS_UNZIP="$ac_prog"
19225     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19226     break 2
19227   fi
19228 done
19229   done
19230 IFS=$as_save_IFS
19231 
19232 fi
19233 fi
19234 BDEPS_UNZIP=$ac_cv_prog_BDEPS_UNZIP
19235 if test -n "$BDEPS_UNZIP"; then
19236   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BDEPS_UNZIP" >&5
19237 $as_echo "$BDEPS_UNZIP" >&6; }
19238 else
19239   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19240 $as_echo "no" >&6; }
19241 fi
19242 
19243 
19244   test -n "$BDEPS_UNZIP" && break
19245 done
19246 
19247   if test "x$BDEPS_UNZIP" = x7z; then
19248     BDEPS_UNZIP="7z x"
19249   fi
19250 
19251   for ac_prog in wget lftp ftp
19252 do
19253   # Extract the first word of "$ac_prog", so it can be a program name with args.
19254 set dummy $ac_prog; ac_word=$2
19255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19256 $as_echo_n "checking for $ac_word... " >&6; }
19257 if ${ac_cv_prog_BDEPS_FTP+:} false; then :
19258   $as_echo_n "(cached) " >&6
19259 else
19260   if test -n "$BDEPS_FTP"; then
19261   ac_cv_prog_BDEPS_FTP="$BDEPS_FTP" # Let the user override the test.
19262 else
19263 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19264 for as_dir in $PATH
19265 do
19266   IFS=$as_save_IFS
19267   test -z "$as_dir" && as_dir=.
19268     for ac_exec_ext in '' $ac_executable_extensions; do
19269   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19270     ac_cv_prog_BDEPS_FTP="$ac_prog"
19271     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19272     break 2
19273   fi
19274 done
19275   done
19276 IFS=$as_save_IFS
19277 
19278 fi
19279 fi
19280 BDEPS_FTP=$ac_cv_prog_BDEPS_FTP
19281 if test -n "$BDEPS_FTP"; then
19282   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BDEPS_FTP" >&5
19283 $as_echo "$BDEPS_FTP" >&6; }
19284 else
19285   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19286 $as_echo "no" >&6; }
19287 fi
19288 
19289 
19290   test -n "$BDEPS_FTP" && break
19291 done
19292 
19293 
19294 
19295 ###############################################################################
19296 #
19297 # Determine OpenJDK variants, options and version numbers.
19298 #
19299 ###############################################################################
19300 
19301 # We need build & target for this.
19302 
19303 
19304   ###############################################################################
19305   #
19306   # Should we build a JDK/JVM with headful support (ie a graphical ui)?
19307   # We always build headless support.
19308   #
19309   { $as_echo "$as_me:${as_lineno-$LINENO}: checking headful support" >&5
19310 $as_echo_n "checking headful support... " >&6; }
19311   # Check whether --enable-headful was given.
19312 if test "${enable_headful+set}" = set; then :
19313   enableval=$enable_headful; SUPPORT_HEADFUL=${enable_headful}
19314 else
19315   SUPPORT_HEADFUL=yes
19316 fi
19317 
19318 
19319   SUPPORT_HEADLESS=yes
19320   BUILD_HEADLESS="BUILD_HEADLESS:=true"
19321 
19322   if test "x$SUPPORT_HEADFUL" = xyes; then
19323     # We are building both headful and headless.
19324     headful_msg="include support for both headful and headless"
19325   fi
19326 
19327   if test "x$SUPPORT_HEADFUL" = xno; then
19328     # Thus we are building headless only.
19329     BUILD_HEADLESS="BUILD_HEADLESS:=true"
19330     headful_msg="headless only"
19331   fi
19332 
19333   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $headful_msg" >&5
19334 $as_echo "$headful_msg" >&6; }
19335 
19336 
19337 
19338 
19339 
19340   # Control wether Hotspot runs Queens test after build.
19341   # Check whether --enable-hotspot-test-in-build was given.
19342 if test "${enable_hotspot_test_in_build+set}" = set; then :
19343   enableval=$enable_hotspot_test_in_build;
19344 else
19345   enable_hotspot_test_in_build=no
19346 fi
19347 
19348   if test "x$enable_hotspot_test_in_build" = "xyes"; then
19349     TEST_IN_BUILD=true
19350   else
19351     TEST_IN_BUILD=false
19352   fi
19353 
19354 
19355   ###############################################################################
19356   #
19357   # Choose cacerts source file
19358   #
19359 
19360 # Check whether --with-cacerts-file was given.
19361 if test "${with_cacerts_file+set}" = set; then :
19362   withval=$with_cacerts_file;
19363 fi
19364 
19365   if test "x$with_cacerts_file" != x; then
19366     CACERTS_FILE=$with_cacerts_file
19367   else
19368     CACERTS_FILE=${SRC_ROOT}/jdk/src/share/lib/security/cacerts
19369   fi
19370 
19371 
19372   ###############################################################################
19373   #
19374   # Enable or disable unlimited crypto
19375   #
19376   # Check whether --enable-unlimited-crypto was given.
19377 if test "${enable_unlimited_crypto+set}" = set; then :
19378   enableval=$enable_unlimited_crypto;
19379 else
19380   enable_unlimited_crypto=no
19381 fi
19382 
19383   if test "x$enable_unlimited_crypto" = "xyes"; then
19384     UNLIMITED_CRYPTO=true
19385   else
19386     UNLIMITED_CRYPTO=false
19387   fi
19388 
19389 
19390   ###############################################################################
19391   #
19392   # Enable or disable the elliptic curve crypto implementation
19393   #
19394 
19395 
19396   ###############################################################################
19397   #
19398   # --enable-rmiconnector-iiop
19399   #
19400   # Check whether --enable-rmiconnector-iiop was given.
19401 if test "${enable_rmiconnector_iiop+set}" = set; then :
19402   enableval=$enable_rmiconnector_iiop;
19403 fi
19404 
19405   if test "x$enable_rmiconnector_iiop" = "xyes"; then
19406     RMICONNECTOR_IIOP=true
19407   else
19408     RMICONNECTOR_IIOP=false
19409   fi
19410 
19411 
19412   ###############################################################################
19413   #
19414   # Compress jars
19415   #
19416   COMPRESS_JARS=false
19417 
19418 
19419 
19420 
19421   # Source the version numbers
19422   . $AUTOCONF_DIR/version-numbers
19423 
19424   # Get the settings from parameters
19425 
19426 # Check whether --with-milestone was given.
19427 if test "${with_milestone+set}" = set; then :
19428   withval=$with_milestone;
19429 fi
19430 
19431   if test "x$with_milestone" = xyes; then
19432     as_fn_error $? "Milestone must have a value" "$LINENO" 5
19433   elif test "x$with_milestone" != x; then
19434     MILESTONE="$with_milestone"
19435   fi
19436   if test "x$MILESTONE" = x; then
19437     MILESTONE=internal
19438   fi
19439 
19440 
19441 # Check whether --with-update-version was given.
19442 if test "${with_update_version+set}" = set; then :
19443   withval=$with_update_version;
19444 fi
19445 
19446   if test "x$with_update_version" = xyes; then
19447     as_fn_error $? "Update version must have a value" "$LINENO" 5
19448   elif test "x$with_update_version" != x; then
19449     JDK_UPDATE_VERSION="$with_update_version"
19450     # On macosx 10.7, it's not possible to set --with-update-version=0X due
19451     # to a bug in expr (which reduces it to just X). To work around this, we
19452     # always add a 0 to one digit update versions.
19453     if test "${#JDK_UPDATE_VERSION}" = "1"; then
19454       JDK_UPDATE_VERSION="0${JDK_UPDATE_VERSION}"
19455     fi
19456   fi
19457 
19458 
19459 # Check whether --with-user-release-suffix was given.
19460 if test "${with_user_release_suffix+set}" = set; then :
19461   withval=$with_user_release_suffix;
19462 fi
19463 
19464   if test "x$with_user_release_suffix" = xyes; then
19465     as_fn_error $? "Release suffix must have a value" "$LINENO" 5
19466   elif test "x$with_user_release_suffix" != x; then
19467     USER_RELEASE_SUFFIX="$with_user_release_suffix"
19468   fi
19469 
19470 
19471 # Check whether --with-build-number was given.
19472 if test "${with_build_number+set}" = set; then :
19473   withval=$with_build_number;
19474 fi
19475 
19476   if test "x$with_build_number" = xyes; then
19477     as_fn_error $? "Build number must have a value" "$LINENO" 5
19478   elif test "x$with_build_number" != x; then
19479     JDK_BUILD_NUMBER="$with_build_number"
19480   fi
19481   # Define default USER_RELEASE_SUFFIX if BUILD_NUMBER and USER_RELEASE_SUFFIX are not set
19482   if test "x$JDK_BUILD_NUMBER" = x; then
19483     JDK_BUILD_NUMBER=b00
19484     if test "x$USER_RELEASE_SUFFIX" = x; then
19485       BUILD_DATE=`date '+%Y_%m_%d_%H_%M'`
19486       # Avoid [:alnum:] since it depends on the locale.
19487       CLEAN_USERNAME=`echo "$USER" | $TR -d -c 'abcdefghijklmnopqrstuvqxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'`
19488       USER_RELEASE_SUFFIX=`echo "${CLEAN_USERNAME}_${BUILD_DATE}" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
19489     fi
19490   fi
19491 
19492   # Now set the JDK version, milestone, build number etc.
19493 
19494 
19495 
19496 
19497 
19498 
19499 
19500 
19501 
19502 
19503 
19504 
19505 
19506 
19507 
19508   COPYRIGHT_YEAR=`date +'%Y'`
19509 
19510 
19511   if test "x$JDK_UPDATE_VERSION" != x; then
19512     JDK_VERSION="${JDK_MAJOR_VERSION}.${JDK_MINOR_VERSION}.${JDK_MICRO_VERSION}_${JDK_UPDATE_VERSION}"
19513   else
19514     JDK_VERSION="${JDK_MAJOR_VERSION}.${JDK_MINOR_VERSION}.${JDK_MICRO_VERSION}"
19515   fi
19516 
19517 
19518   COOKED_BUILD_NUMBER=`$ECHO $JDK_BUILD_NUMBER | $SED -e 's/^b//' -e 's/^0//'`
19519 
19520 
19521 
19522 ###############################################################################
19523 #
19524 # Setup BootJDK, used to bootstrap the build.
19525 #
19526 ###############################################################################
19527 
19528 
19529   BOOT_JDK_FOUND=no
19530 
19531 # Check whether --with-boot-jdk was given.
19532 if test "${with_boot_jdk+set}" = set; then :
19533   withval=$with_boot_jdk;
19534 fi
19535 
19536 
19537   # We look for the Boot JDK through various means, going from more certain to
19538   # more of a guess-work. After each test, BOOT_JDK_FOUND is set to "yes" if
19539   # we detected something (if so, the path to the jdk is in BOOT_JDK). But we
19540   # must check if this is indeed valid; otherwise we'll continue looking.
19541 
19542   # Test: Is bootjdk explicitely set by command line arguments?
19543 
19544   if test "x$BOOT_JDK_FOUND" = xno; then
19545     # Now execute the test
19546 
19547   if test "x$with_boot_jdk" != x; then
19548     BOOT_JDK=$with_boot_jdk
19549     BOOT_JDK_FOUND=maybe
19550     { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using configure arguments" >&5
19551 $as_echo "$as_me: Found potential Boot JDK using configure arguments" >&6;}
19552   fi
19553 
19554 
19555     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
19556     if test "x$BOOT_JDK_FOUND" = xmaybe; then
19557       # Do we have a bin/java?
19558       if test ! -x "$BOOT_JDK/bin/java"; then
19559         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
19560 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
19561         BOOT_JDK_FOUND=no
19562       else
19563         # Do we have a bin/javac?
19564         if test ! -x "$BOOT_JDK/bin/javac"; then
19565           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
19566 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
19567           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
19568 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
19569           BOOT_JDK_FOUND=no
19570         else
19571           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
19572           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
19573             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
19574 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
19575             BOOT_JDK_FOUND=no
19576           else
19577             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
19578             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
19579 
19580             # Extra M4 quote needed to protect [] in grep expression.
19581             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
19582             if test "x$FOUND_CORRECT_VERSION" = x; then
19583               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
19584 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
19585               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
19586 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
19587               BOOT_JDK_FOUND=no
19588             else
19589               # We're done! :-)
19590               BOOT_JDK_FOUND=yes
19591 
19592   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
19593 
19594   # Input might be given as Windows format, start by converting to
19595   # unix format.
19596   path="$BOOT_JDK"
19597   new_path=`$CYGPATH -u "$path"`
19598 
19599   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
19600   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
19601   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
19602   # "foo.exe" is OK but "foo" is an error.
19603   #
19604   # This test is therefore slightly more accurate than "test -f" to check for file precense.
19605   # It is also a way to make sure we got the proper file name for the real test later on.
19606   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
19607   if test "x$test_shortpath" = x; then
19608     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
19609 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
19610     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
19611   fi
19612 
19613   # Call helper function which possibly converts this using DOS-style short mode.
19614   # If so, the updated path is stored in $new_path.
19615 
19616   input_path="$new_path"
19617   # Check if we need to convert this using DOS-style short mode. If the path
19618   # contains just simple characters, use it. Otherwise (spaces, weird characters),
19619   # take no chances and rewrite it.
19620   # Note: m4 eats our [], so we need to use [ and ] instead.
19621   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
19622   if test "x$has_forbidden_chars" != x; then
19623     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
19624     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
19625     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
19626     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
19627       # Going to short mode and back again did indeed matter. Since short mode is
19628       # case insensitive, let's make it lowercase to improve readability.
19629       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
19630       # Now convert it back to Unix-stile (cygpath)
19631       input_path=`$CYGPATH -u "$shortmode_path"`
19632       new_path="$input_path"
19633     fi
19634   fi
19635 
19636   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
19637   if test "x$test_cygdrive_prefix" = x; then
19638     # As a simple fix, exclude /usr/bin since it's not a real path.
19639     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
19640       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
19641       # a path prefixed by /cygdrive for fixpath to work.
19642       new_path="$CYGWIN_ROOT_PATH$input_path"
19643     fi
19644   fi
19645 
19646 
19647   if test "x$path" != "x$new_path"; then
19648     BOOT_JDK="$new_path"
19649     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
19650 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
19651   fi
19652 
19653   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
19654 
19655   path="$BOOT_JDK"
19656   has_colon=`$ECHO $path | $GREP ^.:`
19657   new_path="$path"
19658   if test "x$has_colon" = x; then
19659     # Not in mixed or Windows style, start by that.
19660     new_path=`cmd //c echo $path`
19661   fi
19662 
19663 
19664   input_path="$new_path"
19665   # Check if we need to convert this using DOS-style short mode. If the path
19666   # contains just simple characters, use it. Otherwise (spaces, weird characters),
19667   # take no chances and rewrite it.
19668   # Note: m4 eats our [], so we need to use [ and ] instead.
19669   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
19670   if test "x$has_forbidden_chars" != x; then
19671     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
19672     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
19673   fi
19674 
19675 
19676   windows_path="$new_path"
19677   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
19678     unix_path=`$CYGPATH -u "$windows_path"`
19679     new_path="$unix_path"
19680   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
19681     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
19682     new_path="$unix_path"
19683   fi
19684 
19685   if test "x$path" != "x$new_path"; then
19686     BOOT_JDK="$new_path"
19687     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
19688 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
19689   fi
19690 
19691   # Save the first 10 bytes of this path to the storage, so fixpath can work.
19692   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
19693 
19694   else
19695     # We're on a posix platform. Hooray! :)
19696     path="$BOOT_JDK"
19697     has_space=`$ECHO "$path" | $GREP " "`
19698     if test "x$has_space" != x; then
19699       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
19700 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
19701       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
19702     fi
19703 
19704     # Use eval to expand a potential ~
19705     eval path="$path"
19706     if test ! -f "$path" && test ! -d "$path"; then
19707       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
19708     fi
19709 
19710     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
19711   fi
19712 
19713               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
19714 $as_echo_n "checking for Boot JDK... " >&6; }
19715               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
19716 $as_echo "$BOOT_JDK" >&6; }
19717               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
19718 $as_echo_n "checking Boot JDK version... " >&6; }
19719               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
19720               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
19721 $as_echo "$BOOT_JDK_VERSION" >&6; }
19722             fi # end check jdk version
19723           fi # end check rt.jar
19724         fi # end check javac
19725       fi # end check java
19726     fi # end check boot jdk found
19727   fi
19728 
19729   if test "x$with_boot_jdk" != x && test "x$BOOT_JDK_FOUND" = xno; then
19730     # Having specified an argument which is incorrect will produce an instant failure;
19731     # we should not go on looking
19732     as_fn_error $? "The path given by --with-boot-jdk does not contain a valid Boot JDK" "$LINENO" 5
19733   fi
19734 
19735   # Test: Is bootjdk available from builddeps?
19736 
19737   if test "x$BOOT_JDK_FOUND" = xno; then
19738     # Now execute the test
19739 
19740 
19741 
19742   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
19743     # Source the builddeps file again, to make sure it uses the latest variables!
19744     . $builddepsfile
19745     # Look for a target and build machine specific resource!
19746     eval resource=\${builddep_bootjdk_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
19747     if test "x$resource" = x; then
19748       # Ok, lets instead look for a target specific resource
19749       eval resource=\${builddep_bootjdk_TARGET_${rewritten_target_var}}
19750     fi
19751     if test "x$resource" = x; then
19752       # Ok, lets instead look for a build specific resource
19753       eval resource=\${builddep_bootjdk_BUILD_${rewritten_build_var}}
19754     fi
19755     if test "x$resource" = x; then
19756       # Ok, lets instead look for a generic resource
19757       # (The bootjdk comes from M4 and not the shell, thus no need for eval here.)
19758       resource=${builddep_bootjdk}
19759     fi
19760     if test "x$resource" != x; then
19761       { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for bootjdk" >&5
19762 $as_echo "$as_me: Using builddeps $resource for bootjdk" >&6;}
19763       # If the resource in the builddeps.conf file is an existing directory,
19764       # for example /java/linux/cups
19765       if test -d ${resource}; then
19766         depdir=${resource}
19767       else
19768 
19769   # bootjdk is for example mymodule
19770   # $resource is for example libs/general/libmymod_1_2_3.zip
19771   # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
19772   # $with_builddeps_dir is for example /localhome/builddeps
19773   # depdir is the name of the variable into which we store the depdir, eg MYMOD
19774   # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
19775   # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
19776   filename=`basename $resource`
19777   filebase=`echo $filename | sed 's/\.[^\.]*$//'`
19778   filebase=${filename%%.*}
19779   extension=${filename#*.}
19780   installdir=$with_builddeps_dir/$filebase
19781   if test ! -f $installdir/$filename.unpacked; then
19782     { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency bootjdk from $with_builddeps_server/$resource and installing into $installdir" >&5
19783 $as_echo "$as_me: Downloading build dependency bootjdk from $with_builddeps_server/$resource and installing into $installdir" >&6;}
19784     if test ! -d $installdir; then
19785       mkdir -p $installdir
19786     fi
19787     if test ! -d $installdir; then
19788       as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
19789     fi
19790     tmpfile=`mktemp $installdir/bootjdk.XXXXXXXXX`
19791     touch $tmpfile
19792     if test ! -f $tmpfile; then
19793       as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
19794     fi
19795 
19796   # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
19797   # $tmpfile is the local file name for the downloaded file.
19798   VALID_TOOL=no
19799   if test "x$BDEPS_FTP" = xwget; then
19800     VALID_TOOL=yes
19801     wget -O $tmpfile $with_builddeps_server/$resource
19802   fi
19803   if test "x$BDEPS_FTP" = xlftp; then
19804     VALID_TOOL=yes
19805     lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
19806   fi
19807   if test "x$BDEPS_FTP" = xftp; then
19808     VALID_TOOL=yes
19809     FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
19810     FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
19811     FTPUSERPWD=${FTPSERVER%%@*}
19812     if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
19813       FTPUSER=${userpwd%%:*}
19814       FTPPWD=${userpwd#*@}
19815       FTPSERVER=${FTPSERVER#*@}
19816     else
19817       FTPUSER=ftp
19818       FTPPWD=ftp
19819     fi
19820     # the "pass" command does not work on some
19821     # ftp clients (read ftp.exe) but if it works,
19822     # passive mode is better!
19823     ( \
19824         echo "user $FTPUSER $FTPPWD"        ; \
19825         echo "pass"                         ; \
19826         echo "bin"                          ; \
19827         echo "get $FTPPATH $tmpfile"              ; \
19828     ) | ftp -in $FTPSERVER
19829   fi
19830   if test "x$VALID_TOOL" != xyes; then
19831     as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
19832   fi
19833 
19834     mv $tmpfile $installdir/$filename
19835     if test ! -s $installdir/$filename; then
19836       as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
19837     fi
19838     case "$extension" in
19839       zip)  echo "Unzipping $installdir/$filename..."
19840         (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
19841         ;;
19842       tar.gz) echo "Untaring $installdir/$filename..."
19843         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
19844         ;;
19845       tgz) echo "Untaring $installdir/$filename..."
19846         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
19847         ;;
19848       *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
19849         ;;
19850     esac
19851   fi
19852   if test -f $installdir/$filename.unpacked; then
19853     depdir=$installdir
19854   fi
19855 
19856       fi
19857       # Source the builddeps file again, because in the previous command, the depdir
19858       # was updated to point at the current build dependency install directory.
19859       . $builddepsfile
19860       # Now extract variables from the builddeps.conf files.
19861       theroot=${builddep_bootjdk_ROOT}
19862       thecflags=${builddep_bootjdk_CFLAGS}
19863       thelibs=${builddep_bootjdk_LIBS}
19864       if test "x$depdir" = x; then
19865         as_fn_error $? "Could not download build dependency bootjdk" "$LINENO" 5
19866       fi
19867       BOOT_JDK=$depdir
19868       if test "x$theroot" != x; then
19869         BOOT_JDK="$theroot"
19870       fi
19871       if test "x$thecflags" != x; then
19872         BOOT_JDK_CFLAGS="$thecflags"
19873       fi
19874       if test "x$thelibs" != x; then
19875         BOOT_JDK_LIBS="$thelibs"
19876       fi
19877       BOOT_JDK_FOUND=maybe
19878       else BOOT_JDK_FOUND=no
19879 
19880     fi
19881     else BOOT_JDK_FOUND=no
19882 
19883   fi
19884 
19885 
19886 
19887     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
19888     if test "x$BOOT_JDK_FOUND" = xmaybe; then
19889       # Do we have a bin/java?
19890       if test ! -x "$BOOT_JDK/bin/java"; then
19891         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
19892 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
19893         BOOT_JDK_FOUND=no
19894       else
19895         # Do we have a bin/javac?
19896         if test ! -x "$BOOT_JDK/bin/javac"; then
19897           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
19898 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
19899           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
19900 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
19901           BOOT_JDK_FOUND=no
19902         else
19903           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
19904           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
19905             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
19906 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
19907             BOOT_JDK_FOUND=no
19908           else
19909             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
19910             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
19911 
19912             # Extra M4 quote needed to protect [] in grep expression.
19913             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
19914             if test "x$FOUND_CORRECT_VERSION" = x; then
19915               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
19916 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
19917               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
19918 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
19919               BOOT_JDK_FOUND=no
19920             else
19921               # We're done! :-)
19922               BOOT_JDK_FOUND=yes
19923 
19924   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
19925 
19926   # Input might be given as Windows format, start by converting to
19927   # unix format.
19928   path="$BOOT_JDK"
19929   new_path=`$CYGPATH -u "$path"`
19930 
19931   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
19932   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
19933   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
19934   # "foo.exe" is OK but "foo" is an error.
19935   #
19936   # This test is therefore slightly more accurate than "test -f" to check for file precense.
19937   # It is also a way to make sure we got the proper file name for the real test later on.
19938   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
19939   if test "x$test_shortpath" = x; then
19940     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
19941 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
19942     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
19943   fi
19944 
19945   # Call helper function which possibly converts this using DOS-style short mode.
19946   # If so, the updated path is stored in $new_path.
19947 
19948   input_path="$new_path"
19949   # Check if we need to convert this using DOS-style short mode. If the path
19950   # contains just simple characters, use it. Otherwise (spaces, weird characters),
19951   # take no chances and rewrite it.
19952   # Note: m4 eats our [], so we need to use [ and ] instead.
19953   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
19954   if test "x$has_forbidden_chars" != x; then
19955     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
19956     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
19957     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
19958     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
19959       # Going to short mode and back again did indeed matter. Since short mode is
19960       # case insensitive, let's make it lowercase to improve readability.
19961       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
19962       # Now convert it back to Unix-stile (cygpath)
19963       input_path=`$CYGPATH -u "$shortmode_path"`
19964       new_path="$input_path"
19965     fi
19966   fi
19967 
19968   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
19969   if test "x$test_cygdrive_prefix" = x; then
19970     # As a simple fix, exclude /usr/bin since it's not a real path.
19971     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
19972       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
19973       # a path prefixed by /cygdrive for fixpath to work.
19974       new_path="$CYGWIN_ROOT_PATH$input_path"
19975     fi
19976   fi
19977 
19978 
19979   if test "x$path" != "x$new_path"; then
19980     BOOT_JDK="$new_path"
19981     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
19982 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
19983   fi
19984 
19985   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
19986 
19987   path="$BOOT_JDK"
19988   has_colon=`$ECHO $path | $GREP ^.:`
19989   new_path="$path"
19990   if test "x$has_colon" = x; then
19991     # Not in mixed or Windows style, start by that.
19992     new_path=`cmd //c echo $path`
19993   fi
19994 
19995 
19996   input_path="$new_path"
19997   # Check if we need to convert this using DOS-style short mode. If the path
19998   # contains just simple characters, use it. Otherwise (spaces, weird characters),
19999   # take no chances and rewrite it.
20000   # Note: m4 eats our [], so we need to use [ and ] instead.
20001   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20002   if test "x$has_forbidden_chars" != x; then
20003     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20004     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20005   fi
20006 
20007 
20008   windows_path="$new_path"
20009   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20010     unix_path=`$CYGPATH -u "$windows_path"`
20011     new_path="$unix_path"
20012   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20013     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20014     new_path="$unix_path"
20015   fi
20016 
20017   if test "x$path" != "x$new_path"; then
20018     BOOT_JDK="$new_path"
20019     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20020 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20021   fi
20022 
20023   # Save the first 10 bytes of this path to the storage, so fixpath can work.
20024   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20025 
20026   else
20027     # We're on a posix platform. Hooray! :)
20028     path="$BOOT_JDK"
20029     has_space=`$ECHO "$path" | $GREP " "`
20030     if test "x$has_space" != x; then
20031       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20032 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20033       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20034     fi
20035 
20036     # Use eval to expand a potential ~
20037     eval path="$path"
20038     if test ! -f "$path" && test ! -d "$path"; then
20039       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20040     fi
20041 
20042     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20043   fi
20044 
20045               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20046 $as_echo_n "checking for Boot JDK... " >&6; }
20047               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20048 $as_echo "$BOOT_JDK" >&6; }
20049               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20050 $as_echo_n "checking Boot JDK version... " >&6; }
20051               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20052               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20053 $as_echo "$BOOT_JDK_VERSION" >&6; }
20054             fi # end check jdk version
20055           fi # end check rt.jar
20056         fi # end check javac
20057       fi # end check java
20058     fi # end check boot jdk found
20059   fi
20060 
20061 
20062   # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home?
20063 
20064   if test "x$BOOT_JDK_FOUND" = xno; then
20065     # Now execute the test
20066 
20067   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
20068     # First check at user selected default
20069 
20070   if test "x$BOOT_JDK_FOUND" = xno; then
20071     # Now execute the test
20072 
20073   if test -x /usr/libexec/java_home; then
20074     BOOT_JDK=`/usr/libexec/java_home `
20075     BOOT_JDK_FOUND=maybe
20076     { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home " >&5
20077 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home " >&6;}
20078   fi
20079 
20080 
20081     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20082     if test "x$BOOT_JDK_FOUND" = xmaybe; then
20083       # Do we have a bin/java?
20084       if test ! -x "$BOOT_JDK/bin/java"; then
20085         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20086 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20087         BOOT_JDK_FOUND=no
20088       else
20089         # Do we have a bin/javac?
20090         if test ! -x "$BOOT_JDK/bin/javac"; then
20091           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20092 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20093           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20094 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20095           BOOT_JDK_FOUND=no
20096         else
20097           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20098           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20099             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20100 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20101             BOOT_JDK_FOUND=no
20102           else
20103             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20104             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20105 
20106             # Extra M4 quote needed to protect [] in grep expression.
20107             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20108             if test "x$FOUND_CORRECT_VERSION" = x; then
20109               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20110 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20111               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20112 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20113               BOOT_JDK_FOUND=no
20114             else
20115               # We're done! :-)
20116               BOOT_JDK_FOUND=yes
20117 
20118   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20119 
20120   # Input might be given as Windows format, start by converting to
20121   # unix format.
20122   path="$BOOT_JDK"
20123   new_path=`$CYGPATH -u "$path"`
20124 
20125   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20126   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20127   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20128   # "foo.exe" is OK but "foo" is an error.
20129   #
20130   # This test is therefore slightly more accurate than "test -f" to check for file precense.
20131   # It is also a way to make sure we got the proper file name for the real test later on.
20132   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20133   if test "x$test_shortpath" = x; then
20134     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20135 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20136     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20137   fi
20138 
20139   # Call helper function which possibly converts this using DOS-style short mode.
20140   # If so, the updated path is stored in $new_path.
20141 
20142   input_path="$new_path"
20143   # Check if we need to convert this using DOS-style short mode. If the path
20144   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20145   # take no chances and rewrite it.
20146   # Note: m4 eats our [], so we need to use [ and ] instead.
20147   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20148   if test "x$has_forbidden_chars" != x; then
20149     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20150     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20151     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20152     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20153       # Going to short mode and back again did indeed matter. Since short mode is
20154       # case insensitive, let's make it lowercase to improve readability.
20155       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20156       # Now convert it back to Unix-stile (cygpath)
20157       input_path=`$CYGPATH -u "$shortmode_path"`
20158       new_path="$input_path"
20159     fi
20160   fi
20161 
20162   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20163   if test "x$test_cygdrive_prefix" = x; then
20164     # As a simple fix, exclude /usr/bin since it's not a real path.
20165     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20166       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20167       # a path prefixed by /cygdrive for fixpath to work.
20168       new_path="$CYGWIN_ROOT_PATH$input_path"
20169     fi
20170   fi
20171 
20172 
20173   if test "x$path" != "x$new_path"; then
20174     BOOT_JDK="$new_path"
20175     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20176 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20177   fi
20178 
20179   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20180 
20181   path="$BOOT_JDK"
20182   has_colon=`$ECHO $path | $GREP ^.:`
20183   new_path="$path"
20184   if test "x$has_colon" = x; then
20185     # Not in mixed or Windows style, start by that.
20186     new_path=`cmd //c echo $path`
20187   fi
20188 
20189 
20190   input_path="$new_path"
20191   # Check if we need to convert this using DOS-style short mode. If the path
20192   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20193   # take no chances and rewrite it.
20194   # Note: m4 eats our [], so we need to use [ and ] instead.
20195   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20196   if test "x$has_forbidden_chars" != x; then
20197     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20198     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20199   fi
20200 
20201 
20202   windows_path="$new_path"
20203   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20204     unix_path=`$CYGPATH -u "$windows_path"`
20205     new_path="$unix_path"
20206   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20207     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20208     new_path="$unix_path"
20209   fi
20210 
20211   if test "x$path" != "x$new_path"; then
20212     BOOT_JDK="$new_path"
20213     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20214 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20215   fi
20216 
20217   # Save the first 10 bytes of this path to the storage, so fixpath can work.
20218   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20219 
20220   else
20221     # We're on a posix platform. Hooray! :)
20222     path="$BOOT_JDK"
20223     has_space=`$ECHO "$path" | $GREP " "`
20224     if test "x$has_space" != x; then
20225       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20226 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20227       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20228     fi
20229 
20230     # Use eval to expand a potential ~
20231     eval path="$path"
20232     if test ! -f "$path" && test ! -d "$path"; then
20233       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20234     fi
20235 
20236     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20237   fi
20238 
20239               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20240 $as_echo_n "checking for Boot JDK... " >&6; }
20241               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20242 $as_echo "$BOOT_JDK" >&6; }
20243               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20244 $as_echo_n "checking Boot JDK version... " >&6; }
20245               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20246               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20247 $as_echo "$BOOT_JDK_VERSION" >&6; }
20248             fi # end check jdk version
20249           fi # end check rt.jar
20250         fi # end check javac
20251       fi # end check java
20252     fi # end check boot jdk found
20253   fi
20254 
20255     # If that did not work out (e.g. too old), try explicit versions instead
20256 
20257   if test "x$BOOT_JDK_FOUND" = xno; then
20258     # Now execute the test
20259 
20260   if test -x /usr/libexec/java_home; then
20261     BOOT_JDK=`/usr/libexec/java_home -v 1.9`
20262     BOOT_JDK_FOUND=maybe
20263     { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&5
20264 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&6;}
20265   fi
20266 
20267 
20268     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20269     if test "x$BOOT_JDK_FOUND" = xmaybe; then
20270       # Do we have a bin/java?
20271       if test ! -x "$BOOT_JDK/bin/java"; then
20272         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20273 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20274         BOOT_JDK_FOUND=no
20275       else
20276         # Do we have a bin/javac?
20277         if test ! -x "$BOOT_JDK/bin/javac"; then
20278           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20279 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20280           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20281 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20282           BOOT_JDK_FOUND=no
20283         else
20284           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20285           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20286             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20287 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20288             BOOT_JDK_FOUND=no
20289           else
20290             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20291             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20292 
20293             # Extra M4 quote needed to protect [] in grep expression.
20294             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20295             if test "x$FOUND_CORRECT_VERSION" = x; then
20296               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20297 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20298               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20299 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20300               BOOT_JDK_FOUND=no
20301             else
20302               # We're done! :-)
20303               BOOT_JDK_FOUND=yes
20304 
20305   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20306 
20307   # Input might be given as Windows format, start by converting to
20308   # unix format.
20309   path="$BOOT_JDK"
20310   new_path=`$CYGPATH -u "$path"`
20311 
20312   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20313   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20314   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20315   # "foo.exe" is OK but "foo" is an error.
20316   #
20317   # This test is therefore slightly more accurate than "test -f" to check for file precense.
20318   # It is also a way to make sure we got the proper file name for the real test later on.
20319   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20320   if test "x$test_shortpath" = x; then
20321     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20322 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20323     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20324   fi
20325 
20326   # Call helper function which possibly converts this using DOS-style short mode.
20327   # If so, the updated path is stored in $new_path.
20328 
20329   input_path="$new_path"
20330   # Check if we need to convert this using DOS-style short mode. If the path
20331   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20332   # take no chances and rewrite it.
20333   # Note: m4 eats our [], so we need to use [ and ] instead.
20334   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20335   if test "x$has_forbidden_chars" != x; then
20336     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20337     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20338     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20339     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20340       # Going to short mode and back again did indeed matter. Since short mode is
20341       # case insensitive, let's make it lowercase to improve readability.
20342       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20343       # Now convert it back to Unix-stile (cygpath)
20344       input_path=`$CYGPATH -u "$shortmode_path"`
20345       new_path="$input_path"
20346     fi
20347   fi
20348 
20349   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20350   if test "x$test_cygdrive_prefix" = x; then
20351     # As a simple fix, exclude /usr/bin since it's not a real path.
20352     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20353       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20354       # a path prefixed by /cygdrive for fixpath to work.
20355       new_path="$CYGWIN_ROOT_PATH$input_path"
20356     fi
20357   fi
20358 
20359 
20360   if test "x$path" != "x$new_path"; then
20361     BOOT_JDK="$new_path"
20362     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20363 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20364   fi
20365 
20366   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20367 
20368   path="$BOOT_JDK"
20369   has_colon=`$ECHO $path | $GREP ^.:`
20370   new_path="$path"
20371   if test "x$has_colon" = x; then
20372     # Not in mixed or Windows style, start by that.
20373     new_path=`cmd //c echo $path`
20374   fi
20375 
20376 
20377   input_path="$new_path"
20378   # Check if we need to convert this using DOS-style short mode. If the path
20379   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20380   # take no chances and rewrite it.
20381   # Note: m4 eats our [], so we need to use [ and ] instead.
20382   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20383   if test "x$has_forbidden_chars" != x; then
20384     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20385     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20386   fi
20387 
20388 
20389   windows_path="$new_path"
20390   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20391     unix_path=`$CYGPATH -u "$windows_path"`
20392     new_path="$unix_path"
20393   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20394     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20395     new_path="$unix_path"
20396   fi
20397 
20398   if test "x$path" != "x$new_path"; then
20399     BOOT_JDK="$new_path"
20400     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20401 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20402   fi
20403 
20404   # Save the first 10 bytes of this path to the storage, so fixpath can work.
20405   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20406 
20407   else
20408     # We're on a posix platform. Hooray! :)
20409     path="$BOOT_JDK"
20410     has_space=`$ECHO "$path" | $GREP " "`
20411     if test "x$has_space" != x; then
20412       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20413 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20414       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20415     fi
20416 
20417     # Use eval to expand a potential ~
20418     eval path="$path"
20419     if test ! -f "$path" && test ! -d "$path"; then
20420       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20421     fi
20422 
20423     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20424   fi
20425 
20426               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20427 $as_echo_n "checking for Boot JDK... " >&6; }
20428               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20429 $as_echo "$BOOT_JDK" >&6; }
20430               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20431 $as_echo_n "checking Boot JDK version... " >&6; }
20432               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20433               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20434 $as_echo "$BOOT_JDK_VERSION" >&6; }
20435             fi # end check jdk version
20436           fi # end check rt.jar
20437         fi # end check javac
20438       fi # end check java
20439     fi # end check boot jdk found
20440   fi
20441 
20442 
20443   if test "x$BOOT_JDK_FOUND" = xno; then
20444     # Now execute the test
20445 
20446   if test -x /usr/libexec/java_home; then
20447     BOOT_JDK=`/usr/libexec/java_home -v 1.8`
20448     BOOT_JDK_FOUND=maybe
20449     { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&5
20450 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&6;}
20451   fi
20452 
20453 
20454     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20455     if test "x$BOOT_JDK_FOUND" = xmaybe; then
20456       # Do we have a bin/java?
20457       if test ! -x "$BOOT_JDK/bin/java"; then
20458         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20459 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20460         BOOT_JDK_FOUND=no
20461       else
20462         # Do we have a bin/javac?
20463         if test ! -x "$BOOT_JDK/bin/javac"; then
20464           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20465 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20466           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20467 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20468           BOOT_JDK_FOUND=no
20469         else
20470           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20471           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20472             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20473 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20474             BOOT_JDK_FOUND=no
20475           else
20476             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20477             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20478 
20479             # Extra M4 quote needed to protect [] in grep expression.
20480             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20481             if test "x$FOUND_CORRECT_VERSION" = x; then
20482               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20483 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20484               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20485 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20486               BOOT_JDK_FOUND=no
20487             else
20488               # We're done! :-)
20489               BOOT_JDK_FOUND=yes
20490 
20491   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20492 
20493   # Input might be given as Windows format, start by converting to
20494   # unix format.
20495   path="$BOOT_JDK"
20496   new_path=`$CYGPATH -u "$path"`
20497 
20498   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20499   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20500   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20501   # "foo.exe" is OK but "foo" is an error.
20502   #
20503   # This test is therefore slightly more accurate than "test -f" to check for file precense.
20504   # It is also a way to make sure we got the proper file name for the real test later on.
20505   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20506   if test "x$test_shortpath" = x; then
20507     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20508 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20509     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20510   fi
20511 
20512   # Call helper function which possibly converts this using DOS-style short mode.
20513   # If so, the updated path is stored in $new_path.
20514 
20515   input_path="$new_path"
20516   # Check if we need to convert this using DOS-style short mode. If the path
20517   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20518   # take no chances and rewrite it.
20519   # Note: m4 eats our [], so we need to use [ and ] instead.
20520   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20521   if test "x$has_forbidden_chars" != x; then
20522     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20523     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20524     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20525     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20526       # Going to short mode and back again did indeed matter. Since short mode is
20527       # case insensitive, let's make it lowercase to improve readability.
20528       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20529       # Now convert it back to Unix-stile (cygpath)
20530       input_path=`$CYGPATH -u "$shortmode_path"`
20531       new_path="$input_path"
20532     fi
20533   fi
20534 
20535   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20536   if test "x$test_cygdrive_prefix" = x; then
20537     # As a simple fix, exclude /usr/bin since it's not a real path.
20538     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20539       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20540       # a path prefixed by /cygdrive for fixpath to work.
20541       new_path="$CYGWIN_ROOT_PATH$input_path"
20542     fi
20543   fi
20544 
20545 
20546   if test "x$path" != "x$new_path"; then
20547     BOOT_JDK="$new_path"
20548     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20549 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20550   fi
20551 
20552   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20553 
20554   path="$BOOT_JDK"
20555   has_colon=`$ECHO $path | $GREP ^.:`
20556   new_path="$path"
20557   if test "x$has_colon" = x; then
20558     # Not in mixed or Windows style, start by that.
20559     new_path=`cmd //c echo $path`
20560   fi
20561 
20562 
20563   input_path="$new_path"
20564   # Check if we need to convert this using DOS-style short mode. If the path
20565   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20566   # take no chances and rewrite it.
20567   # Note: m4 eats our [], so we need to use [ and ] instead.
20568   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20569   if test "x$has_forbidden_chars" != x; then
20570     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20571     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20572   fi
20573 
20574 
20575   windows_path="$new_path"
20576   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20577     unix_path=`$CYGPATH -u "$windows_path"`
20578     new_path="$unix_path"
20579   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20580     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20581     new_path="$unix_path"
20582   fi
20583 
20584   if test "x$path" != "x$new_path"; then
20585     BOOT_JDK="$new_path"
20586     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20587 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20588   fi
20589 
20590   # Save the first 10 bytes of this path to the storage, so fixpath can work.
20591   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20592 
20593   else
20594     # We're on a posix platform. Hooray! :)
20595     path="$BOOT_JDK"
20596     has_space=`$ECHO "$path" | $GREP " "`
20597     if test "x$has_space" != x; then
20598       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20599 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20600       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20601     fi
20602 
20603     # Use eval to expand a potential ~
20604     eval path="$path"
20605     if test ! -f "$path" && test ! -d "$path"; then
20606       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20607     fi
20608 
20609     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20610   fi
20611 
20612               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20613 $as_echo_n "checking for Boot JDK... " >&6; }
20614               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20615 $as_echo "$BOOT_JDK" >&6; }
20616               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20617 $as_echo_n "checking Boot JDK version... " >&6; }
20618               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20619               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20620 $as_echo "$BOOT_JDK_VERSION" >&6; }
20621             fi # end check jdk version
20622           fi # end check rt.jar
20623         fi # end check javac
20624       fi # end check java
20625     fi # end check boot jdk found
20626   fi
20627 
20628 
20629   if test "x$BOOT_JDK_FOUND" = xno; then
20630     # Now execute the test
20631 
20632   if test -x /usr/libexec/java_home; then
20633     BOOT_JDK=`/usr/libexec/java_home -v 1.7`
20634     BOOT_JDK_FOUND=maybe
20635     { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&5
20636 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&6;}
20637   fi
20638 
20639 
20640     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20641     if test "x$BOOT_JDK_FOUND" = xmaybe; then
20642       # Do we have a bin/java?
20643       if test ! -x "$BOOT_JDK/bin/java"; then
20644         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20645 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20646         BOOT_JDK_FOUND=no
20647       else
20648         # Do we have a bin/javac?
20649         if test ! -x "$BOOT_JDK/bin/javac"; then
20650           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20651 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20652           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20653 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20654           BOOT_JDK_FOUND=no
20655         else
20656           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20657           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20658             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20659 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20660             BOOT_JDK_FOUND=no
20661           else
20662             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20663             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20664 
20665             # Extra M4 quote needed to protect [] in grep expression.
20666             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20667             if test "x$FOUND_CORRECT_VERSION" = x; then
20668               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20669 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20670               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20671 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20672               BOOT_JDK_FOUND=no
20673             else
20674               # We're done! :-)
20675               BOOT_JDK_FOUND=yes
20676 
20677   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20678 
20679   # Input might be given as Windows format, start by converting to
20680   # unix format.
20681   path="$BOOT_JDK"
20682   new_path=`$CYGPATH -u "$path"`
20683 
20684   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20685   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20686   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20687   # "foo.exe" is OK but "foo" is an error.
20688   #
20689   # This test is therefore slightly more accurate than "test -f" to check for file precense.
20690   # It is also a way to make sure we got the proper file name for the real test later on.
20691   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20692   if test "x$test_shortpath" = x; then
20693     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20694 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20695     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20696   fi
20697 
20698   # Call helper function which possibly converts this using DOS-style short mode.
20699   # If so, the updated path is stored in $new_path.
20700 
20701   input_path="$new_path"
20702   # Check if we need to convert this using DOS-style short mode. If the path
20703   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20704   # take no chances and rewrite it.
20705   # Note: m4 eats our [], so we need to use [ and ] instead.
20706   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20707   if test "x$has_forbidden_chars" != x; then
20708     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20709     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20710     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20711     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20712       # Going to short mode and back again did indeed matter. Since short mode is
20713       # case insensitive, let's make it lowercase to improve readability.
20714       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20715       # Now convert it back to Unix-stile (cygpath)
20716       input_path=`$CYGPATH -u "$shortmode_path"`
20717       new_path="$input_path"
20718     fi
20719   fi
20720 
20721   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20722   if test "x$test_cygdrive_prefix" = x; then
20723     # As a simple fix, exclude /usr/bin since it's not a real path.
20724     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20725       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20726       # a path prefixed by /cygdrive for fixpath to work.
20727       new_path="$CYGWIN_ROOT_PATH$input_path"
20728     fi
20729   fi
20730 
20731 
20732   if test "x$path" != "x$new_path"; then
20733     BOOT_JDK="$new_path"
20734     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20735 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20736   fi
20737 
20738   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20739 
20740   path="$BOOT_JDK"
20741   has_colon=`$ECHO $path | $GREP ^.:`
20742   new_path="$path"
20743   if test "x$has_colon" = x; then
20744     # Not in mixed or Windows style, start by that.
20745     new_path=`cmd //c echo $path`
20746   fi
20747 
20748 
20749   input_path="$new_path"
20750   # Check if we need to convert this using DOS-style short mode. If the path
20751   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20752   # take no chances and rewrite it.
20753   # Note: m4 eats our [], so we need to use [ and ] instead.
20754   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20755   if test "x$has_forbidden_chars" != x; then
20756     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20757     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20758   fi
20759 
20760 
20761   windows_path="$new_path"
20762   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20763     unix_path=`$CYGPATH -u "$windows_path"`
20764     new_path="$unix_path"
20765   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20766     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20767     new_path="$unix_path"
20768   fi
20769 
20770   if test "x$path" != "x$new_path"; then
20771     BOOT_JDK="$new_path"
20772     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20773 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20774   fi
20775 
20776   # Save the first 10 bytes of this path to the storage, so fixpath can work.
20777   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20778 
20779   else
20780     # We're on a posix platform. Hooray! :)
20781     path="$BOOT_JDK"
20782     has_space=`$ECHO "$path" | $GREP " "`
20783     if test "x$has_space" != x; then
20784       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20785 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20786       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20787     fi
20788 
20789     # Use eval to expand a potential ~
20790     eval path="$path"
20791     if test ! -f "$path" && test ! -d "$path"; then
20792       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20793     fi
20794 
20795     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20796   fi
20797 
20798               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20799 $as_echo_n "checking for Boot JDK... " >&6; }
20800               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20801 $as_echo "$BOOT_JDK" >&6; }
20802               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20803 $as_echo_n "checking Boot JDK version... " >&6; }
20804               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20805               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20806 $as_echo "$BOOT_JDK_VERSION" >&6; }
20807             fi # end check jdk version
20808           fi # end check rt.jar
20809         fi # end check javac
20810       fi # end check java
20811     fi # end check boot jdk found
20812   fi
20813 
20814   fi
20815 
20816 
20817     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20818     if test "x$BOOT_JDK_FOUND" = xmaybe; then
20819       # Do we have a bin/java?
20820       if test ! -x "$BOOT_JDK/bin/java"; then
20821         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20822 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20823         BOOT_JDK_FOUND=no
20824       else
20825         # Do we have a bin/javac?
20826         if test ! -x "$BOOT_JDK/bin/javac"; then
20827           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20828 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20829           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20830 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20831           BOOT_JDK_FOUND=no
20832         else
20833           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20834           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20835             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20836 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20837             BOOT_JDK_FOUND=no
20838           else
20839             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20840             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20841 
20842             # Extra M4 quote needed to protect [] in grep expression.
20843             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
20844             if test "x$FOUND_CORRECT_VERSION" = x; then
20845               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20846 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20847               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
20848 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
20849               BOOT_JDK_FOUND=no
20850             else
20851               # We're done! :-)
20852               BOOT_JDK_FOUND=yes
20853 
20854   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20855 
20856   # Input might be given as Windows format, start by converting to
20857   # unix format.
20858   path="$BOOT_JDK"
20859   new_path=`$CYGPATH -u "$path"`
20860 
20861   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20862   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20863   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20864   # "foo.exe" is OK but "foo" is an error.
20865   #
20866   # This test is therefore slightly more accurate than "test -f" to check for file precense.
20867   # It is also a way to make sure we got the proper file name for the real test later on.
20868   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20869   if test "x$test_shortpath" = x; then
20870     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20871 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20872     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20873   fi
20874 
20875   # Call helper function which possibly converts this using DOS-style short mode.
20876   # If so, the updated path is stored in $new_path.
20877 
20878   input_path="$new_path"
20879   # Check if we need to convert this using DOS-style short mode. If the path
20880   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20881   # take no chances and rewrite it.
20882   # Note: m4 eats our [], so we need to use [ and ] instead.
20883   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20884   if test "x$has_forbidden_chars" != x; then
20885     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20886     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20887     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20888     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20889       # Going to short mode and back again did indeed matter. Since short mode is
20890       # case insensitive, let's make it lowercase to improve readability.
20891       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20892       # Now convert it back to Unix-stile (cygpath)
20893       input_path=`$CYGPATH -u "$shortmode_path"`
20894       new_path="$input_path"
20895     fi
20896   fi
20897 
20898   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20899   if test "x$test_cygdrive_prefix" = x; then
20900     # As a simple fix, exclude /usr/bin since it's not a real path.
20901     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20902       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20903       # a path prefixed by /cygdrive for fixpath to work.
20904       new_path="$CYGWIN_ROOT_PATH$input_path"
20905     fi
20906   fi
20907 
20908 
20909   if test "x$path" != "x$new_path"; then
20910     BOOT_JDK="$new_path"
20911     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20912 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20913   fi
20914 
20915   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20916 
20917   path="$BOOT_JDK"
20918   has_colon=`$ECHO $path | $GREP ^.:`
20919   new_path="$path"
20920   if test "x$has_colon" = x; then
20921     # Not in mixed or Windows style, start by that.
20922     new_path=`cmd //c echo $path`
20923   fi
20924 
20925 
20926   input_path="$new_path"
20927   # Check if we need to convert this using DOS-style short mode. If the path
20928   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20929   # take no chances and rewrite it.
20930   # Note: m4 eats our [], so we need to use [ and ] instead.
20931   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20932   if test "x$has_forbidden_chars" != x; then
20933     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20934     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20935   fi
20936 
20937 
20938   windows_path="$new_path"
20939   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20940     unix_path=`$CYGPATH -u "$windows_path"`
20941     new_path="$unix_path"
20942   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20943     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20944     new_path="$unix_path"
20945   fi
20946 
20947   if test "x$path" != "x$new_path"; then
20948     BOOT_JDK="$new_path"
20949     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20950 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20951   fi
20952 
20953   # Save the first 10 bytes of this path to the storage, so fixpath can work.
20954   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20955 
20956   else
20957     # We're on a posix platform. Hooray! :)
20958     path="$BOOT_JDK"
20959     has_space=`$ECHO "$path" | $GREP " "`
20960     if test "x$has_space" != x; then
20961       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20962 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20963       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20964     fi
20965 
20966     # Use eval to expand a potential ~
20967     eval path="$path"
20968     if test ! -f "$path" && test ! -d "$path"; then
20969       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20970     fi
20971 
20972     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20973   fi
20974 
20975               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20976 $as_echo_n "checking for Boot JDK... " >&6; }
20977               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20978 $as_echo "$BOOT_JDK" >&6; }
20979               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20980 $as_echo_n "checking Boot JDK version... " >&6; }
20981               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20982               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20983 $as_echo "$BOOT_JDK_VERSION" >&6; }
20984             fi # end check jdk version
20985           fi # end check rt.jar
20986         fi # end check javac
20987       fi # end check java
20988     fi # end check boot jdk found
20989   fi
20990 
20991 
20992   # Test: Is $JAVA_HOME set?
20993 
20994   if test "x$BOOT_JDK_FOUND" = xno; then
20995     # Now execute the test
20996 
20997   if test "x$JAVA_HOME" != x; then
20998     JAVA_HOME_PROCESSED="$JAVA_HOME"
20999 
21000   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21001 
21002   # Input might be given as Windows format, start by converting to
21003   # unix format.
21004   path="$JAVA_HOME_PROCESSED"
21005   new_path=`$CYGPATH -u "$path"`
21006 
21007   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21008   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21009   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21010   # "foo.exe" is OK but "foo" is an error.
21011   #
21012   # This test is therefore slightly more accurate than "test -f" to check for file precense.
21013   # It is also a way to make sure we got the proper file name for the real test later on.
21014   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21015   if test "x$test_shortpath" = x; then
21016     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5
21017 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;}
21018     as_fn_error $? "Cannot locate the the path of JAVA_HOME_PROCESSED" "$LINENO" 5
21019   fi
21020 
21021   # Call helper function which possibly converts this using DOS-style short mode.
21022   # If so, the updated path is stored in $new_path.
21023 
21024   input_path="$new_path"
21025   # Check if we need to convert this using DOS-style short mode. If the path
21026   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21027   # take no chances and rewrite it.
21028   # Note: m4 eats our [], so we need to use [ and ] instead.
21029   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21030   if test "x$has_forbidden_chars" != x; then
21031     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21032     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21033     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21034     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21035       # Going to short mode and back again did indeed matter. Since short mode is
21036       # case insensitive, let's make it lowercase to improve readability.
21037       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21038       # Now convert it back to Unix-stile (cygpath)
21039       input_path=`$CYGPATH -u "$shortmode_path"`
21040       new_path="$input_path"
21041     fi
21042   fi
21043 
21044   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21045   if test "x$test_cygdrive_prefix" = x; then
21046     # As a simple fix, exclude /usr/bin since it's not a real path.
21047     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21048       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21049       # a path prefixed by /cygdrive for fixpath to work.
21050       new_path="$CYGWIN_ROOT_PATH$input_path"
21051     fi
21052   fi
21053 
21054 
21055   if test "x$path" != "x$new_path"; then
21056     JAVA_HOME_PROCESSED="$new_path"
21057     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5
21058 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;}
21059   fi
21060 
21061   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21062 
21063   path="$JAVA_HOME_PROCESSED"
21064   has_colon=`$ECHO $path | $GREP ^.:`
21065   new_path="$path"
21066   if test "x$has_colon" = x; then
21067     # Not in mixed or Windows style, start by that.
21068     new_path=`cmd //c echo $path`
21069   fi
21070 
21071 
21072   input_path="$new_path"
21073   # Check if we need to convert this using DOS-style short mode. If the path
21074   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21075   # take no chances and rewrite it.
21076   # Note: m4 eats our [], so we need to use [ and ] instead.
21077   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21078   if test "x$has_forbidden_chars" != x; then
21079     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21080     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21081   fi
21082 
21083 
21084   windows_path="$new_path"
21085   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21086     unix_path=`$CYGPATH -u "$windows_path"`
21087     new_path="$unix_path"
21088   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21089     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21090     new_path="$unix_path"
21091   fi
21092 
21093   if test "x$path" != "x$new_path"; then
21094     JAVA_HOME_PROCESSED="$new_path"
21095     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5
21096 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;}
21097   fi
21098 
21099   # Save the first 10 bytes of this path to the storage, so fixpath can work.
21100   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21101 
21102   else
21103     # We're on a posix platform. Hooray! :)
21104     path="$JAVA_HOME_PROCESSED"
21105     has_space=`$ECHO "$path" | $GREP " "`
21106     if test "x$has_space" != x; then
21107       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5
21108 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;}
21109       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21110     fi
21111 
21112     # Use eval to expand a potential ~
21113     eval path="$path"
21114     if test ! -f "$path" && test ! -d "$path"; then
21115       as_fn_error $? "The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is not found." "$LINENO" 5
21116     fi
21117 
21118     JAVA_HOME_PROCESSED="`cd "$path"; $THEPWDCMD -L`"
21119   fi
21120 
21121     if test ! -d "$JAVA_HOME_PROCESSED"; then
21122       { $as_echo "$as_me:${as_lineno-$LINENO}: Your JAVA_HOME points to a non-existing directory!" >&5
21123 $as_echo "$as_me: Your JAVA_HOME points to a non-existing directory!" >&6;}
21124     else
21125       # Aha, the user has set a JAVA_HOME
21126       # let us use that as the Boot JDK.
21127       BOOT_JDK="$JAVA_HOME_PROCESSED"
21128       BOOT_JDK_FOUND=maybe
21129       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using JAVA_HOME" >&5
21130 $as_echo "$as_me: Found potential Boot JDK using JAVA_HOME" >&6;}
21131     fi
21132   fi
21133 
21134 
21135     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21136     if test "x$BOOT_JDK_FOUND" = xmaybe; then
21137       # Do we have a bin/java?
21138       if test ! -x "$BOOT_JDK/bin/java"; then
21139         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21140 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21141         BOOT_JDK_FOUND=no
21142       else
21143         # Do we have a bin/javac?
21144         if test ! -x "$BOOT_JDK/bin/javac"; then
21145           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21146 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21147           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21148 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21149           BOOT_JDK_FOUND=no
21150         else
21151           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21152           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21153             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21154 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21155             BOOT_JDK_FOUND=no
21156           else
21157             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21158             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21159 
21160             # Extra M4 quote needed to protect [] in grep expression.
21161             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
21162             if test "x$FOUND_CORRECT_VERSION" = x; then
21163               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21164 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21165               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
21166 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
21167               BOOT_JDK_FOUND=no
21168             else
21169               # We're done! :-)
21170               BOOT_JDK_FOUND=yes
21171 
21172   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21173 
21174   # Input might be given as Windows format, start by converting to
21175   # unix format.
21176   path="$BOOT_JDK"
21177   new_path=`$CYGPATH -u "$path"`
21178 
21179   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21180   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21181   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21182   # "foo.exe" is OK but "foo" is an error.
21183   #
21184   # This test is therefore slightly more accurate than "test -f" to check for file precense.
21185   # It is also a way to make sure we got the proper file name for the real test later on.
21186   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21187   if test "x$test_shortpath" = x; then
21188     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21189 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21190     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21191   fi
21192 
21193   # Call helper function which possibly converts this using DOS-style short mode.
21194   # If so, the updated path is stored in $new_path.
21195 
21196   input_path="$new_path"
21197   # Check if we need to convert this using DOS-style short mode. If the path
21198   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21199   # take no chances and rewrite it.
21200   # Note: m4 eats our [], so we need to use [ and ] instead.
21201   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21202   if test "x$has_forbidden_chars" != x; then
21203     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21204     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21205     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21206     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21207       # Going to short mode and back again did indeed matter. Since short mode is
21208       # case insensitive, let's make it lowercase to improve readability.
21209       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21210       # Now convert it back to Unix-stile (cygpath)
21211       input_path=`$CYGPATH -u "$shortmode_path"`
21212       new_path="$input_path"
21213     fi
21214   fi
21215 
21216   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21217   if test "x$test_cygdrive_prefix" = x; then
21218     # As a simple fix, exclude /usr/bin since it's not a real path.
21219     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21220       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21221       # a path prefixed by /cygdrive for fixpath to work.
21222       new_path="$CYGWIN_ROOT_PATH$input_path"
21223     fi
21224   fi
21225 
21226 
21227   if test "x$path" != "x$new_path"; then
21228     BOOT_JDK="$new_path"
21229     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21230 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21231   fi
21232 
21233   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21234 
21235   path="$BOOT_JDK"
21236   has_colon=`$ECHO $path | $GREP ^.:`
21237   new_path="$path"
21238   if test "x$has_colon" = x; then
21239     # Not in mixed or Windows style, start by that.
21240     new_path=`cmd //c echo $path`
21241   fi
21242 
21243 
21244   input_path="$new_path"
21245   # Check if we need to convert this using DOS-style short mode. If the path
21246   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21247   # take no chances and rewrite it.
21248   # Note: m4 eats our [], so we need to use [ and ] instead.
21249   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21250   if test "x$has_forbidden_chars" != x; then
21251     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21252     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21253   fi
21254 
21255 
21256   windows_path="$new_path"
21257   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21258     unix_path=`$CYGPATH -u "$windows_path"`
21259     new_path="$unix_path"
21260   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21261     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21262     new_path="$unix_path"
21263   fi
21264 
21265   if test "x$path" != "x$new_path"; then
21266     BOOT_JDK="$new_path"
21267     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21268 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21269   fi
21270 
21271   # Save the first 10 bytes of this path to the storage, so fixpath can work.
21272   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21273 
21274   else
21275     # We're on a posix platform. Hooray! :)
21276     path="$BOOT_JDK"
21277     has_space=`$ECHO "$path" | $GREP " "`
21278     if test "x$has_space" != x; then
21279       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21280 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21281       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21282     fi
21283 
21284     # Use eval to expand a potential ~
21285     eval path="$path"
21286     if test ! -f "$path" && test ! -d "$path"; then
21287       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21288     fi
21289 
21290     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21291   fi
21292 
21293               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21294 $as_echo_n "checking for Boot JDK... " >&6; }
21295               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21296 $as_echo "$BOOT_JDK" >&6; }
21297               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21298 $as_echo_n "checking Boot JDK version... " >&6; }
21299               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21300               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21301 $as_echo "$BOOT_JDK_VERSION" >&6; }
21302             fi # end check jdk version
21303           fi # end check rt.jar
21304         fi # end check javac
21305       fi # end check java
21306     fi # end check boot jdk found
21307   fi
21308 
21309 
21310   # Test: Is there a java or javac in the PATH, which is a symlink to the JDK?
21311 
21312   if test "x$BOOT_JDK_FOUND" = xno; then
21313     # Now execute the test
21314 
21315   # Extract the first word of "javac", so it can be a program name with args.
21316 set dummy javac; ac_word=$2
21317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21318 $as_echo_n "checking for $ac_word... " >&6; }
21319 if ${ac_cv_path_JAVAC_CHECK+:} false; then :
21320   $as_echo_n "(cached) " >&6
21321 else
21322   case $JAVAC_CHECK in
21323   [\\/]* | ?:[\\/]*)
21324   ac_cv_path_JAVAC_CHECK="$JAVAC_CHECK" # Let the user override the test with a path.
21325   ;;
21326   *)
21327   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21328 for as_dir in $PATH
21329 do
21330   IFS=$as_save_IFS
21331   test -z "$as_dir" && as_dir=.
21332     for ac_exec_ext in '' $ac_executable_extensions; do
21333   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21334     ac_cv_path_JAVAC_CHECK="$as_dir/$ac_word$ac_exec_ext"
21335     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
21336     break 2
21337   fi
21338 done
21339   done
21340 IFS=$as_save_IFS
21341 
21342   ;;
21343 esac
21344 fi
21345 JAVAC_CHECK=$ac_cv_path_JAVAC_CHECK
21346 if test -n "$JAVAC_CHECK"; then
21347   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC_CHECK" >&5
21348 $as_echo "$JAVAC_CHECK" >&6; }
21349 else
21350   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21351 $as_echo "no" >&6; }
21352 fi
21353 
21354 
21355   # Extract the first word of "java", so it can be a program name with args.
21356 set dummy java; ac_word=$2
21357 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21358 $as_echo_n "checking for $ac_word... " >&6; }
21359 if ${ac_cv_path_JAVA_CHECK+:} false; then :
21360   $as_echo_n "(cached) " >&6
21361 else
21362   case $JAVA_CHECK in
21363   [\\/]* | ?:[\\/]*)
21364   ac_cv_path_JAVA_CHECK="$JAVA_CHECK" # Let the user override the test with a path.
21365   ;;
21366   *)
21367   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21368 for as_dir in $PATH
21369 do
21370   IFS=$as_save_IFS
21371   test -z "$as_dir" && as_dir=.
21372     for ac_exec_ext in '' $ac_executable_extensions; do
21373   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21374     ac_cv_path_JAVA_CHECK="$as_dir/$ac_word$ac_exec_ext"
21375     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
21376     break 2
21377   fi
21378 done
21379   done
21380 IFS=$as_save_IFS
21381 
21382   ;;
21383 esac
21384 fi
21385 JAVA_CHECK=$ac_cv_path_JAVA_CHECK
21386 if test -n "$JAVA_CHECK"; then
21387   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA_CHECK" >&5
21388 $as_echo "$JAVA_CHECK" >&6; }
21389 else
21390   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21391 $as_echo "no" >&6; }
21392 fi
21393 
21394 
21395   BINARY="$JAVAC_CHECK"
21396   if test "x$JAVAC_CHECK" = x; then
21397     BINARY="$JAVA_CHECK"
21398   fi
21399   if test "x$BINARY" != x; then
21400     # So there is a java(c) binary, it might be part of a JDK.
21401     # Lets find the JDK/JRE directory by following symbolic links.
21402     # Linux/GNU systems often have links from /usr/bin/java to
21403     # /etc/alternatives/java to the real JDK binary.
21404 
21405   if test "x$OPENJDK_BUILD_OS" != xwindows; then
21406     # Follow a chain of symbolic links. Use readlink
21407     # where it exists, else fall back to horribly
21408     # complicated shell code.
21409     if test "x$READLINK_TESTED" != yes; then
21410       # On MacOSX there is a readlink tool with a different
21411       # purpose than the GNU readlink tool. Check the found readlink.
21412       ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
21413       if test "x$ISGNU" = x; then
21414         # A readlink that we do not know how to use.
21415         # Are there other non-GNU readlinks out there?
21416         READLINK_TESTED=yes
21417         READLINK=
21418       fi
21419     fi
21420 
21421     if test "x$READLINK" != x; then
21422       BINARY=`$READLINK -f $BINARY`
21423     else
21424       # Save the current directory for restoring afterwards
21425       STARTDIR=$PWD
21426       COUNTER=0
21427       sym_link_dir=`$DIRNAME $BINARY`
21428       sym_link_file=`$BASENAME $BINARY`
21429       cd $sym_link_dir
21430       # Use -P flag to resolve symlinks in directories.
21431       cd `$THEPWDCMD -P`
21432       sym_link_dir=`$THEPWDCMD -P`
21433       # Resolve file symlinks
21434       while test $COUNTER -lt 20; do
21435         ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
21436         if test "x$ISLINK" == x; then
21437           # This is not a symbolic link! We are done!
21438           break
21439         fi
21440         # Again resolve directory symlinks since the target of the just found
21441         # link could be in a different directory
21442         cd `$DIRNAME $ISLINK`
21443         sym_link_dir=`$THEPWDCMD -P`
21444         sym_link_file=`$BASENAME $ISLINK`
21445         let COUNTER=COUNTER+1
21446       done
21447       cd $STARTDIR
21448       BINARY=$sym_link_dir/$sym_link_file
21449     fi
21450   fi
21451 
21452     BOOT_JDK=`dirname "$BINARY"`
21453     BOOT_JDK=`cd "$BOOT_JDK/.."; pwd`
21454     if test -x "$BOOT_JDK/bin/javac" && test -x "$BOOT_JDK/bin/java"; then
21455       # Looks like we found ourselves an JDK
21456       BOOT_JDK_FOUND=maybe
21457       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using java(c) in PATH" >&5
21458 $as_echo "$as_me: Found potential Boot JDK using java(c) in PATH" >&6;}
21459     fi
21460   fi
21461 
21462 
21463     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21464     if test "x$BOOT_JDK_FOUND" = xmaybe; then
21465       # Do we have a bin/java?
21466       if test ! -x "$BOOT_JDK/bin/java"; then
21467         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21468 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21469         BOOT_JDK_FOUND=no
21470       else
21471         # Do we have a bin/javac?
21472         if test ! -x "$BOOT_JDK/bin/javac"; then
21473           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21474 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21475           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21476 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21477           BOOT_JDK_FOUND=no
21478         else
21479           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21480           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21481             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21482 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21483             BOOT_JDK_FOUND=no
21484           else
21485             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21486             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21487 
21488             # Extra M4 quote needed to protect [] in grep expression.
21489             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
21490             if test "x$FOUND_CORRECT_VERSION" = x; then
21491               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21492 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21493               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
21494 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
21495               BOOT_JDK_FOUND=no
21496             else
21497               # We're done! :-)
21498               BOOT_JDK_FOUND=yes
21499 
21500   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21501 
21502   # Input might be given as Windows format, start by converting to
21503   # unix format.
21504   path="$BOOT_JDK"
21505   new_path=`$CYGPATH -u "$path"`
21506 
21507   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21508   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21509   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21510   # "foo.exe" is OK but "foo" is an error.
21511   #
21512   # This test is therefore slightly more accurate than "test -f" to check for file precense.
21513   # It is also a way to make sure we got the proper file name for the real test later on.
21514   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21515   if test "x$test_shortpath" = x; then
21516     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21517 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21518     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21519   fi
21520 
21521   # Call helper function which possibly converts this using DOS-style short mode.
21522   # If so, the updated path is stored in $new_path.
21523 
21524   input_path="$new_path"
21525   # Check if we need to convert this using DOS-style short mode. If the path
21526   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21527   # take no chances and rewrite it.
21528   # Note: m4 eats our [], so we need to use [ and ] instead.
21529   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21530   if test "x$has_forbidden_chars" != x; then
21531     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21532     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21533     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21534     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21535       # Going to short mode and back again did indeed matter. Since short mode is
21536       # case insensitive, let's make it lowercase to improve readability.
21537       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21538       # Now convert it back to Unix-stile (cygpath)
21539       input_path=`$CYGPATH -u "$shortmode_path"`
21540       new_path="$input_path"
21541     fi
21542   fi
21543 
21544   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21545   if test "x$test_cygdrive_prefix" = x; then
21546     # As a simple fix, exclude /usr/bin since it's not a real path.
21547     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21548       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21549       # a path prefixed by /cygdrive for fixpath to work.
21550       new_path="$CYGWIN_ROOT_PATH$input_path"
21551     fi
21552   fi
21553 
21554 
21555   if test "x$path" != "x$new_path"; then
21556     BOOT_JDK="$new_path"
21557     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21558 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21559   fi
21560 
21561   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21562 
21563   path="$BOOT_JDK"
21564   has_colon=`$ECHO $path | $GREP ^.:`
21565   new_path="$path"
21566   if test "x$has_colon" = x; then
21567     # Not in mixed or Windows style, start by that.
21568     new_path=`cmd //c echo $path`
21569   fi
21570 
21571 
21572   input_path="$new_path"
21573   # Check if we need to convert this using DOS-style short mode. If the path
21574   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21575   # take no chances and rewrite it.
21576   # Note: m4 eats our [], so we need to use [ and ] instead.
21577   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21578   if test "x$has_forbidden_chars" != x; then
21579     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21580     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21581   fi
21582 
21583 
21584   windows_path="$new_path"
21585   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21586     unix_path=`$CYGPATH -u "$windows_path"`
21587     new_path="$unix_path"
21588   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21589     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21590     new_path="$unix_path"
21591   fi
21592 
21593   if test "x$path" != "x$new_path"; then
21594     BOOT_JDK="$new_path"
21595     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21596 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21597   fi
21598 
21599   # Save the first 10 bytes of this path to the storage, so fixpath can work.
21600   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21601 
21602   else
21603     # We're on a posix platform. Hooray! :)
21604     path="$BOOT_JDK"
21605     has_space=`$ECHO "$path" | $GREP " "`
21606     if test "x$has_space" != x; then
21607       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21608 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21609       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21610     fi
21611 
21612     # Use eval to expand a potential ~
21613     eval path="$path"
21614     if test ! -f "$path" && test ! -d "$path"; then
21615       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21616     fi
21617 
21618     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21619   fi
21620 
21621               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21622 $as_echo_n "checking for Boot JDK... " >&6; }
21623               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21624 $as_echo "$BOOT_JDK" >&6; }
21625               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21626 $as_echo_n "checking Boot JDK version... " >&6; }
21627               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21628               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21629 $as_echo "$BOOT_JDK_VERSION" >&6; }
21630             fi # end check jdk version
21631           fi # end check rt.jar
21632         fi # end check javac
21633       fi # end check java
21634     fi # end check boot jdk found
21635   fi
21636 
21637 
21638   # Test: Is there a JDK installed in default, well-known locations?
21639 
21640   if test "x$BOOT_JDK_FOUND" = xno; then
21641     # Now execute the test
21642 
21643   if test "x$OPENJDK_TARGET_OS" = xwindows; then
21644 
21645   if test "x$BOOT_JDK_FOUND" = xno; then
21646     # Now execute the test
21647 
21648   if test "x$ProgramW6432" != x; then
21649     VIRTUAL_DIR="$ProgramW6432/Java"
21650 
21651   windows_path="$VIRTUAL_DIR"
21652   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21653     unix_path=`$CYGPATH -u "$windows_path"`
21654     VIRTUAL_DIR="$unix_path"
21655   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21656     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21657     VIRTUAL_DIR="$unix_path"
21658   fi
21659 
21660 
21661   BOOT_JDK_PREFIX="$VIRTUAL_DIR"
21662   BOOT_JDK_SUFFIX=""
21663   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
21664   if test "x$ALL_JDKS_FOUND" != x; then
21665     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
21666 
21667   if test "x$BOOT_JDK_FOUND" = xno; then
21668     # Now execute the test
21669 
21670         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
21671         if test -d "$BOOT_JDK"; then
21672           BOOT_JDK_FOUND=maybe
21673           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
21674 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
21675         fi
21676 
21677 
21678     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21679     if test "x$BOOT_JDK_FOUND" = xmaybe; then
21680       # Do we have a bin/java?
21681       if test ! -x "$BOOT_JDK/bin/java"; then
21682         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21683 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21684         BOOT_JDK_FOUND=no
21685       else
21686         # Do we have a bin/javac?
21687         if test ! -x "$BOOT_JDK/bin/javac"; then
21688           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21689 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21690           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21691 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21692           BOOT_JDK_FOUND=no
21693         else
21694           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21695           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21696             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21697 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21698             BOOT_JDK_FOUND=no
21699           else
21700             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21701             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21702 
21703             # Extra M4 quote needed to protect [] in grep expression.
21704             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
21705             if test "x$FOUND_CORRECT_VERSION" = x; then
21706               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21707 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21708               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
21709 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
21710               BOOT_JDK_FOUND=no
21711             else
21712               # We're done! :-)
21713               BOOT_JDK_FOUND=yes
21714 
21715   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21716 
21717   # Input might be given as Windows format, start by converting to
21718   # unix format.
21719   path="$BOOT_JDK"
21720   new_path=`$CYGPATH -u "$path"`
21721 
21722   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21723   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21724   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21725   # "foo.exe" is OK but "foo" is an error.
21726   #
21727   # This test is therefore slightly more accurate than "test -f" to check for file precense.
21728   # It is also a way to make sure we got the proper file name for the real test later on.
21729   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21730   if test "x$test_shortpath" = x; then
21731     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21732 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21733     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21734   fi
21735 
21736   # Call helper function which possibly converts this using DOS-style short mode.
21737   # If so, the updated path is stored in $new_path.
21738 
21739   input_path="$new_path"
21740   # Check if we need to convert this using DOS-style short mode. If the path
21741   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21742   # take no chances and rewrite it.
21743   # Note: m4 eats our [], so we need to use [ and ] instead.
21744   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21745   if test "x$has_forbidden_chars" != x; then
21746     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21747     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21748     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21749     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21750       # Going to short mode and back again did indeed matter. Since short mode is
21751       # case insensitive, let's make it lowercase to improve readability.
21752       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21753       # Now convert it back to Unix-stile (cygpath)
21754       input_path=`$CYGPATH -u "$shortmode_path"`
21755       new_path="$input_path"
21756     fi
21757   fi
21758 
21759   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21760   if test "x$test_cygdrive_prefix" = x; then
21761     # As a simple fix, exclude /usr/bin since it's not a real path.
21762     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21763       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21764       # a path prefixed by /cygdrive for fixpath to work.
21765       new_path="$CYGWIN_ROOT_PATH$input_path"
21766     fi
21767   fi
21768 
21769 
21770   if test "x$path" != "x$new_path"; then
21771     BOOT_JDK="$new_path"
21772     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21773 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21774   fi
21775 
21776   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21777 
21778   path="$BOOT_JDK"
21779   has_colon=`$ECHO $path | $GREP ^.:`
21780   new_path="$path"
21781   if test "x$has_colon" = x; then
21782     # Not in mixed or Windows style, start by that.
21783     new_path=`cmd //c echo $path`
21784   fi
21785 
21786 
21787   input_path="$new_path"
21788   # Check if we need to convert this using DOS-style short mode. If the path
21789   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21790   # take no chances and rewrite it.
21791   # Note: m4 eats our [], so we need to use [ and ] instead.
21792   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21793   if test "x$has_forbidden_chars" != x; then
21794     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21795     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21796   fi
21797 
21798 
21799   windows_path="$new_path"
21800   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21801     unix_path=`$CYGPATH -u "$windows_path"`
21802     new_path="$unix_path"
21803   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21804     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21805     new_path="$unix_path"
21806   fi
21807 
21808   if test "x$path" != "x$new_path"; then
21809     BOOT_JDK="$new_path"
21810     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21811 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21812   fi
21813 
21814   # Save the first 10 bytes of this path to the storage, so fixpath can work.
21815   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21816 
21817   else
21818     # We're on a posix platform. Hooray! :)
21819     path="$BOOT_JDK"
21820     has_space=`$ECHO "$path" | $GREP " "`
21821     if test "x$has_space" != x; then
21822       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21823 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21824       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21825     fi
21826 
21827     # Use eval to expand a potential ~
21828     eval path="$path"
21829     if test ! -f "$path" && test ! -d "$path"; then
21830       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21831     fi
21832 
21833     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21834   fi
21835 
21836               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21837 $as_echo_n "checking for Boot JDK... " >&6; }
21838               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21839 $as_echo "$BOOT_JDK" >&6; }
21840               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21841 $as_echo_n "checking Boot JDK version... " >&6; }
21842               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21843               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21844 $as_echo "$BOOT_JDK_VERSION" >&6; }
21845             fi # end check jdk version
21846           fi # end check rt.jar
21847         fi # end check javac
21848       fi # end check java
21849     fi # end check boot jdk found
21850   fi
21851 
21852     done
21853   fi
21854 
21855   fi
21856 
21857 
21858     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21859     if test "x$BOOT_JDK_FOUND" = xmaybe; then
21860       # Do we have a bin/java?
21861       if test ! -x "$BOOT_JDK/bin/java"; then
21862         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21863 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21864         BOOT_JDK_FOUND=no
21865       else
21866         # Do we have a bin/javac?
21867         if test ! -x "$BOOT_JDK/bin/javac"; then
21868           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21869 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21870           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21871 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21872           BOOT_JDK_FOUND=no
21873         else
21874           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21875           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21876             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21877 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21878             BOOT_JDK_FOUND=no
21879           else
21880             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21881             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21882 
21883             # Extra M4 quote needed to protect [] in grep expression.
21884             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
21885             if test "x$FOUND_CORRECT_VERSION" = x; then
21886               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21887 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21888               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
21889 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
21890               BOOT_JDK_FOUND=no
21891             else
21892               # We're done! :-)
21893               BOOT_JDK_FOUND=yes
21894 
21895   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21896 
21897   # Input might be given as Windows format, start by converting to
21898   # unix format.
21899   path="$BOOT_JDK"
21900   new_path=`$CYGPATH -u "$path"`
21901 
21902   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21903   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21904   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21905   # "foo.exe" is OK but "foo" is an error.
21906   #
21907   # This test is therefore slightly more accurate than "test -f" to check for file precense.
21908   # It is also a way to make sure we got the proper file name for the real test later on.
21909   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21910   if test "x$test_shortpath" = x; then
21911     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21912 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21913     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21914   fi
21915 
21916   # Call helper function which possibly converts this using DOS-style short mode.
21917   # If so, the updated path is stored in $new_path.
21918 
21919   input_path="$new_path"
21920   # Check if we need to convert this using DOS-style short mode. If the path
21921   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21922   # take no chances and rewrite it.
21923   # Note: m4 eats our [], so we need to use [ and ] instead.
21924   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21925   if test "x$has_forbidden_chars" != x; then
21926     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21927     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21928     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21929     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21930       # Going to short mode and back again did indeed matter. Since short mode is
21931       # case insensitive, let's make it lowercase to improve readability.
21932       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21933       # Now convert it back to Unix-stile (cygpath)
21934       input_path=`$CYGPATH -u "$shortmode_path"`
21935       new_path="$input_path"
21936     fi
21937   fi
21938 
21939   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21940   if test "x$test_cygdrive_prefix" = x; then
21941     # As a simple fix, exclude /usr/bin since it's not a real path.
21942     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21943       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21944       # a path prefixed by /cygdrive for fixpath to work.
21945       new_path="$CYGWIN_ROOT_PATH$input_path"
21946     fi
21947   fi
21948 
21949 
21950   if test "x$path" != "x$new_path"; then
21951     BOOT_JDK="$new_path"
21952     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21953 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21954   fi
21955 
21956   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21957 
21958   path="$BOOT_JDK"
21959   has_colon=`$ECHO $path | $GREP ^.:`
21960   new_path="$path"
21961   if test "x$has_colon" = x; then
21962     # Not in mixed or Windows style, start by that.
21963     new_path=`cmd //c echo $path`
21964   fi
21965 
21966 
21967   input_path="$new_path"
21968   # Check if we need to convert this using DOS-style short mode. If the path
21969   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21970   # take no chances and rewrite it.
21971   # Note: m4 eats our [], so we need to use [ and ] instead.
21972   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21973   if test "x$has_forbidden_chars" != x; then
21974     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21975     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21976   fi
21977 
21978 
21979   windows_path="$new_path"
21980   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21981     unix_path=`$CYGPATH -u "$windows_path"`
21982     new_path="$unix_path"
21983   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21984     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21985     new_path="$unix_path"
21986   fi
21987 
21988   if test "x$path" != "x$new_path"; then
21989     BOOT_JDK="$new_path"
21990     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21991 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21992   fi
21993 
21994   # Save the first 10 bytes of this path to the storage, so fixpath can work.
21995   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21996 
21997   else
21998     # We're on a posix platform. Hooray! :)
21999     path="$BOOT_JDK"
22000     has_space=`$ECHO "$path" | $GREP " "`
22001     if test "x$has_space" != x; then
22002       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22003 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22004       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22005     fi
22006 
22007     # Use eval to expand a potential ~
22008     eval path="$path"
22009     if test ! -f "$path" && test ! -d "$path"; then
22010       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22011     fi
22012 
22013     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22014   fi
22015 
22016               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22017 $as_echo_n "checking for Boot JDK... " >&6; }
22018               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22019 $as_echo "$BOOT_JDK" >&6; }
22020               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22021 $as_echo_n "checking Boot JDK version... " >&6; }
22022               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22023               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22024 $as_echo "$BOOT_JDK_VERSION" >&6; }
22025             fi # end check jdk version
22026           fi # end check rt.jar
22027         fi # end check javac
22028       fi # end check java
22029     fi # end check boot jdk found
22030   fi
22031 
22032 
22033   if test "x$BOOT_JDK_FOUND" = xno; then
22034     # Now execute the test
22035 
22036   if test "x$PROGRAMW6432" != x; then
22037     VIRTUAL_DIR="$PROGRAMW6432/Java"
22038 
22039   windows_path="$VIRTUAL_DIR"
22040   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22041     unix_path=`$CYGPATH -u "$windows_path"`
22042     VIRTUAL_DIR="$unix_path"
22043   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22044     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22045     VIRTUAL_DIR="$unix_path"
22046   fi
22047 
22048 
22049   BOOT_JDK_PREFIX="$VIRTUAL_DIR"
22050   BOOT_JDK_SUFFIX=""
22051   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
22052   if test "x$ALL_JDKS_FOUND" != x; then
22053     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
22054 
22055   if test "x$BOOT_JDK_FOUND" = xno; then
22056     # Now execute the test
22057 
22058         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
22059         if test -d "$BOOT_JDK"; then
22060           BOOT_JDK_FOUND=maybe
22061           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
22062 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
22063         fi
22064 
22065 
22066     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22067     if test "x$BOOT_JDK_FOUND" = xmaybe; then
22068       # Do we have a bin/java?
22069       if test ! -x "$BOOT_JDK/bin/java"; then
22070         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22071 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22072         BOOT_JDK_FOUND=no
22073       else
22074         # Do we have a bin/javac?
22075         if test ! -x "$BOOT_JDK/bin/javac"; then
22076           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22077 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22078           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22079 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22080           BOOT_JDK_FOUND=no
22081         else
22082           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22083           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22084             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22085 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22086             BOOT_JDK_FOUND=no
22087           else
22088             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22089             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22090 
22091             # Extra M4 quote needed to protect [] in grep expression.
22092             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22093             if test "x$FOUND_CORRECT_VERSION" = x; then
22094               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22095 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22096               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22097 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22098               BOOT_JDK_FOUND=no
22099             else
22100               # We're done! :-)
22101               BOOT_JDK_FOUND=yes
22102 
22103   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22104 
22105   # Input might be given as Windows format, start by converting to
22106   # unix format.
22107   path="$BOOT_JDK"
22108   new_path=`$CYGPATH -u "$path"`
22109 
22110   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22111   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22112   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22113   # "foo.exe" is OK but "foo" is an error.
22114   #
22115   # This test is therefore slightly more accurate than "test -f" to check for file precense.
22116   # It is also a way to make sure we got the proper file name for the real test later on.
22117   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22118   if test "x$test_shortpath" = x; then
22119     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22120 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22121     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22122   fi
22123 
22124   # Call helper function which possibly converts this using DOS-style short mode.
22125   # If so, the updated path is stored in $new_path.
22126 
22127   input_path="$new_path"
22128   # Check if we need to convert this using DOS-style short mode. If the path
22129   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22130   # take no chances and rewrite it.
22131   # Note: m4 eats our [], so we need to use [ and ] instead.
22132   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22133   if test "x$has_forbidden_chars" != x; then
22134     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22135     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22136     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22137     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22138       # Going to short mode and back again did indeed matter. Since short mode is
22139       # case insensitive, let's make it lowercase to improve readability.
22140       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22141       # Now convert it back to Unix-stile (cygpath)
22142       input_path=`$CYGPATH -u "$shortmode_path"`
22143       new_path="$input_path"
22144     fi
22145   fi
22146 
22147   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22148   if test "x$test_cygdrive_prefix" = x; then
22149     # As a simple fix, exclude /usr/bin since it's not a real path.
22150     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22151       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22152       # a path prefixed by /cygdrive for fixpath to work.
22153       new_path="$CYGWIN_ROOT_PATH$input_path"
22154     fi
22155   fi
22156 
22157 
22158   if test "x$path" != "x$new_path"; then
22159     BOOT_JDK="$new_path"
22160     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22161 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22162   fi
22163 
22164   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22165 
22166   path="$BOOT_JDK"
22167   has_colon=`$ECHO $path | $GREP ^.:`
22168   new_path="$path"
22169   if test "x$has_colon" = x; then
22170     # Not in mixed or Windows style, start by that.
22171     new_path=`cmd //c echo $path`
22172   fi
22173 
22174 
22175   input_path="$new_path"
22176   # Check if we need to convert this using DOS-style short mode. If the path
22177   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22178   # take no chances and rewrite it.
22179   # Note: m4 eats our [], so we need to use [ and ] instead.
22180   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22181   if test "x$has_forbidden_chars" != x; then
22182     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22183     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22184   fi
22185 
22186 
22187   windows_path="$new_path"
22188   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22189     unix_path=`$CYGPATH -u "$windows_path"`
22190     new_path="$unix_path"
22191   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22192     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22193     new_path="$unix_path"
22194   fi
22195 
22196   if test "x$path" != "x$new_path"; then
22197     BOOT_JDK="$new_path"
22198     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22199 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22200   fi
22201 
22202   # Save the first 10 bytes of this path to the storage, so fixpath can work.
22203   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22204 
22205   else
22206     # We're on a posix platform. Hooray! :)
22207     path="$BOOT_JDK"
22208     has_space=`$ECHO "$path" | $GREP " "`
22209     if test "x$has_space" != x; then
22210       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22211 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22212       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22213     fi
22214 
22215     # Use eval to expand a potential ~
22216     eval path="$path"
22217     if test ! -f "$path" && test ! -d "$path"; then
22218       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22219     fi
22220 
22221     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22222   fi
22223 
22224               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22225 $as_echo_n "checking for Boot JDK... " >&6; }
22226               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22227 $as_echo "$BOOT_JDK" >&6; }
22228               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22229 $as_echo_n "checking Boot JDK version... " >&6; }
22230               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22231               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22232 $as_echo "$BOOT_JDK_VERSION" >&6; }
22233             fi # end check jdk version
22234           fi # end check rt.jar
22235         fi # end check javac
22236       fi # end check java
22237     fi # end check boot jdk found
22238   fi
22239 
22240     done
22241   fi
22242 
22243   fi
22244 
22245 
22246     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22247     if test "x$BOOT_JDK_FOUND" = xmaybe; then
22248       # Do we have a bin/java?
22249       if test ! -x "$BOOT_JDK/bin/java"; then
22250         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22251 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22252         BOOT_JDK_FOUND=no
22253       else
22254         # Do we have a bin/javac?
22255         if test ! -x "$BOOT_JDK/bin/javac"; then
22256           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22257 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22258           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22259 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22260           BOOT_JDK_FOUND=no
22261         else
22262           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22263           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22264             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22265 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22266             BOOT_JDK_FOUND=no
22267           else
22268             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22269             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22270 
22271             # Extra M4 quote needed to protect [] in grep expression.
22272             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22273             if test "x$FOUND_CORRECT_VERSION" = x; then
22274               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22275 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22276               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22277 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22278               BOOT_JDK_FOUND=no
22279             else
22280               # We're done! :-)
22281               BOOT_JDK_FOUND=yes
22282 
22283   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22284 
22285   # Input might be given as Windows format, start by converting to
22286   # unix format.
22287   path="$BOOT_JDK"
22288   new_path=`$CYGPATH -u "$path"`
22289 
22290   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22291   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22292   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22293   # "foo.exe" is OK but "foo" is an error.
22294   #
22295   # This test is therefore slightly more accurate than "test -f" to check for file precense.
22296   # It is also a way to make sure we got the proper file name for the real test later on.
22297   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22298   if test "x$test_shortpath" = x; then
22299     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22300 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22301     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22302   fi
22303 
22304   # Call helper function which possibly converts this using DOS-style short mode.
22305   # If so, the updated path is stored in $new_path.
22306 
22307   input_path="$new_path"
22308   # Check if we need to convert this using DOS-style short mode. If the path
22309   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22310   # take no chances and rewrite it.
22311   # Note: m4 eats our [], so we need to use [ and ] instead.
22312   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22313   if test "x$has_forbidden_chars" != x; then
22314     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22315     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22316     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22317     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22318       # Going to short mode and back again did indeed matter. Since short mode is
22319       # case insensitive, let's make it lowercase to improve readability.
22320       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22321       # Now convert it back to Unix-stile (cygpath)
22322       input_path=`$CYGPATH -u "$shortmode_path"`
22323       new_path="$input_path"
22324     fi
22325   fi
22326 
22327   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22328   if test "x$test_cygdrive_prefix" = x; then
22329     # As a simple fix, exclude /usr/bin since it's not a real path.
22330     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22331       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22332       # a path prefixed by /cygdrive for fixpath to work.
22333       new_path="$CYGWIN_ROOT_PATH$input_path"
22334     fi
22335   fi
22336 
22337 
22338   if test "x$path" != "x$new_path"; then
22339     BOOT_JDK="$new_path"
22340     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22341 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22342   fi
22343 
22344   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22345 
22346   path="$BOOT_JDK"
22347   has_colon=`$ECHO $path | $GREP ^.:`
22348   new_path="$path"
22349   if test "x$has_colon" = x; then
22350     # Not in mixed or Windows style, start by that.
22351     new_path=`cmd //c echo $path`
22352   fi
22353 
22354 
22355   input_path="$new_path"
22356   # Check if we need to convert this using DOS-style short mode. If the path
22357   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22358   # take no chances and rewrite it.
22359   # Note: m4 eats our [], so we need to use [ and ] instead.
22360   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22361   if test "x$has_forbidden_chars" != x; then
22362     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22363     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22364   fi
22365 
22366 
22367   windows_path="$new_path"
22368   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22369     unix_path=`$CYGPATH -u "$windows_path"`
22370     new_path="$unix_path"
22371   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22372     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22373     new_path="$unix_path"
22374   fi
22375 
22376   if test "x$path" != "x$new_path"; then
22377     BOOT_JDK="$new_path"
22378     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22379 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22380   fi
22381 
22382   # Save the first 10 bytes of this path to the storage, so fixpath can work.
22383   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22384 
22385   else
22386     # We're on a posix platform. Hooray! :)
22387     path="$BOOT_JDK"
22388     has_space=`$ECHO "$path" | $GREP " "`
22389     if test "x$has_space" != x; then
22390       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22391 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22392       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22393     fi
22394 
22395     # Use eval to expand a potential ~
22396     eval path="$path"
22397     if test ! -f "$path" && test ! -d "$path"; then
22398       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22399     fi
22400 
22401     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22402   fi
22403 
22404               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22405 $as_echo_n "checking for Boot JDK... " >&6; }
22406               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22407 $as_echo "$BOOT_JDK" >&6; }
22408               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22409 $as_echo_n "checking Boot JDK version... " >&6; }
22410               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22411               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22412 $as_echo "$BOOT_JDK_VERSION" >&6; }
22413             fi # end check jdk version
22414           fi # end check rt.jar
22415         fi # end check javac
22416       fi # end check java
22417     fi # end check boot jdk found
22418   fi
22419 
22420 
22421   if test "x$BOOT_JDK_FOUND" = xno; then
22422     # Now execute the test
22423 
22424   if test "x$PROGRAMFILES" != x; then
22425     VIRTUAL_DIR="$PROGRAMFILES/Java"
22426 
22427   windows_path="$VIRTUAL_DIR"
22428   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22429     unix_path=`$CYGPATH -u "$windows_path"`
22430     VIRTUAL_DIR="$unix_path"
22431   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22432     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22433     VIRTUAL_DIR="$unix_path"
22434   fi
22435 
22436 
22437   BOOT_JDK_PREFIX="$VIRTUAL_DIR"
22438   BOOT_JDK_SUFFIX=""
22439   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
22440   if test "x$ALL_JDKS_FOUND" != x; then
22441     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
22442 
22443   if test "x$BOOT_JDK_FOUND" = xno; then
22444     # Now execute the test
22445 
22446         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
22447         if test -d "$BOOT_JDK"; then
22448           BOOT_JDK_FOUND=maybe
22449           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
22450 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
22451         fi
22452 
22453 
22454     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22455     if test "x$BOOT_JDK_FOUND" = xmaybe; then
22456       # Do we have a bin/java?
22457       if test ! -x "$BOOT_JDK/bin/java"; then
22458         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22459 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22460         BOOT_JDK_FOUND=no
22461       else
22462         # Do we have a bin/javac?
22463         if test ! -x "$BOOT_JDK/bin/javac"; then
22464           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22465 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22466           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22467 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22468           BOOT_JDK_FOUND=no
22469         else
22470           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22471           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22472             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22473 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22474             BOOT_JDK_FOUND=no
22475           else
22476             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22477             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22478 
22479             # Extra M4 quote needed to protect [] in grep expression.
22480             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22481             if test "x$FOUND_CORRECT_VERSION" = x; then
22482               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22483 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22484               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22485 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22486               BOOT_JDK_FOUND=no
22487             else
22488               # We're done! :-)
22489               BOOT_JDK_FOUND=yes
22490 
22491   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22492 
22493   # Input might be given as Windows format, start by converting to
22494   # unix format.
22495   path="$BOOT_JDK"
22496   new_path=`$CYGPATH -u "$path"`
22497 
22498   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22499   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22500   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22501   # "foo.exe" is OK but "foo" is an error.
22502   #
22503   # This test is therefore slightly more accurate than "test -f" to check for file precense.
22504   # It is also a way to make sure we got the proper file name for the real test later on.
22505   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22506   if test "x$test_shortpath" = x; then
22507     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22508 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22509     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22510   fi
22511 
22512   # Call helper function which possibly converts this using DOS-style short mode.
22513   # If so, the updated path is stored in $new_path.
22514 
22515   input_path="$new_path"
22516   # Check if we need to convert this using DOS-style short mode. If the path
22517   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22518   # take no chances and rewrite it.
22519   # Note: m4 eats our [], so we need to use [ and ] instead.
22520   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22521   if test "x$has_forbidden_chars" != x; then
22522     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22523     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22524     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22525     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22526       # Going to short mode and back again did indeed matter. Since short mode is
22527       # case insensitive, let's make it lowercase to improve readability.
22528       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22529       # Now convert it back to Unix-stile (cygpath)
22530       input_path=`$CYGPATH -u "$shortmode_path"`
22531       new_path="$input_path"
22532     fi
22533   fi
22534 
22535   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22536   if test "x$test_cygdrive_prefix" = x; then
22537     # As a simple fix, exclude /usr/bin since it's not a real path.
22538     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22539       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22540       # a path prefixed by /cygdrive for fixpath to work.
22541       new_path="$CYGWIN_ROOT_PATH$input_path"
22542     fi
22543   fi
22544 
22545 
22546   if test "x$path" != "x$new_path"; then
22547     BOOT_JDK="$new_path"
22548     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22549 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22550   fi
22551 
22552   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22553 
22554   path="$BOOT_JDK"
22555   has_colon=`$ECHO $path | $GREP ^.:`
22556   new_path="$path"
22557   if test "x$has_colon" = x; then
22558     # Not in mixed or Windows style, start by that.
22559     new_path=`cmd //c echo $path`
22560   fi
22561 
22562 
22563   input_path="$new_path"
22564   # Check if we need to convert this using DOS-style short mode. If the path
22565   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22566   # take no chances and rewrite it.
22567   # Note: m4 eats our [], so we need to use [ and ] instead.
22568   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22569   if test "x$has_forbidden_chars" != x; then
22570     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22571     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22572   fi
22573 
22574 
22575   windows_path="$new_path"
22576   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22577     unix_path=`$CYGPATH -u "$windows_path"`
22578     new_path="$unix_path"
22579   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22580     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22581     new_path="$unix_path"
22582   fi
22583 
22584   if test "x$path" != "x$new_path"; then
22585     BOOT_JDK="$new_path"
22586     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22587 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22588   fi
22589 
22590   # Save the first 10 bytes of this path to the storage, so fixpath can work.
22591   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22592 
22593   else
22594     # We're on a posix platform. Hooray! :)
22595     path="$BOOT_JDK"
22596     has_space=`$ECHO "$path" | $GREP " "`
22597     if test "x$has_space" != x; then
22598       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22599 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22600       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22601     fi
22602 
22603     # Use eval to expand a potential ~
22604     eval path="$path"
22605     if test ! -f "$path" && test ! -d "$path"; then
22606       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22607     fi
22608 
22609     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22610   fi
22611 
22612               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22613 $as_echo_n "checking for Boot JDK... " >&6; }
22614               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22615 $as_echo "$BOOT_JDK" >&6; }
22616               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22617 $as_echo_n "checking Boot JDK version... " >&6; }
22618               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22619               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22620 $as_echo "$BOOT_JDK_VERSION" >&6; }
22621             fi # end check jdk version
22622           fi # end check rt.jar
22623         fi # end check javac
22624       fi # end check java
22625     fi # end check boot jdk found
22626   fi
22627 
22628     done
22629   fi
22630 
22631   fi
22632 
22633 
22634     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22635     if test "x$BOOT_JDK_FOUND" = xmaybe; then
22636       # Do we have a bin/java?
22637       if test ! -x "$BOOT_JDK/bin/java"; then
22638         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22639 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22640         BOOT_JDK_FOUND=no
22641       else
22642         # Do we have a bin/javac?
22643         if test ! -x "$BOOT_JDK/bin/javac"; then
22644           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22645 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22646           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22647 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22648           BOOT_JDK_FOUND=no
22649         else
22650           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22651           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22652             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22653 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22654             BOOT_JDK_FOUND=no
22655           else
22656             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22657             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22658 
22659             # Extra M4 quote needed to protect [] in grep expression.
22660             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22661             if test "x$FOUND_CORRECT_VERSION" = x; then
22662               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22663 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22664               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22665 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22666               BOOT_JDK_FOUND=no
22667             else
22668               # We're done! :-)
22669               BOOT_JDK_FOUND=yes
22670 
22671   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22672 
22673   # Input might be given as Windows format, start by converting to
22674   # unix format.
22675   path="$BOOT_JDK"
22676   new_path=`$CYGPATH -u "$path"`
22677 
22678   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22679   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22680   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22681   # "foo.exe" is OK but "foo" is an error.
22682   #
22683   # This test is therefore slightly more accurate than "test -f" to check for file precense.
22684   # It is also a way to make sure we got the proper file name for the real test later on.
22685   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22686   if test "x$test_shortpath" = x; then
22687     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22688 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22689     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22690   fi
22691 
22692   # Call helper function which possibly converts this using DOS-style short mode.
22693   # If so, the updated path is stored in $new_path.
22694 
22695   input_path="$new_path"
22696   # Check if we need to convert this using DOS-style short mode. If the path
22697   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22698   # take no chances and rewrite it.
22699   # Note: m4 eats our [], so we need to use [ and ] instead.
22700   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22701   if test "x$has_forbidden_chars" != x; then
22702     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22703     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22704     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22705     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22706       # Going to short mode and back again did indeed matter. Since short mode is
22707       # case insensitive, let's make it lowercase to improve readability.
22708       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22709       # Now convert it back to Unix-stile (cygpath)
22710       input_path=`$CYGPATH -u "$shortmode_path"`
22711       new_path="$input_path"
22712     fi
22713   fi
22714 
22715   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22716   if test "x$test_cygdrive_prefix" = x; then
22717     # As a simple fix, exclude /usr/bin since it's not a real path.
22718     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22719       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22720       # a path prefixed by /cygdrive for fixpath to work.
22721       new_path="$CYGWIN_ROOT_PATH$input_path"
22722     fi
22723   fi
22724 
22725 
22726   if test "x$path" != "x$new_path"; then
22727     BOOT_JDK="$new_path"
22728     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22729 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22730   fi
22731 
22732   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22733 
22734   path="$BOOT_JDK"
22735   has_colon=`$ECHO $path | $GREP ^.:`
22736   new_path="$path"
22737   if test "x$has_colon" = x; then
22738     # Not in mixed or Windows style, start by that.
22739     new_path=`cmd //c echo $path`
22740   fi
22741 
22742 
22743   input_path="$new_path"
22744   # Check if we need to convert this using DOS-style short mode. If the path
22745   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22746   # take no chances and rewrite it.
22747   # Note: m4 eats our [], so we need to use [ and ] instead.
22748   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22749   if test "x$has_forbidden_chars" != x; then
22750     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22751     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22752   fi
22753 
22754 
22755   windows_path="$new_path"
22756   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22757     unix_path=`$CYGPATH -u "$windows_path"`
22758     new_path="$unix_path"
22759   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22760     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22761     new_path="$unix_path"
22762   fi
22763 
22764   if test "x$path" != "x$new_path"; then
22765     BOOT_JDK="$new_path"
22766     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22767 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22768   fi
22769 
22770   # Save the first 10 bytes of this path to the storage, so fixpath can work.
22771   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22772 
22773   else
22774     # We're on a posix platform. Hooray! :)
22775     path="$BOOT_JDK"
22776     has_space=`$ECHO "$path" | $GREP " "`
22777     if test "x$has_space" != x; then
22778       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22779 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22780       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22781     fi
22782 
22783     # Use eval to expand a potential ~
22784     eval path="$path"
22785     if test ! -f "$path" && test ! -d "$path"; then
22786       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22787     fi
22788 
22789     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22790   fi
22791 
22792               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22793 $as_echo_n "checking for Boot JDK... " >&6; }
22794               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22795 $as_echo "$BOOT_JDK" >&6; }
22796               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22797 $as_echo_n "checking Boot JDK version... " >&6; }
22798               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22799               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22800 $as_echo "$BOOT_JDK_VERSION" >&6; }
22801             fi # end check jdk version
22802           fi # end check rt.jar
22803         fi # end check javac
22804       fi # end check java
22805     fi # end check boot jdk found
22806   fi
22807 
22808 
22809   if test "x$BOOT_JDK_FOUND" = xno; then
22810     # Now execute the test
22811 
22812   if test "x$ProgramFiles" != x; then
22813     VIRTUAL_DIR="$ProgramFiles/Java"
22814 
22815   windows_path="$VIRTUAL_DIR"
22816   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22817     unix_path=`$CYGPATH -u "$windows_path"`
22818     VIRTUAL_DIR="$unix_path"
22819   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22820     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22821     VIRTUAL_DIR="$unix_path"
22822   fi
22823 
22824 
22825   BOOT_JDK_PREFIX="$VIRTUAL_DIR"
22826   BOOT_JDK_SUFFIX=""
22827   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
22828   if test "x$ALL_JDKS_FOUND" != x; then
22829     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
22830 
22831   if test "x$BOOT_JDK_FOUND" = xno; then
22832     # Now execute the test
22833 
22834         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
22835         if test -d "$BOOT_JDK"; then
22836           BOOT_JDK_FOUND=maybe
22837           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
22838 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
22839         fi
22840 
22841 
22842     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22843     if test "x$BOOT_JDK_FOUND" = xmaybe; then
22844       # Do we have a bin/java?
22845       if test ! -x "$BOOT_JDK/bin/java"; then
22846         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22847 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22848         BOOT_JDK_FOUND=no
22849       else
22850         # Do we have a bin/javac?
22851         if test ! -x "$BOOT_JDK/bin/javac"; then
22852           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22853 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22854           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22855 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22856           BOOT_JDK_FOUND=no
22857         else
22858           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22859           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22860             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22861 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22862             BOOT_JDK_FOUND=no
22863           else
22864             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22865             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22866 
22867             # Extra M4 quote needed to protect [] in grep expression.
22868             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
22869             if test "x$FOUND_CORRECT_VERSION" = x; then
22870               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22871 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22872               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
22873 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
22874               BOOT_JDK_FOUND=no
22875             else
22876               # We're done! :-)
22877               BOOT_JDK_FOUND=yes
22878 
22879   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22880 
22881   # Input might be given as Windows format, start by converting to
22882   # unix format.
22883   path="$BOOT_JDK"
22884   new_path=`$CYGPATH -u "$path"`
22885 
22886   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22887   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22888   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22889   # "foo.exe" is OK but "foo" is an error.
22890   #
22891   # This test is therefore slightly more accurate than "test -f" to check for file precense.
22892   # It is also a way to make sure we got the proper file name for the real test later on.
22893   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22894   if test "x$test_shortpath" = x; then
22895     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22896 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22897     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22898   fi
22899 
22900   # Call helper function which possibly converts this using DOS-style short mode.
22901   # If so, the updated path is stored in $new_path.
22902 
22903   input_path="$new_path"
22904   # Check if we need to convert this using DOS-style short mode. If the path
22905   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22906   # take no chances and rewrite it.
22907   # Note: m4 eats our [], so we need to use [ and ] instead.
22908   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22909   if test "x$has_forbidden_chars" != x; then
22910     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22911     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22912     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22913     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22914       # Going to short mode and back again did indeed matter. Since short mode is
22915       # case insensitive, let's make it lowercase to improve readability.
22916       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22917       # Now convert it back to Unix-stile (cygpath)
22918       input_path=`$CYGPATH -u "$shortmode_path"`
22919       new_path="$input_path"
22920     fi
22921   fi
22922 
22923   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22924   if test "x$test_cygdrive_prefix" = x; then
22925     # As a simple fix, exclude /usr/bin since it's not a real path.
22926     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22927       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22928       # a path prefixed by /cygdrive for fixpath to work.
22929       new_path="$CYGWIN_ROOT_PATH$input_path"
22930     fi
22931   fi
22932 
22933 
22934   if test "x$path" != "x$new_path"; then
22935     BOOT_JDK="$new_path"
22936     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22937 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22938   fi
22939 
22940   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22941 
22942   path="$BOOT_JDK"
22943   has_colon=`$ECHO $path | $GREP ^.:`
22944   new_path="$path"
22945   if test "x$has_colon" = x; then
22946     # Not in mixed or Windows style, start by that.
22947     new_path=`cmd //c echo $path`
22948   fi
22949 
22950 
22951   input_path="$new_path"
22952   # Check if we need to convert this using DOS-style short mode. If the path
22953   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22954   # take no chances and rewrite it.
22955   # Note: m4 eats our [], so we need to use [ and ] instead.
22956   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22957   if test "x$has_forbidden_chars" != x; then
22958     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22959     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22960   fi
22961 
22962 
22963   windows_path="$new_path"
22964   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22965     unix_path=`$CYGPATH -u "$windows_path"`
22966     new_path="$unix_path"
22967   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22968     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22969     new_path="$unix_path"
22970   fi
22971 
22972   if test "x$path" != "x$new_path"; then
22973     BOOT_JDK="$new_path"
22974     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22975 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22976   fi
22977 
22978   # Save the first 10 bytes of this path to the storage, so fixpath can work.
22979   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22980 
22981   else
22982     # We're on a posix platform. Hooray! :)
22983     path="$BOOT_JDK"
22984     has_space=`$ECHO "$path" | $GREP " "`
22985     if test "x$has_space" != x; then
22986       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22987 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22988       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22989     fi
22990 
22991     # Use eval to expand a potential ~
22992     eval path="$path"
22993     if test ! -f "$path" && test ! -d "$path"; then
22994       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22995     fi
22996 
22997     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22998   fi
22999 
23000               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23001 $as_echo_n "checking for Boot JDK... " >&6; }
23002               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23003 $as_echo "$BOOT_JDK" >&6; }
23004               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23005 $as_echo_n "checking Boot JDK version... " >&6; }
23006               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23007               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23008 $as_echo "$BOOT_JDK_VERSION" >&6; }
23009             fi # end check jdk version
23010           fi # end check rt.jar
23011         fi # end check javac
23012       fi # end check java
23013     fi # end check boot jdk found
23014   fi
23015 
23016     done
23017   fi
23018 
23019   fi
23020 
23021 
23022     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23023     if test "x$BOOT_JDK_FOUND" = xmaybe; then
23024       # Do we have a bin/java?
23025       if test ! -x "$BOOT_JDK/bin/java"; then
23026         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23027 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23028         BOOT_JDK_FOUND=no
23029       else
23030         # Do we have a bin/javac?
23031         if test ! -x "$BOOT_JDK/bin/javac"; then
23032           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23033 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23034           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23035 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23036           BOOT_JDK_FOUND=no
23037         else
23038           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23039           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23040             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23041 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23042             BOOT_JDK_FOUND=no
23043           else
23044             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23045             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23046 
23047             # Extra M4 quote needed to protect [] in grep expression.
23048             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23049             if test "x$FOUND_CORRECT_VERSION" = x; then
23050               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23051 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23052               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23053 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23054               BOOT_JDK_FOUND=no
23055             else
23056               # We're done! :-)
23057               BOOT_JDK_FOUND=yes
23058 
23059   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23060 
23061   # Input might be given as Windows format, start by converting to
23062   # unix format.
23063   path="$BOOT_JDK"
23064   new_path=`$CYGPATH -u "$path"`
23065 
23066   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23067   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23068   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23069   # "foo.exe" is OK but "foo" is an error.
23070   #
23071   # This test is therefore slightly more accurate than "test -f" to check for file precense.
23072   # It is also a way to make sure we got the proper file name for the real test later on.
23073   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23074   if test "x$test_shortpath" = x; then
23075     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23076 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23077     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23078   fi
23079 
23080   # Call helper function which possibly converts this using DOS-style short mode.
23081   # If so, the updated path is stored in $new_path.
23082 
23083   input_path="$new_path"
23084   # Check if we need to convert this using DOS-style short mode. If the path
23085   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23086   # take no chances and rewrite it.
23087   # Note: m4 eats our [], so we need to use [ and ] instead.
23088   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23089   if test "x$has_forbidden_chars" != x; then
23090     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23091     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23092     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23093     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23094       # Going to short mode and back again did indeed matter. Since short mode is
23095       # case insensitive, let's make it lowercase to improve readability.
23096       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23097       # Now convert it back to Unix-stile (cygpath)
23098       input_path=`$CYGPATH -u "$shortmode_path"`
23099       new_path="$input_path"
23100     fi
23101   fi
23102 
23103   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23104   if test "x$test_cygdrive_prefix" = x; then
23105     # As a simple fix, exclude /usr/bin since it's not a real path.
23106     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23107       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23108       # a path prefixed by /cygdrive for fixpath to work.
23109       new_path="$CYGWIN_ROOT_PATH$input_path"
23110     fi
23111   fi
23112 
23113 
23114   if test "x$path" != "x$new_path"; then
23115     BOOT_JDK="$new_path"
23116     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23117 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23118   fi
23119 
23120   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23121 
23122   path="$BOOT_JDK"
23123   has_colon=`$ECHO $path | $GREP ^.:`
23124   new_path="$path"
23125   if test "x$has_colon" = x; then
23126     # Not in mixed or Windows style, start by that.
23127     new_path=`cmd //c echo $path`
23128   fi
23129 
23130 
23131   input_path="$new_path"
23132   # Check if we need to convert this using DOS-style short mode. If the path
23133   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23134   # take no chances and rewrite it.
23135   # Note: m4 eats our [], so we need to use [ and ] instead.
23136   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23137   if test "x$has_forbidden_chars" != x; then
23138     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23139     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23140   fi
23141 
23142 
23143   windows_path="$new_path"
23144   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23145     unix_path=`$CYGPATH -u "$windows_path"`
23146     new_path="$unix_path"
23147   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23148     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23149     new_path="$unix_path"
23150   fi
23151 
23152   if test "x$path" != "x$new_path"; then
23153     BOOT_JDK="$new_path"
23154     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23155 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23156   fi
23157 
23158   # Save the first 10 bytes of this path to the storage, so fixpath can work.
23159   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23160 
23161   else
23162     # We're on a posix platform. Hooray! :)
23163     path="$BOOT_JDK"
23164     has_space=`$ECHO "$path" | $GREP " "`
23165     if test "x$has_space" != x; then
23166       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23167 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23168       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23169     fi
23170 
23171     # Use eval to expand a potential ~
23172     eval path="$path"
23173     if test ! -f "$path" && test ! -d "$path"; then
23174       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23175     fi
23176 
23177     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23178   fi
23179 
23180               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23181 $as_echo_n "checking for Boot JDK... " >&6; }
23182               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23183 $as_echo "$BOOT_JDK" >&6; }
23184               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23185 $as_echo_n "checking Boot JDK version... " >&6; }
23186               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23187               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23188 $as_echo "$BOOT_JDK_VERSION" >&6; }
23189             fi # end check jdk version
23190           fi # end check rt.jar
23191         fi # end check javac
23192       fi # end check java
23193     fi # end check boot jdk found
23194   fi
23195 
23196 
23197   if test "x$BOOT_JDK_FOUND" = xno; then
23198     # Now execute the test
23199 
23200   BOOT_JDK_PREFIX="/cygdrive/c/Program Files/Java"
23201   BOOT_JDK_SUFFIX=""
23202   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
23203   if test "x$ALL_JDKS_FOUND" != x; then
23204     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
23205 
23206   if test "x$BOOT_JDK_FOUND" = xno; then
23207     # Now execute the test
23208 
23209         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
23210         if test -d "$BOOT_JDK"; then
23211           BOOT_JDK_FOUND=maybe
23212           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
23213 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
23214         fi
23215 
23216 
23217     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23218     if test "x$BOOT_JDK_FOUND" = xmaybe; then
23219       # Do we have a bin/java?
23220       if test ! -x "$BOOT_JDK/bin/java"; then
23221         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23222 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23223         BOOT_JDK_FOUND=no
23224       else
23225         # Do we have a bin/javac?
23226         if test ! -x "$BOOT_JDK/bin/javac"; then
23227           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23228 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23229           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23230 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23231           BOOT_JDK_FOUND=no
23232         else
23233           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23234           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23235             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23236 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23237             BOOT_JDK_FOUND=no
23238           else
23239             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23240             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23241 
23242             # Extra M4 quote needed to protect [] in grep expression.
23243             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23244             if test "x$FOUND_CORRECT_VERSION" = x; then
23245               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23246 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23247               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23248 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23249               BOOT_JDK_FOUND=no
23250             else
23251               # We're done! :-)
23252               BOOT_JDK_FOUND=yes
23253 
23254   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23255 
23256   # Input might be given as Windows format, start by converting to
23257   # unix format.
23258   path="$BOOT_JDK"
23259   new_path=`$CYGPATH -u "$path"`
23260 
23261   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23262   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23263   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23264   # "foo.exe" is OK but "foo" is an error.
23265   #
23266   # This test is therefore slightly more accurate than "test -f" to check for file precense.
23267   # It is also a way to make sure we got the proper file name for the real test later on.
23268   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23269   if test "x$test_shortpath" = x; then
23270     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23271 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23272     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23273   fi
23274 
23275   # Call helper function which possibly converts this using DOS-style short mode.
23276   # If so, the updated path is stored in $new_path.
23277 
23278   input_path="$new_path"
23279   # Check if we need to convert this using DOS-style short mode. If the path
23280   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23281   # take no chances and rewrite it.
23282   # Note: m4 eats our [], so we need to use [ and ] instead.
23283   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23284   if test "x$has_forbidden_chars" != x; then
23285     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23286     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23287     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23288     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23289       # Going to short mode and back again did indeed matter. Since short mode is
23290       # case insensitive, let's make it lowercase to improve readability.
23291       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23292       # Now convert it back to Unix-stile (cygpath)
23293       input_path=`$CYGPATH -u "$shortmode_path"`
23294       new_path="$input_path"
23295     fi
23296   fi
23297 
23298   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23299   if test "x$test_cygdrive_prefix" = x; then
23300     # As a simple fix, exclude /usr/bin since it's not a real path.
23301     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23302       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23303       # a path prefixed by /cygdrive for fixpath to work.
23304       new_path="$CYGWIN_ROOT_PATH$input_path"
23305     fi
23306   fi
23307 
23308 
23309   if test "x$path" != "x$new_path"; then
23310     BOOT_JDK="$new_path"
23311     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23312 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23313   fi
23314 
23315   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23316 
23317   path="$BOOT_JDK"
23318   has_colon=`$ECHO $path | $GREP ^.:`
23319   new_path="$path"
23320   if test "x$has_colon" = x; then
23321     # Not in mixed or Windows style, start by that.
23322     new_path=`cmd //c echo $path`
23323   fi
23324 
23325 
23326   input_path="$new_path"
23327   # Check if we need to convert this using DOS-style short mode. If the path
23328   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23329   # take no chances and rewrite it.
23330   # Note: m4 eats our [], so we need to use [ and ] instead.
23331   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23332   if test "x$has_forbidden_chars" != x; then
23333     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23334     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23335   fi
23336 
23337 
23338   windows_path="$new_path"
23339   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23340     unix_path=`$CYGPATH -u "$windows_path"`
23341     new_path="$unix_path"
23342   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23343     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23344     new_path="$unix_path"
23345   fi
23346 
23347   if test "x$path" != "x$new_path"; then
23348     BOOT_JDK="$new_path"
23349     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23350 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23351   fi
23352 
23353   # Save the first 10 bytes of this path to the storage, so fixpath can work.
23354   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23355 
23356   else
23357     # We're on a posix platform. Hooray! :)
23358     path="$BOOT_JDK"
23359     has_space=`$ECHO "$path" | $GREP " "`
23360     if test "x$has_space" != x; then
23361       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23362 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23363       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23364     fi
23365 
23366     # Use eval to expand a potential ~
23367     eval path="$path"
23368     if test ! -f "$path" && test ! -d "$path"; then
23369       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23370     fi
23371 
23372     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23373   fi
23374 
23375               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23376 $as_echo_n "checking for Boot JDK... " >&6; }
23377               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23378 $as_echo "$BOOT_JDK" >&6; }
23379               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23380 $as_echo_n "checking Boot JDK version... " >&6; }
23381               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23382               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23383 $as_echo "$BOOT_JDK_VERSION" >&6; }
23384             fi # end check jdk version
23385           fi # end check rt.jar
23386         fi # end check javac
23387       fi # end check java
23388     fi # end check boot jdk found
23389   fi
23390 
23391     done
23392   fi
23393 
23394 
23395     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23396     if test "x$BOOT_JDK_FOUND" = xmaybe; then
23397       # Do we have a bin/java?
23398       if test ! -x "$BOOT_JDK/bin/java"; then
23399         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23400 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23401         BOOT_JDK_FOUND=no
23402       else
23403         # Do we have a bin/javac?
23404         if test ! -x "$BOOT_JDK/bin/javac"; then
23405           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23406 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23407           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23408 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23409           BOOT_JDK_FOUND=no
23410         else
23411           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23412           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23413             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23414 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23415             BOOT_JDK_FOUND=no
23416           else
23417             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23418             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23419 
23420             # Extra M4 quote needed to protect [] in grep expression.
23421             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23422             if test "x$FOUND_CORRECT_VERSION" = x; then
23423               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23424 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23425               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23426 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23427               BOOT_JDK_FOUND=no
23428             else
23429               # We're done! :-)
23430               BOOT_JDK_FOUND=yes
23431 
23432   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23433 
23434   # Input might be given as Windows format, start by converting to
23435   # unix format.
23436   path="$BOOT_JDK"
23437   new_path=`$CYGPATH -u "$path"`
23438 
23439   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23440   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23441   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23442   # "foo.exe" is OK but "foo" is an error.
23443   #
23444   # This test is therefore slightly more accurate than "test -f" to check for file precense.
23445   # It is also a way to make sure we got the proper file name for the real test later on.
23446   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23447   if test "x$test_shortpath" = x; then
23448     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23449 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23450     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23451   fi
23452 
23453   # Call helper function which possibly converts this using DOS-style short mode.
23454   # If so, the updated path is stored in $new_path.
23455 
23456   input_path="$new_path"
23457   # Check if we need to convert this using DOS-style short mode. If the path
23458   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23459   # take no chances and rewrite it.
23460   # Note: m4 eats our [], so we need to use [ and ] instead.
23461   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23462   if test "x$has_forbidden_chars" != x; then
23463     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23464     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23465     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23466     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23467       # Going to short mode and back again did indeed matter. Since short mode is
23468       # case insensitive, let's make it lowercase to improve readability.
23469       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23470       # Now convert it back to Unix-stile (cygpath)
23471       input_path=`$CYGPATH -u "$shortmode_path"`
23472       new_path="$input_path"
23473     fi
23474   fi
23475 
23476   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23477   if test "x$test_cygdrive_prefix" = x; then
23478     # As a simple fix, exclude /usr/bin since it's not a real path.
23479     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23480       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23481       # a path prefixed by /cygdrive for fixpath to work.
23482       new_path="$CYGWIN_ROOT_PATH$input_path"
23483     fi
23484   fi
23485 
23486 
23487   if test "x$path" != "x$new_path"; then
23488     BOOT_JDK="$new_path"
23489     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23490 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23491   fi
23492 
23493   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23494 
23495   path="$BOOT_JDK"
23496   has_colon=`$ECHO $path | $GREP ^.:`
23497   new_path="$path"
23498   if test "x$has_colon" = x; then
23499     # Not in mixed or Windows style, start by that.
23500     new_path=`cmd //c echo $path`
23501   fi
23502 
23503 
23504   input_path="$new_path"
23505   # Check if we need to convert this using DOS-style short mode. If the path
23506   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23507   # take no chances and rewrite it.
23508   # Note: m4 eats our [], so we need to use [ and ] instead.
23509   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23510   if test "x$has_forbidden_chars" != x; then
23511     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23512     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23513   fi
23514 
23515 
23516   windows_path="$new_path"
23517   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23518     unix_path=`$CYGPATH -u "$windows_path"`
23519     new_path="$unix_path"
23520   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23521     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23522     new_path="$unix_path"
23523   fi
23524 
23525   if test "x$path" != "x$new_path"; then
23526     BOOT_JDK="$new_path"
23527     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23528 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23529   fi
23530 
23531   # Save the first 10 bytes of this path to the storage, so fixpath can work.
23532   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23533 
23534   else
23535     # We're on a posix platform. Hooray! :)
23536     path="$BOOT_JDK"
23537     has_space=`$ECHO "$path" | $GREP " "`
23538     if test "x$has_space" != x; then
23539       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23540 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23541       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23542     fi
23543 
23544     # Use eval to expand a potential ~
23545     eval path="$path"
23546     if test ! -f "$path" && test ! -d "$path"; then
23547       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23548     fi
23549 
23550     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23551   fi
23552 
23553               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23554 $as_echo_n "checking for Boot JDK... " >&6; }
23555               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23556 $as_echo "$BOOT_JDK" >&6; }
23557               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23558 $as_echo_n "checking Boot JDK version... " >&6; }
23559               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23560               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23561 $as_echo "$BOOT_JDK_VERSION" >&6; }
23562             fi # end check jdk version
23563           fi # end check rt.jar
23564         fi # end check javac
23565       fi # end check java
23566     fi # end check boot jdk found
23567   fi
23568 
23569   elif test "x$OPENJDK_TARGET_OS" = xmacosx; then
23570 
23571   if test "x$BOOT_JDK_FOUND" = xno; then
23572     # Now execute the test
23573 
23574   BOOT_JDK_PREFIX="/Library/Java/JavaVirtualMachines"
23575   BOOT_JDK_SUFFIX="/Contents/Home"
23576   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
23577   if test "x$ALL_JDKS_FOUND" != x; then
23578     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
23579 
23580   if test "x$BOOT_JDK_FOUND" = xno; then
23581     # Now execute the test
23582 
23583         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
23584         if test -d "$BOOT_JDK"; then
23585           BOOT_JDK_FOUND=maybe
23586           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
23587 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
23588         fi
23589 
23590 
23591     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23592     if test "x$BOOT_JDK_FOUND" = xmaybe; then
23593       # Do we have a bin/java?
23594       if test ! -x "$BOOT_JDK/bin/java"; then
23595         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23596 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23597         BOOT_JDK_FOUND=no
23598       else
23599         # Do we have a bin/javac?
23600         if test ! -x "$BOOT_JDK/bin/javac"; then
23601           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23602 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23603           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23604 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23605           BOOT_JDK_FOUND=no
23606         else
23607           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23608           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23609             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23610 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23611             BOOT_JDK_FOUND=no
23612           else
23613             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23614             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23615 
23616             # Extra M4 quote needed to protect [] in grep expression.
23617             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23618             if test "x$FOUND_CORRECT_VERSION" = x; then
23619               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23620 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23621               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23622 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23623               BOOT_JDK_FOUND=no
23624             else
23625               # We're done! :-)
23626               BOOT_JDK_FOUND=yes
23627 
23628   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23629 
23630   # Input might be given as Windows format, start by converting to
23631   # unix format.
23632   path="$BOOT_JDK"
23633   new_path=`$CYGPATH -u "$path"`
23634 
23635   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23636   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23637   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23638   # "foo.exe" is OK but "foo" is an error.
23639   #
23640   # This test is therefore slightly more accurate than "test -f" to check for file precense.
23641   # It is also a way to make sure we got the proper file name for the real test later on.
23642   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23643   if test "x$test_shortpath" = x; then
23644     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23645 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23646     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23647   fi
23648 
23649   # Call helper function which possibly converts this using DOS-style short mode.
23650   # If so, the updated path is stored in $new_path.
23651 
23652   input_path="$new_path"
23653   # Check if we need to convert this using DOS-style short mode. If the path
23654   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23655   # take no chances and rewrite it.
23656   # Note: m4 eats our [], so we need to use [ and ] instead.
23657   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23658   if test "x$has_forbidden_chars" != x; then
23659     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23660     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23661     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23662     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23663       # Going to short mode and back again did indeed matter. Since short mode is
23664       # case insensitive, let's make it lowercase to improve readability.
23665       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23666       # Now convert it back to Unix-stile (cygpath)
23667       input_path=`$CYGPATH -u "$shortmode_path"`
23668       new_path="$input_path"
23669     fi
23670   fi
23671 
23672   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23673   if test "x$test_cygdrive_prefix" = x; then
23674     # As a simple fix, exclude /usr/bin since it's not a real path.
23675     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23676       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23677       # a path prefixed by /cygdrive for fixpath to work.
23678       new_path="$CYGWIN_ROOT_PATH$input_path"
23679     fi
23680   fi
23681 
23682 
23683   if test "x$path" != "x$new_path"; then
23684     BOOT_JDK="$new_path"
23685     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23686 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23687   fi
23688 
23689   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23690 
23691   path="$BOOT_JDK"
23692   has_colon=`$ECHO $path | $GREP ^.:`
23693   new_path="$path"
23694   if test "x$has_colon" = x; then
23695     # Not in mixed or Windows style, start by that.
23696     new_path=`cmd //c echo $path`
23697   fi
23698 
23699 
23700   input_path="$new_path"
23701   # Check if we need to convert this using DOS-style short mode. If the path
23702   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23703   # take no chances and rewrite it.
23704   # Note: m4 eats our [], so we need to use [ and ] instead.
23705   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23706   if test "x$has_forbidden_chars" != x; then
23707     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23708     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23709   fi
23710 
23711 
23712   windows_path="$new_path"
23713   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23714     unix_path=`$CYGPATH -u "$windows_path"`
23715     new_path="$unix_path"
23716   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23717     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23718     new_path="$unix_path"
23719   fi
23720 
23721   if test "x$path" != "x$new_path"; then
23722     BOOT_JDK="$new_path"
23723     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23724 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23725   fi
23726 
23727   # Save the first 10 bytes of this path to the storage, so fixpath can work.
23728   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23729 
23730   else
23731     # We're on a posix platform. Hooray! :)
23732     path="$BOOT_JDK"
23733     has_space=`$ECHO "$path" | $GREP " "`
23734     if test "x$has_space" != x; then
23735       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23736 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23737       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23738     fi
23739 
23740     # Use eval to expand a potential ~
23741     eval path="$path"
23742     if test ! -f "$path" && test ! -d "$path"; then
23743       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23744     fi
23745 
23746     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23747   fi
23748 
23749               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23750 $as_echo_n "checking for Boot JDK... " >&6; }
23751               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23752 $as_echo "$BOOT_JDK" >&6; }
23753               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23754 $as_echo_n "checking Boot JDK version... " >&6; }
23755               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23756               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23757 $as_echo "$BOOT_JDK_VERSION" >&6; }
23758             fi # end check jdk version
23759           fi # end check rt.jar
23760         fi # end check javac
23761       fi # end check java
23762     fi # end check boot jdk found
23763   fi
23764 
23765     done
23766   fi
23767 
23768 
23769     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23770     if test "x$BOOT_JDK_FOUND" = xmaybe; then
23771       # Do we have a bin/java?
23772       if test ! -x "$BOOT_JDK/bin/java"; then
23773         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23774 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23775         BOOT_JDK_FOUND=no
23776       else
23777         # Do we have a bin/javac?
23778         if test ! -x "$BOOT_JDK/bin/javac"; then
23779           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23780 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23781           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23782 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23783           BOOT_JDK_FOUND=no
23784         else
23785           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23786           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23787             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23788 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23789             BOOT_JDK_FOUND=no
23790           else
23791             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23792             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23793 
23794             # Extra M4 quote needed to protect [] in grep expression.
23795             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23796             if test "x$FOUND_CORRECT_VERSION" = x; then
23797               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23798 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23799               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23800 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23801               BOOT_JDK_FOUND=no
23802             else
23803               # We're done! :-)
23804               BOOT_JDK_FOUND=yes
23805 
23806   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23807 
23808   # Input might be given as Windows format, start by converting to
23809   # unix format.
23810   path="$BOOT_JDK"
23811   new_path=`$CYGPATH -u "$path"`
23812 
23813   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23814   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23815   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23816   # "foo.exe" is OK but "foo" is an error.
23817   #
23818   # This test is therefore slightly more accurate than "test -f" to check for file precense.
23819   # It is also a way to make sure we got the proper file name for the real test later on.
23820   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23821   if test "x$test_shortpath" = x; then
23822     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23823 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23824     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23825   fi
23826 
23827   # Call helper function which possibly converts this using DOS-style short mode.
23828   # If so, the updated path is stored in $new_path.
23829 
23830   input_path="$new_path"
23831   # Check if we need to convert this using DOS-style short mode. If the path
23832   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23833   # take no chances and rewrite it.
23834   # Note: m4 eats our [], so we need to use [ and ] instead.
23835   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23836   if test "x$has_forbidden_chars" != x; then
23837     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23838     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23839     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23840     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23841       # Going to short mode and back again did indeed matter. Since short mode is
23842       # case insensitive, let's make it lowercase to improve readability.
23843       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23844       # Now convert it back to Unix-stile (cygpath)
23845       input_path=`$CYGPATH -u "$shortmode_path"`
23846       new_path="$input_path"
23847     fi
23848   fi
23849 
23850   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23851   if test "x$test_cygdrive_prefix" = x; then
23852     # As a simple fix, exclude /usr/bin since it's not a real path.
23853     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23854       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23855       # a path prefixed by /cygdrive for fixpath to work.
23856       new_path="$CYGWIN_ROOT_PATH$input_path"
23857     fi
23858   fi
23859 
23860 
23861   if test "x$path" != "x$new_path"; then
23862     BOOT_JDK="$new_path"
23863     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23864 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23865   fi
23866 
23867   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23868 
23869   path="$BOOT_JDK"
23870   has_colon=`$ECHO $path | $GREP ^.:`
23871   new_path="$path"
23872   if test "x$has_colon" = x; then
23873     # Not in mixed or Windows style, start by that.
23874     new_path=`cmd //c echo $path`
23875   fi
23876 
23877 
23878   input_path="$new_path"
23879   # Check if we need to convert this using DOS-style short mode. If the path
23880   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23881   # take no chances and rewrite it.
23882   # Note: m4 eats our [], so we need to use [ and ] instead.
23883   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23884   if test "x$has_forbidden_chars" != x; then
23885     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23886     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23887   fi
23888 
23889 
23890   windows_path="$new_path"
23891   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23892     unix_path=`$CYGPATH -u "$windows_path"`
23893     new_path="$unix_path"
23894   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23895     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23896     new_path="$unix_path"
23897   fi
23898 
23899   if test "x$path" != "x$new_path"; then
23900     BOOT_JDK="$new_path"
23901     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23902 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23903   fi
23904 
23905   # Save the first 10 bytes of this path to the storage, so fixpath can work.
23906   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23907 
23908   else
23909     # We're on a posix platform. Hooray! :)
23910     path="$BOOT_JDK"
23911     has_space=`$ECHO "$path" | $GREP " "`
23912     if test "x$has_space" != x; then
23913       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23914 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23915       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23916     fi
23917 
23918     # Use eval to expand a potential ~
23919     eval path="$path"
23920     if test ! -f "$path" && test ! -d "$path"; then
23921       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23922     fi
23923 
23924     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23925   fi
23926 
23927               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23928 $as_echo_n "checking for Boot JDK... " >&6; }
23929               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23930 $as_echo "$BOOT_JDK" >&6; }
23931               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23932 $as_echo_n "checking Boot JDK version... " >&6; }
23933               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23934               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23935 $as_echo "$BOOT_JDK_VERSION" >&6; }
23936             fi # end check jdk version
23937           fi # end check rt.jar
23938         fi # end check javac
23939       fi # end check java
23940     fi # end check boot jdk found
23941   fi
23942 
23943 
23944   if test "x$BOOT_JDK_FOUND" = xno; then
23945     # Now execute the test
23946 
23947   BOOT_JDK_PREFIX="/System/Library/Java/JavaVirtualMachines"
23948   BOOT_JDK_SUFFIX="/Contents/Home"
23949   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
23950   if test "x$ALL_JDKS_FOUND" != x; then
23951     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
23952 
23953   if test "x$BOOT_JDK_FOUND" = xno; then
23954     # Now execute the test
23955 
23956         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
23957         if test -d "$BOOT_JDK"; then
23958           BOOT_JDK_FOUND=maybe
23959           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
23960 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
23961         fi
23962 
23963 
23964     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23965     if test "x$BOOT_JDK_FOUND" = xmaybe; then
23966       # Do we have a bin/java?
23967       if test ! -x "$BOOT_JDK/bin/java"; then
23968         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23969 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23970         BOOT_JDK_FOUND=no
23971       else
23972         # Do we have a bin/javac?
23973         if test ! -x "$BOOT_JDK/bin/javac"; then
23974           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23975 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23976           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23977 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23978           BOOT_JDK_FOUND=no
23979         else
23980           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23981           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23982             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23983 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23984             BOOT_JDK_FOUND=no
23985           else
23986             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23987             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23988 
23989             # Extra M4 quote needed to protect [] in grep expression.
23990             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
23991             if test "x$FOUND_CORRECT_VERSION" = x; then
23992               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23993 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23994               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
23995 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
23996               BOOT_JDK_FOUND=no
23997             else
23998               # We're done! :-)
23999               BOOT_JDK_FOUND=yes
24000 
24001   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24002 
24003   # Input might be given as Windows format, start by converting to
24004   # unix format.
24005   path="$BOOT_JDK"
24006   new_path=`$CYGPATH -u "$path"`
24007 
24008   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24009   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24010   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24011   # "foo.exe" is OK but "foo" is an error.
24012   #
24013   # This test is therefore slightly more accurate than "test -f" to check for file precense.
24014   # It is also a way to make sure we got the proper file name for the real test later on.
24015   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24016   if test "x$test_shortpath" = x; then
24017     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24018 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24019     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24020   fi
24021 
24022   # Call helper function which possibly converts this using DOS-style short mode.
24023   # If so, the updated path is stored in $new_path.
24024 
24025   input_path="$new_path"
24026   # Check if we need to convert this using DOS-style short mode. If the path
24027   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24028   # take no chances and rewrite it.
24029   # Note: m4 eats our [], so we need to use [ and ] instead.
24030   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24031   if test "x$has_forbidden_chars" != x; then
24032     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24033     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24034     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24035     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24036       # Going to short mode and back again did indeed matter. Since short mode is
24037       # case insensitive, let's make it lowercase to improve readability.
24038       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24039       # Now convert it back to Unix-stile (cygpath)
24040       input_path=`$CYGPATH -u "$shortmode_path"`
24041       new_path="$input_path"
24042     fi
24043   fi
24044 
24045   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24046   if test "x$test_cygdrive_prefix" = x; then
24047     # As a simple fix, exclude /usr/bin since it's not a real path.
24048     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24049       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24050       # a path prefixed by /cygdrive for fixpath to work.
24051       new_path="$CYGWIN_ROOT_PATH$input_path"
24052     fi
24053   fi
24054 
24055 
24056   if test "x$path" != "x$new_path"; then
24057     BOOT_JDK="$new_path"
24058     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24059 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24060   fi
24061 
24062   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24063 
24064   path="$BOOT_JDK"
24065   has_colon=`$ECHO $path | $GREP ^.:`
24066   new_path="$path"
24067   if test "x$has_colon" = x; then
24068     # Not in mixed or Windows style, start by that.
24069     new_path=`cmd //c echo $path`
24070   fi
24071 
24072 
24073   input_path="$new_path"
24074   # Check if we need to convert this using DOS-style short mode. If the path
24075   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24076   # take no chances and rewrite it.
24077   # Note: m4 eats our [], so we need to use [ and ] instead.
24078   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24079   if test "x$has_forbidden_chars" != x; then
24080     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24081     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24082   fi
24083 
24084 
24085   windows_path="$new_path"
24086   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24087     unix_path=`$CYGPATH -u "$windows_path"`
24088     new_path="$unix_path"
24089   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24090     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24091     new_path="$unix_path"
24092   fi
24093 
24094   if test "x$path" != "x$new_path"; then
24095     BOOT_JDK="$new_path"
24096     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24097 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24098   fi
24099 
24100   # Save the first 10 bytes of this path to the storage, so fixpath can work.
24101   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24102 
24103   else
24104     # We're on a posix platform. Hooray! :)
24105     path="$BOOT_JDK"
24106     has_space=`$ECHO "$path" | $GREP " "`
24107     if test "x$has_space" != x; then
24108       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24109 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24110       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24111     fi
24112 
24113     # Use eval to expand a potential ~
24114     eval path="$path"
24115     if test ! -f "$path" && test ! -d "$path"; then
24116       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24117     fi
24118 
24119     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24120   fi
24121 
24122               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24123 $as_echo_n "checking for Boot JDK... " >&6; }
24124               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24125 $as_echo "$BOOT_JDK" >&6; }
24126               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24127 $as_echo_n "checking Boot JDK version... " >&6; }
24128               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24129               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24130 $as_echo "$BOOT_JDK_VERSION" >&6; }
24131             fi # end check jdk version
24132           fi # end check rt.jar
24133         fi # end check javac
24134       fi # end check java
24135     fi # end check boot jdk found
24136   fi
24137 
24138     done
24139   fi
24140 
24141 
24142     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24143     if test "x$BOOT_JDK_FOUND" = xmaybe; then
24144       # Do we have a bin/java?
24145       if test ! -x "$BOOT_JDK/bin/java"; then
24146         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24147 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24148         BOOT_JDK_FOUND=no
24149       else
24150         # Do we have a bin/javac?
24151         if test ! -x "$BOOT_JDK/bin/javac"; then
24152           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24153 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24154           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24155 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24156           BOOT_JDK_FOUND=no
24157         else
24158           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24159           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24160             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24161 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24162             BOOT_JDK_FOUND=no
24163           else
24164             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24165             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24166 
24167             # Extra M4 quote needed to protect [] in grep expression.
24168             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24169             if test "x$FOUND_CORRECT_VERSION" = x; then
24170               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24171 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24172               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24173 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24174               BOOT_JDK_FOUND=no
24175             else
24176               # We're done! :-)
24177               BOOT_JDK_FOUND=yes
24178 
24179   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24180 
24181   # Input might be given as Windows format, start by converting to
24182   # unix format.
24183   path="$BOOT_JDK"
24184   new_path=`$CYGPATH -u "$path"`
24185 
24186   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24187   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24188   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24189   # "foo.exe" is OK but "foo" is an error.
24190   #
24191   # This test is therefore slightly more accurate than "test -f" to check for file precense.
24192   # It is also a way to make sure we got the proper file name for the real test later on.
24193   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24194   if test "x$test_shortpath" = x; then
24195     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24196 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24197     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24198   fi
24199 
24200   # Call helper function which possibly converts this using DOS-style short mode.
24201   # If so, the updated path is stored in $new_path.
24202 
24203   input_path="$new_path"
24204   # Check if we need to convert this using DOS-style short mode. If the path
24205   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24206   # take no chances and rewrite it.
24207   # Note: m4 eats our [], so we need to use [ and ] instead.
24208   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24209   if test "x$has_forbidden_chars" != x; then
24210     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24211     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24212     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24213     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24214       # Going to short mode and back again did indeed matter. Since short mode is
24215       # case insensitive, let's make it lowercase to improve readability.
24216       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24217       # Now convert it back to Unix-stile (cygpath)
24218       input_path=`$CYGPATH -u "$shortmode_path"`
24219       new_path="$input_path"
24220     fi
24221   fi
24222 
24223   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24224   if test "x$test_cygdrive_prefix" = x; then
24225     # As a simple fix, exclude /usr/bin since it's not a real path.
24226     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24227       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24228       # a path prefixed by /cygdrive for fixpath to work.
24229       new_path="$CYGWIN_ROOT_PATH$input_path"
24230     fi
24231   fi
24232 
24233 
24234   if test "x$path" != "x$new_path"; then
24235     BOOT_JDK="$new_path"
24236     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24237 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24238   fi
24239 
24240   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24241 
24242   path="$BOOT_JDK"
24243   has_colon=`$ECHO $path | $GREP ^.:`
24244   new_path="$path"
24245   if test "x$has_colon" = x; then
24246     # Not in mixed or Windows style, start by that.
24247     new_path=`cmd //c echo $path`
24248   fi
24249 
24250 
24251   input_path="$new_path"
24252   # Check if we need to convert this using DOS-style short mode. If the path
24253   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24254   # take no chances and rewrite it.
24255   # Note: m4 eats our [], so we need to use [ and ] instead.
24256   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24257   if test "x$has_forbidden_chars" != x; then
24258     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24259     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24260   fi
24261 
24262 
24263   windows_path="$new_path"
24264   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24265     unix_path=`$CYGPATH -u "$windows_path"`
24266     new_path="$unix_path"
24267   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24268     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24269     new_path="$unix_path"
24270   fi
24271 
24272   if test "x$path" != "x$new_path"; then
24273     BOOT_JDK="$new_path"
24274     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24275 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24276   fi
24277 
24278   # Save the first 10 bytes of this path to the storage, so fixpath can work.
24279   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24280 
24281   else
24282     # We're on a posix platform. Hooray! :)
24283     path="$BOOT_JDK"
24284     has_space=`$ECHO "$path" | $GREP " "`
24285     if test "x$has_space" != x; then
24286       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24287 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24288       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24289     fi
24290 
24291     # Use eval to expand a potential ~
24292     eval path="$path"
24293     if test ! -f "$path" && test ! -d "$path"; then
24294       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24295     fi
24296 
24297     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24298   fi
24299 
24300               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24301 $as_echo_n "checking for Boot JDK... " >&6; }
24302               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24303 $as_echo "$BOOT_JDK" >&6; }
24304               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24305 $as_echo_n "checking Boot JDK version... " >&6; }
24306               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24307               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24308 $as_echo "$BOOT_JDK_VERSION" >&6; }
24309             fi # end check jdk version
24310           fi # end check rt.jar
24311         fi # end check javac
24312       fi # end check java
24313     fi # end check boot jdk found
24314   fi
24315 
24316   elif test "x$OPENJDK_TARGET_OS" = xlinux; then
24317 
24318   if test "x$BOOT_JDK_FOUND" = xno; then
24319     # Now execute the test
24320 
24321   BOOT_JDK_PREFIX="/usr/lib/jvm"
24322   BOOT_JDK_SUFFIX=""
24323   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
24324   if test "x$ALL_JDKS_FOUND" != x; then
24325     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
24326 
24327   if test "x$BOOT_JDK_FOUND" = xno; then
24328     # Now execute the test
24329 
24330         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
24331         if test -d "$BOOT_JDK"; then
24332           BOOT_JDK_FOUND=maybe
24333           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
24334 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
24335         fi
24336 
24337 
24338     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24339     if test "x$BOOT_JDK_FOUND" = xmaybe; then
24340       # Do we have a bin/java?
24341       if test ! -x "$BOOT_JDK/bin/java"; then
24342         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24343 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24344         BOOT_JDK_FOUND=no
24345       else
24346         # Do we have a bin/javac?
24347         if test ! -x "$BOOT_JDK/bin/javac"; then
24348           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24349 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24350           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24351 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24352           BOOT_JDK_FOUND=no
24353         else
24354           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24355           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24356             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24357 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24358             BOOT_JDK_FOUND=no
24359           else
24360             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24361             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24362 
24363             # Extra M4 quote needed to protect [] in grep expression.
24364             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24365             if test "x$FOUND_CORRECT_VERSION" = x; then
24366               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24367 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24368               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24369 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24370               BOOT_JDK_FOUND=no
24371             else
24372               # We're done! :-)
24373               BOOT_JDK_FOUND=yes
24374 
24375   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24376 
24377   # Input might be given as Windows format, start by converting to
24378   # unix format.
24379   path="$BOOT_JDK"
24380   new_path=`$CYGPATH -u "$path"`
24381 
24382   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24383   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24384   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24385   # "foo.exe" is OK but "foo" is an error.
24386   #
24387   # This test is therefore slightly more accurate than "test -f" to check for file precense.
24388   # It is also a way to make sure we got the proper file name for the real test later on.
24389   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24390   if test "x$test_shortpath" = x; then
24391     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24392 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24393     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24394   fi
24395 
24396   # Call helper function which possibly converts this using DOS-style short mode.
24397   # If so, the updated path is stored in $new_path.
24398 
24399   input_path="$new_path"
24400   # Check if we need to convert this using DOS-style short mode. If the path
24401   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24402   # take no chances and rewrite it.
24403   # Note: m4 eats our [], so we need to use [ and ] instead.
24404   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24405   if test "x$has_forbidden_chars" != x; then
24406     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24407     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24408     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24409     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24410       # Going to short mode and back again did indeed matter. Since short mode is
24411       # case insensitive, let's make it lowercase to improve readability.
24412       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24413       # Now convert it back to Unix-stile (cygpath)
24414       input_path=`$CYGPATH -u "$shortmode_path"`
24415       new_path="$input_path"
24416     fi
24417   fi
24418 
24419   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24420   if test "x$test_cygdrive_prefix" = x; then
24421     # As a simple fix, exclude /usr/bin since it's not a real path.
24422     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24423       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24424       # a path prefixed by /cygdrive for fixpath to work.
24425       new_path="$CYGWIN_ROOT_PATH$input_path"
24426     fi
24427   fi
24428 
24429 
24430   if test "x$path" != "x$new_path"; then
24431     BOOT_JDK="$new_path"
24432     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24433 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24434   fi
24435 
24436   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24437 
24438   path="$BOOT_JDK"
24439   has_colon=`$ECHO $path | $GREP ^.:`
24440   new_path="$path"
24441   if test "x$has_colon" = x; then
24442     # Not in mixed or Windows style, start by that.
24443     new_path=`cmd //c echo $path`
24444   fi
24445 
24446 
24447   input_path="$new_path"
24448   # Check if we need to convert this using DOS-style short mode. If the path
24449   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24450   # take no chances and rewrite it.
24451   # Note: m4 eats our [], so we need to use [ and ] instead.
24452   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24453   if test "x$has_forbidden_chars" != x; then
24454     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24455     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24456   fi
24457 
24458 
24459   windows_path="$new_path"
24460   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24461     unix_path=`$CYGPATH -u "$windows_path"`
24462     new_path="$unix_path"
24463   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24464     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24465     new_path="$unix_path"
24466   fi
24467 
24468   if test "x$path" != "x$new_path"; then
24469     BOOT_JDK="$new_path"
24470     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24471 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24472   fi
24473 
24474   # Save the first 10 bytes of this path to the storage, so fixpath can work.
24475   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24476 
24477   else
24478     # We're on a posix platform. Hooray! :)
24479     path="$BOOT_JDK"
24480     has_space=`$ECHO "$path" | $GREP " "`
24481     if test "x$has_space" != x; then
24482       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24483 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24484       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24485     fi
24486 
24487     # Use eval to expand a potential ~
24488     eval path="$path"
24489     if test ! -f "$path" && test ! -d "$path"; then
24490       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24491     fi
24492 
24493     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24494   fi
24495 
24496               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24497 $as_echo_n "checking for Boot JDK... " >&6; }
24498               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24499 $as_echo "$BOOT_JDK" >&6; }
24500               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24501 $as_echo_n "checking Boot JDK version... " >&6; }
24502               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24503               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24504 $as_echo "$BOOT_JDK_VERSION" >&6; }
24505             fi # end check jdk version
24506           fi # end check rt.jar
24507         fi # end check javac
24508       fi # end check java
24509     fi # end check boot jdk found
24510   fi
24511 
24512     done
24513   fi
24514 
24515 
24516     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24517     if test "x$BOOT_JDK_FOUND" = xmaybe; then
24518       # Do we have a bin/java?
24519       if test ! -x "$BOOT_JDK/bin/java"; then
24520         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24521 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24522         BOOT_JDK_FOUND=no
24523       else
24524         # Do we have a bin/javac?
24525         if test ! -x "$BOOT_JDK/bin/javac"; then
24526           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24527 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24528           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24529 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24530           BOOT_JDK_FOUND=no
24531         else
24532           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24533           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24534             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24535 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24536             BOOT_JDK_FOUND=no
24537           else
24538             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24539             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24540 
24541             # Extra M4 quote needed to protect [] in grep expression.
24542             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24543             if test "x$FOUND_CORRECT_VERSION" = x; then
24544               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24545 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24546               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24547 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24548               BOOT_JDK_FOUND=no
24549             else
24550               # We're done! :-)
24551               BOOT_JDK_FOUND=yes
24552 
24553   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24554 
24555   # Input might be given as Windows format, start by converting to
24556   # unix format.
24557   path="$BOOT_JDK"
24558   new_path=`$CYGPATH -u "$path"`
24559 
24560   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24561   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24562   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24563   # "foo.exe" is OK but "foo" is an error.
24564   #
24565   # This test is therefore slightly more accurate than "test -f" to check for file precense.
24566   # It is also a way to make sure we got the proper file name for the real test later on.
24567   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24568   if test "x$test_shortpath" = x; then
24569     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24570 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24571     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24572   fi
24573 
24574   # Call helper function which possibly converts this using DOS-style short mode.
24575   # If so, the updated path is stored in $new_path.
24576 
24577   input_path="$new_path"
24578   # Check if we need to convert this using DOS-style short mode. If the path
24579   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24580   # take no chances and rewrite it.
24581   # Note: m4 eats our [], so we need to use [ and ] instead.
24582   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24583   if test "x$has_forbidden_chars" != x; then
24584     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24585     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24586     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24587     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24588       # Going to short mode and back again did indeed matter. Since short mode is
24589       # case insensitive, let's make it lowercase to improve readability.
24590       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24591       # Now convert it back to Unix-stile (cygpath)
24592       input_path=`$CYGPATH -u "$shortmode_path"`
24593       new_path="$input_path"
24594     fi
24595   fi
24596 
24597   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24598   if test "x$test_cygdrive_prefix" = x; then
24599     # As a simple fix, exclude /usr/bin since it's not a real path.
24600     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24601       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24602       # a path prefixed by /cygdrive for fixpath to work.
24603       new_path="$CYGWIN_ROOT_PATH$input_path"
24604     fi
24605   fi
24606 
24607 
24608   if test "x$path" != "x$new_path"; then
24609     BOOT_JDK="$new_path"
24610     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24611 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24612   fi
24613 
24614   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24615 
24616   path="$BOOT_JDK"
24617   has_colon=`$ECHO $path | $GREP ^.:`
24618   new_path="$path"
24619   if test "x$has_colon" = x; then
24620     # Not in mixed or Windows style, start by that.
24621     new_path=`cmd //c echo $path`
24622   fi
24623 
24624 
24625   input_path="$new_path"
24626   # Check if we need to convert this using DOS-style short mode. If the path
24627   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24628   # take no chances and rewrite it.
24629   # Note: m4 eats our [], so we need to use [ and ] instead.
24630   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24631   if test "x$has_forbidden_chars" != x; then
24632     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24633     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24634   fi
24635 
24636 
24637   windows_path="$new_path"
24638   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24639     unix_path=`$CYGPATH -u "$windows_path"`
24640     new_path="$unix_path"
24641   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24642     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24643     new_path="$unix_path"
24644   fi
24645 
24646   if test "x$path" != "x$new_path"; then
24647     BOOT_JDK="$new_path"
24648     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24649 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24650   fi
24651 
24652   # Save the first 10 bytes of this path to the storage, so fixpath can work.
24653   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24654 
24655   else
24656     # We're on a posix platform. Hooray! :)
24657     path="$BOOT_JDK"
24658     has_space=`$ECHO "$path" | $GREP " "`
24659     if test "x$has_space" != x; then
24660       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24661 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24662       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24663     fi
24664 
24665     # Use eval to expand a potential ~
24666     eval path="$path"
24667     if test ! -f "$path" && test ! -d "$path"; then
24668       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24669     fi
24670 
24671     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24672   fi
24673 
24674               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24675 $as_echo_n "checking for Boot JDK... " >&6; }
24676               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24677 $as_echo "$BOOT_JDK" >&6; }
24678               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24679 $as_echo_n "checking Boot JDK version... " >&6; }
24680               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24681               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24682 $as_echo "$BOOT_JDK_VERSION" >&6; }
24683             fi # end check jdk version
24684           fi # end check rt.jar
24685         fi # end check javac
24686       fi # end check java
24687     fi # end check boot jdk found
24688   fi
24689 
24690   fi
24691 
24692 
24693     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24694     if test "x$BOOT_JDK_FOUND" = xmaybe; then
24695       # Do we have a bin/java?
24696       if test ! -x "$BOOT_JDK/bin/java"; then
24697         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24698 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24699         BOOT_JDK_FOUND=no
24700       else
24701         # Do we have a bin/javac?
24702         if test ! -x "$BOOT_JDK/bin/javac"; then
24703           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24704 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24705           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24706 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24707           BOOT_JDK_FOUND=no
24708         else
24709           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24710           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24711             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24712 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24713             BOOT_JDK_FOUND=no
24714           else
24715             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24716             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24717 
24718             # Extra M4 quote needed to protect [] in grep expression.
24719             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[789]\.'`
24720             if test "x$FOUND_CORRECT_VERSION" = x; then
24721               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24722 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24723               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 7, 8 or 9)" >&5
24724 $as_echo "$as_me: (Your Boot JDK must be version 7, 8 or 9)" >&6;}
24725               BOOT_JDK_FOUND=no
24726             else
24727               # We're done! :-)
24728               BOOT_JDK_FOUND=yes
24729 
24730   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24731 
24732   # Input might be given as Windows format, start by converting to
24733   # unix format.
24734   path="$BOOT_JDK"
24735   new_path=`$CYGPATH -u "$path"`
24736 
24737   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24738   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24739   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24740   # "foo.exe" is OK but "foo" is an error.
24741   #
24742   # This test is therefore slightly more accurate than "test -f" to check for file precense.
24743   # It is also a way to make sure we got the proper file name for the real test later on.
24744   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24745   if test "x$test_shortpath" = x; then
24746     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24747 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24748     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24749   fi
24750 
24751   # Call helper function which possibly converts this using DOS-style short mode.
24752   # If so, the updated path is stored in $new_path.
24753 
24754   input_path="$new_path"
24755   # Check if we need to convert this using DOS-style short mode. If the path
24756   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24757   # take no chances and rewrite it.
24758   # Note: m4 eats our [], so we need to use [ and ] instead.
24759   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24760   if test "x$has_forbidden_chars" != x; then
24761     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24762     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24763     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24764     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24765       # Going to short mode and back again did indeed matter. Since short mode is
24766       # case insensitive, let's make it lowercase to improve readability.
24767       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24768       # Now convert it back to Unix-stile (cygpath)
24769       input_path=`$CYGPATH -u "$shortmode_path"`
24770       new_path="$input_path"
24771     fi
24772   fi
24773 
24774   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24775   if test "x$test_cygdrive_prefix" = x; then
24776     # As a simple fix, exclude /usr/bin since it's not a real path.
24777     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24778       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24779       # a path prefixed by /cygdrive for fixpath to work.
24780       new_path="$CYGWIN_ROOT_PATH$input_path"
24781     fi
24782   fi
24783 
24784 
24785   if test "x$path" != "x$new_path"; then
24786     BOOT_JDK="$new_path"
24787     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24788 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24789   fi
24790 
24791   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24792 
24793   path="$BOOT_JDK"
24794   has_colon=`$ECHO $path | $GREP ^.:`
24795   new_path="$path"
24796   if test "x$has_colon" = x; then
24797     # Not in mixed or Windows style, start by that.
24798     new_path=`cmd //c echo $path`
24799   fi
24800 
24801 
24802   input_path="$new_path"
24803   # Check if we need to convert this using DOS-style short mode. If the path
24804   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24805   # take no chances and rewrite it.
24806   # Note: m4 eats our [], so we need to use [ and ] instead.
24807   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24808   if test "x$has_forbidden_chars" != x; then
24809     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24810     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24811   fi
24812 
24813 
24814   windows_path="$new_path"
24815   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24816     unix_path=`$CYGPATH -u "$windows_path"`
24817     new_path="$unix_path"
24818   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24819     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24820     new_path="$unix_path"
24821   fi
24822 
24823   if test "x$path" != "x$new_path"; then
24824     BOOT_JDK="$new_path"
24825     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24826 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24827   fi
24828 
24829   # Save the first 10 bytes of this path to the storage, so fixpath can work.
24830   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24831 
24832   else
24833     # We're on a posix platform. Hooray! :)
24834     path="$BOOT_JDK"
24835     has_space=`$ECHO "$path" | $GREP " "`
24836     if test "x$has_space" != x; then
24837       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24838 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24839       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24840     fi
24841 
24842     # Use eval to expand a potential ~
24843     eval path="$path"
24844     if test ! -f "$path" && test ! -d "$path"; then
24845       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24846     fi
24847 
24848     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24849   fi
24850 
24851               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24852 $as_echo_n "checking for Boot JDK... " >&6; }
24853               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24854 $as_echo "$BOOT_JDK" >&6; }
24855               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24856 $as_echo_n "checking Boot JDK version... " >&6; }
24857               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24858               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24859 $as_echo "$BOOT_JDK_VERSION" >&6; }
24860             fi # end check jdk version
24861           fi # end check rt.jar
24862         fi # end check javac
24863       fi # end check java
24864     fi # end check boot jdk found
24865   fi
24866 
24867 
24868   # If we haven't found anything yet, we've truly lost. Give up.
24869   if test "x$BOOT_JDK_FOUND" = xno; then
24870 
24871   # Print a helpful message on how to acquire the necessary build dependency.
24872   # openjdk is the help tag: freetype, cups, pulse, alsa etc
24873   MISSING_DEPENDENCY=openjdk
24874 
24875   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24876     cygwin_help $MISSING_DEPENDENCY
24877   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24878     msys_help $MISSING_DEPENDENCY
24879   else
24880     PKGHANDLER_COMMAND=
24881 
24882     case $PKGHANDLER in
24883       apt-get)
24884         apt_help     $MISSING_DEPENDENCY ;;
24885       yum)
24886         yum_help     $MISSING_DEPENDENCY ;;
24887       port)
24888         port_help    $MISSING_DEPENDENCY ;;
24889       pkgutil)
24890         pkgutil_help $MISSING_DEPENDENCY ;;
24891       pkgadd)
24892         pkgadd_help  $MISSING_DEPENDENCY ;;
24893     esac
24894 
24895     if test "x$PKGHANDLER_COMMAND" != x; then
24896       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
24897     fi
24898   fi
24899 
24900     { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find a valid Boot JDK. $HELP_MSG" >&5
24901 $as_echo "$as_me: Could not find a valid Boot JDK. $HELP_MSG" >&6;}
24902     { $as_echo "$as_me:${as_lineno-$LINENO}: This might be fixed by explicitely setting --with-boot-jdk" >&5
24903 $as_echo "$as_me: This might be fixed by explicitely setting --with-boot-jdk" >&6;}
24904     as_fn_error $? "Cannot continue" "$LINENO" 5
24905   fi
24906 
24907   # Setup proper paths for what we found
24908   BOOT_RTJAR="$BOOT_JDK/jre/lib/rt.jar"
24909   if test ! -f "$BOOT_RTJAR"; then
24910     # On MacOSX it is called classes.jar
24911     BOOT_RTJAR="$BOOT_JDK/../Classes/classes.jar"
24912     if test -f "$BOOT_RTJAR"; then
24913       # Remove the ..
24914       BOOT_RTJAR="`cd ${BOOT_RTJAR%/*} && pwd`/${BOOT_RTJAR##*/}"
24915     fi
24916   fi
24917   BOOT_TOOLSJAR="$BOOT_JDK/lib/tools.jar"
24918   BOOT_JDK="$BOOT_JDK"
24919 
24920 
24921 
24922 
24923   # Setup tools from the Boot JDK.
24924 
24925   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
24926 
24927   # Publish this variable in the help.
24928 
24929 
24930   if test "x$JAVA" = x; then
24931     # The variable is not set by user, try to locate tool using the code snippet
24932 
24933       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5
24934 $as_echo_n "checking for java in Boot JDK... " >&6; }
24935       JAVA=$BOOT_JDK/bin/java
24936       if test ! -x $JAVA; then
24937         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
24938 $as_echo "not found" >&6; }
24939         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
24940 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
24941         as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5
24942       fi
24943       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
24944 $as_echo "ok" >&6; }
24945 
24946 
24947   else
24948     # The variable is set, but is it from the command line or the environment?
24949 
24950     # Try to remove the string !JAVA! from our list.
24951     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVA!/}
24952     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
24953       # If it failed, the variable was not from the command line. Ignore it,
24954       # but warn the user (except for BASH, which is always set by the calling BASH).
24955       if test "xJAVA" != xBASH; then
24956         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&5
24957 $as_echo "$as_me: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&2;}
24958       fi
24959       # Try to locate tool using the code snippet
24960 
24961       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5
24962 $as_echo_n "checking for java in Boot JDK... " >&6; }
24963       JAVA=$BOOT_JDK/bin/java
24964       if test ! -x $JAVA; then
24965         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
24966 $as_echo "not found" >&6; }
24967         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
24968 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
24969         as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5
24970       fi
24971       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
24972 $as_echo "ok" >&6; }
24973 
24974 
24975     else
24976       # If it succeeded, then it was overridden by the user. We will use it
24977       # for the tool.
24978 
24979       # First remove it from the list of overridden variables, so we can test
24980       # for unknown variables in the end.
24981       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
24982 
24983       # Check if the provided tool contains a complete path.
24984       tool_specified="$JAVA"
24985       tool_basename="${tool_specified##*/}"
24986       if test "x$tool_basename" = "x$tool_specified"; then
24987         # A command without a complete path is provided, search $PATH.
24988         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVA=$tool_basename" >&5
24989 $as_echo "$as_me: Will search for user supplied tool JAVA=$tool_basename" >&6;}
24990         # Extract the first word of "$tool_basename", so it can be a program name with args.
24991 set dummy $tool_basename; ac_word=$2
24992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24993 $as_echo_n "checking for $ac_word... " >&6; }
24994 if ${ac_cv_path_JAVA+:} false; then :
24995   $as_echo_n "(cached) " >&6
24996 else
24997   case $JAVA in
24998   [\\/]* | ?:[\\/]*)
24999   ac_cv_path_JAVA="$JAVA" # Let the user override the test with a path.
25000   ;;
25001   *)
25002   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25003 for as_dir in $PATH
25004 do
25005   IFS=$as_save_IFS
25006   test -z "$as_dir" && as_dir=.
25007     for ac_exec_ext in '' $ac_executable_extensions; do
25008   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25009     ac_cv_path_JAVA="$as_dir/$ac_word$ac_exec_ext"
25010     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25011     break 2
25012   fi
25013 done
25014   done
25015 IFS=$as_save_IFS
25016 
25017   ;;
25018 esac
25019 fi
25020 JAVA=$ac_cv_path_JAVA
25021 if test -n "$JAVA"; then
25022   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA" >&5
25023 $as_echo "$JAVA" >&6; }
25024 else
25025   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25026 $as_echo "no" >&6; }
25027 fi
25028 
25029 
25030         if test "x$JAVA" = x; then
25031           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25032         fi
25033       else
25034         # Otherwise we believe it is a complete path. Use it as it is.
25035         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVA=$tool_specified" >&5
25036 $as_echo "$as_me: Will use user supplied tool JAVA=$tool_specified" >&6;}
25037         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5
25038 $as_echo_n "checking for JAVA... " >&6; }
25039         if test ! -x "$tool_specified"; then
25040           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25041 $as_echo "not found" >&6; }
25042           as_fn_error $? "User supplied tool JAVA=$tool_specified does not exist or is not executable" "$LINENO" 5
25043         fi
25044         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25045 $as_echo "$tool_specified" >&6; }
25046       fi
25047     fi
25048   fi
25049 
25050 
25051 
25052   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25053 
25054   # Publish this variable in the help.
25055 
25056 
25057   if test "x$JAVAC" = x; then
25058     # The variable is not set by user, try to locate tool using the code snippet
25059 
25060       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5
25061 $as_echo_n "checking for javac in Boot JDK... " >&6; }
25062       JAVAC=$BOOT_JDK/bin/javac
25063       if test ! -x $JAVAC; then
25064         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25065 $as_echo "not found" >&6; }
25066         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25067 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25068         as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5
25069       fi
25070       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25071 $as_echo "ok" >&6; }
25072 
25073 
25074   else
25075     # The variable is set, but is it from the command line or the environment?
25076 
25077     # Try to remove the string !JAVAC! from our list.
25078     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAC!/}
25079     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25080       # If it failed, the variable was not from the command line. Ignore it,
25081       # but warn the user (except for BASH, which is always set by the calling BASH).
25082       if test "xJAVAC" != xBASH; then
25083         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&5
25084 $as_echo "$as_me: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&2;}
25085       fi
25086       # Try to locate tool using the code snippet
25087 
25088       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5
25089 $as_echo_n "checking for javac in Boot JDK... " >&6; }
25090       JAVAC=$BOOT_JDK/bin/javac
25091       if test ! -x $JAVAC; then
25092         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25093 $as_echo "not found" >&6; }
25094         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25095 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25096         as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5
25097       fi
25098       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25099 $as_echo "ok" >&6; }
25100 
25101 
25102     else
25103       # If it succeeded, then it was overridden by the user. We will use it
25104       # for the tool.
25105 
25106       # First remove it from the list of overridden variables, so we can test
25107       # for unknown variables in the end.
25108       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25109 
25110       # Check if the provided tool contains a complete path.
25111       tool_specified="$JAVAC"
25112       tool_basename="${tool_specified##*/}"
25113       if test "x$tool_basename" = "x$tool_specified"; then
25114         # A command without a complete path is provided, search $PATH.
25115         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAC=$tool_basename" >&5
25116 $as_echo "$as_me: Will search for user supplied tool JAVAC=$tool_basename" >&6;}
25117         # Extract the first word of "$tool_basename", so it can be a program name with args.
25118 set dummy $tool_basename; ac_word=$2
25119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25120 $as_echo_n "checking for $ac_word... " >&6; }
25121 if ${ac_cv_path_JAVAC+:} false; then :
25122   $as_echo_n "(cached) " >&6
25123 else
25124   case $JAVAC in
25125   [\\/]* | ?:[\\/]*)
25126   ac_cv_path_JAVAC="$JAVAC" # Let the user override the test with a path.
25127   ;;
25128   *)
25129   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25130 for as_dir in $PATH
25131 do
25132   IFS=$as_save_IFS
25133   test -z "$as_dir" && as_dir=.
25134     for ac_exec_ext in '' $ac_executable_extensions; do
25135   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25136     ac_cv_path_JAVAC="$as_dir/$ac_word$ac_exec_ext"
25137     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25138     break 2
25139   fi
25140 done
25141   done
25142 IFS=$as_save_IFS
25143 
25144   ;;
25145 esac
25146 fi
25147 JAVAC=$ac_cv_path_JAVAC
25148 if test -n "$JAVAC"; then
25149   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC" >&5
25150 $as_echo "$JAVAC" >&6; }
25151 else
25152   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25153 $as_echo "no" >&6; }
25154 fi
25155 
25156 
25157         if test "x$JAVAC" = x; then
25158           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25159         fi
25160       else
25161         # Otherwise we believe it is a complete path. Use it as it is.
25162         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAC=$tool_specified" >&5
25163 $as_echo "$as_me: Will use user supplied tool JAVAC=$tool_specified" >&6;}
25164         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5
25165 $as_echo_n "checking for JAVAC... " >&6; }
25166         if test ! -x "$tool_specified"; then
25167           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25168 $as_echo "not found" >&6; }
25169           as_fn_error $? "User supplied tool JAVAC=$tool_specified does not exist or is not executable" "$LINENO" 5
25170         fi
25171         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25172 $as_echo "$tool_specified" >&6; }
25173       fi
25174     fi
25175   fi
25176 
25177 
25178 
25179   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25180 
25181   # Publish this variable in the help.
25182 
25183 
25184   if test "x$JAVAH" = x; then
25185     # The variable is not set by user, try to locate tool using the code snippet
25186 
25187       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5
25188 $as_echo_n "checking for javah in Boot JDK... " >&6; }
25189       JAVAH=$BOOT_JDK/bin/javah
25190       if test ! -x $JAVAH; then
25191         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25192 $as_echo "not found" >&6; }
25193         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25194 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25195         as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5
25196       fi
25197       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25198 $as_echo "ok" >&6; }
25199 
25200 
25201   else
25202     # The variable is set, but is it from the command line or the environment?
25203 
25204     # Try to remove the string !JAVAH! from our list.
25205     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAH!/}
25206     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25207       # If it failed, the variable was not from the command line. Ignore it,
25208       # but warn the user (except for BASH, which is always set by the calling BASH).
25209       if test "xJAVAH" != xBASH; then
25210         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&5
25211 $as_echo "$as_me: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&2;}
25212       fi
25213       # Try to locate tool using the code snippet
25214 
25215       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5
25216 $as_echo_n "checking for javah in Boot JDK... " >&6; }
25217       JAVAH=$BOOT_JDK/bin/javah
25218       if test ! -x $JAVAH; then
25219         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25220 $as_echo "not found" >&6; }
25221         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25222 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25223         as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5
25224       fi
25225       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25226 $as_echo "ok" >&6; }
25227 
25228 
25229     else
25230       # If it succeeded, then it was overridden by the user. We will use it
25231       # for the tool.
25232 
25233       # First remove it from the list of overridden variables, so we can test
25234       # for unknown variables in the end.
25235       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25236 
25237       # Check if the provided tool contains a complete path.
25238       tool_specified="$JAVAH"
25239       tool_basename="${tool_specified##*/}"
25240       if test "x$tool_basename" = "x$tool_specified"; then
25241         # A command without a complete path is provided, search $PATH.
25242         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAH=$tool_basename" >&5
25243 $as_echo "$as_me: Will search for user supplied tool JAVAH=$tool_basename" >&6;}
25244         # Extract the first word of "$tool_basename", so it can be a program name with args.
25245 set dummy $tool_basename; ac_word=$2
25246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25247 $as_echo_n "checking for $ac_word... " >&6; }
25248 if ${ac_cv_path_JAVAH+:} false; then :
25249   $as_echo_n "(cached) " >&6
25250 else
25251   case $JAVAH in
25252   [\\/]* | ?:[\\/]*)
25253   ac_cv_path_JAVAH="$JAVAH" # Let the user override the test with a path.
25254   ;;
25255   *)
25256   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25257 for as_dir in $PATH
25258 do
25259   IFS=$as_save_IFS
25260   test -z "$as_dir" && as_dir=.
25261     for ac_exec_ext in '' $ac_executable_extensions; do
25262   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25263     ac_cv_path_JAVAH="$as_dir/$ac_word$ac_exec_ext"
25264     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25265     break 2
25266   fi
25267 done
25268   done
25269 IFS=$as_save_IFS
25270 
25271   ;;
25272 esac
25273 fi
25274 JAVAH=$ac_cv_path_JAVAH
25275 if test -n "$JAVAH"; then
25276   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAH" >&5
25277 $as_echo "$JAVAH" >&6; }
25278 else
25279   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25280 $as_echo "no" >&6; }
25281 fi
25282 
25283 
25284         if test "x$JAVAH" = x; then
25285           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25286         fi
25287       else
25288         # Otherwise we believe it is a complete path. Use it as it is.
25289         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAH=$tool_specified" >&5
25290 $as_echo "$as_me: Will use user supplied tool JAVAH=$tool_specified" >&6;}
25291         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5
25292 $as_echo_n "checking for JAVAH... " >&6; }
25293         if test ! -x "$tool_specified"; then
25294           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25295 $as_echo "not found" >&6; }
25296           as_fn_error $? "User supplied tool JAVAH=$tool_specified does not exist or is not executable" "$LINENO" 5
25297         fi
25298         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25299 $as_echo "$tool_specified" >&6; }
25300       fi
25301     fi
25302   fi
25303 
25304 
25305 
25306   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25307 
25308   # Publish this variable in the help.
25309 
25310 
25311   if test "x$JAR" = x; then
25312     # The variable is not set by user, try to locate tool using the code snippet
25313 
25314       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5
25315 $as_echo_n "checking for jar in Boot JDK... " >&6; }
25316       JAR=$BOOT_JDK/bin/jar
25317       if test ! -x $JAR; then
25318         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25319 $as_echo "not found" >&6; }
25320         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25321 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25322         as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5
25323       fi
25324       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25325 $as_echo "ok" >&6; }
25326 
25327 
25328   else
25329     # The variable is set, but is it from the command line or the environment?
25330 
25331     # Try to remove the string !JAR! from our list.
25332     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAR!/}
25333     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25334       # If it failed, the variable was not from the command line. Ignore it,
25335       # but warn the user (except for BASH, which is always set by the calling BASH).
25336       if test "xJAR" != xBASH; then
25337         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&5
25338 $as_echo "$as_me: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&2;}
25339       fi
25340       # Try to locate tool using the code snippet
25341 
25342       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5
25343 $as_echo_n "checking for jar in Boot JDK... " >&6; }
25344       JAR=$BOOT_JDK/bin/jar
25345       if test ! -x $JAR; then
25346         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25347 $as_echo "not found" >&6; }
25348         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25349 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25350         as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5
25351       fi
25352       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25353 $as_echo "ok" >&6; }
25354 
25355 
25356     else
25357       # If it succeeded, then it was overridden by the user. We will use it
25358       # for the tool.
25359 
25360       # First remove it from the list of overridden variables, so we can test
25361       # for unknown variables in the end.
25362       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25363 
25364       # Check if the provided tool contains a complete path.
25365       tool_specified="$JAR"
25366       tool_basename="${tool_specified##*/}"
25367       if test "x$tool_basename" = "x$tool_specified"; then
25368         # A command without a complete path is provided, search $PATH.
25369         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAR=$tool_basename" >&5
25370 $as_echo "$as_me: Will search for user supplied tool JAR=$tool_basename" >&6;}
25371         # Extract the first word of "$tool_basename", so it can be a program name with args.
25372 set dummy $tool_basename; ac_word=$2
25373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25374 $as_echo_n "checking for $ac_word... " >&6; }
25375 if ${ac_cv_path_JAR+:} false; then :
25376   $as_echo_n "(cached) " >&6
25377 else
25378   case $JAR in
25379   [\\/]* | ?:[\\/]*)
25380   ac_cv_path_JAR="$JAR" # Let the user override the test with a path.
25381   ;;
25382   *)
25383   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25384 for as_dir in $PATH
25385 do
25386   IFS=$as_save_IFS
25387   test -z "$as_dir" && as_dir=.
25388     for ac_exec_ext in '' $ac_executable_extensions; do
25389   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25390     ac_cv_path_JAR="$as_dir/$ac_word$ac_exec_ext"
25391     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25392     break 2
25393   fi
25394 done
25395   done
25396 IFS=$as_save_IFS
25397 
25398   ;;
25399 esac
25400 fi
25401 JAR=$ac_cv_path_JAR
25402 if test -n "$JAR"; then
25403   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAR" >&5
25404 $as_echo "$JAR" >&6; }
25405 else
25406   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25407 $as_echo "no" >&6; }
25408 fi
25409 
25410 
25411         if test "x$JAR" = x; then
25412           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25413         fi
25414       else
25415         # Otherwise we believe it is a complete path. Use it as it is.
25416         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAR=$tool_specified" >&5
25417 $as_echo "$as_me: Will use user supplied tool JAR=$tool_specified" >&6;}
25418         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5
25419 $as_echo_n "checking for JAR... " >&6; }
25420         if test ! -x "$tool_specified"; then
25421           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25422 $as_echo "not found" >&6; }
25423           as_fn_error $? "User supplied tool JAR=$tool_specified does not exist or is not executable" "$LINENO" 5
25424         fi
25425         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25426 $as_echo "$tool_specified" >&6; }
25427       fi
25428     fi
25429   fi
25430 
25431 
25432 
25433   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25434 
25435   # Publish this variable in the help.
25436 
25437 
25438   if test "x$NATIVE2ASCII" = x; then
25439     # The variable is not set by user, try to locate tool using the code snippet
25440 
25441       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for native2ascii in Boot JDK" >&5
25442 $as_echo_n "checking for native2ascii in Boot JDK... " >&6; }
25443       NATIVE2ASCII=$BOOT_JDK/bin/native2ascii
25444       if test ! -x $NATIVE2ASCII; then
25445         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25446 $as_echo "not found" >&6; }
25447         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25448 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25449         as_fn_error $? "Could not find native2ascii in the Boot JDK" "$LINENO" 5
25450       fi
25451       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25452 $as_echo "ok" >&6; }
25453 
25454 
25455   else
25456     # The variable is set, but is it from the command line or the environment?
25457 
25458     # Try to remove the string !NATIVE2ASCII! from our list.
25459     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NATIVE2ASCII!/}
25460     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25461       # If it failed, the variable was not from the command line. Ignore it,
25462       # but warn the user (except for BASH, which is always set by the calling BASH).
25463       if test "xNATIVE2ASCII" != xBASH; then
25464         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NATIVE2ASCII from the environment. Use command line variables instead." >&5
25465 $as_echo "$as_me: WARNING: Ignoring value of NATIVE2ASCII from the environment. Use command line variables instead." >&2;}
25466       fi
25467       # Try to locate tool using the code snippet
25468 
25469       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for native2ascii in Boot JDK" >&5
25470 $as_echo_n "checking for native2ascii in Boot JDK... " >&6; }
25471       NATIVE2ASCII=$BOOT_JDK/bin/native2ascii
25472       if test ! -x $NATIVE2ASCII; then
25473         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25474 $as_echo "not found" >&6; }
25475         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25476 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25477         as_fn_error $? "Could not find native2ascii in the Boot JDK" "$LINENO" 5
25478       fi
25479       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25480 $as_echo "ok" >&6; }
25481 
25482 
25483     else
25484       # If it succeeded, then it was overridden by the user. We will use it
25485       # for the tool.
25486 
25487       # First remove it from the list of overridden variables, so we can test
25488       # for unknown variables in the end.
25489       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25490 
25491       # Check if the provided tool contains a complete path.
25492       tool_specified="$NATIVE2ASCII"
25493       tool_basename="${tool_specified##*/}"
25494       if test "x$tool_basename" = "x$tool_specified"; then
25495         # A command without a complete path is provided, search $PATH.
25496         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NATIVE2ASCII=$tool_basename" >&5
25497 $as_echo "$as_me: Will search for user supplied tool NATIVE2ASCII=$tool_basename" >&6;}
25498         # Extract the first word of "$tool_basename", so it can be a program name with args.
25499 set dummy $tool_basename; ac_word=$2
25500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25501 $as_echo_n "checking for $ac_word... " >&6; }
25502 if ${ac_cv_path_NATIVE2ASCII+:} false; then :
25503   $as_echo_n "(cached) " >&6
25504 else
25505   case $NATIVE2ASCII in
25506   [\\/]* | ?:[\\/]*)
25507   ac_cv_path_NATIVE2ASCII="$NATIVE2ASCII" # Let the user override the test with a path.
25508   ;;
25509   *)
25510   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25511 for as_dir in $PATH
25512 do
25513   IFS=$as_save_IFS
25514   test -z "$as_dir" && as_dir=.
25515     for ac_exec_ext in '' $ac_executable_extensions; do
25516   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25517     ac_cv_path_NATIVE2ASCII="$as_dir/$ac_word$ac_exec_ext"
25518     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25519     break 2
25520   fi
25521 done
25522   done
25523 IFS=$as_save_IFS
25524 
25525   ;;
25526 esac
25527 fi
25528 NATIVE2ASCII=$ac_cv_path_NATIVE2ASCII
25529 if test -n "$NATIVE2ASCII"; then
25530   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NATIVE2ASCII" >&5
25531 $as_echo "$NATIVE2ASCII" >&6; }
25532 else
25533   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25534 $as_echo "no" >&6; }
25535 fi
25536 
25537 
25538         if test "x$NATIVE2ASCII" = x; then
25539           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25540         fi
25541       else
25542         # Otherwise we believe it is a complete path. Use it as it is.
25543         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NATIVE2ASCII=$tool_specified" >&5
25544 $as_echo "$as_me: Will use user supplied tool NATIVE2ASCII=$tool_specified" >&6;}
25545         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NATIVE2ASCII" >&5
25546 $as_echo_n "checking for NATIVE2ASCII... " >&6; }
25547         if test ! -x "$tool_specified"; then
25548           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25549 $as_echo "not found" >&6; }
25550           as_fn_error $? "User supplied tool NATIVE2ASCII=$tool_specified does not exist or is not executable" "$LINENO" 5
25551         fi
25552         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25553 $as_echo "$tool_specified" >&6; }
25554       fi
25555     fi
25556   fi
25557 
25558 
25559 
25560   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25561 
25562   # Publish this variable in the help.
25563 
25564 
25565   if test "x$JARSIGNER" = x; then
25566     # The variable is not set by user, try to locate tool using the code snippet
25567 
25568       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5
25569 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; }
25570       JARSIGNER=$BOOT_JDK/bin/jarsigner
25571       if test ! -x $JARSIGNER; then
25572         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25573 $as_echo "not found" >&6; }
25574         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25575 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25576         as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5
25577       fi
25578       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25579 $as_echo "ok" >&6; }
25580 
25581 
25582   else
25583     # The variable is set, but is it from the command line or the environment?
25584 
25585     # Try to remove the string !JARSIGNER! from our list.
25586     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JARSIGNER!/}
25587     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25588       # If it failed, the variable was not from the command line. Ignore it,
25589       # but warn the user (except for BASH, which is always set by the calling BASH).
25590       if test "xJARSIGNER" != xBASH; then
25591         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&5
25592 $as_echo "$as_me: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&2;}
25593       fi
25594       # Try to locate tool using the code snippet
25595 
25596       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5
25597 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; }
25598       JARSIGNER=$BOOT_JDK/bin/jarsigner
25599       if test ! -x $JARSIGNER; then
25600         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25601 $as_echo "not found" >&6; }
25602         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25603 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25604         as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5
25605       fi
25606       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25607 $as_echo "ok" >&6; }
25608 
25609 
25610     else
25611       # If it succeeded, then it was overridden by the user. We will use it
25612       # for the tool.
25613 
25614       # First remove it from the list of overridden variables, so we can test
25615       # for unknown variables in the end.
25616       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25617 
25618       # Check if the provided tool contains a complete path.
25619       tool_specified="$JARSIGNER"
25620       tool_basename="${tool_specified##*/}"
25621       if test "x$tool_basename" = "x$tool_specified"; then
25622         # A command without a complete path is provided, search $PATH.
25623         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JARSIGNER=$tool_basename" >&5
25624 $as_echo "$as_me: Will search for user supplied tool JARSIGNER=$tool_basename" >&6;}
25625         # Extract the first word of "$tool_basename", so it can be a program name with args.
25626 set dummy $tool_basename; ac_word=$2
25627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25628 $as_echo_n "checking for $ac_word... " >&6; }
25629 if ${ac_cv_path_JARSIGNER+:} false; then :
25630   $as_echo_n "(cached) " >&6
25631 else
25632   case $JARSIGNER in
25633   [\\/]* | ?:[\\/]*)
25634   ac_cv_path_JARSIGNER="$JARSIGNER" # Let the user override the test with a path.
25635   ;;
25636   *)
25637   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25638 for as_dir in $PATH
25639 do
25640   IFS=$as_save_IFS
25641   test -z "$as_dir" && as_dir=.
25642     for ac_exec_ext in '' $ac_executable_extensions; do
25643   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25644     ac_cv_path_JARSIGNER="$as_dir/$ac_word$ac_exec_ext"
25645     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25646     break 2
25647   fi
25648 done
25649   done
25650 IFS=$as_save_IFS
25651 
25652   ;;
25653 esac
25654 fi
25655 JARSIGNER=$ac_cv_path_JARSIGNER
25656 if test -n "$JARSIGNER"; then
25657   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JARSIGNER" >&5
25658 $as_echo "$JARSIGNER" >&6; }
25659 else
25660   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25661 $as_echo "no" >&6; }
25662 fi
25663 
25664 
25665         if test "x$JARSIGNER" = x; then
25666           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25667         fi
25668       else
25669         # Otherwise we believe it is a complete path. Use it as it is.
25670         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JARSIGNER=$tool_specified" >&5
25671 $as_echo "$as_me: Will use user supplied tool JARSIGNER=$tool_specified" >&6;}
25672         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5
25673 $as_echo_n "checking for JARSIGNER... " >&6; }
25674         if test ! -x "$tool_specified"; then
25675           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25676 $as_echo "not found" >&6; }
25677           as_fn_error $? "User supplied tool JARSIGNER=$tool_specified does not exist or is not executable" "$LINENO" 5
25678         fi
25679         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25680 $as_echo "$tool_specified" >&6; }
25681       fi
25682     fi
25683   fi
25684 
25685 
25686 
25687   # Finally, set some other options...
25688 
25689   # When compiling code to be executed by the Boot JDK, force jdk7 compatibility.
25690   BOOT_JDK_SOURCETARGET="-source 7 -target 7"
25691 
25692 
25693 
25694 
25695   ##############################################################################
25696   #
25697   # Specify options for anything that is run with the Boot JDK.
25698   #
25699 
25700 # Check whether --with-boot-jdk-jvmargs was given.
25701 if test "${with_boot_jdk_jvmargs+set}" = set; then :
25702   withval=$with_boot_jdk_jvmargs;
25703 fi
25704 
25705 
25706   if test "x$with_boot_jdk_jvmargs" = x; then
25707     # Not all JVM:s accept the same arguments on the command line.
25708     # OpenJDK specific increase in thread stack for JDK build,
25709     # well more specifically, when running javac.
25710     if test "x$BUILD_NUM_BITS" = x32; then
25711       STACK_SIZE=768
25712     else
25713       # Running Javac on a JVM on a 64-bit machine, the stack takes more space
25714       # since 64-bit pointers are pushed on the stach. Apparently, we need
25715       # to increase the stack space when javacing the JDK....
25716       STACK_SIZE=1536
25717     fi
25718 
25719     # Minimum amount of heap memory.
25720 
25721   $ECHO "Check if jvm arg is ok: -Xms64M" >&5
25722   $ECHO "Command: $JAVA -Xms64M -version" >&5
25723   OUTPUT=`$JAVA -Xms64M -version 2>&1`
25724   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
25725   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
25726   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
25727     boot_jdk_jvmargs="$boot_jdk_jvmargs -Xms64M"
25728     JVM_ARG_OK=true
25729   else
25730     $ECHO "Arg failed:" >&5
25731     $ECHO "$OUTPUT" >&5
25732     JVM_ARG_OK=false
25733   fi
25734 
25735     if test "x$OPENJDK_TARGET_OS" = "xmacosx" || test "x$OPENJDK_TARGET_CPU" = "xppc64" ; then
25736       # Why does macosx need more heap? Its the huge JDK batch.
25737 
25738   $ECHO "Check if jvm arg is ok: -Xmx1600M" >&5
25739   $ECHO "Command: $JAVA -Xmx1600M -version" >&5
25740   OUTPUT=`$JAVA -Xmx1600M -version 2>&1`
25741   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
25742   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
25743   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
25744     boot_jdk_jvmargs="$boot_jdk_jvmargs -Xmx1600M"
25745     JVM_ARG_OK=true
25746   else
25747     $ECHO "Arg failed:" >&5
25748     $ECHO "$OUTPUT" >&5
25749     JVM_ARG_OK=false
25750   fi
25751 
25752     else
25753 
25754   $ECHO "Check if jvm arg is ok: -Xmx1100M" >&5
25755   $ECHO "Command: $JAVA -Xmx1100M -version" >&5
25756   OUTPUT=`$JAVA -Xmx1100M -version 2>&1`
25757   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
25758   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
25759   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
25760     boot_jdk_jvmargs="$boot_jdk_jvmargs -Xmx1100M"
25761     JVM_ARG_OK=true
25762   else
25763     $ECHO "Arg failed:" >&5
25764     $ECHO "$OUTPUT" >&5
25765     JVM_ARG_OK=false
25766   fi
25767 
25768     fi
25769     # When is adding -client something that speeds up the JVM?
25770     # ADD_JVM_ARG_IF_OK([-client],boot_jdk_jvmargs,[$JAVA])
25771 
25772   $ECHO "Check if jvm arg is ok: -XX:ThreadStackSize=$STACK_SIZE" >&5
25773   $ECHO "Command: $JAVA -XX:ThreadStackSize=$STACK_SIZE -version" >&5
25774   OUTPUT=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1`
25775   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
25776   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
25777   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
25778     boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:ThreadStackSize=$STACK_SIZE"
25779     JVM_ARG_OK=true
25780   else
25781     $ECHO "Arg failed:" >&5
25782     $ECHO "$OUTPUT" >&5
25783     JVM_ARG_OK=false
25784   fi
25785 
25786     # Disable special log output when a debug build is used as Boot JDK...
25787 
25788   $ECHO "Check if jvm arg is ok: -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" >&5
25789   $ECHO "Command: $JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version" >&5
25790   OUTPUT=`$JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version 2>&1`
25791   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
25792   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
25793   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
25794     boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput"
25795     JVM_ARG_OK=true
25796   else
25797     $ECHO "Arg failed:" >&5
25798     $ECHO "$OUTPUT" >&5
25799     JVM_ARG_OK=false
25800   fi
25801 
25802   fi
25803 
25804   BOOT_JDK_JVMARGS=$boot_jdk_jvmargs
25805 
25806 
25807 
25808 ###############################################################################
25809 #
25810 # Configure the sources to use. We can add or override individual directories.
25811 #
25812 ###############################################################################
25813 
25814 
25815   # Where are the sources. Any of these can be overridden
25816   # using --with-override-corba and the likes.
25817   LANGTOOLS_TOPDIR="$SRC_ROOT/langtools"
25818   CORBA_TOPDIR="$SRC_ROOT/corba"
25819   JAXP_TOPDIR="$SRC_ROOT/jaxp"
25820   JAXWS_TOPDIR="$SRC_ROOT/jaxws"
25821   HOTSPOT_TOPDIR="$SRC_ROOT/hotspot"
25822   NASHORN_TOPDIR="$SRC_ROOT/nashorn"
25823   JDK_TOPDIR="$SRC_ROOT/jdk"
25824 
25825 
25826 
25827 
25828 
25829 
25830 
25831 
25832 
25833 
25834   ###############################################################################
25835   #
25836   # Pickup additional source for a component from outside of the source root
25837   # or override source for a component.
25838   #
25839 
25840 # Check whether --with-add-source-root was given.
25841 if test "${with_add_source_root+set}" = set; then :
25842   withval=$with_add_source_root;
25843 fi
25844 
25845 
25846 
25847 # Check whether --with-override-source-root was given.
25848 if test "${with_override_source_root+set}" = set; then :
25849   withval=$with_override_source_root;
25850 fi
25851 
25852 
25853 
25854 # Check whether --with-adds-and-overrides was given.
25855 if test "${with_adds_and_overrides+set}" = set; then :
25856   withval=$with_adds_and_overrides;
25857 fi
25858 
25859 
25860   if test "x$with_adds_and_overrides" != x; then
25861     with_add_source_root="$with_adds_and_overrides/adds"
25862     with_override_source_root="$with_adds_and_overrides/overrides"
25863   fi
25864 
25865   if test "x$with_add_source_root" != x; then
25866     if ! test -d $with_add_source_root; then
25867       as_fn_error $? "Trying to use a non-existant add-source-root $with_add_source_root" "$LINENO" 5
25868     fi
25869     CURDIR="$PWD"
25870     cd "$with_add_source_root"
25871     ADD_SRC_ROOT="`pwd`"
25872     cd "$CURDIR"
25873     # Verify that the addon source root does not have any root makefiles.
25874     # If it does, then it is usually an error, prevent this.
25875     if test -f $with_add_source_root/langtools/make/Makefile; then
25876       as_fn_error $? "Your add source root seems to contain a full langtools repo! An add source root should only contain additional sources." "$LINENO" 5
25877     fi
25878     if test -f $with_add_source_root/corba/make/Makefile; then
25879       as_fn_error $? "Your add source root seems to contain a full corba repo! An add source root should only contain additional sources." "$LINENO" 5
25880     fi
25881     if test -f $with_add_source_root/jaxp/make/Makefile; then
25882       as_fn_error $? "Your add source root seems to contain a full jaxp repo! An add source root should only contain additional sources." "$LINENO" 5
25883     fi
25884     if test -f $with_add_source_root/jaxws/make/Makefile; then
25885       as_fn_error $? "Your add source root seems to contain a full jaxws repo! An add source root should only contain additional sources." "$LINENO" 5
25886     fi
25887     if test -f $with_add_source_root/hotspot/make/Makefile; then
25888       as_fn_error $? "Your add source root seems to contain a full hotspot repo! An add source root should only contain additional sources." "$LINENO" 5
25889     fi
25890     if test -f $with_add_source_root/nashorn/make/Makefile; then
25891       as_fn_error $? "Your add source root seems to contain a full nashorn repo! An add source root should only contain additional sources." "$LINENO" 5
25892     fi
25893     if test -f $with_add_source_root/jdk/make/Makefile; then
25894       as_fn_error $? "Your add source root seems to contain a full JDK repo! An add source root should only contain additional sources." "$LINENO" 5
25895     fi
25896   fi
25897 
25898 
25899   if test "x$with_override_source_root" != x; then
25900     if ! test -d $with_override_source_root; then
25901       as_fn_error $? "Trying to use a non-existant override-source-root $with_override_source_root" "$LINENO" 5
25902     fi
25903     CURDIR="$PWD"
25904     cd "$with_override_source_root"
25905     OVERRIDE_SRC_ROOT="`pwd`"
25906     cd "$CURDIR"
25907     if test -f $with_override_source_root/langtools/make/Makefile; then
25908       as_fn_error $? "Your override source root seems to contain a full langtools repo! An override source root should only contain sources that override." "$LINENO" 5
25909     fi
25910     if test -f $with_override_source_root/corba/make/Makefile; then
25911       as_fn_error $? "Your override source root seems to contain a full corba repo! An override source root should only contain sources that override." "$LINENO" 5
25912     fi
25913     if test -f $with_override_source_root/jaxp/make/Makefile; then
25914       as_fn_error $? "Your override source root seems to contain a full jaxp repo! An override source root should only contain sources that override." "$LINENO" 5
25915     fi
25916     if test -f $with_override_source_root/jaxws/make/Makefile; then
25917       as_fn_error $? "Your override source root seems to contain a full jaxws repo! An override source root should only contain sources that override." "$LINENO" 5
25918     fi
25919     if test -f $with_override_source_root/hotspot/make/Makefile; then
25920       as_fn_error $? "Your override source root seems to contain a full hotspot repo! An override source root should only contain sources that override." "$LINENO" 5
25921     fi
25922     if test -f $with_override_source_root/nashorn/make/Makefile; then
25923       as_fn_error $? "Your override source root seems to contain a full nashorn repo! An override source root should only contain sources that override." "$LINENO" 5
25924     fi
25925     if test -f $with_override_source_root/jdk/make/Makefile; then
25926       as_fn_error $? "Your override source root seems to contain a full JDK repo! An override source root should only contain sources that override." "$LINENO" 5
25927     fi
25928   fi
25929 
25930 
25931   ###############################################################################
25932   #
25933   # Override a repo completely, this is used for example when you have 3 small
25934   # development sandboxes of the langtools sources and want to avoid having 3 full
25935   # OpenJDK sources checked out on disk.
25936   #
25937   # Assuming that the 3 langtools sandboxes are located here:
25938   # /home/fredrik/sandbox1/langtools
25939   # /home/fredrik/sandbox2/langtools
25940   # /home/fredrik/sandbox3/langtools
25941   #
25942   # From the source root you create build subdirs manually:
25943   #     mkdir -p build1 build2 build3
25944   # in each build directory run:
25945   #     (cd build1 && ../configure --with-override-langtools=/home/fredrik/sandbox1 && make)
25946   #     (cd build2 && ../configure --with-override-langtools=/home/fredrik/sandbox2 && make)
25947   #     (cd build3 && ../configure --with-override-langtools=/home/fredrik/sandbox3 && make)
25948   #
25949 
25950 
25951 # Check whether --with-override-langtools was given.
25952 if test "${with_override_langtools+set}" = set; then :
25953   withval=$with_override_langtools;
25954 fi
25955 
25956 
25957 
25958 # Check whether --with-override-corba was given.
25959 if test "${with_override_corba+set}" = set; then :
25960   withval=$with_override_corba;
25961 fi
25962 
25963 
25964 
25965 # Check whether --with-override-jaxp was given.
25966 if test "${with_override_jaxp+set}" = set; then :
25967   withval=$with_override_jaxp;
25968 fi
25969 
25970 
25971 
25972 # Check whether --with-override-jaxws was given.
25973 if test "${with_override_jaxws+set}" = set; then :
25974   withval=$with_override_jaxws;
25975 fi
25976 
25977 
25978 
25979 # Check whether --with-override-hotspot was given.
25980 if test "${with_override_hotspot+set}" = set; then :
25981   withval=$with_override_hotspot;
25982 fi
25983 
25984 
25985 
25986 # Check whether --with-override-nashorn was given.
25987 if test "${with_override_nashorn+set}" = set; then :
25988   withval=$with_override_nashorn;
25989 fi
25990 
25991 
25992 
25993 # Check whether --with-override-jdk was given.
25994 if test "${with_override_jdk+set}" = set; then :
25995   withval=$with_override_jdk;
25996 fi
25997 
25998 
25999   if test "x$with_override_langtools" != x; then
26000     CURDIR="$PWD"
26001     cd "$with_override_langtools"
26002     LANGTOOLS_TOPDIR="`pwd`"
26003     cd "$CURDIR"
26004     if ! test -f $LANGTOOLS_TOPDIR/make/Makefile; then
26005       as_fn_error $? "You have to override langtools with a full langtools repo!" "$LINENO" 5
26006     fi
26007     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if langtools should be overridden" >&5
26008 $as_echo_n "checking if langtools should be overridden... " >&6; }
26009     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $LANGTOOLS_TOPDIR" >&5
26010 $as_echo "yes with $LANGTOOLS_TOPDIR" >&6; }
26011   fi
26012   if test "x$with_override_corba" != x; then
26013     CURDIR="$PWD"
26014     cd "$with_override_corba"
26015     CORBA_TOPDIR="`pwd`"
26016     cd "$CURDIR"
26017     if ! test -f $CORBA_TOPDIR/make/Makefile; then
26018       as_fn_error $? "You have to override corba with a full corba repo!" "$LINENO" 5
26019     fi
26020     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if corba should be overridden" >&5
26021 $as_echo_n "checking if corba should be overridden... " >&6; }
26022     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $CORBA_TOPDIR" >&5
26023 $as_echo "yes with $CORBA_TOPDIR" >&6; }
26024   fi
26025   if test "x$with_override_jaxp" != x; then
26026     CURDIR="$PWD"
26027     cd "$with_override_jaxp"
26028     JAXP_TOPDIR="`pwd`"
26029     cd "$CURDIR"
26030     if ! test -f $JAXP_TOPDIR/make/Makefile; then
26031       as_fn_error $? "You have to override jaxp with a full jaxp repo!" "$LINENO" 5
26032     fi
26033     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jaxp should be overridden" >&5
26034 $as_echo_n "checking if jaxp should be overridden... " >&6; }
26035     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JAXP_TOPDIR" >&5
26036 $as_echo "yes with $JAXP_TOPDIR" >&6; }
26037   fi
26038   if test "x$with_override_jaxws" != x; then
26039     CURDIR="$PWD"
26040     cd "$with_override_jaxws"
26041     JAXWS_TOPDIR="`pwd`"
26042     cd "$CURDIR"
26043     if ! test -f $JAXWS_TOPDIR/make/Makefile; then
26044       as_fn_error $? "You have to override jaxws with a full jaxws repo!" "$LINENO" 5
26045     fi
26046     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jaxws should be overridden" >&5
26047 $as_echo_n "checking if jaxws should be overridden... " >&6; }
26048     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JAXWS_TOPDIR" >&5
26049 $as_echo "yes with $JAXWS_TOPDIR" >&6; }
26050   fi
26051   if test "x$with_override_hotspot" != x; then
26052     CURDIR="$PWD"
26053     cd "$with_override_hotspot"
26054     HOTSPOT_TOPDIR="`pwd`"
26055     cd "$CURDIR"
26056     if ! test -f $HOTSPOT_TOPDIR/make/Makefile; then
26057       as_fn_error $? "You have to override hotspot with a full hotspot repo!" "$LINENO" 5
26058     fi
26059     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be overridden" >&5
26060 $as_echo_n "checking if hotspot should be overridden... " >&6; }
26061     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $HOTSPOT_TOPDIR" >&5
26062 $as_echo "yes with $HOTSPOT_TOPDIR" >&6; }
26063   fi
26064   if test "x$with_override_nashorn" != x; then
26065     CURDIR="$PWD"
26066     cd "$with_override_nashorn"
26067     NASHORN_TOPDIR="`pwd`"
26068     cd "$CURDIR"
26069     if ! test -f $NASHORN_TOPDIR/make/Makefile; then
26070       as_fn_error $? "You have to override nashorn with a full nashorn repo!" "$LINENO" 5
26071     fi
26072     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if nashorn should be overridden" >&5
26073 $as_echo_n "checking if nashorn should be overridden... " >&6; }
26074     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $NASHORN_TOPDIR" >&5
26075 $as_echo "yes with $NASHORN_TOPDIR" >&6; }
26076   fi
26077   if test "x$with_override_jdk" != x; then
26078     CURDIR="$PWD"
26079     cd "$with_override_jdk"
26080     JDK_TOPDIR="`pwd`"
26081     cd "$CURDIR"
26082     if ! test -f $JDK_TOPDIR/make/Makefile; then
26083       as_fn_error $? "You have to override JDK with a full JDK repo!" "$LINENO" 5
26084     fi
26085     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if JDK should be overridden" >&5
26086 $as_echo_n "checking if JDK should be overridden... " >&6; }
26087     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JDK_TOPDIR" >&5
26088 $as_echo "yes with $JDK_TOPDIR" >&6; }
26089   fi
26090 
26091 
26092   BUILD_OUTPUT="$OUTPUT_ROOT"
26093 
26094 
26095   HOTSPOT_DIST="$OUTPUT_ROOT/hotspot/dist"
26096   BUILD_HOTSPOT=true
26097 
26098 
26099 
26100 # Check whether --with-import-hotspot was given.
26101 if test "${with_import_hotspot+set}" = set; then :
26102   withval=$with_import_hotspot;
26103 fi
26104 
26105   if test "x$with_import_hotspot" != x; then
26106     CURDIR="$PWD"
26107     cd "$with_import_hotspot"
26108     HOTSPOT_DIST="`pwd`"
26109     cd "$CURDIR"
26110     if ! (test -d $HOTSPOT_DIST/lib && test -d $HOTSPOT_DIST/jre/lib); then
26111       as_fn_error $? "You have to import hotspot from a full jdk image or hotspot build dist dir!" "$LINENO" 5
26112     fi
26113     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be imported" >&5
26114 $as_echo_n "checking if hotspot should be imported... " >&6; }
26115     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes from $HOTSPOT_DIST" >&5
26116 $as_echo "yes from $HOTSPOT_DIST" >&6; }
26117     BUILD_HOTSPOT=false
26118   fi
26119 
26120   JDK_OUTPUTDIR="$OUTPUT_ROOT/jdk"
26121 
26122 
26123 ###############################################################################
26124 #
26125 # Setup the toolchain (compilers etc), i.e. the tools that need to be
26126 # cross-compilation aware.
26127 #
26128 ###############################################################################
26129 
26130 
26131   ###############################################################################
26132   #
26133   # Configure the development tool paths and potential sysroot.
26134   #
26135   ac_ext=cpp
26136 ac_cpp='$CXXCPP $CPPFLAGS'
26137 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
26138 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
26139 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
26140 
26141 
26142   # The option used to specify the target .o,.a or .so file.
26143   # When compiling, how to specify the to be created object file.
26144   CC_OUT_OPTION='-o$(SPACE)'
26145   # When linking, how to specify the to be created executable.
26146   EXE_OUT_OPTION='-o$(SPACE)'
26147   # When linking, how to specify the to be created dynamically linkable library.
26148   LD_OUT_OPTION='-o$(SPACE)'
26149   # When archiving, how to specify the to be create static archive for object files.
26150   AR_OUT_OPTION='rcs$(SPACE)'
26151 
26152 
26153 
26154 
26155 
26156 # Locate the actual tools
26157 
26158 
26159 # Check whether --with-jtreg was given.
26160 if test "${with_jtreg+set}" = set; then :
26161   withval=$with_jtreg;
26162 else
26163   with_jtreg=no
26164 fi
26165 
26166 
26167   if test "x$with_jtreg" = xno; then
26168     # jtreg disabled
26169     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5
26170 $as_echo_n "checking for jtreg... " >&6; }
26171     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26172 $as_echo "no" >&6; }
26173   else
26174     if test "x$with_jtreg" != xyes; then
26175       # with path specified.
26176       JT_HOME="$with_jtreg"
26177     fi
26178 
26179     if test "x$JT_HOME" != x; then
26180       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5
26181 $as_echo_n "checking for jtreg... " >&6; }
26182 
26183       # use JT_HOME enviroment var.
26184 
26185   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26186 
26187   # Input might be given as Windows format, start by converting to
26188   # unix format.
26189   path="$JT_HOME"
26190   new_path=`$CYGPATH -u "$path"`
26191 
26192   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
26193   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
26194   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
26195   # "foo.exe" is OK but "foo" is an error.
26196   #
26197   # This test is therefore slightly more accurate than "test -f" to check for file precense.
26198   # It is also a way to make sure we got the proper file name for the real test later on.
26199   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
26200   if test "x$test_shortpath" = x; then
26201     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5
26202 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;}
26203     as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5
26204   fi
26205 
26206   # Call helper function which possibly converts this using DOS-style short mode.
26207   # If so, the updated path is stored in $new_path.
26208 
26209   input_path="$new_path"
26210   # Check if we need to convert this using DOS-style short mode. If the path
26211   # contains just simple characters, use it. Otherwise (spaces, weird characters),
26212   # take no chances and rewrite it.
26213   # Note: m4 eats our [], so we need to use [ and ] instead.
26214   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
26215   if test "x$has_forbidden_chars" != x; then
26216     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
26217     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
26218     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
26219     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
26220       # Going to short mode and back again did indeed matter. Since short mode is
26221       # case insensitive, let's make it lowercase to improve readability.
26222       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
26223       # Now convert it back to Unix-stile (cygpath)
26224       input_path=`$CYGPATH -u "$shortmode_path"`
26225       new_path="$input_path"
26226     fi
26227   fi
26228 
26229   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
26230   if test "x$test_cygdrive_prefix" = x; then
26231     # As a simple fix, exclude /usr/bin since it's not a real path.
26232     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
26233       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
26234       # a path prefixed by /cygdrive for fixpath to work.
26235       new_path="$CYGWIN_ROOT_PATH$input_path"
26236     fi
26237   fi
26238 
26239 
26240   if test "x$path" != "x$new_path"; then
26241     JT_HOME="$new_path"
26242     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5
26243 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;}
26244   fi
26245 
26246   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26247 
26248   path="$JT_HOME"
26249   has_colon=`$ECHO $path | $GREP ^.:`
26250   new_path="$path"
26251   if test "x$has_colon" = x; then
26252     # Not in mixed or Windows style, start by that.
26253     new_path=`cmd //c echo $path`
26254   fi
26255 
26256 
26257   input_path="$new_path"
26258   # Check if we need to convert this using DOS-style short mode. If the path
26259   # contains just simple characters, use it. Otherwise (spaces, weird characters),
26260   # take no chances and rewrite it.
26261   # Note: m4 eats our [], so we need to use [ and ] instead.
26262   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
26263   if test "x$has_forbidden_chars" != x; then
26264     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
26265     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
26266   fi
26267 
26268 
26269   windows_path="$new_path"
26270   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26271     unix_path=`$CYGPATH -u "$windows_path"`
26272     new_path="$unix_path"
26273   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26274     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26275     new_path="$unix_path"
26276   fi
26277 
26278   if test "x$path" != "x$new_path"; then
26279     JT_HOME="$new_path"
26280     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5
26281 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;}
26282   fi
26283 
26284   # Save the first 10 bytes of this path to the storage, so fixpath can work.
26285   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
26286 
26287   else
26288     # We're on a posix platform. Hooray! :)
26289     path="$JT_HOME"
26290     has_space=`$ECHO "$path" | $GREP " "`
26291     if test "x$has_space" != x; then
26292       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5
26293 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;}
26294       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
26295     fi
26296 
26297     # Use eval to expand a potential ~
26298     eval path="$path"
26299     if test ! -f "$path" && test ! -d "$path"; then
26300       as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5
26301     fi
26302 
26303     JT_HOME="`cd "$path"; $THEPWDCMD -L`"
26304   fi
26305 
26306 
26307       # jtreg win32 script works for everybody
26308       JTREGEXE="$JT_HOME/win32/bin/jtreg"
26309 
26310       if test ! -f "$JTREGEXE"; then
26311         as_fn_error $? "JTReg executable does not exist: $JTREGEXE" "$LINENO" 5
26312       fi
26313 
26314       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
26315 $as_echo "$JTREGEXE" >&6; }
26316     else
26317       # try to find jtreg on path
26318 
26319 
26320 
26321   # Publish this variable in the help.
26322 
26323 
26324   if test "x$JTREGEXE" = x; then
26325     # The variable is not set by user, try to locate tool using the code snippet
26326     for ac_prog in jtreg
26327 do
26328   # Extract the first word of "$ac_prog", so it can be a program name with args.
26329 set dummy $ac_prog; ac_word=$2
26330 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26331 $as_echo_n "checking for $ac_word... " >&6; }
26332 if ${ac_cv_path_JTREGEXE+:} false; then :
26333   $as_echo_n "(cached) " >&6
26334 else
26335   case $JTREGEXE in
26336   [\\/]* | ?:[\\/]*)
26337   ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
26338   ;;
26339   *)
26340   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26341 for as_dir in $PATH
26342 do
26343   IFS=$as_save_IFS
26344   test -z "$as_dir" && as_dir=.
26345     for ac_exec_ext in '' $ac_executable_extensions; do
26346   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26347     ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
26348     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26349     break 2
26350   fi
26351 done
26352   done
26353 IFS=$as_save_IFS
26354 
26355   ;;
26356 esac
26357 fi
26358 JTREGEXE=$ac_cv_path_JTREGEXE
26359 if test -n "$JTREGEXE"; then
26360   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
26361 $as_echo "$JTREGEXE" >&6; }
26362 else
26363   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26364 $as_echo "no" >&6; }
26365 fi
26366 
26367 
26368   test -n "$JTREGEXE" && break
26369 done
26370 
26371   else
26372     # The variable is set, but is it from the command line or the environment?
26373 
26374     # Try to remove the string !JTREGEXE! from our list.
26375     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JTREGEXE!/}
26376     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
26377       # If it failed, the variable was not from the command line. Ignore it,
26378       # but warn the user (except for BASH, which is always set by the calling BASH).
26379       if test "xJTREGEXE" != xBASH; then
26380         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&5
26381 $as_echo "$as_me: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&2;}
26382       fi
26383       # Try to locate tool using the code snippet
26384       for ac_prog in jtreg
26385 do
26386   # Extract the first word of "$ac_prog", so it can be a program name with args.
26387 set dummy $ac_prog; ac_word=$2
26388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26389 $as_echo_n "checking for $ac_word... " >&6; }
26390 if ${ac_cv_path_JTREGEXE+:} false; then :
26391   $as_echo_n "(cached) " >&6
26392 else
26393   case $JTREGEXE in
26394   [\\/]* | ?:[\\/]*)
26395   ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
26396   ;;
26397   *)
26398   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26399 for as_dir in $PATH
26400 do
26401   IFS=$as_save_IFS
26402   test -z "$as_dir" && as_dir=.
26403     for ac_exec_ext in '' $ac_executable_extensions; do
26404   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26405     ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
26406     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26407     break 2
26408   fi
26409 done
26410   done
26411 IFS=$as_save_IFS
26412 
26413   ;;
26414 esac
26415 fi
26416 JTREGEXE=$ac_cv_path_JTREGEXE
26417 if test -n "$JTREGEXE"; then
26418   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
26419 $as_echo "$JTREGEXE" >&6; }
26420 else
26421   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26422 $as_echo "no" >&6; }
26423 fi
26424 
26425 
26426   test -n "$JTREGEXE" && break
26427 done
26428 
26429     else
26430       # If it succeeded, then it was overridden by the user. We will use it
26431       # for the tool.
26432 
26433       # First remove it from the list of overridden variables, so we can test
26434       # for unknown variables in the end.
26435       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
26436 
26437       # Check if the provided tool contains a complete path.
26438       tool_specified="$JTREGEXE"
26439       tool_basename="${tool_specified##*/}"
26440       if test "x$tool_basename" = "x$tool_specified"; then
26441         # A command without a complete path is provided, search $PATH.
26442         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JTREGEXE=$tool_basename" >&5
26443 $as_echo "$as_me: Will search for user supplied tool JTREGEXE=$tool_basename" >&6;}
26444         # Extract the first word of "$tool_basename", so it can be a program name with args.
26445 set dummy $tool_basename; ac_word=$2
26446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26447 $as_echo_n "checking for $ac_word... " >&6; }
26448 if ${ac_cv_path_JTREGEXE+:} false; then :
26449   $as_echo_n "(cached) " >&6
26450 else
26451   case $JTREGEXE in
26452   [\\/]* | ?:[\\/]*)
26453   ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
26454   ;;
26455   *)
26456   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26457 for as_dir in $PATH
26458 do
26459   IFS=$as_save_IFS
26460   test -z "$as_dir" && as_dir=.
26461     for ac_exec_ext in '' $ac_executable_extensions; do
26462   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26463     ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
26464     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26465     break 2
26466   fi
26467 done
26468   done
26469 IFS=$as_save_IFS
26470 
26471   ;;
26472 esac
26473 fi
26474 JTREGEXE=$ac_cv_path_JTREGEXE
26475 if test -n "$JTREGEXE"; then
26476   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
26477 $as_echo "$JTREGEXE" >&6; }
26478 else
26479   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26480 $as_echo "no" >&6; }
26481 fi
26482 
26483 
26484         if test "x$JTREGEXE" = x; then
26485           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
26486         fi
26487       else
26488         # Otherwise we believe it is a complete path. Use it as it is.
26489         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JTREGEXE=$tool_specified" >&5
26490 $as_echo "$as_me: Will use user supplied tool JTREGEXE=$tool_specified" >&6;}
26491         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5
26492 $as_echo_n "checking for JTREGEXE... " >&6; }
26493         if test ! -x "$tool_specified"; then
26494           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
26495 $as_echo "not found" >&6; }
26496           as_fn_error $? "User supplied tool JTREGEXE=$tool_specified does not exist or is not executable" "$LINENO" 5
26497         fi
26498         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
26499 $as_echo "$tool_specified" >&6; }
26500       fi
26501     fi
26502   fi
26503 
26504 
26505 
26506   if test "x$JTREGEXE" = x; then
26507     as_fn_error $? "Could not find required tool for JTREGEXE" "$LINENO" 5
26508   fi
26509 
26510 
26511       JT_HOME="`$DIRNAME $JTREGEXE`"
26512     fi
26513   fi
26514 
26515 
26516 
26517 
26518 
26519   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
26520 
26521   # Store path to cygwin link.exe to help excluding it when searching for
26522   # VS linker. This must be done before changing the PATH when looking for VS.
26523   # Extract the first word of "link", so it can be a program name with args.
26524 set dummy link; ac_word=$2
26525 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26526 $as_echo_n "checking for $ac_word... " >&6; }
26527 if ${ac_cv_path_CYGWIN_LINK+:} false; then :
26528   $as_echo_n "(cached) " >&6
26529 else
26530   case $CYGWIN_LINK in
26531   [\\/]* | ?:[\\/]*)
26532   ac_cv_path_CYGWIN_LINK="$CYGWIN_LINK" # Let the user override the test with a path.
26533   ;;
26534   *)
26535   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26536 for as_dir in $PATH
26537 do
26538   IFS=$as_save_IFS
26539   test -z "$as_dir" && as_dir=.
26540     for ac_exec_ext in '' $ac_executable_extensions; do
26541   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26542     ac_cv_path_CYGWIN_LINK="$as_dir/$ac_word$ac_exec_ext"
26543     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26544     break 2
26545   fi
26546 done
26547   done
26548 IFS=$as_save_IFS
26549 
26550   ;;
26551 esac
26552 fi
26553 CYGWIN_LINK=$ac_cv_path_CYGWIN_LINK
26554 if test -n "$CYGWIN_LINK"; then
26555   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_LINK" >&5
26556 $as_echo "$CYGWIN_LINK" >&6; }
26557 else
26558   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26559 $as_echo "no" >&6; }
26560 fi
26561 
26562 
26563   if test "x$CYGWIN_LINK" != x; then
26564     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the first found link.exe is actually the Cygwin link tool" >&5
26565 $as_echo_n "checking if the first found link.exe is actually the Cygwin link tool... " >&6; }
26566     "$CYGWIN_LINK" --version > /dev/null
26567     if test $? -eq 0 ; then
26568       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26569 $as_echo "yes" >&6; }
26570     else
26571       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26572 $as_echo "no" >&6; }
26573       # This might be the VS linker. Don't exclude it later on.
26574       CYGWIN_LINK=""
26575     fi
26576   fi
26577 
26578   # First-hand choice is to locate and run the vsvars bat file.
26579 
26580   if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26581     VCVARSFILE="vc/bin/vcvars32.bat"
26582   else
26583     VCVARSFILE="vc/bin/amd64/vcvars64.bat"
26584   fi
26585 
26586   VS_ENV_CMD=""
26587   VS_ENV_ARGS=""
26588   if test "x$with_toolsdir" != x; then
26589 
26590   if test "x$VS_ENV_CMD" = x; then
26591     VS100BASE="$with_toolsdir/../.."
26592     METHOD="--with-tools-dir"
26593 
26594   windows_path="$VS100BASE"
26595   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26596     unix_path=`$CYGPATH -u "$windows_path"`
26597     VS100BASE="$unix_path"
26598   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26599     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26600     VS100BASE="$unix_path"
26601   fi
26602 
26603     if test -d "$VS100BASE"; then
26604       if test -f "$VS100BASE/$VCVARSFILE"; then
26605         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26606 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26607         VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26608       else
26609         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26610 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26611         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26612 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26613       fi
26614     fi
26615   fi
26616 
26617   fi
26618 
26619   if test "x$with_toolsdir" != x && test "x$VS_ENV_CMD" = x; then
26620     # Having specified an argument which is incorrect will produce an instant failure;
26621     # we should not go on looking
26622     { $as_echo "$as_me:${as_lineno-$LINENO}: The path given by --with-tools-dir does not contain a valid Visual Studio installation" >&5
26623 $as_echo "$as_me: The path given by --with-tools-dir does not contain a valid Visual Studio installation" >&6;}
26624     { $as_echo "$as_me:${as_lineno-$LINENO}: Please point to the VC/bin directory within the Visual Studio installation" >&5
26625 $as_echo "$as_me: Please point to the VC/bin directory within the Visual Studio installation" >&6;}
26626     as_fn_error $? "Cannot locate a valid Visual Studio installation" "$LINENO" 5
26627   fi
26628 
26629   if test "x$VS100COMNTOOLS" != x; then
26630 
26631   if test "x$VS_ENV_CMD" = x; then
26632     VS100BASE="$VS100COMNTOOLS/../.."
26633     METHOD="VS100COMNTOOLS variable"
26634 
26635   windows_path="$VS100BASE"
26636   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26637     unix_path=`$CYGPATH -u "$windows_path"`
26638     VS100BASE="$unix_path"
26639   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26640     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26641     VS100BASE="$unix_path"
26642   fi
26643 
26644     if test -d "$VS100BASE"; then
26645       if test -f "$VS100BASE/$VCVARSFILE"; then
26646         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26647 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26648         VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26649       else
26650         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26651 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26652         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26653 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26654       fi
26655     fi
26656   fi
26657 
26658   fi
26659   if test "x$PROGRAMFILES" != x; then
26660 
26661   if test "x$VS_ENV_CMD" = x; then
26662     VS100BASE="$PROGRAMFILES/Microsoft Visual Studio 10.0"
26663     METHOD="well-known name"
26664 
26665   windows_path="$VS100BASE"
26666   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26667     unix_path=`$CYGPATH -u "$windows_path"`
26668     VS100BASE="$unix_path"
26669   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26670     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26671     VS100BASE="$unix_path"
26672   fi
26673 
26674     if test -d "$VS100BASE"; then
26675       if test -f "$VS100BASE/$VCVARSFILE"; then
26676         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26677 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26678         VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26679       else
26680         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26681 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26682         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26683 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26684       fi
26685     fi
26686   fi
26687 
26688   fi
26689 
26690   if test "x$VS_ENV_CMD" = x; then
26691     VS100BASE="C:/Program Files/Microsoft Visual Studio 10.0"
26692     METHOD="well-known name"
26693 
26694   windows_path="$VS100BASE"
26695   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26696     unix_path=`$CYGPATH -u "$windows_path"`
26697     VS100BASE="$unix_path"
26698   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26699     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26700     VS100BASE="$unix_path"
26701   fi
26702 
26703     if test -d "$VS100BASE"; then
26704       if test -f "$VS100BASE/$VCVARSFILE"; then
26705         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26706 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26707         VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26708       else
26709         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26710 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26711         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26712 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26713       fi
26714     fi
26715   fi
26716 
26717 
26718   if test "x$VS_ENV_CMD" = x; then
26719     VS100BASE="C:/Program Files (x86)/Microsoft Visual Studio 10.0"
26720     METHOD="well-known name"
26721 
26722   windows_path="$VS100BASE"
26723   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26724     unix_path=`$CYGPATH -u "$windows_path"`
26725     VS100BASE="$unix_path"
26726   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26727     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26728     VS100BASE="$unix_path"
26729   fi
26730 
26731     if test -d "$VS100BASE"; then
26732       if test -f "$VS100BASE/$VCVARSFILE"; then
26733         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26734 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26735         VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26736       else
26737         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26738 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26739         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26740 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26741       fi
26742     fi
26743   fi
26744 
26745 
26746   if test "x$ProgramW6432" != x; then
26747 
26748   if test "x$VS_ENV_CMD" = x; then
26749     WIN_SDK_BASE="$ProgramW6432/Microsoft SDKs/Windows/v7.1/Bin"
26750     METHOD="well-known name"
26751 
26752   windows_path="$WIN_SDK_BASE"
26753   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26754     unix_path=`$CYGPATH -u "$windows_path"`
26755     WIN_SDK_BASE="$unix_path"
26756   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26757     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26758     WIN_SDK_BASE="$unix_path"
26759   fi
26760 
26761     if test -d "$WIN_SDK_BASE"; then
26762       # There have been cases of partial or broken SDK installations. A missing
26763       # lib dir is not going to work.
26764       if test ! -d "$WIN_SDK_BASE/../lib"; then
26765         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26766 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26767         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26768 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26769       elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26770         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26771 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26772         VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26773         if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26774           VS_ENV_ARGS="/x86"
26775         else
26776           VS_ENV_ARGS="/x64"
26777         fi
26778       else
26779         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26780 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26781         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26782 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26783       fi
26784     fi
26785   fi
26786 
26787   fi
26788   if test "x$PROGRAMW6432" != x; then
26789 
26790   if test "x$VS_ENV_CMD" = x; then
26791     WIN_SDK_BASE="$PROGRAMW6432/Microsoft SDKs/Windows/v7.1/Bin"
26792     METHOD="well-known name"
26793 
26794   windows_path="$WIN_SDK_BASE"
26795   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26796     unix_path=`$CYGPATH -u "$windows_path"`
26797     WIN_SDK_BASE="$unix_path"
26798   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26799     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26800     WIN_SDK_BASE="$unix_path"
26801   fi
26802 
26803     if test -d "$WIN_SDK_BASE"; then
26804       # There have been cases of partial or broken SDK installations. A missing
26805       # lib dir is not going to work.
26806       if test ! -d "$WIN_SDK_BASE/../lib"; then
26807         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26808 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26809         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26810 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26811       elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26812         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26813 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26814         VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26815         if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26816           VS_ENV_ARGS="/x86"
26817         else
26818           VS_ENV_ARGS="/x64"
26819         fi
26820       else
26821         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26822 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26823         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26824 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26825       fi
26826     fi
26827   fi
26828 
26829   fi
26830   if test "x$PROGRAMFILES" != x; then
26831 
26832   if test "x$VS_ENV_CMD" = x; then
26833     WIN_SDK_BASE="$PROGRAMFILES/Microsoft SDKs/Windows/v7.1/Bin"
26834     METHOD="well-known name"
26835 
26836   windows_path="$WIN_SDK_BASE"
26837   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26838     unix_path=`$CYGPATH -u "$windows_path"`
26839     WIN_SDK_BASE="$unix_path"
26840   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26841     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26842     WIN_SDK_BASE="$unix_path"
26843   fi
26844 
26845     if test -d "$WIN_SDK_BASE"; then
26846       # There have been cases of partial or broken SDK installations. A missing
26847       # lib dir is not going to work.
26848       if test ! -d "$WIN_SDK_BASE/../lib"; then
26849         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26850 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26851         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26852 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26853       elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26854         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26855 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26856         VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26857         if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26858           VS_ENV_ARGS="/x86"
26859         else
26860           VS_ENV_ARGS="/x64"
26861         fi
26862       else
26863         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26864 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26865         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26866 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26867       fi
26868     fi
26869   fi
26870 
26871   fi
26872 
26873   if test "x$VS_ENV_CMD" = x; then
26874     WIN_SDK_BASE="C:/Program Files/Microsoft SDKs/Windows/v7.1/Bin"
26875     METHOD="well-known name"
26876 
26877   windows_path="$WIN_SDK_BASE"
26878   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26879     unix_path=`$CYGPATH -u "$windows_path"`
26880     WIN_SDK_BASE="$unix_path"
26881   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26882     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26883     WIN_SDK_BASE="$unix_path"
26884   fi
26885 
26886     if test -d "$WIN_SDK_BASE"; then
26887       # There have been cases of partial or broken SDK installations. A missing
26888       # lib dir is not going to work.
26889       if test ! -d "$WIN_SDK_BASE/../lib"; then
26890         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26891 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26892         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26893 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26894       elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26895         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26896 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26897         VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26898         if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26899           VS_ENV_ARGS="/x86"
26900         else
26901           VS_ENV_ARGS="/x64"
26902         fi
26903       else
26904         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26905 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26906         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26907 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26908       fi
26909     fi
26910   fi
26911 
26912 
26913   if test "x$VS_ENV_CMD" = x; then
26914     WIN_SDK_BASE="C:/Program Files (x86)/Microsoft SDKs/Windows/v7.1/Bin"
26915     METHOD="well-known name"
26916 
26917   windows_path="$WIN_SDK_BASE"
26918   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26919     unix_path=`$CYGPATH -u "$windows_path"`
26920     WIN_SDK_BASE="$unix_path"
26921   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26922     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26923     WIN_SDK_BASE="$unix_path"
26924   fi
26925 
26926     if test -d "$WIN_SDK_BASE"; then
26927       # There have been cases of partial or broken SDK installations. A missing
26928       # lib dir is not going to work.
26929       if test ! -d "$WIN_SDK_BASE/../lib"; then
26930         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26931 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26932         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
26933 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
26934       elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
26935         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26936 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26937         VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
26938         if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26939           VS_ENV_ARGS="/x86"
26940         else
26941           VS_ENV_ARGS="/x64"
26942         fi
26943       else
26944         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
26945 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
26946         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
26947 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
26948       fi
26949     fi
26950   fi
26951 
26952 
26953   if test "x$VS_ENV_CMD" != x; then
26954     # We have found a Visual Studio environment on disk, let's extract variables from the vsvars bat file.
26955 
26956   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26957 
26958   # First separate the path from the arguments. This will split at the first
26959   # space.
26960   complete="$VS_ENV_CMD"
26961   path="${complete%% *}"
26962   tmp="$complete EOL"
26963   arguments="${tmp#* }"
26964 
26965   # Input might be given as Windows format, start by converting to
26966   # unix format.
26967   new_path=`$CYGPATH -u "$path"`
26968 
26969   # Now try to locate executable using which
26970   new_path=`$WHICH "$new_path" 2> /dev/null`
26971   # bat and cmd files are not always considered executable in cygwin causing which
26972   # to not find them
26973   if test "x$new_path" = x \
26974       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
26975       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
26976     new_path=`$CYGPATH -u "$path"`
26977   fi
26978   if test "x$new_path" = x; then
26979     # Oops. Which didn't find the executable.
26980     # The splitting of arguments from the executable at a space might have been incorrect,
26981     # since paths with space are more likely in Windows. Give it another try with the whole
26982     # argument.
26983     path="$complete"
26984     arguments="EOL"
26985     new_path=`$CYGPATH -u "$path"`
26986     new_path=`$WHICH "$new_path" 2> /dev/null`
26987     # bat and cmd files are not always considered executable in cygwin causing which
26988     # to not find them
26989     if test "x$new_path" = x \
26990         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
26991         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
26992       new_path=`$CYGPATH -u "$path"`
26993     fi
26994     if test "x$new_path" = x; then
26995       # It's still not found. Now this is an unrecoverable error.
26996       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
26997 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
26998       has_space=`$ECHO "$complete" | $GREP " "`
26999       if test "x$has_space" != x; then
27000         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27001 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27002       fi
27003       as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27004     fi
27005   fi
27006 
27007   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
27008   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
27009   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
27010   # "foo.exe" is OK but "foo" is an error.
27011   #
27012   # This test is therefore slightly more accurate than "test -f" to check for file presence.
27013   # It is also a way to make sure we got the proper file name for the real test later on.
27014   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
27015   if test "x$test_shortpath" = x; then
27016     # Short path failed, file does not exist as specified.
27017     # Try adding .exe or .cmd
27018     if test -f "${new_path}.exe"; then
27019       input_to_shortpath="${new_path}.exe"
27020     elif test -f "${new_path}.cmd"; then
27021       input_to_shortpath="${new_path}.cmd"
27022     else
27023       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&5
27024 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&6;}
27025       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
27026 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
27027       as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27028     fi
27029   else
27030     input_to_shortpath="$new_path"
27031   fi
27032 
27033   # Call helper function which possibly converts this using DOS-style short mode.
27034   # If so, the updated path is stored in $new_path.
27035   new_path="$input_to_shortpath"
27036 
27037   input_path="$input_to_shortpath"
27038   # Check if we need to convert this using DOS-style short mode. If the path
27039   # contains just simple characters, use it. Otherwise (spaces, weird characters),
27040   # take no chances and rewrite it.
27041   # Note: m4 eats our [], so we need to use [ and ] instead.
27042   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
27043   if test "x$has_forbidden_chars" != x; then
27044     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27045     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
27046     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
27047     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
27048       # Going to short mode and back again did indeed matter. Since short mode is
27049       # case insensitive, let's make it lowercase to improve readability.
27050       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27051       # Now convert it back to Unix-stile (cygpath)
27052       input_path=`$CYGPATH -u "$shortmode_path"`
27053       new_path="$input_path"
27054     fi
27055   fi
27056 
27057   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
27058   if test "x$test_cygdrive_prefix" = x; then
27059     # As a simple fix, exclude /usr/bin since it's not a real path.
27060     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
27061       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
27062       # a path prefixed by /cygdrive for fixpath to work.
27063       new_path="$CYGWIN_ROOT_PATH$input_path"
27064     fi
27065   fi
27066 
27067   # remove trailing .exe if any
27068   new_path="${new_path/%.exe/}"
27069 
27070   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27071 
27072   # First separate the path from the arguments. This will split at the first
27073   # space.
27074   complete="$VS_ENV_CMD"
27075   path="${complete%% *}"
27076   tmp="$complete EOL"
27077   arguments="${tmp#* }"
27078 
27079   # Input might be given as Windows format, start by converting to
27080   # unix format.
27081   new_path="$path"
27082 
27083   windows_path="$new_path"
27084   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27085     unix_path=`$CYGPATH -u "$windows_path"`
27086     new_path="$unix_path"
27087   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27088     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27089     new_path="$unix_path"
27090   fi
27091 
27092 
27093   # Now try to locate executable using which
27094   new_path=`$WHICH "$new_path" 2> /dev/null`
27095 
27096   if test "x$new_path" = x; then
27097     # Oops. Which didn't find the executable.
27098     # The splitting of arguments from the executable at a space might have been incorrect,
27099     # since paths with space are more likely in Windows. Give it another try with the whole
27100     # argument.
27101     path="$complete"
27102     arguments="EOL"
27103     new_path="$path"
27104 
27105   windows_path="$new_path"
27106   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27107     unix_path=`$CYGPATH -u "$windows_path"`
27108     new_path="$unix_path"
27109   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27110     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27111     new_path="$unix_path"
27112   fi
27113 
27114 
27115     new_path=`$WHICH "$new_path" 2> /dev/null`
27116 
27117     if test "x$new_path" = x; then
27118       # It's still not found. Now this is an unrecoverable error.
27119       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
27120 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
27121       has_space=`$ECHO "$complete" | $GREP " "`
27122       if test "x$has_space" != x; then
27123         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27124 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27125       fi
27126       as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27127     fi
27128   fi
27129 
27130   # Now new_path has a complete unix path to the binary
27131   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
27132     # Keep paths in /bin as-is, but remove trailing .exe if any
27133     new_path="${new_path/%.exe/}"
27134     # Do not save /bin paths to all_fixpath_prefixes!
27135   else
27136     # Not in mixed or Windows style, start by that.
27137     new_path=`cmd //c echo $new_path`
27138 
27139   input_path="$new_path"
27140   # Check if we need to convert this using DOS-style short mode. If the path
27141   # contains just simple characters, use it. Otherwise (spaces, weird characters),
27142   # take no chances and rewrite it.
27143   # Note: m4 eats our [], so we need to use [ and ] instead.
27144   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
27145   if test "x$has_forbidden_chars" != x; then
27146     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27147     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27148   fi
27149 
27150     # Output is in $new_path
27151 
27152   windows_path="$new_path"
27153   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27154     unix_path=`$CYGPATH -u "$windows_path"`
27155     new_path="$unix_path"
27156   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27157     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27158     new_path="$unix_path"
27159   fi
27160 
27161     # remove trailing .exe if any
27162     new_path="${new_path/%.exe/}"
27163 
27164     # Save the first 10 bytes of this path to the storage, so fixpath can work.
27165     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
27166   fi
27167 
27168   else
27169     # We're on a posix platform. Hooray! :)
27170     # First separate the path from the arguments. This will split at the first
27171     # space.
27172     complete="$VS_ENV_CMD"
27173     path="${complete%% *}"
27174     tmp="$complete EOL"
27175     arguments="${tmp#* }"
27176 
27177     # Cannot rely on the command "which" here since it doesn't always work.
27178     is_absolute_path=`$ECHO "$path" | $GREP ^/`
27179     if test -z "$is_absolute_path"; then
27180       # Path to executable is not absolute. Find it.
27181       IFS_save="$IFS"
27182       IFS=:
27183       for p in $PATH; do
27184         if test -f "$p/$path" && test -x "$p/$path"; then
27185           new_path="$p/$path"
27186           break
27187         fi
27188       done
27189       IFS="$IFS_save"
27190     else
27191       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving VS_ENV_CMD (as $path) failed, using $path directly." >&5
27192 $as_echo "$as_me: Resolving VS_ENV_CMD (as $path) failed, using $path directly." >&6;}
27193       new_path="$path"
27194     fi
27195 
27196     if test "x$new_path" = x; then
27197       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
27198 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
27199       has_space=`$ECHO "$complete" | $GREP " "`
27200       if test "x$has_space" != x; then
27201         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
27202 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
27203       fi
27204       as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27205     fi
27206   fi
27207 
27208   # Now join together the path and the arguments once again
27209   if test "x$arguments" != xEOL; then
27210     new_complete="$new_path ${arguments% *}"
27211   else
27212     new_complete="$new_path"
27213   fi
27214 
27215   if test "x$complete" != "x$new_complete"; then
27216     VS_ENV_CMD="$new_complete"
27217     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting VS_ENV_CMD to \"$new_complete\"" >&5
27218 $as_echo "$as_me: Rewriting VS_ENV_CMD to \"$new_complete\"" >&6;}
27219   fi
27220 
27221 
27222     # Lets extract the variables that are set by vcvarsall.bat/vsvars32.bat/vsvars64.bat
27223     { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to extract Visual Studio environment variables" >&5
27224 $as_echo "$as_me: Trying to extract Visual Studio environment variables" >&6;}
27225     cd $OUTPUT_ROOT
27226     # FIXME: The code betweeen ---- was inlined from a separate script and is not properly adapted
27227     # to autoconf standards.
27228 
27229     #----
27230 
27231     # Cannot use the VS10 setup script directly (since it only updates the DOS subshell environment)
27232     # but calculate the difference in Cygwin environment before/after running it and then
27233     # apply the diff.
27234 
27235     if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then
27236       _vs10varsall=`cygpath -a -m -s "$VS_ENV_CMD"`
27237       _dosvs10varsall=`cygpath -a -w -s $_vs10varsall`
27238       _dosbash=`cygpath -a -w -s \`which bash\`.*`
27239     else
27240       _dosvs10varsall=`cmd //c echo $VS_ENV_CMD`
27241       _dosbash=`cmd //c echo \`which bash\``
27242     fi
27243 
27244     # generate the set of exported vars before/after the vs10 setup
27245     $ECHO "@echo off"                                           >  localdevenvtmp.bat
27246     $ECHO "$_dosbash -c \"export -p\" > localdevenvtmp.export0" >> localdevenvtmp.bat
27247     $ECHO "call $_dosvs10varsall $VS_ENV_ARGS"                  >> localdevenvtmp.bat
27248     $ECHO "$_dosbash -c \"export -p\" > localdevenvtmp.export1" >> localdevenvtmp.bat
27249 
27250     # Now execute the newly created bat file.
27251     # The | cat is to stop SetEnv.Cmd to mess with system colors on msys
27252     cmd /c localdevenvtmp.bat | cat
27253 
27254     # apply the diff (less some non-vs10 vars named by "!")
27255     $SORT localdevenvtmp.export0 | $GREP -v "!" > localdevenvtmp.export0.sort
27256     $SORT localdevenvtmp.export1 | $GREP -v "!" > localdevenvtmp.export1.sort
27257     $COMM -1 -3 localdevenvtmp.export0.sort localdevenvtmp.export1.sort > localdevenv.sh
27258 
27259     # cleanup
27260     $RM localdevenvtmp*
27261     #----
27262     cd $CURDIR
27263     if test ! -s $OUTPUT_ROOT/localdevenv.sh; then
27264       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27265 $as_echo "no" >&6; }
27266       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not succesfully extract the envionment variables needed for the VS setup." >&5
27267 $as_echo "$as_me: Could not succesfully extract the envionment variables needed for the VS setup." >&6;}
27268       { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5
27269 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;}
27270       { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5
27271 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;}
27272       as_fn_error $? "Cannot continue" "$LINENO" 5
27273     fi
27274 
27275     # Now set all paths and other env variables. This will allow the rest of
27276     # the configure script to find and run the compiler in the proper way.
27277     { $as_echo "$as_me:${as_lineno-$LINENO}: Setting extracted environment variables" >&5
27278 $as_echo "$as_me: Setting extracted environment variables" >&6;}
27279     . $OUTPUT_ROOT/localdevenv.sh
27280   else
27281     # We did not find a vsvars bat file, let's hope we are run from a VS command prompt.
27282     { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio installation, checking current environment" >&5
27283 $as_echo "$as_me: Cannot locate a valid Visual Studio installation, checking current environment" >&6;}
27284   fi
27285 
27286   # At this point, we should have corrent variables in the environment, or we can't continue.
27287   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Visual Studio variables" >&5
27288 $as_echo_n "checking for Visual Studio variables... " >&6; }
27289 
27290   if test "x$VCINSTALLDIR" != x || test "x$WindowsSDKDir" != x || test "x$WINDOWSSDKDIR" != x; then
27291     if test "x$INCLUDE" = x || test "x$LIB" = x; then
27292       { $as_echo "$as_me:${as_lineno-$LINENO}: result: present but broken" >&5
27293 $as_echo "present but broken" >&6; }
27294       as_fn_error $? "Your VC command prompt seems broken, INCLUDE and/or LIB is missing." "$LINENO" 5
27295     else
27296       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
27297 $as_echo "ok" >&6; }
27298       # Remove any trailing \ from INCLUDE and LIB to avoid trouble in spec.gmk.
27299       VS_INCLUDE=`$ECHO "$INCLUDE" | $SED 's/\\\\$//'`
27300       VS_LIB=`$ECHO "$LIB" | $SED 's/\\\\$//'`
27301       # Remove any paths containing # (typically F#) as that messes up make
27302       PATH=`$ECHO "$PATH" | $SED 's/[^:#]*#[^:]*://g'`
27303       VS_PATH="$PATH"
27304 
27305 
27306 
27307     fi
27308   else
27309     { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
27310 $as_echo "not found" >&6; }
27311 
27312     if test "x$VS_ENV_CMD" = x; then
27313       { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&5
27314 $as_echo "$as_me: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&6;}
27315       { $as_echo "$as_me:${as_lineno-$LINENO}: nor is this script run from a Visual Studio command prompt." >&5
27316 $as_echo "$as_me: nor is this script run from a Visual Studio command prompt." >&6;}
27317     else
27318       { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5
27319 $as_echo "$as_me: Running the extraction script failed." >&6;}
27320     fi
27321     { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5
27322 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;}
27323     { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5
27324 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;}
27325     as_fn_error $? "Cannot continue" "$LINENO" 5
27326   fi
27327 
27328 
27329 
27330 # Check whether --with-msvcr-dll was given.
27331 if test "${with_msvcr_dll+set}" = set; then :
27332   withval=$with_msvcr_dll;
27333 fi
27334 
27335 
27336   if test "x$with_msvcr_dll" != x; then
27337     # If given explicitely by user, do not probe. If not present, fail directly.
27338 
27339   POSSIBLE_MSVCR_DLL="$with_msvcr_dll"
27340   METHOD="--with-msvcr-dll"
27341   if test -e "$POSSIBLE_MSVCR_DLL"; then
27342     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
27343 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
27344 
27345     # Need to check if the found msvcr is correct architecture
27346     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
27347 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
27348     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
27349     if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
27350       CORRECT_MSVCR_ARCH=386
27351     else
27352       CORRECT_MSVCR_ARCH=x86-64
27353     fi
27354     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
27355       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
27356 $as_echo "ok" >&6; }
27357       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
27358       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
27359 $as_echo_n "checking for msvcr100.dll... " >&6; }
27360       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
27361 $as_echo "$MSVCR_DLL" >&6; }
27362     else
27363       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
27364 $as_echo "incorrect, ignoring" >&6; }
27365       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
27366 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
27367     fi
27368   fi
27369 
27370     if test "x$MSVCR_DLL" = x; then
27371       as_fn_error $? "Could not find a proper msvcr100.dll as specified by --with-msvcr-dll" "$LINENO" 5
27372     fi
27373   fi
27374 
27375   if test "x$MSVCR_DLL" = x; then
27376     # Probe: Using well-known location from Visual Studio 10.0
27377     if test "x$VCINSTALLDIR" != x; then
27378       CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR"
27379 
27380   windows_path="$CYGWIN_VC_INSTALL_DIR"
27381   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27382     unix_path=`$CYGPATH -u "$windows_path"`
27383     CYGWIN_VC_INSTALL_DIR="$unix_path"
27384   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27385     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27386     CYGWIN_VC_INSTALL_DIR="$unix_path"
27387   fi
27388 
27389       if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
27390         POSSIBLE_MSVCR_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC100.CRT/msvcr100.dll"
27391       else
27392         POSSIBLE_MSVCR_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC100.CRT/msvcr100.dll"
27393       fi
27394 
27395   POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
27396   METHOD="well-known location in VCINSTALLDIR"
27397   if test -e "$POSSIBLE_MSVCR_DLL"; then
27398     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
27399 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
27400 
27401     # Need to check if the found msvcr is correct architecture
27402     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
27403 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
27404     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
27405     if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
27406       CORRECT_MSVCR_ARCH=386
27407     else
27408       CORRECT_MSVCR_ARCH=x86-64
27409     fi
27410     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
27411       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
27412 $as_echo "ok" >&6; }
27413       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
27414       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
27415 $as_echo_n "checking for msvcr100.dll... " >&6; }
27416       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
27417 $as_echo "$MSVCR_DLL" >&6; }
27418     else
27419       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
27420 $as_echo "incorrect, ignoring" >&6; }
27421       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
27422 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
27423     fi
27424   fi
27425 
27426     fi
27427   fi
27428 
27429   if test "x$MSVCR_DLL" = x; then
27430     # Probe: Check in the Boot JDK directory.
27431     POSSIBLE_MSVCR_DLL="$BOOT_JDK/bin/msvcr100.dll"
27432 
27433   POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
27434   METHOD="well-known location in Boot JDK"
27435   if test -e "$POSSIBLE_MSVCR_DLL"; then
27436     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
27437 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
27438 
27439     # Need to check if the found msvcr is correct architecture
27440     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
27441 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
27442     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
27443     if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
27444       CORRECT_MSVCR_ARCH=386
27445     else
27446       CORRECT_MSVCR_ARCH=x86-64
27447     fi
27448     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
27449       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
27450 $as_echo "ok" >&6; }
27451       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
27452       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
27453 $as_echo_n "checking for msvcr100.dll... " >&6; }
27454       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
27455 $as_echo "$MSVCR_DLL" >&6; }
27456     else
27457       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
27458 $as_echo "incorrect, ignoring" >&6; }
27459       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
27460 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
27461     fi
27462   fi
27463 
27464   fi
27465 
27466   if test "x$MSVCR_DLL" = x; then
27467     # Probe: Look in the Windows system32 directory
27468     CYGWIN_SYSTEMROOT="$SYSTEMROOT"
27469 
27470   windows_path="$CYGWIN_SYSTEMROOT"
27471   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27472     unix_path=`$CYGPATH -u "$windows_path"`
27473     CYGWIN_SYSTEMROOT="$unix_path"
27474   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27475     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27476     CYGWIN_SYSTEMROOT="$unix_path"
27477   fi
27478 
27479     POSSIBLE_MSVCR_DLL="$CYGWIN_SYSTEMROOT/system32/msvcr100.dll"
27480 
27481   POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
27482   METHOD="well-known location in SYSTEMROOT"
27483   if test -e "$POSSIBLE_MSVCR_DLL"; then
27484     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
27485 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
27486 
27487     # Need to check if the found msvcr is correct architecture
27488     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
27489 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
27490     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
27491     if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
27492       CORRECT_MSVCR_ARCH=386
27493     else
27494       CORRECT_MSVCR_ARCH=x86-64
27495     fi
27496     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
27497       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
27498 $as_echo "ok" >&6; }
27499       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
27500       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
27501 $as_echo_n "checking for msvcr100.dll... " >&6; }
27502       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
27503 $as_echo "$MSVCR_DLL" >&6; }
27504     else
27505       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
27506 $as_echo "incorrect, ignoring" >&6; }
27507       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
27508 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
27509     fi
27510   fi
27511 
27512   fi
27513 
27514   if test "x$MSVCR_DLL" = x; then
27515     # Probe: If Visual Studio Express is installed, there is usually one with the debugger
27516     if test "x$VS100COMNTOOLS" != x; then
27517       CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.."
27518 
27519   windows_path="$CYGWIN_VS_TOOLS_DIR"
27520   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27521     unix_path=`$CYGPATH -u "$windows_path"`
27522     CYGWIN_VS_TOOLS_DIR="$unix_path"
27523   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27524     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27525     CYGWIN_VS_TOOLS_DIR="$unix_path"
27526   fi
27527 
27528       if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
27529         POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name msvcr100.dll | $GREP -i /x64/ | $HEAD --lines 1`
27530       else
27531         POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name msvcr100.dll | $GREP -i /x86/ | $HEAD --lines 1`
27532       fi
27533 
27534   POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
27535   METHOD="search of VS100COMNTOOLS"
27536   if test -e "$POSSIBLE_MSVCR_DLL"; then
27537     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
27538 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
27539 
27540     # Need to check if the found msvcr is correct architecture
27541     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
27542 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
27543     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
27544     if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
27545       CORRECT_MSVCR_ARCH=386
27546     else
27547       CORRECT_MSVCR_ARCH=x86-64
27548     fi
27549     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
27550       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
27551 $as_echo "ok" >&6; }
27552       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
27553       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
27554 $as_echo_n "checking for msvcr100.dll... " >&6; }
27555       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
27556 $as_echo "$MSVCR_DLL" >&6; }
27557     else
27558       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
27559 $as_echo "incorrect, ignoring" >&6; }
27560       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
27561 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
27562     fi
27563   fi
27564 
27565     fi
27566   fi
27567 
27568   if test "x$MSVCR_DLL" = x; then
27569     # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now.
27570     # (This was the original behaviour; kept since it might turn up something)
27571     if test "x$CYGWIN_VC_INSTALL_DIR" != x; then
27572       if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
27573         POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $GREP x64 | $HEAD --lines 1`
27574       else
27575         POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1`
27576         if test "x$POSSIBLE_MSVCR_DLL" = x; then
27577           # We're grasping at straws now...
27578           POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $HEAD --lines 1`
27579         fi
27580       fi
27581 
27582 
27583   POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
27584   METHOD="search of VCINSTALLDIR"
27585   if test -e "$POSSIBLE_MSVCR_DLL"; then
27586     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
27587 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
27588 
27589     # Need to check if the found msvcr is correct architecture
27590     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
27591 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
27592     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
27593     if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
27594       CORRECT_MSVCR_ARCH=386
27595     else
27596       CORRECT_MSVCR_ARCH=x86-64
27597     fi
27598     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP $CORRECT_MSVCR_ARCH 2>&1 > /dev/null; then
27599       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
27600 $as_echo "ok" >&6; }
27601       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
27602       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
27603 $as_echo_n "checking for msvcr100.dll... " >&6; }
27604       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
27605 $as_echo "$MSVCR_DLL" >&6; }
27606     else
27607       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
27608 $as_echo "incorrect, ignoring" >&6; }
27609       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
27610 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
27611     fi
27612   fi
27613 
27614     fi
27615   fi
27616 
27617   if test "x$MSVCR_DLL" = x; then
27618     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
27619 $as_echo_n "checking for msvcr100.dll... " >&6; }
27620     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27621 $as_echo "no" >&6; }
27622     as_fn_error $? "Could not find msvcr100.dll. Please specify using --with-msvcr-dll." "$LINENO" 5
27623   fi
27624 
27625 
27626   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27627 
27628   # Input might be given as Windows format, start by converting to
27629   # unix format.
27630   path="$MSVCR_DLL"
27631   new_path=`$CYGPATH -u "$path"`
27632 
27633   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
27634   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
27635   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
27636   # "foo.exe" is OK but "foo" is an error.
27637   #
27638   # This test is therefore slightly more accurate than "test -f" to check for file precense.
27639   # It is also a way to make sure we got the proper file name for the real test later on.
27640   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
27641   if test "x$test_shortpath" = x; then
27642     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&5
27643 $as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&6;}
27644     as_fn_error $? "Cannot locate the the path of MSVCR_DLL" "$LINENO" 5
27645   fi
27646 
27647   # Call helper function which possibly converts this using DOS-style short mode.
27648   # If so, the updated path is stored in $new_path.
27649 
27650   input_path="$new_path"
27651   # Check if we need to convert this using DOS-style short mode. If the path
27652   # contains just simple characters, use it. Otherwise (spaces, weird characters),
27653   # take no chances and rewrite it.
27654   # Note: m4 eats our [], so we need to use [ and ] instead.
27655   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
27656   if test "x$has_forbidden_chars" != x; then
27657     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27658     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
27659     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
27660     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
27661       # Going to short mode and back again did indeed matter. Since short mode is
27662       # case insensitive, let's make it lowercase to improve readability.
27663       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27664       # Now convert it back to Unix-stile (cygpath)
27665       input_path=`$CYGPATH -u "$shortmode_path"`
27666       new_path="$input_path"
27667     fi
27668   fi
27669 
27670   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
27671   if test "x$test_cygdrive_prefix" = x; then
27672     # As a simple fix, exclude /usr/bin since it's not a real path.
27673     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
27674       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
27675       # a path prefixed by /cygdrive for fixpath to work.
27676       new_path="$CYGWIN_ROOT_PATH$input_path"
27677     fi
27678   fi
27679 
27680 
27681   if test "x$path" != "x$new_path"; then
27682     MSVCR_DLL="$new_path"
27683     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVCR_DLL to \"$new_path\"" >&5
27684 $as_echo "$as_me: Rewriting MSVCR_DLL to \"$new_path\"" >&6;}
27685   fi
27686 
27687   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27688 
27689   path="$MSVCR_DLL"
27690   has_colon=`$ECHO $path | $GREP ^.:`
27691   new_path="$path"
27692   if test "x$has_colon" = x; then
27693     # Not in mixed or Windows style, start by that.
27694     new_path=`cmd //c echo $path`
27695   fi
27696 
27697 
27698   input_path="$new_path"
27699   # Check if we need to convert this using DOS-style short mode. If the path
27700   # contains just simple characters, use it. Otherwise (spaces, weird characters),
27701   # take no chances and rewrite it.
27702   # Note: m4 eats our [], so we need to use [ and ] instead.
27703   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
27704   if test "x$has_forbidden_chars" != x; then
27705     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27706     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27707   fi
27708 
27709 
27710   windows_path="$new_path"
27711   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27712     unix_path=`$CYGPATH -u "$windows_path"`
27713     new_path="$unix_path"
27714   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27715     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27716     new_path="$unix_path"
27717   fi
27718 
27719   if test "x$path" != "x$new_path"; then
27720     MSVCR_DLL="$new_path"
27721     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVCR_DLL to \"$new_path\"" >&5
27722 $as_echo "$as_me: Rewriting MSVCR_DLL to \"$new_path\"" >&6;}
27723   fi
27724 
27725   # Save the first 10 bytes of this path to the storage, so fixpath can work.
27726   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
27727 
27728   else
27729     # We're on a posix platform. Hooray! :)
27730     path="$MSVCR_DLL"
27731     has_space=`$ECHO "$path" | $GREP " "`
27732     if test "x$has_space" != x; then
27733       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&5
27734 $as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&6;}
27735       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
27736     fi
27737 
27738     # Use eval to expand a potential ~
27739     eval path="$path"
27740     if test ! -f "$path" && test ! -d "$path"; then
27741       as_fn_error $? "The path of MSVCR_DLL, which resolves as \"$path\", is not found." "$LINENO" 5
27742     fi
27743 
27744     MSVCR_DLL="`cd "$path"; $THEPWDCMD -L`"
27745   fi
27746 
27747 
27748 
27749 
27750 # Check whether --with-dxsdk was given.
27751 if test "${with_dxsdk+set}" = set; then :
27752   withval=$with_dxsdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&5
27753 $as_echo "$as_me: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&2;}
27754 fi
27755 
27756 
27757 
27758 
27759 # Check whether --with-dxsdk-lib was given.
27760 if test "${with_dxsdk_lib+set}" = set; then :
27761   withval=$with_dxsdk_lib; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&5
27762 $as_echo "$as_me: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&2;}
27763 fi
27764 
27765 
27766 
27767 
27768 # Check whether --with-dxsdk-include was given.
27769 if test "${with_dxsdk_include+set}" = set; then :
27770   withval=$with_dxsdk_include; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&5
27771 $as_echo "$as_me: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&2;}
27772 fi
27773 
27774 
27775   fi
27776 
27777 
27778 
27779   # If --build AND --host is set, then the configure script will find any
27780   # cross compilation tools in the PATH. Cross compilation tools
27781   # follows the cross compilation standard where they are prefixed with ${host}.
27782   # For example the binary i686-sun-solaris2.10-gcc
27783   # will cross compile for i686-sun-solaris2.10
27784   # If neither of build and host is not set, then build=host and the
27785   # default compiler found in the path will be used.
27786   # Setting only --host, does not seem to be really supported.
27787   # Please set both --build and --host if you want to cross compile.
27788 
27789   if test "x$COMPILE_TYPE" = "xcross"; then
27790     # Now we to find a C/C++ compiler that can build executables for the build
27791     # platform. We can't use the AC_PROG_CC macro, since it can only be used
27792     # once. Also, we need to do this before adding a tools dir to the path,
27793     # otherwise we might pick up cross-compilers which don't use standard naming.
27794     # Otherwise, we'll set the BUILD_tools to the native tools, but that'll have
27795     # to wait until they are properly discovered.
27796 
27797 
27798   # Publish this variable in the help.
27799 
27800 
27801   if test "x$BUILD_CC" = x; then
27802     # The variable is not set by user, try to locate tool using the code snippet
27803     for ac_prog in cl cc gcc
27804 do
27805   # Extract the first word of "$ac_prog", so it can be a program name with args.
27806 set dummy $ac_prog; ac_word=$2
27807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27808 $as_echo_n "checking for $ac_word... " >&6; }
27809 if ${ac_cv_path_BUILD_CC+:} false; then :
27810   $as_echo_n "(cached) " >&6
27811 else
27812   case $BUILD_CC in
27813   [\\/]* | ?:[\\/]*)
27814   ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
27815   ;;
27816   *)
27817   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27818 for as_dir in $PATH
27819 do
27820   IFS=$as_save_IFS
27821   test -z "$as_dir" && as_dir=.
27822     for ac_exec_ext in '' $ac_executable_extensions; do
27823   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27824     ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
27825     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27826     break 2
27827   fi
27828 done
27829   done
27830 IFS=$as_save_IFS
27831 
27832   ;;
27833 esac
27834 fi
27835 BUILD_CC=$ac_cv_path_BUILD_CC
27836 if test -n "$BUILD_CC"; then
27837   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
27838 $as_echo "$BUILD_CC" >&6; }
27839 else
27840   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27841 $as_echo "no" >&6; }
27842 fi
27843 
27844 
27845   test -n "$BUILD_CC" && break
27846 done
27847 
27848   else
27849     # The variable is set, but is it from the command line or the environment?
27850 
27851     # Try to remove the string !BUILD_CC! from our list.
27852     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CC!/}
27853     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
27854       # If it failed, the variable was not from the command line. Ignore it,
27855       # but warn the user (except for BASH, which is always set by the calling BASH).
27856       if test "xBUILD_CC" != xBASH; then
27857         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&5
27858 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&2;}
27859       fi
27860       # Try to locate tool using the code snippet
27861       for ac_prog in cl cc gcc
27862 do
27863   # Extract the first word of "$ac_prog", so it can be a program name with args.
27864 set dummy $ac_prog; ac_word=$2
27865 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27866 $as_echo_n "checking for $ac_word... " >&6; }
27867 if ${ac_cv_path_BUILD_CC+:} false; then :
27868   $as_echo_n "(cached) " >&6
27869 else
27870   case $BUILD_CC in
27871   [\\/]* | ?:[\\/]*)
27872   ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
27873   ;;
27874   *)
27875   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27876 for as_dir in $PATH
27877 do
27878   IFS=$as_save_IFS
27879   test -z "$as_dir" && as_dir=.
27880     for ac_exec_ext in '' $ac_executable_extensions; do
27881   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27882     ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
27883     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27884     break 2
27885   fi
27886 done
27887   done
27888 IFS=$as_save_IFS
27889 
27890   ;;
27891 esac
27892 fi
27893 BUILD_CC=$ac_cv_path_BUILD_CC
27894 if test -n "$BUILD_CC"; then
27895   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
27896 $as_echo "$BUILD_CC" >&6; }
27897 else
27898   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27899 $as_echo "no" >&6; }
27900 fi
27901 
27902 
27903   test -n "$BUILD_CC" && break
27904 done
27905 
27906     else
27907       # If it succeeded, then it was overridden by the user. We will use it
27908       # for the tool.
27909 
27910       # First remove it from the list of overridden variables, so we can test
27911       # for unknown variables in the end.
27912       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
27913 
27914       # Check if the provided tool contains a complete path.
27915       tool_specified="$BUILD_CC"
27916       tool_basename="${tool_specified##*/}"
27917       if test "x$tool_basename" = "x$tool_specified"; then
27918         # A command without a complete path is provided, search $PATH.
27919         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CC=$tool_basename" >&5
27920 $as_echo "$as_me: Will search for user supplied tool BUILD_CC=$tool_basename" >&6;}
27921         # Extract the first word of "$tool_basename", so it can be a program name with args.
27922 set dummy $tool_basename; ac_word=$2
27923 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27924 $as_echo_n "checking for $ac_word... " >&6; }
27925 if ${ac_cv_path_BUILD_CC+:} false; then :
27926   $as_echo_n "(cached) " >&6
27927 else
27928   case $BUILD_CC in
27929   [\\/]* | ?:[\\/]*)
27930   ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
27931   ;;
27932   *)
27933   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27934 for as_dir in $PATH
27935 do
27936   IFS=$as_save_IFS
27937   test -z "$as_dir" && as_dir=.
27938     for ac_exec_ext in '' $ac_executable_extensions; do
27939   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27940     ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
27941     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27942     break 2
27943   fi
27944 done
27945   done
27946 IFS=$as_save_IFS
27947 
27948   ;;
27949 esac
27950 fi
27951 BUILD_CC=$ac_cv_path_BUILD_CC
27952 if test -n "$BUILD_CC"; then
27953   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
27954 $as_echo "$BUILD_CC" >&6; }
27955 else
27956   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27957 $as_echo "no" >&6; }
27958 fi
27959 
27960 
27961         if test "x$BUILD_CC" = x; then
27962           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
27963         fi
27964       else
27965         # Otherwise we believe it is a complete path. Use it as it is.
27966         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CC=$tool_specified" >&5
27967 $as_echo "$as_me: Will use user supplied tool BUILD_CC=$tool_specified" >&6;}
27968         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5
27969 $as_echo_n "checking for BUILD_CC... " >&6; }
27970         if test ! -x "$tool_specified"; then
27971           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
27972 $as_echo "not found" >&6; }
27973           as_fn_error $? "User supplied tool BUILD_CC=$tool_specified does not exist or is not executable" "$LINENO" 5
27974         fi
27975         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
27976 $as_echo "$tool_specified" >&6; }
27977       fi
27978     fi
27979   fi
27980 
27981 
27982 
27983   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27984 
27985   # First separate the path from the arguments. This will split at the first
27986   # space.
27987   complete="$BUILD_CC"
27988   path="${complete%% *}"
27989   tmp="$complete EOL"
27990   arguments="${tmp#* }"
27991 
27992   # Input might be given as Windows format, start by converting to
27993   # unix format.
27994   new_path=`$CYGPATH -u "$path"`
27995 
27996   # Now try to locate executable using which
27997   new_path=`$WHICH "$new_path" 2> /dev/null`
27998   # bat and cmd files are not always considered executable in cygwin causing which
27999   # to not find them
28000   if test "x$new_path" = x \
28001       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28002       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28003     new_path=`$CYGPATH -u "$path"`
28004   fi
28005   if test "x$new_path" = x; then
28006     # Oops. Which didn't find the executable.
28007     # The splitting of arguments from the executable at a space might have been incorrect,
28008     # since paths with space are more likely in Windows. Give it another try with the whole
28009     # argument.
28010     path="$complete"
28011     arguments="EOL"
28012     new_path=`$CYGPATH -u "$path"`
28013     new_path=`$WHICH "$new_path" 2> /dev/null`
28014     # bat and cmd files are not always considered executable in cygwin causing which
28015     # to not find them
28016     if test "x$new_path" = x \
28017         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28018         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28019       new_path=`$CYGPATH -u "$path"`
28020     fi
28021     if test "x$new_path" = x; then
28022       # It's still not found. Now this is an unrecoverable error.
28023       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
28024 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
28025       has_space=`$ECHO "$complete" | $GREP " "`
28026       if test "x$has_space" != x; then
28027         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
28028 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
28029       fi
28030       as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
28031     fi
28032   fi
28033 
28034   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
28035   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
28036   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
28037   # "foo.exe" is OK but "foo" is an error.
28038   #
28039   # This test is therefore slightly more accurate than "test -f" to check for file presence.
28040   # It is also a way to make sure we got the proper file name for the real test later on.
28041   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
28042   if test "x$test_shortpath" = x; then
28043     # Short path failed, file does not exist as specified.
28044     # Try adding .exe or .cmd
28045     if test -f "${new_path}.exe"; then
28046       input_to_shortpath="${new_path}.exe"
28047     elif test -f "${new_path}.cmd"; then
28048       input_to_shortpath="${new_path}.cmd"
28049     else
28050       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&5
28051 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&6;}
28052       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
28053 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
28054       as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
28055     fi
28056   else
28057     input_to_shortpath="$new_path"
28058   fi
28059 
28060   # Call helper function which possibly converts this using DOS-style short mode.
28061   # If so, the updated path is stored in $new_path.
28062   new_path="$input_to_shortpath"
28063 
28064   input_path="$input_to_shortpath"
28065   # Check if we need to convert this using DOS-style short mode. If the path
28066   # contains just simple characters, use it. Otherwise (spaces, weird characters),
28067   # take no chances and rewrite it.
28068   # Note: m4 eats our [], so we need to use [ and ] instead.
28069   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
28070   if test "x$has_forbidden_chars" != x; then
28071     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28072     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
28073     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
28074     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
28075       # Going to short mode and back again did indeed matter. Since short mode is
28076       # case insensitive, let's make it lowercase to improve readability.
28077       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28078       # Now convert it back to Unix-stile (cygpath)
28079       input_path=`$CYGPATH -u "$shortmode_path"`
28080       new_path="$input_path"
28081     fi
28082   fi
28083 
28084   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
28085   if test "x$test_cygdrive_prefix" = x; then
28086     # As a simple fix, exclude /usr/bin since it's not a real path.
28087     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
28088       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
28089       # a path prefixed by /cygdrive for fixpath to work.
28090       new_path="$CYGWIN_ROOT_PATH$input_path"
28091     fi
28092   fi
28093 
28094   # remove trailing .exe if any
28095   new_path="${new_path/%.exe/}"
28096 
28097   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28098 
28099   # First separate the path from the arguments. This will split at the first
28100   # space.
28101   complete="$BUILD_CC"
28102   path="${complete%% *}"
28103   tmp="$complete EOL"
28104   arguments="${tmp#* }"
28105 
28106   # Input might be given as Windows format, start by converting to
28107   # unix format.
28108   new_path="$path"
28109 
28110   windows_path="$new_path"
28111   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28112     unix_path=`$CYGPATH -u "$windows_path"`
28113     new_path="$unix_path"
28114   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28115     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28116     new_path="$unix_path"
28117   fi
28118 
28119 
28120   # Now try to locate executable using which
28121   new_path=`$WHICH "$new_path" 2> /dev/null`
28122 
28123   if test "x$new_path" = x; then
28124     # Oops. Which didn't find the executable.
28125     # The splitting of arguments from the executable at a space might have been incorrect,
28126     # since paths with space are more likely in Windows. Give it another try with the whole
28127     # argument.
28128     path="$complete"
28129     arguments="EOL"
28130     new_path="$path"
28131 
28132   windows_path="$new_path"
28133   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28134     unix_path=`$CYGPATH -u "$windows_path"`
28135     new_path="$unix_path"
28136   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28137     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28138     new_path="$unix_path"
28139   fi
28140 
28141 
28142     new_path=`$WHICH "$new_path" 2> /dev/null`
28143 
28144     if test "x$new_path" = x; then
28145       # It's still not found. Now this is an unrecoverable error.
28146       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
28147 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
28148       has_space=`$ECHO "$complete" | $GREP " "`
28149       if test "x$has_space" != x; then
28150         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
28151 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
28152       fi
28153       as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
28154     fi
28155   fi
28156 
28157   # Now new_path has a complete unix path to the binary
28158   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
28159     # Keep paths in /bin as-is, but remove trailing .exe if any
28160     new_path="${new_path/%.exe/}"
28161     # Do not save /bin paths to all_fixpath_prefixes!
28162   else
28163     # Not in mixed or Windows style, start by that.
28164     new_path=`cmd //c echo $new_path`
28165 
28166   input_path="$new_path"
28167   # Check if we need to convert this using DOS-style short mode. If the path
28168   # contains just simple characters, use it. Otherwise (spaces, weird characters),
28169   # take no chances and rewrite it.
28170   # Note: m4 eats our [], so we need to use [ and ] instead.
28171   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
28172   if test "x$has_forbidden_chars" != x; then
28173     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28174     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28175   fi
28176 
28177     # Output is in $new_path
28178 
28179   windows_path="$new_path"
28180   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28181     unix_path=`$CYGPATH -u "$windows_path"`
28182     new_path="$unix_path"
28183   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28184     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28185     new_path="$unix_path"
28186   fi
28187 
28188     # remove trailing .exe if any
28189     new_path="${new_path/%.exe/}"
28190 
28191     # Save the first 10 bytes of this path to the storage, so fixpath can work.
28192     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
28193   fi
28194 
28195   else
28196     # We're on a posix platform. Hooray! :)
28197     # First separate the path from the arguments. This will split at the first
28198     # space.
28199     complete="$BUILD_CC"
28200     path="${complete%% *}"
28201     tmp="$complete EOL"
28202     arguments="${tmp#* }"
28203 
28204     # Cannot rely on the command "which" here since it doesn't always work.
28205     is_absolute_path=`$ECHO "$path" | $GREP ^/`
28206     if test -z "$is_absolute_path"; then
28207       # Path to executable is not absolute. Find it.
28208       IFS_save="$IFS"
28209       IFS=:
28210       for p in $PATH; do
28211         if test -f "$p/$path" && test -x "$p/$path"; then
28212           new_path="$p/$path"
28213           break
28214         fi
28215       done
28216       IFS="$IFS_save"
28217     else
28218       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving BUILD_CC (as $path) failed, using $path directly." >&5
28219 $as_echo "$as_me: Resolving BUILD_CC (as $path) failed, using $path directly." >&6;}
28220       new_path="$path"
28221     fi
28222 
28223     if test "x$new_path" = x; then
28224       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
28225 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
28226       has_space=`$ECHO "$complete" | $GREP " "`
28227       if test "x$has_space" != x; then
28228         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
28229 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
28230       fi
28231       as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
28232     fi
28233   fi
28234 
28235   # Now join together the path and the arguments once again
28236   if test "x$arguments" != xEOL; then
28237     new_complete="$new_path ${arguments% *}"
28238   else
28239     new_complete="$new_path"
28240   fi
28241 
28242   if test "x$complete" != "x$new_complete"; then
28243     BUILD_CC="$new_complete"
28244     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CC to \"$new_complete\"" >&5
28245 $as_echo "$as_me: Rewriting BUILD_CC to \"$new_complete\"" >&6;}
28246   fi
28247 
28248 
28249 
28250   # Publish this variable in the help.
28251 
28252 
28253   if test "x$BUILD_CXX" = x; then
28254     # The variable is not set by user, try to locate tool using the code snippet
28255     for ac_prog in cl CC g++
28256 do
28257   # Extract the first word of "$ac_prog", so it can be a program name with args.
28258 set dummy $ac_prog; ac_word=$2
28259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28260 $as_echo_n "checking for $ac_word... " >&6; }
28261 if ${ac_cv_path_BUILD_CXX+:} false; then :
28262   $as_echo_n "(cached) " >&6
28263 else
28264   case $BUILD_CXX in
28265   [\\/]* | ?:[\\/]*)
28266   ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
28267   ;;
28268   *)
28269   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28270 for as_dir in $PATH
28271 do
28272   IFS=$as_save_IFS
28273   test -z "$as_dir" && as_dir=.
28274     for ac_exec_ext in '' $ac_executable_extensions; do
28275   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28276     ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
28277     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28278     break 2
28279   fi
28280 done
28281   done
28282 IFS=$as_save_IFS
28283 
28284   ;;
28285 esac
28286 fi
28287 BUILD_CXX=$ac_cv_path_BUILD_CXX
28288 if test -n "$BUILD_CXX"; then
28289   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
28290 $as_echo "$BUILD_CXX" >&6; }
28291 else
28292   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28293 $as_echo "no" >&6; }
28294 fi
28295 
28296 
28297   test -n "$BUILD_CXX" && break
28298 done
28299 
28300   else
28301     # The variable is set, but is it from the command line or the environment?
28302 
28303     # Try to remove the string !BUILD_CXX! from our list.
28304     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CXX!/}
28305     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
28306       # If it failed, the variable was not from the command line. Ignore it,
28307       # but warn the user (except for BASH, which is always set by the calling BASH).
28308       if test "xBUILD_CXX" != xBASH; then
28309         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&5
28310 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&2;}
28311       fi
28312       # Try to locate tool using the code snippet
28313       for ac_prog in cl CC g++
28314 do
28315   # Extract the first word of "$ac_prog", so it can be a program name with args.
28316 set dummy $ac_prog; ac_word=$2
28317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28318 $as_echo_n "checking for $ac_word... " >&6; }
28319 if ${ac_cv_path_BUILD_CXX+:} false; then :
28320   $as_echo_n "(cached) " >&6
28321 else
28322   case $BUILD_CXX in
28323   [\\/]* | ?:[\\/]*)
28324   ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
28325   ;;
28326   *)
28327   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28328 for as_dir in $PATH
28329 do
28330   IFS=$as_save_IFS
28331   test -z "$as_dir" && as_dir=.
28332     for ac_exec_ext in '' $ac_executable_extensions; do
28333   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28334     ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
28335     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28336     break 2
28337   fi
28338 done
28339   done
28340 IFS=$as_save_IFS
28341 
28342   ;;
28343 esac
28344 fi
28345 BUILD_CXX=$ac_cv_path_BUILD_CXX
28346 if test -n "$BUILD_CXX"; then
28347   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
28348 $as_echo "$BUILD_CXX" >&6; }
28349 else
28350   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28351 $as_echo "no" >&6; }
28352 fi
28353 
28354 
28355   test -n "$BUILD_CXX" && break
28356 done
28357 
28358     else
28359       # If it succeeded, then it was overridden by the user. We will use it
28360       # for the tool.
28361 
28362       # First remove it from the list of overridden variables, so we can test
28363       # for unknown variables in the end.
28364       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
28365 
28366       # Check if the provided tool contains a complete path.
28367       tool_specified="$BUILD_CXX"
28368       tool_basename="${tool_specified##*/}"
28369       if test "x$tool_basename" = "x$tool_specified"; then
28370         # A command without a complete path is provided, search $PATH.
28371         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CXX=$tool_basename" >&5
28372 $as_echo "$as_me: Will search for user supplied tool BUILD_CXX=$tool_basename" >&6;}
28373         # Extract the first word of "$tool_basename", so it can be a program name with args.
28374 set dummy $tool_basename; ac_word=$2
28375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28376 $as_echo_n "checking for $ac_word... " >&6; }
28377 if ${ac_cv_path_BUILD_CXX+:} false; then :
28378   $as_echo_n "(cached) " >&6
28379 else
28380   case $BUILD_CXX in
28381   [\\/]* | ?:[\\/]*)
28382   ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
28383   ;;
28384   *)
28385   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28386 for as_dir in $PATH
28387 do
28388   IFS=$as_save_IFS
28389   test -z "$as_dir" && as_dir=.
28390     for ac_exec_ext in '' $ac_executable_extensions; do
28391   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28392     ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
28393     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28394     break 2
28395   fi
28396 done
28397   done
28398 IFS=$as_save_IFS
28399 
28400   ;;
28401 esac
28402 fi
28403 BUILD_CXX=$ac_cv_path_BUILD_CXX
28404 if test -n "$BUILD_CXX"; then
28405   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
28406 $as_echo "$BUILD_CXX" >&6; }
28407 else
28408   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28409 $as_echo "no" >&6; }
28410 fi
28411 
28412 
28413         if test "x$BUILD_CXX" = x; then
28414           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
28415         fi
28416       else
28417         # Otherwise we believe it is a complete path. Use it as it is.
28418         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CXX=$tool_specified" >&5
28419 $as_echo "$as_me: Will use user supplied tool BUILD_CXX=$tool_specified" >&6;}
28420         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5
28421 $as_echo_n "checking for BUILD_CXX... " >&6; }
28422         if test ! -x "$tool_specified"; then
28423           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
28424 $as_echo "not found" >&6; }
28425           as_fn_error $? "User supplied tool BUILD_CXX=$tool_specified does not exist or is not executable" "$LINENO" 5
28426         fi
28427         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
28428 $as_echo "$tool_specified" >&6; }
28429       fi
28430     fi
28431   fi
28432 
28433 
28434 
28435   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28436 
28437   # First separate the path from the arguments. This will split at the first
28438   # space.
28439   complete="$BUILD_CXX"
28440   path="${complete%% *}"
28441   tmp="$complete EOL"
28442   arguments="${tmp#* }"
28443 
28444   # Input might be given as Windows format, start by converting to
28445   # unix format.
28446   new_path=`$CYGPATH -u "$path"`
28447 
28448   # Now try to locate executable using which
28449   new_path=`$WHICH "$new_path" 2> /dev/null`
28450   # bat and cmd files are not always considered executable in cygwin causing which
28451   # to not find them
28452   if test "x$new_path" = x \
28453       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28454       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28455     new_path=`$CYGPATH -u "$path"`
28456   fi
28457   if test "x$new_path" = x; then
28458     # Oops. Which didn't find the executable.
28459     # The splitting of arguments from the executable at a space might have been incorrect,
28460     # since paths with space are more likely in Windows. Give it another try with the whole
28461     # argument.
28462     path="$complete"
28463     arguments="EOL"
28464     new_path=`$CYGPATH -u "$path"`
28465     new_path=`$WHICH "$new_path" 2> /dev/null`
28466     # bat and cmd files are not always considered executable in cygwin causing which
28467     # to not find them
28468     if test "x$new_path" = x \
28469         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28470         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28471       new_path=`$CYGPATH -u "$path"`
28472     fi
28473     if test "x$new_path" = x; then
28474       # It's still not found. Now this is an unrecoverable error.
28475       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
28476 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
28477       has_space=`$ECHO "$complete" | $GREP " "`
28478       if test "x$has_space" != x; then
28479         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
28480 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
28481       fi
28482       as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
28483     fi
28484   fi
28485 
28486   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
28487   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
28488   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
28489   # "foo.exe" is OK but "foo" is an error.
28490   #
28491   # This test is therefore slightly more accurate than "test -f" to check for file presence.
28492   # It is also a way to make sure we got the proper file name for the real test later on.
28493   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
28494   if test "x$test_shortpath" = x; then
28495     # Short path failed, file does not exist as specified.
28496     # Try adding .exe or .cmd
28497     if test -f "${new_path}.exe"; then
28498       input_to_shortpath="${new_path}.exe"
28499     elif test -f "${new_path}.cmd"; then
28500       input_to_shortpath="${new_path}.cmd"
28501     else
28502       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&5
28503 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&6;}
28504       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
28505 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
28506       as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
28507     fi
28508   else
28509     input_to_shortpath="$new_path"
28510   fi
28511 
28512   # Call helper function which possibly converts this using DOS-style short mode.
28513   # If so, the updated path is stored in $new_path.
28514   new_path="$input_to_shortpath"
28515 
28516   input_path="$input_to_shortpath"
28517   # Check if we need to convert this using DOS-style short mode. If the path
28518   # contains just simple characters, use it. Otherwise (spaces, weird characters),
28519   # take no chances and rewrite it.
28520   # Note: m4 eats our [], so we need to use [ and ] instead.
28521   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
28522   if test "x$has_forbidden_chars" != x; then
28523     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28524     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
28525     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
28526     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
28527       # Going to short mode and back again did indeed matter. Since short mode is
28528       # case insensitive, let's make it lowercase to improve readability.
28529       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28530       # Now convert it back to Unix-stile (cygpath)
28531       input_path=`$CYGPATH -u "$shortmode_path"`
28532       new_path="$input_path"
28533     fi
28534   fi
28535 
28536   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
28537   if test "x$test_cygdrive_prefix" = x; then
28538     # As a simple fix, exclude /usr/bin since it's not a real path.
28539     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
28540       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
28541       # a path prefixed by /cygdrive for fixpath to work.
28542       new_path="$CYGWIN_ROOT_PATH$input_path"
28543     fi
28544   fi
28545 
28546   # remove trailing .exe if any
28547   new_path="${new_path/%.exe/}"
28548 
28549   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28550 
28551   # First separate the path from the arguments. This will split at the first
28552   # space.
28553   complete="$BUILD_CXX"
28554   path="${complete%% *}"
28555   tmp="$complete EOL"
28556   arguments="${tmp#* }"
28557 
28558   # Input might be given as Windows format, start by converting to
28559   # unix format.
28560   new_path="$path"
28561 
28562   windows_path="$new_path"
28563   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28564     unix_path=`$CYGPATH -u "$windows_path"`
28565     new_path="$unix_path"
28566   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28567     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28568     new_path="$unix_path"
28569   fi
28570 
28571 
28572   # Now try to locate executable using which
28573   new_path=`$WHICH "$new_path" 2> /dev/null`
28574 
28575   if test "x$new_path" = x; then
28576     # Oops. Which didn't find the executable.
28577     # The splitting of arguments from the executable at a space might have been incorrect,
28578     # since paths with space are more likely in Windows. Give it another try with the whole
28579     # argument.
28580     path="$complete"
28581     arguments="EOL"
28582     new_path="$path"
28583 
28584   windows_path="$new_path"
28585   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28586     unix_path=`$CYGPATH -u "$windows_path"`
28587     new_path="$unix_path"
28588   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28589     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28590     new_path="$unix_path"
28591   fi
28592 
28593 
28594     new_path=`$WHICH "$new_path" 2> /dev/null`
28595 
28596     if test "x$new_path" = x; then
28597       # It's still not found. Now this is an unrecoverable error.
28598       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
28599 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
28600       has_space=`$ECHO "$complete" | $GREP " "`
28601       if test "x$has_space" != x; then
28602         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
28603 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
28604       fi
28605       as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
28606     fi
28607   fi
28608 
28609   # Now new_path has a complete unix path to the binary
28610   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
28611     # Keep paths in /bin as-is, but remove trailing .exe if any
28612     new_path="${new_path/%.exe/}"
28613     # Do not save /bin paths to all_fixpath_prefixes!
28614   else
28615     # Not in mixed or Windows style, start by that.
28616     new_path=`cmd //c echo $new_path`
28617 
28618   input_path="$new_path"
28619   # Check if we need to convert this using DOS-style short mode. If the path
28620   # contains just simple characters, use it. Otherwise (spaces, weird characters),
28621   # take no chances and rewrite it.
28622   # Note: m4 eats our [], so we need to use [ and ] instead.
28623   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
28624   if test "x$has_forbidden_chars" != x; then
28625     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28626     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28627   fi
28628 
28629     # Output is in $new_path
28630 
28631   windows_path="$new_path"
28632   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28633     unix_path=`$CYGPATH -u "$windows_path"`
28634     new_path="$unix_path"
28635   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28636     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28637     new_path="$unix_path"
28638   fi
28639 
28640     # remove trailing .exe if any
28641     new_path="${new_path/%.exe/}"
28642 
28643     # Save the first 10 bytes of this path to the storage, so fixpath can work.
28644     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
28645   fi
28646 
28647   else
28648     # We're on a posix platform. Hooray! :)
28649     # First separate the path from the arguments. This will split at the first
28650     # space.
28651     complete="$BUILD_CXX"
28652     path="${complete%% *}"
28653     tmp="$complete EOL"
28654     arguments="${tmp#* }"
28655 
28656     # Cannot rely on the command "which" here since it doesn't always work.
28657     is_absolute_path=`$ECHO "$path" | $GREP ^/`
28658     if test -z "$is_absolute_path"; then
28659       # Path to executable is not absolute. Find it.
28660       IFS_save="$IFS"
28661       IFS=:
28662       for p in $PATH; do
28663         if test -f "$p/$path" && test -x "$p/$path"; then
28664           new_path="$p/$path"
28665           break
28666         fi
28667       done
28668       IFS="$IFS_save"
28669     else
28670       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving BUILD_CXX (as $path) failed, using $path directly." >&5
28671 $as_echo "$as_me: Resolving BUILD_CXX (as $path) failed, using $path directly." >&6;}
28672       new_path="$path"
28673     fi
28674 
28675     if test "x$new_path" = x; then
28676       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
28677 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
28678       has_space=`$ECHO "$complete" | $GREP " "`
28679       if test "x$has_space" != x; then
28680         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
28681 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
28682       fi
28683       as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
28684     fi
28685   fi
28686 
28687   # Now join together the path and the arguments once again
28688   if test "x$arguments" != xEOL; then
28689     new_complete="$new_path ${arguments% *}"
28690   else
28691     new_complete="$new_path"
28692   fi
28693 
28694   if test "x$complete" != "x$new_complete"; then
28695     BUILD_CXX="$new_complete"
28696     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CXX to \"$new_complete\"" >&5
28697 $as_echo "$as_me: Rewriting BUILD_CXX to \"$new_complete\"" >&6;}
28698   fi
28699 
28700 
28701 
28702   # Publish this variable in the help.
28703 
28704 
28705   if test "x$BUILD_LD" = x; then
28706     # The variable is not set by user, try to locate tool using the code snippet
28707     for ac_prog in ld
28708 do
28709   # Extract the first word of "$ac_prog", so it can be a program name with args.
28710 set dummy $ac_prog; ac_word=$2
28711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28712 $as_echo_n "checking for $ac_word... " >&6; }
28713 if ${ac_cv_path_BUILD_LD+:} false; then :
28714   $as_echo_n "(cached) " >&6
28715 else
28716   case $BUILD_LD in
28717   [\\/]* | ?:[\\/]*)
28718   ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
28719   ;;
28720   *)
28721   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28722 for as_dir in $PATH
28723 do
28724   IFS=$as_save_IFS
28725   test -z "$as_dir" && as_dir=.
28726     for ac_exec_ext in '' $ac_executable_extensions; do
28727   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28728     ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
28729     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28730     break 2
28731   fi
28732 done
28733   done
28734 IFS=$as_save_IFS
28735 
28736   ;;
28737 esac
28738 fi
28739 BUILD_LD=$ac_cv_path_BUILD_LD
28740 if test -n "$BUILD_LD"; then
28741   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
28742 $as_echo "$BUILD_LD" >&6; }
28743 else
28744   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28745 $as_echo "no" >&6; }
28746 fi
28747 
28748 
28749   test -n "$BUILD_LD" && break
28750 done
28751 
28752   else
28753     # The variable is set, but is it from the command line or the environment?
28754 
28755     # Try to remove the string !BUILD_LD! from our list.
28756     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_LD!/}
28757     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
28758       # If it failed, the variable was not from the command line. Ignore it,
28759       # but warn the user (except for BASH, which is always set by the calling BASH).
28760       if test "xBUILD_LD" != xBASH; then
28761         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_LD from the environment. Use command line variables instead." >&5
28762 $as_echo "$as_me: WARNING: Ignoring value of BUILD_LD from the environment. Use command line variables instead." >&2;}
28763       fi
28764       # Try to locate tool using the code snippet
28765       for ac_prog in ld
28766 do
28767   # Extract the first word of "$ac_prog", so it can be a program name with args.
28768 set dummy $ac_prog; ac_word=$2
28769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28770 $as_echo_n "checking for $ac_word... " >&6; }
28771 if ${ac_cv_path_BUILD_LD+:} false; then :
28772   $as_echo_n "(cached) " >&6
28773 else
28774   case $BUILD_LD in
28775   [\\/]* | ?:[\\/]*)
28776   ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
28777   ;;
28778   *)
28779   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28780 for as_dir in $PATH
28781 do
28782   IFS=$as_save_IFS
28783   test -z "$as_dir" && as_dir=.
28784     for ac_exec_ext in '' $ac_executable_extensions; do
28785   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28786     ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
28787     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28788     break 2
28789   fi
28790 done
28791   done
28792 IFS=$as_save_IFS
28793 
28794   ;;
28795 esac
28796 fi
28797 BUILD_LD=$ac_cv_path_BUILD_LD
28798 if test -n "$BUILD_LD"; then
28799   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
28800 $as_echo "$BUILD_LD" >&6; }
28801 else
28802   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28803 $as_echo "no" >&6; }
28804 fi
28805 
28806 
28807   test -n "$BUILD_LD" && break
28808 done
28809 
28810     else
28811       # If it succeeded, then it was overridden by the user. We will use it
28812       # for the tool.
28813 
28814       # First remove it from the list of overridden variables, so we can test
28815       # for unknown variables in the end.
28816       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
28817 
28818       # Check if the provided tool contains a complete path.
28819       tool_specified="$BUILD_LD"
28820       tool_basename="${tool_specified##*/}"
28821       if test "x$tool_basename" = "x$tool_specified"; then
28822         # A command without a complete path is provided, search $PATH.
28823         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_LD=$tool_basename" >&5
28824 $as_echo "$as_me: Will search for user supplied tool BUILD_LD=$tool_basename" >&6;}
28825         # Extract the first word of "$tool_basename", so it can be a program name with args.
28826 set dummy $tool_basename; ac_word=$2
28827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28828 $as_echo_n "checking for $ac_word... " >&6; }
28829 if ${ac_cv_path_BUILD_LD+:} false; then :
28830   $as_echo_n "(cached) " >&6
28831 else
28832   case $BUILD_LD in
28833   [\\/]* | ?:[\\/]*)
28834   ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
28835   ;;
28836   *)
28837   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28838 for as_dir in $PATH
28839 do
28840   IFS=$as_save_IFS
28841   test -z "$as_dir" && as_dir=.
28842     for ac_exec_ext in '' $ac_executable_extensions; do
28843   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28844     ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
28845     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28846     break 2
28847   fi
28848 done
28849   done
28850 IFS=$as_save_IFS
28851 
28852   ;;
28853 esac
28854 fi
28855 BUILD_LD=$ac_cv_path_BUILD_LD
28856 if test -n "$BUILD_LD"; then
28857   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
28858 $as_echo "$BUILD_LD" >&6; }
28859 else
28860   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28861 $as_echo "no" >&6; }
28862 fi
28863 
28864 
28865         if test "x$BUILD_LD" = x; then
28866           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
28867         fi
28868       else
28869         # Otherwise we believe it is a complete path. Use it as it is.
28870         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_LD=$tool_specified" >&5
28871 $as_echo "$as_me: Will use user supplied tool BUILD_LD=$tool_specified" >&6;}
28872         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_LD" >&5
28873 $as_echo_n "checking for BUILD_LD... " >&6; }
28874         if test ! -x "$tool_specified"; then
28875           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
28876 $as_echo "not found" >&6; }
28877           as_fn_error $? "User supplied tool BUILD_LD=$tool_specified does not exist or is not executable" "$LINENO" 5
28878         fi
28879         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
28880 $as_echo "$tool_specified" >&6; }
28881       fi
28882     fi
28883   fi
28884 
28885 
28886 
28887   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28888 
28889   # First separate the path from the arguments. This will split at the first
28890   # space.
28891   complete="$BUILD_LD"
28892   path="${complete%% *}"
28893   tmp="$complete EOL"
28894   arguments="${tmp#* }"
28895 
28896   # Input might be given as Windows format, start by converting to
28897   # unix format.
28898   new_path=`$CYGPATH -u "$path"`
28899 
28900   # Now try to locate executable using which
28901   new_path=`$WHICH "$new_path" 2> /dev/null`
28902   # bat and cmd files are not always considered executable in cygwin causing which
28903   # to not find them
28904   if test "x$new_path" = x \
28905       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28906       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28907     new_path=`$CYGPATH -u "$path"`
28908   fi
28909   if test "x$new_path" = x; then
28910     # Oops. Which didn't find the executable.
28911     # The splitting of arguments from the executable at a space might have been incorrect,
28912     # since paths with space are more likely in Windows. Give it another try with the whole
28913     # argument.
28914     path="$complete"
28915     arguments="EOL"
28916     new_path=`$CYGPATH -u "$path"`
28917     new_path=`$WHICH "$new_path" 2> /dev/null`
28918     # bat and cmd files are not always considered executable in cygwin causing which
28919     # to not find them
28920     if test "x$new_path" = x \
28921         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28922         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28923       new_path=`$CYGPATH -u "$path"`
28924     fi
28925     if test "x$new_path" = x; then
28926       # It's still not found. Now this is an unrecoverable error.
28927       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
28928 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
28929       has_space=`$ECHO "$complete" | $GREP " "`
28930       if test "x$has_space" != x; then
28931         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
28932 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
28933       fi
28934       as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
28935     fi
28936   fi
28937 
28938   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
28939   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
28940   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
28941   # "foo.exe" is OK but "foo" is an error.
28942   #
28943   # This test is therefore slightly more accurate than "test -f" to check for file presence.
28944   # It is also a way to make sure we got the proper file name for the real test later on.
28945   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
28946   if test "x$test_shortpath" = x; then
28947     # Short path failed, file does not exist as specified.
28948     # Try adding .exe or .cmd
28949     if test -f "${new_path}.exe"; then
28950       input_to_shortpath="${new_path}.exe"
28951     elif test -f "${new_path}.cmd"; then
28952       input_to_shortpath="${new_path}.cmd"
28953     else
28954       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$new_path\", is invalid." >&5
28955 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$new_path\", is invalid." >&6;}
28956       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
28957 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
28958       as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
28959     fi
28960   else
28961     input_to_shortpath="$new_path"
28962   fi
28963 
28964   # Call helper function which possibly converts this using DOS-style short mode.
28965   # If so, the updated path is stored in $new_path.
28966   new_path="$input_to_shortpath"
28967 
28968   input_path="$input_to_shortpath"
28969   # Check if we need to convert this using DOS-style short mode. If the path
28970   # contains just simple characters, use it. Otherwise (spaces, weird characters),
28971   # take no chances and rewrite it.
28972   # Note: m4 eats our [], so we need to use [ and ] instead.
28973   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
28974   if test "x$has_forbidden_chars" != x; then
28975     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28976     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
28977     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
28978     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
28979       # Going to short mode and back again did indeed matter. Since short mode is
28980       # case insensitive, let's make it lowercase to improve readability.
28981       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28982       # Now convert it back to Unix-stile (cygpath)
28983       input_path=`$CYGPATH -u "$shortmode_path"`
28984       new_path="$input_path"
28985     fi
28986   fi
28987 
28988   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
28989   if test "x$test_cygdrive_prefix" = x; then
28990     # As a simple fix, exclude /usr/bin since it's not a real path.
28991     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
28992       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
28993       # a path prefixed by /cygdrive for fixpath to work.
28994       new_path="$CYGWIN_ROOT_PATH$input_path"
28995     fi
28996   fi
28997 
28998   # remove trailing .exe if any
28999   new_path="${new_path/%.exe/}"
29000 
29001   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29002 
29003   # First separate the path from the arguments. This will split at the first
29004   # space.
29005   complete="$BUILD_LD"
29006   path="${complete%% *}"
29007   tmp="$complete EOL"
29008   arguments="${tmp#* }"
29009 
29010   # Input might be given as Windows format, start by converting to
29011   # unix format.
29012   new_path="$path"
29013 
29014   windows_path="$new_path"
29015   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29016     unix_path=`$CYGPATH -u "$windows_path"`
29017     new_path="$unix_path"
29018   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29019     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29020     new_path="$unix_path"
29021   fi
29022 
29023 
29024   # Now try to locate executable using which
29025   new_path=`$WHICH "$new_path" 2> /dev/null`
29026 
29027   if test "x$new_path" = x; then
29028     # Oops. Which didn't find the executable.
29029     # The splitting of arguments from the executable at a space might have been incorrect,
29030     # since paths with space are more likely in Windows. Give it another try with the whole
29031     # argument.
29032     path="$complete"
29033     arguments="EOL"
29034     new_path="$path"
29035 
29036   windows_path="$new_path"
29037   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29038     unix_path=`$CYGPATH -u "$windows_path"`
29039     new_path="$unix_path"
29040   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29041     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29042     new_path="$unix_path"
29043   fi
29044 
29045 
29046     new_path=`$WHICH "$new_path" 2> /dev/null`
29047 
29048     if test "x$new_path" = x; then
29049       # It's still not found. Now this is an unrecoverable error.
29050       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
29051 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
29052       has_space=`$ECHO "$complete" | $GREP " "`
29053       if test "x$has_space" != x; then
29054         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29055 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29056       fi
29057       as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
29058     fi
29059   fi
29060 
29061   # Now new_path has a complete unix path to the binary
29062   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
29063     # Keep paths in /bin as-is, but remove trailing .exe if any
29064     new_path="${new_path/%.exe/}"
29065     # Do not save /bin paths to all_fixpath_prefixes!
29066   else
29067     # Not in mixed or Windows style, start by that.
29068     new_path=`cmd //c echo $new_path`
29069 
29070   input_path="$new_path"
29071   # Check if we need to convert this using DOS-style short mode. If the path
29072   # contains just simple characters, use it. Otherwise (spaces, weird characters),
29073   # take no chances and rewrite it.
29074   # Note: m4 eats our [], so we need to use [ and ] instead.
29075   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
29076   if test "x$has_forbidden_chars" != x; then
29077     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29078     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29079   fi
29080 
29081     # Output is in $new_path
29082 
29083   windows_path="$new_path"
29084   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29085     unix_path=`$CYGPATH -u "$windows_path"`
29086     new_path="$unix_path"
29087   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29088     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29089     new_path="$unix_path"
29090   fi
29091 
29092     # remove trailing .exe if any
29093     new_path="${new_path/%.exe/}"
29094 
29095     # Save the first 10 bytes of this path to the storage, so fixpath can work.
29096     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
29097   fi
29098 
29099   else
29100     # We're on a posix platform. Hooray! :)
29101     # First separate the path from the arguments. This will split at the first
29102     # space.
29103     complete="$BUILD_LD"
29104     path="${complete%% *}"
29105     tmp="$complete EOL"
29106     arguments="${tmp#* }"
29107 
29108     # Cannot rely on the command "which" here since it doesn't always work.
29109     is_absolute_path=`$ECHO "$path" | $GREP ^/`
29110     if test -z "$is_absolute_path"; then
29111       # Path to executable is not absolute. Find it.
29112       IFS_save="$IFS"
29113       IFS=:
29114       for p in $PATH; do
29115         if test -f "$p/$path" && test -x "$p/$path"; then
29116           new_path="$p/$path"
29117           break
29118         fi
29119       done
29120       IFS="$IFS_save"
29121     else
29122       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving BUILD_LD (as $path) failed, using $path directly." >&5
29123 $as_echo "$as_me: Resolving BUILD_LD (as $path) failed, using $path directly." >&6;}
29124       new_path="$path"
29125     fi
29126 
29127     if test "x$new_path" = x; then
29128       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
29129 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
29130       has_space=`$ECHO "$complete" | $GREP " "`
29131       if test "x$has_space" != x; then
29132         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
29133 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
29134       fi
29135       as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
29136     fi
29137   fi
29138 
29139   # Now join together the path and the arguments once again
29140   if test "x$arguments" != xEOL; then
29141     new_complete="$new_path ${arguments% *}"
29142   else
29143     new_complete="$new_path"
29144   fi
29145 
29146   if test "x$complete" != "x$new_complete"; then
29147     BUILD_LD="$new_complete"
29148     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_LD to \"$new_complete\"" >&5
29149 $as_echo "$as_me: Rewriting BUILD_LD to \"$new_complete\"" >&6;}
29150   fi
29151 
29152   fi
29153 
29154 
29155 
29156 
29157   # If a devkit is found on the builddeps server, then prepend its path to the
29158   # PATH variable. If there are cross compilers available in the devkit, these
29159   # will be found by AC_PROG_CC et al.
29160   DEVKIT=
29161 
29162 
29163   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
29164     # Source the builddeps file again, to make sure it uses the latest variables!
29165     . $builddepsfile
29166     # Look for a target and build machine specific resource!
29167     eval resource=\${builddep_devkit_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
29168     if test "x$resource" = x; then
29169       # Ok, lets instead look for a target specific resource
29170       eval resource=\${builddep_devkit_TARGET_${rewritten_target_var}}
29171     fi
29172     if test "x$resource" = x; then
29173       # Ok, lets instead look for a build specific resource
29174       eval resource=\${builddep_devkit_BUILD_${rewritten_build_var}}
29175     fi
29176     if test "x$resource" = x; then
29177       # Ok, lets instead look for a generic resource
29178       # (The devkit comes from M4 and not the shell, thus no need for eval here.)
29179       resource=${builddep_devkit}
29180     fi
29181     if test "x$resource" != x; then
29182       { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for devkit" >&5
29183 $as_echo "$as_me: Using builddeps $resource for devkit" >&6;}
29184       # If the resource in the builddeps.conf file is an existing directory,
29185       # for example /java/linux/cups
29186       if test -d ${resource}; then
29187         depdir=${resource}
29188       else
29189 
29190   # devkit is for example mymodule
29191   # $resource is for example libs/general/libmymod_1_2_3.zip
29192   # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
29193   # $with_builddeps_dir is for example /localhome/builddeps
29194   # depdir is the name of the variable into which we store the depdir, eg MYMOD
29195   # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
29196   # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
29197   filename=`basename $resource`
29198   filebase=`echo $filename | sed 's/\.[^\.]*$//'`
29199   filebase=${filename%%.*}
29200   extension=${filename#*.}
29201   installdir=$with_builddeps_dir/$filebase
29202   if test ! -f $installdir/$filename.unpacked; then
29203     { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency devkit from $with_builddeps_server/$resource and installing into $installdir" >&5
29204 $as_echo "$as_me: Downloading build dependency devkit from $with_builddeps_server/$resource and installing into $installdir" >&6;}
29205     if test ! -d $installdir; then
29206       mkdir -p $installdir
29207     fi
29208     if test ! -d $installdir; then
29209       as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
29210     fi
29211     tmpfile=`mktemp $installdir/devkit.XXXXXXXXX`
29212     touch $tmpfile
29213     if test ! -f $tmpfile; then
29214       as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
29215     fi
29216 
29217   # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
29218   # $tmpfile is the local file name for the downloaded file.
29219   VALID_TOOL=no
29220   if test "x$BDEPS_FTP" = xwget; then
29221     VALID_TOOL=yes
29222     wget -O $tmpfile $with_builddeps_server/$resource
29223   fi
29224   if test "x$BDEPS_FTP" = xlftp; then
29225     VALID_TOOL=yes
29226     lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
29227   fi
29228   if test "x$BDEPS_FTP" = xftp; then
29229     VALID_TOOL=yes
29230     FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
29231     FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
29232     FTPUSERPWD=${FTPSERVER%%@*}
29233     if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
29234       FTPUSER=${userpwd%%:*}
29235       FTPPWD=${userpwd#*@}
29236       FTPSERVER=${FTPSERVER#*@}
29237     else
29238       FTPUSER=ftp
29239       FTPPWD=ftp
29240     fi
29241     # the "pass" command does not work on some
29242     # ftp clients (read ftp.exe) but if it works,
29243     # passive mode is better!
29244     ( \
29245         echo "user $FTPUSER $FTPPWD"        ; \
29246         echo "pass"                         ; \
29247         echo "bin"                          ; \
29248         echo "get $FTPPATH $tmpfile"              ; \
29249     ) | ftp -in $FTPSERVER
29250   fi
29251   if test "x$VALID_TOOL" != xyes; then
29252     as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
29253   fi
29254 
29255     mv $tmpfile $installdir/$filename
29256     if test ! -s $installdir/$filename; then
29257       as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
29258     fi
29259     case "$extension" in
29260       zip)  echo "Unzipping $installdir/$filename..."
29261         (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
29262         ;;
29263       tar.gz) echo "Untaring $installdir/$filename..."
29264         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
29265         ;;
29266       tgz) echo "Untaring $installdir/$filename..."
29267         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
29268         ;;
29269       *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
29270         ;;
29271     esac
29272   fi
29273   if test -f $installdir/$filename.unpacked; then
29274     depdir=$installdir
29275   fi
29276 
29277       fi
29278       # Source the builddeps file again, because in the previous command, the depdir
29279       # was updated to point at the current build dependency install directory.
29280       . $builddepsfile
29281       # Now extract variables from the builddeps.conf files.
29282       theroot=${builddep_devkit_ROOT}
29283       thecflags=${builddep_devkit_CFLAGS}
29284       thelibs=${builddep_devkit_LIBS}
29285       if test "x$depdir" = x; then
29286         as_fn_error $? "Could not download build dependency devkit" "$LINENO" 5
29287       fi
29288       DEVKIT=$depdir
29289       if test "x$theroot" != x; then
29290         DEVKIT="$theroot"
29291       fi
29292       if test "x$thecflags" != x; then
29293         DEVKIT_CFLAGS="$thecflags"
29294       fi
29295       if test "x$thelibs" != x; then
29296         DEVKIT_LIBS="$thelibs"
29297       fi
29298 
29299         # Found devkit
29300         PATH="$DEVKIT/bin:$PATH"
29301         SYS_ROOT="$DEVKIT/${rewritten_target}/sys-root"
29302         if test "x$x_includes" = "xNONE"; then
29303           x_includes="$SYS_ROOT/usr/include/X11"
29304         fi
29305         if test "x$x_libraries" = "xNONE"; then
29306           x_libraries="$SYS_ROOT/usr/lib"
29307         fi
29308 
29309 
29310     fi
29311 
29312   fi
29313 
29314 
29315   # Store the CFLAGS etal passed to the configure script.
29316   ORG_CFLAGS="$CFLAGS"
29317   ORG_CXXFLAGS="$CXXFLAGS"
29318   ORG_OBJCFLAGS="$OBJCFLAGS"
29319 
29320   # autoconf magic only relies on PATH, so update it if tools dir is specified
29321   OLD_PATH="$PATH"
29322   if test "x$TOOLS_DIR" != x; then
29323     PATH=$TOOLS_DIR:$PATH
29324   fi
29325 
29326 
29327   ### Locate C compiler (CC)
29328 
29329   # On windows, only cl.exe is supported.
29330   # On Solaris, cc is preferred to gcc.
29331   # Elsewhere, gcc is preferred to cc.
29332 
29333   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
29334     COMPILER_CHECK_LIST="cl"
29335   elif test "x$OPENJDK_TARGET_OS" = "xsolaris"; then
29336     COMPILER_CHECK_LIST="cc gcc"
29337   elif test "x$OPENJDK_TARGET_OS" = "xaix"; then
29338     # Do not probe for cc on AIX.
29339     COMPILER_CHECK_LIST="xlc_r"
29340   else
29341     COMPILER_CHECK_LIST="gcc cc"
29342   fi
29343 
29344 
29345   COMPILER_NAME=C
29346   SEARCH_LIST="$COMPILER_CHECK_LIST"
29347 
29348   if test "x$CC" != x; then
29349     # User has supplied compiler name already, always let that override.
29350     { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CC=$CC" >&5
29351 $as_echo "$as_me: Will use user supplied compiler CC=$CC" >&6;}
29352     if test "x`basename $CC`" = "x$CC"; then
29353       # A command without a complete path is provided, search $PATH.
29354 
29355       for ac_prog in $CC
29356 do
29357   # Extract the first word of "$ac_prog", so it can be a program name with args.
29358 set dummy $ac_prog; ac_word=$2
29359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29360 $as_echo_n "checking for $ac_word... " >&6; }
29361 if ${ac_cv_path_POTENTIAL_CC+:} false; then :
29362   $as_echo_n "(cached) " >&6
29363 else
29364   case $POTENTIAL_CC in
29365   [\\/]* | ?:[\\/]*)
29366   ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path.
29367   ;;
29368   *)
29369   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29370 for as_dir in $PATH
29371 do
29372   IFS=$as_save_IFS
29373   test -z "$as_dir" && as_dir=.
29374     for ac_exec_ext in '' $ac_executable_extensions; do
29375   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29376     ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext"
29377     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29378     break 2
29379   fi
29380 done
29381   done
29382 IFS=$as_save_IFS
29383 
29384   ;;
29385 esac
29386 fi
29387 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC
29388 if test -n "$POTENTIAL_CC"; then
29389   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5
29390 $as_echo "$POTENTIAL_CC" >&6; }
29391 else
29392   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29393 $as_echo "no" >&6; }
29394 fi
29395 
29396 
29397   test -n "$POTENTIAL_CC" && break
29398 done
29399 
29400       if test "x$POTENTIAL_CC" != x; then
29401         CC=$POTENTIAL_CC
29402       else
29403         as_fn_error $? "User supplied compiler CC=$CC could not be found" "$LINENO" 5
29404       fi
29405     else
29406       # Otherwise it might already be a complete path
29407       if test ! -x "$CC"; then
29408         as_fn_error $? "User supplied compiler CC=$CC does not exist" "$LINENO" 5
29409       fi
29410     fi
29411   else
29412     # No user supplied value. Locate compiler ourselves
29413     CC=
29414     # If TOOLS_DIR is set, check for all compiler names in there first
29415     # before checking the rest of the PATH.
29416     if test -n "$TOOLS_DIR"; then
29417       PATH_save="$PATH"
29418       PATH="$TOOLS_DIR"
29419       for ac_prog in $SEARCH_LIST
29420 do
29421   # Extract the first word of "$ac_prog", so it can be a program name with args.
29422 set dummy $ac_prog; ac_word=$2
29423 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29424 $as_echo_n "checking for $ac_word... " >&6; }
29425 if ${ac_cv_path_TOOLS_DIR_CC+:} false; then :
29426   $as_echo_n "(cached) " >&6
29427 else
29428   case $TOOLS_DIR_CC in
29429   [\\/]* | ?:[\\/]*)
29430   ac_cv_path_TOOLS_DIR_CC="$TOOLS_DIR_CC" # Let the user override the test with a path.
29431   ;;
29432   *)
29433   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29434 for as_dir in $PATH
29435 do
29436   IFS=$as_save_IFS
29437   test -z "$as_dir" && as_dir=.
29438     for ac_exec_ext in '' $ac_executable_extensions; do
29439   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29440     ac_cv_path_TOOLS_DIR_CC="$as_dir/$ac_word$ac_exec_ext"
29441     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29442     break 2
29443   fi
29444 done
29445   done
29446 IFS=$as_save_IFS
29447 
29448   ;;
29449 esac
29450 fi
29451 TOOLS_DIR_CC=$ac_cv_path_TOOLS_DIR_CC
29452 if test -n "$TOOLS_DIR_CC"; then
29453   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLS_DIR_CC" >&5
29454 $as_echo "$TOOLS_DIR_CC" >&6; }
29455 else
29456   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29457 $as_echo "no" >&6; }
29458 fi
29459 
29460 
29461   test -n "$TOOLS_DIR_CC" && break
29462 done
29463 
29464       CC=$TOOLS_DIR_CC
29465       PATH="$PATH_save"
29466     fi
29467 
29468     # AC_PATH_PROGS can't be run multiple times with the same variable,
29469     # so create a new name for this run.
29470     if test "x$CC" = x; then
29471       for ac_prog in $SEARCH_LIST
29472 do
29473   # Extract the first word of "$ac_prog", so it can be a program name with args.
29474 set dummy $ac_prog; ac_word=$2
29475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29476 $as_echo_n "checking for $ac_word... " >&6; }
29477 if ${ac_cv_path_POTENTIAL_CC+:} false; then :
29478   $as_echo_n "(cached) " >&6
29479 else
29480   case $POTENTIAL_CC in
29481   [\\/]* | ?:[\\/]*)
29482   ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path.
29483   ;;
29484   *)
29485   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29486 for as_dir in $PATH
29487 do
29488   IFS=$as_save_IFS
29489   test -z "$as_dir" && as_dir=.
29490     for ac_exec_ext in '' $ac_executable_extensions; do
29491   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29492     ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext"
29493     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29494     break 2
29495   fi
29496 done
29497   done
29498 IFS=$as_save_IFS
29499 
29500   ;;
29501 esac
29502 fi
29503 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC
29504 if test -n "$POTENTIAL_CC"; then
29505   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5
29506 $as_echo "$POTENTIAL_CC" >&6; }
29507 else
29508   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29509 $as_echo "no" >&6; }
29510 fi
29511 
29512 
29513   test -n "$POTENTIAL_CC" && break
29514 done
29515 
29516       CC=$POTENTIAL_CC
29517     fi
29518 
29519     if test "x$CC" = x; then
29520 
29521   # Print a helpful message on how to acquire the necessary build dependency.
29522   # devkit is the help tag: freetype, cups, pulse, alsa etc
29523   MISSING_DEPENDENCY=devkit
29524 
29525   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29526     cygwin_help $MISSING_DEPENDENCY
29527   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29528     msys_help $MISSING_DEPENDENCY
29529   else
29530     PKGHANDLER_COMMAND=
29531 
29532     case $PKGHANDLER in
29533       apt-get)
29534         apt_help     $MISSING_DEPENDENCY ;;
29535       yum)
29536         yum_help     $MISSING_DEPENDENCY ;;
29537       port)
29538         port_help    $MISSING_DEPENDENCY ;;
29539       pkgutil)
29540         pkgutil_help $MISSING_DEPENDENCY ;;
29541       pkgadd)
29542         pkgadd_help  $MISSING_DEPENDENCY ;;
29543     esac
29544 
29545     if test "x$PKGHANDLER_COMMAND" != x; then
29546       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
29547     fi
29548   fi
29549 
29550       as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5
29551     fi
29552   fi
29553 
29554   # Now we have a compiler binary in CC. Make sure it's okay.
29555 
29556   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29557 
29558   # First separate the path from the arguments. This will split at the first
29559   # space.
29560   complete="$CC"
29561   path="${complete%% *}"
29562   tmp="$complete EOL"
29563   arguments="${tmp#* }"
29564 
29565   # Input might be given as Windows format, start by converting to
29566   # unix format.
29567   new_path=`$CYGPATH -u "$path"`
29568 
29569   # Now try to locate executable using which
29570   new_path=`$WHICH "$new_path" 2> /dev/null`
29571   # bat and cmd files are not always considered executable in cygwin causing which
29572   # to not find them
29573   if test "x$new_path" = x \
29574       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29575       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29576     new_path=`$CYGPATH -u "$path"`
29577   fi
29578   if test "x$new_path" = x; then
29579     # Oops. Which didn't find the executable.
29580     # The splitting of arguments from the executable at a space might have been incorrect,
29581     # since paths with space are more likely in Windows. Give it another try with the whole
29582     # argument.
29583     path="$complete"
29584     arguments="EOL"
29585     new_path=`$CYGPATH -u "$path"`
29586     new_path=`$WHICH "$new_path" 2> /dev/null`
29587     # bat and cmd files are not always considered executable in cygwin causing which
29588     # to not find them
29589     if test "x$new_path" = x \
29590         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29591         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29592       new_path=`$CYGPATH -u "$path"`
29593     fi
29594     if test "x$new_path" = x; then
29595       # It's still not found. Now this is an unrecoverable error.
29596       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
29597 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
29598       has_space=`$ECHO "$complete" | $GREP " "`
29599       if test "x$has_space" != x; then
29600         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29601 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29602       fi
29603       as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
29604     fi
29605   fi
29606 
29607   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
29608   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
29609   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
29610   # "foo.exe" is OK but "foo" is an error.
29611   #
29612   # This test is therefore slightly more accurate than "test -f" to check for file presence.
29613   # It is also a way to make sure we got the proper file name for the real test later on.
29614   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
29615   if test "x$test_shortpath" = x; then
29616     # Short path failed, file does not exist as specified.
29617     # Try adding .exe or .cmd
29618     if test -f "${new_path}.exe"; then
29619       input_to_shortpath="${new_path}.exe"
29620     elif test -f "${new_path}.cmd"; then
29621       input_to_shortpath="${new_path}.cmd"
29622     else
29623       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$new_path\", is invalid." >&5
29624 $as_echo "$as_me: The path of CC, which resolves as \"$new_path\", is invalid." >&6;}
29625       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
29626 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
29627       as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
29628     fi
29629   else
29630     input_to_shortpath="$new_path"
29631   fi
29632 
29633   # Call helper function which possibly converts this using DOS-style short mode.
29634   # If so, the updated path is stored in $new_path.
29635   new_path="$input_to_shortpath"
29636 
29637   input_path="$input_to_shortpath"
29638   # Check if we need to convert this using DOS-style short mode. If the path
29639   # contains just simple characters, use it. Otherwise (spaces, weird characters),
29640   # take no chances and rewrite it.
29641   # Note: m4 eats our [], so we need to use [ and ] instead.
29642   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
29643   if test "x$has_forbidden_chars" != x; then
29644     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29645     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
29646     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
29647     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
29648       # Going to short mode and back again did indeed matter. Since short mode is
29649       # case insensitive, let's make it lowercase to improve readability.
29650       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29651       # Now convert it back to Unix-stile (cygpath)
29652       input_path=`$CYGPATH -u "$shortmode_path"`
29653       new_path="$input_path"
29654     fi
29655   fi
29656 
29657   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
29658   if test "x$test_cygdrive_prefix" = x; then
29659     # As a simple fix, exclude /usr/bin since it's not a real path.
29660     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
29661       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
29662       # a path prefixed by /cygdrive for fixpath to work.
29663       new_path="$CYGWIN_ROOT_PATH$input_path"
29664     fi
29665   fi
29666 
29667   # remove trailing .exe if any
29668   new_path="${new_path/%.exe/}"
29669 
29670   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29671 
29672   # First separate the path from the arguments. This will split at the first
29673   # space.
29674   complete="$CC"
29675   path="${complete%% *}"
29676   tmp="$complete EOL"
29677   arguments="${tmp#* }"
29678 
29679   # Input might be given as Windows format, start by converting to
29680   # unix format.
29681   new_path="$path"
29682 
29683   windows_path="$new_path"
29684   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29685     unix_path=`$CYGPATH -u "$windows_path"`
29686     new_path="$unix_path"
29687   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29688     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29689     new_path="$unix_path"
29690   fi
29691 
29692 
29693   # Now try to locate executable using which
29694   new_path=`$WHICH "$new_path" 2> /dev/null`
29695 
29696   if test "x$new_path" = x; then
29697     # Oops. Which didn't find the executable.
29698     # The splitting of arguments from the executable at a space might have been incorrect,
29699     # since paths with space are more likely in Windows. Give it another try with the whole
29700     # argument.
29701     path="$complete"
29702     arguments="EOL"
29703     new_path="$path"
29704 
29705   windows_path="$new_path"
29706   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29707     unix_path=`$CYGPATH -u "$windows_path"`
29708     new_path="$unix_path"
29709   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29710     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29711     new_path="$unix_path"
29712   fi
29713 
29714 
29715     new_path=`$WHICH "$new_path" 2> /dev/null`
29716 
29717     if test "x$new_path" = x; then
29718       # It's still not found. Now this is an unrecoverable error.
29719       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
29720 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
29721       has_space=`$ECHO "$complete" | $GREP " "`
29722       if test "x$has_space" != x; then
29723         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29724 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29725       fi
29726       as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
29727     fi
29728   fi
29729 
29730   # Now new_path has a complete unix path to the binary
29731   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
29732     # Keep paths in /bin as-is, but remove trailing .exe if any
29733     new_path="${new_path/%.exe/}"
29734     # Do not save /bin paths to all_fixpath_prefixes!
29735   else
29736     # Not in mixed or Windows style, start by that.
29737     new_path=`cmd //c echo $new_path`
29738 
29739   input_path="$new_path"
29740   # Check if we need to convert this using DOS-style short mode. If the path
29741   # contains just simple characters, use it. Otherwise (spaces, weird characters),
29742   # take no chances and rewrite it.
29743   # Note: m4 eats our [], so we need to use [ and ] instead.
29744   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
29745   if test "x$has_forbidden_chars" != x; then
29746     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29747     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29748   fi
29749 
29750     # Output is in $new_path
29751 
29752   windows_path="$new_path"
29753   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29754     unix_path=`$CYGPATH -u "$windows_path"`
29755     new_path="$unix_path"
29756   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29757     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29758     new_path="$unix_path"
29759   fi
29760 
29761     # remove trailing .exe if any
29762     new_path="${new_path/%.exe/}"
29763 
29764     # Save the first 10 bytes of this path to the storage, so fixpath can work.
29765     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
29766   fi
29767 
29768   else
29769     # We're on a posix platform. Hooray! :)
29770     # First separate the path from the arguments. This will split at the first
29771     # space.
29772     complete="$CC"
29773     path="${complete%% *}"
29774     tmp="$complete EOL"
29775     arguments="${tmp#* }"
29776 
29777     # Cannot rely on the command "which" here since it doesn't always work.
29778     is_absolute_path=`$ECHO "$path" | $GREP ^/`
29779     if test -z "$is_absolute_path"; then
29780       # Path to executable is not absolute. Find it.
29781       IFS_save="$IFS"
29782       IFS=:
29783       for p in $PATH; do
29784         if test -f "$p/$path" && test -x "$p/$path"; then
29785           new_path="$p/$path"
29786           break
29787         fi
29788       done
29789       IFS="$IFS_save"
29790     else
29791       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving CC (as $path) failed, using $path directly." >&5
29792 $as_echo "$as_me: Resolving CC (as $path) failed, using $path directly." >&6;}
29793       new_path="$path"
29794     fi
29795 
29796     if test "x$new_path" = x; then
29797       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
29798 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
29799       has_space=`$ECHO "$complete" | $GREP " "`
29800       if test "x$has_space" != x; then
29801         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
29802 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
29803       fi
29804       as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
29805     fi
29806   fi
29807 
29808   # Now join together the path and the arguments once again
29809   if test "x$arguments" != xEOL; then
29810     new_complete="$new_path ${arguments% *}"
29811   else
29812     new_complete="$new_path"
29813   fi
29814 
29815   if test "x$complete" != "x$new_complete"; then
29816     CC="$new_complete"
29817     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CC to \"$new_complete\"" >&5
29818 $as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;}
29819   fi
29820 
29821   TEST_COMPILER="$CC"
29822   # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links
29823   # to 'xlc' but it is crucial that we invoke the compiler with the right name!
29824   if test "x$OPENJDK_BUILD_OS" != xaix; then
29825     { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5
29826 $as_echo_n "checking resolved symbolic links for CC... " >&6; }
29827 
29828   if test "x$OPENJDK_BUILD_OS" != xwindows; then
29829     # Follow a chain of symbolic links. Use readlink
29830     # where it exists, else fall back to horribly
29831     # complicated shell code.
29832     if test "x$READLINK_TESTED" != yes; then
29833       # On MacOSX there is a readlink tool with a different
29834       # purpose than the GNU readlink tool. Check the found readlink.
29835       ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
29836       if test "x$ISGNU" = x; then
29837         # A readlink that we do not know how to use.
29838         # Are there other non-GNU readlinks out there?
29839         READLINK_TESTED=yes
29840         READLINK=
29841       fi
29842     fi
29843 
29844     if test "x$READLINK" != x; then
29845       TEST_COMPILER=`$READLINK -f $TEST_COMPILER`
29846     else
29847       # Save the current directory for restoring afterwards
29848       STARTDIR=$PWD
29849       COUNTER=0
29850       sym_link_dir=`$DIRNAME $TEST_COMPILER`
29851       sym_link_file=`$BASENAME $TEST_COMPILER`
29852       cd $sym_link_dir
29853       # Use -P flag to resolve symlinks in directories.
29854       cd `$THEPWDCMD -P`
29855       sym_link_dir=`$THEPWDCMD -P`
29856       # Resolve file symlinks
29857       while test $COUNTER -lt 20; do
29858         ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
29859         if test "x$ISLINK" == x; then
29860           # This is not a symbolic link! We are done!
29861           break
29862         fi
29863         # Again resolve directory symlinks since the target of the just found
29864         # link could be in a different directory
29865         cd `$DIRNAME $ISLINK`
29866         sym_link_dir=`$THEPWDCMD -P`
29867         sym_link_file=`$BASENAME $ISLINK`
29868         let COUNTER=COUNTER+1
29869       done
29870       cd $STARTDIR
29871       TEST_COMPILER=$sym_link_dir/$sym_link_file
29872     fi
29873   fi
29874 
29875     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5
29876 $as_echo "$TEST_COMPILER" >&6; }
29877   fi
29878   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CC is disguised ccache" >&5
29879 $as_echo_n "checking if CC is disguised ccache... " >&6; }
29880 
29881   COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"`
29882   if test "x$COMPILER_BASENAME" = "xccache"; then
29883     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5
29884 $as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; }
29885     # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache.
29886     # We want to control ccache invocation ourselves, so ignore this cc and try
29887     # searching again.
29888 
29889     # Remove the path to the fake ccache cc from the PATH
29890     RETRY_COMPILER_SAVED_PATH="$PATH"
29891     COMPILER_DIRNAME=`$DIRNAME $CC`
29892     PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`"
29893 
29894     # Try again looking for our compiler
29895     if test -n "$ac_tool_prefix"; then
29896   for ac_prog in $COMPILER_CHECK_LIST
29897   do
29898     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
29899 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
29900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29901 $as_echo_n "checking for $ac_word... " >&6; }
29902 if ${ac_cv_prog_PROPER_COMPILER_CC+:} false; then :
29903   $as_echo_n "(cached) " >&6
29904 else
29905   if test -n "$PROPER_COMPILER_CC"; then
29906   ac_cv_prog_PROPER_COMPILER_CC="$PROPER_COMPILER_CC" # Let the user override the test.
29907 else
29908 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29909 for as_dir in $PATH
29910 do
29911   IFS=$as_save_IFS
29912   test -z "$as_dir" && as_dir=.
29913     for ac_exec_ext in '' $ac_executable_extensions; do
29914   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29915     ac_cv_prog_PROPER_COMPILER_CC="$ac_tool_prefix$ac_prog"
29916     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29917     break 2
29918   fi
29919 done
29920   done
29921 IFS=$as_save_IFS
29922 
29923 fi
29924 fi
29925 PROPER_COMPILER_CC=$ac_cv_prog_PROPER_COMPILER_CC
29926 if test -n "$PROPER_COMPILER_CC"; then
29927   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5
29928 $as_echo "$PROPER_COMPILER_CC" >&6; }
29929 else
29930   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29931 $as_echo "no" >&6; }
29932 fi
29933 
29934 
29935     test -n "$PROPER_COMPILER_CC" && break
29936   done
29937 fi
29938 if test -z "$PROPER_COMPILER_CC"; then
29939   ac_ct_PROPER_COMPILER_CC=$PROPER_COMPILER_CC
29940   for ac_prog in $COMPILER_CHECK_LIST
29941 do
29942   # Extract the first word of "$ac_prog", so it can be a program name with args.
29943 set dummy $ac_prog; ac_word=$2
29944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29945 $as_echo_n "checking for $ac_word... " >&6; }
29946 if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CC+:} false; then :
29947   $as_echo_n "(cached) " >&6
29948 else
29949   if test -n "$ac_ct_PROPER_COMPILER_CC"; then
29950   ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_ct_PROPER_COMPILER_CC" # Let the user override the test.
29951 else
29952 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29953 for as_dir in $PATH
29954 do
29955   IFS=$as_save_IFS
29956   test -z "$as_dir" && as_dir=.
29957     for ac_exec_ext in '' $ac_executable_extensions; do
29958   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29959     ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_prog"
29960     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29961     break 2
29962   fi
29963 done
29964   done
29965 IFS=$as_save_IFS
29966 
29967 fi
29968 fi
29969 ac_ct_PROPER_COMPILER_CC=$ac_cv_prog_ac_ct_PROPER_COMPILER_CC
29970 if test -n "$ac_ct_PROPER_COMPILER_CC"; then
29971   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CC" >&5
29972 $as_echo "$ac_ct_PROPER_COMPILER_CC" >&6; }
29973 else
29974   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29975 $as_echo "no" >&6; }
29976 fi
29977 
29978 
29979   test -n "$ac_ct_PROPER_COMPILER_CC" && break
29980 done
29981 
29982   if test "x$ac_ct_PROPER_COMPILER_CC" = x; then
29983     PROPER_COMPILER_CC=""
29984   else
29985     case $cross_compiling:$ac_tool_warned in
29986 yes:)
29987 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
29988 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
29989 ac_tool_warned=yes ;;
29990 esac
29991     PROPER_COMPILER_CC=$ac_ct_PROPER_COMPILER_CC
29992   fi
29993 fi
29994 
29995 
29996   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29997 
29998   # First separate the path from the arguments. This will split at the first
29999   # space.
30000   complete="$PROPER_COMPILER_CC"
30001   path="${complete%% *}"
30002   tmp="$complete EOL"
30003   arguments="${tmp#* }"
30004 
30005   # Input might be given as Windows format, start by converting to
30006   # unix format.
30007   new_path=`$CYGPATH -u "$path"`
30008 
30009   # Now try to locate executable using which
30010   new_path=`$WHICH "$new_path" 2> /dev/null`
30011   # bat and cmd files are not always considered executable in cygwin causing which
30012   # to not find them
30013   if test "x$new_path" = x \
30014       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
30015       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
30016     new_path=`$CYGPATH -u "$path"`
30017   fi
30018   if test "x$new_path" = x; then
30019     # Oops. Which didn't find the executable.
30020     # The splitting of arguments from the executable at a space might have been incorrect,
30021     # since paths with space are more likely in Windows. Give it another try with the whole
30022     # argument.
30023     path="$complete"
30024     arguments="EOL"
30025     new_path=`$CYGPATH -u "$path"`
30026     new_path=`$WHICH "$new_path" 2> /dev/null`
30027     # bat and cmd files are not always considered executable in cygwin causing which
30028     # to not find them
30029     if test "x$new_path" = x \
30030         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
30031         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
30032       new_path=`$CYGPATH -u "$path"`
30033     fi
30034     if test "x$new_path" = x; then
30035       # It's still not found. Now this is an unrecoverable error.
30036       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
30037 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
30038       has_space=`$ECHO "$complete" | $GREP " "`
30039       if test "x$has_space" != x; then
30040         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
30041 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
30042       fi
30043       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
30044     fi
30045   fi
30046 
30047   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
30048   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
30049   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
30050   # "foo.exe" is OK but "foo" is an error.
30051   #
30052   # This test is therefore slightly more accurate than "test -f" to check for file presence.
30053   # It is also a way to make sure we got the proper file name for the real test later on.
30054   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
30055   if test "x$test_shortpath" = x; then
30056     # Short path failed, file does not exist as specified.
30057     # Try adding .exe or .cmd
30058     if test -f "${new_path}.exe"; then
30059       input_to_shortpath="${new_path}.exe"
30060     elif test -f "${new_path}.cmd"; then
30061       input_to_shortpath="${new_path}.cmd"
30062     else
30063       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&5
30064 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&6;}
30065       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
30066 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
30067       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
30068     fi
30069   else
30070     input_to_shortpath="$new_path"
30071   fi
30072 
30073   # Call helper function which possibly converts this using DOS-style short mode.
30074   # If so, the updated path is stored in $new_path.
30075   new_path="$input_to_shortpath"
30076 
30077   input_path="$input_to_shortpath"
30078   # Check if we need to convert this using DOS-style short mode. If the path
30079   # contains just simple characters, use it. Otherwise (spaces, weird characters),
30080   # take no chances and rewrite it.
30081   # Note: m4 eats our [], so we need to use [ and ] instead.
30082   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
30083   if test "x$has_forbidden_chars" != x; then
30084     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
30085     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
30086     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
30087     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
30088       # Going to short mode and back again did indeed matter. Since short mode is
30089       # case insensitive, let's make it lowercase to improve readability.
30090       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
30091       # Now convert it back to Unix-stile (cygpath)
30092       input_path=`$CYGPATH -u "$shortmode_path"`
30093       new_path="$input_path"
30094     fi
30095   fi
30096 
30097   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
30098   if test "x$test_cygdrive_prefix" = x; then
30099     # As a simple fix, exclude /usr/bin since it's not a real path.
30100     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
30101       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
30102       # a path prefixed by /cygdrive for fixpath to work.
30103       new_path="$CYGWIN_ROOT_PATH$input_path"
30104     fi
30105   fi
30106 
30107   # remove trailing .exe if any
30108   new_path="${new_path/%.exe/}"
30109 
30110   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30111 
30112   # First separate the path from the arguments. This will split at the first
30113   # space.
30114   complete="$PROPER_COMPILER_CC"
30115   path="${complete%% *}"
30116   tmp="$complete EOL"
30117   arguments="${tmp#* }"
30118 
30119   # Input might be given as Windows format, start by converting to
30120   # unix format.
30121   new_path="$path"
30122 
30123   windows_path="$new_path"
30124   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30125     unix_path=`$CYGPATH -u "$windows_path"`
30126     new_path="$unix_path"
30127   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30128     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30129     new_path="$unix_path"
30130   fi
30131 
30132 
30133   # Now try to locate executable using which
30134   new_path=`$WHICH "$new_path" 2> /dev/null`
30135 
30136   if test "x$new_path" = x; then
30137     # Oops. Which didn't find the executable.
30138     # The splitting of arguments from the executable at a space might have been incorrect,
30139     # since paths with space are more likely in Windows. Give it another try with the whole
30140     # argument.
30141     path="$complete"
30142     arguments="EOL"
30143     new_path="$path"
30144 
30145   windows_path="$new_path"
30146   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30147     unix_path=`$CYGPATH -u "$windows_path"`
30148     new_path="$unix_path"
30149   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30150     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30151     new_path="$unix_path"
30152   fi
30153 
30154 
30155     new_path=`$WHICH "$new_path" 2> /dev/null`
30156 
30157     if test "x$new_path" = x; then
30158       # It's still not found. Now this is an unrecoverable error.
30159       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
30160 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
30161       has_space=`$ECHO "$complete" | $GREP " "`
30162       if test "x$has_space" != x; then
30163         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
30164 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
30165       fi
30166       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
30167     fi
30168   fi
30169 
30170   # Now new_path has a complete unix path to the binary
30171   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
30172     # Keep paths in /bin as-is, but remove trailing .exe if any
30173     new_path="${new_path/%.exe/}"
30174     # Do not save /bin paths to all_fixpath_prefixes!
30175   else
30176     # Not in mixed or Windows style, start by that.
30177     new_path=`cmd //c echo $new_path`
30178 
30179   input_path="$new_path"
30180   # Check if we need to convert this using DOS-style short mode. If the path
30181   # contains just simple characters, use it. Otherwise (spaces, weird characters),
30182   # take no chances and rewrite it.
30183   # Note: m4 eats our [], so we need to use [ and ] instead.
30184   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
30185   if test "x$has_forbidden_chars" != x; then
30186     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
30187     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
30188   fi
30189 
30190     # Output is in $new_path
30191 
30192   windows_path="$new_path"
30193   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30194     unix_path=`$CYGPATH -u "$windows_path"`
30195     new_path="$unix_path"
30196   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30197     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30198     new_path="$unix_path"
30199   fi
30200 
30201     # remove trailing .exe if any
30202     new_path="${new_path/%.exe/}"
30203 
30204     # Save the first 10 bytes of this path to the storage, so fixpath can work.
30205     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
30206   fi
30207 
30208   else
30209     # We're on a posix platform. Hooray! :)
30210     # First separate the path from the arguments. This will split at the first
30211     # space.
30212     complete="$PROPER_COMPILER_CC"
30213     path="${complete%% *}"
30214     tmp="$complete EOL"
30215     arguments="${tmp#* }"
30216 
30217     # Cannot rely on the command "which" here since it doesn't always work.
30218     is_absolute_path=`$ECHO "$path" | $GREP ^/`
30219     if test -z "$is_absolute_path"; then
30220       # Path to executable is not absolute. Find it.
30221       IFS_save="$IFS"
30222       IFS=:
30223       for p in $PATH; do
30224         if test -f "$p/$path" && test -x "$p/$path"; then
30225           new_path="$p/$path"
30226           break
30227         fi
30228       done
30229       IFS="$IFS_save"
30230     else
30231       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving PROPER_COMPILER_CC (as $path) failed, using $path directly." >&5
30232 $as_echo "$as_me: Resolving PROPER_COMPILER_CC (as $path) failed, using $path directly." >&6;}
30233       new_path="$path"
30234     fi
30235 
30236     if test "x$new_path" = x; then
30237       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
30238 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
30239       has_space=`$ECHO "$complete" | $GREP " "`
30240       if test "x$has_space" != x; then
30241         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
30242 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
30243       fi
30244       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
30245     fi
30246   fi
30247 
30248   # Now join together the path and the arguments once again
30249   if test "x$arguments" != xEOL; then
30250     new_complete="$new_path ${arguments% *}"
30251   else
30252     new_complete="$new_path"
30253   fi
30254 
30255   if test "x$complete" != "x$new_complete"; then
30256     PROPER_COMPILER_CC="$new_complete"
30257     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&5
30258 $as_echo "$as_me: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&6;}
30259   fi
30260 
30261     PATH="$RETRY_COMPILER_SAVED_PATH"
30262 
30263     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CC" >&5
30264 $as_echo_n "checking for resolved symbolic links for CC... " >&6; }
30265 
30266   if test "x$OPENJDK_BUILD_OS" != xwindows; then
30267     # Follow a chain of symbolic links. Use readlink
30268     # where it exists, else fall back to horribly
30269     # complicated shell code.
30270     if test "x$READLINK_TESTED" != yes; then
30271       # On MacOSX there is a readlink tool with a different
30272       # purpose than the GNU readlink tool. Check the found readlink.
30273       ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
30274       if test "x$ISGNU" = x; then
30275         # A readlink that we do not know how to use.
30276         # Are there other non-GNU readlinks out there?
30277         READLINK_TESTED=yes
30278         READLINK=
30279       fi
30280     fi
30281 
30282     if test "x$READLINK" != x; then
30283       PROPER_COMPILER_CC=`$READLINK -f $PROPER_COMPILER_CC`
30284     else
30285       # Save the current directory for restoring afterwards
30286       STARTDIR=$PWD
30287       COUNTER=0
30288       sym_link_dir=`$DIRNAME $PROPER_COMPILER_CC`
30289       sym_link_file=`$BASENAME $PROPER_COMPILER_CC`
30290       cd $sym_link_dir
30291       # Use -P flag to resolve symlinks in directories.
30292       cd `$THEPWDCMD -P`
30293       sym_link_dir=`$THEPWDCMD -P`
30294       # Resolve file symlinks
30295       while test $COUNTER -lt 20; do
30296         ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
30297         if test "x$ISLINK" == x; then
30298           # This is not a symbolic link! We are done!
30299           break
30300         fi
30301         # Again resolve directory symlinks since the target of the just found
30302         # link could be in a different directory
30303         cd `$DIRNAME $ISLINK`
30304         sym_link_dir=`$THEPWDCMD -P`
30305         sym_link_file=`$BASENAME $ISLINK`
30306         let COUNTER=COUNTER+1
30307       done
30308       cd $STARTDIR
30309       PROPER_COMPILER_CC=$sym_link_dir/$sym_link_file
30310     fi
30311   fi
30312 
30313     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5
30314 $as_echo "$PROPER_COMPILER_CC" >&6; }
30315     CC="$PROPER_COMPILER_CC"
30316   else
30317     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CC" >&5
30318 $as_echo "no, keeping CC" >&6; }
30319   fi
30320 
30321 
30322   COMPILER=$CC
30323   COMPILER_NAME=$COMPILER_NAME
30324 
30325   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
30326     # Make sure we use the Sun Studio compiler and not gcc on Solaris, which won't work
30327     COMPILER_VERSION_TEST=`$COMPILER -V 2>&1 | $HEAD -n 1`
30328     $ECHO $COMPILER_VERSION_TEST | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null
30329     if test $? -ne 0; then
30330       GCC_VERSION_TEST=`$COMPILER --version 2>&1 | $HEAD -n 1`
30331 
30332       { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required Sun Studio compiler." >&5
30333 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required Sun Studio compiler." >&6;}
30334       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_TEST\" and with --version: \"$GCC_VERSION_TEST\"" >&5
30335 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_TEST\" and with --version: \"$GCC_VERSION_TEST\"" >&6;}
30336       as_fn_error $? "Sun Studio compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30337     else
30338       COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/p"`
30339       COMPILER_VENDOR="Sun Studio"
30340     fi
30341   elif test  "x$OPENJDK_TARGET_OS" = xaix; then
30342       COMPILER_VERSION_TEST=`$COMPILER -qversion  2>&1 | $TAIL -n 1`
30343       $ECHO $COMPILER_VERSION_TEST | $GREP "^Version: " > /dev/null
30344       if test $? -ne 0; then
30345         as_fn_error $? "Failed to detect the compiler version of $COMPILER ...." "$LINENO" 5
30346       else
30347         COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n 's/Version: \(0-90-9\.0-90-9*\).*/\1/p'`
30348         COMPILER_VENDOR='IBM'
30349       fi
30350   elif test  "x$OPENJDK_TARGET_OS" = xwindows; then
30351     # First line typically looks something like:
30352     # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86
30353     COMPILER_VERSION_TEST=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'`
30354     COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.*Version \([1-9][0-9.]*\) .*/\1/p"`
30355     COMPILER_VENDOR="Microsoft CL.EXE"
30356     COMPILER_CPU_TEST=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.* for \(.*\)$/\1/p"`
30357     if test "x$OPENJDK_TARGET_CPU" = "xx86"; then
30358       if test "x$COMPILER_CPU_TEST" != "x80x86"; then
30359         as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"80x86\"." "$LINENO" 5
30360       fi
30361     elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then
30362       if test "x$COMPILER_CPU_TEST" != "xx64"; then
30363         as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5
30364       fi
30365     fi
30366   else
30367     COMPILER_VERSION_TEST=`$COMPILER --version 2>&1 | $HEAD -n 1`
30368     # Check that this is likely to be GCC.
30369     $COMPILER --version 2>&1 | $GREP "Free Software Foundation" > /dev/null
30370     if test $? -ne 0; then
30371       { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required GCC compiler." >&5
30372 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required GCC compiler." >&6;}
30373       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_TEST\"" >&5
30374 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_TEST\"" >&6;}
30375       as_fn_error $? "GCC compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30376     fi
30377 
30378     # First line typically looks something like:
30379     # gcc (Ubuntu/Linaro 4.5.2-8ubuntu4) 4.5.2
30380     COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.* \([1-9][0-9.]*\)/\1/p"`
30381     COMPILER_VENDOR=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^\(.*\) [1-9][0-9.]*/\1/p"`
30382   fi
30383   # This sets CC_VERSION or CXX_VERSION. (This comment is a grep marker)
30384   CC_VERSION="$COMPILER_VERSION"
30385   # This sets CC_VENDOR or CXX_VENDOR. (This comment is a grep marker)
30386   CC_VENDOR="$COMPILER_VENDOR"
30387 
30388   { $as_echo "$as_me:${as_lineno-$LINENO}: Using $COMPILER_VENDOR $COMPILER_NAME compiler version $COMPILER_VERSION (located at $COMPILER)" >&5
30389 $as_echo "$as_me: Using $COMPILER_VENDOR $COMPILER_NAME compiler version $COMPILER_VERSION (located at $COMPILER)" >&6;}
30390 
30391 
30392   # Now that we have resolved CC ourself, let autoconf have its go at it
30393   ac_ext=c
30394 ac_cpp='$CPP $CPPFLAGS'
30395 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30396 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30397 ac_compiler_gnu=$ac_cv_c_compiler_gnu
30398 if test -n "$ac_tool_prefix"; then
30399   for ac_prog in $CC
30400   do
30401     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
30402 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
30403 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
30404 $as_echo_n "checking for $ac_word... " >&6; }
30405 if ${ac_cv_prog_CC+:} false; then :
30406   $as_echo_n "(cached) " >&6
30407 else
30408   if test -n "$CC"; then
30409   ac_cv_prog_CC="$CC" # Let the user override the test.
30410 else
30411 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30412 for as_dir in $PATH
30413 do
30414   IFS=$as_save_IFS
30415   test -z "$as_dir" && as_dir=.
30416     for ac_exec_ext in '' $ac_executable_extensions; do
30417   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
30418     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
30419     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
30420     break 2
30421   fi
30422 done
30423   done
30424 IFS=$as_save_IFS
30425 
30426 fi
30427 fi
30428 CC=$ac_cv_prog_CC
30429 if test -n "$CC"; then
30430   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
30431 $as_echo "$CC" >&6; }
30432 else
30433   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30434 $as_echo "no" >&6; }
30435 fi
30436 
30437 
30438     test -n "$CC" && break
30439   done
30440 fi
30441 if test -z "$CC"; then
30442   ac_ct_CC=$CC
30443   for ac_prog in $CC
30444 do
30445   # Extract the first word of "$ac_prog", so it can be a program name with args.
30446 set dummy $ac_prog; ac_word=$2
30447 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
30448 $as_echo_n "checking for $ac_word... " >&6; }
30449 if ${ac_cv_prog_ac_ct_CC+:} false; then :
30450   $as_echo_n "(cached) " >&6
30451 else
30452   if test -n "$ac_ct_CC"; then
30453   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
30454 else
30455 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30456 for as_dir in $PATH
30457 do
30458   IFS=$as_save_IFS
30459   test -z "$as_dir" && as_dir=.
30460     for ac_exec_ext in '' $ac_executable_extensions; do
30461   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
30462     ac_cv_prog_ac_ct_CC="$ac_prog"
30463     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
30464     break 2
30465   fi
30466 done
30467   done
30468 IFS=$as_save_IFS
30469 
30470 fi
30471 fi
30472 ac_ct_CC=$ac_cv_prog_ac_ct_CC
30473 if test -n "$ac_ct_CC"; then
30474   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
30475 $as_echo "$ac_ct_CC" >&6; }
30476 else
30477   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30478 $as_echo "no" >&6; }
30479 fi
30480 
30481 
30482   test -n "$ac_ct_CC" && break
30483 done
30484 
30485   if test "x$ac_ct_CC" = x; then
30486     CC=""
30487   else
30488     case $cross_compiling:$ac_tool_warned in
30489 yes:)
30490 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
30491 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
30492 ac_tool_warned=yes ;;
30493 esac
30494     CC=$ac_ct_CC
30495   fi
30496 fi
30497 
30498 
30499 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
30500 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
30501 as_fn_error $? "no acceptable C compiler found in \$PATH
30502 See \`config.log' for more details" "$LINENO" 5; }
30503 
30504 # Provide some information about the compiler.
30505 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
30506 set X $ac_compile
30507 ac_compiler=$2
30508 for ac_option in --version -v -V -qversion; do
30509   { { ac_try="$ac_compiler $ac_option >&5"
30510 case "(($ac_try" in
30511   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30512   *) ac_try_echo=$ac_try;;
30513 esac
30514 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
30515 $as_echo "$ac_try_echo"; } >&5
30516   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
30517   ac_status=$?
30518   if test -s conftest.err; then
30519     sed '10a\
30520 ... rest of stderr output deleted ...
30521          10q' conftest.err >conftest.er1
30522     cat conftest.er1 >&5
30523   fi
30524   rm -f conftest.er1 conftest.err
30525   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
30526   test $ac_status = 0; }
30527 done
30528 
30529 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30530 /* end confdefs.h.  */
30531 
30532 int
30533 main ()
30534 {
30535 
30536   ;
30537   return 0;
30538 }
30539 _ACEOF
30540 ac_clean_files_save=$ac_clean_files
30541 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
30542 # Try to create an executable without -o first, disregard a.out.
30543 # It will help us diagnose broken compilers, and finding out an intuition
30544 # of exeext.
30545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
30546 $as_echo_n "checking whether the C compiler works... " >&6; }
30547 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
30548 
30549 # The possible output files:
30550 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
30551 
30552 ac_rmfiles=
30553 for ac_file in $ac_files
30554 do
30555   case $ac_file in
30556     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
30557     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
30558   esac
30559 done
30560 rm -f $ac_rmfiles
30561 
30562 if { { ac_try="$ac_link_default"
30563 case "(($ac_try" in
30564   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30565   *) ac_try_echo=$ac_try;;
30566 esac
30567 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
30568 $as_echo "$ac_try_echo"; } >&5
30569   (eval "$ac_link_default") 2>&5
30570   ac_status=$?
30571   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
30572   test $ac_status = 0; }; then :
30573   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
30574 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
30575 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
30576 # so that the user can short-circuit this test for compilers unknown to
30577 # Autoconf.
30578 for ac_file in $ac_files ''
30579 do
30580   test -f "$ac_file" || continue
30581   case $ac_file in
30582     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
30583         ;;
30584     [ab].out )
30585         # We found the default executable, but exeext='' is most
30586         # certainly right.
30587         break;;
30588     *.* )
30589         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
30590         then :; else
30591            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
30592         fi
30593         # We set ac_cv_exeext here because the later test for it is not
30594         # safe: cross compilers may not add the suffix if given an `-o'
30595         # argument, so we may need to know it at that point already.
30596         # Even if this section looks crufty: it has the advantage of
30597         # actually working.
30598         break;;
30599     * )
30600         break;;
30601   esac
30602 done
30603 test "$ac_cv_exeext" = no && ac_cv_exeext=
30604 
30605 else
30606   ac_file=''
30607 fi
30608 if test -z "$ac_file"; then :
30609   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30610 $as_echo "no" >&6; }
30611 $as_echo "$as_me: failed program was:" >&5
30612 sed 's/^/| /' conftest.$ac_ext >&5
30613 
30614 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
30615 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
30616 as_fn_error 77 "C compiler cannot create executables
30617 See \`config.log' for more details" "$LINENO" 5; }
30618 else
30619   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30620 $as_echo "yes" >&6; }
30621 fi
30622 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
30623 $as_echo_n "checking for C compiler default output file name... " >&6; }
30624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
30625 $as_echo "$ac_file" >&6; }
30626 ac_exeext=$ac_cv_exeext
30627 
30628 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
30629 ac_clean_files=$ac_clean_files_save
30630 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
30631 $as_echo_n "checking for suffix of executables... " >&6; }
30632 if { { ac_try="$ac_link"
30633 case "(($ac_try" in
30634   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30635   *) ac_try_echo=$ac_try;;
30636 esac
30637 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
30638 $as_echo "$ac_try_echo"; } >&5
30639   (eval "$ac_link") 2>&5
30640   ac_status=$?
30641   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
30642   test $ac_status = 0; }; then :
30643   # If both `conftest.exe' and `conftest' are `present' (well, observable)
30644 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
30645 # work properly (i.e., refer to `conftest.exe'), while it won't with
30646 # `rm'.
30647 for ac_file in conftest.exe conftest conftest.*; do
30648   test -f "$ac_file" || continue
30649   case $ac_file in
30650     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
30651     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
30652           break;;
30653     * ) break;;
30654   esac
30655 done
30656 else
30657   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
30658 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
30659 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
30660 See \`config.log' for more details" "$LINENO" 5; }
30661 fi
30662 rm -f conftest conftest$ac_cv_exeext
30663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
30664 $as_echo "$ac_cv_exeext" >&6; }
30665 
30666 rm -f conftest.$ac_ext
30667 EXEEXT=$ac_cv_exeext
30668 ac_exeext=$EXEEXT
30669 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30670 /* end confdefs.h.  */
30671 #include <stdio.h>
30672 int
30673 main ()
30674 {
30675 FILE *f = fopen ("conftest.out", "w");
30676  return ferror (f) || fclose (f) != 0;
30677 
30678   ;
30679   return 0;
30680 }
30681 _ACEOF
30682 ac_clean_files="$ac_clean_files conftest.out"
30683 # Check that the compiler produces executables we can run.  If not, either
30684 # the compiler is broken, or we cross compile.
30685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
30686 $as_echo_n "checking whether we are cross compiling... " >&6; }
30687 if test "$cross_compiling" != yes; then
30688   { { ac_try="$ac_link"
30689 case "(($ac_try" in
30690   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30691   *) ac_try_echo=$ac_try;;
30692 esac
30693 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
30694 $as_echo "$ac_try_echo"; } >&5
30695   (eval "$ac_link") 2>&5
30696   ac_status=$?
30697   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
30698   test $ac_status = 0; }
30699   if { ac_try='./conftest$ac_cv_exeext'
30700   { { case "(($ac_try" in
30701   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30702   *) ac_try_echo=$ac_try;;
30703 esac
30704 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
30705 $as_echo "$ac_try_echo"; } >&5
30706   (eval "$ac_try") 2>&5
30707   ac_status=$?
30708   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
30709   test $ac_status = 0; }; }; then
30710     cross_compiling=no
30711   else
30712     if test "$cross_compiling" = maybe; then
30713         cross_compiling=yes
30714     else
30715         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
30716 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
30717 as_fn_error $? "cannot run C compiled programs.
30718 If you meant to cross compile, use \`--host'.
30719 See \`config.log' for more details" "$LINENO" 5; }
30720     fi
30721   fi
30722 fi
30723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
30724 $as_echo "$cross_compiling" >&6; }
30725 
30726 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
30727 ac_clean_files=$ac_clean_files_save
30728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
30729 $as_echo_n "checking for suffix of object files... " >&6; }
30730 if ${ac_cv_objext+:} false; then :
30731   $as_echo_n "(cached) " >&6
30732 else
30733   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30734 /* end confdefs.h.  */
30735 
30736 int
30737 main ()
30738 {
30739 
30740   ;
30741   return 0;
30742 }
30743 _ACEOF
30744 rm -f conftest.o conftest.obj
30745 if { { ac_try="$ac_compile"
30746 case "(($ac_try" in
30747   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30748   *) ac_try_echo=$ac_try;;
30749 esac
30750 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
30751 $as_echo "$ac_try_echo"; } >&5
30752   (eval "$ac_compile") 2>&5
30753   ac_status=$?
30754   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
30755   test $ac_status = 0; }; then :
30756   for ac_file in conftest.o conftest.obj conftest.*; do
30757   test -f "$ac_file" || continue;
30758   case $ac_file in
30759     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
30760     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
30761        break;;
30762   esac
30763 done
30764 else
30765   $as_echo "$as_me: failed program was:" >&5
30766 sed 's/^/| /' conftest.$ac_ext >&5
30767 
30768 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
30769 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
30770 as_fn_error $? "cannot compute suffix of object files: cannot compile
30771 See \`config.log' for more details" "$LINENO" 5; }
30772 fi
30773 rm -f conftest.$ac_cv_objext conftest.$ac_ext
30774 fi
30775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
30776 $as_echo "$ac_cv_objext" >&6; }
30777 OBJEXT=$ac_cv_objext
30778 ac_objext=$OBJEXT
30779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
30780 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
30781 if ${ac_cv_c_compiler_gnu+:} false; then :
30782   $as_echo_n "(cached) " >&6
30783 else
30784   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30785 /* end confdefs.h.  */
30786 
30787 int
30788 main ()
30789 {
30790 #ifndef __GNUC__
30791        choke me
30792 #endif
30793 
30794   ;
30795   return 0;
30796 }
30797 _ACEOF
30798 if ac_fn_c_try_compile "$LINENO"; then :
30799   ac_compiler_gnu=yes
30800 else
30801   ac_compiler_gnu=no
30802 fi
30803 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30804 ac_cv_c_compiler_gnu=$ac_compiler_gnu
30805 
30806 fi
30807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
30808 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
30809 if test $ac_compiler_gnu = yes; then
30810   GCC=yes
30811 else
30812   GCC=
30813 fi
30814 ac_test_CFLAGS=${CFLAGS+set}
30815 ac_save_CFLAGS=$CFLAGS
30816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
30817 $as_echo_n "checking whether $CC accepts -g... " >&6; }
30818 if ${ac_cv_prog_cc_g+:} false; then :
30819   $as_echo_n "(cached) " >&6
30820 else
30821   ac_save_c_werror_flag=$ac_c_werror_flag
30822    ac_c_werror_flag=yes
30823    ac_cv_prog_cc_g=no
30824    CFLAGS="-g"
30825    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30826 /* end confdefs.h.  */
30827 
30828 int
30829 main ()
30830 {
30831 
30832   ;
30833   return 0;
30834 }
30835 _ACEOF
30836 if ac_fn_c_try_compile "$LINENO"; then :
30837   ac_cv_prog_cc_g=yes
30838 else
30839   CFLAGS=""
30840       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30841 /* end confdefs.h.  */
30842 
30843 int
30844 main ()
30845 {
30846 
30847   ;
30848   return 0;
30849 }
30850 _ACEOF
30851 if ac_fn_c_try_compile "$LINENO"; then :
30852 
30853 else
30854   ac_c_werror_flag=$ac_save_c_werror_flag
30855          CFLAGS="-g"
30856          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30857 /* end confdefs.h.  */
30858 
30859 int
30860 main ()
30861 {
30862 
30863   ;
30864   return 0;
30865 }
30866 _ACEOF
30867 if ac_fn_c_try_compile "$LINENO"; then :
30868   ac_cv_prog_cc_g=yes
30869 fi
30870 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30871 fi
30872 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30873 fi
30874 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30875    ac_c_werror_flag=$ac_save_c_werror_flag
30876 fi
30877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
30878 $as_echo "$ac_cv_prog_cc_g" >&6; }
30879 if test "$ac_test_CFLAGS" = set; then
30880   CFLAGS=$ac_save_CFLAGS
30881 elif test $ac_cv_prog_cc_g = yes; then
30882   if test "$GCC" = yes; then
30883     CFLAGS="-g -O2"
30884   else
30885     CFLAGS="-g"
30886   fi
30887 else
30888   if test "$GCC" = yes; then
30889     CFLAGS="-O2"
30890   else
30891     CFLAGS=
30892   fi
30893 fi
30894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
30895 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
30896 if ${ac_cv_prog_cc_c89+:} false; then :
30897   $as_echo_n "(cached) " >&6
30898 else
30899   ac_cv_prog_cc_c89=no
30900 ac_save_CC=$CC
30901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30902 /* end confdefs.h.  */
30903 #include <stdarg.h>
30904 #include <stdio.h>
30905 struct stat;
30906 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
30907 struct buf { int x; };
30908 FILE * (*rcsopen) (struct buf *, struct stat *, int);
30909 static char *e (p, i)
30910      char **p;
30911      int i;
30912 {
30913   return p[i];
30914 }
30915 static char *f (char * (*g) (char **, int), char **p, ...)
30916 {
30917   char *s;
30918   va_list v;
30919   va_start (v,p);
30920   s = g (p, va_arg (v,int));
30921   va_end (v);
30922   return s;
30923 }
30924 
30925 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
30926    function prototypes and stuff, but not '\xHH' hex character constants.
30927    These don't provoke an error unfortunately, instead are silently treated
30928    as 'x'.  The following induces an error, until -std is added to get
30929    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
30930    array size at least.  It's necessary to write '\x00'==0 to get something
30931    that's true only with -std.  */
30932 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
30933 
30934 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
30935    inside strings and character constants.  */
30936 #define FOO(x) 'x'
30937 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
30938 
30939 int test (int i, double x);
30940 struct s1 {int (*f) (int a);};
30941 struct s2 {int (*f) (double a);};
30942 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
30943 int argc;
30944 char **argv;
30945 int
30946 main ()
30947 {
30948 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
30949   ;
30950   return 0;
30951 }
30952 _ACEOF
30953 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
30954         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
30955 do
30956   CC="$ac_save_CC $ac_arg"
30957   if ac_fn_c_try_compile "$LINENO"; then :
30958   ac_cv_prog_cc_c89=$ac_arg
30959 fi
30960 rm -f core conftest.err conftest.$ac_objext
30961   test "x$ac_cv_prog_cc_c89" != "xno" && break
30962 done
30963 rm -f conftest.$ac_ext
30964 CC=$ac_save_CC
30965 
30966 fi
30967 # AC_CACHE_VAL
30968 case "x$ac_cv_prog_cc_c89" in
30969   x)
30970     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
30971 $as_echo "none needed" >&6; } ;;
30972   xno)
30973     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
30974 $as_echo "unsupported" >&6; } ;;
30975   *)
30976     CC="$CC $ac_cv_prog_cc_c89"
30977     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
30978 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
30979 esac
30980 if test "x$ac_cv_prog_cc_c89" != xno; then :
30981 
30982 fi
30983 
30984 ac_ext=cpp
30985 ac_cpp='$CXXCPP $CPPFLAGS'
30986 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30987 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30988 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30989 
30990 
30991   # Option used to tell the compiler whether to create 32- or 64-bit executables
30992   # Notice that CC contains the full compiler path at this point.
30993   case $CC in
30994     *xlc_r) COMPILER_TARGET_BITS_FLAG="-q";;
30995     *)      COMPILER_TARGET_BITS_FLAG="-m";;
30996   esac
30997 
30998 
30999   ### Locate C++ compiler (CXX)
31000 
31001   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
31002     COMPILER_CHECK_LIST="cl"
31003   elif test "x$OPENJDK_TARGET_OS" = "xsolaris"; then
31004     COMPILER_CHECK_LIST="CC g++"
31005   elif test "x$OPENJDK_TARGET_OS" = "xaix"; then
31006     # Do not probe for CC on AIX .
31007     COMPILER_CHECK_LIST="xlC_r"
31008   else
31009     COMPILER_CHECK_LIST="g++ CC"
31010   fi
31011 
31012 
31013   COMPILER_NAME=C++
31014   SEARCH_LIST="$COMPILER_CHECK_LIST"
31015 
31016   if test "x$CXX" != x; then
31017     # User has supplied compiler name already, always let that override.
31018     { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CXX=$CXX" >&5
31019 $as_echo "$as_me: Will use user supplied compiler CXX=$CXX" >&6;}
31020     if test "x`basename $CXX`" = "x$CXX"; then
31021       # A command without a complete path is provided, search $PATH.
31022 
31023       for ac_prog in $CXX
31024 do
31025   # Extract the first word of "$ac_prog", so it can be a program name with args.
31026 set dummy $ac_prog; ac_word=$2
31027 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31028 $as_echo_n "checking for $ac_word... " >&6; }
31029 if ${ac_cv_path_POTENTIAL_CXX+:} false; then :
31030   $as_echo_n "(cached) " >&6
31031 else
31032   case $POTENTIAL_CXX in
31033   [\\/]* | ?:[\\/]*)
31034   ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path.
31035   ;;
31036   *)
31037   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31038 for as_dir in $PATH
31039 do
31040   IFS=$as_save_IFS
31041   test -z "$as_dir" && as_dir=.
31042     for ac_exec_ext in '' $ac_executable_extensions; do
31043   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31044     ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext"
31045     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31046     break 2
31047   fi
31048 done
31049   done
31050 IFS=$as_save_IFS
31051 
31052   ;;
31053 esac
31054 fi
31055 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX
31056 if test -n "$POTENTIAL_CXX"; then
31057   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5
31058 $as_echo "$POTENTIAL_CXX" >&6; }
31059 else
31060   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31061 $as_echo "no" >&6; }
31062 fi
31063 
31064 
31065   test -n "$POTENTIAL_CXX" && break
31066 done
31067 
31068       if test "x$POTENTIAL_CXX" != x; then
31069         CXX=$POTENTIAL_CXX
31070       else
31071         as_fn_error $? "User supplied compiler CXX=$CXX could not be found" "$LINENO" 5
31072       fi
31073     else
31074       # Otherwise it might already be a complete path
31075       if test ! -x "$CXX"; then
31076         as_fn_error $? "User supplied compiler CXX=$CXX does not exist" "$LINENO" 5
31077       fi
31078     fi
31079   else
31080     # No user supplied value. Locate compiler ourselves
31081     CXX=
31082     # If TOOLS_DIR is set, check for all compiler names in there first
31083     # before checking the rest of the PATH.
31084     if test -n "$TOOLS_DIR"; then
31085       PATH_save="$PATH"
31086       PATH="$TOOLS_DIR"
31087       for ac_prog in $SEARCH_LIST
31088 do
31089   # Extract the first word of "$ac_prog", so it can be a program name with args.
31090 set dummy $ac_prog; ac_word=$2
31091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31092 $as_echo_n "checking for $ac_word... " >&6; }
31093 if ${ac_cv_path_TOOLS_DIR_CXX+:} false; then :
31094   $as_echo_n "(cached) " >&6
31095 else
31096   case $TOOLS_DIR_CXX in
31097   [\\/]* | ?:[\\/]*)
31098   ac_cv_path_TOOLS_DIR_CXX="$TOOLS_DIR_CXX" # Let the user override the test with a path.
31099   ;;
31100   *)
31101   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31102 for as_dir in $PATH
31103 do
31104   IFS=$as_save_IFS
31105   test -z "$as_dir" && as_dir=.
31106     for ac_exec_ext in '' $ac_executable_extensions; do
31107   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31108     ac_cv_path_TOOLS_DIR_CXX="$as_dir/$ac_word$ac_exec_ext"
31109     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31110     break 2
31111   fi
31112 done
31113   done
31114 IFS=$as_save_IFS
31115 
31116   ;;
31117 esac
31118 fi
31119 TOOLS_DIR_CXX=$ac_cv_path_TOOLS_DIR_CXX
31120 if test -n "$TOOLS_DIR_CXX"; then
31121   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLS_DIR_CXX" >&5
31122 $as_echo "$TOOLS_DIR_CXX" >&6; }
31123 else
31124   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31125 $as_echo "no" >&6; }
31126 fi
31127 
31128 
31129   test -n "$TOOLS_DIR_CXX" && break
31130 done
31131 
31132       CXX=$TOOLS_DIR_CXX
31133       PATH="$PATH_save"
31134     fi
31135 
31136     # AC_PATH_PROGS can't be run multiple times with the same variable,
31137     # so create a new name for this run.
31138     if test "x$CXX" = x; then
31139       for ac_prog in $SEARCH_LIST
31140 do
31141   # Extract the first word of "$ac_prog", so it can be a program name with args.
31142 set dummy $ac_prog; ac_word=$2
31143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31144 $as_echo_n "checking for $ac_word... " >&6; }
31145 if ${ac_cv_path_POTENTIAL_CXX+:} false; then :
31146   $as_echo_n "(cached) " >&6
31147 else
31148   case $POTENTIAL_CXX in
31149   [\\/]* | ?:[\\/]*)
31150   ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path.
31151   ;;
31152   *)
31153   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31154 for as_dir in $PATH
31155 do
31156   IFS=$as_save_IFS
31157   test -z "$as_dir" && as_dir=.
31158     for ac_exec_ext in '' $ac_executable_extensions; do
31159   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31160     ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext"
31161     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31162     break 2
31163   fi
31164 done
31165   done
31166 IFS=$as_save_IFS
31167 
31168   ;;
31169 esac
31170 fi
31171 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX
31172 if test -n "$POTENTIAL_CXX"; then
31173   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5
31174 $as_echo "$POTENTIAL_CXX" >&6; }
31175 else
31176   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31177 $as_echo "no" >&6; }
31178 fi
31179 
31180 
31181   test -n "$POTENTIAL_CXX" && break
31182 done
31183 
31184       CXX=$POTENTIAL_CXX
31185     fi
31186 
31187     if test "x$CXX" = x; then
31188 
31189   # Print a helpful message on how to acquire the necessary build dependency.
31190   # devkit is the help tag: freetype, cups, pulse, alsa etc
31191   MISSING_DEPENDENCY=devkit
31192 
31193   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31194     cygwin_help $MISSING_DEPENDENCY
31195   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31196     msys_help $MISSING_DEPENDENCY
31197   else
31198     PKGHANDLER_COMMAND=
31199 
31200     case $PKGHANDLER in
31201       apt-get)
31202         apt_help     $MISSING_DEPENDENCY ;;
31203       yum)
31204         yum_help     $MISSING_DEPENDENCY ;;
31205       port)
31206         port_help    $MISSING_DEPENDENCY ;;
31207       pkgutil)
31208         pkgutil_help $MISSING_DEPENDENCY ;;
31209       pkgadd)
31210         pkgadd_help  $MISSING_DEPENDENCY ;;
31211     esac
31212 
31213     if test "x$PKGHANDLER_COMMAND" != x; then
31214       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
31215     fi
31216   fi
31217 
31218       as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5
31219     fi
31220   fi
31221 
31222   # Now we have a compiler binary in CXX. Make sure it's okay.
31223 
31224   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31225 
31226   # First separate the path from the arguments. This will split at the first
31227   # space.
31228   complete="$CXX"
31229   path="${complete%% *}"
31230   tmp="$complete EOL"
31231   arguments="${tmp#* }"
31232 
31233   # Input might be given as Windows format, start by converting to
31234   # unix format.
31235   new_path=`$CYGPATH -u "$path"`
31236 
31237   # Now try to locate executable using which
31238   new_path=`$WHICH "$new_path" 2> /dev/null`
31239   # bat and cmd files are not always considered executable in cygwin causing which
31240   # to not find them
31241   if test "x$new_path" = x \
31242       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31243       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31244     new_path=`$CYGPATH -u "$path"`
31245   fi
31246   if test "x$new_path" = x; then
31247     # Oops. Which didn't find the executable.
31248     # The splitting of arguments from the executable at a space might have been incorrect,
31249     # since paths with space are more likely in Windows. Give it another try with the whole
31250     # argument.
31251     path="$complete"
31252     arguments="EOL"
31253     new_path=`$CYGPATH -u "$path"`
31254     new_path=`$WHICH "$new_path" 2> /dev/null`
31255     # bat and cmd files are not always considered executable in cygwin causing which
31256     # to not find them
31257     if test "x$new_path" = x \
31258         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31259         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31260       new_path=`$CYGPATH -u "$path"`
31261     fi
31262     if test "x$new_path" = x; then
31263       # It's still not found. Now this is an unrecoverable error.
31264       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
31265 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
31266       has_space=`$ECHO "$complete" | $GREP " "`
31267       if test "x$has_space" != x; then
31268         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31269 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31270       fi
31271       as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
31272     fi
31273   fi
31274 
31275   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31276   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31277   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31278   # "foo.exe" is OK but "foo" is an error.
31279   #
31280   # This test is therefore slightly more accurate than "test -f" to check for file presence.
31281   # It is also a way to make sure we got the proper file name for the real test later on.
31282   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31283   if test "x$test_shortpath" = x; then
31284     # Short path failed, file does not exist as specified.
31285     # Try adding .exe or .cmd
31286     if test -f "${new_path}.exe"; then
31287       input_to_shortpath="${new_path}.exe"
31288     elif test -f "${new_path}.cmd"; then
31289       input_to_shortpath="${new_path}.cmd"
31290     else
31291       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$new_path\", is invalid." >&5
31292 $as_echo "$as_me: The path of CXX, which resolves as \"$new_path\", is invalid." >&6;}
31293       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31294 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31295       as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
31296     fi
31297   else
31298     input_to_shortpath="$new_path"
31299   fi
31300 
31301   # Call helper function which possibly converts this using DOS-style short mode.
31302   # If so, the updated path is stored in $new_path.
31303   new_path="$input_to_shortpath"
31304 
31305   input_path="$input_to_shortpath"
31306   # Check if we need to convert this using DOS-style short mode. If the path
31307   # contains just simple characters, use it. Otherwise (spaces, weird characters),
31308   # take no chances and rewrite it.
31309   # Note: m4 eats our [], so we need to use [ and ] instead.
31310   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
31311   if test "x$has_forbidden_chars" != x; then
31312     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31313     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
31314     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
31315     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
31316       # Going to short mode and back again did indeed matter. Since short mode is
31317       # case insensitive, let's make it lowercase to improve readability.
31318       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31319       # Now convert it back to Unix-stile (cygpath)
31320       input_path=`$CYGPATH -u "$shortmode_path"`
31321       new_path="$input_path"
31322     fi
31323   fi
31324 
31325   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
31326   if test "x$test_cygdrive_prefix" = x; then
31327     # As a simple fix, exclude /usr/bin since it's not a real path.
31328     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
31329       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
31330       # a path prefixed by /cygdrive for fixpath to work.
31331       new_path="$CYGWIN_ROOT_PATH$input_path"
31332     fi
31333   fi
31334 
31335   # remove trailing .exe if any
31336   new_path="${new_path/%.exe/}"
31337 
31338   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31339 
31340   # First separate the path from the arguments. This will split at the first
31341   # space.
31342   complete="$CXX"
31343   path="${complete%% *}"
31344   tmp="$complete EOL"
31345   arguments="${tmp#* }"
31346 
31347   # Input might be given as Windows format, start by converting to
31348   # unix format.
31349   new_path="$path"
31350 
31351   windows_path="$new_path"
31352   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31353     unix_path=`$CYGPATH -u "$windows_path"`
31354     new_path="$unix_path"
31355   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31356     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31357     new_path="$unix_path"
31358   fi
31359 
31360 
31361   # Now try to locate executable using which
31362   new_path=`$WHICH "$new_path" 2> /dev/null`
31363 
31364   if test "x$new_path" = x; then
31365     # Oops. Which didn't find the executable.
31366     # The splitting of arguments from the executable at a space might have been incorrect,
31367     # since paths with space are more likely in Windows. Give it another try with the whole
31368     # argument.
31369     path="$complete"
31370     arguments="EOL"
31371     new_path="$path"
31372 
31373   windows_path="$new_path"
31374   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31375     unix_path=`$CYGPATH -u "$windows_path"`
31376     new_path="$unix_path"
31377   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31378     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31379     new_path="$unix_path"
31380   fi
31381 
31382 
31383     new_path=`$WHICH "$new_path" 2> /dev/null`
31384 
31385     if test "x$new_path" = x; then
31386       # It's still not found. Now this is an unrecoverable error.
31387       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
31388 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
31389       has_space=`$ECHO "$complete" | $GREP " "`
31390       if test "x$has_space" != x; then
31391         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31392 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31393       fi
31394       as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
31395     fi
31396   fi
31397 
31398   # Now new_path has a complete unix path to the binary
31399   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
31400     # Keep paths in /bin as-is, but remove trailing .exe if any
31401     new_path="${new_path/%.exe/}"
31402     # Do not save /bin paths to all_fixpath_prefixes!
31403   else
31404     # Not in mixed or Windows style, start by that.
31405     new_path=`cmd //c echo $new_path`
31406 
31407   input_path="$new_path"
31408   # Check if we need to convert this using DOS-style short mode. If the path
31409   # contains just simple characters, use it. Otherwise (spaces, weird characters),
31410   # take no chances and rewrite it.
31411   # Note: m4 eats our [], so we need to use [ and ] instead.
31412   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
31413   if test "x$has_forbidden_chars" != x; then
31414     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31415     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31416   fi
31417 
31418     # Output is in $new_path
31419 
31420   windows_path="$new_path"
31421   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31422     unix_path=`$CYGPATH -u "$windows_path"`
31423     new_path="$unix_path"
31424   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31425     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31426     new_path="$unix_path"
31427   fi
31428 
31429     # remove trailing .exe if any
31430     new_path="${new_path/%.exe/}"
31431 
31432     # Save the first 10 bytes of this path to the storage, so fixpath can work.
31433     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
31434   fi
31435 
31436   else
31437     # We're on a posix platform. Hooray! :)
31438     # First separate the path from the arguments. This will split at the first
31439     # space.
31440     complete="$CXX"
31441     path="${complete%% *}"
31442     tmp="$complete EOL"
31443     arguments="${tmp#* }"
31444 
31445     # Cannot rely on the command "which" here since it doesn't always work.
31446     is_absolute_path=`$ECHO "$path" | $GREP ^/`
31447     if test -z "$is_absolute_path"; then
31448       # Path to executable is not absolute. Find it.
31449       IFS_save="$IFS"
31450       IFS=:
31451       for p in $PATH; do
31452         if test -f "$p/$path" && test -x "$p/$path"; then
31453           new_path="$p/$path"
31454           break
31455         fi
31456       done
31457       IFS="$IFS_save"
31458     else
31459       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving CXX (as $path) failed, using $path directly." >&5
31460 $as_echo "$as_me: Resolving CXX (as $path) failed, using $path directly." >&6;}
31461       new_path="$path"
31462     fi
31463 
31464     if test "x$new_path" = x; then
31465       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
31466 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
31467       has_space=`$ECHO "$complete" | $GREP " "`
31468       if test "x$has_space" != x; then
31469         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
31470 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
31471       fi
31472       as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
31473     fi
31474   fi
31475 
31476   # Now join together the path and the arguments once again
31477   if test "x$arguments" != xEOL; then
31478     new_complete="$new_path ${arguments% *}"
31479   else
31480     new_complete="$new_path"
31481   fi
31482 
31483   if test "x$complete" != "x$new_complete"; then
31484     CXX="$new_complete"
31485     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXX to \"$new_complete\"" >&5
31486 $as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;}
31487   fi
31488 
31489   TEST_COMPILER="$CXX"
31490   # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links
31491   # to 'xlc' but it is crucial that we invoke the compiler with the right name!
31492   if test "x$OPENJDK_BUILD_OS" != xaix; then
31493     { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5
31494 $as_echo_n "checking resolved symbolic links for CXX... " >&6; }
31495 
31496   if test "x$OPENJDK_BUILD_OS" != xwindows; then
31497     # Follow a chain of symbolic links. Use readlink
31498     # where it exists, else fall back to horribly
31499     # complicated shell code.
31500     if test "x$READLINK_TESTED" != yes; then
31501       # On MacOSX there is a readlink tool with a different
31502       # purpose than the GNU readlink tool. Check the found readlink.
31503       ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
31504       if test "x$ISGNU" = x; then
31505         # A readlink that we do not know how to use.
31506         # Are there other non-GNU readlinks out there?
31507         READLINK_TESTED=yes
31508         READLINK=
31509       fi
31510     fi
31511 
31512     if test "x$READLINK" != x; then
31513       TEST_COMPILER=`$READLINK -f $TEST_COMPILER`
31514     else
31515       # Save the current directory for restoring afterwards
31516       STARTDIR=$PWD
31517       COUNTER=0
31518       sym_link_dir=`$DIRNAME $TEST_COMPILER`
31519       sym_link_file=`$BASENAME $TEST_COMPILER`
31520       cd $sym_link_dir
31521       # Use -P flag to resolve symlinks in directories.
31522       cd `$THEPWDCMD -P`
31523       sym_link_dir=`$THEPWDCMD -P`
31524       # Resolve file symlinks
31525       while test $COUNTER -lt 20; do
31526         ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
31527         if test "x$ISLINK" == x; then
31528           # This is not a symbolic link! We are done!
31529           break
31530         fi
31531         # Again resolve directory symlinks since the target of the just found
31532         # link could be in a different directory
31533         cd `$DIRNAME $ISLINK`
31534         sym_link_dir=`$THEPWDCMD -P`
31535         sym_link_file=`$BASENAME $ISLINK`
31536         let COUNTER=COUNTER+1
31537       done
31538       cd $STARTDIR
31539       TEST_COMPILER=$sym_link_dir/$sym_link_file
31540     fi
31541   fi
31542 
31543     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5
31544 $as_echo "$TEST_COMPILER" >&6; }
31545   fi
31546   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CXX is disguised ccache" >&5
31547 $as_echo_n "checking if CXX is disguised ccache... " >&6; }
31548 
31549   COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"`
31550   if test "x$COMPILER_BASENAME" = "xccache"; then
31551     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5
31552 $as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; }
31553     # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache.
31554     # We want to control ccache invocation ourselves, so ignore this cc and try
31555     # searching again.
31556 
31557     # Remove the path to the fake ccache cc from the PATH
31558     RETRY_COMPILER_SAVED_PATH="$PATH"
31559     COMPILER_DIRNAME=`$DIRNAME $CXX`
31560     PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`"
31561 
31562     # Try again looking for our compiler
31563     if test -n "$ac_tool_prefix"; then
31564   for ac_prog in $COMPILER_CHECK_LIST
31565   do
31566     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
31567 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
31568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31569 $as_echo_n "checking for $ac_word... " >&6; }
31570 if ${ac_cv_prog_PROPER_COMPILER_CXX+:} false; then :
31571   $as_echo_n "(cached) " >&6
31572 else
31573   if test -n "$PROPER_COMPILER_CXX"; then
31574   ac_cv_prog_PROPER_COMPILER_CXX="$PROPER_COMPILER_CXX" # Let the user override the test.
31575 else
31576 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31577 for as_dir in $PATH
31578 do
31579   IFS=$as_save_IFS
31580   test -z "$as_dir" && as_dir=.
31581     for ac_exec_ext in '' $ac_executable_extensions; do
31582   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31583     ac_cv_prog_PROPER_COMPILER_CXX="$ac_tool_prefix$ac_prog"
31584     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31585     break 2
31586   fi
31587 done
31588   done
31589 IFS=$as_save_IFS
31590 
31591 fi
31592 fi
31593 PROPER_COMPILER_CXX=$ac_cv_prog_PROPER_COMPILER_CXX
31594 if test -n "$PROPER_COMPILER_CXX"; then
31595   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5
31596 $as_echo "$PROPER_COMPILER_CXX" >&6; }
31597 else
31598   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31599 $as_echo "no" >&6; }
31600 fi
31601 
31602 
31603     test -n "$PROPER_COMPILER_CXX" && break
31604   done
31605 fi
31606 if test -z "$PROPER_COMPILER_CXX"; then
31607   ac_ct_PROPER_COMPILER_CXX=$PROPER_COMPILER_CXX
31608   for ac_prog in $COMPILER_CHECK_LIST
31609 do
31610   # Extract the first word of "$ac_prog", so it can be a program name with args.
31611 set dummy $ac_prog; ac_word=$2
31612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31613 $as_echo_n "checking for $ac_word... " >&6; }
31614 if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CXX+:} false; then :
31615   $as_echo_n "(cached) " >&6
31616 else
31617   if test -n "$ac_ct_PROPER_COMPILER_CXX"; then
31618   ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_ct_PROPER_COMPILER_CXX" # Let the user override the test.
31619 else
31620 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31621 for as_dir in $PATH
31622 do
31623   IFS=$as_save_IFS
31624   test -z "$as_dir" && as_dir=.
31625     for ac_exec_ext in '' $ac_executable_extensions; do
31626   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31627     ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_prog"
31628     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31629     break 2
31630   fi
31631 done
31632   done
31633 IFS=$as_save_IFS
31634 
31635 fi
31636 fi
31637 ac_ct_PROPER_COMPILER_CXX=$ac_cv_prog_ac_ct_PROPER_COMPILER_CXX
31638 if test -n "$ac_ct_PROPER_COMPILER_CXX"; then
31639   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CXX" >&5
31640 $as_echo "$ac_ct_PROPER_COMPILER_CXX" >&6; }
31641 else
31642   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31643 $as_echo "no" >&6; }
31644 fi
31645 
31646 
31647   test -n "$ac_ct_PROPER_COMPILER_CXX" && break
31648 done
31649 
31650   if test "x$ac_ct_PROPER_COMPILER_CXX" = x; then
31651     PROPER_COMPILER_CXX=""
31652   else
31653     case $cross_compiling:$ac_tool_warned in
31654 yes:)
31655 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
31656 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
31657 ac_tool_warned=yes ;;
31658 esac
31659     PROPER_COMPILER_CXX=$ac_ct_PROPER_COMPILER_CXX
31660   fi
31661 fi
31662 
31663 
31664   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31665 
31666   # First separate the path from the arguments. This will split at the first
31667   # space.
31668   complete="$PROPER_COMPILER_CXX"
31669   path="${complete%% *}"
31670   tmp="$complete EOL"
31671   arguments="${tmp#* }"
31672 
31673   # Input might be given as Windows format, start by converting to
31674   # unix format.
31675   new_path=`$CYGPATH -u "$path"`
31676 
31677   # Now try to locate executable using which
31678   new_path=`$WHICH "$new_path" 2> /dev/null`
31679   # bat and cmd files are not always considered executable in cygwin causing which
31680   # to not find them
31681   if test "x$new_path" = x \
31682       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31683       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31684     new_path=`$CYGPATH -u "$path"`
31685   fi
31686   if test "x$new_path" = x; then
31687     # Oops. Which didn't find the executable.
31688     # The splitting of arguments from the executable at a space might have been incorrect,
31689     # since paths with space are more likely in Windows. Give it another try with the whole
31690     # argument.
31691     path="$complete"
31692     arguments="EOL"
31693     new_path=`$CYGPATH -u "$path"`
31694     new_path=`$WHICH "$new_path" 2> /dev/null`
31695     # bat and cmd files are not always considered executable in cygwin causing which
31696     # to not find them
31697     if test "x$new_path" = x \
31698         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31699         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31700       new_path=`$CYGPATH -u "$path"`
31701     fi
31702     if test "x$new_path" = x; then
31703       # It's still not found. Now this is an unrecoverable error.
31704       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
31705 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
31706       has_space=`$ECHO "$complete" | $GREP " "`
31707       if test "x$has_space" != x; then
31708         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31709 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31710       fi
31711       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
31712     fi
31713   fi
31714 
31715   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31716   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31717   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31718   # "foo.exe" is OK but "foo" is an error.
31719   #
31720   # This test is therefore slightly more accurate than "test -f" to check for file presence.
31721   # It is also a way to make sure we got the proper file name for the real test later on.
31722   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31723   if test "x$test_shortpath" = x; then
31724     # Short path failed, file does not exist as specified.
31725     # Try adding .exe or .cmd
31726     if test -f "${new_path}.exe"; then
31727       input_to_shortpath="${new_path}.exe"
31728     elif test -f "${new_path}.cmd"; then
31729       input_to_shortpath="${new_path}.cmd"
31730     else
31731       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&5
31732 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&6;}
31733       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31734 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31735       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
31736     fi
31737   else
31738     input_to_shortpath="$new_path"
31739   fi
31740 
31741   # Call helper function which possibly converts this using DOS-style short mode.
31742   # If so, the updated path is stored in $new_path.
31743   new_path="$input_to_shortpath"
31744 
31745   input_path="$input_to_shortpath"
31746   # Check if we need to convert this using DOS-style short mode. If the path
31747   # contains just simple characters, use it. Otherwise (spaces, weird characters),
31748   # take no chances and rewrite it.
31749   # Note: m4 eats our [], so we need to use [ and ] instead.
31750   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
31751   if test "x$has_forbidden_chars" != x; then
31752     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31753     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
31754     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
31755     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
31756       # Going to short mode and back again did indeed matter. Since short mode is
31757       # case insensitive, let's make it lowercase to improve readability.
31758       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31759       # Now convert it back to Unix-stile (cygpath)
31760       input_path=`$CYGPATH -u "$shortmode_path"`
31761       new_path="$input_path"
31762     fi
31763   fi
31764 
31765   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
31766   if test "x$test_cygdrive_prefix" = x; then
31767     # As a simple fix, exclude /usr/bin since it's not a real path.
31768     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
31769       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
31770       # a path prefixed by /cygdrive for fixpath to work.
31771       new_path="$CYGWIN_ROOT_PATH$input_path"
31772     fi
31773   fi
31774 
31775   # remove trailing .exe if any
31776   new_path="${new_path/%.exe/}"
31777 
31778   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31779 
31780   # First separate the path from the arguments. This will split at the first
31781   # space.
31782   complete="$PROPER_COMPILER_CXX"
31783   path="${complete%% *}"
31784   tmp="$complete EOL"
31785   arguments="${tmp#* }"
31786 
31787   # Input might be given as Windows format, start by converting to
31788   # unix format.
31789   new_path="$path"
31790 
31791   windows_path="$new_path"
31792   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31793     unix_path=`$CYGPATH -u "$windows_path"`
31794     new_path="$unix_path"
31795   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31796     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31797     new_path="$unix_path"
31798   fi
31799 
31800 
31801   # Now try to locate executable using which
31802   new_path=`$WHICH "$new_path" 2> /dev/null`
31803 
31804   if test "x$new_path" = x; then
31805     # Oops. Which didn't find the executable.
31806     # The splitting of arguments from the executable at a space might have been incorrect,
31807     # since paths with space are more likely in Windows. Give it another try with the whole
31808     # argument.
31809     path="$complete"
31810     arguments="EOL"
31811     new_path="$path"
31812 
31813   windows_path="$new_path"
31814   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31815     unix_path=`$CYGPATH -u "$windows_path"`
31816     new_path="$unix_path"
31817   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31818     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31819     new_path="$unix_path"
31820   fi
31821 
31822 
31823     new_path=`$WHICH "$new_path" 2> /dev/null`
31824 
31825     if test "x$new_path" = x; then
31826       # It's still not found. Now this is an unrecoverable error.
31827       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
31828 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
31829       has_space=`$ECHO "$complete" | $GREP " "`
31830       if test "x$has_space" != x; then
31831         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31832 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31833       fi
31834       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
31835     fi
31836   fi
31837 
31838   # Now new_path has a complete unix path to the binary
31839   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
31840     # Keep paths in /bin as-is, but remove trailing .exe if any
31841     new_path="${new_path/%.exe/}"
31842     # Do not save /bin paths to all_fixpath_prefixes!
31843   else
31844     # Not in mixed or Windows style, start by that.
31845     new_path=`cmd //c echo $new_path`
31846 
31847   input_path="$new_path"
31848   # Check if we need to convert this using DOS-style short mode. If the path
31849   # contains just simple characters, use it. Otherwise (spaces, weird characters),
31850   # take no chances and rewrite it.
31851   # Note: m4 eats our [], so we need to use [ and ] instead.
31852   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
31853   if test "x$has_forbidden_chars" != x; then
31854     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31855     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31856   fi
31857 
31858     # Output is in $new_path
31859 
31860   windows_path="$new_path"
31861   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31862     unix_path=`$CYGPATH -u "$windows_path"`
31863     new_path="$unix_path"
31864   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31865     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31866     new_path="$unix_path"
31867   fi
31868 
31869     # remove trailing .exe if any
31870     new_path="${new_path/%.exe/}"
31871 
31872     # Save the first 10 bytes of this path to the storage, so fixpath can work.
31873     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
31874   fi
31875 
31876   else
31877     # We're on a posix platform. Hooray! :)
31878     # First separate the path from the arguments. This will split at the first
31879     # space.
31880     complete="$PROPER_COMPILER_CXX"
31881     path="${complete%% *}"
31882     tmp="$complete EOL"
31883     arguments="${tmp#* }"
31884 
31885     # Cannot rely on the command "which" here since it doesn't always work.
31886     is_absolute_path=`$ECHO "$path" | $GREP ^/`
31887     if test -z "$is_absolute_path"; then
31888       # Path to executable is not absolute. Find it.
31889       IFS_save="$IFS"
31890       IFS=:
31891       for p in $PATH; do
31892         if test -f "$p/$path" && test -x "$p/$path"; then
31893           new_path="$p/$path"
31894           break
31895         fi
31896       done
31897       IFS="$IFS_save"
31898     else
31899       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving PROPER_COMPILER_CXX (as $path) failed, using $path directly." >&5
31900 $as_echo "$as_me: Resolving PROPER_COMPILER_CXX (as $path) failed, using $path directly." >&6;}
31901       new_path="$path"
31902     fi
31903 
31904     if test "x$new_path" = x; then
31905       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
31906 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
31907       has_space=`$ECHO "$complete" | $GREP " "`
31908       if test "x$has_space" != x; then
31909         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
31910 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
31911       fi
31912       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
31913     fi
31914   fi
31915 
31916   # Now join together the path and the arguments once again
31917   if test "x$arguments" != xEOL; then
31918     new_complete="$new_path ${arguments% *}"
31919   else
31920     new_complete="$new_path"
31921   fi
31922 
31923   if test "x$complete" != "x$new_complete"; then
31924     PROPER_COMPILER_CXX="$new_complete"
31925     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&5
31926 $as_echo "$as_me: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&6;}
31927   fi
31928 
31929     PATH="$RETRY_COMPILER_SAVED_PATH"
31930 
31931     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CXX" >&5
31932 $as_echo_n "checking for resolved symbolic links for CXX... " >&6; }
31933 
31934   if test "x$OPENJDK_BUILD_OS" != xwindows; then
31935     # Follow a chain of symbolic links. Use readlink
31936     # where it exists, else fall back to horribly
31937     # complicated shell code.
31938     if test "x$READLINK_TESTED" != yes; then
31939       # On MacOSX there is a readlink tool with a different
31940       # purpose than the GNU readlink tool. Check the found readlink.
31941       ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
31942       if test "x$ISGNU" = x; then
31943         # A readlink that we do not know how to use.
31944         # Are there other non-GNU readlinks out there?
31945         READLINK_TESTED=yes
31946         READLINK=
31947       fi
31948     fi
31949 
31950     if test "x$READLINK" != x; then
31951       PROPER_COMPILER_CXX=`$READLINK -f $PROPER_COMPILER_CXX`
31952     else
31953       # Save the current directory for restoring afterwards
31954       STARTDIR=$PWD
31955       COUNTER=0
31956       sym_link_dir=`$DIRNAME $PROPER_COMPILER_CXX`
31957       sym_link_file=`$BASENAME $PROPER_COMPILER_CXX`
31958       cd $sym_link_dir
31959       # Use -P flag to resolve symlinks in directories.
31960       cd `$THEPWDCMD -P`
31961       sym_link_dir=`$THEPWDCMD -P`
31962       # Resolve file symlinks
31963       while test $COUNTER -lt 20; do
31964         ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
31965         if test "x$ISLINK" == x; then
31966           # This is not a symbolic link! We are done!
31967           break
31968         fi
31969         # Again resolve directory symlinks since the target of the just found
31970         # link could be in a different directory
31971         cd `$DIRNAME $ISLINK`
31972         sym_link_dir=`$THEPWDCMD -P`
31973         sym_link_file=`$BASENAME $ISLINK`
31974         let COUNTER=COUNTER+1
31975       done
31976       cd $STARTDIR
31977       PROPER_COMPILER_CXX=$sym_link_dir/$sym_link_file
31978     fi
31979   fi
31980 
31981     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5
31982 $as_echo "$PROPER_COMPILER_CXX" >&6; }
31983     CXX="$PROPER_COMPILER_CXX"
31984   else
31985     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CXX" >&5
31986 $as_echo "no, keeping CXX" >&6; }
31987   fi
31988 
31989 
31990   COMPILER=$CXX
31991   COMPILER_NAME=$COMPILER_NAME
31992 
31993   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
31994     # Make sure we use the Sun Studio compiler and not gcc on Solaris, which won't work
31995     COMPILER_VERSION_TEST=`$COMPILER -V 2>&1 | $HEAD -n 1`
31996     $ECHO $COMPILER_VERSION_TEST | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null
31997     if test $? -ne 0; then
31998       GCC_VERSION_TEST=`$COMPILER --version 2>&1 | $HEAD -n 1`
31999 
32000       { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required Sun Studio compiler." >&5
32001 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required Sun Studio compiler." >&6;}
32002       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_TEST\" and with --version: \"$GCC_VERSION_TEST\"" >&5
32003 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_TEST\" and with --version: \"$GCC_VERSION_TEST\"" >&6;}
32004       as_fn_error $? "Sun Studio compiler is required. Try setting --with-tools-dir." "$LINENO" 5
32005     else
32006       COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/p"`
32007       COMPILER_VENDOR="Sun Studio"
32008     fi
32009   elif test  "x$OPENJDK_TARGET_OS" = xaix; then
32010       COMPILER_VERSION_TEST=`$COMPILER -qversion  2>&1 | $TAIL -n 1`
32011       $ECHO $COMPILER_VERSION_TEST | $GREP "^Version: " > /dev/null
32012       if test $? -ne 0; then
32013         as_fn_error $? "Failed to detect the compiler version of $COMPILER ...." "$LINENO" 5
32014       else
32015         COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n 's/Version: \(0-90-9\.0-90-9*\).*/\1/p'`
32016         COMPILER_VENDOR='IBM'
32017       fi
32018   elif test  "x$OPENJDK_TARGET_OS" = xwindows; then
32019     # First line typically looks something like:
32020     # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86
32021     COMPILER_VERSION_TEST=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'`
32022     COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.*Version \([1-9][0-9.]*\) .*/\1/p"`
32023     COMPILER_VENDOR="Microsoft CL.EXE"
32024     COMPILER_CPU_TEST=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.* for \(.*\)$/\1/p"`
32025     if test "x$OPENJDK_TARGET_CPU" = "xx86"; then
32026       if test "x$COMPILER_CPU_TEST" != "x80x86"; then
32027         as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"80x86\"." "$LINENO" 5
32028       fi
32029     elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then
32030       if test "x$COMPILER_CPU_TEST" != "xx64"; then
32031         as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5
32032       fi
32033     fi
32034   else
32035     COMPILER_VERSION_TEST=`$COMPILER --version 2>&1 | $HEAD -n 1`
32036     # Check that this is likely to be GCC.
32037     $COMPILER --version 2>&1 | $GREP "Free Software Foundation" > /dev/null
32038     if test $? -ne 0; then
32039       { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required GCC compiler." >&5
32040 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required GCC compiler." >&6;}
32041       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_TEST\"" >&5
32042 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_TEST\"" >&6;}
32043       as_fn_error $? "GCC compiler is required. Try setting --with-tools-dir." "$LINENO" 5
32044     fi
32045 
32046     # First line typically looks something like:
32047     # gcc (Ubuntu/Linaro 4.5.2-8ubuntu4) 4.5.2
32048     COMPILER_VERSION=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^.* \([1-9][0-9.]*\)/\1/p"`
32049     COMPILER_VENDOR=`$ECHO $COMPILER_VERSION_TEST | $SED -n "s/^\(.*\) [1-9][0-9.]*/\1/p"`
32050   fi
32051   # This sets CC_VERSION or CXX_VERSION. (This comment is a grep marker)
32052   CXX_VERSION="$COMPILER_VERSION"
32053   # This sets CC_VENDOR or CXX_VENDOR. (This comment is a grep marker)
32054   CXX_VENDOR="$COMPILER_VENDOR"
32055 
32056   { $as_echo "$as_me:${as_lineno-$LINENO}: Using $COMPILER_VENDOR $COMPILER_NAME compiler version $COMPILER_VERSION (located at $COMPILER)" >&5
32057 $as_echo "$as_me: Using $COMPILER_VENDOR $COMPILER_NAME compiler version $COMPILER_VERSION (located at $COMPILER)" >&6;}
32058 
32059 
32060   # Now that we have resolved CXX ourself, let autoconf have its go at it
32061   ac_ext=cpp
32062 ac_cpp='$CXXCPP $CPPFLAGS'
32063 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
32064 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
32065 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
32066 if test -z "$CXX"; then
32067   if test -n "$CCC"; then
32068     CXX=$CCC
32069   else
32070     if test -n "$ac_tool_prefix"; then
32071   for ac_prog in $CXX
32072   do
32073     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32074 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32076 $as_echo_n "checking for $ac_word... " >&6; }
32077 if ${ac_cv_prog_CXX+:} false; then :
32078   $as_echo_n "(cached) " >&6
32079 else
32080   if test -n "$CXX"; then
32081   ac_cv_prog_CXX="$CXX" # Let the user override the test.
32082 else
32083 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32084 for as_dir in $PATH
32085 do
32086   IFS=$as_save_IFS
32087   test -z "$as_dir" && as_dir=.
32088     for ac_exec_ext in '' $ac_executable_extensions; do
32089   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32090     ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
32091     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32092     break 2
32093   fi
32094 done
32095   done
32096 IFS=$as_save_IFS
32097 
32098 fi
32099 fi
32100 CXX=$ac_cv_prog_CXX
32101 if test -n "$CXX"; then
32102   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
32103 $as_echo "$CXX" >&6; }
32104 else
32105   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32106 $as_echo "no" >&6; }
32107 fi
32108 
32109 
32110     test -n "$CXX" && break
32111   done
32112 fi
32113 if test -z "$CXX"; then
32114   ac_ct_CXX=$CXX
32115   for ac_prog in $CXX
32116 do
32117   # Extract the first word of "$ac_prog", so it can be a program name with args.
32118 set dummy $ac_prog; ac_word=$2
32119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32120 $as_echo_n "checking for $ac_word... " >&6; }
32121 if ${ac_cv_prog_ac_ct_CXX+:} false; then :
32122   $as_echo_n "(cached) " >&6
32123 else
32124   if test -n "$ac_ct_CXX"; then
32125   ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
32126 else
32127 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32128 for as_dir in $PATH
32129 do
32130   IFS=$as_save_IFS
32131   test -z "$as_dir" && as_dir=.
32132     for ac_exec_ext in '' $ac_executable_extensions; do
32133   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32134     ac_cv_prog_ac_ct_CXX="$ac_prog"
32135     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32136     break 2
32137   fi
32138 done
32139   done
32140 IFS=$as_save_IFS
32141 
32142 fi
32143 fi
32144 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
32145 if test -n "$ac_ct_CXX"; then
32146   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
32147 $as_echo "$ac_ct_CXX" >&6; }
32148 else
32149   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32150 $as_echo "no" >&6; }
32151 fi
32152 
32153 
32154   test -n "$ac_ct_CXX" && break
32155 done
32156 
32157   if test "x$ac_ct_CXX" = x; then
32158     CXX="g++"
32159   else
32160     case $cross_compiling:$ac_tool_warned in
32161 yes:)
32162 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32163 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32164 ac_tool_warned=yes ;;
32165 esac
32166     CXX=$ac_ct_CXX
32167   fi
32168 fi
32169 
32170   fi
32171 fi
32172 # Provide some information about the compiler.
32173 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
32174 set X $ac_compile
32175 ac_compiler=$2
32176 for ac_option in --version -v -V -qversion; do
32177   { { ac_try="$ac_compiler $ac_option >&5"
32178 case "(($ac_try" in
32179   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32180   *) ac_try_echo=$ac_try;;
32181 esac
32182 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
32183 $as_echo "$ac_try_echo"; } >&5
32184   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
32185   ac_status=$?
32186   if test -s conftest.err; then
32187     sed '10a\
32188 ... rest of stderr output deleted ...
32189          10q' conftest.err >conftest.er1
32190     cat conftest.er1 >&5
32191   fi
32192   rm -f conftest.er1 conftest.err
32193   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
32194   test $ac_status = 0; }
32195 done
32196 
32197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
32198 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
32199 if ${ac_cv_cxx_compiler_gnu+:} false; then :
32200   $as_echo_n "(cached) " >&6
32201 else
32202   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32203 /* end confdefs.h.  */
32204 
32205 int
32206 main ()
32207 {
32208 #ifndef __GNUC__
32209        choke me
32210 #endif
32211 
32212   ;
32213   return 0;
32214 }
32215 _ACEOF
32216 if ac_fn_cxx_try_compile "$LINENO"; then :
32217   ac_compiler_gnu=yes
32218 else
32219   ac_compiler_gnu=no
32220 fi
32221 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32222 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
32223 
32224 fi
32225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
32226 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
32227 if test $ac_compiler_gnu = yes; then
32228   GXX=yes
32229 else
32230   GXX=
32231 fi
32232 ac_test_CXXFLAGS=${CXXFLAGS+set}
32233 ac_save_CXXFLAGS=$CXXFLAGS
32234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
32235 $as_echo_n "checking whether $CXX accepts -g... " >&6; }
32236 if ${ac_cv_prog_cxx_g+:} false; then :
32237   $as_echo_n "(cached) " >&6
32238 else
32239   ac_save_cxx_werror_flag=$ac_cxx_werror_flag
32240    ac_cxx_werror_flag=yes
32241    ac_cv_prog_cxx_g=no
32242    CXXFLAGS="-g"
32243    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32244 /* end confdefs.h.  */
32245 
32246 int
32247 main ()
32248 {
32249 
32250   ;
32251   return 0;
32252 }
32253 _ACEOF
32254 if ac_fn_cxx_try_compile "$LINENO"; then :
32255   ac_cv_prog_cxx_g=yes
32256 else
32257   CXXFLAGS=""
32258       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32259 /* end confdefs.h.  */
32260 
32261 int
32262 main ()
32263 {
32264 
32265   ;
32266   return 0;
32267 }
32268 _ACEOF
32269 if ac_fn_cxx_try_compile "$LINENO"; then :
32270 
32271 else
32272   ac_cxx_werror_flag=$ac_save_cxx_werror_flag
32273          CXXFLAGS="-g"
32274          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32275 /* end confdefs.h.  */
32276 
32277 int
32278 main ()
32279 {
32280 
32281   ;
32282   return 0;
32283 }
32284 _ACEOF
32285 if ac_fn_cxx_try_compile "$LINENO"; then :
32286   ac_cv_prog_cxx_g=yes
32287 fi
32288 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32289 fi
32290 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32291 fi
32292 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32293    ac_cxx_werror_flag=$ac_save_cxx_werror_flag
32294 fi
32295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
32296 $as_echo "$ac_cv_prog_cxx_g" >&6; }
32297 if test "$ac_test_CXXFLAGS" = set; then
32298   CXXFLAGS=$ac_save_CXXFLAGS
32299 elif test $ac_cv_prog_cxx_g = yes; then
32300   if test "$GXX" = yes; then
32301     CXXFLAGS="-g -O2"
32302   else
32303     CXXFLAGS="-g"
32304   fi
32305 else
32306   if test "$GXX" = yes; then
32307     CXXFLAGS="-O2"
32308   else
32309     CXXFLAGS=
32310   fi
32311 fi
32312 ac_ext=cpp
32313 ac_cpp='$CXXCPP $CPPFLAGS'
32314 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
32315 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
32316 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
32317 
32318 
32319   ### Locate other tools
32320 
32321   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
32322     ac_ext=m
32323 ac_cpp='$OBJCPP $CPPFLAGS'
32324 ac_compile='$OBJC -c $OBJCFLAGS $CPPFLAGS conftest.$ac_ext >&5'
32325 ac_link='$OBJC -o conftest$ac_exeext $OBJCFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
32326 ac_compiler_gnu=$ac_cv_objc_compiler_gnu
32327 if test -n "$ac_tool_prefix"; then
32328   for ac_prog in gcc objcc objc cc CC
32329   do
32330     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32331 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32333 $as_echo_n "checking for $ac_word... " >&6; }
32334 if ${ac_cv_prog_OBJC+:} false; then :
32335   $as_echo_n "(cached) " >&6
32336 else
32337   if test -n "$OBJC"; then
32338   ac_cv_prog_OBJC="$OBJC" # Let the user override the test.
32339 else
32340 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32341 for as_dir in $PATH
32342 do
32343   IFS=$as_save_IFS
32344   test -z "$as_dir" && as_dir=.
32345     for ac_exec_ext in '' $ac_executable_extensions; do
32346   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32347     ac_cv_prog_OBJC="$ac_tool_prefix$ac_prog"
32348     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32349     break 2
32350   fi
32351 done
32352   done
32353 IFS=$as_save_IFS
32354 
32355 fi
32356 fi
32357 OBJC=$ac_cv_prog_OBJC
32358 if test -n "$OBJC"; then
32359   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJC" >&5
32360 $as_echo "$OBJC" >&6; }
32361 else
32362   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32363 $as_echo "no" >&6; }
32364 fi
32365 
32366 
32367     test -n "$OBJC" && break
32368   done
32369 fi
32370 if test -z "$OBJC"; then
32371   ac_ct_OBJC=$OBJC
32372   for ac_prog in gcc objcc objc cc CC
32373 do
32374   # Extract the first word of "$ac_prog", so it can be a program name with args.
32375 set dummy $ac_prog; ac_word=$2
32376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32377 $as_echo_n "checking for $ac_word... " >&6; }
32378 if ${ac_cv_prog_ac_ct_OBJC+:} false; then :
32379   $as_echo_n "(cached) " >&6
32380 else
32381   if test -n "$ac_ct_OBJC"; then
32382   ac_cv_prog_ac_ct_OBJC="$ac_ct_OBJC" # Let the user override the test.
32383 else
32384 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32385 for as_dir in $PATH
32386 do
32387   IFS=$as_save_IFS
32388   test -z "$as_dir" && as_dir=.
32389     for ac_exec_ext in '' $ac_executable_extensions; do
32390   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32391     ac_cv_prog_ac_ct_OBJC="$ac_prog"
32392     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32393     break 2
32394   fi
32395 done
32396   done
32397 IFS=$as_save_IFS
32398 
32399 fi
32400 fi
32401 ac_ct_OBJC=$ac_cv_prog_ac_ct_OBJC
32402 if test -n "$ac_ct_OBJC"; then
32403   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJC" >&5
32404 $as_echo "$ac_ct_OBJC" >&6; }
32405 else
32406   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32407 $as_echo "no" >&6; }
32408 fi
32409 
32410 
32411   test -n "$ac_ct_OBJC" && break
32412 done
32413 
32414   if test "x$ac_ct_OBJC" = x; then
32415     OBJC="gcc"
32416   else
32417     case $cross_compiling:$ac_tool_warned in
32418 yes:)
32419 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32420 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32421 ac_tool_warned=yes ;;
32422 esac
32423     OBJC=$ac_ct_OBJC
32424   fi
32425 fi
32426 
32427 # Provide some information about the compiler.
32428 $as_echo "$as_me:${as_lineno-$LINENO}: checking for Objective C compiler version" >&5
32429 set X $ac_compile
32430 ac_compiler=$2
32431 for ac_option in --version -v -V -qversion; do
32432   { { ac_try="$ac_compiler $ac_option >&5"
32433 case "(($ac_try" in
32434   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32435   *) ac_try_echo=$ac_try;;
32436 esac
32437 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
32438 $as_echo "$ac_try_echo"; } >&5
32439   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
32440   ac_status=$?
32441   if test -s conftest.err; then
32442     sed '10a\
32443 ... rest of stderr output deleted ...
32444          10q' conftest.err >conftest.er1
32445     cat conftest.er1 >&5
32446   fi
32447   rm -f conftest.er1 conftest.err
32448   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
32449   test $ac_status = 0; }
32450 done
32451 
32452 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU Objective C compiler" >&5
32453 $as_echo_n "checking whether we are using the GNU Objective C compiler... " >&6; }
32454 if ${ac_cv_objc_compiler_gnu+:} false; then :
32455   $as_echo_n "(cached) " >&6
32456 else
32457   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32458 /* end confdefs.h.  */
32459 
32460 int
32461 main ()
32462 {
32463 #ifndef __GNUC__
32464        choke me
32465 #endif
32466 
32467   ;
32468   return 0;
32469 }
32470 _ACEOF
32471 if ac_fn_objc_try_compile "$LINENO"; then :
32472   ac_compiler_gnu=yes
32473 else
32474   ac_compiler_gnu=no
32475 fi
32476 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32477 ac_cv_objc_compiler_gnu=$ac_compiler_gnu
32478 
32479 fi
32480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objc_compiler_gnu" >&5
32481 $as_echo "$ac_cv_objc_compiler_gnu" >&6; }
32482 if test $ac_compiler_gnu = yes; then
32483   GOBJC=yes
32484 else
32485   GOBJC=
32486 fi
32487 ac_test_OBJCFLAGS=${OBJCFLAGS+set}
32488 ac_save_OBJCFLAGS=$OBJCFLAGS
32489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $OBJC accepts -g" >&5
32490 $as_echo_n "checking whether $OBJC accepts -g... " >&6; }
32491 if ${ac_cv_prog_objc_g+:} false; then :
32492   $as_echo_n "(cached) " >&6
32493 else
32494   ac_save_objc_werror_flag=$ac_objc_werror_flag
32495    ac_objc_werror_flag=yes
32496    ac_cv_prog_objc_g=no
32497    OBJCFLAGS="-g"
32498    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32499 /* end confdefs.h.  */
32500 
32501 int
32502 main ()
32503 {
32504 
32505   ;
32506   return 0;
32507 }
32508 _ACEOF
32509 if ac_fn_objc_try_compile "$LINENO"; then :
32510   ac_cv_prog_objc_g=yes
32511 else
32512   OBJCFLAGS=""
32513       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32514 /* end confdefs.h.  */
32515 
32516 int
32517 main ()
32518 {
32519 
32520   ;
32521   return 0;
32522 }
32523 _ACEOF
32524 if ac_fn_objc_try_compile "$LINENO"; then :
32525 
32526 else
32527   ac_objc_werror_flag=$ac_save_objc_werror_flag
32528          OBJCFLAGS="-g"
32529          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32530 /* end confdefs.h.  */
32531 
32532 int
32533 main ()
32534 {
32535 
32536   ;
32537   return 0;
32538 }
32539 _ACEOF
32540 if ac_fn_objc_try_compile "$LINENO"; then :
32541   ac_cv_prog_objc_g=yes
32542 fi
32543 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32544 fi
32545 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32546 fi
32547 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32548    ac_objc_werror_flag=$ac_save_objc_werror_flag
32549 fi
32550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_objc_g" >&5
32551 $as_echo "$ac_cv_prog_objc_g" >&6; }
32552 if test "$ac_test_OBJCFLAGS" = set; then
32553   OBJCFLAGS=$ac_save_OBJCFLAGS
32554 elif test $ac_cv_prog_objc_g = yes; then
32555   if test "$GOBJC" = yes; then
32556     OBJCFLAGS="-g -O2"
32557   else
32558     OBJCFLAGS="-g"
32559   fi
32560 else
32561   if test "$GOBJC" = yes; then
32562     OBJCFLAGS="-O2"
32563   else
32564     OBJCFLAGS=
32565   fi
32566 fi
32567 ac_ext=cpp
32568 ac_cpp='$CXXCPP $CPPFLAGS'
32569 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
32570 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
32571 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
32572 
32573 
32574   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32575 
32576   # First separate the path from the arguments. This will split at the first
32577   # space.
32578   complete="$OBJC"
32579   path="${complete%% *}"
32580   tmp="$complete EOL"
32581   arguments="${tmp#* }"
32582 
32583   # Input might be given as Windows format, start by converting to
32584   # unix format.
32585   new_path=`$CYGPATH -u "$path"`
32586 
32587   # Now try to locate executable using which
32588   new_path=`$WHICH "$new_path" 2> /dev/null`
32589   # bat and cmd files are not always considered executable in cygwin causing which
32590   # to not find them
32591   if test "x$new_path" = x \
32592       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32593       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32594     new_path=`$CYGPATH -u "$path"`
32595   fi
32596   if test "x$new_path" = x; then
32597     # Oops. Which didn't find the executable.
32598     # The splitting of arguments from the executable at a space might have been incorrect,
32599     # since paths with space are more likely in Windows. Give it another try with the whole
32600     # argument.
32601     path="$complete"
32602     arguments="EOL"
32603     new_path=`$CYGPATH -u "$path"`
32604     new_path=`$WHICH "$new_path" 2> /dev/null`
32605     # bat and cmd files are not always considered executable in cygwin causing which
32606     # to not find them
32607     if test "x$new_path" = x \
32608         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32609         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32610       new_path=`$CYGPATH -u "$path"`
32611     fi
32612     if test "x$new_path" = x; then
32613       # It's still not found. Now this is an unrecoverable error.
32614       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
32615 $as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
32616       has_space=`$ECHO "$complete" | $GREP " "`
32617       if test "x$has_space" != x; then
32618         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
32619 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
32620       fi
32621       as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
32622     fi
32623   fi
32624 
32625   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
32626   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
32627   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
32628   # "foo.exe" is OK but "foo" is an error.
32629   #
32630   # This test is therefore slightly more accurate than "test -f" to check for file presence.
32631   # It is also a way to make sure we got the proper file name for the real test later on.
32632   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
32633   if test "x$test_shortpath" = x; then
32634     # Short path failed, file does not exist as specified.
32635     # Try adding .exe or .cmd
32636     if test -f "${new_path}.exe"; then
32637       input_to_shortpath="${new_path}.exe"
32638     elif test -f "${new_path}.cmd"; then
32639       input_to_shortpath="${new_path}.cmd"
32640     else
32641       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$new_path\", is invalid." >&5
32642 $as_echo "$as_me: The path of OBJC, which resolves as \"$new_path\", is invalid." >&6;}
32643       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
32644 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
32645       as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
32646     fi
32647   else
32648     input_to_shortpath="$new_path"
32649   fi
32650 
32651   # Call helper function which possibly converts this using DOS-style short mode.
32652   # If so, the updated path is stored in $new_path.
32653   new_path="$input_to_shortpath"
32654 
32655   input_path="$input_to_shortpath"
32656   # Check if we need to convert this using DOS-style short mode. If the path
32657   # contains just simple characters, use it. Otherwise (spaces, weird characters),
32658   # take no chances and rewrite it.
32659   # Note: m4 eats our [], so we need to use [ and ] instead.
32660   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
32661   if test "x$has_forbidden_chars" != x; then
32662     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
32663     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
32664     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
32665     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
32666       # Going to short mode and back again did indeed matter. Since short mode is
32667       # case insensitive, let's make it lowercase to improve readability.
32668       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
32669       # Now convert it back to Unix-stile (cygpath)
32670       input_path=`$CYGPATH -u "$shortmode_path"`
32671       new_path="$input_path"
32672     fi
32673   fi
32674 
32675   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
32676   if test "x$test_cygdrive_prefix" = x; then
32677     # As a simple fix, exclude /usr/bin since it's not a real path.
32678     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
32679       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
32680       # a path prefixed by /cygdrive for fixpath to work.
32681       new_path="$CYGWIN_ROOT_PATH$input_path"
32682     fi
32683   fi
32684 
32685   # remove trailing .exe if any
32686   new_path="${new_path/%.exe/}"
32687 
32688   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32689 
32690   # First separate the path from the arguments. This will split at the first
32691   # space.
32692   complete="$OBJC"
32693   path="${complete%% *}"
32694   tmp="$complete EOL"
32695   arguments="${tmp#* }"
32696 
32697   # Input might be given as Windows format, start by converting to
32698   # unix format.
32699   new_path="$path"
32700 
32701   windows_path="$new_path"
32702   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32703     unix_path=`$CYGPATH -u "$windows_path"`
32704     new_path="$unix_path"
32705   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32706     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32707     new_path="$unix_path"
32708   fi
32709 
32710 
32711   # Now try to locate executable using which
32712   new_path=`$WHICH "$new_path" 2> /dev/null`
32713 
32714   if test "x$new_path" = x; then
32715     # Oops. Which didn't find the executable.
32716     # The splitting of arguments from the executable at a space might have been incorrect,
32717     # since paths with space are more likely in Windows. Give it another try with the whole
32718     # argument.
32719     path="$complete"
32720     arguments="EOL"
32721     new_path="$path"
32722 
32723   windows_path="$new_path"
32724   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32725     unix_path=`$CYGPATH -u "$windows_path"`
32726     new_path="$unix_path"
32727   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32728     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32729     new_path="$unix_path"
32730   fi
32731 
32732 
32733     new_path=`$WHICH "$new_path" 2> /dev/null`
32734 
32735     if test "x$new_path" = x; then
32736       # It's still not found. Now this is an unrecoverable error.
32737       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
32738 $as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
32739       has_space=`$ECHO "$complete" | $GREP " "`
32740       if test "x$has_space" != x; then
32741         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
32742 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
32743       fi
32744       as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
32745     fi
32746   fi
32747 
32748   # Now new_path has a complete unix path to the binary
32749   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
32750     # Keep paths in /bin as-is, but remove trailing .exe if any
32751     new_path="${new_path/%.exe/}"
32752     # Do not save /bin paths to all_fixpath_prefixes!
32753   else
32754     # Not in mixed or Windows style, start by that.
32755     new_path=`cmd //c echo $new_path`
32756 
32757   input_path="$new_path"
32758   # Check if we need to convert this using DOS-style short mode. If the path
32759   # contains just simple characters, use it. Otherwise (spaces, weird characters),
32760   # take no chances and rewrite it.
32761   # Note: m4 eats our [], so we need to use [ and ] instead.
32762   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
32763   if test "x$has_forbidden_chars" != x; then
32764     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
32765     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
32766   fi
32767 
32768     # Output is in $new_path
32769 
32770   windows_path="$new_path"
32771   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32772     unix_path=`$CYGPATH -u "$windows_path"`
32773     new_path="$unix_path"
32774   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32775     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32776     new_path="$unix_path"
32777   fi
32778 
32779     # remove trailing .exe if any
32780     new_path="${new_path/%.exe/}"
32781 
32782     # Save the first 10 bytes of this path to the storage, so fixpath can work.
32783     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
32784   fi
32785 
32786   else
32787     # We're on a posix platform. Hooray! :)
32788     # First separate the path from the arguments. This will split at the first
32789     # space.
32790     complete="$OBJC"
32791     path="${complete%% *}"
32792     tmp="$complete EOL"
32793     arguments="${tmp#* }"
32794 
32795     # Cannot rely on the command "which" here since it doesn't always work.
32796     is_absolute_path=`$ECHO "$path" | $GREP ^/`
32797     if test -z "$is_absolute_path"; then
32798       # Path to executable is not absolute. Find it.
32799       IFS_save="$IFS"
32800       IFS=:
32801       for p in $PATH; do
32802         if test -f "$p/$path" && test -x "$p/$path"; then
32803           new_path="$p/$path"
32804           break
32805         fi
32806       done
32807       IFS="$IFS_save"
32808     else
32809       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving OBJC (as $path) failed, using $path directly." >&5
32810 $as_echo "$as_me: Resolving OBJC (as $path) failed, using $path directly." >&6;}
32811       new_path="$path"
32812     fi
32813 
32814     if test "x$new_path" = x; then
32815       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
32816 $as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
32817       has_space=`$ECHO "$complete" | $GREP " "`
32818       if test "x$has_space" != x; then
32819         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
32820 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
32821       fi
32822       as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
32823     fi
32824   fi
32825 
32826   # Now join together the path and the arguments once again
32827   if test "x$arguments" != xEOL; then
32828     new_complete="$new_path ${arguments% *}"
32829   else
32830     new_complete="$new_path"
32831   fi
32832 
32833   if test "x$complete" != "x$new_complete"; then
32834     OBJC="$new_complete"
32835     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJC to \"$new_complete\"" >&5
32836 $as_echo "$as_me: Rewriting OBJC to \"$new_complete\"" >&6;}
32837   fi
32838 
32839   else
32840     OBJC=
32841   fi
32842 
32843   # Restore the flags to the user specified values.
32844   # This is necessary since AC_PROG_CC defaults CFLAGS to "-g -O2"
32845   CFLAGS="$ORG_CFLAGS"
32846   CXXFLAGS="$ORG_CXXFLAGS"
32847   OBJCFLAGS="$ORG_OBJCFLAGS"
32848 
32849   LD="$CC"
32850   LDEXE="$CC"
32851   LDCXX="$CXX"
32852   LDEXECXX="$CXX"
32853 
32854   # LDEXE is the linker to use, when creating executables.
32855 
32856   # Linking C++ libraries.
32857 
32858   # Linking C++ executables.
32859 
32860 
32861   if test "x$OPENJDK_TARGET_OS" != xwindows; then
32862 
32863 
32864   # Publish this variable in the help.
32865 
32866 
32867   if test "x$AR" = x; then
32868     # The variable is not set by user, try to locate tool using the code snippet
32869     if test -n "$ac_tool_prefix"; then
32870   for ac_prog in ar
32871   do
32872     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32873 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32875 $as_echo_n "checking for $ac_word... " >&6; }
32876 if ${ac_cv_prog_AR+:} false; then :
32877   $as_echo_n "(cached) " >&6
32878 else
32879   if test -n "$AR"; then
32880   ac_cv_prog_AR="$AR" # Let the user override the test.
32881 else
32882 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32883 for as_dir in $PATH
32884 do
32885   IFS=$as_save_IFS
32886   test -z "$as_dir" && as_dir=.
32887     for ac_exec_ext in '' $ac_executable_extensions; do
32888   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32889     ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
32890     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32891     break 2
32892   fi
32893 done
32894   done
32895 IFS=$as_save_IFS
32896 
32897 fi
32898 fi
32899 AR=$ac_cv_prog_AR
32900 if test -n "$AR"; then
32901   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32902 $as_echo "$AR" >&6; }
32903 else
32904   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32905 $as_echo "no" >&6; }
32906 fi
32907 
32908 
32909     test -n "$AR" && break
32910   done
32911 fi
32912 if test -z "$AR"; then
32913   ac_ct_AR=$AR
32914   for ac_prog in ar
32915 do
32916   # Extract the first word of "$ac_prog", so it can be a program name with args.
32917 set dummy $ac_prog; ac_word=$2
32918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32919 $as_echo_n "checking for $ac_word... " >&6; }
32920 if ${ac_cv_prog_ac_ct_AR+:} false; then :
32921   $as_echo_n "(cached) " >&6
32922 else
32923   if test -n "$ac_ct_AR"; then
32924   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
32925 else
32926 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32927 for as_dir in $PATH
32928 do
32929   IFS=$as_save_IFS
32930   test -z "$as_dir" && as_dir=.
32931     for ac_exec_ext in '' $ac_executable_extensions; do
32932   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32933     ac_cv_prog_ac_ct_AR="$ac_prog"
32934     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32935     break 2
32936   fi
32937 done
32938   done
32939 IFS=$as_save_IFS
32940 
32941 fi
32942 fi
32943 ac_ct_AR=$ac_cv_prog_ac_ct_AR
32944 if test -n "$ac_ct_AR"; then
32945   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
32946 $as_echo "$ac_ct_AR" >&6; }
32947 else
32948   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32949 $as_echo "no" >&6; }
32950 fi
32951 
32952 
32953   test -n "$ac_ct_AR" && break
32954 done
32955 
32956   if test "x$ac_ct_AR" = x; then
32957     AR=""
32958   else
32959     case $cross_compiling:$ac_tool_warned in
32960 yes:)
32961 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32962 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32963 ac_tool_warned=yes ;;
32964 esac
32965     AR=$ac_ct_AR
32966   fi
32967 fi
32968 
32969   else
32970     # The variable is set, but is it from the command line or the environment?
32971 
32972     # Try to remove the string !AR! from our list.
32973     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/}
32974     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
32975       # If it failed, the variable was not from the command line. Ignore it,
32976       # but warn the user (except for BASH, which is always set by the calling BASH).
32977       if test "xAR" != xBASH; then
32978         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5
32979 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;}
32980       fi
32981       # Try to locate tool using the code snippet
32982       if test -n "$ac_tool_prefix"; then
32983   for ac_prog in ar
32984   do
32985     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32986 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32988 $as_echo_n "checking for $ac_word... " >&6; }
32989 if ${ac_cv_prog_AR+:} false; then :
32990   $as_echo_n "(cached) " >&6
32991 else
32992   if test -n "$AR"; then
32993   ac_cv_prog_AR="$AR" # Let the user override the test.
32994 else
32995 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32996 for as_dir in $PATH
32997 do
32998   IFS=$as_save_IFS
32999   test -z "$as_dir" && as_dir=.
33000     for ac_exec_ext in '' $ac_executable_extensions; do
33001   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33002     ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
33003     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33004     break 2
33005   fi
33006 done
33007   done
33008 IFS=$as_save_IFS
33009 
33010 fi
33011 fi
33012 AR=$ac_cv_prog_AR
33013 if test -n "$AR"; then
33014   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
33015 $as_echo "$AR" >&6; }
33016 else
33017   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33018 $as_echo "no" >&6; }
33019 fi
33020 
33021 
33022     test -n "$AR" && break
33023   done
33024 fi
33025 if test -z "$AR"; then
33026   ac_ct_AR=$AR
33027   for ac_prog in ar
33028 do
33029   # Extract the first word of "$ac_prog", so it can be a program name with args.
33030 set dummy $ac_prog; ac_word=$2
33031 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33032 $as_echo_n "checking for $ac_word... " >&6; }
33033 if ${ac_cv_prog_ac_ct_AR+:} false; then :
33034   $as_echo_n "(cached) " >&6
33035 else
33036   if test -n "$ac_ct_AR"; then
33037   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
33038 else
33039 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33040 for as_dir in $PATH
33041 do
33042   IFS=$as_save_IFS
33043   test -z "$as_dir" && as_dir=.
33044     for ac_exec_ext in '' $ac_executable_extensions; do
33045   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33046     ac_cv_prog_ac_ct_AR="$ac_prog"
33047     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33048     break 2
33049   fi
33050 done
33051   done
33052 IFS=$as_save_IFS
33053 
33054 fi
33055 fi
33056 ac_ct_AR=$ac_cv_prog_ac_ct_AR
33057 if test -n "$ac_ct_AR"; then
33058   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
33059 $as_echo "$ac_ct_AR" >&6; }
33060 else
33061   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33062 $as_echo "no" >&6; }
33063 fi
33064 
33065 
33066   test -n "$ac_ct_AR" && break
33067 done
33068 
33069   if test "x$ac_ct_AR" = x; then
33070     AR=""
33071   else
33072     case $cross_compiling:$ac_tool_warned in
33073 yes:)
33074 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
33075 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
33076 ac_tool_warned=yes ;;
33077 esac
33078     AR=$ac_ct_AR
33079   fi
33080 fi
33081 
33082     else
33083       # If it succeeded, then it was overridden by the user. We will use it
33084       # for the tool.
33085 
33086       # First remove it from the list of overridden variables, so we can test
33087       # for unknown variables in the end.
33088       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
33089 
33090       # Check if the provided tool contains a complete path.
33091       tool_specified="$AR"
33092       tool_basename="${tool_specified##*/}"
33093       if test "x$tool_basename" = "x$tool_specified"; then
33094         # A command without a complete path is provided, search $PATH.
33095         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5
33096 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;}
33097         # Extract the first word of "$tool_basename", so it can be a program name with args.
33098 set dummy $tool_basename; ac_word=$2
33099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33100 $as_echo_n "checking for $ac_word... " >&6; }
33101 if ${ac_cv_path_AR+:} false; then :
33102   $as_echo_n "(cached) " >&6
33103 else
33104   case $AR in
33105   [\\/]* | ?:[\\/]*)
33106   ac_cv_path_AR="$AR" # Let the user override the test with a path.
33107   ;;
33108   *)
33109   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33110 for as_dir in $PATH
33111 do
33112   IFS=$as_save_IFS
33113   test -z "$as_dir" && as_dir=.
33114     for ac_exec_ext in '' $ac_executable_extensions; do
33115   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33116     ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext"
33117     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33118     break 2
33119   fi
33120 done
33121   done
33122 IFS=$as_save_IFS
33123 
33124   ;;
33125 esac
33126 fi
33127 AR=$ac_cv_path_AR
33128 if test -n "$AR"; then
33129   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
33130 $as_echo "$AR" >&6; }
33131 else
33132   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33133 $as_echo "no" >&6; }
33134 fi
33135 
33136 
33137         if test "x$AR" = x; then
33138           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
33139         fi
33140       else
33141         # Otherwise we believe it is a complete path. Use it as it is.
33142         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5
33143 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;}
33144         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5
33145 $as_echo_n "checking for AR... " >&6; }
33146         if test ! -x "$tool_specified"; then
33147           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
33148 $as_echo "not found" >&6; }
33149           as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5
33150         fi
33151         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
33152 $as_echo "$tool_specified" >&6; }
33153       fi
33154     fi
33155   fi
33156 
33157 
33158 
33159   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33160 
33161   # First separate the path from the arguments. This will split at the first
33162   # space.
33163   complete="$AR"
33164   path="${complete%% *}"
33165   tmp="$complete EOL"
33166   arguments="${tmp#* }"
33167 
33168   # Input might be given as Windows format, start by converting to
33169   # unix format.
33170   new_path=`$CYGPATH -u "$path"`
33171 
33172   # Now try to locate executable using which
33173   new_path=`$WHICH "$new_path" 2> /dev/null`
33174   # bat and cmd files are not always considered executable in cygwin causing which
33175   # to not find them
33176   if test "x$new_path" = x \
33177       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33178       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33179     new_path=`$CYGPATH -u "$path"`
33180   fi
33181   if test "x$new_path" = x; then
33182     # Oops. Which didn't find the executable.
33183     # The splitting of arguments from the executable at a space might have been incorrect,
33184     # since paths with space are more likely in Windows. Give it another try with the whole
33185     # argument.
33186     path="$complete"
33187     arguments="EOL"
33188     new_path=`$CYGPATH -u "$path"`
33189     new_path=`$WHICH "$new_path" 2> /dev/null`
33190     # bat and cmd files are not always considered executable in cygwin causing which
33191     # to not find them
33192     if test "x$new_path" = x \
33193         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33194         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33195       new_path=`$CYGPATH -u "$path"`
33196     fi
33197     if test "x$new_path" = x; then
33198       # It's still not found. Now this is an unrecoverable error.
33199       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
33200 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
33201       has_space=`$ECHO "$complete" | $GREP " "`
33202       if test "x$has_space" != x; then
33203         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33204 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33205       fi
33206       as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
33207     fi
33208   fi
33209 
33210   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
33211   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
33212   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
33213   # "foo.exe" is OK but "foo" is an error.
33214   #
33215   # This test is therefore slightly more accurate than "test -f" to check for file presence.
33216   # It is also a way to make sure we got the proper file name for the real test later on.
33217   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
33218   if test "x$test_shortpath" = x; then
33219     # Short path failed, file does not exist as specified.
33220     # Try adding .exe or .cmd
33221     if test -f "${new_path}.exe"; then
33222       input_to_shortpath="${new_path}.exe"
33223     elif test -f "${new_path}.cmd"; then
33224       input_to_shortpath="${new_path}.cmd"
33225     else
33226       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$new_path\", is invalid." >&5
33227 $as_echo "$as_me: The path of AR, which resolves as \"$new_path\", is invalid." >&6;}
33228       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33229 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33230       as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
33231     fi
33232   else
33233     input_to_shortpath="$new_path"
33234   fi
33235 
33236   # Call helper function which possibly converts this using DOS-style short mode.
33237   # If so, the updated path is stored in $new_path.
33238   new_path="$input_to_shortpath"
33239 
33240   input_path="$input_to_shortpath"
33241   # Check if we need to convert this using DOS-style short mode. If the path
33242   # contains just simple characters, use it. Otherwise (spaces, weird characters),
33243   # take no chances and rewrite it.
33244   # Note: m4 eats our [], so we need to use [ and ] instead.
33245   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33246   if test "x$has_forbidden_chars" != x; then
33247     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33248     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33249     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33250     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33251       # Going to short mode and back again did indeed matter. Since short mode is
33252       # case insensitive, let's make it lowercase to improve readability.
33253       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33254       # Now convert it back to Unix-stile (cygpath)
33255       input_path=`$CYGPATH -u "$shortmode_path"`
33256       new_path="$input_path"
33257     fi
33258   fi
33259 
33260   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33261   if test "x$test_cygdrive_prefix" = x; then
33262     # As a simple fix, exclude /usr/bin since it's not a real path.
33263     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33264       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33265       # a path prefixed by /cygdrive for fixpath to work.
33266       new_path="$CYGWIN_ROOT_PATH$input_path"
33267     fi
33268   fi
33269 
33270   # remove trailing .exe if any
33271   new_path="${new_path/%.exe/}"
33272 
33273   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33274 
33275   # First separate the path from the arguments. This will split at the first
33276   # space.
33277   complete="$AR"
33278   path="${complete%% *}"
33279   tmp="$complete EOL"
33280   arguments="${tmp#* }"
33281 
33282   # Input might be given as Windows format, start by converting to
33283   # unix format.
33284   new_path="$path"
33285 
33286   windows_path="$new_path"
33287   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33288     unix_path=`$CYGPATH -u "$windows_path"`
33289     new_path="$unix_path"
33290   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33291     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33292     new_path="$unix_path"
33293   fi
33294 
33295 
33296   # Now try to locate executable using which
33297   new_path=`$WHICH "$new_path" 2> /dev/null`
33298 
33299   if test "x$new_path" = x; then
33300     # Oops. Which didn't find the executable.
33301     # The splitting of arguments from the executable at a space might have been incorrect,
33302     # since paths with space are more likely in Windows. Give it another try with the whole
33303     # argument.
33304     path="$complete"
33305     arguments="EOL"
33306     new_path="$path"
33307 
33308   windows_path="$new_path"
33309   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33310     unix_path=`$CYGPATH -u "$windows_path"`
33311     new_path="$unix_path"
33312   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33313     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33314     new_path="$unix_path"
33315   fi
33316 
33317 
33318     new_path=`$WHICH "$new_path" 2> /dev/null`
33319 
33320     if test "x$new_path" = x; then
33321       # It's still not found. Now this is an unrecoverable error.
33322       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
33323 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
33324       has_space=`$ECHO "$complete" | $GREP " "`
33325       if test "x$has_space" != x; then
33326         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33327 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33328       fi
33329       as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
33330     fi
33331   fi
33332 
33333   # Now new_path has a complete unix path to the binary
33334   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
33335     # Keep paths in /bin as-is, but remove trailing .exe if any
33336     new_path="${new_path/%.exe/}"
33337     # Do not save /bin paths to all_fixpath_prefixes!
33338   else
33339     # Not in mixed or Windows style, start by that.
33340     new_path=`cmd //c echo $new_path`
33341 
33342   input_path="$new_path"
33343   # Check if we need to convert this using DOS-style short mode. If the path
33344   # contains just simple characters, use it. Otherwise (spaces, weird characters),
33345   # take no chances and rewrite it.
33346   # Note: m4 eats our [], so we need to use [ and ] instead.
33347   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
33348   if test "x$has_forbidden_chars" != x; then
33349     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33350     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33351   fi
33352 
33353     # Output is in $new_path
33354 
33355   windows_path="$new_path"
33356   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33357     unix_path=`$CYGPATH -u "$windows_path"`
33358     new_path="$unix_path"
33359   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33360     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33361     new_path="$unix_path"
33362   fi
33363 
33364     # remove trailing .exe if any
33365     new_path="${new_path/%.exe/}"
33366 
33367     # Save the first 10 bytes of this path to the storage, so fixpath can work.
33368     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
33369   fi
33370 
33371   else
33372     # We're on a posix platform. Hooray! :)
33373     # First separate the path from the arguments. This will split at the first
33374     # space.
33375     complete="$AR"
33376     path="${complete%% *}"
33377     tmp="$complete EOL"
33378     arguments="${tmp#* }"
33379 
33380     # Cannot rely on the command "which" here since it doesn't always work.
33381     is_absolute_path=`$ECHO "$path" | $GREP ^/`
33382     if test -z "$is_absolute_path"; then
33383       # Path to executable is not absolute. Find it.
33384       IFS_save="$IFS"
33385       IFS=:
33386       for p in $PATH; do
33387         if test -f "$p/$path" && test -x "$p/$path"; then
33388           new_path="$p/$path"
33389           break
33390         fi
33391       done
33392       IFS="$IFS_save"
33393     else
33394       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving AR (as $path) failed, using $path directly." >&5
33395 $as_echo "$as_me: Resolving AR (as $path) failed, using $path directly." >&6;}
33396       new_path="$path"
33397     fi
33398 
33399     if test "x$new_path" = x; then
33400       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
33401 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
33402       has_space=`$ECHO "$complete" | $GREP " "`
33403       if test "x$has_space" != x; then
33404         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
33405 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
33406       fi
33407       as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
33408     fi
33409   fi
33410 
33411   # Now join together the path and the arguments once again
33412   if test "x$arguments" != xEOL; then
33413     new_complete="$new_path ${arguments% *}"
33414   else
33415     new_complete="$new_path"
33416   fi
33417 
33418   if test "x$complete" != "x$new_complete"; then
33419     AR="$new_complete"
33420     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AR to \"$new_complete\"" >&5
33421 $as_echo "$as_me: Rewriting AR to \"$new_complete\"" >&6;}
33422   fi
33423 
33424   fi
33425   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
33426     ARFLAGS="-r"
33427   elif test "x$OPENJDK_TARGET_OS" = xaix; then
33428     ARFLAGS="-X64"
33429   else
33430     ARFLAGS=""
33431   fi
33432 
33433 
33434   # For hotspot, we need these in Windows mixed path; other platforms keep them the same
33435   HOTSPOT_CXX="$CXX"
33436   HOTSPOT_LD="$LD"
33437 
33438 
33439 
33440   COMPILER_NAME=gcc
33441   COMPILER_TYPE=CC
33442   if test "x$OPENJDK_TARGET_OS" = xwindows; then :
33443 
33444     # For now, assume that we are always compiling using cl.exe.
33445     CC_OUT_OPTION=-Fo
33446     EXE_OUT_OPTION=-out:
33447     LD_OUT_OPTION=-out:
33448     AR_OUT_OPTION=-out:
33449     # On Windows, reject /usr/bin/link (as determined in CYGWIN_LINK), which is a cygwin
33450     # program for something completely different.
33451     # Extract the first word of "link", so it can be a program name with args.
33452 set dummy link; ac_word=$2
33453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33454 $as_echo_n "checking for $ac_word... " >&6; }
33455 if ${ac_cv_prog_WINLD+:} false; then :
33456   $as_echo_n "(cached) " >&6
33457 else
33458   if test -n "$WINLD"; then
33459   ac_cv_prog_WINLD="$WINLD" # Let the user override the test.
33460 else
33461   ac_prog_rejected=no
33462 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33463 for as_dir in $PATH
33464 do
33465   IFS=$as_save_IFS
33466   test -z "$as_dir" && as_dir=.
33467     for ac_exec_ext in '' $ac_executable_extensions; do
33468   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33469     if test "$as_dir/$ac_word$ac_exec_ext" = "$CYGWIN_LINK"; then
33470        ac_prog_rejected=yes
33471        continue
33472      fi
33473     ac_cv_prog_WINLD="link"
33474     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33475     break 2
33476   fi
33477 done
33478   done
33479 IFS=$as_save_IFS
33480 
33481 if test $ac_prog_rejected = yes; then
33482   # We found a bogon in the path, so make sure we never use it.
33483   set dummy $ac_cv_prog_WINLD
33484   shift
33485   if test $# != 0; then
33486     # We chose a different compiler from the bogus one.
33487     # However, it has the same basename, so the bogon will be chosen
33488     # first if we set WINLD to just the basename; use the full file name.
33489     shift
33490     ac_cv_prog_WINLD="$as_dir/$ac_word${1+' '}$@"
33491   fi
33492 fi
33493 fi
33494 fi
33495 WINLD=$ac_cv_prog_WINLD
33496 if test -n "$WINLD"; then
33497   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINLD" >&5
33498 $as_echo "$WINLD" >&6; }
33499 else
33500   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33501 $as_echo "no" >&6; }
33502 fi
33503 
33504 
33505     # Since we must ignore the first found link, WINLD will contain
33506     # the full path to the link.exe program.
33507 
33508   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33509 
33510   # First separate the path from the arguments. This will split at the first
33511   # space.
33512   complete="$WINLD"
33513   path="${complete%% *}"
33514   tmp="$complete EOL"
33515   arguments="${tmp#* }"
33516 
33517   # Input might be given as Windows format, start by converting to
33518   # unix format.
33519   new_path=`$CYGPATH -u "$path"`
33520 
33521   # Now try to locate executable using which
33522   new_path=`$WHICH "$new_path" 2> /dev/null`
33523   # bat and cmd files are not always considered executable in cygwin causing which
33524   # to not find them
33525   if test "x$new_path" = x \
33526       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33527       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33528     new_path=`$CYGPATH -u "$path"`
33529   fi
33530   if test "x$new_path" = x; then
33531     # Oops. Which didn't find the executable.
33532     # The splitting of arguments from the executable at a space might have been incorrect,
33533     # since paths with space are more likely in Windows. Give it another try with the whole
33534     # argument.
33535     path="$complete"
33536     arguments="EOL"
33537     new_path=`$CYGPATH -u "$path"`
33538     new_path=`$WHICH "$new_path" 2> /dev/null`
33539     # bat and cmd files are not always considered executable in cygwin causing which
33540     # to not find them
33541     if test "x$new_path" = x \
33542         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33543         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33544       new_path=`$CYGPATH -u "$path"`
33545     fi
33546     if test "x$new_path" = x; then
33547       # It's still not found. Now this is an unrecoverable error.
33548       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINLD, which resolves as \"$complete\", is not found." >&5
33549 $as_echo "$as_me: The path of WINLD, which resolves as \"$complete\", is not found." >&6;}
33550       has_space=`$ECHO "$complete" | $GREP " "`
33551       if test "x$has_space" != x; then
33552         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33553 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33554       fi
33555       as_fn_error $? "Cannot locate the the path of WINLD" "$LINENO" 5
33556     fi
33557   fi
33558 
33559   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
33560   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
33561   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
33562   # "foo.exe" is OK but "foo" is an error.
33563   #
33564   # This test is therefore slightly more accurate than "test -f" to check for file presence.
33565   # It is also a way to make sure we got the proper file name for the real test later on.
33566   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
33567   if test "x$test_shortpath" = x; then
33568     # Short path failed, file does not exist as specified.
33569     # Try adding .exe or .cmd
33570     if test -f "${new_path}.exe"; then
33571       input_to_shortpath="${new_path}.exe"
33572     elif test -f "${new_path}.cmd"; then
33573       input_to_shortpath="${new_path}.cmd"
33574     else
33575       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINLD, which resolves as \"$new_path\", is invalid." >&5
33576 $as_echo "$as_me: The path of WINLD, which resolves as \"$new_path\", is invalid." >&6;}
33577       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33578 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33579       as_fn_error $? "Cannot locate the the path of WINLD" "$LINENO" 5
33580     fi
33581   else
33582     input_to_shortpath="$new_path"
33583   fi
33584 
33585   # Call helper function which possibly converts this using DOS-style short mode.
33586   # If so, the updated path is stored in $new_path.
33587   new_path="$input_to_shortpath"
33588 
33589   input_path="$input_to_shortpath"
33590   # Check if we need to convert this using DOS-style short mode. If the path
33591   # contains just simple characters, use it. Otherwise (spaces, weird characters),
33592   # take no chances and rewrite it.
33593   # Note: m4 eats our [], so we need to use [ and ] instead.
33594   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33595   if test "x$has_forbidden_chars" != x; then
33596     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33597     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33598     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33599     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33600       # Going to short mode and back again did indeed matter. Since short mode is
33601       # case insensitive, let's make it lowercase to improve readability.
33602       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33603       # Now convert it back to Unix-stile (cygpath)
33604       input_path=`$CYGPATH -u "$shortmode_path"`
33605       new_path="$input_path"
33606     fi
33607   fi
33608 
33609   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33610   if test "x$test_cygdrive_prefix" = x; then
33611     # As a simple fix, exclude /usr/bin since it's not a real path.
33612     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33613       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33614       # a path prefixed by /cygdrive for fixpath to work.
33615       new_path="$CYGWIN_ROOT_PATH$input_path"
33616     fi
33617   fi
33618 
33619   # remove trailing .exe if any
33620   new_path="${new_path/%.exe/}"
33621 
33622   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33623 
33624   # First separate the path from the arguments. This will split at the first
33625   # space.
33626   complete="$WINLD"
33627   path="${complete%% *}"
33628   tmp="$complete EOL"
33629   arguments="${tmp#* }"
33630 
33631   # Input might be given as Windows format, start by converting to
33632   # unix format.
33633   new_path="$path"
33634 
33635   windows_path="$new_path"
33636   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33637     unix_path=`$CYGPATH -u "$windows_path"`
33638     new_path="$unix_path"
33639   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33640     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33641     new_path="$unix_path"
33642   fi
33643 
33644 
33645   # Now try to locate executable using which
33646   new_path=`$WHICH "$new_path" 2> /dev/null`
33647 
33648   if test "x$new_path" = x; then
33649     # Oops. Which didn't find the executable.
33650     # The splitting of arguments from the executable at a space might have been incorrect,
33651     # since paths with space are more likely in Windows. Give it another try with the whole
33652     # argument.
33653     path="$complete"
33654     arguments="EOL"
33655     new_path="$path"
33656 
33657   windows_path="$new_path"
33658   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33659     unix_path=`$CYGPATH -u "$windows_path"`
33660     new_path="$unix_path"
33661   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33662     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33663     new_path="$unix_path"
33664   fi
33665 
33666 
33667     new_path=`$WHICH "$new_path" 2> /dev/null`
33668 
33669     if test "x$new_path" = x; then
33670       # It's still not found. Now this is an unrecoverable error.
33671       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINLD, which resolves as \"$complete\", is not found." >&5
33672 $as_echo "$as_me: The path of WINLD, which resolves as \"$complete\", is not found." >&6;}
33673       has_space=`$ECHO "$complete" | $GREP " "`
33674       if test "x$has_space" != x; then
33675         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33676 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33677       fi
33678       as_fn_error $? "Cannot locate the the path of WINLD" "$LINENO" 5
33679     fi
33680   fi
33681 
33682   # Now new_path has a complete unix path to the binary
33683   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
33684     # Keep paths in /bin as-is, but remove trailing .exe if any
33685     new_path="${new_path/%.exe/}"
33686     # Do not save /bin paths to all_fixpath_prefixes!
33687   else
33688     # Not in mixed or Windows style, start by that.
33689     new_path=`cmd //c echo $new_path`
33690 
33691   input_path="$new_path"
33692   # Check if we need to convert this using DOS-style short mode. If the path
33693   # contains just simple characters, use it. Otherwise (spaces, weird characters),
33694   # take no chances and rewrite it.
33695   # Note: m4 eats our [], so we need to use [ and ] instead.
33696   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
33697   if test "x$has_forbidden_chars" != x; then
33698     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33699     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33700   fi
33701 
33702     # Output is in $new_path
33703 
33704   windows_path="$new_path"
33705   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33706     unix_path=`$CYGPATH -u "$windows_path"`
33707     new_path="$unix_path"
33708   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33709     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33710     new_path="$unix_path"
33711   fi
33712 
33713     # remove trailing .exe if any
33714     new_path="${new_path/%.exe/}"
33715 
33716     # Save the first 10 bytes of this path to the storage, so fixpath can work.
33717     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
33718   fi
33719 
33720   else
33721     # We're on a posix platform. Hooray! :)
33722     # First separate the path from the arguments. This will split at the first
33723     # space.
33724     complete="$WINLD"
33725     path="${complete%% *}"
33726     tmp="$complete EOL"
33727     arguments="${tmp#* }"
33728 
33729     # Cannot rely on the command "which" here since it doesn't always work.
33730     is_absolute_path=`$ECHO "$path" | $GREP ^/`
33731     if test -z "$is_absolute_path"; then
33732       # Path to executable is not absolute. Find it.
33733       IFS_save="$IFS"
33734       IFS=:
33735       for p in $PATH; do
33736         if test -f "$p/$path" && test -x "$p/$path"; then
33737           new_path="$p/$path"
33738           break
33739         fi
33740       done
33741       IFS="$IFS_save"
33742     else
33743       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving WINLD (as $path) failed, using $path directly." >&5
33744 $as_echo "$as_me: Resolving WINLD (as $path) failed, using $path directly." >&6;}
33745       new_path="$path"
33746     fi
33747 
33748     if test "x$new_path" = x; then
33749       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINLD, which resolves as \"$complete\", is not found." >&5
33750 $as_echo "$as_me: The path of WINLD, which resolves as \"$complete\", is not found." >&6;}
33751       has_space=`$ECHO "$complete" | $GREP " "`
33752       if test "x$has_space" != x; then
33753         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
33754 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
33755       fi
33756       as_fn_error $? "Cannot locate the the path of WINLD" "$LINENO" 5
33757     fi
33758   fi
33759 
33760   # Now join together the path and the arguments once again
33761   if test "x$arguments" != xEOL; then
33762     new_complete="$new_path ${arguments% *}"
33763   else
33764     new_complete="$new_path"
33765   fi
33766 
33767   if test "x$complete" != "x$new_complete"; then
33768     WINLD="$new_complete"
33769     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting WINLD to \"$new_complete\"" >&5
33770 $as_echo "$as_me: Rewriting WINLD to \"$new_complete\"" >&6;}
33771   fi
33772 
33773     printf "Windows linker was found at $WINLD\n"
33774     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the found link.exe is actually the Visual Studio linker" >&5
33775 $as_echo_n "checking if the found link.exe is actually the Visual Studio linker... " >&6; }
33776     "$WINLD" --version > /dev/null
33777     if test $? -eq 0 ; then
33778       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33779 $as_echo "no" >&6; }
33780       as_fn_error $? "This is the Cygwin link tool. Please check your PATH and rerun configure." "$LINENO" 5
33781     else
33782       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33783 $as_echo "yes" >&6; }
33784     fi
33785     LD="$WINLD"
33786     LDEXE="$WINLD"
33787     LDCXX="$WINLD"
33788     LDEXECXX="$WINLD"
33789 
33790     # Extract the first word of "mt", so it can be a program name with args.
33791 set dummy mt; ac_word=$2
33792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33793 $as_echo_n "checking for $ac_word... " >&6; }
33794 if ${ac_cv_prog_MT+:} false; then :
33795   $as_echo_n "(cached) " >&6
33796 else
33797   if test -n "$MT"; then
33798   ac_cv_prog_MT="$MT" # Let the user override the test.
33799 else
33800   ac_prog_rejected=no
33801 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33802 for as_dir in $PATH
33803 do
33804   IFS=$as_save_IFS
33805   test -z "$as_dir" && as_dir=.
33806     for ac_exec_ext in '' $ac_executable_extensions; do
33807   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33808     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/mt"; then
33809        ac_prog_rejected=yes
33810        continue
33811      fi
33812     ac_cv_prog_MT="mt"
33813     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33814     break 2
33815   fi
33816 done
33817   done
33818 IFS=$as_save_IFS
33819 
33820 if test $ac_prog_rejected = yes; then
33821   # We found a bogon in the path, so make sure we never use it.
33822   set dummy $ac_cv_prog_MT
33823   shift
33824   if test $# != 0; then
33825     # We chose a different compiler from the bogus one.
33826     # However, it has the same basename, so the bogon will be chosen
33827     # first if we set MT to just the basename; use the full file name.
33828     shift
33829     ac_cv_prog_MT="$as_dir/$ac_word${1+' '}$@"
33830   fi
33831 fi
33832 fi
33833 fi
33834 MT=$ac_cv_prog_MT
33835 if test -n "$MT"; then
33836   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5
33837 $as_echo "$MT" >&6; }
33838 else
33839   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33840 $as_echo "no" >&6; }
33841 fi
33842 
33843 
33844 
33845   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33846 
33847   # First separate the path from the arguments. This will split at the first
33848   # space.
33849   complete="$MT"
33850   path="${complete%% *}"
33851   tmp="$complete EOL"
33852   arguments="${tmp#* }"
33853 
33854   # Input might be given as Windows format, start by converting to
33855   # unix format.
33856   new_path=`$CYGPATH -u "$path"`
33857 
33858   # Now try to locate executable using which
33859   new_path=`$WHICH "$new_path" 2> /dev/null`
33860   # bat and cmd files are not always considered executable in cygwin causing which
33861   # to not find them
33862   if test "x$new_path" = x \
33863       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33864       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33865     new_path=`$CYGPATH -u "$path"`
33866   fi
33867   if test "x$new_path" = x; then
33868     # Oops. Which didn't find the executable.
33869     # The splitting of arguments from the executable at a space might have been incorrect,
33870     # since paths with space are more likely in Windows. Give it another try with the whole
33871     # argument.
33872     path="$complete"
33873     arguments="EOL"
33874     new_path=`$CYGPATH -u "$path"`
33875     new_path=`$WHICH "$new_path" 2> /dev/null`
33876     # bat and cmd files are not always considered executable in cygwin causing which
33877     # to not find them
33878     if test "x$new_path" = x \
33879         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33880         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33881       new_path=`$CYGPATH -u "$path"`
33882     fi
33883     if test "x$new_path" = x; then
33884       # It's still not found. Now this is an unrecoverable error.
33885       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
33886 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
33887       has_space=`$ECHO "$complete" | $GREP " "`
33888       if test "x$has_space" != x; then
33889         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33890 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33891       fi
33892       as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33893     fi
33894   fi
33895 
33896   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
33897   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
33898   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
33899   # "foo.exe" is OK but "foo" is an error.
33900   #
33901   # This test is therefore slightly more accurate than "test -f" to check for file presence.
33902   # It is also a way to make sure we got the proper file name for the real test later on.
33903   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
33904   if test "x$test_shortpath" = x; then
33905     # Short path failed, file does not exist as specified.
33906     # Try adding .exe or .cmd
33907     if test -f "${new_path}.exe"; then
33908       input_to_shortpath="${new_path}.exe"
33909     elif test -f "${new_path}.cmd"; then
33910       input_to_shortpath="${new_path}.cmd"
33911     else
33912       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$new_path\", is invalid." >&5
33913 $as_echo "$as_me: The path of MT, which resolves as \"$new_path\", is invalid." >&6;}
33914       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33915 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33916       as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
33917     fi
33918   else
33919     input_to_shortpath="$new_path"
33920   fi
33921 
33922   # Call helper function which possibly converts this using DOS-style short mode.
33923   # If so, the updated path is stored in $new_path.
33924   new_path="$input_to_shortpath"
33925 
33926   input_path="$input_to_shortpath"
33927   # Check if we need to convert this using DOS-style short mode. If the path
33928   # contains just simple characters, use it. Otherwise (spaces, weird characters),
33929   # take no chances and rewrite it.
33930   # Note: m4 eats our [], so we need to use [ and ] instead.
33931   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33932   if test "x$has_forbidden_chars" != x; then
33933     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33934     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33935     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33936     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33937       # Going to short mode and back again did indeed matter. Since short mode is
33938       # case insensitive, let's make it lowercase to improve readability.
33939       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33940       # Now convert it back to Unix-stile (cygpath)
33941       input_path=`$CYGPATH -u "$shortmode_path"`
33942       new_path="$input_path"
33943     fi
33944   fi
33945 
33946   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33947   if test "x$test_cygdrive_prefix" = x; then
33948     # As a simple fix, exclude /usr/bin since it's not a real path.
33949     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33950       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33951       # a path prefixed by /cygdrive for fixpath to work.
33952       new_path="$CYGWIN_ROOT_PATH$input_path"
33953     fi
33954   fi
33955 
33956   # remove trailing .exe if any
33957   new_path="${new_path/%.exe/}"
33958 
33959   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33960 
33961   # First separate the path from the arguments. This will split at the first
33962   # space.
33963   complete="$MT"
33964   path="${complete%% *}"
33965   tmp="$complete EOL"
33966   arguments="${tmp#* }"
33967 
33968   # Input might be given as Windows format, start by converting to
33969   # unix format.
33970   new_path="$path"
33971 
33972   windows_path="$new_path"
33973   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33974     unix_path=`$CYGPATH -u "$windows_path"`
33975     new_path="$unix_path"
33976   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33977     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33978     new_path="$unix_path"
33979   fi
33980 
33981 
33982   # Now try to locate executable using which
33983   new_path=`$WHICH "$new_path" 2> /dev/null`
33984 
33985   if test "x$new_path" = x; then
33986     # Oops. Which didn't find the executable.
33987     # The splitting of arguments from the executable at a space might have been incorrect,
33988     # since paths with space are more likely in Windows. Give it another try with the whole
33989     # argument.
33990     path="$complete"
33991     arguments="EOL"
33992     new_path="$path"
33993 
33994   windows_path="$new_path"
33995   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33996     unix_path=`$CYGPATH -u "$windows_path"`
33997     new_path="$unix_path"
33998   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33999     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34000     new_path="$unix_path"
34001   fi
34002 
34003 
34004     new_path=`$WHICH "$new_path" 2> /dev/null`
34005 
34006     if test "x$new_path" = x; then
34007       # It's still not found. Now this is an unrecoverable error.
34008       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
34009 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
34010       has_space=`$ECHO "$complete" | $GREP " "`
34011       if test "x$has_space" != x; then
34012         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34013 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34014       fi
34015       as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
34016     fi
34017   fi
34018 
34019   # Now new_path has a complete unix path to the binary
34020   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34021     # Keep paths in /bin as-is, but remove trailing .exe if any
34022     new_path="${new_path/%.exe/}"
34023     # Do not save /bin paths to all_fixpath_prefixes!
34024   else
34025     # Not in mixed or Windows style, start by that.
34026     new_path=`cmd //c echo $new_path`
34027 
34028   input_path="$new_path"
34029   # Check if we need to convert this using DOS-style short mode. If the path
34030   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34031   # take no chances and rewrite it.
34032   # Note: m4 eats our [], so we need to use [ and ] instead.
34033   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34034   if test "x$has_forbidden_chars" != x; then
34035     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34036     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34037   fi
34038 
34039     # Output is in $new_path
34040 
34041   windows_path="$new_path"
34042   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34043     unix_path=`$CYGPATH -u "$windows_path"`
34044     new_path="$unix_path"
34045   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34046     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34047     new_path="$unix_path"
34048   fi
34049 
34050     # remove trailing .exe if any
34051     new_path="${new_path/%.exe/}"
34052 
34053     # Save the first 10 bytes of this path to the storage, so fixpath can work.
34054     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34055   fi
34056 
34057   else
34058     # We're on a posix platform. Hooray! :)
34059     # First separate the path from the arguments. This will split at the first
34060     # space.
34061     complete="$MT"
34062     path="${complete%% *}"
34063     tmp="$complete EOL"
34064     arguments="${tmp#* }"
34065 
34066     # Cannot rely on the command "which" here since it doesn't always work.
34067     is_absolute_path=`$ECHO "$path" | $GREP ^/`
34068     if test -z "$is_absolute_path"; then
34069       # Path to executable is not absolute. Find it.
34070       IFS_save="$IFS"
34071       IFS=:
34072       for p in $PATH; do
34073         if test -f "$p/$path" && test -x "$p/$path"; then
34074           new_path="$p/$path"
34075           break
34076         fi
34077       done
34078       IFS="$IFS_save"
34079     else
34080       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving MT (as $path) failed, using $path directly." >&5
34081 $as_echo "$as_me: Resolving MT (as $path) failed, using $path directly." >&6;}
34082       new_path="$path"
34083     fi
34084 
34085     if test "x$new_path" = x; then
34086       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
34087 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
34088       has_space=`$ECHO "$complete" | $GREP " "`
34089       if test "x$has_space" != x; then
34090         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
34091 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
34092       fi
34093       as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
34094     fi
34095   fi
34096 
34097   # Now join together the path and the arguments once again
34098   if test "x$arguments" != xEOL; then
34099     new_complete="$new_path ${arguments% *}"
34100   else
34101     new_complete="$new_path"
34102   fi
34103 
34104   if test "x$complete" != "x$new_complete"; then
34105     MT="$new_complete"
34106     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MT to \"$new_complete\"" >&5
34107 $as_echo "$as_me: Rewriting MT to \"$new_complete\"" >&6;}
34108   fi
34109 
34110     # The resource compiler
34111     # Extract the first word of "rc", so it can be a program name with args.
34112 set dummy rc; ac_word=$2
34113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34114 $as_echo_n "checking for $ac_word... " >&6; }
34115 if ${ac_cv_prog_RC+:} false; then :
34116   $as_echo_n "(cached) " >&6
34117 else
34118   if test -n "$RC"; then
34119   ac_cv_prog_RC="$RC" # Let the user override the test.
34120 else
34121   ac_prog_rejected=no
34122 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34123 for as_dir in $PATH
34124 do
34125   IFS=$as_save_IFS
34126   test -z "$as_dir" && as_dir=.
34127     for ac_exec_ext in '' $ac_executable_extensions; do
34128   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34129     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/rc"; then
34130        ac_prog_rejected=yes
34131        continue
34132      fi
34133     ac_cv_prog_RC="rc"
34134     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34135     break 2
34136   fi
34137 done
34138   done
34139 IFS=$as_save_IFS
34140 
34141 if test $ac_prog_rejected = yes; then
34142   # We found a bogon in the path, so make sure we never use it.
34143   set dummy $ac_cv_prog_RC
34144   shift
34145   if test $# != 0; then
34146     # We chose a different compiler from the bogus one.
34147     # However, it has the same basename, so the bogon will be chosen
34148     # first if we set RC to just the basename; use the full file name.
34149     shift
34150     ac_cv_prog_RC="$as_dir/$ac_word${1+' '}$@"
34151   fi
34152 fi
34153 fi
34154 fi
34155 RC=$ac_cv_prog_RC
34156 if test -n "$RC"; then
34157   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5
34158 $as_echo "$RC" >&6; }
34159 else
34160   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34161 $as_echo "no" >&6; }
34162 fi
34163 
34164 
34165 
34166   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34167 
34168   # First separate the path from the arguments. This will split at the first
34169   # space.
34170   complete="$RC"
34171   path="${complete%% *}"
34172   tmp="$complete EOL"
34173   arguments="${tmp#* }"
34174 
34175   # Input might be given as Windows format, start by converting to
34176   # unix format.
34177   new_path=`$CYGPATH -u "$path"`
34178 
34179   # Now try to locate executable using which
34180   new_path=`$WHICH "$new_path" 2> /dev/null`
34181   # bat and cmd files are not always considered executable in cygwin causing which
34182   # to not find them
34183   if test "x$new_path" = x \
34184       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34185       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34186     new_path=`$CYGPATH -u "$path"`
34187   fi
34188   if test "x$new_path" = x; then
34189     # Oops. Which didn't find the executable.
34190     # The splitting of arguments from the executable at a space might have been incorrect,
34191     # since paths with space are more likely in Windows. Give it another try with the whole
34192     # argument.
34193     path="$complete"
34194     arguments="EOL"
34195     new_path=`$CYGPATH -u "$path"`
34196     new_path=`$WHICH "$new_path" 2> /dev/null`
34197     # bat and cmd files are not always considered executable in cygwin causing which
34198     # to not find them
34199     if test "x$new_path" = x \
34200         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34201         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34202       new_path=`$CYGPATH -u "$path"`
34203     fi
34204     if test "x$new_path" = x; then
34205       # It's still not found. Now this is an unrecoverable error.
34206       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34207 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34208       has_space=`$ECHO "$complete" | $GREP " "`
34209       if test "x$has_space" != x; then
34210         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34211 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34212       fi
34213       as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34214     fi
34215   fi
34216 
34217   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34218   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34219   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34220   # "foo.exe" is OK but "foo" is an error.
34221   #
34222   # This test is therefore slightly more accurate than "test -f" to check for file presence.
34223   # It is also a way to make sure we got the proper file name for the real test later on.
34224   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34225   if test "x$test_shortpath" = x; then
34226     # Short path failed, file does not exist as specified.
34227     # Try adding .exe or .cmd
34228     if test -f "${new_path}.exe"; then
34229       input_to_shortpath="${new_path}.exe"
34230     elif test -f "${new_path}.cmd"; then
34231       input_to_shortpath="${new_path}.cmd"
34232     else
34233       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$new_path\", is invalid." >&5
34234 $as_echo "$as_me: The path of RC, which resolves as \"$new_path\", is invalid." >&6;}
34235       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34236 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34237       as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34238     fi
34239   else
34240     input_to_shortpath="$new_path"
34241   fi
34242 
34243   # Call helper function which possibly converts this using DOS-style short mode.
34244   # If so, the updated path is stored in $new_path.
34245   new_path="$input_to_shortpath"
34246 
34247   input_path="$input_to_shortpath"
34248   # Check if we need to convert this using DOS-style short mode. If the path
34249   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34250   # take no chances and rewrite it.
34251   # Note: m4 eats our [], so we need to use [ and ] instead.
34252   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34253   if test "x$has_forbidden_chars" != x; then
34254     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34255     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34256     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34257     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34258       # Going to short mode and back again did indeed matter. Since short mode is
34259       # case insensitive, let's make it lowercase to improve readability.
34260       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34261       # Now convert it back to Unix-stile (cygpath)
34262       input_path=`$CYGPATH -u "$shortmode_path"`
34263       new_path="$input_path"
34264     fi
34265   fi
34266 
34267   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34268   if test "x$test_cygdrive_prefix" = x; then
34269     # As a simple fix, exclude /usr/bin since it's not a real path.
34270     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34271       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34272       # a path prefixed by /cygdrive for fixpath to work.
34273       new_path="$CYGWIN_ROOT_PATH$input_path"
34274     fi
34275   fi
34276 
34277   # remove trailing .exe if any
34278   new_path="${new_path/%.exe/}"
34279 
34280   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34281 
34282   # First separate the path from the arguments. This will split at the first
34283   # space.
34284   complete="$RC"
34285   path="${complete%% *}"
34286   tmp="$complete EOL"
34287   arguments="${tmp#* }"
34288 
34289   # Input might be given as Windows format, start by converting to
34290   # unix format.
34291   new_path="$path"
34292 
34293   windows_path="$new_path"
34294   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34295     unix_path=`$CYGPATH -u "$windows_path"`
34296     new_path="$unix_path"
34297   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34298     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34299     new_path="$unix_path"
34300   fi
34301 
34302 
34303   # Now try to locate executable using which
34304   new_path=`$WHICH "$new_path" 2> /dev/null`
34305 
34306   if test "x$new_path" = x; then
34307     # Oops. Which didn't find the executable.
34308     # The splitting of arguments from the executable at a space might have been incorrect,
34309     # since paths with space are more likely in Windows. Give it another try with the whole
34310     # argument.
34311     path="$complete"
34312     arguments="EOL"
34313     new_path="$path"
34314 
34315   windows_path="$new_path"
34316   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34317     unix_path=`$CYGPATH -u "$windows_path"`
34318     new_path="$unix_path"
34319   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34320     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34321     new_path="$unix_path"
34322   fi
34323 
34324 
34325     new_path=`$WHICH "$new_path" 2> /dev/null`
34326 
34327     if test "x$new_path" = x; then
34328       # It's still not found. Now this is an unrecoverable error.
34329       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34330 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34331       has_space=`$ECHO "$complete" | $GREP " "`
34332       if test "x$has_space" != x; then
34333         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34334 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34335       fi
34336       as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34337     fi
34338   fi
34339 
34340   # Now new_path has a complete unix path to the binary
34341   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34342     # Keep paths in /bin as-is, but remove trailing .exe if any
34343     new_path="${new_path/%.exe/}"
34344     # Do not save /bin paths to all_fixpath_prefixes!
34345   else
34346     # Not in mixed or Windows style, start by that.
34347     new_path=`cmd //c echo $new_path`
34348 
34349   input_path="$new_path"
34350   # Check if we need to convert this using DOS-style short mode. If the path
34351   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34352   # take no chances and rewrite it.
34353   # Note: m4 eats our [], so we need to use [ and ] instead.
34354   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34355   if test "x$has_forbidden_chars" != x; then
34356     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34357     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34358   fi
34359 
34360     # Output is in $new_path
34361 
34362   windows_path="$new_path"
34363   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34364     unix_path=`$CYGPATH -u "$windows_path"`
34365     new_path="$unix_path"
34366   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34367     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34368     new_path="$unix_path"
34369   fi
34370 
34371     # remove trailing .exe if any
34372     new_path="${new_path/%.exe/}"
34373 
34374     # Save the first 10 bytes of this path to the storage, so fixpath can work.
34375     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34376   fi
34377 
34378   else
34379     # We're on a posix platform. Hooray! :)
34380     # First separate the path from the arguments. This will split at the first
34381     # space.
34382     complete="$RC"
34383     path="${complete%% *}"
34384     tmp="$complete EOL"
34385     arguments="${tmp#* }"
34386 
34387     # Cannot rely on the command "which" here since it doesn't always work.
34388     is_absolute_path=`$ECHO "$path" | $GREP ^/`
34389     if test -z "$is_absolute_path"; then
34390       # Path to executable is not absolute. Find it.
34391       IFS_save="$IFS"
34392       IFS=:
34393       for p in $PATH; do
34394         if test -f "$p/$path" && test -x "$p/$path"; then
34395           new_path="$p/$path"
34396           break
34397         fi
34398       done
34399       IFS="$IFS_save"
34400     else
34401       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving RC (as $path) failed, using $path directly." >&5
34402 $as_echo "$as_me: Resolving RC (as $path) failed, using $path directly." >&6;}
34403       new_path="$path"
34404     fi
34405 
34406     if test "x$new_path" = x; then
34407       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34408 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34409       has_space=`$ECHO "$complete" | $GREP " "`
34410       if test "x$has_space" != x; then
34411         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
34412 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
34413       fi
34414       as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34415     fi
34416   fi
34417 
34418   # Now join together the path and the arguments once again
34419   if test "x$arguments" != xEOL; then
34420     new_complete="$new_path ${arguments% *}"
34421   else
34422     new_complete="$new_path"
34423   fi
34424 
34425   if test "x$complete" != "x$new_complete"; then
34426     RC="$new_complete"
34427     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting RC to \"$new_complete\"" >&5
34428 $as_echo "$as_me: Rewriting RC to \"$new_complete\"" >&6;}
34429   fi
34430 
34431 
34432     # For hotspot, we need these in Windows mixed path,
34433     # so rewrite them all. Need added .exe suffix.
34434     HOTSPOT_CXX="$CXX.exe"
34435     HOTSPOT_LD="$LD.exe"
34436     HOTSPOT_MT="$MT.exe"
34437     HOTSPOT_RC="$RC.exe"
34438 
34439   unix_path="$HOTSPOT_CXX"
34440   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34441     windows_path=`$CYGPATH -m "$unix_path"`
34442     HOTSPOT_CXX="$windows_path"
34443   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34444     windows_path=`cmd //c echo $unix_path`
34445     HOTSPOT_CXX="$windows_path"
34446   fi
34447 
34448 
34449   unix_path="$HOTSPOT_LD"
34450   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34451     windows_path=`$CYGPATH -m "$unix_path"`
34452     HOTSPOT_LD="$windows_path"
34453   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34454     windows_path=`cmd //c echo $unix_path`
34455     HOTSPOT_LD="$windows_path"
34456   fi
34457 
34458 
34459   unix_path="$HOTSPOT_MT"
34460   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34461     windows_path=`$CYGPATH -m "$unix_path"`
34462     HOTSPOT_MT="$windows_path"
34463   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34464     windows_path=`cmd //c echo $unix_path`
34465     HOTSPOT_MT="$windows_path"
34466   fi
34467 
34468 
34469   unix_path="$HOTSPOT_RC"
34470   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34471     windows_path=`$CYGPATH -m "$unix_path"`
34472     HOTSPOT_RC="$windows_path"
34473   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34474     windows_path=`cmd //c echo $unix_path`
34475     HOTSPOT_RC="$windows_path"
34476   fi
34477 
34478 
34479 
34480 
34481     RC_FLAGS="-nologo -l 0x409 -r"
34482     if test "x$VARIANT" = xOPT; then :
34483 
34484     RC_FLAGS="$RC_FLAGS -d NDEBUG"
34485 
34486 fi
34487 
34488   # The version variables used to create RC_FLAGS may be overridden
34489   # in a custom configure script, or possibly the command line.
34490   # Let those variables be expanded at make time in spec.gmk.
34491   # The \$ are escaped to the shell, and the $(...) variables
34492   # are evaluated by make.
34493   RC_FLAGS="$RC_FLAGS \
34494       -d \"JDK_BUILD_ID=\$(FULL_VERSION)\" \
34495       -d \"JDK_COMPANY=\$(COMPANY_NAME)\" \
34496       -d \"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \
34497       -d \"JDK_VER=\$(JDK_MINOR_VERSION).\$(JDK_MICRO_VERSION).\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0).\$(COOKED_BUILD_NUMBER)\" \
34498       -d \"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \
34499       -d \"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(JDK_MINOR_VERSION) \$(JDK_UPDATE_META_TAG)\" \
34500       -d \"JDK_FVER=\$(JDK_MINOR_VERSION),\$(JDK_MICRO_VERSION),\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0),\$(COOKED_BUILD_NUMBER)\""
34501 
34502   # lib.exe is used to create static libraries.
34503   # Extract the first word of "lib", so it can be a program name with args.
34504 set dummy lib; ac_word=$2
34505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34506 $as_echo_n "checking for $ac_word... " >&6; }
34507 if ${ac_cv_prog_WINAR+:} false; then :
34508   $as_echo_n "(cached) " >&6
34509 else
34510   if test -n "$WINAR"; then
34511   ac_cv_prog_WINAR="$WINAR" # Let the user override the test.
34512 else
34513 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34514 for as_dir in $PATH
34515 do
34516   IFS=$as_save_IFS
34517   test -z "$as_dir" && as_dir=.
34518     for ac_exec_ext in '' $ac_executable_extensions; do
34519   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34520     ac_cv_prog_WINAR="lib"
34521     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34522     break 2
34523   fi
34524 done
34525   done
34526 IFS=$as_save_IFS
34527 
34528 fi
34529 fi
34530 WINAR=$ac_cv_prog_WINAR
34531 if test -n "$WINAR"; then
34532   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINAR" >&5
34533 $as_echo "$WINAR" >&6; }
34534 else
34535   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34536 $as_echo "no" >&6; }
34537 fi
34538 
34539 
34540 
34541   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34542 
34543   # First separate the path from the arguments. This will split at the first
34544   # space.
34545   complete="$WINAR"
34546   path="${complete%% *}"
34547   tmp="$complete EOL"
34548   arguments="${tmp#* }"
34549 
34550   # Input might be given as Windows format, start by converting to
34551   # unix format.
34552   new_path=`$CYGPATH -u "$path"`
34553 
34554   # Now try to locate executable using which
34555   new_path=`$WHICH "$new_path" 2> /dev/null`
34556   # bat and cmd files are not always considered executable in cygwin causing which
34557   # to not find them
34558   if test "x$new_path" = x \
34559       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34560       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34561     new_path=`$CYGPATH -u "$path"`
34562   fi
34563   if test "x$new_path" = x; then
34564     # Oops. Which didn't find the executable.
34565     # The splitting of arguments from the executable at a space might have been incorrect,
34566     # since paths with space are more likely in Windows. Give it another try with the whole
34567     # argument.
34568     path="$complete"
34569     arguments="EOL"
34570     new_path=`$CYGPATH -u "$path"`
34571     new_path=`$WHICH "$new_path" 2> /dev/null`
34572     # bat and cmd files are not always considered executable in cygwin causing which
34573     # to not find them
34574     if test "x$new_path" = x \
34575         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34576         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34577       new_path=`$CYGPATH -u "$path"`
34578     fi
34579     if test "x$new_path" = x; then
34580       # It's still not found. Now this is an unrecoverable error.
34581       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINAR, which resolves as \"$complete\", is not found." >&5
34582 $as_echo "$as_me: The path of WINAR, which resolves as \"$complete\", is not found." >&6;}
34583       has_space=`$ECHO "$complete" | $GREP " "`
34584       if test "x$has_space" != x; then
34585         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34586 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34587       fi
34588       as_fn_error $? "Cannot locate the the path of WINAR" "$LINENO" 5
34589     fi
34590   fi
34591 
34592   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34593   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34594   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34595   # "foo.exe" is OK but "foo" is an error.
34596   #
34597   # This test is therefore slightly more accurate than "test -f" to check for file presence.
34598   # It is also a way to make sure we got the proper file name for the real test later on.
34599   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34600   if test "x$test_shortpath" = x; then
34601     # Short path failed, file does not exist as specified.
34602     # Try adding .exe or .cmd
34603     if test -f "${new_path}.exe"; then
34604       input_to_shortpath="${new_path}.exe"
34605     elif test -f "${new_path}.cmd"; then
34606       input_to_shortpath="${new_path}.cmd"
34607     else
34608       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINAR, which resolves as \"$new_path\", is invalid." >&5
34609 $as_echo "$as_me: The path of WINAR, which resolves as \"$new_path\", is invalid." >&6;}
34610       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34611 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34612       as_fn_error $? "Cannot locate the the path of WINAR" "$LINENO" 5
34613     fi
34614   else
34615     input_to_shortpath="$new_path"
34616   fi
34617 
34618   # Call helper function which possibly converts this using DOS-style short mode.
34619   # If so, the updated path is stored in $new_path.
34620   new_path="$input_to_shortpath"
34621 
34622   input_path="$input_to_shortpath"
34623   # Check if we need to convert this using DOS-style short mode. If the path
34624   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34625   # take no chances and rewrite it.
34626   # Note: m4 eats our [], so we need to use [ and ] instead.
34627   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34628   if test "x$has_forbidden_chars" != x; then
34629     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34630     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34631     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34632     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34633       # Going to short mode and back again did indeed matter. Since short mode is
34634       # case insensitive, let's make it lowercase to improve readability.
34635       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34636       # Now convert it back to Unix-stile (cygpath)
34637       input_path=`$CYGPATH -u "$shortmode_path"`
34638       new_path="$input_path"
34639     fi
34640   fi
34641 
34642   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34643   if test "x$test_cygdrive_prefix" = x; then
34644     # As a simple fix, exclude /usr/bin since it's not a real path.
34645     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34646       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34647       # a path prefixed by /cygdrive for fixpath to work.
34648       new_path="$CYGWIN_ROOT_PATH$input_path"
34649     fi
34650   fi
34651 
34652   # remove trailing .exe if any
34653   new_path="${new_path/%.exe/}"
34654 
34655   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34656 
34657   # First separate the path from the arguments. This will split at the first
34658   # space.
34659   complete="$WINAR"
34660   path="${complete%% *}"
34661   tmp="$complete EOL"
34662   arguments="${tmp#* }"
34663 
34664   # Input might be given as Windows format, start by converting to
34665   # unix format.
34666   new_path="$path"
34667 
34668   windows_path="$new_path"
34669   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34670     unix_path=`$CYGPATH -u "$windows_path"`
34671     new_path="$unix_path"
34672   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34673     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34674     new_path="$unix_path"
34675   fi
34676 
34677 
34678   # Now try to locate executable using which
34679   new_path=`$WHICH "$new_path" 2> /dev/null`
34680 
34681   if test "x$new_path" = x; then
34682     # Oops. Which didn't find the executable.
34683     # The splitting of arguments from the executable at a space might have been incorrect,
34684     # since paths with space are more likely in Windows. Give it another try with the whole
34685     # argument.
34686     path="$complete"
34687     arguments="EOL"
34688     new_path="$path"
34689 
34690   windows_path="$new_path"
34691   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34692     unix_path=`$CYGPATH -u "$windows_path"`
34693     new_path="$unix_path"
34694   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34695     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34696     new_path="$unix_path"
34697   fi
34698 
34699 
34700     new_path=`$WHICH "$new_path" 2> /dev/null`
34701 
34702     if test "x$new_path" = x; then
34703       # It's still not found. Now this is an unrecoverable error.
34704       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINAR, which resolves as \"$complete\", is not found." >&5
34705 $as_echo "$as_me: The path of WINAR, which resolves as \"$complete\", is not found." >&6;}
34706       has_space=`$ECHO "$complete" | $GREP " "`
34707       if test "x$has_space" != x; then
34708         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34709 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34710       fi
34711       as_fn_error $? "Cannot locate the the path of WINAR" "$LINENO" 5
34712     fi
34713   fi
34714 
34715   # Now new_path has a complete unix path to the binary
34716   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34717     # Keep paths in /bin as-is, but remove trailing .exe if any
34718     new_path="${new_path/%.exe/}"
34719     # Do not save /bin paths to all_fixpath_prefixes!
34720   else
34721     # Not in mixed or Windows style, start by that.
34722     new_path=`cmd //c echo $new_path`
34723 
34724   input_path="$new_path"
34725   # Check if we need to convert this using DOS-style short mode. If the path
34726   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34727   # take no chances and rewrite it.
34728   # Note: m4 eats our [], so we need to use [ and ] instead.
34729   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34730   if test "x$has_forbidden_chars" != x; then
34731     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34732     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34733   fi
34734 
34735     # Output is in $new_path
34736 
34737   windows_path="$new_path"
34738   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34739     unix_path=`$CYGPATH -u "$windows_path"`
34740     new_path="$unix_path"
34741   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34742     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34743     new_path="$unix_path"
34744   fi
34745 
34746     # remove trailing .exe if any
34747     new_path="${new_path/%.exe/}"
34748 
34749     # Save the first 10 bytes of this path to the storage, so fixpath can work.
34750     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34751   fi
34752 
34753   else
34754     # We're on a posix platform. Hooray! :)
34755     # First separate the path from the arguments. This will split at the first
34756     # space.
34757     complete="$WINAR"
34758     path="${complete%% *}"
34759     tmp="$complete EOL"
34760     arguments="${tmp#* }"
34761 
34762     # Cannot rely on the command "which" here since it doesn't always work.
34763     is_absolute_path=`$ECHO "$path" | $GREP ^/`
34764     if test -z "$is_absolute_path"; then
34765       # Path to executable is not absolute. Find it.
34766       IFS_save="$IFS"
34767       IFS=:
34768       for p in $PATH; do
34769         if test -f "$p/$path" && test -x "$p/$path"; then
34770           new_path="$p/$path"
34771           break
34772         fi
34773       done
34774       IFS="$IFS_save"
34775     else
34776       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving WINAR (as $path) failed, using $path directly." >&5
34777 $as_echo "$as_me: Resolving WINAR (as $path) failed, using $path directly." >&6;}
34778       new_path="$path"
34779     fi
34780 
34781     if test "x$new_path" = x; then
34782       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of WINAR, which resolves as \"$complete\", is not found." >&5
34783 $as_echo "$as_me: The path of WINAR, which resolves as \"$complete\", is not found." >&6;}
34784       has_space=`$ECHO "$complete" | $GREP " "`
34785       if test "x$has_space" != x; then
34786         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
34787 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
34788       fi
34789       as_fn_error $? "Cannot locate the the path of WINAR" "$LINENO" 5
34790     fi
34791   fi
34792 
34793   # Now join together the path and the arguments once again
34794   if test "x$arguments" != xEOL; then
34795     new_complete="$new_path ${arguments% *}"
34796   else
34797     new_complete="$new_path"
34798   fi
34799 
34800   if test "x$complete" != "x$new_complete"; then
34801     WINAR="$new_complete"
34802     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting WINAR to \"$new_complete\"" >&5
34803 $as_echo "$as_me: Rewriting WINAR to \"$new_complete\"" >&6;}
34804   fi
34805 
34806   AR="$WINAR"
34807   ARFLAGS="-nologo -NODEFAULTLIB:MSVCRT"
34808 
34809   # Extract the first word of "dumpbin", so it can be a program name with args.
34810 set dummy dumpbin; ac_word=$2
34811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34812 $as_echo_n "checking for $ac_word... " >&6; }
34813 if ${ac_cv_prog_DUMPBIN+:} false; then :
34814   $as_echo_n "(cached) " >&6
34815 else
34816   if test -n "$DUMPBIN"; then
34817   ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
34818 else
34819 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34820 for as_dir in $PATH
34821 do
34822   IFS=$as_save_IFS
34823   test -z "$as_dir" && as_dir=.
34824     for ac_exec_ext in '' $ac_executable_extensions; do
34825   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34826     ac_cv_prog_DUMPBIN="dumpbin"
34827     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34828     break 2
34829   fi
34830 done
34831   done
34832 IFS=$as_save_IFS
34833 
34834 fi
34835 fi
34836 DUMPBIN=$ac_cv_prog_DUMPBIN
34837 if test -n "$DUMPBIN"; then
34838   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
34839 $as_echo "$DUMPBIN" >&6; }
34840 else
34841   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34842 $as_echo "no" >&6; }
34843 fi
34844 
34845 
34846 
34847   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34848 
34849   # First separate the path from the arguments. This will split at the first
34850   # space.
34851   complete="$DUMPBIN"
34852   path="${complete%% *}"
34853   tmp="$complete EOL"
34854   arguments="${tmp#* }"
34855 
34856   # Input might be given as Windows format, start by converting to
34857   # unix format.
34858   new_path=`$CYGPATH -u "$path"`
34859 
34860   # Now try to locate executable using which
34861   new_path=`$WHICH "$new_path" 2> /dev/null`
34862   # bat and cmd files are not always considered executable in cygwin causing which
34863   # to not find them
34864   if test "x$new_path" = x \
34865       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34866       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34867     new_path=`$CYGPATH -u "$path"`
34868   fi
34869   if test "x$new_path" = x; then
34870     # Oops. Which didn't find the executable.
34871     # The splitting of arguments from the executable at a space might have been incorrect,
34872     # since paths with space are more likely in Windows. Give it another try with the whole
34873     # argument.
34874     path="$complete"
34875     arguments="EOL"
34876     new_path=`$CYGPATH -u "$path"`
34877     new_path=`$WHICH "$new_path" 2> /dev/null`
34878     # bat and cmd files are not always considered executable in cygwin causing which
34879     # to not find them
34880     if test "x$new_path" = x \
34881         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34882         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34883       new_path=`$CYGPATH -u "$path"`
34884     fi
34885     if test "x$new_path" = x; then
34886       # It's still not found. Now this is an unrecoverable error.
34887       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
34888 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
34889       has_space=`$ECHO "$complete" | $GREP " "`
34890       if test "x$has_space" != x; then
34891         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34892 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34893       fi
34894       as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34895     fi
34896   fi
34897 
34898   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34899   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34900   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34901   # "foo.exe" is OK but "foo" is an error.
34902   #
34903   # This test is therefore slightly more accurate than "test -f" to check for file presence.
34904   # It is also a way to make sure we got the proper file name for the real test later on.
34905   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34906   if test "x$test_shortpath" = x; then
34907     # Short path failed, file does not exist as specified.
34908     # Try adding .exe or .cmd
34909     if test -f "${new_path}.exe"; then
34910       input_to_shortpath="${new_path}.exe"
34911     elif test -f "${new_path}.cmd"; then
34912       input_to_shortpath="${new_path}.cmd"
34913     else
34914       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&5
34915 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&6;}
34916       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34917 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34918       as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34919     fi
34920   else
34921     input_to_shortpath="$new_path"
34922   fi
34923 
34924   # Call helper function which possibly converts this using DOS-style short mode.
34925   # If so, the updated path is stored in $new_path.
34926   new_path="$input_to_shortpath"
34927 
34928   input_path="$input_to_shortpath"
34929   # Check if we need to convert this using DOS-style short mode. If the path
34930   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34931   # take no chances and rewrite it.
34932   # Note: m4 eats our [], so we need to use [ and ] instead.
34933   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34934   if test "x$has_forbidden_chars" != x; then
34935     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34936     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34937     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34938     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34939       # Going to short mode and back again did indeed matter. Since short mode is
34940       # case insensitive, let's make it lowercase to improve readability.
34941       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34942       # Now convert it back to Unix-stile (cygpath)
34943       input_path=`$CYGPATH -u "$shortmode_path"`
34944       new_path="$input_path"
34945     fi
34946   fi
34947 
34948   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34949   if test "x$test_cygdrive_prefix" = x; then
34950     # As a simple fix, exclude /usr/bin since it's not a real path.
34951     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34952       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34953       # a path prefixed by /cygdrive for fixpath to work.
34954       new_path="$CYGWIN_ROOT_PATH$input_path"
34955     fi
34956   fi
34957 
34958   # remove trailing .exe if any
34959   new_path="${new_path/%.exe/}"
34960 
34961   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34962 
34963   # First separate the path from the arguments. This will split at the first
34964   # space.
34965   complete="$DUMPBIN"
34966   path="${complete%% *}"
34967   tmp="$complete EOL"
34968   arguments="${tmp#* }"
34969 
34970   # Input might be given as Windows format, start by converting to
34971   # unix format.
34972   new_path="$path"
34973 
34974   windows_path="$new_path"
34975   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34976     unix_path=`$CYGPATH -u "$windows_path"`
34977     new_path="$unix_path"
34978   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34979     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34980     new_path="$unix_path"
34981   fi
34982 
34983 
34984   # Now try to locate executable using which
34985   new_path=`$WHICH "$new_path" 2> /dev/null`
34986 
34987   if test "x$new_path" = x; then
34988     # Oops. Which didn't find the executable.
34989     # The splitting of arguments from the executable at a space might have been incorrect,
34990     # since paths with space are more likely in Windows. Give it another try with the whole
34991     # argument.
34992     path="$complete"
34993     arguments="EOL"
34994     new_path="$path"
34995 
34996   windows_path="$new_path"
34997   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34998     unix_path=`$CYGPATH -u "$windows_path"`
34999     new_path="$unix_path"
35000   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35001     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35002     new_path="$unix_path"
35003   fi
35004 
35005 
35006     new_path=`$WHICH "$new_path" 2> /dev/null`
35007 
35008     if test "x$new_path" = x; then
35009       # It's still not found. Now this is an unrecoverable error.
35010       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
35011 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
35012       has_space=`$ECHO "$complete" | $GREP " "`
35013       if test "x$has_space" != x; then
35014         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35015 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35016       fi
35017       as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
35018     fi
35019   fi
35020 
35021   # Now new_path has a complete unix path to the binary
35022   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
35023     # Keep paths in /bin as-is, but remove trailing .exe if any
35024     new_path="${new_path/%.exe/}"
35025     # Do not save /bin paths to all_fixpath_prefixes!
35026   else
35027     # Not in mixed or Windows style, start by that.
35028     new_path=`cmd //c echo $new_path`
35029 
35030   input_path="$new_path"
35031   # Check if we need to convert this using DOS-style short mode. If the path
35032   # contains just simple characters, use it. Otherwise (spaces, weird characters),
35033   # take no chances and rewrite it.
35034   # Note: m4 eats our [], so we need to use [ and ] instead.
35035   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
35036   if test "x$has_forbidden_chars" != x; then
35037     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35038     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35039   fi
35040 
35041     # Output is in $new_path
35042 
35043   windows_path="$new_path"
35044   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35045     unix_path=`$CYGPATH -u "$windows_path"`
35046     new_path="$unix_path"
35047   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35048     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35049     new_path="$unix_path"
35050   fi
35051 
35052     # remove trailing .exe if any
35053     new_path="${new_path/%.exe/}"
35054 
35055     # Save the first 10 bytes of this path to the storage, so fixpath can work.
35056     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
35057   fi
35058 
35059   else
35060     # We're on a posix platform. Hooray! :)
35061     # First separate the path from the arguments. This will split at the first
35062     # space.
35063     complete="$DUMPBIN"
35064     path="${complete%% *}"
35065     tmp="$complete EOL"
35066     arguments="${tmp#* }"
35067 
35068     # Cannot rely on the command "which" here since it doesn't always work.
35069     is_absolute_path=`$ECHO "$path" | $GREP ^/`
35070     if test -z "$is_absolute_path"; then
35071       # Path to executable is not absolute. Find it.
35072       IFS_save="$IFS"
35073       IFS=:
35074       for p in $PATH; do
35075         if test -f "$p/$path" && test -x "$p/$path"; then
35076           new_path="$p/$path"
35077           break
35078         fi
35079       done
35080       IFS="$IFS_save"
35081     else
35082       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving DUMPBIN (as $path) failed, using $path directly." >&5
35083 $as_echo "$as_me: Resolving DUMPBIN (as $path) failed, using $path directly." >&6;}
35084       new_path="$path"
35085     fi
35086 
35087     if test "x$new_path" = x; then
35088       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
35089 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
35090       has_space=`$ECHO "$complete" | $GREP " "`
35091       if test "x$has_space" != x; then
35092         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
35093 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
35094       fi
35095       as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
35096     fi
35097   fi
35098 
35099   # Now join together the path and the arguments once again
35100   if test "x$arguments" != xEOL; then
35101     new_complete="$new_path ${arguments% *}"
35102   else
35103     new_complete="$new_path"
35104   fi
35105 
35106   if test "x$complete" != "x$new_complete"; then
35107     DUMPBIN="$new_complete"
35108     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DUMPBIN to \"$new_complete\"" >&5
35109 $as_echo "$as_me: Rewriting DUMPBIN to \"$new_complete\"" >&6;}
35110   fi
35111 
35112 
35113       COMPILER_TYPE=CL
35114       CCXXFLAGS="$CCXXFLAGS -nologo"
35115 
35116 fi
35117 
35118 
35119 
35120   ac_ext=c
35121 ac_cpp='$CPP $CPPFLAGS'
35122 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
35123 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
35124 ac_compiler_gnu=$ac_cv_c_compiler_gnu
35125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
35126 $as_echo_n "checking how to run the C preprocessor... " >&6; }
35127 # On Suns, sometimes $CPP names a directory.
35128 if test -n "$CPP" && test -d "$CPP"; then
35129   CPP=
35130 fi
35131 if test -z "$CPP"; then
35132   if ${ac_cv_prog_CPP+:} false; then :
35133   $as_echo_n "(cached) " >&6
35134 else
35135       # Double quotes because CPP needs to be expanded
35136     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
35137     do
35138       ac_preproc_ok=false
35139 for ac_c_preproc_warn_flag in '' yes
35140 do
35141   # Use a header file that comes with gcc, so configuring glibc
35142   # with a fresh cross-compiler works.
35143   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
35144   # <limits.h> exists even on freestanding compilers.
35145   # On the NeXT, cc -E runs the code through the compiler's parser,
35146   # not just through cpp. "Syntax error" is here to catch this case.
35147   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35148 /* end confdefs.h.  */
35149 #ifdef __STDC__
35150 # include <limits.h>
35151 #else
35152 # include <assert.h>
35153 #endif
35154                      Syntax error
35155 _ACEOF
35156 if ac_fn_c_try_cpp "$LINENO"; then :
35157 
35158 else
35159   # Broken: fails on valid input.
35160 continue
35161 fi
35162 rm -f conftest.err conftest.i conftest.$ac_ext
35163 
35164   # OK, works on sane cases.  Now check whether nonexistent headers
35165   # can be detected and how.
35166   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35167 /* end confdefs.h.  */
35168 #include <ac_nonexistent.h>
35169 _ACEOF
35170 if ac_fn_c_try_cpp "$LINENO"; then :
35171   # Broken: success on invalid input.
35172 continue
35173 else
35174   # Passes both tests.
35175 ac_preproc_ok=:
35176 break
35177 fi
35178 rm -f conftest.err conftest.i conftest.$ac_ext
35179 
35180 done
35181 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
35182 rm -f conftest.i conftest.err conftest.$ac_ext
35183 if $ac_preproc_ok; then :
35184   break
35185 fi
35186 
35187     done
35188     ac_cv_prog_CPP=$CPP
35189 
35190 fi
35191   CPP=$ac_cv_prog_CPP
35192 else
35193   ac_cv_prog_CPP=$CPP
35194 fi
35195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
35196 $as_echo "$CPP" >&6; }
35197 ac_preproc_ok=false
35198 for ac_c_preproc_warn_flag in '' yes
35199 do
35200   # Use a header file that comes with gcc, so configuring glibc
35201   # with a fresh cross-compiler works.
35202   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
35203   # <limits.h> exists even on freestanding compilers.
35204   # On the NeXT, cc -E runs the code through the compiler's parser,
35205   # not just through cpp. "Syntax error" is here to catch this case.
35206   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35207 /* end confdefs.h.  */
35208 #ifdef __STDC__
35209 # include <limits.h>
35210 #else
35211 # include <assert.h>
35212 #endif
35213                      Syntax error
35214 _ACEOF
35215 if ac_fn_c_try_cpp "$LINENO"; then :
35216 
35217 else
35218   # Broken: fails on valid input.
35219 continue
35220 fi
35221 rm -f conftest.err conftest.i conftest.$ac_ext
35222 
35223   # OK, works on sane cases.  Now check whether nonexistent headers
35224   # can be detected and how.
35225   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35226 /* end confdefs.h.  */
35227 #include <ac_nonexistent.h>
35228 _ACEOF
35229 if ac_fn_c_try_cpp "$LINENO"; then :
35230   # Broken: success on invalid input.
35231 continue
35232 else
35233   # Passes both tests.
35234 ac_preproc_ok=:
35235 break
35236 fi
35237 rm -f conftest.err conftest.i conftest.$ac_ext
35238 
35239 done
35240 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
35241 rm -f conftest.i conftest.err conftest.$ac_ext
35242 if $ac_preproc_ok; then :
35243 
35244 else
35245   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
35246 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
35247 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
35248 See \`config.log' for more details" "$LINENO" 5; }
35249 fi
35250 
35251 ac_ext=cpp
35252 ac_cpp='$CXXCPP $CPPFLAGS'
35253 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
35254 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
35255 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
35256 
35257 
35258   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35259 
35260   # First separate the path from the arguments. This will split at the first
35261   # space.
35262   complete="$CPP"
35263   path="${complete%% *}"
35264   tmp="$complete EOL"
35265   arguments="${tmp#* }"
35266 
35267   # Input might be given as Windows format, start by converting to
35268   # unix format.
35269   new_path=`$CYGPATH -u "$path"`
35270 
35271   # Now try to locate executable using which
35272   new_path=`$WHICH "$new_path" 2> /dev/null`
35273   # bat and cmd files are not always considered executable in cygwin causing which
35274   # to not find them
35275   if test "x$new_path" = x \
35276       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35277       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35278     new_path=`$CYGPATH -u "$path"`
35279   fi
35280   if test "x$new_path" = x; then
35281     # Oops. Which didn't find the executable.
35282     # The splitting of arguments from the executable at a space might have been incorrect,
35283     # since paths with space are more likely in Windows. Give it another try with the whole
35284     # argument.
35285     path="$complete"
35286     arguments="EOL"
35287     new_path=`$CYGPATH -u "$path"`
35288     new_path=`$WHICH "$new_path" 2> /dev/null`
35289     # bat and cmd files are not always considered executable in cygwin causing which
35290     # to not find them
35291     if test "x$new_path" = x \
35292         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35293         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35294       new_path=`$CYGPATH -u "$path"`
35295     fi
35296     if test "x$new_path" = x; then
35297       # It's still not found. Now this is an unrecoverable error.
35298       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
35299 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
35300       has_space=`$ECHO "$complete" | $GREP " "`
35301       if test "x$has_space" != x; then
35302         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35303 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35304       fi
35305       as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
35306     fi
35307   fi
35308 
35309   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
35310   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
35311   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
35312   # "foo.exe" is OK but "foo" is an error.
35313   #
35314   # This test is therefore slightly more accurate than "test -f" to check for file presence.
35315   # It is also a way to make sure we got the proper file name for the real test later on.
35316   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
35317   if test "x$test_shortpath" = x; then
35318     # Short path failed, file does not exist as specified.
35319     # Try adding .exe or .cmd
35320     if test -f "${new_path}.exe"; then
35321       input_to_shortpath="${new_path}.exe"
35322     elif test -f "${new_path}.cmd"; then
35323       input_to_shortpath="${new_path}.cmd"
35324     else
35325       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$new_path\", is invalid." >&5
35326 $as_echo "$as_me: The path of CPP, which resolves as \"$new_path\", is invalid." >&6;}
35327       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
35328 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
35329       as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
35330     fi
35331   else
35332     input_to_shortpath="$new_path"
35333   fi
35334 
35335   # Call helper function which possibly converts this using DOS-style short mode.
35336   # If so, the updated path is stored in $new_path.
35337   new_path="$input_to_shortpath"
35338 
35339   input_path="$input_to_shortpath"
35340   # Check if we need to convert this using DOS-style short mode. If the path
35341   # contains just simple characters, use it. Otherwise (spaces, weird characters),
35342   # take no chances and rewrite it.
35343   # Note: m4 eats our [], so we need to use [ and ] instead.
35344   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
35345   if test "x$has_forbidden_chars" != x; then
35346     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35347     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
35348     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
35349     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
35350       # Going to short mode and back again did indeed matter. Since short mode is
35351       # case insensitive, let's make it lowercase to improve readability.
35352       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35353       # Now convert it back to Unix-stile (cygpath)
35354       input_path=`$CYGPATH -u "$shortmode_path"`
35355       new_path="$input_path"
35356     fi
35357   fi
35358 
35359   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
35360   if test "x$test_cygdrive_prefix" = x; then
35361     # As a simple fix, exclude /usr/bin since it's not a real path.
35362     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
35363       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
35364       # a path prefixed by /cygdrive for fixpath to work.
35365       new_path="$CYGWIN_ROOT_PATH$input_path"
35366     fi
35367   fi
35368 
35369   # remove trailing .exe if any
35370   new_path="${new_path/%.exe/}"
35371 
35372   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35373 
35374   # First separate the path from the arguments. This will split at the first
35375   # space.
35376   complete="$CPP"
35377   path="${complete%% *}"
35378   tmp="$complete EOL"
35379   arguments="${tmp#* }"
35380 
35381   # Input might be given as Windows format, start by converting to
35382   # unix format.
35383   new_path="$path"
35384 
35385   windows_path="$new_path"
35386   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35387     unix_path=`$CYGPATH -u "$windows_path"`
35388     new_path="$unix_path"
35389   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35390     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35391     new_path="$unix_path"
35392   fi
35393 
35394 
35395   # Now try to locate executable using which
35396   new_path=`$WHICH "$new_path" 2> /dev/null`
35397 
35398   if test "x$new_path" = x; then
35399     # Oops. Which didn't find the executable.
35400     # The splitting of arguments from the executable at a space might have been incorrect,
35401     # since paths with space are more likely in Windows. Give it another try with the whole
35402     # argument.
35403     path="$complete"
35404     arguments="EOL"
35405     new_path="$path"
35406 
35407   windows_path="$new_path"
35408   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35409     unix_path=`$CYGPATH -u "$windows_path"`
35410     new_path="$unix_path"
35411   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35412     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35413     new_path="$unix_path"
35414   fi
35415 
35416 
35417     new_path=`$WHICH "$new_path" 2> /dev/null`
35418 
35419     if test "x$new_path" = x; then
35420       # It's still not found. Now this is an unrecoverable error.
35421       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
35422 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
35423       has_space=`$ECHO "$complete" | $GREP " "`
35424       if test "x$has_space" != x; then
35425         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35426 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35427       fi
35428       as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
35429     fi
35430   fi
35431 
35432   # Now new_path has a complete unix path to the binary
35433   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
35434     # Keep paths in /bin as-is, but remove trailing .exe if any
35435     new_path="${new_path/%.exe/}"
35436     # Do not save /bin paths to all_fixpath_prefixes!
35437   else
35438     # Not in mixed or Windows style, start by that.
35439     new_path=`cmd //c echo $new_path`
35440 
35441   input_path="$new_path"
35442   # Check if we need to convert this using DOS-style short mode. If the path
35443   # contains just simple characters, use it. Otherwise (spaces, weird characters),
35444   # take no chances and rewrite it.
35445   # Note: m4 eats our [], so we need to use [ and ] instead.
35446   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
35447   if test "x$has_forbidden_chars" != x; then
35448     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35449     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35450   fi
35451 
35452     # Output is in $new_path
35453 
35454   windows_path="$new_path"
35455   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35456     unix_path=`$CYGPATH -u "$windows_path"`
35457     new_path="$unix_path"
35458   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35459     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35460     new_path="$unix_path"
35461   fi
35462 
35463     # remove trailing .exe if any
35464     new_path="${new_path/%.exe/}"
35465 
35466     # Save the first 10 bytes of this path to the storage, so fixpath can work.
35467     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
35468   fi
35469 
35470   else
35471     # We're on a posix platform. Hooray! :)
35472     # First separate the path from the arguments. This will split at the first
35473     # space.
35474     complete="$CPP"
35475     path="${complete%% *}"
35476     tmp="$complete EOL"
35477     arguments="${tmp#* }"
35478 
35479     # Cannot rely on the command "which" here since it doesn't always work.
35480     is_absolute_path=`$ECHO "$path" | $GREP ^/`
35481     if test -z "$is_absolute_path"; then
35482       # Path to executable is not absolute. Find it.
35483       IFS_save="$IFS"
35484       IFS=:
35485       for p in $PATH; do
35486         if test -f "$p/$path" && test -x "$p/$path"; then
35487           new_path="$p/$path"
35488           break
35489         fi
35490       done
35491       IFS="$IFS_save"
35492     else
35493       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving CPP (as $path) failed, using $path directly." >&5
35494 $as_echo "$as_me: Resolving CPP (as $path) failed, using $path directly." >&6;}
35495       new_path="$path"
35496     fi
35497 
35498     if test "x$new_path" = x; then
35499       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
35500 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
35501       has_space=`$ECHO "$complete" | $GREP " "`
35502       if test "x$has_space" != x; then
35503         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
35504 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
35505       fi
35506       as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
35507     fi
35508   fi
35509 
35510   # Now join together the path and the arguments once again
35511   if test "x$arguments" != xEOL; then
35512     new_complete="$new_path ${arguments% *}"
35513   else
35514     new_complete="$new_path"
35515   fi
35516 
35517   if test "x$complete" != "x$new_complete"; then
35518     CPP="$new_complete"
35519     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CPP to \"$new_complete\"" >&5
35520 $as_echo "$as_me: Rewriting CPP to \"$new_complete\"" >&6;}
35521   fi
35522 
35523 
35524   ac_ext=cpp
35525 ac_cpp='$CXXCPP $CPPFLAGS'
35526 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
35527 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
35528 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
35529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
35530 $as_echo_n "checking how to run the C++ preprocessor... " >&6; }
35531 if test -z "$CXXCPP"; then
35532   if ${ac_cv_prog_CXXCPP+:} false; then :
35533   $as_echo_n "(cached) " >&6
35534 else
35535       # Double quotes because CXXCPP needs to be expanded
35536     for CXXCPP in "$CXX -E" "/lib/cpp"
35537     do
35538       ac_preproc_ok=false
35539 for ac_cxx_preproc_warn_flag in '' yes
35540 do
35541   # Use a header file that comes with gcc, so configuring glibc
35542   # with a fresh cross-compiler works.
35543   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
35544   # <limits.h> exists even on freestanding compilers.
35545   # On the NeXT, cc -E runs the code through the compiler's parser,
35546   # not just through cpp. "Syntax error" is here to catch this case.
35547   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35548 /* end confdefs.h.  */
35549 #ifdef __STDC__
35550 # include <limits.h>
35551 #else
35552 # include <assert.h>
35553 #endif
35554                      Syntax error
35555 _ACEOF
35556 if ac_fn_cxx_try_cpp "$LINENO"; then :
35557 
35558 else
35559   # Broken: fails on valid input.
35560 continue
35561 fi
35562 rm -f conftest.err conftest.i conftest.$ac_ext
35563 
35564   # OK, works on sane cases.  Now check whether nonexistent headers
35565   # can be detected and how.
35566   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35567 /* end confdefs.h.  */
35568 #include <ac_nonexistent.h>
35569 _ACEOF
35570 if ac_fn_cxx_try_cpp "$LINENO"; then :
35571   # Broken: success on invalid input.
35572 continue
35573 else
35574   # Passes both tests.
35575 ac_preproc_ok=:
35576 break
35577 fi
35578 rm -f conftest.err conftest.i conftest.$ac_ext
35579 
35580 done
35581 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
35582 rm -f conftest.i conftest.err conftest.$ac_ext
35583 if $ac_preproc_ok; then :
35584   break
35585 fi
35586 
35587     done
35588     ac_cv_prog_CXXCPP=$CXXCPP
35589 
35590 fi
35591   CXXCPP=$ac_cv_prog_CXXCPP
35592 else
35593   ac_cv_prog_CXXCPP=$CXXCPP
35594 fi
35595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
35596 $as_echo "$CXXCPP" >&6; }
35597 ac_preproc_ok=false
35598 for ac_cxx_preproc_warn_flag in '' yes
35599 do
35600   # Use a header file that comes with gcc, so configuring glibc
35601   # with a fresh cross-compiler works.
35602   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
35603   # <limits.h> exists even on freestanding compilers.
35604   # On the NeXT, cc -E runs the code through the compiler's parser,
35605   # not just through cpp. "Syntax error" is here to catch this case.
35606   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35607 /* end confdefs.h.  */
35608 #ifdef __STDC__
35609 # include <limits.h>
35610 #else
35611 # include <assert.h>
35612 #endif
35613                      Syntax error
35614 _ACEOF
35615 if ac_fn_cxx_try_cpp "$LINENO"; then :
35616 
35617 else
35618   # Broken: fails on valid input.
35619 continue
35620 fi
35621 rm -f conftest.err conftest.i conftest.$ac_ext
35622 
35623   # OK, works on sane cases.  Now check whether nonexistent headers
35624   # can be detected and how.
35625   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35626 /* end confdefs.h.  */
35627 #include <ac_nonexistent.h>
35628 _ACEOF
35629 if ac_fn_cxx_try_cpp "$LINENO"; then :
35630   # Broken: success on invalid input.
35631 continue
35632 else
35633   # Passes both tests.
35634 ac_preproc_ok=:
35635 break
35636 fi
35637 rm -f conftest.err conftest.i conftest.$ac_ext
35638 
35639 done
35640 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
35641 rm -f conftest.i conftest.err conftest.$ac_ext
35642 if $ac_preproc_ok; then :
35643 
35644 else
35645   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
35646 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
35647 as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
35648 See \`config.log' for more details" "$LINENO" 5; }
35649 fi
35650 
35651 ac_ext=cpp
35652 ac_cpp='$CXXCPP $CPPFLAGS'
35653 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
35654 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
35655 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
35656 
35657 
35658   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35659 
35660   # First separate the path from the arguments. This will split at the first
35661   # space.
35662   complete="$CXXCPP"
35663   path="${complete%% *}"
35664   tmp="$complete EOL"
35665   arguments="${tmp#* }"
35666 
35667   # Input might be given as Windows format, start by converting to
35668   # unix format.
35669   new_path=`$CYGPATH -u "$path"`
35670 
35671   # Now try to locate executable using which
35672   new_path=`$WHICH "$new_path" 2> /dev/null`
35673   # bat and cmd files are not always considered executable in cygwin causing which
35674   # to not find them
35675   if test "x$new_path" = x \
35676       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35677       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35678     new_path=`$CYGPATH -u "$path"`
35679   fi
35680   if test "x$new_path" = x; then
35681     # Oops. Which didn't find the executable.
35682     # The splitting of arguments from the executable at a space might have been incorrect,
35683     # since paths with space are more likely in Windows. Give it another try with the whole
35684     # argument.
35685     path="$complete"
35686     arguments="EOL"
35687     new_path=`$CYGPATH -u "$path"`
35688     new_path=`$WHICH "$new_path" 2> /dev/null`
35689     # bat and cmd files are not always considered executable in cygwin causing which
35690     # to not find them
35691     if test "x$new_path" = x \
35692         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35693         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35694       new_path=`$CYGPATH -u "$path"`
35695     fi
35696     if test "x$new_path" = x; then
35697       # It's still not found. Now this is an unrecoverable error.
35698       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
35699 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
35700       has_space=`$ECHO "$complete" | $GREP " "`
35701       if test "x$has_space" != x; then
35702         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35703 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35704       fi
35705       as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
35706     fi
35707   fi
35708 
35709   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
35710   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
35711   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
35712   # "foo.exe" is OK but "foo" is an error.
35713   #
35714   # This test is therefore slightly more accurate than "test -f" to check for file presence.
35715   # It is also a way to make sure we got the proper file name for the real test later on.
35716   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
35717   if test "x$test_shortpath" = x; then
35718     # Short path failed, file does not exist as specified.
35719     # Try adding .exe or .cmd
35720     if test -f "${new_path}.exe"; then
35721       input_to_shortpath="${new_path}.exe"
35722     elif test -f "${new_path}.cmd"; then
35723       input_to_shortpath="${new_path}.cmd"
35724     else
35725       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&5
35726 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&6;}
35727       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
35728 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
35729       as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
35730     fi
35731   else
35732     input_to_shortpath="$new_path"
35733   fi
35734 
35735   # Call helper function which possibly converts this using DOS-style short mode.
35736   # If so, the updated path is stored in $new_path.
35737   new_path="$input_to_shortpath"
35738 
35739   input_path="$input_to_shortpath"
35740   # Check if we need to convert this using DOS-style short mode. If the path
35741   # contains just simple characters, use it. Otherwise (spaces, weird characters),
35742   # take no chances and rewrite it.
35743   # Note: m4 eats our [], so we need to use [ and ] instead.
35744   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
35745   if test "x$has_forbidden_chars" != x; then
35746     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35747     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
35748     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
35749     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
35750       # Going to short mode and back again did indeed matter. Since short mode is
35751       # case insensitive, let's make it lowercase to improve readability.
35752       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35753       # Now convert it back to Unix-stile (cygpath)
35754       input_path=`$CYGPATH -u "$shortmode_path"`
35755       new_path="$input_path"
35756     fi
35757   fi
35758 
35759   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
35760   if test "x$test_cygdrive_prefix" = x; then
35761     # As a simple fix, exclude /usr/bin since it's not a real path.
35762     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
35763       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
35764       # a path prefixed by /cygdrive for fixpath to work.
35765       new_path="$CYGWIN_ROOT_PATH$input_path"
35766     fi
35767   fi
35768 
35769   # remove trailing .exe if any
35770   new_path="${new_path/%.exe/}"
35771 
35772   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35773 
35774   # First separate the path from the arguments. This will split at the first
35775   # space.
35776   complete="$CXXCPP"
35777   path="${complete%% *}"
35778   tmp="$complete EOL"
35779   arguments="${tmp#* }"
35780 
35781   # Input might be given as Windows format, start by converting to
35782   # unix format.
35783   new_path="$path"
35784 
35785   windows_path="$new_path"
35786   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35787     unix_path=`$CYGPATH -u "$windows_path"`
35788     new_path="$unix_path"
35789   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35790     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35791     new_path="$unix_path"
35792   fi
35793 
35794 
35795   # Now try to locate executable using which
35796   new_path=`$WHICH "$new_path" 2> /dev/null`
35797 
35798   if test "x$new_path" = x; then
35799     # Oops. Which didn't find the executable.
35800     # The splitting of arguments from the executable at a space might have been incorrect,
35801     # since paths with space are more likely in Windows. Give it another try with the whole
35802     # argument.
35803     path="$complete"
35804     arguments="EOL"
35805     new_path="$path"
35806 
35807   windows_path="$new_path"
35808   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35809     unix_path=`$CYGPATH -u "$windows_path"`
35810     new_path="$unix_path"
35811   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35812     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35813     new_path="$unix_path"
35814   fi
35815 
35816 
35817     new_path=`$WHICH "$new_path" 2> /dev/null`
35818 
35819     if test "x$new_path" = x; then
35820       # It's still not found. Now this is an unrecoverable error.
35821       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
35822 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
35823       has_space=`$ECHO "$complete" | $GREP " "`
35824       if test "x$has_space" != x; then
35825         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35826 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35827       fi
35828       as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
35829     fi
35830   fi
35831 
35832   # Now new_path has a complete unix path to the binary
35833   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
35834     # Keep paths in /bin as-is, but remove trailing .exe if any
35835     new_path="${new_path/%.exe/}"
35836     # Do not save /bin paths to all_fixpath_prefixes!
35837   else
35838     # Not in mixed or Windows style, start by that.
35839     new_path=`cmd //c echo $new_path`
35840 
35841   input_path="$new_path"
35842   # Check if we need to convert this using DOS-style short mode. If the path
35843   # contains just simple characters, use it. Otherwise (spaces, weird characters),
35844   # take no chances and rewrite it.
35845   # Note: m4 eats our [], so we need to use [ and ] instead.
35846   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
35847   if test "x$has_forbidden_chars" != x; then
35848     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35849     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35850   fi
35851 
35852     # Output is in $new_path
35853 
35854   windows_path="$new_path"
35855   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35856     unix_path=`$CYGPATH -u "$windows_path"`
35857     new_path="$unix_path"
35858   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35859     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35860     new_path="$unix_path"
35861   fi
35862 
35863     # remove trailing .exe if any
35864     new_path="${new_path/%.exe/}"
35865 
35866     # Save the first 10 bytes of this path to the storage, so fixpath can work.
35867     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
35868   fi
35869 
35870   else
35871     # We're on a posix platform. Hooray! :)
35872     # First separate the path from the arguments. This will split at the first
35873     # space.
35874     complete="$CXXCPP"
35875     path="${complete%% *}"
35876     tmp="$complete EOL"
35877     arguments="${tmp#* }"
35878 
35879     # Cannot rely on the command "which" here since it doesn't always work.
35880     is_absolute_path=`$ECHO "$path" | $GREP ^/`
35881     if test -z "$is_absolute_path"; then
35882       # Path to executable is not absolute. Find it.
35883       IFS_save="$IFS"
35884       IFS=:
35885       for p in $PATH; do
35886         if test -f "$p/$path" && test -x "$p/$path"; then
35887           new_path="$p/$path"
35888           break
35889         fi
35890       done
35891       IFS="$IFS_save"
35892     else
35893       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving CXXCPP (as $path) failed, using $path directly." >&5
35894 $as_echo "$as_me: Resolving CXXCPP (as $path) failed, using $path directly." >&6;}
35895       new_path="$path"
35896     fi
35897 
35898     if test "x$new_path" = x; then
35899       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
35900 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
35901       has_space=`$ECHO "$complete" | $GREP " "`
35902       if test "x$has_space" != x; then
35903         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
35904 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
35905       fi
35906       as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
35907     fi
35908   fi
35909 
35910   # Now join together the path and the arguments once again
35911   if test "x$arguments" != xEOL; then
35912     new_complete="$new_path ${arguments% *}"
35913   else
35914     new_complete="$new_path"
35915   fi
35916 
35917   if test "x$complete" != "x$new_complete"; then
35918     CXXCPP="$new_complete"
35919     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXXCPP to \"$new_complete\"" >&5
35920 $as_echo "$as_me: Rewriting CXXCPP to \"$new_complete\"" >&6;}
35921   fi
35922 
35923 
35924   if test "x$COMPILE_TYPE" != "xcross"; then
35925     # If we are not cross compiling, use the same compilers for
35926     # building the build platform executables. The cross-compilation
35927     # case needed to be done earlier, but this can only be done after
35928     # the native tools have been localized.
35929     BUILD_CC="$CC"
35930     BUILD_CXX="$CXX"
35931     BUILD_LD="$LD"
35932   fi
35933 
35934   # for solaris we really need solaris tools, and not gnu equivalent
35935   #   these seems to normally reside in /usr/ccs/bin so add that to path before
35936   #   starting to probe
35937   #
35938   #   NOTE: I add this /usr/ccs/bin after TOOLS but before OLD_PATH
35939   #         so that it can be overriden --with-tools-dir
35940   if test "x$OPENJDK_BUILD_OS" = xsolaris; then
35941     PATH="${TOOLS_DIR}:/usr/ccs/bin:${OLD_PATH}"
35942   fi
35943 
35944   # Find the right assembler.
35945   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
35946 
35947 
35948   # Publish this variable in the help.
35949 
35950 
35951   if test "x$AS" = x; then
35952     # The variable is not set by user, try to locate tool using the code snippet
35953     for ac_prog in as
35954 do
35955   # Extract the first word of "$ac_prog", so it can be a program name with args.
35956 set dummy $ac_prog; ac_word=$2
35957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35958 $as_echo_n "checking for $ac_word... " >&6; }
35959 if ${ac_cv_path_AS+:} false; then :
35960   $as_echo_n "(cached) " >&6
35961 else
35962   case $AS in
35963   [\\/]* | ?:[\\/]*)
35964   ac_cv_path_AS="$AS" # Let the user override the test with a path.
35965   ;;
35966   *)
35967   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35968 for as_dir in $PATH
35969 do
35970   IFS=$as_save_IFS
35971   test -z "$as_dir" && as_dir=.
35972     for ac_exec_ext in '' $ac_executable_extensions; do
35973   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35974     ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
35975     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35976     break 2
35977   fi
35978 done
35979   done
35980 IFS=$as_save_IFS
35981 
35982   ;;
35983 esac
35984 fi
35985 AS=$ac_cv_path_AS
35986 if test -n "$AS"; then
35987   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
35988 $as_echo "$AS" >&6; }
35989 else
35990   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35991 $as_echo "no" >&6; }
35992 fi
35993 
35994 
35995   test -n "$AS" && break
35996 done
35997 
35998   else
35999     # The variable is set, but is it from the command line or the environment?
36000 
36001     # Try to remove the string !AS! from our list.
36002     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AS!/}
36003     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
36004       # If it failed, the variable was not from the command line. Ignore it,
36005       # but warn the user (except for BASH, which is always set by the calling BASH).
36006       if test "xAS" != xBASH; then
36007         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&5
36008 $as_echo "$as_me: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&2;}
36009       fi
36010       # Try to locate tool using the code snippet
36011       for ac_prog in as
36012 do
36013   # Extract the first word of "$ac_prog", so it can be a program name with args.
36014 set dummy $ac_prog; ac_word=$2
36015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36016 $as_echo_n "checking for $ac_word... " >&6; }
36017 if ${ac_cv_path_AS+:} false; then :
36018   $as_echo_n "(cached) " >&6
36019 else
36020   case $AS in
36021   [\\/]* | ?:[\\/]*)
36022   ac_cv_path_AS="$AS" # Let the user override the test with a path.
36023   ;;
36024   *)
36025   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36026 for as_dir in $PATH
36027 do
36028   IFS=$as_save_IFS
36029   test -z "$as_dir" && as_dir=.
36030     for ac_exec_ext in '' $ac_executable_extensions; do
36031   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36032     ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
36033     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36034     break 2
36035   fi
36036 done
36037   done
36038 IFS=$as_save_IFS
36039 
36040   ;;
36041 esac
36042 fi
36043 AS=$ac_cv_path_AS
36044 if test -n "$AS"; then
36045   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
36046 $as_echo "$AS" >&6; }
36047 else
36048   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36049 $as_echo "no" >&6; }
36050 fi
36051 
36052 
36053   test -n "$AS" && break
36054 done
36055 
36056     else
36057       # If it succeeded, then it was overridden by the user. We will use it
36058       # for the tool.
36059 
36060       # First remove it from the list of overridden variables, so we can test
36061       # for unknown variables in the end.
36062       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
36063 
36064       # Check if the provided tool contains a complete path.
36065       tool_specified="$AS"
36066       tool_basename="${tool_specified##*/}"
36067       if test "x$tool_basename" = "x$tool_specified"; then
36068         # A command without a complete path is provided, search $PATH.
36069         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AS=$tool_basename" >&5
36070 $as_echo "$as_me: Will search for user supplied tool AS=$tool_basename" >&6;}
36071         # Extract the first word of "$tool_basename", so it can be a program name with args.
36072 set dummy $tool_basename; ac_word=$2
36073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36074 $as_echo_n "checking for $ac_word... " >&6; }
36075 if ${ac_cv_path_AS+:} false; then :
36076   $as_echo_n "(cached) " >&6
36077 else
36078   case $AS in
36079   [\\/]* | ?:[\\/]*)
36080   ac_cv_path_AS="$AS" # Let the user override the test with a path.
36081   ;;
36082   *)
36083   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36084 for as_dir in $PATH
36085 do
36086   IFS=$as_save_IFS
36087   test -z "$as_dir" && as_dir=.
36088     for ac_exec_ext in '' $ac_executable_extensions; do
36089   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36090     ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
36091     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36092     break 2
36093   fi
36094 done
36095   done
36096 IFS=$as_save_IFS
36097 
36098   ;;
36099 esac
36100 fi
36101 AS=$ac_cv_path_AS
36102 if test -n "$AS"; then
36103   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
36104 $as_echo "$AS" >&6; }
36105 else
36106   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36107 $as_echo "no" >&6; }
36108 fi
36109 
36110 
36111         if test "x$AS" = x; then
36112           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
36113         fi
36114       else
36115         # Otherwise we believe it is a complete path. Use it as it is.
36116         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AS=$tool_specified" >&5
36117 $as_echo "$as_me: Will use user supplied tool AS=$tool_specified" >&6;}
36118         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5
36119 $as_echo_n "checking for AS... " >&6; }
36120         if test ! -x "$tool_specified"; then
36121           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
36122 $as_echo "not found" >&6; }
36123           as_fn_error $? "User supplied tool AS=$tool_specified does not exist or is not executable" "$LINENO" 5
36124         fi
36125         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
36126 $as_echo "$tool_specified" >&6; }
36127       fi
36128     fi
36129   fi
36130 
36131 
36132 
36133   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36134 
36135   # First separate the path from the arguments. This will split at the first
36136   # space.
36137   complete="$AS"
36138   path="${complete%% *}"
36139   tmp="$complete EOL"
36140   arguments="${tmp#* }"
36141 
36142   # Input might be given as Windows format, start by converting to
36143   # unix format.
36144   new_path=`$CYGPATH -u "$path"`
36145 
36146   # Now try to locate executable using which
36147   new_path=`$WHICH "$new_path" 2> /dev/null`
36148   # bat and cmd files are not always considered executable in cygwin causing which
36149   # to not find them
36150   if test "x$new_path" = x \
36151       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36152       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36153     new_path=`$CYGPATH -u "$path"`
36154   fi
36155   if test "x$new_path" = x; then
36156     # Oops. Which didn't find the executable.
36157     # The splitting of arguments from the executable at a space might have been incorrect,
36158     # since paths with space are more likely in Windows. Give it another try with the whole
36159     # argument.
36160     path="$complete"
36161     arguments="EOL"
36162     new_path=`$CYGPATH -u "$path"`
36163     new_path=`$WHICH "$new_path" 2> /dev/null`
36164     # bat and cmd files are not always considered executable in cygwin causing which
36165     # to not find them
36166     if test "x$new_path" = x \
36167         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36168         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36169       new_path=`$CYGPATH -u "$path"`
36170     fi
36171     if test "x$new_path" = x; then
36172       # It's still not found. Now this is an unrecoverable error.
36173       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
36174 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
36175       has_space=`$ECHO "$complete" | $GREP " "`
36176       if test "x$has_space" != x; then
36177         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36178 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36179       fi
36180       as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
36181     fi
36182   fi
36183 
36184   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
36185   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
36186   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
36187   # "foo.exe" is OK but "foo" is an error.
36188   #
36189   # This test is therefore slightly more accurate than "test -f" to check for file presence.
36190   # It is also a way to make sure we got the proper file name for the real test later on.
36191   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
36192   if test "x$test_shortpath" = x; then
36193     # Short path failed, file does not exist as specified.
36194     # Try adding .exe or .cmd
36195     if test -f "${new_path}.exe"; then
36196       input_to_shortpath="${new_path}.exe"
36197     elif test -f "${new_path}.cmd"; then
36198       input_to_shortpath="${new_path}.cmd"
36199     else
36200       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$new_path\", is invalid." >&5
36201 $as_echo "$as_me: The path of AS, which resolves as \"$new_path\", is invalid." >&6;}
36202       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
36203 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
36204       as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
36205     fi
36206   else
36207     input_to_shortpath="$new_path"
36208   fi
36209 
36210   # Call helper function which possibly converts this using DOS-style short mode.
36211   # If so, the updated path is stored in $new_path.
36212   new_path="$input_to_shortpath"
36213 
36214   input_path="$input_to_shortpath"
36215   # Check if we need to convert this using DOS-style short mode. If the path
36216   # contains just simple characters, use it. Otherwise (spaces, weird characters),
36217   # take no chances and rewrite it.
36218   # Note: m4 eats our [], so we need to use [ and ] instead.
36219   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
36220   if test "x$has_forbidden_chars" != x; then
36221     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36222     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
36223     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
36224     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
36225       # Going to short mode and back again did indeed matter. Since short mode is
36226       # case insensitive, let's make it lowercase to improve readability.
36227       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36228       # Now convert it back to Unix-stile (cygpath)
36229       input_path=`$CYGPATH -u "$shortmode_path"`
36230       new_path="$input_path"
36231     fi
36232   fi
36233 
36234   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
36235   if test "x$test_cygdrive_prefix" = x; then
36236     # As a simple fix, exclude /usr/bin since it's not a real path.
36237     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
36238       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
36239       # a path prefixed by /cygdrive for fixpath to work.
36240       new_path="$CYGWIN_ROOT_PATH$input_path"
36241     fi
36242   fi
36243 
36244   # remove trailing .exe if any
36245   new_path="${new_path/%.exe/}"
36246 
36247   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36248 
36249   # First separate the path from the arguments. This will split at the first
36250   # space.
36251   complete="$AS"
36252   path="${complete%% *}"
36253   tmp="$complete EOL"
36254   arguments="${tmp#* }"
36255 
36256   # Input might be given as Windows format, start by converting to
36257   # unix format.
36258   new_path="$path"
36259 
36260   windows_path="$new_path"
36261   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36262     unix_path=`$CYGPATH -u "$windows_path"`
36263     new_path="$unix_path"
36264   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36265     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36266     new_path="$unix_path"
36267   fi
36268 
36269 
36270   # Now try to locate executable using which
36271   new_path=`$WHICH "$new_path" 2> /dev/null`
36272 
36273   if test "x$new_path" = x; then
36274     # Oops. Which didn't find the executable.
36275     # The splitting of arguments from the executable at a space might have been incorrect,
36276     # since paths with space are more likely in Windows. Give it another try with the whole
36277     # argument.
36278     path="$complete"
36279     arguments="EOL"
36280     new_path="$path"
36281 
36282   windows_path="$new_path"
36283   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36284     unix_path=`$CYGPATH -u "$windows_path"`
36285     new_path="$unix_path"
36286   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36287     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36288     new_path="$unix_path"
36289   fi
36290 
36291 
36292     new_path=`$WHICH "$new_path" 2> /dev/null`
36293 
36294     if test "x$new_path" = x; then
36295       # It's still not found. Now this is an unrecoverable error.
36296       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
36297 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
36298       has_space=`$ECHO "$complete" | $GREP " "`
36299       if test "x$has_space" != x; then
36300         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36301 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36302       fi
36303       as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
36304     fi
36305   fi
36306 
36307   # Now new_path has a complete unix path to the binary
36308   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
36309     # Keep paths in /bin as-is, but remove trailing .exe if any
36310     new_path="${new_path/%.exe/}"
36311     # Do not save /bin paths to all_fixpath_prefixes!
36312   else
36313     # Not in mixed or Windows style, start by that.
36314     new_path=`cmd //c echo $new_path`
36315 
36316   input_path="$new_path"
36317   # Check if we need to convert this using DOS-style short mode. If the path
36318   # contains just simple characters, use it. Otherwise (spaces, weird characters),
36319   # take no chances and rewrite it.
36320   # Note: m4 eats our [], so we need to use [ and ] instead.
36321   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
36322   if test "x$has_forbidden_chars" != x; then
36323     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36324     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36325   fi
36326 
36327     # Output is in $new_path
36328 
36329   windows_path="$new_path"
36330   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36331     unix_path=`$CYGPATH -u "$windows_path"`
36332     new_path="$unix_path"
36333   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36334     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36335     new_path="$unix_path"
36336   fi
36337 
36338     # remove trailing .exe if any
36339     new_path="${new_path/%.exe/}"
36340 
36341     # Save the first 10 bytes of this path to the storage, so fixpath can work.
36342     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
36343   fi
36344 
36345   else
36346     # We're on a posix platform. Hooray! :)
36347     # First separate the path from the arguments. This will split at the first
36348     # space.
36349     complete="$AS"
36350     path="${complete%% *}"
36351     tmp="$complete EOL"
36352     arguments="${tmp#* }"
36353 
36354     # Cannot rely on the command "which" here since it doesn't always work.
36355     is_absolute_path=`$ECHO "$path" | $GREP ^/`
36356     if test -z "$is_absolute_path"; then
36357       # Path to executable is not absolute. Find it.
36358       IFS_save="$IFS"
36359       IFS=:
36360       for p in $PATH; do
36361         if test -f "$p/$path" && test -x "$p/$path"; then
36362           new_path="$p/$path"
36363           break
36364         fi
36365       done
36366       IFS="$IFS_save"
36367     else
36368       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving AS (as $path) failed, using $path directly." >&5
36369 $as_echo "$as_me: Resolving AS (as $path) failed, using $path directly." >&6;}
36370       new_path="$path"
36371     fi
36372 
36373     if test "x$new_path" = x; then
36374       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
36375 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
36376       has_space=`$ECHO "$complete" | $GREP " "`
36377       if test "x$has_space" != x; then
36378         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
36379 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
36380       fi
36381       as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
36382     fi
36383   fi
36384 
36385   # Now join together the path and the arguments once again
36386   if test "x$arguments" != xEOL; then
36387     new_complete="$new_path ${arguments% *}"
36388   else
36389     new_complete="$new_path"
36390   fi
36391 
36392   if test "x$complete" != "x$new_complete"; then
36393     AS="$new_complete"
36394     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AS to \"$new_complete\"" >&5
36395 $as_echo "$as_me: Rewriting AS to \"$new_complete\"" >&6;}
36396   fi
36397 
36398   else
36399     AS="$CC -c"
36400   fi
36401 
36402 
36403   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
36404 
36405 
36406   # Publish this variable in the help.
36407 
36408 
36409   if test "x$NM" = x; then
36410     # The variable is not set by user, try to locate tool using the code snippet
36411     for ac_prog in nm
36412 do
36413   # Extract the first word of "$ac_prog", so it can be a program name with args.
36414 set dummy $ac_prog; ac_word=$2
36415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36416 $as_echo_n "checking for $ac_word... " >&6; }
36417 if ${ac_cv_path_NM+:} false; then :
36418   $as_echo_n "(cached) " >&6
36419 else
36420   case $NM in
36421   [\\/]* | ?:[\\/]*)
36422   ac_cv_path_NM="$NM" # Let the user override the test with a path.
36423   ;;
36424   *)
36425   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36426 for as_dir in $PATH
36427 do
36428   IFS=$as_save_IFS
36429   test -z "$as_dir" && as_dir=.
36430     for ac_exec_ext in '' $ac_executable_extensions; do
36431   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36432     ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
36433     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36434     break 2
36435   fi
36436 done
36437   done
36438 IFS=$as_save_IFS
36439 
36440   ;;
36441 esac
36442 fi
36443 NM=$ac_cv_path_NM
36444 if test -n "$NM"; then
36445   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
36446 $as_echo "$NM" >&6; }
36447 else
36448   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36449 $as_echo "no" >&6; }
36450 fi
36451 
36452 
36453   test -n "$NM" && break
36454 done
36455 
36456   else
36457     # The variable is set, but is it from the command line or the environment?
36458 
36459     # Try to remove the string !NM! from our list.
36460     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/}
36461     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
36462       # If it failed, the variable was not from the command line. Ignore it,
36463       # but warn the user (except for BASH, which is always set by the calling BASH).
36464       if test "xNM" != xBASH; then
36465         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5
36466 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;}
36467       fi
36468       # Try to locate tool using the code snippet
36469       for ac_prog in nm
36470 do
36471   # Extract the first word of "$ac_prog", so it can be a program name with args.
36472 set dummy $ac_prog; ac_word=$2
36473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36474 $as_echo_n "checking for $ac_word... " >&6; }
36475 if ${ac_cv_path_NM+:} false; then :
36476   $as_echo_n "(cached) " >&6
36477 else
36478   case $NM in
36479   [\\/]* | ?:[\\/]*)
36480   ac_cv_path_NM="$NM" # Let the user override the test with a path.
36481   ;;
36482   *)
36483   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36484 for as_dir in $PATH
36485 do
36486   IFS=$as_save_IFS
36487   test -z "$as_dir" && as_dir=.
36488     for ac_exec_ext in '' $ac_executable_extensions; do
36489   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36490     ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
36491     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36492     break 2
36493   fi
36494 done
36495   done
36496 IFS=$as_save_IFS
36497 
36498   ;;
36499 esac
36500 fi
36501 NM=$ac_cv_path_NM
36502 if test -n "$NM"; then
36503   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
36504 $as_echo "$NM" >&6; }
36505 else
36506   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36507 $as_echo "no" >&6; }
36508 fi
36509 
36510 
36511   test -n "$NM" && break
36512 done
36513 
36514     else
36515       # If it succeeded, then it was overridden by the user. We will use it
36516       # for the tool.
36517 
36518       # First remove it from the list of overridden variables, so we can test
36519       # for unknown variables in the end.
36520       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
36521 
36522       # Check if the provided tool contains a complete path.
36523       tool_specified="$NM"
36524       tool_basename="${tool_specified##*/}"
36525       if test "x$tool_basename" = "x$tool_specified"; then
36526         # A command without a complete path is provided, search $PATH.
36527         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5
36528 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;}
36529         # Extract the first word of "$tool_basename", so it can be a program name with args.
36530 set dummy $tool_basename; ac_word=$2
36531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36532 $as_echo_n "checking for $ac_word... " >&6; }
36533 if ${ac_cv_path_NM+:} false; then :
36534   $as_echo_n "(cached) " >&6
36535 else
36536   case $NM in
36537   [\\/]* | ?:[\\/]*)
36538   ac_cv_path_NM="$NM" # Let the user override the test with a path.
36539   ;;
36540   *)
36541   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36542 for as_dir in $PATH
36543 do
36544   IFS=$as_save_IFS
36545   test -z "$as_dir" && as_dir=.
36546     for ac_exec_ext in '' $ac_executable_extensions; do
36547   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36548     ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
36549     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36550     break 2
36551   fi
36552 done
36553   done
36554 IFS=$as_save_IFS
36555 
36556   ;;
36557 esac
36558 fi
36559 NM=$ac_cv_path_NM
36560 if test -n "$NM"; then
36561   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
36562 $as_echo "$NM" >&6; }
36563 else
36564   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36565 $as_echo "no" >&6; }
36566 fi
36567 
36568 
36569         if test "x$NM" = x; then
36570           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
36571         fi
36572       else
36573         # Otherwise we believe it is a complete path. Use it as it is.
36574         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5
36575 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;}
36576         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5
36577 $as_echo_n "checking for NM... " >&6; }
36578         if test ! -x "$tool_specified"; then
36579           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
36580 $as_echo "not found" >&6; }
36581           as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5
36582         fi
36583         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
36584 $as_echo "$tool_specified" >&6; }
36585       fi
36586     fi
36587   fi
36588 
36589 
36590 
36591   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36592 
36593   # First separate the path from the arguments. This will split at the first
36594   # space.
36595   complete="$NM"
36596   path="${complete%% *}"
36597   tmp="$complete EOL"
36598   arguments="${tmp#* }"
36599 
36600   # Input might be given as Windows format, start by converting to
36601   # unix format.
36602   new_path=`$CYGPATH -u "$path"`
36603 
36604   # Now try to locate executable using which
36605   new_path=`$WHICH "$new_path" 2> /dev/null`
36606   # bat and cmd files are not always considered executable in cygwin causing which
36607   # to not find them
36608   if test "x$new_path" = x \
36609       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36610       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36611     new_path=`$CYGPATH -u "$path"`
36612   fi
36613   if test "x$new_path" = x; then
36614     # Oops. Which didn't find the executable.
36615     # The splitting of arguments from the executable at a space might have been incorrect,
36616     # since paths with space are more likely in Windows. Give it another try with the whole
36617     # argument.
36618     path="$complete"
36619     arguments="EOL"
36620     new_path=`$CYGPATH -u "$path"`
36621     new_path=`$WHICH "$new_path" 2> /dev/null`
36622     # bat and cmd files are not always considered executable in cygwin causing which
36623     # to not find them
36624     if test "x$new_path" = x \
36625         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36626         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36627       new_path=`$CYGPATH -u "$path"`
36628     fi
36629     if test "x$new_path" = x; then
36630       # It's still not found. Now this is an unrecoverable error.
36631       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
36632 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
36633       has_space=`$ECHO "$complete" | $GREP " "`
36634       if test "x$has_space" != x; then
36635         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36636 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36637       fi
36638       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
36639     fi
36640   fi
36641 
36642   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
36643   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
36644   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
36645   # "foo.exe" is OK but "foo" is an error.
36646   #
36647   # This test is therefore slightly more accurate than "test -f" to check for file presence.
36648   # It is also a way to make sure we got the proper file name for the real test later on.
36649   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
36650   if test "x$test_shortpath" = x; then
36651     # Short path failed, file does not exist as specified.
36652     # Try adding .exe or .cmd
36653     if test -f "${new_path}.exe"; then
36654       input_to_shortpath="${new_path}.exe"
36655     elif test -f "${new_path}.cmd"; then
36656       input_to_shortpath="${new_path}.cmd"
36657     else
36658       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5
36659 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;}
36660       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
36661 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
36662       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
36663     fi
36664   else
36665     input_to_shortpath="$new_path"
36666   fi
36667 
36668   # Call helper function which possibly converts this using DOS-style short mode.
36669   # If so, the updated path is stored in $new_path.
36670   new_path="$input_to_shortpath"
36671 
36672   input_path="$input_to_shortpath"
36673   # Check if we need to convert this using DOS-style short mode. If the path
36674   # contains just simple characters, use it. Otherwise (spaces, weird characters),
36675   # take no chances and rewrite it.
36676   # Note: m4 eats our [], so we need to use [ and ] instead.
36677   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
36678   if test "x$has_forbidden_chars" != x; then
36679     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36680     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
36681     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
36682     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
36683       # Going to short mode and back again did indeed matter. Since short mode is
36684       # case insensitive, let's make it lowercase to improve readability.
36685       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36686       # Now convert it back to Unix-stile (cygpath)
36687       input_path=`$CYGPATH -u "$shortmode_path"`
36688       new_path="$input_path"
36689     fi
36690   fi
36691 
36692   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
36693   if test "x$test_cygdrive_prefix" = x; then
36694     # As a simple fix, exclude /usr/bin since it's not a real path.
36695     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
36696       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
36697       # a path prefixed by /cygdrive for fixpath to work.
36698       new_path="$CYGWIN_ROOT_PATH$input_path"
36699     fi
36700   fi
36701 
36702   # remove trailing .exe if any
36703   new_path="${new_path/%.exe/}"
36704 
36705   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36706 
36707   # First separate the path from the arguments. This will split at the first
36708   # space.
36709   complete="$NM"
36710   path="${complete%% *}"
36711   tmp="$complete EOL"
36712   arguments="${tmp#* }"
36713 
36714   # Input might be given as Windows format, start by converting to
36715   # unix format.
36716   new_path="$path"
36717 
36718   windows_path="$new_path"
36719   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36720     unix_path=`$CYGPATH -u "$windows_path"`
36721     new_path="$unix_path"
36722   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36723     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36724     new_path="$unix_path"
36725   fi
36726 
36727 
36728   # Now try to locate executable using which
36729   new_path=`$WHICH "$new_path" 2> /dev/null`
36730 
36731   if test "x$new_path" = x; then
36732     # Oops. Which didn't find the executable.
36733     # The splitting of arguments from the executable at a space might have been incorrect,
36734     # since paths with space are more likely in Windows. Give it another try with the whole
36735     # argument.
36736     path="$complete"
36737     arguments="EOL"
36738     new_path="$path"
36739 
36740   windows_path="$new_path"
36741   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36742     unix_path=`$CYGPATH -u "$windows_path"`
36743     new_path="$unix_path"
36744   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36745     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36746     new_path="$unix_path"
36747   fi
36748 
36749 
36750     new_path=`$WHICH "$new_path" 2> /dev/null`
36751 
36752     if test "x$new_path" = x; then
36753       # It's still not found. Now this is an unrecoverable error.
36754       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
36755 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
36756       has_space=`$ECHO "$complete" | $GREP " "`
36757       if test "x$has_space" != x; then
36758         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36759 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36760       fi
36761       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
36762     fi
36763   fi
36764 
36765   # Now new_path has a complete unix path to the binary
36766   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
36767     # Keep paths in /bin as-is, but remove trailing .exe if any
36768     new_path="${new_path/%.exe/}"
36769     # Do not save /bin paths to all_fixpath_prefixes!
36770   else
36771     # Not in mixed or Windows style, start by that.
36772     new_path=`cmd //c echo $new_path`
36773 
36774   input_path="$new_path"
36775   # Check if we need to convert this using DOS-style short mode. If the path
36776   # contains just simple characters, use it. Otherwise (spaces, weird characters),
36777   # take no chances and rewrite it.
36778   # Note: m4 eats our [], so we need to use [ and ] instead.
36779   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
36780   if test "x$has_forbidden_chars" != x; then
36781     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36782     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36783   fi
36784 
36785     # Output is in $new_path
36786 
36787   windows_path="$new_path"
36788   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36789     unix_path=`$CYGPATH -u "$windows_path"`
36790     new_path="$unix_path"
36791   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36792     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36793     new_path="$unix_path"
36794   fi
36795 
36796     # remove trailing .exe if any
36797     new_path="${new_path/%.exe/}"
36798 
36799     # Save the first 10 bytes of this path to the storage, so fixpath can work.
36800     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
36801   fi
36802 
36803   else
36804     # We're on a posix platform. Hooray! :)
36805     # First separate the path from the arguments. This will split at the first
36806     # space.
36807     complete="$NM"
36808     path="${complete%% *}"
36809     tmp="$complete EOL"
36810     arguments="${tmp#* }"
36811 
36812     # Cannot rely on the command "which" here since it doesn't always work.
36813     is_absolute_path=`$ECHO "$path" | $GREP ^/`
36814     if test -z "$is_absolute_path"; then
36815       # Path to executable is not absolute. Find it.
36816       IFS_save="$IFS"
36817       IFS=:
36818       for p in $PATH; do
36819         if test -f "$p/$path" && test -x "$p/$path"; then
36820           new_path="$p/$path"
36821           break
36822         fi
36823       done
36824       IFS="$IFS_save"
36825     else
36826       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving NM (as $path) failed, using $path directly." >&5
36827 $as_echo "$as_me: Resolving NM (as $path) failed, using $path directly." >&6;}
36828       new_path="$path"
36829     fi
36830 
36831     if test "x$new_path" = x; then
36832       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
36833 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
36834       has_space=`$ECHO "$complete" | $GREP " "`
36835       if test "x$has_space" != x; then
36836         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
36837 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
36838       fi
36839       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
36840     fi
36841   fi
36842 
36843   # Now join together the path and the arguments once again
36844   if test "x$arguments" != xEOL; then
36845     new_complete="$new_path ${arguments% *}"
36846   else
36847     new_complete="$new_path"
36848   fi
36849 
36850   if test "x$complete" != "x$new_complete"; then
36851     NM="$new_complete"
36852     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5
36853 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;}
36854   fi
36855 
36856 
36857 
36858   # Publish this variable in the help.
36859 
36860 
36861   if test "x$GNM" = x; then
36862     # The variable is not set by user, try to locate tool using the code snippet
36863     for ac_prog in gnm
36864 do
36865   # Extract the first word of "$ac_prog", so it can be a program name with args.
36866 set dummy $ac_prog; ac_word=$2
36867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36868 $as_echo_n "checking for $ac_word... " >&6; }
36869 if ${ac_cv_path_GNM+:} false; then :
36870   $as_echo_n "(cached) " >&6
36871 else
36872   case $GNM in
36873   [\\/]* | ?:[\\/]*)
36874   ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
36875   ;;
36876   *)
36877   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36878 for as_dir in $PATH
36879 do
36880   IFS=$as_save_IFS
36881   test -z "$as_dir" && as_dir=.
36882     for ac_exec_ext in '' $ac_executable_extensions; do
36883   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36884     ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
36885     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36886     break 2
36887   fi
36888 done
36889   done
36890 IFS=$as_save_IFS
36891 
36892   ;;
36893 esac
36894 fi
36895 GNM=$ac_cv_path_GNM
36896 if test -n "$GNM"; then
36897   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
36898 $as_echo "$GNM" >&6; }
36899 else
36900   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36901 $as_echo "no" >&6; }
36902 fi
36903 
36904 
36905   test -n "$GNM" && break
36906 done
36907 
36908   else
36909     # The variable is set, but is it from the command line or the environment?
36910 
36911     # Try to remove the string !GNM! from our list.
36912     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GNM!/}
36913     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
36914       # If it failed, the variable was not from the command line. Ignore it,
36915       # but warn the user (except for BASH, which is always set by the calling BASH).
36916       if test "xGNM" != xBASH; then
36917         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&5
36918 $as_echo "$as_me: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&2;}
36919       fi
36920       # Try to locate tool using the code snippet
36921       for ac_prog in gnm
36922 do
36923   # Extract the first word of "$ac_prog", so it can be a program name with args.
36924 set dummy $ac_prog; ac_word=$2
36925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36926 $as_echo_n "checking for $ac_word... " >&6; }
36927 if ${ac_cv_path_GNM+:} false; then :
36928   $as_echo_n "(cached) " >&6
36929 else
36930   case $GNM in
36931   [\\/]* | ?:[\\/]*)
36932   ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
36933   ;;
36934   *)
36935   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36936 for as_dir in $PATH
36937 do
36938   IFS=$as_save_IFS
36939   test -z "$as_dir" && as_dir=.
36940     for ac_exec_ext in '' $ac_executable_extensions; do
36941   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36942     ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
36943     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36944     break 2
36945   fi
36946 done
36947   done
36948 IFS=$as_save_IFS
36949 
36950   ;;
36951 esac
36952 fi
36953 GNM=$ac_cv_path_GNM
36954 if test -n "$GNM"; then
36955   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
36956 $as_echo "$GNM" >&6; }
36957 else
36958   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36959 $as_echo "no" >&6; }
36960 fi
36961 
36962 
36963   test -n "$GNM" && break
36964 done
36965 
36966     else
36967       # If it succeeded, then it was overridden by the user. We will use it
36968       # for the tool.
36969 
36970       # First remove it from the list of overridden variables, so we can test
36971       # for unknown variables in the end.
36972       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
36973 
36974       # Check if the provided tool contains a complete path.
36975       tool_specified="$GNM"
36976       tool_basename="${tool_specified##*/}"
36977       if test "x$tool_basename" = "x$tool_specified"; then
36978         # A command without a complete path is provided, search $PATH.
36979         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GNM=$tool_basename" >&5
36980 $as_echo "$as_me: Will search for user supplied tool GNM=$tool_basename" >&6;}
36981         # Extract the first word of "$tool_basename", so it can be a program name with args.
36982 set dummy $tool_basename; ac_word=$2
36983 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36984 $as_echo_n "checking for $ac_word... " >&6; }
36985 if ${ac_cv_path_GNM+:} false; then :
36986   $as_echo_n "(cached) " >&6
36987 else
36988   case $GNM in
36989   [\\/]* | ?:[\\/]*)
36990   ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
36991   ;;
36992   *)
36993   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36994 for as_dir in $PATH
36995 do
36996   IFS=$as_save_IFS
36997   test -z "$as_dir" && as_dir=.
36998     for ac_exec_ext in '' $ac_executable_extensions; do
36999   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37000     ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
37001     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37002     break 2
37003   fi
37004 done
37005   done
37006 IFS=$as_save_IFS
37007 
37008   ;;
37009 esac
37010 fi
37011 GNM=$ac_cv_path_GNM
37012 if test -n "$GNM"; then
37013   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
37014 $as_echo "$GNM" >&6; }
37015 else
37016   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37017 $as_echo "no" >&6; }
37018 fi
37019 
37020 
37021         if test "x$GNM" = x; then
37022           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
37023         fi
37024       else
37025         # Otherwise we believe it is a complete path. Use it as it is.
37026         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GNM=$tool_specified" >&5
37027 $as_echo "$as_me: Will use user supplied tool GNM=$tool_specified" >&6;}
37028         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5
37029 $as_echo_n "checking for GNM... " >&6; }
37030         if test ! -x "$tool_specified"; then
37031           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
37032 $as_echo "not found" >&6; }
37033           as_fn_error $? "User supplied tool GNM=$tool_specified does not exist or is not executable" "$LINENO" 5
37034         fi
37035         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
37036 $as_echo "$tool_specified" >&6; }
37037       fi
37038     fi
37039   fi
37040 
37041 
37042 
37043   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37044 
37045   # First separate the path from the arguments. This will split at the first
37046   # space.
37047   complete="$GNM"
37048   path="${complete%% *}"
37049   tmp="$complete EOL"
37050   arguments="${tmp#* }"
37051 
37052   # Input might be given as Windows format, start by converting to
37053   # unix format.
37054   new_path=`$CYGPATH -u "$path"`
37055 
37056   # Now try to locate executable using which
37057   new_path=`$WHICH "$new_path" 2> /dev/null`
37058   # bat and cmd files are not always considered executable in cygwin causing which
37059   # to not find them
37060   if test "x$new_path" = x \
37061       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37062       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37063     new_path=`$CYGPATH -u "$path"`
37064   fi
37065   if test "x$new_path" = x; then
37066     # Oops. Which didn't find the executable.
37067     # The splitting of arguments from the executable at a space might have been incorrect,
37068     # since paths with space are more likely in Windows. Give it another try with the whole
37069     # argument.
37070     path="$complete"
37071     arguments="EOL"
37072     new_path=`$CYGPATH -u "$path"`
37073     new_path=`$WHICH "$new_path" 2> /dev/null`
37074     # bat and cmd files are not always considered executable in cygwin causing which
37075     # to not find them
37076     if test "x$new_path" = x \
37077         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37078         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37079       new_path=`$CYGPATH -u "$path"`
37080     fi
37081     if test "x$new_path" = x; then
37082       # It's still not found. Now this is an unrecoverable error.
37083       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
37084 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
37085       has_space=`$ECHO "$complete" | $GREP " "`
37086       if test "x$has_space" != x; then
37087         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37088 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37089       fi
37090       as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
37091     fi
37092   fi
37093 
37094   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
37095   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
37096   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
37097   # "foo.exe" is OK but "foo" is an error.
37098   #
37099   # This test is therefore slightly more accurate than "test -f" to check for file presence.
37100   # It is also a way to make sure we got the proper file name for the real test later on.
37101   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
37102   if test "x$test_shortpath" = x; then
37103     # Short path failed, file does not exist as specified.
37104     # Try adding .exe or .cmd
37105     if test -f "${new_path}.exe"; then
37106       input_to_shortpath="${new_path}.exe"
37107     elif test -f "${new_path}.cmd"; then
37108       input_to_shortpath="${new_path}.cmd"
37109     else
37110       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$new_path\", is invalid." >&5
37111 $as_echo "$as_me: The path of GNM, which resolves as \"$new_path\", is invalid." >&6;}
37112       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
37113 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
37114       as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
37115     fi
37116   else
37117     input_to_shortpath="$new_path"
37118   fi
37119 
37120   # Call helper function which possibly converts this using DOS-style short mode.
37121   # If so, the updated path is stored in $new_path.
37122   new_path="$input_to_shortpath"
37123 
37124   input_path="$input_to_shortpath"
37125   # Check if we need to convert this using DOS-style short mode. If the path
37126   # contains just simple characters, use it. Otherwise (spaces, weird characters),
37127   # take no chances and rewrite it.
37128   # Note: m4 eats our [], so we need to use [ and ] instead.
37129   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
37130   if test "x$has_forbidden_chars" != x; then
37131     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37132     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
37133     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
37134     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
37135       # Going to short mode and back again did indeed matter. Since short mode is
37136       # case insensitive, let's make it lowercase to improve readability.
37137       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37138       # Now convert it back to Unix-stile (cygpath)
37139       input_path=`$CYGPATH -u "$shortmode_path"`
37140       new_path="$input_path"
37141     fi
37142   fi
37143 
37144   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
37145   if test "x$test_cygdrive_prefix" = x; then
37146     # As a simple fix, exclude /usr/bin since it's not a real path.
37147     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
37148       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
37149       # a path prefixed by /cygdrive for fixpath to work.
37150       new_path="$CYGWIN_ROOT_PATH$input_path"
37151     fi
37152   fi
37153 
37154   # remove trailing .exe if any
37155   new_path="${new_path/%.exe/}"
37156 
37157   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37158 
37159   # First separate the path from the arguments. This will split at the first
37160   # space.
37161   complete="$GNM"
37162   path="${complete%% *}"
37163   tmp="$complete EOL"
37164   arguments="${tmp#* }"
37165 
37166   # Input might be given as Windows format, start by converting to
37167   # unix format.
37168   new_path="$path"
37169 
37170   windows_path="$new_path"
37171   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37172     unix_path=`$CYGPATH -u "$windows_path"`
37173     new_path="$unix_path"
37174   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37175     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37176     new_path="$unix_path"
37177   fi
37178 
37179 
37180   # Now try to locate executable using which
37181   new_path=`$WHICH "$new_path" 2> /dev/null`
37182 
37183   if test "x$new_path" = x; then
37184     # Oops. Which didn't find the executable.
37185     # The splitting of arguments from the executable at a space might have been incorrect,
37186     # since paths with space are more likely in Windows. Give it another try with the whole
37187     # argument.
37188     path="$complete"
37189     arguments="EOL"
37190     new_path="$path"
37191 
37192   windows_path="$new_path"
37193   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37194     unix_path=`$CYGPATH -u "$windows_path"`
37195     new_path="$unix_path"
37196   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37197     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37198     new_path="$unix_path"
37199   fi
37200 
37201 
37202     new_path=`$WHICH "$new_path" 2> /dev/null`
37203 
37204     if test "x$new_path" = x; then
37205       # It's still not found. Now this is an unrecoverable error.
37206       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
37207 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
37208       has_space=`$ECHO "$complete" | $GREP " "`
37209       if test "x$has_space" != x; then
37210         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37211 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37212       fi
37213       as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
37214     fi
37215   fi
37216 
37217   # Now new_path has a complete unix path to the binary
37218   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
37219     # Keep paths in /bin as-is, but remove trailing .exe if any
37220     new_path="${new_path/%.exe/}"
37221     # Do not save /bin paths to all_fixpath_prefixes!
37222   else
37223     # Not in mixed or Windows style, start by that.
37224     new_path=`cmd //c echo $new_path`
37225 
37226   input_path="$new_path"
37227   # Check if we need to convert this using DOS-style short mode. If the path
37228   # contains just simple characters, use it. Otherwise (spaces, weird characters),
37229   # take no chances and rewrite it.
37230   # Note: m4 eats our [], so we need to use [ and ] instead.
37231   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
37232   if test "x$has_forbidden_chars" != x; then
37233     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37234     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37235   fi
37236 
37237     # Output is in $new_path
37238 
37239   windows_path="$new_path"
37240   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37241     unix_path=`$CYGPATH -u "$windows_path"`
37242     new_path="$unix_path"
37243   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37244     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37245     new_path="$unix_path"
37246   fi
37247 
37248     # remove trailing .exe if any
37249     new_path="${new_path/%.exe/}"
37250 
37251     # Save the first 10 bytes of this path to the storage, so fixpath can work.
37252     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
37253   fi
37254 
37255   else
37256     # We're on a posix platform. Hooray! :)
37257     # First separate the path from the arguments. This will split at the first
37258     # space.
37259     complete="$GNM"
37260     path="${complete%% *}"
37261     tmp="$complete EOL"
37262     arguments="${tmp#* }"
37263 
37264     # Cannot rely on the command "which" here since it doesn't always work.
37265     is_absolute_path=`$ECHO "$path" | $GREP ^/`
37266     if test -z "$is_absolute_path"; then
37267       # Path to executable is not absolute. Find it.
37268       IFS_save="$IFS"
37269       IFS=:
37270       for p in $PATH; do
37271         if test -f "$p/$path" && test -x "$p/$path"; then
37272           new_path="$p/$path"
37273           break
37274         fi
37275       done
37276       IFS="$IFS_save"
37277     else
37278       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving GNM (as $path) failed, using $path directly." >&5
37279 $as_echo "$as_me: Resolving GNM (as $path) failed, using $path directly." >&6;}
37280       new_path="$path"
37281     fi
37282 
37283     if test "x$new_path" = x; then
37284       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
37285 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
37286       has_space=`$ECHO "$complete" | $GREP " "`
37287       if test "x$has_space" != x; then
37288         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
37289 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
37290       fi
37291       as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
37292     fi
37293   fi
37294 
37295   # Now join together the path and the arguments once again
37296   if test "x$arguments" != xEOL; then
37297     new_complete="$new_path ${arguments% *}"
37298   else
37299     new_complete="$new_path"
37300   fi
37301 
37302   if test "x$complete" != "x$new_complete"; then
37303     GNM="$new_complete"
37304     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting GNM to \"$new_complete\"" >&5
37305 $as_echo "$as_me: Rewriting GNM to \"$new_complete\"" >&6;}
37306   fi
37307 
37308 
37309 
37310   # Publish this variable in the help.
37311 
37312 
37313   if test "x$STRIP" = x; then
37314     # The variable is not set by user, try to locate tool using the code snippet
37315     for ac_prog in strip
37316 do
37317   # Extract the first word of "$ac_prog", so it can be a program name with args.
37318 set dummy $ac_prog; ac_word=$2
37319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37320 $as_echo_n "checking for $ac_word... " >&6; }
37321 if ${ac_cv_path_STRIP+:} false; then :
37322   $as_echo_n "(cached) " >&6
37323 else
37324   case $STRIP in
37325   [\\/]* | ?:[\\/]*)
37326   ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
37327   ;;
37328   *)
37329   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37330 for as_dir in $PATH
37331 do
37332   IFS=$as_save_IFS
37333   test -z "$as_dir" && as_dir=.
37334     for ac_exec_ext in '' $ac_executable_extensions; do
37335   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37336     ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
37337     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37338     break 2
37339   fi
37340 done
37341   done
37342 IFS=$as_save_IFS
37343 
37344   ;;
37345 esac
37346 fi
37347 STRIP=$ac_cv_path_STRIP
37348 if test -n "$STRIP"; then
37349   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
37350 $as_echo "$STRIP" >&6; }
37351 else
37352   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37353 $as_echo "no" >&6; }
37354 fi
37355 
37356 
37357   test -n "$STRIP" && break
37358 done
37359 
37360   else
37361     # The variable is set, but is it from the command line or the environment?
37362 
37363     # Try to remove the string !STRIP! from our list.
37364     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/}
37365     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
37366       # If it failed, the variable was not from the command line. Ignore it,
37367       # but warn the user (except for BASH, which is always set by the calling BASH).
37368       if test "xSTRIP" != xBASH; then
37369         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5
37370 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;}
37371       fi
37372       # Try to locate tool using the code snippet
37373       for ac_prog in strip
37374 do
37375   # Extract the first word of "$ac_prog", so it can be a program name with args.
37376 set dummy $ac_prog; ac_word=$2
37377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37378 $as_echo_n "checking for $ac_word... " >&6; }
37379 if ${ac_cv_path_STRIP+:} false; then :
37380   $as_echo_n "(cached) " >&6
37381 else
37382   case $STRIP in
37383   [\\/]* | ?:[\\/]*)
37384   ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
37385   ;;
37386   *)
37387   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37388 for as_dir in $PATH
37389 do
37390   IFS=$as_save_IFS
37391   test -z "$as_dir" && as_dir=.
37392     for ac_exec_ext in '' $ac_executable_extensions; do
37393   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37394     ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
37395     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37396     break 2
37397   fi
37398 done
37399   done
37400 IFS=$as_save_IFS
37401 
37402   ;;
37403 esac
37404 fi
37405 STRIP=$ac_cv_path_STRIP
37406 if test -n "$STRIP"; then
37407   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
37408 $as_echo "$STRIP" >&6; }
37409 else
37410   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37411 $as_echo "no" >&6; }
37412 fi
37413 
37414 
37415   test -n "$STRIP" && break
37416 done
37417 
37418     else
37419       # If it succeeded, then it was overridden by the user. We will use it
37420       # for the tool.
37421 
37422       # First remove it from the list of overridden variables, so we can test
37423       # for unknown variables in the end.
37424       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
37425 
37426       # Check if the provided tool contains a complete path.
37427       tool_specified="$STRIP"
37428       tool_basename="${tool_specified##*/}"
37429       if test "x$tool_basename" = "x$tool_specified"; then
37430         # A command without a complete path is provided, search $PATH.
37431         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5
37432 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;}
37433         # Extract the first word of "$tool_basename", so it can be a program name with args.
37434 set dummy $tool_basename; ac_word=$2
37435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37436 $as_echo_n "checking for $ac_word... " >&6; }
37437 if ${ac_cv_path_STRIP+:} false; then :
37438   $as_echo_n "(cached) " >&6
37439 else
37440   case $STRIP in
37441   [\\/]* | ?:[\\/]*)
37442   ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
37443   ;;
37444   *)
37445   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37446 for as_dir in $PATH
37447 do
37448   IFS=$as_save_IFS
37449   test -z "$as_dir" && as_dir=.
37450     for ac_exec_ext in '' $ac_executable_extensions; do
37451   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37452     ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
37453     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37454     break 2
37455   fi
37456 done
37457   done
37458 IFS=$as_save_IFS
37459 
37460   ;;
37461 esac
37462 fi
37463 STRIP=$ac_cv_path_STRIP
37464 if test -n "$STRIP"; then
37465   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
37466 $as_echo "$STRIP" >&6; }
37467 else
37468   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37469 $as_echo "no" >&6; }
37470 fi
37471 
37472 
37473         if test "x$STRIP" = x; then
37474           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
37475         fi
37476       else
37477         # Otherwise we believe it is a complete path. Use it as it is.
37478         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5
37479 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;}
37480         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5
37481 $as_echo_n "checking for STRIP... " >&6; }
37482         if test ! -x "$tool_specified"; then
37483           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
37484 $as_echo "not found" >&6; }
37485           as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5
37486         fi
37487         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
37488 $as_echo "$tool_specified" >&6; }
37489       fi
37490     fi
37491   fi
37492 
37493 
37494 
37495   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37496 
37497   # First separate the path from the arguments. This will split at the first
37498   # space.
37499   complete="$STRIP"
37500   path="${complete%% *}"
37501   tmp="$complete EOL"
37502   arguments="${tmp#* }"
37503 
37504   # Input might be given as Windows format, start by converting to
37505   # unix format.
37506   new_path=`$CYGPATH -u "$path"`
37507 
37508   # Now try to locate executable using which
37509   new_path=`$WHICH "$new_path" 2> /dev/null`
37510   # bat and cmd files are not always considered executable in cygwin causing which
37511   # to not find them
37512   if test "x$new_path" = x \
37513       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37514       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37515     new_path=`$CYGPATH -u "$path"`
37516   fi
37517   if test "x$new_path" = x; then
37518     # Oops. Which didn't find the executable.
37519     # The splitting of arguments from the executable at a space might have been incorrect,
37520     # since paths with space are more likely in Windows. Give it another try with the whole
37521     # argument.
37522     path="$complete"
37523     arguments="EOL"
37524     new_path=`$CYGPATH -u "$path"`
37525     new_path=`$WHICH "$new_path" 2> /dev/null`
37526     # bat and cmd files are not always considered executable in cygwin causing which
37527     # to not find them
37528     if test "x$new_path" = x \
37529         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37530         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37531       new_path=`$CYGPATH -u "$path"`
37532     fi
37533     if test "x$new_path" = x; then
37534       # It's still not found. Now this is an unrecoverable error.
37535       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
37536 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
37537       has_space=`$ECHO "$complete" | $GREP " "`
37538       if test "x$has_space" != x; then
37539         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37540 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37541       fi
37542       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
37543     fi
37544   fi
37545 
37546   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
37547   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
37548   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
37549   # "foo.exe" is OK but "foo" is an error.
37550   #
37551   # This test is therefore slightly more accurate than "test -f" to check for file presence.
37552   # It is also a way to make sure we got the proper file name for the real test later on.
37553   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
37554   if test "x$test_shortpath" = x; then
37555     # Short path failed, file does not exist as specified.
37556     # Try adding .exe or .cmd
37557     if test -f "${new_path}.exe"; then
37558       input_to_shortpath="${new_path}.exe"
37559     elif test -f "${new_path}.cmd"; then
37560       input_to_shortpath="${new_path}.cmd"
37561     else
37562       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5
37563 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;}
37564       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
37565 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
37566       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
37567     fi
37568   else
37569     input_to_shortpath="$new_path"
37570   fi
37571 
37572   # Call helper function which possibly converts this using DOS-style short mode.
37573   # If so, the updated path is stored in $new_path.
37574   new_path="$input_to_shortpath"
37575 
37576   input_path="$input_to_shortpath"
37577   # Check if we need to convert this using DOS-style short mode. If the path
37578   # contains just simple characters, use it. Otherwise (spaces, weird characters),
37579   # take no chances and rewrite it.
37580   # Note: m4 eats our [], so we need to use [ and ] instead.
37581   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
37582   if test "x$has_forbidden_chars" != x; then
37583     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37584     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
37585     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
37586     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
37587       # Going to short mode and back again did indeed matter. Since short mode is
37588       # case insensitive, let's make it lowercase to improve readability.
37589       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37590       # Now convert it back to Unix-stile (cygpath)
37591       input_path=`$CYGPATH -u "$shortmode_path"`
37592       new_path="$input_path"
37593     fi
37594   fi
37595 
37596   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
37597   if test "x$test_cygdrive_prefix" = x; then
37598     # As a simple fix, exclude /usr/bin since it's not a real path.
37599     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
37600       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
37601       # a path prefixed by /cygdrive for fixpath to work.
37602       new_path="$CYGWIN_ROOT_PATH$input_path"
37603     fi
37604   fi
37605 
37606   # remove trailing .exe if any
37607   new_path="${new_path/%.exe/}"
37608 
37609   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37610 
37611   # First separate the path from the arguments. This will split at the first
37612   # space.
37613   complete="$STRIP"
37614   path="${complete%% *}"
37615   tmp="$complete EOL"
37616   arguments="${tmp#* }"
37617 
37618   # Input might be given as Windows format, start by converting to
37619   # unix format.
37620   new_path="$path"
37621 
37622   windows_path="$new_path"
37623   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37624     unix_path=`$CYGPATH -u "$windows_path"`
37625     new_path="$unix_path"
37626   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37627     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37628     new_path="$unix_path"
37629   fi
37630 
37631 
37632   # Now try to locate executable using which
37633   new_path=`$WHICH "$new_path" 2> /dev/null`
37634 
37635   if test "x$new_path" = x; then
37636     # Oops. Which didn't find the executable.
37637     # The splitting of arguments from the executable at a space might have been incorrect,
37638     # since paths with space are more likely in Windows. Give it another try with the whole
37639     # argument.
37640     path="$complete"
37641     arguments="EOL"
37642     new_path="$path"
37643 
37644   windows_path="$new_path"
37645   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37646     unix_path=`$CYGPATH -u "$windows_path"`
37647     new_path="$unix_path"
37648   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37649     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37650     new_path="$unix_path"
37651   fi
37652 
37653 
37654     new_path=`$WHICH "$new_path" 2> /dev/null`
37655 
37656     if test "x$new_path" = x; then
37657       # It's still not found. Now this is an unrecoverable error.
37658       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
37659 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
37660       has_space=`$ECHO "$complete" | $GREP " "`
37661       if test "x$has_space" != x; then
37662         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37663 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37664       fi
37665       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
37666     fi
37667   fi
37668 
37669   # Now new_path has a complete unix path to the binary
37670   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
37671     # Keep paths in /bin as-is, but remove trailing .exe if any
37672     new_path="${new_path/%.exe/}"
37673     # Do not save /bin paths to all_fixpath_prefixes!
37674   else
37675     # Not in mixed or Windows style, start by that.
37676     new_path=`cmd //c echo $new_path`
37677 
37678   input_path="$new_path"
37679   # Check if we need to convert this using DOS-style short mode. If the path
37680   # contains just simple characters, use it. Otherwise (spaces, weird characters),
37681   # take no chances and rewrite it.
37682   # Note: m4 eats our [], so we need to use [ and ] instead.
37683   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
37684   if test "x$has_forbidden_chars" != x; then
37685     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37686     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37687   fi
37688 
37689     # Output is in $new_path
37690 
37691   windows_path="$new_path"
37692   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37693     unix_path=`$CYGPATH -u "$windows_path"`
37694     new_path="$unix_path"
37695   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37696     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37697     new_path="$unix_path"
37698   fi
37699 
37700     # remove trailing .exe if any
37701     new_path="${new_path/%.exe/}"
37702 
37703     # Save the first 10 bytes of this path to the storage, so fixpath can work.
37704     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
37705   fi
37706 
37707   else
37708     # We're on a posix platform. Hooray! :)
37709     # First separate the path from the arguments. This will split at the first
37710     # space.
37711     complete="$STRIP"
37712     path="${complete%% *}"
37713     tmp="$complete EOL"
37714     arguments="${tmp#* }"
37715 
37716     # Cannot rely on the command "which" here since it doesn't always work.
37717     is_absolute_path=`$ECHO "$path" | $GREP ^/`
37718     if test -z "$is_absolute_path"; then
37719       # Path to executable is not absolute. Find it.
37720       IFS_save="$IFS"
37721       IFS=:
37722       for p in $PATH; do
37723         if test -f "$p/$path" && test -x "$p/$path"; then
37724           new_path="$p/$path"
37725           break
37726         fi
37727       done
37728       IFS="$IFS_save"
37729     else
37730       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving STRIP (as $path) failed, using $path directly." >&5
37731 $as_echo "$as_me: Resolving STRIP (as $path) failed, using $path directly." >&6;}
37732       new_path="$path"
37733     fi
37734 
37735     if test "x$new_path" = x; then
37736       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
37737 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
37738       has_space=`$ECHO "$complete" | $GREP " "`
37739       if test "x$has_space" != x; then
37740         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
37741 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
37742       fi
37743       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
37744     fi
37745   fi
37746 
37747   # Now join together the path and the arguments once again
37748   if test "x$arguments" != xEOL; then
37749     new_complete="$new_path ${arguments% *}"
37750   else
37751     new_complete="$new_path"
37752   fi
37753 
37754   if test "x$complete" != "x$new_complete"; then
37755     STRIP="$new_complete"
37756     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5
37757 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;}
37758   fi
37759 
37760 
37761 
37762   # Publish this variable in the help.
37763 
37764 
37765   if test "x$MCS" = x; then
37766     # The variable is not set by user, try to locate tool using the code snippet
37767     for ac_prog in mcs
37768 do
37769   # Extract the first word of "$ac_prog", so it can be a program name with args.
37770 set dummy $ac_prog; ac_word=$2
37771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37772 $as_echo_n "checking for $ac_word... " >&6; }
37773 if ${ac_cv_path_MCS+:} false; then :
37774   $as_echo_n "(cached) " >&6
37775 else
37776   case $MCS in
37777   [\\/]* | ?:[\\/]*)
37778   ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
37779   ;;
37780   *)
37781   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37782 for as_dir in $PATH
37783 do
37784   IFS=$as_save_IFS
37785   test -z "$as_dir" && as_dir=.
37786     for ac_exec_ext in '' $ac_executable_extensions; do
37787   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37788     ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
37789     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37790     break 2
37791   fi
37792 done
37793   done
37794 IFS=$as_save_IFS
37795 
37796   ;;
37797 esac
37798 fi
37799 MCS=$ac_cv_path_MCS
37800 if test -n "$MCS"; then
37801   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
37802 $as_echo "$MCS" >&6; }
37803 else
37804   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37805 $as_echo "no" >&6; }
37806 fi
37807 
37808 
37809   test -n "$MCS" && break
37810 done
37811 
37812   else
37813     # The variable is set, but is it from the command line or the environment?
37814 
37815     # Try to remove the string !MCS! from our list.
37816     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MCS!/}
37817     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
37818       # If it failed, the variable was not from the command line. Ignore it,
37819       # but warn the user (except for BASH, which is always set by the calling BASH).
37820       if test "xMCS" != xBASH; then
37821         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MCS from the environment. Use command line variables instead." >&5
37822 $as_echo "$as_me: WARNING: Ignoring value of MCS from the environment. Use command line variables instead." >&2;}
37823       fi
37824       # Try to locate tool using the code snippet
37825       for ac_prog in mcs
37826 do
37827   # Extract the first word of "$ac_prog", so it can be a program name with args.
37828 set dummy $ac_prog; ac_word=$2
37829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37830 $as_echo_n "checking for $ac_word... " >&6; }
37831 if ${ac_cv_path_MCS+:} false; then :
37832   $as_echo_n "(cached) " >&6
37833 else
37834   case $MCS in
37835   [\\/]* | ?:[\\/]*)
37836   ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
37837   ;;
37838   *)
37839   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37840 for as_dir in $PATH
37841 do
37842   IFS=$as_save_IFS
37843   test -z "$as_dir" && as_dir=.
37844     for ac_exec_ext in '' $ac_executable_extensions; do
37845   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37846     ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
37847     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37848     break 2
37849   fi
37850 done
37851   done
37852 IFS=$as_save_IFS
37853 
37854   ;;
37855 esac
37856 fi
37857 MCS=$ac_cv_path_MCS
37858 if test -n "$MCS"; then
37859   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
37860 $as_echo "$MCS" >&6; }
37861 else
37862   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37863 $as_echo "no" >&6; }
37864 fi
37865 
37866 
37867   test -n "$MCS" && break
37868 done
37869 
37870     else
37871       # If it succeeded, then it was overridden by the user. We will use it
37872       # for the tool.
37873 
37874       # First remove it from the list of overridden variables, so we can test
37875       # for unknown variables in the end.
37876       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
37877 
37878       # Check if the provided tool contains a complete path.
37879       tool_specified="$MCS"
37880       tool_basename="${tool_specified##*/}"
37881       if test "x$tool_basename" = "x$tool_specified"; then
37882         # A command without a complete path is provided, search $PATH.
37883         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MCS=$tool_basename" >&5
37884 $as_echo "$as_me: Will search for user supplied tool MCS=$tool_basename" >&6;}
37885         # Extract the first word of "$tool_basename", so it can be a program name with args.
37886 set dummy $tool_basename; ac_word=$2
37887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37888 $as_echo_n "checking for $ac_word... " >&6; }
37889 if ${ac_cv_path_MCS+:} false; then :
37890   $as_echo_n "(cached) " >&6
37891 else
37892   case $MCS in
37893   [\\/]* | ?:[\\/]*)
37894   ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
37895   ;;
37896   *)
37897   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37898 for as_dir in $PATH
37899 do
37900   IFS=$as_save_IFS
37901   test -z "$as_dir" && as_dir=.
37902     for ac_exec_ext in '' $ac_executable_extensions; do
37903   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37904     ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
37905     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37906     break 2
37907   fi
37908 done
37909   done
37910 IFS=$as_save_IFS
37911 
37912   ;;
37913 esac
37914 fi
37915 MCS=$ac_cv_path_MCS
37916 if test -n "$MCS"; then
37917   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
37918 $as_echo "$MCS" >&6; }
37919 else
37920   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37921 $as_echo "no" >&6; }
37922 fi
37923 
37924 
37925         if test "x$MCS" = x; then
37926           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
37927         fi
37928       else
37929         # Otherwise we believe it is a complete path. Use it as it is.
37930         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MCS=$tool_specified" >&5
37931 $as_echo "$as_me: Will use user supplied tool MCS=$tool_specified" >&6;}
37932         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MCS" >&5
37933 $as_echo_n "checking for MCS... " >&6; }
37934         if test ! -x "$tool_specified"; then
37935           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
37936 $as_echo "not found" >&6; }
37937           as_fn_error $? "User supplied tool MCS=$tool_specified does not exist or is not executable" "$LINENO" 5
37938         fi
37939         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
37940 $as_echo "$tool_specified" >&6; }
37941       fi
37942     fi
37943   fi
37944 
37945 
37946 
37947   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37948 
37949   # First separate the path from the arguments. This will split at the first
37950   # space.
37951   complete="$MCS"
37952   path="${complete%% *}"
37953   tmp="$complete EOL"
37954   arguments="${tmp#* }"
37955 
37956   # Input might be given as Windows format, start by converting to
37957   # unix format.
37958   new_path=`$CYGPATH -u "$path"`
37959 
37960   # Now try to locate executable using which
37961   new_path=`$WHICH "$new_path" 2> /dev/null`
37962   # bat and cmd files are not always considered executable in cygwin causing which
37963   # to not find them
37964   if test "x$new_path" = x \
37965       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37966       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37967     new_path=`$CYGPATH -u "$path"`
37968   fi
37969   if test "x$new_path" = x; then
37970     # Oops. Which didn't find the executable.
37971     # The splitting of arguments from the executable at a space might have been incorrect,
37972     # since paths with space are more likely in Windows. Give it another try with the whole
37973     # argument.
37974     path="$complete"
37975     arguments="EOL"
37976     new_path=`$CYGPATH -u "$path"`
37977     new_path=`$WHICH "$new_path" 2> /dev/null`
37978     # bat and cmd files are not always considered executable in cygwin causing which
37979     # to not find them
37980     if test "x$new_path" = x \
37981         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37982         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37983       new_path=`$CYGPATH -u "$path"`
37984     fi
37985     if test "x$new_path" = x; then
37986       # It's still not found. Now this is an unrecoverable error.
37987       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
37988 $as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
37989       has_space=`$ECHO "$complete" | $GREP " "`
37990       if test "x$has_space" != x; then
37991         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37992 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37993       fi
37994       as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
37995     fi
37996   fi
37997 
37998   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
37999   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
38000   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
38001   # "foo.exe" is OK but "foo" is an error.
38002   #
38003   # This test is therefore slightly more accurate than "test -f" to check for file presence.
38004   # It is also a way to make sure we got the proper file name for the real test later on.
38005   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
38006   if test "x$test_shortpath" = x; then
38007     # Short path failed, file does not exist as specified.
38008     # Try adding .exe or .cmd
38009     if test -f "${new_path}.exe"; then
38010       input_to_shortpath="${new_path}.exe"
38011     elif test -f "${new_path}.cmd"; then
38012       input_to_shortpath="${new_path}.cmd"
38013     else
38014       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$new_path\", is invalid." >&5
38015 $as_echo "$as_me: The path of MCS, which resolves as \"$new_path\", is invalid." >&6;}
38016       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
38017 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
38018       as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
38019     fi
38020   else
38021     input_to_shortpath="$new_path"
38022   fi
38023 
38024   # Call helper function which possibly converts this using DOS-style short mode.
38025   # If so, the updated path is stored in $new_path.
38026   new_path="$input_to_shortpath"
38027 
38028   input_path="$input_to_shortpath"
38029   # Check if we need to convert this using DOS-style short mode. If the path
38030   # contains just simple characters, use it. Otherwise (spaces, weird characters),
38031   # take no chances and rewrite it.
38032   # Note: m4 eats our [], so we need to use [ and ] instead.
38033   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
38034   if test "x$has_forbidden_chars" != x; then
38035     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38036     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
38037     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
38038     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
38039       # Going to short mode and back again did indeed matter. Since short mode is
38040       # case insensitive, let's make it lowercase to improve readability.
38041       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38042       # Now convert it back to Unix-stile (cygpath)
38043       input_path=`$CYGPATH -u "$shortmode_path"`
38044       new_path="$input_path"
38045     fi
38046   fi
38047 
38048   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
38049   if test "x$test_cygdrive_prefix" = x; then
38050     # As a simple fix, exclude /usr/bin since it's not a real path.
38051     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
38052       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
38053       # a path prefixed by /cygdrive for fixpath to work.
38054       new_path="$CYGWIN_ROOT_PATH$input_path"
38055     fi
38056   fi
38057 
38058   # remove trailing .exe if any
38059   new_path="${new_path/%.exe/}"
38060 
38061   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38062 
38063   # First separate the path from the arguments. This will split at the first
38064   # space.
38065   complete="$MCS"
38066   path="${complete%% *}"
38067   tmp="$complete EOL"
38068   arguments="${tmp#* }"
38069 
38070   # Input might be given as Windows format, start by converting to
38071   # unix format.
38072   new_path="$path"
38073 
38074   windows_path="$new_path"
38075   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38076     unix_path=`$CYGPATH -u "$windows_path"`
38077     new_path="$unix_path"
38078   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38079     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38080     new_path="$unix_path"
38081   fi
38082 
38083 
38084   # Now try to locate executable using which
38085   new_path=`$WHICH "$new_path" 2> /dev/null`
38086 
38087   if test "x$new_path" = x; then
38088     # Oops. Which didn't find the executable.
38089     # The splitting of arguments from the executable at a space might have been incorrect,
38090     # since paths with space are more likely in Windows. Give it another try with the whole
38091     # argument.
38092     path="$complete"
38093     arguments="EOL"
38094     new_path="$path"
38095 
38096   windows_path="$new_path"
38097   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38098     unix_path=`$CYGPATH -u "$windows_path"`
38099     new_path="$unix_path"
38100   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38101     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38102     new_path="$unix_path"
38103   fi
38104 
38105 
38106     new_path=`$WHICH "$new_path" 2> /dev/null`
38107 
38108     if test "x$new_path" = x; then
38109       # It's still not found. Now this is an unrecoverable error.
38110       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
38111 $as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
38112       has_space=`$ECHO "$complete" | $GREP " "`
38113       if test "x$has_space" != x; then
38114         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38115 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38116       fi
38117       as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
38118     fi
38119   fi
38120 
38121   # Now new_path has a complete unix path to the binary
38122   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
38123     # Keep paths in /bin as-is, but remove trailing .exe if any
38124     new_path="${new_path/%.exe/}"
38125     # Do not save /bin paths to all_fixpath_prefixes!
38126   else
38127     # Not in mixed or Windows style, start by that.
38128     new_path=`cmd //c echo $new_path`
38129 
38130   input_path="$new_path"
38131   # Check if we need to convert this using DOS-style short mode. If the path
38132   # contains just simple characters, use it. Otherwise (spaces, weird characters),
38133   # take no chances and rewrite it.
38134   # Note: m4 eats our [], so we need to use [ and ] instead.
38135   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
38136   if test "x$has_forbidden_chars" != x; then
38137     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38138     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38139   fi
38140 
38141     # Output is in $new_path
38142 
38143   windows_path="$new_path"
38144   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38145     unix_path=`$CYGPATH -u "$windows_path"`
38146     new_path="$unix_path"
38147   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38148     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38149     new_path="$unix_path"
38150   fi
38151 
38152     # remove trailing .exe if any
38153     new_path="${new_path/%.exe/}"
38154 
38155     # Save the first 10 bytes of this path to the storage, so fixpath can work.
38156     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
38157   fi
38158 
38159   else
38160     # We're on a posix platform. Hooray! :)
38161     # First separate the path from the arguments. This will split at the first
38162     # space.
38163     complete="$MCS"
38164     path="${complete%% *}"
38165     tmp="$complete EOL"
38166     arguments="${tmp#* }"
38167 
38168     # Cannot rely on the command "which" here since it doesn't always work.
38169     is_absolute_path=`$ECHO "$path" | $GREP ^/`
38170     if test -z "$is_absolute_path"; then
38171       # Path to executable is not absolute. Find it.
38172       IFS_save="$IFS"
38173       IFS=:
38174       for p in $PATH; do
38175         if test -f "$p/$path" && test -x "$p/$path"; then
38176           new_path="$p/$path"
38177           break
38178         fi
38179       done
38180       IFS="$IFS_save"
38181     else
38182       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving MCS (as $path) failed, using $path directly." >&5
38183 $as_echo "$as_me: Resolving MCS (as $path) failed, using $path directly." >&6;}
38184       new_path="$path"
38185     fi
38186 
38187     if test "x$new_path" = x; then
38188       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
38189 $as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
38190       has_space=`$ECHO "$complete" | $GREP " "`
38191       if test "x$has_space" != x; then
38192         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
38193 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
38194       fi
38195       as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
38196     fi
38197   fi
38198 
38199   # Now join together the path and the arguments once again
38200   if test "x$arguments" != xEOL; then
38201     new_complete="$new_path ${arguments% *}"
38202   else
38203     new_complete="$new_path"
38204   fi
38205 
38206   if test "x$complete" != "x$new_complete"; then
38207     MCS="$new_complete"
38208     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MCS to \"$new_complete\"" >&5
38209 $as_echo "$as_me: Rewriting MCS to \"$new_complete\"" >&6;}
38210   fi
38211 
38212   elif test "x$OPENJDK_TARGET_OS" != xwindows; then
38213 
38214 
38215   # Publish this variable in the help.
38216 
38217 
38218   if test "x$NM" = x; then
38219     # The variable is not set by user, try to locate tool using the code snippet
38220     if test -n "$ac_tool_prefix"; then
38221   for ac_prog in nm
38222   do
38223     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
38224 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
38225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38226 $as_echo_n "checking for $ac_word... " >&6; }
38227 if ${ac_cv_prog_NM+:} false; then :
38228   $as_echo_n "(cached) " >&6
38229 else
38230   if test -n "$NM"; then
38231   ac_cv_prog_NM="$NM" # Let the user override the test.
38232 else
38233 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38234 for as_dir in $PATH
38235 do
38236   IFS=$as_save_IFS
38237   test -z "$as_dir" && as_dir=.
38238     for ac_exec_ext in '' $ac_executable_extensions; do
38239   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38240     ac_cv_prog_NM="$ac_tool_prefix$ac_prog"
38241     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38242     break 2
38243   fi
38244 done
38245   done
38246 IFS=$as_save_IFS
38247 
38248 fi
38249 fi
38250 NM=$ac_cv_prog_NM
38251 if test -n "$NM"; then
38252   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
38253 $as_echo "$NM" >&6; }
38254 else
38255   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38256 $as_echo "no" >&6; }
38257 fi
38258 
38259 
38260     test -n "$NM" && break
38261   done
38262 fi
38263 if test -z "$NM"; then
38264   ac_ct_NM=$NM
38265   for ac_prog in nm
38266 do
38267   # Extract the first word of "$ac_prog", so it can be a program name with args.
38268 set dummy $ac_prog; ac_word=$2
38269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38270 $as_echo_n "checking for $ac_word... " >&6; }
38271 if ${ac_cv_prog_ac_ct_NM+:} false; then :
38272   $as_echo_n "(cached) " >&6
38273 else
38274   if test -n "$ac_ct_NM"; then
38275   ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test.
38276 else
38277 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38278 for as_dir in $PATH
38279 do
38280   IFS=$as_save_IFS
38281   test -z "$as_dir" && as_dir=.
38282     for ac_exec_ext in '' $ac_executable_extensions; do
38283   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38284     ac_cv_prog_ac_ct_NM="$ac_prog"
38285     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38286     break 2
38287   fi
38288 done
38289   done
38290 IFS=$as_save_IFS
38291 
38292 fi
38293 fi
38294 ac_ct_NM=$ac_cv_prog_ac_ct_NM
38295 if test -n "$ac_ct_NM"; then
38296   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5
38297 $as_echo "$ac_ct_NM" >&6; }
38298 else
38299   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38300 $as_echo "no" >&6; }
38301 fi
38302 
38303 
38304   test -n "$ac_ct_NM" && break
38305 done
38306 
38307   if test "x$ac_ct_NM" = x; then
38308     NM=""
38309   else
38310     case $cross_compiling:$ac_tool_warned in
38311 yes:)
38312 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
38313 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
38314 ac_tool_warned=yes ;;
38315 esac
38316     NM=$ac_ct_NM
38317   fi
38318 fi
38319 
38320   else
38321     # The variable is set, but is it from the command line or the environment?
38322 
38323     # Try to remove the string !NM! from our list.
38324     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/}
38325     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
38326       # If it failed, the variable was not from the command line. Ignore it,
38327       # but warn the user (except for BASH, which is always set by the calling BASH).
38328       if test "xNM" != xBASH; then
38329         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5
38330 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;}
38331       fi
38332       # Try to locate tool using the code snippet
38333       if test -n "$ac_tool_prefix"; then
38334   for ac_prog in nm
38335   do
38336     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
38337 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
38338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38339 $as_echo_n "checking for $ac_word... " >&6; }
38340 if ${ac_cv_prog_NM+:} false; then :
38341   $as_echo_n "(cached) " >&6
38342 else
38343   if test -n "$NM"; then
38344   ac_cv_prog_NM="$NM" # Let the user override the test.
38345 else
38346 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38347 for as_dir in $PATH
38348 do
38349   IFS=$as_save_IFS
38350   test -z "$as_dir" && as_dir=.
38351     for ac_exec_ext in '' $ac_executable_extensions; do
38352   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38353     ac_cv_prog_NM="$ac_tool_prefix$ac_prog"
38354     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38355     break 2
38356   fi
38357 done
38358   done
38359 IFS=$as_save_IFS
38360 
38361 fi
38362 fi
38363 NM=$ac_cv_prog_NM
38364 if test -n "$NM"; then
38365   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
38366 $as_echo "$NM" >&6; }
38367 else
38368   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38369 $as_echo "no" >&6; }
38370 fi
38371 
38372 
38373     test -n "$NM" && break
38374   done
38375 fi
38376 if test -z "$NM"; then
38377   ac_ct_NM=$NM
38378   for ac_prog in nm
38379 do
38380   # Extract the first word of "$ac_prog", so it can be a program name with args.
38381 set dummy $ac_prog; ac_word=$2
38382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38383 $as_echo_n "checking for $ac_word... " >&6; }
38384 if ${ac_cv_prog_ac_ct_NM+:} false; then :
38385   $as_echo_n "(cached) " >&6
38386 else
38387   if test -n "$ac_ct_NM"; then
38388   ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test.
38389 else
38390 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38391 for as_dir in $PATH
38392 do
38393   IFS=$as_save_IFS
38394   test -z "$as_dir" && as_dir=.
38395     for ac_exec_ext in '' $ac_executable_extensions; do
38396   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38397     ac_cv_prog_ac_ct_NM="$ac_prog"
38398     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38399     break 2
38400   fi
38401 done
38402   done
38403 IFS=$as_save_IFS
38404 
38405 fi
38406 fi
38407 ac_ct_NM=$ac_cv_prog_ac_ct_NM
38408 if test -n "$ac_ct_NM"; then
38409   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5
38410 $as_echo "$ac_ct_NM" >&6; }
38411 else
38412   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38413 $as_echo "no" >&6; }
38414 fi
38415 
38416 
38417   test -n "$ac_ct_NM" && break
38418 done
38419 
38420   if test "x$ac_ct_NM" = x; then
38421     NM=""
38422   else
38423     case $cross_compiling:$ac_tool_warned in
38424 yes:)
38425 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
38426 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
38427 ac_tool_warned=yes ;;
38428 esac
38429     NM=$ac_ct_NM
38430   fi
38431 fi
38432 
38433     else
38434       # If it succeeded, then it was overridden by the user. We will use it
38435       # for the tool.
38436 
38437       # First remove it from the list of overridden variables, so we can test
38438       # for unknown variables in the end.
38439       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
38440 
38441       # Check if the provided tool contains a complete path.
38442       tool_specified="$NM"
38443       tool_basename="${tool_specified##*/}"
38444       if test "x$tool_basename" = "x$tool_specified"; then
38445         # A command without a complete path is provided, search $PATH.
38446         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5
38447 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;}
38448         # Extract the first word of "$tool_basename", so it can be a program name with args.
38449 set dummy $tool_basename; ac_word=$2
38450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38451 $as_echo_n "checking for $ac_word... " >&6; }
38452 if ${ac_cv_path_NM+:} false; then :
38453   $as_echo_n "(cached) " >&6
38454 else
38455   case $NM in
38456   [\\/]* | ?:[\\/]*)
38457   ac_cv_path_NM="$NM" # Let the user override the test with a path.
38458   ;;
38459   *)
38460   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38461 for as_dir in $PATH
38462 do
38463   IFS=$as_save_IFS
38464   test -z "$as_dir" && as_dir=.
38465     for ac_exec_ext in '' $ac_executable_extensions; do
38466   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38467     ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
38468     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38469     break 2
38470   fi
38471 done
38472   done
38473 IFS=$as_save_IFS
38474 
38475   ;;
38476 esac
38477 fi
38478 NM=$ac_cv_path_NM
38479 if test -n "$NM"; then
38480   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
38481 $as_echo "$NM" >&6; }
38482 else
38483   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38484 $as_echo "no" >&6; }
38485 fi
38486 
38487 
38488         if test "x$NM" = x; then
38489           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
38490         fi
38491       else
38492         # Otherwise we believe it is a complete path. Use it as it is.
38493         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5
38494 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;}
38495         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5
38496 $as_echo_n "checking for NM... " >&6; }
38497         if test ! -x "$tool_specified"; then
38498           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
38499 $as_echo "not found" >&6; }
38500           as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5
38501         fi
38502         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
38503 $as_echo "$tool_specified" >&6; }
38504       fi
38505     fi
38506   fi
38507 
38508 
38509 
38510   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38511 
38512   # First separate the path from the arguments. This will split at the first
38513   # space.
38514   complete="$NM"
38515   path="${complete%% *}"
38516   tmp="$complete EOL"
38517   arguments="${tmp#* }"
38518 
38519   # Input might be given as Windows format, start by converting to
38520   # unix format.
38521   new_path=`$CYGPATH -u "$path"`
38522 
38523   # Now try to locate executable using which
38524   new_path=`$WHICH "$new_path" 2> /dev/null`
38525   # bat and cmd files are not always considered executable in cygwin causing which
38526   # to not find them
38527   if test "x$new_path" = x \
38528       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38529       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38530     new_path=`$CYGPATH -u "$path"`
38531   fi
38532   if test "x$new_path" = x; then
38533     # Oops. Which didn't find the executable.
38534     # The splitting of arguments from the executable at a space might have been incorrect,
38535     # since paths with space are more likely in Windows. Give it another try with the whole
38536     # argument.
38537     path="$complete"
38538     arguments="EOL"
38539     new_path=`$CYGPATH -u "$path"`
38540     new_path=`$WHICH "$new_path" 2> /dev/null`
38541     # bat and cmd files are not always considered executable in cygwin causing which
38542     # to not find them
38543     if test "x$new_path" = x \
38544         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38545         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38546       new_path=`$CYGPATH -u "$path"`
38547     fi
38548     if test "x$new_path" = x; then
38549       # It's still not found. Now this is an unrecoverable error.
38550       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
38551 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
38552       has_space=`$ECHO "$complete" | $GREP " "`
38553       if test "x$has_space" != x; then
38554         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38555 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38556       fi
38557       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
38558     fi
38559   fi
38560 
38561   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
38562   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
38563   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
38564   # "foo.exe" is OK but "foo" is an error.
38565   #
38566   # This test is therefore slightly more accurate than "test -f" to check for file presence.
38567   # It is also a way to make sure we got the proper file name for the real test later on.
38568   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
38569   if test "x$test_shortpath" = x; then
38570     # Short path failed, file does not exist as specified.
38571     # Try adding .exe or .cmd
38572     if test -f "${new_path}.exe"; then
38573       input_to_shortpath="${new_path}.exe"
38574     elif test -f "${new_path}.cmd"; then
38575       input_to_shortpath="${new_path}.cmd"
38576     else
38577       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5
38578 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;}
38579       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
38580 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
38581       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
38582     fi
38583   else
38584     input_to_shortpath="$new_path"
38585   fi
38586 
38587   # Call helper function which possibly converts this using DOS-style short mode.
38588   # If so, the updated path is stored in $new_path.
38589   new_path="$input_to_shortpath"
38590 
38591   input_path="$input_to_shortpath"
38592   # Check if we need to convert this using DOS-style short mode. If the path
38593   # contains just simple characters, use it. Otherwise (spaces, weird characters),
38594   # take no chances and rewrite it.
38595   # Note: m4 eats our [], so we need to use [ and ] instead.
38596   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
38597   if test "x$has_forbidden_chars" != x; then
38598     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38599     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
38600     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
38601     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
38602       # Going to short mode and back again did indeed matter. Since short mode is
38603       # case insensitive, let's make it lowercase to improve readability.
38604       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38605       # Now convert it back to Unix-stile (cygpath)
38606       input_path=`$CYGPATH -u "$shortmode_path"`
38607       new_path="$input_path"
38608     fi
38609   fi
38610 
38611   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
38612   if test "x$test_cygdrive_prefix" = x; then
38613     # As a simple fix, exclude /usr/bin since it's not a real path.
38614     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
38615       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
38616       # a path prefixed by /cygdrive for fixpath to work.
38617       new_path="$CYGWIN_ROOT_PATH$input_path"
38618     fi
38619   fi
38620 
38621   # remove trailing .exe if any
38622   new_path="${new_path/%.exe/}"
38623 
38624   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38625 
38626   # First separate the path from the arguments. This will split at the first
38627   # space.
38628   complete="$NM"
38629   path="${complete%% *}"
38630   tmp="$complete EOL"
38631   arguments="${tmp#* }"
38632 
38633   # Input might be given as Windows format, start by converting to
38634   # unix format.
38635   new_path="$path"
38636 
38637   windows_path="$new_path"
38638   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38639     unix_path=`$CYGPATH -u "$windows_path"`
38640     new_path="$unix_path"
38641   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38642     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38643     new_path="$unix_path"
38644   fi
38645 
38646 
38647   # Now try to locate executable using which
38648   new_path=`$WHICH "$new_path" 2> /dev/null`
38649 
38650   if test "x$new_path" = x; then
38651     # Oops. Which didn't find the executable.
38652     # The splitting of arguments from the executable at a space might have been incorrect,
38653     # since paths with space are more likely in Windows. Give it another try with the whole
38654     # argument.
38655     path="$complete"
38656     arguments="EOL"
38657     new_path="$path"
38658 
38659   windows_path="$new_path"
38660   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38661     unix_path=`$CYGPATH -u "$windows_path"`
38662     new_path="$unix_path"
38663   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38664     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38665     new_path="$unix_path"
38666   fi
38667 
38668 
38669     new_path=`$WHICH "$new_path" 2> /dev/null`
38670 
38671     if test "x$new_path" = x; then
38672       # It's still not found. Now this is an unrecoverable error.
38673       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
38674 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
38675       has_space=`$ECHO "$complete" | $GREP " "`
38676       if test "x$has_space" != x; then
38677         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38678 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38679       fi
38680       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
38681     fi
38682   fi
38683 
38684   # Now new_path has a complete unix path to the binary
38685   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
38686     # Keep paths in /bin as-is, but remove trailing .exe if any
38687     new_path="${new_path/%.exe/}"
38688     # Do not save /bin paths to all_fixpath_prefixes!
38689   else
38690     # Not in mixed or Windows style, start by that.
38691     new_path=`cmd //c echo $new_path`
38692 
38693   input_path="$new_path"
38694   # Check if we need to convert this using DOS-style short mode. If the path
38695   # contains just simple characters, use it. Otherwise (spaces, weird characters),
38696   # take no chances and rewrite it.
38697   # Note: m4 eats our [], so we need to use [ and ] instead.
38698   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
38699   if test "x$has_forbidden_chars" != x; then
38700     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38701     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38702   fi
38703 
38704     # Output is in $new_path
38705 
38706   windows_path="$new_path"
38707   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38708     unix_path=`$CYGPATH -u "$windows_path"`
38709     new_path="$unix_path"
38710   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38711     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38712     new_path="$unix_path"
38713   fi
38714 
38715     # remove trailing .exe if any
38716     new_path="${new_path/%.exe/}"
38717 
38718     # Save the first 10 bytes of this path to the storage, so fixpath can work.
38719     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
38720   fi
38721 
38722   else
38723     # We're on a posix platform. Hooray! :)
38724     # First separate the path from the arguments. This will split at the first
38725     # space.
38726     complete="$NM"
38727     path="${complete%% *}"
38728     tmp="$complete EOL"
38729     arguments="${tmp#* }"
38730 
38731     # Cannot rely on the command "which" here since it doesn't always work.
38732     is_absolute_path=`$ECHO "$path" | $GREP ^/`
38733     if test -z "$is_absolute_path"; then
38734       # Path to executable is not absolute. Find it.
38735       IFS_save="$IFS"
38736       IFS=:
38737       for p in $PATH; do
38738         if test -f "$p/$path" && test -x "$p/$path"; then
38739           new_path="$p/$path"
38740           break
38741         fi
38742       done
38743       IFS="$IFS_save"
38744     else
38745       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving NM (as $path) failed, using $path directly." >&5
38746 $as_echo "$as_me: Resolving NM (as $path) failed, using $path directly." >&6;}
38747       new_path="$path"
38748     fi
38749 
38750     if test "x$new_path" = x; then
38751       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
38752 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
38753       has_space=`$ECHO "$complete" | $GREP " "`
38754       if test "x$has_space" != x; then
38755         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
38756 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
38757       fi
38758       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
38759     fi
38760   fi
38761 
38762   # Now join together the path and the arguments once again
38763   if test "x$arguments" != xEOL; then
38764     new_complete="$new_path ${arguments% *}"
38765   else
38766     new_complete="$new_path"
38767   fi
38768 
38769   if test "x$complete" != "x$new_complete"; then
38770     NM="$new_complete"
38771     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5
38772 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;}
38773   fi
38774 
38775     GNM="$NM"
38776 
38777 
38778 
38779   # Publish this variable in the help.
38780 
38781 
38782   if test "x$STRIP" = x; then
38783     # The variable is not set by user, try to locate tool using the code snippet
38784     if test -n "$ac_tool_prefix"; then
38785   for ac_prog in strip
38786   do
38787     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
38788 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
38789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38790 $as_echo_n "checking for $ac_word... " >&6; }
38791 if ${ac_cv_prog_STRIP+:} false; then :
38792   $as_echo_n "(cached) " >&6
38793 else
38794   if test -n "$STRIP"; then
38795   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
38796 else
38797 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38798 for as_dir in $PATH
38799 do
38800   IFS=$as_save_IFS
38801   test -z "$as_dir" && as_dir=.
38802     for ac_exec_ext in '' $ac_executable_extensions; do
38803   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38804     ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog"
38805     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38806     break 2
38807   fi
38808 done
38809   done
38810 IFS=$as_save_IFS
38811 
38812 fi
38813 fi
38814 STRIP=$ac_cv_prog_STRIP
38815 if test -n "$STRIP"; then
38816   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
38817 $as_echo "$STRIP" >&6; }
38818 else
38819   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38820 $as_echo "no" >&6; }
38821 fi
38822 
38823 
38824     test -n "$STRIP" && break
38825   done
38826 fi
38827 if test -z "$STRIP"; then
38828   ac_ct_STRIP=$STRIP
38829   for ac_prog in strip
38830 do
38831   # Extract the first word of "$ac_prog", so it can be a program name with args.
38832 set dummy $ac_prog; ac_word=$2
38833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38834 $as_echo_n "checking for $ac_word... " >&6; }
38835 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
38836   $as_echo_n "(cached) " >&6
38837 else
38838   if test -n "$ac_ct_STRIP"; then
38839   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
38840 else
38841 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38842 for as_dir in $PATH
38843 do
38844   IFS=$as_save_IFS
38845   test -z "$as_dir" && as_dir=.
38846     for ac_exec_ext in '' $ac_executable_extensions; do
38847   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38848     ac_cv_prog_ac_ct_STRIP="$ac_prog"
38849     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38850     break 2
38851   fi
38852 done
38853   done
38854 IFS=$as_save_IFS
38855 
38856 fi
38857 fi
38858 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
38859 if test -n "$ac_ct_STRIP"; then
38860   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
38861 $as_echo "$ac_ct_STRIP" >&6; }
38862 else
38863   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38864 $as_echo "no" >&6; }
38865 fi
38866 
38867 
38868   test -n "$ac_ct_STRIP" && break
38869 done
38870 
38871   if test "x$ac_ct_STRIP" = x; then
38872     STRIP=""
38873   else
38874     case $cross_compiling:$ac_tool_warned in
38875 yes:)
38876 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
38877 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
38878 ac_tool_warned=yes ;;
38879 esac
38880     STRIP=$ac_ct_STRIP
38881   fi
38882 fi
38883 
38884   else
38885     # The variable is set, but is it from the command line or the environment?
38886 
38887     # Try to remove the string !STRIP! from our list.
38888     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/}
38889     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
38890       # If it failed, the variable was not from the command line. Ignore it,
38891       # but warn the user (except for BASH, which is always set by the calling BASH).
38892       if test "xSTRIP" != xBASH; then
38893         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5
38894 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;}
38895       fi
38896       # Try to locate tool using the code snippet
38897       if test -n "$ac_tool_prefix"; then
38898   for ac_prog in strip
38899   do
38900     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
38901 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
38902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38903 $as_echo_n "checking for $ac_word... " >&6; }
38904 if ${ac_cv_prog_STRIP+:} false; then :
38905   $as_echo_n "(cached) " >&6
38906 else
38907   if test -n "$STRIP"; then
38908   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
38909 else
38910 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38911 for as_dir in $PATH
38912 do
38913   IFS=$as_save_IFS
38914   test -z "$as_dir" && as_dir=.
38915     for ac_exec_ext in '' $ac_executable_extensions; do
38916   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38917     ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog"
38918     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38919     break 2
38920   fi
38921 done
38922   done
38923 IFS=$as_save_IFS
38924 
38925 fi
38926 fi
38927 STRIP=$ac_cv_prog_STRIP
38928 if test -n "$STRIP"; then
38929   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
38930 $as_echo "$STRIP" >&6; }
38931 else
38932   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38933 $as_echo "no" >&6; }
38934 fi
38935 
38936 
38937     test -n "$STRIP" && break
38938   done
38939 fi
38940 if test -z "$STRIP"; then
38941   ac_ct_STRIP=$STRIP
38942   for ac_prog in strip
38943 do
38944   # Extract the first word of "$ac_prog", so it can be a program name with args.
38945 set dummy $ac_prog; ac_word=$2
38946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38947 $as_echo_n "checking for $ac_word... " >&6; }
38948 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
38949   $as_echo_n "(cached) " >&6
38950 else
38951   if test -n "$ac_ct_STRIP"; then
38952   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
38953 else
38954 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38955 for as_dir in $PATH
38956 do
38957   IFS=$as_save_IFS
38958   test -z "$as_dir" && as_dir=.
38959     for ac_exec_ext in '' $ac_executable_extensions; do
38960   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38961     ac_cv_prog_ac_ct_STRIP="$ac_prog"
38962     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38963     break 2
38964   fi
38965 done
38966   done
38967 IFS=$as_save_IFS
38968 
38969 fi
38970 fi
38971 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
38972 if test -n "$ac_ct_STRIP"; then
38973   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
38974 $as_echo "$ac_ct_STRIP" >&6; }
38975 else
38976   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38977 $as_echo "no" >&6; }
38978 fi
38979 
38980 
38981   test -n "$ac_ct_STRIP" && break
38982 done
38983 
38984   if test "x$ac_ct_STRIP" = x; then
38985     STRIP=""
38986   else
38987     case $cross_compiling:$ac_tool_warned in
38988 yes:)
38989 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
38990 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
38991 ac_tool_warned=yes ;;
38992 esac
38993     STRIP=$ac_ct_STRIP
38994   fi
38995 fi
38996 
38997     else
38998       # If it succeeded, then it was overridden by the user. We will use it
38999       # for the tool.
39000 
39001       # First remove it from the list of overridden variables, so we can test
39002       # for unknown variables in the end.
39003       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
39004 
39005       # Check if the provided tool contains a complete path.
39006       tool_specified="$STRIP"
39007       tool_basename="${tool_specified##*/}"
39008       if test "x$tool_basename" = "x$tool_specified"; then
39009         # A command without a complete path is provided, search $PATH.
39010         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5
39011 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;}
39012         # Extract the first word of "$tool_basename", so it can be a program name with args.
39013 set dummy $tool_basename; ac_word=$2
39014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39015 $as_echo_n "checking for $ac_word... " >&6; }
39016 if ${ac_cv_path_STRIP+:} false; then :
39017   $as_echo_n "(cached) " >&6
39018 else
39019   case $STRIP in
39020   [\\/]* | ?:[\\/]*)
39021   ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
39022   ;;
39023   *)
39024   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39025 for as_dir in $PATH
39026 do
39027   IFS=$as_save_IFS
39028   test -z "$as_dir" && as_dir=.
39029     for ac_exec_ext in '' $ac_executable_extensions; do
39030   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39031     ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
39032     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39033     break 2
39034   fi
39035 done
39036   done
39037 IFS=$as_save_IFS
39038 
39039   ;;
39040 esac
39041 fi
39042 STRIP=$ac_cv_path_STRIP
39043 if test -n "$STRIP"; then
39044   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
39045 $as_echo "$STRIP" >&6; }
39046 else
39047   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39048 $as_echo "no" >&6; }
39049 fi
39050 
39051 
39052         if test "x$STRIP" = x; then
39053           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
39054         fi
39055       else
39056         # Otherwise we believe it is a complete path. Use it as it is.
39057         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5
39058 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;}
39059         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5
39060 $as_echo_n "checking for STRIP... " >&6; }
39061         if test ! -x "$tool_specified"; then
39062           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
39063 $as_echo "not found" >&6; }
39064           as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5
39065         fi
39066         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
39067 $as_echo "$tool_specified" >&6; }
39068       fi
39069     fi
39070   fi
39071 
39072 
39073 
39074   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39075 
39076   # First separate the path from the arguments. This will split at the first
39077   # space.
39078   complete="$STRIP"
39079   path="${complete%% *}"
39080   tmp="$complete EOL"
39081   arguments="${tmp#* }"
39082 
39083   # Input might be given as Windows format, start by converting to
39084   # unix format.
39085   new_path=`$CYGPATH -u "$path"`
39086 
39087   # Now try to locate executable using which
39088   new_path=`$WHICH "$new_path" 2> /dev/null`
39089   # bat and cmd files are not always considered executable in cygwin causing which
39090   # to not find them
39091   if test "x$new_path" = x \
39092       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39093       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39094     new_path=`$CYGPATH -u "$path"`
39095   fi
39096   if test "x$new_path" = x; then
39097     # Oops. Which didn't find the executable.
39098     # The splitting of arguments from the executable at a space might have been incorrect,
39099     # since paths with space are more likely in Windows. Give it another try with the whole
39100     # argument.
39101     path="$complete"
39102     arguments="EOL"
39103     new_path=`$CYGPATH -u "$path"`
39104     new_path=`$WHICH "$new_path" 2> /dev/null`
39105     # bat and cmd files are not always considered executable in cygwin causing which
39106     # to not find them
39107     if test "x$new_path" = x \
39108         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39109         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39110       new_path=`$CYGPATH -u "$path"`
39111     fi
39112     if test "x$new_path" = x; then
39113       # It's still not found. Now this is an unrecoverable error.
39114       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
39115 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
39116       has_space=`$ECHO "$complete" | $GREP " "`
39117       if test "x$has_space" != x; then
39118         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39119 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39120       fi
39121       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
39122     fi
39123   fi
39124 
39125   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
39126   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
39127   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
39128   # "foo.exe" is OK but "foo" is an error.
39129   #
39130   # This test is therefore slightly more accurate than "test -f" to check for file presence.
39131   # It is also a way to make sure we got the proper file name for the real test later on.
39132   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
39133   if test "x$test_shortpath" = x; then
39134     # Short path failed, file does not exist as specified.
39135     # Try adding .exe or .cmd
39136     if test -f "${new_path}.exe"; then
39137       input_to_shortpath="${new_path}.exe"
39138     elif test -f "${new_path}.cmd"; then
39139       input_to_shortpath="${new_path}.cmd"
39140     else
39141       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5
39142 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;}
39143       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
39144 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
39145       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
39146     fi
39147   else
39148     input_to_shortpath="$new_path"
39149   fi
39150 
39151   # Call helper function which possibly converts this using DOS-style short mode.
39152   # If so, the updated path is stored in $new_path.
39153   new_path="$input_to_shortpath"
39154 
39155   input_path="$input_to_shortpath"
39156   # Check if we need to convert this using DOS-style short mode. If the path
39157   # contains just simple characters, use it. Otherwise (spaces, weird characters),
39158   # take no chances and rewrite it.
39159   # Note: m4 eats our [], so we need to use [ and ] instead.
39160   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
39161   if test "x$has_forbidden_chars" != x; then
39162     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39163     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
39164     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
39165     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
39166       # Going to short mode and back again did indeed matter. Since short mode is
39167       # case insensitive, let's make it lowercase to improve readability.
39168       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39169       # Now convert it back to Unix-stile (cygpath)
39170       input_path=`$CYGPATH -u "$shortmode_path"`
39171       new_path="$input_path"
39172     fi
39173   fi
39174 
39175   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
39176   if test "x$test_cygdrive_prefix" = x; then
39177     # As a simple fix, exclude /usr/bin since it's not a real path.
39178     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
39179       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
39180       # a path prefixed by /cygdrive for fixpath to work.
39181       new_path="$CYGWIN_ROOT_PATH$input_path"
39182     fi
39183   fi
39184 
39185   # remove trailing .exe if any
39186   new_path="${new_path/%.exe/}"
39187 
39188   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39189 
39190   # First separate the path from the arguments. This will split at the first
39191   # space.
39192   complete="$STRIP"
39193   path="${complete%% *}"
39194   tmp="$complete EOL"
39195   arguments="${tmp#* }"
39196 
39197   # Input might be given as Windows format, start by converting to
39198   # unix format.
39199   new_path="$path"
39200 
39201   windows_path="$new_path"
39202   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39203     unix_path=`$CYGPATH -u "$windows_path"`
39204     new_path="$unix_path"
39205   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39206     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39207     new_path="$unix_path"
39208   fi
39209 
39210 
39211   # Now try to locate executable using which
39212   new_path=`$WHICH "$new_path" 2> /dev/null`
39213 
39214   if test "x$new_path" = x; then
39215     # Oops. Which didn't find the executable.
39216     # The splitting of arguments from the executable at a space might have been incorrect,
39217     # since paths with space are more likely in Windows. Give it another try with the whole
39218     # argument.
39219     path="$complete"
39220     arguments="EOL"
39221     new_path="$path"
39222 
39223   windows_path="$new_path"
39224   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39225     unix_path=`$CYGPATH -u "$windows_path"`
39226     new_path="$unix_path"
39227   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39228     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39229     new_path="$unix_path"
39230   fi
39231 
39232 
39233     new_path=`$WHICH "$new_path" 2> /dev/null`
39234 
39235     if test "x$new_path" = x; then
39236       # It's still not found. Now this is an unrecoverable error.
39237       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
39238 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
39239       has_space=`$ECHO "$complete" | $GREP " "`
39240       if test "x$has_space" != x; then
39241         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39242 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39243       fi
39244       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
39245     fi
39246   fi
39247 
39248   # Now new_path has a complete unix path to the binary
39249   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
39250     # Keep paths in /bin as-is, but remove trailing .exe if any
39251     new_path="${new_path/%.exe/}"
39252     # Do not save /bin paths to all_fixpath_prefixes!
39253   else
39254     # Not in mixed or Windows style, start by that.
39255     new_path=`cmd //c echo $new_path`
39256 
39257   input_path="$new_path"
39258   # Check if we need to convert this using DOS-style short mode. If the path
39259   # contains just simple characters, use it. Otherwise (spaces, weird characters),
39260   # take no chances and rewrite it.
39261   # Note: m4 eats our [], so we need to use [ and ] instead.
39262   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
39263   if test "x$has_forbidden_chars" != x; then
39264     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39265     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39266   fi
39267 
39268     # Output is in $new_path
39269 
39270   windows_path="$new_path"
39271   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39272     unix_path=`$CYGPATH -u "$windows_path"`
39273     new_path="$unix_path"
39274   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39275     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39276     new_path="$unix_path"
39277   fi
39278 
39279     # remove trailing .exe if any
39280     new_path="${new_path/%.exe/}"
39281 
39282     # Save the first 10 bytes of this path to the storage, so fixpath can work.
39283     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
39284   fi
39285 
39286   else
39287     # We're on a posix platform. Hooray! :)
39288     # First separate the path from the arguments. This will split at the first
39289     # space.
39290     complete="$STRIP"
39291     path="${complete%% *}"
39292     tmp="$complete EOL"
39293     arguments="${tmp#* }"
39294 
39295     # Cannot rely on the command "which" here since it doesn't always work.
39296     is_absolute_path=`$ECHO "$path" | $GREP ^/`
39297     if test -z "$is_absolute_path"; then
39298       # Path to executable is not absolute. Find it.
39299       IFS_save="$IFS"
39300       IFS=:
39301       for p in $PATH; do
39302         if test -f "$p/$path" && test -x "$p/$path"; then
39303           new_path="$p/$path"
39304           break
39305         fi
39306       done
39307       IFS="$IFS_save"
39308     else
39309       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving STRIP (as $path) failed, using $path directly." >&5
39310 $as_echo "$as_me: Resolving STRIP (as $path) failed, using $path directly." >&6;}
39311       new_path="$path"
39312     fi
39313 
39314     if test "x$new_path" = x; then
39315       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
39316 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
39317       has_space=`$ECHO "$complete" | $GREP " "`
39318       if test "x$has_space" != x; then
39319         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
39320 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
39321       fi
39322       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
39323     fi
39324   fi
39325 
39326   # Now join together the path and the arguments once again
39327   if test "x$arguments" != xEOL; then
39328     new_complete="$new_path ${arguments% *}"
39329   else
39330     new_complete="$new_path"
39331   fi
39332 
39333   if test "x$complete" != "x$new_complete"; then
39334     STRIP="$new_complete"
39335     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5
39336 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;}
39337   fi
39338 
39339   fi
39340 
39341   # objcopy is used for moving debug symbols to separate files when
39342   # full debug symbols are enabled.
39343   if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then
39344 
39345 
39346   # Publish this variable in the help.
39347 
39348 
39349   if test "x$OBJCOPY" = x; then
39350     # The variable is not set by user, try to locate tool using the code snippet
39351     if test -n "$ac_tool_prefix"; then
39352   for ac_prog in gobjcopy objcopy
39353   do
39354     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
39355 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
39356 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39357 $as_echo_n "checking for $ac_word... " >&6; }
39358 if ${ac_cv_prog_OBJCOPY+:} false; then :
39359   $as_echo_n "(cached) " >&6
39360 else
39361   if test -n "$OBJCOPY"; then
39362   ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
39363 else
39364 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39365 for as_dir in $PATH
39366 do
39367   IFS=$as_save_IFS
39368   test -z "$as_dir" && as_dir=.
39369     for ac_exec_ext in '' $ac_executable_extensions; do
39370   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39371     ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog"
39372     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39373     break 2
39374   fi
39375 done
39376   done
39377 IFS=$as_save_IFS
39378 
39379 fi
39380 fi
39381 OBJCOPY=$ac_cv_prog_OBJCOPY
39382 if test -n "$OBJCOPY"; then
39383   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
39384 $as_echo "$OBJCOPY" >&6; }
39385 else
39386   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39387 $as_echo "no" >&6; }
39388 fi
39389 
39390 
39391     test -n "$OBJCOPY" && break
39392   done
39393 fi
39394 if test -z "$OBJCOPY"; then
39395   ac_ct_OBJCOPY=$OBJCOPY
39396   for ac_prog in gobjcopy objcopy
39397 do
39398   # Extract the first word of "$ac_prog", so it can be a program name with args.
39399 set dummy $ac_prog; ac_word=$2
39400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39401 $as_echo_n "checking for $ac_word... " >&6; }
39402 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then :
39403   $as_echo_n "(cached) " >&6
39404 else
39405   if test -n "$ac_ct_OBJCOPY"; then
39406   ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test.
39407 else
39408 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39409 for as_dir in $PATH
39410 do
39411   IFS=$as_save_IFS
39412   test -z "$as_dir" && as_dir=.
39413     for ac_exec_ext in '' $ac_executable_extensions; do
39414   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39415     ac_cv_prog_ac_ct_OBJCOPY="$ac_prog"
39416     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39417     break 2
39418   fi
39419 done
39420   done
39421 IFS=$as_save_IFS
39422 
39423 fi
39424 fi
39425 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY
39426 if test -n "$ac_ct_OBJCOPY"; then
39427   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5
39428 $as_echo "$ac_ct_OBJCOPY" >&6; }
39429 else
39430   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39431 $as_echo "no" >&6; }
39432 fi
39433 
39434 
39435   test -n "$ac_ct_OBJCOPY" && break
39436 done
39437 
39438   if test "x$ac_ct_OBJCOPY" = x; then
39439     OBJCOPY=""
39440   else
39441     case $cross_compiling:$ac_tool_warned in
39442 yes:)
39443 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
39444 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
39445 ac_tool_warned=yes ;;
39446 esac
39447     OBJCOPY=$ac_ct_OBJCOPY
39448   fi
39449 fi
39450 
39451   else
39452     # The variable is set, but is it from the command line or the environment?
39453 
39454     # Try to remove the string !OBJCOPY! from our list.
39455     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJCOPY!/}
39456     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
39457       # If it failed, the variable was not from the command line. Ignore it,
39458       # but warn the user (except for BASH, which is always set by the calling BASH).
39459       if test "xOBJCOPY" != xBASH; then
39460         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&5
39461 $as_echo "$as_me: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&2;}
39462       fi
39463       # Try to locate tool using the code snippet
39464       if test -n "$ac_tool_prefix"; then
39465   for ac_prog in gobjcopy objcopy
39466   do
39467     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
39468 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
39469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39470 $as_echo_n "checking for $ac_word... " >&6; }
39471 if ${ac_cv_prog_OBJCOPY+:} false; then :
39472   $as_echo_n "(cached) " >&6
39473 else
39474   if test -n "$OBJCOPY"; then
39475   ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
39476 else
39477 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39478 for as_dir in $PATH
39479 do
39480   IFS=$as_save_IFS
39481   test -z "$as_dir" && as_dir=.
39482     for ac_exec_ext in '' $ac_executable_extensions; do
39483   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39484     ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog"
39485     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39486     break 2
39487   fi
39488 done
39489   done
39490 IFS=$as_save_IFS
39491 
39492 fi
39493 fi
39494 OBJCOPY=$ac_cv_prog_OBJCOPY
39495 if test -n "$OBJCOPY"; then
39496   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
39497 $as_echo "$OBJCOPY" >&6; }
39498 else
39499   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39500 $as_echo "no" >&6; }
39501 fi
39502 
39503 
39504     test -n "$OBJCOPY" && break
39505   done
39506 fi
39507 if test -z "$OBJCOPY"; then
39508   ac_ct_OBJCOPY=$OBJCOPY
39509   for ac_prog in gobjcopy objcopy
39510 do
39511   # Extract the first word of "$ac_prog", so it can be a program name with args.
39512 set dummy $ac_prog; ac_word=$2
39513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39514 $as_echo_n "checking for $ac_word... " >&6; }
39515 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then :
39516   $as_echo_n "(cached) " >&6
39517 else
39518   if test -n "$ac_ct_OBJCOPY"; then
39519   ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test.
39520 else
39521 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39522 for as_dir in $PATH
39523 do
39524   IFS=$as_save_IFS
39525   test -z "$as_dir" && as_dir=.
39526     for ac_exec_ext in '' $ac_executable_extensions; do
39527   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39528     ac_cv_prog_ac_ct_OBJCOPY="$ac_prog"
39529     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39530     break 2
39531   fi
39532 done
39533   done
39534 IFS=$as_save_IFS
39535 
39536 fi
39537 fi
39538 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY
39539 if test -n "$ac_ct_OBJCOPY"; then
39540   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5
39541 $as_echo "$ac_ct_OBJCOPY" >&6; }
39542 else
39543   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39544 $as_echo "no" >&6; }
39545 fi
39546 
39547 
39548   test -n "$ac_ct_OBJCOPY" && break
39549 done
39550 
39551   if test "x$ac_ct_OBJCOPY" = x; then
39552     OBJCOPY=""
39553   else
39554     case $cross_compiling:$ac_tool_warned in
39555 yes:)
39556 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
39557 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
39558 ac_tool_warned=yes ;;
39559 esac
39560     OBJCOPY=$ac_ct_OBJCOPY
39561   fi
39562 fi
39563 
39564     else
39565       # If it succeeded, then it was overridden by the user. We will use it
39566       # for the tool.
39567 
39568       # First remove it from the list of overridden variables, so we can test
39569       # for unknown variables in the end.
39570       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
39571 
39572       # Check if the provided tool contains a complete path.
39573       tool_specified="$OBJCOPY"
39574       tool_basename="${tool_specified##*/}"
39575       if test "x$tool_basename" = "x$tool_specified"; then
39576         # A command without a complete path is provided, search $PATH.
39577         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJCOPY=$tool_basename" >&5
39578 $as_echo "$as_me: Will search for user supplied tool OBJCOPY=$tool_basename" >&6;}
39579         # Extract the first word of "$tool_basename", so it can be a program name with args.
39580 set dummy $tool_basename; ac_word=$2
39581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39582 $as_echo_n "checking for $ac_word... " >&6; }
39583 if ${ac_cv_path_OBJCOPY+:} false; then :
39584   $as_echo_n "(cached) " >&6
39585 else
39586   case $OBJCOPY in
39587   [\\/]* | ?:[\\/]*)
39588   ac_cv_path_OBJCOPY="$OBJCOPY" # Let the user override the test with a path.
39589   ;;
39590   *)
39591   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39592 for as_dir in $PATH
39593 do
39594   IFS=$as_save_IFS
39595   test -z "$as_dir" && as_dir=.
39596     for ac_exec_ext in '' $ac_executable_extensions; do
39597   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39598     ac_cv_path_OBJCOPY="$as_dir/$ac_word$ac_exec_ext"
39599     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39600     break 2
39601   fi
39602 done
39603   done
39604 IFS=$as_save_IFS
39605 
39606   ;;
39607 esac
39608 fi
39609 OBJCOPY=$ac_cv_path_OBJCOPY
39610 if test -n "$OBJCOPY"; then
39611   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
39612 $as_echo "$OBJCOPY" >&6; }
39613 else
39614   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39615 $as_echo "no" >&6; }
39616 fi
39617 
39618 
39619         if test "x$OBJCOPY" = x; then
39620           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
39621         fi
39622       else
39623         # Otherwise we believe it is a complete path. Use it as it is.
39624         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJCOPY=$tool_specified" >&5
39625 $as_echo "$as_me: Will use user supplied tool OBJCOPY=$tool_specified" >&6;}
39626         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5
39627 $as_echo_n "checking for OBJCOPY... " >&6; }
39628         if test ! -x "$tool_specified"; then
39629           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
39630 $as_echo "not found" >&6; }
39631           as_fn_error $? "User supplied tool OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5
39632         fi
39633         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
39634 $as_echo "$tool_specified" >&6; }
39635       fi
39636     fi
39637   fi
39638 
39639 
39640     # Only call fixup if objcopy was found.
39641     if test -n "$OBJCOPY"; then
39642 
39643   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39644 
39645   # First separate the path from the arguments. This will split at the first
39646   # space.
39647   complete="$OBJCOPY"
39648   path="${complete%% *}"
39649   tmp="$complete EOL"
39650   arguments="${tmp#* }"
39651 
39652   # Input might be given as Windows format, start by converting to
39653   # unix format.
39654   new_path=`$CYGPATH -u "$path"`
39655 
39656   # Now try to locate executable using which
39657   new_path=`$WHICH "$new_path" 2> /dev/null`
39658   # bat and cmd files are not always considered executable in cygwin causing which
39659   # to not find them
39660   if test "x$new_path" = x \
39661       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39662       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39663     new_path=`$CYGPATH -u "$path"`
39664   fi
39665   if test "x$new_path" = x; then
39666     # Oops. Which didn't find the executable.
39667     # The splitting of arguments from the executable at a space might have been incorrect,
39668     # since paths with space are more likely in Windows. Give it another try with the whole
39669     # argument.
39670     path="$complete"
39671     arguments="EOL"
39672     new_path=`$CYGPATH -u "$path"`
39673     new_path=`$WHICH "$new_path" 2> /dev/null`
39674     # bat and cmd files are not always considered executable in cygwin causing which
39675     # to not find them
39676     if test "x$new_path" = x \
39677         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39678         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39679       new_path=`$CYGPATH -u "$path"`
39680     fi
39681     if test "x$new_path" = x; then
39682       # It's still not found. Now this is an unrecoverable error.
39683       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
39684 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
39685       has_space=`$ECHO "$complete" | $GREP " "`
39686       if test "x$has_space" != x; then
39687         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39688 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39689       fi
39690       as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
39691     fi
39692   fi
39693 
39694   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
39695   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
39696   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
39697   # "foo.exe" is OK but "foo" is an error.
39698   #
39699   # This test is therefore slightly more accurate than "test -f" to check for file presence.
39700   # It is also a way to make sure we got the proper file name for the real test later on.
39701   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
39702   if test "x$test_shortpath" = x; then
39703     # Short path failed, file does not exist as specified.
39704     # Try adding .exe or .cmd
39705     if test -f "${new_path}.exe"; then
39706       input_to_shortpath="${new_path}.exe"
39707     elif test -f "${new_path}.cmd"; then
39708       input_to_shortpath="${new_path}.cmd"
39709     else
39710       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&5
39711 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;}
39712       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
39713 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
39714       as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
39715     fi
39716   else
39717     input_to_shortpath="$new_path"
39718   fi
39719 
39720   # Call helper function which possibly converts this using DOS-style short mode.
39721   # If so, the updated path is stored in $new_path.
39722   new_path="$input_to_shortpath"
39723 
39724   input_path="$input_to_shortpath"
39725   # Check if we need to convert this using DOS-style short mode. If the path
39726   # contains just simple characters, use it. Otherwise (spaces, weird characters),
39727   # take no chances and rewrite it.
39728   # Note: m4 eats our [], so we need to use [ and ] instead.
39729   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
39730   if test "x$has_forbidden_chars" != x; then
39731     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39732     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
39733     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
39734     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
39735       # Going to short mode and back again did indeed matter. Since short mode is
39736       # case insensitive, let's make it lowercase to improve readability.
39737       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39738       # Now convert it back to Unix-stile (cygpath)
39739       input_path=`$CYGPATH -u "$shortmode_path"`
39740       new_path="$input_path"
39741     fi
39742   fi
39743 
39744   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
39745   if test "x$test_cygdrive_prefix" = x; then
39746     # As a simple fix, exclude /usr/bin since it's not a real path.
39747     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
39748       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
39749       # a path prefixed by /cygdrive for fixpath to work.
39750       new_path="$CYGWIN_ROOT_PATH$input_path"
39751     fi
39752   fi
39753 
39754   # remove trailing .exe if any
39755   new_path="${new_path/%.exe/}"
39756 
39757   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39758 
39759   # First separate the path from the arguments. This will split at the first
39760   # space.
39761   complete="$OBJCOPY"
39762   path="${complete%% *}"
39763   tmp="$complete EOL"
39764   arguments="${tmp#* }"
39765 
39766   # Input might be given as Windows format, start by converting to
39767   # unix format.
39768   new_path="$path"
39769 
39770   windows_path="$new_path"
39771   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39772     unix_path=`$CYGPATH -u "$windows_path"`
39773     new_path="$unix_path"
39774   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39775     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39776     new_path="$unix_path"
39777   fi
39778 
39779 
39780   # Now try to locate executable using which
39781   new_path=`$WHICH "$new_path" 2> /dev/null`
39782 
39783   if test "x$new_path" = x; then
39784     # Oops. Which didn't find the executable.
39785     # The splitting of arguments from the executable at a space might have been incorrect,
39786     # since paths with space are more likely in Windows. Give it another try with the whole
39787     # argument.
39788     path="$complete"
39789     arguments="EOL"
39790     new_path="$path"
39791 
39792   windows_path="$new_path"
39793   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39794     unix_path=`$CYGPATH -u "$windows_path"`
39795     new_path="$unix_path"
39796   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39797     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39798     new_path="$unix_path"
39799   fi
39800 
39801 
39802     new_path=`$WHICH "$new_path" 2> /dev/null`
39803 
39804     if test "x$new_path" = x; then
39805       # It's still not found. Now this is an unrecoverable error.
39806       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
39807 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
39808       has_space=`$ECHO "$complete" | $GREP " "`
39809       if test "x$has_space" != x; then
39810         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39811 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39812       fi
39813       as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
39814     fi
39815   fi
39816 
39817   # Now new_path has a complete unix path to the binary
39818   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
39819     # Keep paths in /bin as-is, but remove trailing .exe if any
39820     new_path="${new_path/%.exe/}"
39821     # Do not save /bin paths to all_fixpath_prefixes!
39822   else
39823     # Not in mixed or Windows style, start by that.
39824     new_path=`cmd //c echo $new_path`
39825 
39826   input_path="$new_path"
39827   # Check if we need to convert this using DOS-style short mode. If the path
39828   # contains just simple characters, use it. Otherwise (spaces, weird characters),
39829   # take no chances and rewrite it.
39830   # Note: m4 eats our [], so we need to use [ and ] instead.
39831   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
39832   if test "x$has_forbidden_chars" != x; then
39833     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39834     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39835   fi
39836 
39837     # Output is in $new_path
39838 
39839   windows_path="$new_path"
39840   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39841     unix_path=`$CYGPATH -u "$windows_path"`
39842     new_path="$unix_path"
39843   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39844     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39845     new_path="$unix_path"
39846   fi
39847 
39848     # remove trailing .exe if any
39849     new_path="${new_path/%.exe/}"
39850 
39851     # Save the first 10 bytes of this path to the storage, so fixpath can work.
39852     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
39853   fi
39854 
39855   else
39856     # We're on a posix platform. Hooray! :)
39857     # First separate the path from the arguments. This will split at the first
39858     # space.
39859     complete="$OBJCOPY"
39860     path="${complete%% *}"
39861     tmp="$complete EOL"
39862     arguments="${tmp#* }"
39863 
39864     # Cannot rely on the command "which" here since it doesn't always work.
39865     is_absolute_path=`$ECHO "$path" | $GREP ^/`
39866     if test -z "$is_absolute_path"; then
39867       # Path to executable is not absolute. Find it.
39868       IFS_save="$IFS"
39869       IFS=:
39870       for p in $PATH; do
39871         if test -f "$p/$path" && test -x "$p/$path"; then
39872           new_path="$p/$path"
39873           break
39874         fi
39875       done
39876       IFS="$IFS_save"
39877     else
39878       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving OBJCOPY (as $path) failed, using $path directly." >&5
39879 $as_echo "$as_me: Resolving OBJCOPY (as $path) failed, using $path directly." >&6;}
39880       new_path="$path"
39881     fi
39882 
39883     if test "x$new_path" = x; then
39884       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
39885 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
39886       has_space=`$ECHO "$complete" | $GREP " "`
39887       if test "x$has_space" != x; then
39888         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
39889 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
39890       fi
39891       as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
39892     fi
39893   fi
39894 
39895   # Now join together the path and the arguments once again
39896   if test "x$arguments" != xEOL; then
39897     new_complete="$new_path ${arguments% *}"
39898   else
39899     new_complete="$new_path"
39900   fi
39901 
39902   if test "x$complete" != "x$new_complete"; then
39903     OBJCOPY="$new_complete"
39904     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJCOPY to \"$new_complete\"" >&5
39905 $as_echo "$as_me: Rewriting OBJCOPY to \"$new_complete\"" >&6;}
39906   fi
39907 
39908     fi
39909   fi
39910 
39911 
39912 
39913   # Publish this variable in the help.
39914 
39915 
39916   if test "x$OBJDUMP" = x; then
39917     # The variable is not set by user, try to locate tool using the code snippet
39918     if test -n "$ac_tool_prefix"; then
39919   for ac_prog in gobjdump objdump
39920   do
39921     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
39922 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
39923 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39924 $as_echo_n "checking for $ac_word... " >&6; }
39925 if ${ac_cv_prog_OBJDUMP+:} false; then :
39926   $as_echo_n "(cached) " >&6
39927 else
39928   if test -n "$OBJDUMP"; then
39929   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
39930 else
39931 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39932 for as_dir in $PATH
39933 do
39934   IFS=$as_save_IFS
39935   test -z "$as_dir" && as_dir=.
39936     for ac_exec_ext in '' $ac_executable_extensions; do
39937   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39938     ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog"
39939     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39940     break 2
39941   fi
39942 done
39943   done
39944 IFS=$as_save_IFS
39945 
39946 fi
39947 fi
39948 OBJDUMP=$ac_cv_prog_OBJDUMP
39949 if test -n "$OBJDUMP"; then
39950   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
39951 $as_echo "$OBJDUMP" >&6; }
39952 else
39953   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39954 $as_echo "no" >&6; }
39955 fi
39956 
39957 
39958     test -n "$OBJDUMP" && break
39959   done
39960 fi
39961 if test -z "$OBJDUMP"; then
39962   ac_ct_OBJDUMP=$OBJDUMP
39963   for ac_prog in gobjdump objdump
39964 do
39965   # Extract the first word of "$ac_prog", so it can be a program name with args.
39966 set dummy $ac_prog; ac_word=$2
39967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39968 $as_echo_n "checking for $ac_word... " >&6; }
39969 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
39970   $as_echo_n "(cached) " >&6
39971 else
39972   if test -n "$ac_ct_OBJDUMP"; then
39973   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
39974 else
39975 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39976 for as_dir in $PATH
39977 do
39978   IFS=$as_save_IFS
39979   test -z "$as_dir" && as_dir=.
39980     for ac_exec_ext in '' $ac_executable_extensions; do
39981   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39982     ac_cv_prog_ac_ct_OBJDUMP="$ac_prog"
39983     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39984     break 2
39985   fi
39986 done
39987   done
39988 IFS=$as_save_IFS
39989 
39990 fi
39991 fi
39992 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
39993 if test -n "$ac_ct_OBJDUMP"; then
39994   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
39995 $as_echo "$ac_ct_OBJDUMP" >&6; }
39996 else
39997   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39998 $as_echo "no" >&6; }
39999 fi
40000 
40001 
40002   test -n "$ac_ct_OBJDUMP" && break
40003 done
40004 
40005   if test "x$ac_ct_OBJDUMP" = x; then
40006     OBJDUMP=""
40007   else
40008     case $cross_compiling:$ac_tool_warned in
40009 yes:)
40010 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
40011 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
40012 ac_tool_warned=yes ;;
40013 esac
40014     OBJDUMP=$ac_ct_OBJDUMP
40015   fi
40016 fi
40017 
40018   else
40019     # The variable is set, but is it from the command line or the environment?
40020 
40021     # Try to remove the string !OBJDUMP! from our list.
40022     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJDUMP!/}
40023     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
40024       # If it failed, the variable was not from the command line. Ignore it,
40025       # but warn the user (except for BASH, which is always set by the calling BASH).
40026       if test "xOBJDUMP" != xBASH; then
40027         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&5
40028 $as_echo "$as_me: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&2;}
40029       fi
40030       # Try to locate tool using the code snippet
40031       if test -n "$ac_tool_prefix"; then
40032   for ac_prog in gobjdump objdump
40033   do
40034     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
40035 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
40036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40037 $as_echo_n "checking for $ac_word... " >&6; }
40038 if ${ac_cv_prog_OBJDUMP+:} false; then :
40039   $as_echo_n "(cached) " >&6
40040 else
40041   if test -n "$OBJDUMP"; then
40042   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
40043 else
40044 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40045 for as_dir in $PATH
40046 do
40047   IFS=$as_save_IFS
40048   test -z "$as_dir" && as_dir=.
40049     for ac_exec_ext in '' $ac_executable_extensions; do
40050   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40051     ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog"
40052     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40053     break 2
40054   fi
40055 done
40056   done
40057 IFS=$as_save_IFS
40058 
40059 fi
40060 fi
40061 OBJDUMP=$ac_cv_prog_OBJDUMP
40062 if test -n "$OBJDUMP"; then
40063   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
40064 $as_echo "$OBJDUMP" >&6; }
40065 else
40066   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40067 $as_echo "no" >&6; }
40068 fi
40069 
40070 
40071     test -n "$OBJDUMP" && break
40072   done
40073 fi
40074 if test -z "$OBJDUMP"; then
40075   ac_ct_OBJDUMP=$OBJDUMP
40076   for ac_prog in gobjdump objdump
40077 do
40078   # Extract the first word of "$ac_prog", so it can be a program name with args.
40079 set dummy $ac_prog; ac_word=$2
40080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40081 $as_echo_n "checking for $ac_word... " >&6; }
40082 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
40083   $as_echo_n "(cached) " >&6
40084 else
40085   if test -n "$ac_ct_OBJDUMP"; then
40086   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
40087 else
40088 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40089 for as_dir in $PATH
40090 do
40091   IFS=$as_save_IFS
40092   test -z "$as_dir" && as_dir=.
40093     for ac_exec_ext in '' $ac_executable_extensions; do
40094   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40095     ac_cv_prog_ac_ct_OBJDUMP="$ac_prog"
40096     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40097     break 2
40098   fi
40099 done
40100   done
40101 IFS=$as_save_IFS
40102 
40103 fi
40104 fi
40105 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
40106 if test -n "$ac_ct_OBJDUMP"; then
40107   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
40108 $as_echo "$ac_ct_OBJDUMP" >&6; }
40109 else
40110   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40111 $as_echo "no" >&6; }
40112 fi
40113 
40114 
40115   test -n "$ac_ct_OBJDUMP" && break
40116 done
40117 
40118   if test "x$ac_ct_OBJDUMP" = x; then
40119     OBJDUMP=""
40120   else
40121     case $cross_compiling:$ac_tool_warned in
40122 yes:)
40123 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
40124 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
40125 ac_tool_warned=yes ;;
40126 esac
40127     OBJDUMP=$ac_ct_OBJDUMP
40128   fi
40129 fi
40130 
40131     else
40132       # If it succeeded, then it was overridden by the user. We will use it
40133       # for the tool.
40134 
40135       # First remove it from the list of overridden variables, so we can test
40136       # for unknown variables in the end.
40137       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
40138 
40139       # Check if the provided tool contains a complete path.
40140       tool_specified="$OBJDUMP"
40141       tool_basename="${tool_specified##*/}"
40142       if test "x$tool_basename" = "x$tool_specified"; then
40143         # A command without a complete path is provided, search $PATH.
40144         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJDUMP=$tool_basename" >&5
40145 $as_echo "$as_me: Will search for user supplied tool OBJDUMP=$tool_basename" >&6;}
40146         # Extract the first word of "$tool_basename", so it can be a program name with args.
40147 set dummy $tool_basename; ac_word=$2
40148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40149 $as_echo_n "checking for $ac_word... " >&6; }
40150 if ${ac_cv_path_OBJDUMP+:} false; then :
40151   $as_echo_n "(cached) " >&6
40152 else
40153   case $OBJDUMP in
40154   [\\/]* | ?:[\\/]*)
40155   ac_cv_path_OBJDUMP="$OBJDUMP" # Let the user override the test with a path.
40156   ;;
40157   *)
40158   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40159 for as_dir in $PATH
40160 do
40161   IFS=$as_save_IFS
40162   test -z "$as_dir" && as_dir=.
40163     for ac_exec_ext in '' $ac_executable_extensions; do
40164   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40165     ac_cv_path_OBJDUMP="$as_dir/$ac_word$ac_exec_ext"
40166     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40167     break 2
40168   fi
40169 done
40170   done
40171 IFS=$as_save_IFS
40172 
40173   ;;
40174 esac
40175 fi
40176 OBJDUMP=$ac_cv_path_OBJDUMP
40177 if test -n "$OBJDUMP"; then
40178   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
40179 $as_echo "$OBJDUMP" >&6; }
40180 else
40181   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40182 $as_echo "no" >&6; }
40183 fi
40184 
40185 
40186         if test "x$OBJDUMP" = x; then
40187           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
40188         fi
40189       else
40190         # Otherwise we believe it is a complete path. Use it as it is.
40191         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJDUMP=$tool_specified" >&5
40192 $as_echo "$as_me: Will use user supplied tool OBJDUMP=$tool_specified" >&6;}
40193         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5
40194 $as_echo_n "checking for OBJDUMP... " >&6; }
40195         if test ! -x "$tool_specified"; then
40196           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
40197 $as_echo "not found" >&6; }
40198           as_fn_error $? "User supplied tool OBJDUMP=$tool_specified does not exist or is not executable" "$LINENO" 5
40199         fi
40200         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
40201 $as_echo "$tool_specified" >&6; }
40202       fi
40203     fi
40204   fi
40205 
40206 
40207   if test "x$OBJDUMP" != x; then
40208     # Only used for compare.sh; we can live without it. BASIC_FIXUP_EXECUTABLE bails if argument is missing.
40209 
40210   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40211 
40212   # First separate the path from the arguments. This will split at the first
40213   # space.
40214   complete="$OBJDUMP"
40215   path="${complete%% *}"
40216   tmp="$complete EOL"
40217   arguments="${tmp#* }"
40218 
40219   # Input might be given as Windows format, start by converting to
40220   # unix format.
40221   new_path=`$CYGPATH -u "$path"`
40222 
40223   # Now try to locate executable using which
40224   new_path=`$WHICH "$new_path" 2> /dev/null`
40225   # bat and cmd files are not always considered executable in cygwin causing which
40226   # to not find them
40227   if test "x$new_path" = x \
40228       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
40229       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
40230     new_path=`$CYGPATH -u "$path"`
40231   fi
40232   if test "x$new_path" = x; then
40233     # Oops. Which didn't find the executable.
40234     # The splitting of arguments from the executable at a space might have been incorrect,
40235     # since paths with space are more likely in Windows. Give it another try with the whole
40236     # argument.
40237     path="$complete"
40238     arguments="EOL"
40239     new_path=`$CYGPATH -u "$path"`
40240     new_path=`$WHICH "$new_path" 2> /dev/null`
40241     # bat and cmd files are not always considered executable in cygwin causing which
40242     # to not find them
40243     if test "x$new_path" = x \
40244         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
40245         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
40246       new_path=`$CYGPATH -u "$path"`
40247     fi
40248     if test "x$new_path" = x; then
40249       # It's still not found. Now this is an unrecoverable error.
40250       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
40251 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
40252       has_space=`$ECHO "$complete" | $GREP " "`
40253       if test "x$has_space" != x; then
40254         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
40255 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
40256       fi
40257       as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
40258     fi
40259   fi
40260 
40261   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
40262   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
40263   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
40264   # "foo.exe" is OK but "foo" is an error.
40265   #
40266   # This test is therefore slightly more accurate than "test -f" to check for file presence.
40267   # It is also a way to make sure we got the proper file name for the real test later on.
40268   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
40269   if test "x$test_shortpath" = x; then
40270     # Short path failed, file does not exist as specified.
40271     # Try adding .exe or .cmd
40272     if test -f "${new_path}.exe"; then
40273       input_to_shortpath="${new_path}.exe"
40274     elif test -f "${new_path}.cmd"; then
40275       input_to_shortpath="${new_path}.cmd"
40276     else
40277       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&5
40278 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&6;}
40279       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
40280 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
40281       as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
40282     fi
40283   else
40284     input_to_shortpath="$new_path"
40285   fi
40286 
40287   # Call helper function which possibly converts this using DOS-style short mode.
40288   # If so, the updated path is stored in $new_path.
40289   new_path="$input_to_shortpath"
40290 
40291   input_path="$input_to_shortpath"
40292   # Check if we need to convert this using DOS-style short mode. If the path
40293   # contains just simple characters, use it. Otherwise (spaces, weird characters),
40294   # take no chances and rewrite it.
40295   # Note: m4 eats our [], so we need to use [ and ] instead.
40296   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
40297   if test "x$has_forbidden_chars" != x; then
40298     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40299     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
40300     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
40301     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
40302       # Going to short mode and back again did indeed matter. Since short mode is
40303       # case insensitive, let's make it lowercase to improve readability.
40304       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40305       # Now convert it back to Unix-stile (cygpath)
40306       input_path=`$CYGPATH -u "$shortmode_path"`
40307       new_path="$input_path"
40308     fi
40309   fi
40310 
40311   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
40312   if test "x$test_cygdrive_prefix" = x; then
40313     # As a simple fix, exclude /usr/bin since it's not a real path.
40314     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
40315       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
40316       # a path prefixed by /cygdrive for fixpath to work.
40317       new_path="$CYGWIN_ROOT_PATH$input_path"
40318     fi
40319   fi
40320 
40321   # remove trailing .exe if any
40322   new_path="${new_path/%.exe/}"
40323 
40324   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40325 
40326   # First separate the path from the arguments. This will split at the first
40327   # space.
40328   complete="$OBJDUMP"
40329   path="${complete%% *}"
40330   tmp="$complete EOL"
40331   arguments="${tmp#* }"
40332 
40333   # Input might be given as Windows format, start by converting to
40334   # unix format.
40335   new_path="$path"
40336 
40337   windows_path="$new_path"
40338   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40339     unix_path=`$CYGPATH -u "$windows_path"`
40340     new_path="$unix_path"
40341   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40342     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40343     new_path="$unix_path"
40344   fi
40345 
40346 
40347   # Now try to locate executable using which
40348   new_path=`$WHICH "$new_path" 2> /dev/null`
40349 
40350   if test "x$new_path" = x; then
40351     # Oops. Which didn't find the executable.
40352     # The splitting of arguments from the executable at a space might have been incorrect,
40353     # since paths with space are more likely in Windows. Give it another try with the whole
40354     # argument.
40355     path="$complete"
40356     arguments="EOL"
40357     new_path="$path"
40358 
40359   windows_path="$new_path"
40360   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40361     unix_path=`$CYGPATH -u "$windows_path"`
40362     new_path="$unix_path"
40363   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40364     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40365     new_path="$unix_path"
40366   fi
40367 
40368 
40369     new_path=`$WHICH "$new_path" 2> /dev/null`
40370 
40371     if test "x$new_path" = x; then
40372       # It's still not found. Now this is an unrecoverable error.
40373       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
40374 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
40375       has_space=`$ECHO "$complete" | $GREP " "`
40376       if test "x$has_space" != x; then
40377         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
40378 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
40379       fi
40380       as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
40381     fi
40382   fi
40383 
40384   # Now new_path has a complete unix path to the binary
40385   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
40386     # Keep paths in /bin as-is, but remove trailing .exe if any
40387     new_path="${new_path/%.exe/}"
40388     # Do not save /bin paths to all_fixpath_prefixes!
40389   else
40390     # Not in mixed or Windows style, start by that.
40391     new_path=`cmd //c echo $new_path`
40392 
40393   input_path="$new_path"
40394   # Check if we need to convert this using DOS-style short mode. If the path
40395   # contains just simple characters, use it. Otherwise (spaces, weird characters),
40396   # take no chances and rewrite it.
40397   # Note: m4 eats our [], so we need to use [ and ] instead.
40398   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
40399   if test "x$has_forbidden_chars" != x; then
40400     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40401     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40402   fi
40403 
40404     # Output is in $new_path
40405 
40406   windows_path="$new_path"
40407   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40408     unix_path=`$CYGPATH -u "$windows_path"`
40409     new_path="$unix_path"
40410   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40411     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40412     new_path="$unix_path"
40413   fi
40414 
40415     # remove trailing .exe if any
40416     new_path="${new_path/%.exe/}"
40417 
40418     # Save the first 10 bytes of this path to the storage, so fixpath can work.
40419     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
40420   fi
40421 
40422   else
40423     # We're on a posix platform. Hooray! :)
40424     # First separate the path from the arguments. This will split at the first
40425     # space.
40426     complete="$OBJDUMP"
40427     path="${complete%% *}"
40428     tmp="$complete EOL"
40429     arguments="${tmp#* }"
40430 
40431     # Cannot rely on the command "which" here since it doesn't always work.
40432     is_absolute_path=`$ECHO "$path" | $GREP ^/`
40433     if test -z "$is_absolute_path"; then
40434       # Path to executable is not absolute. Find it.
40435       IFS_save="$IFS"
40436       IFS=:
40437       for p in $PATH; do
40438         if test -f "$p/$path" && test -x "$p/$path"; then
40439           new_path="$p/$path"
40440           break
40441         fi
40442       done
40443       IFS="$IFS_save"
40444     else
40445       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving OBJDUMP (as $path) failed, using $path directly." >&5
40446 $as_echo "$as_me: Resolving OBJDUMP (as $path) failed, using $path directly." >&6;}
40447       new_path="$path"
40448     fi
40449 
40450     if test "x$new_path" = x; then
40451       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
40452 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
40453       has_space=`$ECHO "$complete" | $GREP " "`
40454       if test "x$has_space" != x; then
40455         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
40456 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
40457       fi
40458       as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
40459     fi
40460   fi
40461 
40462   # Now join together the path and the arguments once again
40463   if test "x$arguments" != xEOL; then
40464     new_complete="$new_path ${arguments% *}"
40465   else
40466     new_complete="$new_path"
40467   fi
40468 
40469   if test "x$complete" != "x$new_complete"; then
40470     OBJDUMP="$new_complete"
40471     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJDUMP to \"$new_complete\"" >&5
40472 $as_echo "$as_me: Rewriting OBJDUMP to \"$new_complete\"" >&6;}
40473   fi
40474 
40475   fi
40476 
40477   if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
40478 
40479 
40480   # Publish this variable in the help.
40481 
40482 
40483   if test "x$LIPO" = x; then
40484     # The variable is not set by user, try to locate tool using the code snippet
40485     for ac_prog in lipo
40486 do
40487   # Extract the first word of "$ac_prog", so it can be a program name with args.
40488 set dummy $ac_prog; ac_word=$2
40489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40490 $as_echo_n "checking for $ac_word... " >&6; }
40491 if ${ac_cv_path_LIPO+:} false; then :
40492   $as_echo_n "(cached) " >&6
40493 else
40494   case $LIPO in
40495   [\\/]* | ?:[\\/]*)
40496   ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
40497   ;;
40498   *)
40499   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40500 for as_dir in $PATH
40501 do
40502   IFS=$as_save_IFS
40503   test -z "$as_dir" && as_dir=.
40504     for ac_exec_ext in '' $ac_executable_extensions; do
40505   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40506     ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
40507     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40508     break 2
40509   fi
40510 done
40511   done
40512 IFS=$as_save_IFS
40513 
40514   ;;
40515 esac
40516 fi
40517 LIPO=$ac_cv_path_LIPO
40518 if test -n "$LIPO"; then
40519   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
40520 $as_echo "$LIPO" >&6; }
40521 else
40522   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40523 $as_echo "no" >&6; }
40524 fi
40525 
40526 
40527   test -n "$LIPO" && break
40528 done
40529 
40530   else
40531     # The variable is set, but is it from the command line or the environment?
40532 
40533     # Try to remove the string !LIPO! from our list.
40534     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LIPO!/}
40535     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
40536       # If it failed, the variable was not from the command line. Ignore it,
40537       # but warn the user (except for BASH, which is always set by the calling BASH).
40538       if test "xLIPO" != xBASH; then
40539         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&5
40540 $as_echo "$as_me: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&2;}
40541       fi
40542       # Try to locate tool using the code snippet
40543       for ac_prog in lipo
40544 do
40545   # Extract the first word of "$ac_prog", so it can be a program name with args.
40546 set dummy $ac_prog; ac_word=$2
40547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40548 $as_echo_n "checking for $ac_word... " >&6; }
40549 if ${ac_cv_path_LIPO+:} false; then :
40550   $as_echo_n "(cached) " >&6
40551 else
40552   case $LIPO in
40553   [\\/]* | ?:[\\/]*)
40554   ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
40555   ;;
40556   *)
40557   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40558 for as_dir in $PATH
40559 do
40560   IFS=$as_save_IFS
40561   test -z "$as_dir" && as_dir=.
40562     for ac_exec_ext in '' $ac_executable_extensions; do
40563   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40564     ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
40565     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40566     break 2
40567   fi
40568 done
40569   done
40570 IFS=$as_save_IFS
40571 
40572   ;;
40573 esac
40574 fi
40575 LIPO=$ac_cv_path_LIPO
40576 if test -n "$LIPO"; then
40577   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
40578 $as_echo "$LIPO" >&6; }
40579 else
40580   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40581 $as_echo "no" >&6; }
40582 fi
40583 
40584 
40585   test -n "$LIPO" && break
40586 done
40587 
40588     else
40589       # If it succeeded, then it was overridden by the user. We will use it
40590       # for the tool.
40591 
40592       # First remove it from the list of overridden variables, so we can test
40593       # for unknown variables in the end.
40594       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
40595 
40596       # Check if the provided tool contains a complete path.
40597       tool_specified="$LIPO"
40598       tool_basename="${tool_specified##*/}"
40599       if test "x$tool_basename" = "x$tool_specified"; then
40600         # A command without a complete path is provided, search $PATH.
40601         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LIPO=$tool_basename" >&5
40602 $as_echo "$as_me: Will search for user supplied tool LIPO=$tool_basename" >&6;}
40603         # Extract the first word of "$tool_basename", so it can be a program name with args.
40604 set dummy $tool_basename; ac_word=$2
40605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40606 $as_echo_n "checking for $ac_word... " >&6; }
40607 if ${ac_cv_path_LIPO+:} false; then :
40608   $as_echo_n "(cached) " >&6
40609 else
40610   case $LIPO in
40611   [\\/]* | ?:[\\/]*)
40612   ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
40613   ;;
40614   *)
40615   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40616 for as_dir in $PATH
40617 do
40618   IFS=$as_save_IFS
40619   test -z "$as_dir" && as_dir=.
40620     for ac_exec_ext in '' $ac_executable_extensions; do
40621   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40622     ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
40623     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40624     break 2
40625   fi
40626 done
40627   done
40628 IFS=$as_save_IFS
40629 
40630   ;;
40631 esac
40632 fi
40633 LIPO=$ac_cv_path_LIPO
40634 if test -n "$LIPO"; then
40635   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
40636 $as_echo "$LIPO" >&6; }
40637 else
40638   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40639 $as_echo "no" >&6; }
40640 fi
40641 
40642 
40643         if test "x$LIPO" = x; then
40644           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
40645         fi
40646       else
40647         # Otherwise we believe it is a complete path. Use it as it is.
40648         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LIPO=$tool_specified" >&5
40649 $as_echo "$as_me: Will use user supplied tool LIPO=$tool_specified" >&6;}
40650         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5
40651 $as_echo_n "checking for LIPO... " >&6; }
40652         if test ! -x "$tool_specified"; then
40653           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
40654 $as_echo "not found" >&6; }
40655           as_fn_error $? "User supplied tool LIPO=$tool_specified does not exist or is not executable" "$LINENO" 5
40656         fi
40657         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
40658 $as_echo "$tool_specified" >&6; }
40659       fi
40660     fi
40661   fi
40662 
40663 
40664 
40665   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40666 
40667   # First separate the path from the arguments. This will split at the first
40668   # space.
40669   complete="$LIPO"
40670   path="${complete%% *}"
40671   tmp="$complete EOL"
40672   arguments="${tmp#* }"
40673 
40674   # Input might be given as Windows format, start by converting to
40675   # unix format.
40676   new_path=`$CYGPATH -u "$path"`
40677 
40678   # Now try to locate executable using which
40679   new_path=`$WHICH "$new_path" 2> /dev/null`
40680   # bat and cmd files are not always considered executable in cygwin causing which
40681   # to not find them
40682   if test "x$new_path" = x \
40683       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
40684       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
40685     new_path=`$CYGPATH -u "$path"`
40686   fi
40687   if test "x$new_path" = x; then
40688     # Oops. Which didn't find the executable.
40689     # The splitting of arguments from the executable at a space might have been incorrect,
40690     # since paths with space are more likely in Windows. Give it another try with the whole
40691     # argument.
40692     path="$complete"
40693     arguments="EOL"
40694     new_path=`$CYGPATH -u "$path"`
40695     new_path=`$WHICH "$new_path" 2> /dev/null`
40696     # bat and cmd files are not always considered executable in cygwin causing which
40697     # to not find them
40698     if test "x$new_path" = x \
40699         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
40700         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
40701       new_path=`$CYGPATH -u "$path"`
40702     fi
40703     if test "x$new_path" = x; then
40704       # It's still not found. Now this is an unrecoverable error.
40705       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
40706 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
40707       has_space=`$ECHO "$complete" | $GREP " "`
40708       if test "x$has_space" != x; then
40709         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
40710 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
40711       fi
40712       as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
40713     fi
40714   fi
40715 
40716   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
40717   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
40718   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
40719   # "foo.exe" is OK but "foo" is an error.
40720   #
40721   # This test is therefore slightly more accurate than "test -f" to check for file presence.
40722   # It is also a way to make sure we got the proper file name for the real test later on.
40723   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
40724   if test "x$test_shortpath" = x; then
40725     # Short path failed, file does not exist as specified.
40726     # Try adding .exe or .cmd
40727     if test -f "${new_path}.exe"; then
40728       input_to_shortpath="${new_path}.exe"
40729     elif test -f "${new_path}.cmd"; then
40730       input_to_shortpath="${new_path}.cmd"
40731     else
40732       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$new_path\", is invalid." >&5
40733 $as_echo "$as_me: The path of LIPO, which resolves as \"$new_path\", is invalid." >&6;}
40734       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
40735 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
40736       as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
40737     fi
40738   else
40739     input_to_shortpath="$new_path"
40740   fi
40741 
40742   # Call helper function which possibly converts this using DOS-style short mode.
40743   # If so, the updated path is stored in $new_path.
40744   new_path="$input_to_shortpath"
40745 
40746   input_path="$input_to_shortpath"
40747   # Check if we need to convert this using DOS-style short mode. If the path
40748   # contains just simple characters, use it. Otherwise (spaces, weird characters),
40749   # take no chances and rewrite it.
40750   # Note: m4 eats our [], so we need to use [ and ] instead.
40751   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
40752   if test "x$has_forbidden_chars" != x; then
40753     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40754     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
40755     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
40756     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
40757       # Going to short mode and back again did indeed matter. Since short mode is
40758       # case insensitive, let's make it lowercase to improve readability.
40759       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40760       # Now convert it back to Unix-stile (cygpath)
40761       input_path=`$CYGPATH -u "$shortmode_path"`
40762       new_path="$input_path"
40763     fi
40764   fi
40765 
40766   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
40767   if test "x$test_cygdrive_prefix" = x; then
40768     # As a simple fix, exclude /usr/bin since it's not a real path.
40769     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
40770       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
40771       # a path prefixed by /cygdrive for fixpath to work.
40772       new_path="$CYGWIN_ROOT_PATH$input_path"
40773     fi
40774   fi
40775 
40776   # remove trailing .exe if any
40777   new_path="${new_path/%.exe/}"
40778 
40779   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40780 
40781   # First separate the path from the arguments. This will split at the first
40782   # space.
40783   complete="$LIPO"
40784   path="${complete%% *}"
40785   tmp="$complete EOL"
40786   arguments="${tmp#* }"
40787 
40788   # Input might be given as Windows format, start by converting to
40789   # unix format.
40790   new_path="$path"
40791 
40792   windows_path="$new_path"
40793   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40794     unix_path=`$CYGPATH -u "$windows_path"`
40795     new_path="$unix_path"
40796   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40797     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40798     new_path="$unix_path"
40799   fi
40800 
40801 
40802   # Now try to locate executable using which
40803   new_path=`$WHICH "$new_path" 2> /dev/null`
40804 
40805   if test "x$new_path" = x; then
40806     # Oops. Which didn't find the executable.
40807     # The splitting of arguments from the executable at a space might have been incorrect,
40808     # since paths with space are more likely in Windows. Give it another try with the whole
40809     # argument.
40810     path="$complete"
40811     arguments="EOL"
40812     new_path="$path"
40813 
40814   windows_path="$new_path"
40815   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40816     unix_path=`$CYGPATH -u "$windows_path"`
40817     new_path="$unix_path"
40818   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40819     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40820     new_path="$unix_path"
40821   fi
40822 
40823 
40824     new_path=`$WHICH "$new_path" 2> /dev/null`
40825 
40826     if test "x$new_path" = x; then
40827       # It's still not found. Now this is an unrecoverable error.
40828       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
40829 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
40830       has_space=`$ECHO "$complete" | $GREP " "`
40831       if test "x$has_space" != x; then
40832         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
40833 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
40834       fi
40835       as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
40836     fi
40837   fi
40838 
40839   # Now new_path has a complete unix path to the binary
40840   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
40841     # Keep paths in /bin as-is, but remove trailing .exe if any
40842     new_path="${new_path/%.exe/}"
40843     # Do not save /bin paths to all_fixpath_prefixes!
40844   else
40845     # Not in mixed or Windows style, start by that.
40846     new_path=`cmd //c echo $new_path`
40847 
40848   input_path="$new_path"
40849   # Check if we need to convert this using DOS-style short mode. If the path
40850   # contains just simple characters, use it. Otherwise (spaces, weird characters),
40851   # take no chances and rewrite it.
40852   # Note: m4 eats our [], so we need to use [ and ] instead.
40853   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
40854   if test "x$has_forbidden_chars" != x; then
40855     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40856     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40857   fi
40858 
40859     # Output is in $new_path
40860 
40861   windows_path="$new_path"
40862   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40863     unix_path=`$CYGPATH -u "$windows_path"`
40864     new_path="$unix_path"
40865   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40866     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40867     new_path="$unix_path"
40868   fi
40869 
40870     # remove trailing .exe if any
40871     new_path="${new_path/%.exe/}"
40872 
40873     # Save the first 10 bytes of this path to the storage, so fixpath can work.
40874     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
40875   fi
40876 
40877   else
40878     # We're on a posix platform. Hooray! :)
40879     # First separate the path from the arguments. This will split at the first
40880     # space.
40881     complete="$LIPO"
40882     path="${complete%% *}"
40883     tmp="$complete EOL"
40884     arguments="${tmp#* }"
40885 
40886     # Cannot rely on the command "which" here since it doesn't always work.
40887     is_absolute_path=`$ECHO "$path" | $GREP ^/`
40888     if test -z "$is_absolute_path"; then
40889       # Path to executable is not absolute. Find it.
40890       IFS_save="$IFS"
40891       IFS=:
40892       for p in $PATH; do
40893         if test -f "$p/$path" && test -x "$p/$path"; then
40894           new_path="$p/$path"
40895           break
40896         fi
40897       done
40898       IFS="$IFS_save"
40899     else
40900       { $as_echo "$as_me:${as_lineno-$LINENO}: Resolving LIPO (as $path) failed, using $path directly." >&5
40901 $as_echo "$as_me: Resolving LIPO (as $path) failed, using $path directly." >&6;}
40902       new_path="$path"
40903     fi
40904 
40905     if test "x$new_path" = x; then
40906       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
40907 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
40908       has_space=`$ECHO "$complete" | $GREP " "`
40909       if test "x$has_space" != x; then
40910         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
40911 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
40912       fi
40913       as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
40914     fi
40915   fi
40916 
40917   # Now join together the path and the arguments once again
40918   if test "x$arguments" != xEOL; then
40919     new_complete="$new_path ${arguments% *}"
40920   else
40921     new_complete="$new_path"
40922   fi
40923 
40924   if test "x$complete" != "x$new_complete"; then
40925     LIPO="$new_complete"
40926     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LIPO to \"$new_complete\"" >&5
40927 $as_echo "$as_me: Rewriting LIPO to \"$new_complete\"" >&6;}
40928   fi
40929 
40930   fi
40931 
40932 
40933 
40934   # Restore old path without tools dir
40935   PATH="$OLD_PATH"
40936 
40937 
40938 # FIXME: Currently we must test this after paths but before flags. Fix!
40939 
40940 # And we can test some aspects on the target using configure macros.
40941 
40942 
40943 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
40944 $as_echo_n "checking for ANSI C header files... " >&6; }
40945 if ${ac_cv_header_stdc+:} false; then :
40946   $as_echo_n "(cached) " >&6
40947 else
40948   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40949 /* end confdefs.h.  */
40950 #include <stdlib.h>
40951 #include <stdarg.h>
40952 #include <string.h>
40953 #include <float.h>
40954 
40955 int
40956 main ()
40957 {
40958 
40959   ;
40960   return 0;
40961 }
40962 _ACEOF
40963 if ac_fn_cxx_try_compile "$LINENO"; then :
40964   ac_cv_header_stdc=yes
40965 else
40966   ac_cv_header_stdc=no
40967 fi
40968 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40969 
40970 if test $ac_cv_header_stdc = yes; then
40971   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
40972   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40973 /* end confdefs.h.  */
40974 #include <string.h>
40975 
40976 _ACEOF
40977 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40978   $EGREP "memchr" >/dev/null 2>&1; then :
40979 
40980 else
40981   ac_cv_header_stdc=no
40982 fi
40983 rm -f conftest*
40984 
40985 fi
40986 
40987 if test $ac_cv_header_stdc = yes; then
40988   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
40989   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40990 /* end confdefs.h.  */
40991 #include <stdlib.h>
40992 
40993 _ACEOF
40994 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40995   $EGREP "free" >/dev/null 2>&1; then :
40996 
40997 else
40998   ac_cv_header_stdc=no
40999 fi
41000 rm -f conftest*
41001 
41002 fi
41003 
41004 if test $ac_cv_header_stdc = yes; then
41005   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
41006   if test "$cross_compiling" = yes; then :
41007   :
41008 else
41009   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41010 /* end confdefs.h.  */
41011 #include <ctype.h>
41012 #include <stdlib.h>
41013 #if ((' ' & 0x0FF) == 0x020)
41014 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
41015 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
41016 #else
41017 # define ISLOWER(c) \
41018                    (('a' <= (c) && (c) <= 'i') \
41019                      || ('j' <= (c) && (c) <= 'r') \
41020                      || ('s' <= (c) && (c) <= 'z'))
41021 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
41022 #endif
41023 
41024 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
41025 int
41026 main ()
41027 {
41028   int i;
41029   for (i = 0; i < 256; i++)
41030     if (XOR (islower (i), ISLOWER (i))
41031         || toupper (i) != TOUPPER (i))
41032       return 2;
41033   return 0;
41034 }
41035 _ACEOF
41036 if ac_fn_cxx_try_run "$LINENO"; then :
41037 
41038 else
41039   ac_cv_header_stdc=no
41040 fi
41041 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
41042   conftest.$ac_objext conftest.beam conftest.$ac_ext
41043 fi
41044 
41045 fi
41046 fi
41047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
41048 $as_echo "$ac_cv_header_stdc" >&6; }
41049 if test $ac_cv_header_stdc = yes; then
41050 
41051 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
41052 
41053 fi
41054 
41055 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
41056 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
41057                   inttypes.h stdint.h unistd.h
41058 do :
41059   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
41060 ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
41061 "
41062 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
41063   cat >>confdefs.h <<_ACEOF
41064 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
41065 _ACEOF
41066 
41067 fi
41068 
41069 done
41070 
41071 
41072 
41073   ###############################################################################
41074   #
41075   # Now we check if libjvm.so will use 32 or 64 bit pointers for the C/C++ code.
41076   # (The JVM can use 32 or 64 bit Java pointers but that decision
41077   # is made at runtime.)
41078   #
41079 
41080   if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xaix; then
41081     # Always specify -m flag on Solaris
41082     # And -q on AIX because otherwise the compiler produces 32-bit objects by default
41083 
41084   # When we add flags to the "official" CFLAGS etc, we need to
41085   # keep track of these additions in ADDED_CFLAGS etc. These
41086   # will later be checked to make sure only controlled additions
41087   # have been made to CFLAGS etc.
41088   ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41089   ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41090   ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41091 
41092   CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
41093   CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
41094   LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
41095 
41096   CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
41097   CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
41098   LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
41099 
41100   elif test "x$COMPILE_TYPE" = xreduced; then
41101     if test "x$OPENJDK_TARGET_OS" != xwindows; then
41102       # Specify -m if running reduced on other Posix platforms
41103 
41104   # When we add flags to the "official" CFLAGS etc, we need to
41105   # keep track of these additions in ADDED_CFLAGS etc. These
41106   # will later be checked to make sure only controlled additions
41107   # have been made to CFLAGS etc.
41108   ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41109   ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41110   ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41111 
41112   CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
41113   CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
41114   LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
41115 
41116   CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
41117   CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
41118   LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
41119 
41120     fi
41121   fi
41122 
41123   # Make compilation sanity check
41124   for ac_header in stdio.h
41125 do :
41126   ac_fn_cxx_check_header_mongrel "$LINENO" "stdio.h" "ac_cv_header_stdio_h" "$ac_includes_default"
41127 if test "x$ac_cv_header_stdio_h" = xyes; then :
41128   cat >>confdefs.h <<_ACEOF
41129 #define HAVE_STDIO_H 1
41130 _ACEOF
41131 
41132 else
41133 
41134     { $as_echo "$as_me:${as_lineno-$LINENO}: Failed to compile stdio.h. This likely implies missing compile dependencies." >&5
41135 $as_echo "$as_me: Failed to compile stdio.h. This likely implies missing compile dependencies." >&6;}
41136     if test "x$COMPILE_TYPE" = xreduced; then
41137       { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed." >&5
41138 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed." >&6;}
41139     elif test "x$COMPILE_TYPE" = xcross; then
41140       { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5
41141 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;}
41142     fi
41143     as_fn_error $? "Cannot continue." "$LINENO" 5
41144 
41145 fi
41146 
41147 done
41148 
41149 
41150   # The cast to long int works around a bug in the HP C Compiler
41151 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
41152 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
41153 # This bug is HP SR number 8606223364.
41154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5
41155 $as_echo_n "checking size of int *... " >&6; }
41156 if ${ac_cv_sizeof_int_p+:} false; then :
41157   $as_echo_n "(cached) " >&6
41158 else
41159   if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p"        "$ac_includes_default"; then :
41160 
41161 else
41162   if test "$ac_cv_type_int_p" = yes; then
41163      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
41164 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
41165 as_fn_error 77 "cannot compute sizeof (int *)
41166 See \`config.log' for more details" "$LINENO" 5; }
41167    else
41168      ac_cv_sizeof_int_p=0
41169    fi
41170 fi
41171 
41172 fi
41173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5
41174 $as_echo "$ac_cv_sizeof_int_p" >&6; }
41175 
41176 
41177 
41178 cat >>confdefs.h <<_ACEOF
41179 #define SIZEOF_INT_P $ac_cv_sizeof_int_p
41180 _ACEOF
41181 
41182 
41183 
41184   # AC_CHECK_SIZEOF defines 'ac_cv_sizeof_int_p' to hold the number of bytes used by an 'int*'
41185   if test "x$ac_cv_sizeof_int_p" = x; then
41186     # The test failed, lets stick to the assumed value.
41187     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&5
41188 $as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;}
41189   else
41190     TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p`
41191 
41192     if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then
41193       # This situation may happen on 64-bit platforms where the compiler by default only generates 32-bit objects
41194       # Let's try to implicitely set the compilers target architecture and retry the test
41195       { $as_echo "$as_me:${as_lineno-$LINENO}: The tested number of bits in the target ($TESTED_TARGET_CPU_BITS) differs from the number of bits expected to be found in the target ($OPENJDK_TARGET_CPU_BITS)." >&5
41196 $as_echo "$as_me: The tested number of bits in the target ($TESTED_TARGET_CPU_BITS) differs from the number of bits expected to be found in the target ($OPENJDK_TARGET_CPU_BITS)." >&6;}
41197       { $as_echo "$as_me:${as_lineno-$LINENO}: I'll retry after setting the platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&5
41198 $as_echo "$as_me: I'll retry after setting the platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&6;}
41199 
41200   # When we add flags to the "official" CFLAGS etc, we need to
41201   # keep track of these additions in ADDED_CFLAGS etc. These
41202   # will later be checked to make sure only controlled additions
41203   # have been made to CFLAGS etc.
41204   ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41205   ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41206   ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41207 
41208   CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
41209   CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
41210   LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
41211 
41212   CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
41213   CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
41214   LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
41215 
41216 
41217       # We have to unset 'ac_cv_sizeof_int_p' first, otherwise AC_CHECK_SIZEOF will use the previously cached value!
41218       unset ac_cv_sizeof_int_p
41219       # And we have to undef the definition of SIZEOF_INT_P in confdefs.h by the previous invocation of AC_CHECK_SIZEOF
41220       cat >>confdefs.h <<_ACEOF
41221 #undef SIZEOF_INT_P
41222 _ACEOF
41223 
41224       # The cast to long int works around a bug in the HP C Compiler
41225 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
41226 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
41227 # This bug is HP SR number 8606223364.
41228 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5
41229 $as_echo_n "checking size of int *... " >&6; }
41230 if ${ac_cv_sizeof_int_p+:} false; then :
41231   $as_echo_n "(cached) " >&6
41232 else
41233   if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p"        "$ac_includes_default"; then :
41234 
41235 else
41236   if test "$ac_cv_type_int_p" = yes; then
41237      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
41238 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
41239 as_fn_error 77 "cannot compute sizeof (int *)
41240 See \`config.log' for more details" "$LINENO" 5; }
41241    else
41242      ac_cv_sizeof_int_p=0
41243    fi
41244 fi
41245 
41246 fi
41247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5
41248 $as_echo "$ac_cv_sizeof_int_p" >&6; }
41249 
41250 
41251 
41252 cat >>confdefs.h <<_ACEOF
41253 #define SIZEOF_INT_P $ac_cv_sizeof_int_p
41254 _ACEOF
41255 
41256 
41257 
41258       TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p`
41259 
41260       if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then
41261         as_fn_error $? "The tested number of bits in the target ($TESTED_TARGET_CPU_BITS) differs from the number of bits expected to be found in the target ($OPENJDK_TARGET_CPU_BITS)" "$LINENO" 5
41262       fi
41263     fi
41264   fi
41265 
41266   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target address size" >&5
41267 $as_echo_n "checking for target address size... " >&6; }
41268   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_CPU_BITS bits" >&5
41269 $as_echo "$OPENJDK_TARGET_CPU_BITS bits" >&6; }
41270 
41271 
41272   ###############################################################################
41273   #
41274   # Is the target little of big endian?
41275   #
41276    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
41277 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
41278 if ${ac_cv_c_bigendian+:} false; then :
41279   $as_echo_n "(cached) " >&6
41280 else
41281   ac_cv_c_bigendian=unknown
41282     # See if we're dealing with a universal compiler.
41283     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41284 /* end confdefs.h.  */
41285 #ifndef __APPLE_CC__
41286                not a universal capable compiler
41287              #endif
41288              typedef int dummy;
41289 
41290 _ACEOF
41291 if ac_fn_cxx_try_compile "$LINENO"; then :
41292 
41293         # Check for potential -arch flags.  It is not universal unless
41294         # there are at least two -arch flags with different values.
41295         ac_arch=
41296         ac_prev=
41297         for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
41298          if test -n "$ac_prev"; then
41299            case $ac_word in
41300              i?86 | x86_64 | ppc | ppc64)
41301                if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
41302                  ac_arch=$ac_word
41303                else
41304                  ac_cv_c_bigendian=universal
41305                  break
41306                fi
41307                ;;
41308            esac
41309            ac_prev=
41310          elif test "x$ac_word" = "x-arch"; then
41311            ac_prev=arch
41312          fi
41313        done
41314 fi
41315 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41316     if test $ac_cv_c_bigendian = unknown; then
41317       # See if sys/param.h defines the BYTE_ORDER macro.
41318       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41319 /* end confdefs.h.  */
41320 #include <sys/types.h>
41321              #include <sys/param.h>
41322 
41323 int
41324 main ()
41325 {
41326 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
41327                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
41328                      && LITTLE_ENDIAN)
41329               bogus endian macros
41330              #endif
41331 
41332   ;
41333   return 0;
41334 }
41335 _ACEOF
41336 if ac_fn_cxx_try_compile "$LINENO"; then :
41337   # It does; now see whether it defined to BIG_ENDIAN or not.
41338          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41339 /* end confdefs.h.  */
41340 #include <sys/types.h>
41341                 #include <sys/param.h>
41342 
41343 int
41344 main ()
41345 {
41346 #if BYTE_ORDER != BIG_ENDIAN
41347                  not big endian
41348                 #endif
41349 
41350   ;
41351   return 0;
41352 }
41353 _ACEOF
41354 if ac_fn_cxx_try_compile "$LINENO"; then :
41355   ac_cv_c_bigendian=yes
41356 else
41357   ac_cv_c_bigendian=no
41358 fi
41359 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41360 fi
41361 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41362     fi
41363     if test $ac_cv_c_bigendian = unknown; then
41364       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
41365       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41366 /* end confdefs.h.  */
41367 #include <limits.h>
41368 
41369 int
41370 main ()
41371 {
41372 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
41373               bogus endian macros
41374              #endif
41375 
41376   ;
41377   return 0;
41378 }
41379 _ACEOF
41380 if ac_fn_cxx_try_compile "$LINENO"; then :
41381   # It does; now see whether it defined to _BIG_ENDIAN or not.
41382          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41383 /* end confdefs.h.  */
41384 #include <limits.h>
41385 
41386 int
41387 main ()
41388 {
41389 #ifndef _BIG_ENDIAN
41390                  not big endian
41391                 #endif
41392 
41393   ;
41394   return 0;
41395 }
41396 _ACEOF
41397 if ac_fn_cxx_try_compile "$LINENO"; then :
41398   ac_cv_c_bigendian=yes
41399 else
41400   ac_cv_c_bigendian=no
41401 fi
41402 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41403 fi
41404 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41405     fi
41406     if test $ac_cv_c_bigendian = unknown; then
41407       # Compile a test program.
41408       if test "$cross_compiling" = yes; then :
41409   # Try to guess by grepping values from an object file.
41410          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41411 /* end confdefs.h.  */
41412 short int ascii_mm[] =
41413                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
41414                 short int ascii_ii[] =
41415                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
41416                 int use_ascii (int i) {
41417                   return ascii_mm[i] + ascii_ii[i];
41418                 }
41419                 short int ebcdic_ii[] =
41420                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
41421                 short int ebcdic_mm[] =
41422                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
41423                 int use_ebcdic (int i) {
41424                   return ebcdic_mm[i] + ebcdic_ii[i];
41425                 }
41426                 extern int foo;
41427 
41428 int
41429 main ()
41430 {
41431 return use_ascii (foo) == use_ebcdic (foo);
41432   ;
41433   return 0;
41434 }
41435 _ACEOF
41436 if ac_fn_cxx_try_compile "$LINENO"; then :
41437   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
41438               ac_cv_c_bigendian=yes
41439             fi
41440             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
41441               if test "$ac_cv_c_bigendian" = unknown; then
41442                 ac_cv_c_bigendian=no
41443               else
41444                 # finding both strings is unlikely to happen, but who knows?
41445                 ac_cv_c_bigendian=unknown
41446               fi
41447             fi
41448 fi
41449 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41450 else
41451   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41452 /* end confdefs.h.  */
41453 $ac_includes_default
41454 int
41455 main ()
41456 {
41457 
41458              /* Are we little or big endian?  From Harbison&Steele.  */
41459              union
41460              {
41461                long int l;
41462                char c[sizeof (long int)];
41463              } u;
41464              u.l = 1;
41465              return u.c[sizeof (long int) - 1] == 1;
41466 
41467   ;
41468   return 0;
41469 }
41470 _ACEOF
41471 if ac_fn_cxx_try_run "$LINENO"; then :
41472   ac_cv_c_bigendian=no
41473 else
41474   ac_cv_c_bigendian=yes
41475 fi
41476 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
41477   conftest.$ac_objext conftest.beam conftest.$ac_ext
41478 fi
41479 
41480     fi
41481 fi
41482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
41483 $as_echo "$ac_cv_c_bigendian" >&6; }
41484  case $ac_cv_c_bigendian in #(
41485    yes)
41486      ENDIAN="big";; #(
41487    no)
41488      ENDIAN="little" ;; #(
41489    universal)
41490      ENDIAN="universal_endianness"
41491      ;; #(
41492    *)
41493      ENDIAN="unknown" ;;
41494  esac
41495 
41496 
41497   if test "x$ENDIAN" = xuniversal_endianness; then
41498     as_fn_error $? "Building with both big and little endianness is not supported" "$LINENO" 5
41499   fi
41500   if test "x$ENDIAN" != "x$OPENJDK_TARGET_CPU_ENDIAN"; then
41501     as_fn_error $? "The tested endian in the target ($ENDIAN) differs from the endian expected to be found in the target ($OPENJDK_TARGET_CPU_ENDIAN)" "$LINENO" 5
41502   fi
41503 
41504 
41505 # Configure flags for the tools
41506 
41507 
41508   ###############################################################################
41509   #
41510   # How to compile shared libraries.
41511   #
41512 
41513   if test "x$GCC" = xyes; then
41514     COMPILER_NAME=gcc
41515     PICFLAG="-fPIC"
41516     LIBRARY_PREFIX=lib
41517     SHARED_LIBRARY='lib$1.so'
41518     STATIC_LIBRARY='lib$1.a'
41519     SHARED_LIBRARY_FLAGS="-shared"
41520     SHARED_LIBRARY_SUFFIX='.so'
41521     STATIC_LIBRARY_SUFFIX='.a'
41522     OBJ_SUFFIX='.o'
41523     EXE_SUFFIX=''
41524     SET_SHARED_LIBRARY_NAME='-Xlinker -soname=$1'
41525     SET_SHARED_LIBRARY_MAPFILE='-Xlinker -version-script=$1'
41526     C_FLAG_REORDER=''
41527     CXX_FLAG_REORDER=''
41528     SET_SHARED_LIBRARY_ORIGIN='-Xlinker -z -Xlinker origin -Xlinker -rpath -Xlinker \$$$$ORIGIN$1'
41529     SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker \$$$$ORIGIN$1'
41530     LD="$CC"
41531     LDEXE="$CC"
41532     LDCXX="$CXX"
41533     LDEXECXX="$CXX"
41534     POST_STRIP_CMD="$STRIP -g"
41535 
41536     # Linking is different on MacOSX
41537     if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41538       # Might change in the future to clang.
41539       COMPILER_NAME=gcc
41540       SHARED_LIBRARY='lib$1.dylib'
41541       SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG"
41542       SHARED_LIBRARY_SUFFIX='.dylib'
41543       EXE_SUFFIX=''
41544       SET_SHARED_LIBRARY_NAME='-Xlinker -install_name -Xlinker @rpath/$1'
41545       SET_SHARED_LIBRARY_MAPFILE=''
41546       SET_SHARED_LIBRARY_ORIGIN='-Xlinker -rpath -Xlinker @loader_path/.'
41547       SET_EXECUTABLE_ORIGIN="$SET_SHARED_LIBRARY_ORIGIN"
41548       POST_STRIP_CMD="$STRIP -S"
41549     fi
41550   else
41551     if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41552       # If it is not gcc, then assume it is the Oracle Solaris Studio Compiler
41553       COMPILER_NAME=ossc
41554       PICFLAG="-KPIC"
41555       LIBRARY_PREFIX=lib
41556       SHARED_LIBRARY='lib$1.so'
41557       STATIC_LIBRARY='lib$1.a'
41558       SHARED_LIBRARY_FLAGS="-G"
41559       SHARED_LIBRARY_SUFFIX='.so'
41560       STATIC_LIBRARY_SUFFIX='.a'
41561       OBJ_SUFFIX='.o'
41562       EXE_SUFFIX=''
41563       SET_SHARED_LIBRARY_NAME=''
41564       SET_SHARED_LIBRARY_MAPFILE='-M$1'
41565       C_FLAG_REORDER='-xF'
41566       CXX_FLAG_REORDER='-xF'
41567       SET_SHARED_LIBRARY_ORIGIN='-R\$$$$ORIGIN$1'
41568       SET_EXECUTABLE_ORIGIN="$SET_SHARED_LIBRARY_ORIGIN"
41569       CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__"
41570       CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__"
41571       CFLAGS_JDKLIB_EXTRA='-xstrconst'
41572       POST_STRIP_CMD="$STRIP -x"
41573       POST_MCS_CMD="$MCS -d -a \"JDK $FULL_VERSION\""
41574     fi
41575     if test "x$OPENJDK_TARGET_OS" = xaix; then
41576         COMPILER_NAME=xlc
41577         PICFLAG="-qpic=large"
41578         LIBRARY_PREFIX=lib
41579         SHARED_LIBRARY='lib$1.so'
41580         STATIC_LIBRARY='lib$1.a'
41581         SHARED_LIBRARY_FLAGS="-qmkshrobj"
41582         SHARED_LIBRARY_SUFFIX='.so'
41583         STATIC_LIBRARY_SUFFIX='.a'
41584         OBJ_SUFFIX='.o'
41585         EXE_SUFFIX=''
41586         SET_SHARED_LIBRARY_NAME=''
41587         SET_SHARED_LIBRARY_MAPFILE=''
41588         C_FLAG_REORDER=''
41589         CXX_FLAG_REORDER=''
41590         SET_SHARED_LIBRARY_ORIGIN=''
41591         SET_EXECUTABLE_ORIGIN=""
41592         CFLAGS_JDK=""
41593         CXXFLAGS_JDK=""
41594         CFLAGS_JDKLIB_EXTRA=''
41595         POST_STRIP_CMD="$STRIP -X32_64"
41596         POST_MCS_CMD=""
41597     fi
41598     if test "x$OPENJDK_TARGET_OS" = xwindows; then
41599       # If it is not gcc, then assume it is the MS Visual Studio compiler
41600       COMPILER_NAME=cl
41601       PICFLAG=""
41602       LIBRARY_PREFIX=
41603       SHARED_LIBRARY='$1.dll'
41604       STATIC_LIBRARY='$1.lib'
41605       SHARED_LIBRARY_FLAGS="-LD"
41606       SHARED_LIBRARY_SUFFIX='.dll'
41607       STATIC_LIBRARY_SUFFIX='.lib'
41608       OBJ_SUFFIX='.obj'
41609       EXE_SUFFIX='.exe'
41610       SET_SHARED_LIBRARY_NAME=''
41611       SET_SHARED_LIBRARY_MAPFILE=''
41612       SET_SHARED_LIBRARY_ORIGIN=''
41613       SET_EXECUTABLE_ORIGIN=''
41614     fi
41615   fi
41616 
41617 
41618 
41619 
41620 
41621 
41622 
41623 
41624 
41625 
41626 
41627 
41628 
41629 
41630 
41631 
41632 
41633 
41634 
41635   # The (cross) compiler is now configured, we can now test capabilities
41636   # of the target platform.
41637 
41638 
41639 
41640   ###############################################################################
41641   #
41642   # Setup the opt flags for different compilers
41643   # and different operating systems.
41644   #
41645 
41646   #
41647   # NOTE: check for -mstackrealign needs to be below potential addition of -m32
41648   #
41649   if test "x$OPENJDK_TARGET_CPU_BITS" = x32 && test "x$OPENJDK_TARGET_OS" = xmacosx; then
41650     # On 32-bit MacOSX the OS requires C-entry points to be 16 byte aligned.
41651     # While waiting for a better solution, the current workaround is to use -mstackrealign.
41652     CFLAGS="$CFLAGS -mstackrealign"
41653     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if 32-bit compiler supports -mstackrealign" >&5
41654 $as_echo_n "checking if 32-bit compiler supports -mstackrealign... " >&6; }
41655     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41656 /* end confdefs.h.  */
41657 int main() { return 0; }
41658 _ACEOF
41659 if ac_fn_cxx_try_link "$LINENO"; then :
41660 
41661           { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41662 $as_echo "yes" >&6; }
41663 
41664 else
41665 
41666           { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41667 $as_echo "no" >&6; }
41668           as_fn_error $? "The selected compiler $CXX does not support -mstackrealign! Try to put another compiler in the path." "$LINENO" 5
41669 
41670 
41671 fi
41672 rm -f core conftest.err conftest.$ac_objext \
41673     conftest$ac_exeext conftest.$ac_ext
41674   fi
41675 
41676   C_FLAG_DEPS="-MMD -MF"
41677   CXX_FLAG_DEPS="-MMD -MF"
41678 
41679   case $COMPILER_TYPE in
41680     CC )
41681       case $COMPILER_NAME in
41682         gcc )
41683           case $OPENJDK_TARGET_OS in
41684             macosx )
41685               # On MacOSX we optimize for size, something
41686               # we should do for all platforms?
41687               C_O_FLAG_HI="-Os"
41688               C_O_FLAG_NORM="-Os"
41689               C_O_FLAG_NONE=""
41690               ;;
41691             *)
41692               C_O_FLAG_HI="-O3"
41693               C_O_FLAG_NORM="-O2"
41694               C_O_FLAG_NONE="-O0"
41695               ;;
41696           esac
41697           CXX_O_FLAG_HI="$C_O_FLAG_HI"
41698           CXX_O_FLAG_NORM="$C_O_FLAG_NORM"
41699           CXX_O_FLAG_NONE="$C_O_FLAG_NONE"
41700           CFLAGS_DEBUG_SYMBOLS="-g"
41701           CXXFLAGS_DEBUG_SYMBOLS="-g"
41702           if test "x$OPENJDK_TARGET_CPU_BITS" = "x64" && test "x$DEBUG_LEVEL" = "xfastdebug"; then
41703             CFLAGS_DEBUG_SYMBOLS="-g1"
41704             CXXFLAGS_DEBUG_SYMBOLS="-g1"
41705           fi
41706           ;;
41707         ossc )
41708           #
41709           # Forte has different names for this with their C++ compiler...
41710           #
41711           C_FLAG_DEPS="-xMMD -xMF"
41712           CXX_FLAG_DEPS="-xMMD -xMF"
41713 
41714           # Extra options used with HIGHEST
41715           #
41716           # WARNING: Use of OPTIMIZATION_LEVEL=HIGHEST in your Makefile needs to be
41717           #          done with care, there are some assumptions below that need to
41718           #          be understood about the use of pointers, and IEEE behavior.
41719           #
41720           # Use non-standard floating point mode (not IEEE 754)
41721           CC_HIGHEST="$CC_HIGHEST -fns"
41722           # Do some simplification of floating point arithmetic (not IEEE 754)
41723           CC_HIGHEST="$CC_HIGHEST -fsimple"
41724           # Use single precision floating point with 'float'
41725           CC_HIGHEST="$CC_HIGHEST -fsingle"
41726           # Assume memory references via basic pointer types do not alias
41727           #   (Source with excessing pointer casting and data access with mixed
41728           #    pointer types are not recommended)
41729           CC_HIGHEST="$CC_HIGHEST -xalias_level=basic"
41730           # Use intrinsic or inline versions for math/std functions
41731           #   (If you expect perfect errno behavior, do not use this)
41732           CC_HIGHEST="$CC_HIGHEST -xbuiltin=%all"
41733           # Loop data dependency optimizations (need -xO3 or higher)
41734           CC_HIGHEST="$CC_HIGHEST -xdepend"
41735           # Pointer parameters to functions do not overlap
41736           #   (Similar to -xalias_level=basic usage, but less obvious sometimes.
41737           #    If you pass in multiple pointers to the same data, do not use this)
41738           CC_HIGHEST="$CC_HIGHEST -xrestrict"
41739           # Inline some library routines
41740           #   (If you expect perfect errno behavior, do not use this)
41741           CC_HIGHEST="$CC_HIGHEST -xlibmil"
41742           # Use optimized math routines
41743           #   (If you expect perfect errno behavior, do not use this)
41744           #  Can cause undefined external on Solaris 8 X86 on __sincos, removing for now
41745           #CC_HIGHEST="$CC_HIGHEST -xlibmopt"
41746 
41747           if test "x$OPENJDK_TARGET_CPU" = xsparc; then
41748             CFLAGS_JDK="${CFLAGS_JDK} -xmemalign=4s"
41749             CXXFLAGS_JDK="${CXXFLAGS_JDK} -xmemalign=4s"
41750           fi
41751 
41752           case $OPENJDK_TARGET_CPU_ARCH in
41753             x86)
41754               C_O_FLAG_HIGHEST="-xO4 -Wu,-O4~yz $CC_HIGHEST -xregs=no%frameptr"
41755               C_O_FLAG_HI="-xO4 -Wu,-O4~yz -xregs=no%frameptr"
41756               C_O_FLAG_NORM="-xO2 -Wu,-O2~yz -xregs=no%frameptr"
41757               C_O_FLAG_NONE="-xregs=no%frameptr"
41758               CXX_O_FLAG_HIGHEST="-xO4 -Qoption ube -O4~yz $CC_HIGHEST -xregs=no%frameptr"
41759               CXX_O_FLAG_HI="-xO4 -Qoption ube -O4~yz -xregs=no%frameptr"
41760               CXX_O_FLAG_NORM="-xO2 -Qoption ube -O2~yz -xregs=no%frameptr"
41761               CXX_O_FLAG_NONE="-xregs=no%frameptr"
41762               if test "x$OPENJDK_TARGET_CPU" = xx86; then
41763                 C_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST -xchip=pentium"
41764                 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HIGHEST -xchip=pentium"
41765               fi
41766               ;;
41767             sparc)
41768               CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -xregs=no%appl"
41769               CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl"
41770               C_O_FLAG_HIGHEST="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra"
41771               C_O_FLAG_HI="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0"
41772               C_O_FLAG_NORM="-xO2 -Wc,-Qrm-s -Wc,-Qiselect-T0"
41773               C_O_FLAG_NONE=""
41774               CXX_O_FLAG_HIGHEST="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra"
41775               CXX_O_FLAG_HI="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0"
41776               CXX_O_FLAG_NORM="-xO2 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0"
41777               CXX_O_FLAG_NONE=""
41778               ;;
41779           esac
41780 
41781           CFLAGS_DEBUG_SYMBOLS="-g -xs"
41782           CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs"
41783           ;;
41784         xlc )
41785           C_FLAG_DEPS="-qmakedep=gcc -MF"
41786           CXX_FLAG_DEPS="-qmakedep=gcc -MF"
41787           C_O_FLAG_HIGHEST="-O3"
41788           C_O_FLAG_HI="-O3 -qstrict"
41789           C_O_FLAG_NORM="-O2"
41790           C_O_FLAG_NONE=""
41791           CXX_O_FLAG_HIGHEST="-O3"
41792           CXX_O_FLAG_HI="-O3 -qstrict"
41793           CXX_O_FLAG_NORM="-O2"
41794           CXX_O_FLAG_NONE=""
41795           CFLAGS_DEBUG_SYMBOLS="-g"
41796           CXXFLAGS_DEBUG_SYMBOLS="-g"
41797           LDFLAGS_JDK="${LDFLAGS_JDK} -q64 -brtl -bnolibpath -liconv -bexpall"
41798           CFLAGS_JDK="${CFLAGS_JDK} -qchars=signed -q64 -qfullpath -qsaveopt"
41799           CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -q64 -qfullpath -qsaveopt"
41800           ;;
41801       esac
41802       ;;
41803     CL )
41804       C_O_FLAG_HIGHEST="-O2"
41805       C_O_FLAG_HI="-O1"
41806       C_O_FLAG_NORM="-O1"
41807       C_O_FLAG_NONE="-Od"
41808       CXX_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST"
41809       CXX_O_FLAG_HI="$C_O_FLAG_HI"
41810       CXX_O_FLAG_NORM="$C_O_FLAG_NORM"
41811       CXX_O_FLAG_NONE="$C_O_FLAG_NONE"
41812       ;;
41813   esac
41814 
41815   if test -z "$C_O_FLAG_HIGHEST"; then
41816     C_O_FLAG_HIGHEST="$C_O_FLAG_HI"
41817   fi
41818 
41819   if test -z "$CXX_O_FLAG_HIGHEST"; then
41820     CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HI"
41821   fi
41822 
41823 
41824 
41825 
41826 
41827 
41828 
41829 
41830 
41831 
41832 
41833 
41834 
41835 
41836   if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then
41837     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5
41838 $as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;}
41839   fi
41840 
41841   if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then
41842     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5
41843 $as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;}
41844   fi
41845 
41846   if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then
41847     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5
41848 $as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;}
41849   fi
41850 
41851 
41852 # Check whether --with-extra-cflags was given.
41853 if test "${with_extra_cflags+set}" = set; then :
41854   withval=$with_extra_cflags;
41855 fi
41856 
41857 
41858 
41859 # Check whether --with-extra-cxxflags was given.
41860 if test "${with_extra_cxxflags+set}" = set; then :
41861   withval=$with_extra_cxxflags;
41862 fi
41863 
41864 
41865 
41866 # Check whether --with-extra-ldflags was given.
41867 if test "${with_extra_ldflags+set}" = set; then :
41868   withval=$with_extra_ldflags;
41869 fi
41870 
41871 
41872   CFLAGS_JDK="${CFLAGS_JDK} $with_extra_cflags"
41873   CXXFLAGS_JDK="${CXXFLAGS_JDK} $with_extra_cxxflags"
41874   LDFLAGS_JDK="${LDFLAGS_JDK} $with_extra_ldflags"
41875 
41876   # Hotspot needs these set in their legacy form
41877   LEGACY_EXTRA_CFLAGS=$with_extra_cflags
41878   LEGACY_EXTRA_CXXFLAGS=$with_extra_cxxflags
41879   LEGACY_EXTRA_LDFLAGS=$with_extra_ldflags
41880 
41881 
41882 
41883 
41884 
41885   ###############################################################################
41886   #
41887   # Now setup the CFLAGS and LDFLAGS for the JDK build.
41888   # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build.
41889   #
41890   case $COMPILER_NAME in
41891     gcc )
41892       # these options are used for both C and C++ compiles
41893       CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -Wall -Wno-parentheses -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \
41894       -pipe \
41895       -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE"
41896       case $OPENJDK_TARGET_CPU_ARCH in
41897         arm )
41898           # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing
41899           CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing"
41900           ;;
41901         ppc )
41902           # on ppc we don't prevent gcc to omit frame pointer nor strict-aliasing
41903           ;;
41904         * )
41905           CCXXFLAGS_JDK="$CCXXFLAGS_JDK -fno-omit-frame-pointer"
41906           CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing"
41907           ;;
41908       esac
41909       ;;
41910     ossc )
41911       CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS"
41912       case $OPENJDK_TARGET_CPU_ARCH in
41913         x86 )
41914           CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB"
41915           CFLAGS_JDK="$CFLAGS_JDK -erroff=E_BAD_PRAGMA_PACK_VALUE"
41916           ;;
41917       esac
41918 
41919       CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal"
41920       CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib"
41921 
41922       LDFLAGS_JDK="$LDFLAGS_JDK -z defs -xildoff -ztext"
41923       LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK -norunpath -xnolib"
41924       ;;
41925     xlc )
41926       CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC"
41927       CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC"
41928 
41929       LDFLAGS_JDK="$LDFLAGS_JDK"
41930       LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK"
41931       ;;
41932     cl )
41933       CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -Zi -MD -Zc:wchar_t- -W3 -wd4800 \
41934       -D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB -DWIN32_LEAN_AND_MEAN \
41935       -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \
41936       -DWIN32 -DIAL"
41937       case $OPENJDK_TARGET_CPU in
41938         x86 )
41939           CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_X86_ -Dx86"
41940           ;;
41941         x86_64 )
41942           CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_AMD64_ -Damd64"
41943           ;;
41944       esac
41945       ;;
41946   esac
41947 
41948   ###############################################################################
41949 
41950   # Adjust flags according to debug level.
41951   case $DEBUG_LEVEL in
41952     fastdebug )
41953       CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS"
41954       CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS"
41955       C_O_FLAG_HI="$C_O_FLAG_NORM"
41956       C_O_FLAG_NORM="$C_O_FLAG_NORM"
41957       CXX_O_FLAG_HI="$CXX_O_FLAG_NORM"
41958       CXX_O_FLAG_NORM="$CXX_O_FLAG_NORM"
41959       JAVAC_FLAGS="$JAVAC_FLAGS -g"
41960       ;;
41961     slowdebug )
41962       CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS"
41963       CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS"
41964       C_O_FLAG_HI="$C_O_FLAG_NONE"
41965       C_O_FLAG_NORM="$C_O_FLAG_NONE"
41966       CXX_O_FLAG_HI="$CXX_O_FLAG_NONE"
41967       CXX_O_FLAG_NORM="$CXX_O_FLAG_NONE"
41968       JAVAC_FLAGS="$JAVAC_FLAGS -g"
41969       ;;
41970   esac
41971 
41972   CCXXFLAGS_JDK="$CCXXFLAGS_JDK $ADD_LP64"
41973 
41974   # The package path is used only on macosx?
41975   PACKAGE_PATH=/opt/local
41976 
41977 
41978   if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then
41979     # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the
41980     #   Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN
41981     #   (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h).
41982     #   Note: -Dmacro         is the same as    #define macro 1
41983     #         -Dmacro=        is the same as    #define macro
41984     if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41985       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN="
41986     else
41987       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN"
41988     fi
41989   else
41990     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_BIG_ENDIAN"
41991   fi
41992   if test "x$OPENJDK_TARGET_OS" = xlinux; then
41993     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DLINUX"
41994   fi
41995   if test "x$OPENJDK_TARGET_OS" = xwindows; then
41996     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DWINDOWS"
41997   fi
41998   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41999     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DSOLARIS"
42000   fi
42001   if test "x$OPENJDK_TARGET_OS" = xaix; then
42002     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DAIX -DPPC64"
42003   fi
42004   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
42005     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DMACOSX -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT"
42006     # Setting these parameters makes it an error to link to macosx APIs that are
42007     # newer than the given OS version and makes the linked binaries compatible even
42008     # if built on a newer version of the OS.
42009     # The expected format is X.Y.Z
42010     MACOSX_VERSION_MIN=10.7.0
42011 
42012     # The macro takes the version with no dots, ex: 1070
42013     # Let the flags variables get resolved in make for easier override on make
42014     # command line.
42015     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
42016     LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
42017   fi
42018   if test "x$OPENJDK_TARGET_OS" = xbsd; then
42019     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DBSD -D_ALLBSD_SOURCE"
42020   fi
42021   if test "x$DEBUG_LEVEL" = xrelease; then
42022     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DNDEBUG"
42023   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
42024     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DTRIMMED"
42025   fi
42026   else
42027     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DDEBUG"
42028   fi
42029 
42030   CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY"
42031   CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DRELEASE='\"\$(RELEASE)\"'"
42032 
42033   CCXXFLAGS_JDK="$CCXXFLAGS_JDK \
42034       -I${JDK_OUTPUTDIR}/include \
42035       -I${JDK_OUTPUTDIR}/include/$OPENJDK_TARGET_OS \
42036       -I${JDK_TOPDIR}/src/share/javavm/export \
42037       -I${JDK_TOPDIR}/src/$OPENJDK_TARGET_OS_EXPORT_DIR/javavm/export \
42038       -I${JDK_TOPDIR}/src/share/native/common \
42039       -I${JDK_TOPDIR}/src/$OPENJDK_TARGET_OS_API_DIR/native/common"
42040 
42041   # The shared libraries are compiled using the picflag.
42042   CFLAGS_JDKLIB="$CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA"
42043   CXXFLAGS_JDKLIB="$CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA "
42044 
42045   # Executable flags
42046   CFLAGS_JDKEXE="$CCXXFLAGS_JDK $CFLAGS_JDK"
42047   CXXFLAGS_JDKEXE="$CCXXFLAGS_JDK $CXXFLAGS_JDK"
42048 
42049   # Now this is odd. The JDK native libraries have to link against libjvm.so
42050   # On 32-bit machines there is normally two distinct libjvm.so:s, client and server.
42051   # Which should we link to? Are we lucky enough that the binary api to the libjvm.so library
42052   # is identical for client and server? Yes. Which is picked at runtime (client or server)?
42053   # Neither, since the chosen libjvm.so has already been loaded by the launcher, all the following
42054   # libraries will link to whatever is in memory. Yuck.
42055   #
42056   # Thus we offer the compiler to find libjvm.so first in server then in client. It works. Ugh.
42057   if test "x$COMPILER_NAME" = xcl; then
42058     LDFLAGS_JDK="$LDFLAGS_JDK -nologo -opt:ref -incremental:no"
42059     if test "x$OPENJDK_TARGET_CPU" = xx86; then
42060       LDFLAGS_JDK="$LDFLAGS_JDK -safeseh"
42061     fi
42062     # TODO: make -debug optional "--disable-full-debug-symbols"
42063     LDFLAGS_JDK="$LDFLAGS_JDK -debug"
42064     LDFLAGS_JDKLIB="${LDFLAGS_JDK} -dll -libpath:${JDK_OUTPUTDIR}/lib"
42065     LDFLAGS_JDKLIB_SUFFIX=""
42066     if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then
42067       LDFLAGS_STACK_SIZE=1048576
42068     else
42069       LDFLAGS_STACK_SIZE=327680
42070     fi
42071     LDFLAGS_JDKEXE="${LDFLAGS_JDK} /STACK:$LDFLAGS_STACK_SIZE"
42072   else
42073     if test "x$COMPILER_NAME" = xgcc; then
42074       # If this is a --hash-style=gnu system, use --hash-style=both, why?
42075       HAS_GNU_HASH=`$CC -dumpspecs 2>/dev/null | $GREP 'hash-style=gnu'`
42076       if test -n "$HAS_GNU_HASH"; then
42077         LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker --hash-style=both "
42078       fi
42079       if test "x$OPENJDK_TARGET_OS" = xlinux; then
42080         # And since we now know that the linker is gnu, then add -z defs, to forbid
42081         # undefined symbols in object files.
42082         LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker -z -Xlinker defs"
42083         if test "x$DEBUG_LEVEL" = "xrelease"; then
42084           # When building release libraries, tell the linker optimize them.
42085           # Should this be supplied to the OSS linker as well?
42086           LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker -O1"
42087         fi
42088       fi
42089     fi
42090     LDFLAGS_JDKLIB="${LDFLAGS_JDK} $SHARED_LIBRARY_FLAGS \
42091         -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}"
42092 
42093     # On some platforms (mac) the linker warns about non existing -L dirs.
42094     # Add server first if available. Linking aginst client does not always produce the same results.
42095     # Only add client dir if client is being built. Add minimal (note not minimal1) if only building minimal1.
42096     # Default to server for other variants.
42097     if test "x$JVM_VARIANT_SERVER" = xtrue; then
42098       LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/server"
42099     elif test "x$JVM_VARIANT_CLIENT" = xtrue; then
42100       LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/client"
42101     elif test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
42102       LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/minimal"
42103     else
42104       LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/server"
42105     fi
42106 
42107     LDFLAGS_JDKLIB_SUFFIX="-ljava -ljvm"
42108     if test "x$COMPILER_NAME" = xossc; then
42109       LDFLAGS_JDKLIB_SUFFIX="$LDFLAGS_JDKLIB_SUFFIX -lc"
42110     fi
42111 
42112     LDFLAGS_JDKEXE="${LDFLAGS_JDK}"
42113     if test "x$OPENJDK_TARGET_OS" = xlinux; then
42114       LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Xlinker --allow-shlib-undefined"
42115     fi
42116   fi
42117 
42118 
42119 
42120 
42121 
42122 
42123 
42124 
42125 
42126 
42127 
42128 
42129 
42130 
42131 
42132   # Some Zero and Shark settings.
42133   # ZERO_ARCHFLAG tells the compiler which mode to build for
42134   case "${OPENJDK_TARGET_CPU}" in
42135     s390)
42136       ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}31"
42137       ;;
42138     *)
42139       ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
42140   esac
42141 
42142   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"$ZERO_ARCHFLAG\"" >&5
42143 $as_echo_n "checking if compiler supports \"$ZERO_ARCHFLAG\"... " >&6; }
42144   supports=yes
42145 
42146   saved_cflags="$CFLAGS"
42147   CFLAGS="$CFLAGS $ZERO_ARCHFLAG"
42148   ac_ext=c
42149 ac_cpp='$CPP $CPPFLAGS'
42150 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42151 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42152 ac_compiler_gnu=$ac_cv_c_compiler_gnu
42153 
42154   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42155 /* end confdefs.h.  */
42156 int i;
42157 _ACEOF
42158 if ac_fn_c_try_compile "$LINENO"; then :
42159 
42160 else
42161   supports=no
42162 fi
42163 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
42164   ac_ext=cpp
42165 ac_cpp='$CXXCPP $CPPFLAGS'
42166 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42167 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42168 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
42169 
42170   CFLAGS="$saved_cflags"
42171 
42172   saved_cxxflags="$CXXFLAGS"
42173   CXXFLAGS="$CXXFLAG $ZERO_ARCHFLAG"
42174   ac_ext=cpp
42175 ac_cpp='$CXXCPP $CPPFLAGS'
42176 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42177 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42178 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
42179 
42180   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42181 /* end confdefs.h.  */
42182 int i;
42183 _ACEOF
42184 if ac_fn_cxx_try_compile "$LINENO"; then :
42185 
42186 else
42187   supports=no
42188 fi
42189 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
42190   ac_ext=cpp
42191 ac_cpp='$CXXCPP $CPPFLAGS'
42192 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42193 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42194 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
42195 
42196   CXXFLAGS="$saved_cxxflags"
42197 
42198   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5
42199 $as_echo "$supports" >&6; }
42200   if test "x$supports" = "xyes" ; then
42201     :
42202   else
42203     ZERO_ARCHFLAG=""
42204   fi
42205 
42206 
42207 
42208   # Check that the compiler supports -mX (or -qX on AIX) flags
42209   # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does
42210 
42211   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5
42212 $as_echo_n "checking if compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; }
42213   supports=yes
42214 
42215   saved_cflags="$CFLAGS"
42216   CFLAGS="$CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
42217   ac_ext=c
42218 ac_cpp='$CPP $CPPFLAGS'
42219 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42220 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42221 ac_compiler_gnu=$ac_cv_c_compiler_gnu
42222 
42223   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42224 /* end confdefs.h.  */
42225 int i;
42226 _ACEOF
42227 if ac_fn_c_try_compile "$LINENO"; then :
42228 
42229 else
42230   supports=no
42231 fi
42232 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
42233   ac_ext=cpp
42234 ac_cpp='$CXXCPP $CPPFLAGS'
42235 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42236 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42237 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
42238 
42239   CFLAGS="$saved_cflags"
42240 
42241   saved_cxxflags="$CXXFLAGS"
42242   CXXFLAGS="$CXXFLAG ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
42243   ac_ext=cpp
42244 ac_cpp='$CXXCPP $CPPFLAGS'
42245 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42246 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42247 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
42248 
42249   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42250 /* end confdefs.h.  */
42251 int i;
42252 _ACEOF
42253 if ac_fn_cxx_try_compile "$LINENO"; then :
42254 
42255 else
42256   supports=no
42257 fi
42258 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
42259   ac_ext=cpp
42260 ac_cpp='$CXXCPP $CPPFLAGS'
42261 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42262 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42263 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
42264 
42265   CXXFLAGS="$saved_cxxflags"
42266 
42267   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5
42268 $as_echo "$supports" >&6; }
42269   if test "x$supports" = "xyes" ; then
42270     COMPILER_SUPPORTS_TARGET_BITS_FLAG=true
42271   else
42272     COMPILER_SUPPORTS_TARGET_BITS_FLAG=false
42273   fi
42274 
42275 
42276 
42277 
42278   # Check for broken SuSE 'ld' for which 'Only anonymous version tag is allowed in executable.'
42279   USING_BROKEN_SUSE_LD=no
42280   if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$GCC" = xyes; then
42281     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken SuSE 'ld' which only understands anonymous version tags in executables" >&5
42282 $as_echo_n "checking for broken SuSE 'ld' which only understands anonymous version tags in executables... " >&6; }
42283     echo "SUNWprivate_1.1 { local: *; };" > version-script.map
42284     echo "int main() { }" > main.c
42285     if $CXX -Xlinker -version-script=version-script.map main.c 2>&5 >&5; then
42286       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42287 $as_echo "no" >&6; }
42288       USING_BROKEN_SUSE_LD=no
42289     else
42290       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42291 $as_echo "yes" >&6; }
42292       USING_BROKEN_SUSE_LD=yes
42293     fi
42294     rm -rf version-script.map main.c a.out
42295   fi
42296 
42297 
42298 
42299 # Setup debug symbols (need objcopy from the toolchain for that)
42300 
42301   #
42302   # ENABLE_DEBUG_SYMBOLS
42303   # This must be done after the toolchain is setup, since we're looking at objcopy.
42304   #
42305   # Check whether --enable-debug-symbols was given.
42306 if test "${enable_debug_symbols+set}" = set; then :
42307   enableval=$enable_debug_symbols;
42308 fi
42309 
42310 
42311   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should generate debug symbols" >&5
42312 $as_echo_n "checking if we should generate debug symbols... " >&6; }
42313 
42314   if test "x$enable_debug_symbols" = "xyes" && test "x$OBJCOPY" = x; then
42315     # explicit enabling of enable-debug-symbols and can't find objcopy
42316     #   this is an error
42317     as_fn_error $? "Unable to find objcopy, cannot enable debug-symbols" "$LINENO" 5
42318   fi
42319 
42320   if test "x$enable_debug_symbols" = "xyes"; then
42321     ENABLE_DEBUG_SYMBOLS=true
42322   elif test "x$enable_debug_symbols" = "xno"; then
42323     ENABLE_DEBUG_SYMBOLS=false
42324   else
42325     # Default is on if objcopy is found
42326     if test "x$OBJCOPY" != x; then
42327       ENABLE_DEBUG_SYMBOLS=true
42328     # MacOS X and Windows don't use objcopy but default is on for those OSes
42329     elif test "x$OPENJDK_TARGET_OS" = xmacosx || test "x$OPENJDK_TARGET_OS" = xwindows; then
42330       ENABLE_DEBUG_SYMBOLS=true
42331     else
42332       ENABLE_DEBUG_SYMBOLS=false
42333     fi
42334   fi
42335 
42336   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_DEBUG_SYMBOLS" >&5
42337 $as_echo "$ENABLE_DEBUG_SYMBOLS" >&6; }
42338 
42339   #
42340   # ZIP_DEBUGINFO_FILES
42341   #
42342   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should zip debug-info files" >&5
42343 $as_echo_n "checking if we should zip debug-info files... " >&6; }
42344   # Check whether --enable-zip-debug-info was given.
42345 if test "${enable_zip_debug_info+set}" = set; then :
42346   enableval=$enable_zip_debug_info; enable_zip_debug_info="${enableval}"
42347 else
42348   enable_zip_debug_info="yes"
42349 fi
42350 
42351   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_zip_debug_info}" >&5
42352 $as_echo "${enable_zip_debug_info}" >&6; }
42353 
42354   if test "x${enable_zip_debug_info}" = "xno"; then
42355     ZIP_DEBUGINFO_FILES=false
42356   else
42357     ZIP_DEBUGINFO_FILES=true
42358   fi
42359 
42360 
42361 
42362 
42363 
42364 
42365 
42366 ###############################################################################
42367 #
42368 # Check dependencies for external and internal libraries.
42369 #
42370 ###############################################################################
42371 
42372 # After we have toolchain, we can compile fixpath. It's needed by the lib checks.
42373 
42374   # When using cygwin or msys, we need a wrapper binary that renames
42375   # /cygdrive/c/ arguments into c:/ arguments and peeks into
42376   # @files and rewrites these too! This wrapper binary is
42377   # called fixpath.
42378   FIXPATH=
42379   if test "x$OPENJDK_BUILD_OS" = xwindows; then
42380     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5
42381 $as_echo_n "checking if fixpath can be created... " >&6; }
42382     FIXPATH_SRC="$SRC_ROOT/common/src/fixpath.c"
42383     FIXPATH_BIN="$OUTPUT_ROOT/fixpath.exe"
42384     if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then
42385       FIXPATH_SRC=`$CYGPATH -m $FIXPATH_SRC`
42386       FIXPATH_BIN=`$CYGPATH -m $FIXPATH_BIN`
42387       # Important to keep the .exe suffix on Cygwin for Hotspot makefiles
42388       FIXPATH="$OUTPUT_ROOT/fixpath.exe -c"
42389     elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then
42390       FIXPATH_SRC=`cmd //c echo $FIXPATH_SRC`
42391       FIXPATH_BIN=`cmd //c echo $FIXPATH_BIN`
42392 
42393       # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line
42394       # @ was chosen as separator to minimize risk of other tools messing around with it
42395       all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" | tr ' ' '\n' | grep '^/./' | sort | uniq`
42396       fixpath_argument_list=`echo $all_unique_prefixes  | tr ' ' '@'`
42397 
42398       FIXPATH="$OUTPUT_ROOT/fixpath -m$fixpath_argument_list"
42399     fi
42400     rm -f $OUTPUT_ROOT/fixpath*
42401     cd $OUTPUT_ROOT
42402     $CC $FIXPATH_SRC -Fe$FIXPATH_BIN > $OUTPUT_ROOT/fixpath1.log 2>&1
42403     cd $CURDIR
42404 
42405     if test ! -x $OUTPUT_ROOT/fixpath.exe; then
42406       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42407 $as_echo "no" >&6; }
42408       cat $OUTPUT_ROOT/fixpath1.log
42409       as_fn_error $? "Could not create $OUTPUT_ROOT/fixpath.exe" "$LINENO" 5
42410     fi
42411     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42412 $as_echo "yes" >&6; }
42413     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5
42414 $as_echo_n "checking if fixpath.exe works... " >&6; }
42415     cd $OUTPUT_ROOT
42416     $FIXPATH $CC $SRC_ROOT/common/src/fixpath.c -Fe$OUTPUT_ROOT/fixpath2.exe > $OUTPUT_ROOT/fixpath2.log 2>&1
42417     cd $CURDIR
42418     if test ! -x $OUTPUT_ROOT/fixpath2.exe; then
42419       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42420 $as_echo "no" >&6; }
42421       cat $OUTPUT_ROOT/fixpath2.log
42422       as_fn_error $? "fixpath did not work!" "$LINENO" 5
42423     fi
42424     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42425 $as_echo "yes" >&6; }
42426     rm -f $OUTPUT_ROOT/fixpath?.??? $OUTPUT_ROOT/fixpath.obj
42427   fi
42428 
42429 
42430 
42431 
42432 
42433 
42434   ###############################################################################
42435   #
42436   # OS specific settings that we never will need to probe.
42437   #
42438   if test "x$OPENJDK_TARGET_OS" = xlinux; then
42439     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Linux?" >&5
42440 $as_echo_n "checking what is not needed on Linux?... " >&6; }
42441     PULSE_NOT_NEEDED=yes
42442     { $as_echo "$as_me:${as_lineno-$LINENO}: result: pulse" >&5
42443 $as_echo "pulse" >&6; }
42444   fi
42445 
42446   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
42447     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Solaris?" >&5
42448 $as_echo_n "checking what is not needed on Solaris?... " >&6; }
42449     ALSA_NOT_NEEDED=yes
42450     PULSE_NOT_NEEDED=yes
42451     { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5
42452 $as_echo "alsa pulse" >&6; }
42453   fi
42454 
42455   if test "x$OPENJDK_TARGET_OS" = xaix; then
42456     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on AIX?" >&5
42457 $as_echo_n "checking what is not needed on AIX?... " >&6; }
42458     ALSA_NOT_NEEDED=yes
42459     PULSE_NOT_NEEDED=yes
42460     { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5
42461 $as_echo "alsa pulse" >&6; }
42462   fi
42463 
42464 
42465   if test "x$OPENJDK_TARGET_OS" = xwindows; then
42466     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Windows?" >&5
42467 $as_echo_n "checking what is not needed on Windows?... " >&6; }
42468     CUPS_NOT_NEEDED=yes
42469     ALSA_NOT_NEEDED=yes
42470     PULSE_NOT_NEEDED=yes
42471     X11_NOT_NEEDED=yes
42472     { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa cups pulse x11" >&5
42473 $as_echo "alsa cups pulse x11" >&6; }
42474   fi
42475 
42476   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
42477     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on MacOSX?" >&5
42478 $as_echo_n "checking what is not needed on MacOSX?... " >&6; }
42479     ALSA_NOT_NEEDED=yes
42480     PULSE_NOT_NEEDED=yes
42481     X11_NOT_NEEDED=yes
42482     # If the java runtime framework is disabled, then we need X11.
42483     # This will be adjusted below.
42484     { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse x11" >&5
42485 $as_echo "alsa pulse x11" >&6; }
42486   fi
42487 
42488   if test "x$OPENJDK_TARGET_OS" = xbsd; then
42489     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on bsd?" >&5
42490 $as_echo_n "checking what is not needed on bsd?... " >&6; }
42491     ALSA_NOT_NEEDED=yes
42492     { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa" >&5
42493 $as_echo "alsa" >&6; }
42494   fi
42495 
42496   if test "x$OPENJDK" = "xfalse"; then
42497     FREETYPE_NOT_NEEDED=yes
42498   fi
42499 
42500   if test "x$SUPPORT_HEADFUL" = xno; then
42501     X11_NOT_NEEDED=yes
42502   fi
42503 
42504   ###############################################################################
42505   #
42506   # Check for MacOSX support for OpenJDK.
42507   #
42508 
42509 
42510   # Check whether --enable-macosx-runtime-support was given.
42511 if test "${enable_macosx_runtime_support+set}" = set; then :
42512   enableval=$enable_macosx_runtime_support;
42513 fi
42514 
42515   if test "x$enable_macosx_runtime_support" != x; then
42516     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-macosx-runtime-support is deprecated and will be ignored." >&5
42517 $as_echo "$as_me: WARNING: Option --enable-macosx-runtime-support is deprecated and will be ignored." >&2;}
42518   fi
42519 
42520 
42521   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Mac OS X Java Framework" >&5
42522 $as_echo_n "checking for Mac OS X Java Framework... " >&6; }
42523   if test -f /System/Library/Frameworks/JavaVM.framework/Frameworks/JavaRuntimeSupport.framework/Headers/JavaRuntimeSupport.h; then
42524     { $as_echo "$as_me:${as_lineno-$LINENO}: result: /System/Library/Frameworks/JavaVM.framework" >&5
42525 $as_echo "/System/Library/Frameworks/JavaVM.framework" >&6; }
42526   else
42527     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42528 $as_echo "no" >&6; }
42529   fi
42530 
42531 
42532 
42533   ###############################################################################
42534   #
42535   # Check for X Windows
42536   #
42537 
42538   # Check if the user has specified sysroot, but not --x-includes or --x-libraries.
42539   # Make a simple check for the libraries at the sysroot, and setup --x-includes and
42540   # --x-libraries for the sysroot, if that seems to be correct.
42541   if test "x$SYS_ROOT" != "x/"; then
42542     if test "x$x_includes" = xNONE; then
42543       if test -f "$SYS_ROOT/usr/X11R6/include/X11/Xlib.h"; then
42544         x_includes="$SYS_ROOT/usr/X11R6/include"
42545       elif test -f "$SYS_ROOT/usr/include/X11/Xlib.h"; then
42546         x_includes="$SYS_ROOT/usr/include"
42547       fi
42548     fi
42549     if test "x$x_libraries" = xNONE; then
42550       if test -f "$SYS_ROOT/usr/X11R6/lib/libX11.so"; then
42551         x_libraries="$SYS_ROOT/usr/X11R6/lib"
42552       elif test "$SYS_ROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
42553         x_libraries="$SYS_ROOT/usr/lib64"
42554       elif test -f "$SYS_ROOT/usr/lib/libX11.so"; then
42555         x_libraries="$SYS_ROOT/usr/lib"
42556       fi
42557     fi
42558   fi
42559 
42560   # Now let autoconf do it's magic
42561   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
42562 $as_echo_n "checking for X... " >&6; }
42563 
42564 
42565 # Check whether --with-x was given.
42566 if test "${with_x+set}" = set; then :
42567   withval=$with_x;
42568 fi
42569 
42570 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
42571 if test "x$with_x" = xno; then
42572   # The user explicitly disabled X.
42573   have_x=disabled
42574 else
42575   case $x_includes,$x_libraries in #(
42576     *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #(
42577     *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then :
42578   $as_echo_n "(cached) " >&6
42579 else
42580   # One or both of the vars are not set, and there is no cached value.
42581 ac_x_includes=no ac_x_libraries=no
42582 rm -f -r conftest.dir
42583 if mkdir conftest.dir; then
42584   cd conftest.dir
42585   cat >Imakefile <<'_ACEOF'
42586 incroot:
42587         @echo incroot='${INCROOT}'
42588 usrlibdir:
42589         @echo usrlibdir='${USRLIBDIR}'
42590 libdir:
42591         @echo libdir='${LIBDIR}'
42592 _ACEOF
42593   if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
42594     # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
42595     for ac_var in incroot usrlibdir libdir; do
42596       eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
42597     done
42598     # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
42599     for ac_extension in a so sl dylib la dll; do
42600       if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
42601          test -f "$ac_im_libdir/libX11.$ac_extension"; then
42602         ac_im_usrlibdir=$ac_im_libdir; break
42603       fi
42604     done
42605     # Screen out bogus values from the imake configuration.  They are
42606     # bogus both because they are the default anyway, and because
42607     # using them would break gcc on systems where it needs fixed includes.
42608     case $ac_im_incroot in
42609         /usr/include) ac_x_includes= ;;
42610         *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
42611     esac
42612     case $ac_im_usrlibdir in
42613         /usr/lib | /usr/lib64 | /lib | /lib64) ;;
42614         *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
42615     esac
42616   fi
42617   cd ..
42618   rm -f -r conftest.dir
42619 fi
42620 
42621 # Standard set of common directories for X headers.
42622 # Check X11 before X11Rn because it is often a symlink to the current release.
42623 ac_x_header_dirs='
42624 /usr/X11/include
42625 /usr/X11R7/include
42626 /usr/X11R6/include
42627 /usr/X11R5/include
42628 /usr/X11R4/include
42629 
42630 /usr/include/X11
42631 /usr/include/X11R7
42632 /usr/include/X11R6
42633 /usr/include/X11R5
42634 /usr/include/X11R4
42635 
42636 /usr/local/X11/include
42637 /usr/local/X11R7/include
42638 /usr/local/X11R6/include
42639 /usr/local/X11R5/include
42640 /usr/local/X11R4/include
42641 
42642 /usr/local/include/X11
42643 /usr/local/include/X11R7
42644 /usr/local/include/X11R6
42645 /usr/local/include/X11R5
42646 /usr/local/include/X11R4
42647 
42648 /usr/X386/include
42649 /usr/x386/include
42650 /usr/XFree86/include/X11
42651 
42652 /usr/include
42653 /usr/local/include
42654 /usr/unsupported/include
42655 /usr/athena/include
42656 /usr/local/x11r5/include
42657 /usr/lpp/Xamples/include
42658 
42659 /usr/openwin/include
42660 /usr/openwin/share/include'
42661 
42662 if test "$ac_x_includes" = no; then
42663   # Guess where to find include files, by looking for Xlib.h.
42664   # First, try using that file with no special directory specified.
42665   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42666 /* end confdefs.h.  */
42667 #include <X11/Xlib.h>
42668 _ACEOF
42669 if ac_fn_cxx_try_cpp "$LINENO"; then :
42670   # We can compile using X headers with no special include directory.
42671 ac_x_includes=
42672 else
42673   for ac_dir in $ac_x_header_dirs; do
42674   if test -r "$ac_dir/X11/Xlib.h"; then
42675     ac_x_includes=$ac_dir
42676     break
42677   fi
42678 done
42679 fi
42680 rm -f conftest.err conftest.i conftest.$ac_ext
42681 fi # $ac_x_includes = no
42682 
42683 if test "$ac_x_libraries" = no; then
42684   # Check for the libraries.
42685   # See if we find them without any special options.
42686   # Don't add to $LIBS permanently.
42687   ac_save_LIBS=$LIBS
42688   LIBS="-lX11 $LIBS"
42689   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42690 /* end confdefs.h.  */
42691 #include <X11/Xlib.h>
42692 int
42693 main ()
42694 {
42695 XrmInitialize ()
42696   ;
42697   return 0;
42698 }
42699 _ACEOF
42700 if ac_fn_cxx_try_link "$LINENO"; then :
42701   LIBS=$ac_save_LIBS
42702 # We can link X programs with no special library path.
42703 ac_x_libraries=
42704 else
42705   LIBS=$ac_save_LIBS
42706 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
42707 do
42708   # Don't even attempt the hair of trying to link an X program!
42709   for ac_extension in a so sl dylib la dll; do
42710     if test -r "$ac_dir/libX11.$ac_extension"; then
42711       ac_x_libraries=$ac_dir
42712       break 2
42713     fi
42714   done
42715 done
42716 fi
42717 rm -f core conftest.err conftest.$ac_objext \
42718     conftest$ac_exeext conftest.$ac_ext
42719 fi # $ac_x_libraries = no
42720 
42721 case $ac_x_includes,$ac_x_libraries in #(
42722   no,* | *,no | *\'*)
42723     # Didn't find X, or a directory has "'" in its name.
42724     ac_cv_have_x="have_x=no";; #(
42725   *)
42726     # Record where we found X for the cache.
42727     ac_cv_have_x="have_x=yes\
42728         ac_x_includes='$ac_x_includes'\
42729         ac_x_libraries='$ac_x_libraries'"
42730 esac
42731 fi
42732 ;; #(
42733     *) have_x=yes;;
42734   esac
42735   eval "$ac_cv_have_x"
42736 fi # $with_x != no
42737 
42738 if test "$have_x" != yes; then
42739   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
42740 $as_echo "$have_x" >&6; }
42741   no_x=yes
42742 else
42743   # If each of the values was on the command line, it overrides each guess.
42744   test "x$x_includes" = xNONE && x_includes=$ac_x_includes
42745   test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
42746   # Update the cache value to reflect the command line values.
42747   ac_cv_have_x="have_x=yes\
42748         ac_x_includes='$x_includes'\
42749         ac_x_libraries='$x_libraries'"
42750   { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
42751 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
42752 fi
42753 
42754   if test "$no_x" = yes; then
42755   # Not all programs may use this symbol, but it does not hurt to define it.
42756 
42757 $as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h
42758 
42759   X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
42760 else
42761   if test -n "$x_includes"; then
42762     X_CFLAGS="$X_CFLAGS -I$x_includes"
42763   fi
42764 
42765   # It would also be nice to do this for all -L options, not just this one.
42766   if test -n "$x_libraries"; then
42767     X_LIBS="$X_LIBS -L$x_libraries"
42768     # For Solaris; some versions of Sun CC require a space after -R and
42769     # others require no space.  Words are not sufficient . . . .
42770     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5
42771 $as_echo_n "checking whether -R must be followed by a space... " >&6; }
42772     ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
42773     ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag
42774     ac_cxx_werror_flag=yes
42775     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42776 /* end confdefs.h.  */
42777 
42778 int
42779 main ()
42780 {
42781 
42782   ;
42783   return 0;
42784 }
42785 _ACEOF
42786 if ac_fn_cxx_try_link "$LINENO"; then :
42787   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42788 $as_echo "no" >&6; }
42789        X_LIBS="$X_LIBS -R$x_libraries"
42790 else
42791   LIBS="$ac_xsave_LIBS -R $x_libraries"
42792        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42793 /* end confdefs.h.  */
42794 
42795 int
42796 main ()
42797 {
42798 
42799   ;
42800   return 0;
42801 }
42802 _ACEOF
42803 if ac_fn_cxx_try_link "$LINENO"; then :
42804   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42805 $as_echo "yes" >&6; }
42806           X_LIBS="$X_LIBS -R $x_libraries"
42807 else
42808   { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5
42809 $as_echo "neither works" >&6; }
42810 fi
42811 rm -f core conftest.err conftest.$ac_objext \
42812     conftest$ac_exeext conftest.$ac_ext
42813 fi
42814 rm -f core conftest.err conftest.$ac_objext \
42815     conftest$ac_exeext conftest.$ac_ext
42816     ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag
42817     LIBS=$ac_xsave_LIBS
42818   fi
42819 
42820   # Check for system-dependent libraries X programs must link with.
42821   # Do this before checking for the system-independent R6 libraries
42822   # (-lICE), since we may need -lsocket or whatever for X linking.
42823 
42824   if test "$ISC" = yes; then
42825     X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
42826   else
42827     # Martyn Johnson says this is needed for Ultrix, if the X
42828     # libraries were built with DECnet support.  And Karl Berry says
42829     # the Alpha needs dnet_stub (dnet does not exist).
42830     ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
42831     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42832 /* end confdefs.h.  */
42833 
42834 /* Override any GCC internal prototype to avoid an error.
42835    Use char because int might match the return type of a GCC
42836    builtin and then its argument prototype would still apply.  */
42837 #ifdef __cplusplus
42838 extern "C"
42839 #endif
42840 char XOpenDisplay ();
42841 int
42842 main ()
42843 {
42844 return XOpenDisplay ();
42845   ;
42846   return 0;
42847 }
42848 _ACEOF
42849 if ac_fn_cxx_try_link "$LINENO"; then :
42850 
42851 else
42852   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
42853 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
42854 if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then :
42855   $as_echo_n "(cached) " >&6
42856 else
42857   ac_check_lib_save_LIBS=$LIBS
42858 LIBS="-ldnet  $LIBS"
42859 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42860 /* end confdefs.h.  */
42861 
42862 /* Override any GCC internal prototype to avoid an error.
42863    Use char because int might match the return type of a GCC
42864    builtin and then its argument prototype would still apply.  */
42865 #ifdef __cplusplus
42866 extern "C"
42867 #endif
42868 char dnet_ntoa ();
42869 int
42870 main ()
42871 {
42872 return dnet_ntoa ();
42873   ;
42874   return 0;
42875 }
42876 _ACEOF
42877 if ac_fn_cxx_try_link "$LINENO"; then :
42878   ac_cv_lib_dnet_dnet_ntoa=yes
42879 else
42880   ac_cv_lib_dnet_dnet_ntoa=no
42881 fi
42882 rm -f core conftest.err conftest.$ac_objext \
42883     conftest$ac_exeext conftest.$ac_ext
42884 LIBS=$ac_check_lib_save_LIBS
42885 fi
42886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
42887 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
42888 if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then :
42889   X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
42890 fi
42891 
42892     if test $ac_cv_lib_dnet_dnet_ntoa = no; then
42893       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5
42894 $as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; }
42895 if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then :
42896   $as_echo_n "(cached) " >&6
42897 else
42898   ac_check_lib_save_LIBS=$LIBS
42899 LIBS="-ldnet_stub  $LIBS"
42900 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42901 /* end confdefs.h.  */
42902 
42903 /* Override any GCC internal prototype to avoid an error.
42904    Use char because int might match the return type of a GCC
42905    builtin and then its argument prototype would still apply.  */
42906 #ifdef __cplusplus
42907 extern "C"
42908 #endif
42909 char dnet_ntoa ();
42910 int
42911 main ()
42912 {
42913 return dnet_ntoa ();
42914   ;
42915   return 0;
42916 }
42917 _ACEOF
42918 if ac_fn_cxx_try_link "$LINENO"; then :
42919   ac_cv_lib_dnet_stub_dnet_ntoa=yes
42920 else
42921   ac_cv_lib_dnet_stub_dnet_ntoa=no
42922 fi
42923 rm -f core conftest.err conftest.$ac_objext \
42924     conftest$ac_exeext conftest.$ac_ext
42925 LIBS=$ac_check_lib_save_LIBS
42926 fi
42927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
42928 $as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; }
42929 if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then :
42930   X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
42931 fi
42932 
42933     fi
42934 fi
42935 rm -f core conftest.err conftest.$ac_objext \
42936     conftest$ac_exeext conftest.$ac_ext
42937     LIBS="$ac_xsave_LIBS"
42938 
42939     # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
42940     # to get the SysV transport functions.
42941     # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
42942     # needs -lnsl.
42943     # The nsl library prevents programs from opening the X display
42944     # on Irix 5.2, according to T.E. Dickey.
42945     # The functions gethostbyname, getservbyname, and inet_addr are
42946     # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
42947     ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname"
42948 if test "x$ac_cv_func_gethostbyname" = xyes; then :
42949 
42950 fi
42951 
42952     if test $ac_cv_func_gethostbyname = no; then
42953       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5
42954 $as_echo_n "checking for gethostbyname in -lnsl... " >&6; }
42955 if ${ac_cv_lib_nsl_gethostbyname+:} false; then :
42956   $as_echo_n "(cached) " >&6
42957 else
42958   ac_check_lib_save_LIBS=$LIBS
42959 LIBS="-lnsl  $LIBS"
42960 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42961 /* end confdefs.h.  */
42962 
42963 /* Override any GCC internal prototype to avoid an error.
42964    Use char because int might match the return type of a GCC
42965    builtin and then its argument prototype would still apply.  */
42966 #ifdef __cplusplus
42967 extern "C"
42968 #endif
42969 char gethostbyname ();
42970 int
42971 main ()
42972 {
42973 return gethostbyname ();
42974   ;
42975   return 0;
42976 }
42977 _ACEOF
42978 if ac_fn_cxx_try_link "$LINENO"; then :
42979   ac_cv_lib_nsl_gethostbyname=yes
42980 else
42981   ac_cv_lib_nsl_gethostbyname=no
42982 fi
42983 rm -f core conftest.err conftest.$ac_objext \
42984     conftest$ac_exeext conftest.$ac_ext
42985 LIBS=$ac_check_lib_save_LIBS
42986 fi
42987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5
42988 $as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; }
42989 if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then :
42990   X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
42991 fi
42992 
42993       if test $ac_cv_lib_nsl_gethostbyname = no; then
42994         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5
42995 $as_echo_n "checking for gethostbyname in -lbsd... " >&6; }
42996 if ${ac_cv_lib_bsd_gethostbyname+:} false; then :
42997   $as_echo_n "(cached) " >&6
42998 else
42999   ac_check_lib_save_LIBS=$LIBS
43000 LIBS="-lbsd  $LIBS"
43001 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43002 /* end confdefs.h.  */
43003 
43004 /* Override any GCC internal prototype to avoid an error.
43005    Use char because int might match the return type of a GCC
43006    builtin and then its argument prototype would still apply.  */
43007 #ifdef __cplusplus
43008 extern "C"
43009 #endif
43010 char gethostbyname ();
43011 int
43012 main ()
43013 {
43014 return gethostbyname ();
43015   ;
43016   return 0;
43017 }
43018 _ACEOF
43019 if ac_fn_cxx_try_link "$LINENO"; then :
43020   ac_cv_lib_bsd_gethostbyname=yes
43021 else
43022   ac_cv_lib_bsd_gethostbyname=no
43023 fi
43024 rm -f core conftest.err conftest.$ac_objext \
43025     conftest$ac_exeext conftest.$ac_ext
43026 LIBS=$ac_check_lib_save_LIBS
43027 fi
43028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5
43029 $as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; }
43030 if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then :
43031   X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
43032 fi
43033 
43034       fi
43035     fi
43036 
43037     # lieder@skyler.mavd.honeywell.com says without -lsocket,
43038     # socket/setsockopt and other routines are undefined under SCO ODT
43039     # 2.0.  But -lsocket is broken on IRIX 5.2 (and is not necessary
43040     # on later versions), says Simon Leinen: it contains gethostby*
43041     # variants that don't use the name server (or something).  -lsocket
43042     # must be given before -lnsl if both are needed.  We assume that
43043     # if connect needs -lnsl, so does gethostbyname.
43044     ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect"
43045 if test "x$ac_cv_func_connect" = xyes; then :
43046 
43047 fi
43048 
43049     if test $ac_cv_func_connect = no; then
43050       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5
43051 $as_echo_n "checking for connect in -lsocket... " >&6; }
43052 if ${ac_cv_lib_socket_connect+:} false; then :
43053   $as_echo_n "(cached) " >&6
43054 else
43055   ac_check_lib_save_LIBS=$LIBS
43056 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
43057 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43058 /* end confdefs.h.  */
43059 
43060 /* Override any GCC internal prototype to avoid an error.
43061    Use char because int might match the return type of a GCC
43062    builtin and then its argument prototype would still apply.  */
43063 #ifdef __cplusplus
43064 extern "C"
43065 #endif
43066 char connect ();
43067 int
43068 main ()
43069 {
43070 return connect ();
43071   ;
43072   return 0;
43073 }
43074 _ACEOF
43075 if ac_fn_cxx_try_link "$LINENO"; then :
43076   ac_cv_lib_socket_connect=yes
43077 else
43078   ac_cv_lib_socket_connect=no
43079 fi
43080 rm -f core conftest.err conftest.$ac_objext \
43081     conftest$ac_exeext conftest.$ac_ext
43082 LIBS=$ac_check_lib_save_LIBS
43083 fi
43084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5
43085 $as_echo "$ac_cv_lib_socket_connect" >&6; }
43086 if test "x$ac_cv_lib_socket_connect" = xyes; then :
43087   X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
43088 fi
43089 
43090     fi
43091 
43092     # Guillermo Gomez says -lposix is necessary on A/UX.
43093     ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove"
43094 if test "x$ac_cv_func_remove" = xyes; then :
43095 
43096 fi
43097 
43098     if test $ac_cv_func_remove = no; then
43099       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5
43100 $as_echo_n "checking for remove in -lposix... " >&6; }
43101 if ${ac_cv_lib_posix_remove+:} false; then :
43102   $as_echo_n "(cached) " >&6
43103 else
43104   ac_check_lib_save_LIBS=$LIBS
43105 LIBS="-lposix  $LIBS"
43106 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43107 /* end confdefs.h.  */
43108 
43109 /* Override any GCC internal prototype to avoid an error.
43110    Use char because int might match the return type of a GCC
43111    builtin and then its argument prototype would still apply.  */
43112 #ifdef __cplusplus
43113 extern "C"
43114 #endif
43115 char remove ();
43116 int
43117 main ()
43118 {
43119 return remove ();
43120   ;
43121   return 0;
43122 }
43123 _ACEOF
43124 if ac_fn_cxx_try_link "$LINENO"; then :
43125   ac_cv_lib_posix_remove=yes
43126 else
43127   ac_cv_lib_posix_remove=no
43128 fi
43129 rm -f core conftest.err conftest.$ac_objext \
43130     conftest$ac_exeext conftest.$ac_ext
43131 LIBS=$ac_check_lib_save_LIBS
43132 fi
43133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5
43134 $as_echo "$ac_cv_lib_posix_remove" >&6; }
43135 if test "x$ac_cv_lib_posix_remove" = xyes; then :
43136   X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
43137 fi
43138 
43139     fi
43140 
43141     # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
43142     ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat"
43143 if test "x$ac_cv_func_shmat" = xyes; then :
43144 
43145 fi
43146 
43147     if test $ac_cv_func_shmat = no; then
43148       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5
43149 $as_echo_n "checking for shmat in -lipc... " >&6; }
43150 if ${ac_cv_lib_ipc_shmat+:} false; then :
43151   $as_echo_n "(cached) " >&6
43152 else
43153   ac_check_lib_save_LIBS=$LIBS
43154 LIBS="-lipc  $LIBS"
43155 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43156 /* end confdefs.h.  */
43157 
43158 /* Override any GCC internal prototype to avoid an error.
43159    Use char because int might match the return type of a GCC
43160    builtin and then its argument prototype would still apply.  */
43161 #ifdef __cplusplus
43162 extern "C"
43163 #endif
43164 char shmat ();
43165 int
43166 main ()
43167 {
43168 return shmat ();
43169   ;
43170   return 0;
43171 }
43172 _ACEOF
43173 if ac_fn_cxx_try_link "$LINENO"; then :
43174   ac_cv_lib_ipc_shmat=yes
43175 else
43176   ac_cv_lib_ipc_shmat=no
43177 fi
43178 rm -f core conftest.err conftest.$ac_objext \
43179     conftest$ac_exeext conftest.$ac_ext
43180 LIBS=$ac_check_lib_save_LIBS
43181 fi
43182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5
43183 $as_echo "$ac_cv_lib_ipc_shmat" >&6; }
43184 if test "x$ac_cv_lib_ipc_shmat" = xyes; then :
43185   X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
43186 fi
43187 
43188     fi
43189   fi
43190 
43191   # Check for libraries that X11R6 Xt/Xaw programs need.
43192   ac_save_LDFLAGS=$LDFLAGS
43193   test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
43194   # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
43195   # check for ICE first), but we must link in the order -lSM -lICE or
43196   # we get undefined symbols.  So assume we have SM if we have ICE.
43197   # These have to be linked with before -lX11, unlike the other
43198   # libraries we check for below, so use a different variable.
43199   # John Interrante, Karl Berry
43200   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5
43201 $as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; }
43202 if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then :
43203   $as_echo_n "(cached) " >&6
43204 else
43205   ac_check_lib_save_LIBS=$LIBS
43206 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
43207 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43208 /* end confdefs.h.  */
43209 
43210 /* Override any GCC internal prototype to avoid an error.
43211    Use char because int might match the return type of a GCC
43212    builtin and then its argument prototype would still apply.  */
43213 #ifdef __cplusplus
43214 extern "C"
43215 #endif
43216 char IceConnectionNumber ();
43217 int
43218 main ()
43219 {
43220 return IceConnectionNumber ();
43221   ;
43222   return 0;
43223 }
43224 _ACEOF
43225 if ac_fn_cxx_try_link "$LINENO"; then :
43226   ac_cv_lib_ICE_IceConnectionNumber=yes
43227 else
43228   ac_cv_lib_ICE_IceConnectionNumber=no
43229 fi
43230 rm -f core conftest.err conftest.$ac_objext \
43231     conftest$ac_exeext conftest.$ac_ext
43232 LIBS=$ac_check_lib_save_LIBS
43233 fi
43234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
43235 $as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; }
43236 if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then :
43237   X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
43238 fi
43239 
43240   LDFLAGS=$ac_save_LDFLAGS
43241 
43242 fi
43243 
43244 
43245   # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling
43246   # this doesn't make sense so we remove it.
43247   if test "x$COMPILE_TYPE" = xcross; then
43248     X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'`
43249   fi
43250 
43251   if test "x$no_x" = xyes && test "x$X11_NOT_NEEDED" != xyes; then
43252 
43253   # Print a helpful message on how to acquire the necessary build dependency.
43254   # x11 is the help tag: freetype, cups, pulse, alsa etc
43255   MISSING_DEPENDENCY=x11
43256 
43257   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43258     cygwin_help $MISSING_DEPENDENCY
43259   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43260     msys_help $MISSING_DEPENDENCY
43261   else
43262     PKGHANDLER_COMMAND=
43263 
43264     case $PKGHANDLER in
43265       apt-get)
43266         apt_help     $MISSING_DEPENDENCY ;;
43267       yum)
43268         yum_help     $MISSING_DEPENDENCY ;;
43269       port)
43270         port_help    $MISSING_DEPENDENCY ;;
43271       pkgutil)
43272         pkgutil_help $MISSING_DEPENDENCY ;;
43273       pkgadd)
43274         pkgadd_help  $MISSING_DEPENDENCY ;;
43275     esac
43276 
43277     if test "x$PKGHANDLER_COMMAND" != x; then
43278       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
43279     fi
43280   fi
43281 
43282     as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5
43283   fi
43284 
43285   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
43286     OPENWIN_HOME="/usr/openwin"
43287   fi
43288 
43289 
43290 
43291   #
43292   # Weird Sol10 something check...TODO change to try compile
43293   #
43294   if test "x${OPENJDK_TARGET_OS}" = xsolaris; then
43295     if test "`uname -r`" = "5.10"; then
43296       if test "`${EGREP} -c XLinearGradient ${OPENWIN_HOME}/share/include/X11/extensions/Xrender.h`" = "0"; then
43297         X_CFLAGS="${X_CFLAGS} -DSOLARIS10_NO_XRENDER_STRUCTS"
43298       fi
43299     fi
43300   fi
43301 
43302   ac_ext=c
43303 ac_cpp='$CPP $CPPFLAGS'
43304 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
43305 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
43306 ac_compiler_gnu=$ac_cv_c_compiler_gnu
43307 
43308   OLD_CFLAGS="$CFLAGS"
43309   CFLAGS="$CFLAGS $X_CFLAGS"
43310 
43311   # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10
43312   for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h X11/Intrinsic.h
43313 do :
43314   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
43315 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
43316         # include <X11/Xlib.h>
43317         # include <X11/Xutil.h>
43318 
43319 
43320 "
43321 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
43322   cat >>confdefs.h <<_ACEOF
43323 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
43324 _ACEOF
43325  X11_A_OK=yes
43326 else
43327   X11_A_OK=no; break
43328 fi
43329 
43330 done
43331 
43332 
43333   CFLAGS="$OLD_CFLAGS"
43334   ac_ext=cpp
43335 ac_cpp='$CXXCPP $CPPFLAGS'
43336 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
43337 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
43338 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
43339 
43340 
43341   if test "x$X11_A_OK" = xno && test "x$X11_NOT_NEEDED" != xyes; then
43342 
43343   # Print a helpful message on how to acquire the necessary build dependency.
43344   # x11 is the help tag: freetype, cups, pulse, alsa etc
43345   MISSING_DEPENDENCY=x11
43346 
43347   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43348     cygwin_help $MISSING_DEPENDENCY
43349   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43350     msys_help $MISSING_DEPENDENCY
43351   else
43352     PKGHANDLER_COMMAND=
43353 
43354     case $PKGHANDLER in
43355       apt-get)
43356         apt_help     $MISSING_DEPENDENCY ;;
43357       yum)
43358         yum_help     $MISSING_DEPENDENCY ;;
43359       port)
43360         port_help    $MISSING_DEPENDENCY ;;
43361       pkgutil)
43362         pkgutil_help $MISSING_DEPENDENCY ;;
43363       pkgadd)
43364         pkgadd_help  $MISSING_DEPENDENCY ;;
43365     esac
43366 
43367     if test "x$PKGHANDLER_COMMAND" != x; then
43368       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
43369     fi
43370   fi
43371 
43372     as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h Intrinsic.h). $HELP_MSG" "$LINENO" 5
43373   fi
43374 
43375 
43376 
43377 
43378 
43379 
43380   ###############################################################################
43381   #
43382   # The common unix printing system cups is used to print from java.
43383   #
43384 
43385 # Check whether --with-cups was given.
43386 if test "${with_cups+set}" = set; then :
43387   withval=$with_cups;
43388 fi
43389 
43390 
43391 # Check whether --with-cups-include was given.
43392 if test "${with_cups_include+set}" = set; then :
43393   withval=$with_cups_include;
43394 fi
43395 
43396 
43397   if test "x$CUPS_NOT_NEEDED" = xyes; then
43398     if test "x${with_cups}" != x || test "x${with_cups_include}" != x; then
43399       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups is ignored" >&5
43400 $as_echo "$as_me: WARNING: cups not used, so --with-cups is ignored" >&2;}
43401     fi
43402     CUPS_CFLAGS=
43403   else
43404     CUPS_FOUND=no
43405 
43406     if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then
43407       as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5
43408     fi
43409 
43410     if test "x${with_cups}" != x; then
43411       CUPS_CFLAGS="-I${with_cups}/include"
43412       CUPS_FOUND=yes
43413     fi
43414     if test "x${with_cups_include}" != x; then
43415       CUPS_CFLAGS="-I${with_cups_include}"
43416       CUPS_FOUND=yes
43417     fi
43418     if test "x$CUPS_FOUND" = xno; then
43419 
43420 
43421   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
43422     # Source the builddeps file again, to make sure it uses the latest variables!
43423     . $builddepsfile
43424     # Look for a target and build machine specific resource!
43425     eval resource=\${builddep_cups_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
43426     if test "x$resource" = x; then
43427       # Ok, lets instead look for a target specific resource
43428       eval resource=\${builddep_cups_TARGET_${rewritten_target_var}}
43429     fi
43430     if test "x$resource" = x; then
43431       # Ok, lets instead look for a build specific resource
43432       eval resource=\${builddep_cups_BUILD_${rewritten_build_var}}
43433     fi
43434     if test "x$resource" = x; then
43435       # Ok, lets instead look for a generic resource
43436       # (The cups comes from M4 and not the shell, thus no need for eval here.)
43437       resource=${builddep_cups}
43438     fi
43439     if test "x$resource" != x; then
43440       { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for cups" >&5
43441 $as_echo "$as_me: Using builddeps $resource for cups" >&6;}
43442       # If the resource in the builddeps.conf file is an existing directory,
43443       # for example /java/linux/cups
43444       if test -d ${resource}; then
43445         depdir=${resource}
43446       else
43447 
43448   # cups is for example mymodule
43449   # $resource is for example libs/general/libmymod_1_2_3.zip
43450   # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
43451   # $with_builddeps_dir is for example /localhome/builddeps
43452   # depdir is the name of the variable into which we store the depdir, eg MYMOD
43453   # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
43454   # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
43455   filename=`basename $resource`
43456   filebase=`echo $filename | sed 's/\.[^\.]*$//'`
43457   filebase=${filename%%.*}
43458   extension=${filename#*.}
43459   installdir=$with_builddeps_dir/$filebase
43460   if test ! -f $installdir/$filename.unpacked; then
43461     { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency cups from $with_builddeps_server/$resource and installing into $installdir" >&5
43462 $as_echo "$as_me: Downloading build dependency cups from $with_builddeps_server/$resource and installing into $installdir" >&6;}
43463     if test ! -d $installdir; then
43464       mkdir -p $installdir
43465     fi
43466     if test ! -d $installdir; then
43467       as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
43468     fi
43469     tmpfile=`mktemp $installdir/cups.XXXXXXXXX`
43470     touch $tmpfile
43471     if test ! -f $tmpfile; then
43472       as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
43473     fi
43474 
43475   # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
43476   # $tmpfile is the local file name for the downloaded file.
43477   VALID_TOOL=no
43478   if test "x$BDEPS_FTP" = xwget; then
43479     VALID_TOOL=yes
43480     wget -O $tmpfile $with_builddeps_server/$resource
43481   fi
43482   if test "x$BDEPS_FTP" = xlftp; then
43483     VALID_TOOL=yes
43484     lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
43485   fi
43486   if test "x$BDEPS_FTP" = xftp; then
43487     VALID_TOOL=yes
43488     FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
43489     FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
43490     FTPUSERPWD=${FTPSERVER%%@*}
43491     if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
43492       FTPUSER=${userpwd%%:*}
43493       FTPPWD=${userpwd#*@}
43494       FTPSERVER=${FTPSERVER#*@}
43495     else
43496       FTPUSER=ftp
43497       FTPPWD=ftp
43498     fi
43499     # the "pass" command does not work on some
43500     # ftp clients (read ftp.exe) but if it works,
43501     # passive mode is better!
43502     ( \
43503         echo "user $FTPUSER $FTPPWD"        ; \
43504         echo "pass"                         ; \
43505         echo "bin"                          ; \
43506         echo "get $FTPPATH $tmpfile"              ; \
43507     ) | ftp -in $FTPSERVER
43508   fi
43509   if test "x$VALID_TOOL" != xyes; then
43510     as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
43511   fi
43512 
43513     mv $tmpfile $installdir/$filename
43514     if test ! -s $installdir/$filename; then
43515       as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
43516     fi
43517     case "$extension" in
43518       zip)  echo "Unzipping $installdir/$filename..."
43519         (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
43520         ;;
43521       tar.gz) echo "Untaring $installdir/$filename..."
43522         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43523         ;;
43524       tgz) echo "Untaring $installdir/$filename..."
43525         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
43526         ;;
43527       *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
43528         ;;
43529     esac
43530   fi
43531   if test -f $installdir/$filename.unpacked; then
43532     depdir=$installdir
43533   fi
43534 
43535       fi
43536       # Source the builddeps file again, because in the previous command, the depdir
43537       # was updated to point at the current build dependency install directory.
43538       . $builddepsfile
43539       # Now extract variables from the builddeps.conf files.
43540       theroot=${builddep_cups_ROOT}
43541       thecflags=${builddep_cups_CFLAGS}
43542       thelibs=${builddep_cups_LIBS}
43543       if test "x$depdir" = x; then
43544         as_fn_error $? "Could not download build dependency cups" "$LINENO" 5
43545       fi
43546       CUPS=$depdir
43547       if test "x$theroot" != x; then
43548         CUPS="$theroot"
43549       fi
43550       if test "x$thecflags" != x; then
43551         CUPS_CFLAGS="$thecflags"
43552       fi
43553       if test "x$thelibs" != x; then
43554         CUPS_LIBS="$thelibs"
43555       fi
43556       CUPS_FOUND=yes
43557 
43558     fi
43559 
43560   fi
43561 
43562     fi
43563     if test "x$CUPS_FOUND" = xno; then
43564       # Are the cups headers installed in the default /usr/include location?
43565       for ac_header in cups/cups.h cups/ppd.h
43566 do :
43567   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
43568 ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
43569 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
43570   cat >>confdefs.h <<_ACEOF
43571 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
43572 _ACEOF
43573 
43574             CUPS_FOUND=yes
43575             CUPS_CFLAGS=
43576             DEFAULT_CUPS=yes
43577 
43578 
43579 fi
43580 
43581 done
43582 
43583     fi
43584     if test "x$CUPS_FOUND" = xno; then
43585       # Getting nervous now? Lets poke around for standard Solaris third-party
43586       # package installation locations.
43587       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5
43588 $as_echo_n "checking for cups headers... " >&6; }
43589       if test -s /opt/sfw/cups/include/cups/cups.h; then
43590         # An SFW package seems to be installed!
43591         CUPS_FOUND=yes
43592         CUPS_CFLAGS="-I/opt/sfw/cups/include"
43593       elif test -s /opt/csw/include/cups/cups.h; then
43594         # A CSW package seems to be installed!
43595         CUPS_FOUND=yes
43596         CUPS_CFLAGS="-I/opt/csw/include"
43597       fi
43598       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5
43599 $as_echo "$CUPS_FOUND" >&6; }
43600     fi
43601     if test "x$CUPS_FOUND" = xno; then
43602 
43603   # Print a helpful message on how to acquire the necessary build dependency.
43604   # cups is the help tag: freetype, cups, pulse, alsa etc
43605   MISSING_DEPENDENCY=cups
43606 
43607   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43608     cygwin_help $MISSING_DEPENDENCY
43609   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43610     msys_help $MISSING_DEPENDENCY
43611   else
43612     PKGHANDLER_COMMAND=
43613 
43614     case $PKGHANDLER in
43615       apt-get)
43616         apt_help     $MISSING_DEPENDENCY ;;
43617       yum)
43618         yum_help     $MISSING_DEPENDENCY ;;
43619       port)
43620         port_help    $MISSING_DEPENDENCY ;;
43621       pkgutil)
43622         pkgutil_help $MISSING_DEPENDENCY ;;
43623       pkgadd)
43624         pkgadd_help  $MISSING_DEPENDENCY ;;
43625     esac
43626 
43627     if test "x$PKGHANDLER_COMMAND" != x; then
43628       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
43629     fi
43630   fi
43631 
43632       as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5
43633     fi
43634   fi
43635 
43636 
43637 
43638 
43639 
43640 
43641   ###############################################################################
43642   #
43643   # The ubiquitous freetype library is used to render fonts.
43644   #
43645 
43646 # Check whether --with-freetype was given.
43647 if test "${with_freetype+set}" = set; then :
43648   withval=$with_freetype;
43649 fi
43650 
43651 
43652 # Check whether --with-freetype-include was given.
43653 if test "${with_freetype_include+set}" = set; then :
43654   withval=$with_freetype_include;
43655 fi
43656 
43657 
43658 # Check whether --with-freetype-lib was given.
43659 if test "${with_freetype_lib+set}" = set; then :
43660   withval=$with_freetype_lib;
43661 fi
43662 
43663   # Check whether --enable-freetype-bundling was given.
43664 if test "${enable_freetype_bundling+set}" = set; then :
43665   enableval=$enable_freetype_bundling;
43666 fi
43667 
43668 
43669   FREETYPE_CFLAGS=
43670   FREETYPE_LIBS=
43671   FREETYPE_BUNDLE_LIB_PATH=
43672 
43673   if test "x$FREETYPE_NOT_NEEDED" = xyes; then
43674     if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then
43675       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype is ignored" >&5
43676 $as_echo "$as_me: WARNING: freetype not used, so --with-freetype is ignored" >&2;}
43677     fi
43678     if test "x$enable_freetype_bundling" != x; then
43679       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&5
43680 $as_echo "$as_me: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&2;}
43681     fi
43682   else
43683     # freetype is needed to build; go get it!
43684 
43685     BUNDLE_FREETYPE="$enable_freetype_bundling"
43686 
43687     if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then
43688       # User has specified settings
43689 
43690       if test "x$BUNDLE_FREETYPE" = x; then
43691         # If not specified, default is to bundle freetype
43692         BUNDLE_FREETYPE=yes
43693       fi
43694 
43695       if test "x$with_freetype" != x; then
43696         POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype/include"
43697         POTENTIAL_FREETYPE_LIB_PATH="$with_freetype/lib"
43698       fi
43699 
43700       # Allow --with-freetype-lib and --with-freetype-include to override
43701       if test "x$with_freetype_include" != x; then
43702         POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype_include"
43703       fi
43704       if test "x$with_freetype_lib" != x; then
43705         POTENTIAL_FREETYPE_LIB_PATH="$with_freetype_lib"
43706       fi
43707 
43708       if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x && test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then
43709         # Okay, we got it. Check that it works.
43710 
43711   POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43712   POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
43713   METHOD="--with-freetype"
43714 
43715   # First check if the files exists.
43716   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
43717     # We found an arbitrary include file. That's a good sign.
43718     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
43719 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
43720     FOUND_FREETYPE=yes
43721 
43722     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
43723     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
43724       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
43725 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
43726       FOUND_FREETYPE=no
43727     else
43728       if test "x$OPENJDK_TARGET_OS" = xwindows; then
43729         # On Windows, we will need both .lib and .dll file.
43730         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
43731           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
43732 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
43733           FOUND_FREETYPE=no
43734         fi
43735       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
43736         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
43737         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
43738       fi
43739     fi
43740   fi
43741 
43742   if test "x$FOUND_FREETYPE" = xyes; then
43743 
43744   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43745 
43746   # Input might be given as Windows format, start by converting to
43747   # unix format.
43748   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43749   new_path=`$CYGPATH -u "$path"`
43750 
43751   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
43752   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
43753   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
43754   # "foo.exe" is OK but "foo" is an error.
43755   #
43756   # This test is therefore slightly more accurate than "test -f" to check for file precense.
43757   # It is also a way to make sure we got the proper file name for the real test later on.
43758   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
43759   if test "x$test_shortpath" = x; then
43760     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
43761 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
43762     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
43763   fi
43764 
43765   # Call helper function which possibly converts this using DOS-style short mode.
43766   # If so, the updated path is stored in $new_path.
43767 
43768   input_path="$new_path"
43769   # Check if we need to convert this using DOS-style short mode. If the path
43770   # contains just simple characters, use it. Otherwise (spaces, weird characters),
43771   # take no chances and rewrite it.
43772   # Note: m4 eats our [], so we need to use [ and ] instead.
43773   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
43774   if test "x$has_forbidden_chars" != x; then
43775     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43776     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
43777     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
43778     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
43779       # Going to short mode and back again did indeed matter. Since short mode is
43780       # case insensitive, let's make it lowercase to improve readability.
43781       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43782       # Now convert it back to Unix-stile (cygpath)
43783       input_path=`$CYGPATH -u "$shortmode_path"`
43784       new_path="$input_path"
43785     fi
43786   fi
43787 
43788   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
43789   if test "x$test_cygdrive_prefix" = x; then
43790     # As a simple fix, exclude /usr/bin since it's not a real path.
43791     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
43792       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
43793       # a path prefixed by /cygdrive for fixpath to work.
43794       new_path="$CYGWIN_ROOT_PATH$input_path"
43795     fi
43796   fi
43797 
43798 
43799   if test "x$path" != "x$new_path"; then
43800     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
43801     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
43802 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
43803   fi
43804 
43805   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43806 
43807   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43808   has_colon=`$ECHO $path | $GREP ^.:`
43809   new_path="$path"
43810   if test "x$has_colon" = x; then
43811     # Not in mixed or Windows style, start by that.
43812     new_path=`cmd //c echo $path`
43813   fi
43814 
43815 
43816   input_path="$new_path"
43817   # Check if we need to convert this using DOS-style short mode. If the path
43818   # contains just simple characters, use it. Otherwise (spaces, weird characters),
43819   # take no chances and rewrite it.
43820   # Note: m4 eats our [], so we need to use [ and ] instead.
43821   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
43822   if test "x$has_forbidden_chars" != x; then
43823     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43824     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43825   fi
43826 
43827 
43828   windows_path="$new_path"
43829   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43830     unix_path=`$CYGPATH -u "$windows_path"`
43831     new_path="$unix_path"
43832   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43833     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
43834     new_path="$unix_path"
43835   fi
43836 
43837   if test "x$path" != "x$new_path"; then
43838     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
43839     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
43840 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
43841   fi
43842 
43843   # Save the first 10 bytes of this path to the storage, so fixpath can work.
43844   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
43845 
43846   else
43847     # We're on a posix platform. Hooray! :)
43848     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43849     has_space=`$ECHO "$path" | $GREP " "`
43850     if test "x$has_space" != x; then
43851       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
43852 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
43853       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
43854     fi
43855 
43856     # Use eval to expand a potential ~
43857     eval path="$path"
43858     if test ! -f "$path" && test ! -d "$path"; then
43859       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
43860     fi
43861 
43862     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
43863   fi
43864 
43865 
43866   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43867 
43868   # Input might be given as Windows format, start by converting to
43869   # unix format.
43870   path="$POTENTIAL_FREETYPE_LIB_PATH"
43871   new_path=`$CYGPATH -u "$path"`
43872 
43873   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
43874   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
43875   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
43876   # "foo.exe" is OK but "foo" is an error.
43877   #
43878   # This test is therefore slightly more accurate than "test -f" to check for file precense.
43879   # It is also a way to make sure we got the proper file name for the real test later on.
43880   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
43881   if test "x$test_shortpath" = x; then
43882     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
43883 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
43884     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
43885   fi
43886 
43887   # Call helper function which possibly converts this using DOS-style short mode.
43888   # If so, the updated path is stored in $new_path.
43889 
43890   input_path="$new_path"
43891   # Check if we need to convert this using DOS-style short mode. If the path
43892   # contains just simple characters, use it. Otherwise (spaces, weird characters),
43893   # take no chances and rewrite it.
43894   # Note: m4 eats our [], so we need to use [ and ] instead.
43895   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
43896   if test "x$has_forbidden_chars" != x; then
43897     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43898     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
43899     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
43900     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
43901       # Going to short mode and back again did indeed matter. Since short mode is
43902       # case insensitive, let's make it lowercase to improve readability.
43903       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43904       # Now convert it back to Unix-stile (cygpath)
43905       input_path=`$CYGPATH -u "$shortmode_path"`
43906       new_path="$input_path"
43907     fi
43908   fi
43909 
43910   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
43911   if test "x$test_cygdrive_prefix" = x; then
43912     # As a simple fix, exclude /usr/bin since it's not a real path.
43913     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
43914       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
43915       # a path prefixed by /cygdrive for fixpath to work.
43916       new_path="$CYGWIN_ROOT_PATH$input_path"
43917     fi
43918   fi
43919 
43920 
43921   if test "x$path" != "x$new_path"; then
43922     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
43923     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
43924 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
43925   fi
43926 
43927   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43928 
43929   path="$POTENTIAL_FREETYPE_LIB_PATH"
43930   has_colon=`$ECHO $path | $GREP ^.:`
43931   new_path="$path"
43932   if test "x$has_colon" = x; then
43933     # Not in mixed or Windows style, start by that.
43934     new_path=`cmd //c echo $path`
43935   fi
43936 
43937 
43938   input_path="$new_path"
43939   # Check if we need to convert this using DOS-style short mode. If the path
43940   # contains just simple characters, use it. Otherwise (spaces, weird characters),
43941   # take no chances and rewrite it.
43942   # Note: m4 eats our [], so we need to use [ and ] instead.
43943   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
43944   if test "x$has_forbidden_chars" != x; then
43945     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
43946     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
43947   fi
43948 
43949 
43950   windows_path="$new_path"
43951   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43952     unix_path=`$CYGPATH -u "$windows_path"`
43953     new_path="$unix_path"
43954   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43955     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
43956     new_path="$unix_path"
43957   fi
43958 
43959   if test "x$path" != "x$new_path"; then
43960     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
43961     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
43962 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
43963   fi
43964 
43965   # Save the first 10 bytes of this path to the storage, so fixpath can work.
43966   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
43967 
43968   else
43969     # We're on a posix platform. Hooray! :)
43970     path="$POTENTIAL_FREETYPE_LIB_PATH"
43971     has_space=`$ECHO "$path" | $GREP " "`
43972     if test "x$has_space" != x; then
43973       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
43974 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
43975       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
43976     fi
43977 
43978     # Use eval to expand a potential ~
43979     eval path="$path"
43980     if test ! -f "$path" && test ! -d "$path"; then
43981       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
43982     fi
43983 
43984     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
43985   fi
43986 
43987 
43988     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
43989     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
43990 $as_echo_n "checking for freetype includes... " >&6; }
43991     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
43992 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
43993     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
43994     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
43995 $as_echo_n "checking for freetype libraries... " >&6; }
43996     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
43997 $as_echo "$FREETYPE_LIB_PATH" >&6; }
43998   fi
43999 
44000         if test "x$FOUND_FREETYPE" != xyes; then
44001           as_fn_error $? "Can not find or use freetype at location given by --with-freetype" "$LINENO" 5
44002         fi
44003       else
44004         # User specified only one of lib or include. This is an error.
44005         if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" = x ; then
44006           { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-lib but not --with-freetype-include" >&5
44007 $as_echo "$as_me: User specified --with-freetype-lib but not --with-freetype-include" >&6;}
44008           as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5
44009         else
44010           { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-include but not --with-freetype-lib" >&5
44011 $as_echo "$as_me: User specified --with-freetype-include but not --with-freetype-lib" >&6;}
44012           as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5
44013         fi
44014       fi
44015     else
44016       # User did not specify settings, but we need freetype. Try to locate it.
44017 
44018       if test "x$BUNDLE_FREETYPE" = x; then
44019         # If not specified, default is to bundle freetype only on windows
44020         if test "x$OPENJDK_TARGET_OS" = xwindows; then
44021           BUNDLE_FREETYPE=yes
44022         else
44023           BUNDLE_FREETYPE=no
44024         fi
44025       fi
44026 
44027       if test "x$FOUND_FREETYPE" != xyes; then
44028         # Check builddeps
44029 
44030 
44031   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
44032     # Source the builddeps file again, to make sure it uses the latest variables!
44033     . $builddepsfile
44034     # Look for a target and build machine specific resource!
44035     eval resource=\${builddep_freetype2_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
44036     if test "x$resource" = x; then
44037       # Ok, lets instead look for a target specific resource
44038       eval resource=\${builddep_freetype2_TARGET_${rewritten_target_var}}
44039     fi
44040     if test "x$resource" = x; then
44041       # Ok, lets instead look for a build specific resource
44042       eval resource=\${builddep_freetype2_BUILD_${rewritten_build_var}}
44043     fi
44044     if test "x$resource" = x; then
44045       # Ok, lets instead look for a generic resource
44046       # (The freetype2 comes from M4 and not the shell, thus no need for eval here.)
44047       resource=${builddep_freetype2}
44048     fi
44049     if test "x$resource" != x; then
44050       { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for freetype2" >&5
44051 $as_echo "$as_me: Using builddeps $resource for freetype2" >&6;}
44052       # If the resource in the builddeps.conf file is an existing directory,
44053       # for example /java/linux/cups
44054       if test -d ${resource}; then
44055         depdir=${resource}
44056       else
44057 
44058   # freetype2 is for example mymodule
44059   # $resource is for example libs/general/libmymod_1_2_3.zip
44060   # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
44061   # $with_builddeps_dir is for example /localhome/builddeps
44062   # depdir is the name of the variable into which we store the depdir, eg MYMOD
44063   # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
44064   # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
44065   filename=`basename $resource`
44066   filebase=`echo $filename | sed 's/\.[^\.]*$//'`
44067   filebase=${filename%%.*}
44068   extension=${filename#*.}
44069   installdir=$with_builddeps_dir/$filebase
44070   if test ! -f $installdir/$filename.unpacked; then
44071     { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency freetype2 from $with_builddeps_server/$resource and installing into $installdir" >&5
44072 $as_echo "$as_me: Downloading build dependency freetype2 from $with_builddeps_server/$resource and installing into $installdir" >&6;}
44073     if test ! -d $installdir; then
44074       mkdir -p $installdir
44075     fi
44076     if test ! -d $installdir; then
44077       as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
44078     fi
44079     tmpfile=`mktemp $installdir/freetype2.XXXXXXXXX`
44080     touch $tmpfile
44081     if test ! -f $tmpfile; then
44082       as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
44083     fi
44084 
44085   # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
44086   # $tmpfile is the local file name for the downloaded file.
44087   VALID_TOOL=no
44088   if test "x$BDEPS_FTP" = xwget; then
44089     VALID_TOOL=yes
44090     wget -O $tmpfile $with_builddeps_server/$resource
44091   fi
44092   if test "x$BDEPS_FTP" = xlftp; then
44093     VALID_TOOL=yes
44094     lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
44095   fi
44096   if test "x$BDEPS_FTP" = xftp; then
44097     VALID_TOOL=yes
44098     FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
44099     FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
44100     FTPUSERPWD=${FTPSERVER%%@*}
44101     if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
44102       FTPUSER=${userpwd%%:*}
44103       FTPPWD=${userpwd#*@}
44104       FTPSERVER=${FTPSERVER#*@}
44105     else
44106       FTPUSER=ftp
44107       FTPPWD=ftp
44108     fi
44109     # the "pass" command does not work on some
44110     # ftp clients (read ftp.exe) but if it works,
44111     # passive mode is better!
44112     ( \
44113         echo "user $FTPUSER $FTPPWD"        ; \
44114         echo "pass"                         ; \
44115         echo "bin"                          ; \
44116         echo "get $FTPPATH $tmpfile"              ; \
44117     ) | ftp -in $FTPSERVER
44118   fi
44119   if test "x$VALID_TOOL" != xyes; then
44120     as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
44121   fi
44122 
44123     mv $tmpfile $installdir/$filename
44124     if test ! -s $installdir/$filename; then
44125       as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
44126     fi
44127     case "$extension" in
44128       zip)  echo "Unzipping $installdir/$filename..."
44129         (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
44130         ;;
44131       tar.gz) echo "Untaring $installdir/$filename..."
44132         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
44133         ;;
44134       tgz) echo "Untaring $installdir/$filename..."
44135         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
44136         ;;
44137       *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
44138         ;;
44139     esac
44140   fi
44141   if test -f $installdir/$filename.unpacked; then
44142     depdir=$installdir
44143   fi
44144 
44145       fi
44146       # Source the builddeps file again, because in the previous command, the depdir
44147       # was updated to point at the current build dependency install directory.
44148       . $builddepsfile
44149       # Now extract variables from the builddeps.conf files.
44150       theroot=${builddep_freetype2_ROOT}
44151       thecflags=${builddep_freetype2_CFLAGS}
44152       thelibs=${builddep_freetype2_LIBS}
44153       if test "x$depdir" = x; then
44154         as_fn_error $? "Could not download build dependency freetype2" "$LINENO" 5
44155       fi
44156       FREETYPE=$depdir
44157       if test "x$theroot" != x; then
44158         FREETYPE="$theroot"
44159       fi
44160       if test "x$thecflags" != x; then
44161         FREETYPE_CFLAGS="$thecflags"
44162       fi
44163       if test "x$thelibs" != x; then
44164         FREETYPE_LIBS="$thelibs"
44165       fi
44166       FOUND_FREETYPE=yes
44167       else FOUND_FREETYPE=no
44168 
44169     fi
44170     else FOUND_FREETYPE=no
44171 
44172   fi
44173 
44174         # BDEPS_CHECK_MODULE will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling.
44175         if test "x$FOUND_FREETYPE" = xyes; then
44176           if test "x$BUNDLE_FREETYPE" = xyes; then
44177             { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using builddeps, but ignoring since we can not bundle that" >&5
44178 $as_echo "$as_me: Found freetype using builddeps, but ignoring since we can not bundle that" >&6;}
44179             FOUND_FREETYPE=no
44180           else
44181             { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5
44182 $as_echo_n "checking for freetype... " >&6; }
44183             { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using builddeps)" >&5
44184 $as_echo "yes (using builddeps)" >&6; }
44185           fi
44186         fi
44187       fi
44188 
44189       if test "x$FOUND_FREETYPE" != xyes; then
44190         # Check modules using pkg-config, but only if we have it (ugly output results otherwise)
44191         if test "x$PKG_CONFIG" != x; then
44192 
44193 pkg_failed=no
44194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5
44195 $as_echo_n "checking for FREETYPE... " >&6; }
44196 
44197 if test -n "$FREETYPE_CFLAGS"; then
44198     pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS"
44199  elif test -n "$PKG_CONFIG"; then
44200     if test -n "$PKG_CONFIG" && \
44201     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5
44202   ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5
44203   ac_status=$?
44204   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
44205   test $ac_status = 0; }; then
44206   pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null`
44207 else
44208   pkg_failed=yes
44209 fi
44210  else
44211     pkg_failed=untried
44212 fi
44213 if test -n "$FREETYPE_LIBS"; then
44214     pkg_cv_FREETYPE_LIBS="$FREETYPE_LIBS"
44215  elif test -n "$PKG_CONFIG"; then
44216     if test -n "$PKG_CONFIG" && \
44217     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5
44218   ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5
44219   ac_status=$?
44220   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
44221   test $ac_status = 0; }; then
44222   pkg_cv_FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null`
44223 else
44224   pkg_failed=yes
44225 fi
44226  else
44227     pkg_failed=untried
44228 fi
44229 
44230 
44231 
44232 if test $pkg_failed = yes; then
44233 
44234 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
44235         _pkg_short_errors_supported=yes
44236 else
44237         _pkg_short_errors_supported=no
44238 fi
44239         if test $_pkg_short_errors_supported = yes; then
44240                 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1`
44241         else
44242                 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1`
44243         fi
44244         # Put the nasty error message in config.log where it belongs
44245         echo "$FREETYPE_PKG_ERRORS" >&5
44246 
44247         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
44248 $as_echo "no" >&6; }
44249                 FOUND_FREETYPE=no
44250 elif test $pkg_failed = untried; then
44251         FOUND_FREETYPE=no
44252 else
44253         FREETYPE_CFLAGS=$pkg_cv_FREETYPE_CFLAGS
44254         FREETYPE_LIBS=$pkg_cv_FREETYPE_LIBS
44255         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
44256 $as_echo "yes" >&6; }
44257         FOUND_FREETYPE=yes
44258 fi
44259           if test "x$FOUND_FREETYPE" = xyes; then
44260             # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us.
44261             FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'`
44262             # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64
44263             if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
44264               FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'`
44265             fi
44266             # BDEPS_CHECK_MODULE will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling.
44267             if test "x$BUNDLE_FREETYPE" = xyes; then
44268               { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5
44269 $as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;}
44270               FOUND_FREETYPE=no
44271             else
44272               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5
44273 $as_echo_n "checking for freetype... " >&6; }
44274               { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5
44275 $as_echo "yes (using pkg-config)" >&6; }
44276             fi
44277           fi
44278         fi
44279       fi
44280 
44281       if test "x$FOUND_FREETYPE" != xyes; then
44282         # Check in well-known locations
44283         if test "x$OPENJDK_TARGET_OS" = xwindows; then
44284           FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32"
44285 
44286   windows_path="$FREETYPE_BASE_DIR"
44287   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44288     unix_path=`$CYGPATH -u "$windows_path"`
44289     FREETYPE_BASE_DIR="$unix_path"
44290   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44291     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44292     FREETYPE_BASE_DIR="$unix_path"
44293   fi
44294 
44295 
44296   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44297   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44298   METHOD="well-known location"
44299 
44300   # First check if the files exists.
44301   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44302     # We found an arbitrary include file. That's a good sign.
44303     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44304 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44305     FOUND_FREETYPE=yes
44306 
44307     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44308     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44309       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44310 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44311       FOUND_FREETYPE=no
44312     else
44313       if test "x$OPENJDK_TARGET_OS" = xwindows; then
44314         # On Windows, we will need both .lib and .dll file.
44315         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44316           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44317 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44318           FOUND_FREETYPE=no
44319         fi
44320       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
44321         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44322         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44323       fi
44324     fi
44325   fi
44326 
44327   if test "x$FOUND_FREETYPE" = xyes; then
44328 
44329   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44330 
44331   # Input might be given as Windows format, start by converting to
44332   # unix format.
44333   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44334   new_path=`$CYGPATH -u "$path"`
44335 
44336   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44337   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44338   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44339   # "foo.exe" is OK but "foo" is an error.
44340   #
44341   # This test is therefore slightly more accurate than "test -f" to check for file precense.
44342   # It is also a way to make sure we got the proper file name for the real test later on.
44343   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44344   if test "x$test_shortpath" = x; then
44345     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44346 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44347     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44348   fi
44349 
44350   # Call helper function which possibly converts this using DOS-style short mode.
44351   # If so, the updated path is stored in $new_path.
44352 
44353   input_path="$new_path"
44354   # Check if we need to convert this using DOS-style short mode. If the path
44355   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44356   # take no chances and rewrite it.
44357   # Note: m4 eats our [], so we need to use [ and ] instead.
44358   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44359   if test "x$has_forbidden_chars" != x; then
44360     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44361     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44362     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44363     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44364       # Going to short mode and back again did indeed matter. Since short mode is
44365       # case insensitive, let's make it lowercase to improve readability.
44366       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44367       # Now convert it back to Unix-stile (cygpath)
44368       input_path=`$CYGPATH -u "$shortmode_path"`
44369       new_path="$input_path"
44370     fi
44371   fi
44372 
44373   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44374   if test "x$test_cygdrive_prefix" = x; then
44375     # As a simple fix, exclude /usr/bin since it's not a real path.
44376     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44377       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44378       # a path prefixed by /cygdrive for fixpath to work.
44379       new_path="$CYGWIN_ROOT_PATH$input_path"
44380     fi
44381   fi
44382 
44383 
44384   if test "x$path" != "x$new_path"; then
44385     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44386     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44387 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44388   fi
44389 
44390   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44391 
44392   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44393   has_colon=`$ECHO $path | $GREP ^.:`
44394   new_path="$path"
44395   if test "x$has_colon" = x; then
44396     # Not in mixed or Windows style, start by that.
44397     new_path=`cmd //c echo $path`
44398   fi
44399 
44400 
44401   input_path="$new_path"
44402   # Check if we need to convert this using DOS-style short mode. If the path
44403   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44404   # take no chances and rewrite it.
44405   # Note: m4 eats our [], so we need to use [ and ] instead.
44406   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44407   if test "x$has_forbidden_chars" != x; then
44408     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44409     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44410   fi
44411 
44412 
44413   windows_path="$new_path"
44414   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44415     unix_path=`$CYGPATH -u "$windows_path"`
44416     new_path="$unix_path"
44417   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44418     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44419     new_path="$unix_path"
44420   fi
44421 
44422   if test "x$path" != "x$new_path"; then
44423     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44424     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44425 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44426   fi
44427 
44428   # Save the first 10 bytes of this path to the storage, so fixpath can work.
44429   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44430 
44431   else
44432     # We're on a posix platform. Hooray! :)
44433     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44434     has_space=`$ECHO "$path" | $GREP " "`
44435     if test "x$has_space" != x; then
44436       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44437 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44438       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44439     fi
44440 
44441     # Use eval to expand a potential ~
44442     eval path="$path"
44443     if test ! -f "$path" && test ! -d "$path"; then
44444       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44445     fi
44446 
44447     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44448   fi
44449 
44450 
44451   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44452 
44453   # Input might be given as Windows format, start by converting to
44454   # unix format.
44455   path="$POTENTIAL_FREETYPE_LIB_PATH"
44456   new_path=`$CYGPATH -u "$path"`
44457 
44458   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44459   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44460   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44461   # "foo.exe" is OK but "foo" is an error.
44462   #
44463   # This test is therefore slightly more accurate than "test -f" to check for file precense.
44464   # It is also a way to make sure we got the proper file name for the real test later on.
44465   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44466   if test "x$test_shortpath" = x; then
44467     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44468 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44469     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44470   fi
44471 
44472   # Call helper function which possibly converts this using DOS-style short mode.
44473   # If so, the updated path is stored in $new_path.
44474 
44475   input_path="$new_path"
44476   # Check if we need to convert this using DOS-style short mode. If the path
44477   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44478   # take no chances and rewrite it.
44479   # Note: m4 eats our [], so we need to use [ and ] instead.
44480   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44481   if test "x$has_forbidden_chars" != x; then
44482     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44483     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44484     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44485     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44486       # Going to short mode and back again did indeed matter. Since short mode is
44487       # case insensitive, let's make it lowercase to improve readability.
44488       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44489       # Now convert it back to Unix-stile (cygpath)
44490       input_path=`$CYGPATH -u "$shortmode_path"`
44491       new_path="$input_path"
44492     fi
44493   fi
44494 
44495   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44496   if test "x$test_cygdrive_prefix" = x; then
44497     # As a simple fix, exclude /usr/bin since it's not a real path.
44498     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44499       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44500       # a path prefixed by /cygdrive for fixpath to work.
44501       new_path="$CYGWIN_ROOT_PATH$input_path"
44502     fi
44503   fi
44504 
44505 
44506   if test "x$path" != "x$new_path"; then
44507     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44508     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44509 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44510   fi
44511 
44512   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44513 
44514   path="$POTENTIAL_FREETYPE_LIB_PATH"
44515   has_colon=`$ECHO $path | $GREP ^.:`
44516   new_path="$path"
44517   if test "x$has_colon" = x; then
44518     # Not in mixed or Windows style, start by that.
44519     new_path=`cmd //c echo $path`
44520   fi
44521 
44522 
44523   input_path="$new_path"
44524   # Check if we need to convert this using DOS-style short mode. If the path
44525   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44526   # take no chances and rewrite it.
44527   # Note: m4 eats our [], so we need to use [ and ] instead.
44528   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44529   if test "x$has_forbidden_chars" != x; then
44530     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44531     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44532   fi
44533 
44534 
44535   windows_path="$new_path"
44536   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44537     unix_path=`$CYGPATH -u "$windows_path"`
44538     new_path="$unix_path"
44539   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44540     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44541     new_path="$unix_path"
44542   fi
44543 
44544   if test "x$path" != "x$new_path"; then
44545     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44546     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44547 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44548   fi
44549 
44550   # Save the first 10 bytes of this path to the storage, so fixpath can work.
44551   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44552 
44553   else
44554     # We're on a posix platform. Hooray! :)
44555     path="$POTENTIAL_FREETYPE_LIB_PATH"
44556     has_space=`$ECHO "$path" | $GREP " "`
44557     if test "x$has_space" != x; then
44558       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44559 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44560       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44561     fi
44562 
44563     # Use eval to expand a potential ~
44564     eval path="$path"
44565     if test ! -f "$path" && test ! -d "$path"; then
44566       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44567     fi
44568 
44569     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44570   fi
44571 
44572 
44573     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44574     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44575 $as_echo_n "checking for freetype includes... " >&6; }
44576     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44577 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44578     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44579     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44580 $as_echo_n "checking for freetype libraries... " >&6; }
44581     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44582 $as_echo "$FREETYPE_LIB_PATH" >&6; }
44583   fi
44584 
44585           if test "x$FOUND_FREETYPE" != xyes; then
44586             FREETYPE_BASE_DIR="$ProgramW6432/GnuWin32"
44587 
44588   windows_path="$FREETYPE_BASE_DIR"
44589   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44590     unix_path=`$CYGPATH -u "$windows_path"`
44591     FREETYPE_BASE_DIR="$unix_path"
44592   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44593     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44594     FREETYPE_BASE_DIR="$unix_path"
44595   fi
44596 
44597 
44598   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44599   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44600   METHOD="well-known location"
44601 
44602   # First check if the files exists.
44603   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44604     # We found an arbitrary include file. That's a good sign.
44605     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44606 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44607     FOUND_FREETYPE=yes
44608 
44609     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44610     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44611       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44612 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44613       FOUND_FREETYPE=no
44614     else
44615       if test "x$OPENJDK_TARGET_OS" = xwindows; then
44616         # On Windows, we will need both .lib and .dll file.
44617         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44618           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44619 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44620           FOUND_FREETYPE=no
44621         fi
44622       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
44623         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44624         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44625       fi
44626     fi
44627   fi
44628 
44629   if test "x$FOUND_FREETYPE" = xyes; then
44630 
44631   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44632 
44633   # Input might be given as Windows format, start by converting to
44634   # unix format.
44635   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44636   new_path=`$CYGPATH -u "$path"`
44637 
44638   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44639   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44640   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44641   # "foo.exe" is OK but "foo" is an error.
44642   #
44643   # This test is therefore slightly more accurate than "test -f" to check for file precense.
44644   # It is also a way to make sure we got the proper file name for the real test later on.
44645   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44646   if test "x$test_shortpath" = x; then
44647     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44648 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44649     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44650   fi
44651 
44652   # Call helper function which possibly converts this using DOS-style short mode.
44653   # If so, the updated path is stored in $new_path.
44654 
44655   input_path="$new_path"
44656   # Check if we need to convert this using DOS-style short mode. If the path
44657   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44658   # take no chances and rewrite it.
44659   # Note: m4 eats our [], so we need to use [ and ] instead.
44660   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44661   if test "x$has_forbidden_chars" != x; then
44662     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44663     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44664     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44665     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44666       # Going to short mode and back again did indeed matter. Since short mode is
44667       # case insensitive, let's make it lowercase to improve readability.
44668       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44669       # Now convert it back to Unix-stile (cygpath)
44670       input_path=`$CYGPATH -u "$shortmode_path"`
44671       new_path="$input_path"
44672     fi
44673   fi
44674 
44675   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44676   if test "x$test_cygdrive_prefix" = x; then
44677     # As a simple fix, exclude /usr/bin since it's not a real path.
44678     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44679       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44680       # a path prefixed by /cygdrive for fixpath to work.
44681       new_path="$CYGWIN_ROOT_PATH$input_path"
44682     fi
44683   fi
44684 
44685 
44686   if test "x$path" != "x$new_path"; then
44687     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44688     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44689 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44690   fi
44691 
44692   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44693 
44694   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44695   has_colon=`$ECHO $path | $GREP ^.:`
44696   new_path="$path"
44697   if test "x$has_colon" = x; then
44698     # Not in mixed or Windows style, start by that.
44699     new_path=`cmd //c echo $path`
44700   fi
44701 
44702 
44703   input_path="$new_path"
44704   # Check if we need to convert this using DOS-style short mode. If the path
44705   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44706   # take no chances and rewrite it.
44707   # Note: m4 eats our [], so we need to use [ and ] instead.
44708   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44709   if test "x$has_forbidden_chars" != x; then
44710     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44711     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44712   fi
44713 
44714 
44715   windows_path="$new_path"
44716   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44717     unix_path=`$CYGPATH -u "$windows_path"`
44718     new_path="$unix_path"
44719   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44720     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44721     new_path="$unix_path"
44722   fi
44723 
44724   if test "x$path" != "x$new_path"; then
44725     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44726     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44727 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44728   fi
44729 
44730   # Save the first 10 bytes of this path to the storage, so fixpath can work.
44731   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44732 
44733   else
44734     # We're on a posix platform. Hooray! :)
44735     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44736     has_space=`$ECHO "$path" | $GREP " "`
44737     if test "x$has_space" != x; then
44738       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44739 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44740       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44741     fi
44742 
44743     # Use eval to expand a potential ~
44744     eval path="$path"
44745     if test ! -f "$path" && test ! -d "$path"; then
44746       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44747     fi
44748 
44749     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44750   fi
44751 
44752 
44753   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44754 
44755   # Input might be given as Windows format, start by converting to
44756   # unix format.
44757   path="$POTENTIAL_FREETYPE_LIB_PATH"
44758   new_path=`$CYGPATH -u "$path"`
44759 
44760   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44761   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44762   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44763   # "foo.exe" is OK but "foo" is an error.
44764   #
44765   # This test is therefore slightly more accurate than "test -f" to check for file precense.
44766   # It is also a way to make sure we got the proper file name for the real test later on.
44767   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44768   if test "x$test_shortpath" = x; then
44769     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44770 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44771     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44772   fi
44773 
44774   # Call helper function which possibly converts this using DOS-style short mode.
44775   # If so, the updated path is stored in $new_path.
44776 
44777   input_path="$new_path"
44778   # Check if we need to convert this using DOS-style short mode. If the path
44779   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44780   # take no chances and rewrite it.
44781   # Note: m4 eats our [], so we need to use [ and ] instead.
44782   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44783   if test "x$has_forbidden_chars" != x; then
44784     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44785     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44786     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44787     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44788       # Going to short mode and back again did indeed matter. Since short mode is
44789       # case insensitive, let's make it lowercase to improve readability.
44790       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44791       # Now convert it back to Unix-stile (cygpath)
44792       input_path=`$CYGPATH -u "$shortmode_path"`
44793       new_path="$input_path"
44794     fi
44795   fi
44796 
44797   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44798   if test "x$test_cygdrive_prefix" = x; then
44799     # As a simple fix, exclude /usr/bin since it's not a real path.
44800     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44801       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44802       # a path prefixed by /cygdrive for fixpath to work.
44803       new_path="$CYGWIN_ROOT_PATH$input_path"
44804     fi
44805   fi
44806 
44807 
44808   if test "x$path" != "x$new_path"; then
44809     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44810     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44811 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44812   fi
44813 
44814   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44815 
44816   path="$POTENTIAL_FREETYPE_LIB_PATH"
44817   has_colon=`$ECHO $path | $GREP ^.:`
44818   new_path="$path"
44819   if test "x$has_colon" = x; then
44820     # Not in mixed or Windows style, start by that.
44821     new_path=`cmd //c echo $path`
44822   fi
44823 
44824 
44825   input_path="$new_path"
44826   # Check if we need to convert this using DOS-style short mode. If the path
44827   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44828   # take no chances and rewrite it.
44829   # Note: m4 eats our [], so we need to use [ and ] instead.
44830   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44831   if test "x$has_forbidden_chars" != x; then
44832     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44833     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44834   fi
44835 
44836 
44837   windows_path="$new_path"
44838   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44839     unix_path=`$CYGPATH -u "$windows_path"`
44840     new_path="$unix_path"
44841   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44842     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44843     new_path="$unix_path"
44844   fi
44845 
44846   if test "x$path" != "x$new_path"; then
44847     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44848     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44849 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44850   fi
44851 
44852   # Save the first 10 bytes of this path to the storage, so fixpath can work.
44853   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44854 
44855   else
44856     # We're on a posix platform. Hooray! :)
44857     path="$POTENTIAL_FREETYPE_LIB_PATH"
44858     has_space=`$ECHO "$path" | $GREP " "`
44859     if test "x$has_space" != x; then
44860       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44861 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44862       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44863     fi
44864 
44865     # Use eval to expand a potential ~
44866     eval path="$path"
44867     if test ! -f "$path" && test ! -d "$path"; then
44868       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44869     fi
44870 
44871     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44872   fi
44873 
44874 
44875     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44876     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44877 $as_echo_n "checking for freetype includes... " >&6; }
44878     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44879 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44880     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44881     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44882 $as_echo_n "checking for freetype libraries... " >&6; }
44883     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44884 $as_echo "$FREETYPE_LIB_PATH" >&6; }
44885   fi
44886 
44887           fi
44888         else
44889           if test "x$SYS_ROOT" = "x/"; then
44890             FREETYPE_ROOT=
44891           else
44892             FREETYPE_ROOT="$SYS_ROOT"
44893           fi
44894           FREETYPE_BASE_DIR="$FREETYPE_ROOT/usr"
44895 
44896   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44897   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44898   METHOD="well-known location"
44899 
44900   # First check if the files exists.
44901   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44902     # We found an arbitrary include file. That's a good sign.
44903     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44904 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44905     FOUND_FREETYPE=yes
44906 
44907     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44908     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44909       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44910 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44911       FOUND_FREETYPE=no
44912     else
44913       if test "x$OPENJDK_TARGET_OS" = xwindows; then
44914         # On Windows, we will need both .lib and .dll file.
44915         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44916           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44917 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44918           FOUND_FREETYPE=no
44919         fi
44920       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
44921         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44922         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44923       fi
44924     fi
44925   fi
44926 
44927   if test "x$FOUND_FREETYPE" = xyes; then
44928 
44929   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44930 
44931   # Input might be given as Windows format, start by converting to
44932   # unix format.
44933   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44934   new_path=`$CYGPATH -u "$path"`
44935 
44936   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44937   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44938   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44939   # "foo.exe" is OK but "foo" is an error.
44940   #
44941   # This test is therefore slightly more accurate than "test -f" to check for file precense.
44942   # It is also a way to make sure we got the proper file name for the real test later on.
44943   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44944   if test "x$test_shortpath" = x; then
44945     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44946 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44947     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44948   fi
44949 
44950   # Call helper function which possibly converts this using DOS-style short mode.
44951   # If so, the updated path is stored in $new_path.
44952 
44953   input_path="$new_path"
44954   # Check if we need to convert this using DOS-style short mode. If the path
44955   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44956   # take no chances and rewrite it.
44957   # Note: m4 eats our [], so we need to use [ and ] instead.
44958   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44959   if test "x$has_forbidden_chars" != x; then
44960     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44961     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44962     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44963     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44964       # Going to short mode and back again did indeed matter. Since short mode is
44965       # case insensitive, let's make it lowercase to improve readability.
44966       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44967       # Now convert it back to Unix-stile (cygpath)
44968       input_path=`$CYGPATH -u "$shortmode_path"`
44969       new_path="$input_path"
44970     fi
44971   fi
44972 
44973   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44974   if test "x$test_cygdrive_prefix" = x; then
44975     # As a simple fix, exclude /usr/bin since it's not a real path.
44976     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44977       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44978       # a path prefixed by /cygdrive for fixpath to work.
44979       new_path="$CYGWIN_ROOT_PATH$input_path"
44980     fi
44981   fi
44982 
44983 
44984   if test "x$path" != "x$new_path"; then
44985     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44986     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44987 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44988   fi
44989 
44990   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44991 
44992   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44993   has_colon=`$ECHO $path | $GREP ^.:`
44994   new_path="$path"
44995   if test "x$has_colon" = x; then
44996     # Not in mixed or Windows style, start by that.
44997     new_path=`cmd //c echo $path`
44998   fi
44999 
45000 
45001   input_path="$new_path"
45002   # Check if we need to convert this using DOS-style short mode. If the path
45003   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45004   # take no chances and rewrite it.
45005   # Note: m4 eats our [], so we need to use [ and ] instead.
45006   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45007   if test "x$has_forbidden_chars" != x; then
45008     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45009     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45010   fi
45011 
45012 
45013   windows_path="$new_path"
45014   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45015     unix_path=`$CYGPATH -u "$windows_path"`
45016     new_path="$unix_path"
45017   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45018     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45019     new_path="$unix_path"
45020   fi
45021 
45022   if test "x$path" != "x$new_path"; then
45023     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45024     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45025 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45026   fi
45027 
45028   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45029   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45030 
45031   else
45032     # We're on a posix platform. Hooray! :)
45033     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45034     has_space=`$ECHO "$path" | $GREP " "`
45035     if test "x$has_space" != x; then
45036       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45037 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45038       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45039     fi
45040 
45041     # Use eval to expand a potential ~
45042     eval path="$path"
45043     if test ! -f "$path" && test ! -d "$path"; then
45044       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45045     fi
45046 
45047     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45048   fi
45049 
45050 
45051   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45052 
45053   # Input might be given as Windows format, start by converting to
45054   # unix format.
45055   path="$POTENTIAL_FREETYPE_LIB_PATH"
45056   new_path=`$CYGPATH -u "$path"`
45057 
45058   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45059   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45060   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45061   # "foo.exe" is OK but "foo" is an error.
45062   #
45063   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45064   # It is also a way to make sure we got the proper file name for the real test later on.
45065   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45066   if test "x$test_shortpath" = x; then
45067     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45068 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45069     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45070   fi
45071 
45072   # Call helper function which possibly converts this using DOS-style short mode.
45073   # If so, the updated path is stored in $new_path.
45074 
45075   input_path="$new_path"
45076   # Check if we need to convert this using DOS-style short mode. If the path
45077   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45078   # take no chances and rewrite it.
45079   # Note: m4 eats our [], so we need to use [ and ] instead.
45080   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45081   if test "x$has_forbidden_chars" != x; then
45082     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45083     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45084     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45085     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45086       # Going to short mode and back again did indeed matter. Since short mode is
45087       # case insensitive, let's make it lowercase to improve readability.
45088       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45089       # Now convert it back to Unix-stile (cygpath)
45090       input_path=`$CYGPATH -u "$shortmode_path"`
45091       new_path="$input_path"
45092     fi
45093   fi
45094 
45095   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45096   if test "x$test_cygdrive_prefix" = x; then
45097     # As a simple fix, exclude /usr/bin since it's not a real path.
45098     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45099       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45100       # a path prefixed by /cygdrive for fixpath to work.
45101       new_path="$CYGWIN_ROOT_PATH$input_path"
45102     fi
45103   fi
45104 
45105 
45106   if test "x$path" != "x$new_path"; then
45107     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45108     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45109 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45110   fi
45111 
45112   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45113 
45114   path="$POTENTIAL_FREETYPE_LIB_PATH"
45115   has_colon=`$ECHO $path | $GREP ^.:`
45116   new_path="$path"
45117   if test "x$has_colon" = x; then
45118     # Not in mixed or Windows style, start by that.
45119     new_path=`cmd //c echo $path`
45120   fi
45121 
45122 
45123   input_path="$new_path"
45124   # Check if we need to convert this using DOS-style short mode. If the path
45125   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45126   # take no chances and rewrite it.
45127   # Note: m4 eats our [], so we need to use [ and ] instead.
45128   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45129   if test "x$has_forbidden_chars" != x; then
45130     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45131     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45132   fi
45133 
45134 
45135   windows_path="$new_path"
45136   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45137     unix_path=`$CYGPATH -u "$windows_path"`
45138     new_path="$unix_path"
45139   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45140     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45141     new_path="$unix_path"
45142   fi
45143 
45144   if test "x$path" != "x$new_path"; then
45145     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45146     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45147 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45148   fi
45149 
45150   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45151   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45152 
45153   else
45154     # We're on a posix platform. Hooray! :)
45155     path="$POTENTIAL_FREETYPE_LIB_PATH"
45156     has_space=`$ECHO "$path" | $GREP " "`
45157     if test "x$has_space" != x; then
45158       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45159 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45160       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45161     fi
45162 
45163     # Use eval to expand a potential ~
45164     eval path="$path"
45165     if test ! -f "$path" && test ! -d "$path"; then
45166       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45167     fi
45168 
45169     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45170   fi
45171 
45172 
45173     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45174     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45175 $as_echo_n "checking for freetype includes... " >&6; }
45176     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45177 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45178     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45179     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45180 $as_echo_n "checking for freetype libraries... " >&6; }
45181     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45182 $as_echo "$FREETYPE_LIB_PATH" >&6; }
45183   fi
45184 
45185 
45186           if test "x$FOUND_FREETYPE" != xyes; then
45187             FREETYPE_BASE_DIR="$FREETYPE_ROOT/usr/X11"
45188 
45189   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45190   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
45191   METHOD="well-known location"
45192 
45193   # First check if the files exists.
45194   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45195     # We found an arbitrary include file. That's a good sign.
45196     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45197 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45198     FOUND_FREETYPE=yes
45199 
45200     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45201     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45202       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45203 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45204       FOUND_FREETYPE=no
45205     else
45206       if test "x$OPENJDK_TARGET_OS" = xwindows; then
45207         # On Windows, we will need both .lib and .dll file.
45208         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
45209           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
45210 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
45211           FOUND_FREETYPE=no
45212         fi
45213       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
45214         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
45215         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
45216       fi
45217     fi
45218   fi
45219 
45220   if test "x$FOUND_FREETYPE" = xyes; then
45221 
45222   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45223 
45224   # Input might be given as Windows format, start by converting to
45225   # unix format.
45226   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45227   new_path=`$CYGPATH -u "$path"`
45228 
45229   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45230   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45231   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45232   # "foo.exe" is OK but "foo" is an error.
45233   #
45234   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45235   # It is also a way to make sure we got the proper file name for the real test later on.
45236   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45237   if test "x$test_shortpath" = x; then
45238     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45239 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45240     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45241   fi
45242 
45243   # Call helper function which possibly converts this using DOS-style short mode.
45244   # If so, the updated path is stored in $new_path.
45245 
45246   input_path="$new_path"
45247   # Check if we need to convert this using DOS-style short mode. If the path
45248   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45249   # take no chances and rewrite it.
45250   # Note: m4 eats our [], so we need to use [ and ] instead.
45251   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45252   if test "x$has_forbidden_chars" != x; then
45253     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45254     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45255     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45256     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45257       # Going to short mode and back again did indeed matter. Since short mode is
45258       # case insensitive, let's make it lowercase to improve readability.
45259       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45260       # Now convert it back to Unix-stile (cygpath)
45261       input_path=`$CYGPATH -u "$shortmode_path"`
45262       new_path="$input_path"
45263     fi
45264   fi
45265 
45266   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45267   if test "x$test_cygdrive_prefix" = x; then
45268     # As a simple fix, exclude /usr/bin since it's not a real path.
45269     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45270       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45271       # a path prefixed by /cygdrive for fixpath to work.
45272       new_path="$CYGWIN_ROOT_PATH$input_path"
45273     fi
45274   fi
45275 
45276 
45277   if test "x$path" != "x$new_path"; then
45278     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45279     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45280 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45281   fi
45282 
45283   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45284 
45285   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45286   has_colon=`$ECHO $path | $GREP ^.:`
45287   new_path="$path"
45288   if test "x$has_colon" = x; then
45289     # Not in mixed or Windows style, start by that.
45290     new_path=`cmd //c echo $path`
45291   fi
45292 
45293 
45294   input_path="$new_path"
45295   # Check if we need to convert this using DOS-style short mode. If the path
45296   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45297   # take no chances and rewrite it.
45298   # Note: m4 eats our [], so we need to use [ and ] instead.
45299   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45300   if test "x$has_forbidden_chars" != x; then
45301     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45302     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45303   fi
45304 
45305 
45306   windows_path="$new_path"
45307   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45308     unix_path=`$CYGPATH -u "$windows_path"`
45309     new_path="$unix_path"
45310   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45311     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45312     new_path="$unix_path"
45313   fi
45314 
45315   if test "x$path" != "x$new_path"; then
45316     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45317     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45318 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45319   fi
45320 
45321   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45322   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45323 
45324   else
45325     # We're on a posix platform. Hooray! :)
45326     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45327     has_space=`$ECHO "$path" | $GREP " "`
45328     if test "x$has_space" != x; then
45329       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45330 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45331       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45332     fi
45333 
45334     # Use eval to expand a potential ~
45335     eval path="$path"
45336     if test ! -f "$path" && test ! -d "$path"; then
45337       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45338     fi
45339 
45340     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45341   fi
45342 
45343 
45344   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45345 
45346   # Input might be given as Windows format, start by converting to
45347   # unix format.
45348   path="$POTENTIAL_FREETYPE_LIB_PATH"
45349   new_path=`$CYGPATH -u "$path"`
45350 
45351   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45352   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45353   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45354   # "foo.exe" is OK but "foo" is an error.
45355   #
45356   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45357   # It is also a way to make sure we got the proper file name for the real test later on.
45358   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45359   if test "x$test_shortpath" = x; then
45360     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45361 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45362     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45363   fi
45364 
45365   # Call helper function which possibly converts this using DOS-style short mode.
45366   # If so, the updated path is stored in $new_path.
45367 
45368   input_path="$new_path"
45369   # Check if we need to convert this using DOS-style short mode. If the path
45370   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45371   # take no chances and rewrite it.
45372   # Note: m4 eats our [], so we need to use [ and ] instead.
45373   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45374   if test "x$has_forbidden_chars" != x; then
45375     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45376     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45377     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45378     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45379       # Going to short mode and back again did indeed matter. Since short mode is
45380       # case insensitive, let's make it lowercase to improve readability.
45381       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45382       # Now convert it back to Unix-stile (cygpath)
45383       input_path=`$CYGPATH -u "$shortmode_path"`
45384       new_path="$input_path"
45385     fi
45386   fi
45387 
45388   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45389   if test "x$test_cygdrive_prefix" = x; then
45390     # As a simple fix, exclude /usr/bin since it's not a real path.
45391     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45392       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45393       # a path prefixed by /cygdrive for fixpath to work.
45394       new_path="$CYGWIN_ROOT_PATH$input_path"
45395     fi
45396   fi
45397 
45398 
45399   if test "x$path" != "x$new_path"; then
45400     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45401     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45402 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45403   fi
45404 
45405   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45406 
45407   path="$POTENTIAL_FREETYPE_LIB_PATH"
45408   has_colon=`$ECHO $path | $GREP ^.:`
45409   new_path="$path"
45410   if test "x$has_colon" = x; then
45411     # Not in mixed or Windows style, start by that.
45412     new_path=`cmd //c echo $path`
45413   fi
45414 
45415 
45416   input_path="$new_path"
45417   # Check if we need to convert this using DOS-style short mode. If the path
45418   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45419   # take no chances and rewrite it.
45420   # Note: m4 eats our [], so we need to use [ and ] instead.
45421   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45422   if test "x$has_forbidden_chars" != x; then
45423     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45424     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45425   fi
45426 
45427 
45428   windows_path="$new_path"
45429   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45430     unix_path=`$CYGPATH -u "$windows_path"`
45431     new_path="$unix_path"
45432   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45433     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45434     new_path="$unix_path"
45435   fi
45436 
45437   if test "x$path" != "x$new_path"; then
45438     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45439     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45440 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45441   fi
45442 
45443   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45444   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45445 
45446   else
45447     # We're on a posix platform. Hooray! :)
45448     path="$POTENTIAL_FREETYPE_LIB_PATH"
45449     has_space=`$ECHO "$path" | $GREP " "`
45450     if test "x$has_space" != x; then
45451       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45452 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45453       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45454     fi
45455 
45456     # Use eval to expand a potential ~
45457     eval path="$path"
45458     if test ! -f "$path" && test ! -d "$path"; then
45459       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45460     fi
45461 
45462     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45463   fi
45464 
45465 
45466     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45467     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45468 $as_echo_n "checking for freetype includes... " >&6; }
45469     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45470 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45471     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45472     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45473 $as_echo_n "checking for freetype libraries... " >&6; }
45474     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45475 $as_echo "$FREETYPE_LIB_PATH" >&6; }
45476   fi
45477 
45478           fi
45479 
45480           if test "x$FOUND_FREETYPE" != xyes; then
45481             FREETYPE_BASE_DIR="$FREETYPE_ROOT/usr"
45482             if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
45483 
45484   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45485   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/x86_64-linux-gnu"
45486   METHOD="well-known location"
45487 
45488   # First check if the files exists.
45489   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45490     # We found an arbitrary include file. That's a good sign.
45491     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45492 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45493     FOUND_FREETYPE=yes
45494 
45495     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45496     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45497       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45498 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45499       FOUND_FREETYPE=no
45500     else
45501       if test "x$OPENJDK_TARGET_OS" = xwindows; then
45502         # On Windows, we will need both .lib and .dll file.
45503         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
45504           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
45505 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
45506           FOUND_FREETYPE=no
45507         fi
45508       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
45509         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
45510         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
45511       fi
45512     fi
45513   fi
45514 
45515   if test "x$FOUND_FREETYPE" = xyes; then
45516 
45517   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45518 
45519   # Input might be given as Windows format, start by converting to
45520   # unix format.
45521   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45522   new_path=`$CYGPATH -u "$path"`
45523 
45524   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45525   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45526   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45527   # "foo.exe" is OK but "foo" is an error.
45528   #
45529   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45530   # It is also a way to make sure we got the proper file name for the real test later on.
45531   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45532   if test "x$test_shortpath" = x; then
45533     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45534 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45535     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45536   fi
45537 
45538   # Call helper function which possibly converts this using DOS-style short mode.
45539   # If so, the updated path is stored in $new_path.
45540 
45541   input_path="$new_path"
45542   # Check if we need to convert this using DOS-style short mode. If the path
45543   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45544   # take no chances and rewrite it.
45545   # Note: m4 eats our [], so we need to use [ and ] instead.
45546   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45547   if test "x$has_forbidden_chars" != x; then
45548     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45549     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45550     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45551     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45552       # Going to short mode and back again did indeed matter. Since short mode is
45553       # case insensitive, let's make it lowercase to improve readability.
45554       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45555       # Now convert it back to Unix-stile (cygpath)
45556       input_path=`$CYGPATH -u "$shortmode_path"`
45557       new_path="$input_path"
45558     fi
45559   fi
45560 
45561   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45562   if test "x$test_cygdrive_prefix" = x; then
45563     # As a simple fix, exclude /usr/bin since it's not a real path.
45564     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45565       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45566       # a path prefixed by /cygdrive for fixpath to work.
45567       new_path="$CYGWIN_ROOT_PATH$input_path"
45568     fi
45569   fi
45570 
45571 
45572   if test "x$path" != "x$new_path"; then
45573     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45574     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45575 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45576   fi
45577 
45578   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45579 
45580   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45581   has_colon=`$ECHO $path | $GREP ^.:`
45582   new_path="$path"
45583   if test "x$has_colon" = x; then
45584     # Not in mixed or Windows style, start by that.
45585     new_path=`cmd //c echo $path`
45586   fi
45587 
45588 
45589   input_path="$new_path"
45590   # Check if we need to convert this using DOS-style short mode. If the path
45591   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45592   # take no chances and rewrite it.
45593   # Note: m4 eats our [], so we need to use [ and ] instead.
45594   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45595   if test "x$has_forbidden_chars" != x; then
45596     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45597     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45598   fi
45599 
45600 
45601   windows_path="$new_path"
45602   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45603     unix_path=`$CYGPATH -u "$windows_path"`
45604     new_path="$unix_path"
45605   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45606     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45607     new_path="$unix_path"
45608   fi
45609 
45610   if test "x$path" != "x$new_path"; then
45611     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45612     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45613 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45614   fi
45615 
45616   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45617   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45618 
45619   else
45620     # We're on a posix platform. Hooray! :)
45621     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45622     has_space=`$ECHO "$path" | $GREP " "`
45623     if test "x$has_space" != x; then
45624       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45625 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45626       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45627     fi
45628 
45629     # Use eval to expand a potential ~
45630     eval path="$path"
45631     if test ! -f "$path" && test ! -d "$path"; then
45632       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45633     fi
45634 
45635     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45636   fi
45637 
45638 
45639   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45640 
45641   # Input might be given as Windows format, start by converting to
45642   # unix format.
45643   path="$POTENTIAL_FREETYPE_LIB_PATH"
45644   new_path=`$CYGPATH -u "$path"`
45645 
45646   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45647   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45648   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45649   # "foo.exe" is OK but "foo" is an error.
45650   #
45651   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45652   # It is also a way to make sure we got the proper file name for the real test later on.
45653   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45654   if test "x$test_shortpath" = x; then
45655     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45656 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45657     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45658   fi
45659 
45660   # Call helper function which possibly converts this using DOS-style short mode.
45661   # If so, the updated path is stored in $new_path.
45662 
45663   input_path="$new_path"
45664   # Check if we need to convert this using DOS-style short mode. If the path
45665   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45666   # take no chances and rewrite it.
45667   # Note: m4 eats our [], so we need to use [ and ] instead.
45668   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45669   if test "x$has_forbidden_chars" != x; then
45670     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45671     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45672     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45673     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45674       # Going to short mode and back again did indeed matter. Since short mode is
45675       # case insensitive, let's make it lowercase to improve readability.
45676       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45677       # Now convert it back to Unix-stile (cygpath)
45678       input_path=`$CYGPATH -u "$shortmode_path"`
45679       new_path="$input_path"
45680     fi
45681   fi
45682 
45683   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45684   if test "x$test_cygdrive_prefix" = x; then
45685     # As a simple fix, exclude /usr/bin since it's not a real path.
45686     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45687       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45688       # a path prefixed by /cygdrive for fixpath to work.
45689       new_path="$CYGWIN_ROOT_PATH$input_path"
45690     fi
45691   fi
45692 
45693 
45694   if test "x$path" != "x$new_path"; then
45695     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45696     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45697 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45698   fi
45699 
45700   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45701 
45702   path="$POTENTIAL_FREETYPE_LIB_PATH"
45703   has_colon=`$ECHO $path | $GREP ^.:`
45704   new_path="$path"
45705   if test "x$has_colon" = x; then
45706     # Not in mixed or Windows style, start by that.
45707     new_path=`cmd //c echo $path`
45708   fi
45709 
45710 
45711   input_path="$new_path"
45712   # Check if we need to convert this using DOS-style short mode. If the path
45713   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45714   # take no chances and rewrite it.
45715   # Note: m4 eats our [], so we need to use [ and ] instead.
45716   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45717   if test "x$has_forbidden_chars" != x; then
45718     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45719     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45720   fi
45721 
45722 
45723   windows_path="$new_path"
45724   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45725     unix_path=`$CYGPATH -u "$windows_path"`
45726     new_path="$unix_path"
45727   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45728     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45729     new_path="$unix_path"
45730   fi
45731 
45732   if test "x$path" != "x$new_path"; then
45733     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45734     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45735 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45736   fi
45737 
45738   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45739   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45740 
45741   else
45742     # We're on a posix platform. Hooray! :)
45743     path="$POTENTIAL_FREETYPE_LIB_PATH"
45744     has_space=`$ECHO "$path" | $GREP " "`
45745     if test "x$has_space" != x; then
45746       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45747 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45748       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45749     fi
45750 
45751     # Use eval to expand a potential ~
45752     eval path="$path"
45753     if test ! -f "$path" && test ! -d "$path"; then
45754       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45755     fi
45756 
45757     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45758   fi
45759 
45760 
45761     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45762     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45763 $as_echo_n "checking for freetype includes... " >&6; }
45764     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45765 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45766     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45767     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45768 $as_echo_n "checking for freetype libraries... " >&6; }
45769     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45770 $as_echo "$FREETYPE_LIB_PATH" >&6; }
45771   fi
45772 
45773             else
45774 
45775   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45776   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/i386-linux-gnu"
45777   METHOD="well-known location"
45778 
45779   # First check if the files exists.
45780   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45781     # We found an arbitrary include file. That's a good sign.
45782     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45783 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45784     FOUND_FREETYPE=yes
45785 
45786     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45787     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45788       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45789 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45790       FOUND_FREETYPE=no
45791     else
45792       if test "x$OPENJDK_TARGET_OS" = xwindows; then
45793         # On Windows, we will need both .lib and .dll file.
45794         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
45795           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
45796 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
45797           FOUND_FREETYPE=no
45798         fi
45799       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
45800         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
45801         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
45802       fi
45803     fi
45804   fi
45805 
45806   if test "x$FOUND_FREETYPE" = xyes; then
45807 
45808   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45809 
45810   # Input might be given as Windows format, start by converting to
45811   # unix format.
45812   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45813   new_path=`$CYGPATH -u "$path"`
45814 
45815   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45816   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45817   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45818   # "foo.exe" is OK but "foo" is an error.
45819   #
45820   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45821   # It is also a way to make sure we got the proper file name for the real test later on.
45822   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45823   if test "x$test_shortpath" = x; then
45824     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45825 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45826     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45827   fi
45828 
45829   # Call helper function which possibly converts this using DOS-style short mode.
45830   # If so, the updated path is stored in $new_path.
45831 
45832   input_path="$new_path"
45833   # Check if we need to convert this using DOS-style short mode. If the path
45834   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45835   # take no chances and rewrite it.
45836   # Note: m4 eats our [], so we need to use [ and ] instead.
45837   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45838   if test "x$has_forbidden_chars" != x; then
45839     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45840     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45841     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45842     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45843       # Going to short mode and back again did indeed matter. Since short mode is
45844       # case insensitive, let's make it lowercase to improve readability.
45845       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45846       # Now convert it back to Unix-stile (cygpath)
45847       input_path=`$CYGPATH -u "$shortmode_path"`
45848       new_path="$input_path"
45849     fi
45850   fi
45851 
45852   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45853   if test "x$test_cygdrive_prefix" = x; then
45854     # As a simple fix, exclude /usr/bin since it's not a real path.
45855     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45856       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45857       # a path prefixed by /cygdrive for fixpath to work.
45858       new_path="$CYGWIN_ROOT_PATH$input_path"
45859     fi
45860   fi
45861 
45862 
45863   if test "x$path" != "x$new_path"; then
45864     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45865     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45866 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45867   fi
45868 
45869   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45870 
45871   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45872   has_colon=`$ECHO $path | $GREP ^.:`
45873   new_path="$path"
45874   if test "x$has_colon" = x; then
45875     # Not in mixed or Windows style, start by that.
45876     new_path=`cmd //c echo $path`
45877   fi
45878 
45879 
45880   input_path="$new_path"
45881   # Check if we need to convert this using DOS-style short mode. If the path
45882   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45883   # take no chances and rewrite it.
45884   # Note: m4 eats our [], so we need to use [ and ] instead.
45885   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45886   if test "x$has_forbidden_chars" != x; then
45887     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45888     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45889   fi
45890 
45891 
45892   windows_path="$new_path"
45893   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45894     unix_path=`$CYGPATH -u "$windows_path"`
45895     new_path="$unix_path"
45896   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45897     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45898     new_path="$unix_path"
45899   fi
45900 
45901   if test "x$path" != "x$new_path"; then
45902     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45903     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45904 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45905   fi
45906 
45907   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45908   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45909 
45910   else
45911     # We're on a posix platform. Hooray! :)
45912     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45913     has_space=`$ECHO "$path" | $GREP " "`
45914     if test "x$has_space" != x; then
45915       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45916 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45917       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45918     fi
45919 
45920     # Use eval to expand a potential ~
45921     eval path="$path"
45922     if test ! -f "$path" && test ! -d "$path"; then
45923       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45924     fi
45925 
45926     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45927   fi
45928 
45929 
45930   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45931 
45932   # Input might be given as Windows format, start by converting to
45933   # unix format.
45934   path="$POTENTIAL_FREETYPE_LIB_PATH"
45935   new_path=`$CYGPATH -u "$path"`
45936 
45937   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45938   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45939   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45940   # "foo.exe" is OK but "foo" is an error.
45941   #
45942   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45943   # It is also a way to make sure we got the proper file name for the real test later on.
45944   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45945   if test "x$test_shortpath" = x; then
45946     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45947 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45948     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45949   fi
45950 
45951   # Call helper function which possibly converts this using DOS-style short mode.
45952   # If so, the updated path is stored in $new_path.
45953 
45954   input_path="$new_path"
45955   # Check if we need to convert this using DOS-style short mode. If the path
45956   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45957   # take no chances and rewrite it.
45958   # Note: m4 eats our [], so we need to use [ and ] instead.
45959   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45960   if test "x$has_forbidden_chars" != x; then
45961     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45962     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45963     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45964     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45965       # Going to short mode and back again did indeed matter. Since short mode is
45966       # case insensitive, let's make it lowercase to improve readability.
45967       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45968       # Now convert it back to Unix-stile (cygpath)
45969       input_path=`$CYGPATH -u "$shortmode_path"`
45970       new_path="$input_path"
45971     fi
45972   fi
45973 
45974   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45975   if test "x$test_cygdrive_prefix" = x; then
45976     # As a simple fix, exclude /usr/bin since it's not a real path.
45977     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45978       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45979       # a path prefixed by /cygdrive for fixpath to work.
45980       new_path="$CYGWIN_ROOT_PATH$input_path"
45981     fi
45982   fi
45983 
45984 
45985   if test "x$path" != "x$new_path"; then
45986     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45987     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45988 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45989   fi
45990 
45991   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45992 
45993   path="$POTENTIAL_FREETYPE_LIB_PATH"
45994   has_colon=`$ECHO $path | $GREP ^.:`
45995   new_path="$path"
45996   if test "x$has_colon" = x; then
45997     # Not in mixed or Windows style, start by that.
45998     new_path=`cmd //c echo $path`
45999   fi
46000 
46001 
46002   input_path="$new_path"
46003   # Check if we need to convert this using DOS-style short mode. If the path
46004   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46005   # take no chances and rewrite it.
46006   # Note: m4 eats our [], so we need to use [ and ] instead.
46007   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46008   if test "x$has_forbidden_chars" != x; then
46009     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46010     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46011   fi
46012 
46013 
46014   windows_path="$new_path"
46015   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46016     unix_path=`$CYGPATH -u "$windows_path"`
46017     new_path="$unix_path"
46018   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46019     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46020     new_path="$unix_path"
46021   fi
46022 
46023   if test "x$path" != "x$new_path"; then
46024     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
46025     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
46026 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46027   fi
46028 
46029   # Save the first 10 bytes of this path to the storage, so fixpath can work.
46030   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46031 
46032   else
46033     # We're on a posix platform. Hooray! :)
46034     path="$POTENTIAL_FREETYPE_LIB_PATH"
46035     has_space=`$ECHO "$path" | $GREP " "`
46036     if test "x$has_space" != x; then
46037       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46038 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46039       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46040     fi
46041 
46042     # Use eval to expand a potential ~
46043     eval path="$path"
46044     if test ! -f "$path" && test ! -d "$path"; then
46045       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46046     fi
46047 
46048     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
46049   fi
46050 
46051 
46052     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46053     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
46054 $as_echo_n "checking for freetype includes... " >&6; }
46055     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
46056 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
46057     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
46058     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
46059 $as_echo_n "checking for freetype libraries... " >&6; }
46060     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
46061 $as_echo "$FREETYPE_LIB_PATH" >&6; }
46062   fi
46063 
46064               if test "x$FOUND_FREETYPE" != xyes; then
46065 
46066   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
46067   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32"
46068   METHOD="well-known location"
46069 
46070   # First check if the files exists.
46071   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
46072     # We found an arbitrary include file. That's a good sign.
46073     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
46074 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
46075     FOUND_FREETYPE=yes
46076 
46077     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
46078     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
46079       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
46080 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
46081       FOUND_FREETYPE=no
46082     else
46083       if test "x$OPENJDK_TARGET_OS" = xwindows; then
46084         # On Windows, we will need both .lib and .dll file.
46085         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
46086           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
46087 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
46088           FOUND_FREETYPE=no
46089         fi
46090       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
46091         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
46092         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
46093       fi
46094     fi
46095   fi
46096 
46097   if test "x$FOUND_FREETYPE" = xyes; then
46098 
46099   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46100 
46101   # Input might be given as Windows format, start by converting to
46102   # unix format.
46103   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46104   new_path=`$CYGPATH -u "$path"`
46105 
46106   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46107   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46108   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46109   # "foo.exe" is OK but "foo" is an error.
46110   #
46111   # This test is therefore slightly more accurate than "test -f" to check for file precense.
46112   # It is also a way to make sure we got the proper file name for the real test later on.
46113   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46114   if test "x$test_shortpath" = x; then
46115     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46116 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46117     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
46118   fi
46119 
46120   # Call helper function which possibly converts this using DOS-style short mode.
46121   # If so, the updated path is stored in $new_path.
46122 
46123   input_path="$new_path"
46124   # Check if we need to convert this using DOS-style short mode. If the path
46125   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46126   # take no chances and rewrite it.
46127   # Note: m4 eats our [], so we need to use [ and ] instead.
46128   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46129   if test "x$has_forbidden_chars" != x; then
46130     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46131     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46132     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46133     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46134       # Going to short mode and back again did indeed matter. Since short mode is
46135       # case insensitive, let's make it lowercase to improve readability.
46136       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46137       # Now convert it back to Unix-stile (cygpath)
46138       input_path=`$CYGPATH -u "$shortmode_path"`
46139       new_path="$input_path"
46140     fi
46141   fi
46142 
46143   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46144   if test "x$test_cygdrive_prefix" = x; then
46145     # As a simple fix, exclude /usr/bin since it's not a real path.
46146     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46147       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46148       # a path prefixed by /cygdrive for fixpath to work.
46149       new_path="$CYGWIN_ROOT_PATH$input_path"
46150     fi
46151   fi
46152 
46153 
46154   if test "x$path" != "x$new_path"; then
46155     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
46156     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46157 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46158   fi
46159 
46160   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46161 
46162   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46163   has_colon=`$ECHO $path | $GREP ^.:`
46164   new_path="$path"
46165   if test "x$has_colon" = x; then
46166     # Not in mixed or Windows style, start by that.
46167     new_path=`cmd //c echo $path`
46168   fi
46169 
46170 
46171   input_path="$new_path"
46172   # Check if we need to convert this using DOS-style short mode. If the path
46173   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46174   # take no chances and rewrite it.
46175   # Note: m4 eats our [], so we need to use [ and ] instead.
46176   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46177   if test "x$has_forbidden_chars" != x; then
46178     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46179     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46180   fi
46181 
46182 
46183   windows_path="$new_path"
46184   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46185     unix_path=`$CYGPATH -u "$windows_path"`
46186     new_path="$unix_path"
46187   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46188     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46189     new_path="$unix_path"
46190   fi
46191 
46192   if test "x$path" != "x$new_path"; then
46193     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
46194     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46195 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46196   fi
46197 
46198   # Save the first 10 bytes of this path to the storage, so fixpath can work.
46199   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46200 
46201   else
46202     # We're on a posix platform. Hooray! :)
46203     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46204     has_space=`$ECHO "$path" | $GREP " "`
46205     if test "x$has_space" != x; then
46206       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46207 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46208       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46209     fi
46210 
46211     # Use eval to expand a potential ~
46212     eval path="$path"
46213     if test ! -f "$path" && test ! -d "$path"; then
46214       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46215     fi
46216 
46217     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
46218   fi
46219 
46220 
46221   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46222 
46223   # Input might be given as Windows format, start by converting to
46224   # unix format.
46225   path="$POTENTIAL_FREETYPE_LIB_PATH"
46226   new_path=`$CYGPATH -u "$path"`
46227 
46228   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46229   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46230   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46231   # "foo.exe" is OK but "foo" is an error.
46232   #
46233   # This test is therefore slightly more accurate than "test -f" to check for file precense.
46234   # It is also a way to make sure we got the proper file name for the real test later on.
46235   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46236   if test "x$test_shortpath" = x; then
46237     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46238 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46239     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
46240   fi
46241 
46242   # Call helper function which possibly converts this using DOS-style short mode.
46243   # If so, the updated path is stored in $new_path.
46244 
46245   input_path="$new_path"
46246   # Check if we need to convert this using DOS-style short mode. If the path
46247   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46248   # take no chances and rewrite it.
46249   # Note: m4 eats our [], so we need to use [ and ] instead.
46250   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46251   if test "x$has_forbidden_chars" != x; then
46252     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46253     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46254     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46255     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46256       # Going to short mode and back again did indeed matter. Since short mode is
46257       # case insensitive, let's make it lowercase to improve readability.
46258       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46259       # Now convert it back to Unix-stile (cygpath)
46260       input_path=`$CYGPATH -u "$shortmode_path"`
46261       new_path="$input_path"
46262     fi
46263   fi
46264 
46265   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46266   if test "x$test_cygdrive_prefix" = x; then
46267     # As a simple fix, exclude /usr/bin since it's not a real path.
46268     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46269       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46270       # a path prefixed by /cygdrive for fixpath to work.
46271       new_path="$CYGWIN_ROOT_PATH$input_path"
46272     fi
46273   fi
46274 
46275 
46276   if test "x$path" != "x$new_path"; then
46277     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
46278     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
46279 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46280   fi
46281 
46282   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46283 
46284   path="$POTENTIAL_FREETYPE_LIB_PATH"
46285   has_colon=`$ECHO $path | $GREP ^.:`
46286   new_path="$path"
46287   if test "x$has_colon" = x; then
46288     # Not in mixed or Windows style, start by that.
46289     new_path=`cmd //c echo $path`
46290   fi
46291 
46292 
46293   input_path="$new_path"
46294   # Check if we need to convert this using DOS-style short mode. If the path
46295   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46296   # take no chances and rewrite it.
46297   # Note: m4 eats our [], so we need to use [ and ] instead.
46298   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46299   if test "x$has_forbidden_chars" != x; then
46300     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46301     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46302   fi
46303 
46304 
46305   windows_path="$new_path"
46306   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46307     unix_path=`$CYGPATH -u "$windows_path"`
46308     new_path="$unix_path"
46309   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46310     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46311     new_path="$unix_path"
46312   fi
46313 
46314   if test "x$path" != "x$new_path"; then
46315     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
46316     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
46317 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46318   fi
46319 
46320   # Save the first 10 bytes of this path to the storage, so fixpath can work.
46321   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46322 
46323   else
46324     # We're on a posix platform. Hooray! :)
46325     path="$POTENTIAL_FREETYPE_LIB_PATH"
46326     has_space=`$ECHO "$path" | $GREP " "`
46327     if test "x$has_space" != x; then
46328       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46329 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46330       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46331     fi
46332 
46333     # Use eval to expand a potential ~
46334     eval path="$path"
46335     if test ! -f "$path" && test ! -d "$path"; then
46336       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46337     fi
46338 
46339     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
46340   fi
46341 
46342 
46343     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46344     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
46345 $as_echo_n "checking for freetype includes... " >&6; }
46346     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
46347 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
46348     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
46349     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
46350 $as_echo_n "checking for freetype libraries... " >&6; }
46351     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
46352 $as_echo "$FREETYPE_LIB_PATH" >&6; }
46353   fi
46354 
46355               fi
46356             fi
46357           fi
46358         fi
46359       fi # end check in well-known locations
46360 
46361       if test "x$FOUND_FREETYPE" != xyes; then
46362 
46363   # Print a helpful message on how to acquire the necessary build dependency.
46364   # freetype is the help tag: freetype, cups, pulse, alsa etc
46365   MISSING_DEPENDENCY=freetype
46366 
46367   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46368     cygwin_help $MISSING_DEPENDENCY
46369   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46370     msys_help $MISSING_DEPENDENCY
46371   else
46372     PKGHANDLER_COMMAND=
46373 
46374     case $PKGHANDLER in
46375       apt-get)
46376         apt_help     $MISSING_DEPENDENCY ;;
46377       yum)
46378         yum_help     $MISSING_DEPENDENCY ;;
46379       port)
46380         port_help    $MISSING_DEPENDENCY ;;
46381       pkgutil)
46382         pkgutil_help $MISSING_DEPENDENCY ;;
46383       pkgadd)
46384         pkgadd_help  $MISSING_DEPENDENCY ;;
46385     esac
46386 
46387     if test "x$PKGHANDLER_COMMAND" != x; then
46388       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
46389     fi
46390   fi
46391 
46392         as_fn_error $? "Could not find freetype! $HELP_MSG " "$LINENO" 5
46393       fi
46394     fi # end user specified settings
46395 
46396     # Set FREETYPE_CFLAGS, _LIBS and _LIB_PATH from include and lib dir.
46397     if test "x$FREETYPE_CFLAGS" = x; then
46398 
46399   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46400 
46401   # Input might be given as Windows format, start by converting to
46402   # unix format.
46403   path="$FREETYPE_INCLUDE_PATH"
46404   new_path=`$CYGPATH -u "$path"`
46405 
46406   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46407   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46408   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46409   # "foo.exe" is OK but "foo" is an error.
46410   #
46411   # This test is therefore slightly more accurate than "test -f" to check for file precense.
46412   # It is also a way to make sure we got the proper file name for the real test later on.
46413   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46414   if test "x$test_shortpath" = x; then
46415     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46416 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46417     as_fn_error $? "Cannot locate the the path of FREETYPE_INCLUDE_PATH" "$LINENO" 5
46418   fi
46419 
46420   # Call helper function which possibly converts this using DOS-style short mode.
46421   # If so, the updated path is stored in $new_path.
46422 
46423   input_path="$new_path"
46424   # Check if we need to convert this using DOS-style short mode. If the path
46425   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46426   # take no chances and rewrite it.
46427   # Note: m4 eats our [], so we need to use [ and ] instead.
46428   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46429   if test "x$has_forbidden_chars" != x; then
46430     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46431     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46432     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46433     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46434       # Going to short mode and back again did indeed matter. Since short mode is
46435       # case insensitive, let's make it lowercase to improve readability.
46436       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46437       # Now convert it back to Unix-stile (cygpath)
46438       input_path=`$CYGPATH -u "$shortmode_path"`
46439       new_path="$input_path"
46440     fi
46441   fi
46442 
46443   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46444   if test "x$test_cygdrive_prefix" = x; then
46445     # As a simple fix, exclude /usr/bin since it's not a real path.
46446     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46447       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46448       # a path prefixed by /cygdrive for fixpath to work.
46449       new_path="$CYGWIN_ROOT_PATH$input_path"
46450     fi
46451   fi
46452 
46453 
46454   if test "x$path" != "x$new_path"; then
46455     FREETYPE_INCLUDE_PATH="$new_path"
46456     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46457 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46458   fi
46459 
46460   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46461 
46462   path="$FREETYPE_INCLUDE_PATH"
46463   has_colon=`$ECHO $path | $GREP ^.:`
46464   new_path="$path"
46465   if test "x$has_colon" = x; then
46466     # Not in mixed or Windows style, start by that.
46467     new_path=`cmd //c echo $path`
46468   fi
46469 
46470 
46471   input_path="$new_path"
46472   # Check if we need to convert this using DOS-style short mode. If the path
46473   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46474   # take no chances and rewrite it.
46475   # Note: m4 eats our [], so we need to use [ and ] instead.
46476   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46477   if test "x$has_forbidden_chars" != x; then
46478     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46479     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46480   fi
46481 
46482 
46483   windows_path="$new_path"
46484   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46485     unix_path=`$CYGPATH -u "$windows_path"`
46486     new_path="$unix_path"
46487   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46488     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46489     new_path="$unix_path"
46490   fi
46491 
46492   if test "x$path" != "x$new_path"; then
46493     FREETYPE_INCLUDE_PATH="$new_path"
46494     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46495 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46496   fi
46497 
46498   # Save the first 10 bytes of this path to the storage, so fixpath can work.
46499   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46500 
46501   else
46502     # We're on a posix platform. Hooray! :)
46503     path="$FREETYPE_INCLUDE_PATH"
46504     has_space=`$ECHO "$path" | $GREP " "`
46505     if test "x$has_space" != x; then
46506       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46507 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46508       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46509     fi
46510 
46511     # Use eval to expand a potential ~
46512     eval path="$path"
46513     if test ! -f "$path" && test ! -d "$path"; then
46514       as_fn_error $? "The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46515     fi
46516 
46517     FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
46518   fi
46519 
46520       if test -d $FREETYPE_INCLUDE_PATH/freetype2/freetype; then
46521         FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH/freetype2 -I$FREETYPE_INCLUDE_PATH"
46522       else
46523         FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH"
46524       fi
46525     fi
46526 
46527     if test "x$FREETYPE_LIBS" = x; then
46528 
46529   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46530 
46531   # Input might be given as Windows format, start by converting to
46532   # unix format.
46533   path="$FREETYPE_LIB_PATH"
46534   new_path=`$CYGPATH -u "$path"`
46535 
46536   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46537   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46538   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46539   # "foo.exe" is OK but "foo" is an error.
46540   #
46541   # This test is therefore slightly more accurate than "test -f" to check for file precense.
46542   # It is also a way to make sure we got the proper file name for the real test later on.
46543   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46544   if test "x$test_shortpath" = x; then
46545     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46546 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46547     as_fn_error $? "Cannot locate the the path of FREETYPE_LIB_PATH" "$LINENO" 5
46548   fi
46549 
46550   # Call helper function which possibly converts this using DOS-style short mode.
46551   # If so, the updated path is stored in $new_path.
46552 
46553   input_path="$new_path"
46554   # Check if we need to convert this using DOS-style short mode. If the path
46555   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46556   # take no chances and rewrite it.
46557   # Note: m4 eats our [], so we need to use [ and ] instead.
46558   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46559   if test "x$has_forbidden_chars" != x; then
46560     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46561     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46562     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46563     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46564       # Going to short mode and back again did indeed matter. Since short mode is
46565       # case insensitive, let's make it lowercase to improve readability.
46566       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46567       # Now convert it back to Unix-stile (cygpath)
46568       input_path=`$CYGPATH -u "$shortmode_path"`
46569       new_path="$input_path"
46570     fi
46571   fi
46572 
46573   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46574   if test "x$test_cygdrive_prefix" = x; then
46575     # As a simple fix, exclude /usr/bin since it's not a real path.
46576     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46577       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46578       # a path prefixed by /cygdrive for fixpath to work.
46579       new_path="$CYGWIN_ROOT_PATH$input_path"
46580     fi
46581   fi
46582 
46583 
46584   if test "x$path" != "x$new_path"; then
46585     FREETYPE_LIB_PATH="$new_path"
46586     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5
46587 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46588   fi
46589 
46590   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46591 
46592   path="$FREETYPE_LIB_PATH"
46593   has_colon=`$ECHO $path | $GREP ^.:`
46594   new_path="$path"
46595   if test "x$has_colon" = x; then
46596     # Not in mixed or Windows style, start by that.
46597     new_path=`cmd //c echo $path`
46598   fi
46599 
46600 
46601   input_path="$new_path"
46602   # Check if we need to convert this using DOS-style short mode. If the path
46603   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46604   # take no chances and rewrite it.
46605   # Note: m4 eats our [], so we need to use [ and ] instead.
46606   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46607   if test "x$has_forbidden_chars" != x; then
46608     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46609     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46610   fi
46611 
46612 
46613   windows_path="$new_path"
46614   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46615     unix_path=`$CYGPATH -u "$windows_path"`
46616     new_path="$unix_path"
46617   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46618     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46619     new_path="$unix_path"
46620   fi
46621 
46622   if test "x$path" != "x$new_path"; then
46623     FREETYPE_LIB_PATH="$new_path"
46624     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5
46625 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46626   fi
46627 
46628   # Save the first 10 bytes of this path to the storage, so fixpath can work.
46629   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46630 
46631   else
46632     # We're on a posix platform. Hooray! :)
46633     path="$FREETYPE_LIB_PATH"
46634     has_space=`$ECHO "$path" | $GREP " "`
46635     if test "x$has_space" != x; then
46636       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46637 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46638       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46639     fi
46640 
46641     # Use eval to expand a potential ~
46642     eval path="$path"
46643     if test ! -f "$path" && test ! -d "$path"; then
46644       as_fn_error $? "The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46645     fi
46646 
46647     FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
46648   fi
46649 
46650       if test "x$OPENJDK_TARGET_OS" = xwindows; then
46651         FREETYPE_LIBS="$FREETYPE_LIB_PATH/freetype.lib"
46652       else
46653         FREETYPE_LIBS="-L$FREETYPE_LIB_PATH -lfreetype"
46654       fi
46655     fi
46656 
46657     # Try to compile it
46658     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can compile and link with freetype" >&5
46659 $as_echo_n "checking if we can compile and link with freetype... " >&6; }
46660     ac_ext=cpp
46661 ac_cpp='$CXXCPP $CPPFLAGS'
46662 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
46663 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
46664 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
46665 
46666     PREV_CXXCFLAGS="$CXXFLAGS"
46667     PREV_LIBS="$LIBS"
46668     PREV_CXX="$CXX"
46669     CXXFLAGS="$CXXFLAGS $FREETYPE_CFLAGS"
46670     LIBS="$LIBS $FREETYPE_LIBS"
46671     CXX="$FIXPATH $CXX"
46672     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46673 /* end confdefs.h.  */
46674 
46675           #include<ft2build.h>
46676           #include FT_FREETYPE_H
46677           int main () {
46678             FT_Init_FreeType(NULL);
46679             return 0;
46680           }
46681 
46682 _ACEOF
46683 if ac_fn_cxx_try_link "$LINENO"; then :
46684 
46685           { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
46686 $as_echo "yes" >&6; }
46687 
46688 else
46689 
46690           { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
46691 $as_echo "no" >&6; }
46692           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&5
46693 $as_echo "$as_me: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&6;}
46694           { $as_echo "$as_me:${as_lineno-$LINENO}: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&5
46695 $as_echo "$as_me: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&6;}
46696 
46697 
46698   # Print a helpful message on how to acquire the necessary build dependency.
46699   # freetype is the help tag: freetype, cups, pulse, alsa etc
46700   MISSING_DEPENDENCY=freetype
46701 
46702   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46703     cygwin_help $MISSING_DEPENDENCY
46704   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46705     msys_help $MISSING_DEPENDENCY
46706   else
46707     PKGHANDLER_COMMAND=
46708 
46709     case $PKGHANDLER in
46710       apt-get)
46711         apt_help     $MISSING_DEPENDENCY ;;
46712       yum)
46713         yum_help     $MISSING_DEPENDENCY ;;
46714       port)
46715         port_help    $MISSING_DEPENDENCY ;;
46716       pkgutil)
46717         pkgutil_help $MISSING_DEPENDENCY ;;
46718       pkgadd)
46719         pkgadd_help  $MISSING_DEPENDENCY ;;
46720     esac
46721 
46722     if test "x$PKGHANDLER_COMMAND" != x; then
46723       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
46724     fi
46725   fi
46726 
46727 
46728           as_fn_error $? "Can not continue without freetype. $HELP_MSG" "$LINENO" 5
46729 
46730 
46731 fi
46732 rm -f core conftest.err conftest.$ac_objext \
46733     conftest$ac_exeext conftest.$ac_ext
46734     CXXCFLAGS="$PREV_CXXFLAGS"
46735     LIBS="$PREV_LIBS"
46736     CXX="$PREV_CXX"
46737     ac_ext=cpp
46738 ac_cpp='$CXXCPP $CPPFLAGS'
46739 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
46740 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
46741 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
46742 
46743 
46744     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should bundle freetype" >&5
46745 $as_echo_n "checking if we should bundle freetype... " >&6; }
46746     if test "x$BUNDLE_FREETYPE" = xyes; then
46747       FREETYPE_BUNDLE_LIB_PATH="$FREETYPE_LIB_PATH"
46748     fi
46749     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUNDLE_FREETYPE" >&5
46750 $as_echo "$BUNDLE_FREETYPE" >&6; }
46751 
46752   fi # end freetype needed
46753 
46754 
46755 
46756 
46757 
46758 
46759 
46760   ###############################################################################
46761   #
46762   # Check for alsa headers and libraries. Used on Linux/GNU systems.
46763   #
46764 
46765 # Check whether --with-alsa was given.
46766 if test "${with_alsa+set}" = set; then :
46767   withval=$with_alsa;
46768 fi
46769 
46770 
46771 # Check whether --with-alsa-include was given.
46772 if test "${with_alsa_include+set}" = set; then :
46773   withval=$with_alsa_include;
46774 fi
46775 
46776 
46777 # Check whether --with-alsa-lib was given.
46778 if test "${with_alsa_lib+set}" = set; then :
46779   withval=$with_alsa_lib;
46780 fi
46781 
46782 
46783   if test "x$ALSA_NOT_NEEDED" = xyes; then
46784     if test "x${with_alsa}" != x || test "x${with_alsa_include}" != x || test "x${with_alsa_lib}" != x; then
46785       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa is ignored" >&5
46786 $as_echo "$as_me: WARNING: alsa not used, so --with-alsa is ignored" >&2;}
46787     fi
46788     ALSA_CFLAGS=
46789     ALSA_LIBS=
46790   else
46791     ALSA_FOUND=no
46792 
46793     if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then
46794       as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5
46795     fi
46796 
46797     if test "x${with_alsa}" != x; then
46798       ALSA_LIBS="-L${with_alsa}/lib -lasound"
46799       ALSA_CFLAGS="-I${with_alsa}/include"
46800       ALSA_FOUND=yes
46801     fi
46802     if test "x${with_alsa_include}" != x; then
46803       ALSA_CFLAGS="-I${with_alsa_include}"
46804       ALSA_FOUND=yes
46805     fi
46806     if test "x${with_alsa_lib}" != x; then
46807       ALSA_LIBS="-L${with_alsa_lib} -lasound"
46808       ALSA_FOUND=yes
46809     fi
46810     if test "x$ALSA_FOUND" = xno; then
46811 
46812 
46813   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
46814     # Source the builddeps file again, to make sure it uses the latest variables!
46815     . $builddepsfile
46816     # Look for a target and build machine specific resource!
46817     eval resource=\${builddep_alsa_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
46818     if test "x$resource" = x; then
46819       # Ok, lets instead look for a target specific resource
46820       eval resource=\${builddep_alsa_TARGET_${rewritten_target_var}}
46821     fi
46822     if test "x$resource" = x; then
46823       # Ok, lets instead look for a build specific resource
46824       eval resource=\${builddep_alsa_BUILD_${rewritten_build_var}}
46825     fi
46826     if test "x$resource" = x; then
46827       # Ok, lets instead look for a generic resource
46828       # (The alsa comes from M4 and not the shell, thus no need for eval here.)
46829       resource=${builddep_alsa}
46830     fi
46831     if test "x$resource" != x; then
46832       { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for alsa" >&5
46833 $as_echo "$as_me: Using builddeps $resource for alsa" >&6;}
46834       # If the resource in the builddeps.conf file is an existing directory,
46835       # for example /java/linux/cups
46836       if test -d ${resource}; then
46837         depdir=${resource}
46838       else
46839 
46840   # alsa is for example mymodule
46841   # $resource is for example libs/general/libmymod_1_2_3.zip
46842   # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
46843   # $with_builddeps_dir is for example /localhome/builddeps
46844   # depdir is the name of the variable into which we store the depdir, eg MYMOD
46845   # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
46846   # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
46847   filename=`basename $resource`
46848   filebase=`echo $filename | sed 's/\.[^\.]*$//'`
46849   filebase=${filename%%.*}
46850   extension=${filename#*.}
46851   installdir=$with_builddeps_dir/$filebase
46852   if test ! -f $installdir/$filename.unpacked; then
46853     { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency alsa from $with_builddeps_server/$resource and installing into $installdir" >&5
46854 $as_echo "$as_me: Downloading build dependency alsa from $with_builddeps_server/$resource and installing into $installdir" >&6;}
46855     if test ! -d $installdir; then
46856       mkdir -p $installdir
46857     fi
46858     if test ! -d $installdir; then
46859       as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
46860     fi
46861     tmpfile=`mktemp $installdir/alsa.XXXXXXXXX`
46862     touch $tmpfile
46863     if test ! -f $tmpfile; then
46864       as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
46865     fi
46866 
46867   # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
46868   # $tmpfile is the local file name for the downloaded file.
46869   VALID_TOOL=no
46870   if test "x$BDEPS_FTP" = xwget; then
46871     VALID_TOOL=yes
46872     wget -O $tmpfile $with_builddeps_server/$resource
46873   fi
46874   if test "x$BDEPS_FTP" = xlftp; then
46875     VALID_TOOL=yes
46876     lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
46877   fi
46878   if test "x$BDEPS_FTP" = xftp; then
46879     VALID_TOOL=yes
46880     FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
46881     FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
46882     FTPUSERPWD=${FTPSERVER%%@*}
46883     if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
46884       FTPUSER=${userpwd%%:*}
46885       FTPPWD=${userpwd#*@}
46886       FTPSERVER=${FTPSERVER#*@}
46887     else
46888       FTPUSER=ftp
46889       FTPPWD=ftp
46890     fi
46891     # the "pass" command does not work on some
46892     # ftp clients (read ftp.exe) but if it works,
46893     # passive mode is better!
46894     ( \
46895         echo "user $FTPUSER $FTPPWD"        ; \
46896         echo "pass"                         ; \
46897         echo "bin"                          ; \
46898         echo "get $FTPPATH $tmpfile"              ; \
46899     ) | ftp -in $FTPSERVER
46900   fi
46901   if test "x$VALID_TOOL" != xyes; then
46902     as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
46903   fi
46904 
46905     mv $tmpfile $installdir/$filename
46906     if test ! -s $installdir/$filename; then
46907       as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
46908     fi
46909     case "$extension" in
46910       zip)  echo "Unzipping $installdir/$filename..."
46911         (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
46912         ;;
46913       tar.gz) echo "Untaring $installdir/$filename..."
46914         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
46915         ;;
46916       tgz) echo "Untaring $installdir/$filename..."
46917         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
46918         ;;
46919       *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
46920         ;;
46921     esac
46922   fi
46923   if test -f $installdir/$filename.unpacked; then
46924     depdir=$installdir
46925   fi
46926 
46927       fi
46928       # Source the builddeps file again, because in the previous command, the depdir
46929       # was updated to point at the current build dependency install directory.
46930       . $builddepsfile
46931       # Now extract variables from the builddeps.conf files.
46932       theroot=${builddep_alsa_ROOT}
46933       thecflags=${builddep_alsa_CFLAGS}
46934       thelibs=${builddep_alsa_LIBS}
46935       if test "x$depdir" = x; then
46936         as_fn_error $? "Could not download build dependency alsa" "$LINENO" 5
46937       fi
46938       ALSA=$depdir
46939       if test "x$theroot" != x; then
46940         ALSA="$theroot"
46941       fi
46942       if test "x$thecflags" != x; then
46943         ALSA_CFLAGS="$thecflags"
46944       fi
46945       if test "x$thelibs" != x; then
46946         ALSA_LIBS="$thelibs"
46947       fi
46948       ALSA_FOUND=yes
46949       else ALSA_FOUND=no
46950 
46951     fi
46952     else ALSA_FOUND=no
46953 
46954   fi
46955 
46956     fi
46957     if test "x$ALSA_FOUND" = xno; then
46958 
46959 pkg_failed=no
46960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5
46961 $as_echo_n "checking for ALSA... " >&6; }
46962 
46963 if test -n "$ALSA_CFLAGS"; then
46964     pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS"
46965  elif test -n "$PKG_CONFIG"; then
46966     if test -n "$PKG_CONFIG" && \
46967     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5
46968   ($PKG_CONFIG --exists --print-errors "alsa") 2>&5
46969   ac_status=$?
46970   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
46971   test $ac_status = 0; }; then
46972   pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null`
46973 else
46974   pkg_failed=yes
46975 fi
46976  else
46977     pkg_failed=untried
46978 fi
46979 if test -n "$ALSA_LIBS"; then
46980     pkg_cv_ALSA_LIBS="$ALSA_LIBS"
46981  elif test -n "$PKG_CONFIG"; then
46982     if test -n "$PKG_CONFIG" && \
46983     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5
46984   ($PKG_CONFIG --exists --print-errors "alsa") 2>&5
46985   ac_status=$?
46986   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
46987   test $ac_status = 0; }; then
46988   pkg_cv_ALSA_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null`
46989 else
46990   pkg_failed=yes
46991 fi
46992  else
46993     pkg_failed=untried
46994 fi
46995 
46996 
46997 
46998 if test $pkg_failed = yes; then
46999 
47000 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
47001         _pkg_short_errors_supported=yes
47002 else
47003         _pkg_short_errors_supported=no
47004 fi
47005         if test $_pkg_short_errors_supported = yes; then
47006                 ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1`
47007         else
47008                 ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1`
47009         fi
47010         # Put the nasty error message in config.log where it belongs
47011         echo "$ALSA_PKG_ERRORS" >&5
47012 
47013         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47014 $as_echo "no" >&6; }
47015                 ALSA_FOUND=no
47016 elif test $pkg_failed = untried; then
47017         ALSA_FOUND=no
47018 else
47019         ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS
47020         ALSA_LIBS=$pkg_cv_ALSA_LIBS
47021         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
47022 $as_echo "yes" >&6; }
47023         ALSA_FOUND=yes
47024 fi
47025     fi
47026     if test "x$ALSA_FOUND" = xno; then
47027       for ac_header in alsa/asoundlib.h
47028 do :
47029   ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default"
47030 if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then :
47031   cat >>confdefs.h <<_ACEOF
47032 #define HAVE_ALSA_ASOUNDLIB_H 1
47033 _ACEOF
47034 
47035             ALSA_FOUND=yes
47036             ALSA_CFLAGS=-Iignoreme
47037             ALSA_LIBS=-lasound
47038             DEFAULT_ALSA=yes
47039 
47040 else
47041   ALSA_FOUND=no
47042 fi
47043 
47044 done
47045 
47046     fi
47047     if test "x$ALSA_FOUND" = xno; then
47048 
47049   # Print a helpful message on how to acquire the necessary build dependency.
47050   # alsa is the help tag: freetype, cups, pulse, alsa etc
47051   MISSING_DEPENDENCY=alsa
47052 
47053   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47054     cygwin_help $MISSING_DEPENDENCY
47055   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47056     msys_help $MISSING_DEPENDENCY
47057   else
47058     PKGHANDLER_COMMAND=
47059 
47060     case $PKGHANDLER in
47061       apt-get)
47062         apt_help     $MISSING_DEPENDENCY ;;
47063       yum)
47064         yum_help     $MISSING_DEPENDENCY ;;
47065       port)
47066         port_help    $MISSING_DEPENDENCY ;;
47067       pkgutil)
47068         pkgutil_help $MISSING_DEPENDENCY ;;
47069       pkgadd)
47070         pkgadd_help  $MISSING_DEPENDENCY ;;
47071     esac
47072 
47073     if test "x$PKGHANDLER_COMMAND" != x; then
47074       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
47075     fi
47076   fi
47077 
47078       as_fn_error $? "Could not find alsa! $HELP_MSG " "$LINENO" 5
47079     fi
47080   fi
47081 
47082 
47083 
47084 
47085 
47086 
47087   ###############################################################################
47088   #
47089   # Check for the jpeg library
47090   #
47091 
47092   USE_EXTERNAL_LIBJPEG=true
47093   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -ljpeg" >&5
47094 $as_echo_n "checking for main in -ljpeg... " >&6; }
47095 if ${ac_cv_lib_jpeg_main+:} false; then :
47096   $as_echo_n "(cached) " >&6
47097 else
47098   ac_check_lib_save_LIBS=$LIBS
47099 LIBS="-ljpeg  $LIBS"
47100 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47101 /* end confdefs.h.  */
47102 
47103 
47104 int
47105 main ()
47106 {
47107 return main ();
47108   ;
47109   return 0;
47110 }
47111 _ACEOF
47112 if ac_fn_cxx_try_link "$LINENO"; then :
47113   ac_cv_lib_jpeg_main=yes
47114 else
47115   ac_cv_lib_jpeg_main=no
47116 fi
47117 rm -f core conftest.err conftest.$ac_objext \
47118     conftest$ac_exeext conftest.$ac_ext
47119 LIBS=$ac_check_lib_save_LIBS
47120 fi
47121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_main" >&5
47122 $as_echo "$ac_cv_lib_jpeg_main" >&6; }
47123 if test "x$ac_cv_lib_jpeg_main" = xyes; then :
47124   cat >>confdefs.h <<_ACEOF
47125 #define HAVE_LIBJPEG 1
47126 _ACEOF
47127 
47128   LIBS="-ljpeg $LIBS"
47129 
47130 else
47131    USE_EXTERNAL_LIBJPEG=false
47132       { $as_echo "$as_me:${as_lineno-$LINENO}: Will use jpeg decoder bundled with the OpenJDK source" >&5
47133 $as_echo "$as_me: Will use jpeg decoder bundled with the OpenJDK source" >&6;}
47134 
47135 fi
47136 
47137 
47138 
47139   ###############################################################################
47140   #
47141   # Check for the gif library
47142   #
47143 
47144 
47145 # Check whether --with-giflib was given.
47146 if test "${with_giflib+set}" = set; then :
47147   withval=$with_giflib;
47148 fi
47149 
47150 
47151 
47152   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5
47153 $as_echo_n "checking for which giflib to use... " >&6; }
47154 
47155   # default is bundled
47156   DEFAULT_GIFLIB=bundled
47157 
47158   #
47159   # if user didn't specify, use DEFAULT_GIFLIB
47160   #
47161   if test "x${with_giflib}" = "x"; then
47162     with_giflib=${DEFAULT_GIFLIB}
47163   fi
47164 
47165   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5
47166 $as_echo "${with_giflib}" >&6; }
47167 
47168   if test "x${with_giflib}" = "xbundled"; then
47169     USE_EXTERNAL_LIBGIF=false
47170   elif test "x${with_giflib}" = "xsystem"; then
47171     ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
47172 if test "x$ac_cv_header_gif_lib_h" = xyes; then :
47173 
47174 else
47175    as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5
47176 fi
47177 
47178 
47179     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5
47180 $as_echo_n "checking for DGifGetCode in -lgif... " >&6; }
47181 if ${ac_cv_lib_gif_DGifGetCode+:} false; then :
47182   $as_echo_n "(cached) " >&6
47183 else
47184   ac_check_lib_save_LIBS=$LIBS
47185 LIBS="-lgif  $LIBS"
47186 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47187 /* end confdefs.h.  */
47188 
47189 /* Override any GCC internal prototype to avoid an error.
47190    Use char because int might match the return type of a GCC
47191    builtin and then its argument prototype would still apply.  */
47192 #ifdef __cplusplus
47193 extern "C"
47194 #endif
47195 char DGifGetCode ();
47196 int
47197 main ()
47198 {
47199 return DGifGetCode ();
47200   ;
47201   return 0;
47202 }
47203 _ACEOF
47204 if ac_fn_cxx_try_link "$LINENO"; then :
47205   ac_cv_lib_gif_DGifGetCode=yes
47206 else
47207   ac_cv_lib_gif_DGifGetCode=no
47208 fi
47209 rm -f core conftest.err conftest.$ac_objext \
47210     conftest$ac_exeext conftest.$ac_ext
47211 LIBS=$ac_check_lib_save_LIBS
47212 fi
47213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5
47214 $as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; }
47215 if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then :
47216   cat >>confdefs.h <<_ACEOF
47217 #define HAVE_LIBGIF 1
47218 _ACEOF
47219 
47220   LIBS="-lgif $LIBS"
47221 
47222 else
47223    as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5
47224 fi
47225 
47226 
47227     USE_EXTERNAL_LIBGIF=true
47228   else
47229     as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5
47230   fi
47231 
47232 
47233   ###############################################################################
47234   #
47235   # Check for the zlib library
47236   #
47237 
47238 
47239 # Check whether --with-zlib was given.
47240 if test "${with_zlib+set}" = set; then :
47241   withval=$with_zlib;
47242 fi
47243 
47244 
47245   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5
47246 $as_echo_n "checking for compress in -lz... " >&6; }
47247 if ${ac_cv_lib_z_compress+:} false; then :
47248   $as_echo_n "(cached) " >&6
47249 else
47250   ac_check_lib_save_LIBS=$LIBS
47251 LIBS="-lz  $LIBS"
47252 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47253 /* end confdefs.h.  */
47254 
47255 /* Override any GCC internal prototype to avoid an error.
47256    Use char because int might match the return type of a GCC
47257    builtin and then its argument prototype would still apply.  */
47258 #ifdef __cplusplus
47259 extern "C"
47260 #endif
47261 char compress ();
47262 int
47263 main ()
47264 {
47265 return compress ();
47266   ;
47267   return 0;
47268 }
47269 _ACEOF
47270 if ac_fn_cxx_try_link "$LINENO"; then :
47271   ac_cv_lib_z_compress=yes
47272 else
47273   ac_cv_lib_z_compress=no
47274 fi
47275 rm -f core conftest.err conftest.$ac_objext \
47276     conftest$ac_exeext conftest.$ac_ext
47277 LIBS=$ac_check_lib_save_LIBS
47278 fi
47279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5
47280 $as_echo "$ac_cv_lib_z_compress" >&6; }
47281 if test "x$ac_cv_lib_z_compress" = xyes; then :
47282    ZLIB_FOUND=yes
47283 else
47284    ZLIB_FOUND=no
47285 fi
47286 
47287 
47288   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5
47289 $as_echo_n "checking for which zlib to use... " >&6; }
47290 
47291   DEFAULT_ZLIB=bundled
47292   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
47293     #
47294     # On macosx default is system...on others default is
47295     #
47296     DEFAULT_ZLIB=system
47297   fi
47298 
47299   if test "x${ZLIB_FOUND}" != "xyes"; then
47300     #
47301     # If we don't find any system...set default to bundled
47302     #
47303     DEFAULT_ZLIB=bundled
47304   fi
47305 
47306   #
47307   # If user didn't specify, use DEFAULT_ZLIB
47308   #
47309   if test "x${with_zlib}" = "x"; then
47310     with_zlib=${DEFAULT_ZLIB}
47311   fi
47312 
47313   if test "x${with_zlib}" = "xbundled"; then
47314     USE_EXTERNAL_LIBZ=false
47315     { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5
47316 $as_echo "bundled" >&6; }
47317   elif test "x${with_zlib}" = "xsystem"; then
47318     if test "x${ZLIB_FOUND}" = "xyes"; then
47319       USE_EXTERNAL_LIBZ=true
47320       { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5
47321 $as_echo "system" >&6; }
47322     else
47323       { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5
47324 $as_echo "system not found" >&6; }
47325       as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5
47326     fi
47327   else
47328     as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5
47329   fi
47330 
47331 
47332 
47333   ###############################################################################
47334   LIBZIP_CAN_USE_MMAP=true
47335 
47336 
47337 
47338   ###############################################################################
47339   #
47340   # Check if altzone exists in time.h
47341   #
47342 
47343   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47344 /* end confdefs.h.  */
47345 #include <time.h>
47346 int
47347 main ()
47348 {
47349 return (int)altzone;
47350   ;
47351   return 0;
47352 }
47353 _ACEOF
47354 if ac_fn_cxx_try_link "$LINENO"; then :
47355   has_altzone=yes
47356 else
47357   has_altzone=no
47358 fi
47359 rm -f core conftest.err conftest.$ac_objext \
47360     conftest$ac_exeext conftest.$ac_ext
47361   if test "x$has_altzone" = xyes; then
47362 
47363 $as_echo "#define HAVE_ALTZONE 1" >>confdefs.h
47364 
47365   fi
47366 
47367   ###############################################################################
47368   #
47369   # Check the maths library
47370   #
47371 
47372   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5
47373 $as_echo_n "checking for cos in -lm... " >&6; }
47374 if ${ac_cv_lib_m_cos+:} false; then :
47375   $as_echo_n "(cached) " >&6
47376 else
47377   ac_check_lib_save_LIBS=$LIBS
47378 LIBS="-lm  $LIBS"
47379 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47380 /* end confdefs.h.  */
47381 
47382 /* Override any GCC internal prototype to avoid an error.
47383    Use char because int might match the return type of a GCC
47384    builtin and then its argument prototype would still apply.  */
47385 #ifdef __cplusplus
47386 extern "C"
47387 #endif
47388 char cos ();
47389 int
47390 main ()
47391 {
47392 return cos ();
47393   ;
47394   return 0;
47395 }
47396 _ACEOF
47397 if ac_fn_cxx_try_link "$LINENO"; then :
47398   ac_cv_lib_m_cos=yes
47399 else
47400   ac_cv_lib_m_cos=no
47401 fi
47402 rm -f core conftest.err conftest.$ac_objext \
47403     conftest$ac_exeext conftest.$ac_ext
47404 LIBS=$ac_check_lib_save_LIBS
47405 fi
47406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5
47407 $as_echo "$ac_cv_lib_m_cos" >&6; }
47408 if test "x$ac_cv_lib_m_cos" = xyes; then :
47409   cat >>confdefs.h <<_ACEOF
47410 #define HAVE_LIBM 1
47411 _ACEOF
47412 
47413   LIBS="-lm $LIBS"
47414 
47415 else
47416 
47417         { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5
47418 $as_echo "$as_me: Maths library was not found" >&6;}
47419 
47420 
47421 fi
47422 
47423 
47424 
47425   ###############################################################################
47426   #
47427   # Check for libdl.so
47428 
47429   save_LIBS="$LIBS"
47430   LIBS=""
47431   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
47432 $as_echo_n "checking for dlopen in -ldl... " >&6; }
47433 if ${ac_cv_lib_dl_dlopen+:} false; then :
47434   $as_echo_n "(cached) " >&6
47435 else
47436   ac_check_lib_save_LIBS=$LIBS
47437 LIBS="-ldl  $LIBS"
47438 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47439 /* end confdefs.h.  */
47440 
47441 /* Override any GCC internal prototype to avoid an error.
47442    Use char because int might match the return type of a GCC
47443    builtin and then its argument prototype would still apply.  */
47444 #ifdef __cplusplus
47445 extern "C"
47446 #endif
47447 char dlopen ();
47448 int
47449 main ()
47450 {
47451 return dlopen ();
47452   ;
47453   return 0;
47454 }
47455 _ACEOF
47456 if ac_fn_cxx_try_link "$LINENO"; then :
47457   ac_cv_lib_dl_dlopen=yes
47458 else
47459   ac_cv_lib_dl_dlopen=no
47460 fi
47461 rm -f core conftest.err conftest.$ac_objext \
47462     conftest$ac_exeext conftest.$ac_ext
47463 LIBS=$ac_check_lib_save_LIBS
47464 fi
47465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
47466 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
47467 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
47468   cat >>confdefs.h <<_ACEOF
47469 #define HAVE_LIBDL 1
47470 _ACEOF
47471 
47472   LIBS="-ldl $LIBS"
47473 
47474 fi
47475 
47476   LIBDL="$LIBS"
47477 
47478   LIBS="$save_LIBS"
47479 
47480 
47481   ###############################################################################
47482   #
47483   # statically link libstdc++ before C++ ABI is stablized on Linux unless
47484   # dynamic build is configured on command line.
47485   #
47486 
47487 # Check whether --with-stdc++lib was given.
47488 if test "${with_stdc__lib+set}" = set; then :
47489   withval=$with_stdc__lib;
47490         if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \
47491                 && test "x$with_stdc__lib" != xdefault; then
47492           as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5
47493         fi
47494 
47495 else
47496   with_stdc__lib=default
47497 
47498 fi
47499 
47500 
47501   if test "x$OPENJDK_TARGET_OS" = xlinux; then
47502     # Test if -lstdc++ works.
47503     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dynamic link of stdc++ is possible" >&5
47504 $as_echo_n "checking if dynamic link of stdc++ is possible... " >&6; }
47505     ac_ext=cpp
47506 ac_cpp='$CXXCPP $CPPFLAGS'
47507 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47508 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47509 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47510 
47511     OLD_CXXFLAGS="$CXXFLAGS"
47512     CXXFLAGS="$CXXFLAGS -lstdc++"
47513     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47514 /* end confdefs.h.  */
47515 
47516 int
47517 main ()
47518 {
47519 return 0;
47520   ;
47521   return 0;
47522 }
47523 _ACEOF
47524 if ac_fn_cxx_try_link "$LINENO"; then :
47525   has_dynamic_libstdcxx=yes
47526 else
47527   has_dynamic_libstdcxx=no
47528 fi
47529 rm -f core conftest.err conftest.$ac_objext \
47530     conftest$ac_exeext conftest.$ac_ext
47531     CXXFLAGS="$OLD_CXXFLAGS"
47532     ac_ext=cpp
47533 ac_cpp='$CXXCPP $CPPFLAGS'
47534 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47535 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47536 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47537 
47538     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_dynamic_libstdcxx" >&5
47539 $as_echo "$has_dynamic_libstdcxx" >&6; }
47540 
47541     # Test if stdc++ can be linked statically.
47542     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5
47543 $as_echo_n "checking if static link of stdc++ is possible... " >&6; }
47544     STATIC_STDCXX_FLAGS="-Wl,-Bstatic -lstdc++ -lgcc -Wl,-Bdynamic"
47545     ac_ext=cpp
47546 ac_cpp='$CXXCPP $CPPFLAGS'
47547 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47548 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47549 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47550 
47551     OLD_LIBS="$LIBS"
47552     OLD_CXX="$CXX"
47553     LIBS="$STATIC_STDCXX_FLAGS"
47554     CXX="$CC"
47555     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47556 /* end confdefs.h.  */
47557 
47558 int
47559 main ()
47560 {
47561 return 0;
47562   ;
47563   return 0;
47564 }
47565 _ACEOF
47566 if ac_fn_cxx_try_link "$LINENO"; then :
47567   has_static_libstdcxx=yes
47568 else
47569   has_static_libstdcxx=no
47570 fi
47571 rm -f core conftest.err conftest.$ac_objext \
47572     conftest$ac_exeext conftest.$ac_ext
47573     LIBS="$OLD_LIBS"
47574     CXX="$OLD_CXX"
47575     ac_ext=cpp
47576 ac_cpp='$CXXCPP $CPPFLAGS'
47577 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
47578 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
47579 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
47580 
47581     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5
47582 $as_echo "$has_static_libstdcxx" >&6; }
47583 
47584     if test "x$has_static_libstdcxx" = xno && test "x$has_dynamic_libstdcxx" = xno; then
47585       as_fn_error $? "Cannot link to stdc++, neither dynamically nor statically!" "$LINENO" 5
47586     fi
47587 
47588     if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then
47589       as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5
47590     fi
47591 
47592     if test "x$with_stdc__lib" = xdynamic && test "x$has_dynamic_libstdcxx" = xno; then
47593       as_fn_error $? "Dynamic linking of libstdc++ was not possible!" "$LINENO" 5
47594     fi
47595 
47596     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5
47597 $as_echo_n "checking how to link with libstdc++... " >&6; }
47598     # If dynamic was requested, it's available since it would fail above otherwise.
47599     # If dynamic wasn't requested, go with static unless it isn't available.
47600     if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
47601       LIBCXX="$LIBCXX -lstdc++"
47602       LDCXX="$CXX"
47603       STATIC_CXX_SETTING="STATIC_CXX=false"
47604       { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5
47605 $as_echo "dynamic" >&6; }
47606     else
47607       LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS"
47608       LDCXX="$CC"
47609       STATIC_CXX_SETTING="STATIC_CXX=true"
47610       { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5
47611 $as_echo "static" >&6; }
47612     fi
47613   fi
47614 
47615 
47616   if test "x$JVM_VARIANT_ZERO" = xtrue || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
47617     # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS
47618 
47619 pkg_failed=no
47620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5
47621 $as_echo_n "checking for LIBFFI... " >&6; }
47622 
47623 if test -n "$LIBFFI_CFLAGS"; then
47624     pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS"
47625  elif test -n "$PKG_CONFIG"; then
47626     if test -n "$PKG_CONFIG" && \
47627     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5
47628   ($PKG_CONFIG --exists --print-errors "libffi") 2>&5
47629   ac_status=$?
47630   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
47631   test $ac_status = 0; }; then
47632   pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null`
47633 else
47634   pkg_failed=yes
47635 fi
47636  else
47637     pkg_failed=untried
47638 fi
47639 if test -n "$LIBFFI_LIBS"; then
47640     pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS"
47641  elif test -n "$PKG_CONFIG"; then
47642     if test -n "$PKG_CONFIG" && \
47643     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5
47644   ($PKG_CONFIG --exists --print-errors "libffi") 2>&5
47645   ac_status=$?
47646   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
47647   test $ac_status = 0; }; then
47648   pkg_cv_LIBFFI_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null`
47649 else
47650   pkg_failed=yes
47651 fi
47652  else
47653     pkg_failed=untried
47654 fi
47655 
47656 
47657 
47658 if test $pkg_failed = yes; then
47659 
47660 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
47661         _pkg_short_errors_supported=yes
47662 else
47663         _pkg_short_errors_supported=no
47664 fi
47665         if test $_pkg_short_errors_supported = yes; then
47666                 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1`
47667         else
47668                 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1`
47669         fi
47670         # Put the nasty error message in config.log where it belongs
47671         echo "$LIBFFI_PKG_ERRORS" >&5
47672 
47673         as_fn_error $? "Package requirements (libffi) were not met:
47674 
47675 $LIBFFI_PKG_ERRORS
47676 
47677 Consider adjusting the PKG_CONFIG_PATH environment variable if you
47678 installed software in a non-standard prefix.
47679 
47680 Alternatively, you may set the environment variables LIBFFI_CFLAGS
47681 and LIBFFI_LIBS to avoid the need to call pkg-config.
47682 See the pkg-config man page for more details.
47683 " "$LINENO" 5
47684 elif test $pkg_failed = untried; then
47685         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
47686 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
47687 as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
47688 is in your PATH or set the PKG_CONFIG environment variable to the full
47689 path to pkg-config.
47690 
47691 Alternatively, you may set the environment variables LIBFFI_CFLAGS
47692 and LIBFFI_LIBS to avoid the need to call pkg-config.
47693 See the pkg-config man page for more details.
47694 
47695 To get pkg-config, see <http://pkg-config.freedesktop.org/>.
47696 See \`config.log' for more details" "$LINENO" 5; }
47697 else
47698         LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS
47699         LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS
47700         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
47701 $as_echo "yes" >&6; }
47702         :
47703 fi
47704 
47705   fi
47706 
47707   if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
47708     # Extract the first word of "llvm-config", so it can be a program name with args.
47709 set dummy llvm-config; ac_word=$2
47710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
47711 $as_echo_n "checking for $ac_word... " >&6; }
47712 if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
47713   $as_echo_n "(cached) " >&6
47714 else
47715   if test -n "$LLVM_CONFIG"; then
47716   ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
47717 else
47718 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
47719 for as_dir in $PATH
47720 do
47721   IFS=$as_save_IFS
47722   test -z "$as_dir" && as_dir=.
47723     for ac_exec_ext in '' $ac_executable_extensions; do
47724   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
47725     ac_cv_prog_LLVM_CONFIG="llvm-config"
47726     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
47727     break 2
47728   fi
47729 done
47730   done
47731 IFS=$as_save_IFS
47732 
47733 fi
47734 fi
47735 LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
47736 if test -n "$LLVM_CONFIG"; then
47737   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
47738 $as_echo "$LLVM_CONFIG" >&6; }
47739 else
47740   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47741 $as_echo "no" >&6; }
47742 fi
47743 
47744 
47745 
47746     if test "x$LLVM_CONFIG" != xllvm-config; then
47747       as_fn_error $? "llvm-config not found in $PATH." "$LINENO" 5
47748     fi
47749 
47750     llvm_components="jit mcjit engine nativecodegen native"
47751     unset LLVM_CFLAGS
47752     for flag in $("$LLVM_CONFIG" --cxxflags); do
47753       if echo "${flag}" | grep -q '^-[ID]'; then
47754         if test "${flag}" != "-D_DEBUG" ; then
47755           if test "${LLVM_CFLAGS}" != "" ; then
47756             LLVM_CFLAGS="${LLVM_CFLAGS} "
47757           fi
47758           LLVM_CFLAGS="${LLVM_CFLAGS}${flag}"
47759         fi
47760       fi
47761     done
47762     llvm_version=$("${LLVM_CONFIG}" --version | sed 's/\.//; s/svn.*//')
47763     LLVM_CFLAGS="${LLVM_CFLAGS} -DSHARK_LLVM_VERSION=${llvm_version}"
47764 
47765     unset LLVM_LDFLAGS
47766     for flag in $("${LLVM_CONFIG}" --ldflags); do
47767       if echo "${flag}" | grep -q '^-L'; then
47768         if test "${LLVM_LDFLAGS}" != ""; then
47769           LLVM_LDFLAGS="${LLVM_LDFLAGS} "
47770         fi
47771         LLVM_LDFLAGS="${LLVM_LDFLAGS}${flag}"
47772       fi
47773     done
47774 
47775     unset LLVM_LIBS
47776     for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do
47777       if echo "${flag}" | grep -q '^-l'; then
47778         if test "${LLVM_LIBS}" != ""; then
47779           LLVM_LIBS="${LLVM_LIBS} "
47780         fi
47781         LLVM_LIBS="${LLVM_LIBS}${flag}"
47782       fi
47783     done
47784 
47785 
47786 
47787 
47788   fi
47789 
47790   # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so)
47791   if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$LIBCXX" = x; then
47792     LIBCXX="/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1"
47793   fi
47794 
47795   # TODO better (platform agnostic) test
47796   if test "x$OPENJDK_TARGET_OS" = xmacosx && test "x$LIBCXX" = x && test "x$GCC" = xyes; then
47797     LIBCXX="-lstdc++"
47798   fi
47799 
47800 
47801 
47802 
47803 
47804 ###############################################################################
47805 #
47806 # We need to do some final tweaking, when everything else is done.
47807 #
47808 ###############################################################################
47809 
47810 
47811   HOTSPOT_MAKE_ARGS="$HOTSPOT_TARGET"
47812 
47813 
47814   # The name of the Service Agent jar.
47815   SALIB_NAME="${LIBRARY_PREFIX}saproc${SHARED_LIBRARY_SUFFIX}"
47816   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
47817     SALIB_NAME="${LIBRARY_PREFIX}sawindbg${SHARED_LIBRARY_SUFFIX}"
47818   fi
47819 
47820 
47821 
47822     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5
47823 $as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; }
47824 
47825     if test -d "${SRC_ROOT}/jdk/src/share/native/sun/security/ec/impl"; then
47826       ENABLE_INTREE_EC=yes
47827       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
47828 $as_echo "yes" >&6; }
47829     else
47830       ENABLE_INTREE_EC=no
47831       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47832 $as_echo "no" >&6; }
47833     fi
47834 
47835 
47836 
47837 
47838 ###############################################################################
47839 #
47840 # Configure parts of the build that only affect the build performance,
47841 # not the result.
47842 #
47843 ###############################################################################
47844 
47845 
47846   # How many cores do we have on this build system?
47847 
47848 # Check whether --with-num-cores was given.
47849 if test "${with_num_cores+set}" = set; then :
47850   withval=$with_num_cores;
47851 fi
47852 
47853   if test "x$with_num_cores" = x; then
47854     # The number of cores were not specified, try to probe them.
47855 
47856   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5
47857 $as_echo_n "checking for number of cores... " >&6; }
47858   NUM_CORES=1
47859   FOUND_CORES=no
47860 
47861   if test -f /proc/cpuinfo; then
47862     # Looks like a Linux (or cygwin) system
47863     NUM_CORES=`cat /proc/cpuinfo  | grep -c processor`
47864     FOUND_CORES=yes
47865   elif test -x /usr/sbin/psrinfo; then
47866     # Looks like a Solaris system
47867     NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line`
47868     FOUND_CORES=yes
47869   elif test -x /usr/sbin/system_profiler; then
47870     # Looks like a MacOSX system
47871     NUM_CORES=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Cores' | awk  '{print $5}'`
47872     FOUND_CORES=yes
47873   elif test "x$OPENJDK_BUILD_OS" = xaix ; then
47874     NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print $4 }'`
47875     FOUND_CORES=yes
47876   elif test -n "$NUMBER_OF_PROCESSORS"; then
47877     # On windows, look in the env
47878     NUM_CORES=$NUMBER_OF_PROCESSORS
47879     FOUND_CORES=yes
47880   fi
47881 
47882   if test "x$FOUND_CORES" = xyes; then
47883     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5
47884 $as_echo "$NUM_CORES" >&6; }
47885   else
47886     { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5
47887 $as_echo "could not detect number of cores, defaulting to 1" >&6; }
47888     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5
47889 $as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;}
47890   fi
47891 
47892   else
47893     NUM_CORES=$with_num_cores
47894   fi
47895 
47896 
47897 
47898   # How much memory do we have on this build system?
47899 
47900 # Check whether --with-memory-size was given.
47901 if test "${with_memory_size+set}" = set; then :
47902   withval=$with_memory_size;
47903 fi
47904 
47905   if test "x$with_memory_size" = x; then
47906     # The memory size was not specified, try to probe it.
47907 
47908   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5
47909 $as_echo_n "checking for memory size... " >&6; }
47910   # Default to 1024 MB
47911   MEMORY_SIZE=1024
47912   FOUND_MEM=no
47913 
47914   if test -f /proc/meminfo; then
47915     # Looks like a Linux (or cygwin) system
47916     MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'`
47917     MEMORY_SIZE=`expr $MEMORY_SIZE / 1024`
47918     FOUND_MEM=yes
47919   elif test -x /usr/sbin/prtconf; then
47920     # Looks like a Solaris or AIX system
47921     MEMORY_SIZE=`/usr/sbin/prtconf | grep "^Memory [Ss]ize" | awk '{ print $3 }'`
47922     FOUND_MEM=yes
47923   elif test -x /usr/sbin/system_profiler; then
47924     # Looks like a MacOSX system
47925     MEMORY_SIZE=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Memory' | awk  '{print $2}'`
47926     MEMORY_SIZE=`expr $MEMORY_SIZE \* 1024`
47927     FOUND_MEM=yes
47928   elif test "x$OPENJDK_BUILD_OS" = xwindows; then
47929     # Windows, but without cygwin
47930     MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-`
47931     MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024`
47932     FOUND_MEM=yes
47933   fi
47934 
47935   if test "x$FOUND_MEM" = xyes; then
47936     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5
47937 $as_echo "$MEMORY_SIZE MB" >&6; }
47938   else
47939     { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to 1024 MB" >&5
47940 $as_echo "could not detect memory size, defaulting to 1024 MB" >&6; }
47941     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5
47942 $as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;}
47943   fi
47944 
47945   else
47946     MEMORY_SIZE=$with_memory_size
47947   fi
47948 
47949 
47950 
47951   # Provide a decent default number of parallel jobs for make depending on
47952   # number of cores, amount of memory and machine architecture.
47953 
47954 # Check whether --with-jobs was given.
47955 if test "${with_jobs+set}" = set; then :
47956   withval=$with_jobs;
47957 fi
47958 
47959   if test "x$with_jobs" = x; then
47960     # Number of jobs was not specified, calculate.
47961     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5
47962 $as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; }
47963     # Approximate memory in GB, rounding up a bit.
47964     memory_gb=`expr $MEMORY_SIZE / 1100`
47965     # Pick the lowest of memory in gb and number of cores.
47966     if test "$memory_gb" -lt "$NUM_CORES"; then
47967       JOBS="$memory_gb"
47968     else
47969       JOBS="$NUM_CORES"
47970       # On bigger machines, leave some room for other processes to run
47971       if test "$JOBS" -gt "4"; then
47972         JOBS=`expr $JOBS '*' 90 / 100`
47973       fi
47974     fi
47975     # Cap number of jobs to 16
47976     if test "$JOBS" -gt "16"; then
47977       JOBS=16
47978     fi
47979     if test "$JOBS" -eq "0"; then
47980       JOBS=1
47981     fi
47982     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5
47983 $as_echo "$JOBS" >&6; }
47984   else
47985     JOBS=$with_jobs
47986   fi
47987 
47988 
47989 
47990 # Setup smart javac (after cores and memory have been setup)
47991 
47992 
47993 # Check whether --with-sjavac-server-java was given.
47994 if test "${with_sjavac_server_java+set}" = set; then :
47995   withval=$with_sjavac_server_java;
47996 fi
47997 
47998 
47999   if test "x$with_sjavac_server_java" != x; then
48000     SJAVAC_SERVER_JAVA="$with_sjavac_server_java"
48001     FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""`
48002     if test "x$FOUND_VERSION" = x; then
48003       as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5
48004     fi
48005   else
48006     SJAVAC_SERVER_JAVA=""
48007     # Hotspot specific options.
48008 
48009   $ECHO "Check if jvm arg is ok: -verbosegc" >&5
48010   $ECHO "Command: $JAVA -verbosegc -version" >&5
48011   OUTPUT=`$JAVA -verbosegc -version 2>&1`
48012   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48013   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48014   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48015     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -verbosegc"
48016     JVM_ARG_OK=true
48017   else
48018     $ECHO "Arg failed:" >&5
48019     $ECHO "$OUTPUT" >&5
48020     JVM_ARG_OK=false
48021   fi
48022 
48023     # JRockit specific options.
48024 
48025   $ECHO "Check if jvm arg is ok: -Xverbose:gc" >&5
48026   $ECHO "Command: $JAVA -Xverbose:gc -version" >&5
48027   OUTPUT=`$JAVA -Xverbose:gc -version 2>&1`
48028   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48029   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48030   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48031     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xverbose:gc"
48032     JVM_ARG_OK=true
48033   else
48034     $ECHO "Arg failed:" >&5
48035     $ECHO "$OUTPUT" >&5
48036     JVM_ARG_OK=false
48037   fi
48038 
48039     SJAVAC_SERVER_JAVA="$JAVA $SJAVAC_SERVER_JAVA"
48040   fi
48041 
48042 
48043   if test "$MEMORY_SIZE" -gt "2500"; then
48044 
48045   $ECHO "Check if jvm arg is ok: -d64" >&5
48046   $ECHO "Command: $SJAVAC_SERVER_JAVA -d64 -version" >&5
48047   OUTPUT=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1`
48048   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48049   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48050   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48051     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -d64"
48052     JVM_ARG_OK=true
48053   else
48054     $ECHO "Arg failed:" >&5
48055     $ECHO "$OUTPUT" >&5
48056     JVM_ARG_OK=false
48057   fi
48058 
48059     if test "$JVM_ARG_OK" = true; then
48060       JVM_64BIT=true
48061       JVM_ARG_OK=false
48062     fi
48063   fi
48064 
48065   if test "$JVM_64BIT" = true; then
48066     if test "$MEMORY_SIZE" -gt "17000"; then
48067 
48068   $ECHO "Check if jvm arg is ok: -Xms10G -Xmx10G" >&5
48069   $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms10G -Xmx10G -version" >&5
48070   OUTPUT=`$SJAVAC_SERVER_JAVA -Xms10G -Xmx10G -version 2>&1`
48071   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48072   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48073   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48074     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms10G -Xmx10G"
48075     JVM_ARG_OK=true
48076   else
48077     $ECHO "Arg failed:" >&5
48078     $ECHO "$OUTPUT" >&5
48079     JVM_ARG_OK=false
48080   fi
48081 
48082     fi
48083     if test "$MEMORY_SIZE" -gt "10000" && test "$JVM_ARG_OK" = false; then
48084 
48085   $ECHO "Check if jvm arg is ok: -Xms6G -Xmx6G" >&5
48086   $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms6G -Xmx6G -version" >&5
48087   OUTPUT=`$SJAVAC_SERVER_JAVA -Xms6G -Xmx6G -version 2>&1`
48088   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48089   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48090   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48091     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms6G -Xmx6G"
48092     JVM_ARG_OK=true
48093   else
48094     $ECHO "Arg failed:" >&5
48095     $ECHO "$OUTPUT" >&5
48096     JVM_ARG_OK=false
48097   fi
48098 
48099     fi
48100     if test "$MEMORY_SIZE" -gt "5000" && test "$JVM_ARG_OK" = false; then
48101 
48102   $ECHO "Check if jvm arg is ok: -Xms1G -Xmx3G" >&5
48103   $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1G -Xmx3G -version" >&5
48104   OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1G -Xmx3G -version 2>&1`
48105   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48106   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48107   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48108     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1G -Xmx3G"
48109     JVM_ARG_OK=true
48110   else
48111     $ECHO "Arg failed:" >&5
48112     $ECHO "$OUTPUT" >&5
48113     JVM_ARG_OK=false
48114   fi
48115 
48116     fi
48117     if test "$MEMORY_SIZE" -gt "3800" && test "$JVM_ARG_OK" = false; then
48118 
48119   $ECHO "Check if jvm arg is ok: -Xms1G -Xmx2500M" >&5
48120   $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M -version" >&5
48121   OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M -version 2>&1`
48122   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48123   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48124   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48125     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1G -Xmx2500M"
48126     JVM_ARG_OK=true
48127   else
48128     $ECHO "Arg failed:" >&5
48129     $ECHO "$OUTPUT" >&5
48130     JVM_ARG_OK=false
48131   fi
48132 
48133     fi
48134   fi
48135   if test "$MEMORY_SIZE" -gt "2500" && test "$JVM_ARG_OK" = false; then
48136 
48137   $ECHO "Check if jvm arg is ok: -Xms1000M -Xmx1500M" >&5
48138   $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M -version" >&5
48139   OUTPUT=`$SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M -version 2>&1`
48140   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48141   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48142   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48143     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms1000M -Xmx1500M"
48144     JVM_ARG_OK=true
48145   else
48146     $ECHO "Arg failed:" >&5
48147     $ECHO "$OUTPUT" >&5
48148     JVM_ARG_OK=false
48149   fi
48150 
48151   fi
48152   if test "$MEMORY_SIZE" -gt "1000" && test "$JVM_ARG_OK" = false; then
48153 
48154   $ECHO "Check if jvm arg is ok: -Xms400M -Xmx1100M" >&5
48155   $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M -version" >&5
48156   OUTPUT=`$SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M -version 2>&1`
48157   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48158   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48159   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48160     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms400M -Xmx1100M"
48161     JVM_ARG_OK=true
48162   else
48163     $ECHO "Arg failed:" >&5
48164     $ECHO "$OUTPUT" >&5
48165     JVM_ARG_OK=false
48166   fi
48167 
48168   fi
48169   if test "$JVM_ARG_OK" = false; then
48170 
48171   $ECHO "Check if jvm arg is ok: -Xms256M -Xmx512M" >&5
48172   $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms256M -Xmx512M -version" >&5
48173   OUTPUT=`$SJAVAC_SERVER_JAVA -Xms256M -Xmx512M -version 2>&1`
48174   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
48175   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
48176   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
48177     SJAVAC_SERVER_JAVA="$SJAVAC_SERVER_JAVA -Xms256M -Xmx512M"
48178     JVM_ARG_OK=true
48179   else
48180     $ECHO "Arg failed:" >&5
48181     $ECHO "$OUTPUT" >&5
48182     JVM_ARG_OK=false
48183   fi
48184 
48185   fi
48186 
48187   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5
48188 $as_echo_n "checking whether to use sjavac... " >&6; }
48189   # Check whether --enable-sjavac was given.
48190 if test "${enable_sjavac+set}" = set; then :
48191   enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}"
48192 else
48193   ENABLE_SJAVAC='no'
48194 fi
48195 
48196   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5
48197 $as_echo "$ENABLE_SJAVAC" >&6; }
48198 
48199 
48200   if test "x$ENABLE_SJAVAC" = xyes; then
48201     SJAVAC_SERVER_DIR="$OUTPUT_ROOT/javacservers"
48202   else
48203     SJAVAC_SERVER_DIR=
48204   fi
48205 
48206 
48207 
48208 # Can the C/C++ compiler use precompiled headers?
48209 
48210 
48211   ###############################################################################
48212   #
48213   # Can the C/C++ compiler use precompiled headers?
48214   #
48215   # Check whether --enable-precompiled-headers was given.
48216 if test "${enable_precompiled_headers+set}" = set; then :
48217   enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers}
48218 else
48219   ENABLE_PRECOMPH=yes
48220 fi
48221 
48222 
48223   USE_PRECOMPILED_HEADER=1
48224   if test "x$ENABLE_PRECOMPH" = xno; then
48225     USE_PRECOMPILED_HEADER=0
48226   fi
48227 
48228   if test "x$ENABLE_PRECOMPH" = xyes; then
48229     # Check that the compiler actually supports precomp headers.
48230     if test "x$GCC" = xyes; then
48231       { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5
48232 $as_echo_n "checking that precompiled headers work... " >&6; }
48233       echo "int alfa();" > conftest.h
48234       $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5
48235       if test ! -f conftest.hpp.gch; then
48236         USE_PRECOMPILED_HEADER=0
48237         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48238 $as_echo "no" >&6; }
48239       else
48240         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48241 $as_echo "yes" >&6; }
48242       fi
48243       rm -f conftest.h conftest.hpp.gch
48244     fi
48245   fi
48246 
48247 
48248 
48249 
48250 # Setup use of ccache, if available
48251 
48252   # Check whether --enable-ccache was given.
48253 if test "${enable_ccache+set}" = set; then :
48254   enableval=$enable_ccache;
48255 fi
48256 
48257 
48258   CCACHE=
48259   { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5
48260 $as_echo_n "checking is ccache enabled... " >&6; }
48261   ENABLE_CCACHE=$enable_ccache
48262   if test "x$enable_ccache" = xyes; then
48263     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48264 $as_echo "yes" >&6; }
48265     OLD_PATH="$PATH"
48266     if test "x$TOOLS_DIR" != x; then
48267       PATH=$TOOLS_DIR:$PATH
48268     fi
48269 
48270 
48271 
48272   # Publish this variable in the help.
48273 
48274 
48275   if test "x$CCACHE" = x; then
48276     # The variable is not set by user, try to locate tool using the code snippet
48277     for ac_prog in ccache
48278 do
48279   # Extract the first word of "$ac_prog", so it can be a program name with args.
48280 set dummy $ac_prog; ac_word=$2
48281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48282 $as_echo_n "checking for $ac_word... " >&6; }
48283 if ${ac_cv_path_CCACHE+:} false; then :
48284   $as_echo_n "(cached) " >&6
48285 else
48286   case $CCACHE in
48287   [\\/]* | ?:[\\/]*)
48288   ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
48289   ;;
48290   *)
48291   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48292 for as_dir in $PATH
48293 do
48294   IFS=$as_save_IFS
48295   test -z "$as_dir" && as_dir=.
48296     for ac_exec_ext in '' $ac_executable_extensions; do
48297   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48298     ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
48299     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48300     break 2
48301   fi
48302 done
48303   done
48304 IFS=$as_save_IFS
48305 
48306   ;;
48307 esac
48308 fi
48309 CCACHE=$ac_cv_path_CCACHE
48310 if test -n "$CCACHE"; then
48311   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
48312 $as_echo "$CCACHE" >&6; }
48313 else
48314   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48315 $as_echo "no" >&6; }
48316 fi
48317 
48318 
48319   test -n "$CCACHE" && break
48320 done
48321 
48322   else
48323     # The variable is set, but is it from the command line or the environment?
48324 
48325     # Try to remove the string !CCACHE! from our list.
48326     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CCACHE!/}
48327     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
48328       # If it failed, the variable was not from the command line. Ignore it,
48329       # but warn the user (except for BASH, which is always set by the calling BASH).
48330       if test "xCCACHE" != xBASH; then
48331         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&5
48332 $as_echo "$as_me: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&2;}
48333       fi
48334       # Try to locate tool using the code snippet
48335       for ac_prog in ccache
48336 do
48337   # Extract the first word of "$ac_prog", so it can be a program name with args.
48338 set dummy $ac_prog; ac_word=$2
48339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48340 $as_echo_n "checking for $ac_word... " >&6; }
48341 if ${ac_cv_path_CCACHE+:} false; then :
48342   $as_echo_n "(cached) " >&6
48343 else
48344   case $CCACHE in
48345   [\\/]* | ?:[\\/]*)
48346   ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
48347   ;;
48348   *)
48349   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48350 for as_dir in $PATH
48351 do
48352   IFS=$as_save_IFS
48353   test -z "$as_dir" && as_dir=.
48354     for ac_exec_ext in '' $ac_executable_extensions; do
48355   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48356     ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
48357     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48358     break 2
48359   fi
48360 done
48361   done
48362 IFS=$as_save_IFS
48363 
48364   ;;
48365 esac
48366 fi
48367 CCACHE=$ac_cv_path_CCACHE
48368 if test -n "$CCACHE"; then
48369   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
48370 $as_echo "$CCACHE" >&6; }
48371 else
48372   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48373 $as_echo "no" >&6; }
48374 fi
48375 
48376 
48377   test -n "$CCACHE" && break
48378 done
48379 
48380     else
48381       # If it succeeded, then it was overridden by the user. We will use it
48382       # for the tool.
48383 
48384       # First remove it from the list of overridden variables, so we can test
48385       # for unknown variables in the end.
48386       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
48387 
48388       # Check if the provided tool contains a complete path.
48389       tool_specified="$CCACHE"
48390       tool_basename="${tool_specified##*/}"
48391       if test "x$tool_basename" = "x$tool_specified"; then
48392         # A command without a complete path is provided, search $PATH.
48393         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CCACHE=$tool_basename" >&5
48394 $as_echo "$as_me: Will search for user supplied tool CCACHE=$tool_basename" >&6;}
48395         # Extract the first word of "$tool_basename", so it can be a program name with args.
48396 set dummy $tool_basename; ac_word=$2
48397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48398 $as_echo_n "checking for $ac_word... " >&6; }
48399 if ${ac_cv_path_CCACHE+:} false; then :
48400   $as_echo_n "(cached) " >&6
48401 else
48402   case $CCACHE in
48403   [\\/]* | ?:[\\/]*)
48404   ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
48405   ;;
48406   *)
48407   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48408 for as_dir in $PATH
48409 do
48410   IFS=$as_save_IFS
48411   test -z "$as_dir" && as_dir=.
48412     for ac_exec_ext in '' $ac_executable_extensions; do
48413   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48414     ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
48415     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48416     break 2
48417   fi
48418 done
48419   done
48420 IFS=$as_save_IFS
48421 
48422   ;;
48423 esac
48424 fi
48425 CCACHE=$ac_cv_path_CCACHE
48426 if test -n "$CCACHE"; then
48427   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
48428 $as_echo "$CCACHE" >&6; }
48429 else
48430   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48431 $as_echo "no" >&6; }
48432 fi
48433 
48434 
48435         if test "x$CCACHE" = x; then
48436           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
48437         fi
48438       else
48439         # Otherwise we believe it is a complete path. Use it as it is.
48440         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CCACHE=$tool_specified" >&5
48441 $as_echo "$as_me: Will use user supplied tool CCACHE=$tool_specified" >&6;}
48442         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5
48443 $as_echo_n "checking for CCACHE... " >&6; }
48444         if test ! -x "$tool_specified"; then
48445           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
48446 $as_echo "not found" >&6; }
48447           as_fn_error $? "User supplied tool CCACHE=$tool_specified does not exist or is not executable" "$LINENO" 5
48448         fi
48449         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
48450 $as_echo "$tool_specified" >&6; }
48451       fi
48452     fi
48453   fi
48454 
48455 
48456 
48457   if test "x$CCACHE" = x; then
48458     as_fn_error $? "Could not find required tool for CCACHE" "$LINENO" 5
48459   fi
48460 
48461 
48462     CCACHE_STATUS="enabled"
48463     PATH="$OLD_PATH"
48464   elif test "x$enable_ccache" = xno; then
48465     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, explicitly disabled" >&5
48466 $as_echo "no, explicitly disabled" >&6; }
48467   elif test "x$enable_ccache" = x; then
48468     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48469 $as_echo "no" >&6; }
48470   else
48471     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5
48472 $as_echo "unknown" >&6; }
48473     as_fn_error $? "--enable-ccache does not accept any parameters" "$LINENO" 5
48474   fi
48475 
48476 
48477 
48478 # Check whether --with-ccache-dir was given.
48479 if test "${with_ccache_dir+set}" = set; then :
48480   withval=$with_ccache_dir;
48481 fi
48482 
48483 
48484   if test "x$with_ccache_dir" != x; then
48485     # When using a non home ccache directory, assume the use is to share ccache files
48486     # with other users. Thus change the umask.
48487     SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002"
48488     if test "x$CCACHE" = x; then
48489       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&5
48490 $as_echo "$as_me: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&2;}
48491     fi
48492   fi
48493 
48494   if test "x$CCACHE" != x; then
48495 
48496   if test "x$CCACHE" != x; then
48497     # Only use ccache if it is 3.1.4 or later, which supports
48498     # precompiled headers.
48499     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ccache supports precompiled headers" >&5
48500 $as_echo_n "checking if ccache supports precompiled headers... " >&6; }
48501     HAS_GOOD_CCACHE=`($CCACHE --version | head -n 1 | grep -E 3.1.[456789]) 2> /dev/null`
48502     if test "x$HAS_GOOD_CCACHE" = x; then
48503       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabling ccache" >&5
48504 $as_echo "no, disabling ccache" >&6; }
48505       CCACHE=
48506       CCACHE_STATUS="disabled"
48507     else
48508       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48509 $as_echo "yes" >&6; }
48510       { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5
48511 $as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; }
48512       PUSHED_FLAGS="$CXXFLAGS"
48513       CXXFLAGS="-fpch-preprocess $CXXFLAGS"
48514       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
48515 /* end confdefs.h.  */
48516 
48517 int
48518 main ()
48519 {
48520 
48521   ;
48522   return 0;
48523 }
48524 _ACEOF
48525 if ac_fn_cxx_try_compile "$LINENO"; then :
48526   CC_KNOWS_CCACHE_TRICK=yes
48527 else
48528   CC_KNOWS_CCACHE_TRICK=no
48529 fi
48530 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
48531       CXXFLAGS="$PUSHED_FLAGS"
48532       if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then
48533         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48534 $as_echo "yes" >&6; }
48535       else
48536         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabling ccaching of precompiled headers" >&5
48537 $as_echo "no, disabling ccaching of precompiled headers" >&6; }
48538         CCACHE=
48539         CCACHE_STATUS="disabled"
48540       fi
48541     fi
48542   fi
48543 
48544   if test "x$CCACHE" != x; then
48545     CCACHE_SLOPPINESS=time_macros
48546     CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS $CCACHE"
48547     CCACHE_FLAGS=-fpch-preprocess
48548 
48549     if test "x$SET_CCACHE_DIR" != x; then
48550       mkdir -p $CCACHE_DIR > /dev/null 2>&1
48551       chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1
48552     fi
48553   fi
48554 
48555   fi
48556 
48557 
48558 ###############################################################################
48559 #
48560 # And now the finish...
48561 #
48562 ###############################################################################
48563 
48564 # Check for some common pitfalls
48565 
48566   if test x"$OPENJDK_BUILD_OS" = xwindows; then
48567     file_to_test="$SRC_ROOT/LICENSE"
48568     if test `$STAT -c '%a' "$file_to_test"` -lt 400; then
48569       as_fn_error $? "Bad file permissions on src files. This is usually caused by cloning the repositories with a non cygwin hg in a directory not created in cygwin." "$LINENO" 5
48570     fi
48571   fi
48572 
48573 
48574   # Did user specify any unknown variables?
48575 
48576   if test "x$CONFIGURE_OVERRIDDEN_VARIABLES" != x; then
48577     # Replace the separating ! with spaces before presenting for end user.
48578     unknown_variables=${CONFIGURE_OVERRIDDEN_VARIABLES//!/ }
48579     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The following variables might be unknown to configure: $unknown_variables" >&5
48580 $as_echo "$as_me: WARNING: The following variables might be unknown to configure: $unknown_variables" >&2;}
48581   fi
48582 
48583 
48584   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5
48585 $as_echo_n "checking if build directory is on local disk... " >&6; }
48586 
48587   # df -l lists only local disks; if the given directory is not found then
48588   # a non-zero exit code is given
48589   if test "x$DF" = x; then
48590     if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48591       # msys does not have df; use Windows "net use" instead.
48592       IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:`
48593       if test "x$IS_NETWORK_DISK" = x; then
48594         OUTPUT_DIR_IS_LOCAL="yes"
48595       else
48596         OUTPUT_DIR_IS_LOCAL="no"
48597       fi
48598     else
48599       # No df here, say it's local
48600       OUTPUT_DIR_IS_LOCAL="yes"
48601     fi
48602   else
48603     if $DF -l $OUTPUT_ROOT > /dev/null 2>&1; then
48604       OUTPUT_DIR_IS_LOCAL="yes"
48605     else
48606       OUTPUT_DIR_IS_LOCAL="no"
48607     fi
48608   fi
48609 
48610   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5
48611 $as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; }
48612 
48613 
48614 
48615   # Check if the user has any old-style ALT_ variables set.
48616   FOUND_ALT_VARIABLES=`env | grep ^ALT_`
48617 
48618   # Before generating output files, test if they exist. If they do, this is a reconfigure.
48619   # Since we can't properly handle the dependencies for this, warn the user about the situation
48620   if test -e $OUTPUT_ROOT/spec.gmk; then
48621     IS_RECONFIGURE=yes
48622   else
48623     IS_RECONFIGURE=no
48624   fi
48625 
48626 
48627 # At the end, call the custom hook. (Dummy macro if no custom sources available)
48628 
48629 
48630 # We're messing a bit with internal autoconf variables to put the config.status
48631 # in the output directory instead of the current directory.
48632 CONFIG_STATUS="$OUTPUT_ROOT/config.status"
48633 
48634 # Create the actual output files. Now the main work of configure is done.
48635 cat >confcache <<\_ACEOF
48636 # This file is a shell script that caches the results of configure
48637 # tests run on this system so they can be shared between configure
48638 # scripts and configure runs, see configure's option --config-cache.
48639 # It is not useful on other systems.  If it contains results you don't
48640 # want to keep, you may remove or edit it.
48641 #
48642 # config.status only pays attention to the cache file if you give it
48643 # the --recheck option to rerun configure.
48644 #
48645 # `ac_cv_env_foo' variables (set or unset) will be overridden when
48646 # loading this file, other *unset* `ac_cv_foo' will be assigned the
48647 # following values.
48648 
48649 _ACEOF
48650 
48651 # The following way of writing the cache mishandles newlines in values,
48652 # but we know of no workaround that is simple, portable, and efficient.
48653 # So, we kill variables containing newlines.
48654 # Ultrix sh set writes to stderr and can't be redirected directly,
48655 # and sets the high bit in the cache file unless we assign to the vars.
48656 (
48657   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
48658     eval ac_val=\$$ac_var
48659     case $ac_val in #(
48660     *${as_nl}*)
48661       case $ac_var in #(
48662       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
48663 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
48664       esac
48665       case $ac_var in #(
48666       _ | IFS | as_nl) ;; #(
48667       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
48668       *) { eval $ac_var=; unset $ac_var;} ;;
48669       esac ;;
48670     esac
48671   done
48672 
48673   (set) 2>&1 |
48674     case $as_nl`(ac_space=' '; set) 2>&1` in #(
48675     *${as_nl}ac_space=\ *)
48676       # `set' does not quote correctly, so add quotes: double-quote
48677       # substitution turns \\\\ into \\, and sed turns \\ into \.
48678       sed -n \
48679         "s/'/'\\\\''/g;
48680           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
48681       ;; #(
48682     *)
48683       # `set' quotes correctly as required by POSIX, so do not add quotes.
48684       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
48685       ;;
48686     esac |
48687     sort
48688 ) |
48689   sed '
48690      /^ac_cv_env_/b end
48691      t clear
48692      :clear
48693      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
48694      t end
48695      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
48696      :end' >>confcache
48697 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
48698   if test -w "$cache_file"; then
48699     if test "x$cache_file" != "x/dev/null"; then
48700       { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
48701 $as_echo "$as_me: updating cache $cache_file" >&6;}
48702       if test ! -f "$cache_file" || test -h "$cache_file"; then
48703         cat confcache >"$cache_file"
48704       else
48705         case $cache_file in #(
48706         */* | ?:*)
48707           mv -f confcache "$cache_file"$$ &&
48708           mv -f "$cache_file"$$ "$cache_file" ;; #(
48709         *)
48710           mv -f confcache "$cache_file" ;;
48711         esac
48712       fi
48713     fi
48714   else
48715     { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
48716 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
48717   fi
48718 fi
48719 rm -f confcache
48720 
48721 test "x$prefix" = xNONE && prefix=$ac_default_prefix
48722 # Let make expand exec_prefix.
48723 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
48724 
48725 DEFS=-DHAVE_CONFIG_H
48726 
48727 ac_libobjs=
48728 ac_ltlibobjs=
48729 U=
48730 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
48731   # 1. Remove the extension, and $U if already installed.
48732   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
48733   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
48734   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
48735   #    will be set to the directory where LIBOBJS objects are built.
48736   as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
48737   as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
48738 done
48739 LIBOBJS=$ac_libobjs
48740 
48741 LTLIBOBJS=$ac_ltlibobjs
48742 
48743 
48744 
48745 : "${CONFIG_STATUS=./config.status}"
48746 ac_write_fail=0
48747 ac_clean_files_save=$ac_clean_files
48748 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
48749 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
48750 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
48751 as_write_fail=0
48752 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
48753 #! $SHELL
48754 # Generated by $as_me.
48755 # Run this file to recreate the current configuration.
48756 # Compiler output produced by configure, useful for debugging
48757 # configure, is in config.log if it exists.
48758 
48759 debug=false
48760 ac_cs_recheck=false
48761 ac_cs_silent=false
48762 
48763 SHELL=\${CONFIG_SHELL-$SHELL}
48764 export SHELL
48765 _ASEOF
48766 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
48767 ## -------------------- ##
48768 ## M4sh Initialization. ##
48769 ## -------------------- ##
48770 
48771 # Be more Bourne compatible
48772 DUALCASE=1; export DUALCASE # for MKS sh
48773 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
48774   emulate sh
48775   NULLCMD=:
48776   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
48777   # is contrary to our usage.  Disable this feature.
48778   alias -g '${1+"$@"}'='"$@"'
48779   setopt NO_GLOB_SUBST
48780 else
48781   case `(set -o) 2>/dev/null` in #(
48782   *posix*) :
48783     set -o posix ;; #(
48784   *) :
48785      ;;
48786 esac
48787 fi
48788 
48789 
48790 as_nl='
48791 '
48792 export as_nl
48793 # Printing a long string crashes Solaris 7 /usr/bin/printf.
48794 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
48795 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
48796 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
48797 # Prefer a ksh shell builtin over an external printf program on Solaris,
48798 # but without wasting forks for bash or zsh.
48799 if test -z "$BASH_VERSION$ZSH_VERSION" \
48800     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
48801   as_echo='print -r --'
48802   as_echo_n='print -rn --'
48803 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
48804   as_echo='printf %s\n'
48805   as_echo_n='printf %s'
48806 else
48807   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
48808     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
48809     as_echo_n='/usr/ucb/echo -n'
48810   else
48811     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
48812     as_echo_n_body='eval
48813       arg=$1;
48814       case $arg in #(
48815       *"$as_nl"*)
48816         expr "X$arg" : "X\\(.*\\)$as_nl";
48817         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
48818       esac;
48819       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
48820     '
48821     export as_echo_n_body
48822     as_echo_n='sh -c $as_echo_n_body as_echo'
48823   fi
48824   export as_echo_body
48825   as_echo='sh -c $as_echo_body as_echo'
48826 fi
48827 
48828 # The user is always right.
48829 if test "${PATH_SEPARATOR+set}" != set; then
48830   PATH_SEPARATOR=:
48831   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
48832     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
48833       PATH_SEPARATOR=';'
48834   }
48835 fi
48836 
48837 
48838 # IFS
48839 # We need space, tab and new line, in precisely that order.  Quoting is
48840 # there to prevent editors from complaining about space-tab.
48841 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
48842 # splitting by setting IFS to empty value.)
48843 IFS=" ""        $as_nl"
48844 
48845 # Find who we are.  Look in the path if we contain no directory separator.
48846 as_myself=
48847 case $0 in #((
48848   *[\\/]* ) as_myself=$0 ;;
48849   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48850 for as_dir in $PATH
48851 do
48852   IFS=$as_save_IFS
48853   test -z "$as_dir" && as_dir=.
48854     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
48855   done
48856 IFS=$as_save_IFS
48857 
48858      ;;
48859 esac
48860 # We did not find ourselves, most probably we were run as `sh COMMAND'
48861 # in which case we are not to be found in the path.
48862 if test "x$as_myself" = x; then
48863   as_myself=$0
48864 fi
48865 if test ! -f "$as_myself"; then
48866   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
48867   exit 1
48868 fi
48869 
48870 # Unset variables that we do not need and which cause bugs (e.g. in
48871 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
48872 # suppresses any "Segmentation fault" message there.  '((' could
48873 # trigger a bug in pdksh 5.2.14.
48874 for as_var in BASH_ENV ENV MAIL MAILPATH
48875 do eval test x\${$as_var+set} = xset \
48876   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
48877 done
48878 PS1='$ '
48879 PS2='> '
48880 PS4='+ '
48881 
48882 # NLS nuisances.
48883 LC_ALL=C
48884 export LC_ALL
48885 LANGUAGE=C
48886 export LANGUAGE
48887 
48888 # CDPATH.
48889 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
48890 
48891 
48892 # as_fn_error STATUS ERROR [LINENO LOG_FD]
48893 # ----------------------------------------
48894 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
48895 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
48896 # script with STATUS, using 1 if that was 0.
48897 as_fn_error ()
48898 {
48899   as_status=$1; test $as_status -eq 0 && as_status=1
48900   if test "$4"; then
48901     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
48902     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
48903   fi
48904   $as_echo "$as_me: error: $2" >&2
48905   as_fn_exit $as_status
48906 } # as_fn_error
48907 
48908 
48909 # as_fn_set_status STATUS
48910 # -----------------------
48911 # Set $? to STATUS, without forking.
48912 as_fn_set_status ()
48913 {
48914   return $1
48915 } # as_fn_set_status
48916 
48917 # as_fn_exit STATUS
48918 # -----------------
48919 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
48920 as_fn_exit ()
48921 {
48922   set +e
48923   as_fn_set_status $1
48924   exit $1
48925 } # as_fn_exit
48926 
48927 # as_fn_unset VAR
48928 # ---------------
48929 # Portably unset VAR.
48930 as_fn_unset ()
48931 {
48932   { eval $1=; unset $1;}
48933 }
48934 as_unset=as_fn_unset
48935 # as_fn_append VAR VALUE
48936 # ----------------------
48937 # Append the text in VALUE to the end of the definition contained in VAR. Take
48938 # advantage of any shell optimizations that allow amortized linear growth over
48939 # repeated appends, instead of the typical quadratic growth present in naive
48940 # implementations.
48941 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
48942   eval 'as_fn_append ()
48943   {
48944     eval $1+=\$2
48945   }'
48946 else
48947   as_fn_append ()
48948   {
48949     eval $1=\$$1\$2
48950   }
48951 fi # as_fn_append
48952 
48953 # as_fn_arith ARG...
48954 # ------------------
48955 # Perform arithmetic evaluation on the ARGs, and store the result in the
48956 # global $as_val. Take advantage of shells that can avoid forks. The arguments
48957 # must be portable across $(()) and expr.
48958 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
48959   eval 'as_fn_arith ()
48960   {
48961     as_val=$(( $* ))
48962   }'
48963 else
48964   as_fn_arith ()
48965   {
48966     as_val=`expr "$@" || test $? -eq 1`
48967   }
48968 fi # as_fn_arith
48969 
48970 
48971 if expr a : '\(a\)' >/dev/null 2>&1 &&
48972    test "X`expr 00001 : '.*\(...\)'`" = X001; then
48973   as_expr=expr
48974 else
48975   as_expr=false
48976 fi
48977 
48978 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
48979   as_basename=basename
48980 else
48981   as_basename=false
48982 fi
48983 
48984 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
48985   as_dirname=dirname
48986 else
48987   as_dirname=false
48988 fi
48989 
48990 as_me=`$as_basename -- "$0" ||
48991 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
48992          X"$0" : 'X\(//\)$' \| \
48993          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
48994 $as_echo X/"$0" |
48995     sed '/^.*\/\([^/][^/]*\)\/*$/{
48996             s//\1/
48997             q
48998           }
48999           /^X\/\(\/\/\)$/{
49000             s//\1/
49001             q
49002           }
49003           /^X\/\(\/\).*/{
49004             s//\1/
49005             q
49006           }
49007           s/.*/./; q'`
49008 
49009 # Avoid depending upon Character Ranges.
49010 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
49011 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
49012 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
49013 as_cr_digits='0123456789'
49014 as_cr_alnum=$as_cr_Letters$as_cr_digits
49015 
49016 ECHO_C= ECHO_N= ECHO_T=
49017 case `echo -n x` in #(((((
49018 -n*)
49019   case `echo 'xy\c'` in
49020   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
49021   xy)  ECHO_C='\c';;
49022   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
49023        ECHO_T=' ';;
49024   esac;;
49025 *)
49026   ECHO_N='-n';;
49027 esac
49028 
49029 rm -f conf$$ conf$$.exe conf$$.file
49030 if test -d conf$$.dir; then
49031   rm -f conf$$.dir/conf$$.file
49032 else
49033   rm -f conf$$.dir
49034   mkdir conf$$.dir 2>/dev/null
49035 fi
49036 if (echo >conf$$.file) 2>/dev/null; then
49037   if ln -s conf$$.file conf$$ 2>/dev/null; then
49038     as_ln_s='ln -s'
49039     # ... but there are two gotchas:
49040     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
49041     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
49042     # In both cases, we have to default to `cp -pR'.
49043     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
49044       as_ln_s='cp -pR'
49045   elif ln conf$$.file conf$$ 2>/dev/null; then
49046     as_ln_s=ln
49047   else
49048     as_ln_s='cp -pR'
49049   fi
49050 else
49051   as_ln_s='cp -pR'
49052 fi
49053 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
49054 rmdir conf$$.dir 2>/dev/null
49055 
49056 
49057 # as_fn_mkdir_p
49058 # -------------
49059 # Create "$as_dir" as a directory, including parents if necessary.
49060 as_fn_mkdir_p ()
49061 {
49062 
49063   case $as_dir in #(
49064   -*) as_dir=./$as_dir;;
49065   esac
49066   test -d "$as_dir" || eval $as_mkdir_p || {
49067     as_dirs=
49068     while :; do
49069       case $as_dir in #(
49070       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
49071       *) as_qdir=$as_dir;;
49072       esac
49073       as_dirs="'$as_qdir' $as_dirs"
49074       as_dir=`$as_dirname -- "$as_dir" ||
49075 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
49076          X"$as_dir" : 'X\(//\)[^/]' \| \
49077          X"$as_dir" : 'X\(//\)$' \| \
49078          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
49079 $as_echo X"$as_dir" |
49080     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
49081             s//\1/
49082             q
49083           }
49084           /^X\(\/\/\)[^/].*/{
49085             s//\1/
49086             q
49087           }
49088           /^X\(\/\/\)$/{
49089             s//\1/
49090             q
49091           }
49092           /^X\(\/\).*/{
49093             s//\1/
49094             q
49095           }
49096           s/.*/./; q'`
49097       test -d "$as_dir" && break
49098     done
49099     test -z "$as_dirs" || eval "mkdir $as_dirs"
49100   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
49101 
49102 
49103 } # as_fn_mkdir_p
49104 if mkdir -p . 2>/dev/null; then
49105   as_mkdir_p='mkdir -p "$as_dir"'
49106 else
49107   test -d ./-p && rmdir ./-p
49108   as_mkdir_p=false
49109 fi
49110 
49111 
49112 # as_fn_executable_p FILE
49113 # -----------------------
49114 # Test if FILE is an executable regular file.
49115 as_fn_executable_p ()
49116 {
49117   test -f "$1" && test -x "$1"
49118 } # as_fn_executable_p
49119 as_test_x='test -x'
49120 as_executable_p=as_fn_executable_p
49121 
49122 # Sed expression to map a string onto a valid CPP name.
49123 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
49124 
49125 # Sed expression to map a string onto a valid variable name.
49126 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
49127 
49128 
49129 exec 6>&1
49130 ## ----------------------------------- ##
49131 ## Main body of $CONFIG_STATUS script. ##
49132 ## ----------------------------------- ##
49133 _ASEOF
49134 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
49135 
49136 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49137 # Save the log message, to keep $0 and so on meaningful, and to
49138 # report actual input values of CONFIG_FILES etc. instead of their
49139 # values after options handling.
49140 ac_log="
49141 This file was extended by OpenJDK $as_me jdk8, which was
49142 generated by GNU Autoconf 2.69.  Invocation command line was
49143 
49144   CONFIG_FILES    = $CONFIG_FILES
49145   CONFIG_HEADERS  = $CONFIG_HEADERS
49146   CONFIG_LINKS    = $CONFIG_LINKS
49147   CONFIG_COMMANDS = $CONFIG_COMMANDS
49148   $ $0 $@
49149 
49150 on `(hostname || uname -n) 2>/dev/null | sed 1q`
49151 "
49152 
49153 _ACEOF
49154 
49155 case $ac_config_files in *"
49156 "*) set x $ac_config_files; shift; ac_config_files=$*;;
49157 esac
49158 
49159 case $ac_config_headers in *"
49160 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
49161 esac
49162 
49163 
49164 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49165 # Files that config.status was made for.
49166 config_files="$ac_config_files"
49167 config_headers="$ac_config_headers"
49168 
49169 _ACEOF
49170 
49171 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49172 ac_cs_usage="\
49173 \`$as_me' instantiates files and other configuration actions
49174 from templates according to the current configuration.  Unless the files
49175 and actions are specified as TAGs, all are instantiated by default.
49176 
49177 Usage: $0 [OPTION]... [TAG]...
49178 
49179   -h, --help       print this help, then exit
49180   -V, --version    print version number and configuration settings, then exit
49181       --config     print configuration, then exit
49182   -q, --quiet, --silent
49183                    do not print progress messages
49184   -d, --debug      don't remove temporary files
49185       --recheck    update $as_me by reconfiguring in the same conditions
49186       --file=FILE[:TEMPLATE]
49187                    instantiate the configuration file FILE
49188       --header=FILE[:TEMPLATE]
49189                    instantiate the configuration header FILE
49190 
49191 Configuration files:
49192 $config_files
49193 
49194 Configuration headers:
49195 $config_headers
49196 
49197 Report bugs to <build-dev@openjdk.java.net>.
49198 OpenJDK home page: <http://openjdk.java.net>."
49199 
49200 _ACEOF
49201 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49202 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
49203 ac_cs_version="\\
49204 OpenJDK config.status jdk8
49205 configured by $0, generated by GNU Autoconf 2.69,
49206   with options \\"\$ac_cs_config\\"
49207 
49208 Copyright (C) 2012 Free Software Foundation, Inc.
49209 This config.status script is free software; the Free Software Foundation
49210 gives unlimited permission to copy, distribute and modify it."
49211 
49212 ac_pwd='$ac_pwd'
49213 srcdir='$srcdir'
49214 AWK='$AWK'
49215 test -n "\$AWK" || AWK=awk
49216 _ACEOF
49217 
49218 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49219 # The default lists apply if the user does not specify any file.
49220 ac_need_defaults=:
49221 while test $# != 0
49222 do
49223   case $1 in
49224   --*=?*)
49225     ac_option=`expr "X$1" : 'X\([^=]*\)='`
49226     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
49227     ac_shift=:
49228     ;;
49229   --*=)
49230     ac_option=`expr "X$1" : 'X\([^=]*\)='`
49231     ac_optarg=
49232     ac_shift=:
49233     ;;
49234   *)
49235     ac_option=$1
49236     ac_optarg=$2
49237     ac_shift=shift
49238     ;;
49239   esac
49240 
49241   case $ac_option in
49242   # Handling of the options.
49243   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
49244     ac_cs_recheck=: ;;
49245   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
49246     $as_echo "$ac_cs_version"; exit ;;
49247   --config | --confi | --conf | --con | --co | --c )
49248     $as_echo "$ac_cs_config"; exit ;;
49249   --debug | --debu | --deb | --de | --d | -d )
49250     debug=: ;;
49251   --file | --fil | --fi | --f )
49252     $ac_shift
49253     case $ac_optarg in
49254     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
49255     '') as_fn_error $? "missing file argument" ;;
49256     esac
49257     as_fn_append CONFIG_FILES " '$ac_optarg'"
49258     ac_need_defaults=false;;
49259   --header | --heade | --head | --hea )
49260     $ac_shift
49261     case $ac_optarg in
49262     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
49263     esac
49264     as_fn_append CONFIG_HEADERS " '$ac_optarg'"
49265     ac_need_defaults=false;;
49266   --he | --h)
49267     # Conflict between --help and --header
49268     as_fn_error $? "ambiguous option: \`$1'
49269 Try \`$0 --help' for more information.";;
49270   --help | --hel | -h )
49271     $as_echo "$ac_cs_usage"; exit ;;
49272   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
49273   | -silent | --silent | --silen | --sile | --sil | --si | --s)
49274     ac_cs_silent=: ;;
49275 
49276   # This is an error.
49277   -*) as_fn_error $? "unrecognized option: \`$1'
49278 Try \`$0 --help' for more information." ;;
49279 
49280   *) as_fn_append ac_config_targets " $1"
49281      ac_need_defaults=false ;;
49282 
49283   esac
49284   shift
49285 done
49286 
49287 ac_configure_extra_args=
49288 
49289 if $ac_cs_silent; then
49290   exec 6>/dev/null
49291   ac_configure_extra_args="$ac_configure_extra_args --silent"
49292 fi
49293 
49294 _ACEOF
49295 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49296 if \$ac_cs_recheck; then
49297   set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
49298   shift
49299   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
49300   CONFIG_SHELL='$SHELL'
49301   export CONFIG_SHELL
49302   exec "\$@"
49303 fi
49304 
49305 _ACEOF
49306 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49307 exec 5>>config.log
49308 {
49309   echo
49310   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
49311 ## Running $as_me. ##
49312 _ASBOX
49313   $as_echo "$ac_log"
49314 } >&5
49315 
49316 _ACEOF
49317 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49318 _ACEOF
49319 
49320 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49321 
49322 # Handling of arguments.
49323 for ac_config_target in $ac_config_targets
49324 do
49325   case $ac_config_target in
49326     "$OUTPUT_ROOT/config.h") CONFIG_HEADERS="$CONFIG_HEADERS $OUTPUT_ROOT/config.h:$AUTOCONF_DIR/config.h.in" ;;
49327     "$OUTPUT_ROOT/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;;
49328     "$OUTPUT_ROOT/hotspot-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in" ;;
49329     "$OUTPUT_ROOT/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;;
49330     "$OUTPUT_ROOT/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;;
49331     "$OUTPUT_ROOT/spec.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.sh:$AUTOCONF_DIR/spec.sh.in" ;;
49332     "$OUTPUT_ROOT/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" ;;
49333 
49334   *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
49335   esac
49336 done
49337 
49338 
49339 # If the user did not use the arguments to specify the items to instantiate,
49340 # then the envvar interface is used.  Set only those that are not.
49341 # We use the long form for the default assignment because of an extremely
49342 # bizarre bug on SunOS 4.1.3.
49343 if $ac_need_defaults; then
49344   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
49345   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
49346 fi
49347 
49348 # Have a temporary directory for convenience.  Make it in the build tree
49349 # simply because there is no reason against having it here, and in addition,
49350 # creating and moving files from /tmp can sometimes cause problems.
49351 # Hook for its removal unless debugging.
49352 # Note that there is a small window in which the directory will not be cleaned:
49353 # after its creation but before its name has been assigned to `$tmp'.
49354 $debug ||
49355 {
49356   tmp= ac_tmp=
49357   trap 'exit_status=$?
49358   : "${ac_tmp:=$tmp}"
49359   { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
49360 ' 0
49361   trap 'as_fn_exit 1' 1 2 13 15
49362 }
49363 # Create a (secure) tmp directory for tmp files.
49364 
49365 {
49366   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
49367   test -d "$tmp"
49368 }  ||
49369 {
49370   tmp=./conf$$-$RANDOM
49371   (umask 077 && mkdir "$tmp")
49372 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
49373 ac_tmp=$tmp
49374 
49375 # Set up the scripts for CONFIG_FILES section.
49376 # No need to generate them if there are no CONFIG_FILES.
49377 # This happens for instance with `./config.status config.h'.
49378 if test -n "$CONFIG_FILES"; then
49379 
49380 
49381 ac_cr=`echo X | tr X '\015'`
49382 # On cygwin, bash can eat \r inside `` if the user requested igncr.
49383 # But we know of no other shell where ac_cr would be empty at this
49384 # point, so we can use a bashism as a fallback.
49385 if test "x$ac_cr" = x; then
49386   eval ac_cr=\$\'\\r\'
49387 fi
49388 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
49389 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
49390   ac_cs_awk_cr='\\r'
49391 else
49392   ac_cs_awk_cr=$ac_cr
49393 fi
49394 
49395 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
49396 _ACEOF
49397 
49398 
49399 {
49400   echo "cat >conf$$subs.awk <<_ACEOF" &&
49401   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
49402   echo "_ACEOF"
49403 } >conf$$subs.sh ||
49404   as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
49405 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
49406 ac_delim='%!_!# '
49407 for ac_last_try in false false false false false :; do
49408   . ./conf$$subs.sh ||
49409     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
49410 
49411   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
49412   if test $ac_delim_n = $ac_delim_num; then
49413     break
49414   elif $ac_last_try; then
49415     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
49416   else
49417     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
49418   fi
49419 done
49420 rm -f conf$$subs.sh
49421 
49422 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49423 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
49424 _ACEOF
49425 sed -n '
49426 h
49427 s/^/S["/; s/!.*/"]=/
49428 p
49429 g
49430 s/^[^!]*!//
49431 :repl
49432 t repl
49433 s/'"$ac_delim"'$//
49434 t delim
49435 :nl
49436 h
49437 s/\(.\{148\}\)..*/\1/
49438 t more1
49439 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
49440 p
49441 n
49442 b repl
49443 :more1
49444 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
49445 p
49446 g
49447 s/.\{148\}//
49448 t nl
49449 :delim
49450 h
49451 s/\(.\{148\}\)..*/\1/
49452 t more2
49453 s/["\\]/\\&/g; s/^/"/; s/$/"/
49454 p
49455 b
49456 :more2
49457 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
49458 p
49459 g
49460 s/.\{148\}//
49461 t delim
49462 ' <conf$$subs.awk | sed '
49463 /^[^""]/{
49464   N
49465   s/\n//
49466 }
49467 ' >>$CONFIG_STATUS || ac_write_fail=1
49468 rm -f conf$$subs.awk
49469 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49470 _ACAWK
49471 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
49472   for (key in S) S_is_set[key] = 1
49473   FS = ""
49474 
49475 }
49476 {
49477   line = $ 0
49478   nfields = split(line, field, "@")
49479   substed = 0
49480   len = length(field[1])
49481   for (i = 2; i < nfields; i++) {
49482     key = field[i]
49483     keylen = length(key)
49484     if (S_is_set[key]) {
49485       value = S[key]
49486       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
49487       len += length(value) + length(field[++i])
49488       substed = 1
49489     } else
49490       len += 1 + keylen
49491   }
49492 
49493   print line
49494 }
49495 
49496 _ACAWK
49497 _ACEOF
49498 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49499 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
49500   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
49501 else
49502   cat
49503 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
49504   || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
49505 _ACEOF
49506 
49507 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
49508 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
49509 # trailing colons and then remove the whole line if VPATH becomes empty
49510 # (actually we leave an empty line to preserve line numbers).
49511 if test "x$srcdir" = x.; then
49512   ac_vpsub='/^[  ]*VPATH[        ]*=[    ]*/{
49513 h
49514 s///
49515 s/^/:/
49516 s/[      ]*$/:/
49517 s/:\$(srcdir):/:/g
49518 s/:\${srcdir}:/:/g
49519 s/:@srcdir@:/:/g
49520 s/^:*//
49521 s/:*$//
49522 x
49523 s/\(=[   ]*\).*/\1/
49524 G
49525 s/\n//
49526 s/^[^=]*=[       ]*$//
49527 }'
49528 fi
49529 
49530 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49531 fi # test -n "$CONFIG_FILES"
49532 
49533 # Set up the scripts for CONFIG_HEADERS section.
49534 # No need to generate them if there are no CONFIG_HEADERS.
49535 # This happens for instance with `./config.status Makefile'.
49536 if test -n "$CONFIG_HEADERS"; then
49537 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
49538 BEGIN {
49539 _ACEOF
49540 
49541 # Transform confdefs.h into an awk script `defines.awk', embedded as
49542 # here-document in config.status, that substitutes the proper values into
49543 # config.h.in to produce config.h.
49544 
49545 # Create a delimiter string that does not exist in confdefs.h, to ease
49546 # handling of long lines.
49547 ac_delim='%!_!# '
49548 for ac_last_try in false false :; do
49549   ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
49550   if test -z "$ac_tt"; then
49551     break
49552   elif $ac_last_try; then
49553     as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
49554   else
49555     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
49556   fi
49557 done
49558 
49559 # For the awk script, D is an array of macro values keyed by name,
49560 # likewise P contains macro parameters if any.  Preserve backslash
49561 # newline sequences.
49562 
49563 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
49564 sed -n '
49565 s/.\{148\}/&'"$ac_delim"'/g
49566 t rset
49567 :rset
49568 s/^[     ]*#[    ]*define[       ][      ]*/ /
49569 t def
49570 d
49571 :def
49572 s/\\$//
49573 t bsnl
49574 s/["\\]/\\&/g
49575 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
49576 D["\1"]=" \3"/p
49577 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
49578 d
49579 :bsnl
49580 s/["\\]/\\&/g
49581 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
49582 D["\1"]=" \3\\\\\\n"\\/p
49583 t cont
49584 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
49585 t cont
49586 d
49587 :cont
49588 n
49589 s/.\{148\}/&'"$ac_delim"'/g
49590 t clear
49591 :clear
49592 s/\\$//
49593 t bsnlc
49594 s/["\\]/\\&/g; s/^/"/; s/$/"/p
49595 d
49596 :bsnlc
49597 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
49598 b cont
49599 ' <confdefs.h | sed '
49600 s/'"$ac_delim"'/"\\\
49601 "/g' >>$CONFIG_STATUS || ac_write_fail=1
49602 
49603 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49604   for (key in D) D_is_set[key] = 1
49605   FS = ""
49606 }
49607 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
49608   line = \$ 0
49609   split(line, arg, " ")
49610   if (arg[1] == "#") {
49611     defundef = arg[2]
49612     mac1 = arg[3]
49613   } else {
49614     defundef = substr(arg[1], 2)
49615     mac1 = arg[2]
49616   }
49617   split(mac1, mac2, "(") #)
49618   macro = mac2[1]
49619   prefix = substr(line, 1, index(line, defundef) - 1)
49620   if (D_is_set[macro]) {
49621     # Preserve the white space surrounding the "#".
49622     print prefix "define", macro P[macro] D[macro]
49623     next
49624   } else {
49625     # Replace #undef with comments.  This is necessary, for example,
49626     # in the case of _POSIX_SOURCE, which is predefined and required
49627     # on some systems where configure will not decide to define it.
49628     if (defundef == "undef") {
49629       print "/*", prefix defundef, macro, "*/"
49630       next
49631     }
49632   }
49633 }
49634 { print }
49635 _ACAWK
49636 _ACEOF
49637 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49638   as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
49639 fi # test -n "$CONFIG_HEADERS"
49640 
49641 
49642 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    "
49643 shift
49644 for ac_tag
49645 do
49646   case $ac_tag in
49647   :[FHLC]) ac_mode=$ac_tag; continue;;
49648   esac
49649   case $ac_mode$ac_tag in
49650   :[FHL]*:*);;
49651   :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
49652   :[FH]-) ac_tag=-:-;;
49653   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
49654   esac
49655   ac_save_IFS=$IFS
49656   IFS=:
49657   set x $ac_tag
49658   IFS=$ac_save_IFS
49659   shift
49660   ac_file=$1
49661   shift
49662 
49663   case $ac_mode in
49664   :L) ac_source=$1;;
49665   :[FH])
49666     ac_file_inputs=
49667     for ac_f
49668     do
49669       case $ac_f in
49670       -) ac_f="$ac_tmp/stdin";;
49671       *) # Look for the file first in the build tree, then in the source tree
49672          # (if the path is not absolute).  The absolute path cannot be DOS-style,
49673          # because $ac_f cannot contain `:'.
49674          test -f "$ac_f" ||
49675            case $ac_f in
49676            [\\/$]*) false;;
49677            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
49678            esac ||
49679            as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
49680       esac
49681       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
49682       as_fn_append ac_file_inputs " '$ac_f'"
49683     done
49684 
49685     # Let's still pretend it is `configure' which instantiates (i.e., don't
49686     # use $as_me), people would be surprised to read:
49687     #    /* config.h.  Generated by config.status.  */
49688     configure_input='Generated from '`
49689           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
49690         `' by configure.'
49691     if test x"$ac_file" != x-; then
49692       configure_input="$ac_file.  $configure_input"
49693       { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
49694 $as_echo "$as_me: creating $ac_file" >&6;}
49695     fi
49696     # Neutralize special characters interpreted by sed in replacement strings.
49697     case $configure_input in #(
49698     *\&* | *\|* | *\\* )
49699        ac_sed_conf_input=`$as_echo "$configure_input" |
49700        sed 's/[\\\\&|]/\\\\&/g'`;; #(
49701     *) ac_sed_conf_input=$configure_input;;
49702     esac
49703 
49704     case $ac_tag in
49705     *:-:* | *:-) cat >"$ac_tmp/stdin" \
49706       || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
49707     esac
49708     ;;
49709   esac
49710 
49711   ac_dir=`$as_dirname -- "$ac_file" ||
49712 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
49713          X"$ac_file" : 'X\(//\)[^/]' \| \
49714          X"$ac_file" : 'X\(//\)$' \| \
49715          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
49716 $as_echo X"$ac_file" |
49717     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
49718             s//\1/
49719             q
49720           }
49721           /^X\(\/\/\)[^/].*/{
49722             s//\1/
49723             q
49724           }
49725           /^X\(\/\/\)$/{
49726             s//\1/
49727             q
49728           }
49729           /^X\(\/\).*/{
49730             s//\1/
49731             q
49732           }
49733           s/.*/./; q'`
49734   as_dir="$ac_dir"; as_fn_mkdir_p
49735   ac_builddir=.
49736 
49737 case "$ac_dir" in
49738 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
49739 *)
49740   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
49741   # A ".." for each directory in $ac_dir_suffix.
49742   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
49743   case $ac_top_builddir_sub in
49744   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
49745   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
49746   esac ;;
49747 esac
49748 ac_abs_top_builddir=$ac_pwd
49749 ac_abs_builddir=$ac_pwd$ac_dir_suffix
49750 # for backward compatibility:
49751 ac_top_builddir=$ac_top_build_prefix
49752 
49753 case $srcdir in
49754   .)  # We are building in place.
49755     ac_srcdir=.
49756     ac_top_srcdir=$ac_top_builddir_sub
49757     ac_abs_top_srcdir=$ac_pwd ;;
49758   [\\/]* | ?:[\\/]* )  # Absolute name.
49759     ac_srcdir=$srcdir$ac_dir_suffix;
49760     ac_top_srcdir=$srcdir
49761     ac_abs_top_srcdir=$srcdir ;;
49762   *) # Relative name.
49763     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
49764     ac_top_srcdir=$ac_top_build_prefix$srcdir
49765     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
49766 esac
49767 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
49768 
49769 
49770   case $ac_mode in
49771   :F)
49772   #
49773   # CONFIG_FILE
49774   #
49775 
49776 _ACEOF
49777 
49778 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49779 # If the template does not know about datarootdir, expand it.
49780 # FIXME: This hack should be removed a few years after 2.60.
49781 ac_datarootdir_hack=; ac_datarootdir_seen=
49782 ac_sed_dataroot='
49783 /datarootdir/ {
49784   p
49785   q
49786 }
49787 /@datadir@/p
49788 /@docdir@/p
49789 /@infodir@/p
49790 /@localedir@/p
49791 /@mandir@/p'
49792 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
49793 *datarootdir*) ac_datarootdir_seen=yes;;
49794 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
49795   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
49796 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
49797 _ACEOF
49798 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49799   ac_datarootdir_hack='
49800   s&@datadir@&$datadir&g
49801   s&@docdir@&$docdir&g
49802   s&@infodir@&$infodir&g
49803   s&@localedir@&$localedir&g
49804   s&@mandir@&$mandir&g
49805   s&\\\${datarootdir}&$datarootdir&g' ;;
49806 esac
49807 _ACEOF
49808 
49809 # Neutralize VPATH when `$srcdir' = `.'.
49810 # Shell code in configure.ac might set extrasub.
49811 # FIXME: do we really want to maintain this feature?
49812 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
49813 ac_sed_extra="$ac_vpsub
49814 $extrasub
49815 _ACEOF
49816 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
49817 :t
49818 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
49819 s|@configure_input@|$ac_sed_conf_input|;t t
49820 s&@top_builddir@&$ac_top_builddir_sub&;t t
49821 s&@top_build_prefix@&$ac_top_build_prefix&;t t
49822 s&@srcdir@&$ac_srcdir&;t t
49823 s&@abs_srcdir@&$ac_abs_srcdir&;t t
49824 s&@top_srcdir@&$ac_top_srcdir&;t t
49825 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
49826 s&@builddir@&$ac_builddir&;t t
49827 s&@abs_builddir@&$ac_abs_builddir&;t t
49828 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
49829 $ac_datarootdir_hack
49830 "
49831 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
49832   >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
49833 
49834 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
49835   { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
49836   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' \
49837       "$ac_tmp/out"`; test -z "$ac_out"; } &&
49838   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
49839 which seems to be undefined.  Please make sure it is defined" >&5
49840 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
49841 which seems to be undefined.  Please make sure it is defined" >&2;}
49842 
49843   rm -f "$ac_tmp/stdin"
49844   case $ac_file in
49845   -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
49846   *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
49847   esac \
49848   || as_fn_error $? "could not create $ac_file" "$LINENO" 5
49849  ;;
49850   :H)
49851   #
49852   # CONFIG_HEADER
49853   #
49854   if test x"$ac_file" != x-; then
49855     {
49856       $as_echo "/* $configure_input  */" \
49857       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
49858     } >"$ac_tmp/config.h" \
49859       || as_fn_error $? "could not create $ac_file" "$LINENO" 5
49860     if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
49861       { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
49862 $as_echo "$as_me: $ac_file is unchanged" >&6;}
49863     else
49864       rm -f "$ac_file"
49865       mv "$ac_tmp/config.h" "$ac_file" \
49866         || as_fn_error $? "could not create $ac_file" "$LINENO" 5
49867     fi
49868   else
49869     $as_echo "/* $configure_input  */" \
49870       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
49871       || as_fn_error $? "could not create -" "$LINENO" 5
49872   fi
49873  ;;
49874 
49875 
49876   esac
49877 
49878 done # for ac_tag
49879 
49880 
49881 as_fn_exit 0
49882 _ACEOF
49883 ac_clean_files=$ac_clean_files_save
49884 
49885 test $ac_write_fail = 0 ||
49886   as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
49887 
49888 
49889 # configure is writing to config.log, and then calls config.status.
49890 # config.status does its own redirection, appending to config.log.
49891 # Unfortunately, on DOS this fails, as config.log is still kept open
49892 # by configure, so config.status won't be able to write to it; its
49893 # output is simply discarded.  So we exec the FD to /dev/null,
49894 # effectively closing config.log, so it can be properly (re)opened and
49895 # appended to by config.status.  When coming back to configure, we
49896 # need to make the FD available again.
49897 if test "$no_create" != yes; then
49898   ac_cs_success=:
49899   ac_config_status_args=
49900   test "$silent" = yes &&
49901     ac_config_status_args="$ac_config_status_args --quiet"
49902   exec 5>/dev/null
49903   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
49904   exec 5>>config.log
49905   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
49906   # would make configure fail if this is the last instruction.
49907   $ac_cs_success || as_fn_exit 1
49908 fi
49909 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
49910   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
49911 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
49912 fi
49913 
49914 
49915 # Try to move the config.log file to the output directory.
49916 if test -e ./config.log; then
49917   $MV -f ./config.log "$OUTPUT_ROOT/config.log" 2> /dev/null
49918 fi
49919 
49920 # Make the compare script executable
49921 $CHMOD +x $OUTPUT_ROOT/compare.sh
49922 
49923 # Finally output some useful information to the user
49924 
49925   # Finally output some useful information to the user
49926 
49927   printf "\n"
49928   printf "====================================================\n"
49929   if test "x$no_create" != "xyes"; then
49930     if test "x$IS_RECONFIGURE" != "xyes"; then
49931       printf "A new configuration has been successfully created in\n %s\n" "$OUTPUT_ROOT"
49932     else
49933       printf "The existing configuration has been successfully updated in\n %s\n" "$OUTPUT_ROOT"
49934     fi
49935   else
49936     if test "x$IS_RECONFIGURE" != "xyes"; then
49937       printf "A configuration has been successfully checked but not created\n"
49938     else
49939       printf "The existing configuration has been successfully checked in\n %s\n" "$OUTPUT_ROOT"
49940     fi
49941   fi
49942   if test "x$CONFIGURE_COMMAND_LINE" != x; then
49943     printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n"
49944   else
49945     printf "using default settings.\n"
49946   fi
49947 
49948   printf "\n"
49949   printf "Configuration summary:\n"
49950   printf "* Debug level:    $DEBUG_LEVEL\n"
49951   printf "* JDK variant:    $JDK_VARIANT\n"
49952   printf "* JVM variants:   $with_jvm_variants\n"
49953   printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n"
49954 
49955   printf "\n"
49956   printf "Tools summary:\n"
49957   if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
49958     printf "* Environment:    $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n"
49959   fi
49960   printf "* Boot JDK:       $BOOT_JDK_VERSION (at $BOOT_JDK)\n"
49961   printf "* C Compiler:     $CC_VENDOR version $CC_VERSION (at $CC)\n"
49962   printf "* C++ Compiler:   $CXX_VENDOR version $CXX_VERSION (at $CXX)\n"
49963 
49964   printf "\n"
49965   printf "Build performance summary:\n"
49966   printf "* Cores to use:   $JOBS\n"
49967   printf "* Memory limit:   $MEMORY_SIZE MB\n"
49968   if test "x$CCACHE_STATUS" != "x"; then
49969     printf "* ccache status:  $CCACHE_STATUS\n"
49970   fi
49971   printf "\n"
49972 
49973   if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xyes"; then
49974     printf "NOTE: You have requested to build more than one version of the JVM, which\n"
49975     printf "will result in longer build times.\n"
49976     printf "\n"
49977   fi
49978 
49979   if test "x$FOUND_ALT_VARIABLES" != "x"; then
49980     printf "WARNING: You have old-style ALT_ environment variables set.\n"
49981     printf "These are not respected, and will be ignored. It is recommended\n"
49982     printf "that you clean your environment. The following variables are set:\n"
49983     printf "$FOUND_ALT_VARIABLES\n"
49984     printf "\n"
49985   fi
49986 
49987   if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then
49988     printf "WARNING: Your build output directory is not on a local disk.\n"
49989     printf "This will severely degrade build performance!\n"
49990     printf "It is recommended that you create an output directory on a local disk,\n"
49991     printf "and run the configure script again from that directory.\n"
49992     printf "\n"
49993   fi
49994 
49995   if test "x$IS_RECONFIGURE" = "xyes" && test "x$no_create" != "xyes"; then
49996     printf "WARNING: The result of this configuration has overridden an older\n"
49997     printf "configuration. You *should* run 'make clean' to make sure you get a\n"
49998     printf "proper build. Failure to do so might result in strange build problems.\n"
49999     printf "\n"
50000   fi
50001 
50002   if test "x$IS_RECONFIGURE" != "xyes" && test "x$no_create" = "xyes"; then
50003     printf "WARNING: The result of this configuration was not saved.\n"
50004     printf "You should run without '--no-create | -n' to create the configuration.\n"
50005     printf "\n"
50006   fi
50007