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 jdk9.
  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='jdk9'
 590 PACKAGE_STRING='OpenJDK jdk9'
 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_FLAGS
 637 SJAVAC_SERVER_JAVA
 638 JAVA_TOOL_FLAGS_SMALL
 639 JAVA_FLAGS_SMALL
 640 JAVA_FLAGS_BIG
 641 JAVA_FLAGS
 642 JOBS
 643 MEMORY_SIZE
 644 NUM_CORES
 645 ENABLE_INTREE_EC
 646 SALIB_NAME
 647 HOTSPOT_MAKE_ARGS
 648 MSVCR_DLL
 649 LIBCXX
 650 LLVM_LIBS
 651 LLVM_LDFLAGS
 652 LLVM_CFLAGS
 653 LLVM_CONFIG
 654 LIBFFI_LIBS
 655 LIBFFI_CFLAGS
 656 STATIC_CXX_SETTING
 657 LIBDL
 658 LIBM
 659 LIBZIP_CAN_USE_MMAP
 660 USE_EXTERNAL_LIBZ
 661 USE_EXTERNAL_LIBPNG
 662 PNG_LIBS
 663 PNG_CFLAGS
 664 USE_EXTERNAL_LCMS
 665 LCMS_LIBS
 666 LCMS_CFLAGS
 667 USE_EXTERNAL_LIBGIF
 668 USE_EXTERNAL_LIBJPEG
 669 ALSA_LIBS
 670 ALSA_CFLAGS
 671 FREETYPE_BUNDLE_LIB_PATH
 672 FREETYPE_LIBS
 673 FREETYPE_CFLAGS
 674 CUPS_CFLAGS
 675 X_EXTRA_LIBS
 676 X_LIBS
 677 X_PRE_LIBS
 678 X_CFLAGS
 679 XMKMF
 680 FIXPATH
 681 ZIP_DEBUGINFO_FILES
 682 ENABLE_DEBUG_SYMBOLS
 683 CFLAGS_WARNINGS_ARE_ERRORS
 684 COMPILER_SUPPORTS_TARGET_BITS_FLAG
 685 ZERO_ARCHFLAG
 686 LDFLAGS_CXX_JDK
 687 LDFLAGS_JDKEXE_SUFFIX
 688 LDFLAGS_JDKLIB_SUFFIX
 689 LDFLAGS_JDKEXE
 690 LDFLAGS_JDKLIB
 691 CXXFLAGS_JDKEXE
 692 CXXFLAGS_JDKLIB
 693 CFLAGS_JDKEXE
 694 CFLAGS_JDKLIB
 695 MACOSX_VERSION_MIN
 696 LEGACY_EXTRA_LDFLAGS
 697 LEGACY_EXTRA_CXXFLAGS
 698 LEGACY_EXTRA_CFLAGS
 699 CXX_O_FLAG_NONE
 700 CXX_O_FLAG_DEBUG
 701 CXX_O_FLAG_NORM
 702 CXX_O_FLAG_HI
 703 CXX_O_FLAG_HIGHEST
 704 C_O_FLAG_NONE
 705 C_O_FLAG_DEBUG
 706 C_O_FLAG_NORM
 707 C_O_FLAG_HI
 708 C_O_FLAG_HIGHEST
 709 CXXFLAGS_DEBUG_OPTIONS
 710 CFLAGS_DEBUG_OPTIONS
 711 CXXFLAGS_DEBUG_SYMBOLS
 712 CFLAGS_DEBUG_SYMBOLS
 713 CXX_FLAG_DEPS
 714 C_FLAG_DEPS
 715 SET_SHARED_LIBRARY_MAPFILE
 716 SET_SHARED_LIBRARY_NAME
 717 SET_SHARED_LIBRARY_ORIGIN
 718 SET_EXECUTABLE_ORIGIN
 719 SHARED_LIBRARY_FLAGS
 720 CXX_FLAG_REORDER
 721 C_FLAG_REORDER
 722 SYSROOT_LDFLAGS
 723 SYSROOT_CFLAGS
 724 RC_FLAGS
 725 AR_OUT_OPTION
 726 LD_OUT_OPTION
 727 EXE_OUT_OPTION
 728 CC_OUT_OPTION
 729 POST_MCS_CMD
 730 POST_STRIP_CMD
 731 ARFLAGS
 732 COMPILER_TARGET_BITS_FLAG
 733 JT_HOME
 734 JTREGEXE
 735 USING_BROKEN_SUSE_LD
 736 PACKAGE_PATH
 737 LDEXECXX
 738 LDEXE
 739 USE_CLANG
 740 HOTSPOT_LD
 741 HOTSPOT_CXX
 742 HOTSPOT_RC
 743 HOTSPOT_MT
 744 BUILD_LD
 745 BUILD_CXX
 746 BUILD_CC
 747 ac_ct_OBJDUMP
 748 OBJDUMP
 749 ac_ct_OBJCOPY
 750 OBJCOPY
 751 ac_ct_NM
 752 ac_ct_STRIP
 753 MCS
 754 GNM
 755 NM
 756 STRIP
 757 MSBUILD
 758 DUMPBIN
 759 RC
 760 MT
 761 LIPO
 762 ac_ct_OBJC
 763 OBJCFLAGS
 764 OBJC
 765 ac_ct_AR
 766 AR
 767 AS
 768 LDCXX
 769 LD
 770 CXXCPP
 771 CPP
 772 ac_ct_CXX
 773 CXXFLAGS
 774 CXX
 775 ac_ct_PROPER_COMPILER_CXX
 776 PROPER_COMPILER_CXX
 777 TOOLCHAIN_PATH_CXX
 778 POTENTIAL_CXX
 779 OBJEXT
 780 EXEEXT
 781 ac_ct_CC
 782 CPPFLAGS
 783 LDFLAGS
 784 CFLAGS
 785 CC
 786 ac_ct_PROPER_COMPILER_CC
 787 PROPER_COMPILER_CC
 788 TOOLCHAIN_PATH_CC
 789 POTENTIAL_CC
 790 VS_LIB
 791 VS_INCLUDE
 792 VS_PATH
 793 CYGWIN_LINK
 794 EXE_SUFFIX
 795 OBJ_SUFFIX
 796 STATIC_LIBRARY
 797 SHARED_LIBRARY
 798 STATIC_LIBRARY_SUFFIX
 799 SHARED_LIBRARY_SUFFIX
 800 LIBRARY_PREFIX
 801 TOOLCHAIN_TYPE
 802 BUILD_HOTSPOT
 803 HOTSPOT_DIST
 804 BUILD_OUTPUT
 805 OVERRIDE_SRC_ROOT
 806 ADD_SRC_ROOT
 807 JDK_TOPDIR
 808 NASHORN_TOPDIR
 809 HOTSPOT_TOPDIR
 810 JAXWS_TOPDIR
 811 JAXP_TOPDIR
 812 CORBA_TOPDIR
 813 LANGTOOLS_TOPDIR
 814 JAVAC_FLAGS
 815 BOOT_JDK_SOURCETARGET
 816 JARSIGNER
 817 NATIVE2ASCII
 818 JAR
 819 JAVAH
 820 JAVAC
 821 JAVA
 822 BOOT_JDK
 823 BOOT_TOOLSJAR
 824 BOOT_RTJAR
 825 JAVA_CHECK
 826 JAVAC_CHECK
 827 COOKED_BUILD_NUMBER
 828 JDK_VERSION
 829 COPYRIGHT_YEAR
 830 MACOSX_BUNDLE_ID_BASE
 831 MACOSX_BUNDLE_NAME_BASE
 832 COMPANY_NAME
 833 JDK_RC_PLATFORM_NAME
 834 PRODUCT_SUFFIX
 835 PRODUCT_NAME
 836 LAUNCHER_NAME
 837 MILESTONE
 838 JDK_BUILD_NUMBER
 839 JDK_UPDATE_VERSION
 840 JDK_MICRO_VERSION
 841 JDK_MINOR_VERSION
 842 JDK_MAJOR_VERSION
 843 USER_RELEASE_SUFFIX
 844 COMPRESS_JARS
 845 RMICONNECTOR_IIOP
 846 UNLIMITED_CRYPTO
 847 CACERTS_FILE
 848 TEST_IN_BUILD
 849 BUILD_HEADLESS
 850 SUPPORT_HEADFUL
 851 SUPPORT_HEADLESS
 852 BDEPS_FTP
 853 BDEPS_UNZIP
 854 OS_VERSION_MICRO
 855 OS_VERSION_MINOR
 856 OS_VERSION_MAJOR
 857 PKG_CONFIG
 858 CODESIGN
 859 XATTR
 860 DSYMUTIL
 861 IS_GNU_TIME
 862 TIME
 863 STAT
 864 HG
 865 READELF
 866 OTOOL
 867 LDD
 868 ZIP
 869 UNZIP
 870 FIND_DELETE
 871 OUTPUT_SYNC
 872 OUTPUT_SYNC_SUPPORTED
 873 MAKE
 874 CHECK_TOOLSDIR_MAKE
 875 CHECK_TOOLSDIR_GMAKE
 876 CHECK_MAKE
 877 CHECK_GMAKE
 878 PKGHANDLER
 879 OUTPUT_ROOT
 880 CONF_NAME
 881 SPEC
 882 SDKROOT
 883 XCODEBUILD
 884 BUILD_VARIANT_RELEASE
 885 DEBUG_CLASSFILES
 886 FASTDEBUG
 887 VARIANT
 888 DEBUG_LEVEL
 889 MACOSX_UNIVERSAL
 890 INCLUDE_SA
 891 JVM_VARIANT_CORE
 892 JVM_VARIANT_ZEROSHARK
 893 JVM_VARIANT_ZERO
 894 JVM_VARIANT_KERNEL
 895 JVM_VARIANT_MINIMAL1
 896 JVM_VARIANT_CLIENT
 897 JVM_VARIANT_SERVER
 898 JVM_VARIANTS
 899 JVM_INTERPRETER
 900 JDK_VARIANT
 901 SET_OPENJDK
 902 BUILD_LOG_WRAPPER
 903 BUILD_LOG_PREVIOUS
 904 BUILD_LOG
 905 TOPDIR
 906 PATH_SEP
 907 ZERO_ARCHDEF
 908 DEFINE_CROSS_COMPILE_ARCH
 909 LP64
 910 OPENJDK_TARGET_OS_EXPORT_DIR
 911 OPENJDK_TARGET_CPU_JLI_CFLAGS
 912 OPENJDK_TARGET_CPU_OSARCH
 913 OPENJDK_TARGET_CPU_ISADIR
 914 OPENJDK_TARGET_CPU_LIBDIR
 915 OPENJDK_TARGET_CPU_LEGACY_LIB
 916 OPENJDK_TARGET_CPU_LEGACY
 917 REQUIRED_OS_VERSION
 918 REQUIRED_OS_NAME
 919 COMPILE_TYPE
 920 OPENJDK_TARGET_CPU_ENDIAN
 921 OPENJDK_TARGET_CPU_BITS
 922 OPENJDK_TARGET_CPU_ARCH
 923 OPENJDK_TARGET_CPU
 924 OPENJDK_TARGET_OS_ENV
 925 OPENJDK_TARGET_OS_TYPE
 926 OPENJDK_TARGET_OS
 927 OPENJDK_BUILD_CPU_ENDIAN
 928 OPENJDK_BUILD_CPU_BITS
 929 OPENJDK_BUILD_CPU_ARCH
 930 OPENJDK_BUILD_CPU
 931 OPENJDK_BUILD_OS_ENV
 932 OPENJDK_BUILD_OS_TYPE
 933 OPENJDK_BUILD_OS
 934 OPENJDK_BUILD_AUTOCONF_NAME
 935 OPENJDK_TARGET_AUTOCONF_NAME
 936 target_os
 937 target_vendor
 938 target_cpu
 939 target
 940 host_os
 941 host_vendor
 942 host_cpu
 943 host
 944 build_os
 945 build_vendor
 946 build_cpu
 947 build
 948 CPIO
 949 SETFILE
 950 DF
 951 READLINK
 952 CYGPATH
 953 SED
 954 FGREP
 955 EGREP
 956 GREP
 957 AWK
 958 XARGS
 959 WHICH
 960 WC
 961 UNIQ
 962 UNAME
 963 TR
 964 TOUCH
 965 TEE
 966 TAR
 967 TAIL
 968 SORT
 969 SH
 970 RM
 971 PRINTF
 972 NAWK
 973 MV
 974 MKTEMP
 975 MKDIR
 976 LS
 977 LN
 978 HEAD
 979 FIND
 980 FILE
 981 EXPR
 982 ECHO
 983 DIRNAME
 984 DIFF
 985 DATE
 986 CUT
 987 CP
 988 COMM
 989 CMP
 990 CHMOD
 991 CAT
 992 BASH
 993 BASENAME
 994 DATE_WHEN_CONFIGURED
 995 CONFIGURE_COMMAND_LINE
 996 target_alias
 997 host_alias
 998 build_alias
 999 LIBS
1000 ECHO_T
1001 ECHO_N
1002 ECHO_C
1003 DEFS
1004 mandir
1005 localedir
1006 libdir
1007 psdir
1008 pdfdir
1009 dvidir
1010 htmldir
1011 infodir
1012 docdir
1013 oldincludedir
1014 includedir
1015 localstatedir
1016 sharedstatedir
1017 sysconfdir
1018 datadir
1019 datarootdir
1020 libexecdir
1021 sbindir
1022 bindir
1023 program_transform_name
1024 prefix
1025 exec_prefix
1026 PACKAGE_URL
1027 PACKAGE_BUGREPORT
1028 PACKAGE_STRING
1029 PACKAGE_VERSION
1030 PACKAGE_TARNAME
1031 PACKAGE_NAME
1032 PATH_SEPARATOR
1033 SHELL'
1034 ac_subst_files=''
1035 ac_user_opts='
1036 enable_option_checking
1037 with_target_bits
1038 enable_openjdk_only
1039 with_custom_make_dir
1040 with_jdk_variant
1041 with_jvm_interpreter
1042 with_jvm_variants
1043 enable_debug
1044 with_debug_level
1045 with_devkit
1046 with_sys_root
1047 with_sysroot
1048 with_tools_dir
1049 with_toolchain_path
1050 with_extra_path
1051 with_sdk_name
1052 with_conf_name
1053 with_output_sync
1054 with_builddeps_conf
1055 with_builddeps_server
1056 with_builddeps_dir
1057 with_builddeps_group
1058 enable_headful
1059 enable_hotspot_test_in_build
1060 with_cacerts_file
1061 enable_unlimited_crypto
1062 enable_rmiconnector_iiop
1063 with_milestone
1064 with_update_version
1065 with_user_release_suffix
1066 with_build_number
1067 with_copyright_year
1068 with_boot_jdk
1069 with_add_source_root
1070 with_override_source_root
1071 with_adds_and_overrides
1072 with_override_langtools
1073 with_override_corba
1074 with_override_jaxp
1075 with_override_jaxws
1076 with_override_hotspot
1077 with_override_nashorn
1078 with_override_jdk
1079 with_import_hotspot
1080 with_toolchain_type
1081 with_jtreg
1082 with_extra_cflags
1083 with_extra_cxxflags
1084 with_extra_ldflags
1085 enable_debug_symbols
1086 enable_zip_debug_info
1087 with_x
1088 with_cups
1089 with_cups_include
1090 with_freetype
1091 with_freetype_include
1092 with_freetype_lib
1093 with_freetype_src
1094 enable_freetype_bundling
1095 with_alsa
1096 with_alsa_include
1097 with_alsa_lib
1098 with_libjpeg
1099 with_giflib
1100 with_lcms
1101 with_libpng
1102 with_zlib
1103 with_stdc__lib
1104 with_msvcr_dll
1105 with_dxsdk
1106 with_dxsdk_lib
1107 with_dxsdk_include
1108 with_num_cores
1109 with_memory_size
1110 with_jobs
1111 with_boot_jdk_jvmargs
1112 with_sjavac_server_java
1113 enable_sjavac
1114 enable_precompiled_headers
1115 enable_ccache
1116 with_ccache_dir
1117 '
1118       ac_precious_vars='build_alias
1119 host_alias
1120 target_alias
1121 BASENAME
1122 BASH
1123 CAT
1124 CHMOD
1125 CMP
1126 COMM
1127 CP
1128 CUT
1129 DATE
1130 DIFF
1131 DIRNAME
1132 ECHO
1133 EXPR
1134 FILE
1135 FIND
1136 HEAD
1137 LN
1138 LS
1139 MKDIR
1140 MKTEMP
1141 MV
1142 NAWK
1143 PRINTF
1144 RM
1145 SH
1146 SORT
1147 TAIL
1148 TAR
1149 TEE
1150 TOUCH
1151 TR
1152 UNAME
1153 UNIQ
1154 WC
1155 WHICH
1156 XARGS
1157 AWK
1158 GREP
1159 EGREP
1160 FGREP
1161 SED
1162 CYGPATH
1163 READLINK
1164 DF
1165 SETFILE
1166 CPIO
1167 UNZIP
1168 ZIP
1169 LDD
1170 OTOOL
1171 READELF
1172 HG
1173 STAT
1174 TIME
1175 DSYMUTIL
1176 XATTR
1177 CODESIGN
1178 PKG_CONFIG
1179 JAVA
1180 JAVAC
1181 JAVAH
1182 JAR
1183 NATIVE2ASCII
1184 JARSIGNER
1185 CC
1186 CFLAGS
1187 LDFLAGS
1188 LIBS
1189 CPPFLAGS
1190 CXX
1191 CXXFLAGS
1192 CCC
1193 CPP
1194 CXXCPP
1195 AS
1196 AR
1197 OBJC
1198 OBJCFLAGS
1199 LIPO
1200 STRIP
1201 NM
1202 GNM
1203 MCS
1204 OBJCOPY
1205 OBJDUMP
1206 BUILD_CC
1207 BUILD_CXX
1208 BUILD_LD
1209 JTREGEXE
1210 XMKMF
1211 FREETYPE_CFLAGS
1212 FREETYPE_LIBS
1213 ALSA_CFLAGS
1214 ALSA_LIBS
1215 LCMS_CFLAGS
1216 LCMS_LIBS
1217 PNG_CFLAGS
1218 PNG_LIBS
1219 LIBFFI_CFLAGS
1220 LIBFFI_LIBS
1221 CCACHE'
1222 
1223 
1224 # Initialize some variables set by options.
1225 ac_init_help=
1226 ac_init_version=false
1227 ac_unrecognized_opts=
1228 ac_unrecognized_sep=
1229 # The variables have the same names as the options, with
1230 # dashes changed to underlines.
1231 cache_file=/dev/null
1232 exec_prefix=NONE
1233 no_create=
1234 no_recursion=
1235 prefix=NONE
1236 program_prefix=NONE
1237 program_suffix=NONE
1238 program_transform_name=s,x,x,
1239 silent=
1240 site=
1241 srcdir=
1242 verbose=
1243 x_includes=NONE
1244 x_libraries=NONE
1245 
1246 # Installation directory options.
1247 # These are left unexpanded so users can "make install exec_prefix=/foo"
1248 # and all the variables that are supposed to be based on exec_prefix
1249 # by default will actually change.
1250 # Use braces instead of parens because sh, perl, etc. also accept them.
1251 # (The list follows the same order as the GNU Coding Standards.)
1252 bindir='${exec_prefix}/bin'
1253 sbindir='${exec_prefix}/sbin'
1254 libexecdir='${exec_prefix}/libexec'
1255 datarootdir='${prefix}/share'
1256 datadir='${datarootdir}'
1257 sysconfdir='${prefix}/etc'
1258 sharedstatedir='${prefix}/com'
1259 localstatedir='${prefix}/var'
1260 includedir='${prefix}/include'
1261 oldincludedir='/usr/include'
1262 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1263 infodir='${datarootdir}/info'
1264 htmldir='${docdir}'
1265 dvidir='${docdir}'
1266 pdfdir='${docdir}'
1267 psdir='${docdir}'
1268 libdir='${exec_prefix}/lib'
1269 localedir='${datarootdir}/locale'
1270 mandir='${datarootdir}/man'
1271 
1272 ac_prev=
1273 ac_dashdash=
1274 for ac_option
1275 do
1276   # If the previous option needs an argument, assign it.
1277   if test -n "$ac_prev"; then
1278     eval $ac_prev=\$ac_option
1279     ac_prev=
1280     continue
1281   fi
1282 
1283   case $ac_option in
1284   *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1285   *=)   ac_optarg= ;;
1286   *)    ac_optarg=yes ;;
1287   esac
1288 
1289   # Accept the important Cygnus configure options, so we can diagnose typos.
1290 
1291   case $ac_dashdash$ac_option in
1292   --)
1293     ac_dashdash=yes ;;
1294 
1295   -bindir | --bindir | --bindi | --bind | --bin | --bi)
1296     ac_prev=bindir ;;
1297   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1298     bindir=$ac_optarg ;;
1299 
1300   -build | --build | --buil | --bui | --bu)
1301     ac_prev=build_alias ;;
1302   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1303     build_alias=$ac_optarg ;;
1304 
1305   -cache-file | --cache-file | --cache-fil | --cache-fi \
1306   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1307     ac_prev=cache_file ;;
1308   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1309   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1310     cache_file=$ac_optarg ;;
1311 
1312   --config-cache | -C)
1313     cache_file=config.cache ;;
1314 
1315   -datadir | --datadir | --datadi | --datad)
1316     ac_prev=datadir ;;
1317   -datadir=* | --datadir=* | --datadi=* | --datad=*)
1318     datadir=$ac_optarg ;;
1319 
1320   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1321   | --dataroo | --dataro | --datar)
1322     ac_prev=datarootdir ;;
1323   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1324   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1325     datarootdir=$ac_optarg ;;
1326 
1327   -disable-* | --disable-*)
1328     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1329     # Reject names that are not valid shell variable names.
1330     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1331       as_fn_error $? "invalid feature name: $ac_useropt"
1332     ac_useropt_orig=$ac_useropt
1333     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1334     case $ac_user_opts in
1335       *"
1336 "enable_$ac_useropt"
1337 "*) ;;
1338       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1339          ac_unrecognized_sep=', ';;
1340     esac
1341     eval enable_$ac_useropt=no ;;
1342 
1343   -docdir | --docdir | --docdi | --doc | --do)
1344     ac_prev=docdir ;;
1345   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1346     docdir=$ac_optarg ;;
1347 
1348   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1349     ac_prev=dvidir ;;
1350   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1351     dvidir=$ac_optarg ;;
1352 
1353   -enable-* | --enable-*)
1354     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1355     # Reject names that are not valid shell variable names.
1356     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1357       as_fn_error $? "invalid feature name: $ac_useropt"
1358     ac_useropt_orig=$ac_useropt
1359     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1360     case $ac_user_opts in
1361       *"
1362 "enable_$ac_useropt"
1363 "*) ;;
1364       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1365          ac_unrecognized_sep=', ';;
1366     esac
1367     eval enable_$ac_useropt=\$ac_optarg ;;
1368 
1369   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1370   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1371   | --exec | --exe | --ex)
1372     ac_prev=exec_prefix ;;
1373   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1374   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1375   | --exec=* | --exe=* | --ex=*)
1376     exec_prefix=$ac_optarg ;;
1377 
1378   -gas | --gas | --ga | --g)
1379     # Obsolete; use --with-gas.
1380     with_gas=yes ;;
1381 
1382   -help | --help | --hel | --he | -h)
1383     ac_init_help=long ;;
1384   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1385     ac_init_help=recursive ;;
1386   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1387     ac_init_help=short ;;
1388 
1389   -host | --host | --hos | --ho)
1390     ac_prev=host_alias ;;
1391   -host=* | --host=* | --hos=* | --ho=*)
1392     host_alias=$ac_optarg ;;
1393 
1394   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1395     ac_prev=htmldir ;;
1396   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1397   | --ht=*)
1398     htmldir=$ac_optarg ;;
1399 
1400   -includedir | --includedir | --includedi | --included | --include \
1401   | --includ | --inclu | --incl | --inc)
1402     ac_prev=includedir ;;
1403   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1404   | --includ=* | --inclu=* | --incl=* | --inc=*)
1405     includedir=$ac_optarg ;;
1406 
1407   -infodir | --infodir | --infodi | --infod | --info | --inf)
1408     ac_prev=infodir ;;
1409   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1410     infodir=$ac_optarg ;;
1411 
1412   -libdir | --libdir | --libdi | --libd)
1413     ac_prev=libdir ;;
1414   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1415     libdir=$ac_optarg ;;
1416 
1417   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1418   | --libexe | --libex | --libe)
1419     ac_prev=libexecdir ;;
1420   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1421   | --libexe=* | --libex=* | --libe=*)
1422     libexecdir=$ac_optarg ;;
1423 
1424   -localedir | --localedir | --localedi | --localed | --locale)
1425     ac_prev=localedir ;;
1426   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1427     localedir=$ac_optarg ;;
1428 
1429   -localstatedir | --localstatedir | --localstatedi | --localstated \
1430   | --localstate | --localstat | --localsta | --localst | --locals)
1431     ac_prev=localstatedir ;;
1432   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1433   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1434     localstatedir=$ac_optarg ;;
1435 
1436   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1437     ac_prev=mandir ;;
1438   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1439     mandir=$ac_optarg ;;
1440 
1441   -nfp | --nfp | --nf)
1442     # Obsolete; use --without-fp.
1443     with_fp=no ;;
1444 
1445   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1446   | --no-cr | --no-c | -n)
1447     no_create=yes ;;
1448 
1449   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1450   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1451     no_recursion=yes ;;
1452 
1453   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1454   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1455   | --oldin | --oldi | --old | --ol | --o)
1456     ac_prev=oldincludedir ;;
1457   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1458   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1459   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1460     oldincludedir=$ac_optarg ;;
1461 
1462   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1463     ac_prev=prefix ;;
1464   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1465     prefix=$ac_optarg ;;
1466 
1467   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1468   | --program-pre | --program-pr | --program-p)
1469     ac_prev=program_prefix ;;
1470   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1471   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1472     program_prefix=$ac_optarg ;;
1473 
1474   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1475   | --program-suf | --program-su | --program-s)
1476     ac_prev=program_suffix ;;
1477   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1478   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1479     program_suffix=$ac_optarg ;;
1480 
1481   -program-transform-name | --program-transform-name \
1482   | --program-transform-nam | --program-transform-na \
1483   | --program-transform-n | --program-transform- \
1484   | --program-transform | --program-transfor \
1485   | --program-transfo | --program-transf \
1486   | --program-trans | --program-tran \
1487   | --progr-tra | --program-tr | --program-t)
1488     ac_prev=program_transform_name ;;
1489   -program-transform-name=* | --program-transform-name=* \
1490   | --program-transform-nam=* | --program-transform-na=* \
1491   | --program-transform-n=* | --program-transform-=* \
1492   | --program-transform=* | --program-transfor=* \
1493   | --program-transfo=* | --program-transf=* \
1494   | --program-trans=* | --program-tran=* \
1495   | --progr-tra=* | --program-tr=* | --program-t=*)
1496     program_transform_name=$ac_optarg ;;
1497 
1498   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1499     ac_prev=pdfdir ;;
1500   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1501     pdfdir=$ac_optarg ;;
1502 
1503   -psdir | --psdir | --psdi | --psd | --ps)
1504     ac_prev=psdir ;;
1505   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1506     psdir=$ac_optarg ;;
1507 
1508   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1509   | -silent | --silent | --silen | --sile | --sil)
1510     silent=yes ;;
1511 
1512   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1513     ac_prev=sbindir ;;
1514   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1515   | --sbi=* | --sb=*)
1516     sbindir=$ac_optarg ;;
1517 
1518   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1519   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1520   | --sharedst | --shareds | --shared | --share | --shar \
1521   | --sha | --sh)
1522     ac_prev=sharedstatedir ;;
1523   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1524   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1525   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1526   | --sha=* | --sh=*)
1527     sharedstatedir=$ac_optarg ;;
1528 
1529   -site | --site | --sit)
1530     ac_prev=site ;;
1531   -site=* | --site=* | --sit=*)
1532     site=$ac_optarg ;;
1533 
1534   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1535     ac_prev=srcdir ;;
1536   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1537     srcdir=$ac_optarg ;;
1538 
1539   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1540   | --syscon | --sysco | --sysc | --sys | --sy)
1541     ac_prev=sysconfdir ;;
1542   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1543   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1544     sysconfdir=$ac_optarg ;;
1545 
1546   -target | --target | --targe | --targ | --tar | --ta | --t)
1547     ac_prev=target_alias ;;
1548   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1549     target_alias=$ac_optarg ;;
1550 
1551   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1552     verbose=yes ;;
1553 
1554   -version | --version | --versio | --versi | --vers | -V)
1555     ac_init_version=: ;;
1556 
1557   -with-* | --with-*)
1558     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1559     # Reject names that are not valid shell variable names.
1560     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1561       as_fn_error $? "invalid package name: $ac_useropt"
1562     ac_useropt_orig=$ac_useropt
1563     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1564     case $ac_user_opts in
1565       *"
1566 "with_$ac_useropt"
1567 "*) ;;
1568       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1569          ac_unrecognized_sep=', ';;
1570     esac
1571     eval with_$ac_useropt=\$ac_optarg ;;
1572 
1573   -without-* | --without-*)
1574     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1575     # Reject names that are not valid shell variable names.
1576     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1577       as_fn_error $? "invalid package name: $ac_useropt"
1578     ac_useropt_orig=$ac_useropt
1579     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1580     case $ac_user_opts in
1581       *"
1582 "with_$ac_useropt"
1583 "*) ;;
1584       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1585          ac_unrecognized_sep=', ';;
1586     esac
1587     eval with_$ac_useropt=no ;;
1588 
1589   --x)
1590     # Obsolete; use --with-x.
1591     with_x=yes ;;
1592 
1593   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1594   | --x-incl | --x-inc | --x-in | --x-i)
1595     ac_prev=x_includes ;;
1596   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1597   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1598     x_includes=$ac_optarg ;;
1599 
1600   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1601   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1602     ac_prev=x_libraries ;;
1603   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1604   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1605     x_libraries=$ac_optarg ;;
1606 
1607   -*) as_fn_error $? "unrecognized option: \`$ac_option'
1608 Try \`$0 --help' for more information"
1609     ;;
1610 
1611   *=*)
1612     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1613     # Reject names that are not valid shell variable names.
1614     case $ac_envvar in #(
1615       '' | [0-9]* | *[!_$as_cr_alnum]* )
1616       as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1617     esac
1618     eval $ac_envvar=\$ac_optarg
1619     export $ac_envvar ;;
1620 
1621   *)
1622     # FIXME: should be removed in autoconf 3.0.
1623     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1624     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1625       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1626     : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1627     ;;
1628 
1629   esac
1630 done
1631 
1632 if test -n "$ac_prev"; then
1633   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1634   as_fn_error $? "missing argument to $ac_option"
1635 fi
1636 
1637 if test -n "$ac_unrecognized_opts"; then
1638   case $enable_option_checking in
1639     no) ;;
1640     fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1641     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1642   esac
1643 fi
1644 
1645 # Check all directory arguments for consistency.
1646 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1647                 datadir sysconfdir sharedstatedir localstatedir includedir \
1648                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1649                 libdir localedir mandir
1650 do
1651   eval ac_val=\$$ac_var
1652   # Remove trailing slashes.
1653   case $ac_val in
1654     */ )
1655       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1656       eval $ac_var=\$ac_val;;
1657   esac
1658   # Be sure to have absolute directory names.
1659   case $ac_val in
1660     [\\/$]* | ?:[\\/]* )  continue;;
1661     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1662   esac
1663   as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1664 done
1665 
1666 # There might be people who depend on the old broken behavior: `$host'
1667 # used to hold the argument of --host etc.
1668 # FIXME: To remove some day.
1669 build=$build_alias
1670 host=$host_alias
1671 target=$target_alias
1672 
1673 # FIXME: To remove some day.
1674 if test "x$host_alias" != x; then
1675   if test "x$build_alias" = x; then
1676     cross_compiling=maybe
1677   elif test "x$build_alias" != "x$host_alias"; then
1678     cross_compiling=yes
1679   fi
1680 fi
1681 
1682 ac_tool_prefix=
1683 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1684 
1685 test "$silent" = yes && exec 6>/dev/null
1686 
1687 
1688 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1689 ac_ls_di=`ls -di .` &&
1690 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1691   as_fn_error $? "working directory cannot be determined"
1692 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1693   as_fn_error $? "pwd does not report name of working directory"
1694 
1695 
1696 # Find the source files, if location was not specified.
1697 if test -z "$srcdir"; then
1698   ac_srcdir_defaulted=yes
1699   # Try the directory containing this script, then the parent directory.
1700   ac_confdir=`$as_dirname -- "$as_myself" ||
1701 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1702          X"$as_myself" : 'X\(//\)[^/]' \| \
1703          X"$as_myself" : 'X\(//\)$' \| \
1704          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1705 $as_echo X"$as_myself" |
1706     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1707             s//\1/
1708             q
1709           }
1710           /^X\(\/\/\)[^/].*/{
1711             s//\1/
1712             q
1713           }
1714           /^X\(\/\/\)$/{
1715             s//\1/
1716             q
1717           }
1718           /^X\(\/\).*/{
1719             s//\1/
1720             q
1721           }
1722           s/.*/./; q'`
1723   srcdir=$ac_confdir
1724   if test ! -r "$srcdir/$ac_unique_file"; then
1725     srcdir=..
1726   fi
1727 else
1728   ac_srcdir_defaulted=no
1729 fi
1730 if test ! -r "$srcdir/$ac_unique_file"; then
1731   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1732   as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1733 fi
1734 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1735 ac_abs_confdir=`(
1736         cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1737         pwd)`
1738 # When building in place, set srcdir=.
1739 if test "$ac_abs_confdir" = "$ac_pwd"; then
1740   srcdir=.
1741 fi
1742 # Remove unnecessary trailing slashes from srcdir.
1743 # Double slashes in file names in object file debugging info
1744 # mess up M-x gdb in Emacs.
1745 case $srcdir in
1746 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1747 esac
1748 for ac_var in $ac_precious_vars; do
1749   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1750   eval ac_env_${ac_var}_value=\$${ac_var}
1751   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1752   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1753 done
1754 
1755 #
1756 # Report the --help message.
1757 #
1758 if test "$ac_init_help" = "long"; then
1759   # Omit some internal or obsolete options to make the list less imposing.
1760   # This message is too long to be a string in the A/UX 3.1 sh.
1761   cat <<_ACEOF
1762 \`configure' configures OpenJDK jdk9 to adapt to many kinds of systems.
1763 
1764 Usage: $0 [OPTION]... [VAR=VALUE]...
1765 
1766 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1767 VAR=VALUE.  See below for descriptions of some of the useful variables.
1768 
1769 Defaults for the options are specified in brackets.
1770 
1771 Configuration:
1772   -h, --help              display this help and exit
1773       --help=short        display options specific to this package
1774       --help=recursive    display the short help of all the included packages
1775   -V, --version           display version information and exit
1776   -q, --quiet, --silent   do not print \`checking ...' messages
1777       --cache-file=FILE   cache test results in FILE [disabled]
1778   -C, --config-cache      alias for \`--cache-file=config.cache'
1779   -n, --no-create         do not create output files
1780       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1781 
1782 Installation directories:
1783   --prefix=PREFIX         install architecture-independent files in PREFIX
1784                           [$ac_default_prefix]
1785   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1786                           [PREFIX]
1787 
1788 By default, \`make install' will install all the files in
1789 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1790 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1791 for instance \`--prefix=\$HOME'.
1792 
1793 For better control, use the options below.
1794 
1795 Fine tuning of the installation directories:
1796   --bindir=DIR            user executables [EPREFIX/bin]
1797   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1798   --libexecdir=DIR        program executables [EPREFIX/libexec]
1799   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1800   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1801   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1802   --libdir=DIR            object code libraries [EPREFIX/lib]
1803   --includedir=DIR        C header files [PREFIX/include]
1804   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1805   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1806   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1807   --infodir=DIR           info documentation [DATAROOTDIR/info]
1808   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1809   --mandir=DIR            man documentation [DATAROOTDIR/man]
1810   --docdir=DIR            documentation root [DATAROOTDIR/doc/openjdk]
1811   --htmldir=DIR           html documentation [DOCDIR]
1812   --dvidir=DIR            dvi documentation [DOCDIR]
1813   --pdfdir=DIR            pdf documentation [DOCDIR]
1814   --psdir=DIR             ps documentation [DOCDIR]
1815 _ACEOF
1816 
1817   cat <<\_ACEOF
1818 
1819 X features:
1820   --x-includes=DIR    X include files are in DIR
1821   --x-libraries=DIR   X library files are in DIR
1822 
1823 System types:
1824   --build=BUILD     configure for building on BUILD [guessed]
1825   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1826   --target=TARGET   configure for building compilers for TARGET [HOST]
1827 _ACEOF
1828 fi
1829 
1830 if test -n "$ac_init_help"; then
1831   case $ac_init_help in
1832      short | recursive ) echo "Configuration of OpenJDK jdk9:";;
1833    esac
1834   cat <<\_ACEOF
1835 
1836 Optional Features:
1837   --disable-option-checking  ignore unrecognized --enable/--with options
1838   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1839   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1840   --enable-openjdk-only   suppress building custom source even if present
1841                           [disabled]
1842   --enable-debug          set the debug level to fastdebug (shorthand for
1843                           --with-debug-level=fastdebug) [disabled]
1844   --disable-headful       disable building headful support (graphical UI
1845                           support) [enabled]
1846   --enable-hotspot-test-in-build
1847                           run the Queens test after Hotspot build [disabled]
1848   --enable-unlimited-crypto
1849                           Enable unlimited crypto policy [disabled]
1850   --enable-rmiconnector-iiop
1851                           enable the JMX RMIConnector iiop transport
1852                           [disabled]
1853   --disable-debug-symbols disable generation of debug symbols [enabled]
1854   --disable-zip-debug-info
1855                           disable zipping of debug-info files [enabled]
1856   --disable-freetype-bundling
1857                           disable bundling of the freetype library with the
1858                           build result [enabled on Windows or when using
1859                           --with-freetype, disabled otherwise]
1860   --enable-sjavac         use sjavac to do fast incremental compiles
1861                           [disabled]
1862   --disable-precompiled-headers
1863                           disable using precompiled headers when compiling C++
1864                           [enabled]
1865   --enable-ccache         enable using ccache to speed up recompilations
1866                           [disabled]
1867 
1868 Optional Packages:
1869   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1870   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1871   --with-target-bits      build 32-bit or 64-bit binaries (for platforms that
1872                           support it), e.g. --with-target-bits=32 [guessed]
1873   --with-custom-make-dir  Deprecated. Option is kept for backwards
1874                           compatibility and is ignored
1875   --with-jdk-variant      JDK variant to build (normal) [normal]
1876   --with-jvm-interpreter  JVM interpreter to build (template, cpp) [template]
1877   --with-jvm-variants     JVM variants (separated by commas) to build (server,
1878                           client, minimal1, kernel, zero, zeroshark, core)
1879                           [server]
1880   --with-debug-level      set the debug level (release, fastdebug, slowdebug,
1881                           optimized (HotSpot build only)) [release]
1882   --with-devkit           use this devkit for compilers, tools and resources
1883   --with-sys-root         alias for --with-sysroot for backwards compatability
1884   --with-sysroot          use this directory as sysroot
1885   --with-tools-dir        alias for --with-toolchain-path for backwards
1886                           compatibility
1887   --with-toolchain-path   prepend these directories when searching for
1888                           toolchain binaries (compilers etc)
1889   --with-extra-path       prepend these directories to the default path
1890   --with-sdk-name         use the platform SDK of the given name. [macosx]
1891   --with-conf-name        use this as the name of the configuration [generated
1892                           from important configuration options]
1893   --with-output-sync      set make output sync type if supported by make.
1894                           [recurse]
1895   --with-builddeps-conf   use this configuration file for the builddeps
1896   --with-builddeps-server download and use build dependencies from this server
1897                           url
1898   --with-builddeps-dir    store downloaded build dependencies here
1899                           [/localhome/builddeps]
1900   --with-builddeps-group  chgrp the downloaded build dependencies to this
1901                           group
1902   --with-cacerts-file     specify alternative cacerts file
1903   --with-milestone        Set milestone value for build [internal]
1904   --with-update-version   Set update version value for build [b00]
1905   --with-user-release-suffix
1906                           Add a custom string to the version string if build
1907                           number is not set.[username_builddateb00]
1908   --with-build-number     Set build number value for build [b00]
1909   --with-copyright-year   Set copyright year value for build [current year]
1910   --with-boot-jdk         path to Boot JDK (used to bootstrap build) [probed]
1911   --with-add-source-root  for each and every source directory, look in this
1912                           additional source root for the same directory; if it
1913                           exists and have files in it, include it in the build
1914   --with-override-source-root
1915                           for each and every source directory, look in this
1916                           override source root for the same directory; if it
1917                           exists, use that directory instead and ignore the
1918                           directory in the original source root
1919   --with-adds-and-overrides
1920                           use the subdirs 'adds' and 'overrides' in the
1921                           specified directory as add-source-root and
1922                           override-source-root
1923   --with-override-langtools
1924                           use this langtools dir for the build
1925   --with-override-corba   use this corba dir for the build
1926   --with-override-jaxp    use this jaxp dir for the build
1927   --with-override-jaxws   use this jaxws dir for the build
1928   --with-override-hotspot use this hotspot dir for the build
1929   --with-override-nashorn use this nashorn dir for the build
1930   --with-override-jdk     use this jdk dir for the build
1931   --with-import-hotspot   import hotspot binaries from this jdk image or
1932                           hotspot build dist dir instead of building from
1933                           source
1934   --with-toolchain-type   the toolchain type (or family) to use, use '--help'
1935                           to show possible values [platform dependent]
1936   --with-jtreg            Regression Test Harness [probed]
1937   --with-extra-cflags     extra flags to be used when compiling jdk c-files
1938   --with-extra-cxxflags   extra flags to be used when compiling jdk c++-files
1939   --with-extra-ldflags    extra flags to be used when linking jdk
1940   --with-x                use the X Window System
1941   --with-cups             specify prefix directory for the cups package
1942                           (expecting the headers under PATH/include)
1943   --with-cups-include     specify directory for the cups include files
1944   --with-freetype         specify prefix directory for the freetype package
1945                           (expecting the libraries under PATH/lib and the
1946                           headers under PATH/include)
1947   --with-freetype-include specify directory for the freetype include files
1948   --with-freetype-lib     specify directory for the freetype library
1949   --with-freetype-src     specify directory with freetype sources to
1950                           automatically build the library (experimental,
1951                           Windows-only)
1952   --with-alsa             specify prefix directory for the alsa package
1953                           (expecting the libraries under PATH/lib and the
1954                           headers under PATH/include)
1955   --with-alsa-include     specify directory for the alsa include files
1956   --with-alsa-lib         specify directory for the alsa library
1957   --with-libjpeg          use libjpeg from build system or OpenJDK source
1958                           (system, bundled) [bundled]
1959   --with-giflib           use giflib from build system or OpenJDK source
1960                           (system, bundled) [bundled]
1961   --with-lcms             use lcms2 from build system or OpenJDK source
1962                           (system, bundled) [bundled]
1963   --with-libpng           use libpng from build system or OpenJDK source
1964                           (system, bundled) [bundled]
1965   --with-zlib             use zlib from build system or OpenJDK source
1966                           (system, bundled) [bundled]
1967   --with-stdc++lib=<static>,<dynamic>,<default>
1968                           force linking of the C++ runtime on Linux to either
1969                           static or dynamic, default is static with dynamic as
1970                           fallback
1971   --with-msvcr-dll        copy this msvcr100.dll into the built JDK (Windows
1972                           only) [probed]
1973   --with-dxsdk            Deprecated. Option is kept for backwards
1974                           compatibility and is ignored
1975   --with-dxsdk-lib        Deprecated. Option is kept for backwards
1976                           compatibility and is ignored
1977   --with-dxsdk-include    Deprecated. Option is kept for backwards
1978                           compatibility and is ignored
1979   --with-num-cores        number of cores in the build system, e.g.
1980                           --with-num-cores=8 [probed]
1981   --with-memory-size      memory (in MB) available in the build system, e.g.
1982                           --with-memory-size=1024 [probed]
1983   --with-jobs             number of parallel jobs to let make run [calculated
1984                           based on cores and memory]
1985   --with-boot-jdk-jvmargs specify JVM arguments to be passed to all java
1986                           invocations of boot JDK, overriding the default
1987                           values, e.g --with-boot-jdk-jvmargs="-Xmx8G
1988                           -enableassertions"
1989   --with-sjavac-server-java
1990                           use this java binary for running the sjavac
1991                           background server [Boot JDK java]
1992   --with-ccache-dir       where to store ccache files [~/.ccache]
1993 
1994 Some influential environment variables:
1995   BASENAME    Override default value for BASENAME
1996   BASH        Override default value for BASH
1997   CAT         Override default value for CAT
1998   CHMOD       Override default value for CHMOD
1999   CMP         Override default value for CMP
2000   COMM        Override default value for COMM
2001   CP          Override default value for CP
2002   CUT         Override default value for CUT
2003   DATE        Override default value for DATE
2004   DIFF        Override default value for DIFF
2005   DIRNAME     Override default value for DIRNAME
2006   ECHO        Override default value for ECHO
2007   EXPR        Override default value for EXPR
2008   FILE        Override default value for FILE
2009   FIND        Override default value for FIND
2010   HEAD        Override default value for HEAD
2011   LN          Override default value for LN
2012   LS          Override default value for LS
2013   MKDIR       Override default value for MKDIR
2014   MKTEMP      Override default value for MKTEMP
2015   MV          Override default value for MV
2016   NAWK        Override default value for NAWK
2017   PRINTF      Override default value for PRINTF
2018   RM          Override default value for RM
2019   SH          Override default value for SH
2020   SORT        Override default value for SORT
2021   TAIL        Override default value for TAIL
2022   TAR         Override default value for TAR
2023   TEE         Override default value for TEE
2024   TOUCH       Override default value for TOUCH
2025   TR          Override default value for TR
2026   UNAME       Override default value for UNAME
2027   UNIQ        Override default value for UNIQ
2028   WC          Override default value for WC
2029   WHICH       Override default value for WHICH
2030   XARGS       Override default value for XARGS
2031   AWK         Override default value for AWK
2032   GREP        Override default value for GREP
2033   EGREP       Override default value for EGREP
2034   FGREP       Override default value for FGREP
2035   SED         Override default value for SED
2036   CYGPATH     Override default value for CYGPATH
2037   READLINK    Override default value for READLINK
2038   DF          Override default value for DF
2039   SETFILE     Override default value for SETFILE
2040   CPIO        Override default value for CPIO
2041   UNZIP       Override default value for UNZIP
2042   ZIP         Override default value for ZIP
2043   LDD         Override default value for LDD
2044   OTOOL       Override default value for OTOOL
2045   READELF     Override default value for READELF
2046   HG          Override default value for HG
2047   STAT        Override default value for STAT
2048   TIME        Override default value for TIME
2049   DSYMUTIL    Override default value for DSYMUTIL
2050   XATTR       Override default value for XATTR
2051   CODESIGN    Override default value for CODESIGN
2052   PKG_CONFIG  path to pkg-config utility
2053   JAVA        Override default value for JAVA
2054   JAVAC       Override default value for JAVAC
2055   JAVAH       Override default value for JAVAH
2056   JAR         Override default value for JAR
2057   NATIVE2ASCII
2058               Override default value for NATIVE2ASCII
2059   JARSIGNER   Override default value for JARSIGNER
2060   CC          C compiler command
2061   CFLAGS      C compiler flags
2062   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
2063               nonstandard directory <lib dir>
2064   LIBS        libraries to pass to the linker, e.g. -l<library>
2065   CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2066               you have headers in a nonstandard directory <include dir>
2067   CXX         C++ compiler command
2068   CXXFLAGS    C++ compiler flags
2069   CPP         C preprocessor
2070   CXXCPP      C++ preprocessor
2071   AS          Override default value for AS
2072   AR          Override default value for AR
2073   OBJC        Objective C compiler command
2074   OBJCFLAGS   Objective C compiler flags
2075   LIPO        Override default value for LIPO
2076   STRIP       Override default value for STRIP
2077   NM          Override default value for NM
2078   GNM         Override default value for GNM
2079   MCS         Override default value for MCS
2080   OBJCOPY     Override default value for OBJCOPY
2081   OBJDUMP     Override default value for OBJDUMP
2082   BUILD_CC    Override default value for BUILD_CC
2083   BUILD_CXX   Override default value for BUILD_CXX
2084   BUILD_LD    Override default value for BUILD_LD
2085   JTREGEXE    Override default value for JTREGEXE
2086   XMKMF       Path to xmkmf, Makefile generator for X Window System
2087   FREETYPE_CFLAGS
2088               C compiler flags for FREETYPE, overriding pkg-config
2089   FREETYPE_LIBS
2090               linker flags for FREETYPE, overriding pkg-config
2091   ALSA_CFLAGS C compiler flags for ALSA, overriding pkg-config
2092   ALSA_LIBS   linker flags for ALSA, overriding pkg-config
2093   LCMS_CFLAGS C compiler flags for LCMS, overriding pkg-config
2094   LCMS_LIBS   linker flags for LCMS, overriding pkg-config
2095   PNG_CFLAGS  C compiler flags for PNG, overriding pkg-config
2096   PNG_LIBS    linker flags for PNG, overriding pkg-config
2097   LIBFFI_CFLAGS
2098               C compiler flags for LIBFFI, overriding pkg-config
2099   LIBFFI_LIBS linker flags for LIBFFI, overriding pkg-config
2100   CCACHE      Override default value for CCACHE
2101 
2102 Use these variables to override the choices made by `configure' or to help
2103 it to find libraries and programs with nonstandard names/locations.
2104 
2105 Report bugs to <build-dev@openjdk.java.net>.
2106 OpenJDK home page: <http://openjdk.java.net>.
2107 _ACEOF
2108 ac_status=$?
2109 fi
2110 
2111 if test "$ac_init_help" = "recursive"; then
2112   # If there are subdirs, report their specific --help.
2113   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2114     test -d "$ac_dir" ||
2115       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2116       continue
2117     ac_builddir=.
2118 
2119 case "$ac_dir" in
2120 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2121 *)
2122   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2123   # A ".." for each directory in $ac_dir_suffix.
2124   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2125   case $ac_top_builddir_sub in
2126   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2127   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2128   esac ;;
2129 esac
2130 ac_abs_top_builddir=$ac_pwd
2131 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2132 # for backward compatibility:
2133 ac_top_builddir=$ac_top_build_prefix
2134 
2135 case $srcdir in
2136   .)  # We are building in place.
2137     ac_srcdir=.
2138     ac_top_srcdir=$ac_top_builddir_sub
2139     ac_abs_top_srcdir=$ac_pwd ;;
2140   [\\/]* | ?:[\\/]* )  # Absolute name.
2141     ac_srcdir=$srcdir$ac_dir_suffix;
2142     ac_top_srcdir=$srcdir
2143     ac_abs_top_srcdir=$srcdir ;;
2144   *) # Relative name.
2145     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2146     ac_top_srcdir=$ac_top_build_prefix$srcdir
2147     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2148 esac
2149 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2150 
2151     cd "$ac_dir" || { ac_status=$?; continue; }
2152     # Check for guested configure.
2153     if test -f "$ac_srcdir/configure.gnu"; then
2154       echo &&
2155       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2156     elif test -f "$ac_srcdir/configure"; then
2157       echo &&
2158       $SHELL "$ac_srcdir/configure" --help=recursive
2159     else
2160       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2161     fi || ac_status=$?
2162     cd "$ac_pwd" || { ac_status=$?; break; }
2163   done
2164 fi
2165 
2166 test -n "$ac_init_help" && exit $ac_status
2167 if $ac_init_version; then
2168   cat <<\_ACEOF
2169 OpenJDK configure jdk9
2170 generated by GNU Autoconf 2.69
2171 
2172 Copyright (C) 2012 Free Software Foundation, Inc.
2173 This configure script is free software; the Free Software Foundation
2174 gives unlimited permission to copy, distribute and modify it.
2175 _ACEOF
2176   exit
2177 fi
2178 
2179 ## ------------------------ ##
2180 ## Autoconf initialization. ##
2181 ## ------------------------ ##
2182 
2183 # ac_fn_c_try_compile LINENO
2184 # --------------------------
2185 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2186 ac_fn_c_try_compile ()
2187 {
2188   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2189   rm -f conftest.$ac_objext
2190   if { { ac_try="$ac_compile"
2191 case "(($ac_try" in
2192   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2193   *) ac_try_echo=$ac_try;;
2194 esac
2195 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2196 $as_echo "$ac_try_echo"; } >&5
2197   (eval "$ac_compile") 2>conftest.err
2198   ac_status=$?
2199   if test -s conftest.err; then
2200     grep -v '^ *+' conftest.err >conftest.er1
2201     cat conftest.er1 >&5
2202     mv -f conftest.er1 conftest.err
2203   fi
2204   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2205   test $ac_status = 0; } && {
2206          test -z "$ac_c_werror_flag" ||
2207          test ! -s conftest.err
2208        } && test -s conftest.$ac_objext; then :
2209   ac_retval=0
2210 else
2211   $as_echo "$as_me: failed program was:" >&5
2212 sed 's/^/| /' conftest.$ac_ext >&5
2213 
2214         ac_retval=1
2215 fi
2216   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2217   as_fn_set_status $ac_retval
2218 
2219 } # ac_fn_c_try_compile
2220 
2221 # ac_fn_cxx_try_compile LINENO
2222 # ----------------------------
2223 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2224 ac_fn_cxx_try_compile ()
2225 {
2226   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2227   rm -f conftest.$ac_objext
2228   if { { ac_try="$ac_compile"
2229 case "(($ac_try" in
2230   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2231   *) ac_try_echo=$ac_try;;
2232 esac
2233 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2234 $as_echo "$ac_try_echo"; } >&5
2235   (eval "$ac_compile") 2>conftest.err
2236   ac_status=$?
2237   if test -s conftest.err; then
2238     grep -v '^ *+' conftest.err >conftest.er1
2239     cat conftest.er1 >&5
2240     mv -f conftest.er1 conftest.err
2241   fi
2242   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2243   test $ac_status = 0; } && {
2244          test -z "$ac_cxx_werror_flag" ||
2245          test ! -s conftest.err
2246        } && test -s conftest.$ac_objext; then :
2247   ac_retval=0
2248 else
2249   $as_echo "$as_me: failed program was:" >&5
2250 sed 's/^/| /' conftest.$ac_ext >&5
2251 
2252         ac_retval=1
2253 fi
2254   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2255   as_fn_set_status $ac_retval
2256 
2257 } # ac_fn_cxx_try_compile
2258 
2259 # ac_fn_c_try_cpp LINENO
2260 # ----------------------
2261 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2262 ac_fn_c_try_cpp ()
2263 {
2264   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2265   if { { ac_try="$ac_cpp conftest.$ac_ext"
2266 case "(($ac_try" in
2267   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2268   *) ac_try_echo=$ac_try;;
2269 esac
2270 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2271 $as_echo "$ac_try_echo"; } >&5
2272   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2273   ac_status=$?
2274   if test -s conftest.err; then
2275     grep -v '^ *+' conftest.err >conftest.er1
2276     cat conftest.er1 >&5
2277     mv -f conftest.er1 conftest.err
2278   fi
2279   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2280   test $ac_status = 0; } > conftest.i && {
2281          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2282          test ! -s conftest.err
2283        }; then :
2284   ac_retval=0
2285 else
2286   $as_echo "$as_me: failed program was:" >&5
2287 sed 's/^/| /' conftest.$ac_ext >&5
2288 
2289     ac_retval=1
2290 fi
2291   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2292   as_fn_set_status $ac_retval
2293 
2294 } # ac_fn_c_try_cpp
2295 
2296 # ac_fn_cxx_try_cpp LINENO
2297 # ------------------------
2298 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2299 ac_fn_cxx_try_cpp ()
2300 {
2301   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2302   if { { ac_try="$ac_cpp conftest.$ac_ext"
2303 case "(($ac_try" in
2304   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2305   *) ac_try_echo=$ac_try;;
2306 esac
2307 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2308 $as_echo "$ac_try_echo"; } >&5
2309   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2310   ac_status=$?
2311   if test -s conftest.err; then
2312     grep -v '^ *+' conftest.err >conftest.er1
2313     cat conftest.er1 >&5
2314     mv -f conftest.er1 conftest.err
2315   fi
2316   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2317   test $ac_status = 0; } > conftest.i && {
2318          test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
2319          test ! -s conftest.err
2320        }; then :
2321   ac_retval=0
2322 else
2323   $as_echo "$as_me: failed program was:" >&5
2324 sed 's/^/| /' conftest.$ac_ext >&5
2325 
2326     ac_retval=1
2327 fi
2328   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2329   as_fn_set_status $ac_retval
2330 
2331 } # ac_fn_cxx_try_cpp
2332 
2333 # ac_fn_objc_try_compile LINENO
2334 # -----------------------------
2335 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2336 ac_fn_objc_try_compile ()
2337 {
2338   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2339   rm -f conftest.$ac_objext
2340   if { { ac_try="$ac_compile"
2341 case "(($ac_try" in
2342   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2343   *) ac_try_echo=$ac_try;;
2344 esac
2345 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2346 $as_echo "$ac_try_echo"; } >&5
2347   (eval "$ac_compile") 2>conftest.err
2348   ac_status=$?
2349   if test -s conftest.err; then
2350     grep -v '^ *+' conftest.err >conftest.er1
2351     cat conftest.er1 >&5
2352     mv -f conftest.er1 conftest.err
2353   fi
2354   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2355   test $ac_status = 0; } && {
2356          test -z "$ac_objc_werror_flag" ||
2357          test ! -s conftest.err
2358        } && test -s conftest.$ac_objext; then :
2359   ac_retval=0
2360 else
2361   $as_echo "$as_me: failed program was:" >&5
2362 sed 's/^/| /' conftest.$ac_ext >&5
2363 
2364         ac_retval=1
2365 fi
2366   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2367   as_fn_set_status $ac_retval
2368 
2369 } # ac_fn_objc_try_compile
2370 
2371 # ac_fn_c_try_link LINENO
2372 # -----------------------
2373 # Try to link conftest.$ac_ext, and return whether this succeeded.
2374 ac_fn_c_try_link ()
2375 {
2376   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2377   rm -f conftest.$ac_objext conftest$ac_exeext
2378   if { { ac_try="$ac_link"
2379 case "(($ac_try" in
2380   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2381   *) ac_try_echo=$ac_try;;
2382 esac
2383 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2384 $as_echo "$ac_try_echo"; } >&5
2385   (eval "$ac_link") 2>conftest.err
2386   ac_status=$?
2387   if test -s conftest.err; then
2388     grep -v '^ *+' conftest.err >conftest.er1
2389     cat conftest.er1 >&5
2390     mv -f conftest.er1 conftest.err
2391   fi
2392   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2393   test $ac_status = 0; } && {
2394          test -z "$ac_c_werror_flag" ||
2395          test ! -s conftest.err
2396        } && test -s conftest$ac_exeext && {
2397          test "$cross_compiling" = yes ||
2398          test -x conftest$ac_exeext
2399        }; then :
2400   ac_retval=0
2401 else
2402   $as_echo "$as_me: failed program was:" >&5
2403 sed 's/^/| /' conftest.$ac_ext >&5
2404 
2405         ac_retval=1
2406 fi
2407   # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2408   # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2409   # interfere with the next link command; also delete a directory that is
2410   # left behind by Apple's compiler.  We do this before executing the actions.
2411   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2412   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2413   as_fn_set_status $ac_retval
2414 
2415 } # ac_fn_c_try_link
2416 
2417 # ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES
2418 # ---------------------------------------------------------
2419 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2420 # the include files in INCLUDES and setting the cache variable VAR
2421 # accordingly.
2422 ac_fn_cxx_check_header_mongrel ()
2423 {
2424   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2425   if eval \${$3+:} false; then :
2426   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2427 $as_echo_n "checking for $2... " >&6; }
2428 if eval \${$3+:} false; then :
2429   $as_echo_n "(cached) " >&6
2430 fi
2431 eval ac_res=\$$3
2432                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2433 $as_echo "$ac_res" >&6; }
2434 else
2435   # Is the header compilable?
2436 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2437 $as_echo_n "checking $2 usability... " >&6; }
2438 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2439 /* end confdefs.h.  */
2440 $4
2441 #include <$2>
2442 _ACEOF
2443 if ac_fn_cxx_try_compile "$LINENO"; then :
2444   ac_header_compiler=yes
2445 else
2446   ac_header_compiler=no
2447 fi
2448 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2450 $as_echo "$ac_header_compiler" >&6; }
2451 
2452 # Is the header present?
2453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2454 $as_echo_n "checking $2 presence... " >&6; }
2455 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2456 /* end confdefs.h.  */
2457 #include <$2>
2458 _ACEOF
2459 if ac_fn_cxx_try_cpp "$LINENO"; then :
2460   ac_header_preproc=yes
2461 else
2462   ac_header_preproc=no
2463 fi
2464 rm -f conftest.err conftest.i conftest.$ac_ext
2465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2466 $as_echo "$ac_header_preproc" >&6; }
2467 
2468 # So?  What about this header?
2469 case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #((
2470   yes:no: )
2471     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2472 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2473     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2474 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2475     ;;
2476   no:yes:* )
2477     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2478 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2479     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
2480 $as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
2481     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2482 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2483     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
2484 $as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
2485     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2486 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2487 ( $as_echo "## ----------------------------------------- ##
2488 ## Report this to build-dev@openjdk.java.net ##
2489 ## ----------------------------------------- ##"
2490      ) | sed "s/^/$as_me: WARNING:     /" >&2
2491     ;;
2492 esac
2493   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2494 $as_echo_n "checking for $2... " >&6; }
2495 if eval \${$3+:} false; then :
2496   $as_echo_n "(cached) " >&6
2497 else
2498   eval "$3=\$ac_header_compiler"
2499 fi
2500 eval ac_res=\$$3
2501                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2502 $as_echo "$ac_res" >&6; }
2503 fi
2504   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2505 
2506 } # ac_fn_cxx_check_header_mongrel
2507 
2508 # ac_fn_cxx_try_run LINENO
2509 # ------------------------
2510 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2511 # that executables *can* be run.
2512 ac_fn_cxx_try_run ()
2513 {
2514   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2515   if { { ac_try="$ac_link"
2516 case "(($ac_try" in
2517   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2518   *) ac_try_echo=$ac_try;;
2519 esac
2520 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2521 $as_echo "$ac_try_echo"; } >&5
2522   (eval "$ac_link") 2>&5
2523   ac_status=$?
2524   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2525   test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2526   { { case "(($ac_try" in
2527   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2528   *) ac_try_echo=$ac_try;;
2529 esac
2530 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2531 $as_echo "$ac_try_echo"; } >&5
2532   (eval "$ac_try") 2>&5
2533   ac_status=$?
2534   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2535   test $ac_status = 0; }; }; then :
2536   ac_retval=0
2537 else
2538   $as_echo "$as_me: program exited with status $ac_status" >&5
2539        $as_echo "$as_me: failed program was:" >&5
2540 sed 's/^/| /' conftest.$ac_ext >&5
2541 
2542        ac_retval=$ac_status
2543 fi
2544   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2545   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2546   as_fn_set_status $ac_retval
2547 
2548 } # ac_fn_cxx_try_run
2549 
2550 # ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES
2551 # ---------------------------------------------------------
2552 # Tests whether HEADER exists and can be compiled using the include files in
2553 # INCLUDES, setting the cache variable VAR accordingly.
2554 ac_fn_cxx_check_header_compile ()
2555 {
2556   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2557   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2558 $as_echo_n "checking for $2... " >&6; }
2559 if eval \${$3+:} false; then :
2560   $as_echo_n "(cached) " >&6
2561 else
2562   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2563 /* end confdefs.h.  */
2564 $4
2565 #include <$2>
2566 _ACEOF
2567 if ac_fn_cxx_try_compile "$LINENO"; then :
2568   eval "$3=yes"
2569 else
2570   eval "$3=no"
2571 fi
2572 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2573 fi
2574 eval ac_res=\$$3
2575                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2576 $as_echo "$ac_res" >&6; }
2577   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2578 
2579 } # ac_fn_cxx_check_header_compile
2580 
2581 # ac_fn_cxx_compute_int LINENO EXPR VAR INCLUDES
2582 # ----------------------------------------------
2583 # Tries to find the compile-time value of EXPR in a program that includes
2584 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2585 # computed
2586 ac_fn_cxx_compute_int ()
2587 {
2588   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2589   if test "$cross_compiling" = yes; then
2590     # Depending upon the size, compute the lo and hi bounds.
2591 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2592 /* end confdefs.h.  */
2593 $4
2594 int
2595 main ()
2596 {
2597 static int test_array [1 - 2 * !(($2) >= 0)];
2598 test_array [0] = 0;
2599 return test_array [0];
2600 
2601   ;
2602   return 0;
2603 }
2604 _ACEOF
2605 if ac_fn_cxx_try_compile "$LINENO"; then :
2606   ac_lo=0 ac_mid=0
2607   while :; do
2608     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2609 /* end confdefs.h.  */
2610 $4
2611 int
2612 main ()
2613 {
2614 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2615 test_array [0] = 0;
2616 return test_array [0];
2617 
2618   ;
2619   return 0;
2620 }
2621 _ACEOF
2622 if ac_fn_cxx_try_compile "$LINENO"; then :
2623   ac_hi=$ac_mid; break
2624 else
2625   as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2626                         if test $ac_lo -le $ac_mid; then
2627                           ac_lo= ac_hi=
2628                           break
2629                         fi
2630                         as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2631 fi
2632 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2633   done
2634 else
2635   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2636 /* end confdefs.h.  */
2637 $4
2638 int
2639 main ()
2640 {
2641 static int test_array [1 - 2 * !(($2) < 0)];
2642 test_array [0] = 0;
2643 return test_array [0];
2644 
2645   ;
2646   return 0;
2647 }
2648 _ACEOF
2649 if ac_fn_cxx_try_compile "$LINENO"; then :
2650   ac_hi=-1 ac_mid=-1
2651   while :; do
2652     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2653 /* end confdefs.h.  */
2654 $4
2655 int
2656 main ()
2657 {
2658 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2659 test_array [0] = 0;
2660 return test_array [0];
2661 
2662   ;
2663   return 0;
2664 }
2665 _ACEOF
2666 if ac_fn_cxx_try_compile "$LINENO"; then :
2667   ac_lo=$ac_mid; break
2668 else
2669   as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2670                         if test $ac_mid -le $ac_hi; then
2671                           ac_lo= ac_hi=
2672                           break
2673                         fi
2674                         as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2675 fi
2676 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2677   done
2678 else
2679   ac_lo= ac_hi=
2680 fi
2681 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2682 fi
2683 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2684 # Binary search between lo and hi bounds.
2685 while test "x$ac_lo" != "x$ac_hi"; do
2686   as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2687   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2688 /* end confdefs.h.  */
2689 $4
2690 int
2691 main ()
2692 {
2693 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2694 test_array [0] = 0;
2695 return test_array [0];
2696 
2697   ;
2698   return 0;
2699 }
2700 _ACEOF
2701 if ac_fn_cxx_try_compile "$LINENO"; then :
2702   ac_hi=$ac_mid
2703 else
2704   as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2705 fi
2706 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2707 done
2708 case $ac_lo in #((
2709 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2710 '') ac_retval=1 ;;
2711 esac
2712   else
2713     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2714 /* end confdefs.h.  */
2715 $4
2716 static long int longval () { return $2; }
2717 static unsigned long int ulongval () { return $2; }
2718 #include <stdio.h>
2719 #include <stdlib.h>
2720 int
2721 main ()
2722 {
2723 
2724   FILE *f = fopen ("conftest.val", "w");
2725   if (! f)
2726     return 1;
2727   if (($2) < 0)
2728     {
2729       long int i = longval ();
2730       if (i != ($2))
2731         return 1;
2732       fprintf (f, "%ld", i);
2733     }
2734   else
2735     {
2736       unsigned long int i = ulongval ();
2737       if (i != ($2))
2738         return 1;
2739       fprintf (f, "%lu", i);
2740     }
2741   /* Do not output a trailing newline, as this causes \r\n confusion
2742      on some platforms.  */
2743   return ferror (f) || fclose (f) != 0;
2744 
2745   ;
2746   return 0;
2747 }
2748 _ACEOF
2749 if ac_fn_cxx_try_run "$LINENO"; then :
2750   echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2751 else
2752   ac_retval=1
2753 fi
2754 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2755   conftest.$ac_objext conftest.beam conftest.$ac_ext
2756 rm -f conftest.val
2757 
2758   fi
2759   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2760   as_fn_set_status $ac_retval
2761 
2762 } # ac_fn_cxx_compute_int
2763 
2764 # ac_fn_cxx_try_link LINENO
2765 # -------------------------
2766 # Try to link conftest.$ac_ext, and return whether this succeeded.
2767 ac_fn_cxx_try_link ()
2768 {
2769   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2770   rm -f conftest.$ac_objext conftest$ac_exeext
2771   if { { ac_try="$ac_link"
2772 case "(($ac_try" in
2773   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2774   *) ac_try_echo=$ac_try;;
2775 esac
2776 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2777 $as_echo "$ac_try_echo"; } >&5
2778   (eval "$ac_link") 2>conftest.err
2779   ac_status=$?
2780   if test -s conftest.err; then
2781     grep -v '^ *+' conftest.err >conftest.er1
2782     cat conftest.er1 >&5
2783     mv -f conftest.er1 conftest.err
2784   fi
2785   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2786   test $ac_status = 0; } && {
2787          test -z "$ac_cxx_werror_flag" ||
2788          test ! -s conftest.err
2789        } && test -s conftest$ac_exeext && {
2790          test "$cross_compiling" = yes ||
2791          test -x conftest$ac_exeext
2792        }; then :
2793   ac_retval=0
2794 else
2795   $as_echo "$as_me: failed program was:" >&5
2796 sed 's/^/| /' conftest.$ac_ext >&5
2797 
2798         ac_retval=1
2799 fi
2800   # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2801   # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2802   # interfere with the next link command; also delete a directory that is
2803   # left behind by Apple's compiler.  We do this before executing the actions.
2804   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2805   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2806   as_fn_set_status $ac_retval
2807 
2808 } # ac_fn_cxx_try_link
2809 
2810 # ac_fn_cxx_check_func LINENO FUNC VAR
2811 # ------------------------------------
2812 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2813 ac_fn_cxx_check_func ()
2814 {
2815   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2816   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2817 $as_echo_n "checking for $2... " >&6; }
2818 if eval \${$3+:} false; then :
2819   $as_echo_n "(cached) " >&6
2820 else
2821   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2822 /* end confdefs.h.  */
2823 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2824    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
2825 #define $2 innocuous_$2
2826 
2827 /* System header to define __stub macros and hopefully few prototypes,
2828     which can conflict with char $2 (); below.
2829     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2830     <limits.h> exists even on freestanding compilers.  */
2831 
2832 #ifdef __STDC__
2833 # include <limits.h>
2834 #else
2835 # include <assert.h>
2836 #endif
2837 
2838 #undef $2
2839 
2840 /* Override any GCC internal prototype to avoid an error.
2841    Use char because int might match the return type of a GCC
2842    builtin and then its argument prototype would still apply.  */
2843 #ifdef __cplusplus
2844 extern "C"
2845 #endif
2846 char $2 ();
2847 /* The GNU C library defines this for functions which it implements
2848     to always fail with ENOSYS.  Some functions are actually named
2849     something starting with __ and the normal name is an alias.  */
2850 #if defined __stub_$2 || defined __stub___$2
2851 choke me
2852 #endif
2853 
2854 int
2855 main ()
2856 {
2857 return $2 ();
2858   ;
2859   return 0;
2860 }
2861 _ACEOF
2862 if ac_fn_cxx_try_link "$LINENO"; then :
2863   eval "$3=yes"
2864 else
2865   eval "$3=no"
2866 fi
2867 rm -f core conftest.err conftest.$ac_objext \
2868     conftest$ac_exeext conftest.$ac_ext
2869 fi
2870 eval ac_res=\$$3
2871                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2872 $as_echo "$ac_res" >&6; }
2873   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2874 
2875 } # ac_fn_cxx_check_func
2876 
2877 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2878 # -------------------------------------------------------
2879 # Tests whether HEADER exists and can be compiled using the include files in
2880 # INCLUDES, setting the cache variable VAR accordingly.
2881 ac_fn_c_check_header_compile ()
2882 {
2883   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2884   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2885 $as_echo_n "checking for $2... " >&6; }
2886 if eval \${$3+:} false; then :
2887   $as_echo_n "(cached) " >&6
2888 else
2889   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2890 /* end confdefs.h.  */
2891 $4
2892 #include <$2>
2893 _ACEOF
2894 if ac_fn_c_try_compile "$LINENO"; then :
2895   eval "$3=yes"
2896 else
2897   eval "$3=no"
2898 fi
2899 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2900 fi
2901 eval ac_res=\$$3
2902                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2903 $as_echo "$ac_res" >&6; }
2904   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2905 
2906 } # ac_fn_c_check_header_compile
2907 cat >config.log <<_ACEOF
2908 This file contains any messages produced by compilers while
2909 running configure, to aid debugging if configure makes a mistake.
2910 
2911 It was created by OpenJDK $as_me jdk9, which was
2912 generated by GNU Autoconf 2.69.  Invocation command line was
2913 
2914   $ $0 $@
2915 
2916 _ACEOF
2917 exec 5>>config.log
2918 {
2919 cat <<_ASUNAME
2920 ## --------- ##
2921 ## Platform. ##
2922 ## --------- ##
2923 
2924 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2925 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2926 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2927 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2928 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2929 
2930 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2931 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2932 
2933 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2934 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2935 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2936 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2937 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2938 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2939 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2940 
2941 _ASUNAME
2942 
2943 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2944 for as_dir in $PATH
2945 do
2946   IFS=$as_save_IFS
2947   test -z "$as_dir" && as_dir=.
2948     $as_echo "PATH: $as_dir"
2949   done
2950 IFS=$as_save_IFS
2951 
2952 } >&5
2953 
2954 cat >&5 <<_ACEOF
2955 
2956 
2957 ## ----------- ##
2958 ## Core tests. ##
2959 ## ----------- ##
2960 
2961 _ACEOF
2962 
2963 
2964 # Keep a trace of the command line.
2965 # Strip out --no-create and --no-recursion so they do not pile up.
2966 # Strip out --silent because we don't want to record it for future runs.
2967 # Also quote any args containing shell meta-characters.
2968 # Make two passes to allow for proper duplicate-argument suppression.
2969 ac_configure_args=
2970 ac_configure_args0=
2971 ac_configure_args1=
2972 ac_must_keep_next=false
2973 for ac_pass in 1 2
2974 do
2975   for ac_arg
2976   do
2977     case $ac_arg in
2978     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2979     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2980     | -silent | --silent | --silen | --sile | --sil)
2981       continue ;;
2982     *\'*)
2983       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2984     esac
2985     case $ac_pass in
2986     1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2987     2)
2988       as_fn_append ac_configure_args1 " '$ac_arg'"
2989       if test $ac_must_keep_next = true; then
2990         ac_must_keep_next=false # Got value, back to normal.
2991       else
2992         case $ac_arg in
2993           *=* | --config-cache | -C | -disable-* | --disable-* \
2994           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2995           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2996           | -with-* | --with-* | -without-* | --without-* | --x)
2997             case "$ac_configure_args0 " in
2998               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2999             esac
3000             ;;
3001           -* ) ac_must_keep_next=true ;;
3002         esac
3003       fi
3004       as_fn_append ac_configure_args " '$ac_arg'"
3005       ;;
3006     esac
3007   done
3008 done
3009 { ac_configure_args0=; unset ac_configure_args0;}
3010 { ac_configure_args1=; unset ac_configure_args1;}
3011 
3012 # When interrupted or exit'd, cleanup temporary files, and complete
3013 # config.log.  We remove comments because anyway the quotes in there
3014 # would cause problems or look ugly.
3015 # WARNING: Use '\'' to represent an apostrophe within the trap.
3016 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3017 trap 'exit_status=$?
3018   # Save into config.log some information that might help in debugging.
3019   {
3020     echo
3021 
3022     $as_echo "## ---------------- ##
3023 ## Cache variables. ##
3024 ## ---------------- ##"
3025     echo
3026     # The following way of writing the cache mishandles newlines in values,
3027 (
3028   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3029     eval ac_val=\$$ac_var
3030     case $ac_val in #(
3031     *${as_nl}*)
3032       case $ac_var in #(
3033       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3034 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3035       esac
3036       case $ac_var in #(
3037       _ | IFS | as_nl) ;; #(
3038       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3039       *) { eval $ac_var=; unset $ac_var;} ;;
3040       esac ;;
3041     esac
3042   done
3043   (set) 2>&1 |
3044     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3045     *${as_nl}ac_space=\ *)
3046       sed -n \
3047         "s/'\''/'\''\\\\'\'''\''/g;
3048           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3049       ;; #(
3050     *)
3051       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3052       ;;
3053     esac |
3054     sort
3055 )
3056     echo
3057 
3058     $as_echo "## ----------------- ##
3059 ## Output variables. ##
3060 ## ----------------- ##"
3061     echo
3062     for ac_var in $ac_subst_vars
3063     do
3064       eval ac_val=\$$ac_var
3065       case $ac_val in
3066       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3067       esac
3068       $as_echo "$ac_var='\''$ac_val'\''"
3069     done | sort
3070     echo
3071 
3072     if test -n "$ac_subst_files"; then
3073       $as_echo "## ------------------- ##
3074 ## File substitutions. ##
3075 ## ------------------- ##"
3076       echo
3077       for ac_var in $ac_subst_files
3078       do
3079         eval ac_val=\$$ac_var
3080         case $ac_val in
3081         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3082         esac
3083         $as_echo "$ac_var='\''$ac_val'\''"
3084       done | sort
3085       echo
3086     fi
3087 
3088     if test -s confdefs.h; then
3089       $as_echo "## ----------- ##
3090 ## confdefs.h. ##
3091 ## ----------- ##"
3092       echo
3093       cat confdefs.h
3094       echo
3095     fi
3096     test "$ac_signal" != 0 &&
3097       $as_echo "$as_me: caught signal $ac_signal"
3098     $as_echo "$as_me: exit $exit_status"
3099   } >&5
3100   rm -f core *.core core.conftest.* &&
3101     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3102     exit $exit_status
3103 ' 0
3104 for ac_signal in 1 2 13 15; do
3105   trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3106 done
3107 ac_signal=0
3108 
3109 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3110 rm -f -r conftest* confdefs.h
3111 
3112 $as_echo "/* confdefs.h */" > confdefs.h
3113 
3114 # Predefined preprocessor variables.
3115 
3116 cat >>confdefs.h <<_ACEOF
3117 #define PACKAGE_NAME "$PACKAGE_NAME"
3118 _ACEOF
3119 
3120 cat >>confdefs.h <<_ACEOF
3121 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3122 _ACEOF
3123 
3124 cat >>confdefs.h <<_ACEOF
3125 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3126 _ACEOF
3127 
3128 cat >>confdefs.h <<_ACEOF
3129 #define PACKAGE_STRING "$PACKAGE_STRING"
3130 _ACEOF
3131 
3132 cat >>confdefs.h <<_ACEOF
3133 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3134 _ACEOF
3135 
3136 cat >>confdefs.h <<_ACEOF
3137 #define PACKAGE_URL "$PACKAGE_URL"
3138 _ACEOF
3139 
3140 
3141 # Let the site file select an alternate cache file if it wants to.
3142 # Prefer an explicitly selected file to automatically selected ones.
3143 ac_site_file1=NONE
3144 ac_site_file2=NONE
3145 if test -n "$CONFIG_SITE"; then
3146   # We do not want a PATH search for config.site.
3147   case $CONFIG_SITE in #((
3148     -*)  ac_site_file1=./$CONFIG_SITE;;
3149     */*) ac_site_file1=$CONFIG_SITE;;
3150     *)   ac_site_file1=./$CONFIG_SITE;;
3151   esac
3152 elif test "x$prefix" != xNONE; then
3153   ac_site_file1=$prefix/share/config.site
3154   ac_site_file2=$prefix/etc/config.site
3155 else
3156   ac_site_file1=$ac_default_prefix/share/config.site
3157   ac_site_file2=$ac_default_prefix/etc/config.site
3158 fi
3159 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3160 do
3161   test "x$ac_site_file" = xNONE && continue
3162   if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3163     { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3164 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3165     sed 's/^/| /' "$ac_site_file" >&5
3166     . "$ac_site_file" \
3167       || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3168 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3169 as_fn_error $? "failed to load site script $ac_site_file
3170 See \`config.log' for more details" "$LINENO" 5; }
3171   fi
3172 done
3173 
3174 if test -r "$cache_file"; then
3175   # Some versions of bash will fail to source /dev/null (special files
3176   # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
3177   if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3178     { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3179 $as_echo "$as_me: loading cache $cache_file" >&6;}
3180     case $cache_file in
3181       [\\/]* | ?:[\\/]* ) . "$cache_file";;
3182       *)                      . "./$cache_file";;
3183     esac
3184   fi
3185 else
3186   { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3187 $as_echo "$as_me: creating cache $cache_file" >&6;}
3188   >$cache_file
3189 fi
3190 
3191 # Check that the precious variables saved in the cache have kept the same
3192 # value.
3193 ac_cache_corrupted=false
3194 for ac_var in $ac_precious_vars; do
3195   eval ac_old_set=\$ac_cv_env_${ac_var}_set
3196   eval ac_new_set=\$ac_env_${ac_var}_set
3197   eval ac_old_val=\$ac_cv_env_${ac_var}_value
3198   eval ac_new_val=\$ac_env_${ac_var}_value
3199   case $ac_old_set,$ac_new_set in
3200     set,)
3201       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3202 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3203       ac_cache_corrupted=: ;;
3204     ,set)
3205       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3206 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3207       ac_cache_corrupted=: ;;
3208     ,);;
3209     *)
3210       if test "x$ac_old_val" != "x$ac_new_val"; then
3211         # differences in whitespace do not lead to failure.
3212         ac_old_val_w=`echo x $ac_old_val`
3213         ac_new_val_w=`echo x $ac_new_val`
3214         if test "$ac_old_val_w" != "$ac_new_val_w"; then
3215           { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3216 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3217           ac_cache_corrupted=:
3218         else
3219           { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3220 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3221           eval $ac_var=\$ac_old_val
3222         fi
3223         { $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
3224 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
3225         { $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
3226 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
3227       fi;;
3228   esac
3229   # Pass precious variables to config.status.
3230   if test "$ac_new_set" = set; then
3231     case $ac_new_val in
3232     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3233     *) ac_arg=$ac_var=$ac_new_val ;;
3234     esac
3235     case " $ac_configure_args " in
3236       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
3237       *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3238     esac
3239   fi
3240 done
3241 if $ac_cache_corrupted; then
3242   { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3243 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3244   { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3245 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3246   as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3247 fi
3248 ## -------------------- ##
3249 ## Main body of script. ##
3250 ## -------------------- ##
3251 
3252 ac_ext=c
3253 ac_cpp='$CPP $CPPFLAGS'
3254 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3255 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3256 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3257 
3258 
3259 
3260 ac_aux_dir=
3261 for ac_dir in $TOPDIR/common/autoconf/build-aux "$srcdir"/$TOPDIR/common/autoconf/build-aux; do
3262   if test -f "$ac_dir/install-sh"; then
3263     ac_aux_dir=$ac_dir
3264     ac_install_sh="$ac_aux_dir/install-sh -c"
3265     break
3266   elif test -f "$ac_dir/install.sh"; then
3267     ac_aux_dir=$ac_dir
3268     ac_install_sh="$ac_aux_dir/install.sh -c"
3269     break
3270   elif test -f "$ac_dir/shtool"; then
3271     ac_aux_dir=$ac_dir
3272     ac_install_sh="$ac_aux_dir/shtool install -c"
3273     break
3274   fi
3275 done
3276 if test -z "$ac_aux_dir"; then
3277   as_fn_error $? "cannot find install-sh, install.sh, or shtool in $TOPDIR/common/autoconf/build-aux \"$srcdir\"/$TOPDIR/common/autoconf/build-aux" "$LINENO" 5
3278 fi
3279 
3280 # These three variables are undocumented and unsupported,
3281 # and are intended to be withdrawn in a future Autoconf release.
3282 # They can cause serious problems if a builder's source tree is in a directory
3283 # whose full name contains unusual characters.
3284 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
3285 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
3286 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
3287 
3288 
3289 # pkg.m4 - Macros to locate and utilise pkg-config.            -*- Autoconf -*-
3290 
3291 #
3292 # Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
3293 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3294 #
3295 # This code is free software; you can redistribute it and/or modify it
3296 # under the terms of the GNU General Public License version 2 only, as
3297 # published by the Free Software Foundation.  Oracle designates this
3298 # particular file as subject to the "Classpath" exception as provided
3299 # by Oracle in the LICENSE file that accompanied this code.
3300 #
3301 # This code is distributed in the hope that it will be useful, but WITHOUT
3302 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3303 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3304 # version 2 for more details (a copy is included in the LICENSE file that
3305 # accompanied this code).
3306 #
3307 # You should have received a copy of the GNU General Public License version
3308 # 2 along with this work; if not, write to the Free Software Foundation,
3309 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3310 #
3311 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3312 # or visit www.oracle.com if you need additional information or have any
3313 # questions.
3314 #
3315 
3316 #
3317 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>.
3318 #
3319 # This program is free software; you can redistribute it and/or modify
3320 # it under the terms of the GNU General Public License as published by
3321 # the Free Software Foundation; either version 2 of the License, or
3322 # (at your option) any later version.
3323 #
3324 # This program is distributed in the hope that it will be useful, but
3325 # WITHOUT ANY WARRANTY; without even the implied warranty of
3326 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
3327 # General Public License for more details.
3328 #
3329 # You should have received a copy of the GNU General Public License
3330 # along with this program; if not, write to the Free Software
3331 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
3332 #
3333 # As a special exception to the GNU General Public License, if you
3334 # distribute this file as part of a program that contains a
3335 # configuration script generated by Autoconf, you may include it under
3336 # the same distribution terms that you use for the rest of that program.
3337 
3338 # PKG_PROG_PKG_CONFIG([MIN-VERSION])
3339 # ----------------------------------
3340 # PKG_PROG_PKG_CONFIG
3341 
3342 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
3343 #
3344 # Check to see whether a particular set of modules exists.  Similar
3345 # to PKG_CHECK_MODULES(), but does not set variables or print errors.
3346 #
3347 #
3348 # Similar to PKG_CHECK_MODULES, make sure that the first instance of
3349 # this or PKG_CHECK_MODULES is called, or make sure to call
3350 # PKG_CHECK_EXISTS manually
3351 # --------------------------------------------------------------
3352 
3353 
3354 
3355 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
3356 # ---------------------------------------------
3357 # _PKG_CONFIG
3358 
3359 # _PKG_SHORT_ERRORS_SUPPORTED
3360 # -----------------------------
3361 # _PKG_SHORT_ERRORS_SUPPORTED
3362 
3363 
3364 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
3365 # [ACTION-IF-NOT-FOUND])
3366 #
3367 #
3368 # Note that if there is a possibility the first call to
3369 # PKG_CHECK_MODULES might not happen, you should be sure to include an
3370 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
3371 #
3372 #
3373 # --------------------------------------------------------------
3374 # PKG_CHECK_MODULES
3375 
3376 
3377 # Include these first...
3378 #
3379 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3380 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3381 #
3382 # This code is free software; you can redistribute it and/or modify it
3383 # under the terms of the GNU General Public License version 2 only, as
3384 # published by the Free Software Foundation.  Oracle designates this
3385 # particular file as subject to the "Classpath" exception as provided
3386 # by Oracle in the LICENSE file that accompanied this code.
3387 #
3388 # This code is distributed in the hope that it will be useful, but WITHOUT
3389 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3390 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3391 # version 2 for more details (a copy is included in the LICENSE file that
3392 # accompanied this code).
3393 #
3394 # You should have received a copy of the GNU General Public License version
3395 # 2 along with this work; if not, write to the Free Software Foundation,
3396 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3397 #
3398 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3399 # or visit www.oracle.com if you need additional information or have any
3400 # questions.
3401 #
3402 
3403 # Test if $1 is a valid argument to $3 (often is $JAVA passed as $3)
3404 # If so, then append $1 to $2 \
3405 # Also set JVM_ARG_OK to true/false depending on outcome.
3406 
3407 
3408 # Appends a string to a path variable, only adding the : when needed.
3409 
3410 
3411 # Prepends a string to a path variable, only adding the : when needed.
3412 
3413 
3414 # This will make sure the given variable points to a full and proper
3415 # path. This means:
3416 # 1) There will be no spaces in the path. On unix platforms,
3417 #    spaces in the path will result in an error. On Windows,
3418 #    the path will be rewritten using short-style to be space-free.
3419 # 2) The path will be absolute, and it will be in unix-style (on
3420 #     cygwin).
3421 # $1: The name of the variable to fix
3422 
3423 
3424 # This will make sure the given variable points to a executable
3425 # with a full and proper path. This means:
3426 # 1) There will be no spaces in the path. On unix platforms,
3427 #    spaces in the path will result in an error. On Windows,
3428 #    the path will be rewritten using short-style to be space-free.
3429 # 2) The path will be absolute, and it will be in unix-style (on
3430 #     cygwin).
3431 # Any arguments given to the executable is preserved.
3432 # If the input variable does not have a directory specification, then
3433 # it need to be in the PATH.
3434 # $1: The name of the variable to fix
3435 
3436 
3437 
3438 
3439 # Register a --with argument but mark it as deprecated
3440 # $1: The name of the with argument to deprecate, not including --with-
3441 
3442 
3443 # Register a --enable argument but mark it as deprecated
3444 # $1: The name of the with argument to deprecate, not including --enable-
3445 # $2: The name of the argument to deprecate, in shell variable style (i.e. with _ instead of -)
3446 
3447 
3448 
3449 
3450 # Test that variable $1 denoting a program is not empty. If empty, exit with an error.
3451 # $1: variable to check
3452 
3453 
3454 # Check that there are no unprocessed overridden variables left.
3455 # If so, they are an incorrect argument and we will exit with an error.
3456 
3457 
3458 # Setup a tool for the given variable. If correctly specified by the user,
3459 # use that value, otherwise search for the tool using the supplied code snippet.
3460 # $1: variable to set
3461 # $2: code snippet to call to look for the tool
3462 
3463 
3464 # Call BASIC_SETUP_TOOL with AC_PATH_PROGS to locate the tool
3465 # $1: variable to set
3466 # $2: executable name (or list of names) to look for
3467 
3468 
3469 # Call BASIC_SETUP_TOOL with AC_CHECK_TOOLS to locate the tool
3470 # $1: variable to set
3471 # $2: executable name (or list of names) to look for
3472 
3473 
3474 # Like BASIC_PATH_PROGS but fails if no tool was found.
3475 # $1: variable to set
3476 # $2: executable name (or list of names) to look for
3477 
3478 
3479 # Like BASIC_SETUP_TOOL but fails if no tool was found.
3480 # $1: variable to set
3481 # $2: autoconf macro to call to look for the special tool
3482 
3483 
3484 # Setup the most fundamental tools that relies on not much else to set up,
3485 # but is used by much of the early bootstrap code.
3486 
3487 
3488 # Setup basic configuration paths, and platform-specific stuff related to PATHs.
3489 
3490 
3491 
3492 
3493 
3494 
3495 
3496 
3497 
3498 #%%% Simple tools %%%
3499 
3500 # Check if we have found a usable version of make
3501 # $1: the path to a potential make binary (or empty)
3502 # $2: the description on how we found this
3503 
3504 
3505 
3506 
3507 # Goes looking for a usable version of GNU make.
3508 
3509 
3510 
3511 
3512 
3513 
3514 # Check if build directory is on local disk. If not possible to determine,
3515 # we prefer to claim it's local.
3516 # Argument 1: directory to test
3517 # Argument 2: what to do if it is on local disk
3518 # Argument 3: what to do otherwise (remote disk or failure)
3519 
3520 
3521 # Check that source files have basic read permissions set. This might
3522 # not be the case in cygwin in certain conditions.
3523 
3524 
3525 
3526 
3527 #
3528 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3529 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3530 #
3531 # This code is free software; you can redistribute it and/or modify it
3532 # under the terms of the GNU General Public License version 2 only, as
3533 # published by the Free Software Foundation.  Oracle designates this
3534 # particular file as subject to the "Classpath" exception as provided
3535 # by Oracle in the LICENSE file that accompanied this code.
3536 #
3537 # This code is distributed in the hope that it will be useful, but WITHOUT
3538 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3539 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3540 # version 2 for more details (a copy is included in the LICENSE file that
3541 # accompanied this code).
3542 #
3543 # You should have received a copy of the GNU General Public License version
3544 # 2 along with this work; if not, write to the Free Software Foundation,
3545 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3546 #
3547 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3548 # or visit www.oracle.com if you need additional information or have any
3549 # questions.
3550 #
3551 
3552 
3553 
3554 
3555 
3556 # Helper function which possibly converts a path using DOS-style short mode.
3557 # If so, the updated path is stored in $new_path.
3558 # $1: The path to check
3559 
3560 
3561 # Helper function which possibly converts a path using DOS-style short mode.
3562 # If so, the updated path is stored in $new_path.
3563 # $1: The path to check
3564 
3565 
3566 # FIXME: The BASIC_FIXUP_*_CYGWIN/MSYS is most likely too convoluted
3567 # and could probably be heavily simplified. However, all changes in this
3568 # area tend to need lot of testing in different scenarios, and in lack of
3569 # proper unit testing, cleaning this up has not been deemed worth the effort
3570 # at the moment.
3571 
3572 
3573 
3574 
3575 
3576 
3577 
3578 
3579 
3580 # Setup basic configuration paths, and platform-specific stuff related to PATHs.
3581 
3582 
3583 
3584 
3585 #
3586 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3587 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3588 #
3589 # This code is free software; you can redistribute it and/or modify it
3590 # under the terms of the GNU General Public License version 2 only, as
3591 # published by the Free Software Foundation.  Oracle designates this
3592 # particular file as subject to the "Classpath" exception as provided
3593 # by Oracle in the LICENSE file that accompanied this code.
3594 #
3595 # This code is distributed in the hope that it will be useful, but WITHOUT
3596 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3597 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3598 # version 2 for more details (a copy is included in the LICENSE file that
3599 # accompanied this code).
3600 #
3601 # You should have received a copy of the GNU General Public License version
3602 # 2 along with this work; if not, write to the Free Software Foundation,
3603 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3604 #
3605 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3606 # or visit www.oracle.com if you need additional information or have any
3607 # questions.
3608 #
3609 
3610 
3611 
3612 
3613 
3614 
3615 
3616 
3617 
3618 
3619 
3620 # ... then the rest
3621 #
3622 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3623 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3624 #
3625 # This code is free software; you can redistribute it and/or modify it
3626 # under the terms of the GNU General Public License version 2 only, as
3627 # published by the Free Software Foundation.  Oracle designates this
3628 # particular file as subject to the "Classpath" exception as provided
3629 # by Oracle in the LICENSE file that accompanied this code.
3630 #
3631 # This code is distributed in the hope that it will be useful, but WITHOUT
3632 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3633 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3634 # version 2 for more details (a copy is included in the LICENSE file that
3635 # accompanied this code).
3636 #
3637 # You should have received a copy of the GNU General Public License version
3638 # 2 along with this work; if not, write to the Free Software Foundation,
3639 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3640 #
3641 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3642 # or visit www.oracle.com if you need additional information or have any
3643 # questions.
3644 #
3645 
3646 ########################################################################
3647 # This file handles detection of the Boot JDK. The Boot JDK detection
3648 # process has been developed as a response to solve a complex real-world
3649 # problem. Initially, it was simple, but it has grown as platform after
3650 # platform, idiosyncracy after idiosyncracy has been supported.
3651 #
3652 # The basic idea is this:
3653 # 1) You need an acceptable *) JDK to use as a Boot JDK
3654 # 2) There are several ways to locate a JDK, that are mostly platform
3655 #    dependent **)
3656 # 3) You can have multiple JDKs installed
3657 # 4) If possible, configure should try to dig out an acceptable JDK
3658 #    automatically, without having to resort to command-line options
3659 #
3660 # *)  acceptable means e.g. JDK7 for building JDK8, a complete JDK (with
3661 #     javac) and not a JRE, etc.
3662 #
3663 # **) On Windows we typically use a well-known path.
3664 #     On MacOSX we typically use the tool java_home.
3665 #     On Linux we typically find javac in the $PATH, and then follow a
3666 #     chain of symlinks that often ends up in a real JDK.
3667 #
3668 # This leads to the code where we check in different ways to locate a
3669 # JDK, and if one is found, check if it is acceptable. If not, we print
3670 # our reasons for rejecting it (useful when debugging non-working
3671 # configure situations) and continue checking the next one.
3672 ########################################################################
3673 
3674 # Execute the check given as argument, and verify the result
3675 # If the Boot JDK was previously found, do nothing
3676 # $1 A command line (typically autoconf macro) to execute
3677 
3678 
3679 # Test: Is bootjdk explicitely set by command line arguments?
3680 
3681 
3682 # Test: Is bootjdk available from builddeps?
3683 
3684 
3685 # Test: Is $JAVA_HOME set?
3686 
3687 
3688 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK?
3689 
3690 
3691 # Test: Is there a /usr/libexec/java_home? (Typically on MacOSX)
3692 # $1: Argument to the java_home binary (optional)
3693 
3694 
3695 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home?
3696 
3697 
3698 # Look for a jdk in the given path. If there are multiple, try to select the newest.
3699 # If found, set BOOT_JDK and BOOT_JDK_FOUND.
3700 # $1 = Path to directory containing jdk installations.
3701 # $2 = String to append to the found JDK directory to get the proper JDK home
3702 
3703 
3704 # Call BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY, but use the given
3705 # environmental variable as base for where to look.
3706 # $1 Name of an environmal variable, assumed to point to the Program Files directory.
3707 
3708 
3709 # Test: Is there a JDK installed in default, well-known locations?
3710 
3711 
3712 # Check that a command-line tool in the Boot JDK is correct
3713 # $1 = name of variable to assign
3714 # $2 = name of binary
3715 
3716 
3717 ###############################################################################
3718 #
3719 # We need a Boot JDK to bootstrap the build.
3720 #
3721 
3722 
3723 
3724 
3725 
3726 #
3727 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
3728 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3729 #
3730 # This code is free software; you can redistribute it and/or modify it
3731 # under the terms of the GNU General Public License version 2 only, as
3732 # published by the Free Software Foundation.  Oracle designates this
3733 # particular file as subject to the "Classpath" exception as provided
3734 # by Oracle in the LICENSE file that accompanied this code.
3735 #
3736 # This code is distributed in the hope that it will be useful, but WITHOUT
3737 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3738 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3739 # version 2 for more details (a copy is included in the LICENSE file that
3740 # accompanied this code).
3741 #
3742 # You should have received a copy of the GNU General Public License version
3743 # 2 along with this work; if not, write to the Free Software Foundation,
3744 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3745 #
3746 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3747 # or visit www.oracle.com if you need additional information or have any
3748 # questions.
3749 #
3750 
3751 
3752 
3753 
3754 
3755 
3756 
3757 
3758 
3759 
3760 
3761 
3762 
3763 
3764 
3765 
3766 
3767 
3768 
3769 
3770 #
3771 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3772 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3773 #
3774 # This code is free software; you can redistribute it and/or modify it
3775 # under the terms of the GNU General Public License version 2 only, as
3776 # published by the Free Software Foundation.  Oracle designates this
3777 # particular file as subject to the "Classpath" exception as provided
3778 # by Oracle in the LICENSE file that accompanied this code.
3779 #
3780 # This code is distributed in the hope that it will be useful, but WITHOUT
3781 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3782 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3783 # version 2 for more details (a copy is included in the LICENSE file that
3784 # accompanied this code).
3785 #
3786 # You should have received a copy of the GNU General Public License version
3787 # 2 along with this work; if not, write to the Free Software Foundation,
3788 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3789 #
3790 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3791 # or visit www.oracle.com if you need additional information or have any
3792 # questions.
3793 #
3794 
3795 
3796 
3797 
3798 
3799 # Documentation on common flags used for solstudio in HIGHEST.
3800 #
3801 # WARNING: Use of OPTIMIZATION_LEVEL=HIGHEST in your Makefile needs to be
3802 #          done with care, there are some assumptions below that need to
3803 #          be understood about the use of pointers, and IEEE behavior.
3804 #
3805 # -fns: Use non-standard floating point mode (not IEEE 754)
3806 # -fsimple: Do some simplification of floating point arithmetic (not IEEE 754)
3807 # -fsingle: Use single precision floating point with 'float'
3808 # -xalias_level=basic: Assume memory references via basic pointer types do not alias
3809 #   (Source with excessing pointer casting and data access with mixed
3810 #    pointer types are not recommended)
3811 # -xbuiltin=%all: Use intrinsic or inline versions for math/std functions
3812 #   (If you expect perfect errno behavior, do not use this)
3813 # -xdepend: Loop data dependency optimizations (need -xO3 or higher)
3814 # -xrestrict: Pointer parameters to functions do not overlap
3815 #   (Similar to -xalias_level=basic usage, but less obvious sometimes.
3816 #    If you pass in multiple pointers to the same data, do not use this)
3817 # -xlibmil: Inline some library routines
3818 #   (If you expect perfect errno behavior, do not use this)
3819 # -xlibmopt: Use optimized math routines (CURRENTLY DISABLED)
3820 #   (If you expect perfect errno behavior, do not use this)
3821 #  Can cause undefined external on Solaris 8 X86 on __sincos, removing for now
3822 
3823     # FIXME: this will never happen since sparc != sparcv9, ie 32 bit, which we don't build anymore.
3824     # Bug?
3825     #if test "x$OPENJDK_TARGET_CPU" = xsparc; then
3826     #  CFLAGS_JDK="${CFLAGS_JDK} -xmemalign=4s"
3827     #  CXXFLAGS_JDK="${CXXFLAGS_JDK} -xmemalign=4s"
3828     #fi
3829 
3830 
3831 
3832 
3833 
3834 # FLAGS_COMPILER_CHECK_ARGUMENTS([ARGUMENT], [RUN-IF-TRUE],
3835 #                                   [RUN-IF-FALSE])
3836 # ------------------------------------------------------------
3837 # Check that the c and c++ compilers support an argument
3838 
3839 
3840 # FLAGS_LINKER_CHECK_ARGUMENTS([ARGUMENT], [RUN-IF-TRUE],
3841 #                                    [RUN-IF-FALSE])
3842 # ------------------------------------------------------------
3843 # Check that the linker support an argument
3844 
3845 
3846 
3847 
3848 #
3849 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3850 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3851 #
3852 # This code is free software; you can redistribute it and/or modify it
3853 # under the terms of the GNU General Public License version 2 only, as
3854 # published by the Free Software Foundation.  Oracle designates this
3855 # particular file as subject to the "Classpath" exception as provided
3856 # by Oracle in the LICENSE file that accompanied this code.
3857 #
3858 # This code is distributed in the hope that it will be useful, but WITHOUT
3859 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3860 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3861 # version 2 for more details (a copy is included in the LICENSE file that
3862 # accompanied this code).
3863 #
3864 # You should have received a copy of the GNU General Public License version
3865 # 2 along with this work; if not, write to the Free Software Foundation,
3866 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3867 #
3868 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3869 # or visit www.oracle.com if you need additional information or have any
3870 # questions.
3871 #
3872 
3873 
3874 
3875 
3876 
3877 cygwin_help() {
3878   case $1 in
3879     unzip)
3880       PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P unzip )"
3881       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
3882       ;;
3883     zip)
3884       PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P zip )"
3885       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
3886       ;;
3887     make)
3888       PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P make )"
3889       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
3890       ;;
3891     freetype)
3892       HELP_MSG="
3893 The freetype library can now be build during the configure process.
3894 Download the freetype sources and unpack them into an arbitrary directory:
3895 
3896 wget http://download.savannah.gnu.org/releases/freetype/freetype-2.5.3.tar.gz
3897 tar -xzf freetype-2.5.3.tar.gz
3898 
3899 Then run configure with '--with-freetype-src=<freetype_src>'. This will
3900 automatically build the freetype library into '<freetype_src>/lib64' for 64-bit
3901 builds or into '<freetype_src>/lib32' for 32-bit builds.
3902 Afterwards you can always use '--with-freetype-include=<freetype_src>/include'
3903 and '--with-freetype-lib=<freetype_src>/lib32|64' for other builds."
3904       ;;
3905   esac
3906 }
3907 
3908 msys_help() {
3909   PKGHANDLER_COMMAND=""
3910 }
3911 
3912 apt_help() {
3913   case $1 in
3914     devkit)
3915       PKGHANDLER_COMMAND="sudo apt-get install build-essential" ;;
3916     openjdk)
3917       PKGHANDLER_COMMAND="sudo apt-get install openjdk-7-jdk" ;;
3918     alsa)
3919       PKGHANDLER_COMMAND="sudo apt-get install libasound2-dev" ;;
3920     cups)
3921       PKGHANDLER_COMMAND="sudo apt-get install libcups2-dev" ;;
3922     freetype)
3923       PKGHANDLER_COMMAND="sudo apt-get install libfreetype6-dev" ;;
3924     pulse)
3925       PKGHANDLER_COMMAND="sudo apt-get install libpulse-dev" ;;
3926     x11)
3927       PKGHANDLER_COMMAND="sudo apt-get install libX11-dev libxext-dev libxrender-dev libxtst-dev libxt-dev" ;;
3928     ccache)
3929       PKGHANDLER_COMMAND="sudo apt-get install ccache" ;;
3930   esac
3931 }
3932 
3933 yum_help() {
3934   case $1 in
3935     devkit)
3936       PKGHANDLER_COMMAND="sudo yum groupinstall \"Development Tools\"" ;;
3937     openjdk)
3938       PKGHANDLER_COMMAND="sudo yum install java-1.7.0-openjdk" ;;
3939     alsa)
3940       PKGHANDLER_COMMAND="sudo yum install alsa-lib-devel" ;;
3941     cups)
3942       PKGHANDLER_COMMAND="sudo yum install cups-devel" ;;
3943     freetype)
3944       PKGHANDLER_COMMAND="sudo yum install freetype-devel" ;;
3945     pulse)
3946       PKGHANDLER_COMMAND="sudo yum install pulseaudio-libs-devel" ;;
3947     x11)
3948       PKGHANDLER_COMMAND="sudo yum install libXtst-devel libXt-devel libXrender-devel libXi-devel" ;;
3949     ccache)
3950       PKGHANDLER_COMMAND="sudo yum install ccache" ;;
3951   esac
3952 }
3953 
3954 port_help() {
3955   PKGHANDLER_COMMAND=""
3956 }
3957 
3958 pkgutil_help() {
3959   PKGHANDLER_COMMAND=""
3960 }
3961 
3962 pkgadd_help() {
3963   PKGHANDLER_COMMAND=""
3964 }
3965 
3966 # This function will check if we're called from the "configure" wrapper while
3967 # printing --help. If so, we will print out additional information that can
3968 # only be extracted within the autoconf script, and then exit. This must be
3969 # called at the very beginning in configure.ac.
3970 
3971 
3972 
3973 
3974 
3975 
3976 #
3977 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
3978 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
3979 #
3980 # This code is free software; you can redistribute it and/or modify it
3981 # under the terms of the GNU General Public License version 2 only, as
3982 # published by the Free Software Foundation.  Oracle designates this
3983 # particular file as subject to the "Classpath" exception as provided
3984 # by Oracle in the LICENSE file that accompanied this code.
3985 #
3986 # This code is distributed in the hope that it will be useful, but WITHOUT
3987 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
3988 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
3989 # version 2 for more details (a copy is included in the LICENSE file that
3990 # accompanied this code).
3991 #
3992 # You should have received a copy of the GNU General Public License version
3993 # 2 along with this work; if not, write to the Free Software Foundation,
3994 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3995 #
3996 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3997 # or visit www.oracle.com if you need additional information or have any
3998 # questions.
3999 #
4000 
4001 
4002 
4003 
4004 
4005 
4006 
4007 
4008 
4009 
4010 ###############################################################################
4011 #
4012 # Should we build only OpenJDK even if closed sources are present?
4013 #
4014 
4015 
4016 
4017 
4018 ###############################################################################
4019 #
4020 # Setup version numbers
4021 #
4022 
4023 
4024 
4025 
4026 
4027 
4028 #
4029 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
4030 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4031 #
4032 # This code is free software; you can redistribute it and/or modify it
4033 # under the terms of the GNU General Public License version 2 only, as
4034 # published by the Free Software Foundation.  Oracle designates this
4035 # particular file as subject to the "Classpath" exception as provided
4036 # by Oracle in the LICENSE file that accompanied this code.
4037 #
4038 # This code is distributed in the hope that it will be useful, but WITHOUT
4039 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4040 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4041 # version 2 for more details (a copy is included in the LICENSE file that
4042 # accompanied this code).
4043 #
4044 # You should have received a copy of the GNU General Public License version
4045 # 2 along with this work; if not, write to the Free Software Foundation,
4046 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4047 #
4048 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4049 # or visit www.oracle.com if you need additional information or have any
4050 # questions.
4051 #
4052 
4053 
4054 
4055 
4056 
4057 
4058 
4059 
4060 
4061 
4062 
4063 
4064 
4065 
4066 
4067 
4068 
4069 
4070 
4071 
4072 
4073 #
4074 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
4075 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4076 #
4077 # This code is free software; you can redistribute it and/or modify it
4078 # under the terms of the GNU General Public License version 2 only, as
4079 # published by the Free Software Foundation.  Oracle designates this
4080 # particular file as subject to the "Classpath" exception as provided
4081 # by Oracle in the LICENSE file that accompanied this code.
4082 #
4083 # This code is distributed in the hope that it will be useful, but WITHOUT
4084 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4085 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4086 # version 2 for more details (a copy is included in the LICENSE file that
4087 # accompanied this code).
4088 #
4089 # You should have received a copy of the GNU General Public License version
4090 # 2 along with this work; if not, write to the Free Software Foundation,
4091 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4092 #
4093 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4094 # or visit www.oracle.com if you need additional information or have any
4095 # questions.
4096 #
4097 
4098 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD.
4099 # Converts autoconf style CPU name to OpenJDK style, into
4100 # VAR_CPU, VAR_CPU_ARCH, VAR_CPU_BITS and VAR_CPU_ENDIAN.
4101 
4102 
4103 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD.
4104 # Converts autoconf style OS name to OpenJDK style, into
4105 # VAR_OS, VAR_OS_TYPE and VAR_OS_ENV.
4106 
4107 
4108 # Expects $host_os $host_cpu $build_os and $build_cpu
4109 # and $with_target_bits to have been setup!
4110 #
4111 # Translate the standard triplet(quadruplet) definition
4112 # of the target/build system into OPENJDK_TARGET_OS, OPENJDK_TARGET_CPU,
4113 # OPENJDK_BUILD_OS, etc.
4114 
4115 
4116 # Check if a reduced build (32-bit on 64-bit platforms) is requested, and modify behaviour
4117 # accordingly. Must be done after setting up build and target system, but before
4118 # doing anything else with these values.
4119 
4120 
4121 # Setup the legacy variables, for controlling the old makefiles.
4122 #
4123 
4124 
4125 
4126 
4127 #%%% Build and target systems %%%
4128 
4129 
4130 
4131 
4132 # Support macro for PLATFORM_SETUP_OPENJDK_TARGET_BITS.
4133 # Add -mX to various FLAGS variables.
4134 
4135 
4136 
4137 
4138 
4139 
4140 #
4141 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
4142 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4143 #
4144 # This code is free software; you can redistribute it and/or modify it
4145 # under the terms of the GNU General Public License version 2 only, as
4146 # published by the Free Software Foundation.  Oracle designates this
4147 # particular file as subject to the "Classpath" exception as provided
4148 # by Oracle in the LICENSE file that accompanied this code.
4149 #
4150 # This code is distributed in the hope that it will be useful, but WITHOUT
4151 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4152 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4153 # version 2 for more details (a copy is included in the LICENSE file that
4154 # accompanied this code).
4155 #
4156 # You should have received a copy of the GNU General Public License version
4157 # 2 along with this work; if not, write to the Free Software Foundation,
4158 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4159 #
4160 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4161 # or visit www.oracle.com if you need additional information or have any
4162 # questions.
4163 #
4164 
4165 
4166 
4167 
4168 
4169 
4170 
4171 
4172 #
4173 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
4174 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4175 #
4176 # This code is free software; you can redistribute it and/or modify it
4177 # under the terms of the GNU General Public License version 2 only, as
4178 # published by the Free Software Foundation.  Oracle designates this
4179 # particular file as subject to the "Classpath" exception as provided
4180 # by Oracle in the LICENSE file that accompanied this code.
4181 #
4182 # This code is distributed in the hope that it will be useful, but WITHOUT
4183 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4184 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4185 # version 2 for more details (a copy is included in the LICENSE file that
4186 # accompanied this code).
4187 #
4188 # You should have received a copy of the GNU General Public License version
4189 # 2 along with this work; if not, write to the Free Software Foundation,
4190 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4191 #
4192 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4193 # or visit www.oracle.com if you need additional information or have any
4194 # questions.
4195 #
4196 
4197 ########################################################################
4198 # This file is responsible for detecting, verifying and setting up the
4199 # toolchain, i.e. the compiler, linker and related utilities. It will setup
4200 # proper paths to the binaries, but it will not setup any flags.
4201 #
4202 # The binaries used is determined by the toolchain type, which is the family of
4203 # compilers and related tools that are used.
4204 ########################################################################
4205 
4206 
4207 # All valid toolchains, regardless of platform (used by help.m4)
4208 VALID_TOOLCHAINS_all="gcc clang solstudio xlc microsoft"
4209 
4210 # These toolchains are valid on different platforms
4211 VALID_TOOLCHAINS_linux="gcc clang"
4212 VALID_TOOLCHAINS_solaris="solstudio"
4213 VALID_TOOLCHAINS_macosx="gcc clang"
4214 VALID_TOOLCHAINS_aix="xlc"
4215 VALID_TOOLCHAINS_windows="microsoft"
4216 
4217 # Toolchain descriptions
4218 TOOLCHAIN_DESCRIPTION_clang="clang/LLVM"
4219 TOOLCHAIN_DESCRIPTION_gcc="GNU Compiler Collection"
4220 TOOLCHAIN_DESCRIPTION_microsoft="Microsoft Visual Studio"
4221 TOOLCHAIN_DESCRIPTION_solstudio="Oracle Solaris Studio"
4222 TOOLCHAIN_DESCRIPTION_xlc="IBM XL C/C++"
4223 
4224 # Setup a number of variables describing how native output files are
4225 # named on this platform/toolchain.
4226 
4227 
4228 # Determine which toolchain type to use, and make sure it is valid for this
4229 # platform. Setup various information about the selected toolchain.
4230 
4231 
4232 # Before we start detecting the toolchain executables, we might need some
4233 # special setup, e.g. additional paths etc.
4234 
4235 
4236 # Restore path, etc
4237 
4238 
4239 # Check if a compiler is of the toolchain type we expect, and save the version
4240 # information from it. If the compiler does not match the expected type,
4241 # this function will abort using AC_MSG_ERROR. If it matches, the version will
4242 # be stored in CC_VERSION_NUMBER/CXX_VERSION_NUMBER (as a dotted number), and
4243 # the full version string in CC_VERSION_STRING/CXX_VERSION_STRING.
4244 #
4245 # $1 = compiler to test (CC or CXX)
4246 # $2 = human readable name of compiler (C or C++)
4247 
4248 
4249 # Try to locate the given C or C++ compiler in the path, or otherwise.
4250 #
4251 # $1 = compiler to test (CC or CXX)
4252 # $2 = human readable name of compiler (C or C++)
4253 # $3 = list of compiler names to search for
4254 
4255 
4256 # Detect the core components of the toolchain, i.e. the compilers (CC and CXX),
4257 # preprocessor (CPP and CXXCPP), the linker (LD), the assembler (AS) and the
4258 # archiver (AR). Verify that the compilers are correct according to the
4259 # toolchain type.
4260 
4261 
4262 # Setup additional tools that is considered a part of the toolchain, but not the
4263 # core part. Many of these are highly platform-specific and do not exist,
4264 # and/or are not needed on all platforms.
4265 
4266 
4267 # Setup the build tools (i.e, the compiler and linker used to build programs
4268 # that should be run on the build platform, not the target platform, as a build
4269 # helper). Since the non-cross-compile case uses the normal, target compilers
4270 # for this, we can only do this after these have been setup.
4271 
4272 
4273 # Setup legacy variables that are still needed as alternative ways to refer to
4274 # parts of the toolchain.
4275 
4276 
4277 # Do some additional checks on the detected tools.
4278 
4279 
4280 # Setup the JTReg Regression Test Harness.
4281 
4282 
4283 #
4284 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
4285 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4286 #
4287 # This code is free software; you can redistribute it and/or modify it
4288 # under the terms of the GNU General Public License version 2 only, as
4289 # published by the Free Software Foundation.  Oracle designates this
4290 # particular file as subject to the "Classpath" exception as provided
4291 # by Oracle in the LICENSE file that accompanied this code.
4292 #
4293 # This code is distributed in the hope that it will be useful, but WITHOUT
4294 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4295 # FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4296 # version 2 for more details (a copy is included in the LICENSE file that
4297 # accompanied this code).
4298 #
4299 # You should have received a copy of the GNU General Public License version
4300 # 2 along with this work; if not, write to the Free Software Foundation,
4301 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4302 #
4303 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4304 # or visit www.oracle.com if you need additional information or have any
4305 # questions.
4306 #
4307 
4308 
4309 
4310 
4311 
4312 
4313 
4314 # Check if the VS env variables were setup prior to running configure.
4315 # If not, then find vcvarsall.bat and run it automatically, and integrate
4316 # the set env variables into the spec file.
4317 
4318 
4319 
4320 
4321 
4322 
4323 
4324 
4325 
4326 
4327 
4328 # This line needs to be here, verbatim, after all includes and the dummy hook
4329 # definitions. It is replaced with custom functionality when building
4330 # custom sources.
4331 #CUSTOM_AUTOCONF_INCLUDE
4332 
4333 # Do not change or remove the following line, it is needed for consistency checks:
4334 DATE_WHEN_GENERATED=1416929627
4335 
4336 ###############################################################################
4337 #
4338 # Initialization / Boot-strapping
4339 #
4340 # The bootstrapping process needs to solve the "chicken or the egg" problem,
4341 # thus it jumps back and forth, each time gaining something needed later on.
4342 #
4343 ###############################################################################
4344 
4345 # If we are requested to print additional help, do that and then exit.
4346 # This must be the very first call.
4347 
4348   if test "x$CONFIGURE_PRINT_TOOLCHAIN_LIST" != x; then
4349     $PRINTF "The following toolchains are available as arguments to --with-toolchain-type.\n"
4350     $PRINTF "Which are valid to use depends on the build platform.\n"
4351     for toolchain in $VALID_TOOLCHAINS_all; do
4352       # Use indirect variable referencing
4353       toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain
4354       TOOLCHAIN_DESCRIPTION=${!toolchain_var_name}
4355       $PRINTF "  %-10s  %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION"
4356     done
4357 
4358     # And now exit directly
4359     exit 0
4360   fi
4361 
4362 
4363 # Basic initialization that must happen first of all in the normal process.
4364 
4365   # Save the original command line. This is passed to us by the wrapper configure script.
4366 
4367   DATE_WHEN_CONFIGURED=`LANG=C date`
4368 
4369   { $as_echo "$as_me:${as_lineno-$LINENO}: Configuration created at $DATE_WHEN_CONFIGURED." >&5
4370 $as_echo "$as_me: Configuration created at $DATE_WHEN_CONFIGURED." >&6;}
4371   { $as_echo "$as_me:${as_lineno-$LINENO}: configure script generated at timestamp $DATE_WHEN_GENERATED." >&5
4372 $as_echo "$as_me: configure script generated at timestamp $DATE_WHEN_GENERATED." >&6;}
4373 
4374 
4375   # Start with tools that do not need have cross compilation support
4376   # and can be expected to be found in the default PATH. These tools are
4377   # used by configure. Nor are these tools expected to be found in the
4378   # devkit from the builddeps server either, since they are
4379   # needed to download the devkit.
4380 
4381   # First are all the simple required tools.
4382 
4383 
4384 
4385   # Publish this variable in the help.
4386 
4387 
4388   if test "x$BASENAME" = x; then
4389     # The variable is not set by user, try to locate tool using the code snippet
4390     for ac_prog in basename
4391 do
4392   # Extract the first word of "$ac_prog", so it can be a program name with args.
4393 set dummy $ac_prog; ac_word=$2
4394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4395 $as_echo_n "checking for $ac_word... " >&6; }
4396 if ${ac_cv_path_BASENAME+:} false; then :
4397   $as_echo_n "(cached) " >&6
4398 else
4399   case $BASENAME in
4400   [\\/]* | ?:[\\/]*)
4401   ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
4402   ;;
4403   *)
4404   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4405 for as_dir in $PATH
4406 do
4407   IFS=$as_save_IFS
4408   test -z "$as_dir" && as_dir=.
4409     for ac_exec_ext in '' $ac_executable_extensions; do
4410   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4411     ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
4412     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4413     break 2
4414   fi
4415 done
4416   done
4417 IFS=$as_save_IFS
4418 
4419   ;;
4420 esac
4421 fi
4422 BASENAME=$ac_cv_path_BASENAME
4423 if test -n "$BASENAME"; then
4424   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
4425 $as_echo "$BASENAME" >&6; }
4426 else
4427   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4428 $as_echo "no" >&6; }
4429 fi
4430 
4431 
4432   test -n "$BASENAME" && break
4433 done
4434 
4435   else
4436     # The variable is set, but is it from the command line or the environment?
4437 
4438     # Try to remove the string !BASENAME! from our list.
4439     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASENAME!/}
4440     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4441       # If it failed, the variable was not from the command line. Ignore it,
4442       # but warn the user (except for BASH, which is always set by the calling BASH).
4443       if test "xBASENAME" != xBASH; then
4444         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&5
4445 $as_echo "$as_me: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&2;}
4446       fi
4447       # Try to locate tool using the code snippet
4448       for ac_prog in basename
4449 do
4450   # Extract the first word of "$ac_prog", so it can be a program name with args.
4451 set dummy $ac_prog; ac_word=$2
4452 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4453 $as_echo_n "checking for $ac_word... " >&6; }
4454 if ${ac_cv_path_BASENAME+:} false; then :
4455   $as_echo_n "(cached) " >&6
4456 else
4457   case $BASENAME in
4458   [\\/]* | ?:[\\/]*)
4459   ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
4460   ;;
4461   *)
4462   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4463 for as_dir in $PATH
4464 do
4465   IFS=$as_save_IFS
4466   test -z "$as_dir" && as_dir=.
4467     for ac_exec_ext in '' $ac_executable_extensions; do
4468   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4469     ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
4470     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4471     break 2
4472   fi
4473 done
4474   done
4475 IFS=$as_save_IFS
4476 
4477   ;;
4478 esac
4479 fi
4480 BASENAME=$ac_cv_path_BASENAME
4481 if test -n "$BASENAME"; then
4482   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
4483 $as_echo "$BASENAME" >&6; }
4484 else
4485   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4486 $as_echo "no" >&6; }
4487 fi
4488 
4489 
4490   test -n "$BASENAME" && break
4491 done
4492 
4493     else
4494       # If it succeeded, then it was overridden by the user. We will use it
4495       # for the tool.
4496 
4497       # First remove it from the list of overridden variables, so we can test
4498       # for unknown variables in the end.
4499       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4500 
4501       # Check if the provided tool contains a complete path.
4502       tool_specified="$BASENAME"
4503       tool_basename="${tool_specified##*/}"
4504       if test "x$tool_basename" = "x$tool_specified"; then
4505         # A command without a complete path is provided, search $PATH.
4506         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASENAME=$tool_basename" >&5
4507 $as_echo "$as_me: Will search for user supplied tool BASENAME=$tool_basename" >&6;}
4508         # Extract the first word of "$tool_basename", so it can be a program name with args.
4509 set dummy $tool_basename; ac_word=$2
4510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4511 $as_echo_n "checking for $ac_word... " >&6; }
4512 if ${ac_cv_path_BASENAME+:} false; then :
4513   $as_echo_n "(cached) " >&6
4514 else
4515   case $BASENAME in
4516   [\\/]* | ?:[\\/]*)
4517   ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
4518   ;;
4519   *)
4520   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4521 for as_dir in $PATH
4522 do
4523   IFS=$as_save_IFS
4524   test -z "$as_dir" && as_dir=.
4525     for ac_exec_ext in '' $ac_executable_extensions; do
4526   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4527     ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
4528     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4529     break 2
4530   fi
4531 done
4532   done
4533 IFS=$as_save_IFS
4534 
4535   ;;
4536 esac
4537 fi
4538 BASENAME=$ac_cv_path_BASENAME
4539 if test -n "$BASENAME"; then
4540   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
4541 $as_echo "$BASENAME" >&6; }
4542 else
4543   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4544 $as_echo "no" >&6; }
4545 fi
4546 
4547 
4548         if test "x$BASENAME" = x; then
4549           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
4550         fi
4551       else
4552         # Otherwise we believe it is a complete path. Use it as it is.
4553         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASENAME=$tool_specified" >&5
4554 $as_echo "$as_me: Will use user supplied tool BASENAME=$tool_specified" >&6;}
4555         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5
4556 $as_echo_n "checking for BASENAME... " >&6; }
4557         if test ! -x "$tool_specified"; then
4558           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4559 $as_echo "not found" >&6; }
4560           as_fn_error $? "User supplied tool BASENAME=$tool_specified does not exist or is not executable" "$LINENO" 5
4561         fi
4562         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
4563 $as_echo "$tool_specified" >&6; }
4564       fi
4565     fi
4566   fi
4567 
4568 
4569 
4570   if test "x$BASENAME" = x; then
4571     as_fn_error $? "Could not find required tool for BASENAME" "$LINENO" 5
4572   fi
4573 
4574 
4575 
4576 
4577 
4578   # Publish this variable in the help.
4579 
4580 
4581   if test "x$BASH" = x; then
4582     # The variable is not set by user, try to locate tool using the code snippet
4583     for ac_prog in bash
4584 do
4585   # Extract the first word of "$ac_prog", so it can be a program name with args.
4586 set dummy $ac_prog; ac_word=$2
4587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4588 $as_echo_n "checking for $ac_word... " >&6; }
4589 if ${ac_cv_path_BASH+:} false; then :
4590   $as_echo_n "(cached) " >&6
4591 else
4592   case $BASH in
4593   [\\/]* | ?:[\\/]*)
4594   ac_cv_path_BASH="$BASH" # Let the user override the test with a path.
4595   ;;
4596   *)
4597   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4598 for as_dir in $PATH
4599 do
4600   IFS=$as_save_IFS
4601   test -z "$as_dir" && as_dir=.
4602     for ac_exec_ext in '' $ac_executable_extensions; do
4603   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4604     ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext"
4605     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4606     break 2
4607   fi
4608 done
4609   done
4610 IFS=$as_save_IFS
4611 
4612   ;;
4613 esac
4614 fi
4615 BASH=$ac_cv_path_BASH
4616 if test -n "$BASH"; then
4617   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5
4618 $as_echo "$BASH" >&6; }
4619 else
4620   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4621 $as_echo "no" >&6; }
4622 fi
4623 
4624 
4625   test -n "$BASH" && break
4626 done
4627 
4628   else
4629     # The variable is set, but is it from the command line or the environment?
4630 
4631     # Try to remove the string !BASH! from our list.
4632     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASH!/}
4633     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4634       # If it failed, the variable was not from the command line. Ignore it,
4635       # but warn the user (except for BASH, which is always set by the calling BASH).
4636       if test "xBASH" != xBASH; then
4637         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&5
4638 $as_echo "$as_me: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&2;}
4639       fi
4640       # Try to locate tool using the code snippet
4641       for ac_prog in bash
4642 do
4643   # Extract the first word of "$ac_prog", so it can be a program name with args.
4644 set dummy $ac_prog; ac_word=$2
4645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4646 $as_echo_n "checking for $ac_word... " >&6; }
4647 if ${ac_cv_path_BASH+:} false; then :
4648   $as_echo_n "(cached) " >&6
4649 else
4650   case $BASH in
4651   [\\/]* | ?:[\\/]*)
4652   ac_cv_path_BASH="$BASH" # Let the user override the test with a path.
4653   ;;
4654   *)
4655   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4656 for as_dir in $PATH
4657 do
4658   IFS=$as_save_IFS
4659   test -z "$as_dir" && as_dir=.
4660     for ac_exec_ext in '' $ac_executable_extensions; do
4661   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4662     ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext"
4663     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4664     break 2
4665   fi
4666 done
4667   done
4668 IFS=$as_save_IFS
4669 
4670   ;;
4671 esac
4672 fi
4673 BASH=$ac_cv_path_BASH
4674 if test -n "$BASH"; then
4675   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5
4676 $as_echo "$BASH" >&6; }
4677 else
4678   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4679 $as_echo "no" >&6; }
4680 fi
4681 
4682 
4683   test -n "$BASH" && break
4684 done
4685 
4686     else
4687       # If it succeeded, then it was overridden by the user. We will use it
4688       # for the tool.
4689 
4690       # First remove it from the list of overridden variables, so we can test
4691       # for unknown variables in the end.
4692       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4693 
4694       # Check if the provided tool contains a complete path.
4695       tool_specified="$BASH"
4696       tool_basename="${tool_specified##*/}"
4697       if test "x$tool_basename" = "x$tool_specified"; then
4698         # A command without a complete path is provided, search $PATH.
4699         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASH=$tool_basename" >&5
4700 $as_echo "$as_me: Will search for user supplied tool BASH=$tool_basename" >&6;}
4701         # Extract the first word of "$tool_basename", so it can be a program name with args.
4702 set dummy $tool_basename; ac_word=$2
4703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4704 $as_echo_n "checking for $ac_word... " >&6; }
4705 if ${ac_cv_path_BASH+:} false; then :
4706   $as_echo_n "(cached) " >&6
4707 else
4708   case $BASH in
4709   [\\/]* | ?:[\\/]*)
4710   ac_cv_path_BASH="$BASH" # Let the user override the test with a path.
4711   ;;
4712   *)
4713   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4714 for as_dir in $PATH
4715 do
4716   IFS=$as_save_IFS
4717   test -z "$as_dir" && as_dir=.
4718     for ac_exec_ext in '' $ac_executable_extensions; do
4719   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4720     ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext"
4721     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4722     break 2
4723   fi
4724 done
4725   done
4726 IFS=$as_save_IFS
4727 
4728   ;;
4729 esac
4730 fi
4731 BASH=$ac_cv_path_BASH
4732 if test -n "$BASH"; then
4733   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5
4734 $as_echo "$BASH" >&6; }
4735 else
4736   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4737 $as_echo "no" >&6; }
4738 fi
4739 
4740 
4741         if test "x$BASH" = x; then
4742           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
4743         fi
4744       else
4745         # Otherwise we believe it is a complete path. Use it as it is.
4746         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASH=$tool_specified" >&5
4747 $as_echo "$as_me: Will use user supplied tool BASH=$tool_specified" >&6;}
4748         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5
4749 $as_echo_n "checking for BASH... " >&6; }
4750         if test ! -x "$tool_specified"; then
4751           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4752 $as_echo "not found" >&6; }
4753           as_fn_error $? "User supplied tool BASH=$tool_specified does not exist or is not executable" "$LINENO" 5
4754         fi
4755         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
4756 $as_echo "$tool_specified" >&6; }
4757       fi
4758     fi
4759   fi
4760 
4761 
4762 
4763   if test "x$BASH" = x; then
4764     as_fn_error $? "Could not find required tool for BASH" "$LINENO" 5
4765   fi
4766 
4767 
4768 
4769 
4770 
4771   # Publish this variable in the help.
4772 
4773 
4774   if test "x$CAT" = x; then
4775     # The variable is not set by user, try to locate tool using the code snippet
4776     for ac_prog in cat
4777 do
4778   # Extract the first word of "$ac_prog", so it can be a program name with args.
4779 set dummy $ac_prog; ac_word=$2
4780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4781 $as_echo_n "checking for $ac_word... " >&6; }
4782 if ${ac_cv_path_CAT+:} false; then :
4783   $as_echo_n "(cached) " >&6
4784 else
4785   case $CAT in
4786   [\\/]* | ?:[\\/]*)
4787   ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4788   ;;
4789   *)
4790   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4791 for as_dir in $PATH
4792 do
4793   IFS=$as_save_IFS
4794   test -z "$as_dir" && as_dir=.
4795     for ac_exec_ext in '' $ac_executable_extensions; do
4796   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4797     ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4798     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4799     break 2
4800   fi
4801 done
4802   done
4803 IFS=$as_save_IFS
4804 
4805   ;;
4806 esac
4807 fi
4808 CAT=$ac_cv_path_CAT
4809 if test -n "$CAT"; then
4810   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5
4811 $as_echo "$CAT" >&6; }
4812 else
4813   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4814 $as_echo "no" >&6; }
4815 fi
4816 
4817 
4818   test -n "$CAT" && break
4819 done
4820 
4821   else
4822     # The variable is set, but is it from the command line or the environment?
4823 
4824     # Try to remove the string !CAT! from our list.
4825     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CAT!/}
4826     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
4827       # If it failed, the variable was not from the command line. Ignore it,
4828       # but warn the user (except for BASH, which is always set by the calling BASH).
4829       if test "xCAT" != xBASH; then
4830         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&5
4831 $as_echo "$as_me: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&2;}
4832       fi
4833       # Try to locate tool using the code snippet
4834       for ac_prog in cat
4835 do
4836   # Extract the first word of "$ac_prog", so it can be a program name with args.
4837 set dummy $ac_prog; ac_word=$2
4838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4839 $as_echo_n "checking for $ac_word... " >&6; }
4840 if ${ac_cv_path_CAT+:} false; then :
4841   $as_echo_n "(cached) " >&6
4842 else
4843   case $CAT in
4844   [\\/]* | ?:[\\/]*)
4845   ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4846   ;;
4847   *)
4848   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4849 for as_dir in $PATH
4850 do
4851   IFS=$as_save_IFS
4852   test -z "$as_dir" && as_dir=.
4853     for ac_exec_ext in '' $ac_executable_extensions; do
4854   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4855     ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4856     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4857     break 2
4858   fi
4859 done
4860   done
4861 IFS=$as_save_IFS
4862 
4863   ;;
4864 esac
4865 fi
4866 CAT=$ac_cv_path_CAT
4867 if test -n "$CAT"; then
4868   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5
4869 $as_echo "$CAT" >&6; }
4870 else
4871   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4872 $as_echo "no" >&6; }
4873 fi
4874 
4875 
4876   test -n "$CAT" && break
4877 done
4878 
4879     else
4880       # If it succeeded, then it was overridden by the user. We will use it
4881       # for the tool.
4882 
4883       # First remove it from the list of overridden variables, so we can test
4884       # for unknown variables in the end.
4885       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
4886 
4887       # Check if the provided tool contains a complete path.
4888       tool_specified="$CAT"
4889       tool_basename="${tool_specified##*/}"
4890       if test "x$tool_basename" = "x$tool_specified"; then
4891         # A command without a complete path is provided, search $PATH.
4892         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CAT=$tool_basename" >&5
4893 $as_echo "$as_me: Will search for user supplied tool CAT=$tool_basename" >&6;}
4894         # Extract the first word of "$tool_basename", so it can be a program name with args.
4895 set dummy $tool_basename; ac_word=$2
4896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4897 $as_echo_n "checking for $ac_word... " >&6; }
4898 if ${ac_cv_path_CAT+:} false; then :
4899   $as_echo_n "(cached) " >&6
4900 else
4901   case $CAT in
4902   [\\/]* | ?:[\\/]*)
4903   ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4904   ;;
4905   *)
4906   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4907 for as_dir in $PATH
4908 do
4909   IFS=$as_save_IFS
4910   test -z "$as_dir" && as_dir=.
4911     for ac_exec_ext in '' $ac_executable_extensions; do
4912   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4913     ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4914     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4915     break 2
4916   fi
4917 done
4918   done
4919 IFS=$as_save_IFS
4920 
4921   ;;
4922 esac
4923 fi
4924 CAT=$ac_cv_path_CAT
4925 if test -n "$CAT"; then
4926   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5
4927 $as_echo "$CAT" >&6; }
4928 else
4929   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4930 $as_echo "no" >&6; }
4931 fi
4932 
4933 
4934         if test "x$CAT" = x; then
4935           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
4936         fi
4937       else
4938         # Otherwise we believe it is a complete path. Use it as it is.
4939         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CAT=$tool_specified" >&5
4940 $as_echo "$as_me: Will use user supplied tool CAT=$tool_specified" >&6;}
4941         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5
4942 $as_echo_n "checking for CAT... " >&6; }
4943         if test ! -x "$tool_specified"; then
4944           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
4945 $as_echo "not found" >&6; }
4946           as_fn_error $? "User supplied tool CAT=$tool_specified does not exist or is not executable" "$LINENO" 5
4947         fi
4948         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
4949 $as_echo "$tool_specified" >&6; }
4950       fi
4951     fi
4952   fi
4953 
4954 
4955 
4956   if test "x$CAT" = x; then
4957     as_fn_error $? "Could not find required tool for CAT" "$LINENO" 5
4958   fi
4959 
4960 
4961 
4962 
4963 
4964   # Publish this variable in the help.
4965 
4966 
4967   if test "x$CHMOD" = x; then
4968     # The variable is not set by user, try to locate tool using the code snippet
4969     for ac_prog in chmod
4970 do
4971   # Extract the first word of "$ac_prog", so it can be a program name with args.
4972 set dummy $ac_prog; ac_word=$2
4973 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4974 $as_echo_n "checking for $ac_word... " >&6; }
4975 if ${ac_cv_path_CHMOD+:} false; then :
4976   $as_echo_n "(cached) " >&6
4977 else
4978   case $CHMOD in
4979   [\\/]* | ?:[\\/]*)
4980   ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
4981   ;;
4982   *)
4983   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4984 for as_dir in $PATH
4985 do
4986   IFS=$as_save_IFS
4987   test -z "$as_dir" && as_dir=.
4988     for ac_exec_ext in '' $ac_executable_extensions; do
4989   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4990     ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext"
4991     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4992     break 2
4993   fi
4994 done
4995   done
4996 IFS=$as_save_IFS
4997 
4998   ;;
4999 esac
5000 fi
5001 CHMOD=$ac_cv_path_CHMOD
5002 if test -n "$CHMOD"; then
5003   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5
5004 $as_echo "$CHMOD" >&6; }
5005 else
5006   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5007 $as_echo "no" >&6; }
5008 fi
5009 
5010 
5011   test -n "$CHMOD" && break
5012 done
5013 
5014   else
5015     # The variable is set, but is it from the command line or the environment?
5016 
5017     # Try to remove the string !CHMOD! from our list.
5018     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CHMOD!/}
5019     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5020       # If it failed, the variable was not from the command line. Ignore it,
5021       # but warn the user (except for BASH, which is always set by the calling BASH).
5022       if test "xCHMOD" != xBASH; then
5023         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&5
5024 $as_echo "$as_me: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&2;}
5025       fi
5026       # Try to locate tool using the code snippet
5027       for ac_prog in chmod
5028 do
5029   # Extract the first word of "$ac_prog", so it can be a program name with args.
5030 set dummy $ac_prog; ac_word=$2
5031 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5032 $as_echo_n "checking for $ac_word... " >&6; }
5033 if ${ac_cv_path_CHMOD+:} false; then :
5034   $as_echo_n "(cached) " >&6
5035 else
5036   case $CHMOD in
5037   [\\/]* | ?:[\\/]*)
5038   ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
5039   ;;
5040   *)
5041   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5042 for as_dir in $PATH
5043 do
5044   IFS=$as_save_IFS
5045   test -z "$as_dir" && as_dir=.
5046     for ac_exec_ext in '' $ac_executable_extensions; do
5047   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5048     ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext"
5049     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5050     break 2
5051   fi
5052 done
5053   done
5054 IFS=$as_save_IFS
5055 
5056   ;;
5057 esac
5058 fi
5059 CHMOD=$ac_cv_path_CHMOD
5060 if test -n "$CHMOD"; then
5061   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5
5062 $as_echo "$CHMOD" >&6; }
5063 else
5064   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5065 $as_echo "no" >&6; }
5066 fi
5067 
5068 
5069   test -n "$CHMOD" && break
5070 done
5071 
5072     else
5073       # If it succeeded, then it was overridden by the user. We will use it
5074       # for the tool.
5075 
5076       # First remove it from the list of overridden variables, so we can test
5077       # for unknown variables in the end.
5078       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5079 
5080       # Check if the provided tool contains a complete path.
5081       tool_specified="$CHMOD"
5082       tool_basename="${tool_specified##*/}"
5083       if test "x$tool_basename" = "x$tool_specified"; then
5084         # A command without a complete path is provided, search $PATH.
5085         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CHMOD=$tool_basename" >&5
5086 $as_echo "$as_me: Will search for user supplied tool CHMOD=$tool_basename" >&6;}
5087         # Extract the first word of "$tool_basename", so it can be a program name with args.
5088 set dummy $tool_basename; ac_word=$2
5089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5090 $as_echo_n "checking for $ac_word... " >&6; }
5091 if ${ac_cv_path_CHMOD+:} false; then :
5092   $as_echo_n "(cached) " >&6
5093 else
5094   case $CHMOD in
5095   [\\/]* | ?:[\\/]*)
5096   ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path.
5097   ;;
5098   *)
5099   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5100 for as_dir in $PATH
5101 do
5102   IFS=$as_save_IFS
5103   test -z "$as_dir" && as_dir=.
5104     for ac_exec_ext in '' $ac_executable_extensions; do
5105   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5106     ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext"
5107     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5108     break 2
5109   fi
5110 done
5111   done
5112 IFS=$as_save_IFS
5113 
5114   ;;
5115 esac
5116 fi
5117 CHMOD=$ac_cv_path_CHMOD
5118 if test -n "$CHMOD"; then
5119   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5
5120 $as_echo "$CHMOD" >&6; }
5121 else
5122   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5123 $as_echo "no" >&6; }
5124 fi
5125 
5126 
5127         if test "x$CHMOD" = x; then
5128           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5129         fi
5130       else
5131         # Otherwise we believe it is a complete path. Use it as it is.
5132         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CHMOD=$tool_specified" >&5
5133 $as_echo "$as_me: Will use user supplied tool CHMOD=$tool_specified" >&6;}
5134         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5
5135 $as_echo_n "checking for CHMOD... " >&6; }
5136         if test ! -x "$tool_specified"; then
5137           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5138 $as_echo "not found" >&6; }
5139           as_fn_error $? "User supplied tool CHMOD=$tool_specified does not exist or is not executable" "$LINENO" 5
5140         fi
5141         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5142 $as_echo "$tool_specified" >&6; }
5143       fi
5144     fi
5145   fi
5146 
5147 
5148 
5149   if test "x$CHMOD" = x; then
5150     as_fn_error $? "Could not find required tool for CHMOD" "$LINENO" 5
5151   fi
5152 
5153 
5154 
5155 
5156 
5157   # Publish this variable in the help.
5158 
5159 
5160   if test "x$CMP" = x; then
5161     # The variable is not set by user, try to locate tool using the code snippet
5162     for ac_prog in cmp
5163 do
5164   # Extract the first word of "$ac_prog", so it can be a program name with args.
5165 set dummy $ac_prog; ac_word=$2
5166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5167 $as_echo_n "checking for $ac_word... " >&6; }
5168 if ${ac_cv_path_CMP+:} false; then :
5169   $as_echo_n "(cached) " >&6
5170 else
5171   case $CMP in
5172   [\\/]* | ?:[\\/]*)
5173   ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
5174   ;;
5175   *)
5176   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5177 for as_dir in $PATH
5178 do
5179   IFS=$as_save_IFS
5180   test -z "$as_dir" && as_dir=.
5181     for ac_exec_ext in '' $ac_executable_extensions; do
5182   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5183     ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
5184     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5185     break 2
5186   fi
5187 done
5188   done
5189 IFS=$as_save_IFS
5190 
5191   ;;
5192 esac
5193 fi
5194 CMP=$ac_cv_path_CMP
5195 if test -n "$CMP"; then
5196   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
5197 $as_echo "$CMP" >&6; }
5198 else
5199   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5200 $as_echo "no" >&6; }
5201 fi
5202 
5203 
5204   test -n "$CMP" && break
5205 done
5206 
5207   else
5208     # The variable is set, but is it from the command line or the environment?
5209 
5210     # Try to remove the string !CMP! from our list.
5211     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CMP!/}
5212     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5213       # If it failed, the variable was not from the command line. Ignore it,
5214       # but warn the user (except for BASH, which is always set by the calling BASH).
5215       if test "xCMP" != xBASH; then
5216         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&5
5217 $as_echo "$as_me: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&2;}
5218       fi
5219       # Try to locate tool using the code snippet
5220       for ac_prog in cmp
5221 do
5222   # Extract the first word of "$ac_prog", so it can be a program name with args.
5223 set dummy $ac_prog; ac_word=$2
5224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5225 $as_echo_n "checking for $ac_word... " >&6; }
5226 if ${ac_cv_path_CMP+:} false; then :
5227   $as_echo_n "(cached) " >&6
5228 else
5229   case $CMP in
5230   [\\/]* | ?:[\\/]*)
5231   ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
5232   ;;
5233   *)
5234   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5235 for as_dir in $PATH
5236 do
5237   IFS=$as_save_IFS
5238   test -z "$as_dir" && as_dir=.
5239     for ac_exec_ext in '' $ac_executable_extensions; do
5240   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5241     ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
5242     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5243     break 2
5244   fi
5245 done
5246   done
5247 IFS=$as_save_IFS
5248 
5249   ;;
5250 esac
5251 fi
5252 CMP=$ac_cv_path_CMP
5253 if test -n "$CMP"; then
5254   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
5255 $as_echo "$CMP" >&6; }
5256 else
5257   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5258 $as_echo "no" >&6; }
5259 fi
5260 
5261 
5262   test -n "$CMP" && break
5263 done
5264 
5265     else
5266       # If it succeeded, then it was overridden by the user. We will use it
5267       # for the tool.
5268 
5269       # First remove it from the list of overridden variables, so we can test
5270       # for unknown variables in the end.
5271       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5272 
5273       # Check if the provided tool contains a complete path.
5274       tool_specified="$CMP"
5275       tool_basename="${tool_specified##*/}"
5276       if test "x$tool_basename" = "x$tool_specified"; then
5277         # A command without a complete path is provided, search $PATH.
5278         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CMP=$tool_basename" >&5
5279 $as_echo "$as_me: Will search for user supplied tool CMP=$tool_basename" >&6;}
5280         # Extract the first word of "$tool_basename", so it can be a program name with args.
5281 set dummy $tool_basename; ac_word=$2
5282 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5283 $as_echo_n "checking for $ac_word... " >&6; }
5284 if ${ac_cv_path_CMP+:} false; then :
5285   $as_echo_n "(cached) " >&6
5286 else
5287   case $CMP in
5288   [\\/]* | ?:[\\/]*)
5289   ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
5290   ;;
5291   *)
5292   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5293 for as_dir in $PATH
5294 do
5295   IFS=$as_save_IFS
5296   test -z "$as_dir" && as_dir=.
5297     for ac_exec_ext in '' $ac_executable_extensions; do
5298   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5299     ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
5300     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5301     break 2
5302   fi
5303 done
5304   done
5305 IFS=$as_save_IFS
5306 
5307   ;;
5308 esac
5309 fi
5310 CMP=$ac_cv_path_CMP
5311 if test -n "$CMP"; then
5312   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
5313 $as_echo "$CMP" >&6; }
5314 else
5315   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5316 $as_echo "no" >&6; }
5317 fi
5318 
5319 
5320         if test "x$CMP" = x; then
5321           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5322         fi
5323       else
5324         # Otherwise we believe it is a complete path. Use it as it is.
5325         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CMP=$tool_specified" >&5
5326 $as_echo "$as_me: Will use user supplied tool CMP=$tool_specified" >&6;}
5327         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5
5328 $as_echo_n "checking for CMP... " >&6; }
5329         if test ! -x "$tool_specified"; then
5330           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5331 $as_echo "not found" >&6; }
5332           as_fn_error $? "User supplied tool CMP=$tool_specified does not exist or is not executable" "$LINENO" 5
5333         fi
5334         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5335 $as_echo "$tool_specified" >&6; }
5336       fi
5337     fi
5338   fi
5339 
5340 
5341 
5342   if test "x$CMP" = x; then
5343     as_fn_error $? "Could not find required tool for CMP" "$LINENO" 5
5344   fi
5345 
5346 
5347 
5348 
5349 
5350   # Publish this variable in the help.
5351 
5352 
5353   if test "x$COMM" = x; then
5354     # The variable is not set by user, try to locate tool using the code snippet
5355     for ac_prog in comm
5356 do
5357   # Extract the first word of "$ac_prog", so it can be a program name with args.
5358 set dummy $ac_prog; ac_word=$2
5359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5360 $as_echo_n "checking for $ac_word... " >&6; }
5361 if ${ac_cv_path_COMM+:} false; then :
5362   $as_echo_n "(cached) " >&6
5363 else
5364   case $COMM in
5365   [\\/]* | ?:[\\/]*)
5366   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
5367   ;;
5368   *)
5369   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5370 for as_dir in $PATH
5371 do
5372   IFS=$as_save_IFS
5373   test -z "$as_dir" && as_dir=.
5374     for ac_exec_ext in '' $ac_executable_extensions; do
5375   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5376     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
5377     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5378     break 2
5379   fi
5380 done
5381   done
5382 IFS=$as_save_IFS
5383 
5384   ;;
5385 esac
5386 fi
5387 COMM=$ac_cv_path_COMM
5388 if test -n "$COMM"; then
5389   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
5390 $as_echo "$COMM" >&6; }
5391 else
5392   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5393 $as_echo "no" >&6; }
5394 fi
5395 
5396 
5397   test -n "$COMM" && break
5398 done
5399 
5400   else
5401     # The variable is set, but is it from the command line or the environment?
5402 
5403     # Try to remove the string !COMM! from our list.
5404     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/}
5405     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5406       # If it failed, the variable was not from the command line. Ignore it,
5407       # but warn the user (except for BASH, which is always set by the calling BASH).
5408       if test "xCOMM" != xBASH; then
5409         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5
5410 $as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;}
5411       fi
5412       # Try to locate tool using the code snippet
5413       for ac_prog in comm
5414 do
5415   # Extract the first word of "$ac_prog", so it can be a program name with args.
5416 set dummy $ac_prog; ac_word=$2
5417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5418 $as_echo_n "checking for $ac_word... " >&6; }
5419 if ${ac_cv_path_COMM+:} false; then :
5420   $as_echo_n "(cached) " >&6
5421 else
5422   case $COMM in
5423   [\\/]* | ?:[\\/]*)
5424   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
5425   ;;
5426   *)
5427   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5428 for as_dir in $PATH
5429 do
5430   IFS=$as_save_IFS
5431   test -z "$as_dir" && as_dir=.
5432     for ac_exec_ext in '' $ac_executable_extensions; do
5433   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5434     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
5435     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5436     break 2
5437   fi
5438 done
5439   done
5440 IFS=$as_save_IFS
5441 
5442   ;;
5443 esac
5444 fi
5445 COMM=$ac_cv_path_COMM
5446 if test -n "$COMM"; then
5447   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
5448 $as_echo "$COMM" >&6; }
5449 else
5450   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5451 $as_echo "no" >&6; }
5452 fi
5453 
5454 
5455   test -n "$COMM" && break
5456 done
5457 
5458     else
5459       # If it succeeded, then it was overridden by the user. We will use it
5460       # for the tool.
5461 
5462       # First remove it from the list of overridden variables, so we can test
5463       # for unknown variables in the end.
5464       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5465 
5466       # Check if the provided tool contains a complete path.
5467       tool_specified="$COMM"
5468       tool_basename="${tool_specified##*/}"
5469       if test "x$tool_basename" = "x$tool_specified"; then
5470         # A command without a complete path is provided, search $PATH.
5471         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5
5472 $as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;}
5473         # Extract the first word of "$tool_basename", so it can be a program name with args.
5474 set dummy $tool_basename; ac_word=$2
5475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5476 $as_echo_n "checking for $ac_word... " >&6; }
5477 if ${ac_cv_path_COMM+:} false; then :
5478   $as_echo_n "(cached) " >&6
5479 else
5480   case $COMM in
5481   [\\/]* | ?:[\\/]*)
5482   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
5483   ;;
5484   *)
5485   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5486 for as_dir in $PATH
5487 do
5488   IFS=$as_save_IFS
5489   test -z "$as_dir" && as_dir=.
5490     for ac_exec_ext in '' $ac_executable_extensions; do
5491   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5492     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
5493     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5494     break 2
5495   fi
5496 done
5497   done
5498 IFS=$as_save_IFS
5499 
5500   ;;
5501 esac
5502 fi
5503 COMM=$ac_cv_path_COMM
5504 if test -n "$COMM"; then
5505   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
5506 $as_echo "$COMM" >&6; }
5507 else
5508   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5509 $as_echo "no" >&6; }
5510 fi
5511 
5512 
5513         if test "x$COMM" = x; then
5514           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5515         fi
5516       else
5517         # Otherwise we believe it is a complete path. Use it as it is.
5518         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5
5519 $as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;}
5520         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5
5521 $as_echo_n "checking for COMM... " >&6; }
5522         if test ! -x "$tool_specified"; then
5523           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5524 $as_echo "not found" >&6; }
5525           as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5
5526         fi
5527         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5528 $as_echo "$tool_specified" >&6; }
5529       fi
5530     fi
5531   fi
5532 
5533 
5534 
5535   if test "x$COMM" = x; then
5536     as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5
5537   fi
5538 
5539 
5540 
5541 
5542 
5543   # Publish this variable in the help.
5544 
5545 
5546   if test "x$CP" = x; then
5547     # The variable is not set by user, try to locate tool using the code snippet
5548     for ac_prog in cp
5549 do
5550   # Extract the first word of "$ac_prog", so it can be a program name with args.
5551 set dummy $ac_prog; ac_word=$2
5552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5553 $as_echo_n "checking for $ac_word... " >&6; }
5554 if ${ac_cv_path_CP+:} false; then :
5555   $as_echo_n "(cached) " >&6
5556 else
5557   case $CP in
5558   [\\/]* | ?:[\\/]*)
5559   ac_cv_path_CP="$CP" # Let the user override the test with a path.
5560   ;;
5561   *)
5562   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5563 for as_dir in $PATH
5564 do
5565   IFS=$as_save_IFS
5566   test -z "$as_dir" && as_dir=.
5567     for ac_exec_ext in '' $ac_executable_extensions; do
5568   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5569     ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext"
5570     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5571     break 2
5572   fi
5573 done
5574   done
5575 IFS=$as_save_IFS
5576 
5577   ;;
5578 esac
5579 fi
5580 CP=$ac_cv_path_CP
5581 if test -n "$CP"; then
5582   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5
5583 $as_echo "$CP" >&6; }
5584 else
5585   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5586 $as_echo "no" >&6; }
5587 fi
5588 
5589 
5590   test -n "$CP" && break
5591 done
5592 
5593   else
5594     # The variable is set, but is it from the command line or the environment?
5595 
5596     # Try to remove the string !CP! from our list.
5597     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CP!/}
5598     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5599       # If it failed, the variable was not from the command line. Ignore it,
5600       # but warn the user (except for BASH, which is always set by the calling BASH).
5601       if test "xCP" != xBASH; then
5602         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&5
5603 $as_echo "$as_me: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&2;}
5604       fi
5605       # Try to locate tool using the code snippet
5606       for ac_prog in cp
5607 do
5608   # Extract the first word of "$ac_prog", so it can be a program name with args.
5609 set dummy $ac_prog; ac_word=$2
5610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5611 $as_echo_n "checking for $ac_word... " >&6; }
5612 if ${ac_cv_path_CP+:} false; then :
5613   $as_echo_n "(cached) " >&6
5614 else
5615   case $CP in
5616   [\\/]* | ?:[\\/]*)
5617   ac_cv_path_CP="$CP" # Let the user override the test with a path.
5618   ;;
5619   *)
5620   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5621 for as_dir in $PATH
5622 do
5623   IFS=$as_save_IFS
5624   test -z "$as_dir" && as_dir=.
5625     for ac_exec_ext in '' $ac_executable_extensions; do
5626   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5627     ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext"
5628     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5629     break 2
5630   fi
5631 done
5632   done
5633 IFS=$as_save_IFS
5634 
5635   ;;
5636 esac
5637 fi
5638 CP=$ac_cv_path_CP
5639 if test -n "$CP"; then
5640   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5
5641 $as_echo "$CP" >&6; }
5642 else
5643   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5644 $as_echo "no" >&6; }
5645 fi
5646 
5647 
5648   test -n "$CP" && break
5649 done
5650 
5651     else
5652       # If it succeeded, then it was overridden by the user. We will use it
5653       # for the tool.
5654 
5655       # First remove it from the list of overridden variables, so we can test
5656       # for unknown variables in the end.
5657       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5658 
5659       # Check if the provided tool contains a complete path.
5660       tool_specified="$CP"
5661       tool_basename="${tool_specified##*/}"
5662       if test "x$tool_basename" = "x$tool_specified"; then
5663         # A command without a complete path is provided, search $PATH.
5664         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CP=$tool_basename" >&5
5665 $as_echo "$as_me: Will search for user supplied tool CP=$tool_basename" >&6;}
5666         # Extract the first word of "$tool_basename", so it can be a program name with args.
5667 set dummy $tool_basename; ac_word=$2
5668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5669 $as_echo_n "checking for $ac_word... " >&6; }
5670 if ${ac_cv_path_CP+:} false; then :
5671   $as_echo_n "(cached) " >&6
5672 else
5673   case $CP in
5674   [\\/]* | ?:[\\/]*)
5675   ac_cv_path_CP="$CP" # Let the user override the test with a path.
5676   ;;
5677   *)
5678   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5679 for as_dir in $PATH
5680 do
5681   IFS=$as_save_IFS
5682   test -z "$as_dir" && as_dir=.
5683     for ac_exec_ext in '' $ac_executable_extensions; do
5684   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5685     ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext"
5686     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5687     break 2
5688   fi
5689 done
5690   done
5691 IFS=$as_save_IFS
5692 
5693   ;;
5694 esac
5695 fi
5696 CP=$ac_cv_path_CP
5697 if test -n "$CP"; then
5698   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5
5699 $as_echo "$CP" >&6; }
5700 else
5701   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5702 $as_echo "no" >&6; }
5703 fi
5704 
5705 
5706         if test "x$CP" = x; then
5707           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5708         fi
5709       else
5710         # Otherwise we believe it is a complete path. Use it as it is.
5711         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CP=$tool_specified" >&5
5712 $as_echo "$as_me: Will use user supplied tool CP=$tool_specified" >&6;}
5713         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5
5714 $as_echo_n "checking for CP... " >&6; }
5715         if test ! -x "$tool_specified"; then
5716           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5717 $as_echo "not found" >&6; }
5718           as_fn_error $? "User supplied tool CP=$tool_specified does not exist or is not executable" "$LINENO" 5
5719         fi
5720         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5721 $as_echo "$tool_specified" >&6; }
5722       fi
5723     fi
5724   fi
5725 
5726 
5727 
5728   if test "x$CP" = x; then
5729     as_fn_error $? "Could not find required tool for CP" "$LINENO" 5
5730   fi
5731 
5732 
5733 
5734 
5735 
5736   # Publish this variable in the help.
5737 
5738 
5739   if test "x$CUT" = x; then
5740     # The variable is not set by user, try to locate tool using the code snippet
5741     for ac_prog in cut
5742 do
5743   # Extract the first word of "$ac_prog", so it can be a program name with args.
5744 set dummy $ac_prog; ac_word=$2
5745 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5746 $as_echo_n "checking for $ac_word... " >&6; }
5747 if ${ac_cv_path_CUT+:} false; then :
5748   $as_echo_n "(cached) " >&6
5749 else
5750   case $CUT in
5751   [\\/]* | ?:[\\/]*)
5752   ac_cv_path_CUT="$CUT" # Let the user override the test with a path.
5753   ;;
5754   *)
5755   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5756 for as_dir in $PATH
5757 do
5758   IFS=$as_save_IFS
5759   test -z "$as_dir" && as_dir=.
5760     for ac_exec_ext in '' $ac_executable_extensions; do
5761   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5762     ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext"
5763     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5764     break 2
5765   fi
5766 done
5767   done
5768 IFS=$as_save_IFS
5769 
5770   ;;
5771 esac
5772 fi
5773 CUT=$ac_cv_path_CUT
5774 if test -n "$CUT"; then
5775   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5
5776 $as_echo "$CUT" >&6; }
5777 else
5778   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5779 $as_echo "no" >&6; }
5780 fi
5781 
5782 
5783   test -n "$CUT" && break
5784 done
5785 
5786   else
5787     # The variable is set, but is it from the command line or the environment?
5788 
5789     # Try to remove the string !CUT! from our list.
5790     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CUT!/}
5791     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5792       # If it failed, the variable was not from the command line. Ignore it,
5793       # but warn the user (except for BASH, which is always set by the calling BASH).
5794       if test "xCUT" != xBASH; then
5795         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&5
5796 $as_echo "$as_me: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&2;}
5797       fi
5798       # Try to locate tool using the code snippet
5799       for ac_prog in cut
5800 do
5801   # Extract the first word of "$ac_prog", so it can be a program name with args.
5802 set dummy $ac_prog; ac_word=$2
5803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5804 $as_echo_n "checking for $ac_word... " >&6; }
5805 if ${ac_cv_path_CUT+:} false; then :
5806   $as_echo_n "(cached) " >&6
5807 else
5808   case $CUT in
5809   [\\/]* | ?:[\\/]*)
5810   ac_cv_path_CUT="$CUT" # Let the user override the test with a path.
5811   ;;
5812   *)
5813   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5814 for as_dir in $PATH
5815 do
5816   IFS=$as_save_IFS
5817   test -z "$as_dir" && as_dir=.
5818     for ac_exec_ext in '' $ac_executable_extensions; do
5819   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5820     ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext"
5821     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5822     break 2
5823   fi
5824 done
5825   done
5826 IFS=$as_save_IFS
5827 
5828   ;;
5829 esac
5830 fi
5831 CUT=$ac_cv_path_CUT
5832 if test -n "$CUT"; then
5833   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5
5834 $as_echo "$CUT" >&6; }
5835 else
5836   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5837 $as_echo "no" >&6; }
5838 fi
5839 
5840 
5841   test -n "$CUT" && break
5842 done
5843 
5844     else
5845       # If it succeeded, then it was overridden by the user. We will use it
5846       # for the tool.
5847 
5848       # First remove it from the list of overridden variables, so we can test
5849       # for unknown variables in the end.
5850       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
5851 
5852       # Check if the provided tool contains a complete path.
5853       tool_specified="$CUT"
5854       tool_basename="${tool_specified##*/}"
5855       if test "x$tool_basename" = "x$tool_specified"; then
5856         # A command without a complete path is provided, search $PATH.
5857         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CUT=$tool_basename" >&5
5858 $as_echo "$as_me: Will search for user supplied tool CUT=$tool_basename" >&6;}
5859         # Extract the first word of "$tool_basename", so it can be a program name with args.
5860 set dummy $tool_basename; ac_word=$2
5861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5862 $as_echo_n "checking for $ac_word... " >&6; }
5863 if ${ac_cv_path_CUT+:} false; then :
5864   $as_echo_n "(cached) " >&6
5865 else
5866   case $CUT in
5867   [\\/]* | ?:[\\/]*)
5868   ac_cv_path_CUT="$CUT" # Let the user override the test with a path.
5869   ;;
5870   *)
5871   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5872 for as_dir in $PATH
5873 do
5874   IFS=$as_save_IFS
5875   test -z "$as_dir" && as_dir=.
5876     for ac_exec_ext in '' $ac_executable_extensions; do
5877   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5878     ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext"
5879     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5880     break 2
5881   fi
5882 done
5883   done
5884 IFS=$as_save_IFS
5885 
5886   ;;
5887 esac
5888 fi
5889 CUT=$ac_cv_path_CUT
5890 if test -n "$CUT"; then
5891   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5
5892 $as_echo "$CUT" >&6; }
5893 else
5894   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5895 $as_echo "no" >&6; }
5896 fi
5897 
5898 
5899         if test "x$CUT" = x; then
5900           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
5901         fi
5902       else
5903         # Otherwise we believe it is a complete path. Use it as it is.
5904         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CUT=$tool_specified" >&5
5905 $as_echo "$as_me: Will use user supplied tool CUT=$tool_specified" >&6;}
5906         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5
5907 $as_echo_n "checking for CUT... " >&6; }
5908         if test ! -x "$tool_specified"; then
5909           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
5910 $as_echo "not found" >&6; }
5911           as_fn_error $? "User supplied tool CUT=$tool_specified does not exist or is not executable" "$LINENO" 5
5912         fi
5913         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
5914 $as_echo "$tool_specified" >&6; }
5915       fi
5916     fi
5917   fi
5918 
5919 
5920 
5921   if test "x$CUT" = x; then
5922     as_fn_error $? "Could not find required tool for CUT" "$LINENO" 5
5923   fi
5924 
5925 
5926 
5927 
5928 
5929   # Publish this variable in the help.
5930 
5931 
5932   if test "x$DATE" = x; then
5933     # The variable is not set by user, try to locate tool using the code snippet
5934     for ac_prog in date
5935 do
5936   # Extract the first word of "$ac_prog", so it can be a program name with args.
5937 set dummy $ac_prog; ac_word=$2
5938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5939 $as_echo_n "checking for $ac_word... " >&6; }
5940 if ${ac_cv_path_DATE+:} false; then :
5941   $as_echo_n "(cached) " >&6
5942 else
5943   case $DATE in
5944   [\\/]* | ?:[\\/]*)
5945   ac_cv_path_DATE="$DATE" # Let the user override the test with a path.
5946   ;;
5947   *)
5948   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5949 for as_dir in $PATH
5950 do
5951   IFS=$as_save_IFS
5952   test -z "$as_dir" && as_dir=.
5953     for ac_exec_ext in '' $ac_executable_extensions; do
5954   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5955     ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext"
5956     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5957     break 2
5958   fi
5959 done
5960   done
5961 IFS=$as_save_IFS
5962 
5963   ;;
5964 esac
5965 fi
5966 DATE=$ac_cv_path_DATE
5967 if test -n "$DATE"; then
5968   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5
5969 $as_echo "$DATE" >&6; }
5970 else
5971   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5972 $as_echo "no" >&6; }
5973 fi
5974 
5975 
5976   test -n "$DATE" && break
5977 done
5978 
5979   else
5980     # The variable is set, but is it from the command line or the environment?
5981 
5982     # Try to remove the string !DATE! from our list.
5983     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DATE!/}
5984     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
5985       # If it failed, the variable was not from the command line. Ignore it,
5986       # but warn the user (except for BASH, which is always set by the calling BASH).
5987       if test "xDATE" != xBASH; then
5988         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&5
5989 $as_echo "$as_me: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&2;}
5990       fi
5991       # Try to locate tool using the code snippet
5992       for ac_prog in date
5993 do
5994   # Extract the first word of "$ac_prog", so it can be a program name with args.
5995 set dummy $ac_prog; ac_word=$2
5996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5997 $as_echo_n "checking for $ac_word... " >&6; }
5998 if ${ac_cv_path_DATE+:} false; then :
5999   $as_echo_n "(cached) " >&6
6000 else
6001   case $DATE in
6002   [\\/]* | ?:[\\/]*)
6003   ac_cv_path_DATE="$DATE" # Let the user override the test with a path.
6004   ;;
6005   *)
6006   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6007 for as_dir in $PATH
6008 do
6009   IFS=$as_save_IFS
6010   test -z "$as_dir" && as_dir=.
6011     for ac_exec_ext in '' $ac_executable_extensions; do
6012   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6013     ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext"
6014     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6015     break 2
6016   fi
6017 done
6018   done
6019 IFS=$as_save_IFS
6020 
6021   ;;
6022 esac
6023 fi
6024 DATE=$ac_cv_path_DATE
6025 if test -n "$DATE"; then
6026   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5
6027 $as_echo "$DATE" >&6; }
6028 else
6029   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6030 $as_echo "no" >&6; }
6031 fi
6032 
6033 
6034   test -n "$DATE" && break
6035 done
6036 
6037     else
6038       # If it succeeded, then it was overridden by the user. We will use it
6039       # for the tool.
6040 
6041       # First remove it from the list of overridden variables, so we can test
6042       # for unknown variables in the end.
6043       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6044 
6045       # Check if the provided tool contains a complete path.
6046       tool_specified="$DATE"
6047       tool_basename="${tool_specified##*/}"
6048       if test "x$tool_basename" = "x$tool_specified"; then
6049         # A command without a complete path is provided, search $PATH.
6050         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DATE=$tool_basename" >&5
6051 $as_echo "$as_me: Will search for user supplied tool DATE=$tool_basename" >&6;}
6052         # Extract the first word of "$tool_basename", so it can be a program name with args.
6053 set dummy $tool_basename; ac_word=$2
6054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6055 $as_echo_n "checking for $ac_word... " >&6; }
6056 if ${ac_cv_path_DATE+:} false; then :
6057   $as_echo_n "(cached) " >&6
6058 else
6059   case $DATE in
6060   [\\/]* | ?:[\\/]*)
6061   ac_cv_path_DATE="$DATE" # Let the user override the test with a path.
6062   ;;
6063   *)
6064   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6065 for as_dir in $PATH
6066 do
6067   IFS=$as_save_IFS
6068   test -z "$as_dir" && as_dir=.
6069     for ac_exec_ext in '' $ac_executable_extensions; do
6070   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6071     ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext"
6072     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6073     break 2
6074   fi
6075 done
6076   done
6077 IFS=$as_save_IFS
6078 
6079   ;;
6080 esac
6081 fi
6082 DATE=$ac_cv_path_DATE
6083 if test -n "$DATE"; then
6084   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5
6085 $as_echo "$DATE" >&6; }
6086 else
6087   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6088 $as_echo "no" >&6; }
6089 fi
6090 
6091 
6092         if test "x$DATE" = x; then
6093           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6094         fi
6095       else
6096         # Otherwise we believe it is a complete path. Use it as it is.
6097         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DATE=$tool_specified" >&5
6098 $as_echo "$as_me: Will use user supplied tool DATE=$tool_specified" >&6;}
6099         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5
6100 $as_echo_n "checking for DATE... " >&6; }
6101         if test ! -x "$tool_specified"; then
6102           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6103 $as_echo "not found" >&6; }
6104           as_fn_error $? "User supplied tool DATE=$tool_specified does not exist or is not executable" "$LINENO" 5
6105         fi
6106         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6107 $as_echo "$tool_specified" >&6; }
6108       fi
6109     fi
6110   fi
6111 
6112 
6113 
6114   if test "x$DATE" = x; then
6115     as_fn_error $? "Could not find required tool for DATE" "$LINENO" 5
6116   fi
6117 
6118 
6119 
6120 
6121 
6122   # Publish this variable in the help.
6123 
6124 
6125   if test "x$DIFF" = x; then
6126     # The variable is not set by user, try to locate tool using the code snippet
6127     for ac_prog in gdiff diff
6128 do
6129   # Extract the first word of "$ac_prog", so it can be a program name with args.
6130 set dummy $ac_prog; ac_word=$2
6131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6132 $as_echo_n "checking for $ac_word... " >&6; }
6133 if ${ac_cv_path_DIFF+:} false; then :
6134   $as_echo_n "(cached) " >&6
6135 else
6136   case $DIFF in
6137   [\\/]* | ?:[\\/]*)
6138   ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path.
6139   ;;
6140   *)
6141   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6142 for as_dir in $PATH
6143 do
6144   IFS=$as_save_IFS
6145   test -z "$as_dir" && as_dir=.
6146     for ac_exec_ext in '' $ac_executable_extensions; do
6147   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6148     ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext"
6149     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6150     break 2
6151   fi
6152 done
6153   done
6154 IFS=$as_save_IFS
6155 
6156   ;;
6157 esac
6158 fi
6159 DIFF=$ac_cv_path_DIFF
6160 if test -n "$DIFF"; then
6161   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5
6162 $as_echo "$DIFF" >&6; }
6163 else
6164   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6165 $as_echo "no" >&6; }
6166 fi
6167 
6168 
6169   test -n "$DIFF" && break
6170 done
6171 
6172   else
6173     # The variable is set, but is it from the command line or the environment?
6174 
6175     # Try to remove the string !DIFF! from our list.
6176     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIFF!/}
6177     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6178       # If it failed, the variable was not from the command line. Ignore it,
6179       # but warn the user (except for BASH, which is always set by the calling BASH).
6180       if test "xDIFF" != xBASH; then
6181         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&5
6182 $as_echo "$as_me: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&2;}
6183       fi
6184       # Try to locate tool using the code snippet
6185       for ac_prog in gdiff diff
6186 do
6187   # Extract the first word of "$ac_prog", so it can be a program name with args.
6188 set dummy $ac_prog; ac_word=$2
6189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6190 $as_echo_n "checking for $ac_word... " >&6; }
6191 if ${ac_cv_path_DIFF+:} false; then :
6192   $as_echo_n "(cached) " >&6
6193 else
6194   case $DIFF in
6195   [\\/]* | ?:[\\/]*)
6196   ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path.
6197   ;;
6198   *)
6199   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6200 for as_dir in $PATH
6201 do
6202   IFS=$as_save_IFS
6203   test -z "$as_dir" && as_dir=.
6204     for ac_exec_ext in '' $ac_executable_extensions; do
6205   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6206     ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext"
6207     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6208     break 2
6209   fi
6210 done
6211   done
6212 IFS=$as_save_IFS
6213 
6214   ;;
6215 esac
6216 fi
6217 DIFF=$ac_cv_path_DIFF
6218 if test -n "$DIFF"; then
6219   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5
6220 $as_echo "$DIFF" >&6; }
6221 else
6222   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6223 $as_echo "no" >&6; }
6224 fi
6225 
6226 
6227   test -n "$DIFF" && break
6228 done
6229 
6230     else
6231       # If it succeeded, then it was overridden by the user. We will use it
6232       # for the tool.
6233 
6234       # First remove it from the list of overridden variables, so we can test
6235       # for unknown variables in the end.
6236       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6237 
6238       # Check if the provided tool contains a complete path.
6239       tool_specified="$DIFF"
6240       tool_basename="${tool_specified##*/}"
6241       if test "x$tool_basename" = "x$tool_specified"; then
6242         # A command without a complete path is provided, search $PATH.
6243         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIFF=$tool_basename" >&5
6244 $as_echo "$as_me: Will search for user supplied tool DIFF=$tool_basename" >&6;}
6245         # Extract the first word of "$tool_basename", so it can be a program name with args.
6246 set dummy $tool_basename; ac_word=$2
6247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6248 $as_echo_n "checking for $ac_word... " >&6; }
6249 if ${ac_cv_path_DIFF+:} false; then :
6250   $as_echo_n "(cached) " >&6
6251 else
6252   case $DIFF in
6253   [\\/]* | ?:[\\/]*)
6254   ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path.
6255   ;;
6256   *)
6257   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6258 for as_dir in $PATH
6259 do
6260   IFS=$as_save_IFS
6261   test -z "$as_dir" && as_dir=.
6262     for ac_exec_ext in '' $ac_executable_extensions; do
6263   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6264     ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext"
6265     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6266     break 2
6267   fi
6268 done
6269   done
6270 IFS=$as_save_IFS
6271 
6272   ;;
6273 esac
6274 fi
6275 DIFF=$ac_cv_path_DIFF
6276 if test -n "$DIFF"; then
6277   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5
6278 $as_echo "$DIFF" >&6; }
6279 else
6280   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6281 $as_echo "no" >&6; }
6282 fi
6283 
6284 
6285         if test "x$DIFF" = x; then
6286           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6287         fi
6288       else
6289         # Otherwise we believe it is a complete path. Use it as it is.
6290         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIFF=$tool_specified" >&5
6291 $as_echo "$as_me: Will use user supplied tool DIFF=$tool_specified" >&6;}
6292         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5
6293 $as_echo_n "checking for DIFF... " >&6; }
6294         if test ! -x "$tool_specified"; then
6295           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6296 $as_echo "not found" >&6; }
6297           as_fn_error $? "User supplied tool DIFF=$tool_specified does not exist or is not executable" "$LINENO" 5
6298         fi
6299         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6300 $as_echo "$tool_specified" >&6; }
6301       fi
6302     fi
6303   fi
6304 
6305 
6306 
6307   if test "x$DIFF" = x; then
6308     as_fn_error $? "Could not find required tool for DIFF" "$LINENO" 5
6309   fi
6310 
6311 
6312 
6313 
6314 
6315   # Publish this variable in the help.
6316 
6317 
6318   if test "x$DIRNAME" = x; then
6319     # The variable is not set by user, try to locate tool using the code snippet
6320     for ac_prog in dirname
6321 do
6322   # Extract the first word of "$ac_prog", so it can be a program name with args.
6323 set dummy $ac_prog; ac_word=$2
6324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6325 $as_echo_n "checking for $ac_word... " >&6; }
6326 if ${ac_cv_path_DIRNAME+:} false; then :
6327   $as_echo_n "(cached) " >&6
6328 else
6329   case $DIRNAME in
6330   [\\/]* | ?:[\\/]*)
6331   ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
6332   ;;
6333   *)
6334   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6335 for as_dir in $PATH
6336 do
6337   IFS=$as_save_IFS
6338   test -z "$as_dir" && as_dir=.
6339     for ac_exec_ext in '' $ac_executable_extensions; do
6340   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6341     ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
6342     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6343     break 2
6344   fi
6345 done
6346   done
6347 IFS=$as_save_IFS
6348 
6349   ;;
6350 esac
6351 fi
6352 DIRNAME=$ac_cv_path_DIRNAME
6353 if test -n "$DIRNAME"; then
6354   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
6355 $as_echo "$DIRNAME" >&6; }
6356 else
6357   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6358 $as_echo "no" >&6; }
6359 fi
6360 
6361 
6362   test -n "$DIRNAME" && break
6363 done
6364 
6365   else
6366     # The variable is set, but is it from the command line or the environment?
6367 
6368     # Try to remove the string !DIRNAME! from our list.
6369     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIRNAME!/}
6370     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6371       # If it failed, the variable was not from the command line. Ignore it,
6372       # but warn the user (except for BASH, which is always set by the calling BASH).
6373       if test "xDIRNAME" != xBASH; then
6374         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&5
6375 $as_echo "$as_me: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&2;}
6376       fi
6377       # Try to locate tool using the code snippet
6378       for ac_prog in dirname
6379 do
6380   # Extract the first word of "$ac_prog", so it can be a program name with args.
6381 set dummy $ac_prog; ac_word=$2
6382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6383 $as_echo_n "checking for $ac_word... " >&6; }
6384 if ${ac_cv_path_DIRNAME+:} false; then :
6385   $as_echo_n "(cached) " >&6
6386 else
6387   case $DIRNAME in
6388   [\\/]* | ?:[\\/]*)
6389   ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
6390   ;;
6391   *)
6392   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6393 for as_dir in $PATH
6394 do
6395   IFS=$as_save_IFS
6396   test -z "$as_dir" && as_dir=.
6397     for ac_exec_ext in '' $ac_executable_extensions; do
6398   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6399     ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
6400     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6401     break 2
6402   fi
6403 done
6404   done
6405 IFS=$as_save_IFS
6406 
6407   ;;
6408 esac
6409 fi
6410 DIRNAME=$ac_cv_path_DIRNAME
6411 if test -n "$DIRNAME"; then
6412   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
6413 $as_echo "$DIRNAME" >&6; }
6414 else
6415   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6416 $as_echo "no" >&6; }
6417 fi
6418 
6419 
6420   test -n "$DIRNAME" && break
6421 done
6422 
6423     else
6424       # If it succeeded, then it was overridden by the user. We will use it
6425       # for the tool.
6426 
6427       # First remove it from the list of overridden variables, so we can test
6428       # for unknown variables in the end.
6429       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6430 
6431       # Check if the provided tool contains a complete path.
6432       tool_specified="$DIRNAME"
6433       tool_basename="${tool_specified##*/}"
6434       if test "x$tool_basename" = "x$tool_specified"; then
6435         # A command without a complete path is provided, search $PATH.
6436         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIRNAME=$tool_basename" >&5
6437 $as_echo "$as_me: Will search for user supplied tool DIRNAME=$tool_basename" >&6;}
6438         # Extract the first word of "$tool_basename", so it can be a program name with args.
6439 set dummy $tool_basename; ac_word=$2
6440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6441 $as_echo_n "checking for $ac_word... " >&6; }
6442 if ${ac_cv_path_DIRNAME+:} false; then :
6443   $as_echo_n "(cached) " >&6
6444 else
6445   case $DIRNAME in
6446   [\\/]* | ?:[\\/]*)
6447   ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
6448   ;;
6449   *)
6450   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6451 for as_dir in $PATH
6452 do
6453   IFS=$as_save_IFS
6454   test -z "$as_dir" && as_dir=.
6455     for ac_exec_ext in '' $ac_executable_extensions; do
6456   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6457     ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
6458     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6459     break 2
6460   fi
6461 done
6462   done
6463 IFS=$as_save_IFS
6464 
6465   ;;
6466 esac
6467 fi
6468 DIRNAME=$ac_cv_path_DIRNAME
6469 if test -n "$DIRNAME"; then
6470   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
6471 $as_echo "$DIRNAME" >&6; }
6472 else
6473   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6474 $as_echo "no" >&6; }
6475 fi
6476 
6477 
6478         if test "x$DIRNAME" = x; then
6479           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6480         fi
6481       else
6482         # Otherwise we believe it is a complete path. Use it as it is.
6483         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIRNAME=$tool_specified" >&5
6484 $as_echo "$as_me: Will use user supplied tool DIRNAME=$tool_specified" >&6;}
6485         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5
6486 $as_echo_n "checking for DIRNAME... " >&6; }
6487         if test ! -x "$tool_specified"; then
6488           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6489 $as_echo "not found" >&6; }
6490           as_fn_error $? "User supplied tool DIRNAME=$tool_specified does not exist or is not executable" "$LINENO" 5
6491         fi
6492         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6493 $as_echo "$tool_specified" >&6; }
6494       fi
6495     fi
6496   fi
6497 
6498 
6499 
6500   if test "x$DIRNAME" = x; then
6501     as_fn_error $? "Could not find required tool for DIRNAME" "$LINENO" 5
6502   fi
6503 
6504 
6505 
6506 
6507 
6508   # Publish this variable in the help.
6509 
6510 
6511   if test "x$ECHO" = x; then
6512     # The variable is not set by user, try to locate tool using the code snippet
6513     for ac_prog in echo
6514 do
6515   # Extract the first word of "$ac_prog", so it can be a program name with args.
6516 set dummy $ac_prog; ac_word=$2
6517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6518 $as_echo_n "checking for $ac_word... " >&6; }
6519 if ${ac_cv_path_ECHO+:} false; then :
6520   $as_echo_n "(cached) " >&6
6521 else
6522   case $ECHO in
6523   [\\/]* | ?:[\\/]*)
6524   ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path.
6525   ;;
6526   *)
6527   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6528 for as_dir in $PATH
6529 do
6530   IFS=$as_save_IFS
6531   test -z "$as_dir" && as_dir=.
6532     for ac_exec_ext in '' $ac_executable_extensions; do
6533   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6534     ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext"
6535     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6536     break 2
6537   fi
6538 done
6539   done
6540 IFS=$as_save_IFS
6541 
6542   ;;
6543 esac
6544 fi
6545 ECHO=$ac_cv_path_ECHO
6546 if test -n "$ECHO"; then
6547   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5
6548 $as_echo "$ECHO" >&6; }
6549 else
6550   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6551 $as_echo "no" >&6; }
6552 fi
6553 
6554 
6555   test -n "$ECHO" && break
6556 done
6557 
6558   else
6559     # The variable is set, but is it from the command line or the environment?
6560 
6561     # Try to remove the string !ECHO! from our list.
6562     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ECHO!/}
6563     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6564       # If it failed, the variable was not from the command line. Ignore it,
6565       # but warn the user (except for BASH, which is always set by the calling BASH).
6566       if test "xECHO" != xBASH; then
6567         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&5
6568 $as_echo "$as_me: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&2;}
6569       fi
6570       # Try to locate tool using the code snippet
6571       for ac_prog in echo
6572 do
6573   # Extract the first word of "$ac_prog", so it can be a program name with args.
6574 set dummy $ac_prog; ac_word=$2
6575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6576 $as_echo_n "checking for $ac_word... " >&6; }
6577 if ${ac_cv_path_ECHO+:} false; then :
6578   $as_echo_n "(cached) " >&6
6579 else
6580   case $ECHO in
6581   [\\/]* | ?:[\\/]*)
6582   ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path.
6583   ;;
6584   *)
6585   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6586 for as_dir in $PATH
6587 do
6588   IFS=$as_save_IFS
6589   test -z "$as_dir" && as_dir=.
6590     for ac_exec_ext in '' $ac_executable_extensions; do
6591   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6592     ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext"
6593     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6594     break 2
6595   fi
6596 done
6597   done
6598 IFS=$as_save_IFS
6599 
6600   ;;
6601 esac
6602 fi
6603 ECHO=$ac_cv_path_ECHO
6604 if test -n "$ECHO"; then
6605   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5
6606 $as_echo "$ECHO" >&6; }
6607 else
6608   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6609 $as_echo "no" >&6; }
6610 fi
6611 
6612 
6613   test -n "$ECHO" && break
6614 done
6615 
6616     else
6617       # If it succeeded, then it was overridden by the user. We will use it
6618       # for the tool.
6619 
6620       # First remove it from the list of overridden variables, so we can test
6621       # for unknown variables in the end.
6622       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6623 
6624       # Check if the provided tool contains a complete path.
6625       tool_specified="$ECHO"
6626       tool_basename="${tool_specified##*/}"
6627       if test "x$tool_basename" = "x$tool_specified"; then
6628         # A command without a complete path is provided, search $PATH.
6629         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ECHO=$tool_basename" >&5
6630 $as_echo "$as_me: Will search for user supplied tool ECHO=$tool_basename" >&6;}
6631         # Extract the first word of "$tool_basename", so it can be a program name with args.
6632 set dummy $tool_basename; ac_word=$2
6633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6634 $as_echo_n "checking for $ac_word... " >&6; }
6635 if ${ac_cv_path_ECHO+:} false; then :
6636   $as_echo_n "(cached) " >&6
6637 else
6638   case $ECHO in
6639   [\\/]* | ?:[\\/]*)
6640   ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path.
6641   ;;
6642   *)
6643   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6644 for as_dir in $PATH
6645 do
6646   IFS=$as_save_IFS
6647   test -z "$as_dir" && as_dir=.
6648     for ac_exec_ext in '' $ac_executable_extensions; do
6649   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6650     ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext"
6651     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6652     break 2
6653   fi
6654 done
6655   done
6656 IFS=$as_save_IFS
6657 
6658   ;;
6659 esac
6660 fi
6661 ECHO=$ac_cv_path_ECHO
6662 if test -n "$ECHO"; then
6663   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5
6664 $as_echo "$ECHO" >&6; }
6665 else
6666   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6667 $as_echo "no" >&6; }
6668 fi
6669 
6670 
6671         if test "x$ECHO" = x; then
6672           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6673         fi
6674       else
6675         # Otherwise we believe it is a complete path. Use it as it is.
6676         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ECHO=$tool_specified" >&5
6677 $as_echo "$as_me: Will use user supplied tool ECHO=$tool_specified" >&6;}
6678         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5
6679 $as_echo_n "checking for ECHO... " >&6; }
6680         if test ! -x "$tool_specified"; then
6681           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6682 $as_echo "not found" >&6; }
6683           as_fn_error $? "User supplied tool ECHO=$tool_specified does not exist or is not executable" "$LINENO" 5
6684         fi
6685         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6686 $as_echo "$tool_specified" >&6; }
6687       fi
6688     fi
6689   fi
6690 
6691 
6692 
6693   if test "x$ECHO" = x; then
6694     as_fn_error $? "Could not find required tool for ECHO" "$LINENO" 5
6695   fi
6696 
6697 
6698 
6699 
6700 
6701   # Publish this variable in the help.
6702 
6703 
6704   if test "x$EXPR" = x; then
6705     # The variable is not set by user, try to locate tool using the code snippet
6706     for ac_prog in expr
6707 do
6708   # Extract the first word of "$ac_prog", so it can be a program name with args.
6709 set dummy $ac_prog; ac_word=$2
6710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6711 $as_echo_n "checking for $ac_word... " >&6; }
6712 if ${ac_cv_path_EXPR+:} false; then :
6713   $as_echo_n "(cached) " >&6
6714 else
6715   case $EXPR in
6716   [\\/]* | ?:[\\/]*)
6717   ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path.
6718   ;;
6719   *)
6720   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6721 for as_dir in $PATH
6722 do
6723   IFS=$as_save_IFS
6724   test -z "$as_dir" && as_dir=.
6725     for ac_exec_ext in '' $ac_executable_extensions; do
6726   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6727     ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext"
6728     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6729     break 2
6730   fi
6731 done
6732   done
6733 IFS=$as_save_IFS
6734 
6735   ;;
6736 esac
6737 fi
6738 EXPR=$ac_cv_path_EXPR
6739 if test -n "$EXPR"; then
6740   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5
6741 $as_echo "$EXPR" >&6; }
6742 else
6743   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6744 $as_echo "no" >&6; }
6745 fi
6746 
6747 
6748   test -n "$EXPR" && break
6749 done
6750 
6751   else
6752     # The variable is set, but is it from the command line or the environment?
6753 
6754     # Try to remove the string !EXPR! from our list.
6755     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EXPR!/}
6756     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6757       # If it failed, the variable was not from the command line. Ignore it,
6758       # but warn the user (except for BASH, which is always set by the calling BASH).
6759       if test "xEXPR" != xBASH; then
6760         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&5
6761 $as_echo "$as_me: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&2;}
6762       fi
6763       # Try to locate tool using the code snippet
6764       for ac_prog in expr
6765 do
6766   # Extract the first word of "$ac_prog", so it can be a program name with args.
6767 set dummy $ac_prog; ac_word=$2
6768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6769 $as_echo_n "checking for $ac_word... " >&6; }
6770 if ${ac_cv_path_EXPR+:} false; then :
6771   $as_echo_n "(cached) " >&6
6772 else
6773   case $EXPR in
6774   [\\/]* | ?:[\\/]*)
6775   ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path.
6776   ;;
6777   *)
6778   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6779 for as_dir in $PATH
6780 do
6781   IFS=$as_save_IFS
6782   test -z "$as_dir" && as_dir=.
6783     for ac_exec_ext in '' $ac_executable_extensions; do
6784   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6785     ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext"
6786     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6787     break 2
6788   fi
6789 done
6790   done
6791 IFS=$as_save_IFS
6792 
6793   ;;
6794 esac
6795 fi
6796 EXPR=$ac_cv_path_EXPR
6797 if test -n "$EXPR"; then
6798   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5
6799 $as_echo "$EXPR" >&6; }
6800 else
6801   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6802 $as_echo "no" >&6; }
6803 fi
6804 
6805 
6806   test -n "$EXPR" && break
6807 done
6808 
6809     else
6810       # If it succeeded, then it was overridden by the user. We will use it
6811       # for the tool.
6812 
6813       # First remove it from the list of overridden variables, so we can test
6814       # for unknown variables in the end.
6815       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
6816 
6817       # Check if the provided tool contains a complete path.
6818       tool_specified="$EXPR"
6819       tool_basename="${tool_specified##*/}"
6820       if test "x$tool_basename" = "x$tool_specified"; then
6821         # A command without a complete path is provided, search $PATH.
6822         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EXPR=$tool_basename" >&5
6823 $as_echo "$as_me: Will search for user supplied tool EXPR=$tool_basename" >&6;}
6824         # Extract the first word of "$tool_basename", so it can be a program name with args.
6825 set dummy $tool_basename; ac_word=$2
6826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6827 $as_echo_n "checking for $ac_word... " >&6; }
6828 if ${ac_cv_path_EXPR+:} false; then :
6829   $as_echo_n "(cached) " >&6
6830 else
6831   case $EXPR in
6832   [\\/]* | ?:[\\/]*)
6833   ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path.
6834   ;;
6835   *)
6836   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6837 for as_dir in $PATH
6838 do
6839   IFS=$as_save_IFS
6840   test -z "$as_dir" && as_dir=.
6841     for ac_exec_ext in '' $ac_executable_extensions; do
6842   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6843     ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext"
6844     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6845     break 2
6846   fi
6847 done
6848   done
6849 IFS=$as_save_IFS
6850 
6851   ;;
6852 esac
6853 fi
6854 EXPR=$ac_cv_path_EXPR
6855 if test -n "$EXPR"; then
6856   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5
6857 $as_echo "$EXPR" >&6; }
6858 else
6859   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6860 $as_echo "no" >&6; }
6861 fi
6862 
6863 
6864         if test "x$EXPR" = x; then
6865           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
6866         fi
6867       else
6868         # Otherwise we believe it is a complete path. Use it as it is.
6869         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EXPR=$tool_specified" >&5
6870 $as_echo "$as_me: Will use user supplied tool EXPR=$tool_specified" >&6;}
6871         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5
6872 $as_echo_n "checking for EXPR... " >&6; }
6873         if test ! -x "$tool_specified"; then
6874           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6875 $as_echo "not found" >&6; }
6876           as_fn_error $? "User supplied tool EXPR=$tool_specified does not exist or is not executable" "$LINENO" 5
6877         fi
6878         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
6879 $as_echo "$tool_specified" >&6; }
6880       fi
6881     fi
6882   fi
6883 
6884 
6885 
6886   if test "x$EXPR" = x; then
6887     as_fn_error $? "Could not find required tool for EXPR" "$LINENO" 5
6888   fi
6889 
6890 
6891 
6892 
6893 
6894   # Publish this variable in the help.
6895 
6896 
6897   if test "x$FILE" = x; then
6898     # The variable is not set by user, try to locate tool using the code snippet
6899     for ac_prog in file
6900 do
6901   # Extract the first word of "$ac_prog", so it can be a program name with args.
6902 set dummy $ac_prog; ac_word=$2
6903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6904 $as_echo_n "checking for $ac_word... " >&6; }
6905 if ${ac_cv_path_FILE+:} false; then :
6906   $as_echo_n "(cached) " >&6
6907 else
6908   case $FILE in
6909   [\\/]* | ?:[\\/]*)
6910   ac_cv_path_FILE="$FILE" # Let the user override the test with a path.
6911   ;;
6912   *)
6913   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6914 for as_dir in $PATH
6915 do
6916   IFS=$as_save_IFS
6917   test -z "$as_dir" && as_dir=.
6918     for ac_exec_ext in '' $ac_executable_extensions; do
6919   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6920     ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext"
6921     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6922     break 2
6923   fi
6924 done
6925   done
6926 IFS=$as_save_IFS
6927 
6928   ;;
6929 esac
6930 fi
6931 FILE=$ac_cv_path_FILE
6932 if test -n "$FILE"; then
6933   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5
6934 $as_echo "$FILE" >&6; }
6935 else
6936   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6937 $as_echo "no" >&6; }
6938 fi
6939 
6940 
6941   test -n "$FILE" && break
6942 done
6943 
6944   else
6945     # The variable is set, but is it from the command line or the environment?
6946 
6947     # Try to remove the string !FILE! from our list.
6948     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FILE!/}
6949     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
6950       # If it failed, the variable was not from the command line. Ignore it,
6951       # but warn the user (except for BASH, which is always set by the calling BASH).
6952       if test "xFILE" != xBASH; then
6953         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&5
6954 $as_echo "$as_me: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&2;}
6955       fi
6956       # Try to locate tool using the code snippet
6957       for ac_prog in file
6958 do
6959   # Extract the first word of "$ac_prog", so it can be a program name with args.
6960 set dummy $ac_prog; ac_word=$2
6961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6962 $as_echo_n "checking for $ac_word... " >&6; }
6963 if ${ac_cv_path_FILE+:} false; then :
6964   $as_echo_n "(cached) " >&6
6965 else
6966   case $FILE in
6967   [\\/]* | ?:[\\/]*)
6968   ac_cv_path_FILE="$FILE" # Let the user override the test with a path.
6969   ;;
6970   *)
6971   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6972 for as_dir in $PATH
6973 do
6974   IFS=$as_save_IFS
6975   test -z "$as_dir" && as_dir=.
6976     for ac_exec_ext in '' $ac_executable_extensions; do
6977   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6978     ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext"
6979     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6980     break 2
6981   fi
6982 done
6983   done
6984 IFS=$as_save_IFS
6985 
6986   ;;
6987 esac
6988 fi
6989 FILE=$ac_cv_path_FILE
6990 if test -n "$FILE"; then
6991   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5
6992 $as_echo "$FILE" >&6; }
6993 else
6994   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6995 $as_echo "no" >&6; }
6996 fi
6997 
6998 
6999   test -n "$FILE" && break
7000 done
7001 
7002     else
7003       # If it succeeded, then it was overridden by the user. We will use it
7004       # for the tool.
7005 
7006       # First remove it from the list of overridden variables, so we can test
7007       # for unknown variables in the end.
7008       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7009 
7010       # Check if the provided tool contains a complete path.
7011       tool_specified="$FILE"
7012       tool_basename="${tool_specified##*/}"
7013       if test "x$tool_basename" = "x$tool_specified"; then
7014         # A command without a complete path is provided, search $PATH.
7015         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FILE=$tool_basename" >&5
7016 $as_echo "$as_me: Will search for user supplied tool FILE=$tool_basename" >&6;}
7017         # Extract the first word of "$tool_basename", so it can be a program name with args.
7018 set dummy $tool_basename; ac_word=$2
7019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7020 $as_echo_n "checking for $ac_word... " >&6; }
7021 if ${ac_cv_path_FILE+:} false; then :
7022   $as_echo_n "(cached) " >&6
7023 else
7024   case $FILE in
7025   [\\/]* | ?:[\\/]*)
7026   ac_cv_path_FILE="$FILE" # Let the user override the test with a path.
7027   ;;
7028   *)
7029   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7030 for as_dir in $PATH
7031 do
7032   IFS=$as_save_IFS
7033   test -z "$as_dir" && as_dir=.
7034     for ac_exec_ext in '' $ac_executable_extensions; do
7035   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7036     ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext"
7037     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7038     break 2
7039   fi
7040 done
7041   done
7042 IFS=$as_save_IFS
7043 
7044   ;;
7045 esac
7046 fi
7047 FILE=$ac_cv_path_FILE
7048 if test -n "$FILE"; then
7049   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5
7050 $as_echo "$FILE" >&6; }
7051 else
7052   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7053 $as_echo "no" >&6; }
7054 fi
7055 
7056 
7057         if test "x$FILE" = x; then
7058           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7059         fi
7060       else
7061         # Otherwise we believe it is a complete path. Use it as it is.
7062         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FILE=$tool_specified" >&5
7063 $as_echo "$as_me: Will use user supplied tool FILE=$tool_specified" >&6;}
7064         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5
7065 $as_echo_n "checking for FILE... " >&6; }
7066         if test ! -x "$tool_specified"; then
7067           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7068 $as_echo "not found" >&6; }
7069           as_fn_error $? "User supplied tool FILE=$tool_specified does not exist or is not executable" "$LINENO" 5
7070         fi
7071         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7072 $as_echo "$tool_specified" >&6; }
7073       fi
7074     fi
7075   fi
7076 
7077 
7078 
7079   if test "x$FILE" = x; then
7080     as_fn_error $? "Could not find required tool for FILE" "$LINENO" 5
7081   fi
7082 
7083 
7084 
7085 
7086 
7087   # Publish this variable in the help.
7088 
7089 
7090   if test "x$FIND" = x; then
7091     # The variable is not set by user, try to locate tool using the code snippet
7092     for ac_prog in find
7093 do
7094   # Extract the first word of "$ac_prog", so it can be a program name with args.
7095 set dummy $ac_prog; ac_word=$2
7096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7097 $as_echo_n "checking for $ac_word... " >&6; }
7098 if ${ac_cv_path_FIND+:} false; then :
7099   $as_echo_n "(cached) " >&6
7100 else
7101   case $FIND in
7102   [\\/]* | ?:[\\/]*)
7103   ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
7104   ;;
7105   *)
7106   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7107 for as_dir in $PATH
7108 do
7109   IFS=$as_save_IFS
7110   test -z "$as_dir" && as_dir=.
7111     for ac_exec_ext in '' $ac_executable_extensions; do
7112   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7113     ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
7114     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7115     break 2
7116   fi
7117 done
7118   done
7119 IFS=$as_save_IFS
7120 
7121   ;;
7122 esac
7123 fi
7124 FIND=$ac_cv_path_FIND
7125 if test -n "$FIND"; then
7126   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
7127 $as_echo "$FIND" >&6; }
7128 else
7129   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7130 $as_echo "no" >&6; }
7131 fi
7132 
7133 
7134   test -n "$FIND" && break
7135 done
7136 
7137   else
7138     # The variable is set, but is it from the command line or the environment?
7139 
7140     # Try to remove the string !FIND! from our list.
7141     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FIND!/}
7142     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7143       # If it failed, the variable was not from the command line. Ignore it,
7144       # but warn the user (except for BASH, which is always set by the calling BASH).
7145       if test "xFIND" != xBASH; then
7146         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&5
7147 $as_echo "$as_me: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&2;}
7148       fi
7149       # Try to locate tool using the code snippet
7150       for ac_prog in find
7151 do
7152   # Extract the first word of "$ac_prog", so it can be a program name with args.
7153 set dummy $ac_prog; ac_word=$2
7154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7155 $as_echo_n "checking for $ac_word... " >&6; }
7156 if ${ac_cv_path_FIND+:} false; then :
7157   $as_echo_n "(cached) " >&6
7158 else
7159   case $FIND in
7160   [\\/]* | ?:[\\/]*)
7161   ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
7162   ;;
7163   *)
7164   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7165 for as_dir in $PATH
7166 do
7167   IFS=$as_save_IFS
7168   test -z "$as_dir" && as_dir=.
7169     for ac_exec_ext in '' $ac_executable_extensions; do
7170   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7171     ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
7172     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7173     break 2
7174   fi
7175 done
7176   done
7177 IFS=$as_save_IFS
7178 
7179   ;;
7180 esac
7181 fi
7182 FIND=$ac_cv_path_FIND
7183 if test -n "$FIND"; then
7184   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
7185 $as_echo "$FIND" >&6; }
7186 else
7187   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7188 $as_echo "no" >&6; }
7189 fi
7190 
7191 
7192   test -n "$FIND" && break
7193 done
7194 
7195     else
7196       # If it succeeded, then it was overridden by the user. We will use it
7197       # for the tool.
7198 
7199       # First remove it from the list of overridden variables, so we can test
7200       # for unknown variables in the end.
7201       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7202 
7203       # Check if the provided tool contains a complete path.
7204       tool_specified="$FIND"
7205       tool_basename="${tool_specified##*/}"
7206       if test "x$tool_basename" = "x$tool_specified"; then
7207         # A command without a complete path is provided, search $PATH.
7208         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FIND=$tool_basename" >&5
7209 $as_echo "$as_me: Will search for user supplied tool FIND=$tool_basename" >&6;}
7210         # Extract the first word of "$tool_basename", so it can be a program name with args.
7211 set dummy $tool_basename; ac_word=$2
7212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7213 $as_echo_n "checking for $ac_word... " >&6; }
7214 if ${ac_cv_path_FIND+:} false; then :
7215   $as_echo_n "(cached) " >&6
7216 else
7217   case $FIND in
7218   [\\/]* | ?:[\\/]*)
7219   ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
7220   ;;
7221   *)
7222   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7223 for as_dir in $PATH
7224 do
7225   IFS=$as_save_IFS
7226   test -z "$as_dir" && as_dir=.
7227     for ac_exec_ext in '' $ac_executable_extensions; do
7228   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7229     ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
7230     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7231     break 2
7232   fi
7233 done
7234   done
7235 IFS=$as_save_IFS
7236 
7237   ;;
7238 esac
7239 fi
7240 FIND=$ac_cv_path_FIND
7241 if test -n "$FIND"; then
7242   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
7243 $as_echo "$FIND" >&6; }
7244 else
7245   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7246 $as_echo "no" >&6; }
7247 fi
7248 
7249 
7250         if test "x$FIND" = x; then
7251           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7252         fi
7253       else
7254         # Otherwise we believe it is a complete path. Use it as it is.
7255         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FIND=$tool_specified" >&5
7256 $as_echo "$as_me: Will use user supplied tool FIND=$tool_specified" >&6;}
7257         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5
7258 $as_echo_n "checking for FIND... " >&6; }
7259         if test ! -x "$tool_specified"; then
7260           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7261 $as_echo "not found" >&6; }
7262           as_fn_error $? "User supplied tool FIND=$tool_specified does not exist or is not executable" "$LINENO" 5
7263         fi
7264         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7265 $as_echo "$tool_specified" >&6; }
7266       fi
7267     fi
7268   fi
7269 
7270 
7271 
7272   if test "x$FIND" = x; then
7273     as_fn_error $? "Could not find required tool for FIND" "$LINENO" 5
7274   fi
7275 
7276 
7277 
7278 
7279 
7280   # Publish this variable in the help.
7281 
7282 
7283   if test "x$HEAD" = x; then
7284     # The variable is not set by user, try to locate tool using the code snippet
7285     for ac_prog in head
7286 do
7287   # Extract the first word of "$ac_prog", so it can be a program name with args.
7288 set dummy $ac_prog; ac_word=$2
7289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7290 $as_echo_n "checking for $ac_word... " >&6; }
7291 if ${ac_cv_path_HEAD+:} false; then :
7292   $as_echo_n "(cached) " >&6
7293 else
7294   case $HEAD in
7295   [\\/]* | ?:[\\/]*)
7296   ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path.
7297   ;;
7298   *)
7299   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7300 for as_dir in $PATH
7301 do
7302   IFS=$as_save_IFS
7303   test -z "$as_dir" && as_dir=.
7304     for ac_exec_ext in '' $ac_executable_extensions; do
7305   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7306     ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext"
7307     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7308     break 2
7309   fi
7310 done
7311   done
7312 IFS=$as_save_IFS
7313 
7314   ;;
7315 esac
7316 fi
7317 HEAD=$ac_cv_path_HEAD
7318 if test -n "$HEAD"; then
7319   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5
7320 $as_echo "$HEAD" >&6; }
7321 else
7322   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7323 $as_echo "no" >&6; }
7324 fi
7325 
7326 
7327   test -n "$HEAD" && break
7328 done
7329 
7330   else
7331     # The variable is set, but is it from the command line or the environment?
7332 
7333     # Try to remove the string !HEAD! from our list.
7334     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HEAD!/}
7335     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7336       # If it failed, the variable was not from the command line. Ignore it,
7337       # but warn the user (except for BASH, which is always set by the calling BASH).
7338       if test "xHEAD" != xBASH; then
7339         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&5
7340 $as_echo "$as_me: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&2;}
7341       fi
7342       # Try to locate tool using the code snippet
7343       for ac_prog in head
7344 do
7345   # Extract the first word of "$ac_prog", so it can be a program name with args.
7346 set dummy $ac_prog; ac_word=$2
7347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7348 $as_echo_n "checking for $ac_word... " >&6; }
7349 if ${ac_cv_path_HEAD+:} false; then :
7350   $as_echo_n "(cached) " >&6
7351 else
7352   case $HEAD in
7353   [\\/]* | ?:[\\/]*)
7354   ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path.
7355   ;;
7356   *)
7357   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7358 for as_dir in $PATH
7359 do
7360   IFS=$as_save_IFS
7361   test -z "$as_dir" && as_dir=.
7362     for ac_exec_ext in '' $ac_executable_extensions; do
7363   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7364     ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext"
7365     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7366     break 2
7367   fi
7368 done
7369   done
7370 IFS=$as_save_IFS
7371 
7372   ;;
7373 esac
7374 fi
7375 HEAD=$ac_cv_path_HEAD
7376 if test -n "$HEAD"; then
7377   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5
7378 $as_echo "$HEAD" >&6; }
7379 else
7380   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7381 $as_echo "no" >&6; }
7382 fi
7383 
7384 
7385   test -n "$HEAD" && break
7386 done
7387 
7388     else
7389       # If it succeeded, then it was overridden by the user. We will use it
7390       # for the tool.
7391 
7392       # First remove it from the list of overridden variables, so we can test
7393       # for unknown variables in the end.
7394       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7395 
7396       # Check if the provided tool contains a complete path.
7397       tool_specified="$HEAD"
7398       tool_basename="${tool_specified##*/}"
7399       if test "x$tool_basename" = "x$tool_specified"; then
7400         # A command without a complete path is provided, search $PATH.
7401         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HEAD=$tool_basename" >&5
7402 $as_echo "$as_me: Will search for user supplied tool HEAD=$tool_basename" >&6;}
7403         # Extract the first word of "$tool_basename", so it can be a program name with args.
7404 set dummy $tool_basename; ac_word=$2
7405 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7406 $as_echo_n "checking for $ac_word... " >&6; }
7407 if ${ac_cv_path_HEAD+:} false; then :
7408   $as_echo_n "(cached) " >&6
7409 else
7410   case $HEAD in
7411   [\\/]* | ?:[\\/]*)
7412   ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path.
7413   ;;
7414   *)
7415   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7416 for as_dir in $PATH
7417 do
7418   IFS=$as_save_IFS
7419   test -z "$as_dir" && as_dir=.
7420     for ac_exec_ext in '' $ac_executable_extensions; do
7421   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7422     ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext"
7423     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7424     break 2
7425   fi
7426 done
7427   done
7428 IFS=$as_save_IFS
7429 
7430   ;;
7431 esac
7432 fi
7433 HEAD=$ac_cv_path_HEAD
7434 if test -n "$HEAD"; then
7435   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5
7436 $as_echo "$HEAD" >&6; }
7437 else
7438   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7439 $as_echo "no" >&6; }
7440 fi
7441 
7442 
7443         if test "x$HEAD" = x; then
7444           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7445         fi
7446       else
7447         # Otherwise we believe it is a complete path. Use it as it is.
7448         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HEAD=$tool_specified" >&5
7449 $as_echo "$as_me: Will use user supplied tool HEAD=$tool_specified" >&6;}
7450         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5
7451 $as_echo_n "checking for HEAD... " >&6; }
7452         if test ! -x "$tool_specified"; then
7453           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7454 $as_echo "not found" >&6; }
7455           as_fn_error $? "User supplied tool HEAD=$tool_specified does not exist or is not executable" "$LINENO" 5
7456         fi
7457         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7458 $as_echo "$tool_specified" >&6; }
7459       fi
7460     fi
7461   fi
7462 
7463 
7464 
7465   if test "x$HEAD" = x; then
7466     as_fn_error $? "Could not find required tool for HEAD" "$LINENO" 5
7467   fi
7468 
7469 
7470 
7471 
7472 
7473   # Publish this variable in the help.
7474 
7475 
7476   if test "x$LN" = x; then
7477     # The variable is not set by user, try to locate tool using the code snippet
7478     for ac_prog in ln
7479 do
7480   # Extract the first word of "$ac_prog", so it can be a program name with args.
7481 set dummy $ac_prog; ac_word=$2
7482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7483 $as_echo_n "checking for $ac_word... " >&6; }
7484 if ${ac_cv_path_LN+:} false; then :
7485   $as_echo_n "(cached) " >&6
7486 else
7487   case $LN in
7488   [\\/]* | ?:[\\/]*)
7489   ac_cv_path_LN="$LN" # Let the user override the test with a path.
7490   ;;
7491   *)
7492   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7493 for as_dir in $PATH
7494 do
7495   IFS=$as_save_IFS
7496   test -z "$as_dir" && as_dir=.
7497     for ac_exec_ext in '' $ac_executable_extensions; do
7498   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7499     ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
7500     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7501     break 2
7502   fi
7503 done
7504   done
7505 IFS=$as_save_IFS
7506 
7507   ;;
7508 esac
7509 fi
7510 LN=$ac_cv_path_LN
7511 if test -n "$LN"; then
7512   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
7513 $as_echo "$LN" >&6; }
7514 else
7515   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7516 $as_echo "no" >&6; }
7517 fi
7518 
7519 
7520   test -n "$LN" && break
7521 done
7522 
7523   else
7524     # The variable is set, but is it from the command line or the environment?
7525 
7526     # Try to remove the string !LN! from our list.
7527     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LN!/}
7528     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7529       # If it failed, the variable was not from the command line. Ignore it,
7530       # but warn the user (except for BASH, which is always set by the calling BASH).
7531       if test "xLN" != xBASH; then
7532         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&5
7533 $as_echo "$as_me: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&2;}
7534       fi
7535       # Try to locate tool using the code snippet
7536       for ac_prog in ln
7537 do
7538   # Extract the first word of "$ac_prog", so it can be a program name with args.
7539 set dummy $ac_prog; ac_word=$2
7540 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7541 $as_echo_n "checking for $ac_word... " >&6; }
7542 if ${ac_cv_path_LN+:} false; then :
7543   $as_echo_n "(cached) " >&6
7544 else
7545   case $LN in
7546   [\\/]* | ?:[\\/]*)
7547   ac_cv_path_LN="$LN" # Let the user override the test with a path.
7548   ;;
7549   *)
7550   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7551 for as_dir in $PATH
7552 do
7553   IFS=$as_save_IFS
7554   test -z "$as_dir" && as_dir=.
7555     for ac_exec_ext in '' $ac_executable_extensions; do
7556   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7557     ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
7558     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7559     break 2
7560   fi
7561 done
7562   done
7563 IFS=$as_save_IFS
7564 
7565   ;;
7566 esac
7567 fi
7568 LN=$ac_cv_path_LN
7569 if test -n "$LN"; then
7570   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
7571 $as_echo "$LN" >&6; }
7572 else
7573   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7574 $as_echo "no" >&6; }
7575 fi
7576 
7577 
7578   test -n "$LN" && break
7579 done
7580 
7581     else
7582       # If it succeeded, then it was overridden by the user. We will use it
7583       # for the tool.
7584 
7585       # First remove it from the list of overridden variables, so we can test
7586       # for unknown variables in the end.
7587       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7588 
7589       # Check if the provided tool contains a complete path.
7590       tool_specified="$LN"
7591       tool_basename="${tool_specified##*/}"
7592       if test "x$tool_basename" = "x$tool_specified"; then
7593         # A command without a complete path is provided, search $PATH.
7594         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LN=$tool_basename" >&5
7595 $as_echo "$as_me: Will search for user supplied tool LN=$tool_basename" >&6;}
7596         # Extract the first word of "$tool_basename", so it can be a program name with args.
7597 set dummy $tool_basename; ac_word=$2
7598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7599 $as_echo_n "checking for $ac_word... " >&6; }
7600 if ${ac_cv_path_LN+:} false; then :
7601   $as_echo_n "(cached) " >&6
7602 else
7603   case $LN in
7604   [\\/]* | ?:[\\/]*)
7605   ac_cv_path_LN="$LN" # Let the user override the test with a path.
7606   ;;
7607   *)
7608   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7609 for as_dir in $PATH
7610 do
7611   IFS=$as_save_IFS
7612   test -z "$as_dir" && as_dir=.
7613     for ac_exec_ext in '' $ac_executable_extensions; do
7614   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7615     ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
7616     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7617     break 2
7618   fi
7619 done
7620   done
7621 IFS=$as_save_IFS
7622 
7623   ;;
7624 esac
7625 fi
7626 LN=$ac_cv_path_LN
7627 if test -n "$LN"; then
7628   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
7629 $as_echo "$LN" >&6; }
7630 else
7631   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7632 $as_echo "no" >&6; }
7633 fi
7634 
7635 
7636         if test "x$LN" = x; then
7637           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7638         fi
7639       else
7640         # Otherwise we believe it is a complete path. Use it as it is.
7641         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LN=$tool_specified" >&5
7642 $as_echo "$as_me: Will use user supplied tool LN=$tool_specified" >&6;}
7643         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5
7644 $as_echo_n "checking for LN... " >&6; }
7645         if test ! -x "$tool_specified"; then
7646           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7647 $as_echo "not found" >&6; }
7648           as_fn_error $? "User supplied tool LN=$tool_specified does not exist or is not executable" "$LINENO" 5
7649         fi
7650         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7651 $as_echo "$tool_specified" >&6; }
7652       fi
7653     fi
7654   fi
7655 
7656 
7657 
7658   if test "x$LN" = x; then
7659     as_fn_error $? "Could not find required tool for LN" "$LINENO" 5
7660   fi
7661 
7662 
7663 
7664 
7665 
7666   # Publish this variable in the help.
7667 
7668 
7669   if test "x$LS" = x; then
7670     # The variable is not set by user, try to locate tool using the code snippet
7671     for ac_prog in ls
7672 do
7673   # Extract the first word of "$ac_prog", so it can be a program name with args.
7674 set dummy $ac_prog; ac_word=$2
7675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7676 $as_echo_n "checking for $ac_word... " >&6; }
7677 if ${ac_cv_path_LS+:} false; then :
7678   $as_echo_n "(cached) " >&6
7679 else
7680   case $LS in
7681   [\\/]* | ?:[\\/]*)
7682   ac_cv_path_LS="$LS" # Let the user override the test with a path.
7683   ;;
7684   *)
7685   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7686 for as_dir in $PATH
7687 do
7688   IFS=$as_save_IFS
7689   test -z "$as_dir" && as_dir=.
7690     for ac_exec_ext in '' $ac_executable_extensions; do
7691   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7692     ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext"
7693     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7694     break 2
7695   fi
7696 done
7697   done
7698 IFS=$as_save_IFS
7699 
7700   ;;
7701 esac
7702 fi
7703 LS=$ac_cv_path_LS
7704 if test -n "$LS"; then
7705   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5
7706 $as_echo "$LS" >&6; }
7707 else
7708   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7709 $as_echo "no" >&6; }
7710 fi
7711 
7712 
7713   test -n "$LS" && break
7714 done
7715 
7716   else
7717     # The variable is set, but is it from the command line or the environment?
7718 
7719     # Try to remove the string !LS! from our list.
7720     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LS!/}
7721     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7722       # If it failed, the variable was not from the command line. Ignore it,
7723       # but warn the user (except for BASH, which is always set by the calling BASH).
7724       if test "xLS" != xBASH; then
7725         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&5
7726 $as_echo "$as_me: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&2;}
7727       fi
7728       # Try to locate tool using the code snippet
7729       for ac_prog in ls
7730 do
7731   # Extract the first word of "$ac_prog", so it can be a program name with args.
7732 set dummy $ac_prog; ac_word=$2
7733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7734 $as_echo_n "checking for $ac_word... " >&6; }
7735 if ${ac_cv_path_LS+:} false; then :
7736   $as_echo_n "(cached) " >&6
7737 else
7738   case $LS in
7739   [\\/]* | ?:[\\/]*)
7740   ac_cv_path_LS="$LS" # Let the user override the test with a path.
7741   ;;
7742   *)
7743   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7744 for as_dir in $PATH
7745 do
7746   IFS=$as_save_IFS
7747   test -z "$as_dir" && as_dir=.
7748     for ac_exec_ext in '' $ac_executable_extensions; do
7749   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7750     ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext"
7751     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7752     break 2
7753   fi
7754 done
7755   done
7756 IFS=$as_save_IFS
7757 
7758   ;;
7759 esac
7760 fi
7761 LS=$ac_cv_path_LS
7762 if test -n "$LS"; then
7763   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5
7764 $as_echo "$LS" >&6; }
7765 else
7766   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7767 $as_echo "no" >&6; }
7768 fi
7769 
7770 
7771   test -n "$LS" && break
7772 done
7773 
7774     else
7775       # If it succeeded, then it was overridden by the user. We will use it
7776       # for the tool.
7777 
7778       # First remove it from the list of overridden variables, so we can test
7779       # for unknown variables in the end.
7780       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7781 
7782       # Check if the provided tool contains a complete path.
7783       tool_specified="$LS"
7784       tool_basename="${tool_specified##*/}"
7785       if test "x$tool_basename" = "x$tool_specified"; then
7786         # A command without a complete path is provided, search $PATH.
7787         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LS=$tool_basename" >&5
7788 $as_echo "$as_me: Will search for user supplied tool LS=$tool_basename" >&6;}
7789         # Extract the first word of "$tool_basename", so it can be a program name with args.
7790 set dummy $tool_basename; ac_word=$2
7791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7792 $as_echo_n "checking for $ac_word... " >&6; }
7793 if ${ac_cv_path_LS+:} false; then :
7794   $as_echo_n "(cached) " >&6
7795 else
7796   case $LS in
7797   [\\/]* | ?:[\\/]*)
7798   ac_cv_path_LS="$LS" # Let the user override the test with a path.
7799   ;;
7800   *)
7801   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7802 for as_dir in $PATH
7803 do
7804   IFS=$as_save_IFS
7805   test -z "$as_dir" && as_dir=.
7806     for ac_exec_ext in '' $ac_executable_extensions; do
7807   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7808     ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext"
7809     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7810     break 2
7811   fi
7812 done
7813   done
7814 IFS=$as_save_IFS
7815 
7816   ;;
7817 esac
7818 fi
7819 LS=$ac_cv_path_LS
7820 if test -n "$LS"; then
7821   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5
7822 $as_echo "$LS" >&6; }
7823 else
7824   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7825 $as_echo "no" >&6; }
7826 fi
7827 
7828 
7829         if test "x$LS" = x; then
7830           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
7831         fi
7832       else
7833         # Otherwise we believe it is a complete path. Use it as it is.
7834         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LS=$tool_specified" >&5
7835 $as_echo "$as_me: Will use user supplied tool LS=$tool_specified" >&6;}
7836         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5
7837 $as_echo_n "checking for LS... " >&6; }
7838         if test ! -x "$tool_specified"; then
7839           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
7840 $as_echo "not found" >&6; }
7841           as_fn_error $? "User supplied tool LS=$tool_specified does not exist or is not executable" "$LINENO" 5
7842         fi
7843         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
7844 $as_echo "$tool_specified" >&6; }
7845       fi
7846     fi
7847   fi
7848 
7849 
7850 
7851   if test "x$LS" = x; then
7852     as_fn_error $? "Could not find required tool for LS" "$LINENO" 5
7853   fi
7854 
7855 
7856 
7857 
7858 
7859   # Publish this variable in the help.
7860 
7861 
7862   if test "x$MKDIR" = x; then
7863     # The variable is not set by user, try to locate tool using the code snippet
7864     for ac_prog in mkdir
7865 do
7866   # Extract the first word of "$ac_prog", so it can be a program name with args.
7867 set dummy $ac_prog; ac_word=$2
7868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7869 $as_echo_n "checking for $ac_word... " >&6; }
7870 if ${ac_cv_path_MKDIR+:} false; then :
7871   $as_echo_n "(cached) " >&6
7872 else
7873   case $MKDIR in
7874   [\\/]* | ?:[\\/]*)
7875   ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path.
7876   ;;
7877   *)
7878   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7879 for as_dir in $PATH
7880 do
7881   IFS=$as_save_IFS
7882   test -z "$as_dir" && as_dir=.
7883     for ac_exec_ext in '' $ac_executable_extensions; do
7884   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7885     ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext"
7886     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7887     break 2
7888   fi
7889 done
7890   done
7891 IFS=$as_save_IFS
7892 
7893   ;;
7894 esac
7895 fi
7896 MKDIR=$ac_cv_path_MKDIR
7897 if test -n "$MKDIR"; then
7898   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5
7899 $as_echo "$MKDIR" >&6; }
7900 else
7901   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7902 $as_echo "no" >&6; }
7903 fi
7904 
7905 
7906   test -n "$MKDIR" && break
7907 done
7908 
7909   else
7910     # The variable is set, but is it from the command line or the environment?
7911 
7912     # Try to remove the string !MKDIR! from our list.
7913     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKDIR!/}
7914     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
7915       # If it failed, the variable was not from the command line. Ignore it,
7916       # but warn the user (except for BASH, which is always set by the calling BASH).
7917       if test "xMKDIR" != xBASH; then
7918         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&5
7919 $as_echo "$as_me: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&2;}
7920       fi
7921       # Try to locate tool using the code snippet
7922       for ac_prog in mkdir
7923 do
7924   # Extract the first word of "$ac_prog", so it can be a program name with args.
7925 set dummy $ac_prog; ac_word=$2
7926 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7927 $as_echo_n "checking for $ac_word... " >&6; }
7928 if ${ac_cv_path_MKDIR+:} false; then :
7929   $as_echo_n "(cached) " >&6
7930 else
7931   case $MKDIR in
7932   [\\/]* | ?:[\\/]*)
7933   ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path.
7934   ;;
7935   *)
7936   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7937 for as_dir in $PATH
7938 do
7939   IFS=$as_save_IFS
7940   test -z "$as_dir" && as_dir=.
7941     for ac_exec_ext in '' $ac_executable_extensions; do
7942   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7943     ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext"
7944     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7945     break 2
7946   fi
7947 done
7948   done
7949 IFS=$as_save_IFS
7950 
7951   ;;
7952 esac
7953 fi
7954 MKDIR=$ac_cv_path_MKDIR
7955 if test -n "$MKDIR"; then
7956   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5
7957 $as_echo "$MKDIR" >&6; }
7958 else
7959   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7960 $as_echo "no" >&6; }
7961 fi
7962 
7963 
7964   test -n "$MKDIR" && break
7965 done
7966 
7967     else
7968       # If it succeeded, then it was overridden by the user. We will use it
7969       # for the tool.
7970 
7971       # First remove it from the list of overridden variables, so we can test
7972       # for unknown variables in the end.
7973       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
7974 
7975       # Check if the provided tool contains a complete path.
7976       tool_specified="$MKDIR"
7977       tool_basename="${tool_specified##*/}"
7978       if test "x$tool_basename" = "x$tool_specified"; then
7979         # A command without a complete path is provided, search $PATH.
7980         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKDIR=$tool_basename" >&5
7981 $as_echo "$as_me: Will search for user supplied tool MKDIR=$tool_basename" >&6;}
7982         # Extract the first word of "$tool_basename", so it can be a program name with args.
7983 set dummy $tool_basename; ac_word=$2
7984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7985 $as_echo_n "checking for $ac_word... " >&6; }
7986 if ${ac_cv_path_MKDIR+:} false; then :
7987   $as_echo_n "(cached) " >&6
7988 else
7989   case $MKDIR in
7990   [\\/]* | ?:[\\/]*)
7991   ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path.
7992   ;;
7993   *)
7994   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7995 for as_dir in $PATH
7996 do
7997   IFS=$as_save_IFS
7998   test -z "$as_dir" && as_dir=.
7999     for ac_exec_ext in '' $ac_executable_extensions; do
8000   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8001     ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext"
8002     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8003     break 2
8004   fi
8005 done
8006   done
8007 IFS=$as_save_IFS
8008 
8009   ;;
8010 esac
8011 fi
8012 MKDIR=$ac_cv_path_MKDIR
8013 if test -n "$MKDIR"; then
8014   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5
8015 $as_echo "$MKDIR" >&6; }
8016 else
8017   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8018 $as_echo "no" >&6; }
8019 fi
8020 
8021 
8022         if test "x$MKDIR" = x; then
8023           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8024         fi
8025       else
8026         # Otherwise we believe it is a complete path. Use it as it is.
8027         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKDIR=$tool_specified" >&5
8028 $as_echo "$as_me: Will use user supplied tool MKDIR=$tool_specified" >&6;}
8029         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5
8030 $as_echo_n "checking for MKDIR... " >&6; }
8031         if test ! -x "$tool_specified"; then
8032           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8033 $as_echo "not found" >&6; }
8034           as_fn_error $? "User supplied tool MKDIR=$tool_specified does not exist or is not executable" "$LINENO" 5
8035         fi
8036         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8037 $as_echo "$tool_specified" >&6; }
8038       fi
8039     fi
8040   fi
8041 
8042 
8043 
8044   if test "x$MKDIR" = x; then
8045     as_fn_error $? "Could not find required tool for MKDIR" "$LINENO" 5
8046   fi
8047 
8048 
8049 
8050 
8051 
8052   # Publish this variable in the help.
8053 
8054 
8055   if test "x$MKTEMP" = x; then
8056     # The variable is not set by user, try to locate tool using the code snippet
8057     for ac_prog in mktemp
8058 do
8059   # Extract the first word of "$ac_prog", so it can be a program name with args.
8060 set dummy $ac_prog; ac_word=$2
8061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8062 $as_echo_n "checking for $ac_word... " >&6; }
8063 if ${ac_cv_path_MKTEMP+:} false; then :
8064   $as_echo_n "(cached) " >&6
8065 else
8066   case $MKTEMP in
8067   [\\/]* | ?:[\\/]*)
8068   ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path.
8069   ;;
8070   *)
8071   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8072 for as_dir in $PATH
8073 do
8074   IFS=$as_save_IFS
8075   test -z "$as_dir" && as_dir=.
8076     for ac_exec_ext in '' $ac_executable_extensions; do
8077   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8078     ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext"
8079     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8080     break 2
8081   fi
8082 done
8083   done
8084 IFS=$as_save_IFS
8085 
8086   ;;
8087 esac
8088 fi
8089 MKTEMP=$ac_cv_path_MKTEMP
8090 if test -n "$MKTEMP"; then
8091   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5
8092 $as_echo "$MKTEMP" >&6; }
8093 else
8094   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8095 $as_echo "no" >&6; }
8096 fi
8097 
8098 
8099   test -n "$MKTEMP" && break
8100 done
8101 
8102   else
8103     # The variable is set, but is it from the command line or the environment?
8104 
8105     # Try to remove the string !MKTEMP! from our list.
8106     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKTEMP!/}
8107     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8108       # If it failed, the variable was not from the command line. Ignore it,
8109       # but warn the user (except for BASH, which is always set by the calling BASH).
8110       if test "xMKTEMP" != xBASH; then
8111         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&5
8112 $as_echo "$as_me: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&2;}
8113       fi
8114       # Try to locate tool using the code snippet
8115       for ac_prog in mktemp
8116 do
8117   # Extract the first word of "$ac_prog", so it can be a program name with args.
8118 set dummy $ac_prog; ac_word=$2
8119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8120 $as_echo_n "checking for $ac_word... " >&6; }
8121 if ${ac_cv_path_MKTEMP+:} false; then :
8122   $as_echo_n "(cached) " >&6
8123 else
8124   case $MKTEMP in
8125   [\\/]* | ?:[\\/]*)
8126   ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path.
8127   ;;
8128   *)
8129   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8130 for as_dir in $PATH
8131 do
8132   IFS=$as_save_IFS
8133   test -z "$as_dir" && as_dir=.
8134     for ac_exec_ext in '' $ac_executable_extensions; do
8135   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8136     ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext"
8137     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8138     break 2
8139   fi
8140 done
8141   done
8142 IFS=$as_save_IFS
8143 
8144   ;;
8145 esac
8146 fi
8147 MKTEMP=$ac_cv_path_MKTEMP
8148 if test -n "$MKTEMP"; then
8149   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5
8150 $as_echo "$MKTEMP" >&6; }
8151 else
8152   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8153 $as_echo "no" >&6; }
8154 fi
8155 
8156 
8157   test -n "$MKTEMP" && break
8158 done
8159 
8160     else
8161       # If it succeeded, then it was overridden by the user. We will use it
8162       # for the tool.
8163 
8164       # First remove it from the list of overridden variables, so we can test
8165       # for unknown variables in the end.
8166       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8167 
8168       # Check if the provided tool contains a complete path.
8169       tool_specified="$MKTEMP"
8170       tool_basename="${tool_specified##*/}"
8171       if test "x$tool_basename" = "x$tool_specified"; then
8172         # A command without a complete path is provided, search $PATH.
8173         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKTEMP=$tool_basename" >&5
8174 $as_echo "$as_me: Will search for user supplied tool MKTEMP=$tool_basename" >&6;}
8175         # Extract the first word of "$tool_basename", so it can be a program name with args.
8176 set dummy $tool_basename; ac_word=$2
8177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8178 $as_echo_n "checking for $ac_word... " >&6; }
8179 if ${ac_cv_path_MKTEMP+:} false; then :
8180   $as_echo_n "(cached) " >&6
8181 else
8182   case $MKTEMP in
8183   [\\/]* | ?:[\\/]*)
8184   ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path.
8185   ;;
8186   *)
8187   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8188 for as_dir in $PATH
8189 do
8190   IFS=$as_save_IFS
8191   test -z "$as_dir" && as_dir=.
8192     for ac_exec_ext in '' $ac_executable_extensions; do
8193   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8194     ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext"
8195     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8196     break 2
8197   fi
8198 done
8199   done
8200 IFS=$as_save_IFS
8201 
8202   ;;
8203 esac
8204 fi
8205 MKTEMP=$ac_cv_path_MKTEMP
8206 if test -n "$MKTEMP"; then
8207   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5
8208 $as_echo "$MKTEMP" >&6; }
8209 else
8210   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8211 $as_echo "no" >&6; }
8212 fi
8213 
8214 
8215         if test "x$MKTEMP" = x; then
8216           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8217         fi
8218       else
8219         # Otherwise we believe it is a complete path. Use it as it is.
8220         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKTEMP=$tool_specified" >&5
8221 $as_echo "$as_me: Will use user supplied tool MKTEMP=$tool_specified" >&6;}
8222         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5
8223 $as_echo_n "checking for MKTEMP... " >&6; }
8224         if test ! -x "$tool_specified"; then
8225           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8226 $as_echo "not found" >&6; }
8227           as_fn_error $? "User supplied tool MKTEMP=$tool_specified does not exist or is not executable" "$LINENO" 5
8228         fi
8229         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8230 $as_echo "$tool_specified" >&6; }
8231       fi
8232     fi
8233   fi
8234 
8235 
8236 
8237   if test "x$MKTEMP" = x; then
8238     as_fn_error $? "Could not find required tool for MKTEMP" "$LINENO" 5
8239   fi
8240 
8241 
8242 
8243 
8244 
8245   # Publish this variable in the help.
8246 
8247 
8248   if test "x$MV" = x; then
8249     # The variable is not set by user, try to locate tool using the code snippet
8250     for ac_prog in mv
8251 do
8252   # Extract the first word of "$ac_prog", so it can be a program name with args.
8253 set dummy $ac_prog; ac_word=$2
8254 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8255 $as_echo_n "checking for $ac_word... " >&6; }
8256 if ${ac_cv_path_MV+:} false; then :
8257   $as_echo_n "(cached) " >&6
8258 else
8259   case $MV in
8260   [\\/]* | ?:[\\/]*)
8261   ac_cv_path_MV="$MV" # Let the user override the test with a path.
8262   ;;
8263   *)
8264   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8265 for as_dir in $PATH
8266 do
8267   IFS=$as_save_IFS
8268   test -z "$as_dir" && as_dir=.
8269     for ac_exec_ext in '' $ac_executable_extensions; do
8270   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8271     ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext"
8272     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8273     break 2
8274   fi
8275 done
8276   done
8277 IFS=$as_save_IFS
8278 
8279   ;;
8280 esac
8281 fi
8282 MV=$ac_cv_path_MV
8283 if test -n "$MV"; then
8284   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5
8285 $as_echo "$MV" >&6; }
8286 else
8287   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8288 $as_echo "no" >&6; }
8289 fi
8290 
8291 
8292   test -n "$MV" && break
8293 done
8294 
8295   else
8296     # The variable is set, but is it from the command line or the environment?
8297 
8298     # Try to remove the string !MV! from our list.
8299     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MV!/}
8300     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8301       # If it failed, the variable was not from the command line. Ignore it,
8302       # but warn the user (except for BASH, which is always set by the calling BASH).
8303       if test "xMV" != xBASH; then
8304         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&5
8305 $as_echo "$as_me: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&2;}
8306       fi
8307       # Try to locate tool using the code snippet
8308       for ac_prog in mv
8309 do
8310   # Extract the first word of "$ac_prog", so it can be a program name with args.
8311 set dummy $ac_prog; ac_word=$2
8312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8313 $as_echo_n "checking for $ac_word... " >&6; }
8314 if ${ac_cv_path_MV+:} false; then :
8315   $as_echo_n "(cached) " >&6
8316 else
8317   case $MV in
8318   [\\/]* | ?:[\\/]*)
8319   ac_cv_path_MV="$MV" # Let the user override the test with a path.
8320   ;;
8321   *)
8322   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8323 for as_dir in $PATH
8324 do
8325   IFS=$as_save_IFS
8326   test -z "$as_dir" && as_dir=.
8327     for ac_exec_ext in '' $ac_executable_extensions; do
8328   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8329     ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext"
8330     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8331     break 2
8332   fi
8333 done
8334   done
8335 IFS=$as_save_IFS
8336 
8337   ;;
8338 esac
8339 fi
8340 MV=$ac_cv_path_MV
8341 if test -n "$MV"; then
8342   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5
8343 $as_echo "$MV" >&6; }
8344 else
8345   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8346 $as_echo "no" >&6; }
8347 fi
8348 
8349 
8350   test -n "$MV" && break
8351 done
8352 
8353     else
8354       # If it succeeded, then it was overridden by the user. We will use it
8355       # for the tool.
8356 
8357       # First remove it from the list of overridden variables, so we can test
8358       # for unknown variables in the end.
8359       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8360 
8361       # Check if the provided tool contains a complete path.
8362       tool_specified="$MV"
8363       tool_basename="${tool_specified##*/}"
8364       if test "x$tool_basename" = "x$tool_specified"; then
8365         # A command without a complete path is provided, search $PATH.
8366         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MV=$tool_basename" >&5
8367 $as_echo "$as_me: Will search for user supplied tool MV=$tool_basename" >&6;}
8368         # Extract the first word of "$tool_basename", so it can be a program name with args.
8369 set dummy $tool_basename; ac_word=$2
8370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8371 $as_echo_n "checking for $ac_word... " >&6; }
8372 if ${ac_cv_path_MV+:} false; then :
8373   $as_echo_n "(cached) " >&6
8374 else
8375   case $MV in
8376   [\\/]* | ?:[\\/]*)
8377   ac_cv_path_MV="$MV" # Let the user override the test with a path.
8378   ;;
8379   *)
8380   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8381 for as_dir in $PATH
8382 do
8383   IFS=$as_save_IFS
8384   test -z "$as_dir" && as_dir=.
8385     for ac_exec_ext in '' $ac_executable_extensions; do
8386   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8387     ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext"
8388     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8389     break 2
8390   fi
8391 done
8392   done
8393 IFS=$as_save_IFS
8394 
8395   ;;
8396 esac
8397 fi
8398 MV=$ac_cv_path_MV
8399 if test -n "$MV"; then
8400   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5
8401 $as_echo "$MV" >&6; }
8402 else
8403   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8404 $as_echo "no" >&6; }
8405 fi
8406 
8407 
8408         if test "x$MV" = x; then
8409           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8410         fi
8411       else
8412         # Otherwise we believe it is a complete path. Use it as it is.
8413         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MV=$tool_specified" >&5
8414 $as_echo "$as_me: Will use user supplied tool MV=$tool_specified" >&6;}
8415         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5
8416 $as_echo_n "checking for MV... " >&6; }
8417         if test ! -x "$tool_specified"; then
8418           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8419 $as_echo "not found" >&6; }
8420           as_fn_error $? "User supplied tool MV=$tool_specified does not exist or is not executable" "$LINENO" 5
8421         fi
8422         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8423 $as_echo "$tool_specified" >&6; }
8424       fi
8425     fi
8426   fi
8427 
8428 
8429 
8430   if test "x$MV" = x; then
8431     as_fn_error $? "Could not find required tool for MV" "$LINENO" 5
8432   fi
8433 
8434 
8435 
8436 
8437 
8438   # Publish this variable in the help.
8439 
8440 
8441   if test "x$NAWK" = x; then
8442     # The variable is not set by user, try to locate tool using the code snippet
8443     for ac_prog in nawk gawk awk
8444 do
8445   # Extract the first word of "$ac_prog", so it can be a program name with args.
8446 set dummy $ac_prog; ac_word=$2
8447 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8448 $as_echo_n "checking for $ac_word... " >&6; }
8449 if ${ac_cv_path_NAWK+:} false; then :
8450   $as_echo_n "(cached) " >&6
8451 else
8452   case $NAWK in
8453   [\\/]* | ?:[\\/]*)
8454   ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path.
8455   ;;
8456   *)
8457   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8458 for as_dir in $PATH
8459 do
8460   IFS=$as_save_IFS
8461   test -z "$as_dir" && as_dir=.
8462     for ac_exec_ext in '' $ac_executable_extensions; do
8463   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8464     ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext"
8465     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8466     break 2
8467   fi
8468 done
8469   done
8470 IFS=$as_save_IFS
8471 
8472   ;;
8473 esac
8474 fi
8475 NAWK=$ac_cv_path_NAWK
8476 if test -n "$NAWK"; then
8477   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5
8478 $as_echo "$NAWK" >&6; }
8479 else
8480   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8481 $as_echo "no" >&6; }
8482 fi
8483 
8484 
8485   test -n "$NAWK" && break
8486 done
8487 
8488   else
8489     # The variable is set, but is it from the command line or the environment?
8490 
8491     # Try to remove the string !NAWK! from our list.
8492     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NAWK!/}
8493     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8494       # If it failed, the variable was not from the command line. Ignore it,
8495       # but warn the user (except for BASH, which is always set by the calling BASH).
8496       if test "xNAWK" != xBASH; then
8497         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&5
8498 $as_echo "$as_me: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&2;}
8499       fi
8500       # Try to locate tool using the code snippet
8501       for ac_prog in nawk gawk awk
8502 do
8503   # Extract the first word of "$ac_prog", so it can be a program name with args.
8504 set dummy $ac_prog; ac_word=$2
8505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8506 $as_echo_n "checking for $ac_word... " >&6; }
8507 if ${ac_cv_path_NAWK+:} false; then :
8508   $as_echo_n "(cached) " >&6
8509 else
8510   case $NAWK in
8511   [\\/]* | ?:[\\/]*)
8512   ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path.
8513   ;;
8514   *)
8515   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8516 for as_dir in $PATH
8517 do
8518   IFS=$as_save_IFS
8519   test -z "$as_dir" && as_dir=.
8520     for ac_exec_ext in '' $ac_executable_extensions; do
8521   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8522     ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext"
8523     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8524     break 2
8525   fi
8526 done
8527   done
8528 IFS=$as_save_IFS
8529 
8530   ;;
8531 esac
8532 fi
8533 NAWK=$ac_cv_path_NAWK
8534 if test -n "$NAWK"; then
8535   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5
8536 $as_echo "$NAWK" >&6; }
8537 else
8538   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8539 $as_echo "no" >&6; }
8540 fi
8541 
8542 
8543   test -n "$NAWK" && break
8544 done
8545 
8546     else
8547       # If it succeeded, then it was overridden by the user. We will use it
8548       # for the tool.
8549 
8550       # First remove it from the list of overridden variables, so we can test
8551       # for unknown variables in the end.
8552       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8553 
8554       # Check if the provided tool contains a complete path.
8555       tool_specified="$NAWK"
8556       tool_basename="${tool_specified##*/}"
8557       if test "x$tool_basename" = "x$tool_specified"; then
8558         # A command without a complete path is provided, search $PATH.
8559         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NAWK=$tool_basename" >&5
8560 $as_echo "$as_me: Will search for user supplied tool NAWK=$tool_basename" >&6;}
8561         # Extract the first word of "$tool_basename", so it can be a program name with args.
8562 set dummy $tool_basename; ac_word=$2
8563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8564 $as_echo_n "checking for $ac_word... " >&6; }
8565 if ${ac_cv_path_NAWK+:} false; then :
8566   $as_echo_n "(cached) " >&6
8567 else
8568   case $NAWK in
8569   [\\/]* | ?:[\\/]*)
8570   ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path.
8571   ;;
8572   *)
8573   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8574 for as_dir in $PATH
8575 do
8576   IFS=$as_save_IFS
8577   test -z "$as_dir" && as_dir=.
8578     for ac_exec_ext in '' $ac_executable_extensions; do
8579   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8580     ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext"
8581     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8582     break 2
8583   fi
8584 done
8585   done
8586 IFS=$as_save_IFS
8587 
8588   ;;
8589 esac
8590 fi
8591 NAWK=$ac_cv_path_NAWK
8592 if test -n "$NAWK"; then
8593   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5
8594 $as_echo "$NAWK" >&6; }
8595 else
8596   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8597 $as_echo "no" >&6; }
8598 fi
8599 
8600 
8601         if test "x$NAWK" = x; then
8602           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8603         fi
8604       else
8605         # Otherwise we believe it is a complete path. Use it as it is.
8606         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NAWK=$tool_specified" >&5
8607 $as_echo "$as_me: Will use user supplied tool NAWK=$tool_specified" >&6;}
8608         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5
8609 $as_echo_n "checking for NAWK... " >&6; }
8610         if test ! -x "$tool_specified"; then
8611           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8612 $as_echo "not found" >&6; }
8613           as_fn_error $? "User supplied tool NAWK=$tool_specified does not exist or is not executable" "$LINENO" 5
8614         fi
8615         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8616 $as_echo "$tool_specified" >&6; }
8617       fi
8618     fi
8619   fi
8620 
8621 
8622 
8623   if test "x$NAWK" = x; then
8624     as_fn_error $? "Could not find required tool for NAWK" "$LINENO" 5
8625   fi
8626 
8627 
8628 
8629 
8630 
8631   # Publish this variable in the help.
8632 
8633 
8634   if test "x$PRINTF" = x; then
8635     # The variable is not set by user, try to locate tool using the code snippet
8636     for ac_prog in printf
8637 do
8638   # Extract the first word of "$ac_prog", so it can be a program name with args.
8639 set dummy $ac_prog; ac_word=$2
8640 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8641 $as_echo_n "checking for $ac_word... " >&6; }
8642 if ${ac_cv_path_PRINTF+:} false; then :
8643   $as_echo_n "(cached) " >&6
8644 else
8645   case $PRINTF in
8646   [\\/]* | ?:[\\/]*)
8647   ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path.
8648   ;;
8649   *)
8650   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8651 for as_dir in $PATH
8652 do
8653   IFS=$as_save_IFS
8654   test -z "$as_dir" && as_dir=.
8655     for ac_exec_ext in '' $ac_executable_extensions; do
8656   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8657     ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext"
8658     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8659     break 2
8660   fi
8661 done
8662   done
8663 IFS=$as_save_IFS
8664 
8665   ;;
8666 esac
8667 fi
8668 PRINTF=$ac_cv_path_PRINTF
8669 if test -n "$PRINTF"; then
8670   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5
8671 $as_echo "$PRINTF" >&6; }
8672 else
8673   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8674 $as_echo "no" >&6; }
8675 fi
8676 
8677 
8678   test -n "$PRINTF" && break
8679 done
8680 
8681   else
8682     # The variable is set, but is it from the command line or the environment?
8683 
8684     # Try to remove the string !PRINTF! from our list.
8685     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PRINTF!/}
8686     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8687       # If it failed, the variable was not from the command line. Ignore it,
8688       # but warn the user (except for BASH, which is always set by the calling BASH).
8689       if test "xPRINTF" != xBASH; then
8690         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&5
8691 $as_echo "$as_me: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&2;}
8692       fi
8693       # Try to locate tool using the code snippet
8694       for ac_prog in printf
8695 do
8696   # Extract the first word of "$ac_prog", so it can be a program name with args.
8697 set dummy $ac_prog; ac_word=$2
8698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8699 $as_echo_n "checking for $ac_word... " >&6; }
8700 if ${ac_cv_path_PRINTF+:} false; then :
8701   $as_echo_n "(cached) " >&6
8702 else
8703   case $PRINTF in
8704   [\\/]* | ?:[\\/]*)
8705   ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path.
8706   ;;
8707   *)
8708   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8709 for as_dir in $PATH
8710 do
8711   IFS=$as_save_IFS
8712   test -z "$as_dir" && as_dir=.
8713     for ac_exec_ext in '' $ac_executable_extensions; do
8714   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8715     ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext"
8716     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8717     break 2
8718   fi
8719 done
8720   done
8721 IFS=$as_save_IFS
8722 
8723   ;;
8724 esac
8725 fi
8726 PRINTF=$ac_cv_path_PRINTF
8727 if test -n "$PRINTF"; then
8728   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5
8729 $as_echo "$PRINTF" >&6; }
8730 else
8731   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8732 $as_echo "no" >&6; }
8733 fi
8734 
8735 
8736   test -n "$PRINTF" && break
8737 done
8738 
8739     else
8740       # If it succeeded, then it was overridden by the user. We will use it
8741       # for the tool.
8742 
8743       # First remove it from the list of overridden variables, so we can test
8744       # for unknown variables in the end.
8745       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8746 
8747       # Check if the provided tool contains a complete path.
8748       tool_specified="$PRINTF"
8749       tool_basename="${tool_specified##*/}"
8750       if test "x$tool_basename" = "x$tool_specified"; then
8751         # A command without a complete path is provided, search $PATH.
8752         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PRINTF=$tool_basename" >&5
8753 $as_echo "$as_me: Will search for user supplied tool PRINTF=$tool_basename" >&6;}
8754         # Extract the first word of "$tool_basename", so it can be a program name with args.
8755 set dummy $tool_basename; ac_word=$2
8756 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8757 $as_echo_n "checking for $ac_word... " >&6; }
8758 if ${ac_cv_path_PRINTF+:} false; then :
8759   $as_echo_n "(cached) " >&6
8760 else
8761   case $PRINTF in
8762   [\\/]* | ?:[\\/]*)
8763   ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path.
8764   ;;
8765   *)
8766   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8767 for as_dir in $PATH
8768 do
8769   IFS=$as_save_IFS
8770   test -z "$as_dir" && as_dir=.
8771     for ac_exec_ext in '' $ac_executable_extensions; do
8772   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8773     ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext"
8774     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8775     break 2
8776   fi
8777 done
8778   done
8779 IFS=$as_save_IFS
8780 
8781   ;;
8782 esac
8783 fi
8784 PRINTF=$ac_cv_path_PRINTF
8785 if test -n "$PRINTF"; then
8786   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5
8787 $as_echo "$PRINTF" >&6; }
8788 else
8789   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8790 $as_echo "no" >&6; }
8791 fi
8792 
8793 
8794         if test "x$PRINTF" = x; then
8795           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8796         fi
8797       else
8798         # Otherwise we believe it is a complete path. Use it as it is.
8799         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PRINTF=$tool_specified" >&5
8800 $as_echo "$as_me: Will use user supplied tool PRINTF=$tool_specified" >&6;}
8801         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5
8802 $as_echo_n "checking for PRINTF... " >&6; }
8803         if test ! -x "$tool_specified"; then
8804           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8805 $as_echo "not found" >&6; }
8806           as_fn_error $? "User supplied tool PRINTF=$tool_specified does not exist or is not executable" "$LINENO" 5
8807         fi
8808         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
8809 $as_echo "$tool_specified" >&6; }
8810       fi
8811     fi
8812   fi
8813 
8814 
8815 
8816   if test "x$PRINTF" = x; then
8817     as_fn_error $? "Could not find required tool for PRINTF" "$LINENO" 5
8818   fi
8819 
8820 
8821 
8822 
8823 
8824   # Publish this variable in the help.
8825 
8826 
8827   if test "x$RM" = x; then
8828     # The variable is not set by user, try to locate tool using the code snippet
8829     for ac_prog in rm
8830 do
8831   # Extract the first word of "$ac_prog", so it can be a program name with args.
8832 set dummy $ac_prog; ac_word=$2
8833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8834 $as_echo_n "checking for $ac_word... " >&6; }
8835 if ${ac_cv_path_RM+:} false; then :
8836   $as_echo_n "(cached) " >&6
8837 else
8838   case $RM in
8839   [\\/]* | ?:[\\/]*)
8840   ac_cv_path_RM="$RM" # Let the user override the test with a path.
8841   ;;
8842   *)
8843   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8844 for as_dir in $PATH
8845 do
8846   IFS=$as_save_IFS
8847   test -z "$as_dir" && as_dir=.
8848     for ac_exec_ext in '' $ac_executable_extensions; do
8849   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8850     ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext"
8851     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8852     break 2
8853   fi
8854 done
8855   done
8856 IFS=$as_save_IFS
8857 
8858   ;;
8859 esac
8860 fi
8861 RM=$ac_cv_path_RM
8862 if test -n "$RM"; then
8863   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5
8864 $as_echo "$RM" >&6; }
8865 else
8866   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8867 $as_echo "no" >&6; }
8868 fi
8869 
8870 
8871   test -n "$RM" && break
8872 done
8873 
8874   else
8875     # The variable is set, but is it from the command line or the environment?
8876 
8877     # Try to remove the string !RM! from our list.
8878     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RM!/}
8879     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
8880       # If it failed, the variable was not from the command line. Ignore it,
8881       # but warn the user (except for BASH, which is always set by the calling BASH).
8882       if test "xRM" != xBASH; then
8883         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&5
8884 $as_echo "$as_me: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&2;}
8885       fi
8886       # Try to locate tool using the code snippet
8887       for ac_prog in rm
8888 do
8889   # Extract the first word of "$ac_prog", so it can be a program name with args.
8890 set dummy $ac_prog; ac_word=$2
8891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8892 $as_echo_n "checking for $ac_word... " >&6; }
8893 if ${ac_cv_path_RM+:} false; then :
8894   $as_echo_n "(cached) " >&6
8895 else
8896   case $RM in
8897   [\\/]* | ?:[\\/]*)
8898   ac_cv_path_RM="$RM" # Let the user override the test with a path.
8899   ;;
8900   *)
8901   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8902 for as_dir in $PATH
8903 do
8904   IFS=$as_save_IFS
8905   test -z "$as_dir" && as_dir=.
8906     for ac_exec_ext in '' $ac_executable_extensions; do
8907   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8908     ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext"
8909     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8910     break 2
8911   fi
8912 done
8913   done
8914 IFS=$as_save_IFS
8915 
8916   ;;
8917 esac
8918 fi
8919 RM=$ac_cv_path_RM
8920 if test -n "$RM"; then
8921   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5
8922 $as_echo "$RM" >&6; }
8923 else
8924   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8925 $as_echo "no" >&6; }
8926 fi
8927 
8928 
8929   test -n "$RM" && break
8930 done
8931 
8932     else
8933       # If it succeeded, then it was overridden by the user. We will use it
8934       # for the tool.
8935 
8936       # First remove it from the list of overridden variables, so we can test
8937       # for unknown variables in the end.
8938       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
8939 
8940       # Check if the provided tool contains a complete path.
8941       tool_specified="$RM"
8942       tool_basename="${tool_specified##*/}"
8943       if test "x$tool_basename" = "x$tool_specified"; then
8944         # A command without a complete path is provided, search $PATH.
8945         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RM=$tool_basename" >&5
8946 $as_echo "$as_me: Will search for user supplied tool RM=$tool_basename" >&6;}
8947         # Extract the first word of "$tool_basename", so it can be a program name with args.
8948 set dummy $tool_basename; ac_word=$2
8949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8950 $as_echo_n "checking for $ac_word... " >&6; }
8951 if ${ac_cv_path_RM+:} false; then :
8952   $as_echo_n "(cached) " >&6
8953 else
8954   case $RM in
8955   [\\/]* | ?:[\\/]*)
8956   ac_cv_path_RM="$RM" # Let the user override the test with a path.
8957   ;;
8958   *)
8959   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8960 for as_dir in $PATH
8961 do
8962   IFS=$as_save_IFS
8963   test -z "$as_dir" && as_dir=.
8964     for ac_exec_ext in '' $ac_executable_extensions; do
8965   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8966     ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext"
8967     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8968     break 2
8969   fi
8970 done
8971   done
8972 IFS=$as_save_IFS
8973 
8974   ;;
8975 esac
8976 fi
8977 RM=$ac_cv_path_RM
8978 if test -n "$RM"; then
8979   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5
8980 $as_echo "$RM" >&6; }
8981 else
8982   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8983 $as_echo "no" >&6; }
8984 fi
8985 
8986 
8987         if test "x$RM" = x; then
8988           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
8989         fi
8990       else
8991         # Otherwise we believe it is a complete path. Use it as it is.
8992         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RM=$tool_specified" >&5
8993 $as_echo "$as_me: Will use user supplied tool RM=$tool_specified" >&6;}
8994         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5
8995 $as_echo_n "checking for RM... " >&6; }
8996         if test ! -x "$tool_specified"; then
8997           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
8998 $as_echo "not found" >&6; }
8999           as_fn_error $? "User supplied tool RM=$tool_specified does not exist or is not executable" "$LINENO" 5
9000         fi
9001         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9002 $as_echo "$tool_specified" >&6; }
9003       fi
9004     fi
9005   fi
9006 
9007 
9008 
9009   if test "x$RM" = x; then
9010     as_fn_error $? "Could not find required tool for RM" "$LINENO" 5
9011   fi
9012 
9013 
9014 
9015 
9016 
9017   # Publish this variable in the help.
9018 
9019 
9020   if test "x$SH" = x; then
9021     # The variable is not set by user, try to locate tool using the code snippet
9022     for ac_prog in sh
9023 do
9024   # Extract the first word of "$ac_prog", so it can be a program name with args.
9025 set dummy $ac_prog; ac_word=$2
9026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9027 $as_echo_n "checking for $ac_word... " >&6; }
9028 if ${ac_cv_path_SH+:} false; then :
9029   $as_echo_n "(cached) " >&6
9030 else
9031   case $SH in
9032   [\\/]* | ?:[\\/]*)
9033   ac_cv_path_SH="$SH" # Let the user override the test with a path.
9034   ;;
9035   *)
9036   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9037 for as_dir in $PATH
9038 do
9039   IFS=$as_save_IFS
9040   test -z "$as_dir" && as_dir=.
9041     for ac_exec_ext in '' $ac_executable_extensions; do
9042   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9043     ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
9044     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9045     break 2
9046   fi
9047 done
9048   done
9049 IFS=$as_save_IFS
9050 
9051   ;;
9052 esac
9053 fi
9054 SH=$ac_cv_path_SH
9055 if test -n "$SH"; then
9056   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5
9057 $as_echo "$SH" >&6; }
9058 else
9059   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9060 $as_echo "no" >&6; }
9061 fi
9062 
9063 
9064   test -n "$SH" && break
9065 done
9066 
9067   else
9068     # The variable is set, but is it from the command line or the environment?
9069 
9070     # Try to remove the string !SH! from our list.
9071     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SH!/}
9072     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9073       # If it failed, the variable was not from the command line. Ignore it,
9074       # but warn the user (except for BASH, which is always set by the calling BASH).
9075       if test "xSH" != xBASH; then
9076         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&5
9077 $as_echo "$as_me: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&2;}
9078       fi
9079       # Try to locate tool using the code snippet
9080       for ac_prog in sh
9081 do
9082   # Extract the first word of "$ac_prog", so it can be a program name with args.
9083 set dummy $ac_prog; ac_word=$2
9084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9085 $as_echo_n "checking for $ac_word... " >&6; }
9086 if ${ac_cv_path_SH+:} false; then :
9087   $as_echo_n "(cached) " >&6
9088 else
9089   case $SH in
9090   [\\/]* | ?:[\\/]*)
9091   ac_cv_path_SH="$SH" # Let the user override the test with a path.
9092   ;;
9093   *)
9094   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9095 for as_dir in $PATH
9096 do
9097   IFS=$as_save_IFS
9098   test -z "$as_dir" && as_dir=.
9099     for ac_exec_ext in '' $ac_executable_extensions; do
9100   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9101     ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
9102     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9103     break 2
9104   fi
9105 done
9106   done
9107 IFS=$as_save_IFS
9108 
9109   ;;
9110 esac
9111 fi
9112 SH=$ac_cv_path_SH
9113 if test -n "$SH"; then
9114   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5
9115 $as_echo "$SH" >&6; }
9116 else
9117   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9118 $as_echo "no" >&6; }
9119 fi
9120 
9121 
9122   test -n "$SH" && break
9123 done
9124 
9125     else
9126       # If it succeeded, then it was overridden by the user. We will use it
9127       # for the tool.
9128 
9129       # First remove it from the list of overridden variables, so we can test
9130       # for unknown variables in the end.
9131       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9132 
9133       # Check if the provided tool contains a complete path.
9134       tool_specified="$SH"
9135       tool_basename="${tool_specified##*/}"
9136       if test "x$tool_basename" = "x$tool_specified"; then
9137         # A command without a complete path is provided, search $PATH.
9138         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SH=$tool_basename" >&5
9139 $as_echo "$as_me: Will search for user supplied tool SH=$tool_basename" >&6;}
9140         # Extract the first word of "$tool_basename", so it can be a program name with args.
9141 set dummy $tool_basename; ac_word=$2
9142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9143 $as_echo_n "checking for $ac_word... " >&6; }
9144 if ${ac_cv_path_SH+:} false; then :
9145   $as_echo_n "(cached) " >&6
9146 else
9147   case $SH in
9148   [\\/]* | ?:[\\/]*)
9149   ac_cv_path_SH="$SH" # Let the user override the test with a path.
9150   ;;
9151   *)
9152   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9153 for as_dir in $PATH
9154 do
9155   IFS=$as_save_IFS
9156   test -z "$as_dir" && as_dir=.
9157     for ac_exec_ext in '' $ac_executable_extensions; do
9158   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9159     ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
9160     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9161     break 2
9162   fi
9163 done
9164   done
9165 IFS=$as_save_IFS
9166 
9167   ;;
9168 esac
9169 fi
9170 SH=$ac_cv_path_SH
9171 if test -n "$SH"; then
9172   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5
9173 $as_echo "$SH" >&6; }
9174 else
9175   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9176 $as_echo "no" >&6; }
9177 fi
9178 
9179 
9180         if test "x$SH" = x; then
9181           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9182         fi
9183       else
9184         # Otherwise we believe it is a complete path. Use it as it is.
9185         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SH=$tool_specified" >&5
9186 $as_echo "$as_me: Will use user supplied tool SH=$tool_specified" >&6;}
9187         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5
9188 $as_echo_n "checking for SH... " >&6; }
9189         if test ! -x "$tool_specified"; then
9190           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9191 $as_echo "not found" >&6; }
9192           as_fn_error $? "User supplied tool SH=$tool_specified does not exist or is not executable" "$LINENO" 5
9193         fi
9194         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9195 $as_echo "$tool_specified" >&6; }
9196       fi
9197     fi
9198   fi
9199 
9200 
9201 
9202   if test "x$SH" = x; then
9203     as_fn_error $? "Could not find required tool for SH" "$LINENO" 5
9204   fi
9205 
9206 
9207 
9208 
9209 
9210   # Publish this variable in the help.
9211 
9212 
9213   if test "x$SORT" = x; then
9214     # The variable is not set by user, try to locate tool using the code snippet
9215     for ac_prog in sort
9216 do
9217   # Extract the first word of "$ac_prog", so it can be a program name with args.
9218 set dummy $ac_prog; ac_word=$2
9219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9220 $as_echo_n "checking for $ac_word... " >&6; }
9221 if ${ac_cv_path_SORT+:} false; then :
9222   $as_echo_n "(cached) " >&6
9223 else
9224   case $SORT in
9225   [\\/]* | ?:[\\/]*)
9226   ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
9227   ;;
9228   *)
9229   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9230 for as_dir in $PATH
9231 do
9232   IFS=$as_save_IFS
9233   test -z "$as_dir" && as_dir=.
9234     for ac_exec_ext in '' $ac_executable_extensions; do
9235   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9236     ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext"
9237     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9238     break 2
9239   fi
9240 done
9241   done
9242 IFS=$as_save_IFS
9243 
9244   ;;
9245 esac
9246 fi
9247 SORT=$ac_cv_path_SORT
9248 if test -n "$SORT"; then
9249   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5
9250 $as_echo "$SORT" >&6; }
9251 else
9252   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9253 $as_echo "no" >&6; }
9254 fi
9255 
9256 
9257   test -n "$SORT" && break
9258 done
9259 
9260   else
9261     # The variable is set, but is it from the command line or the environment?
9262 
9263     # Try to remove the string !SORT! from our list.
9264     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SORT!/}
9265     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9266       # If it failed, the variable was not from the command line. Ignore it,
9267       # but warn the user (except for BASH, which is always set by the calling BASH).
9268       if test "xSORT" != xBASH; then
9269         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&5
9270 $as_echo "$as_me: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&2;}
9271       fi
9272       # Try to locate tool using the code snippet
9273       for ac_prog in sort
9274 do
9275   # Extract the first word of "$ac_prog", so it can be a program name with args.
9276 set dummy $ac_prog; ac_word=$2
9277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9278 $as_echo_n "checking for $ac_word... " >&6; }
9279 if ${ac_cv_path_SORT+:} false; then :
9280   $as_echo_n "(cached) " >&6
9281 else
9282   case $SORT in
9283   [\\/]* | ?:[\\/]*)
9284   ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
9285   ;;
9286   *)
9287   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9288 for as_dir in $PATH
9289 do
9290   IFS=$as_save_IFS
9291   test -z "$as_dir" && as_dir=.
9292     for ac_exec_ext in '' $ac_executable_extensions; do
9293   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9294     ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext"
9295     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9296     break 2
9297   fi
9298 done
9299   done
9300 IFS=$as_save_IFS
9301 
9302   ;;
9303 esac
9304 fi
9305 SORT=$ac_cv_path_SORT
9306 if test -n "$SORT"; then
9307   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5
9308 $as_echo "$SORT" >&6; }
9309 else
9310   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9311 $as_echo "no" >&6; }
9312 fi
9313 
9314 
9315   test -n "$SORT" && break
9316 done
9317 
9318     else
9319       # If it succeeded, then it was overridden by the user. We will use it
9320       # for the tool.
9321 
9322       # First remove it from the list of overridden variables, so we can test
9323       # for unknown variables in the end.
9324       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9325 
9326       # Check if the provided tool contains a complete path.
9327       tool_specified="$SORT"
9328       tool_basename="${tool_specified##*/}"
9329       if test "x$tool_basename" = "x$tool_specified"; then
9330         # A command without a complete path is provided, search $PATH.
9331         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SORT=$tool_basename" >&5
9332 $as_echo "$as_me: Will search for user supplied tool SORT=$tool_basename" >&6;}
9333         # Extract the first word of "$tool_basename", so it can be a program name with args.
9334 set dummy $tool_basename; ac_word=$2
9335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9336 $as_echo_n "checking for $ac_word... " >&6; }
9337 if ${ac_cv_path_SORT+:} false; then :
9338   $as_echo_n "(cached) " >&6
9339 else
9340   case $SORT in
9341   [\\/]* | ?:[\\/]*)
9342   ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
9343   ;;
9344   *)
9345   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9346 for as_dir in $PATH
9347 do
9348   IFS=$as_save_IFS
9349   test -z "$as_dir" && as_dir=.
9350     for ac_exec_ext in '' $ac_executable_extensions; do
9351   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9352     ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext"
9353     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9354     break 2
9355   fi
9356 done
9357   done
9358 IFS=$as_save_IFS
9359 
9360   ;;
9361 esac
9362 fi
9363 SORT=$ac_cv_path_SORT
9364 if test -n "$SORT"; then
9365   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5
9366 $as_echo "$SORT" >&6; }
9367 else
9368   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9369 $as_echo "no" >&6; }
9370 fi
9371 
9372 
9373         if test "x$SORT" = x; then
9374           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9375         fi
9376       else
9377         # Otherwise we believe it is a complete path. Use it as it is.
9378         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SORT=$tool_specified" >&5
9379 $as_echo "$as_me: Will use user supplied tool SORT=$tool_specified" >&6;}
9380         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5
9381 $as_echo_n "checking for SORT... " >&6; }
9382         if test ! -x "$tool_specified"; then
9383           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9384 $as_echo "not found" >&6; }
9385           as_fn_error $? "User supplied tool SORT=$tool_specified does not exist or is not executable" "$LINENO" 5
9386         fi
9387         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9388 $as_echo "$tool_specified" >&6; }
9389       fi
9390     fi
9391   fi
9392 
9393 
9394 
9395   if test "x$SORT" = x; then
9396     as_fn_error $? "Could not find required tool for SORT" "$LINENO" 5
9397   fi
9398 
9399 
9400 
9401 
9402 
9403   # Publish this variable in the help.
9404 
9405 
9406   if test "x$TAIL" = x; then
9407     # The variable is not set by user, try to locate tool using the code snippet
9408     for ac_prog in tail
9409 do
9410   # Extract the first word of "$ac_prog", so it can be a program name with args.
9411 set dummy $ac_prog; ac_word=$2
9412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9413 $as_echo_n "checking for $ac_word... " >&6; }
9414 if ${ac_cv_path_TAIL+:} false; then :
9415   $as_echo_n "(cached) " >&6
9416 else
9417   case $TAIL in
9418   [\\/]* | ?:[\\/]*)
9419   ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path.
9420   ;;
9421   *)
9422   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9423 for as_dir in $PATH
9424 do
9425   IFS=$as_save_IFS
9426   test -z "$as_dir" && as_dir=.
9427     for ac_exec_ext in '' $ac_executable_extensions; do
9428   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9429     ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext"
9430     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9431     break 2
9432   fi
9433 done
9434   done
9435 IFS=$as_save_IFS
9436 
9437   ;;
9438 esac
9439 fi
9440 TAIL=$ac_cv_path_TAIL
9441 if test -n "$TAIL"; then
9442   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5
9443 $as_echo "$TAIL" >&6; }
9444 else
9445   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9446 $as_echo "no" >&6; }
9447 fi
9448 
9449 
9450   test -n "$TAIL" && break
9451 done
9452 
9453   else
9454     # The variable is set, but is it from the command line or the environment?
9455 
9456     # Try to remove the string !TAIL! from our list.
9457     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAIL!/}
9458     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9459       # If it failed, the variable was not from the command line. Ignore it,
9460       # but warn the user (except for BASH, which is always set by the calling BASH).
9461       if test "xTAIL" != xBASH; then
9462         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&5
9463 $as_echo "$as_me: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&2;}
9464       fi
9465       # Try to locate tool using the code snippet
9466       for ac_prog in tail
9467 do
9468   # Extract the first word of "$ac_prog", so it can be a program name with args.
9469 set dummy $ac_prog; ac_word=$2
9470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9471 $as_echo_n "checking for $ac_word... " >&6; }
9472 if ${ac_cv_path_TAIL+:} false; then :
9473   $as_echo_n "(cached) " >&6
9474 else
9475   case $TAIL in
9476   [\\/]* | ?:[\\/]*)
9477   ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path.
9478   ;;
9479   *)
9480   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9481 for as_dir in $PATH
9482 do
9483   IFS=$as_save_IFS
9484   test -z "$as_dir" && as_dir=.
9485     for ac_exec_ext in '' $ac_executable_extensions; do
9486   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9487     ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext"
9488     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9489     break 2
9490   fi
9491 done
9492   done
9493 IFS=$as_save_IFS
9494 
9495   ;;
9496 esac
9497 fi
9498 TAIL=$ac_cv_path_TAIL
9499 if test -n "$TAIL"; then
9500   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5
9501 $as_echo "$TAIL" >&6; }
9502 else
9503   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9504 $as_echo "no" >&6; }
9505 fi
9506 
9507 
9508   test -n "$TAIL" && break
9509 done
9510 
9511     else
9512       # If it succeeded, then it was overridden by the user. We will use it
9513       # for the tool.
9514 
9515       # First remove it from the list of overridden variables, so we can test
9516       # for unknown variables in the end.
9517       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9518 
9519       # Check if the provided tool contains a complete path.
9520       tool_specified="$TAIL"
9521       tool_basename="${tool_specified##*/}"
9522       if test "x$tool_basename" = "x$tool_specified"; then
9523         # A command without a complete path is provided, search $PATH.
9524         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAIL=$tool_basename" >&5
9525 $as_echo "$as_me: Will search for user supplied tool TAIL=$tool_basename" >&6;}
9526         # Extract the first word of "$tool_basename", so it can be a program name with args.
9527 set dummy $tool_basename; ac_word=$2
9528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9529 $as_echo_n "checking for $ac_word... " >&6; }
9530 if ${ac_cv_path_TAIL+:} false; then :
9531   $as_echo_n "(cached) " >&6
9532 else
9533   case $TAIL in
9534   [\\/]* | ?:[\\/]*)
9535   ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path.
9536   ;;
9537   *)
9538   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9539 for as_dir in $PATH
9540 do
9541   IFS=$as_save_IFS
9542   test -z "$as_dir" && as_dir=.
9543     for ac_exec_ext in '' $ac_executable_extensions; do
9544   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9545     ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext"
9546     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9547     break 2
9548   fi
9549 done
9550   done
9551 IFS=$as_save_IFS
9552 
9553   ;;
9554 esac
9555 fi
9556 TAIL=$ac_cv_path_TAIL
9557 if test -n "$TAIL"; then
9558   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5
9559 $as_echo "$TAIL" >&6; }
9560 else
9561   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9562 $as_echo "no" >&6; }
9563 fi
9564 
9565 
9566         if test "x$TAIL" = x; then
9567           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9568         fi
9569       else
9570         # Otherwise we believe it is a complete path. Use it as it is.
9571         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAIL=$tool_specified" >&5
9572 $as_echo "$as_me: Will use user supplied tool TAIL=$tool_specified" >&6;}
9573         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5
9574 $as_echo_n "checking for TAIL... " >&6; }
9575         if test ! -x "$tool_specified"; then
9576           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9577 $as_echo "not found" >&6; }
9578           as_fn_error $? "User supplied tool TAIL=$tool_specified does not exist or is not executable" "$LINENO" 5
9579         fi
9580         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9581 $as_echo "$tool_specified" >&6; }
9582       fi
9583     fi
9584   fi
9585 
9586 
9587 
9588   if test "x$TAIL" = x; then
9589     as_fn_error $? "Could not find required tool for TAIL" "$LINENO" 5
9590   fi
9591 
9592 
9593 
9594 
9595 
9596   # Publish this variable in the help.
9597 
9598 
9599   if test "x$TAR" = x; then
9600     # The variable is not set by user, try to locate tool using the code snippet
9601     for ac_prog in tar
9602 do
9603   # Extract the first word of "$ac_prog", so it can be a program name with args.
9604 set dummy $ac_prog; ac_word=$2
9605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9606 $as_echo_n "checking for $ac_word... " >&6; }
9607 if ${ac_cv_path_TAR+:} false; then :
9608   $as_echo_n "(cached) " >&6
9609 else
9610   case $TAR in
9611   [\\/]* | ?:[\\/]*)
9612   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9613   ;;
9614   *)
9615   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9616 for as_dir in $PATH
9617 do
9618   IFS=$as_save_IFS
9619   test -z "$as_dir" && as_dir=.
9620     for ac_exec_ext in '' $ac_executable_extensions; do
9621   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9622     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9623     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9624     break 2
9625   fi
9626 done
9627   done
9628 IFS=$as_save_IFS
9629 
9630   ;;
9631 esac
9632 fi
9633 TAR=$ac_cv_path_TAR
9634 if test -n "$TAR"; then
9635   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9636 $as_echo "$TAR" >&6; }
9637 else
9638   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9639 $as_echo "no" >&6; }
9640 fi
9641 
9642 
9643   test -n "$TAR" && break
9644 done
9645 
9646   else
9647     # The variable is set, but is it from the command line or the environment?
9648 
9649     # Try to remove the string !TAR! from our list.
9650     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAR!/}
9651     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9652       # If it failed, the variable was not from the command line. Ignore it,
9653       # but warn the user (except for BASH, which is always set by the calling BASH).
9654       if test "xTAR" != xBASH; then
9655         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&5
9656 $as_echo "$as_me: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&2;}
9657       fi
9658       # Try to locate tool using the code snippet
9659       for ac_prog in tar
9660 do
9661   # Extract the first word of "$ac_prog", so it can be a program name with args.
9662 set dummy $ac_prog; ac_word=$2
9663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9664 $as_echo_n "checking for $ac_word... " >&6; }
9665 if ${ac_cv_path_TAR+:} false; then :
9666   $as_echo_n "(cached) " >&6
9667 else
9668   case $TAR in
9669   [\\/]* | ?:[\\/]*)
9670   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9671   ;;
9672   *)
9673   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9674 for as_dir in $PATH
9675 do
9676   IFS=$as_save_IFS
9677   test -z "$as_dir" && as_dir=.
9678     for ac_exec_ext in '' $ac_executable_extensions; do
9679   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9680     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9681     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9682     break 2
9683   fi
9684 done
9685   done
9686 IFS=$as_save_IFS
9687 
9688   ;;
9689 esac
9690 fi
9691 TAR=$ac_cv_path_TAR
9692 if test -n "$TAR"; then
9693   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9694 $as_echo "$TAR" >&6; }
9695 else
9696   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9697 $as_echo "no" >&6; }
9698 fi
9699 
9700 
9701   test -n "$TAR" && break
9702 done
9703 
9704     else
9705       # If it succeeded, then it was overridden by the user. We will use it
9706       # for the tool.
9707 
9708       # First remove it from the list of overridden variables, so we can test
9709       # for unknown variables in the end.
9710       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9711 
9712       # Check if the provided tool contains a complete path.
9713       tool_specified="$TAR"
9714       tool_basename="${tool_specified##*/}"
9715       if test "x$tool_basename" = "x$tool_specified"; then
9716         # A command without a complete path is provided, search $PATH.
9717         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAR=$tool_basename" >&5
9718 $as_echo "$as_me: Will search for user supplied tool TAR=$tool_basename" >&6;}
9719         # Extract the first word of "$tool_basename", so it can be a program name with args.
9720 set dummy $tool_basename; ac_word=$2
9721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9722 $as_echo_n "checking for $ac_word... " >&6; }
9723 if ${ac_cv_path_TAR+:} false; then :
9724   $as_echo_n "(cached) " >&6
9725 else
9726   case $TAR in
9727   [\\/]* | ?:[\\/]*)
9728   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
9729   ;;
9730   *)
9731   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9732 for as_dir in $PATH
9733 do
9734   IFS=$as_save_IFS
9735   test -z "$as_dir" && as_dir=.
9736     for ac_exec_ext in '' $ac_executable_extensions; do
9737   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9738     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
9739     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9740     break 2
9741   fi
9742 done
9743   done
9744 IFS=$as_save_IFS
9745 
9746   ;;
9747 esac
9748 fi
9749 TAR=$ac_cv_path_TAR
9750 if test -n "$TAR"; then
9751   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5
9752 $as_echo "$TAR" >&6; }
9753 else
9754   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9755 $as_echo "no" >&6; }
9756 fi
9757 
9758 
9759         if test "x$TAR" = x; then
9760           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9761         fi
9762       else
9763         # Otherwise we believe it is a complete path. Use it as it is.
9764         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAR=$tool_specified" >&5
9765 $as_echo "$as_me: Will use user supplied tool TAR=$tool_specified" >&6;}
9766         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5
9767 $as_echo_n "checking for TAR... " >&6; }
9768         if test ! -x "$tool_specified"; then
9769           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9770 $as_echo "not found" >&6; }
9771           as_fn_error $? "User supplied tool TAR=$tool_specified does not exist or is not executable" "$LINENO" 5
9772         fi
9773         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9774 $as_echo "$tool_specified" >&6; }
9775       fi
9776     fi
9777   fi
9778 
9779 
9780 
9781   if test "x$TAR" = x; then
9782     as_fn_error $? "Could not find required tool for TAR" "$LINENO" 5
9783   fi
9784 
9785 
9786 
9787 
9788 
9789   # Publish this variable in the help.
9790 
9791 
9792   if test "x$TEE" = x; then
9793     # The variable is not set by user, try to locate tool using the code snippet
9794     for ac_prog in tee
9795 do
9796   # Extract the first word of "$ac_prog", so it can be a program name with args.
9797 set dummy $ac_prog; ac_word=$2
9798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9799 $as_echo_n "checking for $ac_word... " >&6; }
9800 if ${ac_cv_path_TEE+:} false; then :
9801   $as_echo_n "(cached) " >&6
9802 else
9803   case $TEE in
9804   [\\/]* | ?:[\\/]*)
9805   ac_cv_path_TEE="$TEE" # Let the user override the test with a path.
9806   ;;
9807   *)
9808   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9809 for as_dir in $PATH
9810 do
9811   IFS=$as_save_IFS
9812   test -z "$as_dir" && as_dir=.
9813     for ac_exec_ext in '' $ac_executable_extensions; do
9814   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9815     ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext"
9816     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9817     break 2
9818   fi
9819 done
9820   done
9821 IFS=$as_save_IFS
9822 
9823   ;;
9824 esac
9825 fi
9826 TEE=$ac_cv_path_TEE
9827 if test -n "$TEE"; then
9828   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5
9829 $as_echo "$TEE" >&6; }
9830 else
9831   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9832 $as_echo "no" >&6; }
9833 fi
9834 
9835 
9836   test -n "$TEE" && break
9837 done
9838 
9839   else
9840     # The variable is set, but is it from the command line or the environment?
9841 
9842     # Try to remove the string !TEE! from our list.
9843     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TEE!/}
9844     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
9845       # If it failed, the variable was not from the command line. Ignore it,
9846       # but warn the user (except for BASH, which is always set by the calling BASH).
9847       if test "xTEE" != xBASH; then
9848         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&5
9849 $as_echo "$as_me: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&2;}
9850       fi
9851       # Try to locate tool using the code snippet
9852       for ac_prog in tee
9853 do
9854   # Extract the first word of "$ac_prog", so it can be a program name with args.
9855 set dummy $ac_prog; ac_word=$2
9856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9857 $as_echo_n "checking for $ac_word... " >&6; }
9858 if ${ac_cv_path_TEE+:} false; then :
9859   $as_echo_n "(cached) " >&6
9860 else
9861   case $TEE in
9862   [\\/]* | ?:[\\/]*)
9863   ac_cv_path_TEE="$TEE" # Let the user override the test with a path.
9864   ;;
9865   *)
9866   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9867 for as_dir in $PATH
9868 do
9869   IFS=$as_save_IFS
9870   test -z "$as_dir" && as_dir=.
9871     for ac_exec_ext in '' $ac_executable_extensions; do
9872   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9873     ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext"
9874     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9875     break 2
9876   fi
9877 done
9878   done
9879 IFS=$as_save_IFS
9880 
9881   ;;
9882 esac
9883 fi
9884 TEE=$ac_cv_path_TEE
9885 if test -n "$TEE"; then
9886   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5
9887 $as_echo "$TEE" >&6; }
9888 else
9889   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9890 $as_echo "no" >&6; }
9891 fi
9892 
9893 
9894   test -n "$TEE" && break
9895 done
9896 
9897     else
9898       # If it succeeded, then it was overridden by the user. We will use it
9899       # for the tool.
9900 
9901       # First remove it from the list of overridden variables, so we can test
9902       # for unknown variables in the end.
9903       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
9904 
9905       # Check if the provided tool contains a complete path.
9906       tool_specified="$TEE"
9907       tool_basename="${tool_specified##*/}"
9908       if test "x$tool_basename" = "x$tool_specified"; then
9909         # A command without a complete path is provided, search $PATH.
9910         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TEE=$tool_basename" >&5
9911 $as_echo "$as_me: Will search for user supplied tool TEE=$tool_basename" >&6;}
9912         # Extract the first word of "$tool_basename", so it can be a program name with args.
9913 set dummy $tool_basename; ac_word=$2
9914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9915 $as_echo_n "checking for $ac_word... " >&6; }
9916 if ${ac_cv_path_TEE+:} false; then :
9917   $as_echo_n "(cached) " >&6
9918 else
9919   case $TEE in
9920   [\\/]* | ?:[\\/]*)
9921   ac_cv_path_TEE="$TEE" # Let the user override the test with a path.
9922   ;;
9923   *)
9924   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9925 for as_dir in $PATH
9926 do
9927   IFS=$as_save_IFS
9928   test -z "$as_dir" && as_dir=.
9929     for ac_exec_ext in '' $ac_executable_extensions; do
9930   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9931     ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext"
9932     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9933     break 2
9934   fi
9935 done
9936   done
9937 IFS=$as_save_IFS
9938 
9939   ;;
9940 esac
9941 fi
9942 TEE=$ac_cv_path_TEE
9943 if test -n "$TEE"; then
9944   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5
9945 $as_echo "$TEE" >&6; }
9946 else
9947   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9948 $as_echo "no" >&6; }
9949 fi
9950 
9951 
9952         if test "x$TEE" = x; then
9953           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
9954         fi
9955       else
9956         # Otherwise we believe it is a complete path. Use it as it is.
9957         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TEE=$tool_specified" >&5
9958 $as_echo "$as_me: Will use user supplied tool TEE=$tool_specified" >&6;}
9959         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5
9960 $as_echo_n "checking for TEE... " >&6; }
9961         if test ! -x "$tool_specified"; then
9962           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
9963 $as_echo "not found" >&6; }
9964           as_fn_error $? "User supplied tool TEE=$tool_specified does not exist or is not executable" "$LINENO" 5
9965         fi
9966         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
9967 $as_echo "$tool_specified" >&6; }
9968       fi
9969     fi
9970   fi
9971 
9972 
9973 
9974   if test "x$TEE" = x; then
9975     as_fn_error $? "Could not find required tool for TEE" "$LINENO" 5
9976   fi
9977 
9978 
9979 
9980 
9981 
9982   # Publish this variable in the help.
9983 
9984 
9985   if test "x$TOUCH" = x; then
9986     # The variable is not set by user, try to locate tool using the code snippet
9987     for ac_prog in touch
9988 do
9989   # Extract the first word of "$ac_prog", so it can be a program name with args.
9990 set dummy $ac_prog; ac_word=$2
9991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9992 $as_echo_n "checking for $ac_word... " >&6; }
9993 if ${ac_cv_path_TOUCH+:} false; then :
9994   $as_echo_n "(cached) " >&6
9995 else
9996   case $TOUCH in
9997   [\\/]* | ?:[\\/]*)
9998   ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path.
9999   ;;
10000   *)
10001   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10002 for as_dir in $PATH
10003 do
10004   IFS=$as_save_IFS
10005   test -z "$as_dir" && as_dir=.
10006     for ac_exec_ext in '' $ac_executable_extensions; do
10007   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10008     ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext"
10009     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10010     break 2
10011   fi
10012 done
10013   done
10014 IFS=$as_save_IFS
10015 
10016   ;;
10017 esac
10018 fi
10019 TOUCH=$ac_cv_path_TOUCH
10020 if test -n "$TOUCH"; then
10021   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5
10022 $as_echo "$TOUCH" >&6; }
10023 else
10024   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10025 $as_echo "no" >&6; }
10026 fi
10027 
10028 
10029   test -n "$TOUCH" && break
10030 done
10031 
10032   else
10033     # The variable is set, but is it from the command line or the environment?
10034 
10035     # Try to remove the string !TOUCH! from our list.
10036     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TOUCH!/}
10037     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10038       # If it failed, the variable was not from the command line. Ignore it,
10039       # but warn the user (except for BASH, which is always set by the calling BASH).
10040       if test "xTOUCH" != xBASH; then
10041         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&5
10042 $as_echo "$as_me: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&2;}
10043       fi
10044       # Try to locate tool using the code snippet
10045       for ac_prog in touch
10046 do
10047   # Extract the first word of "$ac_prog", so it can be a program name with args.
10048 set dummy $ac_prog; ac_word=$2
10049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10050 $as_echo_n "checking for $ac_word... " >&6; }
10051 if ${ac_cv_path_TOUCH+:} false; then :
10052   $as_echo_n "(cached) " >&6
10053 else
10054   case $TOUCH in
10055   [\\/]* | ?:[\\/]*)
10056   ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path.
10057   ;;
10058   *)
10059   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10060 for as_dir in $PATH
10061 do
10062   IFS=$as_save_IFS
10063   test -z "$as_dir" && as_dir=.
10064     for ac_exec_ext in '' $ac_executable_extensions; do
10065   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10066     ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext"
10067     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10068     break 2
10069   fi
10070 done
10071   done
10072 IFS=$as_save_IFS
10073 
10074   ;;
10075 esac
10076 fi
10077 TOUCH=$ac_cv_path_TOUCH
10078 if test -n "$TOUCH"; then
10079   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5
10080 $as_echo "$TOUCH" >&6; }
10081 else
10082   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10083 $as_echo "no" >&6; }
10084 fi
10085 
10086 
10087   test -n "$TOUCH" && break
10088 done
10089 
10090     else
10091       # If it succeeded, then it was overridden by the user. We will use it
10092       # for the tool.
10093 
10094       # First remove it from the list of overridden variables, so we can test
10095       # for unknown variables in the end.
10096       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10097 
10098       # Check if the provided tool contains a complete path.
10099       tool_specified="$TOUCH"
10100       tool_basename="${tool_specified##*/}"
10101       if test "x$tool_basename" = "x$tool_specified"; then
10102         # A command without a complete path is provided, search $PATH.
10103         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TOUCH=$tool_basename" >&5
10104 $as_echo "$as_me: Will search for user supplied tool TOUCH=$tool_basename" >&6;}
10105         # Extract the first word of "$tool_basename", so it can be a program name with args.
10106 set dummy $tool_basename; ac_word=$2
10107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10108 $as_echo_n "checking for $ac_word... " >&6; }
10109 if ${ac_cv_path_TOUCH+:} false; then :
10110   $as_echo_n "(cached) " >&6
10111 else
10112   case $TOUCH in
10113   [\\/]* | ?:[\\/]*)
10114   ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path.
10115   ;;
10116   *)
10117   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10118 for as_dir in $PATH
10119 do
10120   IFS=$as_save_IFS
10121   test -z "$as_dir" && as_dir=.
10122     for ac_exec_ext in '' $ac_executable_extensions; do
10123   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10124     ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext"
10125     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10126     break 2
10127   fi
10128 done
10129   done
10130 IFS=$as_save_IFS
10131 
10132   ;;
10133 esac
10134 fi
10135 TOUCH=$ac_cv_path_TOUCH
10136 if test -n "$TOUCH"; then
10137   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5
10138 $as_echo "$TOUCH" >&6; }
10139 else
10140   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10141 $as_echo "no" >&6; }
10142 fi
10143 
10144 
10145         if test "x$TOUCH" = x; then
10146           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10147         fi
10148       else
10149         # Otherwise we believe it is a complete path. Use it as it is.
10150         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TOUCH=$tool_specified" >&5
10151 $as_echo "$as_me: Will use user supplied tool TOUCH=$tool_specified" >&6;}
10152         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5
10153 $as_echo_n "checking for TOUCH... " >&6; }
10154         if test ! -x "$tool_specified"; then
10155           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10156 $as_echo "not found" >&6; }
10157           as_fn_error $? "User supplied tool TOUCH=$tool_specified does not exist or is not executable" "$LINENO" 5
10158         fi
10159         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10160 $as_echo "$tool_specified" >&6; }
10161       fi
10162     fi
10163   fi
10164 
10165 
10166 
10167   if test "x$TOUCH" = x; then
10168     as_fn_error $? "Could not find required tool for TOUCH" "$LINENO" 5
10169   fi
10170 
10171 
10172 
10173 
10174 
10175   # Publish this variable in the help.
10176 
10177 
10178   if test "x$TR" = x; then
10179     # The variable is not set by user, try to locate tool using the code snippet
10180     for ac_prog in tr
10181 do
10182   # Extract the first word of "$ac_prog", so it can be a program name with args.
10183 set dummy $ac_prog; ac_word=$2
10184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10185 $as_echo_n "checking for $ac_word... " >&6; }
10186 if ${ac_cv_path_TR+:} false; then :
10187   $as_echo_n "(cached) " >&6
10188 else
10189   case $TR in
10190   [\\/]* | ?:[\\/]*)
10191   ac_cv_path_TR="$TR" # Let the user override the test with a path.
10192   ;;
10193   *)
10194   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10195 for as_dir in $PATH
10196 do
10197   IFS=$as_save_IFS
10198   test -z "$as_dir" && as_dir=.
10199     for ac_exec_ext in '' $ac_executable_extensions; do
10200   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10201     ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext"
10202     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10203     break 2
10204   fi
10205 done
10206   done
10207 IFS=$as_save_IFS
10208 
10209   ;;
10210 esac
10211 fi
10212 TR=$ac_cv_path_TR
10213 if test -n "$TR"; then
10214   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5
10215 $as_echo "$TR" >&6; }
10216 else
10217   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10218 $as_echo "no" >&6; }
10219 fi
10220 
10221 
10222   test -n "$TR" && break
10223 done
10224 
10225   else
10226     # The variable is set, but is it from the command line or the environment?
10227 
10228     # Try to remove the string !TR! from our list.
10229     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TR!/}
10230     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10231       # If it failed, the variable was not from the command line. Ignore it,
10232       # but warn the user (except for BASH, which is always set by the calling BASH).
10233       if test "xTR" != xBASH; then
10234         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&5
10235 $as_echo "$as_me: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&2;}
10236       fi
10237       # Try to locate tool using the code snippet
10238       for ac_prog in tr
10239 do
10240   # Extract the first word of "$ac_prog", so it can be a program name with args.
10241 set dummy $ac_prog; ac_word=$2
10242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10243 $as_echo_n "checking for $ac_word... " >&6; }
10244 if ${ac_cv_path_TR+:} false; then :
10245   $as_echo_n "(cached) " >&6
10246 else
10247   case $TR in
10248   [\\/]* | ?:[\\/]*)
10249   ac_cv_path_TR="$TR" # Let the user override the test with a path.
10250   ;;
10251   *)
10252   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10253 for as_dir in $PATH
10254 do
10255   IFS=$as_save_IFS
10256   test -z "$as_dir" && as_dir=.
10257     for ac_exec_ext in '' $ac_executable_extensions; do
10258   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10259     ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext"
10260     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10261     break 2
10262   fi
10263 done
10264   done
10265 IFS=$as_save_IFS
10266 
10267   ;;
10268 esac
10269 fi
10270 TR=$ac_cv_path_TR
10271 if test -n "$TR"; then
10272   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5
10273 $as_echo "$TR" >&6; }
10274 else
10275   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10276 $as_echo "no" >&6; }
10277 fi
10278 
10279 
10280   test -n "$TR" && break
10281 done
10282 
10283     else
10284       # If it succeeded, then it was overridden by the user. We will use it
10285       # for the tool.
10286 
10287       # First remove it from the list of overridden variables, so we can test
10288       # for unknown variables in the end.
10289       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10290 
10291       # Check if the provided tool contains a complete path.
10292       tool_specified="$TR"
10293       tool_basename="${tool_specified##*/}"
10294       if test "x$tool_basename" = "x$tool_specified"; then
10295         # A command without a complete path is provided, search $PATH.
10296         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TR=$tool_basename" >&5
10297 $as_echo "$as_me: Will search for user supplied tool TR=$tool_basename" >&6;}
10298         # Extract the first word of "$tool_basename", so it can be a program name with args.
10299 set dummy $tool_basename; ac_word=$2
10300 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10301 $as_echo_n "checking for $ac_word... " >&6; }
10302 if ${ac_cv_path_TR+:} false; then :
10303   $as_echo_n "(cached) " >&6
10304 else
10305   case $TR in
10306   [\\/]* | ?:[\\/]*)
10307   ac_cv_path_TR="$TR" # Let the user override the test with a path.
10308   ;;
10309   *)
10310   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10311 for as_dir in $PATH
10312 do
10313   IFS=$as_save_IFS
10314   test -z "$as_dir" && as_dir=.
10315     for ac_exec_ext in '' $ac_executable_extensions; do
10316   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10317     ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext"
10318     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10319     break 2
10320   fi
10321 done
10322   done
10323 IFS=$as_save_IFS
10324 
10325   ;;
10326 esac
10327 fi
10328 TR=$ac_cv_path_TR
10329 if test -n "$TR"; then
10330   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5
10331 $as_echo "$TR" >&6; }
10332 else
10333   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10334 $as_echo "no" >&6; }
10335 fi
10336 
10337 
10338         if test "x$TR" = x; then
10339           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10340         fi
10341       else
10342         # Otherwise we believe it is a complete path. Use it as it is.
10343         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TR=$tool_specified" >&5
10344 $as_echo "$as_me: Will use user supplied tool TR=$tool_specified" >&6;}
10345         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5
10346 $as_echo_n "checking for TR... " >&6; }
10347         if test ! -x "$tool_specified"; then
10348           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10349 $as_echo "not found" >&6; }
10350           as_fn_error $? "User supplied tool TR=$tool_specified does not exist or is not executable" "$LINENO" 5
10351         fi
10352         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10353 $as_echo "$tool_specified" >&6; }
10354       fi
10355     fi
10356   fi
10357 
10358 
10359 
10360   if test "x$TR" = x; then
10361     as_fn_error $? "Could not find required tool for TR" "$LINENO" 5
10362   fi
10363 
10364 
10365 
10366 
10367 
10368   # Publish this variable in the help.
10369 
10370 
10371   if test "x$UNAME" = x; then
10372     # The variable is not set by user, try to locate tool using the code snippet
10373     for ac_prog in uname
10374 do
10375   # Extract the first word of "$ac_prog", so it can be a program name with args.
10376 set dummy $ac_prog; ac_word=$2
10377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10378 $as_echo_n "checking for $ac_word... " >&6; }
10379 if ${ac_cv_path_UNAME+:} false; then :
10380   $as_echo_n "(cached) " >&6
10381 else
10382   case $UNAME in
10383   [\\/]* | ?:[\\/]*)
10384   ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
10385   ;;
10386   *)
10387   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10388 for as_dir in $PATH
10389 do
10390   IFS=$as_save_IFS
10391   test -z "$as_dir" && as_dir=.
10392     for ac_exec_ext in '' $ac_executable_extensions; do
10393   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10394     ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
10395     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10396     break 2
10397   fi
10398 done
10399   done
10400 IFS=$as_save_IFS
10401 
10402   ;;
10403 esac
10404 fi
10405 UNAME=$ac_cv_path_UNAME
10406 if test -n "$UNAME"; then
10407   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
10408 $as_echo "$UNAME" >&6; }
10409 else
10410   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10411 $as_echo "no" >&6; }
10412 fi
10413 
10414 
10415   test -n "$UNAME" && break
10416 done
10417 
10418   else
10419     # The variable is set, but is it from the command line or the environment?
10420 
10421     # Try to remove the string !UNAME! from our list.
10422     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNAME!/}
10423     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10424       # If it failed, the variable was not from the command line. Ignore it,
10425       # but warn the user (except for BASH, which is always set by the calling BASH).
10426       if test "xUNAME" != xBASH; then
10427         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&5
10428 $as_echo "$as_me: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&2;}
10429       fi
10430       # Try to locate tool using the code snippet
10431       for ac_prog in uname
10432 do
10433   # Extract the first word of "$ac_prog", so it can be a program name with args.
10434 set dummy $ac_prog; ac_word=$2
10435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10436 $as_echo_n "checking for $ac_word... " >&6; }
10437 if ${ac_cv_path_UNAME+:} false; then :
10438   $as_echo_n "(cached) " >&6
10439 else
10440   case $UNAME in
10441   [\\/]* | ?:[\\/]*)
10442   ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
10443   ;;
10444   *)
10445   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10446 for as_dir in $PATH
10447 do
10448   IFS=$as_save_IFS
10449   test -z "$as_dir" && as_dir=.
10450     for ac_exec_ext in '' $ac_executable_extensions; do
10451   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10452     ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
10453     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10454     break 2
10455   fi
10456 done
10457   done
10458 IFS=$as_save_IFS
10459 
10460   ;;
10461 esac
10462 fi
10463 UNAME=$ac_cv_path_UNAME
10464 if test -n "$UNAME"; then
10465   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
10466 $as_echo "$UNAME" >&6; }
10467 else
10468   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10469 $as_echo "no" >&6; }
10470 fi
10471 
10472 
10473   test -n "$UNAME" && break
10474 done
10475 
10476     else
10477       # If it succeeded, then it was overridden by the user. We will use it
10478       # for the tool.
10479 
10480       # First remove it from the list of overridden variables, so we can test
10481       # for unknown variables in the end.
10482       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10483 
10484       # Check if the provided tool contains a complete path.
10485       tool_specified="$UNAME"
10486       tool_basename="${tool_specified##*/}"
10487       if test "x$tool_basename" = "x$tool_specified"; then
10488         # A command without a complete path is provided, search $PATH.
10489         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNAME=$tool_basename" >&5
10490 $as_echo "$as_me: Will search for user supplied tool UNAME=$tool_basename" >&6;}
10491         # Extract the first word of "$tool_basename", so it can be a program name with args.
10492 set dummy $tool_basename; ac_word=$2
10493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10494 $as_echo_n "checking for $ac_word... " >&6; }
10495 if ${ac_cv_path_UNAME+:} false; then :
10496   $as_echo_n "(cached) " >&6
10497 else
10498   case $UNAME in
10499   [\\/]* | ?:[\\/]*)
10500   ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
10501   ;;
10502   *)
10503   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10504 for as_dir in $PATH
10505 do
10506   IFS=$as_save_IFS
10507   test -z "$as_dir" && as_dir=.
10508     for ac_exec_ext in '' $ac_executable_extensions; do
10509   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10510     ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
10511     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10512     break 2
10513   fi
10514 done
10515   done
10516 IFS=$as_save_IFS
10517 
10518   ;;
10519 esac
10520 fi
10521 UNAME=$ac_cv_path_UNAME
10522 if test -n "$UNAME"; then
10523   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
10524 $as_echo "$UNAME" >&6; }
10525 else
10526   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10527 $as_echo "no" >&6; }
10528 fi
10529 
10530 
10531         if test "x$UNAME" = x; then
10532           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10533         fi
10534       else
10535         # Otherwise we believe it is a complete path. Use it as it is.
10536         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNAME=$tool_specified" >&5
10537 $as_echo "$as_me: Will use user supplied tool UNAME=$tool_specified" >&6;}
10538         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5
10539 $as_echo_n "checking for UNAME... " >&6; }
10540         if test ! -x "$tool_specified"; then
10541           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10542 $as_echo "not found" >&6; }
10543           as_fn_error $? "User supplied tool UNAME=$tool_specified does not exist or is not executable" "$LINENO" 5
10544         fi
10545         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10546 $as_echo "$tool_specified" >&6; }
10547       fi
10548     fi
10549   fi
10550 
10551 
10552 
10553   if test "x$UNAME" = x; then
10554     as_fn_error $? "Could not find required tool for UNAME" "$LINENO" 5
10555   fi
10556 
10557 
10558 
10559 
10560 
10561   # Publish this variable in the help.
10562 
10563 
10564   if test "x$UNIQ" = x; then
10565     # The variable is not set by user, try to locate tool using the code snippet
10566     for ac_prog in uniq
10567 do
10568   # Extract the first word of "$ac_prog", so it can be a program name with args.
10569 set dummy $ac_prog; ac_word=$2
10570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10571 $as_echo_n "checking for $ac_word... " >&6; }
10572 if ${ac_cv_path_UNIQ+:} false; then :
10573   $as_echo_n "(cached) " >&6
10574 else
10575   case $UNIQ in
10576   [\\/]* | ?:[\\/]*)
10577   ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path.
10578   ;;
10579   *)
10580   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10581 for as_dir in $PATH
10582 do
10583   IFS=$as_save_IFS
10584   test -z "$as_dir" && as_dir=.
10585     for ac_exec_ext in '' $ac_executable_extensions; do
10586   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10587     ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext"
10588     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10589     break 2
10590   fi
10591 done
10592   done
10593 IFS=$as_save_IFS
10594 
10595   ;;
10596 esac
10597 fi
10598 UNIQ=$ac_cv_path_UNIQ
10599 if test -n "$UNIQ"; then
10600   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5
10601 $as_echo "$UNIQ" >&6; }
10602 else
10603   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10604 $as_echo "no" >&6; }
10605 fi
10606 
10607 
10608   test -n "$UNIQ" && break
10609 done
10610 
10611   else
10612     # The variable is set, but is it from the command line or the environment?
10613 
10614     # Try to remove the string !UNIQ! from our list.
10615     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNIQ!/}
10616     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10617       # If it failed, the variable was not from the command line. Ignore it,
10618       # but warn the user (except for BASH, which is always set by the calling BASH).
10619       if test "xUNIQ" != xBASH; then
10620         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&5
10621 $as_echo "$as_me: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&2;}
10622       fi
10623       # Try to locate tool using the code snippet
10624       for ac_prog in uniq
10625 do
10626   # Extract the first word of "$ac_prog", so it can be a program name with args.
10627 set dummy $ac_prog; ac_word=$2
10628 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10629 $as_echo_n "checking for $ac_word... " >&6; }
10630 if ${ac_cv_path_UNIQ+:} false; then :
10631   $as_echo_n "(cached) " >&6
10632 else
10633   case $UNIQ in
10634   [\\/]* | ?:[\\/]*)
10635   ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path.
10636   ;;
10637   *)
10638   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10639 for as_dir in $PATH
10640 do
10641   IFS=$as_save_IFS
10642   test -z "$as_dir" && as_dir=.
10643     for ac_exec_ext in '' $ac_executable_extensions; do
10644   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10645     ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext"
10646     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10647     break 2
10648   fi
10649 done
10650   done
10651 IFS=$as_save_IFS
10652 
10653   ;;
10654 esac
10655 fi
10656 UNIQ=$ac_cv_path_UNIQ
10657 if test -n "$UNIQ"; then
10658   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5
10659 $as_echo "$UNIQ" >&6; }
10660 else
10661   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10662 $as_echo "no" >&6; }
10663 fi
10664 
10665 
10666   test -n "$UNIQ" && break
10667 done
10668 
10669     else
10670       # If it succeeded, then it was overridden by the user. We will use it
10671       # for the tool.
10672 
10673       # First remove it from the list of overridden variables, so we can test
10674       # for unknown variables in the end.
10675       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10676 
10677       # Check if the provided tool contains a complete path.
10678       tool_specified="$UNIQ"
10679       tool_basename="${tool_specified##*/}"
10680       if test "x$tool_basename" = "x$tool_specified"; then
10681         # A command without a complete path is provided, search $PATH.
10682         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNIQ=$tool_basename" >&5
10683 $as_echo "$as_me: Will search for user supplied tool UNIQ=$tool_basename" >&6;}
10684         # Extract the first word of "$tool_basename", so it can be a program name with args.
10685 set dummy $tool_basename; ac_word=$2
10686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10687 $as_echo_n "checking for $ac_word... " >&6; }
10688 if ${ac_cv_path_UNIQ+:} false; then :
10689   $as_echo_n "(cached) " >&6
10690 else
10691   case $UNIQ in
10692   [\\/]* | ?:[\\/]*)
10693   ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path.
10694   ;;
10695   *)
10696   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10697 for as_dir in $PATH
10698 do
10699   IFS=$as_save_IFS
10700   test -z "$as_dir" && as_dir=.
10701     for ac_exec_ext in '' $ac_executable_extensions; do
10702   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10703     ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext"
10704     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10705     break 2
10706   fi
10707 done
10708   done
10709 IFS=$as_save_IFS
10710 
10711   ;;
10712 esac
10713 fi
10714 UNIQ=$ac_cv_path_UNIQ
10715 if test -n "$UNIQ"; then
10716   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5
10717 $as_echo "$UNIQ" >&6; }
10718 else
10719   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10720 $as_echo "no" >&6; }
10721 fi
10722 
10723 
10724         if test "x$UNIQ" = x; then
10725           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10726         fi
10727       else
10728         # Otherwise we believe it is a complete path. Use it as it is.
10729         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNIQ=$tool_specified" >&5
10730 $as_echo "$as_me: Will use user supplied tool UNIQ=$tool_specified" >&6;}
10731         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5
10732 $as_echo_n "checking for UNIQ... " >&6; }
10733         if test ! -x "$tool_specified"; then
10734           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10735 $as_echo "not found" >&6; }
10736           as_fn_error $? "User supplied tool UNIQ=$tool_specified does not exist or is not executable" "$LINENO" 5
10737         fi
10738         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10739 $as_echo "$tool_specified" >&6; }
10740       fi
10741     fi
10742   fi
10743 
10744 
10745 
10746   if test "x$UNIQ" = x; then
10747     as_fn_error $? "Could not find required tool for UNIQ" "$LINENO" 5
10748   fi
10749 
10750 
10751 
10752 
10753 
10754   # Publish this variable in the help.
10755 
10756 
10757   if test "x$WC" = x; then
10758     # The variable is not set by user, try to locate tool using the code snippet
10759     for ac_prog in wc
10760 do
10761   # Extract the first word of "$ac_prog", so it can be a program name with args.
10762 set dummy $ac_prog; ac_word=$2
10763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10764 $as_echo_n "checking for $ac_word... " >&6; }
10765 if ${ac_cv_path_WC+:} false; then :
10766   $as_echo_n "(cached) " >&6
10767 else
10768   case $WC in
10769   [\\/]* | ?:[\\/]*)
10770   ac_cv_path_WC="$WC" # Let the user override the test with a path.
10771   ;;
10772   *)
10773   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10774 for as_dir in $PATH
10775 do
10776   IFS=$as_save_IFS
10777   test -z "$as_dir" && as_dir=.
10778     for ac_exec_ext in '' $ac_executable_extensions; do
10779   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10780     ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext"
10781     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10782     break 2
10783   fi
10784 done
10785   done
10786 IFS=$as_save_IFS
10787 
10788   ;;
10789 esac
10790 fi
10791 WC=$ac_cv_path_WC
10792 if test -n "$WC"; then
10793   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5
10794 $as_echo "$WC" >&6; }
10795 else
10796   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10797 $as_echo "no" >&6; }
10798 fi
10799 
10800 
10801   test -n "$WC" && break
10802 done
10803 
10804   else
10805     # The variable is set, but is it from the command line or the environment?
10806 
10807     # Try to remove the string !WC! from our list.
10808     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WC!/}
10809     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
10810       # If it failed, the variable was not from the command line. Ignore it,
10811       # but warn the user (except for BASH, which is always set by the calling BASH).
10812       if test "xWC" != xBASH; then
10813         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&5
10814 $as_echo "$as_me: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&2;}
10815       fi
10816       # Try to locate tool using the code snippet
10817       for ac_prog in wc
10818 do
10819   # Extract the first word of "$ac_prog", so it can be a program name with args.
10820 set dummy $ac_prog; ac_word=$2
10821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10822 $as_echo_n "checking for $ac_word... " >&6; }
10823 if ${ac_cv_path_WC+:} false; then :
10824   $as_echo_n "(cached) " >&6
10825 else
10826   case $WC in
10827   [\\/]* | ?:[\\/]*)
10828   ac_cv_path_WC="$WC" # Let the user override the test with a path.
10829   ;;
10830   *)
10831   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10832 for as_dir in $PATH
10833 do
10834   IFS=$as_save_IFS
10835   test -z "$as_dir" && as_dir=.
10836     for ac_exec_ext in '' $ac_executable_extensions; do
10837   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10838     ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext"
10839     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10840     break 2
10841   fi
10842 done
10843   done
10844 IFS=$as_save_IFS
10845 
10846   ;;
10847 esac
10848 fi
10849 WC=$ac_cv_path_WC
10850 if test -n "$WC"; then
10851   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5
10852 $as_echo "$WC" >&6; }
10853 else
10854   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10855 $as_echo "no" >&6; }
10856 fi
10857 
10858 
10859   test -n "$WC" && break
10860 done
10861 
10862     else
10863       # If it succeeded, then it was overridden by the user. We will use it
10864       # for the tool.
10865 
10866       # First remove it from the list of overridden variables, so we can test
10867       # for unknown variables in the end.
10868       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
10869 
10870       # Check if the provided tool contains a complete path.
10871       tool_specified="$WC"
10872       tool_basename="${tool_specified##*/}"
10873       if test "x$tool_basename" = "x$tool_specified"; then
10874         # A command without a complete path is provided, search $PATH.
10875         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WC=$tool_basename" >&5
10876 $as_echo "$as_me: Will search for user supplied tool WC=$tool_basename" >&6;}
10877         # Extract the first word of "$tool_basename", so it can be a program name with args.
10878 set dummy $tool_basename; ac_word=$2
10879 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10880 $as_echo_n "checking for $ac_word... " >&6; }
10881 if ${ac_cv_path_WC+:} false; then :
10882   $as_echo_n "(cached) " >&6
10883 else
10884   case $WC in
10885   [\\/]* | ?:[\\/]*)
10886   ac_cv_path_WC="$WC" # Let the user override the test with a path.
10887   ;;
10888   *)
10889   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10890 for as_dir in $PATH
10891 do
10892   IFS=$as_save_IFS
10893   test -z "$as_dir" && as_dir=.
10894     for ac_exec_ext in '' $ac_executable_extensions; do
10895   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10896     ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext"
10897     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10898     break 2
10899   fi
10900 done
10901   done
10902 IFS=$as_save_IFS
10903 
10904   ;;
10905 esac
10906 fi
10907 WC=$ac_cv_path_WC
10908 if test -n "$WC"; then
10909   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5
10910 $as_echo "$WC" >&6; }
10911 else
10912   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10913 $as_echo "no" >&6; }
10914 fi
10915 
10916 
10917         if test "x$WC" = x; then
10918           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
10919         fi
10920       else
10921         # Otherwise we believe it is a complete path. Use it as it is.
10922         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WC=$tool_specified" >&5
10923 $as_echo "$as_me: Will use user supplied tool WC=$tool_specified" >&6;}
10924         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5
10925 $as_echo_n "checking for WC... " >&6; }
10926         if test ! -x "$tool_specified"; then
10927           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10928 $as_echo "not found" >&6; }
10929           as_fn_error $? "User supplied tool WC=$tool_specified does not exist or is not executable" "$LINENO" 5
10930         fi
10931         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
10932 $as_echo "$tool_specified" >&6; }
10933       fi
10934     fi
10935   fi
10936 
10937 
10938 
10939   if test "x$WC" = x; then
10940     as_fn_error $? "Could not find required tool for WC" "$LINENO" 5
10941   fi
10942 
10943 
10944 
10945 
10946 
10947   # Publish this variable in the help.
10948 
10949 
10950   if test "x$WHICH" = x; then
10951     # The variable is not set by user, try to locate tool using the code snippet
10952     for ac_prog in which
10953 do
10954   # Extract the first word of "$ac_prog", so it can be a program name with args.
10955 set dummy $ac_prog; ac_word=$2
10956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10957 $as_echo_n "checking for $ac_word... " >&6; }
10958 if ${ac_cv_path_WHICH+:} false; then :
10959   $as_echo_n "(cached) " >&6
10960 else
10961   case $WHICH in
10962   [\\/]* | ?:[\\/]*)
10963   ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path.
10964   ;;
10965   *)
10966   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10967 for as_dir in $PATH
10968 do
10969   IFS=$as_save_IFS
10970   test -z "$as_dir" && as_dir=.
10971     for ac_exec_ext in '' $ac_executable_extensions; do
10972   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10973     ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext"
10974     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10975     break 2
10976   fi
10977 done
10978   done
10979 IFS=$as_save_IFS
10980 
10981   ;;
10982 esac
10983 fi
10984 WHICH=$ac_cv_path_WHICH
10985 if test -n "$WHICH"; then
10986   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5
10987 $as_echo "$WHICH" >&6; }
10988 else
10989   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10990 $as_echo "no" >&6; }
10991 fi
10992 
10993 
10994   test -n "$WHICH" && break
10995 done
10996 
10997   else
10998     # The variable is set, but is it from the command line or the environment?
10999 
11000     # Try to remove the string !WHICH! from our list.
11001     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WHICH!/}
11002     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11003       # If it failed, the variable was not from the command line. Ignore it,
11004       # but warn the user (except for BASH, which is always set by the calling BASH).
11005       if test "xWHICH" != xBASH; then
11006         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&5
11007 $as_echo "$as_me: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&2;}
11008       fi
11009       # Try to locate tool using the code snippet
11010       for ac_prog in which
11011 do
11012   # Extract the first word of "$ac_prog", so it can be a program name with args.
11013 set dummy $ac_prog; ac_word=$2
11014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11015 $as_echo_n "checking for $ac_word... " >&6; }
11016 if ${ac_cv_path_WHICH+:} false; then :
11017   $as_echo_n "(cached) " >&6
11018 else
11019   case $WHICH in
11020   [\\/]* | ?:[\\/]*)
11021   ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path.
11022   ;;
11023   *)
11024   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11025 for as_dir in $PATH
11026 do
11027   IFS=$as_save_IFS
11028   test -z "$as_dir" && as_dir=.
11029     for ac_exec_ext in '' $ac_executable_extensions; do
11030   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11031     ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext"
11032     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11033     break 2
11034   fi
11035 done
11036   done
11037 IFS=$as_save_IFS
11038 
11039   ;;
11040 esac
11041 fi
11042 WHICH=$ac_cv_path_WHICH
11043 if test -n "$WHICH"; then
11044   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5
11045 $as_echo "$WHICH" >&6; }
11046 else
11047   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11048 $as_echo "no" >&6; }
11049 fi
11050 
11051 
11052   test -n "$WHICH" && break
11053 done
11054 
11055     else
11056       # If it succeeded, then it was overridden by the user. We will use it
11057       # for the tool.
11058 
11059       # First remove it from the list of overridden variables, so we can test
11060       # for unknown variables in the end.
11061       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11062 
11063       # Check if the provided tool contains a complete path.
11064       tool_specified="$WHICH"
11065       tool_basename="${tool_specified##*/}"
11066       if test "x$tool_basename" = "x$tool_specified"; then
11067         # A command without a complete path is provided, search $PATH.
11068         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WHICH=$tool_basename" >&5
11069 $as_echo "$as_me: Will search for user supplied tool WHICH=$tool_basename" >&6;}
11070         # Extract the first word of "$tool_basename", so it can be a program name with args.
11071 set dummy $tool_basename; ac_word=$2
11072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11073 $as_echo_n "checking for $ac_word... " >&6; }
11074 if ${ac_cv_path_WHICH+:} false; then :
11075   $as_echo_n "(cached) " >&6
11076 else
11077   case $WHICH in
11078   [\\/]* | ?:[\\/]*)
11079   ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path.
11080   ;;
11081   *)
11082   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11083 for as_dir in $PATH
11084 do
11085   IFS=$as_save_IFS
11086   test -z "$as_dir" && as_dir=.
11087     for ac_exec_ext in '' $ac_executable_extensions; do
11088   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11089     ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext"
11090     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11091     break 2
11092   fi
11093 done
11094   done
11095 IFS=$as_save_IFS
11096 
11097   ;;
11098 esac
11099 fi
11100 WHICH=$ac_cv_path_WHICH
11101 if test -n "$WHICH"; then
11102   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5
11103 $as_echo "$WHICH" >&6; }
11104 else
11105   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11106 $as_echo "no" >&6; }
11107 fi
11108 
11109 
11110         if test "x$WHICH" = x; then
11111           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11112         fi
11113       else
11114         # Otherwise we believe it is a complete path. Use it as it is.
11115         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WHICH=$tool_specified" >&5
11116 $as_echo "$as_me: Will use user supplied tool WHICH=$tool_specified" >&6;}
11117         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5
11118 $as_echo_n "checking for WHICH... " >&6; }
11119         if test ! -x "$tool_specified"; then
11120           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11121 $as_echo "not found" >&6; }
11122           as_fn_error $? "User supplied tool WHICH=$tool_specified does not exist or is not executable" "$LINENO" 5
11123         fi
11124         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11125 $as_echo "$tool_specified" >&6; }
11126       fi
11127     fi
11128   fi
11129 
11130 
11131 
11132   if test "x$WHICH" = x; then
11133     as_fn_error $? "Could not find required tool for WHICH" "$LINENO" 5
11134   fi
11135 
11136 
11137 
11138 
11139 
11140   # Publish this variable in the help.
11141 
11142 
11143   if test "x$XARGS" = x; then
11144     # The variable is not set by user, try to locate tool using the code snippet
11145     for ac_prog in xargs
11146 do
11147   # Extract the first word of "$ac_prog", so it can be a program name with args.
11148 set dummy $ac_prog; ac_word=$2
11149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11150 $as_echo_n "checking for $ac_word... " >&6; }
11151 if ${ac_cv_path_XARGS+:} false; then :
11152   $as_echo_n "(cached) " >&6
11153 else
11154   case $XARGS in
11155   [\\/]* | ?:[\\/]*)
11156   ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path.
11157   ;;
11158   *)
11159   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11160 for as_dir in $PATH
11161 do
11162   IFS=$as_save_IFS
11163   test -z "$as_dir" && as_dir=.
11164     for ac_exec_ext in '' $ac_executable_extensions; do
11165   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11166     ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext"
11167     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11168     break 2
11169   fi
11170 done
11171   done
11172 IFS=$as_save_IFS
11173 
11174   ;;
11175 esac
11176 fi
11177 XARGS=$ac_cv_path_XARGS
11178 if test -n "$XARGS"; then
11179   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5
11180 $as_echo "$XARGS" >&6; }
11181 else
11182   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11183 $as_echo "no" >&6; }
11184 fi
11185 
11186 
11187   test -n "$XARGS" && break
11188 done
11189 
11190   else
11191     # The variable is set, but is it from the command line or the environment?
11192 
11193     # Try to remove the string !XARGS! from our list.
11194     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XARGS!/}
11195     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11196       # If it failed, the variable was not from the command line. Ignore it,
11197       # but warn the user (except for BASH, which is always set by the calling BASH).
11198       if test "xXARGS" != xBASH; then
11199         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&5
11200 $as_echo "$as_me: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&2;}
11201       fi
11202       # Try to locate tool using the code snippet
11203       for ac_prog in xargs
11204 do
11205   # Extract the first word of "$ac_prog", so it can be a program name with args.
11206 set dummy $ac_prog; ac_word=$2
11207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11208 $as_echo_n "checking for $ac_word... " >&6; }
11209 if ${ac_cv_path_XARGS+:} false; then :
11210   $as_echo_n "(cached) " >&6
11211 else
11212   case $XARGS in
11213   [\\/]* | ?:[\\/]*)
11214   ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path.
11215   ;;
11216   *)
11217   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11218 for as_dir in $PATH
11219 do
11220   IFS=$as_save_IFS
11221   test -z "$as_dir" && as_dir=.
11222     for ac_exec_ext in '' $ac_executable_extensions; do
11223   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11224     ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext"
11225     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11226     break 2
11227   fi
11228 done
11229   done
11230 IFS=$as_save_IFS
11231 
11232   ;;
11233 esac
11234 fi
11235 XARGS=$ac_cv_path_XARGS
11236 if test -n "$XARGS"; then
11237   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5
11238 $as_echo "$XARGS" >&6; }
11239 else
11240   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11241 $as_echo "no" >&6; }
11242 fi
11243 
11244 
11245   test -n "$XARGS" && break
11246 done
11247 
11248     else
11249       # If it succeeded, then it was overridden by the user. We will use it
11250       # for the tool.
11251 
11252       # First remove it from the list of overridden variables, so we can test
11253       # for unknown variables in the end.
11254       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11255 
11256       # Check if the provided tool contains a complete path.
11257       tool_specified="$XARGS"
11258       tool_basename="${tool_specified##*/}"
11259       if test "x$tool_basename" = "x$tool_specified"; then
11260         # A command without a complete path is provided, search $PATH.
11261         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XARGS=$tool_basename" >&5
11262 $as_echo "$as_me: Will search for user supplied tool XARGS=$tool_basename" >&6;}
11263         # Extract the first word of "$tool_basename", so it can be a program name with args.
11264 set dummy $tool_basename; ac_word=$2
11265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11266 $as_echo_n "checking for $ac_word... " >&6; }
11267 if ${ac_cv_path_XARGS+:} false; then :
11268   $as_echo_n "(cached) " >&6
11269 else
11270   case $XARGS in
11271   [\\/]* | ?:[\\/]*)
11272   ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path.
11273   ;;
11274   *)
11275   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11276 for as_dir in $PATH
11277 do
11278   IFS=$as_save_IFS
11279   test -z "$as_dir" && as_dir=.
11280     for ac_exec_ext in '' $ac_executable_extensions; do
11281   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11282     ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext"
11283     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11284     break 2
11285   fi
11286 done
11287   done
11288 IFS=$as_save_IFS
11289 
11290   ;;
11291 esac
11292 fi
11293 XARGS=$ac_cv_path_XARGS
11294 if test -n "$XARGS"; then
11295   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5
11296 $as_echo "$XARGS" >&6; }
11297 else
11298   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11299 $as_echo "no" >&6; }
11300 fi
11301 
11302 
11303         if test "x$XARGS" = x; then
11304           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11305         fi
11306       else
11307         # Otherwise we believe it is a complete path. Use it as it is.
11308         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XARGS=$tool_specified" >&5
11309 $as_echo "$as_me: Will use user supplied tool XARGS=$tool_specified" >&6;}
11310         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5
11311 $as_echo_n "checking for XARGS... " >&6; }
11312         if test ! -x "$tool_specified"; then
11313           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11314 $as_echo "not found" >&6; }
11315           as_fn_error $? "User supplied tool XARGS=$tool_specified does not exist or is not executable" "$LINENO" 5
11316         fi
11317         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11318 $as_echo "$tool_specified" >&6; }
11319       fi
11320     fi
11321   fi
11322 
11323 
11324 
11325   if test "x$XARGS" = x; then
11326     as_fn_error $? "Could not find required tool for XARGS" "$LINENO" 5
11327   fi
11328 
11329 
11330 
11331   # Then required tools that require some special treatment.
11332 
11333 
11334   # Publish this variable in the help.
11335 
11336 
11337   if test "x$AWK" = x; then
11338     # The variable is not set by user, try to locate tool using the code snippet
11339     for ac_prog in gawk mawk nawk awk
11340 do
11341   # Extract the first word of "$ac_prog", so it can be a program name with args.
11342 set dummy $ac_prog; ac_word=$2
11343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11344 $as_echo_n "checking for $ac_word... " >&6; }
11345 if ${ac_cv_prog_AWK+:} false; then :
11346   $as_echo_n "(cached) " >&6
11347 else
11348   if test -n "$AWK"; then
11349   ac_cv_prog_AWK="$AWK" # Let the user override the test.
11350 else
11351 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11352 for as_dir in $PATH
11353 do
11354   IFS=$as_save_IFS
11355   test -z "$as_dir" && as_dir=.
11356     for ac_exec_ext in '' $ac_executable_extensions; do
11357   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11358     ac_cv_prog_AWK="$ac_prog"
11359     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11360     break 2
11361   fi
11362 done
11363   done
11364 IFS=$as_save_IFS
11365 
11366 fi
11367 fi
11368 AWK=$ac_cv_prog_AWK
11369 if test -n "$AWK"; then
11370   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
11371 $as_echo "$AWK" >&6; }
11372 else
11373   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11374 $as_echo "no" >&6; }
11375 fi
11376 
11377 
11378   test -n "$AWK" && break
11379 done
11380 
11381   else
11382     # The variable is set, but is it from the command line or the environment?
11383 
11384     # Try to remove the string !AWK! from our list.
11385     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AWK!/}
11386     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11387       # If it failed, the variable was not from the command line. Ignore it,
11388       # but warn the user (except for BASH, which is always set by the calling BASH).
11389       if test "xAWK" != xBASH; then
11390         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&5
11391 $as_echo "$as_me: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&2;}
11392       fi
11393       # Try to locate tool using the code snippet
11394       for ac_prog in gawk mawk nawk awk
11395 do
11396   # Extract the first word of "$ac_prog", so it can be a program name with args.
11397 set dummy $ac_prog; ac_word=$2
11398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11399 $as_echo_n "checking for $ac_word... " >&6; }
11400 if ${ac_cv_prog_AWK+:} false; then :
11401   $as_echo_n "(cached) " >&6
11402 else
11403   if test -n "$AWK"; then
11404   ac_cv_prog_AWK="$AWK" # Let the user override the test.
11405 else
11406 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11407 for as_dir in $PATH
11408 do
11409   IFS=$as_save_IFS
11410   test -z "$as_dir" && as_dir=.
11411     for ac_exec_ext in '' $ac_executable_extensions; do
11412   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11413     ac_cv_prog_AWK="$ac_prog"
11414     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11415     break 2
11416   fi
11417 done
11418   done
11419 IFS=$as_save_IFS
11420 
11421 fi
11422 fi
11423 AWK=$ac_cv_prog_AWK
11424 if test -n "$AWK"; then
11425   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
11426 $as_echo "$AWK" >&6; }
11427 else
11428   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11429 $as_echo "no" >&6; }
11430 fi
11431 
11432 
11433   test -n "$AWK" && break
11434 done
11435 
11436     else
11437       # If it succeeded, then it was overridden by the user. We will use it
11438       # for the tool.
11439 
11440       # First remove it from the list of overridden variables, so we can test
11441       # for unknown variables in the end.
11442       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11443 
11444       # Check if the provided tool contains a complete path.
11445       tool_specified="$AWK"
11446       tool_basename="${tool_specified##*/}"
11447       if test "x$tool_basename" = "x$tool_specified"; then
11448         # A command without a complete path is provided, search $PATH.
11449         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AWK=$tool_basename" >&5
11450 $as_echo "$as_me: Will search for user supplied tool AWK=$tool_basename" >&6;}
11451         # Extract the first word of "$tool_basename", so it can be a program name with args.
11452 set dummy $tool_basename; ac_word=$2
11453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11454 $as_echo_n "checking for $ac_word... " >&6; }
11455 if ${ac_cv_path_AWK+:} false; then :
11456   $as_echo_n "(cached) " >&6
11457 else
11458   case $AWK in
11459   [\\/]* | ?:[\\/]*)
11460   ac_cv_path_AWK="$AWK" # Let the user override the test with a path.
11461   ;;
11462   *)
11463   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11464 for as_dir in $PATH
11465 do
11466   IFS=$as_save_IFS
11467   test -z "$as_dir" && as_dir=.
11468     for ac_exec_ext in '' $ac_executable_extensions; do
11469   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11470     ac_cv_path_AWK="$as_dir/$ac_word$ac_exec_ext"
11471     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11472     break 2
11473   fi
11474 done
11475   done
11476 IFS=$as_save_IFS
11477 
11478   ;;
11479 esac
11480 fi
11481 AWK=$ac_cv_path_AWK
11482 if test -n "$AWK"; then
11483   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
11484 $as_echo "$AWK" >&6; }
11485 else
11486   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11487 $as_echo "no" >&6; }
11488 fi
11489 
11490 
11491         if test "x$AWK" = x; then
11492           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11493         fi
11494       else
11495         # Otherwise we believe it is a complete path. Use it as it is.
11496         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AWK=$tool_specified" >&5
11497 $as_echo "$as_me: Will use user supplied tool AWK=$tool_specified" >&6;}
11498         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5
11499 $as_echo_n "checking for AWK... " >&6; }
11500         if test ! -x "$tool_specified"; then
11501           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11502 $as_echo "not found" >&6; }
11503           as_fn_error $? "User supplied tool AWK=$tool_specified does not exist or is not executable" "$LINENO" 5
11504         fi
11505         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11506 $as_echo "$tool_specified" >&6; }
11507       fi
11508     fi
11509   fi
11510 
11511 
11512   if test "x$AWK" = x; then
11513     as_fn_error $? "Could not find required tool for AWK" "$LINENO" 5
11514   fi
11515 
11516 
11517 
11518 
11519   # Publish this variable in the help.
11520 
11521 
11522   if test "x$GREP" = x; then
11523     # The variable is not set by user, try to locate tool using the code snippet
11524     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
11525 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
11526 if ${ac_cv_path_GREP+:} false; then :
11527   $as_echo_n "(cached) " >&6
11528 else
11529   if test -z "$GREP"; then
11530   ac_path_GREP_found=false
11531   # Loop through the user's path and test for each of PROGNAME-LIST
11532   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11533 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11534 do
11535   IFS=$as_save_IFS
11536   test -z "$as_dir" && as_dir=.
11537     for ac_prog in grep ggrep; do
11538     for ac_exec_ext in '' $ac_executable_extensions; do
11539       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
11540       as_fn_executable_p "$ac_path_GREP" || continue
11541 # Check for GNU ac_path_GREP and select it if it is found.
11542   # Check for GNU $ac_path_GREP
11543 case `"$ac_path_GREP" --version 2>&1` in
11544 *GNU*)
11545   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
11546 *)
11547   ac_count=0
11548   $as_echo_n 0123456789 >"conftest.in"
11549   while :
11550   do
11551     cat "conftest.in" "conftest.in" >"conftest.tmp"
11552     mv "conftest.tmp" "conftest.in"
11553     cp "conftest.in" "conftest.nl"
11554     $as_echo 'GREP' >> "conftest.nl"
11555     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11556     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11557     as_fn_arith $ac_count + 1 && ac_count=$as_val
11558     if test $ac_count -gt ${ac_path_GREP_max-0}; then
11559       # Best one so far, save it but keep looking for a better one
11560       ac_cv_path_GREP="$ac_path_GREP"
11561       ac_path_GREP_max=$ac_count
11562     fi
11563     # 10*(2^10) chars as input seems more than enough
11564     test $ac_count -gt 10 && break
11565   done
11566   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11567 esac
11568 
11569       $ac_path_GREP_found && break 3
11570     done
11571   done
11572   done
11573 IFS=$as_save_IFS
11574   if test -z "$ac_cv_path_GREP"; then
11575     as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11576   fi
11577 else
11578   ac_cv_path_GREP=$GREP
11579 fi
11580 
11581 fi
11582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
11583 $as_echo "$ac_cv_path_GREP" >&6; }
11584  GREP="$ac_cv_path_GREP"
11585 
11586 
11587   else
11588     # The variable is set, but is it from the command line or the environment?
11589 
11590     # Try to remove the string !GREP! from our list.
11591     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GREP!/}
11592     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11593       # If it failed, the variable was not from the command line. Ignore it,
11594       # but warn the user (except for BASH, which is always set by the calling BASH).
11595       if test "xGREP" != xBASH; then
11596         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&5
11597 $as_echo "$as_me: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&2;}
11598       fi
11599       # Try to locate tool using the code snippet
11600       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
11601 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
11602 if ${ac_cv_path_GREP+:} false; then :
11603   $as_echo_n "(cached) " >&6
11604 else
11605   if test -z "$GREP"; then
11606   ac_path_GREP_found=false
11607   # Loop through the user's path and test for each of PROGNAME-LIST
11608   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11609 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11610 do
11611   IFS=$as_save_IFS
11612   test -z "$as_dir" && as_dir=.
11613     for ac_prog in grep ggrep; do
11614     for ac_exec_ext in '' $ac_executable_extensions; do
11615       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
11616       as_fn_executable_p "$ac_path_GREP" || continue
11617 # Check for GNU ac_path_GREP and select it if it is found.
11618   # Check for GNU $ac_path_GREP
11619 case `"$ac_path_GREP" --version 2>&1` in
11620 *GNU*)
11621   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
11622 *)
11623   ac_count=0
11624   $as_echo_n 0123456789 >"conftest.in"
11625   while :
11626   do
11627     cat "conftest.in" "conftest.in" >"conftest.tmp"
11628     mv "conftest.tmp" "conftest.in"
11629     cp "conftest.in" "conftest.nl"
11630     $as_echo 'GREP' >> "conftest.nl"
11631     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11632     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11633     as_fn_arith $ac_count + 1 && ac_count=$as_val
11634     if test $ac_count -gt ${ac_path_GREP_max-0}; then
11635       # Best one so far, save it but keep looking for a better one
11636       ac_cv_path_GREP="$ac_path_GREP"
11637       ac_path_GREP_max=$ac_count
11638     fi
11639     # 10*(2^10) chars as input seems more than enough
11640     test $ac_count -gt 10 && break
11641   done
11642   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11643 esac
11644 
11645       $ac_path_GREP_found && break 3
11646     done
11647   done
11648   done
11649 IFS=$as_save_IFS
11650   if test -z "$ac_cv_path_GREP"; then
11651     as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11652   fi
11653 else
11654   ac_cv_path_GREP=$GREP
11655 fi
11656 
11657 fi
11658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
11659 $as_echo "$ac_cv_path_GREP" >&6; }
11660  GREP="$ac_cv_path_GREP"
11661 
11662 
11663     else
11664       # If it succeeded, then it was overridden by the user. We will use it
11665       # for the tool.
11666 
11667       # First remove it from the list of overridden variables, so we can test
11668       # for unknown variables in the end.
11669       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11670 
11671       # Check if the provided tool contains a complete path.
11672       tool_specified="$GREP"
11673       tool_basename="${tool_specified##*/}"
11674       if test "x$tool_basename" = "x$tool_specified"; then
11675         # A command without a complete path is provided, search $PATH.
11676         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GREP=$tool_basename" >&5
11677 $as_echo "$as_me: Will search for user supplied tool GREP=$tool_basename" >&6;}
11678         # Extract the first word of "$tool_basename", so it can be a program name with args.
11679 set dummy $tool_basename; ac_word=$2
11680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11681 $as_echo_n "checking for $ac_word... " >&6; }
11682 if ${ac_cv_path_GREP+:} false; then :
11683   $as_echo_n "(cached) " >&6
11684 else
11685   case $GREP in
11686   [\\/]* | ?:[\\/]*)
11687   ac_cv_path_GREP="$GREP" # Let the user override the test with a path.
11688   ;;
11689   *)
11690   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11691 for as_dir in $PATH
11692 do
11693   IFS=$as_save_IFS
11694   test -z "$as_dir" && as_dir=.
11695     for ac_exec_ext in '' $ac_executable_extensions; do
11696   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11697     ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext"
11698     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11699     break 2
11700   fi
11701 done
11702   done
11703 IFS=$as_save_IFS
11704 
11705   ;;
11706 esac
11707 fi
11708 GREP=$ac_cv_path_GREP
11709 if test -n "$GREP"; then
11710   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5
11711 $as_echo "$GREP" >&6; }
11712 else
11713   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11714 $as_echo "no" >&6; }
11715 fi
11716 
11717 
11718         if test "x$GREP" = x; then
11719           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11720         fi
11721       else
11722         # Otherwise we believe it is a complete path. Use it as it is.
11723         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GREP=$tool_specified" >&5
11724 $as_echo "$as_me: Will use user supplied tool GREP=$tool_specified" >&6;}
11725         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5
11726 $as_echo_n "checking for GREP... " >&6; }
11727         if test ! -x "$tool_specified"; then
11728           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11729 $as_echo "not found" >&6; }
11730           as_fn_error $? "User supplied tool GREP=$tool_specified does not exist or is not executable" "$LINENO" 5
11731         fi
11732         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11733 $as_echo "$tool_specified" >&6; }
11734       fi
11735     fi
11736   fi
11737 
11738 
11739   if test "x$GREP" = x; then
11740     as_fn_error $? "Could not find required tool for GREP" "$LINENO" 5
11741   fi
11742 
11743 
11744 
11745 
11746   # Publish this variable in the help.
11747 
11748 
11749   if test "x$EGREP" = x; then
11750     # The variable is not set by user, try to locate tool using the code snippet
11751     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
11752 $as_echo_n "checking for egrep... " >&6; }
11753 if ${ac_cv_path_EGREP+:} false; then :
11754   $as_echo_n "(cached) " >&6
11755 else
11756   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
11757    then ac_cv_path_EGREP="$GREP -E"
11758    else
11759      if test -z "$EGREP"; then
11760   ac_path_EGREP_found=false
11761   # Loop through the user's path and test for each of PROGNAME-LIST
11762   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11763 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11764 do
11765   IFS=$as_save_IFS
11766   test -z "$as_dir" && as_dir=.
11767     for ac_prog in egrep; do
11768     for ac_exec_ext in '' $ac_executable_extensions; do
11769       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
11770       as_fn_executable_p "$ac_path_EGREP" || continue
11771 # Check for GNU ac_path_EGREP and select it if it is found.
11772   # Check for GNU $ac_path_EGREP
11773 case `"$ac_path_EGREP" --version 2>&1` in
11774 *GNU*)
11775   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
11776 *)
11777   ac_count=0
11778   $as_echo_n 0123456789 >"conftest.in"
11779   while :
11780   do
11781     cat "conftest.in" "conftest.in" >"conftest.tmp"
11782     mv "conftest.tmp" "conftest.in"
11783     cp "conftest.in" "conftest.nl"
11784     $as_echo 'EGREP' >> "conftest.nl"
11785     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11786     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11787     as_fn_arith $ac_count + 1 && ac_count=$as_val
11788     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
11789       # Best one so far, save it but keep looking for a better one
11790       ac_cv_path_EGREP="$ac_path_EGREP"
11791       ac_path_EGREP_max=$ac_count
11792     fi
11793     # 10*(2^10) chars as input seems more than enough
11794     test $ac_count -gt 10 && break
11795   done
11796   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11797 esac
11798 
11799       $ac_path_EGREP_found && break 3
11800     done
11801   done
11802   done
11803 IFS=$as_save_IFS
11804   if test -z "$ac_cv_path_EGREP"; then
11805     as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11806   fi
11807 else
11808   ac_cv_path_EGREP=$EGREP
11809 fi
11810 
11811    fi
11812 fi
11813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
11814 $as_echo "$ac_cv_path_EGREP" >&6; }
11815  EGREP="$ac_cv_path_EGREP"
11816 
11817 
11818   else
11819     # The variable is set, but is it from the command line or the environment?
11820 
11821     # Try to remove the string !EGREP! from our list.
11822     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EGREP!/}
11823     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
11824       # If it failed, the variable was not from the command line. Ignore it,
11825       # but warn the user (except for BASH, which is always set by the calling BASH).
11826       if test "xEGREP" != xBASH; then
11827         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&5
11828 $as_echo "$as_me: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&2;}
11829       fi
11830       # Try to locate tool using the code snippet
11831       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
11832 $as_echo_n "checking for egrep... " >&6; }
11833 if ${ac_cv_path_EGREP+:} false; then :
11834   $as_echo_n "(cached) " >&6
11835 else
11836   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
11837    then ac_cv_path_EGREP="$GREP -E"
11838    else
11839      if test -z "$EGREP"; then
11840   ac_path_EGREP_found=false
11841   # Loop through the user's path and test for each of PROGNAME-LIST
11842   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11843 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11844 do
11845   IFS=$as_save_IFS
11846   test -z "$as_dir" && as_dir=.
11847     for ac_prog in egrep; do
11848     for ac_exec_ext in '' $ac_executable_extensions; do
11849       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
11850       as_fn_executable_p "$ac_path_EGREP" || continue
11851 # Check for GNU ac_path_EGREP and select it if it is found.
11852   # Check for GNU $ac_path_EGREP
11853 case `"$ac_path_EGREP" --version 2>&1` in
11854 *GNU*)
11855   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
11856 *)
11857   ac_count=0
11858   $as_echo_n 0123456789 >"conftest.in"
11859   while :
11860   do
11861     cat "conftest.in" "conftest.in" >"conftest.tmp"
11862     mv "conftest.tmp" "conftest.in"
11863     cp "conftest.in" "conftest.nl"
11864     $as_echo 'EGREP' >> "conftest.nl"
11865     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
11866     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
11867     as_fn_arith $ac_count + 1 && ac_count=$as_val
11868     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
11869       # Best one so far, save it but keep looking for a better one
11870       ac_cv_path_EGREP="$ac_path_EGREP"
11871       ac_path_EGREP_max=$ac_count
11872     fi
11873     # 10*(2^10) chars as input seems more than enough
11874     test $ac_count -gt 10 && break
11875   done
11876   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
11877 esac
11878 
11879       $ac_path_EGREP_found && break 3
11880     done
11881   done
11882   done
11883 IFS=$as_save_IFS
11884   if test -z "$ac_cv_path_EGREP"; then
11885     as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
11886   fi
11887 else
11888   ac_cv_path_EGREP=$EGREP
11889 fi
11890 
11891    fi
11892 fi
11893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
11894 $as_echo "$ac_cv_path_EGREP" >&6; }
11895  EGREP="$ac_cv_path_EGREP"
11896 
11897 
11898     else
11899       # If it succeeded, then it was overridden by the user. We will use it
11900       # for the tool.
11901 
11902       # First remove it from the list of overridden variables, so we can test
11903       # for unknown variables in the end.
11904       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
11905 
11906       # Check if the provided tool contains a complete path.
11907       tool_specified="$EGREP"
11908       tool_basename="${tool_specified##*/}"
11909       if test "x$tool_basename" = "x$tool_specified"; then
11910         # A command without a complete path is provided, search $PATH.
11911         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EGREP=$tool_basename" >&5
11912 $as_echo "$as_me: Will search for user supplied tool EGREP=$tool_basename" >&6;}
11913         # Extract the first word of "$tool_basename", so it can be a program name with args.
11914 set dummy $tool_basename; ac_word=$2
11915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11916 $as_echo_n "checking for $ac_word... " >&6; }
11917 if ${ac_cv_path_EGREP+:} false; then :
11918   $as_echo_n "(cached) " >&6
11919 else
11920   case $EGREP in
11921   [\\/]* | ?:[\\/]*)
11922   ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path.
11923   ;;
11924   *)
11925   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11926 for as_dir in $PATH
11927 do
11928   IFS=$as_save_IFS
11929   test -z "$as_dir" && as_dir=.
11930     for ac_exec_ext in '' $ac_executable_extensions; do
11931   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11932     ac_cv_path_EGREP="$as_dir/$ac_word$ac_exec_ext"
11933     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11934     break 2
11935   fi
11936 done
11937   done
11938 IFS=$as_save_IFS
11939 
11940   ;;
11941 esac
11942 fi
11943 EGREP=$ac_cv_path_EGREP
11944 if test -n "$EGREP"; then
11945   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5
11946 $as_echo "$EGREP" >&6; }
11947 else
11948   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11949 $as_echo "no" >&6; }
11950 fi
11951 
11952 
11953         if test "x$EGREP" = x; then
11954           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
11955         fi
11956       else
11957         # Otherwise we believe it is a complete path. Use it as it is.
11958         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EGREP=$tool_specified" >&5
11959 $as_echo "$as_me: Will use user supplied tool EGREP=$tool_specified" >&6;}
11960         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5
11961 $as_echo_n "checking for EGREP... " >&6; }
11962         if test ! -x "$tool_specified"; then
11963           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11964 $as_echo "not found" >&6; }
11965           as_fn_error $? "User supplied tool EGREP=$tool_specified does not exist or is not executable" "$LINENO" 5
11966         fi
11967         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
11968 $as_echo "$tool_specified" >&6; }
11969       fi
11970     fi
11971   fi
11972 
11973 
11974   if test "x$EGREP" = x; then
11975     as_fn_error $? "Could not find required tool for EGREP" "$LINENO" 5
11976   fi
11977 
11978 
11979 
11980 
11981   # Publish this variable in the help.
11982 
11983 
11984   if test "x$FGREP" = x; then
11985     # The variable is not set by user, try to locate tool using the code snippet
11986     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
11987 $as_echo_n "checking for fgrep... " >&6; }
11988 if ${ac_cv_path_FGREP+:} false; then :
11989   $as_echo_n "(cached) " >&6
11990 else
11991   if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
11992    then ac_cv_path_FGREP="$GREP -F"
11993    else
11994      if test -z "$FGREP"; then
11995   ac_path_FGREP_found=false
11996   # Loop through the user's path and test for each of PROGNAME-LIST
11997   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11998 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
11999 do
12000   IFS=$as_save_IFS
12001   test -z "$as_dir" && as_dir=.
12002     for ac_prog in fgrep; do
12003     for ac_exec_ext in '' $ac_executable_extensions; do
12004       ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
12005       as_fn_executable_p "$ac_path_FGREP" || continue
12006 # Check for GNU ac_path_FGREP and select it if it is found.
12007   # Check for GNU $ac_path_FGREP
12008 case `"$ac_path_FGREP" --version 2>&1` in
12009 *GNU*)
12010   ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
12011 *)
12012   ac_count=0
12013   $as_echo_n 0123456789 >"conftest.in"
12014   while :
12015   do
12016     cat "conftest.in" "conftest.in" >"conftest.tmp"
12017     mv "conftest.tmp" "conftest.in"
12018     cp "conftest.in" "conftest.nl"
12019     $as_echo 'FGREP' >> "conftest.nl"
12020     "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
12021     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12022     as_fn_arith $ac_count + 1 && ac_count=$as_val
12023     if test $ac_count -gt ${ac_path_FGREP_max-0}; then
12024       # Best one so far, save it but keep looking for a better one
12025       ac_cv_path_FGREP="$ac_path_FGREP"
12026       ac_path_FGREP_max=$ac_count
12027     fi
12028     # 10*(2^10) chars as input seems more than enough
12029     test $ac_count -gt 10 && break
12030   done
12031   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12032 esac
12033 
12034       $ac_path_FGREP_found && break 3
12035     done
12036   done
12037   done
12038 IFS=$as_save_IFS
12039   if test -z "$ac_cv_path_FGREP"; then
12040     as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
12041   fi
12042 else
12043   ac_cv_path_FGREP=$FGREP
12044 fi
12045 
12046    fi
12047 fi
12048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
12049 $as_echo "$ac_cv_path_FGREP" >&6; }
12050  FGREP="$ac_cv_path_FGREP"
12051 
12052 
12053   else
12054     # The variable is set, but is it from the command line or the environment?
12055 
12056     # Try to remove the string !FGREP! from our list.
12057     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FGREP!/}
12058     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12059       # If it failed, the variable was not from the command line. Ignore it,
12060       # but warn the user (except for BASH, which is always set by the calling BASH).
12061       if test "xFGREP" != xBASH; then
12062         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&5
12063 $as_echo "$as_me: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&2;}
12064       fi
12065       # Try to locate tool using the code snippet
12066       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
12067 $as_echo_n "checking for fgrep... " >&6; }
12068 if ${ac_cv_path_FGREP+:} false; then :
12069   $as_echo_n "(cached) " >&6
12070 else
12071   if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
12072    then ac_cv_path_FGREP="$GREP -F"
12073    else
12074      if test -z "$FGREP"; then
12075   ac_path_FGREP_found=false
12076   # Loop through the user's path and test for each of PROGNAME-LIST
12077   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12078 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
12079 do
12080   IFS=$as_save_IFS
12081   test -z "$as_dir" && as_dir=.
12082     for ac_prog in fgrep; do
12083     for ac_exec_ext in '' $ac_executable_extensions; do
12084       ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
12085       as_fn_executable_p "$ac_path_FGREP" || continue
12086 # Check for GNU ac_path_FGREP and select it if it is found.
12087   # Check for GNU $ac_path_FGREP
12088 case `"$ac_path_FGREP" --version 2>&1` in
12089 *GNU*)
12090   ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
12091 *)
12092   ac_count=0
12093   $as_echo_n 0123456789 >"conftest.in"
12094   while :
12095   do
12096     cat "conftest.in" "conftest.in" >"conftest.tmp"
12097     mv "conftest.tmp" "conftest.in"
12098     cp "conftest.in" "conftest.nl"
12099     $as_echo 'FGREP' >> "conftest.nl"
12100     "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
12101     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12102     as_fn_arith $ac_count + 1 && ac_count=$as_val
12103     if test $ac_count -gt ${ac_path_FGREP_max-0}; then
12104       # Best one so far, save it but keep looking for a better one
12105       ac_cv_path_FGREP="$ac_path_FGREP"
12106       ac_path_FGREP_max=$ac_count
12107     fi
12108     # 10*(2^10) chars as input seems more than enough
12109     test $ac_count -gt 10 && break
12110   done
12111   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12112 esac
12113 
12114       $ac_path_FGREP_found && break 3
12115     done
12116   done
12117   done
12118 IFS=$as_save_IFS
12119   if test -z "$ac_cv_path_FGREP"; then
12120     as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
12121   fi
12122 else
12123   ac_cv_path_FGREP=$FGREP
12124 fi
12125 
12126    fi
12127 fi
12128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
12129 $as_echo "$ac_cv_path_FGREP" >&6; }
12130  FGREP="$ac_cv_path_FGREP"
12131 
12132 
12133     else
12134       # If it succeeded, then it was overridden by the user. We will use it
12135       # for the tool.
12136 
12137       # First remove it from the list of overridden variables, so we can test
12138       # for unknown variables in the end.
12139       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12140 
12141       # Check if the provided tool contains a complete path.
12142       tool_specified="$FGREP"
12143       tool_basename="${tool_specified##*/}"
12144       if test "x$tool_basename" = "x$tool_specified"; then
12145         # A command without a complete path is provided, search $PATH.
12146         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FGREP=$tool_basename" >&5
12147 $as_echo "$as_me: Will search for user supplied tool FGREP=$tool_basename" >&6;}
12148         # Extract the first word of "$tool_basename", so it can be a program name with args.
12149 set dummy $tool_basename; ac_word=$2
12150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12151 $as_echo_n "checking for $ac_word... " >&6; }
12152 if ${ac_cv_path_FGREP+:} false; then :
12153   $as_echo_n "(cached) " >&6
12154 else
12155   case $FGREP in
12156   [\\/]* | ?:[\\/]*)
12157   ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path.
12158   ;;
12159   *)
12160   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12161 for as_dir in $PATH
12162 do
12163   IFS=$as_save_IFS
12164   test -z "$as_dir" && as_dir=.
12165     for ac_exec_ext in '' $ac_executable_extensions; do
12166   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12167     ac_cv_path_FGREP="$as_dir/$ac_word$ac_exec_ext"
12168     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12169     break 2
12170   fi
12171 done
12172   done
12173 IFS=$as_save_IFS
12174 
12175   ;;
12176 esac
12177 fi
12178 FGREP=$ac_cv_path_FGREP
12179 if test -n "$FGREP"; then
12180   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FGREP" >&5
12181 $as_echo "$FGREP" >&6; }
12182 else
12183   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12184 $as_echo "no" >&6; }
12185 fi
12186 
12187 
12188         if test "x$FGREP" = x; then
12189           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12190         fi
12191       else
12192         # Otherwise we believe it is a complete path. Use it as it is.
12193         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FGREP=$tool_specified" >&5
12194 $as_echo "$as_me: Will use user supplied tool FGREP=$tool_specified" >&6;}
12195         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5
12196 $as_echo_n "checking for FGREP... " >&6; }
12197         if test ! -x "$tool_specified"; then
12198           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12199 $as_echo "not found" >&6; }
12200           as_fn_error $? "User supplied tool FGREP=$tool_specified does not exist or is not executable" "$LINENO" 5
12201         fi
12202         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12203 $as_echo "$tool_specified" >&6; }
12204       fi
12205     fi
12206   fi
12207 
12208 
12209   if test "x$FGREP" = x; then
12210     as_fn_error $? "Could not find required tool for FGREP" "$LINENO" 5
12211   fi
12212 
12213 
12214 
12215 
12216   # Publish this variable in the help.
12217 
12218 
12219   if test "x$SED" = x; then
12220     # The variable is not set by user, try to locate tool using the code snippet
12221     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
12222 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
12223 if ${ac_cv_path_SED+:} false; then :
12224   $as_echo_n "(cached) " >&6
12225 else
12226             ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
12227      for ac_i in 1 2 3 4 5 6 7; do
12228        ac_script="$ac_script$as_nl$ac_script"
12229      done
12230      echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
12231      { ac_script=; unset ac_script;}
12232      if test -z "$SED"; then
12233   ac_path_SED_found=false
12234   # Loop through the user's path and test for each of PROGNAME-LIST
12235   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12236 for as_dir in $PATH
12237 do
12238   IFS=$as_save_IFS
12239   test -z "$as_dir" && as_dir=.
12240     for ac_prog in sed gsed; do
12241     for ac_exec_ext in '' $ac_executable_extensions; do
12242       ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
12243       as_fn_executable_p "$ac_path_SED" || continue
12244 # Check for GNU ac_path_SED and select it if it is found.
12245   # Check for GNU $ac_path_SED
12246 case `"$ac_path_SED" --version 2>&1` in
12247 *GNU*)
12248   ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
12249 *)
12250   ac_count=0
12251   $as_echo_n 0123456789 >"conftest.in"
12252   while :
12253   do
12254     cat "conftest.in" "conftest.in" >"conftest.tmp"
12255     mv "conftest.tmp" "conftest.in"
12256     cp "conftest.in" "conftest.nl"
12257     $as_echo '' >> "conftest.nl"
12258     "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
12259     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12260     as_fn_arith $ac_count + 1 && ac_count=$as_val
12261     if test $ac_count -gt ${ac_path_SED_max-0}; then
12262       # Best one so far, save it but keep looking for a better one
12263       ac_cv_path_SED="$ac_path_SED"
12264       ac_path_SED_max=$ac_count
12265     fi
12266     # 10*(2^10) chars as input seems more than enough
12267     test $ac_count -gt 10 && break
12268   done
12269   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12270 esac
12271 
12272       $ac_path_SED_found && break 3
12273     done
12274   done
12275   done
12276 IFS=$as_save_IFS
12277   if test -z "$ac_cv_path_SED"; then
12278     as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
12279   fi
12280 else
12281   ac_cv_path_SED=$SED
12282 fi
12283 
12284 fi
12285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
12286 $as_echo "$ac_cv_path_SED" >&6; }
12287  SED="$ac_cv_path_SED"
12288   rm -f conftest.sed
12289 
12290   else
12291     # The variable is set, but is it from the command line or the environment?
12292 
12293     # Try to remove the string !SED! from our list.
12294     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SED!/}
12295     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12296       # If it failed, the variable was not from the command line. Ignore it,
12297       # but warn the user (except for BASH, which is always set by the calling BASH).
12298       if test "xSED" != xBASH; then
12299         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&5
12300 $as_echo "$as_me: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&2;}
12301       fi
12302       # Try to locate tool using the code snippet
12303       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
12304 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
12305 if ${ac_cv_path_SED+:} false; then :
12306   $as_echo_n "(cached) " >&6
12307 else
12308             ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
12309      for ac_i in 1 2 3 4 5 6 7; do
12310        ac_script="$ac_script$as_nl$ac_script"
12311      done
12312      echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
12313      { ac_script=; unset ac_script;}
12314      if test -z "$SED"; then
12315   ac_path_SED_found=false
12316   # Loop through the user's path and test for each of PROGNAME-LIST
12317   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12318 for as_dir in $PATH
12319 do
12320   IFS=$as_save_IFS
12321   test -z "$as_dir" && as_dir=.
12322     for ac_prog in sed gsed; do
12323     for ac_exec_ext in '' $ac_executable_extensions; do
12324       ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
12325       as_fn_executable_p "$ac_path_SED" || continue
12326 # Check for GNU ac_path_SED and select it if it is found.
12327   # Check for GNU $ac_path_SED
12328 case `"$ac_path_SED" --version 2>&1` in
12329 *GNU*)
12330   ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
12331 *)
12332   ac_count=0
12333   $as_echo_n 0123456789 >"conftest.in"
12334   while :
12335   do
12336     cat "conftest.in" "conftest.in" >"conftest.tmp"
12337     mv "conftest.tmp" "conftest.in"
12338     cp "conftest.in" "conftest.nl"
12339     $as_echo '' >> "conftest.nl"
12340     "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
12341     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
12342     as_fn_arith $ac_count + 1 && ac_count=$as_val
12343     if test $ac_count -gt ${ac_path_SED_max-0}; then
12344       # Best one so far, save it but keep looking for a better one
12345       ac_cv_path_SED="$ac_path_SED"
12346       ac_path_SED_max=$ac_count
12347     fi
12348     # 10*(2^10) chars as input seems more than enough
12349     test $ac_count -gt 10 && break
12350   done
12351   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
12352 esac
12353 
12354       $ac_path_SED_found && break 3
12355     done
12356   done
12357   done
12358 IFS=$as_save_IFS
12359   if test -z "$ac_cv_path_SED"; then
12360     as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
12361   fi
12362 else
12363   ac_cv_path_SED=$SED
12364 fi
12365 
12366 fi
12367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
12368 $as_echo "$ac_cv_path_SED" >&6; }
12369  SED="$ac_cv_path_SED"
12370   rm -f conftest.sed
12371 
12372     else
12373       # If it succeeded, then it was overridden by the user. We will use it
12374       # for the tool.
12375 
12376       # First remove it from the list of overridden variables, so we can test
12377       # for unknown variables in the end.
12378       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12379 
12380       # Check if the provided tool contains a complete path.
12381       tool_specified="$SED"
12382       tool_basename="${tool_specified##*/}"
12383       if test "x$tool_basename" = "x$tool_specified"; then
12384         # A command without a complete path is provided, search $PATH.
12385         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SED=$tool_basename" >&5
12386 $as_echo "$as_me: Will search for user supplied tool SED=$tool_basename" >&6;}
12387         # Extract the first word of "$tool_basename", so it can be a program name with args.
12388 set dummy $tool_basename; ac_word=$2
12389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12390 $as_echo_n "checking for $ac_word... " >&6; }
12391 if ${ac_cv_path_SED+:} false; then :
12392   $as_echo_n "(cached) " >&6
12393 else
12394   case $SED in
12395   [\\/]* | ?:[\\/]*)
12396   ac_cv_path_SED="$SED" # Let the user override the test with a path.
12397   ;;
12398   *)
12399   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12400 for as_dir in $PATH
12401 do
12402   IFS=$as_save_IFS
12403   test -z "$as_dir" && as_dir=.
12404     for ac_exec_ext in '' $ac_executable_extensions; do
12405   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12406     ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext"
12407     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12408     break 2
12409   fi
12410 done
12411   done
12412 IFS=$as_save_IFS
12413 
12414   ;;
12415 esac
12416 fi
12417 SED=$ac_cv_path_SED
12418 if test -n "$SED"; then
12419   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5
12420 $as_echo "$SED" >&6; }
12421 else
12422   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12423 $as_echo "no" >&6; }
12424 fi
12425 
12426 
12427         if test "x$SED" = x; then
12428           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12429         fi
12430       else
12431         # Otherwise we believe it is a complete path. Use it as it is.
12432         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SED=$tool_specified" >&5
12433 $as_echo "$as_me: Will use user supplied tool SED=$tool_specified" >&6;}
12434         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5
12435 $as_echo_n "checking for SED... " >&6; }
12436         if test ! -x "$tool_specified"; then
12437           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12438 $as_echo "not found" >&6; }
12439           as_fn_error $? "User supplied tool SED=$tool_specified does not exist or is not executable" "$LINENO" 5
12440         fi
12441         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12442 $as_echo "$tool_specified" >&6; }
12443       fi
12444     fi
12445   fi
12446 
12447 
12448   if test "x$SED" = x; then
12449     as_fn_error $? "Could not find required tool for SED" "$LINENO" 5
12450   fi
12451 
12452 
12453 
12454   # Always force rm.
12455   RM="$RM -f"
12456 
12457   # pwd behaves differently on various platforms and some don't support the -L flag.
12458   # Always use the bash builtin pwd to get uniform behavior.
12459   THEPWDCMD=pwd
12460 
12461   # These are not required on all platforms
12462 
12463 
12464   # Publish this variable in the help.
12465 
12466 
12467   if test "x$CYGPATH" = x; then
12468     # The variable is not set by user, try to locate tool using the code snippet
12469     for ac_prog in cygpath
12470 do
12471   # Extract the first word of "$ac_prog", so it can be a program name with args.
12472 set dummy $ac_prog; ac_word=$2
12473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12474 $as_echo_n "checking for $ac_word... " >&6; }
12475 if ${ac_cv_path_CYGPATH+:} false; then :
12476   $as_echo_n "(cached) " >&6
12477 else
12478   case $CYGPATH in
12479   [\\/]* | ?:[\\/]*)
12480   ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path.
12481   ;;
12482   *)
12483   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12484 for as_dir in $PATH
12485 do
12486   IFS=$as_save_IFS
12487   test -z "$as_dir" && as_dir=.
12488     for ac_exec_ext in '' $ac_executable_extensions; do
12489   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12490     ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext"
12491     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12492     break 2
12493   fi
12494 done
12495   done
12496 IFS=$as_save_IFS
12497 
12498   ;;
12499 esac
12500 fi
12501 CYGPATH=$ac_cv_path_CYGPATH
12502 if test -n "$CYGPATH"; then
12503   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
12504 $as_echo "$CYGPATH" >&6; }
12505 else
12506   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12507 $as_echo "no" >&6; }
12508 fi
12509 
12510 
12511   test -n "$CYGPATH" && break
12512 done
12513 
12514   else
12515     # The variable is set, but is it from the command line or the environment?
12516 
12517     # Try to remove the string !CYGPATH! from our list.
12518     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CYGPATH!/}
12519     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12520       # If it failed, the variable was not from the command line. Ignore it,
12521       # but warn the user (except for BASH, which is always set by the calling BASH).
12522       if test "xCYGPATH" != xBASH; then
12523         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&5
12524 $as_echo "$as_me: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&2;}
12525       fi
12526       # Try to locate tool using the code snippet
12527       for ac_prog in cygpath
12528 do
12529   # Extract the first word of "$ac_prog", so it can be a program name with args.
12530 set dummy $ac_prog; ac_word=$2
12531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12532 $as_echo_n "checking for $ac_word... " >&6; }
12533 if ${ac_cv_path_CYGPATH+:} false; then :
12534   $as_echo_n "(cached) " >&6
12535 else
12536   case $CYGPATH in
12537   [\\/]* | ?:[\\/]*)
12538   ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path.
12539   ;;
12540   *)
12541   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12542 for as_dir in $PATH
12543 do
12544   IFS=$as_save_IFS
12545   test -z "$as_dir" && as_dir=.
12546     for ac_exec_ext in '' $ac_executable_extensions; do
12547   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12548     ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext"
12549     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12550     break 2
12551   fi
12552 done
12553   done
12554 IFS=$as_save_IFS
12555 
12556   ;;
12557 esac
12558 fi
12559 CYGPATH=$ac_cv_path_CYGPATH
12560 if test -n "$CYGPATH"; then
12561   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
12562 $as_echo "$CYGPATH" >&6; }
12563 else
12564   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12565 $as_echo "no" >&6; }
12566 fi
12567 
12568 
12569   test -n "$CYGPATH" && break
12570 done
12571 
12572     else
12573       # If it succeeded, then it was overridden by the user. We will use it
12574       # for the tool.
12575 
12576       # First remove it from the list of overridden variables, so we can test
12577       # for unknown variables in the end.
12578       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12579 
12580       # Check if the provided tool contains a complete path.
12581       tool_specified="$CYGPATH"
12582       tool_basename="${tool_specified##*/}"
12583       if test "x$tool_basename" = "x$tool_specified"; then
12584         # A command without a complete path is provided, search $PATH.
12585         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CYGPATH=$tool_basename" >&5
12586 $as_echo "$as_me: Will search for user supplied tool CYGPATH=$tool_basename" >&6;}
12587         # Extract the first word of "$tool_basename", so it can be a program name with args.
12588 set dummy $tool_basename; 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_CYGPATH+:} false; then :
12592   $as_echo_n "(cached) " >&6
12593 else
12594   case $CYGPATH in
12595   [\\/]* | ?:[\\/]*)
12596   ac_cv_path_CYGPATH="$CYGPATH" # 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_CYGPATH="$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 CYGPATH=$ac_cv_path_CYGPATH
12618 if test -n "$CYGPATH"; then
12619   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5
12620 $as_echo "$CYGPATH" >&6; }
12621 else
12622   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12623 $as_echo "no" >&6; }
12624 fi
12625 
12626 
12627         if test "x$CYGPATH" = x; then
12628           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12629         fi
12630       else
12631         # Otherwise we believe it is a complete path. Use it as it is.
12632         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CYGPATH=$tool_specified" >&5
12633 $as_echo "$as_me: Will use user supplied tool CYGPATH=$tool_specified" >&6;}
12634         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5
12635 $as_echo_n "checking for CYGPATH... " >&6; }
12636         if test ! -x "$tool_specified"; then
12637           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12638 $as_echo "not found" >&6; }
12639           as_fn_error $? "User supplied tool CYGPATH=$tool_specified does not exist or is not executable" "$LINENO" 5
12640         fi
12641         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12642 $as_echo "$tool_specified" >&6; }
12643       fi
12644     fi
12645   fi
12646 
12647 
12648 
12649 
12650   # Publish this variable in the help.
12651 
12652 
12653   if test "x$READLINK" = x; then
12654     # The variable is not set by user, try to locate tool using the code snippet
12655     for ac_prog in greadlink readlink
12656 do
12657   # Extract the first word of "$ac_prog", so it can be a program name with args.
12658 set dummy $ac_prog; ac_word=$2
12659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12660 $as_echo_n "checking for $ac_word... " >&6; }
12661 if ${ac_cv_path_READLINK+:} false; then :
12662   $as_echo_n "(cached) " >&6
12663 else
12664   case $READLINK in
12665   [\\/]* | ?:[\\/]*)
12666   ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path.
12667   ;;
12668   *)
12669   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12670 for as_dir in $PATH
12671 do
12672   IFS=$as_save_IFS
12673   test -z "$as_dir" && as_dir=.
12674     for ac_exec_ext in '' $ac_executable_extensions; do
12675   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12676     ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext"
12677     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12678     break 2
12679   fi
12680 done
12681   done
12682 IFS=$as_save_IFS
12683 
12684   ;;
12685 esac
12686 fi
12687 READLINK=$ac_cv_path_READLINK
12688 if test -n "$READLINK"; then
12689   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5
12690 $as_echo "$READLINK" >&6; }
12691 else
12692   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12693 $as_echo "no" >&6; }
12694 fi
12695 
12696 
12697   test -n "$READLINK" && break
12698 done
12699 
12700   else
12701     # The variable is set, but is it from the command line or the environment?
12702 
12703     # Try to remove the string !READLINK! from our list.
12704     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READLINK!/}
12705     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12706       # If it failed, the variable was not from the command line. Ignore it,
12707       # but warn the user (except for BASH, which is always set by the calling BASH).
12708       if test "xREADLINK" != xBASH; then
12709         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&5
12710 $as_echo "$as_me: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&2;}
12711       fi
12712       # Try to locate tool using the code snippet
12713       for ac_prog in greadlink readlink
12714 do
12715   # Extract the first word of "$ac_prog", so it can be a program name with args.
12716 set dummy $ac_prog; ac_word=$2
12717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12718 $as_echo_n "checking for $ac_word... " >&6; }
12719 if ${ac_cv_path_READLINK+:} false; then :
12720   $as_echo_n "(cached) " >&6
12721 else
12722   case $READLINK in
12723   [\\/]* | ?:[\\/]*)
12724   ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path.
12725   ;;
12726   *)
12727   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12728 for as_dir in $PATH
12729 do
12730   IFS=$as_save_IFS
12731   test -z "$as_dir" && as_dir=.
12732     for ac_exec_ext in '' $ac_executable_extensions; do
12733   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12734     ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext"
12735     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12736     break 2
12737   fi
12738 done
12739   done
12740 IFS=$as_save_IFS
12741 
12742   ;;
12743 esac
12744 fi
12745 READLINK=$ac_cv_path_READLINK
12746 if test -n "$READLINK"; then
12747   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5
12748 $as_echo "$READLINK" >&6; }
12749 else
12750   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12751 $as_echo "no" >&6; }
12752 fi
12753 
12754 
12755   test -n "$READLINK" && break
12756 done
12757 
12758     else
12759       # If it succeeded, then it was overridden by the user. We will use it
12760       # for the tool.
12761 
12762       # First remove it from the list of overridden variables, so we can test
12763       # for unknown variables in the end.
12764       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12765 
12766       # Check if the provided tool contains a complete path.
12767       tool_specified="$READLINK"
12768       tool_basename="${tool_specified##*/}"
12769       if test "x$tool_basename" = "x$tool_specified"; then
12770         # A command without a complete path is provided, search $PATH.
12771         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READLINK=$tool_basename" >&5
12772 $as_echo "$as_me: Will search for user supplied tool READLINK=$tool_basename" >&6;}
12773         # Extract the first word of "$tool_basename", so it can be a program name with args.
12774 set dummy $tool_basename; 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_READLINK+:} false; then :
12778   $as_echo_n "(cached) " >&6
12779 else
12780   case $READLINK in
12781   [\\/]* | ?:[\\/]*)
12782   ac_cv_path_READLINK="$READLINK" # 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_READLINK="$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 READLINK=$ac_cv_path_READLINK
12804 if test -n "$READLINK"; then
12805   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5
12806 $as_echo "$READLINK" >&6; }
12807 else
12808   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12809 $as_echo "no" >&6; }
12810 fi
12811 
12812 
12813         if test "x$READLINK" = x; then
12814           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
12815         fi
12816       else
12817         # Otherwise we believe it is a complete path. Use it as it is.
12818         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READLINK=$tool_specified" >&5
12819 $as_echo "$as_me: Will use user supplied tool READLINK=$tool_specified" >&6;}
12820         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5
12821 $as_echo_n "checking for READLINK... " >&6; }
12822         if test ! -x "$tool_specified"; then
12823           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
12824 $as_echo "not found" >&6; }
12825           as_fn_error $? "User supplied tool READLINK=$tool_specified does not exist or is not executable" "$LINENO" 5
12826         fi
12827         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
12828 $as_echo "$tool_specified" >&6; }
12829       fi
12830     fi
12831   fi
12832 
12833 
12834 
12835 
12836   # Publish this variable in the help.
12837 
12838 
12839   if test "x$DF" = x; then
12840     # The variable is not set by user, try to locate tool using the code snippet
12841     for ac_prog in df
12842 do
12843   # Extract the first word of "$ac_prog", so it can be a program name with args.
12844 set dummy $ac_prog; ac_word=$2
12845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12846 $as_echo_n "checking for $ac_word... " >&6; }
12847 if ${ac_cv_path_DF+:} false; then :
12848   $as_echo_n "(cached) " >&6
12849 else
12850   case $DF in
12851   [\\/]* | ?:[\\/]*)
12852   ac_cv_path_DF="$DF" # Let the user override the test with a path.
12853   ;;
12854   *)
12855   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12856 for as_dir in $PATH
12857 do
12858   IFS=$as_save_IFS
12859   test -z "$as_dir" && as_dir=.
12860     for ac_exec_ext in '' $ac_executable_extensions; do
12861   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12862     ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext"
12863     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12864     break 2
12865   fi
12866 done
12867   done
12868 IFS=$as_save_IFS
12869 
12870   ;;
12871 esac
12872 fi
12873 DF=$ac_cv_path_DF
12874 if test -n "$DF"; then
12875   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5
12876 $as_echo "$DF" >&6; }
12877 else
12878   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12879 $as_echo "no" >&6; }
12880 fi
12881 
12882 
12883   test -n "$DF" && break
12884 done
12885 
12886   else
12887     # The variable is set, but is it from the command line or the environment?
12888 
12889     # Try to remove the string !DF! from our list.
12890     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DF!/}
12891     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
12892       # If it failed, the variable was not from the command line. Ignore it,
12893       # but warn the user (except for BASH, which is always set by the calling BASH).
12894       if test "xDF" != xBASH; then
12895         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&5
12896 $as_echo "$as_me: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&2;}
12897       fi
12898       # Try to locate tool using the code snippet
12899       for ac_prog in df
12900 do
12901   # Extract the first word of "$ac_prog", so it can be a program name with args.
12902 set dummy $ac_prog; ac_word=$2
12903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12904 $as_echo_n "checking for $ac_word... " >&6; }
12905 if ${ac_cv_path_DF+:} false; then :
12906   $as_echo_n "(cached) " >&6
12907 else
12908   case $DF in
12909   [\\/]* | ?:[\\/]*)
12910   ac_cv_path_DF="$DF" # Let the user override the test with a path.
12911   ;;
12912   *)
12913   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12914 for as_dir in $PATH
12915 do
12916   IFS=$as_save_IFS
12917   test -z "$as_dir" && as_dir=.
12918     for ac_exec_ext in '' $ac_executable_extensions; do
12919   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
12920     ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext"
12921     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12922     break 2
12923   fi
12924 done
12925   done
12926 IFS=$as_save_IFS
12927 
12928   ;;
12929 esac
12930 fi
12931 DF=$ac_cv_path_DF
12932 if test -n "$DF"; then
12933   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5
12934 $as_echo "$DF" >&6; }
12935 else
12936   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12937 $as_echo "no" >&6; }
12938 fi
12939 
12940 
12941   test -n "$DF" && break
12942 done
12943 
12944     else
12945       # If it succeeded, then it was overridden by the user. We will use it
12946       # for the tool.
12947 
12948       # First remove it from the list of overridden variables, so we can test
12949       # for unknown variables in the end.
12950       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
12951 
12952       # Check if the provided tool contains a complete path.
12953       tool_specified="$DF"
12954       tool_basename="${tool_specified##*/}"
12955       if test "x$tool_basename" = "x$tool_specified"; then
12956         # A command without a complete path is provided, search $PATH.
12957         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DF=$tool_basename" >&5
12958 $as_echo "$as_me: Will search for user supplied tool DF=$tool_basename" >&6;}
12959         # Extract the first word of "$tool_basename", so it can be a program name with args.
12960 set dummy $tool_basename; 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_DF+:} false; then :
12964   $as_echo_n "(cached) " >&6
12965 else
12966   case $DF in
12967   [\\/]* | ?:[\\/]*)
12968   ac_cv_path_DF="$DF" # 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_DF="$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 DF=$ac_cv_path_DF
12990 if test -n "$DF"; then
12991   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5
12992 $as_echo "$DF" >&6; }
12993 else
12994   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12995 $as_echo "no" >&6; }
12996 fi
12997 
12998 
12999         if test "x$DF" = x; then
13000           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
13001         fi
13002       else
13003         # Otherwise we believe it is a complete path. Use it as it is.
13004         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DF=$tool_specified" >&5
13005 $as_echo "$as_me: Will use user supplied tool DF=$tool_specified" >&6;}
13006         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5
13007 $as_echo_n "checking for DF... " >&6; }
13008         if test ! -x "$tool_specified"; then
13009           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
13010 $as_echo "not found" >&6; }
13011           as_fn_error $? "User supplied tool DF=$tool_specified does not exist or is not executable" "$LINENO" 5
13012         fi
13013         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
13014 $as_echo "$tool_specified" >&6; }
13015       fi
13016     fi
13017   fi
13018 
13019 
13020 
13021 
13022   # Publish this variable in the help.
13023 
13024 
13025   if test "x$SETFILE" = x; then
13026     # The variable is not set by user, try to locate tool using the code snippet
13027     for ac_prog in SetFile
13028 do
13029   # Extract the first word of "$ac_prog", so it can be a program name with args.
13030 set dummy $ac_prog; ac_word=$2
13031 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13032 $as_echo_n "checking for $ac_word... " >&6; }
13033 if ${ac_cv_path_SETFILE+:} false; then :
13034   $as_echo_n "(cached) " >&6
13035 else
13036   case $SETFILE in
13037   [\\/]* | ?:[\\/]*)
13038   ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path.
13039   ;;
13040   *)
13041   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13042 for as_dir in $PATH
13043 do
13044   IFS=$as_save_IFS
13045   test -z "$as_dir" && as_dir=.
13046     for ac_exec_ext in '' $ac_executable_extensions; do
13047   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13048     ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext"
13049     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13050     break 2
13051   fi
13052 done
13053   done
13054 IFS=$as_save_IFS
13055 
13056   ;;
13057 esac
13058 fi
13059 SETFILE=$ac_cv_path_SETFILE
13060 if test -n "$SETFILE"; then
13061   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5
13062 $as_echo "$SETFILE" >&6; }
13063 else
13064   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13065 $as_echo "no" >&6; }
13066 fi
13067 
13068 
13069   test -n "$SETFILE" && break
13070 done
13071 
13072   else
13073     # The variable is set, but is it from the command line or the environment?
13074 
13075     # Try to remove the string !SETFILE! from our list.
13076     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SETFILE!/}
13077     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
13078       # If it failed, the variable was not from the command line. Ignore it,
13079       # but warn the user (except for BASH, which is always set by the calling BASH).
13080       if test "xSETFILE" != xBASH; then
13081         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&5
13082 $as_echo "$as_me: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&2;}
13083       fi
13084       # Try to locate tool using the code snippet
13085       for ac_prog in SetFile
13086 do
13087   # Extract the first word of "$ac_prog", so it can be a program name with args.
13088 set dummy $ac_prog; ac_word=$2
13089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13090 $as_echo_n "checking for $ac_word... " >&6; }
13091 if ${ac_cv_path_SETFILE+:} false; then :
13092   $as_echo_n "(cached) " >&6
13093 else
13094   case $SETFILE in
13095   [\\/]* | ?:[\\/]*)
13096   ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path.
13097   ;;
13098   *)
13099   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13100 for as_dir in $PATH
13101 do
13102   IFS=$as_save_IFS
13103   test -z "$as_dir" && as_dir=.
13104     for ac_exec_ext in '' $ac_executable_extensions; do
13105   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13106     ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext"
13107     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13108     break 2
13109   fi
13110 done
13111   done
13112 IFS=$as_save_IFS
13113 
13114   ;;
13115 esac
13116 fi
13117 SETFILE=$ac_cv_path_SETFILE
13118 if test -n "$SETFILE"; then
13119   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5
13120 $as_echo "$SETFILE" >&6; }
13121 else
13122   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13123 $as_echo "no" >&6; }
13124 fi
13125 
13126 
13127   test -n "$SETFILE" && break
13128 done
13129 
13130     else
13131       # If it succeeded, then it was overridden by the user. We will use it
13132       # for the tool.
13133 
13134       # First remove it from the list of overridden variables, so we can test
13135       # for unknown variables in the end.
13136       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
13137 
13138       # Check if the provided tool contains a complete path.
13139       tool_specified="$SETFILE"
13140       tool_basename="${tool_specified##*/}"
13141       if test "x$tool_basename" = "x$tool_specified"; then
13142         # A command without a complete path is provided, search $PATH.
13143         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SETFILE=$tool_basename" >&5
13144 $as_echo "$as_me: Will search for user supplied tool SETFILE=$tool_basename" >&6;}
13145         # Extract the first word of "$tool_basename", so it can be a program name with args.
13146 set dummy $tool_basename; ac_word=$2
13147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13148 $as_echo_n "checking for $ac_word... " >&6; }
13149 if ${ac_cv_path_SETFILE+:} false; then :
13150   $as_echo_n "(cached) " >&6
13151 else
13152   case $SETFILE in
13153   [\\/]* | ?:[\\/]*)
13154   ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path.
13155   ;;
13156   *)
13157   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13158 for as_dir in $PATH
13159 do
13160   IFS=$as_save_IFS
13161   test -z "$as_dir" && as_dir=.
13162     for ac_exec_ext in '' $ac_executable_extensions; do
13163   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13164     ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext"
13165     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13166     break 2
13167   fi
13168 done
13169   done
13170 IFS=$as_save_IFS
13171 
13172   ;;
13173 esac
13174 fi
13175 SETFILE=$ac_cv_path_SETFILE
13176 if test -n "$SETFILE"; then
13177   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5
13178 $as_echo "$SETFILE" >&6; }
13179 else
13180   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13181 $as_echo "no" >&6; }
13182 fi
13183 
13184 
13185         if test "x$SETFILE" = x; then
13186           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
13187         fi
13188       else
13189         # Otherwise we believe it is a complete path. Use it as it is.
13190         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SETFILE=$tool_specified" >&5
13191 $as_echo "$as_me: Will use user supplied tool SETFILE=$tool_specified" >&6;}
13192         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5
13193 $as_echo_n "checking for SETFILE... " >&6; }
13194         if test ! -x "$tool_specified"; then
13195           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
13196 $as_echo "not found" >&6; }
13197           as_fn_error $? "User supplied tool SETFILE=$tool_specified does not exist or is not executable" "$LINENO" 5
13198         fi
13199         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
13200 $as_echo "$tool_specified" >&6; }
13201       fi
13202     fi
13203   fi
13204 
13205 
13206 
13207 
13208   # Publish this variable in the help.
13209 
13210 
13211   if test "x$CPIO" = x; then
13212     # The variable is not set by user, try to locate tool using the code snippet
13213     for ac_prog in cpio bsdcpio
13214 do
13215   # Extract the first word of "$ac_prog", so it can be a program name with args.
13216 set dummy $ac_prog; ac_word=$2
13217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13218 $as_echo_n "checking for $ac_word... " >&6; }
13219 if ${ac_cv_path_CPIO+:} false; then :
13220   $as_echo_n "(cached) " >&6
13221 else
13222   case $CPIO in
13223   [\\/]* | ?:[\\/]*)
13224   ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path.
13225   ;;
13226   *)
13227   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13228 for as_dir in $PATH
13229 do
13230   IFS=$as_save_IFS
13231   test -z "$as_dir" && as_dir=.
13232     for ac_exec_ext in '' $ac_executable_extensions; do
13233   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13234     ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext"
13235     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13236     break 2
13237   fi
13238 done
13239   done
13240 IFS=$as_save_IFS
13241 
13242   ;;
13243 esac
13244 fi
13245 CPIO=$ac_cv_path_CPIO
13246 if test -n "$CPIO"; then
13247   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5
13248 $as_echo "$CPIO" >&6; }
13249 else
13250   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13251 $as_echo "no" >&6; }
13252 fi
13253 
13254 
13255   test -n "$CPIO" && break
13256 done
13257 
13258   else
13259     # The variable is set, but is it from the command line or the environment?
13260 
13261     # Try to remove the string !CPIO! from our list.
13262     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CPIO!/}
13263     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
13264       # If it failed, the variable was not from the command line. Ignore it,
13265       # but warn the user (except for BASH, which is always set by the calling BASH).
13266       if test "xCPIO" != xBASH; then
13267         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&5
13268 $as_echo "$as_me: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&2;}
13269       fi
13270       # Try to locate tool using the code snippet
13271       for ac_prog in cpio bsdcpio
13272 do
13273   # Extract the first word of "$ac_prog", so it can be a program name with args.
13274 set dummy $ac_prog; ac_word=$2
13275 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13276 $as_echo_n "checking for $ac_word... " >&6; }
13277 if ${ac_cv_path_CPIO+:} false; then :
13278   $as_echo_n "(cached) " >&6
13279 else
13280   case $CPIO in
13281   [\\/]* | ?:[\\/]*)
13282   ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path.
13283   ;;
13284   *)
13285   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13286 for as_dir in $PATH
13287 do
13288   IFS=$as_save_IFS
13289   test -z "$as_dir" && as_dir=.
13290     for ac_exec_ext in '' $ac_executable_extensions; do
13291   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13292     ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext"
13293     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13294     break 2
13295   fi
13296 done
13297   done
13298 IFS=$as_save_IFS
13299 
13300   ;;
13301 esac
13302 fi
13303 CPIO=$ac_cv_path_CPIO
13304 if test -n "$CPIO"; then
13305   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5
13306 $as_echo "$CPIO" >&6; }
13307 else
13308   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13309 $as_echo "no" >&6; }
13310 fi
13311 
13312 
13313   test -n "$CPIO" && break
13314 done
13315 
13316     else
13317       # If it succeeded, then it was overridden by the user. We will use it
13318       # for the tool.
13319 
13320       # First remove it from the list of overridden variables, so we can test
13321       # for unknown variables in the end.
13322       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
13323 
13324       # Check if the provided tool contains a complete path.
13325       tool_specified="$CPIO"
13326       tool_basename="${tool_specified##*/}"
13327       if test "x$tool_basename" = "x$tool_specified"; then
13328         # A command without a complete path is provided, search $PATH.
13329         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CPIO=$tool_basename" >&5
13330 $as_echo "$as_me: Will search for user supplied tool CPIO=$tool_basename" >&6;}
13331         # Extract the first word of "$tool_basename", so it can be a program name with args.
13332 set dummy $tool_basename; ac_word=$2
13333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13334 $as_echo_n "checking for $ac_word... " >&6; }
13335 if ${ac_cv_path_CPIO+:} false; then :
13336   $as_echo_n "(cached) " >&6
13337 else
13338   case $CPIO in
13339   [\\/]* | ?:[\\/]*)
13340   ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path.
13341   ;;
13342   *)
13343   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13344 for as_dir in $PATH
13345 do
13346   IFS=$as_save_IFS
13347   test -z "$as_dir" && as_dir=.
13348     for ac_exec_ext in '' $ac_executable_extensions; do
13349   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13350     ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext"
13351     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13352     break 2
13353   fi
13354 done
13355   done
13356 IFS=$as_save_IFS
13357 
13358   ;;
13359 esac
13360 fi
13361 CPIO=$ac_cv_path_CPIO
13362 if test -n "$CPIO"; then
13363   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5
13364 $as_echo "$CPIO" >&6; }
13365 else
13366   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13367 $as_echo "no" >&6; }
13368 fi
13369 
13370 
13371         if test "x$CPIO" = x; then
13372           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
13373         fi
13374       else
13375         # Otherwise we believe it is a complete path. Use it as it is.
13376         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CPIO=$tool_specified" >&5
13377 $as_echo "$as_me: Will use user supplied tool CPIO=$tool_specified" >&6;}
13378         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5
13379 $as_echo_n "checking for CPIO... " >&6; }
13380         if test ! -x "$tool_specified"; then
13381           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
13382 $as_echo "not found" >&6; }
13383           as_fn_error $? "User supplied tool CPIO=$tool_specified does not exist or is not executable" "$LINENO" 5
13384         fi
13385         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
13386 $as_echo "$tool_specified" >&6; }
13387       fi
13388     fi
13389   fi
13390 
13391 
13392 
13393 
13394 # Now we can determine OpenJDK build and target platforms. This is required to
13395 # have early on.
13396 # Make sure we can run config.sub.
13397 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
13398   as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
13399 
13400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
13401 $as_echo_n "checking build system type... " >&6; }
13402 if ${ac_cv_build+:} false; then :
13403   $as_echo_n "(cached) " >&6
13404 else
13405   ac_build_alias=$build_alias
13406 test "x$ac_build_alias" = x &&
13407   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
13408 test "x$ac_build_alias" = x &&
13409   as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
13410 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
13411   as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
13412 
13413 fi
13414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
13415 $as_echo "$ac_cv_build" >&6; }
13416 case $ac_cv_build in
13417 *-*-*) ;;
13418 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
13419 esac
13420 build=$ac_cv_build
13421 ac_save_IFS=$IFS; IFS='-'
13422 set x $ac_cv_build
13423 shift
13424 build_cpu=$1
13425 build_vendor=$2
13426 shift; shift
13427 # Remember, the first character of IFS is used to create $*,
13428 # except with old shells:
13429 build_os=$*
13430 IFS=$ac_save_IFS
13431 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
13432 
13433 
13434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
13435 $as_echo_n "checking host system type... " >&6; }
13436 if ${ac_cv_host+:} false; then :
13437   $as_echo_n "(cached) " >&6
13438 else
13439   if test "x$host_alias" = x; then
13440   ac_cv_host=$ac_cv_build
13441 else
13442   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
13443     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
13444 fi
13445 
13446 fi
13447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
13448 $as_echo "$ac_cv_host" >&6; }
13449 case $ac_cv_host in
13450 *-*-*) ;;
13451 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
13452 esac
13453 host=$ac_cv_host
13454 ac_save_IFS=$IFS; IFS='-'
13455 set x $ac_cv_host
13456 shift
13457 host_cpu=$1
13458 host_vendor=$2
13459 shift; shift
13460 # Remember, the first character of IFS is used to create $*,
13461 # except with old shells:
13462 host_os=$*
13463 IFS=$ac_save_IFS
13464 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
13465 
13466 
13467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
13468 $as_echo_n "checking target system type... " >&6; }
13469 if ${ac_cv_target+:} false; then :
13470   $as_echo_n "(cached) " >&6
13471 else
13472   if test "x$target_alias" = x; then
13473   ac_cv_target=$ac_cv_host
13474 else
13475   ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
13476     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
13477 fi
13478 
13479 fi
13480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
13481 $as_echo "$ac_cv_target" >&6; }
13482 case $ac_cv_target in
13483 *-*-*) ;;
13484 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
13485 esac
13486 target=$ac_cv_target
13487 ac_save_IFS=$IFS; IFS='-'
13488 set x $ac_cv_target
13489 shift
13490 target_cpu=$1
13491 target_vendor=$2
13492 shift; shift
13493 # Remember, the first character of IFS is used to create $*,
13494 # except with old shells:
13495 target_os=$*
13496 IFS=$ac_save_IFS
13497 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
13498 
13499 
13500 # The aliases save the names the user supplied, while $host etc.
13501 # will get canonicalized.
13502 test -n "$target_alias" &&
13503   test "$program_prefix$program_suffix$program_transform_name" = \
13504     NONENONEs,x,x, &&
13505   program_prefix=${target_alias}-
13506 
13507   # Figure out the build and target systems. # Note that in autoconf terminology, "build" is obvious, but "target"
13508   # is confusing; it assumes you are cross-compiling a cross-compiler (!)  and "target" is thus the target of the
13509   # product you're building. The target of this build is called "host". Since this is confusing to most people, we
13510   # have not adopted that system, but use "target" as the platform we are building for. In some places though we need
13511   # to use the configure naming style.
13512 
13513 
13514 
13515 
13516 
13517   # Copy the autoconf trip/quadruplet verbatim to OPENJDK_TARGET_AUTOCONF_NAME
13518   # (from the autoconf "host") and OPENJDK_BUILD_AUTOCONF_NAME
13519   # Note that we might later on rewrite e.g. OPENJDK_TARGET_CPU due to reduced build,
13520   # but this will not change the value of OPENJDK_TARGET_AUTOCONF_NAME.
13521   OPENJDK_TARGET_AUTOCONF_NAME="$host"
13522   OPENJDK_BUILD_AUTOCONF_NAME="$build"
13523 
13524 
13525 
13526   # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables.
13527 
13528   case "$build_os" in
13529     *linux*)
13530       VAR_OS=linux
13531       VAR_OS_TYPE=unix
13532       ;;
13533     *solaris*)
13534       VAR_OS=solaris
13535       VAR_OS_TYPE=unix
13536       ;;
13537     *darwin*)
13538       VAR_OS=macosx
13539       VAR_OS_TYPE=unix
13540       ;;
13541     *bsd*)
13542       VAR_OS=bsd
13543       VAR_OS_TYPE=unix
13544       ;;
13545     *cygwin*)
13546       VAR_OS=windows
13547       VAR_OS_ENV=windows.cygwin
13548       ;;
13549     *mingw*)
13550       VAR_OS=windows
13551       VAR_OS_ENV=windows.msys
13552       ;;
13553     *aix*)
13554       VAR_OS=aix
13555       VAR_OS_TYPE=unix
13556       ;;
13557     *)
13558       as_fn_error $? "unsupported operating system $build_os" "$LINENO" 5
13559       ;;
13560   esac
13561 
13562 
13563   # First argument is the cpu name from the trip/quad
13564   case "$build_cpu" in
13565     x86_64)
13566       VAR_CPU=x86_64
13567       VAR_CPU_ARCH=x86
13568       VAR_CPU_BITS=64
13569       VAR_CPU_ENDIAN=little
13570       ;;
13571     i?86)
13572       VAR_CPU=x86
13573       VAR_CPU_ARCH=x86
13574       VAR_CPU_BITS=32
13575       VAR_CPU_ENDIAN=little
13576       ;;
13577     arm*)
13578       VAR_CPU=arm
13579       VAR_CPU_ARCH=arm
13580       VAR_CPU_BITS=32
13581       VAR_CPU_ENDIAN=little
13582       ;;
13583     powerpc)
13584       VAR_CPU=ppc
13585       VAR_CPU_ARCH=ppc
13586       VAR_CPU_BITS=32
13587       VAR_CPU_ENDIAN=big
13588       ;;
13589     powerpc64)
13590       VAR_CPU=ppc64
13591       VAR_CPU_ARCH=ppc
13592       VAR_CPU_BITS=64
13593       VAR_CPU_ENDIAN=big
13594       ;;
13595     powerpc64le)
13596       VAR_CPU=ppc64
13597       VAR_CPU_ARCH=ppc
13598       VAR_CPU_BITS=64
13599       VAR_CPU_ENDIAN=little
13600       ;;
13601     s390)
13602       VAR_CPU=s390
13603       VAR_CPU_ARCH=s390
13604       VAR_CPU_BITS=32
13605       VAR_CPU_ENDIAN=big
13606       ;;
13607     s390x)
13608       VAR_CPU=s390x
13609       VAR_CPU_ARCH=s390
13610       VAR_CPU_BITS=64
13611       VAR_CPU_ENDIAN=big
13612       ;;
13613     sparc)
13614       VAR_CPU=sparc
13615       VAR_CPU_ARCH=sparc
13616       VAR_CPU_BITS=32
13617       VAR_CPU_ENDIAN=big
13618       ;;
13619     sparcv9|sparc64)
13620       VAR_CPU=sparcv9
13621       VAR_CPU_ARCH=sparc
13622       VAR_CPU_BITS=64
13623       VAR_CPU_ENDIAN=big
13624       ;;
13625     *)
13626       as_fn_error $? "unsupported cpu $build_cpu" "$LINENO" 5
13627       ;;
13628   esac
13629 
13630   # ..and setup our own variables. (Do this explicitely to facilitate searching)
13631   OPENJDK_BUILD_OS="$VAR_OS"
13632   if test "x$VAR_OS_TYPE" != x; then
13633     OPENJDK_BUILD_OS_TYPE="$VAR_OS_TYPE"
13634   else
13635     OPENJDK_BUILD_OS_TYPE="$VAR_OS"
13636   fi
13637   if test "x$VAR_OS_ENV" != x; then
13638     OPENJDK_BUILD_OS_ENV="$VAR_OS_ENV"
13639   else
13640     OPENJDK_BUILD_OS_ENV="$VAR_OS"
13641   fi
13642   OPENJDK_BUILD_CPU="$VAR_CPU"
13643   OPENJDK_BUILD_CPU_ARCH="$VAR_CPU_ARCH"
13644   OPENJDK_BUILD_CPU_BITS="$VAR_CPU_BITS"
13645   OPENJDK_BUILD_CPU_ENDIAN="$VAR_CPU_ENDIAN"
13646 
13647 
13648 
13649 
13650 
13651 
13652 
13653 
13654   { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-build os-cpu" >&5
13655 $as_echo_n "checking openjdk-build os-cpu... " >&6; }
13656   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&5
13657 $as_echo "$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&6; }
13658 
13659   # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables.
13660 
13661   case "$host_os" in
13662     *linux*)
13663       VAR_OS=linux
13664       VAR_OS_TYPE=unix
13665       ;;
13666     *solaris*)
13667       VAR_OS=solaris
13668       VAR_OS_TYPE=unix
13669       ;;
13670     *darwin*)
13671       VAR_OS=macosx
13672       VAR_OS_TYPE=unix
13673       ;;
13674     *bsd*)
13675       VAR_OS=bsd
13676       VAR_OS_TYPE=unix
13677       ;;
13678     *cygwin*)
13679       VAR_OS=windows
13680       VAR_OS_ENV=windows.cygwin
13681       ;;
13682     *mingw*)
13683       VAR_OS=windows
13684       VAR_OS_ENV=windows.msys
13685       ;;
13686     *aix*)
13687       VAR_OS=aix
13688       VAR_OS_TYPE=unix
13689       ;;
13690     *)
13691       as_fn_error $? "unsupported operating system $host_os" "$LINENO" 5
13692       ;;
13693   esac
13694 
13695 
13696   # First argument is the cpu name from the trip/quad
13697   case "$host_cpu" in
13698     x86_64)
13699       VAR_CPU=x86_64
13700       VAR_CPU_ARCH=x86
13701       VAR_CPU_BITS=64
13702       VAR_CPU_ENDIAN=little
13703       ;;
13704     i?86)
13705       VAR_CPU=x86
13706       VAR_CPU_ARCH=x86
13707       VAR_CPU_BITS=32
13708       VAR_CPU_ENDIAN=little
13709       ;;
13710     arm*)
13711       VAR_CPU=arm
13712       VAR_CPU_ARCH=arm
13713       VAR_CPU_BITS=32
13714       VAR_CPU_ENDIAN=little
13715       ;;
13716     powerpc)
13717       VAR_CPU=ppc
13718       VAR_CPU_ARCH=ppc
13719       VAR_CPU_BITS=32
13720       VAR_CPU_ENDIAN=big
13721       ;;
13722     powerpc64)
13723       VAR_CPU=ppc64
13724       VAR_CPU_ARCH=ppc
13725       VAR_CPU_BITS=64
13726       VAR_CPU_ENDIAN=big
13727       ;;
13728     powerpc64le)
13729       VAR_CPU=ppc64
13730       VAR_CPU_ARCH=ppc
13731       VAR_CPU_BITS=64
13732       VAR_CPU_ENDIAN=little
13733       ;;
13734     s390)
13735       VAR_CPU=s390
13736       VAR_CPU_ARCH=s390
13737       VAR_CPU_BITS=32
13738       VAR_CPU_ENDIAN=big
13739       ;;
13740     s390x)
13741       VAR_CPU=s390x
13742       VAR_CPU_ARCH=s390
13743       VAR_CPU_BITS=64
13744       VAR_CPU_ENDIAN=big
13745       ;;
13746     sparc)
13747       VAR_CPU=sparc
13748       VAR_CPU_ARCH=sparc
13749       VAR_CPU_BITS=32
13750       VAR_CPU_ENDIAN=big
13751       ;;
13752     sparcv9|sparc64)
13753       VAR_CPU=sparcv9
13754       VAR_CPU_ARCH=sparc
13755       VAR_CPU_BITS=64
13756       VAR_CPU_ENDIAN=big
13757       ;;
13758     *)
13759       as_fn_error $? "unsupported cpu $host_cpu" "$LINENO" 5
13760       ;;
13761   esac
13762 
13763   # ... and setup our own variables. (Do this explicitely to facilitate searching)
13764   OPENJDK_TARGET_OS="$VAR_OS"
13765   if test "x$VAR_OS_TYPE" != x; then
13766     OPENJDK_TARGET_OS_TYPE="$VAR_OS_TYPE"
13767   else
13768     OPENJDK_TARGET_OS_TYPE="$VAR_OS"
13769   fi
13770   if test "x$VAR_OS_ENV" != x; then
13771     OPENJDK_TARGET_OS_ENV="$VAR_OS_ENV"
13772   else
13773     OPENJDK_TARGET_OS_ENV="$VAR_OS"
13774   fi
13775   OPENJDK_TARGET_CPU="$VAR_CPU"
13776   OPENJDK_TARGET_CPU_ARCH="$VAR_CPU_ARCH"
13777   OPENJDK_TARGET_CPU_BITS="$VAR_CPU_BITS"
13778   OPENJDK_TARGET_CPU_ENDIAN="$VAR_CPU_ENDIAN"
13779 
13780 
13781 
13782 
13783 
13784 
13785 
13786 
13787   { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-target os-cpu" >&5
13788 $as_echo_n "checking openjdk-target os-cpu... " >&6; }
13789   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&5
13790 $as_echo "$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&6; }
13791 
13792 
13793 
13794 # Check whether --with-target-bits was given.
13795 if test "${with_target_bits+set}" = set; then :
13796   withval=$with_target_bits;
13797 fi
13798 
13799 
13800   # We have three types of compiles:
13801   # native  == normal compilation, target system == build system
13802   # cross   == traditional cross compilation, target system != build system; special toolchain needed
13803   # reduced == using native compilers, but with special flags (e.g. -m32) to produce 32-bit builds on 64-bit machines
13804   #
13805   if test "x$OPENJDK_BUILD_AUTOCONF_NAME" != "x$OPENJDK_TARGET_AUTOCONF_NAME"; then
13806     # We're doing a proper cross-compilation
13807     COMPILE_TYPE="cross"
13808   else
13809     COMPILE_TYPE="native"
13810   fi
13811 
13812   if test "x$with_target_bits" != x; then
13813     if test "x$COMPILE_TYPE" = "xcross"; then
13814       as_fn_error $? "It is not possible to combine --with-target-bits=X and proper cross-compilation. Choose either." "$LINENO" 5
13815     fi
13816 
13817     if test "x$with_target_bits" = x32 && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
13818       # A reduced build is requested
13819       COMPILE_TYPE="reduced"
13820       OPENJDK_TARGET_CPU_BITS=32
13821       if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then
13822         OPENJDK_TARGET_CPU=x86
13823       elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then
13824         OPENJDK_TARGET_CPU=sparc
13825       else
13826         as_fn_error $? "Reduced build (--with-target-bits=32) is only supported on x86_64 and sparcv9" "$LINENO" 5
13827       fi
13828     elif test "x$with_target_bits" = x64 && test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
13829       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
13830     elif test "x$with_target_bits" = "x$OPENJDK_TARGET_CPU_BITS"; then
13831       { $as_echo "$as_me:${as_lineno-$LINENO}: --with-target-bits are set to build platform address size; argument has no meaning" >&5
13832 $as_echo "$as_me: --with-target-bits are set to build platform address size; argument has no meaning" >&6;}
13833     else
13834       as_fn_error $? "--with-target-bits can only be 32 or 64, you specified $with_target_bits!" "$LINENO" 5
13835     fi
13836   fi
13837 
13838 
13839   { $as_echo "$as_me:${as_lineno-$LINENO}: checking compilation type" >&5
13840 $as_echo_n "checking compilation type... " >&6; }
13841   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPILE_TYPE" >&5
13842 $as_echo "$COMPILE_TYPE" >&6; }
13843 
13844 
13845   if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then
13846     REQUIRED_OS_NAME=SunOS
13847     REQUIRED_OS_VERSION=5.10
13848   fi
13849   if test "x$OPENJDK_TARGET_OS" = "xlinux"; then
13850     REQUIRED_OS_NAME=Linux
13851     REQUIRED_OS_VERSION=2.6
13852   fi
13853   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
13854     REQUIRED_OS_NAME=Windows
13855     if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then
13856       REQUIRED_OS_VERSION=5.2
13857     else
13858       REQUIRED_OS_VERSION=5.1
13859     fi
13860   fi
13861   if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
13862     REQUIRED_OS_NAME=Darwin
13863     REQUIRED_OS_VERSION=11.2
13864   fi
13865 
13866 
13867 
13868 
13869 
13870   # Also store the legacy naming of the cpu.
13871   # Ie i586 and amd64 instead of x86 and x86_64
13872   OPENJDK_TARGET_CPU_LEGACY="$OPENJDK_TARGET_CPU"
13873   if test "x$OPENJDK_TARGET_CPU" = xx86; then
13874     OPENJDK_TARGET_CPU_LEGACY="i586"
13875   elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13876     # On all platforms except MacOSX replace x86_64 with amd64.
13877     OPENJDK_TARGET_CPU_LEGACY="amd64"
13878   fi
13879 
13880 
13881   # And the second legacy naming of the cpu.
13882   # Ie i386 and amd64 instead of x86 and x86_64.
13883   OPENJDK_TARGET_CPU_LEGACY_LIB="$OPENJDK_TARGET_CPU"
13884   if test "x$OPENJDK_TARGET_CPU" = xx86; then
13885     OPENJDK_TARGET_CPU_LEGACY_LIB="i386"
13886   elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13887     OPENJDK_TARGET_CPU_LEGACY_LIB="amd64"
13888   fi
13889 
13890 
13891   # This is the name of the cpu (but using i386 and amd64 instead of
13892   # x86 and x86_64, respectively), preceeded by a /, to be used when
13893   # locating libraries. On macosx, it's empty, though.
13894   OPENJDK_TARGET_CPU_LIBDIR="/$OPENJDK_TARGET_CPU_LEGACY_LIB"
13895   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
13896     OPENJDK_TARGET_CPU_LIBDIR=""
13897   fi
13898 
13899 
13900   # OPENJDK_TARGET_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to
13901   # /amd64 or /sparcv9. This string is appended to some library paths, like this:
13902   # /usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libexample.so
13903   OPENJDK_TARGET_CPU_ISADIR=""
13904   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
13905     if test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13906       OPENJDK_TARGET_CPU_ISADIR="/amd64"
13907     elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then
13908       OPENJDK_TARGET_CPU_ISADIR="/sparcv9"
13909     fi
13910   fi
13911 
13912 
13913   # Setup OPENJDK_TARGET_CPU_OSARCH, which is used to set the os.arch Java system property
13914   OPENJDK_TARGET_CPU_OSARCH="$OPENJDK_TARGET_CPU"
13915   if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$OPENJDK_TARGET_CPU" = xx86; then
13916     # On linux only, we replace x86 with i386.
13917     OPENJDK_TARGET_CPU_OSARCH="i386"
13918   elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13919     # On all platforms except macosx, we replace x86_64 with amd64.
13920     OPENJDK_TARGET_CPU_OSARCH="amd64"
13921   fi
13922 
13923 
13924   OPENJDK_TARGET_CPU_JLI="$OPENJDK_TARGET_CPU"
13925   if test "x$OPENJDK_TARGET_CPU" = xx86; then
13926     OPENJDK_TARGET_CPU_JLI="i386"
13927   elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
13928     # On all platforms except macosx, we replace x86_64 with amd64.
13929     OPENJDK_TARGET_CPU_JLI="amd64"
13930   fi
13931   # Now setup the -D flags for building libjli.
13932   OPENJDK_TARGET_CPU_JLI_CFLAGS="-DLIBARCHNAME='\"$OPENJDK_TARGET_CPU_JLI\"'"
13933   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
13934     if test "x$OPENJDK_TARGET_CPU_ARCH" = xsparc; then
13935       OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"sparc\"' -DLIBARCH64NAME='\"sparcv9\"'"
13936     elif test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then
13937       OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"i386\"' -DLIBARCH64NAME='\"amd64\"'"
13938     fi
13939   fi
13940 
13941 
13942   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
13943       OPENJDK_TARGET_OS_EXPORT_DIR=macosx
13944   else
13945       OPENJDK_TARGET_OS_EXPORT_DIR=${OPENJDK_TARGET_OS_TYPE}
13946   fi
13947 
13948 
13949   if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
13950     A_LP64="LP64:="
13951     # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in
13952     # unpack200.exe
13953     if test "x$OPENJDK_TARGET_OS" = xlinux || test "x$OPENJDK_TARGET_OS" = xmacosx; then
13954       ADD_LP64="-D_LP64=1"
13955     fi
13956   fi
13957   LP64=$A_LP64
13958 
13959 
13960   if test "x$COMPILE_TYPE" = "xcross"; then
13961     # FIXME: ... or should this include reduced builds..?
13962     DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_TARGET_CPU_LEGACY"
13963   else
13964     DEFINE_CROSS_COMPILE_ARCH=""
13965   fi
13966 
13967 
13968   # ZERO_ARCHDEF is used to enable architecture-specific code
13969   case "${OPENJDK_TARGET_CPU}" in
13970     ppc*)    ZERO_ARCHDEF=PPC   ;;
13971     s390*)   ZERO_ARCHDEF=S390  ;;
13972     sparc*)  ZERO_ARCHDEF=SPARC ;;
13973     x86_64*) ZERO_ARCHDEF=AMD64 ;;
13974     x86)     ZERO_ARCHDEF=IA32  ;;
13975     *)      ZERO_ARCHDEF=$(echo "${OPENJDK_TARGET_CPU_LEGACY_LIB}" | tr a-z A-Z)
13976   esac
13977 
13978 
13979 
13980 
13981 # Continue setting up basic stuff. Most remaining code require fundamental tools.
13982 
13983   # Save the current directory this script was started from
13984   CURDIR="$PWD"
13985 
13986   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
13987     PATH_SEP=";"
13988 
13989   SRC_ROOT_LENGTH=`$THEPWDCMD -L|$WC -m`
13990   if test $SRC_ROOT_LENGTH -gt 100; then
13991     as_fn_error $? "Your base path is too long. It is $SRC_ROOT_LENGTH characters long, but only 100 is supported" "$LINENO" 5
13992   fi
13993 
13994   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
13995     { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin release" >&5
13996 $as_echo_n "checking cygwin release... " >&6; }
13997     CYGWIN_VERSION=`$UNAME -r`
13998     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_VERSION" >&5
13999 $as_echo "$CYGWIN_VERSION" >&6; }
14000     WINDOWS_ENV_VENDOR='cygwin'
14001     WINDOWS_ENV_VERSION="$CYGWIN_VERSION"
14002 
14003     CYGWIN_VERSION_OK=`$ECHO $CYGWIN_VERSION | $GREP ^1.7.`
14004     if test "x$CYGWIN_VERSION_OK" = x; then
14005       { $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
14006 $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;}
14007       as_fn_error $? "Cannot continue" "$LINENO" 5
14008     fi
14009     if test "x$CYGPATH" = x; then
14010       as_fn_error $? "Something is wrong with your cygwin installation since I cannot find cygpath.exe in your path" "$LINENO" 5
14011     fi
14012     { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin root directory as unix-style path" >&5
14013 $as_echo_n "checking cygwin root directory as unix-style path... " >&6; }
14014     # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away
14015     cygwin_winpath_root=`cd / ; cmd /c cd | grep ".*"`
14016     # Force cygpath to report the proper root by including a trailing space, and then stripping it off again.
14017     CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "`
14018     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_ROOT_PATH" >&5
14019 $as_echo "$CYGWIN_ROOT_PATH" >&6; }
14020     WINDOWS_ENV_ROOT_PATH="$CYGWIN_ROOT_PATH"
14021     test_cygdrive_prefix=`$ECHO $CYGWIN_ROOT_PATH | $GREP ^/cygdrive/`
14022     if test "x$test_cygdrive_prefix" = x; then
14023       as_fn_error $? "Your cygdrive prefix is not /cygdrive. This is currently not supported. Change with mount -c." "$LINENO" 5
14024     fi
14025   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14026     { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys release" >&5
14027 $as_echo_n "checking msys release... " >&6; }
14028     MSYS_VERSION=`$UNAME -r`
14029     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_VERSION" >&5
14030 $as_echo "$MSYS_VERSION" >&6; }
14031 
14032     WINDOWS_ENV_VENDOR='msys'
14033     WINDOWS_ENV_VERSION="$MSYS_VERSION"
14034 
14035     { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys root directory as unix-style path" >&5
14036 $as_echo_n "checking msys root directory as unix-style path... " >&6; }
14037     # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away
14038     MSYS_ROOT_PATH=`cd / ; cmd /c cd | grep ".*"`
14039 
14040   windows_path="$MSYS_ROOT_PATH"
14041   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14042     unix_path=`$CYGPATH -u "$windows_path"`
14043     MSYS_ROOT_PATH="$unix_path"
14044   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14045     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14046     MSYS_ROOT_PATH="$unix_path"
14047   fi
14048 
14049     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_ROOT_PATH" >&5
14050 $as_echo "$MSYS_ROOT_PATH" >&6; }
14051     WINDOWS_ENV_ROOT_PATH="$MSYS_ROOT_PATH"
14052   else
14053     as_fn_error $? "Unknown Windows environment. Neither cygwin nor msys was detected." "$LINENO" 5
14054   fi
14055 
14056   # Test if windows or unix (cygwin/msys) find is first in path.
14057   { $as_echo "$as_me:${as_lineno-$LINENO}: checking what kind of 'find' is first on the PATH" >&5
14058 $as_echo_n "checking what kind of 'find' is first on the PATH... " >&6; }
14059   FIND_BINARY_OUTPUT=`find --version 2>&1`
14060   if test "x`echo $FIND_BINARY_OUTPUT | $GREP GNU`" != x; then
14061     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unix style" >&5
14062 $as_echo "unix style" >&6; }
14063   elif test "x`echo $FIND_BINARY_OUTPUT | $GREP FIND`" != x; then
14064     { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows" >&5
14065 $as_echo "Windows" >&6; }
14066     { $as_echo "$as_me:${as_lineno-$LINENO}: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&5
14067 $as_echo "$as_me: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&6;}
14068     { $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
14069 $as_echo "$as_me: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&6;}
14070     as_fn_error $? "Cannot continue" "$LINENO" 5
14071   else
14072     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5
14073 $as_echo "unknown" >&6; }
14074     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: It seems that your find utility is non-standard." >&5
14075 $as_echo "$as_me: WARNING: It seems that your find utility is non-standard." >&2;}
14076   fi
14077 
14078   else
14079     PATH_SEP=":"
14080   fi
14081 
14082 
14083   # We get the top-level directory from the supporting wrappers.
14084   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for top-level directory" >&5
14085 $as_echo_n "checking for top-level directory... " >&6; }
14086   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOPDIR" >&5
14087 $as_echo "$TOPDIR" >&6; }
14088 
14089 
14090   # We can only call BASIC_FIXUP_PATH after BASIC_CHECK_PATHS_WINDOWS.
14091 
14092   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14093 
14094   # Input might be given as Windows format, start by converting to
14095   # unix format.
14096   path="$CURDIR"
14097   new_path=`$CYGPATH -u "$path"`
14098 
14099   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14100   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14101   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14102   # "foo.exe" is OK but "foo" is an error.
14103   #
14104   # This test is therefore slightly more accurate than "test -f" to check for file precense.
14105   # It is also a way to make sure we got the proper file name for the real test later on.
14106   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14107   if test "x$test_shortpath" = x; then
14108     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5
14109 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;}
14110     as_fn_error $? "Cannot locate the the path of CURDIR" "$LINENO" 5
14111   fi
14112 
14113   # Call helper function which possibly converts this using DOS-style short mode.
14114   # If so, the updated path is stored in $new_path.
14115 
14116   input_path="$new_path"
14117   # Check if we need to convert this using DOS-style short mode. If the path
14118   # contains just simple characters, use it. Otherwise (spaces, weird characters),
14119   # take no chances and rewrite it.
14120   # Note: m4 eats our [], so we need to use [ and ] instead.
14121   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
14122   if test "x$has_forbidden_chars" != x; then
14123     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14124     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
14125     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
14126     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
14127       # Going to short mode and back again did indeed matter. Since short mode is
14128       # case insensitive, let's make it lowercase to improve readability.
14129       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14130       # Now convert it back to Unix-stile (cygpath)
14131       input_path=`$CYGPATH -u "$shortmode_path"`
14132       new_path="$input_path"
14133     fi
14134   fi
14135 
14136   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
14137   if test "x$test_cygdrive_prefix" = x; then
14138     # As a simple fix, exclude /usr/bin since it's not a real path.
14139     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
14140       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
14141       # a path prefixed by /cygdrive for fixpath to work.
14142       new_path="$CYGWIN_ROOT_PATH$input_path"
14143     fi
14144   fi
14145 
14146 
14147   if test "x$path" != "x$new_path"; then
14148     CURDIR="$new_path"
14149     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5
14150 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;}
14151   fi
14152 
14153   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14154 
14155   path="$CURDIR"
14156   has_colon=`$ECHO $path | $GREP ^.:`
14157   new_path="$path"
14158   if test "x$has_colon" = x; then
14159     # Not in mixed or Windows style, start by that.
14160     new_path=`cmd //c echo $path`
14161   fi
14162 
14163 
14164   input_path="$new_path"
14165   # Check if we need to convert this using DOS-style short mode. If the path
14166   # contains just simple characters, use it. Otherwise (spaces, weird characters),
14167   # take no chances and rewrite it.
14168   # Note: m4 eats our [], so we need to use [ and ] instead.
14169   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
14170   if test "x$has_forbidden_chars" != x; then
14171     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14172     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14173   fi
14174 
14175 
14176   windows_path="$new_path"
14177   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14178     unix_path=`$CYGPATH -u "$windows_path"`
14179     new_path="$unix_path"
14180   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14181     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14182     new_path="$unix_path"
14183   fi
14184 
14185   if test "x$path" != "x$new_path"; then
14186     CURDIR="$new_path"
14187     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5
14188 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;}
14189   fi
14190 
14191   # Save the first 10 bytes of this path to the storage, so fixpath can work.
14192   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
14193 
14194   else
14195     # We're on a unix platform. Hooray! :)
14196     path="$CURDIR"
14197     has_space=`$ECHO "$path" | $GREP " "`
14198     if test "x$has_space" != x; then
14199       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5
14200 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;}
14201       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14202     fi
14203 
14204     # Use eval to expand a potential ~
14205     eval path="$path"
14206     if test ! -f "$path" && test ! -d "$path"; then
14207       as_fn_error $? "The path of CURDIR, which resolves as \"$path\", is not found." "$LINENO" 5
14208     fi
14209 
14210     CURDIR="`cd "$path"; $THEPWDCMD -L`"
14211   fi
14212 
14213 
14214   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14215 
14216   # Input might be given as Windows format, start by converting to
14217   # unix format.
14218   path="$TOPDIR"
14219   new_path=`$CYGPATH -u "$path"`
14220 
14221   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14222   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14223   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14224   # "foo.exe" is OK but "foo" is an error.
14225   #
14226   # This test is therefore slightly more accurate than "test -f" to check for file precense.
14227   # It is also a way to make sure we got the proper file name for the real test later on.
14228   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14229   if test "x$test_shortpath" = x; then
14230     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5
14231 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;}
14232     as_fn_error $? "Cannot locate the the path of TOPDIR" "$LINENO" 5
14233   fi
14234 
14235   # Call helper function which possibly converts this using DOS-style short mode.
14236   # If so, the updated path is stored in $new_path.
14237 
14238   input_path="$new_path"
14239   # Check if we need to convert this using DOS-style short mode. If the path
14240   # contains just simple characters, use it. Otherwise (spaces, weird characters),
14241   # take no chances and rewrite it.
14242   # Note: m4 eats our [], so we need to use [ and ] instead.
14243   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
14244   if test "x$has_forbidden_chars" != x; then
14245     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14246     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
14247     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
14248     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
14249       # Going to short mode and back again did indeed matter. Since short mode is
14250       # case insensitive, let's make it lowercase to improve readability.
14251       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14252       # Now convert it back to Unix-stile (cygpath)
14253       input_path=`$CYGPATH -u "$shortmode_path"`
14254       new_path="$input_path"
14255     fi
14256   fi
14257 
14258   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
14259   if test "x$test_cygdrive_prefix" = x; then
14260     # As a simple fix, exclude /usr/bin since it's not a real path.
14261     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
14262       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
14263       # a path prefixed by /cygdrive for fixpath to work.
14264       new_path="$CYGWIN_ROOT_PATH$input_path"
14265     fi
14266   fi
14267 
14268 
14269   if test "x$path" != "x$new_path"; then
14270     TOPDIR="$new_path"
14271     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5
14272 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;}
14273   fi
14274 
14275   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14276 
14277   path="$TOPDIR"
14278   has_colon=`$ECHO $path | $GREP ^.:`
14279   new_path="$path"
14280   if test "x$has_colon" = x; then
14281     # Not in mixed or Windows style, start by that.
14282     new_path=`cmd //c echo $path`
14283   fi
14284 
14285 
14286   input_path="$new_path"
14287   # Check if we need to convert this using DOS-style short mode. If the path
14288   # contains just simple characters, use it. Otherwise (spaces, weird characters),
14289   # take no chances and rewrite it.
14290   # Note: m4 eats our [], so we need to use [ and ] instead.
14291   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
14292   if test "x$has_forbidden_chars" != x; then
14293     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14294     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14295   fi
14296 
14297 
14298   windows_path="$new_path"
14299   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14300     unix_path=`$CYGPATH -u "$windows_path"`
14301     new_path="$unix_path"
14302   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14303     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14304     new_path="$unix_path"
14305   fi
14306 
14307   if test "x$path" != "x$new_path"; then
14308     TOPDIR="$new_path"
14309     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5
14310 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;}
14311   fi
14312 
14313   # Save the first 10 bytes of this path to the storage, so fixpath can work.
14314   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
14315 
14316   else
14317     # We're on a unix platform. Hooray! :)
14318     path="$TOPDIR"
14319     has_space=`$ECHO "$path" | $GREP " "`
14320     if test "x$has_space" != x; then
14321       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5
14322 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;}
14323       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14324     fi
14325 
14326     # Use eval to expand a potential ~
14327     eval path="$path"
14328     if test ! -f "$path" && test ! -d "$path"; then
14329       as_fn_error $? "The path of TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5
14330     fi
14331 
14332     TOPDIR="`cd "$path"; $THEPWDCMD -L`"
14333   fi
14334 
14335   # SRC_ROOT is a traditional alias for TOPDIR.
14336   SRC_ROOT=$TOPDIR
14337 
14338   # Locate the directory of this script.
14339   AUTOCONF_DIR=$TOPDIR/common/autoconf
14340 
14341 
14342   # Setup default logging of stdout and stderr to build.log in the output root.
14343   BUILD_LOG='$(OUTPUT_ROOT)/build.log'
14344   BUILD_LOG_PREVIOUS='$(OUTPUT_ROOT)/build.log.old'
14345   BUILD_LOG_WRAPPER='$(BASH) $(SRC_ROOT)/common/bin/logger.sh $(BUILD_LOG)'
14346 
14347 
14348 
14349 
14350 
14351 # Check if it's a pure open build or if custom sources are to be used.
14352 
14353   # Check whether --enable-openjdk-only was given.
14354 if test "${enable_openjdk_only+set}" = set; then :
14355   enableval=$enable_openjdk_only;
14356 else
14357   enable_openjdk_only="no"
14358 fi
14359 
14360 
14361   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of closed sources" >&5
14362 $as_echo_n "checking for presence of closed sources... " >&6; }
14363   if test -d "$SRC_ROOT/jdk/src/closed"; then
14364     CLOSED_SOURCE_PRESENT=yes
14365   else
14366     CLOSED_SOURCE_PRESENT=no
14367   fi
14368   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CLOSED_SOURCE_PRESENT" >&5
14369 $as_echo "$CLOSED_SOURCE_PRESENT" >&6; }
14370 
14371   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closed source is suppressed (openjdk-only)" >&5
14372 $as_echo_n "checking if closed source is suppressed (openjdk-only)... " >&6; }
14373   SUPPRESS_CLOSED_SOURCE="$enable_openjdk_only"
14374   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SUPPRESS_CLOSED_SOURCE" >&5
14375 $as_echo "$SUPPRESS_CLOSED_SOURCE" >&6; }
14376 
14377   if test "x$CLOSED_SOURCE_PRESENT" = xno; then
14378     OPENJDK=true
14379     if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then
14380       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: No closed source present, --enable-openjdk-only makes no sense" >&5
14381 $as_echo "$as_me: WARNING: No closed source present, --enable-openjdk-only makes no sense" >&2;}
14382     fi
14383   else
14384     if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then
14385       OPENJDK=true
14386     else
14387       OPENJDK=false
14388     fi
14389   fi
14390 
14391   if test "x$OPENJDK" = "xtrue"; then
14392     SET_OPENJDK="OPENJDK=true"
14393   fi
14394 
14395 
14396 
14397   # custom-make-dir is deprecated. Please use your custom-hook.m4 to override
14398   # the IncludeCustomExtension macro.
14399 
14400 
14401 # Check whether --with-custom-make-dir was given.
14402 if test "${with_custom_make_dir+set}" = set; then :
14403   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
14404 $as_echo "$as_me: WARNING: Option --with-custom-make-dir is deprecated and will be ignored." >&2;}
14405 fi
14406 
14407 
14408 
14409 
14410 # These are needed to be able to create a configuration name (and thus the output directory)
14411 
14412   ###############################################################################
14413   #
14414   # Check which variant of the JDK that we want to build.
14415   # Currently we have:
14416   #    normal:   standard edition
14417   # but the custom make system may add other variants
14418   #
14419   # Effectively the JDK variant gives a name to a specific set of
14420   # modules to compile into the JDK. In the future, these modules
14421   # might even be Jigsaw modules.
14422   #
14423   { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of the JDK to build" >&5
14424 $as_echo_n "checking which variant of the JDK to build... " >&6; }
14425 
14426 # Check whether --with-jdk-variant was given.
14427 if test "${with_jdk_variant+set}" = set; then :
14428   withval=$with_jdk_variant;
14429 fi
14430 
14431 
14432   if test "x$with_jdk_variant" = xnormal || test "x$with_jdk_variant" = x; then
14433     JDK_VARIANT="normal"
14434   else
14435     as_fn_error $? "The available JDK variants are: normal" "$LINENO" 5
14436   fi
14437 
14438 
14439 
14440   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_VARIANT" >&5
14441 $as_echo "$JDK_VARIANT" >&6; }
14442 
14443 
14444 ###############################################################################
14445 #
14446 # Check which interpreter of the JVM we want to build.
14447 # Currently we have:
14448 #    template: Template interpreter (the default)
14449 #    cpp     : C++ interpreter
14450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which interpreter of the JVM to build" >&5
14451 $as_echo_n "checking which interpreter of the JVM to build... " >&6; }
14452 
14453 # Check whether --with-jvm-interpreter was given.
14454 if test "${with_jvm_interpreter+set}" = set; then :
14455   withval=$with_jvm_interpreter;
14456 fi
14457 
14458 
14459 if test "x$with_jvm_interpreter" = x; then
14460      with_jvm_interpreter="template"
14461 fi
14462 
14463 JVM_INTERPRETER="$with_jvm_interpreter"
14464 
14465 if test "x$JVM_INTERPRETER" != xtemplate && test "x$JVM_INTERPRETER" != xcpp; then
14466    as_fn_error $? "The available JVM interpreters are: template, cpp" "$LINENO" 5
14467 fi
14468 
14469 
14470 
14471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_jvm_interpreter" >&5
14472 $as_echo "$with_jvm_interpreter" >&6; }
14473 
14474 
14475 
14476   ###############################################################################
14477   #
14478   # Check which variants of the JVM that we want to build.
14479   # Currently we have:
14480   #    server: normal interpreter and a tiered C1/C2 compiler
14481   #    client: normal interpreter and C1 (no C2 compiler) (only 32-bit platforms)
14482   #    minimal1: reduced form of client with optional VM services and features stripped out
14483   #    kernel: kernel footprint JVM that passes the TCK without major performance problems,
14484   #             ie normal interpreter and C1, only the serial GC, kernel jvmti etc
14485   #    zero: no machine code interpreter, no compiler
14486   #    zeroshark: zero interpreter and shark/llvm compiler backend
14487 #    core: interpreter only, no compiler (only works on some platforms)
14488   { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variants of the JVM to build" >&5
14489 $as_echo_n "checking which variants of the JVM to build... " >&6; }
14490 
14491 # Check whether --with-jvm-variants was given.
14492 if test "${with_jvm_variants+set}" = set; then :
14493   withval=$with_jvm_variants;
14494 fi
14495 
14496 
14497   if test "x$with_jvm_variants" = x; then
14498     with_jvm_variants="server"
14499   fi
14500 
14501   JVM_VARIANTS=",$with_jvm_variants,"
14502   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,//'`
14503 
14504   if test "x$TEST_VARIANTS" != "x,"; then
14505      as_fn_error $? "The available JVM variants are: server, client, minimal1, kernel, zero, zeroshark, core" "$LINENO" 5
14506   fi
14507   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_jvm_variants" >&5
14508 $as_echo "$with_jvm_variants" >&6; }
14509 
14510   JVM_VARIANT_SERVER=`$ECHO "$JVM_VARIANTS" | $SED -e '/,server,/!s/.*/false/g' -e '/,server,/s/.*/true/g'`
14511   JVM_VARIANT_CLIENT=`$ECHO "$JVM_VARIANTS" | $SED -e '/,client,/!s/.*/false/g' -e '/,client,/s/.*/true/g'`
14512   JVM_VARIANT_MINIMAL1=`$ECHO "$JVM_VARIANTS" | $SED -e '/,minimal1,/!s/.*/false/g' -e '/,minimal1,/s/.*/true/g'`
14513   JVM_VARIANT_KERNEL=`$ECHO "$JVM_VARIANTS" | $SED -e '/,kernel,/!s/.*/false/g' -e '/,kernel,/s/.*/true/g'`
14514   JVM_VARIANT_ZERO=`$ECHO "$JVM_VARIANTS" | $SED -e '/,zero,/!s/.*/false/g' -e '/,zero,/s/.*/true/g'`
14515   JVM_VARIANT_ZEROSHARK=`$ECHO "$JVM_VARIANTS" | $SED -e '/,zeroshark,/!s/.*/false/g' -e '/,zeroshark,/s/.*/true/g'`
14516   JVM_VARIANT_CORE=`$ECHO "$JVM_VARIANTS" | $SED -e '/,core,/!s/.*/false/g' -e '/,core,/s/.*/true/g'`
14517 
14518   if test "x$JVM_VARIANT_CLIENT" = xtrue; then
14519     if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
14520       as_fn_error $? "You cannot build a client JVM for a 64-bit machine." "$LINENO" 5
14521     fi
14522   fi
14523   if test "x$JVM_VARIANT_KERNEL" = xtrue; then
14524     if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
14525       as_fn_error $? "You cannot build a kernel JVM for a 64-bit machine." "$LINENO" 5
14526     fi
14527   fi
14528   if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
14529     if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
14530       as_fn_error $? "You cannot build a minimal JVM for a 64-bit machine." "$LINENO" 5
14531     fi
14532   fi
14533 
14534   # Replace the commas with AND for use in the build directory name.
14535   ANDED_JVM_VARIANTS=`$ECHO "$JVM_VARIANTS" | $SED -e 's/^,//' -e 's/,$//' -e 's/,/AND/g'`
14536   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/'`
14537   if test "x$COUNT_VARIANTS" != "x,1"; then
14538     BUILDING_MULTIPLE_JVM_VARIANTS=yes
14539   else
14540     BUILDING_MULTIPLE_JVM_VARIANTS=no
14541   fi
14542 
14543 
14544 
14545 
14546 
14547 
14548 
14549 
14550 
14551 
14552   INCLUDE_SA=true
14553   if test "x$JVM_VARIANT_ZERO" = xtrue ; then
14554     INCLUDE_SA=false
14555   fi
14556   if test "x$JVM_VARIANT_ZEROSHARK" = xtrue ; then
14557     INCLUDE_SA=false
14558   fi
14559   if test "x$OPENJDK_TARGET_OS" = xaix ; then
14560     INCLUDE_SA=false
14561   fi
14562 
14563 
14564   if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
14565     MACOSX_UNIVERSAL="true"
14566   fi
14567 
14568 
14569 
14570 
14571   ###############################################################################
14572   #
14573   # Set the debug level
14574   #    release: no debug information, all optimizations, no asserts.
14575   #    optimized: no debug information, all optimizations, no asserts, HotSpot target is 'optimized'.
14576   #    fastdebug: debug information (-g), all optimizations, all asserts
14577   #    slowdebug: debug information (-g), no optimizations, all asserts
14578   #
14579   DEBUG_LEVEL="release"
14580   { $as_echo "$as_me:${as_lineno-$LINENO}: checking which debug level to use" >&5
14581 $as_echo_n "checking which debug level to use... " >&6; }
14582   # Check whether --enable-debug was given.
14583 if test "${enable_debug+set}" = set; then :
14584   enableval=$enable_debug;
14585         ENABLE_DEBUG="${enableval}"
14586         DEBUG_LEVEL="fastdebug"
14587 
14588 else
14589   ENABLE_DEBUG="no"
14590 fi
14591 
14592 
14593 
14594 # Check whether --with-debug-level was given.
14595 if test "${with_debug_level+set}" = set; then :
14596   withval=$with_debug_level;
14597         DEBUG_LEVEL="${withval}"
14598         if test "x$ENABLE_DEBUG" = xyes; then
14599           as_fn_error $? "You cannot use both --enable-debug and --with-debug-level at the same time." "$LINENO" 5
14600         fi
14601 
14602 fi
14603 
14604   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEBUG_LEVEL" >&5
14605 $as_echo "$DEBUG_LEVEL" >&6; }
14606 
14607   if test "x$DEBUG_LEVEL" != xrelease && \
14608       test "x$DEBUG_LEVEL" != xoptimized && \
14609       test "x$DEBUG_LEVEL" != xfastdebug && \
14610       test "x$DEBUG_LEVEL" != xslowdebug; then
14611     as_fn_error $? "Allowed debug levels are: release, fastdebug and slowdebug" "$LINENO" 5
14612   fi
14613 
14614 
14615   ###############################################################################
14616   #
14617   # Setup legacy vars/targets and new vars to deal with different debug levels.
14618   #
14619 
14620   case $DEBUG_LEVEL in
14621     release )
14622       VARIANT="OPT"
14623       FASTDEBUG="false"
14624       DEBUG_CLASSFILES="false"
14625       BUILD_VARIANT_RELEASE=""
14626       HOTSPOT_DEBUG_LEVEL="product"
14627       HOTSPOT_EXPORT="product"
14628       ;;
14629     fastdebug )
14630       VARIANT="DBG"
14631       FASTDEBUG="true"
14632       DEBUG_CLASSFILES="true"
14633       BUILD_VARIANT_RELEASE="-fastdebug"
14634       HOTSPOT_DEBUG_LEVEL="fastdebug"
14635       HOTSPOT_EXPORT="fastdebug"
14636       ;;
14637     slowdebug )
14638       VARIANT="DBG"
14639       FASTDEBUG="false"
14640       DEBUG_CLASSFILES="true"
14641       BUILD_VARIANT_RELEASE="-debug"
14642       HOTSPOT_DEBUG_LEVEL="debug"
14643       HOTSPOT_EXPORT="debug"
14644       ;;
14645     optimized )
14646       VARIANT="OPT"
14647       FASTDEBUG="false"
14648       DEBUG_CLASSFILES="false"
14649       BUILD_VARIANT_RELEASE="-optimized"
14650       HOTSPOT_DEBUG_LEVEL="optimized"
14651       HOTSPOT_EXPORT="optimized"
14652       ;;
14653   esac
14654 
14655   # The debug level 'optimized' is a little special because it is currently only
14656   # applicable to the HotSpot build where it means to build a completely
14657   # optimized version of the VM without any debugging code (like for the
14658   # 'release' debug level which is called 'product' in the HotSpot build) but
14659   # with the exception that it can contain additional code which is otherwise
14660   # protected by '#ifndef PRODUCT' macros. These 'optimized' builds are used to
14661   # test new and/or experimental features which are not intended for customer
14662   # shipment. Because these new features need to be tested and benchmarked in
14663   # real world scenarios, we want to build the containing JDK at the 'release'
14664   # debug level.
14665   if test "x$DEBUG_LEVEL" = xoptimized; then
14666     DEBUG_LEVEL="release"
14667   fi
14668 
14669   #####
14670   # Generate the legacy makefile targets for hotspot.
14671   # The hotspot api for selecting the build artifacts, really, needs to be improved.
14672   # JDK-7195896 will fix this on the hotspot side by using the JVM_VARIANT_* variables to
14673   # determine what needs to be built. All we will need to set here is all_product, all_fastdebug etc
14674   # But until then ...
14675   HOTSPOT_TARGET=""
14676 
14677   if test "x$JVM_VARIANT_SERVER" = xtrue; then
14678     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL} "
14679   fi
14680 
14681   if test "x$JVM_VARIANT_CLIENT" = xtrue; then
14682     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}1 "
14683   fi
14684 
14685   if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
14686     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}minimal1 "
14687   fi
14688 
14689   if test "x$JVM_VARIANT_KERNEL" = xtrue; then
14690     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}kernel "
14691   fi
14692 
14693   if test "x$JVM_VARIANT_ZERO" = xtrue; then
14694     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}zero "
14695   fi
14696 
14697   if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
14698     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}shark "
14699   fi
14700 
14701   if test "x$JVM_VARIANT_CORE" = xtrue; then
14702     HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}core "
14703   fi
14704 
14705   HOTSPOT_TARGET="$HOTSPOT_TARGET docs export_$HOTSPOT_EXPORT"
14706 
14707   # On Macosx universal binaries are produced, but they only contain
14708   # 64 bit intel. This invalidates control of which jvms are built
14709   # from configure, but only server is valid anyway. Fix this
14710   # when hotspot makefiles are rewritten.
14711   if test "x$MACOSX_UNIVERSAL" = xtrue; then
14712     HOTSPOT_TARGET=universal_${HOTSPOT_EXPORT}
14713   fi
14714 
14715   #####
14716 
14717 
14718 
14719 
14720 
14721 
14722 
14723 
14724 # With basic setup done, call the custom early hook.
14725 
14726 
14727 # Check if we have devkits, extra paths or sysroot set.
14728 
14729 
14730 # Check whether --with-devkit was given.
14731 if test "${with_devkit+set}" = set; then :
14732   withval=$with_devkit;
14733 
14734   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14735 
14736   # Input might be given as Windows format, start by converting to
14737   # unix format.
14738   path="$with_devkit"
14739   new_path=`$CYGPATH -u "$path"`
14740 
14741   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14742   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14743   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14744   # "foo.exe" is OK but "foo" is an error.
14745   #
14746   # This test is therefore slightly more accurate than "test -f" to check for file precense.
14747   # It is also a way to make sure we got the proper file name for the real test later on.
14748   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14749   if test "x$test_shortpath" = x; then
14750     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5
14751 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;}
14752     as_fn_error $? "Cannot locate the the path of with_devkit" "$LINENO" 5
14753   fi
14754 
14755   # Call helper function which possibly converts this using DOS-style short mode.
14756   # If so, the updated path is stored in $new_path.
14757 
14758   input_path="$new_path"
14759   # Check if we need to convert this using DOS-style short mode. If the path
14760   # contains just simple characters, use it. Otherwise (spaces, weird characters),
14761   # take no chances and rewrite it.
14762   # Note: m4 eats our [], so we need to use [ and ] instead.
14763   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
14764   if test "x$has_forbidden_chars" != x; then
14765     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14766     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
14767     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
14768     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
14769       # Going to short mode and back again did indeed matter. Since short mode is
14770       # case insensitive, let's make it lowercase to improve readability.
14771       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14772       # Now convert it back to Unix-stile (cygpath)
14773       input_path=`$CYGPATH -u "$shortmode_path"`
14774       new_path="$input_path"
14775     fi
14776   fi
14777 
14778   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
14779   if test "x$test_cygdrive_prefix" = x; then
14780     # As a simple fix, exclude /usr/bin since it's not a real path.
14781     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
14782       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
14783       # a path prefixed by /cygdrive for fixpath to work.
14784       new_path="$CYGWIN_ROOT_PATH$input_path"
14785     fi
14786   fi
14787 
14788 
14789   if test "x$path" != "x$new_path"; then
14790     with_devkit="$new_path"
14791     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5
14792 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;}
14793   fi
14794 
14795   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14796 
14797   path="$with_devkit"
14798   has_colon=`$ECHO $path | $GREP ^.:`
14799   new_path="$path"
14800   if test "x$has_colon" = x; then
14801     # Not in mixed or Windows style, start by that.
14802     new_path=`cmd //c echo $path`
14803   fi
14804 
14805 
14806   input_path="$new_path"
14807   # Check if we need to convert this using DOS-style short mode. If the path
14808   # contains just simple characters, use it. Otherwise (spaces, weird characters),
14809   # take no chances and rewrite it.
14810   # Note: m4 eats our [], so we need to use [ and ] instead.
14811   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
14812   if test "x$has_forbidden_chars" != x; then
14813     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
14814     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
14815   fi
14816 
14817 
14818   windows_path="$new_path"
14819   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14820     unix_path=`$CYGPATH -u "$windows_path"`
14821     new_path="$unix_path"
14822   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
14823     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
14824     new_path="$unix_path"
14825   fi
14826 
14827   if test "x$path" != "x$new_path"; then
14828     with_devkit="$new_path"
14829     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5
14830 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;}
14831   fi
14832 
14833   # Save the first 10 bytes of this path to the storage, so fixpath can work.
14834   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
14835 
14836   else
14837     # We're on a unix platform. Hooray! :)
14838     path="$with_devkit"
14839     has_space=`$ECHO "$path" | $GREP " "`
14840     if test "x$has_space" != x; then
14841       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5
14842 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;}
14843       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14844     fi
14845 
14846     # Use eval to expand a potential ~
14847     eval path="$path"
14848     if test ! -f "$path" && test ! -d "$path"; then
14849       as_fn_error $? "The path of with_devkit, which resolves as \"$path\", is not found." "$LINENO" 5
14850     fi
14851 
14852     with_devkit="`cd "$path"; $THEPWDCMD -L`"
14853   fi
14854 
14855         DEVKIT_ROOT="$with_devkit"
14856         # Check for a meta data info file in the root of the devkit
14857         if test -f "$DEVKIT_ROOT/devkit.info"; then
14858           # This potentially sets the following:
14859           # DEVKIT_NAME: A descriptive name of the devkit
14860           # DEVKIT_TOOLCHAIN_PATH: Corresponds to --with-toolchain-path
14861           # DEVKIT_EXTRA_PATH: Corresponds to --with-extra-path
14862           # DEVKIT_SYSROOT: Corresponds to --with-sysroot
14863           . $DEVKIT_ROOT/devkit.info
14864         fi
14865 
14866         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for devkit" >&5
14867 $as_echo_n "checking for devkit... " >&6; }
14868         if test "x$DEVKIT_NAME" != x; then
14869           { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_NAME in $DEVKIT_ROOT" >&5
14870 $as_echo "$DEVKIT_NAME in $DEVKIT_ROOT" >&6; }
14871         else
14872           { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_ROOT" >&5
14873 $as_echo "$DEVKIT_ROOT" >&6; }
14874         fi
14875 
14876         if test "x$DEVKIT_EXTRA_PATH" != x; then
14877 
14878   if test "x$DEVKIT_EXTRA_PATH" != x; then
14879     if test "x$EXTRA_PATH" = x; then
14880       EXTRA_PATH="$DEVKIT_EXTRA_PATH"
14881     else
14882       EXTRA_PATH="$DEVKIT_EXTRA_PATH:$EXTRA_PATH"
14883     fi
14884   fi
14885 
14886         fi
14887 
14888         # Fallback default of just /bin if DEVKIT_PATH is not defined
14889         if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then
14890           DEVKIT_TOOLCHAIN_PATH="$DEVKIT_ROOT/bin"
14891         fi
14892 
14893   if test "x$DEVKIT_TOOLCHAIN_PATH" != x; then
14894     if test "x$TOOLCHAIN_PATH" = x; then
14895       TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH"
14896     else
14897       TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH:$TOOLCHAIN_PATH"
14898     fi
14899   fi
14900 
14901 
14902         # If DEVKIT_SYSROOT is set, use that, otherwise try a couple of known
14903         # places for backwards compatiblity.
14904         if test "x$DEVKIT_SYSROOT" != x; then
14905           SYSROOT="$DEVKIT_SYSROOT"
14906         elif test -d "$DEVKIT_ROOT/$host_alias/libc"; then
14907           SYSROOT="$DEVKIT_ROOT/$host_alias/libc"
14908         elif test -d "$DEVKIT_ROOT/$host/sys-root"; then
14909           SYSROOT="$DEVKIT_ROOT/$host/sys-root"
14910         fi
14911 
14912 
14913 fi
14914 
14915 
14916   # You can force the sysroot if the sysroot encoded into the compiler tools
14917   # is not correct.
14918 
14919 # Check whether --with-sys-root was given.
14920 if test "${with_sys_root+set}" = set; then :
14921   withval=$with_sys_root; SYSROOT=$with_sys_root
14922 
14923 fi
14924 
14925 
14926 
14927 # Check whether --with-sysroot was given.
14928 if test "${with_sysroot+set}" = set; then :
14929   withval=$with_sysroot; SYSROOT=$with_sysroot
14930 
14931 fi
14932 
14933 
14934 
14935 # Check whether --with-tools-dir was given.
14936 if test "${with_tools_dir+set}" = set; then :
14937   withval=$with_tools_dir;
14938   if test "x$with_tools_dir" != x; then
14939     if test "x$TOOLCHAIN_PATH" = x; then
14940       TOOLCHAIN_PATH="$with_tools_dir"
14941     else
14942       TOOLCHAIN_PATH="$with_tools_dir:$TOOLCHAIN_PATH"
14943     fi
14944   fi
14945 
14946 
14947 fi
14948 
14949 
14950 
14951 # Check whether --with-toolchain-path was given.
14952 if test "${with_toolchain_path+set}" = set; then :
14953   withval=$with_toolchain_path;
14954   if test "x$with_toolchain_path" != x; then
14955     if test "x$TOOLCHAIN_PATH" = x; then
14956       TOOLCHAIN_PATH="$with_toolchain_path"
14957     else
14958       TOOLCHAIN_PATH="$with_toolchain_path:$TOOLCHAIN_PATH"
14959     fi
14960   fi
14961 
14962 
14963 fi
14964 
14965 
14966 
14967 # Check whether --with-extra-path was given.
14968 if test "${with_extra_path+set}" = set; then :
14969   withval=$with_extra_path;
14970   if test "x$with_extra_path" != x; then
14971     if test "x$EXTRA_PATH" = x; then
14972       EXTRA_PATH="$with_extra_path"
14973     else
14974       EXTRA_PATH="$with_extra_path:$EXTRA_PATH"
14975     fi
14976   fi
14977 
14978 
14979 fi
14980 
14981 
14982   if test "x$OPENJDK_BUILD_OS" = "xmacosx"; then
14983     # detect if Xcode is installed by running xcodebuild -version
14984     # if no Xcode installed, xcodebuild exits with 1
14985     # if Xcode is installed, even if xcode-select is misconfigured, then it exits with 0
14986     if /usr/bin/xcodebuild -version >/dev/null 2>&1; then
14987       # We need to use xcodebuild in the toolchain dir provided by the user, this will
14988       # fall back on the stub binary in /usr/bin/xcodebuild
14989       # Extract the first word of "xcodebuild", so it can be a program name with args.
14990 set dummy xcodebuild; ac_word=$2
14991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14992 $as_echo_n "checking for $ac_word... " >&6; }
14993 if ${ac_cv_path_XCODEBUILD+:} false; then :
14994   $as_echo_n "(cached) " >&6
14995 else
14996   case $XCODEBUILD in
14997   [\\/]* | ?:[\\/]*)
14998   ac_cv_path_XCODEBUILD="$XCODEBUILD" # Let the user override the test with a path.
14999   ;;
15000   *)
15001   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15002 for as_dir in $TOOLCHAIN_PATH
15003 do
15004   IFS=$as_save_IFS
15005   test -z "$as_dir" && as_dir=.
15006     for ac_exec_ext in '' $ac_executable_extensions; do
15007   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15008     ac_cv_path_XCODEBUILD="$as_dir/$ac_word$ac_exec_ext"
15009     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15010     break 2
15011   fi
15012 done
15013   done
15014 IFS=$as_save_IFS
15015 
15016   test -z "$ac_cv_path_XCODEBUILD" && ac_cv_path_XCODEBUILD="/usr/bin/xcodebuild"
15017   ;;
15018 esac
15019 fi
15020 XCODEBUILD=$ac_cv_path_XCODEBUILD
15021 if test -n "$XCODEBUILD"; then
15022   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XCODEBUILD" >&5
15023 $as_echo "$XCODEBUILD" >&6; }
15024 else
15025   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15026 $as_echo "no" >&6; }
15027 fi
15028 
15029 
15030     else
15031       # this should result in SYSROOT being empty, unless --with-sysroot is provided
15032       # when only the command line tools are installed there are no SDKs, so headers
15033       # are copied into the system frameworks
15034       XCODEBUILD=
15035 
15036     fi
15037 
15038     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sdk name" >&5
15039 $as_echo_n "checking for sdk name... " >&6; }
15040 
15041 # Check whether --with-sdk-name was given.
15042 if test "${with_sdk_name+set}" = set; then :
15043   withval=$with_sdk_name; SDKNAME=$with_sdk_name
15044 
15045 fi
15046 
15047     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SDKNAME" >&5
15048 $as_echo "$SDKNAME" >&6; }
15049 
15050     # if toolchain path is specified then don't rely on system headers, they may not compile
15051     HAVE_SYSTEM_FRAMEWORK_HEADERS=0
15052     test -z "$TOOLCHAIN_PATH" && \
15053       HAVE_SYSTEM_FRAMEWORK_HEADERS=`test ! -f /System/Library/Frameworks/Foundation.framework/Headers/Foundation.h; echo $?`
15054 
15055     if test -z "$SYSROOT"; then
15056       if test -n "$XCODEBUILD"; then
15057         # if we don't have system headers, use default SDK name (last resort)
15058         if test -z "$SDKNAME" -a $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then
15059           SDKNAME=${SDKNAME:-macosx}
15060         fi
15061 
15062         if test -n "$SDKNAME"; then
15063           # Call xcodebuild to determine SYSROOT
15064           SYSROOT=`"$XCODEBUILD" -sdk $SDKNAME -version | grep '^Path: ' | sed 's/Path: //'`
15065         fi
15066       else
15067         if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then
15068           as_fn_error $? "No xcodebuild tool and no system framework headers found, use --with-sysroot or --with-sdk-name to provide a path to a valid SDK" "$LINENO" 5
15069         fi
15070       fi
15071     else
15072       # warn user if --with-sdk-name was also set
15073       if test -n "$with_sdk_name"; then
15074         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&5
15075 $as_echo "$as_me: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&2;}
15076       fi
15077     fi
15078 
15079     if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0 -a -z "$SYSROOT"; then
15080       # If no system framework headers, then SYSROOT must be set, or we won't build
15081       as_fn_error $? "Unable to determine SYSROOT and no headers found in /System/Library/Frameworks. Check Xcode configuration, --with-sysroot or --with-sdk-name arguments." "$LINENO" 5
15082     fi
15083 
15084     # Perform a basic sanity test
15085     if test ! -f "$SYSROOT/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h"; then
15086       if test -z "$SYSROOT"; then
15087         as_fn_error $? "Unable to find required framework headers, provide a path to an SDK via --with-sysroot or --with-sdk-name and be sure Xcode is installed properly" "$LINENO" 5
15088       else
15089         as_fn_error $? "Invalid SDK or SYSROOT path, dependent framework headers not found" "$LINENO" 5
15090       fi
15091     fi
15092 
15093     # set SDKROOT too, Xcode tools will pick it up
15094     SDKROOT=$SYSROOT
15095 
15096   fi
15097 
15098   # Prepend the extra path to the global path
15099 
15100   if test "x$EXTRA_PATH" != x; then
15101     if test "x$PATH" = x; then
15102       PATH="$EXTRA_PATH"
15103     else
15104       PATH="$EXTRA_PATH:$PATH"
15105     fi
15106   fi
15107 
15108 
15109   if test "x$OPENJDK_BUILD_OS" = "xsolaris"; then
15110     # Add extra search paths on solaris for utilities like ar and as etc...
15111     PATH="$PATH:/usr/ccs/bin:/usr/sfw/bin:/opt/csw/bin"
15112   fi
15113 
15114   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
15115 $as_echo_n "checking for sysroot... " >&6; }
15116   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYSROOT" >&5
15117 $as_echo "$SYSROOT" >&6; }
15118   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for toolchain path" >&5
15119 $as_echo_n "checking for toolchain path... " >&6; }
15120   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH" >&5
15121 $as_echo "$TOOLCHAIN_PATH" >&6; }
15122   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for extra path" >&5
15123 $as_echo_n "checking for extra path... " >&6; }
15124   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXTRA_PATH" >&5
15125 $as_echo "$EXTRA_PATH" >&6; }
15126 
15127 
15128 # To properly create a configuration name, we need to have the OpenJDK target
15129 # and options (variants and debug level) parsed.
15130 
15131 
15132 
15133 # Check whether --with-conf-name was given.
15134 if test "${with_conf_name+set}" = set; then :
15135   withval=$with_conf_name;  CONF_NAME=${with_conf_name}
15136 fi
15137 
15138 
15139   # Test from where we are running configure, in or outside of src root.
15140   { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to store configuration" >&5
15141 $as_echo_n "checking where to store configuration... " >&6; }
15142   if test "x$CURDIR" = "x$SRC_ROOT" || test "x$CURDIR" = "x$SRC_ROOT/common" \
15143       || test "x$CURDIR" = "x$SRC_ROOT/common/autoconf" \
15144       || test "x$CURDIR" = "x$SRC_ROOT/make" ; then
15145     # We are running configure from the src root.
15146     # Create a default ./build/target-variant-debuglevel output root.
15147     if test "x${CONF_NAME}" = x; then
15148       { $as_echo "$as_me:${as_lineno-$LINENO}: result: in default location" >&5
15149 $as_echo "in default location" >&6; }
15150       CONF_NAME="${OPENJDK_TARGET_OS}-${OPENJDK_TARGET_CPU}-${JDK_VARIANT}-${ANDED_JVM_VARIANTS}-${DEBUG_LEVEL}"
15151     else
15152       { $as_echo "$as_me:${as_lineno-$LINENO}: result: in build directory with custom name" >&5
15153 $as_echo "in build directory with custom name" >&6; }
15154     fi
15155     OUTPUT_ROOT="$SRC_ROOT/build/${CONF_NAME}"
15156     $MKDIR -p "$OUTPUT_ROOT"
15157     if test ! -d "$OUTPUT_ROOT"; then
15158       as_fn_error $? "Could not create build directory $OUTPUT_ROOT" "$LINENO" 5
15159     fi
15160   else
15161     # We are running configure from outside of the src dir.
15162     # Then use the current directory as output dir!
15163     # If configuration is situated in normal build directory, just use the build
15164     # directory name as configuration name, otherwise use the complete path.
15165     if test "x${CONF_NAME}" = x; then
15166       CONF_NAME=`$ECHO $CURDIR | $SED -e "s!^${SRC_ROOT}/build/!!"`
15167     fi
15168     OUTPUT_ROOT="$CURDIR"
15169     { $as_echo "$as_me:${as_lineno-$LINENO}: result: in current directory" >&5
15170 $as_echo "in current directory" >&6; }
15171 
15172     # WARNING: This might be a bad thing to do. You need to be sure you want to
15173     # have a configuration in this directory. Do some sanity checks!
15174 
15175     if test ! -e "$OUTPUT_ROOT/spec.gmk"; then
15176       # If we have a spec.gmk, we have run here before and we are OK. Otherwise, check for
15177       # other files
15178       files_present=`$LS $OUTPUT_ROOT`
15179       # Configure has already touched config.log and confdefs.h in the current dir when this check
15180       # is performed.
15181       filtered_files=`$ECHO "$files_present" | $SED -e 's/config.log//g' -e 's/confdefs.h//g' -e 's/ //g' \
15182       | $TR -d '\n'`
15183       if test "x$filtered_files" != x; then
15184         { $as_echo "$as_me:${as_lineno-$LINENO}: Current directory is $CURDIR." >&5
15185 $as_echo "$as_me: Current directory is $CURDIR." >&6;}
15186         { $as_echo "$as_me:${as_lineno-$LINENO}: Since this is not the source root, configure will output the configuration here" >&5
15187 $as_echo "$as_me: Since this is not the source root, configure will output the configuration here" >&6;}
15188         { $as_echo "$as_me:${as_lineno-$LINENO}: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&5
15189 $as_echo "$as_me: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&6;}
15190         { $as_echo "$as_me:${as_lineno-$LINENO}: However, this directory is not empty. This is not allowed, since it could" >&5
15191 $as_echo "$as_me: However, this directory is not empty. This is not allowed, since it could" >&6;}
15192         { $as_echo "$as_me:${as_lineno-$LINENO}: seriously mess up just about everything." >&5
15193 $as_echo "$as_me: seriously mess up just about everything." >&6;}
15194         { $as_echo "$as_me:${as_lineno-$LINENO}: Try 'cd $SRC_ROOT' and restart configure" >&5
15195 $as_echo "$as_me: Try 'cd $SRC_ROOT' and restart configure" >&6;}
15196         { $as_echo "$as_me:${as_lineno-$LINENO}: (or create a new empty directory and cd to it)." >&5
15197 $as_echo "$as_me: (or create a new empty directory and cd to it)." >&6;}
15198         as_fn_error $? "Will not continue creating configuration in $CURDIR" "$LINENO" 5
15199       fi
15200     fi
15201   fi
15202   { $as_echo "$as_me:${as_lineno-$LINENO}: checking what configuration name to use" >&5
15203 $as_echo_n "checking what configuration name to use... " >&6; }
15204   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONF_NAME" >&5
15205 $as_echo "$CONF_NAME" >&6; }
15206 
15207 
15208   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15209 
15210   # Input might be given as Windows format, start by converting to
15211   # unix format.
15212   path="$OUTPUT_ROOT"
15213   new_path=`$CYGPATH -u "$path"`
15214 
15215   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
15216   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
15217   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
15218   # "foo.exe" is OK but "foo" is an error.
15219   #
15220   # This test is therefore slightly more accurate than "test -f" to check for file precense.
15221   # It is also a way to make sure we got the proper file name for the real test later on.
15222   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
15223   if test "x$test_shortpath" = x; then
15224     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5
15225 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;}
15226     as_fn_error $? "Cannot locate the the path of OUTPUT_ROOT" "$LINENO" 5
15227   fi
15228 
15229   # Call helper function which possibly converts this using DOS-style short mode.
15230   # If so, the updated path is stored in $new_path.
15231 
15232   input_path="$new_path"
15233   # Check if we need to convert this using DOS-style short mode. If the path
15234   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15235   # take no chances and rewrite it.
15236   # Note: m4 eats our [], so we need to use [ and ] instead.
15237   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
15238   if test "x$has_forbidden_chars" != x; then
15239     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15240     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
15241     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
15242     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
15243       # Going to short mode and back again did indeed matter. Since short mode is
15244       # case insensitive, let's make it lowercase to improve readability.
15245       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15246       # Now convert it back to Unix-stile (cygpath)
15247       input_path=`$CYGPATH -u "$shortmode_path"`
15248       new_path="$input_path"
15249     fi
15250   fi
15251 
15252   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
15253   if test "x$test_cygdrive_prefix" = x; then
15254     # As a simple fix, exclude /usr/bin since it's not a real path.
15255     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
15256       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
15257       # a path prefixed by /cygdrive for fixpath to work.
15258       new_path="$CYGWIN_ROOT_PATH$input_path"
15259     fi
15260   fi
15261 
15262 
15263   if test "x$path" != "x$new_path"; then
15264     OUTPUT_ROOT="$new_path"
15265     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5
15266 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;}
15267   fi
15268 
15269   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15270 
15271   path="$OUTPUT_ROOT"
15272   has_colon=`$ECHO $path | $GREP ^.:`
15273   new_path="$path"
15274   if test "x$has_colon" = x; then
15275     # Not in mixed or Windows style, start by that.
15276     new_path=`cmd //c echo $path`
15277   fi
15278 
15279 
15280   input_path="$new_path"
15281   # Check if we need to convert this using DOS-style short mode. If the path
15282   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15283   # take no chances and rewrite it.
15284   # Note: m4 eats our [], so we need to use [ and ] instead.
15285   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
15286   if test "x$has_forbidden_chars" != x; then
15287     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15288     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15289   fi
15290 
15291 
15292   windows_path="$new_path"
15293   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15294     unix_path=`$CYGPATH -u "$windows_path"`
15295     new_path="$unix_path"
15296   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15297     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15298     new_path="$unix_path"
15299   fi
15300 
15301   if test "x$path" != "x$new_path"; then
15302     OUTPUT_ROOT="$new_path"
15303     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5
15304 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;}
15305   fi
15306 
15307   # Save the first 10 bytes of this path to the storage, so fixpath can work.
15308   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
15309 
15310   else
15311     # We're on a unix platform. Hooray! :)
15312     path="$OUTPUT_ROOT"
15313     has_space=`$ECHO "$path" | $GREP " "`
15314     if test "x$has_space" != x; then
15315       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5
15316 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;}
15317       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
15318     fi
15319 
15320     # Use eval to expand a potential ~
15321     eval path="$path"
15322     if test ! -f "$path" && test ! -d "$path"; then
15323       as_fn_error $? "The path of OUTPUT_ROOT, which resolves as \"$path\", is not found." "$LINENO" 5
15324     fi
15325 
15326     OUTPUT_ROOT="`cd "$path"; $THEPWDCMD -L`"
15327   fi
15328 
15329 
15330   SPEC=$OUTPUT_ROOT/spec.gmk
15331 
15332   CONF_NAME=$CONF_NAME
15333 
15334   OUTPUT_ROOT=$OUTPUT_ROOT
15335 
15336 
15337   # The spec.gmk file contains all variables for the make system.
15338   ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in"
15339 
15340   # The hotspot-spec.gmk file contains legacy variables for the hotspot make system.
15341   ac_config_files="$ac_config_files $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in"
15342 
15343   # The bootcycle-spec.gmk file contains support for boot cycle builds.
15344   ac_config_files="$ac_config_files $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in"
15345 
15346   # The compare.sh is used to compare the build output to other builds.
15347   ac_config_files="$ac_config_files $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in"
15348 
15349   # The generated Makefile knows where the spec.gmk is and where the source is.
15350   # You can run make from the OUTPUT_ROOT, or from the top-level Makefile
15351   # which will look for generated configurations
15352   ac_config_files="$ac_config_files $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in"
15353 
15354 
15355 
15356 # Must be done before we can call HELP_MSG_MISSING_DEPENDENCY.
15357 
15358   for ac_prog in apt-get yum port pkgutil pkgadd
15359 do
15360   # Extract the first word of "$ac_prog", so it can be a program name with args.
15361 set dummy $ac_prog; ac_word=$2
15362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15363 $as_echo_n "checking for $ac_word... " >&6; }
15364 if ${ac_cv_prog_PKGHANDLER+:} false; then :
15365   $as_echo_n "(cached) " >&6
15366 else
15367   if test -n "$PKGHANDLER"; then
15368   ac_cv_prog_PKGHANDLER="$PKGHANDLER" # Let the user override the test.
15369 else
15370 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15371 for as_dir in $PATH
15372 do
15373   IFS=$as_save_IFS
15374   test -z "$as_dir" && as_dir=.
15375     for ac_exec_ext in '' $ac_executable_extensions; do
15376   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15377     ac_cv_prog_PKGHANDLER="$ac_prog"
15378     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15379     break 2
15380   fi
15381 done
15382   done
15383 IFS=$as_save_IFS
15384 
15385 fi
15386 fi
15387 PKGHANDLER=$ac_cv_prog_PKGHANDLER
15388 if test -n "$PKGHANDLER"; then
15389   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGHANDLER" >&5
15390 $as_echo "$PKGHANDLER" >&6; }
15391 else
15392   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15393 $as_echo "no" >&6; }
15394 fi
15395 
15396 
15397   test -n "$PKGHANDLER" && break
15398 done
15399 
15400 
15401 
15402 # Setup tools that requires more complex handling, or that is not needed by the configure script.
15403 
15404 
15405   # We need to find a recent version of GNU make. Especially on Solaris, this can be tricky.
15406   if test "x$MAKE" != x; then
15407     # User has supplied a make, test it.
15408     if test ! -f "$MAKE"; then
15409       as_fn_error $? "The specified make (by MAKE=$MAKE) is not found." "$LINENO" 5
15410     fi
15411 
15412   MAKE_CANDIDATE=""$MAKE""
15413   DESCRIPTION="user supplied MAKE=$MAKE"
15414   if test "x$MAKE_CANDIDATE" != x; then
15415     { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
15416 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
15417     MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
15418     IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
15419     if test "x$IS_GNU_MAKE" = x; then
15420       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
15421 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
15422     else
15423       IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
15424       if test "x$IS_MODERN_MAKE" = x; then
15425         { $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
15426 $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;}
15427       else
15428         if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
15429           if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15430             MAKE_EXPECTED_ENV='cygwin'
15431           elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15432             MAKE_EXPECTED_ENV='msys'
15433           else
15434             as_fn_error $? "Unknown Windows environment" "$LINENO" 5
15435           fi
15436           MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
15437           IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
15438         else
15439           # Not relevant for non-Windows
15440           IS_MAKE_CORRECT_ENV=true
15441         fi
15442         if test "x$IS_MAKE_CORRECT_ENV" = x; then
15443           { $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
15444 $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;}
15445         else
15446           FOUND_MAKE=$MAKE_CANDIDATE
15447 
15448   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15449 
15450   # First separate the path from the arguments. This will split at the first
15451   # space.
15452   complete="$FOUND_MAKE"
15453   path="${complete%% *}"
15454   tmp="$complete EOL"
15455   arguments="${tmp#* }"
15456 
15457   # Input might be given as Windows format, start by converting to
15458   # unix format.
15459   new_path=`$CYGPATH -u "$path"`
15460 
15461   # Now try to locate executable using which
15462   new_path=`$WHICH "$new_path" 2> /dev/null`
15463   # bat and cmd files are not always considered executable in cygwin causing which
15464   # to not find them
15465   if test "x$new_path" = x \
15466       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15467       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15468     new_path=`$CYGPATH -u "$path"`
15469   fi
15470   if test "x$new_path" = x; then
15471     # Oops. Which didn't find the executable.
15472     # The splitting of arguments from the executable at a space might have been incorrect,
15473     # since paths with space are more likely in Windows. Give it another try with the whole
15474     # argument.
15475     path="$complete"
15476     arguments="EOL"
15477     new_path=`$CYGPATH -u "$path"`
15478     new_path=`$WHICH "$new_path" 2> /dev/null`
15479     # bat and cmd files are not always considered executable in cygwin causing which
15480     # to not find them
15481     if test "x$new_path" = x \
15482         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15483         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15484       new_path=`$CYGPATH -u "$path"`
15485     fi
15486     if test "x$new_path" = x; then
15487       # It's still not found. Now this is an unrecoverable error.
15488       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15489 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15490       has_space=`$ECHO "$complete" | $GREP " "`
15491       if test "x$has_space" != x; then
15492         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15493 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15494       fi
15495       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15496     fi
15497   fi
15498 
15499   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
15500   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
15501   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
15502   # "foo.exe" is OK but "foo" is an error.
15503   #
15504   # This test is therefore slightly more accurate than "test -f" to check for file presence.
15505   # It is also a way to make sure we got the proper file name for the real test later on.
15506   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
15507   if test "x$test_shortpath" = x; then
15508     # Short path failed, file does not exist as specified.
15509     # Try adding .exe or .cmd
15510     if test -f "${new_path}.exe"; then
15511       input_to_shortpath="${new_path}.exe"
15512     elif test -f "${new_path}.cmd"; then
15513       input_to_shortpath="${new_path}.cmd"
15514     else
15515       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
15516 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
15517       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
15518 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
15519       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15520     fi
15521   else
15522     input_to_shortpath="$new_path"
15523   fi
15524 
15525   # Call helper function which possibly converts this using DOS-style short mode.
15526   # If so, the updated path is stored in $new_path.
15527   new_path="$input_to_shortpath"
15528 
15529   input_path="$input_to_shortpath"
15530   # Check if we need to convert this using DOS-style short mode. If the path
15531   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15532   # take no chances and rewrite it.
15533   # Note: m4 eats our [], so we need to use [ and ] instead.
15534   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
15535   if test "x$has_forbidden_chars" != x; then
15536     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15537     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
15538     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
15539     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
15540       # Going to short mode and back again did indeed matter. Since short mode is
15541       # case insensitive, let's make it lowercase to improve readability.
15542       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15543       # Now convert it back to Unix-stile (cygpath)
15544       input_path=`$CYGPATH -u "$shortmode_path"`
15545       new_path="$input_path"
15546     fi
15547   fi
15548 
15549   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
15550   if test "x$test_cygdrive_prefix" = x; then
15551     # As a simple fix, exclude /usr/bin since it's not a real path.
15552     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
15553       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
15554       # a path prefixed by /cygdrive for fixpath to work.
15555       new_path="$CYGWIN_ROOT_PATH$input_path"
15556     fi
15557   fi
15558 
15559   # remove trailing .exe if any
15560   new_path="${new_path/%.exe/}"
15561 
15562   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15563 
15564   # First separate the path from the arguments. This will split at the first
15565   # space.
15566   complete="$FOUND_MAKE"
15567   path="${complete%% *}"
15568   tmp="$complete EOL"
15569   arguments="${tmp#* }"
15570 
15571   # Input might be given as Windows format, start by converting to
15572   # unix format.
15573   new_path="$path"
15574 
15575   windows_path="$new_path"
15576   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15577     unix_path=`$CYGPATH -u "$windows_path"`
15578     new_path="$unix_path"
15579   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15580     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15581     new_path="$unix_path"
15582   fi
15583 
15584 
15585   # Now try to locate executable using which
15586   new_path=`$WHICH "$new_path" 2> /dev/null`
15587 
15588   if test "x$new_path" = x; then
15589     # Oops. Which didn't find the executable.
15590     # The splitting of arguments from the executable at a space might have been incorrect,
15591     # since paths with space are more likely in Windows. Give it another try with the whole
15592     # argument.
15593     path="$complete"
15594     arguments="EOL"
15595     new_path="$path"
15596 
15597   windows_path="$new_path"
15598   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15599     unix_path=`$CYGPATH -u "$windows_path"`
15600     new_path="$unix_path"
15601   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15602     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15603     new_path="$unix_path"
15604   fi
15605 
15606 
15607     new_path=`$WHICH "$new_path" 2> /dev/null`
15608     # bat and cmd files are not always considered executable in MSYS causing which
15609     # to not find them
15610     if test "x$new_path" = x \
15611         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15612         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15613       new_path="$path"
15614 
15615   windows_path="$new_path"
15616   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15617     unix_path=`$CYGPATH -u "$windows_path"`
15618     new_path="$unix_path"
15619   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15620     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15621     new_path="$unix_path"
15622   fi
15623 
15624     fi
15625 
15626     if test "x$new_path" = x; then
15627       # It's still not found. Now this is an unrecoverable error.
15628       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15629 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15630       has_space=`$ECHO "$complete" | $GREP " "`
15631       if test "x$has_space" != x; then
15632         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15633 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15634       fi
15635       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15636     fi
15637   fi
15638 
15639   # Now new_path has a complete unix path to the binary
15640   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
15641     # Keep paths in /bin as-is, but remove trailing .exe if any
15642     new_path="${new_path/%.exe/}"
15643     # Do not save /bin paths to all_fixpath_prefixes!
15644   else
15645     # Not in mixed or Windows style, start by that.
15646     new_path=`cmd //c echo $new_path`
15647 
15648   input_path="$new_path"
15649   # Check if we need to convert this using DOS-style short mode. If the path
15650   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15651   # take no chances and rewrite it.
15652   # Note: m4 eats our [], so we need to use [ and ] instead.
15653   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
15654   if test "x$has_forbidden_chars" != x; then
15655     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15656     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15657   fi
15658 
15659     # Output is in $new_path
15660 
15661   windows_path="$new_path"
15662   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15663     unix_path=`$CYGPATH -u "$windows_path"`
15664     new_path="$unix_path"
15665   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15666     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15667     new_path="$unix_path"
15668   fi
15669 
15670     # remove trailing .exe if any
15671     new_path="${new_path/%.exe/}"
15672 
15673     # Save the first 10 bytes of this path to the storage, so fixpath can work.
15674     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
15675   fi
15676 
15677   else
15678     # We're on a unix platform. Hooray! :)
15679     # First separate the path from the arguments. This will split at the first
15680     # space.
15681     complete="$FOUND_MAKE"
15682     path="${complete%% *}"
15683     tmp="$complete EOL"
15684     arguments="${tmp#* }"
15685 
15686     # Cannot rely on the command "which" here since it doesn't always work.
15687     is_absolute_path=`$ECHO "$path" | $GREP ^/`
15688     if test -z "$is_absolute_path"; then
15689       # Path to executable is not absolute. Find it.
15690       IFS_save="$IFS"
15691       IFS=:
15692       for p in $PATH; do
15693         if test -f "$p/$path" && test -x "$p/$path"; then
15694           new_path="$p/$path"
15695           break
15696         fi
15697       done
15698       IFS="$IFS_save"
15699     else
15700       # This is an absolute path, we can use it without further modifications.
15701       new_path="$path"
15702     fi
15703 
15704     if test "x$new_path" = x; then
15705       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15706 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15707       has_space=`$ECHO "$complete" | $GREP " "`
15708       if test "x$has_space" != x; then
15709         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
15710 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
15711       fi
15712       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15713     fi
15714   fi
15715 
15716   # Now join together the path and the arguments once again
15717   if test "x$arguments" != xEOL; then
15718     new_complete="$new_path ${arguments% *}"
15719   else
15720     new_complete="$new_path"
15721   fi
15722 
15723   if test "x$complete" != "x$new_complete"; then
15724     FOUND_MAKE="$new_complete"
15725     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
15726 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
15727   fi
15728 
15729         fi
15730       fi
15731     fi
15732   fi
15733 
15734     if test "x$FOUND_MAKE" = x; then
15735       as_fn_error $? "The specified make (by MAKE=$MAKE) is not GNU make 3.81 or newer." "$LINENO" 5
15736     fi
15737   else
15738     # Try our hardest to locate a correct version of GNU make
15739     for ac_prog in gmake
15740 do
15741   # Extract the first word of "$ac_prog", so it can be a program name with args.
15742 set dummy $ac_prog; ac_word=$2
15743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15744 $as_echo_n "checking for $ac_word... " >&6; }
15745 if ${ac_cv_path_CHECK_GMAKE+:} false; then :
15746   $as_echo_n "(cached) " >&6
15747 else
15748   case $CHECK_GMAKE in
15749   [\\/]* | ?:[\\/]*)
15750   ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path.
15751   ;;
15752   *)
15753   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15754 for as_dir in $PATH
15755 do
15756   IFS=$as_save_IFS
15757   test -z "$as_dir" && as_dir=.
15758     for ac_exec_ext in '' $ac_executable_extensions; do
15759   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15760     ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext"
15761     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15762     break 2
15763   fi
15764 done
15765   done
15766 IFS=$as_save_IFS
15767 
15768   ;;
15769 esac
15770 fi
15771 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE
15772 if test -n "$CHECK_GMAKE"; then
15773   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5
15774 $as_echo "$CHECK_GMAKE" >&6; }
15775 else
15776   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15777 $as_echo "no" >&6; }
15778 fi
15779 
15780 
15781   test -n "$CHECK_GMAKE" && break
15782 done
15783 
15784 
15785   MAKE_CANDIDATE=""$CHECK_GMAKE""
15786   DESCRIPTION="gmake in PATH"
15787   if test "x$MAKE_CANDIDATE" != x; then
15788     { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
15789 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
15790     MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
15791     IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
15792     if test "x$IS_GNU_MAKE" = x; then
15793       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
15794 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
15795     else
15796       IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
15797       if test "x$IS_MODERN_MAKE" = x; then
15798         { $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
15799 $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;}
15800       else
15801         if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
15802           if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15803             MAKE_EXPECTED_ENV='cygwin'
15804           elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15805             MAKE_EXPECTED_ENV='msys'
15806           else
15807             as_fn_error $? "Unknown Windows environment" "$LINENO" 5
15808           fi
15809           MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
15810           IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
15811         else
15812           # Not relevant for non-Windows
15813           IS_MAKE_CORRECT_ENV=true
15814         fi
15815         if test "x$IS_MAKE_CORRECT_ENV" = x; then
15816           { $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
15817 $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;}
15818         else
15819           FOUND_MAKE=$MAKE_CANDIDATE
15820 
15821   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15822 
15823   # First separate the path from the arguments. This will split at the first
15824   # space.
15825   complete="$FOUND_MAKE"
15826   path="${complete%% *}"
15827   tmp="$complete EOL"
15828   arguments="${tmp#* }"
15829 
15830   # Input might be given as Windows format, start by converting to
15831   # unix format.
15832   new_path=`$CYGPATH -u "$path"`
15833 
15834   # Now try to locate executable using which
15835   new_path=`$WHICH "$new_path" 2> /dev/null`
15836   # bat and cmd files are not always considered executable in cygwin causing which
15837   # to not find them
15838   if test "x$new_path" = x \
15839       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15840       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15841     new_path=`$CYGPATH -u "$path"`
15842   fi
15843   if test "x$new_path" = x; then
15844     # Oops. Which didn't find the executable.
15845     # The splitting of arguments from the executable at a space might have been incorrect,
15846     # since paths with space are more likely in Windows. Give it another try with the whole
15847     # argument.
15848     path="$complete"
15849     arguments="EOL"
15850     new_path=`$CYGPATH -u "$path"`
15851     new_path=`$WHICH "$new_path" 2> /dev/null`
15852     # bat and cmd files are not always considered executable in cygwin causing which
15853     # to not find them
15854     if test "x$new_path" = x \
15855         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15856         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15857       new_path=`$CYGPATH -u "$path"`
15858     fi
15859     if test "x$new_path" = x; then
15860       # It's still not found. Now this is an unrecoverable error.
15861       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
15862 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
15863       has_space=`$ECHO "$complete" | $GREP " "`
15864       if test "x$has_space" != x; then
15865         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
15866 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
15867       fi
15868       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15869     fi
15870   fi
15871 
15872   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
15873   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
15874   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
15875   # "foo.exe" is OK but "foo" is an error.
15876   #
15877   # This test is therefore slightly more accurate than "test -f" to check for file presence.
15878   # It is also a way to make sure we got the proper file name for the real test later on.
15879   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
15880   if test "x$test_shortpath" = x; then
15881     # Short path failed, file does not exist as specified.
15882     # Try adding .exe or .cmd
15883     if test -f "${new_path}.exe"; then
15884       input_to_shortpath="${new_path}.exe"
15885     elif test -f "${new_path}.cmd"; then
15886       input_to_shortpath="${new_path}.cmd"
15887     else
15888       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
15889 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
15890       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
15891 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
15892       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
15893     fi
15894   else
15895     input_to_shortpath="$new_path"
15896   fi
15897 
15898   # Call helper function which possibly converts this using DOS-style short mode.
15899   # If so, the updated path is stored in $new_path.
15900   new_path="$input_to_shortpath"
15901 
15902   input_path="$input_to_shortpath"
15903   # Check if we need to convert this using DOS-style short mode. If the path
15904   # contains just simple characters, use it. Otherwise (spaces, weird characters),
15905   # take no chances and rewrite it.
15906   # Note: m4 eats our [], so we need to use [ and ] instead.
15907   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
15908   if test "x$has_forbidden_chars" != x; then
15909     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
15910     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
15911     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
15912     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
15913       # Going to short mode and back again did indeed matter. Since short mode is
15914       # case insensitive, let's make it lowercase to improve readability.
15915       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
15916       # Now convert it back to Unix-stile (cygpath)
15917       input_path=`$CYGPATH -u "$shortmode_path"`
15918       new_path="$input_path"
15919     fi
15920   fi
15921 
15922   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
15923   if test "x$test_cygdrive_prefix" = x; then
15924     # As a simple fix, exclude /usr/bin since it's not a real path.
15925     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
15926       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
15927       # a path prefixed by /cygdrive for fixpath to work.
15928       new_path="$CYGWIN_ROOT_PATH$input_path"
15929     fi
15930   fi
15931 
15932   # remove trailing .exe if any
15933   new_path="${new_path/%.exe/}"
15934 
15935   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15936 
15937   # First separate the path from the arguments. This will split at the first
15938   # space.
15939   complete="$FOUND_MAKE"
15940   path="${complete%% *}"
15941   tmp="$complete EOL"
15942   arguments="${tmp#* }"
15943 
15944   # Input might be given as Windows format, start by converting to
15945   # unix format.
15946   new_path="$path"
15947 
15948   windows_path="$new_path"
15949   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15950     unix_path=`$CYGPATH -u "$windows_path"`
15951     new_path="$unix_path"
15952   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15953     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15954     new_path="$unix_path"
15955   fi
15956 
15957 
15958   # Now try to locate executable using which
15959   new_path=`$WHICH "$new_path" 2> /dev/null`
15960 
15961   if test "x$new_path" = x; then
15962     # Oops. Which didn't find the executable.
15963     # The splitting of arguments from the executable at a space might have been incorrect,
15964     # since paths with space are more likely in Windows. Give it another try with the whole
15965     # argument.
15966     path="$complete"
15967     arguments="EOL"
15968     new_path="$path"
15969 
15970   windows_path="$new_path"
15971   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15972     unix_path=`$CYGPATH -u "$windows_path"`
15973     new_path="$unix_path"
15974   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15975     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15976     new_path="$unix_path"
15977   fi
15978 
15979 
15980     new_path=`$WHICH "$new_path" 2> /dev/null`
15981     # bat and cmd files are not always considered executable in MSYS causing which
15982     # to not find them
15983     if test "x$new_path" = x \
15984         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
15985         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
15986       new_path="$path"
15987 
15988   windows_path="$new_path"
15989   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
15990     unix_path=`$CYGPATH -u "$windows_path"`
15991     new_path="$unix_path"
15992   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
15993     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
15994     new_path="$unix_path"
15995   fi
15996 
15997     fi
15998 
15999     if test "x$new_path" = x; then
16000       # It's still not found. Now this is an unrecoverable error.
16001       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16002 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16003       has_space=`$ECHO "$complete" | $GREP " "`
16004       if test "x$has_space" != x; then
16005         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16006 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16007       fi
16008       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16009     fi
16010   fi
16011 
16012   # Now new_path has a complete unix path to the binary
16013   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
16014     # Keep paths in /bin as-is, but remove trailing .exe if any
16015     new_path="${new_path/%.exe/}"
16016     # Do not save /bin paths to all_fixpath_prefixes!
16017   else
16018     # Not in mixed or Windows style, start by that.
16019     new_path=`cmd //c echo $new_path`
16020 
16021   input_path="$new_path"
16022   # Check if we need to convert this using DOS-style short mode. If the path
16023   # contains just simple characters, use it. Otherwise (spaces, weird characters),
16024   # take no chances and rewrite it.
16025   # Note: m4 eats our [], so we need to use [ and ] instead.
16026   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
16027   if test "x$has_forbidden_chars" != x; then
16028     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16029     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16030   fi
16031 
16032     # Output is in $new_path
16033 
16034   windows_path="$new_path"
16035   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16036     unix_path=`$CYGPATH -u "$windows_path"`
16037     new_path="$unix_path"
16038   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16039     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16040     new_path="$unix_path"
16041   fi
16042 
16043     # remove trailing .exe if any
16044     new_path="${new_path/%.exe/}"
16045 
16046     # Save the first 10 bytes of this path to the storage, so fixpath can work.
16047     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
16048   fi
16049 
16050   else
16051     # We're on a unix platform. Hooray! :)
16052     # First separate the path from the arguments. This will split at the first
16053     # space.
16054     complete="$FOUND_MAKE"
16055     path="${complete%% *}"
16056     tmp="$complete EOL"
16057     arguments="${tmp#* }"
16058 
16059     # Cannot rely on the command "which" here since it doesn't always work.
16060     is_absolute_path=`$ECHO "$path" | $GREP ^/`
16061     if test -z "$is_absolute_path"; then
16062       # Path to executable is not absolute. Find it.
16063       IFS_save="$IFS"
16064       IFS=:
16065       for p in $PATH; do
16066         if test -f "$p/$path" && test -x "$p/$path"; then
16067           new_path="$p/$path"
16068           break
16069         fi
16070       done
16071       IFS="$IFS_save"
16072     else
16073       # This is an absolute path, we can use it without further modifications.
16074       new_path="$path"
16075     fi
16076 
16077     if test "x$new_path" = x; then
16078       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16079 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16080       has_space=`$ECHO "$complete" | $GREP " "`
16081       if test "x$has_space" != x; then
16082         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
16083 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
16084       fi
16085       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16086     fi
16087   fi
16088 
16089   # Now join together the path and the arguments once again
16090   if test "x$arguments" != xEOL; then
16091     new_complete="$new_path ${arguments% *}"
16092   else
16093     new_complete="$new_path"
16094   fi
16095 
16096   if test "x$complete" != "x$new_complete"; then
16097     FOUND_MAKE="$new_complete"
16098     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
16099 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
16100   fi
16101 
16102         fi
16103       fi
16104     fi
16105   fi
16106 
16107 
16108     if test "x$FOUND_MAKE" = x; then
16109       for ac_prog in make
16110 do
16111   # Extract the first word of "$ac_prog", so it can be a program name with args.
16112 set dummy $ac_prog; ac_word=$2
16113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16114 $as_echo_n "checking for $ac_word... " >&6; }
16115 if ${ac_cv_path_CHECK_MAKE+:} false; then :
16116   $as_echo_n "(cached) " >&6
16117 else
16118   case $CHECK_MAKE in
16119   [\\/]* | ?:[\\/]*)
16120   ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path.
16121   ;;
16122   *)
16123   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16124 for as_dir in $PATH
16125 do
16126   IFS=$as_save_IFS
16127   test -z "$as_dir" && as_dir=.
16128     for ac_exec_ext in '' $ac_executable_extensions; do
16129   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16130     ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext"
16131     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16132     break 2
16133   fi
16134 done
16135   done
16136 IFS=$as_save_IFS
16137 
16138   ;;
16139 esac
16140 fi
16141 CHECK_MAKE=$ac_cv_path_CHECK_MAKE
16142 if test -n "$CHECK_MAKE"; then
16143   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5
16144 $as_echo "$CHECK_MAKE" >&6; }
16145 else
16146   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16147 $as_echo "no" >&6; }
16148 fi
16149 
16150 
16151   test -n "$CHECK_MAKE" && break
16152 done
16153 
16154 
16155   MAKE_CANDIDATE=""$CHECK_MAKE""
16156   DESCRIPTION="make in PATH"
16157   if test "x$MAKE_CANDIDATE" != x; then
16158     { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
16159 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
16160     MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
16161     IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
16162     if test "x$IS_GNU_MAKE" = x; then
16163       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
16164 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
16165     else
16166       IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
16167       if test "x$IS_MODERN_MAKE" = x; then
16168         { $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
16169 $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;}
16170       else
16171         if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
16172           if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16173             MAKE_EXPECTED_ENV='cygwin'
16174           elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16175             MAKE_EXPECTED_ENV='msys'
16176           else
16177             as_fn_error $? "Unknown Windows environment" "$LINENO" 5
16178           fi
16179           MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
16180           IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
16181         else
16182           # Not relevant for non-Windows
16183           IS_MAKE_CORRECT_ENV=true
16184         fi
16185         if test "x$IS_MAKE_CORRECT_ENV" = x; then
16186           { $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
16187 $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;}
16188         else
16189           FOUND_MAKE=$MAKE_CANDIDATE
16190 
16191   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16192 
16193   # First separate the path from the arguments. This will split at the first
16194   # space.
16195   complete="$FOUND_MAKE"
16196   path="${complete%% *}"
16197   tmp="$complete EOL"
16198   arguments="${tmp#* }"
16199 
16200   # Input might be given as Windows format, start by converting to
16201   # unix format.
16202   new_path=`$CYGPATH -u "$path"`
16203 
16204   # Now try to locate executable using which
16205   new_path=`$WHICH "$new_path" 2> /dev/null`
16206   # bat and cmd files are not always considered executable in cygwin causing which
16207   # to not find them
16208   if test "x$new_path" = x \
16209       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16210       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16211     new_path=`$CYGPATH -u "$path"`
16212   fi
16213   if test "x$new_path" = x; then
16214     # Oops. Which didn't find the executable.
16215     # The splitting of arguments from the executable at a space might have been incorrect,
16216     # since paths with space are more likely in Windows. Give it another try with the whole
16217     # argument.
16218     path="$complete"
16219     arguments="EOL"
16220     new_path=`$CYGPATH -u "$path"`
16221     new_path=`$WHICH "$new_path" 2> /dev/null`
16222     # bat and cmd files are not always considered executable in cygwin causing which
16223     # to not find them
16224     if test "x$new_path" = x \
16225         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16226         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16227       new_path=`$CYGPATH -u "$path"`
16228     fi
16229     if test "x$new_path" = x; then
16230       # It's still not found. Now this is an unrecoverable error.
16231       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16232 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16233       has_space=`$ECHO "$complete" | $GREP " "`
16234       if test "x$has_space" != x; then
16235         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16236 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16237       fi
16238       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16239     fi
16240   fi
16241 
16242   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
16243   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
16244   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
16245   # "foo.exe" is OK but "foo" is an error.
16246   #
16247   # This test is therefore slightly more accurate than "test -f" to check for file presence.
16248   # It is also a way to make sure we got the proper file name for the real test later on.
16249   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
16250   if test "x$test_shortpath" = x; then
16251     # Short path failed, file does not exist as specified.
16252     # Try adding .exe or .cmd
16253     if test -f "${new_path}.exe"; then
16254       input_to_shortpath="${new_path}.exe"
16255     elif test -f "${new_path}.cmd"; then
16256       input_to_shortpath="${new_path}.cmd"
16257     else
16258       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
16259 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
16260       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
16261 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
16262       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16263     fi
16264   else
16265     input_to_shortpath="$new_path"
16266   fi
16267 
16268   # Call helper function which possibly converts this using DOS-style short mode.
16269   # If so, the updated path is stored in $new_path.
16270   new_path="$input_to_shortpath"
16271 
16272   input_path="$input_to_shortpath"
16273   # Check if we need to convert this using DOS-style short mode. If the path
16274   # contains just simple characters, use it. Otherwise (spaces, weird characters),
16275   # take no chances and rewrite it.
16276   # Note: m4 eats our [], so we need to use [ and ] instead.
16277   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
16278   if test "x$has_forbidden_chars" != x; then
16279     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16280     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
16281     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
16282     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
16283       # Going to short mode and back again did indeed matter. Since short mode is
16284       # case insensitive, let's make it lowercase to improve readability.
16285       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16286       # Now convert it back to Unix-stile (cygpath)
16287       input_path=`$CYGPATH -u "$shortmode_path"`
16288       new_path="$input_path"
16289     fi
16290   fi
16291 
16292   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
16293   if test "x$test_cygdrive_prefix" = x; then
16294     # As a simple fix, exclude /usr/bin since it's not a real path.
16295     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
16296       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
16297       # a path prefixed by /cygdrive for fixpath to work.
16298       new_path="$CYGWIN_ROOT_PATH$input_path"
16299     fi
16300   fi
16301 
16302   # remove trailing .exe if any
16303   new_path="${new_path/%.exe/}"
16304 
16305   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16306 
16307   # First separate the path from the arguments. This will split at the first
16308   # space.
16309   complete="$FOUND_MAKE"
16310   path="${complete%% *}"
16311   tmp="$complete EOL"
16312   arguments="${tmp#* }"
16313 
16314   # Input might be given as Windows format, start by converting to
16315   # unix format.
16316   new_path="$path"
16317 
16318   windows_path="$new_path"
16319   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16320     unix_path=`$CYGPATH -u "$windows_path"`
16321     new_path="$unix_path"
16322   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16323     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16324     new_path="$unix_path"
16325   fi
16326 
16327 
16328   # Now try to locate executable using which
16329   new_path=`$WHICH "$new_path" 2> /dev/null`
16330 
16331   if test "x$new_path" = x; then
16332     # Oops. Which didn't find the executable.
16333     # The splitting of arguments from the executable at a space might have been incorrect,
16334     # since paths with space are more likely in Windows. Give it another try with the whole
16335     # argument.
16336     path="$complete"
16337     arguments="EOL"
16338     new_path="$path"
16339 
16340   windows_path="$new_path"
16341   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16342     unix_path=`$CYGPATH -u "$windows_path"`
16343     new_path="$unix_path"
16344   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16345     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16346     new_path="$unix_path"
16347   fi
16348 
16349 
16350     new_path=`$WHICH "$new_path" 2> /dev/null`
16351     # bat and cmd files are not always considered executable in MSYS causing which
16352     # to not find them
16353     if test "x$new_path" = x \
16354         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16355         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16356       new_path="$path"
16357 
16358   windows_path="$new_path"
16359   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16360     unix_path=`$CYGPATH -u "$windows_path"`
16361     new_path="$unix_path"
16362   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16363     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16364     new_path="$unix_path"
16365   fi
16366 
16367     fi
16368 
16369     if test "x$new_path" = x; then
16370       # It's still not found. Now this is an unrecoverable error.
16371       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16372 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16373       has_space=`$ECHO "$complete" | $GREP " "`
16374       if test "x$has_space" != x; then
16375         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16376 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16377       fi
16378       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16379     fi
16380   fi
16381 
16382   # Now new_path has a complete unix path to the binary
16383   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
16384     # Keep paths in /bin as-is, but remove trailing .exe if any
16385     new_path="${new_path/%.exe/}"
16386     # Do not save /bin paths to all_fixpath_prefixes!
16387   else
16388     # Not in mixed or Windows style, start by that.
16389     new_path=`cmd //c echo $new_path`
16390 
16391   input_path="$new_path"
16392   # Check if we need to convert this using DOS-style short mode. If the path
16393   # contains just simple characters, use it. Otherwise (spaces, weird characters),
16394   # take no chances and rewrite it.
16395   # Note: m4 eats our [], so we need to use [ and ] instead.
16396   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
16397   if test "x$has_forbidden_chars" != x; then
16398     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16399     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16400   fi
16401 
16402     # Output is in $new_path
16403 
16404   windows_path="$new_path"
16405   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16406     unix_path=`$CYGPATH -u "$windows_path"`
16407     new_path="$unix_path"
16408   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16409     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16410     new_path="$unix_path"
16411   fi
16412 
16413     # remove trailing .exe if any
16414     new_path="${new_path/%.exe/}"
16415 
16416     # Save the first 10 bytes of this path to the storage, so fixpath can work.
16417     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
16418   fi
16419 
16420   else
16421     # We're on a unix platform. Hooray! :)
16422     # First separate the path from the arguments. This will split at the first
16423     # space.
16424     complete="$FOUND_MAKE"
16425     path="${complete%% *}"
16426     tmp="$complete EOL"
16427     arguments="${tmp#* }"
16428 
16429     # Cannot rely on the command "which" here since it doesn't always work.
16430     is_absolute_path=`$ECHO "$path" | $GREP ^/`
16431     if test -z "$is_absolute_path"; then
16432       # Path to executable is not absolute. Find it.
16433       IFS_save="$IFS"
16434       IFS=:
16435       for p in $PATH; do
16436         if test -f "$p/$path" && test -x "$p/$path"; then
16437           new_path="$p/$path"
16438           break
16439         fi
16440       done
16441       IFS="$IFS_save"
16442     else
16443       # This is an absolute path, we can use it without further modifications.
16444       new_path="$path"
16445     fi
16446 
16447     if test "x$new_path" = x; then
16448       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16449 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16450       has_space=`$ECHO "$complete" | $GREP " "`
16451       if test "x$has_space" != x; then
16452         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
16453 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
16454       fi
16455       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16456     fi
16457   fi
16458 
16459   # Now join together the path and the arguments once again
16460   if test "x$arguments" != xEOL; then
16461     new_complete="$new_path ${arguments% *}"
16462   else
16463     new_complete="$new_path"
16464   fi
16465 
16466   if test "x$complete" != "x$new_complete"; then
16467     FOUND_MAKE="$new_complete"
16468     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
16469 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
16470   fi
16471 
16472         fi
16473       fi
16474     fi
16475   fi
16476 
16477     fi
16478 
16479     if test "x$FOUND_MAKE" = x; then
16480       if test "x$TOOLCHAIN_PATH" != x; then
16481         # We have a toolchain path, check that as well before giving up.
16482         OLD_PATH=$PATH
16483         PATH=$TOOLCHAIN_PATH:$PATH
16484         for ac_prog in gmake
16485 do
16486   # Extract the first word of "$ac_prog", so it can be a program name with args.
16487 set dummy $ac_prog; ac_word=$2
16488 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16489 $as_echo_n "checking for $ac_word... " >&6; }
16490 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then :
16491   $as_echo_n "(cached) " >&6
16492 else
16493   case $CHECK_TOOLSDIR_GMAKE in
16494   [\\/]* | ?:[\\/]*)
16495   ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path.
16496   ;;
16497   *)
16498   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16499 for as_dir in $PATH
16500 do
16501   IFS=$as_save_IFS
16502   test -z "$as_dir" && as_dir=.
16503     for ac_exec_ext in '' $ac_executable_extensions; do
16504   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16505     ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext"
16506     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16507     break 2
16508   fi
16509 done
16510   done
16511 IFS=$as_save_IFS
16512 
16513   ;;
16514 esac
16515 fi
16516 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE
16517 if test -n "$CHECK_TOOLSDIR_GMAKE"; then
16518   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5
16519 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; }
16520 else
16521   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16522 $as_echo "no" >&6; }
16523 fi
16524 
16525 
16526   test -n "$CHECK_TOOLSDIR_GMAKE" && break
16527 done
16528 
16529 
16530   MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE""
16531   DESCRIPTION="gmake in tools-dir"
16532   if test "x$MAKE_CANDIDATE" != x; then
16533     { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
16534 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
16535     MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
16536     IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
16537     if test "x$IS_GNU_MAKE" = x; then
16538       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
16539 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
16540     else
16541       IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
16542       if test "x$IS_MODERN_MAKE" = x; then
16543         { $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
16544 $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;}
16545       else
16546         if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
16547           if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16548             MAKE_EXPECTED_ENV='cygwin'
16549           elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16550             MAKE_EXPECTED_ENV='msys'
16551           else
16552             as_fn_error $? "Unknown Windows environment" "$LINENO" 5
16553           fi
16554           MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
16555           IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
16556         else
16557           # Not relevant for non-Windows
16558           IS_MAKE_CORRECT_ENV=true
16559         fi
16560         if test "x$IS_MAKE_CORRECT_ENV" = x; then
16561           { $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
16562 $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;}
16563         else
16564           FOUND_MAKE=$MAKE_CANDIDATE
16565 
16566   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16567 
16568   # First separate the path from the arguments. This will split at the first
16569   # space.
16570   complete="$FOUND_MAKE"
16571   path="${complete%% *}"
16572   tmp="$complete EOL"
16573   arguments="${tmp#* }"
16574 
16575   # Input might be given as Windows format, start by converting to
16576   # unix format.
16577   new_path=`$CYGPATH -u "$path"`
16578 
16579   # Now try to locate executable using which
16580   new_path=`$WHICH "$new_path" 2> /dev/null`
16581   # bat and cmd files are not always considered executable in cygwin causing which
16582   # to not find them
16583   if test "x$new_path" = x \
16584       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16585       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16586     new_path=`$CYGPATH -u "$path"`
16587   fi
16588   if test "x$new_path" = x; then
16589     # Oops. Which didn't find the executable.
16590     # The splitting of arguments from the executable at a space might have been incorrect,
16591     # since paths with space are more likely in Windows. Give it another try with the whole
16592     # argument.
16593     path="$complete"
16594     arguments="EOL"
16595     new_path=`$CYGPATH -u "$path"`
16596     new_path=`$WHICH "$new_path" 2> /dev/null`
16597     # bat and cmd files are not always considered executable in cygwin causing which
16598     # to not find them
16599     if test "x$new_path" = x \
16600         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16601         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16602       new_path=`$CYGPATH -u "$path"`
16603     fi
16604     if test "x$new_path" = x; then
16605       # It's still not found. Now this is an unrecoverable error.
16606       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16607 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16608       has_space=`$ECHO "$complete" | $GREP " "`
16609       if test "x$has_space" != x; then
16610         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16611 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16612       fi
16613       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16614     fi
16615   fi
16616 
16617   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
16618   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
16619   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
16620   # "foo.exe" is OK but "foo" is an error.
16621   #
16622   # This test is therefore slightly more accurate than "test -f" to check for file presence.
16623   # It is also a way to make sure we got the proper file name for the real test later on.
16624   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
16625   if test "x$test_shortpath" = x; then
16626     # Short path failed, file does not exist as specified.
16627     # Try adding .exe or .cmd
16628     if test -f "${new_path}.exe"; then
16629       input_to_shortpath="${new_path}.exe"
16630     elif test -f "${new_path}.cmd"; then
16631       input_to_shortpath="${new_path}.cmd"
16632     else
16633       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
16634 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
16635       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
16636 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
16637       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16638     fi
16639   else
16640     input_to_shortpath="$new_path"
16641   fi
16642 
16643   # Call helper function which possibly converts this using DOS-style short mode.
16644   # If so, the updated path is stored in $new_path.
16645   new_path="$input_to_shortpath"
16646 
16647   input_path="$input_to_shortpath"
16648   # Check if we need to convert this using DOS-style short mode. If the path
16649   # contains just simple characters, use it. Otherwise (spaces, weird characters),
16650   # take no chances and rewrite it.
16651   # Note: m4 eats our [], so we need to use [ and ] instead.
16652   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
16653   if test "x$has_forbidden_chars" != x; then
16654     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16655     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
16656     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
16657     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
16658       # Going to short mode and back again did indeed matter. Since short mode is
16659       # case insensitive, let's make it lowercase to improve readability.
16660       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16661       # Now convert it back to Unix-stile (cygpath)
16662       input_path=`$CYGPATH -u "$shortmode_path"`
16663       new_path="$input_path"
16664     fi
16665   fi
16666 
16667   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
16668   if test "x$test_cygdrive_prefix" = x; then
16669     # As a simple fix, exclude /usr/bin since it's not a real path.
16670     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
16671       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
16672       # a path prefixed by /cygdrive for fixpath to work.
16673       new_path="$CYGWIN_ROOT_PATH$input_path"
16674     fi
16675   fi
16676 
16677   # remove trailing .exe if any
16678   new_path="${new_path/%.exe/}"
16679 
16680   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16681 
16682   # First separate the path from the arguments. This will split at the first
16683   # space.
16684   complete="$FOUND_MAKE"
16685   path="${complete%% *}"
16686   tmp="$complete EOL"
16687   arguments="${tmp#* }"
16688 
16689   # Input might be given as Windows format, start by converting to
16690   # unix format.
16691   new_path="$path"
16692 
16693   windows_path="$new_path"
16694   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16695     unix_path=`$CYGPATH -u "$windows_path"`
16696     new_path="$unix_path"
16697   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16698     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16699     new_path="$unix_path"
16700   fi
16701 
16702 
16703   # Now try to locate executable using which
16704   new_path=`$WHICH "$new_path" 2> /dev/null`
16705 
16706   if test "x$new_path" = x; then
16707     # Oops. Which didn't find the executable.
16708     # The splitting of arguments from the executable at a space might have been incorrect,
16709     # since paths with space are more likely in Windows. Give it another try with the whole
16710     # argument.
16711     path="$complete"
16712     arguments="EOL"
16713     new_path="$path"
16714 
16715   windows_path="$new_path"
16716   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16717     unix_path=`$CYGPATH -u "$windows_path"`
16718     new_path="$unix_path"
16719   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16720     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16721     new_path="$unix_path"
16722   fi
16723 
16724 
16725     new_path=`$WHICH "$new_path" 2> /dev/null`
16726     # bat and cmd files are not always considered executable in MSYS causing which
16727     # to not find them
16728     if test "x$new_path" = x \
16729         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16730         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16731       new_path="$path"
16732 
16733   windows_path="$new_path"
16734   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16735     unix_path=`$CYGPATH -u "$windows_path"`
16736     new_path="$unix_path"
16737   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16738     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16739     new_path="$unix_path"
16740   fi
16741 
16742     fi
16743 
16744     if test "x$new_path" = x; then
16745       # It's still not found. Now this is an unrecoverable error.
16746       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16747 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16748       has_space=`$ECHO "$complete" | $GREP " "`
16749       if test "x$has_space" != x; then
16750         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16751 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16752       fi
16753       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16754     fi
16755   fi
16756 
16757   # Now new_path has a complete unix path to the binary
16758   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
16759     # Keep paths in /bin as-is, but remove trailing .exe if any
16760     new_path="${new_path/%.exe/}"
16761     # Do not save /bin paths to all_fixpath_prefixes!
16762   else
16763     # Not in mixed or Windows style, start by that.
16764     new_path=`cmd //c echo $new_path`
16765 
16766   input_path="$new_path"
16767   # Check if we need to convert this using DOS-style short mode. If the path
16768   # contains just simple characters, use it. Otherwise (spaces, weird characters),
16769   # take no chances and rewrite it.
16770   # Note: m4 eats our [], so we need to use [ and ] instead.
16771   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
16772   if test "x$has_forbidden_chars" != x; then
16773     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
16774     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
16775   fi
16776 
16777     # Output is in $new_path
16778 
16779   windows_path="$new_path"
16780   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16781     unix_path=`$CYGPATH -u "$windows_path"`
16782     new_path="$unix_path"
16783   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16784     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
16785     new_path="$unix_path"
16786   fi
16787 
16788     # remove trailing .exe if any
16789     new_path="${new_path/%.exe/}"
16790 
16791     # Save the first 10 bytes of this path to the storage, so fixpath can work.
16792     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
16793   fi
16794 
16795   else
16796     # We're on a unix platform. Hooray! :)
16797     # First separate the path from the arguments. This will split at the first
16798     # space.
16799     complete="$FOUND_MAKE"
16800     path="${complete%% *}"
16801     tmp="$complete EOL"
16802     arguments="${tmp#* }"
16803 
16804     # Cannot rely on the command "which" here since it doesn't always work.
16805     is_absolute_path=`$ECHO "$path" | $GREP ^/`
16806     if test -z "$is_absolute_path"; then
16807       # Path to executable is not absolute. Find it.
16808       IFS_save="$IFS"
16809       IFS=:
16810       for p in $PATH; do
16811         if test -f "$p/$path" && test -x "$p/$path"; then
16812           new_path="$p/$path"
16813           break
16814         fi
16815       done
16816       IFS="$IFS_save"
16817     else
16818       # This is an absolute path, we can use it without further modifications.
16819       new_path="$path"
16820     fi
16821 
16822     if test "x$new_path" = x; then
16823       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16824 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16825       has_space=`$ECHO "$complete" | $GREP " "`
16826       if test "x$has_space" != x; then
16827         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
16828 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
16829       fi
16830       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16831     fi
16832   fi
16833 
16834   # Now join together the path and the arguments once again
16835   if test "x$arguments" != xEOL; then
16836     new_complete="$new_path ${arguments% *}"
16837   else
16838     new_complete="$new_path"
16839   fi
16840 
16841   if test "x$complete" != "x$new_complete"; then
16842     FOUND_MAKE="$new_complete"
16843     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
16844 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
16845   fi
16846 
16847         fi
16848       fi
16849     fi
16850   fi
16851 
16852         if test "x$FOUND_MAKE" = x; then
16853           for ac_prog in make
16854 do
16855   # Extract the first word of "$ac_prog", so it can be a program name with args.
16856 set dummy $ac_prog; ac_word=$2
16857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16858 $as_echo_n "checking for $ac_word... " >&6; }
16859 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then :
16860   $as_echo_n "(cached) " >&6
16861 else
16862   case $CHECK_TOOLSDIR_MAKE in
16863   [\\/]* | ?:[\\/]*)
16864   ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path.
16865   ;;
16866   *)
16867   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16868 for as_dir in $PATH
16869 do
16870   IFS=$as_save_IFS
16871   test -z "$as_dir" && as_dir=.
16872     for ac_exec_ext in '' $ac_executable_extensions; do
16873   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16874     ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext"
16875     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16876     break 2
16877   fi
16878 done
16879   done
16880 IFS=$as_save_IFS
16881 
16882   ;;
16883 esac
16884 fi
16885 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE
16886 if test -n "$CHECK_TOOLSDIR_MAKE"; then
16887   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5
16888 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; }
16889 else
16890   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16891 $as_echo "no" >&6; }
16892 fi
16893 
16894 
16895   test -n "$CHECK_TOOLSDIR_MAKE" && break
16896 done
16897 
16898 
16899   MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE""
16900   DESCRIPTION="make in tools-dir"
16901   if test "x$MAKE_CANDIDATE" != x; then
16902     { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5
16903 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;}
16904     MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1`
16905     IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'`
16906     if test "x$IS_GNU_MAKE" = x; then
16907       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5
16908 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;}
16909     else
16910       IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP -e '3\.8[12]' -e '4\.'`
16911       if test "x$IS_MODERN_MAKE" = x; then
16912         { $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
16913 $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;}
16914       else
16915         if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
16916           if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16917             MAKE_EXPECTED_ENV='cygwin'
16918           elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
16919             MAKE_EXPECTED_ENV='msys'
16920           else
16921             as_fn_error $? "Unknown Windows environment" "$LINENO" 5
16922           fi
16923           MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'`
16924           IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV`
16925         else
16926           # Not relevant for non-Windows
16927           IS_MAKE_CORRECT_ENV=true
16928         fi
16929         if test "x$IS_MAKE_CORRECT_ENV" = x; then
16930           { $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
16931 $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;}
16932         else
16933           FOUND_MAKE=$MAKE_CANDIDATE
16934 
16935   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
16936 
16937   # First separate the path from the arguments. This will split at the first
16938   # space.
16939   complete="$FOUND_MAKE"
16940   path="${complete%% *}"
16941   tmp="$complete EOL"
16942   arguments="${tmp#* }"
16943 
16944   # Input might be given as Windows format, start by converting to
16945   # unix format.
16946   new_path=`$CYGPATH -u "$path"`
16947 
16948   # Now try to locate executable using which
16949   new_path=`$WHICH "$new_path" 2> /dev/null`
16950   # bat and cmd files are not always considered executable in cygwin causing which
16951   # to not find them
16952   if test "x$new_path" = x \
16953       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16954       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16955     new_path=`$CYGPATH -u "$path"`
16956   fi
16957   if test "x$new_path" = x; then
16958     # Oops. Which didn't find the executable.
16959     # The splitting of arguments from the executable at a space might have been incorrect,
16960     # since paths with space are more likely in Windows. Give it another try with the whole
16961     # argument.
16962     path="$complete"
16963     arguments="EOL"
16964     new_path=`$CYGPATH -u "$path"`
16965     new_path=`$WHICH "$new_path" 2> /dev/null`
16966     # bat and cmd files are not always considered executable in cygwin causing which
16967     # to not find them
16968     if test "x$new_path" = x \
16969         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
16970         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
16971       new_path=`$CYGPATH -u "$path"`
16972     fi
16973     if test "x$new_path" = x; then
16974       # It's still not found. Now this is an unrecoverable error.
16975       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
16976 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
16977       has_space=`$ECHO "$complete" | $GREP " "`
16978       if test "x$has_space" != x; then
16979         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
16980 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
16981       fi
16982       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
16983     fi
16984   fi
16985 
16986   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
16987   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
16988   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
16989   # "foo.exe" is OK but "foo" is an error.
16990   #
16991   # This test is therefore slightly more accurate than "test -f" to check for file presence.
16992   # It is also a way to make sure we got the proper file name for the real test later on.
16993   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
16994   if test "x$test_shortpath" = x; then
16995     # Short path failed, file does not exist as specified.
16996     # Try adding .exe or .cmd
16997     if test -f "${new_path}.exe"; then
16998       input_to_shortpath="${new_path}.exe"
16999     elif test -f "${new_path}.cmd"; then
17000       input_to_shortpath="${new_path}.cmd"
17001     else
17002       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5
17003 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;}
17004       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
17005 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
17006       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
17007     fi
17008   else
17009     input_to_shortpath="$new_path"
17010   fi
17011 
17012   # Call helper function which possibly converts this using DOS-style short mode.
17013   # If so, the updated path is stored in $new_path.
17014   new_path="$input_to_shortpath"
17015 
17016   input_path="$input_to_shortpath"
17017   # Check if we need to convert this using DOS-style short mode. If the path
17018   # contains just simple characters, use it. Otherwise (spaces, weird characters),
17019   # take no chances and rewrite it.
17020   # Note: m4 eats our [], so we need to use [ and ] instead.
17021   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
17022   if test "x$has_forbidden_chars" != x; then
17023     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
17024     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
17025     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
17026     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
17027       # Going to short mode and back again did indeed matter. Since short mode is
17028       # case insensitive, let's make it lowercase to improve readability.
17029       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
17030       # Now convert it back to Unix-stile (cygpath)
17031       input_path=`$CYGPATH -u "$shortmode_path"`
17032       new_path="$input_path"
17033     fi
17034   fi
17035 
17036   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
17037   if test "x$test_cygdrive_prefix" = x; then
17038     # As a simple fix, exclude /usr/bin since it's not a real path.
17039     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
17040       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
17041       # a path prefixed by /cygdrive for fixpath to work.
17042       new_path="$CYGWIN_ROOT_PATH$input_path"
17043     fi
17044   fi
17045 
17046   # remove trailing .exe if any
17047   new_path="${new_path/%.exe/}"
17048 
17049   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
17050 
17051   # First separate the path from the arguments. This will split at the first
17052   # space.
17053   complete="$FOUND_MAKE"
17054   path="${complete%% *}"
17055   tmp="$complete EOL"
17056   arguments="${tmp#* }"
17057 
17058   # Input might be given as Windows format, start by converting to
17059   # unix format.
17060   new_path="$path"
17061 
17062   windows_path="$new_path"
17063   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
17064     unix_path=`$CYGPATH -u "$windows_path"`
17065     new_path="$unix_path"
17066   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
17067     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
17068     new_path="$unix_path"
17069   fi
17070 
17071 
17072   # Now try to locate executable using which
17073   new_path=`$WHICH "$new_path" 2> /dev/null`
17074 
17075   if test "x$new_path" = x; then
17076     # Oops. Which didn't find the executable.
17077     # The splitting of arguments from the executable at a space might have been incorrect,
17078     # since paths with space are more likely in Windows. Give it another try with the whole
17079     # argument.
17080     path="$complete"
17081     arguments="EOL"
17082     new_path="$path"
17083 
17084   windows_path="$new_path"
17085   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
17086     unix_path=`$CYGPATH -u "$windows_path"`
17087     new_path="$unix_path"
17088   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
17089     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
17090     new_path="$unix_path"
17091   fi
17092 
17093 
17094     new_path=`$WHICH "$new_path" 2> /dev/null`
17095     # bat and cmd files are not always considered executable in MSYS causing which
17096     # to not find them
17097     if test "x$new_path" = x \
17098         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
17099         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
17100       new_path="$path"
17101 
17102   windows_path="$new_path"
17103   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
17104     unix_path=`$CYGPATH -u "$windows_path"`
17105     new_path="$unix_path"
17106   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
17107     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
17108     new_path="$unix_path"
17109   fi
17110 
17111     fi
17112 
17113     if test "x$new_path" = x; then
17114       # It's still not found. Now this is an unrecoverable error.
17115       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
17116 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
17117       has_space=`$ECHO "$complete" | $GREP " "`
17118       if test "x$has_space" != x; then
17119         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
17120 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
17121       fi
17122       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
17123     fi
17124   fi
17125 
17126   # Now new_path has a complete unix path to the binary
17127   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
17128     # Keep paths in /bin as-is, but remove trailing .exe if any
17129     new_path="${new_path/%.exe/}"
17130     # Do not save /bin paths to all_fixpath_prefixes!
17131   else
17132     # Not in mixed or Windows style, start by that.
17133     new_path=`cmd //c echo $new_path`
17134 
17135   input_path="$new_path"
17136   # Check if we need to convert this using DOS-style short mode. If the path
17137   # contains just simple characters, use it. Otherwise (spaces, weird characters),
17138   # take no chances and rewrite it.
17139   # Note: m4 eats our [], so we need to use [ and ] instead.
17140   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
17141   if test "x$has_forbidden_chars" != x; then
17142     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
17143     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
17144   fi
17145 
17146     # Output is in $new_path
17147 
17148   windows_path="$new_path"
17149   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
17150     unix_path=`$CYGPATH -u "$windows_path"`
17151     new_path="$unix_path"
17152   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
17153     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
17154     new_path="$unix_path"
17155   fi
17156 
17157     # remove trailing .exe if any
17158     new_path="${new_path/%.exe/}"
17159 
17160     # Save the first 10 bytes of this path to the storage, so fixpath can work.
17161     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
17162   fi
17163 
17164   else
17165     # We're on a unix platform. Hooray! :)
17166     # First separate the path from the arguments. This will split at the first
17167     # space.
17168     complete="$FOUND_MAKE"
17169     path="${complete%% *}"
17170     tmp="$complete EOL"
17171     arguments="${tmp#* }"
17172 
17173     # Cannot rely on the command "which" here since it doesn't always work.
17174     is_absolute_path=`$ECHO "$path" | $GREP ^/`
17175     if test -z "$is_absolute_path"; then
17176       # Path to executable is not absolute. Find it.
17177       IFS_save="$IFS"
17178       IFS=:
17179       for p in $PATH; do
17180         if test -f "$p/$path" && test -x "$p/$path"; then
17181           new_path="$p/$path"
17182           break
17183         fi
17184       done
17185       IFS="$IFS_save"
17186     else
17187       # This is an absolute path, we can use it without further modifications.
17188       new_path="$path"
17189     fi
17190 
17191     if test "x$new_path" = x; then
17192       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5
17193 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;}
17194       has_space=`$ECHO "$complete" | $GREP " "`
17195       if test "x$has_space" != x; then
17196         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
17197 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
17198       fi
17199       as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5
17200     fi
17201   fi
17202 
17203   # Now join together the path and the arguments once again
17204   if test "x$arguments" != xEOL; then
17205     new_complete="$new_path ${arguments% *}"
17206   else
17207     new_complete="$new_path"
17208   fi
17209 
17210   if test "x$complete" != "x$new_complete"; then
17211     FOUND_MAKE="$new_complete"
17212     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
17213 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
17214   fi
17215 
17216         fi
17217       fi
17218     fi
17219   fi
17220 
17221         fi
17222         PATH=$OLD_PATH
17223       fi
17224     fi
17225 
17226     if test "x$FOUND_MAKE" = x; then
17227       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
17228     fi
17229   fi
17230 
17231   MAKE=$FOUND_MAKE
17232 
17233   { $as_echo "$as_me:${as_lineno-$LINENO}: Using GNU make 3.81 (or later) at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&5
17234 $as_echo "$as_me: Using GNU make 3.81 (or later) at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&6;}
17235 
17236 
17237   # Check if make supports the output sync option and if so, setup using it.
17238   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if make --output-sync is supported" >&5
17239 $as_echo_n "checking if make --output-sync is supported... " >&6; }
17240   if $MAKE --version -O > /dev/null 2>&1; then
17241     OUTPUT_SYNC_SUPPORTED=true
17242     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17243 $as_echo "yes" >&6; }
17244     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for output-sync value" >&5
17245 $as_echo_n "checking for output-sync value... " >&6; }
17246 
17247 # Check whether --with-output-sync was given.
17248 if test "${with_output_sync+set}" = set; then :
17249   withval=$with_output_sync; OUTPUT_SYNC=$with_output_sync
17250 fi
17251 
17252     if test "x$OUTPUT_SYNC" = "x"; then
17253       OUTPUT_SYNC=none
17254     fi
17255     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_SYNC" >&5
17256 $as_echo "$OUTPUT_SYNC" >&6; }
17257     if ! $MAKE --version -O$OUTPUT_SYNC > /dev/null 2>&1; then
17258       as_fn_error $? "Make did not the support the value $OUTPUT_SYNC as output sync type." "$LINENO" 5
17259     fi
17260   else
17261     OUTPUT_SYNC_SUPPORTED=false
17262     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17263 $as_echo "no" >&6; }
17264   fi
17265 
17266 
17267 
17268 
17269 
17270 
17271   # Test if find supports -delete
17272   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if find supports -delete" >&5
17273 $as_echo_n "checking if find supports -delete... " >&6; }
17274   FIND_DELETE="-delete"
17275 
17276   DELETEDIR=`$MKTEMP -d tmp.XXXXXXXXXX` || (echo Could not create temporary directory!; exit $?)
17277 
17278   echo Hejsan > $DELETEDIR/TestIfFindSupportsDelete
17279 
17280   TEST_DELETE=`$FIND "$DELETEDIR" -name TestIfFindSupportsDelete $FIND_DELETE 2>&1`
17281   if test -f $DELETEDIR/TestIfFindSupportsDelete; then
17282     # No, it does not.
17283     rm $DELETEDIR/TestIfFindSupportsDelete
17284     if test "x$OPENJDK_TARGET_OS" = "xaix"; then
17285       # AIX 'find' is buggy if called with '-exec {} \+' and an empty file list
17286       FIND_DELETE="-print | xargs rm"
17287     else
17288       FIND_DELETE="-exec rm \{\} \+"
17289     fi
17290     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17291 $as_echo "no" >&6; }
17292   else
17293     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17294 $as_echo "yes" >&6; }
17295   fi
17296   rmdir $DELETEDIR
17297 
17298 
17299 
17300   # These tools might not be installed by default,
17301   # need hint on how to install them.
17302 
17303 
17304 
17305   # Publish this variable in the help.
17306 
17307 
17308   if test "x$UNZIP" = x; then
17309     # The variable is not set by user, try to locate tool using the code snippet
17310     for ac_prog in unzip
17311 do
17312   # Extract the first word of "$ac_prog", so it can be a program name with args.
17313 set dummy $ac_prog; ac_word=$2
17314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17315 $as_echo_n "checking for $ac_word... " >&6; }
17316 if ${ac_cv_path_UNZIP+:} false; then :
17317   $as_echo_n "(cached) " >&6
17318 else
17319   case $UNZIP in
17320   [\\/]* | ?:[\\/]*)
17321   ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path.
17322   ;;
17323   *)
17324   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17325 for as_dir in $PATH
17326 do
17327   IFS=$as_save_IFS
17328   test -z "$as_dir" && as_dir=.
17329     for ac_exec_ext in '' $ac_executable_extensions; do
17330   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17331     ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext"
17332     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17333     break 2
17334   fi
17335 done
17336   done
17337 IFS=$as_save_IFS
17338 
17339   ;;
17340 esac
17341 fi
17342 UNZIP=$ac_cv_path_UNZIP
17343 if test -n "$UNZIP"; then
17344   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5
17345 $as_echo "$UNZIP" >&6; }
17346 else
17347   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17348 $as_echo "no" >&6; }
17349 fi
17350 
17351 
17352   test -n "$UNZIP" && break
17353 done
17354 
17355   else
17356     # The variable is set, but is it from the command line or the environment?
17357 
17358     # Try to remove the string !UNZIP! from our list.
17359     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNZIP!/}
17360     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17361       # If it failed, the variable was not from the command line. Ignore it,
17362       # but warn the user (except for BASH, which is always set by the calling BASH).
17363       if test "xUNZIP" != xBASH; then
17364         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&5
17365 $as_echo "$as_me: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&2;}
17366       fi
17367       # Try to locate tool using the code snippet
17368       for ac_prog in unzip
17369 do
17370   # Extract the first word of "$ac_prog", so it can be a program name with args.
17371 set dummy $ac_prog; ac_word=$2
17372 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17373 $as_echo_n "checking for $ac_word... " >&6; }
17374 if ${ac_cv_path_UNZIP+:} false; then :
17375   $as_echo_n "(cached) " >&6
17376 else
17377   case $UNZIP in
17378   [\\/]* | ?:[\\/]*)
17379   ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path.
17380   ;;
17381   *)
17382   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17383 for as_dir in $PATH
17384 do
17385   IFS=$as_save_IFS
17386   test -z "$as_dir" && as_dir=.
17387     for ac_exec_ext in '' $ac_executable_extensions; do
17388   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17389     ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext"
17390     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17391     break 2
17392   fi
17393 done
17394   done
17395 IFS=$as_save_IFS
17396 
17397   ;;
17398 esac
17399 fi
17400 UNZIP=$ac_cv_path_UNZIP
17401 if test -n "$UNZIP"; then
17402   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5
17403 $as_echo "$UNZIP" >&6; }
17404 else
17405   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17406 $as_echo "no" >&6; }
17407 fi
17408 
17409 
17410   test -n "$UNZIP" && break
17411 done
17412 
17413     else
17414       # If it succeeded, then it was overridden by the user. We will use it
17415       # for the tool.
17416 
17417       # First remove it from the list of overridden variables, so we can test
17418       # for unknown variables in the end.
17419       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17420 
17421       # Check if the provided tool contains a complete path.
17422       tool_specified="$UNZIP"
17423       tool_basename="${tool_specified##*/}"
17424       if test "x$tool_basename" = "x$tool_specified"; then
17425         # A command without a complete path is provided, search $PATH.
17426         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNZIP=$tool_basename" >&5
17427 $as_echo "$as_me: Will search for user supplied tool UNZIP=$tool_basename" >&6;}
17428         # Extract the first word of "$tool_basename", so it can be a program name with args.
17429 set dummy $tool_basename; ac_word=$2
17430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17431 $as_echo_n "checking for $ac_word... " >&6; }
17432 if ${ac_cv_path_UNZIP+:} false; then :
17433   $as_echo_n "(cached) " >&6
17434 else
17435   case $UNZIP in
17436   [\\/]* | ?:[\\/]*)
17437   ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path.
17438   ;;
17439   *)
17440   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17441 for as_dir in $PATH
17442 do
17443   IFS=$as_save_IFS
17444   test -z "$as_dir" && as_dir=.
17445     for ac_exec_ext in '' $ac_executable_extensions; do
17446   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17447     ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext"
17448     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17449     break 2
17450   fi
17451 done
17452   done
17453 IFS=$as_save_IFS
17454 
17455   ;;
17456 esac
17457 fi
17458 UNZIP=$ac_cv_path_UNZIP
17459 if test -n "$UNZIP"; then
17460   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5
17461 $as_echo "$UNZIP" >&6; }
17462 else
17463   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17464 $as_echo "no" >&6; }
17465 fi
17466 
17467 
17468         if test "x$UNZIP" = x; then
17469           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17470         fi
17471       else
17472         # Otherwise we believe it is a complete path. Use it as it is.
17473         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNZIP=$tool_specified" >&5
17474 $as_echo "$as_me: Will use user supplied tool UNZIP=$tool_specified" >&6;}
17475         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5
17476 $as_echo_n "checking for UNZIP... " >&6; }
17477         if test ! -x "$tool_specified"; then
17478           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17479 $as_echo "not found" >&6; }
17480           as_fn_error $? "User supplied tool UNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5
17481         fi
17482         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17483 $as_echo "$tool_specified" >&6; }
17484       fi
17485     fi
17486   fi
17487 
17488 
17489 
17490   if test "x$UNZIP" = x; then
17491     as_fn_error $? "Could not find required tool for UNZIP" "$LINENO" 5
17492   fi
17493 
17494 
17495 
17496 
17497 
17498   # Publish this variable in the help.
17499 
17500 
17501   if test "x$ZIP" = x; then
17502     # The variable is not set by user, try to locate tool using the code snippet
17503     for ac_prog in zip
17504 do
17505   # Extract the first word of "$ac_prog", so it can be a program name with args.
17506 set dummy $ac_prog; ac_word=$2
17507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17508 $as_echo_n "checking for $ac_word... " >&6; }
17509 if ${ac_cv_path_ZIP+:} false; then :
17510   $as_echo_n "(cached) " >&6
17511 else
17512   case $ZIP in
17513   [\\/]* | ?:[\\/]*)
17514   ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path.
17515   ;;
17516   *)
17517   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17518 for as_dir in $PATH
17519 do
17520   IFS=$as_save_IFS
17521   test -z "$as_dir" && as_dir=.
17522     for ac_exec_ext in '' $ac_executable_extensions; do
17523   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17524     ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext"
17525     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17526     break 2
17527   fi
17528 done
17529   done
17530 IFS=$as_save_IFS
17531 
17532   ;;
17533 esac
17534 fi
17535 ZIP=$ac_cv_path_ZIP
17536 if test -n "$ZIP"; then
17537   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5
17538 $as_echo "$ZIP" >&6; }
17539 else
17540   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17541 $as_echo "no" >&6; }
17542 fi
17543 
17544 
17545   test -n "$ZIP" && break
17546 done
17547 
17548   else
17549     # The variable is set, but is it from the command line or the environment?
17550 
17551     # Try to remove the string !ZIP! from our list.
17552     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ZIP!/}
17553     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17554       # If it failed, the variable was not from the command line. Ignore it,
17555       # but warn the user (except for BASH, which is always set by the calling BASH).
17556       if test "xZIP" != xBASH; then
17557         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&5
17558 $as_echo "$as_me: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&2;}
17559       fi
17560       # Try to locate tool using the code snippet
17561       for ac_prog in zip
17562 do
17563   # Extract the first word of "$ac_prog", so it can be a program name with args.
17564 set dummy $ac_prog; ac_word=$2
17565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17566 $as_echo_n "checking for $ac_word... " >&6; }
17567 if ${ac_cv_path_ZIP+:} false; then :
17568   $as_echo_n "(cached) " >&6
17569 else
17570   case $ZIP in
17571   [\\/]* | ?:[\\/]*)
17572   ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path.
17573   ;;
17574   *)
17575   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17576 for as_dir in $PATH
17577 do
17578   IFS=$as_save_IFS
17579   test -z "$as_dir" && as_dir=.
17580     for ac_exec_ext in '' $ac_executable_extensions; do
17581   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17582     ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext"
17583     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17584     break 2
17585   fi
17586 done
17587   done
17588 IFS=$as_save_IFS
17589 
17590   ;;
17591 esac
17592 fi
17593 ZIP=$ac_cv_path_ZIP
17594 if test -n "$ZIP"; then
17595   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5
17596 $as_echo "$ZIP" >&6; }
17597 else
17598   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17599 $as_echo "no" >&6; }
17600 fi
17601 
17602 
17603   test -n "$ZIP" && break
17604 done
17605 
17606     else
17607       # If it succeeded, then it was overridden by the user. We will use it
17608       # for the tool.
17609 
17610       # First remove it from the list of overridden variables, so we can test
17611       # for unknown variables in the end.
17612       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17613 
17614       # Check if the provided tool contains a complete path.
17615       tool_specified="$ZIP"
17616       tool_basename="${tool_specified##*/}"
17617       if test "x$tool_basename" = "x$tool_specified"; then
17618         # A command without a complete path is provided, search $PATH.
17619         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ZIP=$tool_basename" >&5
17620 $as_echo "$as_me: Will search for user supplied tool ZIP=$tool_basename" >&6;}
17621         # Extract the first word of "$tool_basename", so it can be a program name with args.
17622 set dummy $tool_basename; ac_word=$2
17623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17624 $as_echo_n "checking for $ac_word... " >&6; }
17625 if ${ac_cv_path_ZIP+:} false; then :
17626   $as_echo_n "(cached) " >&6
17627 else
17628   case $ZIP in
17629   [\\/]* | ?:[\\/]*)
17630   ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path.
17631   ;;
17632   *)
17633   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17634 for as_dir in $PATH
17635 do
17636   IFS=$as_save_IFS
17637   test -z "$as_dir" && as_dir=.
17638     for ac_exec_ext in '' $ac_executable_extensions; do
17639   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17640     ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext"
17641     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17642     break 2
17643   fi
17644 done
17645   done
17646 IFS=$as_save_IFS
17647 
17648   ;;
17649 esac
17650 fi
17651 ZIP=$ac_cv_path_ZIP
17652 if test -n "$ZIP"; then
17653   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5
17654 $as_echo "$ZIP" >&6; }
17655 else
17656   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17657 $as_echo "no" >&6; }
17658 fi
17659 
17660 
17661         if test "x$ZIP" = x; then
17662           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17663         fi
17664       else
17665         # Otherwise we believe it is a complete path. Use it as it is.
17666         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ZIP=$tool_specified" >&5
17667 $as_echo "$as_me: Will use user supplied tool ZIP=$tool_specified" >&6;}
17668         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIP" >&5
17669 $as_echo_n "checking for ZIP... " >&6; }
17670         if test ! -x "$tool_specified"; then
17671           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17672 $as_echo "not found" >&6; }
17673           as_fn_error $? "User supplied tool ZIP=$tool_specified does not exist or is not executable" "$LINENO" 5
17674         fi
17675         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17676 $as_echo "$tool_specified" >&6; }
17677       fi
17678     fi
17679   fi
17680 
17681 
17682 
17683   if test "x$ZIP" = x; then
17684     as_fn_error $? "Could not find required tool for ZIP" "$LINENO" 5
17685   fi
17686 
17687 
17688 
17689   # Non-required basic tools
17690 
17691 
17692 
17693   # Publish this variable in the help.
17694 
17695 
17696   if test "x$LDD" = x; then
17697     # The variable is not set by user, try to locate tool using the code snippet
17698     for ac_prog in ldd
17699 do
17700   # Extract the first word of "$ac_prog", so it can be a program name with args.
17701 set dummy $ac_prog; ac_word=$2
17702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17703 $as_echo_n "checking for $ac_word... " >&6; }
17704 if ${ac_cv_path_LDD+:} false; then :
17705   $as_echo_n "(cached) " >&6
17706 else
17707   case $LDD in
17708   [\\/]* | ?:[\\/]*)
17709   ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
17710   ;;
17711   *)
17712   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17713 for as_dir in $PATH
17714 do
17715   IFS=$as_save_IFS
17716   test -z "$as_dir" && as_dir=.
17717     for ac_exec_ext in '' $ac_executable_extensions; do
17718   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17719     ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
17720     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17721     break 2
17722   fi
17723 done
17724   done
17725 IFS=$as_save_IFS
17726 
17727   ;;
17728 esac
17729 fi
17730 LDD=$ac_cv_path_LDD
17731 if test -n "$LDD"; then
17732   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5
17733 $as_echo "$LDD" >&6; }
17734 else
17735   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17736 $as_echo "no" >&6; }
17737 fi
17738 
17739 
17740   test -n "$LDD" && break
17741 done
17742 
17743   else
17744     # The variable is set, but is it from the command line or the environment?
17745 
17746     # Try to remove the string !LDD! from our list.
17747     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LDD!/}
17748     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17749       # If it failed, the variable was not from the command line. Ignore it,
17750       # but warn the user (except for BASH, which is always set by the calling BASH).
17751       if test "xLDD" != xBASH; then
17752         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&5
17753 $as_echo "$as_me: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&2;}
17754       fi
17755       # Try to locate tool using the code snippet
17756       for ac_prog in ldd
17757 do
17758   # Extract the first word of "$ac_prog", so it can be a program name with args.
17759 set dummy $ac_prog; ac_word=$2
17760 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17761 $as_echo_n "checking for $ac_word... " >&6; }
17762 if ${ac_cv_path_LDD+:} false; then :
17763   $as_echo_n "(cached) " >&6
17764 else
17765   case $LDD in
17766   [\\/]* | ?:[\\/]*)
17767   ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
17768   ;;
17769   *)
17770   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17771 for as_dir in $PATH
17772 do
17773   IFS=$as_save_IFS
17774   test -z "$as_dir" && as_dir=.
17775     for ac_exec_ext in '' $ac_executable_extensions; do
17776   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17777     ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
17778     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17779     break 2
17780   fi
17781 done
17782   done
17783 IFS=$as_save_IFS
17784 
17785   ;;
17786 esac
17787 fi
17788 LDD=$ac_cv_path_LDD
17789 if test -n "$LDD"; then
17790   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5
17791 $as_echo "$LDD" >&6; }
17792 else
17793   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17794 $as_echo "no" >&6; }
17795 fi
17796 
17797 
17798   test -n "$LDD" && break
17799 done
17800 
17801     else
17802       # If it succeeded, then it was overridden by the user. We will use it
17803       # for the tool.
17804 
17805       # First remove it from the list of overridden variables, so we can test
17806       # for unknown variables in the end.
17807       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
17808 
17809       # Check if the provided tool contains a complete path.
17810       tool_specified="$LDD"
17811       tool_basename="${tool_specified##*/}"
17812       if test "x$tool_basename" = "x$tool_specified"; then
17813         # A command without a complete path is provided, search $PATH.
17814         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LDD=$tool_basename" >&5
17815 $as_echo "$as_me: Will search for user supplied tool LDD=$tool_basename" >&6;}
17816         # Extract the first word of "$tool_basename", so it can be a program name with args.
17817 set dummy $tool_basename; ac_word=$2
17818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17819 $as_echo_n "checking for $ac_word... " >&6; }
17820 if ${ac_cv_path_LDD+:} false; then :
17821   $as_echo_n "(cached) " >&6
17822 else
17823   case $LDD in
17824   [\\/]* | ?:[\\/]*)
17825   ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
17826   ;;
17827   *)
17828   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17829 for as_dir in $PATH
17830 do
17831   IFS=$as_save_IFS
17832   test -z "$as_dir" && as_dir=.
17833     for ac_exec_ext in '' $ac_executable_extensions; do
17834   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17835     ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
17836     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17837     break 2
17838   fi
17839 done
17840   done
17841 IFS=$as_save_IFS
17842 
17843   ;;
17844 esac
17845 fi
17846 LDD=$ac_cv_path_LDD
17847 if test -n "$LDD"; then
17848   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5
17849 $as_echo "$LDD" >&6; }
17850 else
17851   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17852 $as_echo "no" >&6; }
17853 fi
17854 
17855 
17856         if test "x$LDD" = x; then
17857           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
17858         fi
17859       else
17860         # Otherwise we believe it is a complete path. Use it as it is.
17861         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LDD=$tool_specified" >&5
17862 $as_echo "$as_me: Will use user supplied tool LDD=$tool_specified" >&6;}
17863         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5
17864 $as_echo_n "checking for LDD... " >&6; }
17865         if test ! -x "$tool_specified"; then
17866           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
17867 $as_echo "not found" >&6; }
17868           as_fn_error $? "User supplied tool LDD=$tool_specified does not exist or is not executable" "$LINENO" 5
17869         fi
17870         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
17871 $as_echo "$tool_specified" >&6; }
17872       fi
17873     fi
17874   fi
17875 
17876 
17877   if test "x$LDD" = "x"; then
17878     # List shared lib dependencies is used for
17879     # debug output and checking for forbidden dependencies.
17880     # We can build without it.
17881     LDD="true"
17882   fi
17883 
17884 
17885   # Publish this variable in the help.
17886 
17887 
17888   if test "x$OTOOL" = x; then
17889     # The variable is not set by user, try to locate tool using the code snippet
17890     for ac_prog in otool
17891 do
17892   # Extract the first word of "$ac_prog", so it can be a program name with args.
17893 set dummy $ac_prog; ac_word=$2
17894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17895 $as_echo_n "checking for $ac_word... " >&6; }
17896 if ${ac_cv_path_OTOOL+:} false; then :
17897   $as_echo_n "(cached) " >&6
17898 else
17899   case $OTOOL in
17900   [\\/]* | ?:[\\/]*)
17901   ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path.
17902   ;;
17903   *)
17904   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17905 for as_dir in $PATH
17906 do
17907   IFS=$as_save_IFS
17908   test -z "$as_dir" && as_dir=.
17909     for ac_exec_ext in '' $ac_executable_extensions; do
17910   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17911     ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext"
17912     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17913     break 2
17914   fi
17915 done
17916   done
17917 IFS=$as_save_IFS
17918 
17919   ;;
17920 esac
17921 fi
17922 OTOOL=$ac_cv_path_OTOOL
17923 if test -n "$OTOOL"; then
17924   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
17925 $as_echo "$OTOOL" >&6; }
17926 else
17927   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17928 $as_echo "no" >&6; }
17929 fi
17930 
17931 
17932   test -n "$OTOOL" && break
17933 done
17934 
17935   else
17936     # The variable is set, but is it from the command line or the environment?
17937 
17938     # Try to remove the string !OTOOL! from our list.
17939     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OTOOL!/}
17940     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
17941       # If it failed, the variable was not from the command line. Ignore it,
17942       # but warn the user (except for BASH, which is always set by the calling BASH).
17943       if test "xOTOOL" != xBASH; then
17944         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&5
17945 $as_echo "$as_me: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&2;}
17946       fi
17947       # Try to locate tool using the code snippet
17948       for ac_prog in otool
17949 do
17950   # Extract the first word of "$ac_prog", so it can be a program name with args.
17951 set dummy $ac_prog; ac_word=$2
17952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17953 $as_echo_n "checking for $ac_word... " >&6; }
17954 if ${ac_cv_path_OTOOL+:} false; then :
17955   $as_echo_n "(cached) " >&6
17956 else
17957   case $OTOOL in
17958   [\\/]* | ?:[\\/]*)
17959   ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path.
17960   ;;
17961   *)
17962   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17963 for as_dir in $PATH
17964 do
17965   IFS=$as_save_IFS
17966   test -z "$as_dir" && as_dir=.
17967     for ac_exec_ext in '' $ac_executable_extensions; do
17968   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
17969     ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext"
17970     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17971     break 2
17972   fi
17973 done
17974   done
17975 IFS=$as_save_IFS
17976 
17977   ;;
17978 esac
17979 fi
17980 OTOOL=$ac_cv_path_OTOOL
17981 if test -n "$OTOOL"; then
17982   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
17983 $as_echo "$OTOOL" >&6; }
17984 else
17985   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17986 $as_echo "no" >&6; }
17987 fi
17988 
17989 
17990   test -n "$OTOOL" && break
17991 done
17992 
17993     else
17994       # If it succeeded, then it was overridden by the user. We will use it
17995       # for the tool.
17996 
17997       # First remove it from the list of overridden variables, so we can test
17998       # for unknown variables in the end.
17999       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18000 
18001       # Check if the provided tool contains a complete path.
18002       tool_specified="$OTOOL"
18003       tool_basename="${tool_specified##*/}"
18004       if test "x$tool_basename" = "x$tool_specified"; then
18005         # A command without a complete path is provided, search $PATH.
18006         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OTOOL=$tool_basename" >&5
18007 $as_echo "$as_me: Will search for user supplied tool OTOOL=$tool_basename" >&6;}
18008         # Extract the first word of "$tool_basename", so it can be a program name with args.
18009 set dummy $tool_basename; ac_word=$2
18010 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18011 $as_echo_n "checking for $ac_word... " >&6; }
18012 if ${ac_cv_path_OTOOL+:} false; then :
18013   $as_echo_n "(cached) " >&6
18014 else
18015   case $OTOOL in
18016   [\\/]* | ?:[\\/]*)
18017   ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path.
18018   ;;
18019   *)
18020   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18021 for as_dir in $PATH
18022 do
18023   IFS=$as_save_IFS
18024   test -z "$as_dir" && as_dir=.
18025     for ac_exec_ext in '' $ac_executable_extensions; do
18026   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18027     ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext"
18028     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18029     break 2
18030   fi
18031 done
18032   done
18033 IFS=$as_save_IFS
18034 
18035   ;;
18036 esac
18037 fi
18038 OTOOL=$ac_cv_path_OTOOL
18039 if test -n "$OTOOL"; then
18040   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
18041 $as_echo "$OTOOL" >&6; }
18042 else
18043   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18044 $as_echo "no" >&6; }
18045 fi
18046 
18047 
18048         if test "x$OTOOL" = x; then
18049           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18050         fi
18051       else
18052         # Otherwise we believe it is a complete path. Use it as it is.
18053         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OTOOL=$tool_specified" >&5
18054 $as_echo "$as_me: Will use user supplied tool OTOOL=$tool_specified" >&6;}
18055         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5
18056 $as_echo_n "checking for OTOOL... " >&6; }
18057         if test ! -x "$tool_specified"; then
18058           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18059 $as_echo "not found" >&6; }
18060           as_fn_error $? "User supplied tool OTOOL=$tool_specified does not exist or is not executable" "$LINENO" 5
18061         fi
18062         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18063 $as_echo "$tool_specified" >&6; }
18064       fi
18065     fi
18066   fi
18067 
18068 
18069   if test "x$OTOOL" = "x"; then
18070     OTOOL="true"
18071   fi
18072 
18073 
18074   # Publish this variable in the help.
18075 
18076 
18077   if test "x$READELF" = x; then
18078     # The variable is not set by user, try to locate tool using the code snippet
18079     for ac_prog in greadelf readelf
18080 do
18081   # Extract the first word of "$ac_prog", so it can be a program name with args.
18082 set dummy $ac_prog; ac_word=$2
18083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18084 $as_echo_n "checking for $ac_word... " >&6; }
18085 if ${ac_cv_path_READELF+:} false; then :
18086   $as_echo_n "(cached) " >&6
18087 else
18088   case $READELF in
18089   [\\/]* | ?:[\\/]*)
18090   ac_cv_path_READELF="$READELF" # Let the user override the test with a path.
18091   ;;
18092   *)
18093   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18094 for as_dir in $PATH
18095 do
18096   IFS=$as_save_IFS
18097   test -z "$as_dir" && as_dir=.
18098     for ac_exec_ext in '' $ac_executable_extensions; do
18099   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18100     ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext"
18101     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18102     break 2
18103   fi
18104 done
18105   done
18106 IFS=$as_save_IFS
18107 
18108   ;;
18109 esac
18110 fi
18111 READELF=$ac_cv_path_READELF
18112 if test -n "$READELF"; then
18113   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
18114 $as_echo "$READELF" >&6; }
18115 else
18116   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18117 $as_echo "no" >&6; }
18118 fi
18119 
18120 
18121   test -n "$READELF" && break
18122 done
18123 
18124   else
18125     # The variable is set, but is it from the command line or the environment?
18126 
18127     # Try to remove the string !READELF! from our list.
18128     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READELF!/}
18129     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18130       # If it failed, the variable was not from the command line. Ignore it,
18131       # but warn the user (except for BASH, which is always set by the calling BASH).
18132       if test "xREADELF" != xBASH; then
18133         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&5
18134 $as_echo "$as_me: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&2;}
18135       fi
18136       # Try to locate tool using the code snippet
18137       for ac_prog in greadelf readelf
18138 do
18139   # Extract the first word of "$ac_prog", so it can be a program name with args.
18140 set dummy $ac_prog; ac_word=$2
18141 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18142 $as_echo_n "checking for $ac_word... " >&6; }
18143 if ${ac_cv_path_READELF+:} false; then :
18144   $as_echo_n "(cached) " >&6
18145 else
18146   case $READELF in
18147   [\\/]* | ?:[\\/]*)
18148   ac_cv_path_READELF="$READELF" # Let the user override the test with a path.
18149   ;;
18150   *)
18151   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18152 for as_dir in $PATH
18153 do
18154   IFS=$as_save_IFS
18155   test -z "$as_dir" && as_dir=.
18156     for ac_exec_ext in '' $ac_executable_extensions; do
18157   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18158     ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext"
18159     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18160     break 2
18161   fi
18162 done
18163   done
18164 IFS=$as_save_IFS
18165 
18166   ;;
18167 esac
18168 fi
18169 READELF=$ac_cv_path_READELF
18170 if test -n "$READELF"; then
18171   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
18172 $as_echo "$READELF" >&6; }
18173 else
18174   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18175 $as_echo "no" >&6; }
18176 fi
18177 
18178 
18179   test -n "$READELF" && break
18180 done
18181 
18182     else
18183       # If it succeeded, then it was overridden by the user. We will use it
18184       # for the tool.
18185 
18186       # First remove it from the list of overridden variables, so we can test
18187       # for unknown variables in the end.
18188       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18189 
18190       # Check if the provided tool contains a complete path.
18191       tool_specified="$READELF"
18192       tool_basename="${tool_specified##*/}"
18193       if test "x$tool_basename" = "x$tool_specified"; then
18194         # A command without a complete path is provided, search $PATH.
18195         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READELF=$tool_basename" >&5
18196 $as_echo "$as_me: Will search for user supplied tool READELF=$tool_basename" >&6;}
18197         # Extract the first word of "$tool_basename", so it can be a program name with args.
18198 set dummy $tool_basename; ac_word=$2
18199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18200 $as_echo_n "checking for $ac_word... " >&6; }
18201 if ${ac_cv_path_READELF+:} false; then :
18202   $as_echo_n "(cached) " >&6
18203 else
18204   case $READELF in
18205   [\\/]* | ?:[\\/]*)
18206   ac_cv_path_READELF="$READELF" # Let the user override the test with a path.
18207   ;;
18208   *)
18209   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18210 for as_dir in $PATH
18211 do
18212   IFS=$as_save_IFS
18213   test -z "$as_dir" && as_dir=.
18214     for ac_exec_ext in '' $ac_executable_extensions; do
18215   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18216     ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext"
18217     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18218     break 2
18219   fi
18220 done
18221   done
18222 IFS=$as_save_IFS
18223 
18224   ;;
18225 esac
18226 fi
18227 READELF=$ac_cv_path_READELF
18228 if test -n "$READELF"; then
18229   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
18230 $as_echo "$READELF" >&6; }
18231 else
18232   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18233 $as_echo "no" >&6; }
18234 fi
18235 
18236 
18237         if test "x$READELF" = x; then
18238           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18239         fi
18240       else
18241         # Otherwise we believe it is a complete path. Use it as it is.
18242         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READELF=$tool_specified" >&5
18243 $as_echo "$as_me: Will use user supplied tool READELF=$tool_specified" >&6;}
18244         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5
18245 $as_echo_n "checking for READELF... " >&6; }
18246         if test ! -x "$tool_specified"; then
18247           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18248 $as_echo "not found" >&6; }
18249           as_fn_error $? "User supplied tool READELF=$tool_specified does not exist or is not executable" "$LINENO" 5
18250         fi
18251         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18252 $as_echo "$tool_specified" >&6; }
18253       fi
18254     fi
18255   fi
18256 
18257 
18258 
18259 
18260   # Publish this variable in the help.
18261 
18262 
18263   if test "x$HG" = x; then
18264     # The variable is not set by user, try to locate tool using the code snippet
18265     for ac_prog in hg
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_HG+:} false; then :
18272   $as_echo_n "(cached) " >&6
18273 else
18274   case $HG in
18275   [\\/]* | ?:[\\/]*)
18276   ac_cv_path_HG="$HG" # 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_HG="$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 HG=$ac_cv_path_HG
18298 if test -n "$HG"; then
18299   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5
18300 $as_echo "$HG" >&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 "$HG" && break
18308 done
18309 
18310   else
18311     # The variable is set, but is it from the command line or the environment?
18312 
18313     # Try to remove the string !HG! from our list.
18314     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HG!/}
18315     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18316       # If it failed, the variable was not from the command line. Ignore it,
18317       # but warn the user (except for BASH, which is always set by the calling BASH).
18318       if test "xHG" != xBASH; then
18319         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&5
18320 $as_echo "$as_me: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&2;}
18321       fi
18322       # Try to locate tool using the code snippet
18323       for ac_prog in hg
18324 do
18325   # Extract the first word of "$ac_prog", so it can be a program name with args.
18326 set dummy $ac_prog; 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_HG+:} false; then :
18330   $as_echo_n "(cached) " >&6
18331 else
18332   case $HG in
18333   [\\/]* | ?:[\\/]*)
18334   ac_cv_path_HG="$HG" # 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_HG="$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 HG=$ac_cv_path_HG
18356 if test -n "$HG"; then
18357   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5
18358 $as_echo "$HG" >&6; }
18359 else
18360   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18361 $as_echo "no" >&6; }
18362 fi
18363 
18364 
18365   test -n "$HG" && break
18366 done
18367 
18368     else
18369       # If it succeeded, then it was overridden by the user. We will use it
18370       # for the tool.
18371 
18372       # First remove it from the list of overridden variables, so we can test
18373       # for unknown variables in the end.
18374       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18375 
18376       # Check if the provided tool contains a complete path.
18377       tool_specified="$HG"
18378       tool_basename="${tool_specified##*/}"
18379       if test "x$tool_basename" = "x$tool_specified"; then
18380         # A command without a complete path is provided, search $PATH.
18381         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HG=$tool_basename" >&5
18382 $as_echo "$as_me: Will search for user supplied tool HG=$tool_basename" >&6;}
18383         # Extract the first word of "$tool_basename", so it can be a program name with args.
18384 set dummy $tool_basename; ac_word=$2
18385 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18386 $as_echo_n "checking for $ac_word... " >&6; }
18387 if ${ac_cv_path_HG+:} false; then :
18388   $as_echo_n "(cached) " >&6
18389 else
18390   case $HG in
18391   [\\/]* | ?:[\\/]*)
18392   ac_cv_path_HG="$HG" # Let the user override the test with a path.
18393   ;;
18394   *)
18395   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18396 for as_dir in $PATH
18397 do
18398   IFS=$as_save_IFS
18399   test -z "$as_dir" && as_dir=.
18400     for ac_exec_ext in '' $ac_executable_extensions; do
18401   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18402     ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext"
18403     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18404     break 2
18405   fi
18406 done
18407   done
18408 IFS=$as_save_IFS
18409 
18410   ;;
18411 esac
18412 fi
18413 HG=$ac_cv_path_HG
18414 if test -n "$HG"; then
18415   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5
18416 $as_echo "$HG" >&6; }
18417 else
18418   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18419 $as_echo "no" >&6; }
18420 fi
18421 
18422 
18423         if test "x$HG" = x; then
18424           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18425         fi
18426       else
18427         # Otherwise we believe it is a complete path. Use it as it is.
18428         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HG=$tool_specified" >&5
18429 $as_echo "$as_me: Will use user supplied tool HG=$tool_specified" >&6;}
18430         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5
18431 $as_echo_n "checking for HG... " >&6; }
18432         if test ! -x "$tool_specified"; then
18433           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18434 $as_echo "not found" >&6; }
18435           as_fn_error $? "User supplied tool HG=$tool_specified does not exist or is not executable" "$LINENO" 5
18436         fi
18437         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18438 $as_echo "$tool_specified" >&6; }
18439       fi
18440     fi
18441   fi
18442 
18443 
18444 
18445 
18446   # Publish this variable in the help.
18447 
18448 
18449   if test "x$STAT" = x; then
18450     # The variable is not set by user, try to locate tool using the code snippet
18451     for ac_prog in stat
18452 do
18453   # Extract the first word of "$ac_prog", so it can be a program name with args.
18454 set dummy $ac_prog; ac_word=$2
18455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18456 $as_echo_n "checking for $ac_word... " >&6; }
18457 if ${ac_cv_path_STAT+:} false; then :
18458   $as_echo_n "(cached) " >&6
18459 else
18460   case $STAT in
18461   [\\/]* | ?:[\\/]*)
18462   ac_cv_path_STAT="$STAT" # Let the user override the test with a path.
18463   ;;
18464   *)
18465   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18466 for as_dir in $PATH
18467 do
18468   IFS=$as_save_IFS
18469   test -z "$as_dir" && as_dir=.
18470     for ac_exec_ext in '' $ac_executable_extensions; do
18471   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18472     ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext"
18473     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18474     break 2
18475   fi
18476 done
18477   done
18478 IFS=$as_save_IFS
18479 
18480   ;;
18481 esac
18482 fi
18483 STAT=$ac_cv_path_STAT
18484 if test -n "$STAT"; then
18485   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5
18486 $as_echo "$STAT" >&6; }
18487 else
18488   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18489 $as_echo "no" >&6; }
18490 fi
18491 
18492 
18493   test -n "$STAT" && break
18494 done
18495 
18496   else
18497     # The variable is set, but is it from the command line or the environment?
18498 
18499     # Try to remove the string !STAT! from our list.
18500     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STAT!/}
18501     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18502       # If it failed, the variable was not from the command line. Ignore it,
18503       # but warn the user (except for BASH, which is always set by the calling BASH).
18504       if test "xSTAT" != xBASH; then
18505         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&5
18506 $as_echo "$as_me: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&2;}
18507       fi
18508       # Try to locate tool using the code snippet
18509       for ac_prog in stat
18510 do
18511   # Extract the first word of "$ac_prog", so it can be a program name with args.
18512 set dummy $ac_prog; ac_word=$2
18513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18514 $as_echo_n "checking for $ac_word... " >&6; }
18515 if ${ac_cv_path_STAT+:} false; then :
18516   $as_echo_n "(cached) " >&6
18517 else
18518   case $STAT in
18519   [\\/]* | ?:[\\/]*)
18520   ac_cv_path_STAT="$STAT" # Let the user override the test with a path.
18521   ;;
18522   *)
18523   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18524 for as_dir in $PATH
18525 do
18526   IFS=$as_save_IFS
18527   test -z "$as_dir" && as_dir=.
18528     for ac_exec_ext in '' $ac_executable_extensions; do
18529   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18530     ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext"
18531     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18532     break 2
18533   fi
18534 done
18535   done
18536 IFS=$as_save_IFS
18537 
18538   ;;
18539 esac
18540 fi
18541 STAT=$ac_cv_path_STAT
18542 if test -n "$STAT"; then
18543   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5
18544 $as_echo "$STAT" >&6; }
18545 else
18546   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18547 $as_echo "no" >&6; }
18548 fi
18549 
18550 
18551   test -n "$STAT" && break
18552 done
18553 
18554     else
18555       # If it succeeded, then it was overridden by the user. We will use it
18556       # for the tool.
18557 
18558       # First remove it from the list of overridden variables, so we can test
18559       # for unknown variables in the end.
18560       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18561 
18562       # Check if the provided tool contains a complete path.
18563       tool_specified="$STAT"
18564       tool_basename="${tool_specified##*/}"
18565       if test "x$tool_basename" = "x$tool_specified"; then
18566         # A command without a complete path is provided, search $PATH.
18567         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STAT=$tool_basename" >&5
18568 $as_echo "$as_me: Will search for user supplied tool STAT=$tool_basename" >&6;}
18569         # Extract the first word of "$tool_basename", so it can be a program name with args.
18570 set dummy $tool_basename; ac_word=$2
18571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18572 $as_echo_n "checking for $ac_word... " >&6; }
18573 if ${ac_cv_path_STAT+:} false; then :
18574   $as_echo_n "(cached) " >&6
18575 else
18576   case $STAT in
18577   [\\/]* | ?:[\\/]*)
18578   ac_cv_path_STAT="$STAT" # Let the user override the test with a path.
18579   ;;
18580   *)
18581   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18582 for as_dir in $PATH
18583 do
18584   IFS=$as_save_IFS
18585   test -z "$as_dir" && as_dir=.
18586     for ac_exec_ext in '' $ac_executable_extensions; do
18587   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18588     ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext"
18589     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18590     break 2
18591   fi
18592 done
18593   done
18594 IFS=$as_save_IFS
18595 
18596   ;;
18597 esac
18598 fi
18599 STAT=$ac_cv_path_STAT
18600 if test -n "$STAT"; then
18601   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5
18602 $as_echo "$STAT" >&6; }
18603 else
18604   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18605 $as_echo "no" >&6; }
18606 fi
18607 
18608 
18609         if test "x$STAT" = x; then
18610           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18611         fi
18612       else
18613         # Otherwise we believe it is a complete path. Use it as it is.
18614         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STAT=$tool_specified" >&5
18615 $as_echo "$as_me: Will use user supplied tool STAT=$tool_specified" >&6;}
18616         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5
18617 $as_echo_n "checking for STAT... " >&6; }
18618         if test ! -x "$tool_specified"; then
18619           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18620 $as_echo "not found" >&6; }
18621           as_fn_error $? "User supplied tool STAT=$tool_specified does not exist or is not executable" "$LINENO" 5
18622         fi
18623         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18624 $as_echo "$tool_specified" >&6; }
18625       fi
18626     fi
18627   fi
18628 
18629 
18630 
18631 
18632   # Publish this variable in the help.
18633 
18634 
18635   if test "x$TIME" = x; then
18636     # The variable is not set by user, try to locate tool using the code snippet
18637     for ac_prog in time
18638 do
18639   # Extract the first word of "$ac_prog", so it can be a program name with args.
18640 set dummy $ac_prog; ac_word=$2
18641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18642 $as_echo_n "checking for $ac_word... " >&6; }
18643 if ${ac_cv_path_TIME+:} false; then :
18644   $as_echo_n "(cached) " >&6
18645 else
18646   case $TIME in
18647   [\\/]* | ?:[\\/]*)
18648   ac_cv_path_TIME="$TIME" # Let the user override the test with a path.
18649   ;;
18650   *)
18651   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18652 for as_dir in $PATH
18653 do
18654   IFS=$as_save_IFS
18655   test -z "$as_dir" && as_dir=.
18656     for ac_exec_ext in '' $ac_executable_extensions; do
18657   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18658     ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext"
18659     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18660     break 2
18661   fi
18662 done
18663   done
18664 IFS=$as_save_IFS
18665 
18666   ;;
18667 esac
18668 fi
18669 TIME=$ac_cv_path_TIME
18670 if test -n "$TIME"; then
18671   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5
18672 $as_echo "$TIME" >&6; }
18673 else
18674   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18675 $as_echo "no" >&6; }
18676 fi
18677 
18678 
18679   test -n "$TIME" && break
18680 done
18681 
18682   else
18683     # The variable is set, but is it from the command line or the environment?
18684 
18685     # Try to remove the string !TIME! from our list.
18686     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TIME!/}
18687     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18688       # If it failed, the variable was not from the command line. Ignore it,
18689       # but warn the user (except for BASH, which is always set by the calling BASH).
18690       if test "xTIME" != xBASH; then
18691         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&5
18692 $as_echo "$as_me: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&2;}
18693       fi
18694       # Try to locate tool using the code snippet
18695       for ac_prog in time
18696 do
18697   # Extract the first word of "$ac_prog", so it can be a program name with args.
18698 set dummy $ac_prog; ac_word=$2
18699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18700 $as_echo_n "checking for $ac_word... " >&6; }
18701 if ${ac_cv_path_TIME+:} false; then :
18702   $as_echo_n "(cached) " >&6
18703 else
18704   case $TIME in
18705   [\\/]* | ?:[\\/]*)
18706   ac_cv_path_TIME="$TIME" # Let the user override the test with a path.
18707   ;;
18708   *)
18709   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18710 for as_dir in $PATH
18711 do
18712   IFS=$as_save_IFS
18713   test -z "$as_dir" && as_dir=.
18714     for ac_exec_ext in '' $ac_executable_extensions; do
18715   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18716     ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext"
18717     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18718     break 2
18719   fi
18720 done
18721   done
18722 IFS=$as_save_IFS
18723 
18724   ;;
18725 esac
18726 fi
18727 TIME=$ac_cv_path_TIME
18728 if test -n "$TIME"; then
18729   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5
18730 $as_echo "$TIME" >&6; }
18731 else
18732   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18733 $as_echo "no" >&6; }
18734 fi
18735 
18736 
18737   test -n "$TIME" && break
18738 done
18739 
18740     else
18741       # If it succeeded, then it was overridden by the user. We will use it
18742       # for the tool.
18743 
18744       # First remove it from the list of overridden variables, so we can test
18745       # for unknown variables in the end.
18746       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18747 
18748       # Check if the provided tool contains a complete path.
18749       tool_specified="$TIME"
18750       tool_basename="${tool_specified##*/}"
18751       if test "x$tool_basename" = "x$tool_specified"; then
18752         # A command without a complete path is provided, search $PATH.
18753         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TIME=$tool_basename" >&5
18754 $as_echo "$as_me: Will search for user supplied tool TIME=$tool_basename" >&6;}
18755         # Extract the first word of "$tool_basename", so it can be a program name with args.
18756 set dummy $tool_basename; ac_word=$2
18757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18758 $as_echo_n "checking for $ac_word... " >&6; }
18759 if ${ac_cv_path_TIME+:} false; then :
18760   $as_echo_n "(cached) " >&6
18761 else
18762   case $TIME in
18763   [\\/]* | ?:[\\/]*)
18764   ac_cv_path_TIME="$TIME" # Let the user override the test with a path.
18765   ;;
18766   *)
18767   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18768 for as_dir in $PATH
18769 do
18770   IFS=$as_save_IFS
18771   test -z "$as_dir" && as_dir=.
18772     for ac_exec_ext in '' $ac_executable_extensions; do
18773   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18774     ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext"
18775     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18776     break 2
18777   fi
18778 done
18779   done
18780 IFS=$as_save_IFS
18781 
18782   ;;
18783 esac
18784 fi
18785 TIME=$ac_cv_path_TIME
18786 if test -n "$TIME"; then
18787   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5
18788 $as_echo "$TIME" >&6; }
18789 else
18790   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18791 $as_echo "no" >&6; }
18792 fi
18793 
18794 
18795         if test "x$TIME" = x; then
18796           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18797         fi
18798       else
18799         # Otherwise we believe it is a complete path. Use it as it is.
18800         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TIME=$tool_specified" >&5
18801 $as_echo "$as_me: Will use user supplied tool TIME=$tool_specified" >&6;}
18802         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5
18803 $as_echo_n "checking for TIME... " >&6; }
18804         if test ! -x "$tool_specified"; then
18805           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
18806 $as_echo "not found" >&6; }
18807           as_fn_error $? "User supplied tool TIME=$tool_specified does not exist or is not executable" "$LINENO" 5
18808         fi
18809         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
18810 $as_echo "$tool_specified" >&6; }
18811       fi
18812     fi
18813   fi
18814 
18815 
18816   # Check if it's GNU time
18817   IS_GNU_TIME=`$TIME --version 2>&1 | $GREP 'GNU time'`
18818   if test "x$IS_GNU_TIME" != x; then
18819     IS_GNU_TIME=yes
18820   else
18821     IS_GNU_TIME=no
18822   fi
18823 
18824 
18825   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
18826 
18827 
18828 
18829   # Publish this variable in the help.
18830 
18831 
18832   if test "x$COMM" = x; then
18833     # The variable is not set by user, try to locate tool using the code snippet
18834     for ac_prog in comm
18835 do
18836   # Extract the first word of "$ac_prog", so it can be a program name with args.
18837 set dummy $ac_prog; ac_word=$2
18838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18839 $as_echo_n "checking for $ac_word... " >&6; }
18840 if ${ac_cv_path_COMM+:} false; then :
18841   $as_echo_n "(cached) " >&6
18842 else
18843   case $COMM in
18844   [\\/]* | ?:[\\/]*)
18845   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
18846   ;;
18847   *)
18848   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18849 for as_dir in $PATH
18850 do
18851   IFS=$as_save_IFS
18852   test -z "$as_dir" && as_dir=.
18853     for ac_exec_ext in '' $ac_executable_extensions; do
18854   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18855     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
18856     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18857     break 2
18858   fi
18859 done
18860   done
18861 IFS=$as_save_IFS
18862 
18863   ;;
18864 esac
18865 fi
18866 COMM=$ac_cv_path_COMM
18867 if test -n "$COMM"; then
18868   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
18869 $as_echo "$COMM" >&6; }
18870 else
18871   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18872 $as_echo "no" >&6; }
18873 fi
18874 
18875 
18876   test -n "$COMM" && break
18877 done
18878 
18879   else
18880     # The variable is set, but is it from the command line or the environment?
18881 
18882     # Try to remove the string !COMM! from our list.
18883     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/}
18884     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
18885       # If it failed, the variable was not from the command line. Ignore it,
18886       # but warn the user (except for BASH, which is always set by the calling BASH).
18887       if test "xCOMM" != xBASH; then
18888         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5
18889 $as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;}
18890       fi
18891       # Try to locate tool using the code snippet
18892       for ac_prog in comm
18893 do
18894   # Extract the first word of "$ac_prog", so it can be a program name with args.
18895 set dummy $ac_prog; ac_word=$2
18896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18897 $as_echo_n "checking for $ac_word... " >&6; }
18898 if ${ac_cv_path_COMM+:} false; then :
18899   $as_echo_n "(cached) " >&6
18900 else
18901   case $COMM in
18902   [\\/]* | ?:[\\/]*)
18903   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
18904   ;;
18905   *)
18906   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18907 for as_dir in $PATH
18908 do
18909   IFS=$as_save_IFS
18910   test -z "$as_dir" && as_dir=.
18911     for ac_exec_ext in '' $ac_executable_extensions; do
18912   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18913     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
18914     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18915     break 2
18916   fi
18917 done
18918   done
18919 IFS=$as_save_IFS
18920 
18921   ;;
18922 esac
18923 fi
18924 COMM=$ac_cv_path_COMM
18925 if test -n "$COMM"; then
18926   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
18927 $as_echo "$COMM" >&6; }
18928 else
18929   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18930 $as_echo "no" >&6; }
18931 fi
18932 
18933 
18934   test -n "$COMM" && break
18935 done
18936 
18937     else
18938       # If it succeeded, then it was overridden by the user. We will use it
18939       # for the tool.
18940 
18941       # First remove it from the list of overridden variables, so we can test
18942       # for unknown variables in the end.
18943       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
18944 
18945       # Check if the provided tool contains a complete path.
18946       tool_specified="$COMM"
18947       tool_basename="${tool_specified##*/}"
18948       if test "x$tool_basename" = "x$tool_specified"; then
18949         # A command without a complete path is provided, search $PATH.
18950         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5
18951 $as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;}
18952         # Extract the first word of "$tool_basename", so it can be a program name with args.
18953 set dummy $tool_basename; ac_word=$2
18954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18955 $as_echo_n "checking for $ac_word... " >&6; }
18956 if ${ac_cv_path_COMM+:} false; then :
18957   $as_echo_n "(cached) " >&6
18958 else
18959   case $COMM in
18960   [\\/]* | ?:[\\/]*)
18961   ac_cv_path_COMM="$COMM" # Let the user override the test with a path.
18962   ;;
18963   *)
18964   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18965 for as_dir in $PATH
18966 do
18967   IFS=$as_save_IFS
18968   test -z "$as_dir" && as_dir=.
18969     for ac_exec_ext in '' $ac_executable_extensions; do
18970   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18971     ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext"
18972     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18973     break 2
18974   fi
18975 done
18976   done
18977 IFS=$as_save_IFS
18978 
18979   ;;
18980 esac
18981 fi
18982 COMM=$ac_cv_path_COMM
18983 if test -n "$COMM"; then
18984   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5
18985 $as_echo "$COMM" >&6; }
18986 else
18987   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18988 $as_echo "no" >&6; }
18989 fi
18990 
18991 
18992         if test "x$COMM" = x; then
18993           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
18994         fi
18995       else
18996         # Otherwise we believe it is a complete path. Use it as it is.
18997         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5
18998 $as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;}
18999         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5
19000 $as_echo_n "checking for COMM... " >&6; }
19001         if test ! -x "$tool_specified"; then
19002           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
19003 $as_echo "not found" >&6; }
19004           as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5
19005         fi
19006         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
19007 $as_echo "$tool_specified" >&6; }
19008       fi
19009     fi
19010   fi
19011 
19012 
19013 
19014   if test "x$COMM" = x; then
19015     as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5
19016   fi
19017 
19018 
19019   fi
19020 
19021   if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
19022 
19023 
19024 
19025   # Publish this variable in the help.
19026 
19027 
19028   if test "x$DSYMUTIL" = x; then
19029     # The variable is not set by user, try to locate tool using the code snippet
19030     for ac_prog in dsymutil
19031 do
19032   # Extract the first word of "$ac_prog", so it can be a program name with args.
19033 set dummy $ac_prog; ac_word=$2
19034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19035 $as_echo_n "checking for $ac_word... " >&6; }
19036 if ${ac_cv_path_DSYMUTIL+:} false; then :
19037   $as_echo_n "(cached) " >&6
19038 else
19039   case $DSYMUTIL in
19040   [\\/]* | ?:[\\/]*)
19041   ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path.
19042   ;;
19043   *)
19044   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19045 for as_dir in $PATH
19046 do
19047   IFS=$as_save_IFS
19048   test -z "$as_dir" && as_dir=.
19049     for ac_exec_ext in '' $ac_executable_extensions; do
19050   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19051     ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext"
19052     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19053     break 2
19054   fi
19055 done
19056   done
19057 IFS=$as_save_IFS
19058 
19059   ;;
19060 esac
19061 fi
19062 DSYMUTIL=$ac_cv_path_DSYMUTIL
19063 if test -n "$DSYMUTIL"; then
19064   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
19065 $as_echo "$DSYMUTIL" >&6; }
19066 else
19067   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19068 $as_echo "no" >&6; }
19069 fi
19070 
19071 
19072   test -n "$DSYMUTIL" && break
19073 done
19074 
19075   else
19076     # The variable is set, but is it from the command line or the environment?
19077 
19078     # Try to remove the string !DSYMUTIL! from our list.
19079     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DSYMUTIL!/}
19080     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
19081       # If it failed, the variable was not from the command line. Ignore it,
19082       # but warn the user (except for BASH, which is always set by the calling BASH).
19083       if test "xDSYMUTIL" != xBASH; then
19084         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&5
19085 $as_echo "$as_me: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&2;}
19086       fi
19087       # Try to locate tool using the code snippet
19088       for ac_prog in dsymutil
19089 do
19090   # Extract the first word of "$ac_prog", so it can be a program name with args.
19091 set dummy $ac_prog; ac_word=$2
19092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19093 $as_echo_n "checking for $ac_word... " >&6; }
19094 if ${ac_cv_path_DSYMUTIL+:} false; then :
19095   $as_echo_n "(cached) " >&6
19096 else
19097   case $DSYMUTIL in
19098   [\\/]* | ?:[\\/]*)
19099   ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path.
19100   ;;
19101   *)
19102   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19103 for as_dir in $PATH
19104 do
19105   IFS=$as_save_IFS
19106   test -z "$as_dir" && as_dir=.
19107     for ac_exec_ext in '' $ac_executable_extensions; do
19108   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19109     ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext"
19110     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19111     break 2
19112   fi
19113 done
19114   done
19115 IFS=$as_save_IFS
19116 
19117   ;;
19118 esac
19119 fi
19120 DSYMUTIL=$ac_cv_path_DSYMUTIL
19121 if test -n "$DSYMUTIL"; then
19122   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
19123 $as_echo "$DSYMUTIL" >&6; }
19124 else
19125   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19126 $as_echo "no" >&6; }
19127 fi
19128 
19129 
19130   test -n "$DSYMUTIL" && break
19131 done
19132 
19133     else
19134       # If it succeeded, then it was overridden by the user. We will use it
19135       # for the tool.
19136 
19137       # First remove it from the list of overridden variables, so we can test
19138       # for unknown variables in the end.
19139       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
19140 
19141       # Check if the provided tool contains a complete path.
19142       tool_specified="$DSYMUTIL"
19143       tool_basename="${tool_specified##*/}"
19144       if test "x$tool_basename" = "x$tool_specified"; then
19145         # A command without a complete path is provided, search $PATH.
19146         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DSYMUTIL=$tool_basename" >&5
19147 $as_echo "$as_me: Will search for user supplied tool DSYMUTIL=$tool_basename" >&6;}
19148         # Extract the first word of "$tool_basename", so it can be a program name with args.
19149 set dummy $tool_basename; ac_word=$2
19150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19151 $as_echo_n "checking for $ac_word... " >&6; }
19152 if ${ac_cv_path_DSYMUTIL+:} false; then :
19153   $as_echo_n "(cached) " >&6
19154 else
19155   case $DSYMUTIL in
19156   [\\/]* | ?:[\\/]*)
19157   ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path.
19158   ;;
19159   *)
19160   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19161 for as_dir in $PATH
19162 do
19163   IFS=$as_save_IFS
19164   test -z "$as_dir" && as_dir=.
19165     for ac_exec_ext in '' $ac_executable_extensions; do
19166   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19167     ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext"
19168     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19169     break 2
19170   fi
19171 done
19172   done
19173 IFS=$as_save_IFS
19174 
19175   ;;
19176 esac
19177 fi
19178 DSYMUTIL=$ac_cv_path_DSYMUTIL
19179 if test -n "$DSYMUTIL"; then
19180   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
19181 $as_echo "$DSYMUTIL" >&6; }
19182 else
19183   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19184 $as_echo "no" >&6; }
19185 fi
19186 
19187 
19188         if test "x$DSYMUTIL" = x; then
19189           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
19190         fi
19191       else
19192         # Otherwise we believe it is a complete path. Use it as it is.
19193         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DSYMUTIL=$tool_specified" >&5
19194 $as_echo "$as_me: Will use user supplied tool DSYMUTIL=$tool_specified" >&6;}
19195         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5
19196 $as_echo_n "checking for DSYMUTIL... " >&6; }
19197         if test ! -x "$tool_specified"; then
19198           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
19199 $as_echo "not found" >&6; }
19200           as_fn_error $? "User supplied tool DSYMUTIL=$tool_specified does not exist or is not executable" "$LINENO" 5
19201         fi
19202         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
19203 $as_echo "$tool_specified" >&6; }
19204       fi
19205     fi
19206   fi
19207 
19208 
19209 
19210   if test "x$DSYMUTIL" = x; then
19211     as_fn_error $? "Could not find required tool for DSYMUTIL" "$LINENO" 5
19212   fi
19213 
19214 
19215 
19216 
19217 
19218   # Publish this variable in the help.
19219 
19220 
19221   if test "x$XATTR" = x; then
19222     # The variable is not set by user, try to locate tool using the code snippet
19223     for ac_prog in xattr
19224 do
19225   # Extract the first word of "$ac_prog", so it can be a program name with args.
19226 set dummy $ac_prog; ac_word=$2
19227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19228 $as_echo_n "checking for $ac_word... " >&6; }
19229 if ${ac_cv_path_XATTR+:} false; then :
19230   $as_echo_n "(cached) " >&6
19231 else
19232   case $XATTR in
19233   [\\/]* | ?:[\\/]*)
19234   ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path.
19235   ;;
19236   *)
19237   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19238 for as_dir in $PATH
19239 do
19240   IFS=$as_save_IFS
19241   test -z "$as_dir" && as_dir=.
19242     for ac_exec_ext in '' $ac_executable_extensions; do
19243   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19244     ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext"
19245     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19246     break 2
19247   fi
19248 done
19249   done
19250 IFS=$as_save_IFS
19251 
19252   ;;
19253 esac
19254 fi
19255 XATTR=$ac_cv_path_XATTR
19256 if test -n "$XATTR"; then
19257   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5
19258 $as_echo "$XATTR" >&6; }
19259 else
19260   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19261 $as_echo "no" >&6; }
19262 fi
19263 
19264 
19265   test -n "$XATTR" && break
19266 done
19267 
19268   else
19269     # The variable is set, but is it from the command line or the environment?
19270 
19271     # Try to remove the string !XATTR! from our list.
19272     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XATTR!/}
19273     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
19274       # If it failed, the variable was not from the command line. Ignore it,
19275       # but warn the user (except for BASH, which is always set by the calling BASH).
19276       if test "xXATTR" != xBASH; then
19277         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&5
19278 $as_echo "$as_me: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&2;}
19279       fi
19280       # Try to locate tool using the code snippet
19281       for ac_prog in xattr
19282 do
19283   # Extract the first word of "$ac_prog", so it can be a program name with args.
19284 set dummy $ac_prog; ac_word=$2
19285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19286 $as_echo_n "checking for $ac_word... " >&6; }
19287 if ${ac_cv_path_XATTR+:} false; then :
19288   $as_echo_n "(cached) " >&6
19289 else
19290   case $XATTR in
19291   [\\/]* | ?:[\\/]*)
19292   ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path.
19293   ;;
19294   *)
19295   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19296 for as_dir in $PATH
19297 do
19298   IFS=$as_save_IFS
19299   test -z "$as_dir" && as_dir=.
19300     for ac_exec_ext in '' $ac_executable_extensions; do
19301   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19302     ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext"
19303     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19304     break 2
19305   fi
19306 done
19307   done
19308 IFS=$as_save_IFS
19309 
19310   ;;
19311 esac
19312 fi
19313 XATTR=$ac_cv_path_XATTR
19314 if test -n "$XATTR"; then
19315   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5
19316 $as_echo "$XATTR" >&6; }
19317 else
19318   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19319 $as_echo "no" >&6; }
19320 fi
19321 
19322 
19323   test -n "$XATTR" && break
19324 done
19325 
19326     else
19327       # If it succeeded, then it was overridden by the user. We will use it
19328       # for the tool.
19329 
19330       # First remove it from the list of overridden variables, so we can test
19331       # for unknown variables in the end.
19332       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
19333 
19334       # Check if the provided tool contains a complete path.
19335       tool_specified="$XATTR"
19336       tool_basename="${tool_specified##*/}"
19337       if test "x$tool_basename" = "x$tool_specified"; then
19338         # A command without a complete path is provided, search $PATH.
19339         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XATTR=$tool_basename" >&5
19340 $as_echo "$as_me: Will search for user supplied tool XATTR=$tool_basename" >&6;}
19341         # Extract the first word of "$tool_basename", so it can be a program name with args.
19342 set dummy $tool_basename; ac_word=$2
19343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19344 $as_echo_n "checking for $ac_word... " >&6; }
19345 if ${ac_cv_path_XATTR+:} false; then :
19346   $as_echo_n "(cached) " >&6
19347 else
19348   case $XATTR in
19349   [\\/]* | ?:[\\/]*)
19350   ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path.
19351   ;;
19352   *)
19353   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19354 for as_dir in $PATH
19355 do
19356   IFS=$as_save_IFS
19357   test -z "$as_dir" && as_dir=.
19358     for ac_exec_ext in '' $ac_executable_extensions; do
19359   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19360     ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext"
19361     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19362     break 2
19363   fi
19364 done
19365   done
19366 IFS=$as_save_IFS
19367 
19368   ;;
19369 esac
19370 fi
19371 XATTR=$ac_cv_path_XATTR
19372 if test -n "$XATTR"; then
19373   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5
19374 $as_echo "$XATTR" >&6; }
19375 else
19376   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19377 $as_echo "no" >&6; }
19378 fi
19379 
19380 
19381         if test "x$XATTR" = x; then
19382           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
19383         fi
19384       else
19385         # Otherwise we believe it is a complete path. Use it as it is.
19386         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XATTR=$tool_specified" >&5
19387 $as_echo "$as_me: Will use user supplied tool XATTR=$tool_specified" >&6;}
19388         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5
19389 $as_echo_n "checking for XATTR... " >&6; }
19390         if test ! -x "$tool_specified"; then
19391           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
19392 $as_echo "not found" >&6; }
19393           as_fn_error $? "User supplied tool XATTR=$tool_specified does not exist or is not executable" "$LINENO" 5
19394         fi
19395         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
19396 $as_echo "$tool_specified" >&6; }
19397       fi
19398     fi
19399   fi
19400 
19401 
19402 
19403   if test "x$XATTR" = x; then
19404     as_fn_error $? "Could not find required tool for XATTR" "$LINENO" 5
19405   fi
19406 
19407 
19408 
19409 
19410   # Publish this variable in the help.
19411 
19412 
19413   if test "x$CODESIGN" = x; then
19414     # The variable is not set by user, try to locate tool using the code snippet
19415     for ac_prog in codesign
19416 do
19417   # Extract the first word of "$ac_prog", so it can be a program name with args.
19418 set dummy $ac_prog; ac_word=$2
19419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19420 $as_echo_n "checking for $ac_word... " >&6; }
19421 if ${ac_cv_path_CODESIGN+:} false; then :
19422   $as_echo_n "(cached) " >&6
19423 else
19424   case $CODESIGN in
19425   [\\/]* | ?:[\\/]*)
19426   ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path.
19427   ;;
19428   *)
19429   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19430 for as_dir in $PATH
19431 do
19432   IFS=$as_save_IFS
19433   test -z "$as_dir" && as_dir=.
19434     for ac_exec_ext in '' $ac_executable_extensions; do
19435   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19436     ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext"
19437     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19438     break 2
19439   fi
19440 done
19441   done
19442 IFS=$as_save_IFS
19443 
19444   ;;
19445 esac
19446 fi
19447 CODESIGN=$ac_cv_path_CODESIGN
19448 if test -n "$CODESIGN"; then
19449   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5
19450 $as_echo "$CODESIGN" >&6; }
19451 else
19452   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19453 $as_echo "no" >&6; }
19454 fi
19455 
19456 
19457   test -n "$CODESIGN" && break
19458 done
19459 
19460   else
19461     # The variable is set, but is it from the command line or the environment?
19462 
19463     # Try to remove the string !CODESIGN! from our list.
19464     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CODESIGN!/}
19465     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
19466       # If it failed, the variable was not from the command line. Ignore it,
19467       # but warn the user (except for BASH, which is always set by the calling BASH).
19468       if test "xCODESIGN" != xBASH; then
19469         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&5
19470 $as_echo "$as_me: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&2;}
19471       fi
19472       # Try to locate tool using the code snippet
19473       for ac_prog in codesign
19474 do
19475   # Extract the first word of "$ac_prog", so it can be a program name with args.
19476 set dummy $ac_prog; ac_word=$2
19477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19478 $as_echo_n "checking for $ac_word... " >&6; }
19479 if ${ac_cv_path_CODESIGN+:} false; then :
19480   $as_echo_n "(cached) " >&6
19481 else
19482   case $CODESIGN in
19483   [\\/]* | ?:[\\/]*)
19484   ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path.
19485   ;;
19486   *)
19487   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19488 for as_dir in $PATH
19489 do
19490   IFS=$as_save_IFS
19491   test -z "$as_dir" && as_dir=.
19492     for ac_exec_ext in '' $ac_executable_extensions; do
19493   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19494     ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext"
19495     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19496     break 2
19497   fi
19498 done
19499   done
19500 IFS=$as_save_IFS
19501 
19502   ;;
19503 esac
19504 fi
19505 CODESIGN=$ac_cv_path_CODESIGN
19506 if test -n "$CODESIGN"; then
19507   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5
19508 $as_echo "$CODESIGN" >&6; }
19509 else
19510   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19511 $as_echo "no" >&6; }
19512 fi
19513 
19514 
19515   test -n "$CODESIGN" && break
19516 done
19517 
19518     else
19519       # If it succeeded, then it was overridden by the user. We will use it
19520       # for the tool.
19521 
19522       # First remove it from the list of overridden variables, so we can test
19523       # for unknown variables in the end.
19524       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
19525 
19526       # Check if the provided tool contains a complete path.
19527       tool_specified="$CODESIGN"
19528       tool_basename="${tool_specified##*/}"
19529       if test "x$tool_basename" = "x$tool_specified"; then
19530         # A command without a complete path is provided, search $PATH.
19531         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CODESIGN=$tool_basename" >&5
19532 $as_echo "$as_me: Will search for user supplied tool CODESIGN=$tool_basename" >&6;}
19533         # Extract the first word of "$tool_basename", so it can be a program name with args.
19534 set dummy $tool_basename; ac_word=$2
19535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19536 $as_echo_n "checking for $ac_word... " >&6; }
19537 if ${ac_cv_path_CODESIGN+:} false; then :
19538   $as_echo_n "(cached) " >&6
19539 else
19540   case $CODESIGN in
19541   [\\/]* | ?:[\\/]*)
19542   ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path.
19543   ;;
19544   *)
19545   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19546 for as_dir in $PATH
19547 do
19548   IFS=$as_save_IFS
19549   test -z "$as_dir" && as_dir=.
19550     for ac_exec_ext in '' $ac_executable_extensions; do
19551   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19552     ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext"
19553     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19554     break 2
19555   fi
19556 done
19557   done
19558 IFS=$as_save_IFS
19559 
19560   ;;
19561 esac
19562 fi
19563 CODESIGN=$ac_cv_path_CODESIGN
19564 if test -n "$CODESIGN"; then
19565   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5
19566 $as_echo "$CODESIGN" >&6; }
19567 else
19568   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19569 $as_echo "no" >&6; }
19570 fi
19571 
19572 
19573         if test "x$CODESIGN" = x; then
19574           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
19575         fi
19576       else
19577         # Otherwise we believe it is a complete path. Use it as it is.
19578         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CODESIGN=$tool_specified" >&5
19579 $as_echo "$as_me: Will use user supplied tool CODESIGN=$tool_specified" >&6;}
19580         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5
19581 $as_echo_n "checking for CODESIGN... " >&6; }
19582         if test ! -x "$tool_specified"; then
19583           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
19584 $as_echo "not found" >&6; }
19585           as_fn_error $? "User supplied tool CODESIGN=$tool_specified does not exist or is not executable" "$LINENO" 5
19586         fi
19587         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
19588 $as_echo "$tool_specified" >&6; }
19589       fi
19590     fi
19591   fi
19592 
19593 
19594     if test "x$CODESIGN" != "x"; then
19595       # Verify that the openjdk_codesign certificate is present
19596       { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openjdk_codesign certificate is present" >&5
19597 $as_echo_n "checking if openjdk_codesign certificate is present... " >&6; }
19598       rm -f codesign-testfile
19599       touch codesign-testfile
19600       codesign -s openjdk_codesign codesign-testfile 2>&5 >&5 || CODESIGN=
19601       rm -f codesign-testfile
19602       if test "x$CODESIGN" = x; then
19603         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19604 $as_echo "no" >&6; }
19605       else
19606         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19607 $as_echo "yes" >&6; }
19608       fi
19609     fi
19610   fi
19611 
19612 
19613 # Check if pkg-config is available.
19614 
19615 
19616 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
19617         if test -n "$ac_tool_prefix"; then
19618   # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
19619 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
19620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19621 $as_echo_n "checking for $ac_word... " >&6; }
19622 if ${ac_cv_path_PKG_CONFIG+:} false; then :
19623   $as_echo_n "(cached) " >&6
19624 else
19625   case $PKG_CONFIG in
19626   [\\/]* | ?:[\\/]*)
19627   ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
19628   ;;
19629   *)
19630   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19631 for as_dir in $PATH
19632 do
19633   IFS=$as_save_IFS
19634   test -z "$as_dir" && as_dir=.
19635     for ac_exec_ext in '' $ac_executable_extensions; do
19636   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19637     ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
19638     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19639     break 2
19640   fi
19641 done
19642   done
19643 IFS=$as_save_IFS
19644 
19645   ;;
19646 esac
19647 fi
19648 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
19649 if test -n "$PKG_CONFIG"; then
19650   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
19651 $as_echo "$PKG_CONFIG" >&6; }
19652 else
19653   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19654 $as_echo "no" >&6; }
19655 fi
19656 
19657 
19658 fi
19659 if test -z "$ac_cv_path_PKG_CONFIG"; then
19660   ac_pt_PKG_CONFIG=$PKG_CONFIG
19661   # Extract the first word of "pkg-config", so it can be a program name with args.
19662 set dummy pkg-config; ac_word=$2
19663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19664 $as_echo_n "checking for $ac_word... " >&6; }
19665 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
19666   $as_echo_n "(cached) " >&6
19667 else
19668   case $ac_pt_PKG_CONFIG in
19669   [\\/]* | ?:[\\/]*)
19670   ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
19671   ;;
19672   *)
19673   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19674 for as_dir in $PATH
19675 do
19676   IFS=$as_save_IFS
19677   test -z "$as_dir" && as_dir=.
19678     for ac_exec_ext in '' $ac_executable_extensions; do
19679   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19680     ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
19681     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19682     break 2
19683   fi
19684 done
19685   done
19686 IFS=$as_save_IFS
19687 
19688   ;;
19689 esac
19690 fi
19691 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
19692 if test -n "$ac_pt_PKG_CONFIG"; then
19693   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
19694 $as_echo "$ac_pt_PKG_CONFIG" >&6; }
19695 else
19696   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19697 $as_echo "no" >&6; }
19698 fi
19699 
19700   if test "x$ac_pt_PKG_CONFIG" = x; then
19701     PKG_CONFIG=""
19702   else
19703     case $cross_compiling:$ac_tool_warned in
19704 yes:)
19705 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
19706 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
19707 ac_tool_warned=yes ;;
19708 esac
19709     PKG_CONFIG=$ac_pt_PKG_CONFIG
19710   fi
19711 else
19712   PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
19713 fi
19714 
19715 fi
19716 if test -n "$PKG_CONFIG"; then
19717         _pkg_min_version=0.9.0
19718         { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
19719 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
19720         if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
19721                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19722 $as_echo "yes" >&6; }
19723         else
19724                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19725 $as_echo "no" >&6; }
19726                 PKG_CONFIG=""
19727         fi
19728 
19729 fi
19730 
19731 # After basic tools have been setup, we can check build os specific details.
19732 
19733   ###############################################################################
19734 
19735   # Note that this is the build platform OS version!
19736 
19737   OS_VERSION="`uname -r | ${SED} 's!\.! !g' | ${SED} 's!-! !g'`"
19738   OS_VERSION_MAJOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 1 -d ' '`"
19739   OS_VERSION_MINOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 2 -d ' '`"
19740   OS_VERSION_MICRO="`${ECHO} ${OS_VERSION} | ${CUT} -f 3 -d ' '`"
19741 
19742 
19743 
19744 
19745 
19746 # Setup builddeps, for automatic downloading of tools we need.
19747 # This is needed before we can call BDEPS_CHECK_MODULE, which is done in
19748 # boot-jdk setup, but we need to have basic tools setup first.
19749 
19750 
19751 # Check whether --with-builddeps-conf was given.
19752 if test "${with_builddeps_conf+set}" = set; then :
19753   withval=$with_builddeps_conf;
19754 fi
19755 
19756 
19757 
19758 # Check whether --with-builddeps-server was given.
19759 if test "${with_builddeps_server+set}" = set; then :
19760   withval=$with_builddeps_server;
19761 fi
19762 
19763 
19764 
19765 # Check whether --with-builddeps-dir was given.
19766 if test "${with_builddeps_dir+set}" = set; then :
19767   withval=$with_builddeps_dir;
19768 else
19769   with_builddeps_dir=/localhome/builddeps
19770 fi
19771 
19772 
19773 
19774 # Check whether --with-builddeps-group was given.
19775 if test "${with_builddeps_group+set}" = set; then :
19776   withval=$with_builddeps_group;
19777 fi
19778 
19779 
19780 
19781 
19782   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
19783     if test "x$with_builddeps_conf" != x; then
19784       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for supplied builddeps configuration file" >&5
19785 $as_echo_n "checking for supplied builddeps configuration file... " >&6; }
19786       builddepsfile=$with_builddeps_conf
19787       if test -s $builddepsfile; then
19788         . $builddepsfile
19789         { $as_echo "$as_me:${as_lineno-$LINENO}: result: loaded!" >&5
19790 $as_echo "loaded!" >&6; }
19791       else
19792         as_fn_error $? "The given builddeps conf file $with_builddeps_conf could not be loaded!" "$LINENO" 5
19793       fi
19794     else
19795       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for builddeps.conf files in sources..." >&5
19796 $as_echo_n "checking for builddeps.conf files in sources...... " >&6; }
19797       builddepsfile=`mktemp`
19798       touch $builddepsfile
19799       # Put all found confs into a single file.
19800       find ${SRC_ROOT} -name builddeps.conf -exec cat \{\} \; >> $builddepsfile
19801       # Source the file to acquire the variables
19802       if test -s $builddepsfile; then
19803         . $builddepsfile
19804         { $as_echo "$as_me:${as_lineno-$LINENO}: result: found at least one!" >&5
19805 $as_echo "found at least one!" >&6; }
19806       else
19807         as_fn_error $? "Could not find any builddeps.conf at all!" "$LINENO" 5
19808       fi
19809     fi
19810     # Create build and target names that use _ instead of "-" and ".".
19811     # This is necessary to use them in variable names.
19812     build_var=`echo ${OPENJDK_BUILD_AUTOCONF_NAME} | tr '-' '_' | tr '.' '_'`
19813     target_var=`echo ${OPENJDK_TARGET_AUTOCONF_NAME} | tr '-' '_' | tr '.' '_'`
19814     # Extract rewrite information for build and target
19815     eval rewritten_build=\${REWRITE_${build_var}}
19816     if test "x$rewritten_build" = x; then
19817       rewritten_build=${OPENJDK_BUILD_AUTOCONF_NAME}
19818       echo Build stays the same $rewritten_build
19819     else
19820       echo Rewriting build for builddeps into $rewritten_build
19821     fi
19822     eval rewritten_target=\${REWRITE_${target_var}}
19823     if test "x$rewritten_target" = x; then
19824       rewritten_target=${OPENJDK_TARGET_AUTOCONF_NAME}
19825       echo Target stays the same $rewritten_target
19826     else
19827       echo Rewriting target for builddeps into $rewritten_target
19828     fi
19829     rewritten_build_var=`echo ${rewritten_build} | tr '-' '_' | tr '.' '_'`
19830     rewritten_target_var=`echo ${rewritten_target} | tr '-' '_' | tr '.' '_'`
19831   fi
19832   for ac_prog in 7z unzip
19833 do
19834   # Extract the first word of "$ac_prog", so it can be a program name with args.
19835 set dummy $ac_prog; ac_word=$2
19836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19837 $as_echo_n "checking for $ac_word... " >&6; }
19838 if ${ac_cv_prog_BDEPS_UNZIP+:} false; then :
19839   $as_echo_n "(cached) " >&6
19840 else
19841   if test -n "$BDEPS_UNZIP"; then
19842   ac_cv_prog_BDEPS_UNZIP="$BDEPS_UNZIP" # Let the user override the test.
19843 else
19844 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19845 for as_dir in $PATH
19846 do
19847   IFS=$as_save_IFS
19848   test -z "$as_dir" && as_dir=.
19849     for ac_exec_ext in '' $ac_executable_extensions; do
19850   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19851     ac_cv_prog_BDEPS_UNZIP="$ac_prog"
19852     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19853     break 2
19854   fi
19855 done
19856   done
19857 IFS=$as_save_IFS
19858 
19859 fi
19860 fi
19861 BDEPS_UNZIP=$ac_cv_prog_BDEPS_UNZIP
19862 if test -n "$BDEPS_UNZIP"; then
19863   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BDEPS_UNZIP" >&5
19864 $as_echo "$BDEPS_UNZIP" >&6; }
19865 else
19866   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19867 $as_echo "no" >&6; }
19868 fi
19869 
19870 
19871   test -n "$BDEPS_UNZIP" && break
19872 done
19873 
19874   if test "x$BDEPS_UNZIP" = x7z; then
19875     BDEPS_UNZIP="7z x"
19876   fi
19877 
19878   for ac_prog in wget lftp ftp
19879 do
19880   # Extract the first word of "$ac_prog", so it can be a program name with args.
19881 set dummy $ac_prog; ac_word=$2
19882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
19883 $as_echo_n "checking for $ac_word... " >&6; }
19884 if ${ac_cv_prog_BDEPS_FTP+:} false; then :
19885   $as_echo_n "(cached) " >&6
19886 else
19887   if test -n "$BDEPS_FTP"; then
19888   ac_cv_prog_BDEPS_FTP="$BDEPS_FTP" # Let the user override the test.
19889 else
19890 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19891 for as_dir in $PATH
19892 do
19893   IFS=$as_save_IFS
19894   test -z "$as_dir" && as_dir=.
19895     for ac_exec_ext in '' $ac_executable_extensions; do
19896   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19897     ac_cv_prog_BDEPS_FTP="$ac_prog"
19898     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
19899     break 2
19900   fi
19901 done
19902   done
19903 IFS=$as_save_IFS
19904 
19905 fi
19906 fi
19907 BDEPS_FTP=$ac_cv_prog_BDEPS_FTP
19908 if test -n "$BDEPS_FTP"; then
19909   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BDEPS_FTP" >&5
19910 $as_echo "$BDEPS_FTP" >&6; }
19911 else
19912   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19913 $as_echo "no" >&6; }
19914 fi
19915 
19916 
19917   test -n "$BDEPS_FTP" && break
19918 done
19919 
19920 
19921 
19922 ###############################################################################
19923 #
19924 # Determine OpenJDK variants, options and version numbers.
19925 #
19926 ###############################################################################
19927 
19928 # We need build & target for this.
19929 
19930 
19931   ###############################################################################
19932   #
19933   # Should we build a JDK/JVM with headful support (ie a graphical ui)?
19934   # We always build headless support.
19935   #
19936   { $as_echo "$as_me:${as_lineno-$LINENO}: checking headful support" >&5
19937 $as_echo_n "checking headful support... " >&6; }
19938   # Check whether --enable-headful was given.
19939 if test "${enable_headful+set}" = set; then :
19940   enableval=$enable_headful; SUPPORT_HEADFUL=${enable_headful}
19941 else
19942   SUPPORT_HEADFUL=yes
19943 fi
19944 
19945 
19946   SUPPORT_HEADLESS=yes
19947   BUILD_HEADLESS="BUILD_HEADLESS:=true"
19948 
19949   if test "x$SUPPORT_HEADFUL" = xyes; then
19950     # We are building both headful and headless.
19951     headful_msg="include support for both headful and headless"
19952   fi
19953 
19954   if test "x$SUPPORT_HEADFUL" = xno; then
19955     # Thus we are building headless only.
19956     BUILD_HEADLESS="BUILD_HEADLESS:=true"
19957     headful_msg="headless only"
19958   fi
19959 
19960   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $headful_msg" >&5
19961 $as_echo "$headful_msg" >&6; }
19962 
19963 
19964 
19965 
19966 
19967   # Control wether Hotspot runs Queens test after build.
19968   # Check whether --enable-hotspot-test-in-build was given.
19969 if test "${enable_hotspot_test_in_build+set}" = set; then :
19970   enableval=$enable_hotspot_test_in_build;
19971 else
19972   enable_hotspot_test_in_build=no
19973 fi
19974 
19975   if test "x$enable_hotspot_test_in_build" = "xyes"; then
19976     TEST_IN_BUILD=true
19977   else
19978     TEST_IN_BUILD=false
19979   fi
19980 
19981 
19982   ###############################################################################
19983   #
19984   # Choose cacerts source file
19985   #
19986 
19987 # Check whether --with-cacerts-file was given.
19988 if test "${with_cacerts_file+set}" = set; then :
19989   withval=$with_cacerts_file;
19990 fi
19991 
19992   if test "x$with_cacerts_file" != x; then
19993     CACERTS_FILE=$with_cacerts_file
19994   fi
19995 
19996 
19997   ###############################################################################
19998   #
19999   # Enable or disable unlimited crypto
20000   #
20001   # Check whether --enable-unlimited-crypto was given.
20002 if test "${enable_unlimited_crypto+set}" = set; then :
20003   enableval=$enable_unlimited_crypto;
20004 else
20005   enable_unlimited_crypto=no
20006 fi
20007 
20008   if test "x$enable_unlimited_crypto" = "xyes"; then
20009     UNLIMITED_CRYPTO=true
20010   else
20011     UNLIMITED_CRYPTO=false
20012   fi
20013 
20014 
20015   ###############################################################################
20016   #
20017   # Enable or disable the elliptic curve crypto implementation
20018   #
20019 
20020 
20021   ###############################################################################
20022   #
20023   # --enable-rmiconnector-iiop
20024   #
20025   # Check whether --enable-rmiconnector-iiop was given.
20026 if test "${enable_rmiconnector_iiop+set}" = set; then :
20027   enableval=$enable_rmiconnector_iiop;
20028 fi
20029 
20030   if test "x$enable_rmiconnector_iiop" = "xyes"; then
20031     RMICONNECTOR_IIOP=true
20032   else
20033     RMICONNECTOR_IIOP=false
20034   fi
20035 
20036 
20037   ###############################################################################
20038   #
20039   # Compress jars
20040   #
20041   COMPRESS_JARS=false
20042 
20043 
20044 
20045 
20046   # Source the version numbers
20047   . $AUTOCONF_DIR/version-numbers
20048 
20049   # Get the settings from parameters
20050 
20051 # Check whether --with-milestone was given.
20052 if test "${with_milestone+set}" = set; then :
20053   withval=$with_milestone;
20054 fi
20055 
20056   if test "x$with_milestone" = xyes; then
20057     as_fn_error $? "Milestone must have a value" "$LINENO" 5
20058   elif test "x$with_milestone" != x; then
20059     MILESTONE="$with_milestone"
20060   fi
20061   if test "x$MILESTONE" = x; then
20062     MILESTONE=internal
20063   fi
20064 
20065 
20066 # Check whether --with-update-version was given.
20067 if test "${with_update_version+set}" = set; then :
20068   withval=$with_update_version;
20069 fi
20070 
20071   if test "x$with_update_version" = xyes; then
20072     as_fn_error $? "Update version must have a value" "$LINENO" 5
20073   elif test "x$with_update_version" != x; then
20074     JDK_UPDATE_VERSION="$with_update_version"
20075     # On macosx 10.7, it's not possible to set --with-update-version=0X due
20076     # to a bug in expr (which reduces it to just X). To work around this, we
20077     # always add a 0 to one digit update versions.
20078     if test "${#JDK_UPDATE_VERSION}" = "1"; then
20079       JDK_UPDATE_VERSION="0${JDK_UPDATE_VERSION}"
20080     fi
20081   fi
20082 
20083 
20084 # Check whether --with-user-release-suffix was given.
20085 if test "${with_user_release_suffix+set}" = set; then :
20086   withval=$with_user_release_suffix;
20087 fi
20088 
20089   if test "x$with_user_release_suffix" = xyes; then
20090     as_fn_error $? "Release suffix must have a value" "$LINENO" 5
20091   elif test "x$with_user_release_suffix" != x; then
20092     USER_RELEASE_SUFFIX="$with_user_release_suffix"
20093   fi
20094 
20095 
20096 # Check whether --with-build-number was given.
20097 if test "${with_build_number+set}" = set; then :
20098   withval=$with_build_number;
20099 fi
20100 
20101   if test "x$with_build_number" = xyes; then
20102     as_fn_error $? "Build number must have a value" "$LINENO" 5
20103   elif test "x$with_build_number" != x; then
20104     JDK_BUILD_NUMBER="$with_build_number"
20105   fi
20106   # Define default USER_RELEASE_SUFFIX if BUILD_NUMBER and USER_RELEASE_SUFFIX are not set
20107   if test "x$JDK_BUILD_NUMBER" = x; then
20108     JDK_BUILD_NUMBER=b00
20109     if test "x$USER_RELEASE_SUFFIX" = x; then
20110       BUILD_DATE=`date '+%Y_%m_%d_%H_%M'`
20111       # Avoid [:alnum:] since it depends on the locale.
20112       CLEAN_USERNAME=`echo "$USER" | $TR -d -c 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'`
20113       USER_RELEASE_SUFFIX=`echo "${CLEAN_USERNAME}_${BUILD_DATE}" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20114     fi
20115   fi
20116 
20117   # Now set the JDK version, milestone, build number etc.
20118 
20119 
20120 
20121 
20122 
20123 
20124 
20125 
20126 
20127 
20128 
20129 
20130 
20131 
20132 
20133 
20134 # Check whether --with-copyright-year was given.
20135 if test "${with_copyright_year+set}" = set; then :
20136   withval=$with_copyright_year;
20137 fi
20138 
20139   if test "x$with_copyright_year" = xyes; then
20140     as_fn_error $? "Copyright year must have a value" "$LINENO" 5
20141   elif test "x$with_copyright_year" != x; then
20142     COPYRIGHT_YEAR="$with_copyright_year"
20143   else
20144     COPYRIGHT_YEAR=`date +'%Y'`
20145   fi
20146 
20147 
20148   if test "x$JDK_UPDATE_VERSION" != x; then
20149     JDK_VERSION="${JDK_MAJOR_VERSION}.${JDK_MINOR_VERSION}.${JDK_MICRO_VERSION}_${JDK_UPDATE_VERSION}"
20150   else
20151     JDK_VERSION="${JDK_MAJOR_VERSION}.${JDK_MINOR_VERSION}.${JDK_MICRO_VERSION}"
20152   fi
20153 
20154 
20155   COOKED_BUILD_NUMBER=`$ECHO $JDK_BUILD_NUMBER | $SED -e 's/^b//' -e 's/^0//'`
20156 
20157 
20158 
20159 ###############################################################################
20160 #
20161 # Setup BootJDK, used to bootstrap the build.
20162 #
20163 ###############################################################################
20164 
20165 
20166   BOOT_JDK_FOUND=no
20167 
20168 # Check whether --with-boot-jdk was given.
20169 if test "${with_boot_jdk+set}" = set; then :
20170   withval=$with_boot_jdk;
20171 fi
20172 
20173 
20174   # We look for the Boot JDK through various means, going from more certain to
20175   # more of a guess-work. After each test, BOOT_JDK_FOUND is set to "yes" if
20176   # we detected something (if so, the path to the jdk is in BOOT_JDK). But we
20177   # must check if this is indeed valid; otherwise we'll continue looking.
20178 
20179   # Test: Is bootjdk explicitely set by command line arguments?
20180 
20181   if test "x$BOOT_JDK_FOUND" = xno; then
20182     # Now execute the test
20183 
20184   if test "x$with_boot_jdk" != x; then
20185     BOOT_JDK=$with_boot_jdk
20186     BOOT_JDK_FOUND=maybe
20187     { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using configure arguments" >&5
20188 $as_echo "$as_me: Found potential Boot JDK using configure arguments" >&6;}
20189   fi
20190 
20191 
20192     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20193     if test "x$BOOT_JDK_FOUND" = xmaybe; then
20194       # Do we have a bin/java?
20195       if test ! -x "$BOOT_JDK/bin/java"; then
20196         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20197 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20198         BOOT_JDK_FOUND=no
20199       else
20200         # Do we have a bin/javac?
20201         if test ! -x "$BOOT_JDK/bin/javac"; then
20202           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20203 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20204           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20205 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20206           BOOT_JDK_FOUND=no
20207         else
20208           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20209           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20210             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20211 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20212             BOOT_JDK_FOUND=no
20213           else
20214             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20215             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20216 
20217             # Extra M4 quote needed to protect [] in grep expression.
20218             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
20219             if test "x$FOUND_CORRECT_VERSION" = x; then
20220               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20221 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20222               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
20223 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
20224               BOOT_JDK_FOUND=no
20225             else
20226               # We're done! :-)
20227               BOOT_JDK_FOUND=yes
20228 
20229   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20230 
20231   # Input might be given as Windows format, start by converting to
20232   # unix format.
20233   path="$BOOT_JDK"
20234   new_path=`$CYGPATH -u "$path"`
20235 
20236   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20237   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20238   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20239   # "foo.exe" is OK but "foo" is an error.
20240   #
20241   # This test is therefore slightly more accurate than "test -f" to check for file precense.
20242   # It is also a way to make sure we got the proper file name for the real test later on.
20243   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20244   if test "x$test_shortpath" = x; then
20245     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20246 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20247     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20248   fi
20249 
20250   # Call helper function which possibly converts this using DOS-style short mode.
20251   # If so, the updated path is stored in $new_path.
20252 
20253   input_path="$new_path"
20254   # Check if we need to convert this using DOS-style short mode. If the path
20255   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20256   # take no chances and rewrite it.
20257   # Note: m4 eats our [], so we need to use [ and ] instead.
20258   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20259   if test "x$has_forbidden_chars" != x; then
20260     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20261     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20262     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20263     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20264       # Going to short mode and back again did indeed matter. Since short mode is
20265       # case insensitive, let's make it lowercase to improve readability.
20266       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20267       # Now convert it back to Unix-stile (cygpath)
20268       input_path=`$CYGPATH -u "$shortmode_path"`
20269       new_path="$input_path"
20270     fi
20271   fi
20272 
20273   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20274   if test "x$test_cygdrive_prefix" = x; then
20275     # As a simple fix, exclude /usr/bin since it's not a real path.
20276     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20277       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20278       # a path prefixed by /cygdrive for fixpath to work.
20279       new_path="$CYGWIN_ROOT_PATH$input_path"
20280     fi
20281   fi
20282 
20283 
20284   if test "x$path" != "x$new_path"; then
20285     BOOT_JDK="$new_path"
20286     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20287 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20288   fi
20289 
20290   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20291 
20292   path="$BOOT_JDK"
20293   has_colon=`$ECHO $path | $GREP ^.:`
20294   new_path="$path"
20295   if test "x$has_colon" = x; then
20296     # Not in mixed or Windows style, start by that.
20297     new_path=`cmd //c echo $path`
20298   fi
20299 
20300 
20301   input_path="$new_path"
20302   # Check if we need to convert this using DOS-style short mode. If the path
20303   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20304   # take no chances and rewrite it.
20305   # Note: m4 eats our [], so we need to use [ and ] instead.
20306   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20307   if test "x$has_forbidden_chars" != x; then
20308     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20309     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20310   fi
20311 
20312 
20313   windows_path="$new_path"
20314   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20315     unix_path=`$CYGPATH -u "$windows_path"`
20316     new_path="$unix_path"
20317   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20318     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20319     new_path="$unix_path"
20320   fi
20321 
20322   if test "x$path" != "x$new_path"; then
20323     BOOT_JDK="$new_path"
20324     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20325 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20326   fi
20327 
20328   # Save the first 10 bytes of this path to the storage, so fixpath can work.
20329   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20330 
20331   else
20332     # We're on a unix platform. Hooray! :)
20333     path="$BOOT_JDK"
20334     has_space=`$ECHO "$path" | $GREP " "`
20335     if test "x$has_space" != x; then
20336       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20337 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20338       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20339     fi
20340 
20341     # Use eval to expand a potential ~
20342     eval path="$path"
20343     if test ! -f "$path" && test ! -d "$path"; then
20344       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20345     fi
20346 
20347     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20348   fi
20349 
20350               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20351 $as_echo_n "checking for Boot JDK... " >&6; }
20352               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20353 $as_echo "$BOOT_JDK" >&6; }
20354               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20355 $as_echo_n "checking Boot JDK version... " >&6; }
20356               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20357               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20358 $as_echo "$BOOT_JDK_VERSION" >&6; }
20359             fi # end check jdk version
20360           fi # end check rt.jar
20361         fi # end check javac
20362       fi # end check java
20363     fi # end check boot jdk found
20364   fi
20365 
20366   if test "x$with_boot_jdk" != x && test "x$BOOT_JDK_FOUND" = xno; then
20367     # Having specified an argument which is incorrect will produce an instant failure;
20368     # we should not go on looking
20369     as_fn_error $? "The path given by --with-boot-jdk does not contain a valid Boot JDK" "$LINENO" 5
20370   fi
20371 
20372   # Test: Is bootjdk available from builddeps?
20373 
20374   if test "x$BOOT_JDK_FOUND" = xno; then
20375     # Now execute the test
20376 
20377 
20378 
20379   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
20380     # Source the builddeps file again, to make sure it uses the latest variables!
20381     . $builddepsfile
20382     # Look for a target and build machine specific resource!
20383     eval resource=\${builddep_bootjdk_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
20384     if test "x$resource" = x; then
20385       # Ok, lets instead look for a target specific resource
20386       eval resource=\${builddep_bootjdk_TARGET_${rewritten_target_var}}
20387     fi
20388     if test "x$resource" = x; then
20389       # Ok, lets instead look for a build specific resource
20390       eval resource=\${builddep_bootjdk_BUILD_${rewritten_build_var}}
20391     fi
20392     if test "x$resource" = x; then
20393       # Ok, lets instead look for a generic resource
20394       # (The bootjdk comes from M4 and not the shell, thus no need for eval here.)
20395       resource=${builddep_bootjdk}
20396     fi
20397     if test "x$resource" != x; then
20398       { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for bootjdk" >&5
20399 $as_echo "$as_me: Using builddeps $resource for bootjdk" >&6;}
20400       # If the resource in the builddeps.conf file is an existing directory,
20401       # for example /java/linux/cups
20402       if test -d ${resource}; then
20403         depdir=${resource}
20404       else
20405 
20406   # bootjdk is for example mymodule
20407   # $resource is for example libs/general/libmymod_1_2_3.zip
20408   # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
20409   # $with_builddeps_dir is for example /localhome/builddeps
20410   # depdir is the name of the variable into which we store the depdir, eg MYMOD
20411   # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
20412   # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
20413   filename=`basename $resource`
20414   filebase=`echo $filename | sed 's/\.[^\.]*$//'`
20415   filebase=${filename%%.*}
20416   extension=${filename#*.}
20417   installdir=$with_builddeps_dir/$filebase
20418   if test ! -f $installdir/$filename.unpacked; then
20419     { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency bootjdk from $with_builddeps_server/$resource and installing into $installdir" >&5
20420 $as_echo "$as_me: Downloading build dependency bootjdk from $with_builddeps_server/$resource and installing into $installdir" >&6;}
20421     if test ! -d $installdir; then
20422       mkdir -p $installdir
20423     fi
20424     if test ! -d $installdir; then
20425       as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
20426     fi
20427     tmpfile=`mktemp $installdir/bootjdk.XXXXXXXXX`
20428     touch $tmpfile
20429     if test ! -f $tmpfile; then
20430       as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
20431     fi
20432 
20433   # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
20434   # $tmpfile is the local file name for the downloaded file.
20435   VALID_TOOL=no
20436   if test "x$BDEPS_FTP" = xwget; then
20437     VALID_TOOL=yes
20438     wget -O $tmpfile $with_builddeps_server/$resource
20439   fi
20440   if test "x$BDEPS_FTP" = xlftp; then
20441     VALID_TOOL=yes
20442     lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
20443   fi
20444   if test "x$BDEPS_FTP" = xftp; then
20445     VALID_TOOL=yes
20446     FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
20447     FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
20448     FTPUSERPWD=${FTPSERVER%%@*}
20449     if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
20450       FTPUSER=${userpwd%%:*}
20451       FTPPWD=${userpwd#*@}
20452       FTPSERVER=${FTPSERVER#*@}
20453     else
20454       FTPUSER=ftp
20455       FTPPWD=ftp
20456     fi
20457     # the "pass" command does not work on some
20458     # ftp clients (read ftp.exe) but if it works,
20459     # passive mode is better!
20460     ( \
20461         echo "user $FTPUSER $FTPPWD"        ; \
20462         echo "pass"                         ; \
20463         echo "bin"                          ; \
20464         echo "get $FTPPATH $tmpfile"              ; \
20465     ) | ftp -in $FTPSERVER
20466   fi
20467   if test "x$VALID_TOOL" != xyes; then
20468     as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
20469   fi
20470 
20471     mv $tmpfile $installdir/$filename
20472     if test ! -s $installdir/$filename; then
20473       as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
20474     fi
20475     case "$extension" in
20476       zip)  echo "Unzipping $installdir/$filename..."
20477         (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
20478         ;;
20479       tar.gz) echo "Untaring $installdir/$filename..."
20480         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
20481         ;;
20482       tgz) echo "Untaring $installdir/$filename..."
20483         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
20484         ;;
20485       *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
20486         ;;
20487     esac
20488   fi
20489   if test -f $installdir/$filename.unpacked; then
20490     depdir=$installdir
20491   fi
20492 
20493       fi
20494       # Source the builddeps file again, because in the previous command, the depdir
20495       # was updated to point at the current build dependency install directory.
20496       . $builddepsfile
20497       # Now extract variables from the builddeps.conf files.
20498       theroot=${builddep_bootjdk_ROOT}
20499       thecflags=${builddep_bootjdk_CFLAGS}
20500       thelibs=${builddep_bootjdk_LIBS}
20501       if test "x$depdir" = x; then
20502         as_fn_error $? "Could not download build dependency bootjdk" "$LINENO" 5
20503       fi
20504       BOOT_JDK=$depdir
20505       if test "x$theroot" != x; then
20506         BOOT_JDK="$theroot"
20507       fi
20508       if test "x$thecflags" != x; then
20509         BOOT_JDK_CFLAGS="$thecflags"
20510       fi
20511       if test "x$thelibs" != x; then
20512         BOOT_JDK_LIBS="$thelibs"
20513       fi
20514       BOOT_JDK_FOUND=maybe
20515       else BOOT_JDK_FOUND=no
20516 
20517     fi
20518     else BOOT_JDK_FOUND=no
20519 
20520   fi
20521 
20522 
20523 
20524     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20525     if test "x$BOOT_JDK_FOUND" = xmaybe; then
20526       # Do we have a bin/java?
20527       if test ! -x "$BOOT_JDK/bin/java"; then
20528         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20529 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20530         BOOT_JDK_FOUND=no
20531       else
20532         # Do we have a bin/javac?
20533         if test ! -x "$BOOT_JDK/bin/javac"; then
20534           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20535 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20536           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20537 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20538           BOOT_JDK_FOUND=no
20539         else
20540           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20541           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20542             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20543 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20544             BOOT_JDK_FOUND=no
20545           else
20546             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20547             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20548 
20549             # Extra M4 quote needed to protect [] in grep expression.
20550             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
20551             if test "x$FOUND_CORRECT_VERSION" = x; then
20552               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20553 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20554               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
20555 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
20556               BOOT_JDK_FOUND=no
20557             else
20558               # We're done! :-)
20559               BOOT_JDK_FOUND=yes
20560 
20561   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20562 
20563   # Input might be given as Windows format, start by converting to
20564   # unix format.
20565   path="$BOOT_JDK"
20566   new_path=`$CYGPATH -u "$path"`
20567 
20568   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20569   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20570   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20571   # "foo.exe" is OK but "foo" is an error.
20572   #
20573   # This test is therefore slightly more accurate than "test -f" to check for file precense.
20574   # It is also a way to make sure we got the proper file name for the real test later on.
20575   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20576   if test "x$test_shortpath" = x; then
20577     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20578 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20579     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20580   fi
20581 
20582   # Call helper function which possibly converts this using DOS-style short mode.
20583   # If so, the updated path is stored in $new_path.
20584 
20585   input_path="$new_path"
20586   # Check if we need to convert this using DOS-style short mode. If the path
20587   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20588   # take no chances and rewrite it.
20589   # Note: m4 eats our [], so we need to use [ and ] instead.
20590   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20591   if test "x$has_forbidden_chars" != x; then
20592     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20593     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20594     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20595     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20596       # Going to short mode and back again did indeed matter. Since short mode is
20597       # case insensitive, let's make it lowercase to improve readability.
20598       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20599       # Now convert it back to Unix-stile (cygpath)
20600       input_path=`$CYGPATH -u "$shortmode_path"`
20601       new_path="$input_path"
20602     fi
20603   fi
20604 
20605   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20606   if test "x$test_cygdrive_prefix" = x; then
20607     # As a simple fix, exclude /usr/bin since it's not a real path.
20608     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20609       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20610       # a path prefixed by /cygdrive for fixpath to work.
20611       new_path="$CYGWIN_ROOT_PATH$input_path"
20612     fi
20613   fi
20614 
20615 
20616   if test "x$path" != "x$new_path"; then
20617     BOOT_JDK="$new_path"
20618     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20619 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20620   fi
20621 
20622   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20623 
20624   path="$BOOT_JDK"
20625   has_colon=`$ECHO $path | $GREP ^.:`
20626   new_path="$path"
20627   if test "x$has_colon" = x; then
20628     # Not in mixed or Windows style, start by that.
20629     new_path=`cmd //c echo $path`
20630   fi
20631 
20632 
20633   input_path="$new_path"
20634   # Check if we need to convert this using DOS-style short mode. If the path
20635   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20636   # take no chances and rewrite it.
20637   # Note: m4 eats our [], so we need to use [ and ] instead.
20638   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20639   if test "x$has_forbidden_chars" != x; then
20640     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20641     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20642   fi
20643 
20644 
20645   windows_path="$new_path"
20646   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20647     unix_path=`$CYGPATH -u "$windows_path"`
20648     new_path="$unix_path"
20649   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20650     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20651     new_path="$unix_path"
20652   fi
20653 
20654   if test "x$path" != "x$new_path"; then
20655     BOOT_JDK="$new_path"
20656     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20657 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20658   fi
20659 
20660   # Save the first 10 bytes of this path to the storage, so fixpath can work.
20661   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20662 
20663   else
20664     # We're on a unix platform. Hooray! :)
20665     path="$BOOT_JDK"
20666     has_space=`$ECHO "$path" | $GREP " "`
20667     if test "x$has_space" != x; then
20668       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20669 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20670       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20671     fi
20672 
20673     # Use eval to expand a potential ~
20674     eval path="$path"
20675     if test ! -f "$path" && test ! -d "$path"; then
20676       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20677     fi
20678 
20679     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20680   fi
20681 
20682               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20683 $as_echo_n "checking for Boot JDK... " >&6; }
20684               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20685 $as_echo "$BOOT_JDK" >&6; }
20686               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20687 $as_echo_n "checking Boot JDK version... " >&6; }
20688               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20689               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20690 $as_echo "$BOOT_JDK_VERSION" >&6; }
20691             fi # end check jdk version
20692           fi # end check rt.jar
20693         fi # end check javac
20694       fi # end check java
20695     fi # end check boot jdk found
20696   fi
20697 
20698 
20699   # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home?
20700 
20701   if test "x$BOOT_JDK_FOUND" = xno; then
20702     # Now execute the test
20703 
20704   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
20705     # First check at user selected default
20706 
20707   if test "x$BOOT_JDK_FOUND" = xno; then
20708     # Now execute the test
20709 
20710   if test -x /usr/libexec/java_home; then
20711     BOOT_JDK=`/usr/libexec/java_home `
20712     BOOT_JDK_FOUND=maybe
20713     { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home " >&5
20714 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home " >&6;}
20715   fi
20716 
20717 
20718     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20719     if test "x$BOOT_JDK_FOUND" = xmaybe; then
20720       # Do we have a bin/java?
20721       if test ! -x "$BOOT_JDK/bin/java"; then
20722         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20723 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20724         BOOT_JDK_FOUND=no
20725       else
20726         # Do we have a bin/javac?
20727         if test ! -x "$BOOT_JDK/bin/javac"; then
20728           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20729 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20730           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20731 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20732           BOOT_JDK_FOUND=no
20733         else
20734           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20735           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20736             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20737 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20738             BOOT_JDK_FOUND=no
20739           else
20740             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20741             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20742 
20743             # Extra M4 quote needed to protect [] in grep expression.
20744             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
20745             if test "x$FOUND_CORRECT_VERSION" = x; then
20746               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20747 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20748               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
20749 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
20750               BOOT_JDK_FOUND=no
20751             else
20752               # We're done! :-)
20753               BOOT_JDK_FOUND=yes
20754 
20755   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20756 
20757   # Input might be given as Windows format, start by converting to
20758   # unix format.
20759   path="$BOOT_JDK"
20760   new_path=`$CYGPATH -u "$path"`
20761 
20762   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20763   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20764   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20765   # "foo.exe" is OK but "foo" is an error.
20766   #
20767   # This test is therefore slightly more accurate than "test -f" to check for file precense.
20768   # It is also a way to make sure we got the proper file name for the real test later on.
20769   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20770   if test "x$test_shortpath" = x; then
20771     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20772 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20773     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20774   fi
20775 
20776   # Call helper function which possibly converts this using DOS-style short mode.
20777   # If so, the updated path is stored in $new_path.
20778 
20779   input_path="$new_path"
20780   # Check if we need to convert this using DOS-style short mode. If the path
20781   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20782   # take no chances and rewrite it.
20783   # Note: m4 eats our [], so we need to use [ and ] instead.
20784   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20785   if test "x$has_forbidden_chars" != x; then
20786     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20787     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20788     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20789     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20790       # Going to short mode and back again did indeed matter. Since short mode is
20791       # case insensitive, let's make it lowercase to improve readability.
20792       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20793       # Now convert it back to Unix-stile (cygpath)
20794       input_path=`$CYGPATH -u "$shortmode_path"`
20795       new_path="$input_path"
20796     fi
20797   fi
20798 
20799   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20800   if test "x$test_cygdrive_prefix" = x; then
20801     # As a simple fix, exclude /usr/bin since it's not a real path.
20802     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20803       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20804       # a path prefixed by /cygdrive for fixpath to work.
20805       new_path="$CYGWIN_ROOT_PATH$input_path"
20806     fi
20807   fi
20808 
20809 
20810   if test "x$path" != "x$new_path"; then
20811     BOOT_JDK="$new_path"
20812     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20813 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20814   fi
20815 
20816   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20817 
20818   path="$BOOT_JDK"
20819   has_colon=`$ECHO $path | $GREP ^.:`
20820   new_path="$path"
20821   if test "x$has_colon" = x; then
20822     # Not in mixed or Windows style, start by that.
20823     new_path=`cmd //c echo $path`
20824   fi
20825 
20826 
20827   input_path="$new_path"
20828   # Check if we need to convert this using DOS-style short mode. If the path
20829   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20830   # take no chances and rewrite it.
20831   # Note: m4 eats our [], so we need to use [ and ] instead.
20832   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
20833   if test "x$has_forbidden_chars" != x; then
20834     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20835     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20836   fi
20837 
20838 
20839   windows_path="$new_path"
20840   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20841     unix_path=`$CYGPATH -u "$windows_path"`
20842     new_path="$unix_path"
20843   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
20844     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
20845     new_path="$unix_path"
20846   fi
20847 
20848   if test "x$path" != "x$new_path"; then
20849     BOOT_JDK="$new_path"
20850     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
20851 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
20852   fi
20853 
20854   # Save the first 10 bytes of this path to the storage, so fixpath can work.
20855   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
20856 
20857   else
20858     # We're on a unix platform. Hooray! :)
20859     path="$BOOT_JDK"
20860     has_space=`$ECHO "$path" | $GREP " "`
20861     if test "x$has_space" != x; then
20862       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20863 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20864       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
20865     fi
20866 
20867     # Use eval to expand a potential ~
20868     eval path="$path"
20869     if test ! -f "$path" && test ! -d "$path"; then
20870       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
20871     fi
20872 
20873     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
20874   fi
20875 
20876               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
20877 $as_echo_n "checking for Boot JDK... " >&6; }
20878               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
20879 $as_echo "$BOOT_JDK" >&6; }
20880               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
20881 $as_echo_n "checking Boot JDK version... " >&6; }
20882               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
20883               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
20884 $as_echo "$BOOT_JDK_VERSION" >&6; }
20885             fi # end check jdk version
20886           fi # end check rt.jar
20887         fi # end check javac
20888       fi # end check java
20889     fi # end check boot jdk found
20890   fi
20891 
20892     # If that did not work out (e.g. too old), try explicit versions instead
20893 
20894   if test "x$BOOT_JDK_FOUND" = xno; then
20895     # Now execute the test
20896 
20897   if test -x /usr/libexec/java_home; then
20898     BOOT_JDK=`/usr/libexec/java_home -v 1.9`
20899     BOOT_JDK_FOUND=maybe
20900     { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&5
20901 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&6;}
20902   fi
20903 
20904 
20905     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
20906     if test "x$BOOT_JDK_FOUND" = xmaybe; then
20907       # Do we have a bin/java?
20908       if test ! -x "$BOOT_JDK/bin/java"; then
20909         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
20910 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
20911         BOOT_JDK_FOUND=no
20912       else
20913         # Do we have a bin/javac?
20914         if test ! -x "$BOOT_JDK/bin/javac"; then
20915           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
20916 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
20917           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
20918 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
20919           BOOT_JDK_FOUND=no
20920         else
20921           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
20922           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
20923             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
20924 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
20925             BOOT_JDK_FOUND=no
20926           else
20927             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
20928             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
20929 
20930             # Extra M4 quote needed to protect [] in grep expression.
20931             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
20932             if test "x$FOUND_CORRECT_VERSION" = x; then
20933               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
20934 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
20935               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
20936 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
20937               BOOT_JDK_FOUND=no
20938             else
20939               # We're done! :-)
20940               BOOT_JDK_FOUND=yes
20941 
20942   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
20943 
20944   # Input might be given as Windows format, start by converting to
20945   # unix format.
20946   path="$BOOT_JDK"
20947   new_path=`$CYGPATH -u "$path"`
20948 
20949   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
20950   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
20951   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
20952   # "foo.exe" is OK but "foo" is an error.
20953   #
20954   # This test is therefore slightly more accurate than "test -f" to check for file precense.
20955   # It is also a way to make sure we got the proper file name for the real test later on.
20956   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
20957   if test "x$test_shortpath" = x; then
20958     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
20959 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
20960     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
20961   fi
20962 
20963   # Call helper function which possibly converts this using DOS-style short mode.
20964   # If so, the updated path is stored in $new_path.
20965 
20966   input_path="$new_path"
20967   # Check if we need to convert this using DOS-style short mode. If the path
20968   # contains just simple characters, use it. Otherwise (spaces, weird characters),
20969   # take no chances and rewrite it.
20970   # Note: m4 eats our [], so we need to use [ and ] instead.
20971   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
20972   if test "x$has_forbidden_chars" != x; then
20973     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
20974     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
20975     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
20976     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
20977       # Going to short mode and back again did indeed matter. Since short mode is
20978       # case insensitive, let's make it lowercase to improve readability.
20979       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
20980       # Now convert it back to Unix-stile (cygpath)
20981       input_path=`$CYGPATH -u "$shortmode_path"`
20982       new_path="$input_path"
20983     fi
20984   fi
20985 
20986   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
20987   if test "x$test_cygdrive_prefix" = x; then
20988     # As a simple fix, exclude /usr/bin since it's not a real path.
20989     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
20990       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
20991       # a path prefixed by /cygdrive for fixpath to work.
20992       new_path="$CYGWIN_ROOT_PATH$input_path"
20993     fi
20994   fi
20995 
20996 
20997   if test "x$path" != "x$new_path"; then
20998     BOOT_JDK="$new_path"
20999     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21000 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21001   fi
21002 
21003   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21004 
21005   path="$BOOT_JDK"
21006   has_colon=`$ECHO $path | $GREP ^.:`
21007   new_path="$path"
21008   if test "x$has_colon" = x; then
21009     # Not in mixed or Windows style, start by that.
21010     new_path=`cmd //c echo $path`
21011   fi
21012 
21013 
21014   input_path="$new_path"
21015   # Check if we need to convert this using DOS-style short mode. If the path
21016   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21017   # take no chances and rewrite it.
21018   # Note: m4 eats our [], so we need to use [ and ] instead.
21019   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21020   if test "x$has_forbidden_chars" != x; then
21021     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21022     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21023   fi
21024 
21025 
21026   windows_path="$new_path"
21027   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21028     unix_path=`$CYGPATH -u "$windows_path"`
21029     new_path="$unix_path"
21030   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21031     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21032     new_path="$unix_path"
21033   fi
21034 
21035   if test "x$path" != "x$new_path"; then
21036     BOOT_JDK="$new_path"
21037     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21038 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21039   fi
21040 
21041   # Save the first 10 bytes of this path to the storage, so fixpath can work.
21042   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21043 
21044   else
21045     # We're on a unix platform. Hooray! :)
21046     path="$BOOT_JDK"
21047     has_space=`$ECHO "$path" | $GREP " "`
21048     if test "x$has_space" != x; then
21049       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21050 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21051       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21052     fi
21053 
21054     # Use eval to expand a potential ~
21055     eval path="$path"
21056     if test ! -f "$path" && test ! -d "$path"; then
21057       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21058     fi
21059 
21060     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21061   fi
21062 
21063               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21064 $as_echo_n "checking for Boot JDK... " >&6; }
21065               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21066 $as_echo "$BOOT_JDK" >&6; }
21067               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21068 $as_echo_n "checking Boot JDK version... " >&6; }
21069               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21070               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21071 $as_echo "$BOOT_JDK_VERSION" >&6; }
21072             fi # end check jdk version
21073           fi # end check rt.jar
21074         fi # end check javac
21075       fi # end check java
21076     fi # end check boot jdk found
21077   fi
21078 
21079 
21080   if test "x$BOOT_JDK_FOUND" = xno; then
21081     # Now execute the test
21082 
21083   if test -x /usr/libexec/java_home; then
21084     BOOT_JDK=`/usr/libexec/java_home -v 1.8`
21085     BOOT_JDK_FOUND=maybe
21086     { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&5
21087 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&6;}
21088   fi
21089 
21090 
21091     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21092     if test "x$BOOT_JDK_FOUND" = xmaybe; then
21093       # Do we have a bin/java?
21094       if test ! -x "$BOOT_JDK/bin/java"; then
21095         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21096 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21097         BOOT_JDK_FOUND=no
21098       else
21099         # Do we have a bin/javac?
21100         if test ! -x "$BOOT_JDK/bin/javac"; then
21101           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21102 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21103           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21104 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21105           BOOT_JDK_FOUND=no
21106         else
21107           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21108           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21109             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21110 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21111             BOOT_JDK_FOUND=no
21112           else
21113             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21114             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21115 
21116             # Extra M4 quote needed to protect [] in grep expression.
21117             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
21118             if test "x$FOUND_CORRECT_VERSION" = x; then
21119               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21120 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21121               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
21122 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
21123               BOOT_JDK_FOUND=no
21124             else
21125               # We're done! :-)
21126               BOOT_JDK_FOUND=yes
21127 
21128   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21129 
21130   # Input might be given as Windows format, start by converting to
21131   # unix format.
21132   path="$BOOT_JDK"
21133   new_path=`$CYGPATH -u "$path"`
21134 
21135   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21136   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21137   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21138   # "foo.exe" is OK but "foo" is an error.
21139   #
21140   # This test is therefore slightly more accurate than "test -f" to check for file precense.
21141   # It is also a way to make sure we got the proper file name for the real test later on.
21142   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21143   if test "x$test_shortpath" = x; then
21144     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21145 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21146     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21147   fi
21148 
21149   # Call helper function which possibly converts this using DOS-style short mode.
21150   # If so, the updated path is stored in $new_path.
21151 
21152   input_path="$new_path"
21153   # Check if we need to convert this using DOS-style short mode. If the path
21154   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21155   # take no chances and rewrite it.
21156   # Note: m4 eats our [], so we need to use [ and ] instead.
21157   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21158   if test "x$has_forbidden_chars" != x; then
21159     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21160     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21161     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21162     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21163       # Going to short mode and back again did indeed matter. Since short mode is
21164       # case insensitive, let's make it lowercase to improve readability.
21165       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21166       # Now convert it back to Unix-stile (cygpath)
21167       input_path=`$CYGPATH -u "$shortmode_path"`
21168       new_path="$input_path"
21169     fi
21170   fi
21171 
21172   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21173   if test "x$test_cygdrive_prefix" = x; then
21174     # As a simple fix, exclude /usr/bin since it's not a real path.
21175     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21176       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21177       # a path prefixed by /cygdrive for fixpath to work.
21178       new_path="$CYGWIN_ROOT_PATH$input_path"
21179     fi
21180   fi
21181 
21182 
21183   if test "x$path" != "x$new_path"; then
21184     BOOT_JDK="$new_path"
21185     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21186 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21187   fi
21188 
21189   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21190 
21191   path="$BOOT_JDK"
21192   has_colon=`$ECHO $path | $GREP ^.:`
21193   new_path="$path"
21194   if test "x$has_colon" = x; then
21195     # Not in mixed or Windows style, start by that.
21196     new_path=`cmd //c echo $path`
21197   fi
21198 
21199 
21200   input_path="$new_path"
21201   # Check if we need to convert this using DOS-style short mode. If the path
21202   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21203   # take no chances and rewrite it.
21204   # Note: m4 eats our [], so we need to use [ and ] instead.
21205   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21206   if test "x$has_forbidden_chars" != x; then
21207     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21208     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21209   fi
21210 
21211 
21212   windows_path="$new_path"
21213   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21214     unix_path=`$CYGPATH -u "$windows_path"`
21215     new_path="$unix_path"
21216   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21217     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21218     new_path="$unix_path"
21219   fi
21220 
21221   if test "x$path" != "x$new_path"; then
21222     BOOT_JDK="$new_path"
21223     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21224 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21225   fi
21226 
21227   # Save the first 10 bytes of this path to the storage, so fixpath can work.
21228   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21229 
21230   else
21231     # We're on a unix platform. Hooray! :)
21232     path="$BOOT_JDK"
21233     has_space=`$ECHO "$path" | $GREP " "`
21234     if test "x$has_space" != x; then
21235       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21236 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21237       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21238     fi
21239 
21240     # Use eval to expand a potential ~
21241     eval path="$path"
21242     if test ! -f "$path" && test ! -d "$path"; then
21243       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21244     fi
21245 
21246     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21247   fi
21248 
21249               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21250 $as_echo_n "checking for Boot JDK... " >&6; }
21251               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21252 $as_echo "$BOOT_JDK" >&6; }
21253               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21254 $as_echo_n "checking Boot JDK version... " >&6; }
21255               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21256               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21257 $as_echo "$BOOT_JDK_VERSION" >&6; }
21258             fi # end check jdk version
21259           fi # end check rt.jar
21260         fi # end check javac
21261       fi # end check java
21262     fi # end check boot jdk found
21263   fi
21264 
21265 
21266   if test "x$BOOT_JDK_FOUND" = xno; then
21267     # Now execute the test
21268 
21269   if test -x /usr/libexec/java_home; then
21270     BOOT_JDK=`/usr/libexec/java_home -v 1.7`
21271     BOOT_JDK_FOUND=maybe
21272     { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&5
21273 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&6;}
21274   fi
21275 
21276 
21277     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21278     if test "x$BOOT_JDK_FOUND" = xmaybe; then
21279       # Do we have a bin/java?
21280       if test ! -x "$BOOT_JDK/bin/java"; then
21281         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21282 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21283         BOOT_JDK_FOUND=no
21284       else
21285         # Do we have a bin/javac?
21286         if test ! -x "$BOOT_JDK/bin/javac"; then
21287           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21288 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21289           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21290 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21291           BOOT_JDK_FOUND=no
21292         else
21293           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21294           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21295             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21296 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21297             BOOT_JDK_FOUND=no
21298           else
21299             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21300             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21301 
21302             # Extra M4 quote needed to protect [] in grep expression.
21303             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
21304             if test "x$FOUND_CORRECT_VERSION" = x; then
21305               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21306 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21307               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
21308 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
21309               BOOT_JDK_FOUND=no
21310             else
21311               # We're done! :-)
21312               BOOT_JDK_FOUND=yes
21313 
21314   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21315 
21316   # Input might be given as Windows format, start by converting to
21317   # unix format.
21318   path="$BOOT_JDK"
21319   new_path=`$CYGPATH -u "$path"`
21320 
21321   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21322   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21323   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21324   # "foo.exe" is OK but "foo" is an error.
21325   #
21326   # This test is therefore slightly more accurate than "test -f" to check for file precense.
21327   # It is also a way to make sure we got the proper file name for the real test later on.
21328   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21329   if test "x$test_shortpath" = x; then
21330     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21331 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21332     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21333   fi
21334 
21335   # Call helper function which possibly converts this using DOS-style short mode.
21336   # If so, the updated path is stored in $new_path.
21337 
21338   input_path="$new_path"
21339   # Check if we need to convert this using DOS-style short mode. If the path
21340   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21341   # take no chances and rewrite it.
21342   # Note: m4 eats our [], so we need to use [ and ] instead.
21343   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21344   if test "x$has_forbidden_chars" != x; then
21345     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21346     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21347     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21348     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21349       # Going to short mode and back again did indeed matter. Since short mode is
21350       # case insensitive, let's make it lowercase to improve readability.
21351       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21352       # Now convert it back to Unix-stile (cygpath)
21353       input_path=`$CYGPATH -u "$shortmode_path"`
21354       new_path="$input_path"
21355     fi
21356   fi
21357 
21358   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21359   if test "x$test_cygdrive_prefix" = x; then
21360     # As a simple fix, exclude /usr/bin since it's not a real path.
21361     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21362       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21363       # a path prefixed by /cygdrive for fixpath to work.
21364       new_path="$CYGWIN_ROOT_PATH$input_path"
21365     fi
21366   fi
21367 
21368 
21369   if test "x$path" != "x$new_path"; then
21370     BOOT_JDK="$new_path"
21371     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21372 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21373   fi
21374 
21375   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21376 
21377   path="$BOOT_JDK"
21378   has_colon=`$ECHO $path | $GREP ^.:`
21379   new_path="$path"
21380   if test "x$has_colon" = x; then
21381     # Not in mixed or Windows style, start by that.
21382     new_path=`cmd //c echo $path`
21383   fi
21384 
21385 
21386   input_path="$new_path"
21387   # Check if we need to convert this using DOS-style short mode. If the path
21388   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21389   # take no chances and rewrite it.
21390   # Note: m4 eats our [], so we need to use [ and ] instead.
21391   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21392   if test "x$has_forbidden_chars" != x; then
21393     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21394     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21395   fi
21396 
21397 
21398   windows_path="$new_path"
21399   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21400     unix_path=`$CYGPATH -u "$windows_path"`
21401     new_path="$unix_path"
21402   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21403     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21404     new_path="$unix_path"
21405   fi
21406 
21407   if test "x$path" != "x$new_path"; then
21408     BOOT_JDK="$new_path"
21409     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21410 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21411   fi
21412 
21413   # Save the first 10 bytes of this path to the storage, so fixpath can work.
21414   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21415 
21416   else
21417     # We're on a unix platform. Hooray! :)
21418     path="$BOOT_JDK"
21419     has_space=`$ECHO "$path" | $GREP " "`
21420     if test "x$has_space" != x; then
21421       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21422 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21423       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21424     fi
21425 
21426     # Use eval to expand a potential ~
21427     eval path="$path"
21428     if test ! -f "$path" && test ! -d "$path"; then
21429       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21430     fi
21431 
21432     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21433   fi
21434 
21435               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21436 $as_echo_n "checking for Boot JDK... " >&6; }
21437               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21438 $as_echo "$BOOT_JDK" >&6; }
21439               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21440 $as_echo_n "checking Boot JDK version... " >&6; }
21441               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21442               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21443 $as_echo "$BOOT_JDK_VERSION" >&6; }
21444             fi # end check jdk version
21445           fi # end check rt.jar
21446         fi # end check javac
21447       fi # end check java
21448     fi # end check boot jdk found
21449   fi
21450 
21451   fi
21452 
21453 
21454     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21455     if test "x$BOOT_JDK_FOUND" = xmaybe; then
21456       # Do we have a bin/java?
21457       if test ! -x "$BOOT_JDK/bin/java"; then
21458         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21459 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21460         BOOT_JDK_FOUND=no
21461       else
21462         # Do we have a bin/javac?
21463         if test ! -x "$BOOT_JDK/bin/javac"; then
21464           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21465 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21466           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21467 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21468           BOOT_JDK_FOUND=no
21469         else
21470           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21471           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21472             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21473 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21474             BOOT_JDK_FOUND=no
21475           else
21476             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21477             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21478 
21479             # Extra M4 quote needed to protect [] in grep expression.
21480             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
21481             if test "x$FOUND_CORRECT_VERSION" = x; then
21482               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21483 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21484               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
21485 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
21486               BOOT_JDK_FOUND=no
21487             else
21488               # We're done! :-)
21489               BOOT_JDK_FOUND=yes
21490 
21491   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21492 
21493   # Input might be given as Windows format, start by converting to
21494   # unix format.
21495   path="$BOOT_JDK"
21496   new_path=`$CYGPATH -u "$path"`
21497 
21498   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21499   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21500   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21501   # "foo.exe" is OK but "foo" is an error.
21502   #
21503   # This test is therefore slightly more accurate than "test -f" to check for file precense.
21504   # It is also a way to make sure we got the proper file name for the real test later on.
21505   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21506   if test "x$test_shortpath" = x; then
21507     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21508 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21509     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21510   fi
21511 
21512   # Call helper function which possibly converts this using DOS-style short mode.
21513   # If so, the updated path is stored in $new_path.
21514 
21515   input_path="$new_path"
21516   # Check if we need to convert this using DOS-style short mode. If the path
21517   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21518   # take no chances and rewrite it.
21519   # Note: m4 eats our [], so we need to use [ and ] instead.
21520   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21521   if test "x$has_forbidden_chars" != x; then
21522     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21523     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21524     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21525     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21526       # Going to short mode and back again did indeed matter. Since short mode is
21527       # case insensitive, let's make it lowercase to improve readability.
21528       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21529       # Now convert it back to Unix-stile (cygpath)
21530       input_path=`$CYGPATH -u "$shortmode_path"`
21531       new_path="$input_path"
21532     fi
21533   fi
21534 
21535   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21536   if test "x$test_cygdrive_prefix" = x; then
21537     # As a simple fix, exclude /usr/bin since it's not a real path.
21538     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21539       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21540       # a path prefixed by /cygdrive for fixpath to work.
21541       new_path="$CYGWIN_ROOT_PATH$input_path"
21542     fi
21543   fi
21544 
21545 
21546   if test "x$path" != "x$new_path"; then
21547     BOOT_JDK="$new_path"
21548     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21549 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21550   fi
21551 
21552   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21553 
21554   path="$BOOT_JDK"
21555   has_colon=`$ECHO $path | $GREP ^.:`
21556   new_path="$path"
21557   if test "x$has_colon" = x; then
21558     # Not in mixed or Windows style, start by that.
21559     new_path=`cmd //c echo $path`
21560   fi
21561 
21562 
21563   input_path="$new_path"
21564   # Check if we need to convert this using DOS-style short mode. If the path
21565   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21566   # take no chances and rewrite it.
21567   # Note: m4 eats our [], so we need to use [ and ] instead.
21568   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21569   if test "x$has_forbidden_chars" != x; then
21570     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21571     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21572   fi
21573 
21574 
21575   windows_path="$new_path"
21576   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21577     unix_path=`$CYGPATH -u "$windows_path"`
21578     new_path="$unix_path"
21579   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21580     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21581     new_path="$unix_path"
21582   fi
21583 
21584   if test "x$path" != "x$new_path"; then
21585     BOOT_JDK="$new_path"
21586     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21587 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21588   fi
21589 
21590   # Save the first 10 bytes of this path to the storage, so fixpath can work.
21591   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21592 
21593   else
21594     # We're on a unix platform. Hooray! :)
21595     path="$BOOT_JDK"
21596     has_space=`$ECHO "$path" | $GREP " "`
21597     if test "x$has_space" != x; then
21598       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21599 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21600       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21601     fi
21602 
21603     # Use eval to expand a potential ~
21604     eval path="$path"
21605     if test ! -f "$path" && test ! -d "$path"; then
21606       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21607     fi
21608 
21609     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21610   fi
21611 
21612               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21613 $as_echo_n "checking for Boot JDK... " >&6; }
21614               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21615 $as_echo "$BOOT_JDK" >&6; }
21616               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21617 $as_echo_n "checking Boot JDK version... " >&6; }
21618               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21619               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21620 $as_echo "$BOOT_JDK_VERSION" >&6; }
21621             fi # end check jdk version
21622           fi # end check rt.jar
21623         fi # end check javac
21624       fi # end check java
21625     fi # end check boot jdk found
21626   fi
21627 
21628 
21629   # Test: Is $JAVA_HOME set?
21630 
21631   if test "x$BOOT_JDK_FOUND" = xno; then
21632     # Now execute the test
21633 
21634   if test "x$JAVA_HOME" != x; then
21635     JAVA_HOME_PROCESSED="$JAVA_HOME"
21636 
21637   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21638 
21639   # Input might be given as Windows format, start by converting to
21640   # unix format.
21641   path="$JAVA_HOME_PROCESSED"
21642   new_path=`$CYGPATH -u "$path"`
21643 
21644   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21645   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21646   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21647   # "foo.exe" is OK but "foo" is an error.
21648   #
21649   # This test is therefore slightly more accurate than "test -f" to check for file precense.
21650   # It is also a way to make sure we got the proper file name for the real test later on.
21651   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21652   if test "x$test_shortpath" = x; then
21653     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5
21654 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;}
21655     as_fn_error $? "Cannot locate the the path of JAVA_HOME_PROCESSED" "$LINENO" 5
21656   fi
21657 
21658   # Call helper function which possibly converts this using DOS-style short mode.
21659   # If so, the updated path is stored in $new_path.
21660 
21661   input_path="$new_path"
21662   # Check if we need to convert this using DOS-style short mode. If the path
21663   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21664   # take no chances and rewrite it.
21665   # Note: m4 eats our [], so we need to use [ and ] instead.
21666   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21667   if test "x$has_forbidden_chars" != x; then
21668     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21669     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21670     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21671     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21672       # Going to short mode and back again did indeed matter. Since short mode is
21673       # case insensitive, let's make it lowercase to improve readability.
21674       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21675       # Now convert it back to Unix-stile (cygpath)
21676       input_path=`$CYGPATH -u "$shortmode_path"`
21677       new_path="$input_path"
21678     fi
21679   fi
21680 
21681   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21682   if test "x$test_cygdrive_prefix" = x; then
21683     # As a simple fix, exclude /usr/bin since it's not a real path.
21684     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21685       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21686       # a path prefixed by /cygdrive for fixpath to work.
21687       new_path="$CYGWIN_ROOT_PATH$input_path"
21688     fi
21689   fi
21690 
21691 
21692   if test "x$path" != "x$new_path"; then
21693     JAVA_HOME_PROCESSED="$new_path"
21694     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5
21695 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;}
21696   fi
21697 
21698   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21699 
21700   path="$JAVA_HOME_PROCESSED"
21701   has_colon=`$ECHO $path | $GREP ^.:`
21702   new_path="$path"
21703   if test "x$has_colon" = x; then
21704     # Not in mixed or Windows style, start by that.
21705     new_path=`cmd //c echo $path`
21706   fi
21707 
21708 
21709   input_path="$new_path"
21710   # Check if we need to convert this using DOS-style short mode. If the path
21711   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21712   # take no chances and rewrite it.
21713   # Note: m4 eats our [], so we need to use [ and ] instead.
21714   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21715   if test "x$has_forbidden_chars" != x; then
21716     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21717     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21718   fi
21719 
21720 
21721   windows_path="$new_path"
21722   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21723     unix_path=`$CYGPATH -u "$windows_path"`
21724     new_path="$unix_path"
21725   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21726     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21727     new_path="$unix_path"
21728   fi
21729 
21730   if test "x$path" != "x$new_path"; then
21731     JAVA_HOME_PROCESSED="$new_path"
21732     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5
21733 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;}
21734   fi
21735 
21736   # Save the first 10 bytes of this path to the storage, so fixpath can work.
21737   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21738 
21739   else
21740     # We're on a unix platform. Hooray! :)
21741     path="$JAVA_HOME_PROCESSED"
21742     has_space=`$ECHO "$path" | $GREP " "`
21743     if test "x$has_space" != x; then
21744       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5
21745 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;}
21746       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21747     fi
21748 
21749     # Use eval to expand a potential ~
21750     eval path="$path"
21751     if test ! -f "$path" && test ! -d "$path"; then
21752       as_fn_error $? "The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is not found." "$LINENO" 5
21753     fi
21754 
21755     JAVA_HOME_PROCESSED="`cd "$path"; $THEPWDCMD -L`"
21756   fi
21757 
21758     if test ! -d "$JAVA_HOME_PROCESSED"; then
21759       { $as_echo "$as_me:${as_lineno-$LINENO}: Your JAVA_HOME points to a non-existing directory!" >&5
21760 $as_echo "$as_me: Your JAVA_HOME points to a non-existing directory!" >&6;}
21761     else
21762       # Aha, the user has set a JAVA_HOME
21763       # let us use that as the Boot JDK.
21764       BOOT_JDK="$JAVA_HOME_PROCESSED"
21765       BOOT_JDK_FOUND=maybe
21766       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using JAVA_HOME" >&5
21767 $as_echo "$as_me: Found potential Boot JDK using JAVA_HOME" >&6;}
21768     fi
21769   fi
21770 
21771 
21772     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
21773     if test "x$BOOT_JDK_FOUND" = xmaybe; then
21774       # Do we have a bin/java?
21775       if test ! -x "$BOOT_JDK/bin/java"; then
21776         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
21777 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
21778         BOOT_JDK_FOUND=no
21779       else
21780         # Do we have a bin/javac?
21781         if test ! -x "$BOOT_JDK/bin/javac"; then
21782           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
21783 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
21784           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
21785 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
21786           BOOT_JDK_FOUND=no
21787         else
21788           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
21789           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
21790             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
21791 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
21792             BOOT_JDK_FOUND=no
21793           else
21794             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
21795             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
21796 
21797             # Extra M4 quote needed to protect [] in grep expression.
21798             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
21799             if test "x$FOUND_CORRECT_VERSION" = x; then
21800               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
21801 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
21802               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
21803 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
21804               BOOT_JDK_FOUND=no
21805             else
21806               # We're done! :-)
21807               BOOT_JDK_FOUND=yes
21808 
21809   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21810 
21811   # Input might be given as Windows format, start by converting to
21812   # unix format.
21813   path="$BOOT_JDK"
21814   new_path=`$CYGPATH -u "$path"`
21815 
21816   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
21817   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
21818   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
21819   # "foo.exe" is OK but "foo" is an error.
21820   #
21821   # This test is therefore slightly more accurate than "test -f" to check for file precense.
21822   # It is also a way to make sure we got the proper file name for the real test later on.
21823   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
21824   if test "x$test_shortpath" = x; then
21825     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21826 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21827     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
21828   fi
21829 
21830   # Call helper function which possibly converts this using DOS-style short mode.
21831   # If so, the updated path is stored in $new_path.
21832 
21833   input_path="$new_path"
21834   # Check if we need to convert this using DOS-style short mode. If the path
21835   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21836   # take no chances and rewrite it.
21837   # Note: m4 eats our [], so we need to use [ and ] instead.
21838   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
21839   if test "x$has_forbidden_chars" != x; then
21840     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21841     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
21842     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
21843     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
21844       # Going to short mode and back again did indeed matter. Since short mode is
21845       # case insensitive, let's make it lowercase to improve readability.
21846       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21847       # Now convert it back to Unix-stile (cygpath)
21848       input_path=`$CYGPATH -u "$shortmode_path"`
21849       new_path="$input_path"
21850     fi
21851   fi
21852 
21853   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
21854   if test "x$test_cygdrive_prefix" = x; then
21855     # As a simple fix, exclude /usr/bin since it's not a real path.
21856     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
21857       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
21858       # a path prefixed by /cygdrive for fixpath to work.
21859       new_path="$CYGWIN_ROOT_PATH$input_path"
21860     fi
21861   fi
21862 
21863 
21864   if test "x$path" != "x$new_path"; then
21865     BOOT_JDK="$new_path"
21866     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21867 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21868   fi
21869 
21870   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21871 
21872   path="$BOOT_JDK"
21873   has_colon=`$ECHO $path | $GREP ^.:`
21874   new_path="$path"
21875   if test "x$has_colon" = x; then
21876     # Not in mixed or Windows style, start by that.
21877     new_path=`cmd //c echo $path`
21878   fi
21879 
21880 
21881   input_path="$new_path"
21882   # Check if we need to convert this using DOS-style short mode. If the path
21883   # contains just simple characters, use it. Otherwise (spaces, weird characters),
21884   # take no chances and rewrite it.
21885   # Note: m4 eats our [], so we need to use [ and ] instead.
21886   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
21887   if test "x$has_forbidden_chars" != x; then
21888     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
21889     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
21890   fi
21891 
21892 
21893   windows_path="$new_path"
21894   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
21895     unix_path=`$CYGPATH -u "$windows_path"`
21896     new_path="$unix_path"
21897   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
21898     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
21899     new_path="$unix_path"
21900   fi
21901 
21902   if test "x$path" != "x$new_path"; then
21903     BOOT_JDK="$new_path"
21904     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
21905 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
21906   fi
21907 
21908   # Save the first 10 bytes of this path to the storage, so fixpath can work.
21909   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
21910 
21911   else
21912     # We're on a unix platform. Hooray! :)
21913     path="$BOOT_JDK"
21914     has_space=`$ECHO "$path" | $GREP " "`
21915     if test "x$has_space" != x; then
21916       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
21917 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
21918       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
21919     fi
21920 
21921     # Use eval to expand a potential ~
21922     eval path="$path"
21923     if test ! -f "$path" && test ! -d "$path"; then
21924       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
21925     fi
21926 
21927     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
21928   fi
21929 
21930               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
21931 $as_echo_n "checking for Boot JDK... " >&6; }
21932               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
21933 $as_echo "$BOOT_JDK" >&6; }
21934               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
21935 $as_echo_n "checking Boot JDK version... " >&6; }
21936               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
21937               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
21938 $as_echo "$BOOT_JDK_VERSION" >&6; }
21939             fi # end check jdk version
21940           fi # end check rt.jar
21941         fi # end check javac
21942       fi # end check java
21943     fi # end check boot jdk found
21944   fi
21945 
21946 
21947   # Test: Is there a java or javac in the PATH, which is a symlink to the JDK?
21948 
21949   if test "x$BOOT_JDK_FOUND" = xno; then
21950     # Now execute the test
21951 
21952   # Extract the first word of "javac", so it can be a program name with args.
21953 set dummy javac; ac_word=$2
21954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21955 $as_echo_n "checking for $ac_word... " >&6; }
21956 if ${ac_cv_path_JAVAC_CHECK+:} false; then :
21957   $as_echo_n "(cached) " >&6
21958 else
21959   case $JAVAC_CHECK in
21960   [\\/]* | ?:[\\/]*)
21961   ac_cv_path_JAVAC_CHECK="$JAVAC_CHECK" # Let the user override the test with a path.
21962   ;;
21963   *)
21964   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21965 for as_dir in $PATH
21966 do
21967   IFS=$as_save_IFS
21968   test -z "$as_dir" && as_dir=.
21969     for ac_exec_ext in '' $ac_executable_extensions; do
21970   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21971     ac_cv_path_JAVAC_CHECK="$as_dir/$ac_word$ac_exec_ext"
21972     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
21973     break 2
21974   fi
21975 done
21976   done
21977 IFS=$as_save_IFS
21978 
21979   ;;
21980 esac
21981 fi
21982 JAVAC_CHECK=$ac_cv_path_JAVAC_CHECK
21983 if test -n "$JAVAC_CHECK"; then
21984   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC_CHECK" >&5
21985 $as_echo "$JAVAC_CHECK" >&6; }
21986 else
21987   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21988 $as_echo "no" >&6; }
21989 fi
21990 
21991 
21992   # Extract the first word of "java", so it can be a program name with args.
21993 set dummy java; ac_word=$2
21994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
21995 $as_echo_n "checking for $ac_word... " >&6; }
21996 if ${ac_cv_path_JAVA_CHECK+:} false; then :
21997   $as_echo_n "(cached) " >&6
21998 else
21999   case $JAVA_CHECK in
22000   [\\/]* | ?:[\\/]*)
22001   ac_cv_path_JAVA_CHECK="$JAVA_CHECK" # Let the user override the test with a path.
22002   ;;
22003   *)
22004   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22005 for as_dir in $PATH
22006 do
22007   IFS=$as_save_IFS
22008   test -z "$as_dir" && as_dir=.
22009     for ac_exec_ext in '' $ac_executable_extensions; do
22010   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22011     ac_cv_path_JAVA_CHECK="$as_dir/$ac_word$ac_exec_ext"
22012     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
22013     break 2
22014   fi
22015 done
22016   done
22017 IFS=$as_save_IFS
22018 
22019   ;;
22020 esac
22021 fi
22022 JAVA_CHECK=$ac_cv_path_JAVA_CHECK
22023 if test -n "$JAVA_CHECK"; then
22024   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA_CHECK" >&5
22025 $as_echo "$JAVA_CHECK" >&6; }
22026 else
22027   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22028 $as_echo "no" >&6; }
22029 fi
22030 
22031 
22032   BINARY="$JAVAC_CHECK"
22033   if test "x$JAVAC_CHECK" = x; then
22034     BINARY="$JAVA_CHECK"
22035   fi
22036   if test "x$BINARY" != x; then
22037     # So there is a java(c) binary, it might be part of a JDK.
22038     # Lets find the JDK/JRE directory by following symbolic links.
22039     # Linux/GNU systems often have links from /usr/bin/java to
22040     # /etc/alternatives/java to the real JDK binary.
22041 
22042   if test "x$OPENJDK_BUILD_OS" != xwindows; then
22043     # Follow a chain of symbolic links. Use readlink
22044     # where it exists, else fall back to horribly
22045     # complicated shell code.
22046     if test "x$READLINK_TESTED" != yes; then
22047       # On MacOSX there is a readlink tool with a different
22048       # purpose than the GNU readlink tool. Check the found readlink.
22049       ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
22050       if test "x$ISGNU" = x; then
22051         # A readlink that we do not know how to use.
22052         # Are there other non-GNU readlinks out there?
22053         READLINK_TESTED=yes
22054         READLINK=
22055       fi
22056     fi
22057 
22058     if test "x$READLINK" != x; then
22059       BINARY=`$READLINK -f $BINARY`
22060     else
22061       # Save the current directory for restoring afterwards
22062       STARTDIR=$PWD
22063       COUNTER=0
22064       sym_link_dir=`$DIRNAME $BINARY`
22065       sym_link_file=`$BASENAME $BINARY`
22066       cd $sym_link_dir
22067       # Use -P flag to resolve symlinks in directories.
22068       cd `$THEPWDCMD -P`
22069       sym_link_dir=`$THEPWDCMD -P`
22070       # Resolve file symlinks
22071       while test $COUNTER -lt 20; do
22072         ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
22073         if test "x$ISLINK" == x; then
22074           # This is not a symbolic link! We are done!
22075           break
22076         fi
22077         # Again resolve directory symlinks since the target of the just found
22078         # link could be in a different directory
22079         cd `$DIRNAME $ISLINK`
22080         sym_link_dir=`$THEPWDCMD -P`
22081         sym_link_file=`$BASENAME $ISLINK`
22082         let COUNTER=COUNTER+1
22083       done
22084       cd $STARTDIR
22085       BINARY=$sym_link_dir/$sym_link_file
22086     fi
22087   fi
22088 
22089     BOOT_JDK=`dirname "$BINARY"`
22090     BOOT_JDK=`cd "$BOOT_JDK/.."; pwd`
22091     if test -x "$BOOT_JDK/bin/javac" && test -x "$BOOT_JDK/bin/java"; then
22092       # Looks like we found ourselves an JDK
22093       BOOT_JDK_FOUND=maybe
22094       { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using java(c) in PATH" >&5
22095 $as_echo "$as_me: Found potential Boot JDK using java(c) in PATH" >&6;}
22096     fi
22097   fi
22098 
22099 
22100     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22101     if test "x$BOOT_JDK_FOUND" = xmaybe; then
22102       # Do we have a bin/java?
22103       if test ! -x "$BOOT_JDK/bin/java"; then
22104         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22105 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22106         BOOT_JDK_FOUND=no
22107       else
22108         # Do we have a bin/javac?
22109         if test ! -x "$BOOT_JDK/bin/javac"; then
22110           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22111 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22112           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22113 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22114           BOOT_JDK_FOUND=no
22115         else
22116           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22117           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22118             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22119 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22120             BOOT_JDK_FOUND=no
22121           else
22122             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22123             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22124 
22125             # Extra M4 quote needed to protect [] in grep expression.
22126             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
22127             if test "x$FOUND_CORRECT_VERSION" = x; then
22128               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22129 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22130               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
22131 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
22132               BOOT_JDK_FOUND=no
22133             else
22134               # We're done! :-)
22135               BOOT_JDK_FOUND=yes
22136 
22137   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22138 
22139   # Input might be given as Windows format, start by converting to
22140   # unix format.
22141   path="$BOOT_JDK"
22142   new_path=`$CYGPATH -u "$path"`
22143 
22144   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22145   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22146   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22147   # "foo.exe" is OK but "foo" is an error.
22148   #
22149   # This test is therefore slightly more accurate than "test -f" to check for file precense.
22150   # It is also a way to make sure we got the proper file name for the real test later on.
22151   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22152   if test "x$test_shortpath" = x; then
22153     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22154 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22155     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22156   fi
22157 
22158   # Call helper function which possibly converts this using DOS-style short mode.
22159   # If so, the updated path is stored in $new_path.
22160 
22161   input_path="$new_path"
22162   # Check if we need to convert this using DOS-style short mode. If the path
22163   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22164   # take no chances and rewrite it.
22165   # Note: m4 eats our [], so we need to use [ and ] instead.
22166   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22167   if test "x$has_forbidden_chars" != x; then
22168     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22169     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22170     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22171     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22172       # Going to short mode and back again did indeed matter. Since short mode is
22173       # case insensitive, let's make it lowercase to improve readability.
22174       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22175       # Now convert it back to Unix-stile (cygpath)
22176       input_path=`$CYGPATH -u "$shortmode_path"`
22177       new_path="$input_path"
22178     fi
22179   fi
22180 
22181   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22182   if test "x$test_cygdrive_prefix" = x; then
22183     # As a simple fix, exclude /usr/bin since it's not a real path.
22184     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22185       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22186       # a path prefixed by /cygdrive for fixpath to work.
22187       new_path="$CYGWIN_ROOT_PATH$input_path"
22188     fi
22189   fi
22190 
22191 
22192   if test "x$path" != "x$new_path"; then
22193     BOOT_JDK="$new_path"
22194     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22195 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22196   fi
22197 
22198   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22199 
22200   path="$BOOT_JDK"
22201   has_colon=`$ECHO $path | $GREP ^.:`
22202   new_path="$path"
22203   if test "x$has_colon" = x; then
22204     # Not in mixed or Windows style, start by that.
22205     new_path=`cmd //c echo $path`
22206   fi
22207 
22208 
22209   input_path="$new_path"
22210   # Check if we need to convert this using DOS-style short mode. If the path
22211   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22212   # take no chances and rewrite it.
22213   # Note: m4 eats our [], so we need to use [ and ] instead.
22214   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22215   if test "x$has_forbidden_chars" != x; then
22216     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22217     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22218   fi
22219 
22220 
22221   windows_path="$new_path"
22222   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22223     unix_path=`$CYGPATH -u "$windows_path"`
22224     new_path="$unix_path"
22225   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22226     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22227     new_path="$unix_path"
22228   fi
22229 
22230   if test "x$path" != "x$new_path"; then
22231     BOOT_JDK="$new_path"
22232     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22233 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22234   fi
22235 
22236   # Save the first 10 bytes of this path to the storage, so fixpath can work.
22237   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22238 
22239   else
22240     # We're on a unix platform. Hooray! :)
22241     path="$BOOT_JDK"
22242     has_space=`$ECHO "$path" | $GREP " "`
22243     if test "x$has_space" != x; then
22244       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22245 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22246       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22247     fi
22248 
22249     # Use eval to expand a potential ~
22250     eval path="$path"
22251     if test ! -f "$path" && test ! -d "$path"; then
22252       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22253     fi
22254 
22255     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22256   fi
22257 
22258               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22259 $as_echo_n "checking for Boot JDK... " >&6; }
22260               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22261 $as_echo "$BOOT_JDK" >&6; }
22262               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22263 $as_echo_n "checking Boot JDK version... " >&6; }
22264               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22265               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22266 $as_echo "$BOOT_JDK_VERSION" >&6; }
22267             fi # end check jdk version
22268           fi # end check rt.jar
22269         fi # end check javac
22270       fi # end check java
22271     fi # end check boot jdk found
22272   fi
22273 
22274 
22275   # Test: Is there a JDK installed in default, well-known locations?
22276 
22277   if test "x$BOOT_JDK_FOUND" = xno; then
22278     # Now execute the test
22279 
22280   if test "x$OPENJDK_TARGET_OS" = xwindows; then
22281 
22282   if test "x$BOOT_JDK_FOUND" = xno; then
22283     # Now execute the test
22284 
22285   if test "x$ProgramW6432" != x; then
22286     VIRTUAL_DIR="$ProgramW6432/Java"
22287 
22288   windows_path="$VIRTUAL_DIR"
22289   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22290     unix_path=`$CYGPATH -u "$windows_path"`
22291     VIRTUAL_DIR="$unix_path"
22292   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22293     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22294     VIRTUAL_DIR="$unix_path"
22295   fi
22296 
22297 
22298   BOOT_JDK_PREFIX="$VIRTUAL_DIR"
22299   BOOT_JDK_SUFFIX=""
22300   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
22301   if test "x$ALL_JDKS_FOUND" != x; then
22302     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
22303 
22304   if test "x$BOOT_JDK_FOUND" = xno; then
22305     # Now execute the test
22306 
22307         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
22308         if test -d "$BOOT_JDK"; then
22309           BOOT_JDK_FOUND=maybe
22310           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
22311 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
22312         fi
22313 
22314 
22315     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22316     if test "x$BOOT_JDK_FOUND" = xmaybe; then
22317       # Do we have a bin/java?
22318       if test ! -x "$BOOT_JDK/bin/java"; then
22319         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22320 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22321         BOOT_JDK_FOUND=no
22322       else
22323         # Do we have a bin/javac?
22324         if test ! -x "$BOOT_JDK/bin/javac"; then
22325           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22326 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22327           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22328 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22329           BOOT_JDK_FOUND=no
22330         else
22331           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22332           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22333             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22334 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22335             BOOT_JDK_FOUND=no
22336           else
22337             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22338             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22339 
22340             # Extra M4 quote needed to protect [] in grep expression.
22341             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
22342             if test "x$FOUND_CORRECT_VERSION" = x; then
22343               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22344 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22345               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
22346 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
22347               BOOT_JDK_FOUND=no
22348             else
22349               # We're done! :-)
22350               BOOT_JDK_FOUND=yes
22351 
22352   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22353 
22354   # Input might be given as Windows format, start by converting to
22355   # unix format.
22356   path="$BOOT_JDK"
22357   new_path=`$CYGPATH -u "$path"`
22358 
22359   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22360   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22361   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22362   # "foo.exe" is OK but "foo" is an error.
22363   #
22364   # This test is therefore slightly more accurate than "test -f" to check for file precense.
22365   # It is also a way to make sure we got the proper file name for the real test later on.
22366   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22367   if test "x$test_shortpath" = x; then
22368     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22369 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22370     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22371   fi
22372 
22373   # Call helper function which possibly converts this using DOS-style short mode.
22374   # If so, the updated path is stored in $new_path.
22375 
22376   input_path="$new_path"
22377   # Check if we need to convert this using DOS-style short mode. If the path
22378   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22379   # take no chances and rewrite it.
22380   # Note: m4 eats our [], so we need to use [ and ] instead.
22381   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22382   if test "x$has_forbidden_chars" != x; then
22383     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22384     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22385     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22386     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22387       # Going to short mode and back again did indeed matter. Since short mode is
22388       # case insensitive, let's make it lowercase to improve readability.
22389       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22390       # Now convert it back to Unix-stile (cygpath)
22391       input_path=`$CYGPATH -u "$shortmode_path"`
22392       new_path="$input_path"
22393     fi
22394   fi
22395 
22396   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22397   if test "x$test_cygdrive_prefix" = x; then
22398     # As a simple fix, exclude /usr/bin since it's not a real path.
22399     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22400       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22401       # a path prefixed by /cygdrive for fixpath to work.
22402       new_path="$CYGWIN_ROOT_PATH$input_path"
22403     fi
22404   fi
22405 
22406 
22407   if test "x$path" != "x$new_path"; then
22408     BOOT_JDK="$new_path"
22409     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22410 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22411   fi
22412 
22413   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22414 
22415   path="$BOOT_JDK"
22416   has_colon=`$ECHO $path | $GREP ^.:`
22417   new_path="$path"
22418   if test "x$has_colon" = x; then
22419     # Not in mixed or Windows style, start by that.
22420     new_path=`cmd //c echo $path`
22421   fi
22422 
22423 
22424   input_path="$new_path"
22425   # Check if we need to convert this using DOS-style short mode. If the path
22426   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22427   # take no chances and rewrite it.
22428   # Note: m4 eats our [], so we need to use [ and ] instead.
22429   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22430   if test "x$has_forbidden_chars" != x; then
22431     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22432     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22433   fi
22434 
22435 
22436   windows_path="$new_path"
22437   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22438     unix_path=`$CYGPATH -u "$windows_path"`
22439     new_path="$unix_path"
22440   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22441     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22442     new_path="$unix_path"
22443   fi
22444 
22445   if test "x$path" != "x$new_path"; then
22446     BOOT_JDK="$new_path"
22447     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22448 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22449   fi
22450 
22451   # Save the first 10 bytes of this path to the storage, so fixpath can work.
22452   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22453 
22454   else
22455     # We're on a unix platform. Hooray! :)
22456     path="$BOOT_JDK"
22457     has_space=`$ECHO "$path" | $GREP " "`
22458     if test "x$has_space" != x; then
22459       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22460 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22461       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22462     fi
22463 
22464     # Use eval to expand a potential ~
22465     eval path="$path"
22466     if test ! -f "$path" && test ! -d "$path"; then
22467       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22468     fi
22469 
22470     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22471   fi
22472 
22473               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22474 $as_echo_n "checking for Boot JDK... " >&6; }
22475               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22476 $as_echo "$BOOT_JDK" >&6; }
22477               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22478 $as_echo_n "checking Boot JDK version... " >&6; }
22479               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22480               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22481 $as_echo "$BOOT_JDK_VERSION" >&6; }
22482             fi # end check jdk version
22483           fi # end check rt.jar
22484         fi # end check javac
22485       fi # end check java
22486     fi # end check boot jdk found
22487   fi
22488 
22489     done
22490   fi
22491 
22492   fi
22493 
22494 
22495     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22496     if test "x$BOOT_JDK_FOUND" = xmaybe; then
22497       # Do we have a bin/java?
22498       if test ! -x "$BOOT_JDK/bin/java"; then
22499         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22500 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22501         BOOT_JDK_FOUND=no
22502       else
22503         # Do we have a bin/javac?
22504         if test ! -x "$BOOT_JDK/bin/javac"; then
22505           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22506 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22507           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22508 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22509           BOOT_JDK_FOUND=no
22510         else
22511           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22512           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22513             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22514 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22515             BOOT_JDK_FOUND=no
22516           else
22517             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22518             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22519 
22520             # Extra M4 quote needed to protect [] in grep expression.
22521             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
22522             if test "x$FOUND_CORRECT_VERSION" = x; then
22523               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22524 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22525               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
22526 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
22527               BOOT_JDK_FOUND=no
22528             else
22529               # We're done! :-)
22530               BOOT_JDK_FOUND=yes
22531 
22532   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22533 
22534   # Input might be given as Windows format, start by converting to
22535   # unix format.
22536   path="$BOOT_JDK"
22537   new_path=`$CYGPATH -u "$path"`
22538 
22539   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22540   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22541   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22542   # "foo.exe" is OK but "foo" is an error.
22543   #
22544   # This test is therefore slightly more accurate than "test -f" to check for file precense.
22545   # It is also a way to make sure we got the proper file name for the real test later on.
22546   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22547   if test "x$test_shortpath" = x; then
22548     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22549 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22550     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22551   fi
22552 
22553   # Call helper function which possibly converts this using DOS-style short mode.
22554   # If so, the updated path is stored in $new_path.
22555 
22556   input_path="$new_path"
22557   # Check if we need to convert this using DOS-style short mode. If the path
22558   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22559   # take no chances and rewrite it.
22560   # Note: m4 eats our [], so we need to use [ and ] instead.
22561   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22562   if test "x$has_forbidden_chars" != x; then
22563     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22564     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22565     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22566     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22567       # Going to short mode and back again did indeed matter. Since short mode is
22568       # case insensitive, let's make it lowercase to improve readability.
22569       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22570       # Now convert it back to Unix-stile (cygpath)
22571       input_path=`$CYGPATH -u "$shortmode_path"`
22572       new_path="$input_path"
22573     fi
22574   fi
22575 
22576   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22577   if test "x$test_cygdrive_prefix" = x; then
22578     # As a simple fix, exclude /usr/bin since it's not a real path.
22579     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22580       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22581       # a path prefixed by /cygdrive for fixpath to work.
22582       new_path="$CYGWIN_ROOT_PATH$input_path"
22583     fi
22584   fi
22585 
22586 
22587   if test "x$path" != "x$new_path"; then
22588     BOOT_JDK="$new_path"
22589     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22590 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22591   fi
22592 
22593   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22594 
22595   path="$BOOT_JDK"
22596   has_colon=`$ECHO $path | $GREP ^.:`
22597   new_path="$path"
22598   if test "x$has_colon" = x; then
22599     # Not in mixed or Windows style, start by that.
22600     new_path=`cmd //c echo $path`
22601   fi
22602 
22603 
22604   input_path="$new_path"
22605   # Check if we need to convert this using DOS-style short mode. If the path
22606   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22607   # take no chances and rewrite it.
22608   # Note: m4 eats our [], so we need to use [ and ] instead.
22609   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22610   if test "x$has_forbidden_chars" != x; then
22611     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22612     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22613   fi
22614 
22615 
22616   windows_path="$new_path"
22617   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22618     unix_path=`$CYGPATH -u "$windows_path"`
22619     new_path="$unix_path"
22620   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22621     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22622     new_path="$unix_path"
22623   fi
22624 
22625   if test "x$path" != "x$new_path"; then
22626     BOOT_JDK="$new_path"
22627     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22628 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22629   fi
22630 
22631   # Save the first 10 bytes of this path to the storage, so fixpath can work.
22632   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22633 
22634   else
22635     # We're on a unix platform. Hooray! :)
22636     path="$BOOT_JDK"
22637     has_space=`$ECHO "$path" | $GREP " "`
22638     if test "x$has_space" != x; then
22639       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22640 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22641       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22642     fi
22643 
22644     # Use eval to expand a potential ~
22645     eval path="$path"
22646     if test ! -f "$path" && test ! -d "$path"; then
22647       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22648     fi
22649 
22650     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22651   fi
22652 
22653               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22654 $as_echo_n "checking for Boot JDK... " >&6; }
22655               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22656 $as_echo "$BOOT_JDK" >&6; }
22657               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22658 $as_echo_n "checking Boot JDK version... " >&6; }
22659               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22660               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22661 $as_echo "$BOOT_JDK_VERSION" >&6; }
22662             fi # end check jdk version
22663           fi # end check rt.jar
22664         fi # end check javac
22665       fi # end check java
22666     fi # end check boot jdk found
22667   fi
22668 
22669 
22670   if test "x$BOOT_JDK_FOUND" = xno; then
22671     # Now execute the test
22672 
22673   if test "x$PROGRAMW6432" != x; then
22674     VIRTUAL_DIR="$PROGRAMW6432/Java"
22675 
22676   windows_path="$VIRTUAL_DIR"
22677   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22678     unix_path=`$CYGPATH -u "$windows_path"`
22679     VIRTUAL_DIR="$unix_path"
22680   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22681     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22682     VIRTUAL_DIR="$unix_path"
22683   fi
22684 
22685 
22686   BOOT_JDK_PREFIX="$VIRTUAL_DIR"
22687   BOOT_JDK_SUFFIX=""
22688   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
22689   if test "x$ALL_JDKS_FOUND" != x; then
22690     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
22691 
22692   if test "x$BOOT_JDK_FOUND" = xno; then
22693     # Now execute the test
22694 
22695         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
22696         if test -d "$BOOT_JDK"; then
22697           BOOT_JDK_FOUND=maybe
22698           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
22699 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
22700         fi
22701 
22702 
22703     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22704     if test "x$BOOT_JDK_FOUND" = xmaybe; then
22705       # Do we have a bin/java?
22706       if test ! -x "$BOOT_JDK/bin/java"; then
22707         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22708 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22709         BOOT_JDK_FOUND=no
22710       else
22711         # Do we have a bin/javac?
22712         if test ! -x "$BOOT_JDK/bin/javac"; then
22713           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22714 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22715           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22716 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22717           BOOT_JDK_FOUND=no
22718         else
22719           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22720           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22721             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22722 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22723             BOOT_JDK_FOUND=no
22724           else
22725             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22726             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22727 
22728             # Extra M4 quote needed to protect [] in grep expression.
22729             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
22730             if test "x$FOUND_CORRECT_VERSION" = x; then
22731               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22732 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22733               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
22734 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
22735               BOOT_JDK_FOUND=no
22736             else
22737               # We're done! :-)
22738               BOOT_JDK_FOUND=yes
22739 
22740   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22741 
22742   # Input might be given as Windows format, start by converting to
22743   # unix format.
22744   path="$BOOT_JDK"
22745   new_path=`$CYGPATH -u "$path"`
22746 
22747   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22748   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22749   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22750   # "foo.exe" is OK but "foo" is an error.
22751   #
22752   # This test is therefore slightly more accurate than "test -f" to check for file precense.
22753   # It is also a way to make sure we got the proper file name for the real test later on.
22754   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22755   if test "x$test_shortpath" = x; then
22756     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22757 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22758     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22759   fi
22760 
22761   # Call helper function which possibly converts this using DOS-style short mode.
22762   # If so, the updated path is stored in $new_path.
22763 
22764   input_path="$new_path"
22765   # Check if we need to convert this using DOS-style short mode. If the path
22766   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22767   # take no chances and rewrite it.
22768   # Note: m4 eats our [], so we need to use [ and ] instead.
22769   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22770   if test "x$has_forbidden_chars" != x; then
22771     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22772     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22773     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22774     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22775       # Going to short mode and back again did indeed matter. Since short mode is
22776       # case insensitive, let's make it lowercase to improve readability.
22777       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22778       # Now convert it back to Unix-stile (cygpath)
22779       input_path=`$CYGPATH -u "$shortmode_path"`
22780       new_path="$input_path"
22781     fi
22782   fi
22783 
22784   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22785   if test "x$test_cygdrive_prefix" = x; then
22786     # As a simple fix, exclude /usr/bin since it's not a real path.
22787     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22788       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22789       # a path prefixed by /cygdrive for fixpath to work.
22790       new_path="$CYGWIN_ROOT_PATH$input_path"
22791     fi
22792   fi
22793 
22794 
22795   if test "x$path" != "x$new_path"; then
22796     BOOT_JDK="$new_path"
22797     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22798 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22799   fi
22800 
22801   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22802 
22803   path="$BOOT_JDK"
22804   has_colon=`$ECHO $path | $GREP ^.:`
22805   new_path="$path"
22806   if test "x$has_colon" = x; then
22807     # Not in mixed or Windows style, start by that.
22808     new_path=`cmd //c echo $path`
22809   fi
22810 
22811 
22812   input_path="$new_path"
22813   # Check if we need to convert this using DOS-style short mode. If the path
22814   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22815   # take no chances and rewrite it.
22816   # Note: m4 eats our [], so we need to use [ and ] instead.
22817   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22818   if test "x$has_forbidden_chars" != x; then
22819     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22820     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22821   fi
22822 
22823 
22824   windows_path="$new_path"
22825   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22826     unix_path=`$CYGPATH -u "$windows_path"`
22827     new_path="$unix_path"
22828   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22829     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
22830     new_path="$unix_path"
22831   fi
22832 
22833   if test "x$path" != "x$new_path"; then
22834     BOOT_JDK="$new_path"
22835     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22836 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22837   fi
22838 
22839   # Save the first 10 bytes of this path to the storage, so fixpath can work.
22840   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
22841 
22842   else
22843     # We're on a unix platform. Hooray! :)
22844     path="$BOOT_JDK"
22845     has_space=`$ECHO "$path" | $GREP " "`
22846     if test "x$has_space" != x; then
22847       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22848 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22849       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
22850     fi
22851 
22852     # Use eval to expand a potential ~
22853     eval path="$path"
22854     if test ! -f "$path" && test ! -d "$path"; then
22855       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
22856     fi
22857 
22858     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
22859   fi
22860 
22861               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
22862 $as_echo_n "checking for Boot JDK... " >&6; }
22863               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
22864 $as_echo "$BOOT_JDK" >&6; }
22865               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
22866 $as_echo_n "checking Boot JDK version... " >&6; }
22867               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
22868               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
22869 $as_echo "$BOOT_JDK_VERSION" >&6; }
22870             fi # end check jdk version
22871           fi # end check rt.jar
22872         fi # end check javac
22873       fi # end check java
22874     fi # end check boot jdk found
22875   fi
22876 
22877     done
22878   fi
22879 
22880   fi
22881 
22882 
22883     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
22884     if test "x$BOOT_JDK_FOUND" = xmaybe; then
22885       # Do we have a bin/java?
22886       if test ! -x "$BOOT_JDK/bin/java"; then
22887         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
22888 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
22889         BOOT_JDK_FOUND=no
22890       else
22891         # Do we have a bin/javac?
22892         if test ! -x "$BOOT_JDK/bin/javac"; then
22893           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
22894 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
22895           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
22896 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
22897           BOOT_JDK_FOUND=no
22898         else
22899           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
22900           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
22901             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
22902 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
22903             BOOT_JDK_FOUND=no
22904           else
22905             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
22906             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
22907 
22908             # Extra M4 quote needed to protect [] in grep expression.
22909             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
22910             if test "x$FOUND_CORRECT_VERSION" = x; then
22911               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
22912 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
22913               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
22914 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
22915               BOOT_JDK_FOUND=no
22916             else
22917               # We're done! :-)
22918               BOOT_JDK_FOUND=yes
22919 
22920   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
22921 
22922   # Input might be given as Windows format, start by converting to
22923   # unix format.
22924   path="$BOOT_JDK"
22925   new_path=`$CYGPATH -u "$path"`
22926 
22927   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
22928   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
22929   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
22930   # "foo.exe" is OK but "foo" is an error.
22931   #
22932   # This test is therefore slightly more accurate than "test -f" to check for file precense.
22933   # It is also a way to make sure we got the proper file name for the real test later on.
22934   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
22935   if test "x$test_shortpath" = x; then
22936     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
22937 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
22938     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
22939   fi
22940 
22941   # Call helper function which possibly converts this using DOS-style short mode.
22942   # If so, the updated path is stored in $new_path.
22943 
22944   input_path="$new_path"
22945   # Check if we need to convert this using DOS-style short mode. If the path
22946   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22947   # take no chances and rewrite it.
22948   # Note: m4 eats our [], so we need to use [ and ] instead.
22949   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
22950   if test "x$has_forbidden_chars" != x; then
22951     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
22952     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
22953     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
22954     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
22955       # Going to short mode and back again did indeed matter. Since short mode is
22956       # case insensitive, let's make it lowercase to improve readability.
22957       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
22958       # Now convert it back to Unix-stile (cygpath)
22959       input_path=`$CYGPATH -u "$shortmode_path"`
22960       new_path="$input_path"
22961     fi
22962   fi
22963 
22964   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
22965   if test "x$test_cygdrive_prefix" = x; then
22966     # As a simple fix, exclude /usr/bin since it's not a real path.
22967     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
22968       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
22969       # a path prefixed by /cygdrive for fixpath to work.
22970       new_path="$CYGWIN_ROOT_PATH$input_path"
22971     fi
22972   fi
22973 
22974 
22975   if test "x$path" != "x$new_path"; then
22976     BOOT_JDK="$new_path"
22977     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
22978 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
22979   fi
22980 
22981   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
22982 
22983   path="$BOOT_JDK"
22984   has_colon=`$ECHO $path | $GREP ^.:`
22985   new_path="$path"
22986   if test "x$has_colon" = x; then
22987     # Not in mixed or Windows style, start by that.
22988     new_path=`cmd //c echo $path`
22989   fi
22990 
22991 
22992   input_path="$new_path"
22993   # Check if we need to convert this using DOS-style short mode. If the path
22994   # contains just simple characters, use it. Otherwise (spaces, weird characters),
22995   # take no chances and rewrite it.
22996   # Note: m4 eats our [], so we need to use [ and ] instead.
22997   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
22998   if test "x$has_forbidden_chars" != x; then
22999     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23000     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23001   fi
23002 
23003 
23004   windows_path="$new_path"
23005   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23006     unix_path=`$CYGPATH -u "$windows_path"`
23007     new_path="$unix_path"
23008   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23009     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23010     new_path="$unix_path"
23011   fi
23012 
23013   if test "x$path" != "x$new_path"; then
23014     BOOT_JDK="$new_path"
23015     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23016 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23017   fi
23018 
23019   # Save the first 10 bytes of this path to the storage, so fixpath can work.
23020   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23021 
23022   else
23023     # We're on a unix platform. Hooray! :)
23024     path="$BOOT_JDK"
23025     has_space=`$ECHO "$path" | $GREP " "`
23026     if test "x$has_space" != x; then
23027       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23028 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23029       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23030     fi
23031 
23032     # Use eval to expand a potential ~
23033     eval path="$path"
23034     if test ! -f "$path" && test ! -d "$path"; then
23035       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23036     fi
23037 
23038     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23039   fi
23040 
23041               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23042 $as_echo_n "checking for Boot JDK... " >&6; }
23043               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23044 $as_echo "$BOOT_JDK" >&6; }
23045               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23046 $as_echo_n "checking Boot JDK version... " >&6; }
23047               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23048               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23049 $as_echo "$BOOT_JDK_VERSION" >&6; }
23050             fi # end check jdk version
23051           fi # end check rt.jar
23052         fi # end check javac
23053       fi # end check java
23054     fi # end check boot jdk found
23055   fi
23056 
23057 
23058   if test "x$BOOT_JDK_FOUND" = xno; then
23059     # Now execute the test
23060 
23061   if test "x$PROGRAMFILES" != x; then
23062     VIRTUAL_DIR="$PROGRAMFILES/Java"
23063 
23064   windows_path="$VIRTUAL_DIR"
23065   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23066     unix_path=`$CYGPATH -u "$windows_path"`
23067     VIRTUAL_DIR="$unix_path"
23068   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23069     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23070     VIRTUAL_DIR="$unix_path"
23071   fi
23072 
23073 
23074   BOOT_JDK_PREFIX="$VIRTUAL_DIR"
23075   BOOT_JDK_SUFFIX=""
23076   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
23077   if test "x$ALL_JDKS_FOUND" != x; then
23078     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
23079 
23080   if test "x$BOOT_JDK_FOUND" = xno; then
23081     # Now execute the test
23082 
23083         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
23084         if test -d "$BOOT_JDK"; then
23085           BOOT_JDK_FOUND=maybe
23086           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
23087 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
23088         fi
23089 
23090 
23091     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23092     if test "x$BOOT_JDK_FOUND" = xmaybe; then
23093       # Do we have a bin/java?
23094       if test ! -x "$BOOT_JDK/bin/java"; then
23095         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23096 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23097         BOOT_JDK_FOUND=no
23098       else
23099         # Do we have a bin/javac?
23100         if test ! -x "$BOOT_JDK/bin/javac"; then
23101           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23102 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23103           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23104 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23105           BOOT_JDK_FOUND=no
23106         else
23107           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23108           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23109             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23110 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23111             BOOT_JDK_FOUND=no
23112           else
23113             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23114             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23115 
23116             # Extra M4 quote needed to protect [] in grep expression.
23117             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
23118             if test "x$FOUND_CORRECT_VERSION" = x; then
23119               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23120 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23121               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
23122 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
23123               BOOT_JDK_FOUND=no
23124             else
23125               # We're done! :-)
23126               BOOT_JDK_FOUND=yes
23127 
23128   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23129 
23130   # Input might be given as Windows format, start by converting to
23131   # unix format.
23132   path="$BOOT_JDK"
23133   new_path=`$CYGPATH -u "$path"`
23134 
23135   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23136   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23137   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23138   # "foo.exe" is OK but "foo" is an error.
23139   #
23140   # This test is therefore slightly more accurate than "test -f" to check for file precense.
23141   # It is also a way to make sure we got the proper file name for the real test later on.
23142   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23143   if test "x$test_shortpath" = x; then
23144     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23145 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23146     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23147   fi
23148 
23149   # Call helper function which possibly converts this using DOS-style short mode.
23150   # If so, the updated path is stored in $new_path.
23151 
23152   input_path="$new_path"
23153   # Check if we need to convert this using DOS-style short mode. If the path
23154   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23155   # take no chances and rewrite it.
23156   # Note: m4 eats our [], so we need to use [ and ] instead.
23157   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23158   if test "x$has_forbidden_chars" != x; then
23159     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23160     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23161     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23162     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23163       # Going to short mode and back again did indeed matter. Since short mode is
23164       # case insensitive, let's make it lowercase to improve readability.
23165       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23166       # Now convert it back to Unix-stile (cygpath)
23167       input_path=`$CYGPATH -u "$shortmode_path"`
23168       new_path="$input_path"
23169     fi
23170   fi
23171 
23172   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23173   if test "x$test_cygdrive_prefix" = x; then
23174     # As a simple fix, exclude /usr/bin since it's not a real path.
23175     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23176       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23177       # a path prefixed by /cygdrive for fixpath to work.
23178       new_path="$CYGWIN_ROOT_PATH$input_path"
23179     fi
23180   fi
23181 
23182 
23183   if test "x$path" != "x$new_path"; then
23184     BOOT_JDK="$new_path"
23185     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23186 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23187   fi
23188 
23189   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23190 
23191   path="$BOOT_JDK"
23192   has_colon=`$ECHO $path | $GREP ^.:`
23193   new_path="$path"
23194   if test "x$has_colon" = x; then
23195     # Not in mixed or Windows style, start by that.
23196     new_path=`cmd //c echo $path`
23197   fi
23198 
23199 
23200   input_path="$new_path"
23201   # Check if we need to convert this using DOS-style short mode. If the path
23202   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23203   # take no chances and rewrite it.
23204   # Note: m4 eats our [], so we need to use [ and ] instead.
23205   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23206   if test "x$has_forbidden_chars" != x; then
23207     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23208     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23209   fi
23210 
23211 
23212   windows_path="$new_path"
23213   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23214     unix_path=`$CYGPATH -u "$windows_path"`
23215     new_path="$unix_path"
23216   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23217     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23218     new_path="$unix_path"
23219   fi
23220 
23221   if test "x$path" != "x$new_path"; then
23222     BOOT_JDK="$new_path"
23223     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23224 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23225   fi
23226 
23227   # Save the first 10 bytes of this path to the storage, so fixpath can work.
23228   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23229 
23230   else
23231     # We're on a unix platform. Hooray! :)
23232     path="$BOOT_JDK"
23233     has_space=`$ECHO "$path" | $GREP " "`
23234     if test "x$has_space" != x; then
23235       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23236 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23237       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23238     fi
23239 
23240     # Use eval to expand a potential ~
23241     eval path="$path"
23242     if test ! -f "$path" && test ! -d "$path"; then
23243       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23244     fi
23245 
23246     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23247   fi
23248 
23249               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23250 $as_echo_n "checking for Boot JDK... " >&6; }
23251               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23252 $as_echo "$BOOT_JDK" >&6; }
23253               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23254 $as_echo_n "checking Boot JDK version... " >&6; }
23255               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23256               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23257 $as_echo "$BOOT_JDK_VERSION" >&6; }
23258             fi # end check jdk version
23259           fi # end check rt.jar
23260         fi # end check javac
23261       fi # end check java
23262     fi # end check boot jdk found
23263   fi
23264 
23265     done
23266   fi
23267 
23268   fi
23269 
23270 
23271     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23272     if test "x$BOOT_JDK_FOUND" = xmaybe; then
23273       # Do we have a bin/java?
23274       if test ! -x "$BOOT_JDK/bin/java"; then
23275         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23276 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23277         BOOT_JDK_FOUND=no
23278       else
23279         # Do we have a bin/javac?
23280         if test ! -x "$BOOT_JDK/bin/javac"; then
23281           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23282 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23283           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23284 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23285           BOOT_JDK_FOUND=no
23286         else
23287           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23288           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23289             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23290 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23291             BOOT_JDK_FOUND=no
23292           else
23293             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23294             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23295 
23296             # Extra M4 quote needed to protect [] in grep expression.
23297             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
23298             if test "x$FOUND_CORRECT_VERSION" = x; then
23299               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23300 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23301               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
23302 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
23303               BOOT_JDK_FOUND=no
23304             else
23305               # We're done! :-)
23306               BOOT_JDK_FOUND=yes
23307 
23308   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23309 
23310   # Input might be given as Windows format, start by converting to
23311   # unix format.
23312   path="$BOOT_JDK"
23313   new_path=`$CYGPATH -u "$path"`
23314 
23315   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23316   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23317   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23318   # "foo.exe" is OK but "foo" is an error.
23319   #
23320   # This test is therefore slightly more accurate than "test -f" to check for file precense.
23321   # It is also a way to make sure we got the proper file name for the real test later on.
23322   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23323   if test "x$test_shortpath" = x; then
23324     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23325 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23326     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23327   fi
23328 
23329   # Call helper function which possibly converts this using DOS-style short mode.
23330   # If so, the updated path is stored in $new_path.
23331 
23332   input_path="$new_path"
23333   # Check if we need to convert this using DOS-style short mode. If the path
23334   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23335   # take no chances and rewrite it.
23336   # Note: m4 eats our [], so we need to use [ and ] instead.
23337   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23338   if test "x$has_forbidden_chars" != x; then
23339     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23340     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23341     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23342     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23343       # Going to short mode and back again did indeed matter. Since short mode is
23344       # case insensitive, let's make it lowercase to improve readability.
23345       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23346       # Now convert it back to Unix-stile (cygpath)
23347       input_path=`$CYGPATH -u "$shortmode_path"`
23348       new_path="$input_path"
23349     fi
23350   fi
23351 
23352   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23353   if test "x$test_cygdrive_prefix" = x; then
23354     # As a simple fix, exclude /usr/bin since it's not a real path.
23355     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23356       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23357       # a path prefixed by /cygdrive for fixpath to work.
23358       new_path="$CYGWIN_ROOT_PATH$input_path"
23359     fi
23360   fi
23361 
23362 
23363   if test "x$path" != "x$new_path"; then
23364     BOOT_JDK="$new_path"
23365     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23366 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23367   fi
23368 
23369   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23370 
23371   path="$BOOT_JDK"
23372   has_colon=`$ECHO $path | $GREP ^.:`
23373   new_path="$path"
23374   if test "x$has_colon" = x; then
23375     # Not in mixed or Windows style, start by that.
23376     new_path=`cmd //c echo $path`
23377   fi
23378 
23379 
23380   input_path="$new_path"
23381   # Check if we need to convert this using DOS-style short mode. If the path
23382   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23383   # take no chances and rewrite it.
23384   # Note: m4 eats our [], so we need to use [ and ] instead.
23385   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23386   if test "x$has_forbidden_chars" != x; then
23387     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23388     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23389   fi
23390 
23391 
23392   windows_path="$new_path"
23393   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23394     unix_path=`$CYGPATH -u "$windows_path"`
23395     new_path="$unix_path"
23396   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23397     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23398     new_path="$unix_path"
23399   fi
23400 
23401   if test "x$path" != "x$new_path"; then
23402     BOOT_JDK="$new_path"
23403     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23404 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23405   fi
23406 
23407   # Save the first 10 bytes of this path to the storage, so fixpath can work.
23408   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23409 
23410   else
23411     # We're on a unix platform. Hooray! :)
23412     path="$BOOT_JDK"
23413     has_space=`$ECHO "$path" | $GREP " "`
23414     if test "x$has_space" != x; then
23415       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23416 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23417       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23418     fi
23419 
23420     # Use eval to expand a potential ~
23421     eval path="$path"
23422     if test ! -f "$path" && test ! -d "$path"; then
23423       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23424     fi
23425 
23426     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23427   fi
23428 
23429               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23430 $as_echo_n "checking for Boot JDK... " >&6; }
23431               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23432 $as_echo "$BOOT_JDK" >&6; }
23433               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23434 $as_echo_n "checking Boot JDK version... " >&6; }
23435               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23436               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23437 $as_echo "$BOOT_JDK_VERSION" >&6; }
23438             fi # end check jdk version
23439           fi # end check rt.jar
23440         fi # end check javac
23441       fi # end check java
23442     fi # end check boot jdk found
23443   fi
23444 
23445 
23446   if test "x$BOOT_JDK_FOUND" = xno; then
23447     # Now execute the test
23448 
23449   if test "x$ProgramFiles" != x; then
23450     VIRTUAL_DIR="$ProgramFiles/Java"
23451 
23452   windows_path="$VIRTUAL_DIR"
23453   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23454     unix_path=`$CYGPATH -u "$windows_path"`
23455     VIRTUAL_DIR="$unix_path"
23456   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23457     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23458     VIRTUAL_DIR="$unix_path"
23459   fi
23460 
23461 
23462   BOOT_JDK_PREFIX="$VIRTUAL_DIR"
23463   BOOT_JDK_SUFFIX=""
23464   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
23465   if test "x$ALL_JDKS_FOUND" != x; then
23466     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
23467 
23468   if test "x$BOOT_JDK_FOUND" = xno; then
23469     # Now execute the test
23470 
23471         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
23472         if test -d "$BOOT_JDK"; then
23473           BOOT_JDK_FOUND=maybe
23474           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
23475 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
23476         fi
23477 
23478 
23479     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23480     if test "x$BOOT_JDK_FOUND" = xmaybe; then
23481       # Do we have a bin/java?
23482       if test ! -x "$BOOT_JDK/bin/java"; then
23483         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23484 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23485         BOOT_JDK_FOUND=no
23486       else
23487         # Do we have a bin/javac?
23488         if test ! -x "$BOOT_JDK/bin/javac"; then
23489           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23490 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23491           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23492 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23493           BOOT_JDK_FOUND=no
23494         else
23495           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23496           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23497             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23498 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23499             BOOT_JDK_FOUND=no
23500           else
23501             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23502             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23503 
23504             # Extra M4 quote needed to protect [] in grep expression.
23505             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
23506             if test "x$FOUND_CORRECT_VERSION" = x; then
23507               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23508 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23509               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
23510 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
23511               BOOT_JDK_FOUND=no
23512             else
23513               # We're done! :-)
23514               BOOT_JDK_FOUND=yes
23515 
23516   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23517 
23518   # Input might be given as Windows format, start by converting to
23519   # unix format.
23520   path="$BOOT_JDK"
23521   new_path=`$CYGPATH -u "$path"`
23522 
23523   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23524   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23525   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23526   # "foo.exe" is OK but "foo" is an error.
23527   #
23528   # This test is therefore slightly more accurate than "test -f" to check for file precense.
23529   # It is also a way to make sure we got the proper file name for the real test later on.
23530   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23531   if test "x$test_shortpath" = x; then
23532     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23533 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23534     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23535   fi
23536 
23537   # Call helper function which possibly converts this using DOS-style short mode.
23538   # If so, the updated path is stored in $new_path.
23539 
23540   input_path="$new_path"
23541   # Check if we need to convert this using DOS-style short mode. If the path
23542   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23543   # take no chances and rewrite it.
23544   # Note: m4 eats our [], so we need to use [ and ] instead.
23545   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23546   if test "x$has_forbidden_chars" != x; then
23547     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23548     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23549     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23550     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23551       # Going to short mode and back again did indeed matter. Since short mode is
23552       # case insensitive, let's make it lowercase to improve readability.
23553       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23554       # Now convert it back to Unix-stile (cygpath)
23555       input_path=`$CYGPATH -u "$shortmode_path"`
23556       new_path="$input_path"
23557     fi
23558   fi
23559 
23560   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23561   if test "x$test_cygdrive_prefix" = x; then
23562     # As a simple fix, exclude /usr/bin since it's not a real path.
23563     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23564       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23565       # a path prefixed by /cygdrive for fixpath to work.
23566       new_path="$CYGWIN_ROOT_PATH$input_path"
23567     fi
23568   fi
23569 
23570 
23571   if test "x$path" != "x$new_path"; then
23572     BOOT_JDK="$new_path"
23573     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23574 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23575   fi
23576 
23577   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23578 
23579   path="$BOOT_JDK"
23580   has_colon=`$ECHO $path | $GREP ^.:`
23581   new_path="$path"
23582   if test "x$has_colon" = x; then
23583     # Not in mixed or Windows style, start by that.
23584     new_path=`cmd //c echo $path`
23585   fi
23586 
23587 
23588   input_path="$new_path"
23589   # Check if we need to convert this using DOS-style short mode. If the path
23590   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23591   # take no chances and rewrite it.
23592   # Note: m4 eats our [], so we need to use [ and ] instead.
23593   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23594   if test "x$has_forbidden_chars" != x; then
23595     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23596     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23597   fi
23598 
23599 
23600   windows_path="$new_path"
23601   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23602     unix_path=`$CYGPATH -u "$windows_path"`
23603     new_path="$unix_path"
23604   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23605     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23606     new_path="$unix_path"
23607   fi
23608 
23609   if test "x$path" != "x$new_path"; then
23610     BOOT_JDK="$new_path"
23611     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23612 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23613   fi
23614 
23615   # Save the first 10 bytes of this path to the storage, so fixpath can work.
23616   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23617 
23618   else
23619     # We're on a unix platform. Hooray! :)
23620     path="$BOOT_JDK"
23621     has_space=`$ECHO "$path" | $GREP " "`
23622     if test "x$has_space" != x; then
23623       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23624 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23625       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23626     fi
23627 
23628     # Use eval to expand a potential ~
23629     eval path="$path"
23630     if test ! -f "$path" && test ! -d "$path"; then
23631       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23632     fi
23633 
23634     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23635   fi
23636 
23637               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23638 $as_echo_n "checking for Boot JDK... " >&6; }
23639               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23640 $as_echo "$BOOT_JDK" >&6; }
23641               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23642 $as_echo_n "checking Boot JDK version... " >&6; }
23643               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23644               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23645 $as_echo "$BOOT_JDK_VERSION" >&6; }
23646             fi # end check jdk version
23647           fi # end check rt.jar
23648         fi # end check javac
23649       fi # end check java
23650     fi # end check boot jdk found
23651   fi
23652 
23653     done
23654   fi
23655 
23656   fi
23657 
23658 
23659     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23660     if test "x$BOOT_JDK_FOUND" = xmaybe; then
23661       # Do we have a bin/java?
23662       if test ! -x "$BOOT_JDK/bin/java"; then
23663         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23664 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23665         BOOT_JDK_FOUND=no
23666       else
23667         # Do we have a bin/javac?
23668         if test ! -x "$BOOT_JDK/bin/javac"; then
23669           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23670 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23671           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23672 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23673           BOOT_JDK_FOUND=no
23674         else
23675           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23676           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23677             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23678 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23679             BOOT_JDK_FOUND=no
23680           else
23681             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23682             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23683 
23684             # Extra M4 quote needed to protect [] in grep expression.
23685             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
23686             if test "x$FOUND_CORRECT_VERSION" = x; then
23687               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23688 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23689               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
23690 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
23691               BOOT_JDK_FOUND=no
23692             else
23693               # We're done! :-)
23694               BOOT_JDK_FOUND=yes
23695 
23696   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23697 
23698   # Input might be given as Windows format, start by converting to
23699   # unix format.
23700   path="$BOOT_JDK"
23701   new_path=`$CYGPATH -u "$path"`
23702 
23703   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23704   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23705   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23706   # "foo.exe" is OK but "foo" is an error.
23707   #
23708   # This test is therefore slightly more accurate than "test -f" to check for file precense.
23709   # It is also a way to make sure we got the proper file name for the real test later on.
23710   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23711   if test "x$test_shortpath" = x; then
23712     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23713 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23714     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23715   fi
23716 
23717   # Call helper function which possibly converts this using DOS-style short mode.
23718   # If so, the updated path is stored in $new_path.
23719 
23720   input_path="$new_path"
23721   # Check if we need to convert this using DOS-style short mode. If the path
23722   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23723   # take no chances and rewrite it.
23724   # Note: m4 eats our [], so we need to use [ and ] instead.
23725   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23726   if test "x$has_forbidden_chars" != x; then
23727     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23728     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23729     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23730     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23731       # Going to short mode and back again did indeed matter. Since short mode is
23732       # case insensitive, let's make it lowercase to improve readability.
23733       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23734       # Now convert it back to Unix-stile (cygpath)
23735       input_path=`$CYGPATH -u "$shortmode_path"`
23736       new_path="$input_path"
23737     fi
23738   fi
23739 
23740   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23741   if test "x$test_cygdrive_prefix" = x; then
23742     # As a simple fix, exclude /usr/bin since it's not a real path.
23743     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23744       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23745       # a path prefixed by /cygdrive for fixpath to work.
23746       new_path="$CYGWIN_ROOT_PATH$input_path"
23747     fi
23748   fi
23749 
23750 
23751   if test "x$path" != "x$new_path"; then
23752     BOOT_JDK="$new_path"
23753     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23754 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23755   fi
23756 
23757   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23758 
23759   path="$BOOT_JDK"
23760   has_colon=`$ECHO $path | $GREP ^.:`
23761   new_path="$path"
23762   if test "x$has_colon" = x; then
23763     # Not in mixed or Windows style, start by that.
23764     new_path=`cmd //c echo $path`
23765   fi
23766 
23767 
23768   input_path="$new_path"
23769   # Check if we need to convert this using DOS-style short mode. If the path
23770   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23771   # take no chances and rewrite it.
23772   # Note: m4 eats our [], so we need to use [ and ] instead.
23773   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23774   if test "x$has_forbidden_chars" != x; then
23775     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23776     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23777   fi
23778 
23779 
23780   windows_path="$new_path"
23781   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23782     unix_path=`$CYGPATH -u "$windows_path"`
23783     new_path="$unix_path"
23784   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23785     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23786     new_path="$unix_path"
23787   fi
23788 
23789   if test "x$path" != "x$new_path"; then
23790     BOOT_JDK="$new_path"
23791     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23792 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23793   fi
23794 
23795   # Save the first 10 bytes of this path to the storage, so fixpath can work.
23796   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23797 
23798   else
23799     # We're on a unix platform. Hooray! :)
23800     path="$BOOT_JDK"
23801     has_space=`$ECHO "$path" | $GREP " "`
23802     if test "x$has_space" != x; then
23803       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23804 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23805       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
23806     fi
23807 
23808     # Use eval to expand a potential ~
23809     eval path="$path"
23810     if test ! -f "$path" && test ! -d "$path"; then
23811       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
23812     fi
23813 
23814     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
23815   fi
23816 
23817               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
23818 $as_echo_n "checking for Boot JDK... " >&6; }
23819               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
23820 $as_echo "$BOOT_JDK" >&6; }
23821               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
23822 $as_echo_n "checking Boot JDK version... " >&6; }
23823               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
23824               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
23825 $as_echo "$BOOT_JDK_VERSION" >&6; }
23826             fi # end check jdk version
23827           fi # end check rt.jar
23828         fi # end check javac
23829       fi # end check java
23830     fi # end check boot jdk found
23831   fi
23832 
23833 
23834   if test "x$BOOT_JDK_FOUND" = xno; then
23835     # Now execute the test
23836 
23837   BOOT_JDK_PREFIX="/cygdrive/c/Program Files/Java"
23838   BOOT_JDK_SUFFIX=""
23839   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
23840   if test "x$ALL_JDKS_FOUND" != x; then
23841     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
23842 
23843   if test "x$BOOT_JDK_FOUND" = xno; then
23844     # Now execute the test
23845 
23846         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
23847         if test -d "$BOOT_JDK"; then
23848           BOOT_JDK_FOUND=maybe
23849           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
23850 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
23851         fi
23852 
23853 
23854     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
23855     if test "x$BOOT_JDK_FOUND" = xmaybe; then
23856       # Do we have a bin/java?
23857       if test ! -x "$BOOT_JDK/bin/java"; then
23858         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
23859 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
23860         BOOT_JDK_FOUND=no
23861       else
23862         # Do we have a bin/javac?
23863         if test ! -x "$BOOT_JDK/bin/javac"; then
23864           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
23865 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
23866           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
23867 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
23868           BOOT_JDK_FOUND=no
23869         else
23870           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
23871           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
23872             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
23873 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
23874             BOOT_JDK_FOUND=no
23875           else
23876             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
23877             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
23878 
23879             # Extra M4 quote needed to protect [] in grep expression.
23880             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
23881             if test "x$FOUND_CORRECT_VERSION" = x; then
23882               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
23883 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
23884               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
23885 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
23886               BOOT_JDK_FOUND=no
23887             else
23888               # We're done! :-)
23889               BOOT_JDK_FOUND=yes
23890 
23891   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23892 
23893   # Input might be given as Windows format, start by converting to
23894   # unix format.
23895   path="$BOOT_JDK"
23896   new_path=`$CYGPATH -u "$path"`
23897 
23898   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
23899   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
23900   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
23901   # "foo.exe" is OK but "foo" is an error.
23902   #
23903   # This test is therefore slightly more accurate than "test -f" to check for file precense.
23904   # It is also a way to make sure we got the proper file name for the real test later on.
23905   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
23906   if test "x$test_shortpath" = x; then
23907     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23908 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
23909     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
23910   fi
23911 
23912   # Call helper function which possibly converts this using DOS-style short mode.
23913   # If so, the updated path is stored in $new_path.
23914 
23915   input_path="$new_path"
23916   # Check if we need to convert this using DOS-style short mode. If the path
23917   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23918   # take no chances and rewrite it.
23919   # Note: m4 eats our [], so we need to use [ and ] instead.
23920   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
23921   if test "x$has_forbidden_chars" != x; then
23922     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23923     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
23924     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
23925     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
23926       # Going to short mode and back again did indeed matter. Since short mode is
23927       # case insensitive, let's make it lowercase to improve readability.
23928       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23929       # Now convert it back to Unix-stile (cygpath)
23930       input_path=`$CYGPATH -u "$shortmode_path"`
23931       new_path="$input_path"
23932     fi
23933   fi
23934 
23935   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
23936   if test "x$test_cygdrive_prefix" = x; then
23937     # As a simple fix, exclude /usr/bin since it's not a real path.
23938     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
23939       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
23940       # a path prefixed by /cygdrive for fixpath to work.
23941       new_path="$CYGWIN_ROOT_PATH$input_path"
23942     fi
23943   fi
23944 
23945 
23946   if test "x$path" != "x$new_path"; then
23947     BOOT_JDK="$new_path"
23948     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23949 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23950   fi
23951 
23952   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23953 
23954   path="$BOOT_JDK"
23955   has_colon=`$ECHO $path | $GREP ^.:`
23956   new_path="$path"
23957   if test "x$has_colon" = x; then
23958     # Not in mixed or Windows style, start by that.
23959     new_path=`cmd //c echo $path`
23960   fi
23961 
23962 
23963   input_path="$new_path"
23964   # Check if we need to convert this using DOS-style short mode. If the path
23965   # contains just simple characters, use it. Otherwise (spaces, weird characters),
23966   # take no chances and rewrite it.
23967   # Note: m4 eats our [], so we need to use [ and ] instead.
23968   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
23969   if test "x$has_forbidden_chars" != x; then
23970     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
23971     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
23972   fi
23973 
23974 
23975   windows_path="$new_path"
23976   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
23977     unix_path=`$CYGPATH -u "$windows_path"`
23978     new_path="$unix_path"
23979   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
23980     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
23981     new_path="$unix_path"
23982   fi
23983 
23984   if test "x$path" != "x$new_path"; then
23985     BOOT_JDK="$new_path"
23986     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
23987 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
23988   fi
23989 
23990   # Save the first 10 bytes of this path to the storage, so fixpath can work.
23991   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
23992 
23993   else
23994     # We're on a unix platform. Hooray! :)
23995     path="$BOOT_JDK"
23996     has_space=`$ECHO "$path" | $GREP " "`
23997     if test "x$has_space" != x; then
23998       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
23999 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24000       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24001     fi
24002 
24003     # Use eval to expand a potential ~
24004     eval path="$path"
24005     if test ! -f "$path" && test ! -d "$path"; then
24006       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24007     fi
24008 
24009     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24010   fi
24011 
24012               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24013 $as_echo_n "checking for Boot JDK... " >&6; }
24014               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24015 $as_echo "$BOOT_JDK" >&6; }
24016               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24017 $as_echo_n "checking Boot JDK version... " >&6; }
24018               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24019               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24020 $as_echo "$BOOT_JDK_VERSION" >&6; }
24021             fi # end check jdk version
24022           fi # end check rt.jar
24023         fi # end check javac
24024       fi # end check java
24025     fi # end check boot jdk found
24026   fi
24027 
24028     done
24029   fi
24030 
24031 
24032     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24033     if test "x$BOOT_JDK_FOUND" = xmaybe; then
24034       # Do we have a bin/java?
24035       if test ! -x "$BOOT_JDK/bin/java"; then
24036         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24037 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24038         BOOT_JDK_FOUND=no
24039       else
24040         # Do we have a bin/javac?
24041         if test ! -x "$BOOT_JDK/bin/javac"; then
24042           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24043 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24044           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24045 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24046           BOOT_JDK_FOUND=no
24047         else
24048           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24049           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24050             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24051 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24052             BOOT_JDK_FOUND=no
24053           else
24054             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24055             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24056 
24057             # Extra M4 quote needed to protect [] in grep expression.
24058             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
24059             if test "x$FOUND_CORRECT_VERSION" = x; then
24060               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24061 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24062               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
24063 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
24064               BOOT_JDK_FOUND=no
24065             else
24066               # We're done! :-)
24067               BOOT_JDK_FOUND=yes
24068 
24069   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24070 
24071   # Input might be given as Windows format, start by converting to
24072   # unix format.
24073   path="$BOOT_JDK"
24074   new_path=`$CYGPATH -u "$path"`
24075 
24076   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24077   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24078   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24079   # "foo.exe" is OK but "foo" is an error.
24080   #
24081   # This test is therefore slightly more accurate than "test -f" to check for file precense.
24082   # It is also a way to make sure we got the proper file name for the real test later on.
24083   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24084   if test "x$test_shortpath" = x; then
24085     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24086 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24087     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24088   fi
24089 
24090   # Call helper function which possibly converts this using DOS-style short mode.
24091   # If so, the updated path is stored in $new_path.
24092 
24093   input_path="$new_path"
24094   # Check if we need to convert this using DOS-style short mode. If the path
24095   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24096   # take no chances and rewrite it.
24097   # Note: m4 eats our [], so we need to use [ and ] instead.
24098   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24099   if test "x$has_forbidden_chars" != x; then
24100     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24101     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24102     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24103     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24104       # Going to short mode and back again did indeed matter. Since short mode is
24105       # case insensitive, let's make it lowercase to improve readability.
24106       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24107       # Now convert it back to Unix-stile (cygpath)
24108       input_path=`$CYGPATH -u "$shortmode_path"`
24109       new_path="$input_path"
24110     fi
24111   fi
24112 
24113   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24114   if test "x$test_cygdrive_prefix" = x; then
24115     # As a simple fix, exclude /usr/bin since it's not a real path.
24116     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24117       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24118       # a path prefixed by /cygdrive for fixpath to work.
24119       new_path="$CYGWIN_ROOT_PATH$input_path"
24120     fi
24121   fi
24122 
24123 
24124   if test "x$path" != "x$new_path"; then
24125     BOOT_JDK="$new_path"
24126     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24127 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24128   fi
24129 
24130   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24131 
24132   path="$BOOT_JDK"
24133   has_colon=`$ECHO $path | $GREP ^.:`
24134   new_path="$path"
24135   if test "x$has_colon" = x; then
24136     # Not in mixed or Windows style, start by that.
24137     new_path=`cmd //c echo $path`
24138   fi
24139 
24140 
24141   input_path="$new_path"
24142   # Check if we need to convert this using DOS-style short mode. If the path
24143   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24144   # take no chances and rewrite it.
24145   # Note: m4 eats our [], so we need to use [ and ] instead.
24146   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24147   if test "x$has_forbidden_chars" != x; then
24148     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24149     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24150   fi
24151 
24152 
24153   windows_path="$new_path"
24154   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24155     unix_path=`$CYGPATH -u "$windows_path"`
24156     new_path="$unix_path"
24157   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24158     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24159     new_path="$unix_path"
24160   fi
24161 
24162   if test "x$path" != "x$new_path"; then
24163     BOOT_JDK="$new_path"
24164     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24165 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24166   fi
24167 
24168   # Save the first 10 bytes of this path to the storage, so fixpath can work.
24169   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24170 
24171   else
24172     # We're on a unix platform. Hooray! :)
24173     path="$BOOT_JDK"
24174     has_space=`$ECHO "$path" | $GREP " "`
24175     if test "x$has_space" != x; then
24176       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24177 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24178       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24179     fi
24180 
24181     # Use eval to expand a potential ~
24182     eval path="$path"
24183     if test ! -f "$path" && test ! -d "$path"; then
24184       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24185     fi
24186 
24187     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24188   fi
24189 
24190               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24191 $as_echo_n "checking for Boot JDK... " >&6; }
24192               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24193 $as_echo "$BOOT_JDK" >&6; }
24194               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24195 $as_echo_n "checking Boot JDK version... " >&6; }
24196               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24197               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24198 $as_echo "$BOOT_JDK_VERSION" >&6; }
24199             fi # end check jdk version
24200           fi # end check rt.jar
24201         fi # end check javac
24202       fi # end check java
24203     fi # end check boot jdk found
24204   fi
24205 
24206   elif test "x$OPENJDK_TARGET_OS" = xmacosx; then
24207 
24208   if test "x$BOOT_JDK_FOUND" = xno; then
24209     # Now execute the test
24210 
24211   BOOT_JDK_PREFIX="/Library/Java/JavaVirtualMachines"
24212   BOOT_JDK_SUFFIX="/Contents/Home"
24213   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
24214   if test "x$ALL_JDKS_FOUND" != x; then
24215     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
24216 
24217   if test "x$BOOT_JDK_FOUND" = xno; then
24218     # Now execute the test
24219 
24220         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
24221         if test -d "$BOOT_JDK"; then
24222           BOOT_JDK_FOUND=maybe
24223           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
24224 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
24225         fi
24226 
24227 
24228     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24229     if test "x$BOOT_JDK_FOUND" = xmaybe; then
24230       # Do we have a bin/java?
24231       if test ! -x "$BOOT_JDK/bin/java"; then
24232         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24233 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24234         BOOT_JDK_FOUND=no
24235       else
24236         # Do we have a bin/javac?
24237         if test ! -x "$BOOT_JDK/bin/javac"; then
24238           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24239 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24240           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24241 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24242           BOOT_JDK_FOUND=no
24243         else
24244           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24245           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24246             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24247 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24248             BOOT_JDK_FOUND=no
24249           else
24250             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24251             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24252 
24253             # Extra M4 quote needed to protect [] in grep expression.
24254             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
24255             if test "x$FOUND_CORRECT_VERSION" = x; then
24256               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24257 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24258               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
24259 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
24260               BOOT_JDK_FOUND=no
24261             else
24262               # We're done! :-)
24263               BOOT_JDK_FOUND=yes
24264 
24265   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24266 
24267   # Input might be given as Windows format, start by converting to
24268   # unix format.
24269   path="$BOOT_JDK"
24270   new_path=`$CYGPATH -u "$path"`
24271 
24272   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24273   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24274   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24275   # "foo.exe" is OK but "foo" is an error.
24276   #
24277   # This test is therefore slightly more accurate than "test -f" to check for file precense.
24278   # It is also a way to make sure we got the proper file name for the real test later on.
24279   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24280   if test "x$test_shortpath" = x; then
24281     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24282 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24283     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24284   fi
24285 
24286   # Call helper function which possibly converts this using DOS-style short mode.
24287   # If so, the updated path is stored in $new_path.
24288 
24289   input_path="$new_path"
24290   # Check if we need to convert this using DOS-style short mode. If the path
24291   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24292   # take no chances and rewrite it.
24293   # Note: m4 eats our [], so we need to use [ and ] instead.
24294   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24295   if test "x$has_forbidden_chars" != x; then
24296     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24297     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24298     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24299     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24300       # Going to short mode and back again did indeed matter. Since short mode is
24301       # case insensitive, let's make it lowercase to improve readability.
24302       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24303       # Now convert it back to Unix-stile (cygpath)
24304       input_path=`$CYGPATH -u "$shortmode_path"`
24305       new_path="$input_path"
24306     fi
24307   fi
24308 
24309   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24310   if test "x$test_cygdrive_prefix" = x; then
24311     # As a simple fix, exclude /usr/bin since it's not a real path.
24312     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24313       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24314       # a path prefixed by /cygdrive for fixpath to work.
24315       new_path="$CYGWIN_ROOT_PATH$input_path"
24316     fi
24317   fi
24318 
24319 
24320   if test "x$path" != "x$new_path"; then
24321     BOOT_JDK="$new_path"
24322     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24323 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24324   fi
24325 
24326   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24327 
24328   path="$BOOT_JDK"
24329   has_colon=`$ECHO $path | $GREP ^.:`
24330   new_path="$path"
24331   if test "x$has_colon" = x; then
24332     # Not in mixed or Windows style, start by that.
24333     new_path=`cmd //c echo $path`
24334   fi
24335 
24336 
24337   input_path="$new_path"
24338   # Check if we need to convert this using DOS-style short mode. If the path
24339   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24340   # take no chances and rewrite it.
24341   # Note: m4 eats our [], so we need to use [ and ] instead.
24342   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24343   if test "x$has_forbidden_chars" != x; then
24344     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24345     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24346   fi
24347 
24348 
24349   windows_path="$new_path"
24350   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24351     unix_path=`$CYGPATH -u "$windows_path"`
24352     new_path="$unix_path"
24353   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24354     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24355     new_path="$unix_path"
24356   fi
24357 
24358   if test "x$path" != "x$new_path"; then
24359     BOOT_JDK="$new_path"
24360     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24361 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24362   fi
24363 
24364   # Save the first 10 bytes of this path to the storage, so fixpath can work.
24365   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24366 
24367   else
24368     # We're on a unix platform. Hooray! :)
24369     path="$BOOT_JDK"
24370     has_space=`$ECHO "$path" | $GREP " "`
24371     if test "x$has_space" != x; then
24372       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24373 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24374       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24375     fi
24376 
24377     # Use eval to expand a potential ~
24378     eval path="$path"
24379     if test ! -f "$path" && test ! -d "$path"; then
24380       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24381     fi
24382 
24383     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24384   fi
24385 
24386               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24387 $as_echo_n "checking for Boot JDK... " >&6; }
24388               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24389 $as_echo "$BOOT_JDK" >&6; }
24390               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24391 $as_echo_n "checking Boot JDK version... " >&6; }
24392               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24393               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24394 $as_echo "$BOOT_JDK_VERSION" >&6; }
24395             fi # end check jdk version
24396           fi # end check rt.jar
24397         fi # end check javac
24398       fi # end check java
24399     fi # end check boot jdk found
24400   fi
24401 
24402     done
24403   fi
24404 
24405 
24406     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24407     if test "x$BOOT_JDK_FOUND" = xmaybe; then
24408       # Do we have a bin/java?
24409       if test ! -x "$BOOT_JDK/bin/java"; then
24410         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24411 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24412         BOOT_JDK_FOUND=no
24413       else
24414         # Do we have a bin/javac?
24415         if test ! -x "$BOOT_JDK/bin/javac"; then
24416           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24417 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24418           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24419 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24420           BOOT_JDK_FOUND=no
24421         else
24422           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24423           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24424             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24425 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24426             BOOT_JDK_FOUND=no
24427           else
24428             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24429             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24430 
24431             # Extra M4 quote needed to protect [] in grep expression.
24432             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
24433             if test "x$FOUND_CORRECT_VERSION" = x; then
24434               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24435 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24436               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
24437 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
24438               BOOT_JDK_FOUND=no
24439             else
24440               # We're done! :-)
24441               BOOT_JDK_FOUND=yes
24442 
24443   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24444 
24445   # Input might be given as Windows format, start by converting to
24446   # unix format.
24447   path="$BOOT_JDK"
24448   new_path=`$CYGPATH -u "$path"`
24449 
24450   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24451   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24452   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24453   # "foo.exe" is OK but "foo" is an error.
24454   #
24455   # This test is therefore slightly more accurate than "test -f" to check for file precense.
24456   # It is also a way to make sure we got the proper file name for the real test later on.
24457   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24458   if test "x$test_shortpath" = x; then
24459     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24460 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24461     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24462   fi
24463 
24464   # Call helper function which possibly converts this using DOS-style short mode.
24465   # If so, the updated path is stored in $new_path.
24466 
24467   input_path="$new_path"
24468   # Check if we need to convert this using DOS-style short mode. If the path
24469   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24470   # take no chances and rewrite it.
24471   # Note: m4 eats our [], so we need to use [ and ] instead.
24472   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24473   if test "x$has_forbidden_chars" != x; then
24474     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24475     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24476     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24477     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24478       # Going to short mode and back again did indeed matter. Since short mode is
24479       # case insensitive, let's make it lowercase to improve readability.
24480       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24481       # Now convert it back to Unix-stile (cygpath)
24482       input_path=`$CYGPATH -u "$shortmode_path"`
24483       new_path="$input_path"
24484     fi
24485   fi
24486 
24487   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24488   if test "x$test_cygdrive_prefix" = x; then
24489     # As a simple fix, exclude /usr/bin since it's not a real path.
24490     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24491       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24492       # a path prefixed by /cygdrive for fixpath to work.
24493       new_path="$CYGWIN_ROOT_PATH$input_path"
24494     fi
24495   fi
24496 
24497 
24498   if test "x$path" != "x$new_path"; then
24499     BOOT_JDK="$new_path"
24500     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24501 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24502   fi
24503 
24504   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24505 
24506   path="$BOOT_JDK"
24507   has_colon=`$ECHO $path | $GREP ^.:`
24508   new_path="$path"
24509   if test "x$has_colon" = x; then
24510     # Not in mixed or Windows style, start by that.
24511     new_path=`cmd //c echo $path`
24512   fi
24513 
24514 
24515   input_path="$new_path"
24516   # Check if we need to convert this using DOS-style short mode. If the path
24517   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24518   # take no chances and rewrite it.
24519   # Note: m4 eats our [], so we need to use [ and ] instead.
24520   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24521   if test "x$has_forbidden_chars" != x; then
24522     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24523     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24524   fi
24525 
24526 
24527   windows_path="$new_path"
24528   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24529     unix_path=`$CYGPATH -u "$windows_path"`
24530     new_path="$unix_path"
24531   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24532     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24533     new_path="$unix_path"
24534   fi
24535 
24536   if test "x$path" != "x$new_path"; then
24537     BOOT_JDK="$new_path"
24538     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24539 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24540   fi
24541 
24542   # Save the first 10 bytes of this path to the storage, so fixpath can work.
24543   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24544 
24545   else
24546     # We're on a unix platform. Hooray! :)
24547     path="$BOOT_JDK"
24548     has_space=`$ECHO "$path" | $GREP " "`
24549     if test "x$has_space" != x; then
24550       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24551 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24552       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24553     fi
24554 
24555     # Use eval to expand a potential ~
24556     eval path="$path"
24557     if test ! -f "$path" && test ! -d "$path"; then
24558       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24559     fi
24560 
24561     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24562   fi
24563 
24564               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24565 $as_echo_n "checking for Boot JDK... " >&6; }
24566               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24567 $as_echo "$BOOT_JDK" >&6; }
24568               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24569 $as_echo_n "checking Boot JDK version... " >&6; }
24570               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24571               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24572 $as_echo "$BOOT_JDK_VERSION" >&6; }
24573             fi # end check jdk version
24574           fi # end check rt.jar
24575         fi # end check javac
24576       fi # end check java
24577     fi # end check boot jdk found
24578   fi
24579 
24580 
24581   if test "x$BOOT_JDK_FOUND" = xno; then
24582     # Now execute the test
24583 
24584   BOOT_JDK_PREFIX="/System/Library/Java/JavaVirtualMachines"
24585   BOOT_JDK_SUFFIX="/Contents/Home"
24586   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
24587   if test "x$ALL_JDKS_FOUND" != x; then
24588     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
24589 
24590   if test "x$BOOT_JDK_FOUND" = xno; then
24591     # Now execute the test
24592 
24593         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
24594         if test -d "$BOOT_JDK"; then
24595           BOOT_JDK_FOUND=maybe
24596           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
24597 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
24598         fi
24599 
24600 
24601     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24602     if test "x$BOOT_JDK_FOUND" = xmaybe; then
24603       # Do we have a bin/java?
24604       if test ! -x "$BOOT_JDK/bin/java"; then
24605         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24606 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24607         BOOT_JDK_FOUND=no
24608       else
24609         # Do we have a bin/javac?
24610         if test ! -x "$BOOT_JDK/bin/javac"; then
24611           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24612 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24613           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24614 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24615           BOOT_JDK_FOUND=no
24616         else
24617           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24618           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24619             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24620 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24621             BOOT_JDK_FOUND=no
24622           else
24623             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24624             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24625 
24626             # Extra M4 quote needed to protect [] in grep expression.
24627             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
24628             if test "x$FOUND_CORRECT_VERSION" = x; then
24629               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24630 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24631               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
24632 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
24633               BOOT_JDK_FOUND=no
24634             else
24635               # We're done! :-)
24636               BOOT_JDK_FOUND=yes
24637 
24638   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24639 
24640   # Input might be given as Windows format, start by converting to
24641   # unix format.
24642   path="$BOOT_JDK"
24643   new_path=`$CYGPATH -u "$path"`
24644 
24645   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24646   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24647   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24648   # "foo.exe" is OK but "foo" is an error.
24649   #
24650   # This test is therefore slightly more accurate than "test -f" to check for file precense.
24651   # It is also a way to make sure we got the proper file name for the real test later on.
24652   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24653   if test "x$test_shortpath" = x; then
24654     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24655 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24656     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24657   fi
24658 
24659   # Call helper function which possibly converts this using DOS-style short mode.
24660   # If so, the updated path is stored in $new_path.
24661 
24662   input_path="$new_path"
24663   # Check if we need to convert this using DOS-style short mode. If the path
24664   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24665   # take no chances and rewrite it.
24666   # Note: m4 eats our [], so we need to use [ and ] instead.
24667   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24668   if test "x$has_forbidden_chars" != x; then
24669     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24670     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24671     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24672     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24673       # Going to short mode and back again did indeed matter. Since short mode is
24674       # case insensitive, let's make it lowercase to improve readability.
24675       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24676       # Now convert it back to Unix-stile (cygpath)
24677       input_path=`$CYGPATH -u "$shortmode_path"`
24678       new_path="$input_path"
24679     fi
24680   fi
24681 
24682   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24683   if test "x$test_cygdrive_prefix" = x; then
24684     # As a simple fix, exclude /usr/bin since it's not a real path.
24685     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24686       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24687       # a path prefixed by /cygdrive for fixpath to work.
24688       new_path="$CYGWIN_ROOT_PATH$input_path"
24689     fi
24690   fi
24691 
24692 
24693   if test "x$path" != "x$new_path"; then
24694     BOOT_JDK="$new_path"
24695     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24696 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24697   fi
24698 
24699   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24700 
24701   path="$BOOT_JDK"
24702   has_colon=`$ECHO $path | $GREP ^.:`
24703   new_path="$path"
24704   if test "x$has_colon" = x; then
24705     # Not in mixed or Windows style, start by that.
24706     new_path=`cmd //c echo $path`
24707   fi
24708 
24709 
24710   input_path="$new_path"
24711   # Check if we need to convert this using DOS-style short mode. If the path
24712   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24713   # take no chances and rewrite it.
24714   # Note: m4 eats our [], so we need to use [ and ] instead.
24715   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24716   if test "x$has_forbidden_chars" != x; then
24717     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24718     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24719   fi
24720 
24721 
24722   windows_path="$new_path"
24723   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24724     unix_path=`$CYGPATH -u "$windows_path"`
24725     new_path="$unix_path"
24726   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24727     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24728     new_path="$unix_path"
24729   fi
24730 
24731   if test "x$path" != "x$new_path"; then
24732     BOOT_JDK="$new_path"
24733     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24734 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24735   fi
24736 
24737   # Save the first 10 bytes of this path to the storage, so fixpath can work.
24738   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24739 
24740   else
24741     # We're on a unix platform. Hooray! :)
24742     path="$BOOT_JDK"
24743     has_space=`$ECHO "$path" | $GREP " "`
24744     if test "x$has_space" != x; then
24745       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24746 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24747       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24748     fi
24749 
24750     # Use eval to expand a potential ~
24751     eval path="$path"
24752     if test ! -f "$path" && test ! -d "$path"; then
24753       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24754     fi
24755 
24756     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24757   fi
24758 
24759               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24760 $as_echo_n "checking for Boot JDK... " >&6; }
24761               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24762 $as_echo "$BOOT_JDK" >&6; }
24763               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24764 $as_echo_n "checking Boot JDK version... " >&6; }
24765               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24766               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24767 $as_echo "$BOOT_JDK_VERSION" >&6; }
24768             fi # end check jdk version
24769           fi # end check rt.jar
24770         fi # end check javac
24771       fi # end check java
24772     fi # end check boot jdk found
24773   fi
24774 
24775     done
24776   fi
24777 
24778 
24779     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24780     if test "x$BOOT_JDK_FOUND" = xmaybe; then
24781       # Do we have a bin/java?
24782       if test ! -x "$BOOT_JDK/bin/java"; then
24783         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24784 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24785         BOOT_JDK_FOUND=no
24786       else
24787         # Do we have a bin/javac?
24788         if test ! -x "$BOOT_JDK/bin/javac"; then
24789           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24790 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24791           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24792 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24793           BOOT_JDK_FOUND=no
24794         else
24795           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24796           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24797             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24798 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24799             BOOT_JDK_FOUND=no
24800           else
24801             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24802             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24803 
24804             # Extra M4 quote needed to protect [] in grep expression.
24805             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
24806             if test "x$FOUND_CORRECT_VERSION" = x; then
24807               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
24808 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
24809               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
24810 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
24811               BOOT_JDK_FOUND=no
24812             else
24813               # We're done! :-)
24814               BOOT_JDK_FOUND=yes
24815 
24816   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24817 
24818   # Input might be given as Windows format, start by converting to
24819   # unix format.
24820   path="$BOOT_JDK"
24821   new_path=`$CYGPATH -u "$path"`
24822 
24823   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
24824   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
24825   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
24826   # "foo.exe" is OK but "foo" is an error.
24827   #
24828   # This test is therefore slightly more accurate than "test -f" to check for file precense.
24829   # It is also a way to make sure we got the proper file name for the real test later on.
24830   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
24831   if test "x$test_shortpath" = x; then
24832     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24833 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24834     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
24835   fi
24836 
24837   # Call helper function which possibly converts this using DOS-style short mode.
24838   # If so, the updated path is stored in $new_path.
24839 
24840   input_path="$new_path"
24841   # Check if we need to convert this using DOS-style short mode. If the path
24842   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24843   # take no chances and rewrite it.
24844   # Note: m4 eats our [], so we need to use [ and ] instead.
24845   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
24846   if test "x$has_forbidden_chars" != x; then
24847     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24848     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
24849     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
24850     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
24851       # Going to short mode and back again did indeed matter. Since short mode is
24852       # case insensitive, let's make it lowercase to improve readability.
24853       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24854       # Now convert it back to Unix-stile (cygpath)
24855       input_path=`$CYGPATH -u "$shortmode_path"`
24856       new_path="$input_path"
24857     fi
24858   fi
24859 
24860   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
24861   if test "x$test_cygdrive_prefix" = x; then
24862     # As a simple fix, exclude /usr/bin since it's not a real path.
24863     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
24864       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
24865       # a path prefixed by /cygdrive for fixpath to work.
24866       new_path="$CYGWIN_ROOT_PATH$input_path"
24867     fi
24868   fi
24869 
24870 
24871   if test "x$path" != "x$new_path"; then
24872     BOOT_JDK="$new_path"
24873     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24874 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24875   fi
24876 
24877   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24878 
24879   path="$BOOT_JDK"
24880   has_colon=`$ECHO $path | $GREP ^.:`
24881   new_path="$path"
24882   if test "x$has_colon" = x; then
24883     # Not in mixed or Windows style, start by that.
24884     new_path=`cmd //c echo $path`
24885   fi
24886 
24887 
24888   input_path="$new_path"
24889   # Check if we need to convert this using DOS-style short mode. If the path
24890   # contains just simple characters, use it. Otherwise (spaces, weird characters),
24891   # take no chances and rewrite it.
24892   # Note: m4 eats our [], so we need to use [ and ] instead.
24893   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
24894   if test "x$has_forbidden_chars" != x; then
24895     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
24896     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
24897   fi
24898 
24899 
24900   windows_path="$new_path"
24901   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
24902     unix_path=`$CYGPATH -u "$windows_path"`
24903     new_path="$unix_path"
24904   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
24905     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
24906     new_path="$unix_path"
24907   fi
24908 
24909   if test "x$path" != "x$new_path"; then
24910     BOOT_JDK="$new_path"
24911     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
24912 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
24913   fi
24914 
24915   # Save the first 10 bytes of this path to the storage, so fixpath can work.
24916   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
24917 
24918   else
24919     # We're on a unix platform. Hooray! :)
24920     path="$BOOT_JDK"
24921     has_space=`$ECHO "$path" | $GREP " "`
24922     if test "x$has_space" != x; then
24923       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
24924 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
24925       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
24926     fi
24927 
24928     # Use eval to expand a potential ~
24929     eval path="$path"
24930     if test ! -f "$path" && test ! -d "$path"; then
24931       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
24932     fi
24933 
24934     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
24935   fi
24936 
24937               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
24938 $as_echo_n "checking for Boot JDK... " >&6; }
24939               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
24940 $as_echo "$BOOT_JDK" >&6; }
24941               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
24942 $as_echo_n "checking Boot JDK version... " >&6; }
24943               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
24944               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
24945 $as_echo "$BOOT_JDK_VERSION" >&6; }
24946             fi # end check jdk version
24947           fi # end check rt.jar
24948         fi # end check javac
24949       fi # end check java
24950     fi # end check boot jdk found
24951   fi
24952 
24953   elif test "x$OPENJDK_TARGET_OS" = xlinux; then
24954 
24955   if test "x$BOOT_JDK_FOUND" = xno; then
24956     # Now execute the test
24957 
24958   BOOT_JDK_PREFIX="/usr/lib/jvm"
24959   BOOT_JDK_SUFFIX=""
24960   ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r`
24961   if test "x$ALL_JDKS_FOUND" != x; then
24962     for JDK_TO_TRY in $ALL_JDKS_FOUND ; do
24963 
24964   if test "x$BOOT_JDK_FOUND" = xno; then
24965     # Now execute the test
24966 
24967         BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}"
24968         if test -d "$BOOT_JDK"; then
24969           BOOT_JDK_FOUND=maybe
24970           { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5
24971 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;}
24972         fi
24973 
24974 
24975     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
24976     if test "x$BOOT_JDK_FOUND" = xmaybe; then
24977       # Do we have a bin/java?
24978       if test ! -x "$BOOT_JDK/bin/java"; then
24979         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
24980 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
24981         BOOT_JDK_FOUND=no
24982       else
24983         # Do we have a bin/javac?
24984         if test ! -x "$BOOT_JDK/bin/javac"; then
24985           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
24986 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
24987           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
24988 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
24989           BOOT_JDK_FOUND=no
24990         else
24991           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
24992           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
24993             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
24994 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
24995             BOOT_JDK_FOUND=no
24996           else
24997             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
24998             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
24999 
25000             # Extra M4 quote needed to protect [] in grep expression.
25001             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
25002             if test "x$FOUND_CORRECT_VERSION" = x; then
25003               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
25004 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
25005               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
25006 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
25007               BOOT_JDK_FOUND=no
25008             else
25009               # We're done! :-)
25010               BOOT_JDK_FOUND=yes
25011 
25012   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
25013 
25014   # Input might be given as Windows format, start by converting to
25015   # unix format.
25016   path="$BOOT_JDK"
25017   new_path=`$CYGPATH -u "$path"`
25018 
25019   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
25020   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
25021   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
25022   # "foo.exe" is OK but "foo" is an error.
25023   #
25024   # This test is therefore slightly more accurate than "test -f" to check for file precense.
25025   # It is also a way to make sure we got the proper file name for the real test later on.
25026   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
25027   if test "x$test_shortpath" = x; then
25028     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
25029 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
25030     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
25031   fi
25032 
25033   # Call helper function which possibly converts this using DOS-style short mode.
25034   # If so, the updated path is stored in $new_path.
25035 
25036   input_path="$new_path"
25037   # Check if we need to convert this using DOS-style short mode. If the path
25038   # contains just simple characters, use it. Otherwise (spaces, weird characters),
25039   # take no chances and rewrite it.
25040   # Note: m4 eats our [], so we need to use [ and ] instead.
25041   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
25042   if test "x$has_forbidden_chars" != x; then
25043     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
25044     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
25045     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
25046     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
25047       # Going to short mode and back again did indeed matter. Since short mode is
25048       # case insensitive, let's make it lowercase to improve readability.
25049       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
25050       # Now convert it back to Unix-stile (cygpath)
25051       input_path=`$CYGPATH -u "$shortmode_path"`
25052       new_path="$input_path"
25053     fi
25054   fi
25055 
25056   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
25057   if test "x$test_cygdrive_prefix" = x; then
25058     # As a simple fix, exclude /usr/bin since it's not a real path.
25059     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
25060       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
25061       # a path prefixed by /cygdrive for fixpath to work.
25062       new_path="$CYGWIN_ROOT_PATH$input_path"
25063     fi
25064   fi
25065 
25066 
25067   if test "x$path" != "x$new_path"; then
25068     BOOT_JDK="$new_path"
25069     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
25070 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
25071   fi
25072 
25073   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
25074 
25075   path="$BOOT_JDK"
25076   has_colon=`$ECHO $path | $GREP ^.:`
25077   new_path="$path"
25078   if test "x$has_colon" = x; then
25079     # Not in mixed or Windows style, start by that.
25080     new_path=`cmd //c echo $path`
25081   fi
25082 
25083 
25084   input_path="$new_path"
25085   # Check if we need to convert this using DOS-style short mode. If the path
25086   # contains just simple characters, use it. Otherwise (spaces, weird characters),
25087   # take no chances and rewrite it.
25088   # Note: m4 eats our [], so we need to use [ and ] instead.
25089   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
25090   if test "x$has_forbidden_chars" != x; then
25091     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
25092     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
25093   fi
25094 
25095 
25096   windows_path="$new_path"
25097   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
25098     unix_path=`$CYGPATH -u "$windows_path"`
25099     new_path="$unix_path"
25100   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
25101     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
25102     new_path="$unix_path"
25103   fi
25104 
25105   if test "x$path" != "x$new_path"; then
25106     BOOT_JDK="$new_path"
25107     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
25108 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
25109   fi
25110 
25111   # Save the first 10 bytes of this path to the storage, so fixpath can work.
25112   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
25113 
25114   else
25115     # We're on a unix platform. Hooray! :)
25116     path="$BOOT_JDK"
25117     has_space=`$ECHO "$path" | $GREP " "`
25118     if test "x$has_space" != x; then
25119       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
25120 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
25121       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
25122     fi
25123 
25124     # Use eval to expand a potential ~
25125     eval path="$path"
25126     if test ! -f "$path" && test ! -d "$path"; then
25127       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
25128     fi
25129 
25130     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
25131   fi
25132 
25133               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
25134 $as_echo_n "checking for Boot JDK... " >&6; }
25135               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
25136 $as_echo "$BOOT_JDK" >&6; }
25137               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
25138 $as_echo_n "checking Boot JDK version... " >&6; }
25139               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
25140               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
25141 $as_echo "$BOOT_JDK_VERSION" >&6; }
25142             fi # end check jdk version
25143           fi # end check rt.jar
25144         fi # end check javac
25145       fi # end check java
25146     fi # end check boot jdk found
25147   fi
25148 
25149     done
25150   fi
25151 
25152 
25153     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
25154     if test "x$BOOT_JDK_FOUND" = xmaybe; then
25155       # Do we have a bin/java?
25156       if test ! -x "$BOOT_JDK/bin/java"; then
25157         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
25158 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
25159         BOOT_JDK_FOUND=no
25160       else
25161         # Do we have a bin/javac?
25162         if test ! -x "$BOOT_JDK/bin/javac"; then
25163           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
25164 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
25165           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
25166 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
25167           BOOT_JDK_FOUND=no
25168         else
25169           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
25170           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
25171             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
25172 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
25173             BOOT_JDK_FOUND=no
25174           else
25175             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
25176             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
25177 
25178             # Extra M4 quote needed to protect [] in grep expression.
25179             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
25180             if test "x$FOUND_CORRECT_VERSION" = x; then
25181               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
25182 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
25183               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
25184 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
25185               BOOT_JDK_FOUND=no
25186             else
25187               # We're done! :-)
25188               BOOT_JDK_FOUND=yes
25189 
25190   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
25191 
25192   # Input might be given as Windows format, start by converting to
25193   # unix format.
25194   path="$BOOT_JDK"
25195   new_path=`$CYGPATH -u "$path"`
25196 
25197   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
25198   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
25199   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
25200   # "foo.exe" is OK but "foo" is an error.
25201   #
25202   # This test is therefore slightly more accurate than "test -f" to check for file precense.
25203   # It is also a way to make sure we got the proper file name for the real test later on.
25204   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
25205   if test "x$test_shortpath" = x; then
25206     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
25207 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
25208     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
25209   fi
25210 
25211   # Call helper function which possibly converts this using DOS-style short mode.
25212   # If so, the updated path is stored in $new_path.
25213 
25214   input_path="$new_path"
25215   # Check if we need to convert this using DOS-style short mode. If the path
25216   # contains just simple characters, use it. Otherwise (spaces, weird characters),
25217   # take no chances and rewrite it.
25218   # Note: m4 eats our [], so we need to use [ and ] instead.
25219   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
25220   if test "x$has_forbidden_chars" != x; then
25221     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
25222     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
25223     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
25224     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
25225       # Going to short mode and back again did indeed matter. Since short mode is
25226       # case insensitive, let's make it lowercase to improve readability.
25227       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
25228       # Now convert it back to Unix-stile (cygpath)
25229       input_path=`$CYGPATH -u "$shortmode_path"`
25230       new_path="$input_path"
25231     fi
25232   fi
25233 
25234   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
25235   if test "x$test_cygdrive_prefix" = x; then
25236     # As a simple fix, exclude /usr/bin since it's not a real path.
25237     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
25238       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
25239       # a path prefixed by /cygdrive for fixpath to work.
25240       new_path="$CYGWIN_ROOT_PATH$input_path"
25241     fi
25242   fi
25243 
25244 
25245   if test "x$path" != "x$new_path"; then
25246     BOOT_JDK="$new_path"
25247     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
25248 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
25249   fi
25250 
25251   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
25252 
25253   path="$BOOT_JDK"
25254   has_colon=`$ECHO $path | $GREP ^.:`
25255   new_path="$path"
25256   if test "x$has_colon" = x; then
25257     # Not in mixed or Windows style, start by that.
25258     new_path=`cmd //c echo $path`
25259   fi
25260 
25261 
25262   input_path="$new_path"
25263   # Check if we need to convert this using DOS-style short mode. If the path
25264   # contains just simple characters, use it. Otherwise (spaces, weird characters),
25265   # take no chances and rewrite it.
25266   # Note: m4 eats our [], so we need to use [ and ] instead.
25267   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
25268   if test "x$has_forbidden_chars" != x; then
25269     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
25270     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
25271   fi
25272 
25273 
25274   windows_path="$new_path"
25275   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
25276     unix_path=`$CYGPATH -u "$windows_path"`
25277     new_path="$unix_path"
25278   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
25279     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
25280     new_path="$unix_path"
25281   fi
25282 
25283   if test "x$path" != "x$new_path"; then
25284     BOOT_JDK="$new_path"
25285     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
25286 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
25287   fi
25288 
25289   # Save the first 10 bytes of this path to the storage, so fixpath can work.
25290   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
25291 
25292   else
25293     # We're on a unix platform. Hooray! :)
25294     path="$BOOT_JDK"
25295     has_space=`$ECHO "$path" | $GREP " "`
25296     if test "x$has_space" != x; then
25297       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
25298 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
25299       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
25300     fi
25301 
25302     # Use eval to expand a potential ~
25303     eval path="$path"
25304     if test ! -f "$path" && test ! -d "$path"; then
25305       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
25306     fi
25307 
25308     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
25309   fi
25310 
25311               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
25312 $as_echo_n "checking for Boot JDK... " >&6; }
25313               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
25314 $as_echo "$BOOT_JDK" >&6; }
25315               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
25316 $as_echo_n "checking Boot JDK version... " >&6; }
25317               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
25318               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
25319 $as_echo "$BOOT_JDK_VERSION" >&6; }
25320             fi # end check jdk version
25321           fi # end check rt.jar
25322         fi # end check javac
25323       fi # end check java
25324     fi # end check boot jdk found
25325   fi
25326 
25327   fi
25328 
25329 
25330     # If previous step claimed to have found a JDK, check it to see if it seems to be valid.
25331     if test "x$BOOT_JDK_FOUND" = xmaybe; then
25332       # Do we have a bin/java?
25333       if test ! -x "$BOOT_JDK/bin/java"; then
25334         { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5
25335 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;}
25336         BOOT_JDK_FOUND=no
25337       else
25338         # Do we have a bin/javac?
25339         if test ! -x "$BOOT_JDK/bin/javac"; then
25340           { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5
25341 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;}
25342           { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5
25343 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;}
25344           BOOT_JDK_FOUND=no
25345         else
25346           # Do we have an rt.jar? (On MacOSX it is called classes.jar)
25347           if test ! -f "$BOOT_JDK/jre/lib/rt.jar" && test ! -f "$BOOT_JDK/../Classes/classes.jar"; then
25348             { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&5
25349 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain an rt.jar; ignoring" >&6;}
25350             BOOT_JDK_FOUND=no
25351           else
25352             # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
25353             BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1`
25354 
25355             # Extra M4 quote needed to protect [] in grep expression.
25356             FOUND_CORRECT_VERSION=`echo $BOOT_JDK_VERSION | grep  '\"1\.[89]\.'`
25357             if test "x$FOUND_CORRECT_VERSION" = x; then
25358               { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5
25359 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;}
25360               { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5
25361 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;}
25362               BOOT_JDK_FOUND=no
25363             else
25364               # We're done! :-)
25365               BOOT_JDK_FOUND=yes
25366 
25367   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
25368 
25369   # Input might be given as Windows format, start by converting to
25370   # unix format.
25371   path="$BOOT_JDK"
25372   new_path=`$CYGPATH -u "$path"`
25373 
25374   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
25375   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
25376   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
25377   # "foo.exe" is OK but "foo" is an error.
25378   #
25379   # This test is therefore slightly more accurate than "test -f" to check for file precense.
25380   # It is also a way to make sure we got the proper file name for the real test later on.
25381   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
25382   if test "x$test_shortpath" = x; then
25383     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
25384 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
25385     as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5
25386   fi
25387 
25388   # Call helper function which possibly converts this using DOS-style short mode.
25389   # If so, the updated path is stored in $new_path.
25390 
25391   input_path="$new_path"
25392   # Check if we need to convert this using DOS-style short mode. If the path
25393   # contains just simple characters, use it. Otherwise (spaces, weird characters),
25394   # take no chances and rewrite it.
25395   # Note: m4 eats our [], so we need to use [ and ] instead.
25396   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
25397   if test "x$has_forbidden_chars" != x; then
25398     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
25399     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
25400     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
25401     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
25402       # Going to short mode and back again did indeed matter. Since short mode is
25403       # case insensitive, let's make it lowercase to improve readability.
25404       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
25405       # Now convert it back to Unix-stile (cygpath)
25406       input_path=`$CYGPATH -u "$shortmode_path"`
25407       new_path="$input_path"
25408     fi
25409   fi
25410 
25411   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
25412   if test "x$test_cygdrive_prefix" = x; then
25413     # As a simple fix, exclude /usr/bin since it's not a real path.
25414     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
25415       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
25416       # a path prefixed by /cygdrive for fixpath to work.
25417       new_path="$CYGWIN_ROOT_PATH$input_path"
25418     fi
25419   fi
25420 
25421 
25422   if test "x$path" != "x$new_path"; then
25423     BOOT_JDK="$new_path"
25424     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
25425 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
25426   fi
25427 
25428   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
25429 
25430   path="$BOOT_JDK"
25431   has_colon=`$ECHO $path | $GREP ^.:`
25432   new_path="$path"
25433   if test "x$has_colon" = x; then
25434     # Not in mixed or Windows style, start by that.
25435     new_path=`cmd //c echo $path`
25436   fi
25437 
25438 
25439   input_path="$new_path"
25440   # Check if we need to convert this using DOS-style short mode. If the path
25441   # contains just simple characters, use it. Otherwise (spaces, weird characters),
25442   # take no chances and rewrite it.
25443   # Note: m4 eats our [], so we need to use [ and ] instead.
25444   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
25445   if test "x$has_forbidden_chars" != x; then
25446     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
25447     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
25448   fi
25449 
25450 
25451   windows_path="$new_path"
25452   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
25453     unix_path=`$CYGPATH -u "$windows_path"`
25454     new_path="$unix_path"
25455   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
25456     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
25457     new_path="$unix_path"
25458   fi
25459 
25460   if test "x$path" != "x$new_path"; then
25461     BOOT_JDK="$new_path"
25462     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5
25463 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;}
25464   fi
25465 
25466   # Save the first 10 bytes of this path to the storage, so fixpath can work.
25467   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
25468 
25469   else
25470     # We're on a unix platform. Hooray! :)
25471     path="$BOOT_JDK"
25472     has_space=`$ECHO "$path" | $GREP " "`
25473     if test "x$has_space" != x; then
25474       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5
25475 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;}
25476       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
25477     fi
25478 
25479     # Use eval to expand a potential ~
25480     eval path="$path"
25481     if test ! -f "$path" && test ! -d "$path"; then
25482       as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5
25483     fi
25484 
25485     BOOT_JDK="`cd "$path"; $THEPWDCMD -L`"
25486   fi
25487 
25488               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5
25489 $as_echo_n "checking for Boot JDK... " >&6; }
25490               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5
25491 $as_echo "$BOOT_JDK" >&6; }
25492               { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5
25493 $as_echo_n "checking Boot JDK version... " >&6; }
25494               BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' '  '`
25495               { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5
25496 $as_echo "$BOOT_JDK_VERSION" >&6; }
25497             fi # end check jdk version
25498           fi # end check rt.jar
25499         fi # end check javac
25500       fi # end check java
25501     fi # end check boot jdk found
25502   fi
25503 
25504 
25505   # If we haven't found anything yet, we've truly lost. Give up.
25506   if test "x$BOOT_JDK_FOUND" = xno; then
25507 
25508   # Print a helpful message on how to acquire the necessary build dependency.
25509   # openjdk is the help tag: freetype, cups, pulse, alsa etc
25510   MISSING_DEPENDENCY=openjdk
25511 
25512   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
25513     cygwin_help $MISSING_DEPENDENCY
25514   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
25515     msys_help $MISSING_DEPENDENCY
25516   else
25517     PKGHANDLER_COMMAND=
25518 
25519     case $PKGHANDLER in
25520       apt-get)
25521         apt_help     $MISSING_DEPENDENCY ;;
25522       yum)
25523         yum_help     $MISSING_DEPENDENCY ;;
25524       port)
25525         port_help    $MISSING_DEPENDENCY ;;
25526       pkgutil)
25527         pkgutil_help $MISSING_DEPENDENCY ;;
25528       pkgadd)
25529         pkgadd_help  $MISSING_DEPENDENCY ;;
25530     esac
25531 
25532     if test "x$PKGHANDLER_COMMAND" != x; then
25533       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
25534     fi
25535   fi
25536 
25537     { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find a valid Boot JDK. $HELP_MSG" >&5
25538 $as_echo "$as_me: Could not find a valid Boot JDK. $HELP_MSG" >&6;}
25539     { $as_echo "$as_me:${as_lineno-$LINENO}: This might be fixed by explicitely setting --with-boot-jdk" >&5
25540 $as_echo "$as_me: This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25541     as_fn_error $? "Cannot continue" "$LINENO" 5
25542   fi
25543 
25544   # Setup proper paths for what we found
25545   BOOT_RTJAR="$BOOT_JDK/jre/lib/rt.jar"
25546   if test ! -f "$BOOT_RTJAR"; then
25547     # On MacOSX it is called classes.jar
25548     BOOT_RTJAR="$BOOT_JDK/../Classes/classes.jar"
25549     if test -f "$BOOT_RTJAR"; then
25550       # Remove the ..
25551       BOOT_RTJAR="`cd ${BOOT_RTJAR%/*} && pwd`/${BOOT_RTJAR##*/}"
25552     fi
25553   fi
25554   BOOT_TOOLSJAR="$BOOT_JDK/lib/tools.jar"
25555   BOOT_JDK="$BOOT_JDK"
25556 
25557 
25558 
25559 
25560   # Setup tools from the Boot JDK.
25561 
25562   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25563 
25564   # Publish this variable in the help.
25565 
25566 
25567   if test "x$JAVA" = x; then
25568     # The variable is not set by user, try to locate tool using the code snippet
25569 
25570       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5
25571 $as_echo_n "checking for java in Boot JDK... " >&6; }
25572       JAVA=$BOOT_JDK/bin/java
25573       if test ! -x $JAVA; then
25574         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25575 $as_echo "not found" >&6; }
25576         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25577 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25578         as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5
25579       fi
25580       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25581 $as_echo "ok" >&6; }
25582 
25583 
25584   else
25585     # The variable is set, but is it from the command line or the environment?
25586 
25587     # Try to remove the string !JAVA! from our list.
25588     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVA!/}
25589     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25590       # If it failed, the variable was not from the command line. Ignore it,
25591       # but warn the user (except for BASH, which is always set by the calling BASH).
25592       if test "xJAVA" != xBASH; then
25593         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&5
25594 $as_echo "$as_me: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&2;}
25595       fi
25596       # Try to locate tool using the code snippet
25597 
25598       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5
25599 $as_echo_n "checking for java in Boot JDK... " >&6; }
25600       JAVA=$BOOT_JDK/bin/java
25601       if test ! -x $JAVA; then
25602         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25603 $as_echo "not found" >&6; }
25604         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25605 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25606         as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5
25607       fi
25608       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25609 $as_echo "ok" >&6; }
25610 
25611 
25612     else
25613       # If it succeeded, then it was overridden by the user. We will use it
25614       # for the tool.
25615 
25616       # First remove it from the list of overridden variables, so we can test
25617       # for unknown variables in the end.
25618       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25619 
25620       # Check if the provided tool contains a complete path.
25621       tool_specified="$JAVA"
25622       tool_basename="${tool_specified##*/}"
25623       if test "x$tool_basename" = "x$tool_specified"; then
25624         # A command without a complete path is provided, search $PATH.
25625         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVA=$tool_basename" >&5
25626 $as_echo "$as_me: Will search for user supplied tool JAVA=$tool_basename" >&6;}
25627         # Extract the first word of "$tool_basename", so it can be a program name with args.
25628 set dummy $tool_basename; ac_word=$2
25629 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25630 $as_echo_n "checking for $ac_word... " >&6; }
25631 if ${ac_cv_path_JAVA+:} false; then :
25632   $as_echo_n "(cached) " >&6
25633 else
25634   case $JAVA in
25635   [\\/]* | ?:[\\/]*)
25636   ac_cv_path_JAVA="$JAVA" # Let the user override the test with a path.
25637   ;;
25638   *)
25639   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25640 for as_dir in $PATH
25641 do
25642   IFS=$as_save_IFS
25643   test -z "$as_dir" && as_dir=.
25644     for ac_exec_ext in '' $ac_executable_extensions; do
25645   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25646     ac_cv_path_JAVA="$as_dir/$ac_word$ac_exec_ext"
25647     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25648     break 2
25649   fi
25650 done
25651   done
25652 IFS=$as_save_IFS
25653 
25654   ;;
25655 esac
25656 fi
25657 JAVA=$ac_cv_path_JAVA
25658 if test -n "$JAVA"; then
25659   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA" >&5
25660 $as_echo "$JAVA" >&6; }
25661 else
25662   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25663 $as_echo "no" >&6; }
25664 fi
25665 
25666 
25667         if test "x$JAVA" = x; then
25668           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25669         fi
25670       else
25671         # Otherwise we believe it is a complete path. Use it as it is.
25672         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVA=$tool_specified" >&5
25673 $as_echo "$as_me: Will use user supplied tool JAVA=$tool_specified" >&6;}
25674         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5
25675 $as_echo_n "checking for JAVA... " >&6; }
25676         if test ! -x "$tool_specified"; then
25677           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25678 $as_echo "not found" >&6; }
25679           as_fn_error $? "User supplied tool JAVA=$tool_specified does not exist or is not executable" "$LINENO" 5
25680         fi
25681         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25682 $as_echo "$tool_specified" >&6; }
25683       fi
25684     fi
25685   fi
25686 
25687 
25688 
25689   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25690 
25691   # Publish this variable in the help.
25692 
25693 
25694   if test "x$JAVAC" = x; then
25695     # The variable is not set by user, try to locate tool using the code snippet
25696 
25697       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5
25698 $as_echo_n "checking for javac in Boot JDK... " >&6; }
25699       JAVAC=$BOOT_JDK/bin/javac
25700       if test ! -x $JAVAC; then
25701         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25702 $as_echo "not found" >&6; }
25703         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25704 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25705         as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5
25706       fi
25707       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25708 $as_echo "ok" >&6; }
25709 
25710 
25711   else
25712     # The variable is set, but is it from the command line or the environment?
25713 
25714     # Try to remove the string !JAVAC! from our list.
25715     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAC!/}
25716     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25717       # If it failed, the variable was not from the command line. Ignore it,
25718       # but warn the user (except for BASH, which is always set by the calling BASH).
25719       if test "xJAVAC" != xBASH; then
25720         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&5
25721 $as_echo "$as_me: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&2;}
25722       fi
25723       # Try to locate tool using the code snippet
25724 
25725       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5
25726 $as_echo_n "checking for javac in Boot JDK... " >&6; }
25727       JAVAC=$BOOT_JDK/bin/javac
25728       if test ! -x $JAVAC; then
25729         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25730 $as_echo "not found" >&6; }
25731         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25732 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25733         as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5
25734       fi
25735       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25736 $as_echo "ok" >&6; }
25737 
25738 
25739     else
25740       # If it succeeded, then it was overridden by the user. We will use it
25741       # for the tool.
25742 
25743       # First remove it from the list of overridden variables, so we can test
25744       # for unknown variables in the end.
25745       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25746 
25747       # Check if the provided tool contains a complete path.
25748       tool_specified="$JAVAC"
25749       tool_basename="${tool_specified##*/}"
25750       if test "x$tool_basename" = "x$tool_specified"; then
25751         # A command without a complete path is provided, search $PATH.
25752         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAC=$tool_basename" >&5
25753 $as_echo "$as_me: Will search for user supplied tool JAVAC=$tool_basename" >&6;}
25754         # Extract the first word of "$tool_basename", so it can be a program name with args.
25755 set dummy $tool_basename; ac_word=$2
25756 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25757 $as_echo_n "checking for $ac_word... " >&6; }
25758 if ${ac_cv_path_JAVAC+:} false; then :
25759   $as_echo_n "(cached) " >&6
25760 else
25761   case $JAVAC in
25762   [\\/]* | ?:[\\/]*)
25763   ac_cv_path_JAVAC="$JAVAC" # Let the user override the test with a path.
25764   ;;
25765   *)
25766   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25767 for as_dir in $PATH
25768 do
25769   IFS=$as_save_IFS
25770   test -z "$as_dir" && as_dir=.
25771     for ac_exec_ext in '' $ac_executable_extensions; do
25772   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25773     ac_cv_path_JAVAC="$as_dir/$ac_word$ac_exec_ext"
25774     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25775     break 2
25776   fi
25777 done
25778   done
25779 IFS=$as_save_IFS
25780 
25781   ;;
25782 esac
25783 fi
25784 JAVAC=$ac_cv_path_JAVAC
25785 if test -n "$JAVAC"; then
25786   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC" >&5
25787 $as_echo "$JAVAC" >&6; }
25788 else
25789   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25790 $as_echo "no" >&6; }
25791 fi
25792 
25793 
25794         if test "x$JAVAC" = x; then
25795           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25796         fi
25797       else
25798         # Otherwise we believe it is a complete path. Use it as it is.
25799         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAC=$tool_specified" >&5
25800 $as_echo "$as_me: Will use user supplied tool JAVAC=$tool_specified" >&6;}
25801         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5
25802 $as_echo_n "checking for JAVAC... " >&6; }
25803         if test ! -x "$tool_specified"; then
25804           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25805 $as_echo "not found" >&6; }
25806           as_fn_error $? "User supplied tool JAVAC=$tool_specified does not exist or is not executable" "$LINENO" 5
25807         fi
25808         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25809 $as_echo "$tool_specified" >&6; }
25810       fi
25811     fi
25812   fi
25813 
25814 
25815 
25816   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25817 
25818   # Publish this variable in the help.
25819 
25820 
25821   if test "x$JAVAH" = x; then
25822     # The variable is not set by user, try to locate tool using the code snippet
25823 
25824       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5
25825 $as_echo_n "checking for javah in Boot JDK... " >&6; }
25826       JAVAH=$BOOT_JDK/bin/javah
25827       if test ! -x $JAVAH; then
25828         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25829 $as_echo "not found" >&6; }
25830         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25831 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25832         as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5
25833       fi
25834       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25835 $as_echo "ok" >&6; }
25836 
25837 
25838   else
25839     # The variable is set, but is it from the command line or the environment?
25840 
25841     # Try to remove the string !JAVAH! from our list.
25842     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAH!/}
25843     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25844       # If it failed, the variable was not from the command line. Ignore it,
25845       # but warn the user (except for BASH, which is always set by the calling BASH).
25846       if test "xJAVAH" != xBASH; then
25847         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&5
25848 $as_echo "$as_me: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&2;}
25849       fi
25850       # Try to locate tool using the code snippet
25851 
25852       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5
25853 $as_echo_n "checking for javah in Boot JDK... " >&6; }
25854       JAVAH=$BOOT_JDK/bin/javah
25855       if test ! -x $JAVAH; then
25856         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25857 $as_echo "not found" >&6; }
25858         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25859 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25860         as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5
25861       fi
25862       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25863 $as_echo "ok" >&6; }
25864 
25865 
25866     else
25867       # If it succeeded, then it was overridden by the user. We will use it
25868       # for the tool.
25869 
25870       # First remove it from the list of overridden variables, so we can test
25871       # for unknown variables in the end.
25872       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
25873 
25874       # Check if the provided tool contains a complete path.
25875       tool_specified="$JAVAH"
25876       tool_basename="${tool_specified##*/}"
25877       if test "x$tool_basename" = "x$tool_specified"; then
25878         # A command without a complete path is provided, search $PATH.
25879         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAH=$tool_basename" >&5
25880 $as_echo "$as_me: Will search for user supplied tool JAVAH=$tool_basename" >&6;}
25881         # Extract the first word of "$tool_basename", so it can be a program name with args.
25882 set dummy $tool_basename; ac_word=$2
25883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25884 $as_echo_n "checking for $ac_word... " >&6; }
25885 if ${ac_cv_path_JAVAH+:} false; then :
25886   $as_echo_n "(cached) " >&6
25887 else
25888   case $JAVAH in
25889   [\\/]* | ?:[\\/]*)
25890   ac_cv_path_JAVAH="$JAVAH" # Let the user override the test with a path.
25891   ;;
25892   *)
25893   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25894 for as_dir in $PATH
25895 do
25896   IFS=$as_save_IFS
25897   test -z "$as_dir" && as_dir=.
25898     for ac_exec_ext in '' $ac_executable_extensions; do
25899   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25900     ac_cv_path_JAVAH="$as_dir/$ac_word$ac_exec_ext"
25901     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25902     break 2
25903   fi
25904 done
25905   done
25906 IFS=$as_save_IFS
25907 
25908   ;;
25909 esac
25910 fi
25911 JAVAH=$ac_cv_path_JAVAH
25912 if test -n "$JAVAH"; then
25913   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAH" >&5
25914 $as_echo "$JAVAH" >&6; }
25915 else
25916   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25917 $as_echo "no" >&6; }
25918 fi
25919 
25920 
25921         if test "x$JAVAH" = x; then
25922           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
25923         fi
25924       else
25925         # Otherwise we believe it is a complete path. Use it as it is.
25926         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAH=$tool_specified" >&5
25927 $as_echo "$as_me: Will use user supplied tool JAVAH=$tool_specified" >&6;}
25928         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5
25929 $as_echo_n "checking for JAVAH... " >&6; }
25930         if test ! -x "$tool_specified"; then
25931           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25932 $as_echo "not found" >&6; }
25933           as_fn_error $? "User supplied tool JAVAH=$tool_specified does not exist or is not executable" "$LINENO" 5
25934         fi
25935         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
25936 $as_echo "$tool_specified" >&6; }
25937       fi
25938     fi
25939   fi
25940 
25941 
25942 
25943   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
25944 
25945   # Publish this variable in the help.
25946 
25947 
25948   if test "x$JAR" = x; then
25949     # The variable is not set by user, try to locate tool using the code snippet
25950 
25951       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5
25952 $as_echo_n "checking for jar in Boot JDK... " >&6; }
25953       JAR=$BOOT_JDK/bin/jar
25954       if test ! -x $JAR; then
25955         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25956 $as_echo "not found" >&6; }
25957         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25958 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25959         as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5
25960       fi
25961       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25962 $as_echo "ok" >&6; }
25963 
25964 
25965   else
25966     # The variable is set, but is it from the command line or the environment?
25967 
25968     # Try to remove the string !JAR! from our list.
25969     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAR!/}
25970     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
25971       # If it failed, the variable was not from the command line. Ignore it,
25972       # but warn the user (except for BASH, which is always set by the calling BASH).
25973       if test "xJAR" != xBASH; then
25974         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&5
25975 $as_echo "$as_me: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&2;}
25976       fi
25977       # Try to locate tool using the code snippet
25978 
25979       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5
25980 $as_echo_n "checking for jar in Boot JDK... " >&6; }
25981       JAR=$BOOT_JDK/bin/jar
25982       if test ! -x $JAR; then
25983         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
25984 $as_echo "not found" >&6; }
25985         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
25986 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
25987         as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5
25988       fi
25989       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
25990 $as_echo "ok" >&6; }
25991 
25992 
25993     else
25994       # If it succeeded, then it was overridden by the user. We will use it
25995       # for the tool.
25996 
25997       # First remove it from the list of overridden variables, so we can test
25998       # for unknown variables in the end.
25999       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
26000 
26001       # Check if the provided tool contains a complete path.
26002       tool_specified="$JAR"
26003       tool_basename="${tool_specified##*/}"
26004       if test "x$tool_basename" = "x$tool_specified"; then
26005         # A command without a complete path is provided, search $PATH.
26006         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAR=$tool_basename" >&5
26007 $as_echo "$as_me: Will search for user supplied tool JAR=$tool_basename" >&6;}
26008         # Extract the first word of "$tool_basename", so it can be a program name with args.
26009 set dummy $tool_basename; ac_word=$2
26010 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26011 $as_echo_n "checking for $ac_word... " >&6; }
26012 if ${ac_cv_path_JAR+:} false; then :
26013   $as_echo_n "(cached) " >&6
26014 else
26015   case $JAR in
26016   [\\/]* | ?:[\\/]*)
26017   ac_cv_path_JAR="$JAR" # Let the user override the test with a path.
26018   ;;
26019   *)
26020   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26021 for as_dir in $PATH
26022 do
26023   IFS=$as_save_IFS
26024   test -z "$as_dir" && as_dir=.
26025     for ac_exec_ext in '' $ac_executable_extensions; do
26026   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26027     ac_cv_path_JAR="$as_dir/$ac_word$ac_exec_ext"
26028     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26029     break 2
26030   fi
26031 done
26032   done
26033 IFS=$as_save_IFS
26034 
26035   ;;
26036 esac
26037 fi
26038 JAR=$ac_cv_path_JAR
26039 if test -n "$JAR"; then
26040   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAR" >&5
26041 $as_echo "$JAR" >&6; }
26042 else
26043   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26044 $as_echo "no" >&6; }
26045 fi
26046 
26047 
26048         if test "x$JAR" = x; then
26049           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
26050         fi
26051       else
26052         # Otherwise we believe it is a complete path. Use it as it is.
26053         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAR=$tool_specified" >&5
26054 $as_echo "$as_me: Will use user supplied tool JAR=$tool_specified" >&6;}
26055         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5
26056 $as_echo_n "checking for JAR... " >&6; }
26057         if test ! -x "$tool_specified"; then
26058           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
26059 $as_echo "not found" >&6; }
26060           as_fn_error $? "User supplied tool JAR=$tool_specified does not exist or is not executable" "$LINENO" 5
26061         fi
26062         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
26063 $as_echo "$tool_specified" >&6; }
26064       fi
26065     fi
26066   fi
26067 
26068 
26069 
26070   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
26071 
26072   # Publish this variable in the help.
26073 
26074 
26075   if test "x$NATIVE2ASCII" = x; then
26076     # The variable is not set by user, try to locate tool using the code snippet
26077 
26078       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for native2ascii in Boot JDK" >&5
26079 $as_echo_n "checking for native2ascii in Boot JDK... " >&6; }
26080       NATIVE2ASCII=$BOOT_JDK/bin/native2ascii
26081       if test ! -x $NATIVE2ASCII; then
26082         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
26083 $as_echo "not found" >&6; }
26084         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
26085 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
26086         as_fn_error $? "Could not find native2ascii in the Boot JDK" "$LINENO" 5
26087       fi
26088       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
26089 $as_echo "ok" >&6; }
26090 
26091 
26092   else
26093     # The variable is set, but is it from the command line or the environment?
26094 
26095     # Try to remove the string !NATIVE2ASCII! from our list.
26096     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NATIVE2ASCII!/}
26097     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
26098       # If it failed, the variable was not from the command line. Ignore it,
26099       # but warn the user (except for BASH, which is always set by the calling BASH).
26100       if test "xNATIVE2ASCII" != xBASH; then
26101         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NATIVE2ASCII from the environment. Use command line variables instead." >&5
26102 $as_echo "$as_me: WARNING: Ignoring value of NATIVE2ASCII from the environment. Use command line variables instead." >&2;}
26103       fi
26104       # Try to locate tool using the code snippet
26105 
26106       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for native2ascii in Boot JDK" >&5
26107 $as_echo_n "checking for native2ascii in Boot JDK... " >&6; }
26108       NATIVE2ASCII=$BOOT_JDK/bin/native2ascii
26109       if test ! -x $NATIVE2ASCII; then
26110         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
26111 $as_echo "not found" >&6; }
26112         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
26113 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
26114         as_fn_error $? "Could not find native2ascii in the Boot JDK" "$LINENO" 5
26115       fi
26116       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
26117 $as_echo "ok" >&6; }
26118 
26119 
26120     else
26121       # If it succeeded, then it was overridden by the user. We will use it
26122       # for the tool.
26123 
26124       # First remove it from the list of overridden variables, so we can test
26125       # for unknown variables in the end.
26126       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
26127 
26128       # Check if the provided tool contains a complete path.
26129       tool_specified="$NATIVE2ASCII"
26130       tool_basename="${tool_specified##*/}"
26131       if test "x$tool_basename" = "x$tool_specified"; then
26132         # A command without a complete path is provided, search $PATH.
26133         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NATIVE2ASCII=$tool_basename" >&5
26134 $as_echo "$as_me: Will search for user supplied tool NATIVE2ASCII=$tool_basename" >&6;}
26135         # Extract the first word of "$tool_basename", so it can be a program name with args.
26136 set dummy $tool_basename; ac_word=$2
26137 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26138 $as_echo_n "checking for $ac_word... " >&6; }
26139 if ${ac_cv_path_NATIVE2ASCII+:} false; then :
26140   $as_echo_n "(cached) " >&6
26141 else
26142   case $NATIVE2ASCII in
26143   [\\/]* | ?:[\\/]*)
26144   ac_cv_path_NATIVE2ASCII="$NATIVE2ASCII" # Let the user override the test with a path.
26145   ;;
26146   *)
26147   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26148 for as_dir in $PATH
26149 do
26150   IFS=$as_save_IFS
26151   test -z "$as_dir" && as_dir=.
26152     for ac_exec_ext in '' $ac_executable_extensions; do
26153   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26154     ac_cv_path_NATIVE2ASCII="$as_dir/$ac_word$ac_exec_ext"
26155     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26156     break 2
26157   fi
26158 done
26159   done
26160 IFS=$as_save_IFS
26161 
26162   ;;
26163 esac
26164 fi
26165 NATIVE2ASCII=$ac_cv_path_NATIVE2ASCII
26166 if test -n "$NATIVE2ASCII"; then
26167   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NATIVE2ASCII" >&5
26168 $as_echo "$NATIVE2ASCII" >&6; }
26169 else
26170   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26171 $as_echo "no" >&6; }
26172 fi
26173 
26174 
26175         if test "x$NATIVE2ASCII" = x; then
26176           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
26177         fi
26178       else
26179         # Otherwise we believe it is a complete path. Use it as it is.
26180         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NATIVE2ASCII=$tool_specified" >&5
26181 $as_echo "$as_me: Will use user supplied tool NATIVE2ASCII=$tool_specified" >&6;}
26182         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NATIVE2ASCII" >&5
26183 $as_echo_n "checking for NATIVE2ASCII... " >&6; }
26184         if test ! -x "$tool_specified"; then
26185           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
26186 $as_echo "not found" >&6; }
26187           as_fn_error $? "User supplied tool NATIVE2ASCII=$tool_specified does not exist or is not executable" "$LINENO" 5
26188         fi
26189         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
26190 $as_echo "$tool_specified" >&6; }
26191       fi
26192     fi
26193   fi
26194 
26195 
26196 
26197   # Use user overridden value if available, otherwise locate tool in the Boot JDK.
26198 
26199   # Publish this variable in the help.
26200 
26201 
26202   if test "x$JARSIGNER" = x; then
26203     # The variable is not set by user, try to locate tool using the code snippet
26204 
26205       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5
26206 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; }
26207       JARSIGNER=$BOOT_JDK/bin/jarsigner
26208       if test ! -x $JARSIGNER; then
26209         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
26210 $as_echo "not found" >&6; }
26211         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
26212 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
26213         as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5
26214       fi
26215       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
26216 $as_echo "ok" >&6; }
26217 
26218 
26219   else
26220     # The variable is set, but is it from the command line or the environment?
26221 
26222     # Try to remove the string !JARSIGNER! from our list.
26223     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JARSIGNER!/}
26224     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
26225       # If it failed, the variable was not from the command line. Ignore it,
26226       # but warn the user (except for BASH, which is always set by the calling BASH).
26227       if test "xJARSIGNER" != xBASH; then
26228         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&5
26229 $as_echo "$as_me: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&2;}
26230       fi
26231       # Try to locate tool using the code snippet
26232 
26233       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5
26234 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; }
26235       JARSIGNER=$BOOT_JDK/bin/jarsigner
26236       if test ! -x $JARSIGNER; then
26237         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
26238 $as_echo "not found" >&6; }
26239         { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5
26240 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;}
26241         as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5
26242       fi
26243       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
26244 $as_echo "ok" >&6; }
26245 
26246 
26247     else
26248       # If it succeeded, then it was overridden by the user. We will use it
26249       # for the tool.
26250 
26251       # First remove it from the list of overridden variables, so we can test
26252       # for unknown variables in the end.
26253       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
26254 
26255       # Check if the provided tool contains a complete path.
26256       tool_specified="$JARSIGNER"
26257       tool_basename="${tool_specified##*/}"
26258       if test "x$tool_basename" = "x$tool_specified"; then
26259         # A command without a complete path is provided, search $PATH.
26260         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JARSIGNER=$tool_basename" >&5
26261 $as_echo "$as_me: Will search for user supplied tool JARSIGNER=$tool_basename" >&6;}
26262         # Extract the first word of "$tool_basename", so it can be a program name with args.
26263 set dummy $tool_basename; ac_word=$2
26264 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26265 $as_echo_n "checking for $ac_word... " >&6; }
26266 if ${ac_cv_path_JARSIGNER+:} false; then :
26267   $as_echo_n "(cached) " >&6
26268 else
26269   case $JARSIGNER in
26270   [\\/]* | ?:[\\/]*)
26271   ac_cv_path_JARSIGNER="$JARSIGNER" # Let the user override the test with a path.
26272   ;;
26273   *)
26274   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26275 for as_dir in $PATH
26276 do
26277   IFS=$as_save_IFS
26278   test -z "$as_dir" && as_dir=.
26279     for ac_exec_ext in '' $ac_executable_extensions; do
26280   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26281     ac_cv_path_JARSIGNER="$as_dir/$ac_word$ac_exec_ext"
26282     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26283     break 2
26284   fi
26285 done
26286   done
26287 IFS=$as_save_IFS
26288 
26289   ;;
26290 esac
26291 fi
26292 JARSIGNER=$ac_cv_path_JARSIGNER
26293 if test -n "$JARSIGNER"; then
26294   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JARSIGNER" >&5
26295 $as_echo "$JARSIGNER" >&6; }
26296 else
26297   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26298 $as_echo "no" >&6; }
26299 fi
26300 
26301 
26302         if test "x$JARSIGNER" = x; then
26303           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
26304         fi
26305       else
26306         # Otherwise we believe it is a complete path. Use it as it is.
26307         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JARSIGNER=$tool_specified" >&5
26308 $as_echo "$as_me: Will use user supplied tool JARSIGNER=$tool_specified" >&6;}
26309         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5
26310 $as_echo_n "checking for JARSIGNER... " >&6; }
26311         if test ! -x "$tool_specified"; then
26312           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
26313 $as_echo "not found" >&6; }
26314           as_fn_error $? "User supplied tool JARSIGNER=$tool_specified does not exist or is not executable" "$LINENO" 5
26315         fi
26316         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
26317 $as_echo "$tool_specified" >&6; }
26318       fi
26319     fi
26320   fi
26321 
26322 
26323 
26324   # Finally, set some other options...
26325 
26326   # When compiling code to be executed by the Boot JDK, force jdk8 compatibility.
26327   BOOT_JDK_SOURCETARGET="-source 8 -target 8"
26328 
26329 
26330 
26331 
26332 ###############################################################################
26333 #
26334 # Configure the sources to use. We can add or override individual directories.
26335 #
26336 ###############################################################################
26337 
26338 
26339   # Where are the sources. Any of these can be overridden
26340   # using --with-override-corba and the likes.
26341   LANGTOOLS_TOPDIR="$SRC_ROOT/langtools"
26342   CORBA_TOPDIR="$SRC_ROOT/corba"
26343   JAXP_TOPDIR="$SRC_ROOT/jaxp"
26344   JAXWS_TOPDIR="$SRC_ROOT/jaxws"
26345   HOTSPOT_TOPDIR="$SRC_ROOT/hotspot"
26346   NASHORN_TOPDIR="$SRC_ROOT/nashorn"
26347   JDK_TOPDIR="$SRC_ROOT/jdk"
26348 
26349 
26350 
26351 
26352 
26353 
26354 
26355 
26356 
26357 
26358   ###############################################################################
26359   #
26360   # Pickup additional source for a component from outside of the source root
26361   # or override source for a component.
26362   #
26363 
26364 # Check whether --with-add-source-root was given.
26365 if test "${with_add_source_root+set}" = set; then :
26366   withval=$with_add_source_root;
26367 fi
26368 
26369 
26370 
26371 # Check whether --with-override-source-root was given.
26372 if test "${with_override_source_root+set}" = set; then :
26373   withval=$with_override_source_root;
26374 fi
26375 
26376 
26377 
26378 # Check whether --with-adds-and-overrides was given.
26379 if test "${with_adds_and_overrides+set}" = set; then :
26380   withval=$with_adds_and_overrides;
26381 fi
26382 
26383 
26384   if test "x$with_adds_and_overrides" != x; then
26385     with_add_source_root="$with_adds_and_overrides/adds"
26386     with_override_source_root="$with_adds_and_overrides/overrides"
26387   fi
26388 
26389   if test "x$with_add_source_root" != x; then
26390     if ! test -d $with_add_source_root; then
26391       as_fn_error $? "Trying to use a non-existant add-source-root $with_add_source_root" "$LINENO" 5
26392     fi
26393     CURDIR="$PWD"
26394     cd "$with_add_source_root"
26395     ADD_SRC_ROOT="`pwd`"
26396     cd "$CURDIR"
26397     # Verify that the addon source root does not have any root makefiles.
26398     # If it does, then it is usually an error, prevent this.
26399     if test -f $with_add_source_root/langtools/make/Makefile; then
26400       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
26401     fi
26402     if test -f $with_add_source_root/corba/make/Makefile; then
26403       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
26404     fi
26405     if test -f $with_add_source_root/jaxp/make/Makefile; then
26406       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
26407     fi
26408     if test -f $with_add_source_root/jaxws/make/Makefile; then
26409       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
26410     fi
26411     if test -f $with_add_source_root/hotspot/make/Makefile; then
26412       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
26413     fi
26414     if test -f $with_add_source_root/nashorn/make/Makefile; then
26415       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
26416     fi
26417     if test -f $with_add_source_root/jdk/make/Makefile; then
26418       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
26419     fi
26420   fi
26421 
26422 
26423   if test "x$with_override_source_root" != x; then
26424     if ! test -d $with_override_source_root; then
26425       as_fn_error $? "Trying to use a non-existant override-source-root $with_override_source_root" "$LINENO" 5
26426     fi
26427     CURDIR="$PWD"
26428     cd "$with_override_source_root"
26429     OVERRIDE_SRC_ROOT="`pwd`"
26430     cd "$CURDIR"
26431     if test -f $with_override_source_root/langtools/make/Makefile; then
26432       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
26433     fi
26434     if test -f $with_override_source_root/corba/make/Makefile; then
26435       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
26436     fi
26437     if test -f $with_override_source_root/jaxp/make/Makefile; then
26438       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
26439     fi
26440     if test -f $with_override_source_root/jaxws/make/Makefile; then
26441       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
26442     fi
26443     if test -f $with_override_source_root/hotspot/make/Makefile; then
26444       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
26445     fi
26446     if test -f $with_override_source_root/nashorn/make/Makefile; then
26447       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
26448     fi
26449     if test -f $with_override_source_root/jdk/make/Makefile; then
26450       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
26451     fi
26452   fi
26453 
26454 
26455   ###############################################################################
26456   #
26457   # Override a repo completely, this is used for example when you have 3 small
26458   # development sandboxes of the langtools sources and want to avoid having 3 full
26459   # OpenJDK sources checked out on disk.
26460   #
26461   # Assuming that the 3 langtools sandboxes are located here:
26462   # /home/fredrik/sandbox1/langtools
26463   # /home/fredrik/sandbox2/langtools
26464   # /home/fredrik/sandbox3/langtools
26465   #
26466   # From the source root you create build subdirs manually:
26467   #     mkdir -p build1 build2 build3
26468   # in each build directory run:
26469   #     (cd build1 && ../configure --with-override-langtools=/home/fredrik/sandbox1 && make)
26470   #     (cd build2 && ../configure --with-override-langtools=/home/fredrik/sandbox2 && make)
26471   #     (cd build3 && ../configure --with-override-langtools=/home/fredrik/sandbox3 && make)
26472   #
26473 
26474 
26475 # Check whether --with-override-langtools was given.
26476 if test "${with_override_langtools+set}" = set; then :
26477   withval=$with_override_langtools;
26478 fi
26479 
26480 
26481 
26482 # Check whether --with-override-corba was given.
26483 if test "${with_override_corba+set}" = set; then :
26484   withval=$with_override_corba;
26485 fi
26486 
26487 
26488 
26489 # Check whether --with-override-jaxp was given.
26490 if test "${with_override_jaxp+set}" = set; then :
26491   withval=$with_override_jaxp;
26492 fi
26493 
26494 
26495 
26496 # Check whether --with-override-jaxws was given.
26497 if test "${with_override_jaxws+set}" = set; then :
26498   withval=$with_override_jaxws;
26499 fi
26500 
26501 
26502 
26503 # Check whether --with-override-hotspot was given.
26504 if test "${with_override_hotspot+set}" = set; then :
26505   withval=$with_override_hotspot;
26506 fi
26507 
26508 
26509 
26510 # Check whether --with-override-nashorn was given.
26511 if test "${with_override_nashorn+set}" = set; then :
26512   withval=$with_override_nashorn;
26513 fi
26514 
26515 
26516 
26517 # Check whether --with-override-jdk was given.
26518 if test "${with_override_jdk+set}" = set; then :
26519   withval=$with_override_jdk;
26520 fi
26521 
26522 
26523   if test "x$with_override_langtools" != x; then
26524     CURDIR="$PWD"
26525     cd "$with_override_langtools"
26526     LANGTOOLS_TOPDIR="`pwd`"
26527     cd "$CURDIR"
26528     if ! test -f $LANGTOOLS_TOPDIR/make/Makefile; then
26529       as_fn_error $? "You have to override langtools with a full langtools repo!" "$LINENO" 5
26530     fi
26531     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if langtools should be overridden" >&5
26532 $as_echo_n "checking if langtools should be overridden... " >&6; }
26533     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $LANGTOOLS_TOPDIR" >&5
26534 $as_echo "yes with $LANGTOOLS_TOPDIR" >&6; }
26535   fi
26536   if test "x$with_override_corba" != x; then
26537     CURDIR="$PWD"
26538     cd "$with_override_corba"
26539     CORBA_TOPDIR="`pwd`"
26540     cd "$CURDIR"
26541     if ! test -f $CORBA_TOPDIR/make/Makefile; then
26542       as_fn_error $? "You have to override corba with a full corba repo!" "$LINENO" 5
26543     fi
26544     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if corba should be overridden" >&5
26545 $as_echo_n "checking if corba should be overridden... " >&6; }
26546     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $CORBA_TOPDIR" >&5
26547 $as_echo "yes with $CORBA_TOPDIR" >&6; }
26548   fi
26549   if test "x$with_override_jaxp" != x; then
26550     CURDIR="$PWD"
26551     cd "$with_override_jaxp"
26552     JAXP_TOPDIR="`pwd`"
26553     cd "$CURDIR"
26554     if ! test -f $JAXP_TOPDIR/make/Makefile; then
26555       as_fn_error $? "You have to override jaxp with a full jaxp repo!" "$LINENO" 5
26556     fi
26557     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jaxp should be overridden" >&5
26558 $as_echo_n "checking if jaxp should be overridden... " >&6; }
26559     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JAXP_TOPDIR" >&5
26560 $as_echo "yes with $JAXP_TOPDIR" >&6; }
26561   fi
26562   if test "x$with_override_jaxws" != x; then
26563     CURDIR="$PWD"
26564     cd "$with_override_jaxws"
26565     JAXWS_TOPDIR="`pwd`"
26566     cd "$CURDIR"
26567     if ! test -f $JAXWS_TOPDIR/make/Makefile; then
26568       as_fn_error $? "You have to override jaxws with a full jaxws repo!" "$LINENO" 5
26569     fi
26570     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jaxws should be overridden" >&5
26571 $as_echo_n "checking if jaxws should be overridden... " >&6; }
26572     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JAXWS_TOPDIR" >&5
26573 $as_echo "yes with $JAXWS_TOPDIR" >&6; }
26574   fi
26575   if test "x$with_override_hotspot" != x; then
26576     CURDIR="$PWD"
26577     cd "$with_override_hotspot"
26578     HOTSPOT_TOPDIR="`pwd`"
26579     cd "$CURDIR"
26580     if ! test -f $HOTSPOT_TOPDIR/make/Makefile; then
26581       as_fn_error $? "You have to override hotspot with a full hotspot repo!" "$LINENO" 5
26582     fi
26583     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be overridden" >&5
26584 $as_echo_n "checking if hotspot should be overridden... " >&6; }
26585     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $HOTSPOT_TOPDIR" >&5
26586 $as_echo "yes with $HOTSPOT_TOPDIR" >&6; }
26587   fi
26588   if test "x$with_override_nashorn" != x; then
26589     CURDIR="$PWD"
26590     cd "$with_override_nashorn"
26591     NASHORN_TOPDIR="`pwd`"
26592     cd "$CURDIR"
26593     if ! test -f $NASHORN_TOPDIR/make/Makefile; then
26594       as_fn_error $? "You have to override nashorn with a full nashorn repo!" "$LINENO" 5
26595     fi
26596     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if nashorn should be overridden" >&5
26597 $as_echo_n "checking if nashorn should be overridden... " >&6; }
26598     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $NASHORN_TOPDIR" >&5
26599 $as_echo "yes with $NASHORN_TOPDIR" >&6; }
26600   fi
26601   if test "x$with_override_jdk" != x; then
26602     CURDIR="$PWD"
26603     cd "$with_override_jdk"
26604     JDK_TOPDIR="`pwd`"
26605     cd "$CURDIR"
26606     if ! test -f $JDK_TOPDIR/make/Makefile; then
26607       as_fn_error $? "You have to override JDK with a full JDK repo!" "$LINENO" 5
26608     fi
26609     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if JDK should be overridden" >&5
26610 $as_echo_n "checking if JDK should be overridden... " >&6; }
26611     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes with $JDK_TOPDIR" >&5
26612 $as_echo "yes with $JDK_TOPDIR" >&6; }
26613   fi
26614 
26615 
26616   BUILD_OUTPUT="$OUTPUT_ROOT"
26617 
26618 
26619   HOTSPOT_DIST="$OUTPUT_ROOT/hotspot/dist"
26620   BUILD_HOTSPOT=true
26621 
26622 
26623 
26624 # Check whether --with-import-hotspot was given.
26625 if test "${with_import_hotspot+set}" = set; then :
26626   withval=$with_import_hotspot;
26627 fi
26628 
26629   if test "x$with_import_hotspot" != x; then
26630     CURDIR="$PWD"
26631     cd "$with_import_hotspot"
26632     HOTSPOT_DIST="`pwd`"
26633     cd "$CURDIR"
26634     if ! (test -d $HOTSPOT_DIST/lib && test -d $HOTSPOT_DIST/jre/lib); then
26635       as_fn_error $? "You have to import hotspot from a full jdk image or hotspot build dist dir!" "$LINENO" 5
26636     fi
26637     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be imported" >&5
26638 $as_echo_n "checking if hotspot should be imported... " >&6; }
26639     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes from $HOTSPOT_DIST" >&5
26640 $as_echo "yes from $HOTSPOT_DIST" >&6; }
26641     BUILD_HOTSPOT=false
26642   fi
26643 
26644   JDK_OUTPUTDIR="$OUTPUT_ROOT/jdk"
26645 
26646 
26647 ###############################################################################
26648 #
26649 # Setup the toolchain (compilers etc), i.e. tools used to compile and process
26650 # native code.
26651 #
26652 ###############################################################################
26653 
26654 # First determine the toolchain type (compiler family)
26655 
26656 
26657 # Check whether --with-toolchain-type was given.
26658 if test "${with_toolchain_type+set}" = set; then :
26659   withval=$with_toolchain_type;
26660 fi
26661 
26662 
26663   # Use indirect variable referencing
26664   toolchain_var_name=VALID_TOOLCHAINS_$OPENJDK_BUILD_OS
26665   VALID_TOOLCHAINS=${!toolchain_var_name}
26666 
26667   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
26668     if test -n "$XCODEBUILD"; then
26669       # On Mac OS X, default toolchain to clang after Xcode 5
26670       XCODE_VERSION_OUTPUT=`"$XCODEBUILD" -version 2>&1 | $HEAD -n 1`
26671       $ECHO "$XCODE_VERSION_OUTPUT" | $GREP "Xcode " > /dev/null
26672       if test $? -ne 0; then
26673         as_fn_error $? "Failed to determine Xcode version." "$LINENO" 5
26674       fi
26675       XCODE_MAJOR_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | \
26676           $SED -e 's/^Xcode \([1-9][0-9.]*\)/\1/' | \
26677           $CUT -f 1 -d .`
26678       { $as_echo "$as_me:${as_lineno-$LINENO}: Xcode major version: $XCODE_MAJOR_VERSION" >&5
26679 $as_echo "$as_me: Xcode major version: $XCODE_MAJOR_VERSION" >&6;}
26680       if test $XCODE_MAJOR_VERSION -ge 5; then
26681           DEFAULT_TOOLCHAIN="clang"
26682       else
26683           DEFAULT_TOOLCHAIN="gcc"
26684       fi
26685     else
26686       # If Xcode is not installed, but the command line tools are
26687       # then we can't run xcodebuild. On these systems we should
26688       # default to clang
26689       DEFAULT_TOOLCHAIN="clang"
26690     fi
26691   else
26692     # First toolchain type in the list is the default
26693     DEFAULT_TOOLCHAIN=${VALID_TOOLCHAINS%% *}
26694   fi
26695 
26696   if test "x$with_toolchain_type" = xlist; then
26697     # List all toolchains
26698     { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchains are valid on this platform:" >&5
26699 $as_echo "$as_me: The following toolchains are valid on this platform:" >&6;}
26700     for toolchain in $VALID_TOOLCHAINS; do
26701       toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain
26702       TOOLCHAIN_DESCRIPTION=${!toolchain_var_name}
26703       $PRINTF "  %-10s  %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION"
26704     done
26705 
26706     exit 0
26707   elif test "x$with_toolchain_type" != x; then
26708     # User override; check that it is valid
26709     if test "x${VALID_TOOLCHAINS/$with_toolchain_type/}" = "x${VALID_TOOLCHAINS}"; then
26710       { $as_echo "$as_me:${as_lineno-$LINENO}: Toolchain type $with_toolchain_type is not valid on this platform." >&5
26711 $as_echo "$as_me: Toolchain type $with_toolchain_type is not valid on this platform." >&6;}
26712       { $as_echo "$as_me:${as_lineno-$LINENO}: Valid toolchains: $VALID_TOOLCHAINS." >&5
26713 $as_echo "$as_me: Valid toolchains: $VALID_TOOLCHAINS." >&6;}
26714       as_fn_error $? "Cannot continue." "$LINENO" 5
26715     fi
26716     TOOLCHAIN_TYPE=$with_toolchain_type
26717   else
26718     # No flag given, use default
26719     TOOLCHAIN_TYPE=$DEFAULT_TOOLCHAIN
26720   fi
26721 
26722 
26723   TOOLCHAIN_CC_BINARY_clang="clang"
26724   TOOLCHAIN_CC_BINARY_gcc="gcc"
26725   TOOLCHAIN_CC_BINARY_microsoft="cl"
26726   TOOLCHAIN_CC_BINARY_solstudio="cc"
26727   TOOLCHAIN_CC_BINARY_xlc="xlc_r"
26728 
26729   TOOLCHAIN_CXX_BINARY_clang="clang++"
26730   TOOLCHAIN_CXX_BINARY_gcc="g++"
26731   TOOLCHAIN_CXX_BINARY_microsoft="cl"
26732   TOOLCHAIN_CXX_BINARY_solstudio="CC"
26733   TOOLCHAIN_CXX_BINARY_xlc="xlC_r"
26734 
26735   # Use indirect variable referencing
26736   toolchain_var_name=TOOLCHAIN_DESCRIPTION_$TOOLCHAIN_TYPE
26737   TOOLCHAIN_DESCRIPTION=${!toolchain_var_name}
26738   toolchain_var_name=TOOLCHAIN_CC_BINARY_$TOOLCHAIN_TYPE
26739   TOOLCHAIN_CC_BINARY=${!toolchain_var_name}
26740   toolchain_var_name=TOOLCHAIN_CXX_BINARY_$TOOLCHAIN_TYPE
26741   TOOLCHAIN_CXX_BINARY=${!toolchain_var_name}
26742 
26743 
26744   # Define filename patterns
26745   if test "x$OPENJDK_TARGET_OS" = xwindows; then
26746     LIBRARY_PREFIX=
26747     SHARED_LIBRARY_SUFFIX='.dll'
26748     STATIC_LIBRARY_SUFFIX='.lib'
26749     SHARED_LIBRARY='$1.dll'
26750     STATIC_LIBRARY='$1.lib'
26751     OBJ_SUFFIX='.obj'
26752     EXE_SUFFIX='.exe'
26753   else
26754     LIBRARY_PREFIX=lib
26755     SHARED_LIBRARY_SUFFIX='.so'
26756     STATIC_LIBRARY_SUFFIX='.a'
26757     SHARED_LIBRARY='lib$1.so'
26758     STATIC_LIBRARY='lib$1.a'
26759     OBJ_SUFFIX='.o'
26760     EXE_SUFFIX=''
26761     if test "x$OPENJDK_TARGET_OS" = xmacosx; then
26762       SHARED_LIBRARY='lib$1.dylib'
26763       SHARED_LIBRARY_SUFFIX='.dylib'
26764     fi
26765   fi
26766 
26767 
26768 
26769 
26770 
26771 
26772 
26773 
26774 
26775 
26776   if test "x$TOOLCHAIN_TYPE" = "x$DEFAULT_TOOLCHAIN"; then
26777     { $as_echo "$as_me:${as_lineno-$LINENO}: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&5
26778 $as_echo "$as_me: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&6;}
26779   else
26780     { $as_echo "$as_me:${as_lineno-$LINENO}: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&5
26781 $as_echo "$as_me: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&6;}
26782   fi
26783 
26784 
26785 # Then detect the actual binaries needed
26786 
26787   # FIXME: Is this needed?
26788   ac_ext=cpp
26789 ac_cpp='$CXXCPP $CPPFLAGS'
26790 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
26791 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
26792 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
26793 
26794 
26795   # Store the CFLAGS etc passed to the configure script.
26796   ORG_CFLAGS="$CFLAGS"
26797   ORG_CXXFLAGS="$CXXFLAGS"
26798   ORG_OBJCFLAGS="$OBJCFLAGS"
26799 
26800   # On Windows, we need to detect the visual studio installation first.
26801   # This will change the PATH, but we need to keep that new PATH even
26802   # after toolchain detection is done, since the compiler (on x86) uses
26803   # it for DLL resolution in runtime.
26804   if test "x$OPENJDK_BUILD_OS" = "xwindows" && test "x$TOOLCHAIN_TYPE" = "xmicrosoft"; then
26805 
26806   # Store path to cygwin link.exe to help excluding it when searching for
26807   # VS linker. This must be done before changing the PATH when looking for VS.
26808   # Extract the first word of "link", so it can be a program name with args.
26809 set dummy link; ac_word=$2
26810 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26811 $as_echo_n "checking for $ac_word... " >&6; }
26812 if ${ac_cv_path_CYGWIN_LINK+:} false; then :
26813   $as_echo_n "(cached) " >&6
26814 else
26815   case $CYGWIN_LINK in
26816   [\\/]* | ?:[\\/]*)
26817   ac_cv_path_CYGWIN_LINK="$CYGWIN_LINK" # Let the user override the test with a path.
26818   ;;
26819   *)
26820   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26821 for as_dir in $PATH
26822 do
26823   IFS=$as_save_IFS
26824   test -z "$as_dir" && as_dir=.
26825     for ac_exec_ext in '' $ac_executable_extensions; do
26826   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26827     ac_cv_path_CYGWIN_LINK="$as_dir/$ac_word$ac_exec_ext"
26828     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26829     break 2
26830   fi
26831 done
26832   done
26833 IFS=$as_save_IFS
26834 
26835   ;;
26836 esac
26837 fi
26838 CYGWIN_LINK=$ac_cv_path_CYGWIN_LINK
26839 if test -n "$CYGWIN_LINK"; then
26840   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_LINK" >&5
26841 $as_echo "$CYGWIN_LINK" >&6; }
26842 else
26843   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26844 $as_echo "no" >&6; }
26845 fi
26846 
26847 
26848   if test "x$CYGWIN_LINK" != x; then
26849     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the first found link.exe is actually the Cygwin link tool" >&5
26850 $as_echo_n "checking if the first found link.exe is actually the Cygwin link tool... " >&6; }
26851     "$CYGWIN_LINK" --version > /dev/null
26852     if test $? -eq 0 ; then
26853       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26854 $as_echo "yes" >&6; }
26855     else
26856       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26857 $as_echo "no" >&6; }
26858       # This might be the VS linker. Don't exclude it later on.
26859       CYGWIN_LINK=""
26860     fi
26861   fi
26862 
26863   # First-hand choice is to locate and run the vsvars bat file.
26864 
26865   if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
26866     VCVARSFILE="vc/bin/vcvars32.bat"
26867   else
26868     VCVARSFILE="vc/bin/amd64/vcvars64.bat"
26869   fi
26870 
26871   VS_ENV_CMD=""
26872   VS_ENV_ARGS=""
26873   if test "x$with_toolsdir" != x; then
26874 
26875   if test "x$VS_ENV_CMD" = x; then
26876     VS100BASE="$with_toolsdir/../.."
26877     METHOD="--with-tools-dir"
26878 
26879   windows_path="$VS100BASE"
26880   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26881     unix_path=`$CYGPATH -u "$windows_path"`
26882     VS100BASE="$unix_path"
26883   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26884     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26885     VS100BASE="$unix_path"
26886   fi
26887 
26888     if test -d "$VS100BASE"; then
26889       if test -f "$VS100BASE/$VCVARSFILE"; then
26890         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26891 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26892         VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26893         # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see
26894         # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013
26895         # TODO: improve detection for other versions of VS
26896         PLATFORM_TOOLSET="v100"
26897       else
26898         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26899 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26900         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26901 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26902       fi
26903     fi
26904   fi
26905 
26906   fi
26907 
26908   if test "x$with_toolsdir" != x && test "x$VS_ENV_CMD" = x; then
26909     # Having specified an argument which is incorrect will produce an instant failure;
26910     # we should not go on looking
26911     { $as_echo "$as_me:${as_lineno-$LINENO}: The path given by --with-tools-dir does not contain a valid Visual Studio installation" >&5
26912 $as_echo "$as_me: The path given by --with-tools-dir does not contain a valid Visual Studio installation" >&6;}
26913     { $as_echo "$as_me:${as_lineno-$LINENO}: Please point to the VC/bin directory within the Visual Studio installation" >&5
26914 $as_echo "$as_me: Please point to the VC/bin directory within the Visual Studio installation" >&6;}
26915     as_fn_error $? "Cannot locate a valid Visual Studio installation" "$LINENO" 5
26916   fi
26917 
26918   if test "x$VS100COMNTOOLS" != x; then
26919 
26920   if test "x$VS_ENV_CMD" = x; then
26921     VS100BASE="$VS100COMNTOOLS/../.."
26922     METHOD="VS100COMNTOOLS variable"
26923 
26924   windows_path="$VS100BASE"
26925   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26926     unix_path=`$CYGPATH -u "$windows_path"`
26927     VS100BASE="$unix_path"
26928   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26929     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26930     VS100BASE="$unix_path"
26931   fi
26932 
26933     if test -d "$VS100BASE"; then
26934       if test -f "$VS100BASE/$VCVARSFILE"; then
26935         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26936 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26937         VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26938         # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see
26939         # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013
26940         # TODO: improve detection for other versions of VS
26941         PLATFORM_TOOLSET="v100"
26942       else
26943         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26944 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26945         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26946 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26947       fi
26948     fi
26949   fi
26950 
26951   fi
26952   if test "x$PROGRAMFILES" != x; then
26953 
26954   if test "x$VS_ENV_CMD" = x; then
26955     VS100BASE="$PROGRAMFILES/Microsoft Visual Studio 10.0"
26956     METHOD="well-known name"
26957 
26958   windows_path="$VS100BASE"
26959   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26960     unix_path=`$CYGPATH -u "$windows_path"`
26961     VS100BASE="$unix_path"
26962   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26963     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26964     VS100BASE="$unix_path"
26965   fi
26966 
26967     if test -d "$VS100BASE"; then
26968       if test -f "$VS100BASE/$VCVARSFILE"; then
26969         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26970 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26971         VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
26972         # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see
26973         # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013
26974         # TODO: improve detection for other versions of VS
26975         PLATFORM_TOOLSET="v100"
26976       else
26977         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
26978 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
26979         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
26980 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
26981       fi
26982     fi
26983   fi
26984 
26985   fi
26986 
26987   if test "x$VS_ENV_CMD" = x; then
26988     VS100BASE="C:/Program Files/Microsoft Visual Studio 10.0"
26989     METHOD="well-known name"
26990 
26991   windows_path="$VS100BASE"
26992   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
26993     unix_path=`$CYGPATH -u "$windows_path"`
26994     VS100BASE="$unix_path"
26995   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
26996     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
26997     VS100BASE="$unix_path"
26998   fi
26999 
27000     if test -d "$VS100BASE"; then
27001       if test -f "$VS100BASE/$VCVARSFILE"; then
27002         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
27003 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
27004         VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
27005         # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see
27006         # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013
27007         # TODO: improve detection for other versions of VS
27008         PLATFORM_TOOLSET="v100"
27009       else
27010         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
27011 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
27012         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
27013 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
27014       fi
27015     fi
27016   fi
27017 
27018 
27019   if test "x$VS_ENV_CMD" = x; then
27020     VS100BASE="C:/Program Files (x86)/Microsoft Visual Studio 10.0"
27021     METHOD="well-known name"
27022 
27023   windows_path="$VS100BASE"
27024   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27025     unix_path=`$CYGPATH -u "$windows_path"`
27026     VS100BASE="$unix_path"
27027   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27028     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27029     VS100BASE="$unix_path"
27030   fi
27031 
27032     if test -d "$VS100BASE"; then
27033       if test -f "$VS100BASE/$VCVARSFILE"; then
27034         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
27035 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
27036         VS_ENV_CMD="$VS100BASE/$VCVARSFILE"
27037         # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see
27038         # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013
27039         # TODO: improve detection for other versions of VS
27040         PLATFORM_TOOLSET="v100"
27041       else
27042         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS100BASE using $METHOD" >&5
27043 $as_echo "$as_me: Found Visual Studio installation at $VS100BASE using $METHOD" >&6;}
27044         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5
27045 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;}
27046       fi
27047     fi
27048   fi
27049 
27050 
27051   if test "x$ProgramW6432" != x; then
27052 
27053   if test "x$VS_ENV_CMD" = x; then
27054     WIN_SDK_BASE="$ProgramW6432/Microsoft SDKs/Windows/v7.1/Bin"
27055     METHOD="well-known name"
27056 
27057   windows_path="$WIN_SDK_BASE"
27058   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27059     unix_path=`$CYGPATH -u "$windows_path"`
27060     WIN_SDK_BASE="$unix_path"
27061   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27062     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27063     WIN_SDK_BASE="$unix_path"
27064   fi
27065 
27066     if test -d "$WIN_SDK_BASE"; then
27067       # There have been cases of partial or broken SDK installations. A missing
27068       # lib dir is not going to work.
27069       if test ! -d "$WIN_SDK_BASE/../lib"; then
27070         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27071 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27072         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
27073 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
27074       elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
27075         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27076 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27077         VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
27078         if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
27079           VS_ENV_ARGS="/x86"
27080         else
27081           VS_ENV_ARGS="/x64"
27082         fi
27083         # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see
27084         # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK
27085         # TODO: improve detection for other versions of SDK
27086         PLATFORM_TOOLSET="Windows7.1SDK"
27087       else
27088         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27089 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27090         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
27091 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
27092       fi
27093     fi
27094   fi
27095 
27096   fi
27097   if test "x$PROGRAMW6432" != x; then
27098 
27099   if test "x$VS_ENV_CMD" = x; then
27100     WIN_SDK_BASE="$PROGRAMW6432/Microsoft SDKs/Windows/v7.1/Bin"
27101     METHOD="well-known name"
27102 
27103   windows_path="$WIN_SDK_BASE"
27104   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27105     unix_path=`$CYGPATH -u "$windows_path"`
27106     WIN_SDK_BASE="$unix_path"
27107   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27108     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27109     WIN_SDK_BASE="$unix_path"
27110   fi
27111 
27112     if test -d "$WIN_SDK_BASE"; then
27113       # There have been cases of partial or broken SDK installations. A missing
27114       # lib dir is not going to work.
27115       if test ! -d "$WIN_SDK_BASE/../lib"; then
27116         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27117 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27118         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
27119 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
27120       elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
27121         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27122 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27123         VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
27124         if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
27125           VS_ENV_ARGS="/x86"
27126         else
27127           VS_ENV_ARGS="/x64"
27128         fi
27129         # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see
27130         # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK
27131         # TODO: improve detection for other versions of SDK
27132         PLATFORM_TOOLSET="Windows7.1SDK"
27133       else
27134         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27135 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27136         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
27137 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
27138       fi
27139     fi
27140   fi
27141 
27142   fi
27143   if test "x$PROGRAMFILES" != x; then
27144 
27145   if test "x$VS_ENV_CMD" = x; then
27146     WIN_SDK_BASE="$PROGRAMFILES/Microsoft SDKs/Windows/v7.1/Bin"
27147     METHOD="well-known name"
27148 
27149   windows_path="$WIN_SDK_BASE"
27150   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27151     unix_path=`$CYGPATH -u "$windows_path"`
27152     WIN_SDK_BASE="$unix_path"
27153   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27154     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27155     WIN_SDK_BASE="$unix_path"
27156   fi
27157 
27158     if test -d "$WIN_SDK_BASE"; then
27159       # There have been cases of partial or broken SDK installations. A missing
27160       # lib dir is not going to work.
27161       if test ! -d "$WIN_SDK_BASE/../lib"; then
27162         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27163 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27164         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
27165 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
27166       elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
27167         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27168 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27169         VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
27170         if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
27171           VS_ENV_ARGS="/x86"
27172         else
27173           VS_ENV_ARGS="/x64"
27174         fi
27175         # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see
27176         # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK
27177         # TODO: improve detection for other versions of SDK
27178         PLATFORM_TOOLSET="Windows7.1SDK"
27179       else
27180         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27181 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27182         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
27183 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
27184       fi
27185     fi
27186   fi
27187 
27188   fi
27189 
27190   if test "x$VS_ENV_CMD" = x; then
27191     WIN_SDK_BASE="C:/Program Files/Microsoft SDKs/Windows/v7.1/Bin"
27192     METHOD="well-known name"
27193 
27194   windows_path="$WIN_SDK_BASE"
27195   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27196     unix_path=`$CYGPATH -u "$windows_path"`
27197     WIN_SDK_BASE="$unix_path"
27198   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27199     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27200     WIN_SDK_BASE="$unix_path"
27201   fi
27202 
27203     if test -d "$WIN_SDK_BASE"; then
27204       # There have been cases of partial or broken SDK installations. A missing
27205       # lib dir is not going to work.
27206       if test ! -d "$WIN_SDK_BASE/../lib"; then
27207         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27208 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27209         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
27210 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
27211       elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
27212         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27213 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27214         VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
27215         if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
27216           VS_ENV_ARGS="/x86"
27217         else
27218           VS_ENV_ARGS="/x64"
27219         fi
27220         # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see
27221         # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK
27222         # TODO: improve detection for other versions of SDK
27223         PLATFORM_TOOLSET="Windows7.1SDK"
27224       else
27225         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27226 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27227         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
27228 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
27229       fi
27230     fi
27231   fi
27232 
27233 
27234   if test "x$VS_ENV_CMD" = x; then
27235     WIN_SDK_BASE="C:/Program Files (x86)/Microsoft SDKs/Windows/v7.1/Bin"
27236     METHOD="well-known name"
27237 
27238   windows_path="$WIN_SDK_BASE"
27239   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27240     unix_path=`$CYGPATH -u "$windows_path"`
27241     WIN_SDK_BASE="$unix_path"
27242   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27243     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27244     WIN_SDK_BASE="$unix_path"
27245   fi
27246 
27247     if test -d "$WIN_SDK_BASE"; then
27248       # There have been cases of partial or broken SDK installations. A missing
27249       # lib dir is not going to work.
27250       if test ! -d "$WIN_SDK_BASE/../lib"; then
27251         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27252 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27253         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5
27254 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;}
27255       elif test -f "$WIN_SDK_BASE/SetEnv.Cmd"; then
27256         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27257 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27258         VS_ENV_CMD="$WIN_SDK_BASE/SetEnv.Cmd"
27259         if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
27260           VS_ENV_ARGS="/x86"
27261         else
27262           VS_ENV_ARGS="/x64"
27263         fi
27264         # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see
27265         # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK
27266         # TODO: improve detection for other versions of SDK
27267         PLATFORM_TOOLSET="Windows7.1SDK"
27268       else
27269         { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5
27270 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;}
27271         { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5
27272 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;}
27273       fi
27274     fi
27275   fi
27276 
27277 
27278   if test "x$VS_ENV_CMD" != x; then
27279     # We have found a Visual Studio environment on disk, let's extract variables from the vsvars bat file.
27280 
27281   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27282 
27283   # First separate the path from the arguments. This will split at the first
27284   # space.
27285   complete="$VS_ENV_CMD"
27286   path="${complete%% *}"
27287   tmp="$complete EOL"
27288   arguments="${tmp#* }"
27289 
27290   # Input might be given as Windows format, start by converting to
27291   # unix format.
27292   new_path=`$CYGPATH -u "$path"`
27293 
27294   # Now try to locate executable using which
27295   new_path=`$WHICH "$new_path" 2> /dev/null`
27296   # bat and cmd files are not always considered executable in cygwin causing which
27297   # to not find them
27298   if test "x$new_path" = x \
27299       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
27300       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
27301     new_path=`$CYGPATH -u "$path"`
27302   fi
27303   if test "x$new_path" = x; then
27304     # Oops. Which didn't find the executable.
27305     # The splitting of arguments from the executable at a space might have been incorrect,
27306     # since paths with space are more likely in Windows. Give it another try with the whole
27307     # argument.
27308     path="$complete"
27309     arguments="EOL"
27310     new_path=`$CYGPATH -u "$path"`
27311     new_path=`$WHICH "$new_path" 2> /dev/null`
27312     # bat and cmd files are not always considered executable in cygwin causing which
27313     # to not find them
27314     if test "x$new_path" = x \
27315         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
27316         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
27317       new_path=`$CYGPATH -u "$path"`
27318     fi
27319     if test "x$new_path" = x; then
27320       # It's still not found. Now this is an unrecoverable error.
27321       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
27322 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
27323       has_space=`$ECHO "$complete" | $GREP " "`
27324       if test "x$has_space" != x; then
27325         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27326 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27327       fi
27328       as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27329     fi
27330   fi
27331 
27332   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
27333   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
27334   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
27335   # "foo.exe" is OK but "foo" is an error.
27336   #
27337   # This test is therefore slightly more accurate than "test -f" to check for file presence.
27338   # It is also a way to make sure we got the proper file name for the real test later on.
27339   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
27340   if test "x$test_shortpath" = x; then
27341     # Short path failed, file does not exist as specified.
27342     # Try adding .exe or .cmd
27343     if test -f "${new_path}.exe"; then
27344       input_to_shortpath="${new_path}.exe"
27345     elif test -f "${new_path}.cmd"; then
27346       input_to_shortpath="${new_path}.cmd"
27347     else
27348       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&5
27349 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&6;}
27350       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
27351 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
27352       as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27353     fi
27354   else
27355     input_to_shortpath="$new_path"
27356   fi
27357 
27358   # Call helper function which possibly converts this using DOS-style short mode.
27359   # If so, the updated path is stored in $new_path.
27360   new_path="$input_to_shortpath"
27361 
27362   input_path="$input_to_shortpath"
27363   # Check if we need to convert this using DOS-style short mode. If the path
27364   # contains just simple characters, use it. Otherwise (spaces, weird characters),
27365   # take no chances and rewrite it.
27366   # Note: m4 eats our [], so we need to use [ and ] instead.
27367   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
27368   if test "x$has_forbidden_chars" != x; then
27369     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27370     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
27371     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
27372     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
27373       # Going to short mode and back again did indeed matter. Since short mode is
27374       # case insensitive, let's make it lowercase to improve readability.
27375       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27376       # Now convert it back to Unix-stile (cygpath)
27377       input_path=`$CYGPATH -u "$shortmode_path"`
27378       new_path="$input_path"
27379     fi
27380   fi
27381 
27382   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
27383   if test "x$test_cygdrive_prefix" = x; then
27384     # As a simple fix, exclude /usr/bin since it's not a real path.
27385     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
27386       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
27387       # a path prefixed by /cygdrive for fixpath to work.
27388       new_path="$CYGWIN_ROOT_PATH$input_path"
27389     fi
27390   fi
27391 
27392   # remove trailing .exe if any
27393   new_path="${new_path/%.exe/}"
27394 
27395   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27396 
27397   # First separate the path from the arguments. This will split at the first
27398   # space.
27399   complete="$VS_ENV_CMD"
27400   path="${complete%% *}"
27401   tmp="$complete EOL"
27402   arguments="${tmp#* }"
27403 
27404   # Input might be given as Windows format, start by converting to
27405   # unix format.
27406   new_path="$path"
27407 
27408   windows_path="$new_path"
27409   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27410     unix_path=`$CYGPATH -u "$windows_path"`
27411     new_path="$unix_path"
27412   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27413     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27414     new_path="$unix_path"
27415   fi
27416 
27417 
27418   # Now try to locate executable using which
27419   new_path=`$WHICH "$new_path" 2> /dev/null`
27420 
27421   if test "x$new_path" = x; then
27422     # Oops. Which didn't find the executable.
27423     # The splitting of arguments from the executable at a space might have been incorrect,
27424     # since paths with space are more likely in Windows. Give it another try with the whole
27425     # argument.
27426     path="$complete"
27427     arguments="EOL"
27428     new_path="$path"
27429 
27430   windows_path="$new_path"
27431   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27432     unix_path=`$CYGPATH -u "$windows_path"`
27433     new_path="$unix_path"
27434   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27435     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27436     new_path="$unix_path"
27437   fi
27438 
27439 
27440     new_path=`$WHICH "$new_path" 2> /dev/null`
27441     # bat and cmd files are not always considered executable in MSYS causing which
27442     # to not find them
27443     if test "x$new_path" = x \
27444         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
27445         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
27446       new_path="$path"
27447 
27448   windows_path="$new_path"
27449   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27450     unix_path=`$CYGPATH -u "$windows_path"`
27451     new_path="$unix_path"
27452   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27453     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27454     new_path="$unix_path"
27455   fi
27456 
27457     fi
27458 
27459     if test "x$new_path" = x; then
27460       # It's still not found. Now this is an unrecoverable error.
27461       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
27462 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
27463       has_space=`$ECHO "$complete" | $GREP " "`
27464       if test "x$has_space" != x; then
27465         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27466 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27467       fi
27468       as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27469     fi
27470   fi
27471 
27472   # Now new_path has a complete unix path to the binary
27473   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
27474     # Keep paths in /bin as-is, but remove trailing .exe if any
27475     new_path="${new_path/%.exe/}"
27476     # Do not save /bin paths to all_fixpath_prefixes!
27477   else
27478     # Not in mixed or Windows style, start by that.
27479     new_path=`cmd //c echo $new_path`
27480 
27481   input_path="$new_path"
27482   # Check if we need to convert this using DOS-style short mode. If the path
27483   # contains just simple characters, use it. Otherwise (spaces, weird characters),
27484   # take no chances and rewrite it.
27485   # Note: m4 eats our [], so we need to use [ and ] instead.
27486   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
27487   if test "x$has_forbidden_chars" != x; then
27488     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
27489     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
27490   fi
27491 
27492     # Output is in $new_path
27493 
27494   windows_path="$new_path"
27495   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27496     unix_path=`$CYGPATH -u "$windows_path"`
27497     new_path="$unix_path"
27498   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27499     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
27500     new_path="$unix_path"
27501   fi
27502 
27503     # remove trailing .exe if any
27504     new_path="${new_path/%.exe/}"
27505 
27506     # Save the first 10 bytes of this path to the storage, so fixpath can work.
27507     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
27508   fi
27509 
27510   else
27511     # We're on a unix platform. Hooray! :)
27512     # First separate the path from the arguments. This will split at the first
27513     # space.
27514     complete="$VS_ENV_CMD"
27515     path="${complete%% *}"
27516     tmp="$complete EOL"
27517     arguments="${tmp#* }"
27518 
27519     # Cannot rely on the command "which" here since it doesn't always work.
27520     is_absolute_path=`$ECHO "$path" | $GREP ^/`
27521     if test -z "$is_absolute_path"; then
27522       # Path to executable is not absolute. Find it.
27523       IFS_save="$IFS"
27524       IFS=:
27525       for p in $PATH; do
27526         if test -f "$p/$path" && test -x "$p/$path"; then
27527           new_path="$p/$path"
27528           break
27529         fi
27530       done
27531       IFS="$IFS_save"
27532     else
27533       # This is an absolute path, we can use it without further modifications.
27534       new_path="$path"
27535     fi
27536 
27537     if test "x$new_path" = x; then
27538       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5
27539 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;}
27540       has_space=`$ECHO "$complete" | $GREP " "`
27541       if test "x$has_space" != x; then
27542         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
27543 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
27544       fi
27545       as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5
27546     fi
27547   fi
27548 
27549   # Now join together the path and the arguments once again
27550   if test "x$arguments" != xEOL; then
27551     new_complete="$new_path ${arguments% *}"
27552   else
27553     new_complete="$new_path"
27554   fi
27555 
27556   if test "x$complete" != "x$new_complete"; then
27557     VS_ENV_CMD="$new_complete"
27558     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting VS_ENV_CMD to \"$new_complete\"" >&5
27559 $as_echo "$as_me: Rewriting VS_ENV_CMD to \"$new_complete\"" >&6;}
27560   fi
27561 
27562 
27563     # Lets extract the variables that are set by vcvarsall.bat/vsvars32.bat/vsvars64.bat
27564     { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to extract Visual Studio environment variables" >&5
27565 $as_echo "$as_me: Trying to extract Visual Studio environment variables" >&6;}
27566 
27567     # We need to create a couple of temporary files.
27568     VS_ENV_TMP_DIR="$OUTPUT_ROOT/vs-env"
27569     $MKDIR -p $VS_ENV_TMP_DIR
27570 
27571     # Cannot use the VS10 setup script directly (since it only updates the DOS subshell environment).
27572     # Instead create a shell script which will set the relevant variables when run.
27573     WINPATH_VS_ENV_CMD="$VS_ENV_CMD"
27574 
27575   unix_path="$WINPATH_VS_ENV_CMD"
27576   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27577     windows_path=`$CYGPATH -m "$unix_path"`
27578     WINPATH_VS_ENV_CMD="$windows_path"
27579   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27580     windows_path=`cmd //c echo $unix_path`
27581     WINPATH_VS_ENV_CMD="$windows_path"
27582   fi
27583 
27584     WINPATH_BASH="$BASH"
27585 
27586   unix_path="$WINPATH_BASH"
27587   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27588     windows_path=`$CYGPATH -m "$unix_path"`
27589     WINPATH_BASH="$windows_path"
27590   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27591     windows_path=`cmd //c echo $unix_path`
27592     WINPATH_BASH="$windows_path"
27593   fi
27594 
27595 
27596     # Generate a DOS batch file which runs $VS_ENV_CMD, and then creates a shell
27597     # script (executable by bash) that will setup the important variables.
27598     EXTRACT_VC_ENV_BAT_FILE="$VS_ENV_TMP_DIR/extract-vs-env.bat"
27599     $ECHO "@echo off" >  $EXTRACT_VC_ENV_BAT_FILE
27600     # This will end up something like:
27601     # call C:/progra~2/micros~2.0/vc/bin/amd64/vcvars64.bat
27602     $ECHO "call $WINPATH_VS_ENV_CMD $VS_ENV_ARGS" >> $EXTRACT_VC_ENV_BAT_FILE
27603     # These will end up something like:
27604     # C:/CygWin/bin/bash -c 'echo VS_PATH=\"$PATH\" > localdevenv.sh
27605     # The trailing space for everyone except PATH is no typo, but is needed due
27606     # to trailing \ in the Windows paths. These will be stripped later.
27607     $ECHO "$WINPATH_BASH -c 'echo VS_PATH="'\"$PATH\" > set-vs-env.sh' >> $EXTRACT_VC_ENV_BAT_FILE
27608     $ECHO "$WINPATH_BASH -c 'echo VS_INCLUDE="'\"$INCLUDE \" >> set-vs-env.sh' >> $EXTRACT_VC_ENV_BAT_FILE
27609     $ECHO "$WINPATH_BASH -c 'echo VS_LIB="'\"$LIB \" >> set-vs-env.sh' >> $EXTRACT_VC_ENV_BAT_FILE
27610     $ECHO "$WINPATH_BASH -c 'echo VCINSTALLDIR="'\"$VCINSTALLDIR \" >> set-vs-env.sh' >> $EXTRACT_VC_ENV_BAT_FILE
27611     $ECHO "$WINPATH_BASH -c 'echo WindowsSdkDir="'\"$WindowsSdkDir \" >> set-vs-env.sh' >> $EXTRACT_VC_ENV_BAT_FILE
27612     $ECHO "$WINPATH_BASH -c 'echo WINDOWSSDKDIR="'\"$WINDOWSSDKDIR \" >> set-vs-env.sh' >> $EXTRACT_VC_ENV_BAT_FILE
27613 
27614     # Now execute the newly created bat file.
27615     # The | cat is to stop SetEnv.Cmd to mess with system colors on msys.
27616     # Change directory so we don't need to mess with Windows paths in redirects.
27617     cd $VS_ENV_TMP_DIR
27618     cmd /c extract-vs-env.bat | $CAT
27619     cd $CURDIR
27620 
27621     if test ! -s $VS_ENV_TMP_DIR/set-vs-env.sh; then
27622       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not succesfully extract the envionment variables needed for the VS setup." >&5
27623 $as_echo "$as_me: Could not succesfully extract the envionment variables needed for the VS setup." >&6;}
27624       { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5
27625 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;}
27626       { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5
27627 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;}
27628       as_fn_error $? "Cannot continue" "$LINENO" 5
27629     fi
27630 
27631     # Now set all paths and other env variables. This will allow the rest of
27632     # the configure script to find and run the compiler in the proper way.
27633     { $as_echo "$as_me:${as_lineno-$LINENO}: Setting extracted environment variables" >&5
27634 $as_echo "$as_me: Setting extracted environment variables" >&6;}
27635     . $VS_ENV_TMP_DIR/set-vs-env.sh
27636     # Now we have VS_PATH, VS_INCLUDE, VS_LIB. For further checking, we
27637     # also define VCINSTALLDIR, WindowsSdkDir and WINDOWSSDKDIR.
27638   else
27639     # We did not find a vsvars bat file, let's hope we are run from a VS command prompt.
27640     { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio installation, checking current environment" >&5
27641 $as_echo "$as_me: Cannot locate a valid Visual Studio installation, checking current environment" >&6;}
27642   fi
27643 
27644   # At this point, we should have correct variables in the environment, or we can't continue.
27645   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Visual Studio variables" >&5
27646 $as_echo_n "checking for Visual Studio variables... " >&6; }
27647 
27648   if test "x$VCINSTALLDIR" != x || test "x$WindowsSDKDir" != x || test "x$WINDOWSSDKDIR" != x; then
27649     if test "x$VS_INCLUDE" = x || test "x$VS_LIB" = x; then
27650       { $as_echo "$as_me:${as_lineno-$LINENO}: result: present but broken" >&5
27651 $as_echo "present but broken" >&6; }
27652       as_fn_error $? "Your VC command prompt seems broken, INCLUDE and/or LIB is missing." "$LINENO" 5
27653     else
27654       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
27655 $as_echo "ok" >&6; }
27656       # Remove any trailing "\" and " " from the variables.
27657       VS_INCLUDE=`$ECHO "$VS_INCLUDE" | $SED 's/\\\\* *$//'`
27658       VS_LIB=`$ECHO "$VS_LIB" | $SED 's/\\\\* *$//'`
27659       VCINSTALLDIR=`$ECHO "$VCINSTALLDIR" | $SED 's/\\\\* *$//'`
27660       WindowsSDKDir=`$ECHO "$WindowsSDKDir" | $SED 's/\\\\* *$//'`
27661       WINDOWSSDKDIR=`$ECHO "$WINDOWSSDKDIR" | $SED 's/\\\\* *$//'`
27662       # Remove any paths containing # (typically F#) as that messes up make. This
27663       # is needed if visual studio was installed with F# support.
27664       VS_PATH=`$ECHO "$VS_PATH" | $SED 's/[^:#]*#[^:]*://g'`
27665 
27666 
27667 
27668 
27669     fi
27670   else
27671     { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
27672 $as_echo "not found" >&6; }
27673 
27674     if test "x$VS_ENV_CMD" = x; then
27675       { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&5
27676 $as_echo "$as_me: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&6;}
27677       { $as_echo "$as_me:${as_lineno-$LINENO}: nor is this script run from a Visual Studio command prompt." >&5
27678 $as_echo "$as_me: nor is this script run from a Visual Studio command prompt." >&6;}
27679     else
27680       { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5
27681 $as_echo "$as_me: Running the extraction script failed." >&6;}
27682     fi
27683     { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5
27684 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;}
27685     { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5
27686 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;}
27687     as_fn_error $? "Cannot continue" "$LINENO" 5
27688   fi
27689 
27690     # Reset path to VS_PATH. It will include everything that was on PATH at the time we
27691     # ran TOOLCHAIN_SETUP_VISUAL_STUDIO_ENV.
27692     PATH="$VS_PATH"
27693     # The microsoft toolchain also requires INCLUDE and LIB to be set.
27694     export INCLUDE="$VS_INCLUDE"
27695     export LIB="$VS_LIB"
27696   fi
27697 
27698   # autoconf magic only relies on PATH, so update it if tools dir is specified
27699   OLD_PATH="$PATH"
27700 
27701   # For solaris we really need solaris tools, and not the GNU equivalent.
27702   # The build tools on Solaris reside in /usr/ccs (C Compilation System),
27703   # so add that to path before starting to probe.
27704   # FIXME: This was originally only done for AS,NM,GNM,STRIP,MCS,OBJCOPY,OBJDUMP.
27705   if test "x$OPENJDK_BUILD_OS" = xsolaris; then
27706     PATH="/usr/ccs/bin:$PATH"
27707   fi
27708 
27709   # Finally add TOOLCHAIN_PATH at the beginning, to allow --with-tools-dir to
27710   # override all other locations.
27711   if test "x$TOOLCHAIN_PATH" != x; then
27712     PATH=$TOOLCHAIN_PATH:$PATH
27713   fi
27714 
27715 
27716   #
27717   # Setup the compilers (CC and CXX)
27718   #
27719 
27720   COMPILER_NAME=C
27721   SEARCH_LIST="$TOOLCHAIN_CC_BINARY"
27722 
27723   if test "x$CC" != x; then
27724     # User has supplied compiler name already, always let that override.
27725     { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CC=$CC" >&5
27726 $as_echo "$as_me: Will use user supplied compiler CC=$CC" >&6;}
27727     if test "x`basename $CC`" = "x$CC"; then
27728       # A command without a complete path is provided, search $PATH.
27729 
27730       for ac_prog in $CC
27731 do
27732   # Extract the first word of "$ac_prog", so it can be a program name with args.
27733 set dummy $ac_prog; ac_word=$2
27734 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27735 $as_echo_n "checking for $ac_word... " >&6; }
27736 if ${ac_cv_path_POTENTIAL_CC+:} false; then :
27737   $as_echo_n "(cached) " >&6
27738 else
27739   case $POTENTIAL_CC in
27740   [\\/]* | ?:[\\/]*)
27741   ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path.
27742   ;;
27743   *)
27744   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27745 for as_dir in $PATH
27746 do
27747   IFS=$as_save_IFS
27748   test -z "$as_dir" && as_dir=.
27749     for ac_exec_ext in '' $ac_executable_extensions; do
27750   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27751     ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext"
27752     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27753     break 2
27754   fi
27755 done
27756   done
27757 IFS=$as_save_IFS
27758 
27759   ;;
27760 esac
27761 fi
27762 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC
27763 if test -n "$POTENTIAL_CC"; then
27764   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5
27765 $as_echo "$POTENTIAL_CC" >&6; }
27766 else
27767   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27768 $as_echo "no" >&6; }
27769 fi
27770 
27771 
27772   test -n "$POTENTIAL_CC" && break
27773 done
27774 
27775       if test "x$POTENTIAL_CC" != x; then
27776         CC=$POTENTIAL_CC
27777       else
27778         as_fn_error $? "User supplied compiler CC=$CC could not be found" "$LINENO" 5
27779       fi
27780     else
27781       # Otherwise it might already be a complete path
27782       if test ! -x "$CC"; then
27783         as_fn_error $? "User supplied compiler CC=$CC does not exist" "$LINENO" 5
27784       fi
27785     fi
27786   else
27787     # No user supplied value. Locate compiler ourselves.
27788 
27789     # If we are cross compiling, assume cross compilation tools follows the
27790     # cross compilation standard where they are prefixed with the autoconf
27791     # standard name for the target. For example the binary
27792     # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10.
27793     # If we are not cross compiling, then the default compiler name will be
27794     # used.
27795 
27796     CC=
27797     # If TOOLCHAIN_PATH is set, check for all compiler names in there first
27798     # before checking the rest of the PATH.
27799     # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION
27800     # step, this should not be necessary.
27801     if test -n "$TOOLCHAIN_PATH"; then
27802       PATH_save="$PATH"
27803       PATH="$TOOLCHAIN_PATH"
27804       for ac_prog in $SEARCH_LIST
27805 do
27806   # Extract the first word of "$ac_prog", so it can be a program name with args.
27807 set dummy $ac_prog; ac_word=$2
27808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27809 $as_echo_n "checking for $ac_word... " >&6; }
27810 if ${ac_cv_path_TOOLCHAIN_PATH_CC+:} false; then :
27811   $as_echo_n "(cached) " >&6
27812 else
27813   case $TOOLCHAIN_PATH_CC in
27814   [\\/]* | ?:[\\/]*)
27815   ac_cv_path_TOOLCHAIN_PATH_CC="$TOOLCHAIN_PATH_CC" # Let the user override the test with a path.
27816   ;;
27817   *)
27818   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27819 for as_dir in $PATH
27820 do
27821   IFS=$as_save_IFS
27822   test -z "$as_dir" && as_dir=.
27823     for ac_exec_ext in '' $ac_executable_extensions; do
27824   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27825     ac_cv_path_TOOLCHAIN_PATH_CC="$as_dir/$ac_word$ac_exec_ext"
27826     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27827     break 2
27828   fi
27829 done
27830   done
27831 IFS=$as_save_IFS
27832 
27833   ;;
27834 esac
27835 fi
27836 TOOLCHAIN_PATH_CC=$ac_cv_path_TOOLCHAIN_PATH_CC
27837 if test -n "$TOOLCHAIN_PATH_CC"; then
27838   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CC" >&5
27839 $as_echo "$TOOLCHAIN_PATH_CC" >&6; }
27840 else
27841   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27842 $as_echo "no" >&6; }
27843 fi
27844 
27845 
27846   test -n "$TOOLCHAIN_PATH_CC" && break
27847 done
27848 
27849       CC=$TOOLCHAIN_PATH_CC
27850       PATH="$PATH_save"
27851     fi
27852 
27853     # AC_PATH_PROGS can't be run multiple times with the same variable,
27854     # so create a new name for this run.
27855     if test "x$CC" = x; then
27856       for ac_prog in $SEARCH_LIST
27857 do
27858   # Extract the first word of "$ac_prog", so it can be a program name with args.
27859 set dummy $ac_prog; ac_word=$2
27860 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27861 $as_echo_n "checking for $ac_word... " >&6; }
27862 if ${ac_cv_path_POTENTIAL_CC+:} false; then :
27863   $as_echo_n "(cached) " >&6
27864 else
27865   case $POTENTIAL_CC in
27866   [\\/]* | ?:[\\/]*)
27867   ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path.
27868   ;;
27869   *)
27870   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27871 for as_dir in $PATH
27872 do
27873   IFS=$as_save_IFS
27874   test -z "$as_dir" && as_dir=.
27875     for ac_exec_ext in '' $ac_executable_extensions; do
27876   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27877     ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext"
27878     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27879     break 2
27880   fi
27881 done
27882   done
27883 IFS=$as_save_IFS
27884 
27885   ;;
27886 esac
27887 fi
27888 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC
27889 if test -n "$POTENTIAL_CC"; then
27890   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5
27891 $as_echo "$POTENTIAL_CC" >&6; }
27892 else
27893   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27894 $as_echo "no" >&6; }
27895 fi
27896 
27897 
27898   test -n "$POTENTIAL_CC" && break
27899 done
27900 
27901       CC=$POTENTIAL_CC
27902     fi
27903 
27904     if test "x$CC" = x; then
27905 
27906   # Print a helpful message on how to acquire the necessary build dependency.
27907   # devkit is the help tag: freetype, cups, pulse, alsa etc
27908   MISSING_DEPENDENCY=devkit
27909 
27910   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27911     cygwin_help $MISSING_DEPENDENCY
27912   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
27913     msys_help $MISSING_DEPENDENCY
27914   else
27915     PKGHANDLER_COMMAND=
27916 
27917     case $PKGHANDLER in
27918       apt-get)
27919         apt_help     $MISSING_DEPENDENCY ;;
27920       yum)
27921         yum_help     $MISSING_DEPENDENCY ;;
27922       port)
27923         port_help    $MISSING_DEPENDENCY ;;
27924       pkgutil)
27925         pkgutil_help $MISSING_DEPENDENCY ;;
27926       pkgadd)
27927         pkgadd_help  $MISSING_DEPENDENCY ;;
27928     esac
27929 
27930     if test "x$PKGHANDLER_COMMAND" != x; then
27931       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
27932     fi
27933   fi
27934 
27935       as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5
27936     fi
27937   fi
27938 
27939   # Now we have a compiler binary in CC. Make sure it's okay.
27940 
27941   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
27942 
27943   # First separate the path from the arguments. This will split at the first
27944   # space.
27945   complete="$CC"
27946   path="${complete%% *}"
27947   tmp="$complete EOL"
27948   arguments="${tmp#* }"
27949 
27950   # Input might be given as Windows format, start by converting to
27951   # unix format.
27952   new_path=`$CYGPATH -u "$path"`
27953 
27954   # Now try to locate executable using which
27955   new_path=`$WHICH "$new_path" 2> /dev/null`
27956   # bat and cmd files are not always considered executable in cygwin causing which
27957   # to not find them
27958   if test "x$new_path" = x \
27959       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
27960       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
27961     new_path=`$CYGPATH -u "$path"`
27962   fi
27963   if test "x$new_path" = x; then
27964     # Oops. Which didn't find the executable.
27965     # The splitting of arguments from the executable at a space might have been incorrect,
27966     # since paths with space are more likely in Windows. Give it another try with the whole
27967     # argument.
27968     path="$complete"
27969     arguments="EOL"
27970     new_path=`$CYGPATH -u "$path"`
27971     new_path=`$WHICH "$new_path" 2> /dev/null`
27972     # bat and cmd files are not always considered executable in cygwin causing which
27973     # to not find them
27974     if test "x$new_path" = x \
27975         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
27976         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
27977       new_path=`$CYGPATH -u "$path"`
27978     fi
27979     if test "x$new_path" = x; then
27980       # It's still not found. Now this is an unrecoverable error.
27981       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
27982 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
27983       has_space=`$ECHO "$complete" | $GREP " "`
27984       if test "x$has_space" != x; then
27985         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
27986 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
27987       fi
27988       as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
27989     fi
27990   fi
27991 
27992   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
27993   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
27994   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
27995   # "foo.exe" is OK but "foo" is an error.
27996   #
27997   # This test is therefore slightly more accurate than "test -f" to check for file presence.
27998   # It is also a way to make sure we got the proper file name for the real test later on.
27999   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
28000   if test "x$test_shortpath" = x; then
28001     # Short path failed, file does not exist as specified.
28002     # Try adding .exe or .cmd
28003     if test -f "${new_path}.exe"; then
28004       input_to_shortpath="${new_path}.exe"
28005     elif test -f "${new_path}.cmd"; then
28006       input_to_shortpath="${new_path}.cmd"
28007     else
28008       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$new_path\", is invalid." >&5
28009 $as_echo "$as_me: The path of CC, which resolves as \"$new_path\", is invalid." >&6;}
28010       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
28011 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
28012       as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
28013     fi
28014   else
28015     input_to_shortpath="$new_path"
28016   fi
28017 
28018   # Call helper function which possibly converts this using DOS-style short mode.
28019   # If so, the updated path is stored in $new_path.
28020   new_path="$input_to_shortpath"
28021 
28022   input_path="$input_to_shortpath"
28023   # Check if we need to convert this using DOS-style short mode. If the path
28024   # contains just simple characters, use it. Otherwise (spaces, weird characters),
28025   # take no chances and rewrite it.
28026   # Note: m4 eats our [], so we need to use [ and ] instead.
28027   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
28028   if test "x$has_forbidden_chars" != x; then
28029     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28030     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
28031     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
28032     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
28033       # Going to short mode and back again did indeed matter. Since short mode is
28034       # case insensitive, let's make it lowercase to improve readability.
28035       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28036       # Now convert it back to Unix-stile (cygpath)
28037       input_path=`$CYGPATH -u "$shortmode_path"`
28038       new_path="$input_path"
28039     fi
28040   fi
28041 
28042   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
28043   if test "x$test_cygdrive_prefix" = x; then
28044     # As a simple fix, exclude /usr/bin since it's not a real path.
28045     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
28046       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
28047       # a path prefixed by /cygdrive for fixpath to work.
28048       new_path="$CYGWIN_ROOT_PATH$input_path"
28049     fi
28050   fi
28051 
28052   # remove trailing .exe if any
28053   new_path="${new_path/%.exe/}"
28054 
28055   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28056 
28057   # First separate the path from the arguments. This will split at the first
28058   # space.
28059   complete="$CC"
28060   path="${complete%% *}"
28061   tmp="$complete EOL"
28062   arguments="${tmp#* }"
28063 
28064   # Input might be given as Windows format, start by converting to
28065   # unix format.
28066   new_path="$path"
28067 
28068   windows_path="$new_path"
28069   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28070     unix_path=`$CYGPATH -u "$windows_path"`
28071     new_path="$unix_path"
28072   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28073     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28074     new_path="$unix_path"
28075   fi
28076 
28077 
28078   # Now try to locate executable using which
28079   new_path=`$WHICH "$new_path" 2> /dev/null`
28080 
28081   if test "x$new_path" = x; then
28082     # Oops. Which didn't find the executable.
28083     # The splitting of arguments from the executable at a space might have been incorrect,
28084     # since paths with space are more likely in Windows. Give it another try with the whole
28085     # argument.
28086     path="$complete"
28087     arguments="EOL"
28088     new_path="$path"
28089 
28090   windows_path="$new_path"
28091   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28092     unix_path=`$CYGPATH -u "$windows_path"`
28093     new_path="$unix_path"
28094   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28095     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28096     new_path="$unix_path"
28097   fi
28098 
28099 
28100     new_path=`$WHICH "$new_path" 2> /dev/null`
28101     # bat and cmd files are not always considered executable in MSYS causing which
28102     # to not find them
28103     if test "x$new_path" = x \
28104         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28105         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28106       new_path="$path"
28107 
28108   windows_path="$new_path"
28109   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28110     unix_path=`$CYGPATH -u "$windows_path"`
28111     new_path="$unix_path"
28112   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28113     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28114     new_path="$unix_path"
28115   fi
28116 
28117     fi
28118 
28119     if test "x$new_path" = x; then
28120       # It's still not found. Now this is an unrecoverable error.
28121       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
28122 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
28123       has_space=`$ECHO "$complete" | $GREP " "`
28124       if test "x$has_space" != x; then
28125         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
28126 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
28127       fi
28128       as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
28129     fi
28130   fi
28131 
28132   # Now new_path has a complete unix path to the binary
28133   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
28134     # Keep paths in /bin as-is, but remove trailing .exe if any
28135     new_path="${new_path/%.exe/}"
28136     # Do not save /bin paths to all_fixpath_prefixes!
28137   else
28138     # Not in mixed or Windows style, start by that.
28139     new_path=`cmd //c echo $new_path`
28140 
28141   input_path="$new_path"
28142   # Check if we need to convert this using DOS-style short mode. If the path
28143   # contains just simple characters, use it. Otherwise (spaces, weird characters),
28144   # take no chances and rewrite it.
28145   # Note: m4 eats our [], so we need to use [ and ] instead.
28146   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
28147   if test "x$has_forbidden_chars" != x; then
28148     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28149     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28150   fi
28151 
28152     # Output is in $new_path
28153 
28154   windows_path="$new_path"
28155   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28156     unix_path=`$CYGPATH -u "$windows_path"`
28157     new_path="$unix_path"
28158   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28159     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28160     new_path="$unix_path"
28161   fi
28162 
28163     # remove trailing .exe if any
28164     new_path="${new_path/%.exe/}"
28165 
28166     # Save the first 10 bytes of this path to the storage, so fixpath can work.
28167     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
28168   fi
28169 
28170   else
28171     # We're on a unix platform. Hooray! :)
28172     # First separate the path from the arguments. This will split at the first
28173     # space.
28174     complete="$CC"
28175     path="${complete%% *}"
28176     tmp="$complete EOL"
28177     arguments="${tmp#* }"
28178 
28179     # Cannot rely on the command "which" here since it doesn't always work.
28180     is_absolute_path=`$ECHO "$path" | $GREP ^/`
28181     if test -z "$is_absolute_path"; then
28182       # Path to executable is not absolute. Find it.
28183       IFS_save="$IFS"
28184       IFS=:
28185       for p in $PATH; do
28186         if test -f "$p/$path" && test -x "$p/$path"; then
28187           new_path="$p/$path"
28188           break
28189         fi
28190       done
28191       IFS="$IFS_save"
28192     else
28193       # This is an absolute path, we can use it without further modifications.
28194       new_path="$path"
28195     fi
28196 
28197     if test "x$new_path" = x; then
28198       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5
28199 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;}
28200       has_space=`$ECHO "$complete" | $GREP " "`
28201       if test "x$has_space" != x; then
28202         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
28203 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
28204       fi
28205       as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5
28206     fi
28207   fi
28208 
28209   # Now join together the path and the arguments once again
28210   if test "x$arguments" != xEOL; then
28211     new_complete="$new_path ${arguments% *}"
28212   else
28213     new_complete="$new_path"
28214   fi
28215 
28216   if test "x$complete" != "x$new_complete"; then
28217     CC="$new_complete"
28218     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CC to \"$new_complete\"" >&5
28219 $as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;}
28220   fi
28221 
28222   TEST_COMPILER="$CC"
28223   # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links
28224   # to 'xlc' but it is crucial that we invoke the compiler with the right name!
28225   if test "x$OPENJDK_BUILD_OS" != xaix; then
28226     # FIXME: This test should not be needed anymore; we don't do that for any platform.
28227     { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5
28228 $as_echo_n "checking resolved symbolic links for CC... " >&6; }
28229 
28230   if test "x$OPENJDK_BUILD_OS" != xwindows; then
28231     # Follow a chain of symbolic links. Use readlink
28232     # where it exists, else fall back to horribly
28233     # complicated shell code.
28234     if test "x$READLINK_TESTED" != yes; then
28235       # On MacOSX there is a readlink tool with a different
28236       # purpose than the GNU readlink tool. Check the found readlink.
28237       ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
28238       if test "x$ISGNU" = x; then
28239         # A readlink that we do not know how to use.
28240         # Are there other non-GNU readlinks out there?
28241         READLINK_TESTED=yes
28242         READLINK=
28243       fi
28244     fi
28245 
28246     if test "x$READLINK" != x; then
28247       TEST_COMPILER=`$READLINK -f $TEST_COMPILER`
28248     else
28249       # Save the current directory for restoring afterwards
28250       STARTDIR=$PWD
28251       COUNTER=0
28252       sym_link_dir=`$DIRNAME $TEST_COMPILER`
28253       sym_link_file=`$BASENAME $TEST_COMPILER`
28254       cd $sym_link_dir
28255       # Use -P flag to resolve symlinks in directories.
28256       cd `$THEPWDCMD -P`
28257       sym_link_dir=`$THEPWDCMD -P`
28258       # Resolve file symlinks
28259       while test $COUNTER -lt 20; do
28260         ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
28261         if test "x$ISLINK" == x; then
28262           # This is not a symbolic link! We are done!
28263           break
28264         fi
28265         # Again resolve directory symlinks since the target of the just found
28266         # link could be in a different directory
28267         cd `$DIRNAME $ISLINK`
28268         sym_link_dir=`$THEPWDCMD -P`
28269         sym_link_file=`$BASENAME $ISLINK`
28270         let COUNTER=COUNTER+1
28271       done
28272       cd $STARTDIR
28273       TEST_COMPILER=$sym_link_dir/$sym_link_file
28274     fi
28275   fi
28276 
28277     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5
28278 $as_echo "$TEST_COMPILER" >&6; }
28279   fi
28280   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CC is disguised ccache" >&5
28281 $as_echo_n "checking if CC is disguised ccache... " >&6; }
28282 
28283   COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"`
28284   if test "x$COMPILER_BASENAME" = "xccache"; then
28285     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5
28286 $as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; }
28287     # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache.
28288     # We want to control ccache invocation ourselves, so ignore this cc and try
28289     # searching again.
28290 
28291     # Remove the path to the fake ccache cc from the PATH
28292     RETRY_COMPILER_SAVED_PATH="$PATH"
28293     COMPILER_DIRNAME=`$DIRNAME $CC`
28294     PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`"
28295 
28296     # Try again looking for our compiler
28297     if test -n "$ac_tool_prefix"; then
28298   for ac_prog in $TOOLCHAIN_CC_BINARY
28299   do
28300     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
28301 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
28302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28303 $as_echo_n "checking for $ac_word... " >&6; }
28304 if ${ac_cv_prog_PROPER_COMPILER_CC+:} false; then :
28305   $as_echo_n "(cached) " >&6
28306 else
28307   if test -n "$PROPER_COMPILER_CC"; then
28308   ac_cv_prog_PROPER_COMPILER_CC="$PROPER_COMPILER_CC" # Let the user override the test.
28309 else
28310 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28311 for as_dir in $PATH
28312 do
28313   IFS=$as_save_IFS
28314   test -z "$as_dir" && as_dir=.
28315     for ac_exec_ext in '' $ac_executable_extensions; do
28316   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28317     ac_cv_prog_PROPER_COMPILER_CC="$ac_tool_prefix$ac_prog"
28318     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28319     break 2
28320   fi
28321 done
28322   done
28323 IFS=$as_save_IFS
28324 
28325 fi
28326 fi
28327 PROPER_COMPILER_CC=$ac_cv_prog_PROPER_COMPILER_CC
28328 if test -n "$PROPER_COMPILER_CC"; then
28329   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5
28330 $as_echo "$PROPER_COMPILER_CC" >&6; }
28331 else
28332   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28333 $as_echo "no" >&6; }
28334 fi
28335 
28336 
28337     test -n "$PROPER_COMPILER_CC" && break
28338   done
28339 fi
28340 if test -z "$PROPER_COMPILER_CC"; then
28341   ac_ct_PROPER_COMPILER_CC=$PROPER_COMPILER_CC
28342   for ac_prog in $TOOLCHAIN_CC_BINARY
28343 do
28344   # Extract the first word of "$ac_prog", so it can be a program name with args.
28345 set dummy $ac_prog; ac_word=$2
28346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28347 $as_echo_n "checking for $ac_word... " >&6; }
28348 if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CC+:} false; then :
28349   $as_echo_n "(cached) " >&6
28350 else
28351   if test -n "$ac_ct_PROPER_COMPILER_CC"; then
28352   ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_ct_PROPER_COMPILER_CC" # Let the user override the test.
28353 else
28354 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28355 for as_dir in $PATH
28356 do
28357   IFS=$as_save_IFS
28358   test -z "$as_dir" && as_dir=.
28359     for ac_exec_ext in '' $ac_executable_extensions; do
28360   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28361     ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_prog"
28362     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28363     break 2
28364   fi
28365 done
28366   done
28367 IFS=$as_save_IFS
28368 
28369 fi
28370 fi
28371 ac_ct_PROPER_COMPILER_CC=$ac_cv_prog_ac_ct_PROPER_COMPILER_CC
28372 if test -n "$ac_ct_PROPER_COMPILER_CC"; then
28373   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CC" >&5
28374 $as_echo "$ac_ct_PROPER_COMPILER_CC" >&6; }
28375 else
28376   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28377 $as_echo "no" >&6; }
28378 fi
28379 
28380 
28381   test -n "$ac_ct_PROPER_COMPILER_CC" && break
28382 done
28383 
28384   if test "x$ac_ct_PROPER_COMPILER_CC" = x; then
28385     PROPER_COMPILER_CC=""
28386   else
28387     case $cross_compiling:$ac_tool_warned in
28388 yes:)
28389 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
28390 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
28391 ac_tool_warned=yes ;;
28392 esac
28393     PROPER_COMPILER_CC=$ac_ct_PROPER_COMPILER_CC
28394   fi
28395 fi
28396 
28397 
28398   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28399 
28400   # First separate the path from the arguments. This will split at the first
28401   # space.
28402   complete="$PROPER_COMPILER_CC"
28403   path="${complete%% *}"
28404   tmp="$complete EOL"
28405   arguments="${tmp#* }"
28406 
28407   # Input might be given as Windows format, start by converting to
28408   # unix format.
28409   new_path=`$CYGPATH -u "$path"`
28410 
28411   # Now try to locate executable using which
28412   new_path=`$WHICH "$new_path" 2> /dev/null`
28413   # bat and cmd files are not always considered executable in cygwin causing which
28414   # to not find them
28415   if test "x$new_path" = x \
28416       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28417       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28418     new_path=`$CYGPATH -u "$path"`
28419   fi
28420   if test "x$new_path" = x; then
28421     # Oops. Which didn't find the executable.
28422     # The splitting of arguments from the executable at a space might have been incorrect,
28423     # since paths with space are more likely in Windows. Give it another try with the whole
28424     # argument.
28425     path="$complete"
28426     arguments="EOL"
28427     new_path=`$CYGPATH -u "$path"`
28428     new_path=`$WHICH "$new_path" 2> /dev/null`
28429     # bat and cmd files are not always considered executable in cygwin causing which
28430     # to not find them
28431     if test "x$new_path" = x \
28432         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28433         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28434       new_path=`$CYGPATH -u "$path"`
28435     fi
28436     if test "x$new_path" = x; then
28437       # It's still not found. Now this is an unrecoverable error.
28438       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
28439 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
28440       has_space=`$ECHO "$complete" | $GREP " "`
28441       if test "x$has_space" != x; then
28442         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
28443 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
28444       fi
28445       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28446     fi
28447   fi
28448 
28449   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
28450   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
28451   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
28452   # "foo.exe" is OK but "foo" is an error.
28453   #
28454   # This test is therefore slightly more accurate than "test -f" to check for file presence.
28455   # It is also a way to make sure we got the proper file name for the real test later on.
28456   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
28457   if test "x$test_shortpath" = x; then
28458     # Short path failed, file does not exist as specified.
28459     # Try adding .exe or .cmd
28460     if test -f "${new_path}.exe"; then
28461       input_to_shortpath="${new_path}.exe"
28462     elif test -f "${new_path}.cmd"; then
28463       input_to_shortpath="${new_path}.cmd"
28464     else
28465       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&5
28466 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&6;}
28467       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
28468 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
28469       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28470     fi
28471   else
28472     input_to_shortpath="$new_path"
28473   fi
28474 
28475   # Call helper function which possibly converts this using DOS-style short mode.
28476   # If so, the updated path is stored in $new_path.
28477   new_path="$input_to_shortpath"
28478 
28479   input_path="$input_to_shortpath"
28480   # Check if we need to convert this using DOS-style short mode. If the path
28481   # contains just simple characters, use it. Otherwise (spaces, weird characters),
28482   # take no chances and rewrite it.
28483   # Note: m4 eats our [], so we need to use [ and ] instead.
28484   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
28485   if test "x$has_forbidden_chars" != x; then
28486     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28487     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
28488     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
28489     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
28490       # Going to short mode and back again did indeed matter. Since short mode is
28491       # case insensitive, let's make it lowercase to improve readability.
28492       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28493       # Now convert it back to Unix-stile (cygpath)
28494       input_path=`$CYGPATH -u "$shortmode_path"`
28495       new_path="$input_path"
28496     fi
28497   fi
28498 
28499   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
28500   if test "x$test_cygdrive_prefix" = x; then
28501     # As a simple fix, exclude /usr/bin since it's not a real path.
28502     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
28503       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
28504       # a path prefixed by /cygdrive for fixpath to work.
28505       new_path="$CYGWIN_ROOT_PATH$input_path"
28506     fi
28507   fi
28508 
28509   # remove trailing .exe if any
28510   new_path="${new_path/%.exe/}"
28511 
28512   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28513 
28514   # First separate the path from the arguments. This will split at the first
28515   # space.
28516   complete="$PROPER_COMPILER_CC"
28517   path="${complete%% *}"
28518   tmp="$complete EOL"
28519   arguments="${tmp#* }"
28520 
28521   # Input might be given as Windows format, start by converting to
28522   # unix format.
28523   new_path="$path"
28524 
28525   windows_path="$new_path"
28526   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28527     unix_path=`$CYGPATH -u "$windows_path"`
28528     new_path="$unix_path"
28529   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28530     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28531     new_path="$unix_path"
28532   fi
28533 
28534 
28535   # Now try to locate executable using which
28536   new_path=`$WHICH "$new_path" 2> /dev/null`
28537 
28538   if test "x$new_path" = x; then
28539     # Oops. Which didn't find the executable.
28540     # The splitting of arguments from the executable at a space might have been incorrect,
28541     # since paths with space are more likely in Windows. Give it another try with the whole
28542     # argument.
28543     path="$complete"
28544     arguments="EOL"
28545     new_path="$path"
28546 
28547   windows_path="$new_path"
28548   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28549     unix_path=`$CYGPATH -u "$windows_path"`
28550     new_path="$unix_path"
28551   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28552     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28553     new_path="$unix_path"
28554   fi
28555 
28556 
28557     new_path=`$WHICH "$new_path" 2> /dev/null`
28558     # bat and cmd files are not always considered executable in MSYS causing which
28559     # to not find them
28560     if test "x$new_path" = x \
28561         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
28562         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
28563       new_path="$path"
28564 
28565   windows_path="$new_path"
28566   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28567     unix_path=`$CYGPATH -u "$windows_path"`
28568     new_path="$unix_path"
28569   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28570     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28571     new_path="$unix_path"
28572   fi
28573 
28574     fi
28575 
28576     if test "x$new_path" = x; then
28577       # It's still not found. Now this is an unrecoverable error.
28578       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
28579 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
28580       has_space=`$ECHO "$complete" | $GREP " "`
28581       if test "x$has_space" != x; then
28582         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
28583 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
28584       fi
28585       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28586     fi
28587   fi
28588 
28589   # Now new_path has a complete unix path to the binary
28590   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
28591     # Keep paths in /bin as-is, but remove trailing .exe if any
28592     new_path="${new_path/%.exe/}"
28593     # Do not save /bin paths to all_fixpath_prefixes!
28594   else
28595     # Not in mixed or Windows style, start by that.
28596     new_path=`cmd //c echo $new_path`
28597 
28598   input_path="$new_path"
28599   # Check if we need to convert this using DOS-style short mode. If the path
28600   # contains just simple characters, use it. Otherwise (spaces, weird characters),
28601   # take no chances and rewrite it.
28602   # Note: m4 eats our [], so we need to use [ and ] instead.
28603   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
28604   if test "x$has_forbidden_chars" != x; then
28605     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
28606     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
28607   fi
28608 
28609     # Output is in $new_path
28610 
28611   windows_path="$new_path"
28612   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
28613     unix_path=`$CYGPATH -u "$windows_path"`
28614     new_path="$unix_path"
28615   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
28616     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
28617     new_path="$unix_path"
28618   fi
28619 
28620     # remove trailing .exe if any
28621     new_path="${new_path/%.exe/}"
28622 
28623     # Save the first 10 bytes of this path to the storage, so fixpath can work.
28624     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
28625   fi
28626 
28627   else
28628     # We're on a unix platform. Hooray! :)
28629     # First separate the path from the arguments. This will split at the first
28630     # space.
28631     complete="$PROPER_COMPILER_CC"
28632     path="${complete%% *}"
28633     tmp="$complete EOL"
28634     arguments="${tmp#* }"
28635 
28636     # Cannot rely on the command "which" here since it doesn't always work.
28637     is_absolute_path=`$ECHO "$path" | $GREP ^/`
28638     if test -z "$is_absolute_path"; then
28639       # Path to executable is not absolute. Find it.
28640       IFS_save="$IFS"
28641       IFS=:
28642       for p in $PATH; do
28643         if test -f "$p/$path" && test -x "$p/$path"; then
28644           new_path="$p/$path"
28645           break
28646         fi
28647       done
28648       IFS="$IFS_save"
28649     else
28650       # This is an absolute path, we can use it without further modifications.
28651       new_path="$path"
28652     fi
28653 
28654     if test "x$new_path" = x; then
28655       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5
28656 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;}
28657       has_space=`$ECHO "$complete" | $GREP " "`
28658       if test "x$has_space" != x; then
28659         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
28660 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
28661       fi
28662       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5
28663     fi
28664   fi
28665 
28666   # Now join together the path and the arguments once again
28667   if test "x$arguments" != xEOL; then
28668     new_complete="$new_path ${arguments% *}"
28669   else
28670     new_complete="$new_path"
28671   fi
28672 
28673   if test "x$complete" != "x$new_complete"; then
28674     PROPER_COMPILER_CC="$new_complete"
28675     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&5
28676 $as_echo "$as_me: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&6;}
28677   fi
28678 
28679     PATH="$RETRY_COMPILER_SAVED_PATH"
28680 
28681     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CC" >&5
28682 $as_echo_n "checking for resolved symbolic links for CC... " >&6; }
28683 
28684   if test "x$OPENJDK_BUILD_OS" != xwindows; then
28685     # Follow a chain of symbolic links. Use readlink
28686     # where it exists, else fall back to horribly
28687     # complicated shell code.
28688     if test "x$READLINK_TESTED" != yes; then
28689       # On MacOSX there is a readlink tool with a different
28690       # purpose than the GNU readlink tool. Check the found readlink.
28691       ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
28692       if test "x$ISGNU" = x; then
28693         # A readlink that we do not know how to use.
28694         # Are there other non-GNU readlinks out there?
28695         READLINK_TESTED=yes
28696         READLINK=
28697       fi
28698     fi
28699 
28700     if test "x$READLINK" != x; then
28701       PROPER_COMPILER_CC=`$READLINK -f $PROPER_COMPILER_CC`
28702     else
28703       # Save the current directory for restoring afterwards
28704       STARTDIR=$PWD
28705       COUNTER=0
28706       sym_link_dir=`$DIRNAME $PROPER_COMPILER_CC`
28707       sym_link_file=`$BASENAME $PROPER_COMPILER_CC`
28708       cd $sym_link_dir
28709       # Use -P flag to resolve symlinks in directories.
28710       cd `$THEPWDCMD -P`
28711       sym_link_dir=`$THEPWDCMD -P`
28712       # Resolve file symlinks
28713       while test $COUNTER -lt 20; do
28714         ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
28715         if test "x$ISLINK" == x; then
28716           # This is not a symbolic link! We are done!
28717           break
28718         fi
28719         # Again resolve directory symlinks since the target of the just found
28720         # link could be in a different directory
28721         cd `$DIRNAME $ISLINK`
28722         sym_link_dir=`$THEPWDCMD -P`
28723         sym_link_file=`$BASENAME $ISLINK`
28724         let COUNTER=COUNTER+1
28725       done
28726       cd $STARTDIR
28727       PROPER_COMPILER_CC=$sym_link_dir/$sym_link_file
28728     fi
28729   fi
28730 
28731     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5
28732 $as_echo "$PROPER_COMPILER_CC" >&6; }
28733     CC="$PROPER_COMPILER_CC"
28734   else
28735     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CC" >&5
28736 $as_echo "no, keeping CC" >&6; }
28737   fi
28738 
28739 
28740   COMPILER=$CC
28741   COMPILER_NAME=$COMPILER_NAME
28742 
28743   if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
28744     # cc -V output typically looks like
28745     #     cc: Sun C 5.12 Linux_i386 2011/11/16
28746     COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1`
28747     # Check that this is likely to be the Solaris Studio cc.
28748     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null
28749     if test $? -ne 0; then
28750       ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28751       { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5
28752 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28753       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28754 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28755       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
28756 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
28757       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28758     fi
28759     # Remove usage instructions (if present), and
28760     # collapse compiler output into a single line
28761     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
28762         $SED -e 's/ *[Uu]sage:.*//'`
28763     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28764         $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"`
28765   elif test  "x$TOOLCHAIN_TYPE" = xxlc; then
28766     # xlc -qversion output typically looks like
28767     #     IBM XL C/C++ for AIX, V11.1 (5724-X13)
28768     #     Version: 11.01.0000.0015
28769     COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1`
28770     # Check that this is likely to be the IBM XL C compiler.
28771     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null
28772     if test $? -ne 0; then
28773       ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28774       { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5
28775 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28776       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28777 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28778       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
28779 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
28780       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28781     fi
28782     # Collapse compiler output into a single line
28783     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
28784     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28785         $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'`
28786   elif test  "x$TOOLCHAIN_TYPE" = xmicrosoft; then
28787     # There is no specific version flag, but all output starts with a version string.
28788     # First line typically looks something like:
28789     # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86
28790     COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'`
28791     # Check that this is likely to be Microsoft CL.EXE.
28792     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null
28793     if test $? -ne 0; then
28794       { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5
28795 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28796       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28797 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28798       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28799     fi
28800     # Collapse compiler output into a single line
28801     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
28802     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28803         $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'`
28804   elif test  "x$TOOLCHAIN_TYPE" = xgcc; then
28805     # gcc --version output typically looks like
28806     #     gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1
28807     #     Copyright (C) 2013 Free Software Foundation, Inc.
28808     #     This is free software; see the source for copying conditions.  There is NO
28809     #     warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
28810     COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28811     # Check that this is likely to be GCC.
28812     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null
28813     if test $? -ne 0; then
28814       { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5
28815 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28816       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5
28817 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;}
28818       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28819     fi
28820     # Remove Copyright and legalese from version string, and
28821     # collapse into a single line
28822     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
28823         $SED -e 's/ *Copyright .*//'`
28824     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28825         $SED -e 's/^.* \([1-9]\.[0-9.]*\) .*$/\1/'`
28826   elif test  "x$TOOLCHAIN_TYPE" = xclang; then
28827     # clang --version output typically looks like
28828     #    Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
28829     #    clang version 3.3 (tags/RELEASE_33/final)
28830     # or
28831     #    Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2)
28832     #    Target: x86_64-pc-linux-gnu
28833     #    Thread model: posix
28834     COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
28835     # Check that this is likely to be clang
28836     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null
28837     if test $? -ne 0; then
28838       { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5
28839 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
28840       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5
28841 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
28842       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
28843     fi
28844     # Collapse compiler output into a single line
28845     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
28846     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
28847         $SED -e 's/^.*clang version \([1-9][0-9.]*\).*$/\1/'`
28848   else
28849       as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5
28850   fi
28851   # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker)
28852   CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER"
28853   # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker)
28854   CC_VERSION_STRING="$COMPILER_VERSION_STRING"
28855 
28856   { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5
28857 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;}
28858 
28859 
28860   # Now that we have resolved CC ourself, let autoconf have its go at it
28861   ac_ext=c
28862 ac_cpp='$CPP $CPPFLAGS'
28863 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
28864 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
28865 ac_compiler_gnu=$ac_cv_c_compiler_gnu
28866 if test -n "$ac_tool_prefix"; then
28867   for ac_prog in $CC
28868   do
28869     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
28870 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
28871 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28872 $as_echo_n "checking for $ac_word... " >&6; }
28873 if ${ac_cv_prog_CC+:} false; then :
28874   $as_echo_n "(cached) " >&6
28875 else
28876   if test -n "$CC"; then
28877   ac_cv_prog_CC="$CC" # Let the user override the test.
28878 else
28879 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28880 for as_dir in $PATH
28881 do
28882   IFS=$as_save_IFS
28883   test -z "$as_dir" && as_dir=.
28884     for ac_exec_ext in '' $ac_executable_extensions; do
28885   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28886     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
28887     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28888     break 2
28889   fi
28890 done
28891   done
28892 IFS=$as_save_IFS
28893 
28894 fi
28895 fi
28896 CC=$ac_cv_prog_CC
28897 if test -n "$CC"; then
28898   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
28899 $as_echo "$CC" >&6; }
28900 else
28901   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28902 $as_echo "no" >&6; }
28903 fi
28904 
28905 
28906     test -n "$CC" && break
28907   done
28908 fi
28909 if test -z "$CC"; then
28910   ac_ct_CC=$CC
28911   for ac_prog in $CC
28912 do
28913   # Extract the first word of "$ac_prog", so it can be a program name with args.
28914 set dummy $ac_prog; ac_word=$2
28915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28916 $as_echo_n "checking for $ac_word... " >&6; }
28917 if ${ac_cv_prog_ac_ct_CC+:} false; then :
28918   $as_echo_n "(cached) " >&6
28919 else
28920   if test -n "$ac_ct_CC"; then
28921   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
28922 else
28923 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28924 for as_dir in $PATH
28925 do
28926   IFS=$as_save_IFS
28927   test -z "$as_dir" && as_dir=.
28928     for ac_exec_ext in '' $ac_executable_extensions; do
28929   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28930     ac_cv_prog_ac_ct_CC="$ac_prog"
28931     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28932     break 2
28933   fi
28934 done
28935   done
28936 IFS=$as_save_IFS
28937 
28938 fi
28939 fi
28940 ac_ct_CC=$ac_cv_prog_ac_ct_CC
28941 if test -n "$ac_ct_CC"; then
28942   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
28943 $as_echo "$ac_ct_CC" >&6; }
28944 else
28945   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28946 $as_echo "no" >&6; }
28947 fi
28948 
28949 
28950   test -n "$ac_ct_CC" && break
28951 done
28952 
28953   if test "x$ac_ct_CC" = x; then
28954     CC=""
28955   else
28956     case $cross_compiling:$ac_tool_warned in
28957 yes:)
28958 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
28959 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
28960 ac_tool_warned=yes ;;
28961 esac
28962     CC=$ac_ct_CC
28963   fi
28964 fi
28965 
28966 
28967 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28968 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28969 as_fn_error $? "no acceptable C compiler found in \$PATH
28970 See \`config.log' for more details" "$LINENO" 5; }
28971 
28972 # Provide some information about the compiler.
28973 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
28974 set X $ac_compile
28975 ac_compiler=$2
28976 for ac_option in --version -v -V -qversion; do
28977   { { ac_try="$ac_compiler $ac_option >&5"
28978 case "(($ac_try" in
28979   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28980   *) ac_try_echo=$ac_try;;
28981 esac
28982 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
28983 $as_echo "$ac_try_echo"; } >&5
28984   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
28985   ac_status=$?
28986   if test -s conftest.err; then
28987     sed '10a\
28988 ... rest of stderr output deleted ...
28989          10q' conftest.err >conftest.er1
28990     cat conftest.er1 >&5
28991   fi
28992   rm -f conftest.er1 conftest.err
28993   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28994   test $ac_status = 0; }
28995 done
28996 
28997 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28998 /* end confdefs.h.  */
28999 
29000 int
29001 main ()
29002 {
29003 
29004   ;
29005   return 0;
29006 }
29007 _ACEOF
29008 ac_clean_files_save=$ac_clean_files
29009 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
29010 # Try to create an executable without -o first, disregard a.out.
29011 # It will help us diagnose broken compilers, and finding out an intuition
29012 # of exeext.
29013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
29014 $as_echo_n "checking whether the C compiler works... " >&6; }
29015 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
29016 
29017 # The possible output files:
29018 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
29019 
29020 ac_rmfiles=
29021 for ac_file in $ac_files
29022 do
29023   case $ac_file in
29024     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
29025     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
29026   esac
29027 done
29028 rm -f $ac_rmfiles
29029 
29030 if { { ac_try="$ac_link_default"
29031 case "(($ac_try" in
29032   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29033   *) ac_try_echo=$ac_try;;
29034 esac
29035 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
29036 $as_echo "$ac_try_echo"; } >&5
29037   (eval "$ac_link_default") 2>&5
29038   ac_status=$?
29039   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
29040   test $ac_status = 0; }; then :
29041   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
29042 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
29043 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
29044 # so that the user can short-circuit this test for compilers unknown to
29045 # Autoconf.
29046 for ac_file in $ac_files ''
29047 do
29048   test -f "$ac_file" || continue
29049   case $ac_file in
29050     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
29051         ;;
29052     [ab].out )
29053         # We found the default executable, but exeext='' is most
29054         # certainly right.
29055         break;;
29056     *.* )
29057         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
29058         then :; else
29059            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
29060         fi
29061         # We set ac_cv_exeext here because the later test for it is not
29062         # safe: cross compilers may not add the suffix if given an `-o'
29063         # argument, so we may need to know it at that point already.
29064         # Even if this section looks crufty: it has the advantage of
29065         # actually working.
29066         break;;
29067     * )
29068         break;;
29069   esac
29070 done
29071 test "$ac_cv_exeext" = no && ac_cv_exeext=
29072 
29073 else
29074   ac_file=''
29075 fi
29076 if test -z "$ac_file"; then :
29077   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29078 $as_echo "no" >&6; }
29079 $as_echo "$as_me: failed program was:" >&5
29080 sed 's/^/| /' conftest.$ac_ext >&5
29081 
29082 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
29083 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
29084 as_fn_error 77 "C compiler cannot create executables
29085 See \`config.log' for more details" "$LINENO" 5; }
29086 else
29087   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
29088 $as_echo "yes" >&6; }
29089 fi
29090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
29091 $as_echo_n "checking for C compiler default output file name... " >&6; }
29092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
29093 $as_echo "$ac_file" >&6; }
29094 ac_exeext=$ac_cv_exeext
29095 
29096 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
29097 ac_clean_files=$ac_clean_files_save
29098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
29099 $as_echo_n "checking for suffix of executables... " >&6; }
29100 if { { ac_try="$ac_link"
29101 case "(($ac_try" in
29102   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29103   *) ac_try_echo=$ac_try;;
29104 esac
29105 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
29106 $as_echo "$ac_try_echo"; } >&5
29107   (eval "$ac_link") 2>&5
29108   ac_status=$?
29109   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
29110   test $ac_status = 0; }; then :
29111   # If both `conftest.exe' and `conftest' are `present' (well, observable)
29112 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
29113 # work properly (i.e., refer to `conftest.exe'), while it won't with
29114 # `rm'.
29115 for ac_file in conftest.exe conftest conftest.*; do
29116   test -f "$ac_file" || continue
29117   case $ac_file in
29118     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
29119     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
29120           break;;
29121     * ) break;;
29122   esac
29123 done
29124 else
29125   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
29126 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
29127 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
29128 See \`config.log' for more details" "$LINENO" 5; }
29129 fi
29130 rm -f conftest conftest$ac_cv_exeext
29131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
29132 $as_echo "$ac_cv_exeext" >&6; }
29133 
29134 rm -f conftest.$ac_ext
29135 EXEEXT=$ac_cv_exeext
29136 ac_exeext=$EXEEXT
29137 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29138 /* end confdefs.h.  */
29139 #include <stdio.h>
29140 int
29141 main ()
29142 {
29143 FILE *f = fopen ("conftest.out", "w");
29144  return ferror (f) || fclose (f) != 0;
29145 
29146   ;
29147   return 0;
29148 }
29149 _ACEOF
29150 ac_clean_files="$ac_clean_files conftest.out"
29151 # Check that the compiler produces executables we can run.  If not, either
29152 # the compiler is broken, or we cross compile.
29153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
29154 $as_echo_n "checking whether we are cross compiling... " >&6; }
29155 if test "$cross_compiling" != yes; then
29156   { { ac_try="$ac_link"
29157 case "(($ac_try" in
29158   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29159   *) ac_try_echo=$ac_try;;
29160 esac
29161 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
29162 $as_echo "$ac_try_echo"; } >&5
29163   (eval "$ac_link") 2>&5
29164   ac_status=$?
29165   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
29166   test $ac_status = 0; }
29167   if { ac_try='./conftest$ac_cv_exeext'
29168   { { case "(($ac_try" in
29169   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29170   *) ac_try_echo=$ac_try;;
29171 esac
29172 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
29173 $as_echo "$ac_try_echo"; } >&5
29174   (eval "$ac_try") 2>&5
29175   ac_status=$?
29176   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
29177   test $ac_status = 0; }; }; then
29178     cross_compiling=no
29179   else
29180     if test "$cross_compiling" = maybe; then
29181         cross_compiling=yes
29182     else
29183         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
29184 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
29185 as_fn_error $? "cannot run C compiled programs.
29186 If you meant to cross compile, use \`--host'.
29187 See \`config.log' for more details" "$LINENO" 5; }
29188     fi
29189   fi
29190 fi
29191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
29192 $as_echo "$cross_compiling" >&6; }
29193 
29194 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
29195 ac_clean_files=$ac_clean_files_save
29196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
29197 $as_echo_n "checking for suffix of object files... " >&6; }
29198 if ${ac_cv_objext+:} false; then :
29199   $as_echo_n "(cached) " >&6
29200 else
29201   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29202 /* end confdefs.h.  */
29203 
29204 int
29205 main ()
29206 {
29207 
29208   ;
29209   return 0;
29210 }
29211 _ACEOF
29212 rm -f conftest.o conftest.obj
29213 if { { ac_try="$ac_compile"
29214 case "(($ac_try" in
29215   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29216   *) ac_try_echo=$ac_try;;
29217 esac
29218 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
29219 $as_echo "$ac_try_echo"; } >&5
29220   (eval "$ac_compile") 2>&5
29221   ac_status=$?
29222   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
29223   test $ac_status = 0; }; then :
29224   for ac_file in conftest.o conftest.obj conftest.*; do
29225   test -f "$ac_file" || continue;
29226   case $ac_file in
29227     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
29228     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
29229        break;;
29230   esac
29231 done
29232 else
29233   $as_echo "$as_me: failed program was:" >&5
29234 sed 's/^/| /' conftest.$ac_ext >&5
29235 
29236 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
29237 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
29238 as_fn_error $? "cannot compute suffix of object files: cannot compile
29239 See \`config.log' for more details" "$LINENO" 5; }
29240 fi
29241 rm -f conftest.$ac_cv_objext conftest.$ac_ext
29242 fi
29243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
29244 $as_echo "$ac_cv_objext" >&6; }
29245 OBJEXT=$ac_cv_objext
29246 ac_objext=$OBJEXT
29247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
29248 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
29249 if ${ac_cv_c_compiler_gnu+:} false; then :
29250   $as_echo_n "(cached) " >&6
29251 else
29252   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29253 /* end confdefs.h.  */
29254 
29255 int
29256 main ()
29257 {
29258 #ifndef __GNUC__
29259        choke me
29260 #endif
29261 
29262   ;
29263   return 0;
29264 }
29265 _ACEOF
29266 if ac_fn_c_try_compile "$LINENO"; then :
29267   ac_compiler_gnu=yes
29268 else
29269   ac_compiler_gnu=no
29270 fi
29271 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29272 ac_cv_c_compiler_gnu=$ac_compiler_gnu
29273 
29274 fi
29275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
29276 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
29277 if test $ac_compiler_gnu = yes; then
29278   GCC=yes
29279 else
29280   GCC=
29281 fi
29282 ac_test_CFLAGS=${CFLAGS+set}
29283 ac_save_CFLAGS=$CFLAGS
29284 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
29285 $as_echo_n "checking whether $CC accepts -g... " >&6; }
29286 if ${ac_cv_prog_cc_g+:} false; then :
29287   $as_echo_n "(cached) " >&6
29288 else
29289   ac_save_c_werror_flag=$ac_c_werror_flag
29290    ac_c_werror_flag=yes
29291    ac_cv_prog_cc_g=no
29292    CFLAGS="-g"
29293    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29294 /* end confdefs.h.  */
29295 
29296 int
29297 main ()
29298 {
29299 
29300   ;
29301   return 0;
29302 }
29303 _ACEOF
29304 if ac_fn_c_try_compile "$LINENO"; then :
29305   ac_cv_prog_cc_g=yes
29306 else
29307   CFLAGS=""
29308       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29309 /* end confdefs.h.  */
29310 
29311 int
29312 main ()
29313 {
29314 
29315   ;
29316   return 0;
29317 }
29318 _ACEOF
29319 if ac_fn_c_try_compile "$LINENO"; then :
29320 
29321 else
29322   ac_c_werror_flag=$ac_save_c_werror_flag
29323          CFLAGS="-g"
29324          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29325 /* end confdefs.h.  */
29326 
29327 int
29328 main ()
29329 {
29330 
29331   ;
29332   return 0;
29333 }
29334 _ACEOF
29335 if ac_fn_c_try_compile "$LINENO"; then :
29336   ac_cv_prog_cc_g=yes
29337 fi
29338 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29339 fi
29340 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29341 fi
29342 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29343    ac_c_werror_flag=$ac_save_c_werror_flag
29344 fi
29345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
29346 $as_echo "$ac_cv_prog_cc_g" >&6; }
29347 if test "$ac_test_CFLAGS" = set; then
29348   CFLAGS=$ac_save_CFLAGS
29349 elif test $ac_cv_prog_cc_g = yes; then
29350   if test "$GCC" = yes; then
29351     CFLAGS="-g -O2"
29352   else
29353     CFLAGS="-g"
29354   fi
29355 else
29356   if test "$GCC" = yes; then
29357     CFLAGS="-O2"
29358   else
29359     CFLAGS=
29360   fi
29361 fi
29362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
29363 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
29364 if ${ac_cv_prog_cc_c89+:} false; then :
29365   $as_echo_n "(cached) " >&6
29366 else
29367   ac_cv_prog_cc_c89=no
29368 ac_save_CC=$CC
29369 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29370 /* end confdefs.h.  */
29371 #include <stdarg.h>
29372 #include <stdio.h>
29373 struct stat;
29374 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
29375 struct buf { int x; };
29376 FILE * (*rcsopen) (struct buf *, struct stat *, int);
29377 static char *e (p, i)
29378      char **p;
29379      int i;
29380 {
29381   return p[i];
29382 }
29383 static char *f (char * (*g) (char **, int), char **p, ...)
29384 {
29385   char *s;
29386   va_list v;
29387   va_start (v,p);
29388   s = g (p, va_arg (v,int));
29389   va_end (v);
29390   return s;
29391 }
29392 
29393 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
29394    function prototypes and stuff, but not '\xHH' hex character constants.
29395    These don't provoke an error unfortunately, instead are silently treated
29396    as 'x'.  The following induces an error, until -std is added to get
29397    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
29398    array size at least.  It's necessary to write '\x00'==0 to get something
29399    that's true only with -std.  */
29400 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
29401 
29402 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
29403    inside strings and character constants.  */
29404 #define FOO(x) 'x'
29405 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
29406 
29407 int test (int i, double x);
29408 struct s1 {int (*f) (int a);};
29409 struct s2 {int (*f) (double a);};
29410 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
29411 int argc;
29412 char **argv;
29413 int
29414 main ()
29415 {
29416 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
29417   ;
29418   return 0;
29419 }
29420 _ACEOF
29421 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
29422         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
29423 do
29424   CC="$ac_save_CC $ac_arg"
29425   if ac_fn_c_try_compile "$LINENO"; then :
29426   ac_cv_prog_cc_c89=$ac_arg
29427 fi
29428 rm -f core conftest.err conftest.$ac_objext
29429   test "x$ac_cv_prog_cc_c89" != "xno" && break
29430 done
29431 rm -f conftest.$ac_ext
29432 CC=$ac_save_CC
29433 
29434 fi
29435 # AC_CACHE_VAL
29436 case "x$ac_cv_prog_cc_c89" in
29437   x)
29438     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
29439 $as_echo "none needed" >&6; } ;;
29440   xno)
29441     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
29442 $as_echo "unsupported" >&6; } ;;
29443   *)
29444     CC="$CC $ac_cv_prog_cc_c89"
29445     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
29446 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
29447 esac
29448 if test "x$ac_cv_prog_cc_c89" != xno; then :
29449 
29450 fi
29451 
29452 ac_ext=cpp
29453 ac_cpp='$CXXCPP $CPPFLAGS'
29454 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
29455 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
29456 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
29457 
29458 
29459 
29460   COMPILER_NAME=C++
29461   SEARCH_LIST="$TOOLCHAIN_CXX_BINARY"
29462 
29463   if test "x$CXX" != x; then
29464     # User has supplied compiler name already, always let that override.
29465     { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CXX=$CXX" >&5
29466 $as_echo "$as_me: Will use user supplied compiler CXX=$CXX" >&6;}
29467     if test "x`basename $CXX`" = "x$CXX"; then
29468       # A command without a complete path is provided, search $PATH.
29469 
29470       for ac_prog in $CXX
29471 do
29472   # Extract the first word of "$ac_prog", so it can be a program name with args.
29473 set dummy $ac_prog; ac_word=$2
29474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29475 $as_echo_n "checking for $ac_word... " >&6; }
29476 if ${ac_cv_path_POTENTIAL_CXX+:} false; then :
29477   $as_echo_n "(cached) " >&6
29478 else
29479   case $POTENTIAL_CXX in
29480   [\\/]* | ?:[\\/]*)
29481   ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path.
29482   ;;
29483   *)
29484   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29485 for as_dir in $PATH
29486 do
29487   IFS=$as_save_IFS
29488   test -z "$as_dir" && as_dir=.
29489     for ac_exec_ext in '' $ac_executable_extensions; do
29490   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29491     ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext"
29492     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29493     break 2
29494   fi
29495 done
29496   done
29497 IFS=$as_save_IFS
29498 
29499   ;;
29500 esac
29501 fi
29502 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX
29503 if test -n "$POTENTIAL_CXX"; then
29504   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5
29505 $as_echo "$POTENTIAL_CXX" >&6; }
29506 else
29507   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29508 $as_echo "no" >&6; }
29509 fi
29510 
29511 
29512   test -n "$POTENTIAL_CXX" && break
29513 done
29514 
29515       if test "x$POTENTIAL_CXX" != x; then
29516         CXX=$POTENTIAL_CXX
29517       else
29518         as_fn_error $? "User supplied compiler CXX=$CXX could not be found" "$LINENO" 5
29519       fi
29520     else
29521       # Otherwise it might already be a complete path
29522       if test ! -x "$CXX"; then
29523         as_fn_error $? "User supplied compiler CXX=$CXX does not exist" "$LINENO" 5
29524       fi
29525     fi
29526   else
29527     # No user supplied value. Locate compiler ourselves.
29528 
29529     # If we are cross compiling, assume cross compilation tools follows the
29530     # cross compilation standard where they are prefixed with the autoconf
29531     # standard name for the target. For example the binary
29532     # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10.
29533     # If we are not cross compiling, then the default compiler name will be
29534     # used.
29535 
29536     CXX=
29537     # If TOOLCHAIN_PATH is set, check for all compiler names in there first
29538     # before checking the rest of the PATH.
29539     # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION
29540     # step, this should not be necessary.
29541     if test -n "$TOOLCHAIN_PATH"; then
29542       PATH_save="$PATH"
29543       PATH="$TOOLCHAIN_PATH"
29544       for ac_prog in $SEARCH_LIST
29545 do
29546   # Extract the first word of "$ac_prog", so it can be a program name with args.
29547 set dummy $ac_prog; ac_word=$2
29548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29549 $as_echo_n "checking for $ac_word... " >&6; }
29550 if ${ac_cv_path_TOOLCHAIN_PATH_CXX+:} false; then :
29551   $as_echo_n "(cached) " >&6
29552 else
29553   case $TOOLCHAIN_PATH_CXX in
29554   [\\/]* | ?:[\\/]*)
29555   ac_cv_path_TOOLCHAIN_PATH_CXX="$TOOLCHAIN_PATH_CXX" # Let the user override the test with a path.
29556   ;;
29557   *)
29558   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29559 for as_dir in $PATH
29560 do
29561   IFS=$as_save_IFS
29562   test -z "$as_dir" && as_dir=.
29563     for ac_exec_ext in '' $ac_executable_extensions; do
29564   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29565     ac_cv_path_TOOLCHAIN_PATH_CXX="$as_dir/$ac_word$ac_exec_ext"
29566     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29567     break 2
29568   fi
29569 done
29570   done
29571 IFS=$as_save_IFS
29572 
29573   ;;
29574 esac
29575 fi
29576 TOOLCHAIN_PATH_CXX=$ac_cv_path_TOOLCHAIN_PATH_CXX
29577 if test -n "$TOOLCHAIN_PATH_CXX"; then
29578   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CXX" >&5
29579 $as_echo "$TOOLCHAIN_PATH_CXX" >&6; }
29580 else
29581   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29582 $as_echo "no" >&6; }
29583 fi
29584 
29585 
29586   test -n "$TOOLCHAIN_PATH_CXX" && break
29587 done
29588 
29589       CXX=$TOOLCHAIN_PATH_CXX
29590       PATH="$PATH_save"
29591     fi
29592 
29593     # AC_PATH_PROGS can't be run multiple times with the same variable,
29594     # so create a new name for this run.
29595     if test "x$CXX" = x; then
29596       for ac_prog in $SEARCH_LIST
29597 do
29598   # Extract the first word of "$ac_prog", so it can be a program name with args.
29599 set dummy $ac_prog; ac_word=$2
29600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29601 $as_echo_n "checking for $ac_word... " >&6; }
29602 if ${ac_cv_path_POTENTIAL_CXX+:} false; then :
29603   $as_echo_n "(cached) " >&6
29604 else
29605   case $POTENTIAL_CXX in
29606   [\\/]* | ?:[\\/]*)
29607   ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path.
29608   ;;
29609   *)
29610   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29611 for as_dir in $PATH
29612 do
29613   IFS=$as_save_IFS
29614   test -z "$as_dir" && as_dir=.
29615     for ac_exec_ext in '' $ac_executable_extensions; do
29616   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29617     ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext"
29618     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29619     break 2
29620   fi
29621 done
29622   done
29623 IFS=$as_save_IFS
29624 
29625   ;;
29626 esac
29627 fi
29628 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX
29629 if test -n "$POTENTIAL_CXX"; then
29630   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5
29631 $as_echo "$POTENTIAL_CXX" >&6; }
29632 else
29633   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29634 $as_echo "no" >&6; }
29635 fi
29636 
29637 
29638   test -n "$POTENTIAL_CXX" && break
29639 done
29640 
29641       CXX=$POTENTIAL_CXX
29642     fi
29643 
29644     if test "x$CXX" = x; then
29645 
29646   # Print a helpful message on how to acquire the necessary build dependency.
29647   # devkit is the help tag: freetype, cups, pulse, alsa etc
29648   MISSING_DEPENDENCY=devkit
29649 
29650   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29651     cygwin_help $MISSING_DEPENDENCY
29652   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29653     msys_help $MISSING_DEPENDENCY
29654   else
29655     PKGHANDLER_COMMAND=
29656 
29657     case $PKGHANDLER in
29658       apt-get)
29659         apt_help     $MISSING_DEPENDENCY ;;
29660       yum)
29661         yum_help     $MISSING_DEPENDENCY ;;
29662       port)
29663         port_help    $MISSING_DEPENDENCY ;;
29664       pkgutil)
29665         pkgutil_help $MISSING_DEPENDENCY ;;
29666       pkgadd)
29667         pkgadd_help  $MISSING_DEPENDENCY ;;
29668     esac
29669 
29670     if test "x$PKGHANDLER_COMMAND" != x; then
29671       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
29672     fi
29673   fi
29674 
29675       as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5
29676     fi
29677   fi
29678 
29679   # Now we have a compiler binary in CXX. Make sure it's okay.
29680 
29681   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29682 
29683   # First separate the path from the arguments. This will split at the first
29684   # space.
29685   complete="$CXX"
29686   path="${complete%% *}"
29687   tmp="$complete EOL"
29688   arguments="${tmp#* }"
29689 
29690   # Input might be given as Windows format, start by converting to
29691   # unix format.
29692   new_path=`$CYGPATH -u "$path"`
29693 
29694   # Now try to locate executable using which
29695   new_path=`$WHICH "$new_path" 2> /dev/null`
29696   # bat and cmd files are not always considered executable in cygwin causing which
29697   # to not find them
29698   if test "x$new_path" = x \
29699       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29700       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29701     new_path=`$CYGPATH -u "$path"`
29702   fi
29703   if test "x$new_path" = x; then
29704     # Oops. Which didn't find the executable.
29705     # The splitting of arguments from the executable at a space might have been incorrect,
29706     # since paths with space are more likely in Windows. Give it another try with the whole
29707     # argument.
29708     path="$complete"
29709     arguments="EOL"
29710     new_path=`$CYGPATH -u "$path"`
29711     new_path=`$WHICH "$new_path" 2> /dev/null`
29712     # bat and cmd files are not always considered executable in cygwin causing which
29713     # to not find them
29714     if test "x$new_path" = x \
29715         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29716         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29717       new_path=`$CYGPATH -u "$path"`
29718     fi
29719     if test "x$new_path" = x; then
29720       # It's still not found. Now this is an unrecoverable error.
29721       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
29722 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
29723       has_space=`$ECHO "$complete" | $GREP " "`
29724       if test "x$has_space" != x; then
29725         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29726 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29727       fi
29728       as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29729     fi
29730   fi
29731 
29732   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
29733   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
29734   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
29735   # "foo.exe" is OK but "foo" is an error.
29736   #
29737   # This test is therefore slightly more accurate than "test -f" to check for file presence.
29738   # It is also a way to make sure we got the proper file name for the real test later on.
29739   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
29740   if test "x$test_shortpath" = x; then
29741     # Short path failed, file does not exist as specified.
29742     # Try adding .exe or .cmd
29743     if test -f "${new_path}.exe"; then
29744       input_to_shortpath="${new_path}.exe"
29745     elif test -f "${new_path}.cmd"; then
29746       input_to_shortpath="${new_path}.cmd"
29747     else
29748       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$new_path\", is invalid." >&5
29749 $as_echo "$as_me: The path of CXX, which resolves as \"$new_path\", is invalid." >&6;}
29750       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
29751 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
29752       as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29753     fi
29754   else
29755     input_to_shortpath="$new_path"
29756   fi
29757 
29758   # Call helper function which possibly converts this using DOS-style short mode.
29759   # If so, the updated path is stored in $new_path.
29760   new_path="$input_to_shortpath"
29761 
29762   input_path="$input_to_shortpath"
29763   # Check if we need to convert this using DOS-style short mode. If the path
29764   # contains just simple characters, use it. Otherwise (spaces, weird characters),
29765   # take no chances and rewrite it.
29766   # Note: m4 eats our [], so we need to use [ and ] instead.
29767   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
29768   if test "x$has_forbidden_chars" != x; then
29769     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29770     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
29771     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
29772     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
29773       # Going to short mode and back again did indeed matter. Since short mode is
29774       # case insensitive, let's make it lowercase to improve readability.
29775       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29776       # Now convert it back to Unix-stile (cygpath)
29777       input_path=`$CYGPATH -u "$shortmode_path"`
29778       new_path="$input_path"
29779     fi
29780   fi
29781 
29782   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
29783   if test "x$test_cygdrive_prefix" = x; then
29784     # As a simple fix, exclude /usr/bin since it's not a real path.
29785     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
29786       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
29787       # a path prefixed by /cygdrive for fixpath to work.
29788       new_path="$CYGWIN_ROOT_PATH$input_path"
29789     fi
29790   fi
29791 
29792   # remove trailing .exe if any
29793   new_path="${new_path/%.exe/}"
29794 
29795   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29796 
29797   # First separate the path from the arguments. This will split at the first
29798   # space.
29799   complete="$CXX"
29800   path="${complete%% *}"
29801   tmp="$complete EOL"
29802   arguments="${tmp#* }"
29803 
29804   # Input might be given as Windows format, start by converting to
29805   # unix format.
29806   new_path="$path"
29807 
29808   windows_path="$new_path"
29809   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29810     unix_path=`$CYGPATH -u "$windows_path"`
29811     new_path="$unix_path"
29812   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29813     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29814     new_path="$unix_path"
29815   fi
29816 
29817 
29818   # Now try to locate executable using which
29819   new_path=`$WHICH "$new_path" 2> /dev/null`
29820 
29821   if test "x$new_path" = x; then
29822     # Oops. Which didn't find the executable.
29823     # The splitting of arguments from the executable at a space might have been incorrect,
29824     # since paths with space are more likely in Windows. Give it another try with the whole
29825     # argument.
29826     path="$complete"
29827     arguments="EOL"
29828     new_path="$path"
29829 
29830   windows_path="$new_path"
29831   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29832     unix_path=`$CYGPATH -u "$windows_path"`
29833     new_path="$unix_path"
29834   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29835     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29836     new_path="$unix_path"
29837   fi
29838 
29839 
29840     new_path=`$WHICH "$new_path" 2> /dev/null`
29841     # bat and cmd files are not always considered executable in MSYS causing which
29842     # to not find them
29843     if test "x$new_path" = x \
29844         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
29845         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
29846       new_path="$path"
29847 
29848   windows_path="$new_path"
29849   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29850     unix_path=`$CYGPATH -u "$windows_path"`
29851     new_path="$unix_path"
29852   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29853     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29854     new_path="$unix_path"
29855   fi
29856 
29857     fi
29858 
29859     if test "x$new_path" = x; then
29860       # It's still not found. Now this is an unrecoverable error.
29861       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
29862 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
29863       has_space=`$ECHO "$complete" | $GREP " "`
29864       if test "x$has_space" != x; then
29865         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
29866 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
29867       fi
29868       as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29869     fi
29870   fi
29871 
29872   # Now new_path has a complete unix path to the binary
29873   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
29874     # Keep paths in /bin as-is, but remove trailing .exe if any
29875     new_path="${new_path/%.exe/}"
29876     # Do not save /bin paths to all_fixpath_prefixes!
29877   else
29878     # Not in mixed or Windows style, start by that.
29879     new_path=`cmd //c echo $new_path`
29880 
29881   input_path="$new_path"
29882   # Check if we need to convert this using DOS-style short mode. If the path
29883   # contains just simple characters, use it. Otherwise (spaces, weird characters),
29884   # take no chances and rewrite it.
29885   # Note: m4 eats our [], so we need to use [ and ] instead.
29886   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
29887   if test "x$has_forbidden_chars" != x; then
29888     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
29889     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
29890   fi
29891 
29892     # Output is in $new_path
29893 
29894   windows_path="$new_path"
29895   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
29896     unix_path=`$CYGPATH -u "$windows_path"`
29897     new_path="$unix_path"
29898   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
29899     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
29900     new_path="$unix_path"
29901   fi
29902 
29903     # remove trailing .exe if any
29904     new_path="${new_path/%.exe/}"
29905 
29906     # Save the first 10 bytes of this path to the storage, so fixpath can work.
29907     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
29908   fi
29909 
29910   else
29911     # We're on a unix platform. Hooray! :)
29912     # First separate the path from the arguments. This will split at the first
29913     # space.
29914     complete="$CXX"
29915     path="${complete%% *}"
29916     tmp="$complete EOL"
29917     arguments="${tmp#* }"
29918 
29919     # Cannot rely on the command "which" here since it doesn't always work.
29920     is_absolute_path=`$ECHO "$path" | $GREP ^/`
29921     if test -z "$is_absolute_path"; then
29922       # Path to executable is not absolute. Find it.
29923       IFS_save="$IFS"
29924       IFS=:
29925       for p in $PATH; do
29926         if test -f "$p/$path" && test -x "$p/$path"; then
29927           new_path="$p/$path"
29928           break
29929         fi
29930       done
29931       IFS="$IFS_save"
29932     else
29933       # This is an absolute path, we can use it without further modifications.
29934       new_path="$path"
29935     fi
29936 
29937     if test "x$new_path" = x; then
29938       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5
29939 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;}
29940       has_space=`$ECHO "$complete" | $GREP " "`
29941       if test "x$has_space" != x; then
29942         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
29943 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
29944       fi
29945       as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5
29946     fi
29947   fi
29948 
29949   # Now join together the path and the arguments once again
29950   if test "x$arguments" != xEOL; then
29951     new_complete="$new_path ${arguments% *}"
29952   else
29953     new_complete="$new_path"
29954   fi
29955 
29956   if test "x$complete" != "x$new_complete"; then
29957     CXX="$new_complete"
29958     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXX to \"$new_complete\"" >&5
29959 $as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;}
29960   fi
29961 
29962   TEST_COMPILER="$CXX"
29963   # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links
29964   # to 'xlc' but it is crucial that we invoke the compiler with the right name!
29965   if test "x$OPENJDK_BUILD_OS" != xaix; then
29966     # FIXME: This test should not be needed anymore; we don't do that for any platform.
29967     { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5
29968 $as_echo_n "checking resolved symbolic links for CXX... " >&6; }
29969 
29970   if test "x$OPENJDK_BUILD_OS" != xwindows; then
29971     # Follow a chain of symbolic links. Use readlink
29972     # where it exists, else fall back to horribly
29973     # complicated shell code.
29974     if test "x$READLINK_TESTED" != yes; then
29975       # On MacOSX there is a readlink tool with a different
29976       # purpose than the GNU readlink tool. Check the found readlink.
29977       ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
29978       if test "x$ISGNU" = x; then
29979         # A readlink that we do not know how to use.
29980         # Are there other non-GNU readlinks out there?
29981         READLINK_TESTED=yes
29982         READLINK=
29983       fi
29984     fi
29985 
29986     if test "x$READLINK" != x; then
29987       TEST_COMPILER=`$READLINK -f $TEST_COMPILER`
29988     else
29989       # Save the current directory for restoring afterwards
29990       STARTDIR=$PWD
29991       COUNTER=0
29992       sym_link_dir=`$DIRNAME $TEST_COMPILER`
29993       sym_link_file=`$BASENAME $TEST_COMPILER`
29994       cd $sym_link_dir
29995       # Use -P flag to resolve symlinks in directories.
29996       cd `$THEPWDCMD -P`
29997       sym_link_dir=`$THEPWDCMD -P`
29998       # Resolve file symlinks
29999       while test $COUNTER -lt 20; do
30000         ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
30001         if test "x$ISLINK" == x; then
30002           # This is not a symbolic link! We are done!
30003           break
30004         fi
30005         # Again resolve directory symlinks since the target of the just found
30006         # link could be in a different directory
30007         cd `$DIRNAME $ISLINK`
30008         sym_link_dir=`$THEPWDCMD -P`
30009         sym_link_file=`$BASENAME $ISLINK`
30010         let COUNTER=COUNTER+1
30011       done
30012       cd $STARTDIR
30013       TEST_COMPILER=$sym_link_dir/$sym_link_file
30014     fi
30015   fi
30016 
30017     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5
30018 $as_echo "$TEST_COMPILER" >&6; }
30019   fi
30020   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CXX is disguised ccache" >&5
30021 $as_echo_n "checking if CXX is disguised ccache... " >&6; }
30022 
30023   COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"`
30024   if test "x$COMPILER_BASENAME" = "xccache"; then
30025     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5
30026 $as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; }
30027     # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache.
30028     # We want to control ccache invocation ourselves, so ignore this cc and try
30029     # searching again.
30030 
30031     # Remove the path to the fake ccache cc from the PATH
30032     RETRY_COMPILER_SAVED_PATH="$PATH"
30033     COMPILER_DIRNAME=`$DIRNAME $CXX`
30034     PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`"
30035 
30036     # Try again looking for our compiler
30037     if test -n "$ac_tool_prefix"; then
30038   for ac_prog in $TOOLCHAIN_CXX_BINARY
30039   do
30040     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
30041 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
30042 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
30043 $as_echo_n "checking for $ac_word... " >&6; }
30044 if ${ac_cv_prog_PROPER_COMPILER_CXX+:} false; then :
30045   $as_echo_n "(cached) " >&6
30046 else
30047   if test -n "$PROPER_COMPILER_CXX"; then
30048   ac_cv_prog_PROPER_COMPILER_CXX="$PROPER_COMPILER_CXX" # Let the user override the test.
30049 else
30050 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30051 for as_dir in $PATH
30052 do
30053   IFS=$as_save_IFS
30054   test -z "$as_dir" && as_dir=.
30055     for ac_exec_ext in '' $ac_executable_extensions; do
30056   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
30057     ac_cv_prog_PROPER_COMPILER_CXX="$ac_tool_prefix$ac_prog"
30058     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
30059     break 2
30060   fi
30061 done
30062   done
30063 IFS=$as_save_IFS
30064 
30065 fi
30066 fi
30067 PROPER_COMPILER_CXX=$ac_cv_prog_PROPER_COMPILER_CXX
30068 if test -n "$PROPER_COMPILER_CXX"; then
30069   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5
30070 $as_echo "$PROPER_COMPILER_CXX" >&6; }
30071 else
30072   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30073 $as_echo "no" >&6; }
30074 fi
30075 
30076 
30077     test -n "$PROPER_COMPILER_CXX" && break
30078   done
30079 fi
30080 if test -z "$PROPER_COMPILER_CXX"; then
30081   ac_ct_PROPER_COMPILER_CXX=$PROPER_COMPILER_CXX
30082   for ac_prog in $TOOLCHAIN_CXX_BINARY
30083 do
30084   # Extract the first word of "$ac_prog", so it can be a program name with args.
30085 set dummy $ac_prog; ac_word=$2
30086 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
30087 $as_echo_n "checking for $ac_word... " >&6; }
30088 if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CXX+:} false; then :
30089   $as_echo_n "(cached) " >&6
30090 else
30091   if test -n "$ac_ct_PROPER_COMPILER_CXX"; then
30092   ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_ct_PROPER_COMPILER_CXX" # Let the user override the test.
30093 else
30094 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30095 for as_dir in $PATH
30096 do
30097   IFS=$as_save_IFS
30098   test -z "$as_dir" && as_dir=.
30099     for ac_exec_ext in '' $ac_executable_extensions; do
30100   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
30101     ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_prog"
30102     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
30103     break 2
30104   fi
30105 done
30106   done
30107 IFS=$as_save_IFS
30108 
30109 fi
30110 fi
30111 ac_ct_PROPER_COMPILER_CXX=$ac_cv_prog_ac_ct_PROPER_COMPILER_CXX
30112 if test -n "$ac_ct_PROPER_COMPILER_CXX"; then
30113   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CXX" >&5
30114 $as_echo "$ac_ct_PROPER_COMPILER_CXX" >&6; }
30115 else
30116   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30117 $as_echo "no" >&6; }
30118 fi
30119 
30120 
30121   test -n "$ac_ct_PROPER_COMPILER_CXX" && break
30122 done
30123 
30124   if test "x$ac_ct_PROPER_COMPILER_CXX" = x; then
30125     PROPER_COMPILER_CXX=""
30126   else
30127     case $cross_compiling:$ac_tool_warned in
30128 yes:)
30129 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
30130 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
30131 ac_tool_warned=yes ;;
30132 esac
30133     PROPER_COMPILER_CXX=$ac_ct_PROPER_COMPILER_CXX
30134   fi
30135 fi
30136 
30137 
30138   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30139 
30140   # First separate the path from the arguments. This will split at the first
30141   # space.
30142   complete="$PROPER_COMPILER_CXX"
30143   path="${complete%% *}"
30144   tmp="$complete EOL"
30145   arguments="${tmp#* }"
30146 
30147   # Input might be given as Windows format, start by converting to
30148   # unix format.
30149   new_path=`$CYGPATH -u "$path"`
30150 
30151   # Now try to locate executable using which
30152   new_path=`$WHICH "$new_path" 2> /dev/null`
30153   # bat and cmd files are not always considered executable in cygwin causing which
30154   # to not find them
30155   if test "x$new_path" = x \
30156       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
30157       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
30158     new_path=`$CYGPATH -u "$path"`
30159   fi
30160   if test "x$new_path" = x; then
30161     # Oops. Which didn't find the executable.
30162     # The splitting of arguments from the executable at a space might have been incorrect,
30163     # since paths with space are more likely in Windows. Give it another try with the whole
30164     # argument.
30165     path="$complete"
30166     arguments="EOL"
30167     new_path=`$CYGPATH -u "$path"`
30168     new_path=`$WHICH "$new_path" 2> /dev/null`
30169     # bat and cmd files are not always considered executable in cygwin causing which
30170     # to not find them
30171     if test "x$new_path" = x \
30172         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
30173         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
30174       new_path=`$CYGPATH -u "$path"`
30175     fi
30176     if test "x$new_path" = x; then
30177       # It's still not found. Now this is an unrecoverable error.
30178       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
30179 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
30180       has_space=`$ECHO "$complete" | $GREP " "`
30181       if test "x$has_space" != x; then
30182         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
30183 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
30184       fi
30185       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
30186     fi
30187   fi
30188 
30189   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
30190   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
30191   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
30192   # "foo.exe" is OK but "foo" is an error.
30193   #
30194   # This test is therefore slightly more accurate than "test -f" to check for file presence.
30195   # It is also a way to make sure we got the proper file name for the real test later on.
30196   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
30197   if test "x$test_shortpath" = x; then
30198     # Short path failed, file does not exist as specified.
30199     # Try adding .exe or .cmd
30200     if test -f "${new_path}.exe"; then
30201       input_to_shortpath="${new_path}.exe"
30202     elif test -f "${new_path}.cmd"; then
30203       input_to_shortpath="${new_path}.cmd"
30204     else
30205       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&5
30206 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&6;}
30207       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
30208 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
30209       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
30210     fi
30211   else
30212     input_to_shortpath="$new_path"
30213   fi
30214 
30215   # Call helper function which possibly converts this using DOS-style short mode.
30216   # If so, the updated path is stored in $new_path.
30217   new_path="$input_to_shortpath"
30218 
30219   input_path="$input_to_shortpath"
30220   # Check if we need to convert this using DOS-style short mode. If the path
30221   # contains just simple characters, use it. Otherwise (spaces, weird characters),
30222   # take no chances and rewrite it.
30223   # Note: m4 eats our [], so we need to use [ and ] instead.
30224   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
30225   if test "x$has_forbidden_chars" != x; then
30226     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
30227     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
30228     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
30229     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
30230       # Going to short mode and back again did indeed matter. Since short mode is
30231       # case insensitive, let's make it lowercase to improve readability.
30232       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
30233       # Now convert it back to Unix-stile (cygpath)
30234       input_path=`$CYGPATH -u "$shortmode_path"`
30235       new_path="$input_path"
30236     fi
30237   fi
30238 
30239   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
30240   if test "x$test_cygdrive_prefix" = x; then
30241     # As a simple fix, exclude /usr/bin since it's not a real path.
30242     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
30243       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
30244       # a path prefixed by /cygdrive for fixpath to work.
30245       new_path="$CYGWIN_ROOT_PATH$input_path"
30246     fi
30247   fi
30248 
30249   # remove trailing .exe if any
30250   new_path="${new_path/%.exe/}"
30251 
30252   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30253 
30254   # First separate the path from the arguments. This will split at the first
30255   # space.
30256   complete="$PROPER_COMPILER_CXX"
30257   path="${complete%% *}"
30258   tmp="$complete EOL"
30259   arguments="${tmp#* }"
30260 
30261   # Input might be given as Windows format, start by converting to
30262   # unix format.
30263   new_path="$path"
30264 
30265   windows_path="$new_path"
30266   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30267     unix_path=`$CYGPATH -u "$windows_path"`
30268     new_path="$unix_path"
30269   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30270     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30271     new_path="$unix_path"
30272   fi
30273 
30274 
30275   # Now try to locate executable using which
30276   new_path=`$WHICH "$new_path" 2> /dev/null`
30277 
30278   if test "x$new_path" = x; then
30279     # Oops. Which didn't find the executable.
30280     # The splitting of arguments from the executable at a space might have been incorrect,
30281     # since paths with space are more likely in Windows. Give it another try with the whole
30282     # argument.
30283     path="$complete"
30284     arguments="EOL"
30285     new_path="$path"
30286 
30287   windows_path="$new_path"
30288   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30289     unix_path=`$CYGPATH -u "$windows_path"`
30290     new_path="$unix_path"
30291   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30292     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30293     new_path="$unix_path"
30294   fi
30295 
30296 
30297     new_path=`$WHICH "$new_path" 2> /dev/null`
30298     # bat and cmd files are not always considered executable in MSYS causing which
30299     # to not find them
30300     if test "x$new_path" = x \
30301         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
30302         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
30303       new_path="$path"
30304 
30305   windows_path="$new_path"
30306   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30307     unix_path=`$CYGPATH -u "$windows_path"`
30308     new_path="$unix_path"
30309   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30310     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30311     new_path="$unix_path"
30312   fi
30313 
30314     fi
30315 
30316     if test "x$new_path" = x; then
30317       # It's still not found. Now this is an unrecoverable error.
30318       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
30319 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
30320       has_space=`$ECHO "$complete" | $GREP " "`
30321       if test "x$has_space" != x; then
30322         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
30323 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
30324       fi
30325       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
30326     fi
30327   fi
30328 
30329   # Now new_path has a complete unix path to the binary
30330   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
30331     # Keep paths in /bin as-is, but remove trailing .exe if any
30332     new_path="${new_path/%.exe/}"
30333     # Do not save /bin paths to all_fixpath_prefixes!
30334   else
30335     # Not in mixed or Windows style, start by that.
30336     new_path=`cmd //c echo $new_path`
30337 
30338   input_path="$new_path"
30339   # Check if we need to convert this using DOS-style short mode. If the path
30340   # contains just simple characters, use it. Otherwise (spaces, weird characters),
30341   # take no chances and rewrite it.
30342   # Note: m4 eats our [], so we need to use [ and ] instead.
30343   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
30344   if test "x$has_forbidden_chars" != x; then
30345     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
30346     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
30347   fi
30348 
30349     # Output is in $new_path
30350 
30351   windows_path="$new_path"
30352   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
30353     unix_path=`$CYGPATH -u "$windows_path"`
30354     new_path="$unix_path"
30355   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
30356     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
30357     new_path="$unix_path"
30358   fi
30359 
30360     # remove trailing .exe if any
30361     new_path="${new_path/%.exe/}"
30362 
30363     # Save the first 10 bytes of this path to the storage, so fixpath can work.
30364     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
30365   fi
30366 
30367   else
30368     # We're on a unix platform. Hooray! :)
30369     # First separate the path from the arguments. This will split at the first
30370     # space.
30371     complete="$PROPER_COMPILER_CXX"
30372     path="${complete%% *}"
30373     tmp="$complete EOL"
30374     arguments="${tmp#* }"
30375 
30376     # Cannot rely on the command "which" here since it doesn't always work.
30377     is_absolute_path=`$ECHO "$path" | $GREP ^/`
30378     if test -z "$is_absolute_path"; then
30379       # Path to executable is not absolute. Find it.
30380       IFS_save="$IFS"
30381       IFS=:
30382       for p in $PATH; do
30383         if test -f "$p/$path" && test -x "$p/$path"; then
30384           new_path="$p/$path"
30385           break
30386         fi
30387       done
30388       IFS="$IFS_save"
30389     else
30390       # This is an absolute path, we can use it without further modifications.
30391       new_path="$path"
30392     fi
30393 
30394     if test "x$new_path" = x; then
30395       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5
30396 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;}
30397       has_space=`$ECHO "$complete" | $GREP " "`
30398       if test "x$has_space" != x; then
30399         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
30400 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
30401       fi
30402       as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5
30403     fi
30404   fi
30405 
30406   # Now join together the path and the arguments once again
30407   if test "x$arguments" != xEOL; then
30408     new_complete="$new_path ${arguments% *}"
30409   else
30410     new_complete="$new_path"
30411   fi
30412 
30413   if test "x$complete" != "x$new_complete"; then
30414     PROPER_COMPILER_CXX="$new_complete"
30415     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&5
30416 $as_echo "$as_me: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&6;}
30417   fi
30418 
30419     PATH="$RETRY_COMPILER_SAVED_PATH"
30420 
30421     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CXX" >&5
30422 $as_echo_n "checking for resolved symbolic links for CXX... " >&6; }
30423 
30424   if test "x$OPENJDK_BUILD_OS" != xwindows; then
30425     # Follow a chain of symbolic links. Use readlink
30426     # where it exists, else fall back to horribly
30427     # complicated shell code.
30428     if test "x$READLINK_TESTED" != yes; then
30429       # On MacOSX there is a readlink tool with a different
30430       # purpose than the GNU readlink tool. Check the found readlink.
30431       ISGNU=`$READLINK --version 2>&1 | $GREP GNU`
30432       if test "x$ISGNU" = x; then
30433         # A readlink that we do not know how to use.
30434         # Are there other non-GNU readlinks out there?
30435         READLINK_TESTED=yes
30436         READLINK=
30437       fi
30438     fi
30439 
30440     if test "x$READLINK" != x; then
30441       PROPER_COMPILER_CXX=`$READLINK -f $PROPER_COMPILER_CXX`
30442     else
30443       # Save the current directory for restoring afterwards
30444       STARTDIR=$PWD
30445       COUNTER=0
30446       sym_link_dir=`$DIRNAME $PROPER_COMPILER_CXX`
30447       sym_link_file=`$BASENAME $PROPER_COMPILER_CXX`
30448       cd $sym_link_dir
30449       # Use -P flag to resolve symlinks in directories.
30450       cd `$THEPWDCMD -P`
30451       sym_link_dir=`$THEPWDCMD -P`
30452       # Resolve file symlinks
30453       while test $COUNTER -lt 20; do
30454         ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'`
30455         if test "x$ISLINK" == x; then
30456           # This is not a symbolic link! We are done!
30457           break
30458         fi
30459         # Again resolve directory symlinks since the target of the just found
30460         # link could be in a different directory
30461         cd `$DIRNAME $ISLINK`
30462         sym_link_dir=`$THEPWDCMD -P`
30463         sym_link_file=`$BASENAME $ISLINK`
30464         let COUNTER=COUNTER+1
30465       done
30466       cd $STARTDIR
30467       PROPER_COMPILER_CXX=$sym_link_dir/$sym_link_file
30468     fi
30469   fi
30470 
30471     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5
30472 $as_echo "$PROPER_COMPILER_CXX" >&6; }
30473     CXX="$PROPER_COMPILER_CXX"
30474   else
30475     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CXX" >&5
30476 $as_echo "no, keeping CXX" >&6; }
30477   fi
30478 
30479 
30480   COMPILER=$CXX
30481   COMPILER_NAME=$COMPILER_NAME
30482 
30483   if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
30484     # cc -V output typically looks like
30485     #     cc: Sun C 5.12 Linux_i386 2011/11/16
30486     COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1`
30487     # Check that this is likely to be the Solaris Studio cc.
30488     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null
30489     if test $? -ne 0; then
30490       ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30491       { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5
30492 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30493       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30494 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30495       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
30496 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
30497       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30498     fi
30499     # Remove usage instructions (if present), and
30500     # collapse compiler output into a single line
30501     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
30502         $SED -e 's/ *[Uu]sage:.*//'`
30503     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30504         $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"`
30505   elif test  "x$TOOLCHAIN_TYPE" = xxlc; then
30506     # xlc -qversion output typically looks like
30507     #     IBM XL C/C++ for AIX, V11.1 (5724-X13)
30508     #     Version: 11.01.0000.0015
30509     COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1`
30510     # Check that this is likely to be the IBM XL C compiler.
30511     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null
30512     if test $? -ne 0; then
30513       ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30514       { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5
30515 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30516       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30517 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30518       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5
30519 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;}
30520       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30521     fi
30522     # Collapse compiler output into a single line
30523     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
30524     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30525         $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'`
30526   elif test  "x$TOOLCHAIN_TYPE" = xmicrosoft; then
30527     # There is no specific version flag, but all output starts with a version string.
30528     # First line typically looks something like:
30529     # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86
30530     COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'`
30531     # Check that this is likely to be Microsoft CL.EXE.
30532     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null
30533     if test $? -ne 0; then
30534       { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5
30535 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30536       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30537 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30538       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30539     fi
30540     # Collapse compiler output into a single line
30541     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
30542     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30543         $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'`
30544   elif test  "x$TOOLCHAIN_TYPE" = xgcc; then
30545     # gcc --version output typically looks like
30546     #     gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1
30547     #     Copyright (C) 2013 Free Software Foundation, Inc.
30548     #     This is free software; see the source for copying conditions.  There is NO
30549     #     warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
30550     COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30551     # Check that this is likely to be GCC.
30552     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null
30553     if test $? -ne 0; then
30554       { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5
30555 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30556       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5
30557 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;}
30558       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30559     fi
30560     # Remove Copyright and legalese from version string, and
30561     # collapse into a single line
30562     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \
30563         $SED -e 's/ *Copyright .*//'`
30564     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30565         $SED -e 's/^.* \([1-9]\.[0-9.]*\) .*$/\1/'`
30566   elif test  "x$TOOLCHAIN_TYPE" = xclang; then
30567     # clang --version output typically looks like
30568     #    Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn)
30569     #    clang version 3.3 (tags/RELEASE_33/final)
30570     # or
30571     #    Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2)
30572     #    Target: x86_64-pc-linux-gnu
30573     #    Thread model: posix
30574     COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1`
30575     # Check that this is likely to be clang
30576     $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null
30577     if test $? -ne 0; then
30578       { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5
30579 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;}
30580       { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5
30581 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;}
30582       as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5
30583     fi
30584     # Collapse compiler output into a single line
30585     COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT`
30586     COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \
30587         $SED -e 's/^.*clang version \([1-9][0-9.]*\).*$/\1/'`
30588   else
30589       as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5
30590   fi
30591   # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker)
30592   CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER"
30593   # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker)
30594   CXX_VERSION_STRING="$COMPILER_VERSION_STRING"
30595 
30596   { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5
30597 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;}
30598 
30599 
30600   # Now that we have resolved CXX ourself, let autoconf have its go at it
30601   ac_ext=cpp
30602 ac_cpp='$CXXCPP $CPPFLAGS'
30603 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30604 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30605 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30606 if test -z "$CXX"; then
30607   if test -n "$CCC"; then
30608     CXX=$CCC
30609   else
30610     if test -n "$ac_tool_prefix"; then
30611   for ac_prog in $CXX
30612   do
30613     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
30614 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
30615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
30616 $as_echo_n "checking for $ac_word... " >&6; }
30617 if ${ac_cv_prog_CXX+:} false; then :
30618   $as_echo_n "(cached) " >&6
30619 else
30620   if test -n "$CXX"; then
30621   ac_cv_prog_CXX="$CXX" # Let the user override the test.
30622 else
30623 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30624 for as_dir in $PATH
30625 do
30626   IFS=$as_save_IFS
30627   test -z "$as_dir" && as_dir=.
30628     for ac_exec_ext in '' $ac_executable_extensions; do
30629   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
30630     ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
30631     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
30632     break 2
30633   fi
30634 done
30635   done
30636 IFS=$as_save_IFS
30637 
30638 fi
30639 fi
30640 CXX=$ac_cv_prog_CXX
30641 if test -n "$CXX"; then
30642   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
30643 $as_echo "$CXX" >&6; }
30644 else
30645   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30646 $as_echo "no" >&6; }
30647 fi
30648 
30649 
30650     test -n "$CXX" && break
30651   done
30652 fi
30653 if test -z "$CXX"; then
30654   ac_ct_CXX=$CXX
30655   for ac_prog in $CXX
30656 do
30657   # Extract the first word of "$ac_prog", so it can be a program name with args.
30658 set dummy $ac_prog; ac_word=$2
30659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
30660 $as_echo_n "checking for $ac_word... " >&6; }
30661 if ${ac_cv_prog_ac_ct_CXX+:} false; then :
30662   $as_echo_n "(cached) " >&6
30663 else
30664   if test -n "$ac_ct_CXX"; then
30665   ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
30666 else
30667 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30668 for as_dir in $PATH
30669 do
30670   IFS=$as_save_IFS
30671   test -z "$as_dir" && as_dir=.
30672     for ac_exec_ext in '' $ac_executable_extensions; do
30673   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
30674     ac_cv_prog_ac_ct_CXX="$ac_prog"
30675     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
30676     break 2
30677   fi
30678 done
30679   done
30680 IFS=$as_save_IFS
30681 
30682 fi
30683 fi
30684 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
30685 if test -n "$ac_ct_CXX"; then
30686   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
30687 $as_echo "$ac_ct_CXX" >&6; }
30688 else
30689   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30690 $as_echo "no" >&6; }
30691 fi
30692 
30693 
30694   test -n "$ac_ct_CXX" && break
30695 done
30696 
30697   if test "x$ac_ct_CXX" = x; then
30698     CXX="g++"
30699   else
30700     case $cross_compiling:$ac_tool_warned in
30701 yes:)
30702 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
30703 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
30704 ac_tool_warned=yes ;;
30705 esac
30706     CXX=$ac_ct_CXX
30707   fi
30708 fi
30709 
30710   fi
30711 fi
30712 # Provide some information about the compiler.
30713 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
30714 set X $ac_compile
30715 ac_compiler=$2
30716 for ac_option in --version -v -V -qversion; do
30717   { { ac_try="$ac_compiler $ac_option >&5"
30718 case "(($ac_try" in
30719   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30720   *) ac_try_echo=$ac_try;;
30721 esac
30722 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
30723 $as_echo "$ac_try_echo"; } >&5
30724   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
30725   ac_status=$?
30726   if test -s conftest.err; then
30727     sed '10a\
30728 ... rest of stderr output deleted ...
30729          10q' conftest.err >conftest.er1
30730     cat conftest.er1 >&5
30731   fi
30732   rm -f conftest.er1 conftest.err
30733   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
30734   test $ac_status = 0; }
30735 done
30736 
30737 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
30738 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
30739 if ${ac_cv_cxx_compiler_gnu+:} false; then :
30740   $as_echo_n "(cached) " >&6
30741 else
30742   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30743 /* end confdefs.h.  */
30744 
30745 int
30746 main ()
30747 {
30748 #ifndef __GNUC__
30749        choke me
30750 #endif
30751 
30752   ;
30753   return 0;
30754 }
30755 _ACEOF
30756 if ac_fn_cxx_try_compile "$LINENO"; then :
30757   ac_compiler_gnu=yes
30758 else
30759   ac_compiler_gnu=no
30760 fi
30761 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30762 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
30763 
30764 fi
30765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
30766 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
30767 if test $ac_compiler_gnu = yes; then
30768   GXX=yes
30769 else
30770   GXX=
30771 fi
30772 ac_test_CXXFLAGS=${CXXFLAGS+set}
30773 ac_save_CXXFLAGS=$CXXFLAGS
30774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
30775 $as_echo_n "checking whether $CXX accepts -g... " >&6; }
30776 if ${ac_cv_prog_cxx_g+:} false; then :
30777   $as_echo_n "(cached) " >&6
30778 else
30779   ac_save_cxx_werror_flag=$ac_cxx_werror_flag
30780    ac_cxx_werror_flag=yes
30781    ac_cv_prog_cxx_g=no
30782    CXXFLAGS="-g"
30783    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30784 /* end confdefs.h.  */
30785 
30786 int
30787 main ()
30788 {
30789 
30790   ;
30791   return 0;
30792 }
30793 _ACEOF
30794 if ac_fn_cxx_try_compile "$LINENO"; then :
30795   ac_cv_prog_cxx_g=yes
30796 else
30797   CXXFLAGS=""
30798       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30799 /* end confdefs.h.  */
30800 
30801 int
30802 main ()
30803 {
30804 
30805   ;
30806   return 0;
30807 }
30808 _ACEOF
30809 if ac_fn_cxx_try_compile "$LINENO"; then :
30810 
30811 else
30812   ac_cxx_werror_flag=$ac_save_cxx_werror_flag
30813          CXXFLAGS="-g"
30814          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30815 /* end confdefs.h.  */
30816 
30817 int
30818 main ()
30819 {
30820 
30821   ;
30822   return 0;
30823 }
30824 _ACEOF
30825 if ac_fn_cxx_try_compile "$LINENO"; then :
30826   ac_cv_prog_cxx_g=yes
30827 fi
30828 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30829 fi
30830 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30831 fi
30832 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30833    ac_cxx_werror_flag=$ac_save_cxx_werror_flag
30834 fi
30835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
30836 $as_echo "$ac_cv_prog_cxx_g" >&6; }
30837 if test "$ac_test_CXXFLAGS" = set; then
30838   CXXFLAGS=$ac_save_CXXFLAGS
30839 elif test $ac_cv_prog_cxx_g = yes; then
30840   if test "$GXX" = yes; then
30841     CXXFLAGS="-g -O2"
30842   else
30843     CXXFLAGS="-g"
30844   fi
30845 else
30846   if test "$GXX" = yes; then
30847     CXXFLAGS="-O2"
30848   else
30849     CXXFLAGS=
30850   fi
30851 fi
30852 ac_ext=cpp
30853 ac_cpp='$CXXCPP $CPPFLAGS'
30854 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30855 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30856 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30857 
30858 
30859   #
30860   # Setup the preprocessor (CPP and CXXCPP)
30861   #
30862   ac_ext=c
30863 ac_cpp='$CPP $CPPFLAGS'
30864 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30865 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30866 ac_compiler_gnu=$ac_cv_c_compiler_gnu
30867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
30868 $as_echo_n "checking how to run the C preprocessor... " >&6; }
30869 # On Suns, sometimes $CPP names a directory.
30870 if test -n "$CPP" && test -d "$CPP"; then
30871   CPP=
30872 fi
30873 if test -z "$CPP"; then
30874   if ${ac_cv_prog_CPP+:} false; then :
30875   $as_echo_n "(cached) " >&6
30876 else
30877       # Double quotes because CPP needs to be expanded
30878     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
30879     do
30880       ac_preproc_ok=false
30881 for ac_c_preproc_warn_flag in '' yes
30882 do
30883   # Use a header file that comes with gcc, so configuring glibc
30884   # with a fresh cross-compiler works.
30885   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30886   # <limits.h> exists even on freestanding compilers.
30887   # On the NeXT, cc -E runs the code through the compiler's parser,
30888   # not just through cpp. "Syntax error" is here to catch this case.
30889   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30890 /* end confdefs.h.  */
30891 #ifdef __STDC__
30892 # include <limits.h>
30893 #else
30894 # include <assert.h>
30895 #endif
30896                      Syntax error
30897 _ACEOF
30898 if ac_fn_c_try_cpp "$LINENO"; then :
30899 
30900 else
30901   # Broken: fails on valid input.
30902 continue
30903 fi
30904 rm -f conftest.err conftest.i conftest.$ac_ext
30905 
30906   # OK, works on sane cases.  Now check whether nonexistent headers
30907   # can be detected and how.
30908   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30909 /* end confdefs.h.  */
30910 #include <ac_nonexistent.h>
30911 _ACEOF
30912 if ac_fn_c_try_cpp "$LINENO"; then :
30913   # Broken: success on invalid input.
30914 continue
30915 else
30916   # Passes both tests.
30917 ac_preproc_ok=:
30918 break
30919 fi
30920 rm -f conftest.err conftest.i conftest.$ac_ext
30921 
30922 done
30923 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
30924 rm -f conftest.i conftest.err conftest.$ac_ext
30925 if $ac_preproc_ok; then :
30926   break
30927 fi
30928 
30929     done
30930     ac_cv_prog_CPP=$CPP
30931 
30932 fi
30933   CPP=$ac_cv_prog_CPP
30934 else
30935   ac_cv_prog_CPP=$CPP
30936 fi
30937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
30938 $as_echo "$CPP" >&6; }
30939 ac_preproc_ok=false
30940 for ac_c_preproc_warn_flag in '' yes
30941 do
30942   # Use a header file that comes with gcc, so configuring glibc
30943   # with a fresh cross-compiler works.
30944   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
30945   # <limits.h> exists even on freestanding compilers.
30946   # On the NeXT, cc -E runs the code through the compiler's parser,
30947   # not just through cpp. "Syntax error" is here to catch this case.
30948   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30949 /* end confdefs.h.  */
30950 #ifdef __STDC__
30951 # include <limits.h>
30952 #else
30953 # include <assert.h>
30954 #endif
30955                      Syntax error
30956 _ACEOF
30957 if ac_fn_c_try_cpp "$LINENO"; then :
30958 
30959 else
30960   # Broken: fails on valid input.
30961 continue
30962 fi
30963 rm -f conftest.err conftest.i conftest.$ac_ext
30964 
30965   # OK, works on sane cases.  Now check whether nonexistent headers
30966   # can be detected and how.
30967   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30968 /* end confdefs.h.  */
30969 #include <ac_nonexistent.h>
30970 _ACEOF
30971 if ac_fn_c_try_cpp "$LINENO"; then :
30972   # Broken: success on invalid input.
30973 continue
30974 else
30975   # Passes both tests.
30976 ac_preproc_ok=:
30977 break
30978 fi
30979 rm -f conftest.err conftest.i conftest.$ac_ext
30980 
30981 done
30982 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
30983 rm -f conftest.i conftest.err conftest.$ac_ext
30984 if $ac_preproc_ok; then :
30985 
30986 else
30987   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
30988 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
30989 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
30990 See \`config.log' for more details" "$LINENO" 5; }
30991 fi
30992 
30993 ac_ext=cpp
30994 ac_cpp='$CXXCPP $CPPFLAGS'
30995 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
30996 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
30997 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
30998 
30999 
31000   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31001 
31002   # First separate the path from the arguments. This will split at the first
31003   # space.
31004   complete="$CPP"
31005   path="${complete%% *}"
31006   tmp="$complete EOL"
31007   arguments="${tmp#* }"
31008 
31009   # Input might be given as Windows format, start by converting to
31010   # unix format.
31011   new_path=`$CYGPATH -u "$path"`
31012 
31013   # Now try to locate executable using which
31014   new_path=`$WHICH "$new_path" 2> /dev/null`
31015   # bat and cmd files are not always considered executable in cygwin causing which
31016   # to not find them
31017   if test "x$new_path" = x \
31018       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31019       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31020     new_path=`$CYGPATH -u "$path"`
31021   fi
31022   if test "x$new_path" = x; then
31023     # Oops. Which didn't find the executable.
31024     # The splitting of arguments from the executable at a space might have been incorrect,
31025     # since paths with space are more likely in Windows. Give it another try with the whole
31026     # argument.
31027     path="$complete"
31028     arguments="EOL"
31029     new_path=`$CYGPATH -u "$path"`
31030     new_path=`$WHICH "$new_path" 2> /dev/null`
31031     # bat and cmd files are not always considered executable in cygwin causing which
31032     # to not find them
31033     if test "x$new_path" = x \
31034         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31035         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31036       new_path=`$CYGPATH -u "$path"`
31037     fi
31038     if test "x$new_path" = x; then
31039       # It's still not found. Now this is an unrecoverable error.
31040       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
31041 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
31042       has_space=`$ECHO "$complete" | $GREP " "`
31043       if test "x$has_space" != x; then
31044         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31045 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31046       fi
31047       as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
31048     fi
31049   fi
31050 
31051   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31052   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31053   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31054   # "foo.exe" is OK but "foo" is an error.
31055   #
31056   # This test is therefore slightly more accurate than "test -f" to check for file presence.
31057   # It is also a way to make sure we got the proper file name for the real test later on.
31058   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31059   if test "x$test_shortpath" = x; then
31060     # Short path failed, file does not exist as specified.
31061     # Try adding .exe or .cmd
31062     if test -f "${new_path}.exe"; then
31063       input_to_shortpath="${new_path}.exe"
31064     elif test -f "${new_path}.cmd"; then
31065       input_to_shortpath="${new_path}.cmd"
31066     else
31067       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$new_path\", is invalid." >&5
31068 $as_echo "$as_me: The path of CPP, which resolves as \"$new_path\", is invalid." >&6;}
31069       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31070 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31071       as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
31072     fi
31073   else
31074     input_to_shortpath="$new_path"
31075   fi
31076 
31077   # Call helper function which possibly converts this using DOS-style short mode.
31078   # If so, the updated path is stored in $new_path.
31079   new_path="$input_to_shortpath"
31080 
31081   input_path="$input_to_shortpath"
31082   # Check if we need to convert this using DOS-style short mode. If the path
31083   # contains just simple characters, use it. Otherwise (spaces, weird characters),
31084   # take no chances and rewrite it.
31085   # Note: m4 eats our [], so we need to use [ and ] instead.
31086   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
31087   if test "x$has_forbidden_chars" != x; then
31088     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31089     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
31090     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
31091     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
31092       # Going to short mode and back again did indeed matter. Since short mode is
31093       # case insensitive, let's make it lowercase to improve readability.
31094       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31095       # Now convert it back to Unix-stile (cygpath)
31096       input_path=`$CYGPATH -u "$shortmode_path"`
31097       new_path="$input_path"
31098     fi
31099   fi
31100 
31101   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
31102   if test "x$test_cygdrive_prefix" = x; then
31103     # As a simple fix, exclude /usr/bin since it's not a real path.
31104     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
31105       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
31106       # a path prefixed by /cygdrive for fixpath to work.
31107       new_path="$CYGWIN_ROOT_PATH$input_path"
31108     fi
31109   fi
31110 
31111   # remove trailing .exe if any
31112   new_path="${new_path/%.exe/}"
31113 
31114   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31115 
31116   # First separate the path from the arguments. This will split at the first
31117   # space.
31118   complete="$CPP"
31119   path="${complete%% *}"
31120   tmp="$complete EOL"
31121   arguments="${tmp#* }"
31122 
31123   # Input might be given as Windows format, start by converting to
31124   # unix format.
31125   new_path="$path"
31126 
31127   windows_path="$new_path"
31128   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31129     unix_path=`$CYGPATH -u "$windows_path"`
31130     new_path="$unix_path"
31131   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31132     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31133     new_path="$unix_path"
31134   fi
31135 
31136 
31137   # Now try to locate executable using which
31138   new_path=`$WHICH "$new_path" 2> /dev/null`
31139 
31140   if test "x$new_path" = x; then
31141     # Oops. Which didn't find the executable.
31142     # The splitting of arguments from the executable at a space might have been incorrect,
31143     # since paths with space are more likely in Windows. Give it another try with the whole
31144     # argument.
31145     path="$complete"
31146     arguments="EOL"
31147     new_path="$path"
31148 
31149   windows_path="$new_path"
31150   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31151     unix_path=`$CYGPATH -u "$windows_path"`
31152     new_path="$unix_path"
31153   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31154     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31155     new_path="$unix_path"
31156   fi
31157 
31158 
31159     new_path=`$WHICH "$new_path" 2> /dev/null`
31160     # bat and cmd files are not always considered executable in MSYS causing which
31161     # to not find them
31162     if test "x$new_path" = x \
31163         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31164         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31165       new_path="$path"
31166 
31167   windows_path="$new_path"
31168   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31169     unix_path=`$CYGPATH -u "$windows_path"`
31170     new_path="$unix_path"
31171   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31172     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31173     new_path="$unix_path"
31174   fi
31175 
31176     fi
31177 
31178     if test "x$new_path" = x; then
31179       # It's still not found. Now this is an unrecoverable error.
31180       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
31181 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
31182       has_space=`$ECHO "$complete" | $GREP " "`
31183       if test "x$has_space" != x; then
31184         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31185 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31186       fi
31187       as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
31188     fi
31189   fi
31190 
31191   # Now new_path has a complete unix path to the binary
31192   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
31193     # Keep paths in /bin as-is, but remove trailing .exe if any
31194     new_path="${new_path/%.exe/}"
31195     # Do not save /bin paths to all_fixpath_prefixes!
31196   else
31197     # Not in mixed or Windows style, start by that.
31198     new_path=`cmd //c echo $new_path`
31199 
31200   input_path="$new_path"
31201   # Check if we need to convert this using DOS-style short mode. If the path
31202   # contains just simple characters, use it. Otherwise (spaces, weird characters),
31203   # take no chances and rewrite it.
31204   # Note: m4 eats our [], so we need to use [ and ] instead.
31205   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
31206   if test "x$has_forbidden_chars" != x; then
31207     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31208     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31209   fi
31210 
31211     # Output is in $new_path
31212 
31213   windows_path="$new_path"
31214   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31215     unix_path=`$CYGPATH -u "$windows_path"`
31216     new_path="$unix_path"
31217   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31218     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31219     new_path="$unix_path"
31220   fi
31221 
31222     # remove trailing .exe if any
31223     new_path="${new_path/%.exe/}"
31224 
31225     # Save the first 10 bytes of this path to the storage, so fixpath can work.
31226     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
31227   fi
31228 
31229   else
31230     # We're on a unix platform. Hooray! :)
31231     # First separate the path from the arguments. This will split at the first
31232     # space.
31233     complete="$CPP"
31234     path="${complete%% *}"
31235     tmp="$complete EOL"
31236     arguments="${tmp#* }"
31237 
31238     # Cannot rely on the command "which" here since it doesn't always work.
31239     is_absolute_path=`$ECHO "$path" | $GREP ^/`
31240     if test -z "$is_absolute_path"; then
31241       # Path to executable is not absolute. Find it.
31242       IFS_save="$IFS"
31243       IFS=:
31244       for p in $PATH; do
31245         if test -f "$p/$path" && test -x "$p/$path"; then
31246           new_path="$p/$path"
31247           break
31248         fi
31249       done
31250       IFS="$IFS_save"
31251     else
31252       # This is an absolute path, we can use it without further modifications.
31253       new_path="$path"
31254     fi
31255 
31256     if test "x$new_path" = x; then
31257       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5
31258 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;}
31259       has_space=`$ECHO "$complete" | $GREP " "`
31260       if test "x$has_space" != x; then
31261         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
31262 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
31263       fi
31264       as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5
31265     fi
31266   fi
31267 
31268   # Now join together the path and the arguments once again
31269   if test "x$arguments" != xEOL; then
31270     new_complete="$new_path ${arguments% *}"
31271   else
31272     new_complete="$new_path"
31273   fi
31274 
31275   if test "x$complete" != "x$new_complete"; then
31276     CPP="$new_complete"
31277     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CPP to \"$new_complete\"" >&5
31278 $as_echo "$as_me: Rewriting CPP to \"$new_complete\"" >&6;}
31279   fi
31280 
31281   ac_ext=cpp
31282 ac_cpp='$CXXCPP $CPPFLAGS'
31283 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
31284 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
31285 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
31286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
31287 $as_echo_n "checking how to run the C++ preprocessor... " >&6; }
31288 if test -z "$CXXCPP"; then
31289   if ${ac_cv_prog_CXXCPP+:} false; then :
31290   $as_echo_n "(cached) " >&6
31291 else
31292       # Double quotes because CXXCPP needs to be expanded
31293     for CXXCPP in "$CXX -E" "/lib/cpp"
31294     do
31295       ac_preproc_ok=false
31296 for ac_cxx_preproc_warn_flag in '' yes
31297 do
31298   # Use a header file that comes with gcc, so configuring glibc
31299   # with a fresh cross-compiler works.
31300   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31301   # <limits.h> exists even on freestanding compilers.
31302   # On the NeXT, cc -E runs the code through the compiler's parser,
31303   # not just through cpp. "Syntax error" is here to catch this case.
31304   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31305 /* end confdefs.h.  */
31306 #ifdef __STDC__
31307 # include <limits.h>
31308 #else
31309 # include <assert.h>
31310 #endif
31311                      Syntax error
31312 _ACEOF
31313 if ac_fn_cxx_try_cpp "$LINENO"; then :
31314 
31315 else
31316   # Broken: fails on valid input.
31317 continue
31318 fi
31319 rm -f conftest.err conftest.i conftest.$ac_ext
31320 
31321   # OK, works on sane cases.  Now check whether nonexistent headers
31322   # can be detected and how.
31323   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31324 /* end confdefs.h.  */
31325 #include <ac_nonexistent.h>
31326 _ACEOF
31327 if ac_fn_cxx_try_cpp "$LINENO"; then :
31328   # Broken: success on invalid input.
31329 continue
31330 else
31331   # Passes both tests.
31332 ac_preproc_ok=:
31333 break
31334 fi
31335 rm -f conftest.err conftest.i conftest.$ac_ext
31336 
31337 done
31338 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
31339 rm -f conftest.i conftest.err conftest.$ac_ext
31340 if $ac_preproc_ok; then :
31341   break
31342 fi
31343 
31344     done
31345     ac_cv_prog_CXXCPP=$CXXCPP
31346 
31347 fi
31348   CXXCPP=$ac_cv_prog_CXXCPP
31349 else
31350   ac_cv_prog_CXXCPP=$CXXCPP
31351 fi
31352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
31353 $as_echo "$CXXCPP" >&6; }
31354 ac_preproc_ok=false
31355 for ac_cxx_preproc_warn_flag in '' yes
31356 do
31357   # Use a header file that comes with gcc, so configuring glibc
31358   # with a fresh cross-compiler works.
31359   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31360   # <limits.h> exists even on freestanding compilers.
31361   # On the NeXT, cc -E runs the code through the compiler's parser,
31362   # not just through cpp. "Syntax error" is here to catch this case.
31363   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31364 /* end confdefs.h.  */
31365 #ifdef __STDC__
31366 # include <limits.h>
31367 #else
31368 # include <assert.h>
31369 #endif
31370                      Syntax error
31371 _ACEOF
31372 if ac_fn_cxx_try_cpp "$LINENO"; then :
31373 
31374 else
31375   # Broken: fails on valid input.
31376 continue
31377 fi
31378 rm -f conftest.err conftest.i conftest.$ac_ext
31379 
31380   # OK, works on sane cases.  Now check whether nonexistent headers
31381   # can be detected and how.
31382   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31383 /* end confdefs.h.  */
31384 #include <ac_nonexistent.h>
31385 _ACEOF
31386 if ac_fn_cxx_try_cpp "$LINENO"; then :
31387   # Broken: success on invalid input.
31388 continue
31389 else
31390   # Passes both tests.
31391 ac_preproc_ok=:
31392 break
31393 fi
31394 rm -f conftest.err conftest.i conftest.$ac_ext
31395 
31396 done
31397 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
31398 rm -f conftest.i conftest.err conftest.$ac_ext
31399 if $ac_preproc_ok; then :
31400 
31401 else
31402   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
31403 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
31404 as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
31405 See \`config.log' for more details" "$LINENO" 5; }
31406 fi
31407 
31408 ac_ext=cpp
31409 ac_cpp='$CXXCPP $CPPFLAGS'
31410 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
31411 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
31412 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
31413 
31414 
31415   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31416 
31417   # First separate the path from the arguments. This will split at the first
31418   # space.
31419   complete="$CXXCPP"
31420   path="${complete%% *}"
31421   tmp="$complete EOL"
31422   arguments="${tmp#* }"
31423 
31424   # Input might be given as Windows format, start by converting to
31425   # unix format.
31426   new_path=`$CYGPATH -u "$path"`
31427 
31428   # Now try to locate executable using which
31429   new_path=`$WHICH "$new_path" 2> /dev/null`
31430   # bat and cmd files are not always considered executable in cygwin causing which
31431   # to not find them
31432   if test "x$new_path" = x \
31433       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31434       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31435     new_path=`$CYGPATH -u "$path"`
31436   fi
31437   if test "x$new_path" = x; then
31438     # Oops. Which didn't find the executable.
31439     # The splitting of arguments from the executable at a space might have been incorrect,
31440     # since paths with space are more likely in Windows. Give it another try with the whole
31441     # argument.
31442     path="$complete"
31443     arguments="EOL"
31444     new_path=`$CYGPATH -u "$path"`
31445     new_path=`$WHICH "$new_path" 2> /dev/null`
31446     # bat and cmd files are not always considered executable in cygwin causing which
31447     # to not find them
31448     if test "x$new_path" = x \
31449         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31450         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31451       new_path=`$CYGPATH -u "$path"`
31452     fi
31453     if test "x$new_path" = x; then
31454       # It's still not found. Now this is an unrecoverable error.
31455       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
31456 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
31457       has_space=`$ECHO "$complete" | $GREP " "`
31458       if test "x$has_space" != x; then
31459         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31460 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31461       fi
31462       as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31463     fi
31464   fi
31465 
31466   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31467   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31468   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31469   # "foo.exe" is OK but "foo" is an error.
31470   #
31471   # This test is therefore slightly more accurate than "test -f" to check for file presence.
31472   # It is also a way to make sure we got the proper file name for the real test later on.
31473   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31474   if test "x$test_shortpath" = x; then
31475     # Short path failed, file does not exist as specified.
31476     # Try adding .exe or .cmd
31477     if test -f "${new_path}.exe"; then
31478       input_to_shortpath="${new_path}.exe"
31479     elif test -f "${new_path}.cmd"; then
31480       input_to_shortpath="${new_path}.cmd"
31481     else
31482       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&5
31483 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&6;}
31484       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31485 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31486       as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31487     fi
31488   else
31489     input_to_shortpath="$new_path"
31490   fi
31491 
31492   # Call helper function which possibly converts this using DOS-style short mode.
31493   # If so, the updated path is stored in $new_path.
31494   new_path="$input_to_shortpath"
31495 
31496   input_path="$input_to_shortpath"
31497   # Check if we need to convert this using DOS-style short mode. If the path
31498   # contains just simple characters, use it. Otherwise (spaces, weird characters),
31499   # take no chances and rewrite it.
31500   # Note: m4 eats our [], so we need to use [ and ] instead.
31501   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
31502   if test "x$has_forbidden_chars" != x; then
31503     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31504     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
31505     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
31506     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
31507       # Going to short mode and back again did indeed matter. Since short mode is
31508       # case insensitive, let's make it lowercase to improve readability.
31509       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31510       # Now convert it back to Unix-stile (cygpath)
31511       input_path=`$CYGPATH -u "$shortmode_path"`
31512       new_path="$input_path"
31513     fi
31514   fi
31515 
31516   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
31517   if test "x$test_cygdrive_prefix" = x; then
31518     # As a simple fix, exclude /usr/bin since it's not a real path.
31519     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
31520       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
31521       # a path prefixed by /cygdrive for fixpath to work.
31522       new_path="$CYGWIN_ROOT_PATH$input_path"
31523     fi
31524   fi
31525 
31526   # remove trailing .exe if any
31527   new_path="${new_path/%.exe/}"
31528 
31529   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31530 
31531   # First separate the path from the arguments. This will split at the first
31532   # space.
31533   complete="$CXXCPP"
31534   path="${complete%% *}"
31535   tmp="$complete EOL"
31536   arguments="${tmp#* }"
31537 
31538   # Input might be given as Windows format, start by converting to
31539   # unix format.
31540   new_path="$path"
31541 
31542   windows_path="$new_path"
31543   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31544     unix_path=`$CYGPATH -u "$windows_path"`
31545     new_path="$unix_path"
31546   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31547     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31548     new_path="$unix_path"
31549   fi
31550 
31551 
31552   # Now try to locate executable using which
31553   new_path=`$WHICH "$new_path" 2> /dev/null`
31554 
31555   if test "x$new_path" = x; then
31556     # Oops. Which didn't find the executable.
31557     # The splitting of arguments from the executable at a space might have been incorrect,
31558     # since paths with space are more likely in Windows. Give it another try with the whole
31559     # argument.
31560     path="$complete"
31561     arguments="EOL"
31562     new_path="$path"
31563 
31564   windows_path="$new_path"
31565   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31566     unix_path=`$CYGPATH -u "$windows_path"`
31567     new_path="$unix_path"
31568   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31569     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31570     new_path="$unix_path"
31571   fi
31572 
31573 
31574     new_path=`$WHICH "$new_path" 2> /dev/null`
31575     # bat and cmd files are not always considered executable in MSYS causing which
31576     # to not find them
31577     if test "x$new_path" = x \
31578         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31579         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31580       new_path="$path"
31581 
31582   windows_path="$new_path"
31583   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31584     unix_path=`$CYGPATH -u "$windows_path"`
31585     new_path="$unix_path"
31586   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31587     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31588     new_path="$unix_path"
31589   fi
31590 
31591     fi
31592 
31593     if test "x$new_path" = x; then
31594       # It's still not found. Now this is an unrecoverable error.
31595       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
31596 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
31597       has_space=`$ECHO "$complete" | $GREP " "`
31598       if test "x$has_space" != x; then
31599         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31600 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31601       fi
31602       as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31603     fi
31604   fi
31605 
31606   # Now new_path has a complete unix path to the binary
31607   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
31608     # Keep paths in /bin as-is, but remove trailing .exe if any
31609     new_path="${new_path/%.exe/}"
31610     # Do not save /bin paths to all_fixpath_prefixes!
31611   else
31612     # Not in mixed or Windows style, start by that.
31613     new_path=`cmd //c echo $new_path`
31614 
31615   input_path="$new_path"
31616   # Check if we need to convert this using DOS-style short mode. If the path
31617   # contains just simple characters, use it. Otherwise (spaces, weird characters),
31618   # take no chances and rewrite it.
31619   # Note: m4 eats our [], so we need to use [ and ] instead.
31620   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
31621   if test "x$has_forbidden_chars" != x; then
31622     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31623     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31624   fi
31625 
31626     # Output is in $new_path
31627 
31628   windows_path="$new_path"
31629   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31630     unix_path=`$CYGPATH -u "$windows_path"`
31631     new_path="$unix_path"
31632   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31633     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31634     new_path="$unix_path"
31635   fi
31636 
31637     # remove trailing .exe if any
31638     new_path="${new_path/%.exe/}"
31639 
31640     # Save the first 10 bytes of this path to the storage, so fixpath can work.
31641     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
31642   fi
31643 
31644   else
31645     # We're on a unix platform. Hooray! :)
31646     # First separate the path from the arguments. This will split at the first
31647     # space.
31648     complete="$CXXCPP"
31649     path="${complete%% *}"
31650     tmp="$complete EOL"
31651     arguments="${tmp#* }"
31652 
31653     # Cannot rely on the command "which" here since it doesn't always work.
31654     is_absolute_path=`$ECHO "$path" | $GREP ^/`
31655     if test -z "$is_absolute_path"; then
31656       # Path to executable is not absolute. Find it.
31657       IFS_save="$IFS"
31658       IFS=:
31659       for p in $PATH; do
31660         if test -f "$p/$path" && test -x "$p/$path"; then
31661           new_path="$p/$path"
31662           break
31663         fi
31664       done
31665       IFS="$IFS_save"
31666     else
31667       # This is an absolute path, we can use it without further modifications.
31668       new_path="$path"
31669     fi
31670 
31671     if test "x$new_path" = x; then
31672       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5
31673 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;}
31674       has_space=`$ECHO "$complete" | $GREP " "`
31675       if test "x$has_space" != x; then
31676         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
31677 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
31678       fi
31679       as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5
31680     fi
31681   fi
31682 
31683   # Now join together the path and the arguments once again
31684   if test "x$arguments" != xEOL; then
31685     new_complete="$new_path ${arguments% *}"
31686   else
31687     new_complete="$new_path"
31688   fi
31689 
31690   if test "x$complete" != "x$new_complete"; then
31691     CXXCPP="$new_complete"
31692     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXXCPP to \"$new_complete\"" >&5
31693 $as_echo "$as_me: Rewriting CXXCPP to \"$new_complete\"" >&6;}
31694   fi
31695 
31696 
31697   #
31698   # Setup the linker (LD)
31699   #
31700   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
31701     # In the Microsoft toolchain we have a separate LD command "link".
31702     # Make sure we reject /usr/bin/link (as determined in CYGWIN_LINK), which is
31703     # a cygwin program for something completely different.
31704     # Extract the first word of "link", so it can be a program name with args.
31705 set dummy link; ac_word=$2
31706 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
31707 $as_echo_n "checking for $ac_word... " >&6; }
31708 if ${ac_cv_prog_LD+:} false; then :
31709   $as_echo_n "(cached) " >&6
31710 else
31711   if test -n "$LD"; then
31712   ac_cv_prog_LD="$LD" # Let the user override the test.
31713 else
31714   ac_prog_rejected=no
31715 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31716 for as_dir in $PATH
31717 do
31718   IFS=$as_save_IFS
31719   test -z "$as_dir" && as_dir=.
31720     for ac_exec_ext in '' $ac_executable_extensions; do
31721   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
31722     if test "$as_dir/$ac_word$ac_exec_ext" = "$CYGWIN_LINK"; then
31723        ac_prog_rejected=yes
31724        continue
31725      fi
31726     ac_cv_prog_LD="link"
31727     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
31728     break 2
31729   fi
31730 done
31731   done
31732 IFS=$as_save_IFS
31733 
31734 if test $ac_prog_rejected = yes; then
31735   # We found a bogon in the path, so make sure we never use it.
31736   set dummy $ac_cv_prog_LD
31737   shift
31738   if test $# != 0; then
31739     # We chose a different compiler from the bogus one.
31740     # However, it has the same basename, so the bogon will be chosen
31741     # first if we set LD to just the basename; use the full file name.
31742     shift
31743     ac_cv_prog_LD="$as_dir/$ac_word${1+' '}$@"
31744   fi
31745 fi
31746 fi
31747 fi
31748 LD=$ac_cv_prog_LD
31749 if test -n "$LD"; then
31750   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
31751 $as_echo "$LD" >&6; }
31752 else
31753   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31754 $as_echo "no" >&6; }
31755 fi
31756 
31757 
31758 
31759   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31760 
31761   # First separate the path from the arguments. This will split at the first
31762   # space.
31763   complete="$LD"
31764   path="${complete%% *}"
31765   tmp="$complete EOL"
31766   arguments="${tmp#* }"
31767 
31768   # Input might be given as Windows format, start by converting to
31769   # unix format.
31770   new_path=`$CYGPATH -u "$path"`
31771 
31772   # Now try to locate executable using which
31773   new_path=`$WHICH "$new_path" 2> /dev/null`
31774   # bat and cmd files are not always considered executable in cygwin causing which
31775   # to not find them
31776   if test "x$new_path" = x \
31777       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31778       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31779     new_path=`$CYGPATH -u "$path"`
31780   fi
31781   if test "x$new_path" = x; then
31782     # Oops. Which didn't find the executable.
31783     # The splitting of arguments from the executable at a space might have been incorrect,
31784     # since paths with space are more likely in Windows. Give it another try with the whole
31785     # argument.
31786     path="$complete"
31787     arguments="EOL"
31788     new_path=`$CYGPATH -u "$path"`
31789     new_path=`$WHICH "$new_path" 2> /dev/null`
31790     # bat and cmd files are not always considered executable in cygwin causing which
31791     # to not find them
31792     if test "x$new_path" = x \
31793         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31794         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31795       new_path=`$CYGPATH -u "$path"`
31796     fi
31797     if test "x$new_path" = x; then
31798       # It's still not found. Now this is an unrecoverable error.
31799       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5
31800 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;}
31801       has_space=`$ECHO "$complete" | $GREP " "`
31802       if test "x$has_space" != x; then
31803         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31804 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31805       fi
31806       as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31807     fi
31808   fi
31809 
31810   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
31811   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
31812   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
31813   # "foo.exe" is OK but "foo" is an error.
31814   #
31815   # This test is therefore slightly more accurate than "test -f" to check for file presence.
31816   # It is also a way to make sure we got the proper file name for the real test later on.
31817   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
31818   if test "x$test_shortpath" = x; then
31819     # Short path failed, file does not exist as specified.
31820     # Try adding .exe or .cmd
31821     if test -f "${new_path}.exe"; then
31822       input_to_shortpath="${new_path}.exe"
31823     elif test -f "${new_path}.cmd"; then
31824       input_to_shortpath="${new_path}.cmd"
31825     else
31826       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$new_path\", is invalid." >&5
31827 $as_echo "$as_me: The path of LD, which resolves as \"$new_path\", is invalid." >&6;}
31828       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
31829 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
31830       as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31831     fi
31832   else
31833     input_to_shortpath="$new_path"
31834   fi
31835 
31836   # Call helper function which possibly converts this using DOS-style short mode.
31837   # If so, the updated path is stored in $new_path.
31838   new_path="$input_to_shortpath"
31839 
31840   input_path="$input_to_shortpath"
31841   # Check if we need to convert this using DOS-style short mode. If the path
31842   # contains just simple characters, use it. Otherwise (spaces, weird characters),
31843   # take no chances and rewrite it.
31844   # Note: m4 eats our [], so we need to use [ and ] instead.
31845   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
31846   if test "x$has_forbidden_chars" != x; then
31847     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31848     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
31849     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
31850     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
31851       # Going to short mode and back again did indeed matter. Since short mode is
31852       # case insensitive, let's make it lowercase to improve readability.
31853       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31854       # Now convert it back to Unix-stile (cygpath)
31855       input_path=`$CYGPATH -u "$shortmode_path"`
31856       new_path="$input_path"
31857     fi
31858   fi
31859 
31860   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
31861   if test "x$test_cygdrive_prefix" = x; then
31862     # As a simple fix, exclude /usr/bin since it's not a real path.
31863     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
31864       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
31865       # a path prefixed by /cygdrive for fixpath to work.
31866       new_path="$CYGWIN_ROOT_PATH$input_path"
31867     fi
31868   fi
31869 
31870   # remove trailing .exe if any
31871   new_path="${new_path/%.exe/}"
31872 
31873   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31874 
31875   # First separate the path from the arguments. This will split at the first
31876   # space.
31877   complete="$LD"
31878   path="${complete%% *}"
31879   tmp="$complete EOL"
31880   arguments="${tmp#* }"
31881 
31882   # Input might be given as Windows format, start by converting to
31883   # unix format.
31884   new_path="$path"
31885 
31886   windows_path="$new_path"
31887   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31888     unix_path=`$CYGPATH -u "$windows_path"`
31889     new_path="$unix_path"
31890   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31891     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31892     new_path="$unix_path"
31893   fi
31894 
31895 
31896   # Now try to locate executable using which
31897   new_path=`$WHICH "$new_path" 2> /dev/null`
31898 
31899   if test "x$new_path" = x; then
31900     # Oops. Which didn't find the executable.
31901     # The splitting of arguments from the executable at a space might have been incorrect,
31902     # since paths with space are more likely in Windows. Give it another try with the whole
31903     # argument.
31904     path="$complete"
31905     arguments="EOL"
31906     new_path="$path"
31907 
31908   windows_path="$new_path"
31909   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31910     unix_path=`$CYGPATH -u "$windows_path"`
31911     new_path="$unix_path"
31912   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31913     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31914     new_path="$unix_path"
31915   fi
31916 
31917 
31918     new_path=`$WHICH "$new_path" 2> /dev/null`
31919     # bat and cmd files are not always considered executable in MSYS causing which
31920     # to not find them
31921     if test "x$new_path" = x \
31922         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
31923         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
31924       new_path="$path"
31925 
31926   windows_path="$new_path"
31927   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31928     unix_path=`$CYGPATH -u "$windows_path"`
31929     new_path="$unix_path"
31930   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31931     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31932     new_path="$unix_path"
31933   fi
31934 
31935     fi
31936 
31937     if test "x$new_path" = x; then
31938       # It's still not found. Now this is an unrecoverable error.
31939       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5
31940 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;}
31941       has_space=`$ECHO "$complete" | $GREP " "`
31942       if test "x$has_space" != x; then
31943         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
31944 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
31945       fi
31946       as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
31947     fi
31948   fi
31949 
31950   # Now new_path has a complete unix path to the binary
31951   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
31952     # Keep paths in /bin as-is, but remove trailing .exe if any
31953     new_path="${new_path/%.exe/}"
31954     # Do not save /bin paths to all_fixpath_prefixes!
31955   else
31956     # Not in mixed or Windows style, start by that.
31957     new_path=`cmd //c echo $new_path`
31958 
31959   input_path="$new_path"
31960   # Check if we need to convert this using DOS-style short mode. If the path
31961   # contains just simple characters, use it. Otherwise (spaces, weird characters),
31962   # take no chances and rewrite it.
31963   # Note: m4 eats our [], so we need to use [ and ] instead.
31964   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
31965   if test "x$has_forbidden_chars" != x; then
31966     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
31967     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
31968   fi
31969 
31970     # Output is in $new_path
31971 
31972   windows_path="$new_path"
31973   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
31974     unix_path=`$CYGPATH -u "$windows_path"`
31975     new_path="$unix_path"
31976   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
31977     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
31978     new_path="$unix_path"
31979   fi
31980 
31981     # remove trailing .exe if any
31982     new_path="${new_path/%.exe/}"
31983 
31984     # Save the first 10 bytes of this path to the storage, so fixpath can work.
31985     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
31986   fi
31987 
31988   else
31989     # We're on a unix platform. Hooray! :)
31990     # First separate the path from the arguments. This will split at the first
31991     # space.
31992     complete="$LD"
31993     path="${complete%% *}"
31994     tmp="$complete EOL"
31995     arguments="${tmp#* }"
31996 
31997     # Cannot rely on the command "which" here since it doesn't always work.
31998     is_absolute_path=`$ECHO "$path" | $GREP ^/`
31999     if test -z "$is_absolute_path"; then
32000       # Path to executable is not absolute. Find it.
32001       IFS_save="$IFS"
32002       IFS=:
32003       for p in $PATH; do
32004         if test -f "$p/$path" && test -x "$p/$path"; then
32005           new_path="$p/$path"
32006           break
32007         fi
32008       done
32009       IFS="$IFS_save"
32010     else
32011       # This is an absolute path, we can use it without further modifications.
32012       new_path="$path"
32013     fi
32014 
32015     if test "x$new_path" = x; then
32016       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5
32017 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;}
32018       has_space=`$ECHO "$complete" | $GREP " "`
32019       if test "x$has_space" != x; then
32020         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
32021 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
32022       fi
32023       as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5
32024     fi
32025   fi
32026 
32027   # Now join together the path and the arguments once again
32028   if test "x$arguments" != xEOL; then
32029     new_complete="$new_path ${arguments% *}"
32030   else
32031     new_complete="$new_path"
32032   fi
32033 
32034   if test "x$complete" != "x$new_complete"; then
32035     LD="$new_complete"
32036     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LD to \"$new_complete\"" >&5
32037 $as_echo "$as_me: Rewriting LD to \"$new_complete\"" >&6;}
32038   fi
32039 
32040     # Verify that we indeed succeeded with this trick.
32041     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the found link.exe is actually the Visual Studio linker" >&5
32042 $as_echo_n "checking if the found link.exe is actually the Visual Studio linker... " >&6; }
32043     "$LD" --version > /dev/null
32044     if test $? -eq 0 ; then
32045       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32046 $as_echo "no" >&6; }
32047       as_fn_error $? "This is the Cygwin link tool. Please check your PATH and rerun configure." "$LINENO" 5
32048     else
32049       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32050 $as_echo "yes" >&6; }
32051     fi
32052     LDCXX="$LD"
32053   else
32054     # All other toolchains use the compiler to link.
32055     LD="$CC"
32056     LDCXX="$CXX"
32057   fi
32058 
32059   # FIXME: it should be CXXLD, according to standard (cf CXXCPP)
32060 
32061 
32062   #
32063   # Setup the assembler (AS)
32064   #
32065   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
32066     # FIXME: should this really be solaris, or solstudio?
32067 
32068 
32069   # Publish this variable in the help.
32070 
32071 
32072   if test "x$AS" = x; then
32073     # The variable is not set by user, try to locate tool using the code snippet
32074     for ac_prog in as
32075 do
32076   # Extract the first word of "$ac_prog", so it can be a program name with args.
32077 set dummy $ac_prog; ac_word=$2
32078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32079 $as_echo_n "checking for $ac_word... " >&6; }
32080 if ${ac_cv_path_AS+:} false; then :
32081   $as_echo_n "(cached) " >&6
32082 else
32083   case $AS in
32084   [\\/]* | ?:[\\/]*)
32085   ac_cv_path_AS="$AS" # Let the user override the test with a path.
32086   ;;
32087   *)
32088   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32089 for as_dir in $PATH
32090 do
32091   IFS=$as_save_IFS
32092   test -z "$as_dir" && as_dir=.
32093     for ac_exec_ext in '' $ac_executable_extensions; do
32094   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32095     ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
32096     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32097     break 2
32098   fi
32099 done
32100   done
32101 IFS=$as_save_IFS
32102 
32103   ;;
32104 esac
32105 fi
32106 AS=$ac_cv_path_AS
32107 if test -n "$AS"; then
32108   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
32109 $as_echo "$AS" >&6; }
32110 else
32111   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32112 $as_echo "no" >&6; }
32113 fi
32114 
32115 
32116   test -n "$AS" && break
32117 done
32118 
32119   else
32120     # The variable is set, but is it from the command line or the environment?
32121 
32122     # Try to remove the string !AS! from our list.
32123     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AS!/}
32124     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
32125       # If it failed, the variable was not from the command line. Ignore it,
32126       # but warn the user (except for BASH, which is always set by the calling BASH).
32127       if test "xAS" != xBASH; then
32128         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&5
32129 $as_echo "$as_me: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&2;}
32130       fi
32131       # Try to locate tool using the code snippet
32132       for ac_prog in as
32133 do
32134   # Extract the first word of "$ac_prog", so it can be a program name with args.
32135 set dummy $ac_prog; ac_word=$2
32136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32137 $as_echo_n "checking for $ac_word... " >&6; }
32138 if ${ac_cv_path_AS+:} false; then :
32139   $as_echo_n "(cached) " >&6
32140 else
32141   case $AS in
32142   [\\/]* | ?:[\\/]*)
32143   ac_cv_path_AS="$AS" # Let the user override the test with a path.
32144   ;;
32145   *)
32146   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32147 for as_dir in $PATH
32148 do
32149   IFS=$as_save_IFS
32150   test -z "$as_dir" && as_dir=.
32151     for ac_exec_ext in '' $ac_executable_extensions; do
32152   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32153     ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
32154     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32155     break 2
32156   fi
32157 done
32158   done
32159 IFS=$as_save_IFS
32160 
32161   ;;
32162 esac
32163 fi
32164 AS=$ac_cv_path_AS
32165 if test -n "$AS"; then
32166   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
32167 $as_echo "$AS" >&6; }
32168 else
32169   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32170 $as_echo "no" >&6; }
32171 fi
32172 
32173 
32174   test -n "$AS" && break
32175 done
32176 
32177     else
32178       # If it succeeded, then it was overridden by the user. We will use it
32179       # for the tool.
32180 
32181       # First remove it from the list of overridden variables, so we can test
32182       # for unknown variables in the end.
32183       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
32184 
32185       # Check if the provided tool contains a complete path.
32186       tool_specified="$AS"
32187       tool_basename="${tool_specified##*/}"
32188       if test "x$tool_basename" = "x$tool_specified"; then
32189         # A command without a complete path is provided, search $PATH.
32190         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AS=$tool_basename" >&5
32191 $as_echo "$as_me: Will search for user supplied tool AS=$tool_basename" >&6;}
32192         # Extract the first word of "$tool_basename", so it can be a program name with args.
32193 set dummy $tool_basename; ac_word=$2
32194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32195 $as_echo_n "checking for $ac_word... " >&6; }
32196 if ${ac_cv_path_AS+:} false; then :
32197   $as_echo_n "(cached) " >&6
32198 else
32199   case $AS in
32200   [\\/]* | ?:[\\/]*)
32201   ac_cv_path_AS="$AS" # Let the user override the test with a path.
32202   ;;
32203   *)
32204   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32205 for as_dir in $PATH
32206 do
32207   IFS=$as_save_IFS
32208   test -z "$as_dir" && as_dir=.
32209     for ac_exec_ext in '' $ac_executable_extensions; do
32210   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32211     ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext"
32212     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32213     break 2
32214   fi
32215 done
32216   done
32217 IFS=$as_save_IFS
32218 
32219   ;;
32220 esac
32221 fi
32222 AS=$ac_cv_path_AS
32223 if test -n "$AS"; then
32224   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
32225 $as_echo "$AS" >&6; }
32226 else
32227   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32228 $as_echo "no" >&6; }
32229 fi
32230 
32231 
32232         if test "x$AS" = x; then
32233           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
32234         fi
32235       else
32236         # Otherwise we believe it is a complete path. Use it as it is.
32237         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AS=$tool_specified" >&5
32238 $as_echo "$as_me: Will use user supplied tool AS=$tool_specified" >&6;}
32239         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5
32240 $as_echo_n "checking for AS... " >&6; }
32241         if test ! -x "$tool_specified"; then
32242           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
32243 $as_echo "not found" >&6; }
32244           as_fn_error $? "User supplied tool AS=$tool_specified does not exist or is not executable" "$LINENO" 5
32245         fi
32246         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
32247 $as_echo "$tool_specified" >&6; }
32248       fi
32249     fi
32250   fi
32251 
32252 
32253 
32254   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32255 
32256   # First separate the path from the arguments. This will split at the first
32257   # space.
32258   complete="$AS"
32259   path="${complete%% *}"
32260   tmp="$complete EOL"
32261   arguments="${tmp#* }"
32262 
32263   # Input might be given as Windows format, start by converting to
32264   # unix format.
32265   new_path=`$CYGPATH -u "$path"`
32266 
32267   # Now try to locate executable using which
32268   new_path=`$WHICH "$new_path" 2> /dev/null`
32269   # bat and cmd files are not always considered executable in cygwin causing which
32270   # to not find them
32271   if test "x$new_path" = x \
32272       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32273       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32274     new_path=`$CYGPATH -u "$path"`
32275   fi
32276   if test "x$new_path" = x; then
32277     # Oops. Which didn't find the executable.
32278     # The splitting of arguments from the executable at a space might have been incorrect,
32279     # since paths with space are more likely in Windows. Give it another try with the whole
32280     # argument.
32281     path="$complete"
32282     arguments="EOL"
32283     new_path=`$CYGPATH -u "$path"`
32284     new_path=`$WHICH "$new_path" 2> /dev/null`
32285     # bat and cmd files are not always considered executable in cygwin causing which
32286     # to not find them
32287     if test "x$new_path" = x \
32288         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32289         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32290       new_path=`$CYGPATH -u "$path"`
32291     fi
32292     if test "x$new_path" = x; then
32293       # It's still not found. Now this is an unrecoverable error.
32294       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
32295 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
32296       has_space=`$ECHO "$complete" | $GREP " "`
32297       if test "x$has_space" != x; then
32298         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
32299 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
32300       fi
32301       as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
32302     fi
32303   fi
32304 
32305   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
32306   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
32307   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
32308   # "foo.exe" is OK but "foo" is an error.
32309   #
32310   # This test is therefore slightly more accurate than "test -f" to check for file presence.
32311   # It is also a way to make sure we got the proper file name for the real test later on.
32312   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
32313   if test "x$test_shortpath" = x; then
32314     # Short path failed, file does not exist as specified.
32315     # Try adding .exe or .cmd
32316     if test -f "${new_path}.exe"; then
32317       input_to_shortpath="${new_path}.exe"
32318     elif test -f "${new_path}.cmd"; then
32319       input_to_shortpath="${new_path}.cmd"
32320     else
32321       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$new_path\", is invalid." >&5
32322 $as_echo "$as_me: The path of AS, which resolves as \"$new_path\", is invalid." >&6;}
32323       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
32324 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
32325       as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
32326     fi
32327   else
32328     input_to_shortpath="$new_path"
32329   fi
32330 
32331   # Call helper function which possibly converts this using DOS-style short mode.
32332   # If so, the updated path is stored in $new_path.
32333   new_path="$input_to_shortpath"
32334 
32335   input_path="$input_to_shortpath"
32336   # Check if we need to convert this using DOS-style short mode. If the path
32337   # contains just simple characters, use it. Otherwise (spaces, weird characters),
32338   # take no chances and rewrite it.
32339   # Note: m4 eats our [], so we need to use [ and ] instead.
32340   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
32341   if test "x$has_forbidden_chars" != x; then
32342     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
32343     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
32344     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
32345     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
32346       # Going to short mode and back again did indeed matter. Since short mode is
32347       # case insensitive, let's make it lowercase to improve readability.
32348       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
32349       # Now convert it back to Unix-stile (cygpath)
32350       input_path=`$CYGPATH -u "$shortmode_path"`
32351       new_path="$input_path"
32352     fi
32353   fi
32354 
32355   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
32356   if test "x$test_cygdrive_prefix" = x; then
32357     # As a simple fix, exclude /usr/bin since it's not a real path.
32358     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
32359       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
32360       # a path prefixed by /cygdrive for fixpath to work.
32361       new_path="$CYGWIN_ROOT_PATH$input_path"
32362     fi
32363   fi
32364 
32365   # remove trailing .exe if any
32366   new_path="${new_path/%.exe/}"
32367 
32368   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32369 
32370   # First separate the path from the arguments. This will split at the first
32371   # space.
32372   complete="$AS"
32373   path="${complete%% *}"
32374   tmp="$complete EOL"
32375   arguments="${tmp#* }"
32376 
32377   # Input might be given as Windows format, start by converting to
32378   # unix format.
32379   new_path="$path"
32380 
32381   windows_path="$new_path"
32382   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32383     unix_path=`$CYGPATH -u "$windows_path"`
32384     new_path="$unix_path"
32385   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32386     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32387     new_path="$unix_path"
32388   fi
32389 
32390 
32391   # Now try to locate executable using which
32392   new_path=`$WHICH "$new_path" 2> /dev/null`
32393 
32394   if test "x$new_path" = x; then
32395     # Oops. Which didn't find the executable.
32396     # The splitting of arguments from the executable at a space might have been incorrect,
32397     # since paths with space are more likely in Windows. Give it another try with the whole
32398     # argument.
32399     path="$complete"
32400     arguments="EOL"
32401     new_path="$path"
32402 
32403   windows_path="$new_path"
32404   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32405     unix_path=`$CYGPATH -u "$windows_path"`
32406     new_path="$unix_path"
32407   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32408     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32409     new_path="$unix_path"
32410   fi
32411 
32412 
32413     new_path=`$WHICH "$new_path" 2> /dev/null`
32414     # bat and cmd files are not always considered executable in MSYS causing which
32415     # to not find them
32416     if test "x$new_path" = x \
32417         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32418         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32419       new_path="$path"
32420 
32421   windows_path="$new_path"
32422   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32423     unix_path=`$CYGPATH -u "$windows_path"`
32424     new_path="$unix_path"
32425   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32426     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32427     new_path="$unix_path"
32428   fi
32429 
32430     fi
32431 
32432     if test "x$new_path" = x; then
32433       # It's still not found. Now this is an unrecoverable error.
32434       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
32435 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
32436       has_space=`$ECHO "$complete" | $GREP " "`
32437       if test "x$has_space" != x; then
32438         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
32439 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
32440       fi
32441       as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
32442     fi
32443   fi
32444 
32445   # Now new_path has a complete unix path to the binary
32446   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
32447     # Keep paths in /bin as-is, but remove trailing .exe if any
32448     new_path="${new_path/%.exe/}"
32449     # Do not save /bin paths to all_fixpath_prefixes!
32450   else
32451     # Not in mixed or Windows style, start by that.
32452     new_path=`cmd //c echo $new_path`
32453 
32454   input_path="$new_path"
32455   # Check if we need to convert this using DOS-style short mode. If the path
32456   # contains just simple characters, use it. Otherwise (spaces, weird characters),
32457   # take no chances and rewrite it.
32458   # Note: m4 eats our [], so we need to use [ and ] instead.
32459   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
32460   if test "x$has_forbidden_chars" != x; then
32461     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
32462     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
32463   fi
32464 
32465     # Output is in $new_path
32466 
32467   windows_path="$new_path"
32468   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32469     unix_path=`$CYGPATH -u "$windows_path"`
32470     new_path="$unix_path"
32471   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32472     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
32473     new_path="$unix_path"
32474   fi
32475 
32476     # remove trailing .exe if any
32477     new_path="${new_path/%.exe/}"
32478 
32479     # Save the first 10 bytes of this path to the storage, so fixpath can work.
32480     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
32481   fi
32482 
32483   else
32484     # We're on a unix platform. Hooray! :)
32485     # First separate the path from the arguments. This will split at the first
32486     # space.
32487     complete="$AS"
32488     path="${complete%% *}"
32489     tmp="$complete EOL"
32490     arguments="${tmp#* }"
32491 
32492     # Cannot rely on the command "which" here since it doesn't always work.
32493     is_absolute_path=`$ECHO "$path" | $GREP ^/`
32494     if test -z "$is_absolute_path"; then
32495       # Path to executable is not absolute. Find it.
32496       IFS_save="$IFS"
32497       IFS=:
32498       for p in $PATH; do
32499         if test -f "$p/$path" && test -x "$p/$path"; then
32500           new_path="$p/$path"
32501           break
32502         fi
32503       done
32504       IFS="$IFS_save"
32505     else
32506       # This is an absolute path, we can use it without further modifications.
32507       new_path="$path"
32508     fi
32509 
32510     if test "x$new_path" = x; then
32511       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5
32512 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;}
32513       has_space=`$ECHO "$complete" | $GREP " "`
32514       if test "x$has_space" != x; then
32515         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
32516 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
32517       fi
32518       as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5
32519     fi
32520   fi
32521 
32522   # Now join together the path and the arguments once again
32523   if test "x$arguments" != xEOL; then
32524     new_complete="$new_path ${arguments% *}"
32525   else
32526     new_complete="$new_path"
32527   fi
32528 
32529   if test "x$complete" != "x$new_complete"; then
32530     AS="$new_complete"
32531     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AS to \"$new_complete\"" >&5
32532 $as_echo "$as_me: Rewriting AS to \"$new_complete\"" >&6;}
32533   fi
32534 
32535   else
32536     # FIXME: is this correct for microsoft?
32537     AS="$CC -c"
32538   fi
32539 
32540 
32541   #
32542   # Setup the archiver (AR)
32543   #
32544   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
32545     # The corresponding ar tool is lib.exe (used to create static libraries)
32546     # Extract the first word of "lib", so it can be a program name with args.
32547 set dummy lib; ac_word=$2
32548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32549 $as_echo_n "checking for $ac_word... " >&6; }
32550 if ${ac_cv_prog_AR+:} false; then :
32551   $as_echo_n "(cached) " >&6
32552 else
32553   if test -n "$AR"; then
32554   ac_cv_prog_AR="$AR" # Let the user override the test.
32555 else
32556 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32557 for as_dir in $PATH
32558 do
32559   IFS=$as_save_IFS
32560   test -z "$as_dir" && as_dir=.
32561     for ac_exec_ext in '' $ac_executable_extensions; do
32562   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32563     ac_cv_prog_AR="lib"
32564     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32565     break 2
32566   fi
32567 done
32568   done
32569 IFS=$as_save_IFS
32570 
32571 fi
32572 fi
32573 AR=$ac_cv_prog_AR
32574 if test -n "$AR"; then
32575   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32576 $as_echo "$AR" >&6; }
32577 else
32578   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32579 $as_echo "no" >&6; }
32580 fi
32581 
32582 
32583   else
32584 
32585 
32586   # Publish this variable in the help.
32587 
32588 
32589   if test "x$AR" = x; then
32590     # The variable is not set by user, try to locate tool using the code snippet
32591     if test -n "$ac_tool_prefix"; then
32592   for ac_prog in ar
32593   do
32594     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32595 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32597 $as_echo_n "checking for $ac_word... " >&6; }
32598 if ${ac_cv_prog_AR+:} false; then :
32599   $as_echo_n "(cached) " >&6
32600 else
32601   if test -n "$AR"; then
32602   ac_cv_prog_AR="$AR" # Let the user override the test.
32603 else
32604 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32605 for as_dir in $PATH
32606 do
32607   IFS=$as_save_IFS
32608   test -z "$as_dir" && as_dir=.
32609     for ac_exec_ext in '' $ac_executable_extensions; do
32610   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32611     ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
32612     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32613     break 2
32614   fi
32615 done
32616   done
32617 IFS=$as_save_IFS
32618 
32619 fi
32620 fi
32621 AR=$ac_cv_prog_AR
32622 if test -n "$AR"; then
32623   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32624 $as_echo "$AR" >&6; }
32625 else
32626   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32627 $as_echo "no" >&6; }
32628 fi
32629 
32630 
32631     test -n "$AR" && break
32632   done
32633 fi
32634 if test -z "$AR"; then
32635   ac_ct_AR=$AR
32636   for ac_prog in ar
32637 do
32638   # Extract the first word of "$ac_prog", so it can be a program name with args.
32639 set dummy $ac_prog; ac_word=$2
32640 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32641 $as_echo_n "checking for $ac_word... " >&6; }
32642 if ${ac_cv_prog_ac_ct_AR+:} false; then :
32643   $as_echo_n "(cached) " >&6
32644 else
32645   if test -n "$ac_ct_AR"; then
32646   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
32647 else
32648 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32649 for as_dir in $PATH
32650 do
32651   IFS=$as_save_IFS
32652   test -z "$as_dir" && as_dir=.
32653     for ac_exec_ext in '' $ac_executable_extensions; do
32654   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32655     ac_cv_prog_ac_ct_AR="$ac_prog"
32656     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32657     break 2
32658   fi
32659 done
32660   done
32661 IFS=$as_save_IFS
32662 
32663 fi
32664 fi
32665 ac_ct_AR=$ac_cv_prog_ac_ct_AR
32666 if test -n "$ac_ct_AR"; then
32667   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
32668 $as_echo "$ac_ct_AR" >&6; }
32669 else
32670   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32671 $as_echo "no" >&6; }
32672 fi
32673 
32674 
32675   test -n "$ac_ct_AR" && break
32676 done
32677 
32678   if test "x$ac_ct_AR" = x; then
32679     AR=""
32680   else
32681     case $cross_compiling:$ac_tool_warned in
32682 yes:)
32683 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32684 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32685 ac_tool_warned=yes ;;
32686 esac
32687     AR=$ac_ct_AR
32688   fi
32689 fi
32690 
32691   else
32692     # The variable is set, but is it from the command line or the environment?
32693 
32694     # Try to remove the string !AR! from our list.
32695     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/}
32696     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
32697       # If it failed, the variable was not from the command line. Ignore it,
32698       # but warn the user (except for BASH, which is always set by the calling BASH).
32699       if test "xAR" != xBASH; then
32700         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5
32701 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;}
32702       fi
32703       # Try to locate tool using the code snippet
32704       if test -n "$ac_tool_prefix"; then
32705   for ac_prog in ar
32706   do
32707     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
32708 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
32709 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32710 $as_echo_n "checking for $ac_word... " >&6; }
32711 if ${ac_cv_prog_AR+:} false; then :
32712   $as_echo_n "(cached) " >&6
32713 else
32714   if test -n "$AR"; then
32715   ac_cv_prog_AR="$AR" # Let the user override the test.
32716 else
32717 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32718 for as_dir in $PATH
32719 do
32720   IFS=$as_save_IFS
32721   test -z "$as_dir" && as_dir=.
32722     for ac_exec_ext in '' $ac_executable_extensions; do
32723   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32724     ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
32725     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32726     break 2
32727   fi
32728 done
32729   done
32730 IFS=$as_save_IFS
32731 
32732 fi
32733 fi
32734 AR=$ac_cv_prog_AR
32735 if test -n "$AR"; then
32736   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32737 $as_echo "$AR" >&6; }
32738 else
32739   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32740 $as_echo "no" >&6; }
32741 fi
32742 
32743 
32744     test -n "$AR" && break
32745   done
32746 fi
32747 if test -z "$AR"; then
32748   ac_ct_AR=$AR
32749   for ac_prog in ar
32750 do
32751   # Extract the first word of "$ac_prog", so it can be a program name with args.
32752 set dummy $ac_prog; ac_word=$2
32753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32754 $as_echo_n "checking for $ac_word... " >&6; }
32755 if ${ac_cv_prog_ac_ct_AR+:} false; then :
32756   $as_echo_n "(cached) " >&6
32757 else
32758   if test -n "$ac_ct_AR"; then
32759   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
32760 else
32761 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32762 for as_dir in $PATH
32763 do
32764   IFS=$as_save_IFS
32765   test -z "$as_dir" && as_dir=.
32766     for ac_exec_ext in '' $ac_executable_extensions; do
32767   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32768     ac_cv_prog_ac_ct_AR="$ac_prog"
32769     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32770     break 2
32771   fi
32772 done
32773   done
32774 IFS=$as_save_IFS
32775 
32776 fi
32777 fi
32778 ac_ct_AR=$ac_cv_prog_ac_ct_AR
32779 if test -n "$ac_ct_AR"; then
32780   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
32781 $as_echo "$ac_ct_AR" >&6; }
32782 else
32783   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32784 $as_echo "no" >&6; }
32785 fi
32786 
32787 
32788   test -n "$ac_ct_AR" && break
32789 done
32790 
32791   if test "x$ac_ct_AR" = x; then
32792     AR=""
32793   else
32794     case $cross_compiling:$ac_tool_warned in
32795 yes:)
32796 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
32797 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
32798 ac_tool_warned=yes ;;
32799 esac
32800     AR=$ac_ct_AR
32801   fi
32802 fi
32803 
32804     else
32805       # If it succeeded, then it was overridden by the user. We will use it
32806       # for the tool.
32807 
32808       # First remove it from the list of overridden variables, so we can test
32809       # for unknown variables in the end.
32810       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
32811 
32812       # Check if the provided tool contains a complete path.
32813       tool_specified="$AR"
32814       tool_basename="${tool_specified##*/}"
32815       if test "x$tool_basename" = "x$tool_specified"; then
32816         # A command without a complete path is provided, search $PATH.
32817         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5
32818 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;}
32819         # Extract the first word of "$tool_basename", so it can be a program name with args.
32820 set dummy $tool_basename; ac_word=$2
32821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
32822 $as_echo_n "checking for $ac_word... " >&6; }
32823 if ${ac_cv_path_AR+:} false; then :
32824   $as_echo_n "(cached) " >&6
32825 else
32826   case $AR in
32827   [\\/]* | ?:[\\/]*)
32828   ac_cv_path_AR="$AR" # Let the user override the test with a path.
32829   ;;
32830   *)
32831   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
32832 for as_dir in $PATH
32833 do
32834   IFS=$as_save_IFS
32835   test -z "$as_dir" && as_dir=.
32836     for ac_exec_ext in '' $ac_executable_extensions; do
32837   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
32838     ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext"
32839     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
32840     break 2
32841   fi
32842 done
32843   done
32844 IFS=$as_save_IFS
32845 
32846   ;;
32847 esac
32848 fi
32849 AR=$ac_cv_path_AR
32850 if test -n "$AR"; then
32851   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
32852 $as_echo "$AR" >&6; }
32853 else
32854   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32855 $as_echo "no" >&6; }
32856 fi
32857 
32858 
32859         if test "x$AR" = x; then
32860           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
32861         fi
32862       else
32863         # Otherwise we believe it is a complete path. Use it as it is.
32864         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5
32865 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;}
32866         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5
32867 $as_echo_n "checking for AR... " >&6; }
32868         if test ! -x "$tool_specified"; then
32869           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
32870 $as_echo "not found" >&6; }
32871           as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5
32872         fi
32873         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
32874 $as_echo "$tool_specified" >&6; }
32875       fi
32876     fi
32877   fi
32878 
32879 
32880   fi
32881 
32882   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
32883 
32884   # First separate the path from the arguments. This will split at the first
32885   # space.
32886   complete="$AR"
32887   path="${complete%% *}"
32888   tmp="$complete EOL"
32889   arguments="${tmp#* }"
32890 
32891   # Input might be given as Windows format, start by converting to
32892   # unix format.
32893   new_path=`$CYGPATH -u "$path"`
32894 
32895   # Now try to locate executable using which
32896   new_path=`$WHICH "$new_path" 2> /dev/null`
32897   # bat and cmd files are not always considered executable in cygwin causing which
32898   # to not find them
32899   if test "x$new_path" = x \
32900       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32901       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32902     new_path=`$CYGPATH -u "$path"`
32903   fi
32904   if test "x$new_path" = x; then
32905     # Oops. Which didn't find the executable.
32906     # The splitting of arguments from the executable at a space might have been incorrect,
32907     # since paths with space are more likely in Windows. Give it another try with the whole
32908     # argument.
32909     path="$complete"
32910     arguments="EOL"
32911     new_path=`$CYGPATH -u "$path"`
32912     new_path=`$WHICH "$new_path" 2> /dev/null`
32913     # bat and cmd files are not always considered executable in cygwin causing which
32914     # to not find them
32915     if test "x$new_path" = x \
32916         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
32917         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
32918       new_path=`$CYGPATH -u "$path"`
32919     fi
32920     if test "x$new_path" = x; then
32921       # It's still not found. Now this is an unrecoverable error.
32922       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
32923 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
32924       has_space=`$ECHO "$complete" | $GREP " "`
32925       if test "x$has_space" != x; then
32926         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
32927 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
32928       fi
32929       as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32930     fi
32931   fi
32932 
32933   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
32934   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
32935   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
32936   # "foo.exe" is OK but "foo" is an error.
32937   #
32938   # This test is therefore slightly more accurate than "test -f" to check for file presence.
32939   # It is also a way to make sure we got the proper file name for the real test later on.
32940   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
32941   if test "x$test_shortpath" = x; then
32942     # Short path failed, file does not exist as specified.
32943     # Try adding .exe or .cmd
32944     if test -f "${new_path}.exe"; then
32945       input_to_shortpath="${new_path}.exe"
32946     elif test -f "${new_path}.cmd"; then
32947       input_to_shortpath="${new_path}.cmd"
32948     else
32949       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$new_path\", is invalid." >&5
32950 $as_echo "$as_me: The path of AR, which resolves as \"$new_path\", is invalid." >&6;}
32951       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
32952 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
32953       as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
32954     fi
32955   else
32956     input_to_shortpath="$new_path"
32957   fi
32958 
32959   # Call helper function which possibly converts this using DOS-style short mode.
32960   # If so, the updated path is stored in $new_path.
32961   new_path="$input_to_shortpath"
32962 
32963   input_path="$input_to_shortpath"
32964   # Check if we need to convert this using DOS-style short mode. If the path
32965   # contains just simple characters, use it. Otherwise (spaces, weird characters),
32966   # take no chances and rewrite it.
32967   # Note: m4 eats our [], so we need to use [ and ] instead.
32968   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
32969   if test "x$has_forbidden_chars" != x; then
32970     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
32971     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
32972     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
32973     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
32974       # Going to short mode and back again did indeed matter. Since short mode is
32975       # case insensitive, let's make it lowercase to improve readability.
32976       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
32977       # Now convert it back to Unix-stile (cygpath)
32978       input_path=`$CYGPATH -u "$shortmode_path"`
32979       new_path="$input_path"
32980     fi
32981   fi
32982 
32983   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
32984   if test "x$test_cygdrive_prefix" = x; then
32985     # As a simple fix, exclude /usr/bin since it's not a real path.
32986     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
32987       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
32988       # a path prefixed by /cygdrive for fixpath to work.
32989       new_path="$CYGWIN_ROOT_PATH$input_path"
32990     fi
32991   fi
32992 
32993   # remove trailing .exe if any
32994   new_path="${new_path/%.exe/}"
32995 
32996   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
32997 
32998   # First separate the path from the arguments. This will split at the first
32999   # space.
33000   complete="$AR"
33001   path="${complete%% *}"
33002   tmp="$complete EOL"
33003   arguments="${tmp#* }"
33004 
33005   # Input might be given as Windows format, start by converting to
33006   # unix format.
33007   new_path="$path"
33008 
33009   windows_path="$new_path"
33010   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33011     unix_path=`$CYGPATH -u "$windows_path"`
33012     new_path="$unix_path"
33013   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33014     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33015     new_path="$unix_path"
33016   fi
33017 
33018 
33019   # Now try to locate executable using which
33020   new_path=`$WHICH "$new_path" 2> /dev/null`
33021 
33022   if test "x$new_path" = x; then
33023     # Oops. Which didn't find the executable.
33024     # The splitting of arguments from the executable at a space might have been incorrect,
33025     # since paths with space are more likely in Windows. Give it another try with the whole
33026     # argument.
33027     path="$complete"
33028     arguments="EOL"
33029     new_path="$path"
33030 
33031   windows_path="$new_path"
33032   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33033     unix_path=`$CYGPATH -u "$windows_path"`
33034     new_path="$unix_path"
33035   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33036     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33037     new_path="$unix_path"
33038   fi
33039 
33040 
33041     new_path=`$WHICH "$new_path" 2> /dev/null`
33042     # bat and cmd files are not always considered executable in MSYS causing which
33043     # to not find them
33044     if test "x$new_path" = x \
33045         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33046         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33047       new_path="$path"
33048 
33049   windows_path="$new_path"
33050   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33051     unix_path=`$CYGPATH -u "$windows_path"`
33052     new_path="$unix_path"
33053   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33054     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33055     new_path="$unix_path"
33056   fi
33057 
33058     fi
33059 
33060     if test "x$new_path" = x; then
33061       # It's still not found. Now this is an unrecoverable error.
33062       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
33063 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
33064       has_space=`$ECHO "$complete" | $GREP " "`
33065       if test "x$has_space" != x; then
33066         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33067 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33068       fi
33069       as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
33070     fi
33071   fi
33072 
33073   # Now new_path has a complete unix path to the binary
33074   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
33075     # Keep paths in /bin as-is, but remove trailing .exe if any
33076     new_path="${new_path/%.exe/}"
33077     # Do not save /bin paths to all_fixpath_prefixes!
33078   else
33079     # Not in mixed or Windows style, start by that.
33080     new_path=`cmd //c echo $new_path`
33081 
33082   input_path="$new_path"
33083   # Check if we need to convert this using DOS-style short mode. If the path
33084   # contains just simple characters, use it. Otherwise (spaces, weird characters),
33085   # take no chances and rewrite it.
33086   # Note: m4 eats our [], so we need to use [ and ] instead.
33087   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
33088   if test "x$has_forbidden_chars" != x; then
33089     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33090     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33091   fi
33092 
33093     # Output is in $new_path
33094 
33095   windows_path="$new_path"
33096   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33097     unix_path=`$CYGPATH -u "$windows_path"`
33098     new_path="$unix_path"
33099   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33100     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33101     new_path="$unix_path"
33102   fi
33103 
33104     # remove trailing .exe if any
33105     new_path="${new_path/%.exe/}"
33106 
33107     # Save the first 10 bytes of this path to the storage, so fixpath can work.
33108     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
33109   fi
33110 
33111   else
33112     # We're on a unix platform. Hooray! :)
33113     # First separate the path from the arguments. This will split at the first
33114     # space.
33115     complete="$AR"
33116     path="${complete%% *}"
33117     tmp="$complete EOL"
33118     arguments="${tmp#* }"
33119 
33120     # Cannot rely on the command "which" here since it doesn't always work.
33121     is_absolute_path=`$ECHO "$path" | $GREP ^/`
33122     if test -z "$is_absolute_path"; then
33123       # Path to executable is not absolute. Find it.
33124       IFS_save="$IFS"
33125       IFS=:
33126       for p in $PATH; do
33127         if test -f "$p/$path" && test -x "$p/$path"; then
33128           new_path="$p/$path"
33129           break
33130         fi
33131       done
33132       IFS="$IFS_save"
33133     else
33134       # This is an absolute path, we can use it without further modifications.
33135       new_path="$path"
33136     fi
33137 
33138     if test "x$new_path" = x; then
33139       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5
33140 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;}
33141       has_space=`$ECHO "$complete" | $GREP " "`
33142       if test "x$has_space" != x; then
33143         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
33144 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
33145       fi
33146       as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5
33147     fi
33148   fi
33149 
33150   # Now join together the path and the arguments once again
33151   if test "x$arguments" != xEOL; then
33152     new_complete="$new_path ${arguments% *}"
33153   else
33154     new_complete="$new_path"
33155   fi
33156 
33157   if test "x$complete" != "x$new_complete"; then
33158     AR="$new_complete"
33159     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AR to \"$new_complete\"" >&5
33160 $as_echo "$as_me: Rewriting AR to \"$new_complete\"" >&6;}
33161   fi
33162 
33163 
33164 
33165   if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
33166     ac_ext=m
33167 ac_cpp='$OBJCPP $CPPFLAGS'
33168 ac_compile='$OBJC -c $OBJCFLAGS $CPPFLAGS conftest.$ac_ext >&5'
33169 ac_link='$OBJC -o conftest$ac_exeext $OBJCFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
33170 ac_compiler_gnu=$ac_cv_objc_compiler_gnu
33171 if test -n "$ac_tool_prefix"; then
33172   for ac_prog in gcc objcc objc cc CC
33173   do
33174     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
33175 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
33176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33177 $as_echo_n "checking for $ac_word... " >&6; }
33178 if ${ac_cv_prog_OBJC+:} false; then :
33179   $as_echo_n "(cached) " >&6
33180 else
33181   if test -n "$OBJC"; then
33182   ac_cv_prog_OBJC="$OBJC" # Let the user override the test.
33183 else
33184 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33185 for as_dir in $PATH
33186 do
33187   IFS=$as_save_IFS
33188   test -z "$as_dir" && as_dir=.
33189     for ac_exec_ext in '' $ac_executable_extensions; do
33190   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33191     ac_cv_prog_OBJC="$ac_tool_prefix$ac_prog"
33192     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33193     break 2
33194   fi
33195 done
33196   done
33197 IFS=$as_save_IFS
33198 
33199 fi
33200 fi
33201 OBJC=$ac_cv_prog_OBJC
33202 if test -n "$OBJC"; then
33203   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJC" >&5
33204 $as_echo "$OBJC" >&6; }
33205 else
33206   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33207 $as_echo "no" >&6; }
33208 fi
33209 
33210 
33211     test -n "$OBJC" && break
33212   done
33213 fi
33214 if test -z "$OBJC"; then
33215   ac_ct_OBJC=$OBJC
33216   for ac_prog in gcc objcc objc cc CC
33217 do
33218   # Extract the first word of "$ac_prog", so it can be a program name with args.
33219 set dummy $ac_prog; ac_word=$2
33220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33221 $as_echo_n "checking for $ac_word... " >&6; }
33222 if ${ac_cv_prog_ac_ct_OBJC+:} false; then :
33223   $as_echo_n "(cached) " >&6
33224 else
33225   if test -n "$ac_ct_OBJC"; then
33226   ac_cv_prog_ac_ct_OBJC="$ac_ct_OBJC" # Let the user override the test.
33227 else
33228 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33229 for as_dir in $PATH
33230 do
33231   IFS=$as_save_IFS
33232   test -z "$as_dir" && as_dir=.
33233     for ac_exec_ext in '' $ac_executable_extensions; do
33234   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33235     ac_cv_prog_ac_ct_OBJC="$ac_prog"
33236     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33237     break 2
33238   fi
33239 done
33240   done
33241 IFS=$as_save_IFS
33242 
33243 fi
33244 fi
33245 ac_ct_OBJC=$ac_cv_prog_ac_ct_OBJC
33246 if test -n "$ac_ct_OBJC"; then
33247   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJC" >&5
33248 $as_echo "$ac_ct_OBJC" >&6; }
33249 else
33250   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33251 $as_echo "no" >&6; }
33252 fi
33253 
33254 
33255   test -n "$ac_ct_OBJC" && break
33256 done
33257 
33258   if test "x$ac_ct_OBJC" = x; then
33259     OBJC="gcc"
33260   else
33261     case $cross_compiling:$ac_tool_warned in
33262 yes:)
33263 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
33264 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
33265 ac_tool_warned=yes ;;
33266 esac
33267     OBJC=$ac_ct_OBJC
33268   fi
33269 fi
33270 
33271 # Provide some information about the compiler.
33272 $as_echo "$as_me:${as_lineno-$LINENO}: checking for Objective C compiler version" >&5
33273 set X $ac_compile
33274 ac_compiler=$2
33275 for ac_option in --version -v -V -qversion; do
33276   { { ac_try="$ac_compiler $ac_option >&5"
33277 case "(($ac_try" in
33278   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33279   *) ac_try_echo=$ac_try;;
33280 esac
33281 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
33282 $as_echo "$ac_try_echo"; } >&5
33283   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
33284   ac_status=$?
33285   if test -s conftest.err; then
33286     sed '10a\
33287 ... rest of stderr output deleted ...
33288          10q' conftest.err >conftest.er1
33289     cat conftest.er1 >&5
33290   fi
33291   rm -f conftest.er1 conftest.err
33292   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
33293   test $ac_status = 0; }
33294 done
33295 
33296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU Objective C compiler" >&5
33297 $as_echo_n "checking whether we are using the GNU Objective C compiler... " >&6; }
33298 if ${ac_cv_objc_compiler_gnu+:} false; then :
33299   $as_echo_n "(cached) " >&6
33300 else
33301   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33302 /* end confdefs.h.  */
33303 
33304 int
33305 main ()
33306 {
33307 #ifndef __GNUC__
33308        choke me
33309 #endif
33310 
33311   ;
33312   return 0;
33313 }
33314 _ACEOF
33315 if ac_fn_objc_try_compile "$LINENO"; then :
33316   ac_compiler_gnu=yes
33317 else
33318   ac_compiler_gnu=no
33319 fi
33320 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33321 ac_cv_objc_compiler_gnu=$ac_compiler_gnu
33322 
33323 fi
33324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objc_compiler_gnu" >&5
33325 $as_echo "$ac_cv_objc_compiler_gnu" >&6; }
33326 if test $ac_compiler_gnu = yes; then
33327   GOBJC=yes
33328 else
33329   GOBJC=
33330 fi
33331 ac_test_OBJCFLAGS=${OBJCFLAGS+set}
33332 ac_save_OBJCFLAGS=$OBJCFLAGS
33333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $OBJC accepts -g" >&5
33334 $as_echo_n "checking whether $OBJC accepts -g... " >&6; }
33335 if ${ac_cv_prog_objc_g+:} false; then :
33336   $as_echo_n "(cached) " >&6
33337 else
33338   ac_save_objc_werror_flag=$ac_objc_werror_flag
33339    ac_objc_werror_flag=yes
33340    ac_cv_prog_objc_g=no
33341    OBJCFLAGS="-g"
33342    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33343 /* end confdefs.h.  */
33344 
33345 int
33346 main ()
33347 {
33348 
33349   ;
33350   return 0;
33351 }
33352 _ACEOF
33353 if ac_fn_objc_try_compile "$LINENO"; then :
33354   ac_cv_prog_objc_g=yes
33355 else
33356   OBJCFLAGS=""
33357       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33358 /* end confdefs.h.  */
33359 
33360 int
33361 main ()
33362 {
33363 
33364   ;
33365   return 0;
33366 }
33367 _ACEOF
33368 if ac_fn_objc_try_compile "$LINENO"; then :
33369 
33370 else
33371   ac_objc_werror_flag=$ac_save_objc_werror_flag
33372          OBJCFLAGS="-g"
33373          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33374 /* end confdefs.h.  */
33375 
33376 int
33377 main ()
33378 {
33379 
33380   ;
33381   return 0;
33382 }
33383 _ACEOF
33384 if ac_fn_objc_try_compile "$LINENO"; then :
33385   ac_cv_prog_objc_g=yes
33386 fi
33387 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33388 fi
33389 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33390 fi
33391 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33392    ac_objc_werror_flag=$ac_save_objc_werror_flag
33393 fi
33394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_objc_g" >&5
33395 $as_echo "$ac_cv_prog_objc_g" >&6; }
33396 if test "$ac_test_OBJCFLAGS" = set; then
33397   OBJCFLAGS=$ac_save_OBJCFLAGS
33398 elif test $ac_cv_prog_objc_g = yes; then
33399   if test "$GOBJC" = yes; then
33400     OBJCFLAGS="-g -O2"
33401   else
33402     OBJCFLAGS="-g"
33403   fi
33404 else
33405   if test "$GOBJC" = yes; then
33406     OBJCFLAGS="-O2"
33407   else
33408     OBJCFLAGS=
33409   fi
33410 fi
33411 ac_ext=cpp
33412 ac_cpp='$CXXCPP $CPPFLAGS'
33413 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
33414 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
33415 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
33416 
33417 
33418   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33419 
33420   # First separate the path from the arguments. This will split at the first
33421   # space.
33422   complete="$OBJC"
33423   path="${complete%% *}"
33424   tmp="$complete EOL"
33425   arguments="${tmp#* }"
33426 
33427   # Input might be given as Windows format, start by converting to
33428   # unix format.
33429   new_path=`$CYGPATH -u "$path"`
33430 
33431   # Now try to locate executable using which
33432   new_path=`$WHICH "$new_path" 2> /dev/null`
33433   # bat and cmd files are not always considered executable in cygwin causing which
33434   # to not find them
33435   if test "x$new_path" = x \
33436       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33437       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33438     new_path=`$CYGPATH -u "$path"`
33439   fi
33440   if test "x$new_path" = x; then
33441     # Oops. Which didn't find the executable.
33442     # The splitting of arguments from the executable at a space might have been incorrect,
33443     # since paths with space are more likely in Windows. Give it another try with the whole
33444     # argument.
33445     path="$complete"
33446     arguments="EOL"
33447     new_path=`$CYGPATH -u "$path"`
33448     new_path=`$WHICH "$new_path" 2> /dev/null`
33449     # bat and cmd files are not always considered executable in cygwin causing which
33450     # to not find them
33451     if test "x$new_path" = x \
33452         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33453         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33454       new_path=`$CYGPATH -u "$path"`
33455     fi
33456     if test "x$new_path" = x; then
33457       # It's still not found. Now this is an unrecoverable error.
33458       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
33459 $as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
33460       has_space=`$ECHO "$complete" | $GREP " "`
33461       if test "x$has_space" != x; then
33462         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33463 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33464       fi
33465       as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33466     fi
33467   fi
33468 
33469   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
33470   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
33471   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
33472   # "foo.exe" is OK but "foo" is an error.
33473   #
33474   # This test is therefore slightly more accurate than "test -f" to check for file presence.
33475   # It is also a way to make sure we got the proper file name for the real test later on.
33476   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
33477   if test "x$test_shortpath" = x; then
33478     # Short path failed, file does not exist as specified.
33479     # Try adding .exe or .cmd
33480     if test -f "${new_path}.exe"; then
33481       input_to_shortpath="${new_path}.exe"
33482     elif test -f "${new_path}.cmd"; then
33483       input_to_shortpath="${new_path}.cmd"
33484     else
33485       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$new_path\", is invalid." >&5
33486 $as_echo "$as_me: The path of OBJC, which resolves as \"$new_path\", is invalid." >&6;}
33487       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33488 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33489       as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33490     fi
33491   else
33492     input_to_shortpath="$new_path"
33493   fi
33494 
33495   # Call helper function which possibly converts this using DOS-style short mode.
33496   # If so, the updated path is stored in $new_path.
33497   new_path="$input_to_shortpath"
33498 
33499   input_path="$input_to_shortpath"
33500   # Check if we need to convert this using DOS-style short mode. If the path
33501   # contains just simple characters, use it. Otherwise (spaces, weird characters),
33502   # take no chances and rewrite it.
33503   # Note: m4 eats our [], so we need to use [ and ] instead.
33504   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33505   if test "x$has_forbidden_chars" != x; then
33506     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33507     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33508     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33509     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33510       # Going to short mode and back again did indeed matter. Since short mode is
33511       # case insensitive, let's make it lowercase to improve readability.
33512       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33513       # Now convert it back to Unix-stile (cygpath)
33514       input_path=`$CYGPATH -u "$shortmode_path"`
33515       new_path="$input_path"
33516     fi
33517   fi
33518 
33519   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33520   if test "x$test_cygdrive_prefix" = x; then
33521     # As a simple fix, exclude /usr/bin since it's not a real path.
33522     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33523       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33524       # a path prefixed by /cygdrive for fixpath to work.
33525       new_path="$CYGWIN_ROOT_PATH$input_path"
33526     fi
33527   fi
33528 
33529   # remove trailing .exe if any
33530   new_path="${new_path/%.exe/}"
33531 
33532   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33533 
33534   # First separate the path from the arguments. This will split at the first
33535   # space.
33536   complete="$OBJC"
33537   path="${complete%% *}"
33538   tmp="$complete EOL"
33539   arguments="${tmp#* }"
33540 
33541   # Input might be given as Windows format, start by converting to
33542   # unix format.
33543   new_path="$path"
33544 
33545   windows_path="$new_path"
33546   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33547     unix_path=`$CYGPATH -u "$windows_path"`
33548     new_path="$unix_path"
33549   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33550     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33551     new_path="$unix_path"
33552   fi
33553 
33554 
33555   # Now try to locate executable using which
33556   new_path=`$WHICH "$new_path" 2> /dev/null`
33557 
33558   if test "x$new_path" = x; then
33559     # Oops. Which didn't find the executable.
33560     # The splitting of arguments from the executable at a space might have been incorrect,
33561     # since paths with space are more likely in Windows. Give it another try with the whole
33562     # argument.
33563     path="$complete"
33564     arguments="EOL"
33565     new_path="$path"
33566 
33567   windows_path="$new_path"
33568   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33569     unix_path=`$CYGPATH -u "$windows_path"`
33570     new_path="$unix_path"
33571   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33572     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33573     new_path="$unix_path"
33574   fi
33575 
33576 
33577     new_path=`$WHICH "$new_path" 2> /dev/null`
33578     # bat and cmd files are not always considered executable in MSYS causing which
33579     # to not find them
33580     if test "x$new_path" = x \
33581         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33582         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33583       new_path="$path"
33584 
33585   windows_path="$new_path"
33586   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33587     unix_path=`$CYGPATH -u "$windows_path"`
33588     new_path="$unix_path"
33589   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33590     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33591     new_path="$unix_path"
33592   fi
33593 
33594     fi
33595 
33596     if test "x$new_path" = x; then
33597       # It's still not found. Now this is an unrecoverable error.
33598       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
33599 $as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
33600       has_space=`$ECHO "$complete" | $GREP " "`
33601       if test "x$has_space" != x; then
33602         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33603 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33604       fi
33605       as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33606     fi
33607   fi
33608 
33609   # Now new_path has a complete unix path to the binary
33610   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
33611     # Keep paths in /bin as-is, but remove trailing .exe if any
33612     new_path="${new_path/%.exe/}"
33613     # Do not save /bin paths to all_fixpath_prefixes!
33614   else
33615     # Not in mixed or Windows style, start by that.
33616     new_path=`cmd //c echo $new_path`
33617 
33618   input_path="$new_path"
33619   # Check if we need to convert this using DOS-style short mode. If the path
33620   # contains just simple characters, use it. Otherwise (spaces, weird characters),
33621   # take no chances and rewrite it.
33622   # Note: m4 eats our [], so we need to use [ and ] instead.
33623   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
33624   if test "x$has_forbidden_chars" != x; then
33625     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33626     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33627   fi
33628 
33629     # Output is in $new_path
33630 
33631   windows_path="$new_path"
33632   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33633     unix_path=`$CYGPATH -u "$windows_path"`
33634     new_path="$unix_path"
33635   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
33636     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
33637     new_path="$unix_path"
33638   fi
33639 
33640     # remove trailing .exe if any
33641     new_path="${new_path/%.exe/}"
33642 
33643     # Save the first 10 bytes of this path to the storage, so fixpath can work.
33644     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
33645   fi
33646 
33647   else
33648     # We're on a unix platform. Hooray! :)
33649     # First separate the path from the arguments. This will split at the first
33650     # space.
33651     complete="$OBJC"
33652     path="${complete%% *}"
33653     tmp="$complete EOL"
33654     arguments="${tmp#* }"
33655 
33656     # Cannot rely on the command "which" here since it doesn't always work.
33657     is_absolute_path=`$ECHO "$path" | $GREP ^/`
33658     if test -z "$is_absolute_path"; then
33659       # Path to executable is not absolute. Find it.
33660       IFS_save="$IFS"
33661       IFS=:
33662       for p in $PATH; do
33663         if test -f "$p/$path" && test -x "$p/$path"; then
33664           new_path="$p/$path"
33665           break
33666         fi
33667       done
33668       IFS="$IFS_save"
33669     else
33670       # This is an absolute path, we can use it without further modifications.
33671       new_path="$path"
33672     fi
33673 
33674     if test "x$new_path" = x; then
33675       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJC, which resolves as \"$complete\", is not found." >&5
33676 $as_echo "$as_me: The path of OBJC, which resolves as \"$complete\", is not found." >&6;}
33677       has_space=`$ECHO "$complete" | $GREP " "`
33678       if test "x$has_space" != x; then
33679         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
33680 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
33681       fi
33682       as_fn_error $? "Cannot locate the the path of OBJC" "$LINENO" 5
33683     fi
33684   fi
33685 
33686   # Now join together the path and the arguments once again
33687   if test "x$arguments" != xEOL; then
33688     new_complete="$new_path ${arguments% *}"
33689   else
33690     new_complete="$new_path"
33691   fi
33692 
33693   if test "x$complete" != "x$new_complete"; then
33694     OBJC="$new_complete"
33695     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJC to \"$new_complete\"" >&5
33696 $as_echo "$as_me: Rewriting OBJC to \"$new_complete\"" >&6;}
33697   fi
33698 
33699 
33700 
33701   # Publish this variable in the help.
33702 
33703 
33704   if test "x$LIPO" = x; then
33705     # The variable is not set by user, try to locate tool using the code snippet
33706     for ac_prog in lipo
33707 do
33708   # Extract the first word of "$ac_prog", so it can be a program name with args.
33709 set dummy $ac_prog; ac_word=$2
33710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33711 $as_echo_n "checking for $ac_word... " >&6; }
33712 if ${ac_cv_path_LIPO+:} false; then :
33713   $as_echo_n "(cached) " >&6
33714 else
33715   case $LIPO in
33716   [\\/]* | ?:[\\/]*)
33717   ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
33718   ;;
33719   *)
33720   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33721 for as_dir in $PATH
33722 do
33723   IFS=$as_save_IFS
33724   test -z "$as_dir" && as_dir=.
33725     for ac_exec_ext in '' $ac_executable_extensions; do
33726   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33727     ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
33728     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33729     break 2
33730   fi
33731 done
33732   done
33733 IFS=$as_save_IFS
33734 
33735   ;;
33736 esac
33737 fi
33738 LIPO=$ac_cv_path_LIPO
33739 if test -n "$LIPO"; then
33740   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
33741 $as_echo "$LIPO" >&6; }
33742 else
33743   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33744 $as_echo "no" >&6; }
33745 fi
33746 
33747 
33748   test -n "$LIPO" && break
33749 done
33750 
33751   else
33752     # The variable is set, but is it from the command line or the environment?
33753 
33754     # Try to remove the string !LIPO! from our list.
33755     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LIPO!/}
33756     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
33757       # If it failed, the variable was not from the command line. Ignore it,
33758       # but warn the user (except for BASH, which is always set by the calling BASH).
33759       if test "xLIPO" != xBASH; then
33760         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&5
33761 $as_echo "$as_me: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&2;}
33762       fi
33763       # Try to locate tool using the code snippet
33764       for ac_prog in lipo
33765 do
33766   # Extract the first word of "$ac_prog", so it can be a program name with args.
33767 set dummy $ac_prog; ac_word=$2
33768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33769 $as_echo_n "checking for $ac_word... " >&6; }
33770 if ${ac_cv_path_LIPO+:} false; then :
33771   $as_echo_n "(cached) " >&6
33772 else
33773   case $LIPO in
33774   [\\/]* | ?:[\\/]*)
33775   ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
33776   ;;
33777   *)
33778   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33779 for as_dir in $PATH
33780 do
33781   IFS=$as_save_IFS
33782   test -z "$as_dir" && as_dir=.
33783     for ac_exec_ext in '' $ac_executable_extensions; do
33784   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33785     ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
33786     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33787     break 2
33788   fi
33789 done
33790   done
33791 IFS=$as_save_IFS
33792 
33793   ;;
33794 esac
33795 fi
33796 LIPO=$ac_cv_path_LIPO
33797 if test -n "$LIPO"; then
33798   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
33799 $as_echo "$LIPO" >&6; }
33800 else
33801   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33802 $as_echo "no" >&6; }
33803 fi
33804 
33805 
33806   test -n "$LIPO" && break
33807 done
33808 
33809     else
33810       # If it succeeded, then it was overridden by the user. We will use it
33811       # for the tool.
33812 
33813       # First remove it from the list of overridden variables, so we can test
33814       # for unknown variables in the end.
33815       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
33816 
33817       # Check if the provided tool contains a complete path.
33818       tool_specified="$LIPO"
33819       tool_basename="${tool_specified##*/}"
33820       if test "x$tool_basename" = "x$tool_specified"; then
33821         # A command without a complete path is provided, search $PATH.
33822         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LIPO=$tool_basename" >&5
33823 $as_echo "$as_me: Will search for user supplied tool LIPO=$tool_basename" >&6;}
33824         # Extract the first word of "$tool_basename", so it can be a program name with args.
33825 set dummy $tool_basename; ac_word=$2
33826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
33827 $as_echo_n "checking for $ac_word... " >&6; }
33828 if ${ac_cv_path_LIPO+:} false; then :
33829   $as_echo_n "(cached) " >&6
33830 else
33831   case $LIPO in
33832   [\\/]* | ?:[\\/]*)
33833   ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path.
33834   ;;
33835   *)
33836   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33837 for as_dir in $PATH
33838 do
33839   IFS=$as_save_IFS
33840   test -z "$as_dir" && as_dir=.
33841     for ac_exec_ext in '' $ac_executable_extensions; do
33842   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
33843     ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext"
33844     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
33845     break 2
33846   fi
33847 done
33848   done
33849 IFS=$as_save_IFS
33850 
33851   ;;
33852 esac
33853 fi
33854 LIPO=$ac_cv_path_LIPO
33855 if test -n "$LIPO"; then
33856   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
33857 $as_echo "$LIPO" >&6; }
33858 else
33859   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33860 $as_echo "no" >&6; }
33861 fi
33862 
33863 
33864         if test "x$LIPO" = x; then
33865           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
33866         fi
33867       else
33868         # Otherwise we believe it is a complete path. Use it as it is.
33869         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LIPO=$tool_specified" >&5
33870 $as_echo "$as_me: Will use user supplied tool LIPO=$tool_specified" >&6;}
33871         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5
33872 $as_echo_n "checking for LIPO... " >&6; }
33873         if test ! -x "$tool_specified"; then
33874           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
33875 $as_echo "not found" >&6; }
33876           as_fn_error $? "User supplied tool LIPO=$tool_specified does not exist or is not executable" "$LINENO" 5
33877         fi
33878         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
33879 $as_echo "$tool_specified" >&6; }
33880       fi
33881     fi
33882   fi
33883 
33884 
33885 
33886   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
33887 
33888   # First separate the path from the arguments. This will split at the first
33889   # space.
33890   complete="$LIPO"
33891   path="${complete%% *}"
33892   tmp="$complete EOL"
33893   arguments="${tmp#* }"
33894 
33895   # Input might be given as Windows format, start by converting to
33896   # unix format.
33897   new_path=`$CYGPATH -u "$path"`
33898 
33899   # Now try to locate executable using which
33900   new_path=`$WHICH "$new_path" 2> /dev/null`
33901   # bat and cmd files are not always considered executable in cygwin causing which
33902   # to not find them
33903   if test "x$new_path" = x \
33904       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33905       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33906     new_path=`$CYGPATH -u "$path"`
33907   fi
33908   if test "x$new_path" = x; then
33909     # Oops. Which didn't find the executable.
33910     # The splitting of arguments from the executable at a space might have been incorrect,
33911     # since paths with space are more likely in Windows. Give it another try with the whole
33912     # argument.
33913     path="$complete"
33914     arguments="EOL"
33915     new_path=`$CYGPATH -u "$path"`
33916     new_path=`$WHICH "$new_path" 2> /dev/null`
33917     # bat and cmd files are not always considered executable in cygwin causing which
33918     # to not find them
33919     if test "x$new_path" = x \
33920         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
33921         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
33922       new_path=`$CYGPATH -u "$path"`
33923     fi
33924     if test "x$new_path" = x; then
33925       # It's still not found. Now this is an unrecoverable error.
33926       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
33927 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
33928       has_space=`$ECHO "$complete" | $GREP " "`
33929       if test "x$has_space" != x; then
33930         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
33931 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
33932       fi
33933       as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33934     fi
33935   fi
33936 
33937   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
33938   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
33939   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
33940   # "foo.exe" is OK but "foo" is an error.
33941   #
33942   # This test is therefore slightly more accurate than "test -f" to check for file presence.
33943   # It is also a way to make sure we got the proper file name for the real test later on.
33944   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
33945   if test "x$test_shortpath" = x; then
33946     # Short path failed, file does not exist as specified.
33947     # Try adding .exe or .cmd
33948     if test -f "${new_path}.exe"; then
33949       input_to_shortpath="${new_path}.exe"
33950     elif test -f "${new_path}.cmd"; then
33951       input_to_shortpath="${new_path}.cmd"
33952     else
33953       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$new_path\", is invalid." >&5
33954 $as_echo "$as_me: The path of LIPO, which resolves as \"$new_path\", is invalid." >&6;}
33955       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
33956 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
33957       as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
33958     fi
33959   else
33960     input_to_shortpath="$new_path"
33961   fi
33962 
33963   # Call helper function which possibly converts this using DOS-style short mode.
33964   # If so, the updated path is stored in $new_path.
33965   new_path="$input_to_shortpath"
33966 
33967   input_path="$input_to_shortpath"
33968   # Check if we need to convert this using DOS-style short mode. If the path
33969   # contains just simple characters, use it. Otherwise (spaces, weird characters),
33970   # take no chances and rewrite it.
33971   # Note: m4 eats our [], so we need to use [ and ] instead.
33972   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
33973   if test "x$has_forbidden_chars" != x; then
33974     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
33975     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
33976     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
33977     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
33978       # Going to short mode and back again did indeed matter. Since short mode is
33979       # case insensitive, let's make it lowercase to improve readability.
33980       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
33981       # Now convert it back to Unix-stile (cygpath)
33982       input_path=`$CYGPATH -u "$shortmode_path"`
33983       new_path="$input_path"
33984     fi
33985   fi
33986 
33987   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
33988   if test "x$test_cygdrive_prefix" = x; then
33989     # As a simple fix, exclude /usr/bin since it's not a real path.
33990     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
33991       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
33992       # a path prefixed by /cygdrive for fixpath to work.
33993       new_path="$CYGWIN_ROOT_PATH$input_path"
33994     fi
33995   fi
33996 
33997   # remove trailing .exe if any
33998   new_path="${new_path/%.exe/}"
33999 
34000   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34001 
34002   # First separate the path from the arguments. This will split at the first
34003   # space.
34004   complete="$LIPO"
34005   path="${complete%% *}"
34006   tmp="$complete EOL"
34007   arguments="${tmp#* }"
34008 
34009   # Input might be given as Windows format, start by converting to
34010   # unix format.
34011   new_path="$path"
34012 
34013   windows_path="$new_path"
34014   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34015     unix_path=`$CYGPATH -u "$windows_path"`
34016     new_path="$unix_path"
34017   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34018     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34019     new_path="$unix_path"
34020   fi
34021 
34022 
34023   # Now try to locate executable using which
34024   new_path=`$WHICH "$new_path" 2> /dev/null`
34025 
34026   if test "x$new_path" = x; then
34027     # Oops. Which didn't find the executable.
34028     # The splitting of arguments from the executable at a space might have been incorrect,
34029     # since paths with space are more likely in Windows. Give it another try with the whole
34030     # argument.
34031     path="$complete"
34032     arguments="EOL"
34033     new_path="$path"
34034 
34035   windows_path="$new_path"
34036   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34037     unix_path=`$CYGPATH -u "$windows_path"`
34038     new_path="$unix_path"
34039   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34040     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34041     new_path="$unix_path"
34042   fi
34043 
34044 
34045     new_path=`$WHICH "$new_path" 2> /dev/null`
34046     # bat and cmd files are not always considered executable in MSYS causing which
34047     # to not find them
34048     if test "x$new_path" = x \
34049         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34050         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34051       new_path="$path"
34052 
34053   windows_path="$new_path"
34054   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34055     unix_path=`$CYGPATH -u "$windows_path"`
34056     new_path="$unix_path"
34057   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34058     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34059     new_path="$unix_path"
34060   fi
34061 
34062     fi
34063 
34064     if test "x$new_path" = x; then
34065       # It's still not found. Now this is an unrecoverable error.
34066       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
34067 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
34068       has_space=`$ECHO "$complete" | $GREP " "`
34069       if test "x$has_space" != x; then
34070         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34071 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34072       fi
34073       as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
34074     fi
34075   fi
34076 
34077   # Now new_path has a complete unix path to the binary
34078   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34079     # Keep paths in /bin as-is, but remove trailing .exe if any
34080     new_path="${new_path/%.exe/}"
34081     # Do not save /bin paths to all_fixpath_prefixes!
34082   else
34083     # Not in mixed or Windows style, start by that.
34084     new_path=`cmd //c echo $new_path`
34085 
34086   input_path="$new_path"
34087   # Check if we need to convert this using DOS-style short mode. If the path
34088   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34089   # take no chances and rewrite it.
34090   # Note: m4 eats our [], so we need to use [ and ] instead.
34091   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34092   if test "x$has_forbidden_chars" != x; then
34093     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34094     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34095   fi
34096 
34097     # Output is in $new_path
34098 
34099   windows_path="$new_path"
34100   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34101     unix_path=`$CYGPATH -u "$windows_path"`
34102     new_path="$unix_path"
34103   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34104     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34105     new_path="$unix_path"
34106   fi
34107 
34108     # remove trailing .exe if any
34109     new_path="${new_path/%.exe/}"
34110 
34111     # Save the first 10 bytes of this path to the storage, so fixpath can work.
34112     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34113   fi
34114 
34115   else
34116     # We're on a unix platform. Hooray! :)
34117     # First separate the path from the arguments. This will split at the first
34118     # space.
34119     complete="$LIPO"
34120     path="${complete%% *}"
34121     tmp="$complete EOL"
34122     arguments="${tmp#* }"
34123 
34124     # Cannot rely on the command "which" here since it doesn't always work.
34125     is_absolute_path=`$ECHO "$path" | $GREP ^/`
34126     if test -z "$is_absolute_path"; then
34127       # Path to executable is not absolute. Find it.
34128       IFS_save="$IFS"
34129       IFS=:
34130       for p in $PATH; do
34131         if test -f "$p/$path" && test -x "$p/$path"; then
34132           new_path="$p/$path"
34133           break
34134         fi
34135       done
34136       IFS="$IFS_save"
34137     else
34138       # This is an absolute path, we can use it without further modifications.
34139       new_path="$path"
34140     fi
34141 
34142     if test "x$new_path" = x; then
34143       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5
34144 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;}
34145       has_space=`$ECHO "$complete" | $GREP " "`
34146       if test "x$has_space" != x; then
34147         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
34148 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
34149       fi
34150       as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5
34151     fi
34152   fi
34153 
34154   # Now join together the path and the arguments once again
34155   if test "x$arguments" != xEOL; then
34156     new_complete="$new_path ${arguments% *}"
34157   else
34158     new_complete="$new_path"
34159   fi
34160 
34161   if test "x$complete" != "x$new_complete"; then
34162     LIPO="$new_complete"
34163     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LIPO to \"$new_complete\"" >&5
34164 $as_echo "$as_me: Rewriting LIPO to \"$new_complete\"" >&6;}
34165   fi
34166 
34167   else
34168     OBJC=
34169   fi
34170 
34171   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
34172     # Extract the first word of "mt", so it can be a program name with args.
34173 set dummy mt; ac_word=$2
34174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34175 $as_echo_n "checking for $ac_word... " >&6; }
34176 if ${ac_cv_prog_MT+:} false; then :
34177   $as_echo_n "(cached) " >&6
34178 else
34179   if test -n "$MT"; then
34180   ac_cv_prog_MT="$MT" # Let the user override the test.
34181 else
34182   ac_prog_rejected=no
34183 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34184 for as_dir in $PATH
34185 do
34186   IFS=$as_save_IFS
34187   test -z "$as_dir" && as_dir=.
34188     for ac_exec_ext in '' $ac_executable_extensions; do
34189   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34190     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/mt"; then
34191        ac_prog_rejected=yes
34192        continue
34193      fi
34194     ac_cv_prog_MT="mt"
34195     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34196     break 2
34197   fi
34198 done
34199   done
34200 IFS=$as_save_IFS
34201 
34202 if test $ac_prog_rejected = yes; then
34203   # We found a bogon in the path, so make sure we never use it.
34204   set dummy $ac_cv_prog_MT
34205   shift
34206   if test $# != 0; then
34207     # We chose a different compiler from the bogus one.
34208     # However, it has the same basename, so the bogon will be chosen
34209     # first if we set MT to just the basename; use the full file name.
34210     shift
34211     ac_cv_prog_MT="$as_dir/$ac_word${1+' '}$@"
34212   fi
34213 fi
34214 fi
34215 fi
34216 MT=$ac_cv_prog_MT
34217 if test -n "$MT"; then
34218   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5
34219 $as_echo "$MT" >&6; }
34220 else
34221   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34222 $as_echo "no" >&6; }
34223 fi
34224 
34225 
34226 
34227   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34228 
34229   # First separate the path from the arguments. This will split at the first
34230   # space.
34231   complete="$MT"
34232   path="${complete%% *}"
34233   tmp="$complete EOL"
34234   arguments="${tmp#* }"
34235 
34236   # Input might be given as Windows format, start by converting to
34237   # unix format.
34238   new_path=`$CYGPATH -u "$path"`
34239 
34240   # Now try to locate executable using which
34241   new_path=`$WHICH "$new_path" 2> /dev/null`
34242   # bat and cmd files are not always considered executable in cygwin causing which
34243   # to not find them
34244   if test "x$new_path" = x \
34245       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34246       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34247     new_path=`$CYGPATH -u "$path"`
34248   fi
34249   if test "x$new_path" = x; then
34250     # Oops. Which didn't find the executable.
34251     # The splitting of arguments from the executable at a space might have been incorrect,
34252     # since paths with space are more likely in Windows. Give it another try with the whole
34253     # argument.
34254     path="$complete"
34255     arguments="EOL"
34256     new_path=`$CYGPATH -u "$path"`
34257     new_path=`$WHICH "$new_path" 2> /dev/null`
34258     # bat and cmd files are not always considered executable in cygwin causing which
34259     # to not find them
34260     if test "x$new_path" = x \
34261         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34262         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34263       new_path=`$CYGPATH -u "$path"`
34264     fi
34265     if test "x$new_path" = x; then
34266       # It's still not found. Now this is an unrecoverable error.
34267       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
34268 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
34269       has_space=`$ECHO "$complete" | $GREP " "`
34270       if test "x$has_space" != x; then
34271         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34272 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34273       fi
34274       as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
34275     fi
34276   fi
34277 
34278   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34279   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34280   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34281   # "foo.exe" is OK but "foo" is an error.
34282   #
34283   # This test is therefore slightly more accurate than "test -f" to check for file presence.
34284   # It is also a way to make sure we got the proper file name for the real test later on.
34285   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34286   if test "x$test_shortpath" = x; then
34287     # Short path failed, file does not exist as specified.
34288     # Try adding .exe or .cmd
34289     if test -f "${new_path}.exe"; then
34290       input_to_shortpath="${new_path}.exe"
34291     elif test -f "${new_path}.cmd"; then
34292       input_to_shortpath="${new_path}.cmd"
34293     else
34294       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$new_path\", is invalid." >&5
34295 $as_echo "$as_me: The path of MT, which resolves as \"$new_path\", is invalid." >&6;}
34296       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34297 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34298       as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
34299     fi
34300   else
34301     input_to_shortpath="$new_path"
34302   fi
34303 
34304   # Call helper function which possibly converts this using DOS-style short mode.
34305   # If so, the updated path is stored in $new_path.
34306   new_path="$input_to_shortpath"
34307 
34308   input_path="$input_to_shortpath"
34309   # Check if we need to convert this using DOS-style short mode. If the path
34310   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34311   # take no chances and rewrite it.
34312   # Note: m4 eats our [], so we need to use [ and ] instead.
34313   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34314   if test "x$has_forbidden_chars" != x; then
34315     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34316     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34317     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34318     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34319       # Going to short mode and back again did indeed matter. Since short mode is
34320       # case insensitive, let's make it lowercase to improve readability.
34321       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34322       # Now convert it back to Unix-stile (cygpath)
34323       input_path=`$CYGPATH -u "$shortmode_path"`
34324       new_path="$input_path"
34325     fi
34326   fi
34327 
34328   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34329   if test "x$test_cygdrive_prefix" = x; then
34330     # As a simple fix, exclude /usr/bin since it's not a real path.
34331     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34332       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34333       # a path prefixed by /cygdrive for fixpath to work.
34334       new_path="$CYGWIN_ROOT_PATH$input_path"
34335     fi
34336   fi
34337 
34338   # remove trailing .exe if any
34339   new_path="${new_path/%.exe/}"
34340 
34341   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34342 
34343   # First separate the path from the arguments. This will split at the first
34344   # space.
34345   complete="$MT"
34346   path="${complete%% *}"
34347   tmp="$complete EOL"
34348   arguments="${tmp#* }"
34349 
34350   # Input might be given as Windows format, start by converting to
34351   # unix format.
34352   new_path="$path"
34353 
34354   windows_path="$new_path"
34355   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34356     unix_path=`$CYGPATH -u "$windows_path"`
34357     new_path="$unix_path"
34358   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34359     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34360     new_path="$unix_path"
34361   fi
34362 
34363 
34364   # Now try to locate executable using which
34365   new_path=`$WHICH "$new_path" 2> /dev/null`
34366 
34367   if test "x$new_path" = x; then
34368     # Oops. Which didn't find the executable.
34369     # The splitting of arguments from the executable at a space might have been incorrect,
34370     # since paths with space are more likely in Windows. Give it another try with the whole
34371     # argument.
34372     path="$complete"
34373     arguments="EOL"
34374     new_path="$path"
34375 
34376   windows_path="$new_path"
34377   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34378     unix_path=`$CYGPATH -u "$windows_path"`
34379     new_path="$unix_path"
34380   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34381     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34382     new_path="$unix_path"
34383   fi
34384 
34385 
34386     new_path=`$WHICH "$new_path" 2> /dev/null`
34387     # bat and cmd files are not always considered executable in MSYS causing which
34388     # to not find them
34389     if test "x$new_path" = x \
34390         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34391         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34392       new_path="$path"
34393 
34394   windows_path="$new_path"
34395   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34396     unix_path=`$CYGPATH -u "$windows_path"`
34397     new_path="$unix_path"
34398   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34399     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34400     new_path="$unix_path"
34401   fi
34402 
34403     fi
34404 
34405     if test "x$new_path" = x; then
34406       # It's still not found. Now this is an unrecoverable error.
34407       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
34408 $as_echo "$as_me: The path of MT, 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}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34412 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34413       fi
34414       as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
34415     fi
34416   fi
34417 
34418   # Now new_path has a complete unix path to the binary
34419   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34420     # Keep paths in /bin as-is, but remove trailing .exe if any
34421     new_path="${new_path/%.exe/}"
34422     # Do not save /bin paths to all_fixpath_prefixes!
34423   else
34424     # Not in mixed or Windows style, start by that.
34425     new_path=`cmd //c echo $new_path`
34426 
34427   input_path="$new_path"
34428   # Check if we need to convert this using DOS-style short mode. If the path
34429   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34430   # take no chances and rewrite it.
34431   # Note: m4 eats our [], so we need to use [ and ] instead.
34432   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34433   if test "x$has_forbidden_chars" != x; then
34434     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34435     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34436   fi
34437 
34438     # Output is in $new_path
34439 
34440   windows_path="$new_path"
34441   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34442     unix_path=`$CYGPATH -u "$windows_path"`
34443     new_path="$unix_path"
34444   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34445     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34446     new_path="$unix_path"
34447   fi
34448 
34449     # remove trailing .exe if any
34450     new_path="${new_path/%.exe/}"
34451 
34452     # Save the first 10 bytes of this path to the storage, so fixpath can work.
34453     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34454   fi
34455 
34456   else
34457     # We're on a unix platform. Hooray! :)
34458     # First separate the path from the arguments. This will split at the first
34459     # space.
34460     complete="$MT"
34461     path="${complete%% *}"
34462     tmp="$complete EOL"
34463     arguments="${tmp#* }"
34464 
34465     # Cannot rely on the command "which" here since it doesn't always work.
34466     is_absolute_path=`$ECHO "$path" | $GREP ^/`
34467     if test -z "$is_absolute_path"; then
34468       # Path to executable is not absolute. Find it.
34469       IFS_save="$IFS"
34470       IFS=:
34471       for p in $PATH; do
34472         if test -f "$p/$path" && test -x "$p/$path"; then
34473           new_path="$p/$path"
34474           break
34475         fi
34476       done
34477       IFS="$IFS_save"
34478     else
34479       # This is an absolute path, we can use it without further modifications.
34480       new_path="$path"
34481     fi
34482 
34483     if test "x$new_path" = x; then
34484       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5
34485 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;}
34486       has_space=`$ECHO "$complete" | $GREP " "`
34487       if test "x$has_space" != x; then
34488         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
34489 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
34490       fi
34491       as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5
34492     fi
34493   fi
34494 
34495   # Now join together the path and the arguments once again
34496   if test "x$arguments" != xEOL; then
34497     new_complete="$new_path ${arguments% *}"
34498   else
34499     new_complete="$new_path"
34500   fi
34501 
34502   if test "x$complete" != "x$new_complete"; then
34503     MT="$new_complete"
34504     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MT to \"$new_complete\"" >&5
34505 $as_echo "$as_me: Rewriting MT to \"$new_complete\"" >&6;}
34506   fi
34507 
34508     # Setup the resource compiler (RC)
34509     # Extract the first word of "rc", so it can be a program name with args.
34510 set dummy rc; ac_word=$2
34511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34512 $as_echo_n "checking for $ac_word... " >&6; }
34513 if ${ac_cv_prog_RC+:} false; then :
34514   $as_echo_n "(cached) " >&6
34515 else
34516   if test -n "$RC"; then
34517   ac_cv_prog_RC="$RC" # Let the user override the test.
34518 else
34519   ac_prog_rejected=no
34520 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34521 for as_dir in $PATH
34522 do
34523   IFS=$as_save_IFS
34524   test -z "$as_dir" && as_dir=.
34525     for ac_exec_ext in '' $ac_executable_extensions; do
34526   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34527     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/rc"; then
34528        ac_prog_rejected=yes
34529        continue
34530      fi
34531     ac_cv_prog_RC="rc"
34532     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34533     break 2
34534   fi
34535 done
34536   done
34537 IFS=$as_save_IFS
34538 
34539 if test $ac_prog_rejected = yes; then
34540   # We found a bogon in the path, so make sure we never use it.
34541   set dummy $ac_cv_prog_RC
34542   shift
34543   if test $# != 0; then
34544     # We chose a different compiler from the bogus one.
34545     # However, it has the same basename, so the bogon will be chosen
34546     # first if we set RC to just the basename; use the full file name.
34547     shift
34548     ac_cv_prog_RC="$as_dir/$ac_word${1+' '}$@"
34549   fi
34550 fi
34551 fi
34552 fi
34553 RC=$ac_cv_prog_RC
34554 if test -n "$RC"; then
34555   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5
34556 $as_echo "$RC" >&6; }
34557 else
34558   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34559 $as_echo "no" >&6; }
34560 fi
34561 
34562 
34563 
34564   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34565 
34566   # First separate the path from the arguments. This will split at the first
34567   # space.
34568   complete="$RC"
34569   path="${complete%% *}"
34570   tmp="$complete EOL"
34571   arguments="${tmp#* }"
34572 
34573   # Input might be given as Windows format, start by converting to
34574   # unix format.
34575   new_path=`$CYGPATH -u "$path"`
34576 
34577   # Now try to locate executable using which
34578   new_path=`$WHICH "$new_path" 2> /dev/null`
34579   # bat and cmd files are not always considered executable in cygwin causing which
34580   # to not find them
34581   if test "x$new_path" = x \
34582       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34583       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34584     new_path=`$CYGPATH -u "$path"`
34585   fi
34586   if test "x$new_path" = x; then
34587     # Oops. Which didn't find the executable.
34588     # The splitting of arguments from the executable at a space might have been incorrect,
34589     # since paths with space are more likely in Windows. Give it another try with the whole
34590     # argument.
34591     path="$complete"
34592     arguments="EOL"
34593     new_path=`$CYGPATH -u "$path"`
34594     new_path=`$WHICH "$new_path" 2> /dev/null`
34595     # bat and cmd files are not always considered executable in cygwin causing which
34596     # to not find them
34597     if test "x$new_path" = x \
34598         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34599         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34600       new_path=`$CYGPATH -u "$path"`
34601     fi
34602     if test "x$new_path" = x; then
34603       # It's still not found. Now this is an unrecoverable error.
34604       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34605 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34606       has_space=`$ECHO "$complete" | $GREP " "`
34607       if test "x$has_space" != x; then
34608         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34609 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34610       fi
34611       as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34612     fi
34613   fi
34614 
34615   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34616   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34617   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34618   # "foo.exe" is OK but "foo" is an error.
34619   #
34620   # This test is therefore slightly more accurate than "test -f" to check for file presence.
34621   # It is also a way to make sure we got the proper file name for the real test later on.
34622   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34623   if test "x$test_shortpath" = x; then
34624     # Short path failed, file does not exist as specified.
34625     # Try adding .exe or .cmd
34626     if test -f "${new_path}.exe"; then
34627       input_to_shortpath="${new_path}.exe"
34628     elif test -f "${new_path}.cmd"; then
34629       input_to_shortpath="${new_path}.cmd"
34630     else
34631       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$new_path\", is invalid." >&5
34632 $as_echo "$as_me: The path of RC, which resolves as \"$new_path\", is invalid." >&6;}
34633       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34634 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34635       as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34636     fi
34637   else
34638     input_to_shortpath="$new_path"
34639   fi
34640 
34641   # Call helper function which possibly converts this using DOS-style short mode.
34642   # If so, the updated path is stored in $new_path.
34643   new_path="$input_to_shortpath"
34644 
34645   input_path="$input_to_shortpath"
34646   # Check if we need to convert this using DOS-style short mode. If the path
34647   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34648   # take no chances and rewrite it.
34649   # Note: m4 eats our [], so we need to use [ and ] instead.
34650   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34651   if test "x$has_forbidden_chars" != x; then
34652     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34653     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34654     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34655     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34656       # Going to short mode and back again did indeed matter. Since short mode is
34657       # case insensitive, let's make it lowercase to improve readability.
34658       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34659       # Now convert it back to Unix-stile (cygpath)
34660       input_path=`$CYGPATH -u "$shortmode_path"`
34661       new_path="$input_path"
34662     fi
34663   fi
34664 
34665   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34666   if test "x$test_cygdrive_prefix" = x; then
34667     # As a simple fix, exclude /usr/bin since it's not a real path.
34668     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34669       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34670       # a path prefixed by /cygdrive for fixpath to work.
34671       new_path="$CYGWIN_ROOT_PATH$input_path"
34672     fi
34673   fi
34674 
34675   # remove trailing .exe if any
34676   new_path="${new_path/%.exe/}"
34677 
34678   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34679 
34680   # First separate the path from the arguments. This will split at the first
34681   # space.
34682   complete="$RC"
34683   path="${complete%% *}"
34684   tmp="$complete EOL"
34685   arguments="${tmp#* }"
34686 
34687   # Input might be given as Windows format, start by converting to
34688   # unix format.
34689   new_path="$path"
34690 
34691   windows_path="$new_path"
34692   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34693     unix_path=`$CYGPATH -u "$windows_path"`
34694     new_path="$unix_path"
34695   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34696     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34697     new_path="$unix_path"
34698   fi
34699 
34700 
34701   # Now try to locate executable using which
34702   new_path=`$WHICH "$new_path" 2> /dev/null`
34703 
34704   if test "x$new_path" = x; then
34705     # Oops. Which didn't find the executable.
34706     # The splitting of arguments from the executable at a space might have been incorrect,
34707     # since paths with space are more likely in Windows. Give it another try with the whole
34708     # argument.
34709     path="$complete"
34710     arguments="EOL"
34711     new_path="$path"
34712 
34713   windows_path="$new_path"
34714   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34715     unix_path=`$CYGPATH -u "$windows_path"`
34716     new_path="$unix_path"
34717   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34718     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34719     new_path="$unix_path"
34720   fi
34721 
34722 
34723     new_path=`$WHICH "$new_path" 2> /dev/null`
34724     # bat and cmd files are not always considered executable in MSYS causing which
34725     # to not find them
34726     if test "x$new_path" = x \
34727         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34728         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34729       new_path="$path"
34730 
34731   windows_path="$new_path"
34732   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34733     unix_path=`$CYGPATH -u "$windows_path"`
34734     new_path="$unix_path"
34735   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34736     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34737     new_path="$unix_path"
34738   fi
34739 
34740     fi
34741 
34742     if test "x$new_path" = x; then
34743       # It's still not found. Now this is an unrecoverable error.
34744       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34745 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34746       has_space=`$ECHO "$complete" | $GREP " "`
34747       if test "x$has_space" != x; then
34748         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34749 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34750       fi
34751       as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34752     fi
34753   fi
34754 
34755   # Now new_path has a complete unix path to the binary
34756   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
34757     # Keep paths in /bin as-is, but remove trailing .exe if any
34758     new_path="${new_path/%.exe/}"
34759     # Do not save /bin paths to all_fixpath_prefixes!
34760   else
34761     # Not in mixed or Windows style, start by that.
34762     new_path=`cmd //c echo $new_path`
34763 
34764   input_path="$new_path"
34765   # Check if we need to convert this using DOS-style short mode. If the path
34766   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34767   # take no chances and rewrite it.
34768   # Note: m4 eats our [], so we need to use [ and ] instead.
34769   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
34770   if test "x$has_forbidden_chars" != x; then
34771     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34772     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34773   fi
34774 
34775     # Output is in $new_path
34776 
34777   windows_path="$new_path"
34778   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34779     unix_path=`$CYGPATH -u "$windows_path"`
34780     new_path="$unix_path"
34781   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34782     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
34783     new_path="$unix_path"
34784   fi
34785 
34786     # remove trailing .exe if any
34787     new_path="${new_path/%.exe/}"
34788 
34789     # Save the first 10 bytes of this path to the storage, so fixpath can work.
34790     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
34791   fi
34792 
34793   else
34794     # We're on a unix platform. Hooray! :)
34795     # First separate the path from the arguments. This will split at the first
34796     # space.
34797     complete="$RC"
34798     path="${complete%% *}"
34799     tmp="$complete EOL"
34800     arguments="${tmp#* }"
34801 
34802     # Cannot rely on the command "which" here since it doesn't always work.
34803     is_absolute_path=`$ECHO "$path" | $GREP ^/`
34804     if test -z "$is_absolute_path"; then
34805       # Path to executable is not absolute. Find it.
34806       IFS_save="$IFS"
34807       IFS=:
34808       for p in $PATH; do
34809         if test -f "$p/$path" && test -x "$p/$path"; then
34810           new_path="$p/$path"
34811           break
34812         fi
34813       done
34814       IFS="$IFS_save"
34815     else
34816       # This is an absolute path, we can use it without further modifications.
34817       new_path="$path"
34818     fi
34819 
34820     if test "x$new_path" = x; then
34821       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5
34822 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;}
34823       has_space=`$ECHO "$complete" | $GREP " "`
34824       if test "x$has_space" != x; then
34825         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
34826 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
34827       fi
34828       as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5
34829     fi
34830   fi
34831 
34832   # Now join together the path and the arguments once again
34833   if test "x$arguments" != xEOL; then
34834     new_complete="$new_path ${arguments% *}"
34835   else
34836     new_complete="$new_path"
34837   fi
34838 
34839   if test "x$complete" != "x$new_complete"; then
34840     RC="$new_complete"
34841     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting RC to \"$new_complete\"" >&5
34842 $as_echo "$as_me: Rewriting RC to \"$new_complete\"" >&6;}
34843   fi
34844 
34845     # Extract the first word of "dumpbin", so it can be a program name with args.
34846 set dummy dumpbin; ac_word=$2
34847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
34848 $as_echo_n "checking for $ac_word... " >&6; }
34849 if ${ac_cv_prog_DUMPBIN+:} false; then :
34850   $as_echo_n "(cached) " >&6
34851 else
34852   if test -n "$DUMPBIN"; then
34853   ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
34854 else
34855 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34856 for as_dir in $PATH
34857 do
34858   IFS=$as_save_IFS
34859   test -z "$as_dir" && as_dir=.
34860     for ac_exec_ext in '' $ac_executable_extensions; do
34861   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
34862     ac_cv_prog_DUMPBIN="dumpbin"
34863     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
34864     break 2
34865   fi
34866 done
34867   done
34868 IFS=$as_save_IFS
34869 
34870 fi
34871 fi
34872 DUMPBIN=$ac_cv_prog_DUMPBIN
34873 if test -n "$DUMPBIN"; then
34874   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
34875 $as_echo "$DUMPBIN" >&6; }
34876 else
34877   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34878 $as_echo "no" >&6; }
34879 fi
34880 
34881 
34882 
34883   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
34884 
34885   # First separate the path from the arguments. This will split at the first
34886   # space.
34887   complete="$DUMPBIN"
34888   path="${complete%% *}"
34889   tmp="$complete EOL"
34890   arguments="${tmp#* }"
34891 
34892   # Input might be given as Windows format, start by converting to
34893   # unix format.
34894   new_path=`$CYGPATH -u "$path"`
34895 
34896   # Now try to locate executable using which
34897   new_path=`$WHICH "$new_path" 2> /dev/null`
34898   # bat and cmd files are not always considered executable in cygwin causing which
34899   # to not find them
34900   if test "x$new_path" = x \
34901       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34902       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34903     new_path=`$CYGPATH -u "$path"`
34904   fi
34905   if test "x$new_path" = x; then
34906     # Oops. Which didn't find the executable.
34907     # The splitting of arguments from the executable at a space might have been incorrect,
34908     # since paths with space are more likely in Windows. Give it another try with the whole
34909     # argument.
34910     path="$complete"
34911     arguments="EOL"
34912     new_path=`$CYGPATH -u "$path"`
34913     new_path=`$WHICH "$new_path" 2> /dev/null`
34914     # bat and cmd files are not always considered executable in cygwin causing which
34915     # to not find them
34916     if test "x$new_path" = x \
34917         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
34918         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
34919       new_path=`$CYGPATH -u "$path"`
34920     fi
34921     if test "x$new_path" = x; then
34922       # It's still not found. Now this is an unrecoverable error.
34923       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
34924 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
34925       has_space=`$ECHO "$complete" | $GREP " "`
34926       if test "x$has_space" != x; then
34927         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
34928 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
34929       fi
34930       as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34931     fi
34932   fi
34933 
34934   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
34935   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
34936   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
34937   # "foo.exe" is OK but "foo" is an error.
34938   #
34939   # This test is therefore slightly more accurate than "test -f" to check for file presence.
34940   # It is also a way to make sure we got the proper file name for the real test later on.
34941   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
34942   if test "x$test_shortpath" = x; then
34943     # Short path failed, file does not exist as specified.
34944     # Try adding .exe or .cmd
34945     if test -f "${new_path}.exe"; then
34946       input_to_shortpath="${new_path}.exe"
34947     elif test -f "${new_path}.cmd"; then
34948       input_to_shortpath="${new_path}.cmd"
34949     else
34950       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&5
34951 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&6;}
34952       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
34953 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
34954       as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
34955     fi
34956   else
34957     input_to_shortpath="$new_path"
34958   fi
34959 
34960   # Call helper function which possibly converts this using DOS-style short mode.
34961   # If so, the updated path is stored in $new_path.
34962   new_path="$input_to_shortpath"
34963 
34964   input_path="$input_to_shortpath"
34965   # Check if we need to convert this using DOS-style short mode. If the path
34966   # contains just simple characters, use it. Otherwise (spaces, weird characters),
34967   # take no chances and rewrite it.
34968   # Note: m4 eats our [], so we need to use [ and ] instead.
34969   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
34970   if test "x$has_forbidden_chars" != x; then
34971     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
34972     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
34973     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
34974     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
34975       # Going to short mode and back again did indeed matter. Since short mode is
34976       # case insensitive, let's make it lowercase to improve readability.
34977       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
34978       # Now convert it back to Unix-stile (cygpath)
34979       input_path=`$CYGPATH -u "$shortmode_path"`
34980       new_path="$input_path"
34981     fi
34982   fi
34983 
34984   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
34985   if test "x$test_cygdrive_prefix" = x; then
34986     # As a simple fix, exclude /usr/bin since it's not a real path.
34987     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
34988       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
34989       # a path prefixed by /cygdrive for fixpath to work.
34990       new_path="$CYGWIN_ROOT_PATH$input_path"
34991     fi
34992   fi
34993 
34994   # remove trailing .exe if any
34995   new_path="${new_path/%.exe/}"
34996 
34997   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
34998 
34999   # First separate the path from the arguments. This will split at the first
35000   # space.
35001   complete="$DUMPBIN"
35002   path="${complete%% *}"
35003   tmp="$complete EOL"
35004   arguments="${tmp#* }"
35005 
35006   # Input might be given as Windows format, start by converting to
35007   # unix format.
35008   new_path="$path"
35009 
35010   windows_path="$new_path"
35011   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35012     unix_path=`$CYGPATH -u "$windows_path"`
35013     new_path="$unix_path"
35014   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35015     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35016     new_path="$unix_path"
35017   fi
35018 
35019 
35020   # Now try to locate executable using which
35021   new_path=`$WHICH "$new_path" 2> /dev/null`
35022 
35023   if test "x$new_path" = x; then
35024     # Oops. Which didn't find the executable.
35025     # The splitting of arguments from the executable at a space might have been incorrect,
35026     # since paths with space are more likely in Windows. Give it another try with the whole
35027     # argument.
35028     path="$complete"
35029     arguments="EOL"
35030     new_path="$path"
35031 
35032   windows_path="$new_path"
35033   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35034     unix_path=`$CYGPATH -u "$windows_path"`
35035     new_path="$unix_path"
35036   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35037     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35038     new_path="$unix_path"
35039   fi
35040 
35041 
35042     new_path=`$WHICH "$new_path" 2> /dev/null`
35043     # bat and cmd files are not always considered executable in MSYS causing which
35044     # to not find them
35045     if test "x$new_path" = x \
35046         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35047         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35048       new_path="$path"
35049 
35050   windows_path="$new_path"
35051   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35052     unix_path=`$CYGPATH -u "$windows_path"`
35053     new_path="$unix_path"
35054   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35055     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35056     new_path="$unix_path"
35057   fi
35058 
35059     fi
35060 
35061     if test "x$new_path" = x; then
35062       # It's still not found. Now this is an unrecoverable error.
35063       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
35064 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
35065       has_space=`$ECHO "$complete" | $GREP " "`
35066       if test "x$has_space" != x; then
35067         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35068 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35069       fi
35070       as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
35071     fi
35072   fi
35073 
35074   # Now new_path has a complete unix path to the binary
35075   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
35076     # Keep paths in /bin as-is, but remove trailing .exe if any
35077     new_path="${new_path/%.exe/}"
35078     # Do not save /bin paths to all_fixpath_prefixes!
35079   else
35080     # Not in mixed or Windows style, start by that.
35081     new_path=`cmd //c echo $new_path`
35082 
35083   input_path="$new_path"
35084   # Check if we need to convert this using DOS-style short mode. If the path
35085   # contains just simple characters, use it. Otherwise (spaces, weird characters),
35086   # take no chances and rewrite it.
35087   # Note: m4 eats our [], so we need to use [ and ] instead.
35088   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
35089   if test "x$has_forbidden_chars" != x; then
35090     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35091     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35092   fi
35093 
35094     # Output is in $new_path
35095 
35096   windows_path="$new_path"
35097   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35098     unix_path=`$CYGPATH -u "$windows_path"`
35099     new_path="$unix_path"
35100   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35101     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35102     new_path="$unix_path"
35103   fi
35104 
35105     # remove trailing .exe if any
35106     new_path="${new_path/%.exe/}"
35107 
35108     # Save the first 10 bytes of this path to the storage, so fixpath can work.
35109     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
35110   fi
35111 
35112   else
35113     # We're on a unix platform. Hooray! :)
35114     # First separate the path from the arguments. This will split at the first
35115     # space.
35116     complete="$DUMPBIN"
35117     path="${complete%% *}"
35118     tmp="$complete EOL"
35119     arguments="${tmp#* }"
35120 
35121     # Cannot rely on the command "which" here since it doesn't always work.
35122     is_absolute_path=`$ECHO "$path" | $GREP ^/`
35123     if test -z "$is_absolute_path"; then
35124       # Path to executable is not absolute. Find it.
35125       IFS_save="$IFS"
35126       IFS=:
35127       for p in $PATH; do
35128         if test -f "$p/$path" && test -x "$p/$path"; then
35129           new_path="$p/$path"
35130           break
35131         fi
35132       done
35133       IFS="$IFS_save"
35134     else
35135       # This is an absolute path, we can use it without further modifications.
35136       new_path="$path"
35137     fi
35138 
35139     if test "x$new_path" = x; then
35140       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5
35141 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;}
35142       has_space=`$ECHO "$complete" | $GREP " "`
35143       if test "x$has_space" != x; then
35144         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
35145 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
35146       fi
35147       as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5
35148     fi
35149   fi
35150 
35151   # Now join together the path and the arguments once again
35152   if test "x$arguments" != xEOL; then
35153     new_complete="$new_path ${arguments% *}"
35154   else
35155     new_complete="$new_path"
35156   fi
35157 
35158   if test "x$complete" != "x$new_complete"; then
35159     DUMPBIN="$new_complete"
35160     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DUMPBIN to \"$new_complete\"" >&5
35161 $as_echo "$as_me: Rewriting DUMPBIN to \"$new_complete\"" >&6;}
35162   fi
35163 
35164     # We need to check for 'msbuild.exe' because at the place where we expect to
35165     # find 'msbuild.exe' there's also a directory called 'msbuild' and configure
35166     # won't find the 'msbuild.exe' executable in that case (and the
35167     # 'ac_executable_extensions' is unusable due to performance reasons).
35168     # Notice that we intentionally don't fix up the path to MSBUILD because we
35169     # will call it in a DOS shell during freetype detection on Windows (see
35170     # 'LIB_SETUP_FREETYPE' in "libraries.m4"
35171     # Extract the first word of "msbuild.exe", so it can be a program name with args.
35172 set dummy msbuild.exe; ac_word=$2
35173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35174 $as_echo_n "checking for $ac_word... " >&6; }
35175 if ${ac_cv_prog_MSBUILD+:} false; then :
35176   $as_echo_n "(cached) " >&6
35177 else
35178   if test -n "$MSBUILD"; then
35179   ac_cv_prog_MSBUILD="$MSBUILD" # Let the user override the test.
35180 else
35181 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35182 for as_dir in $PATH
35183 do
35184   IFS=$as_save_IFS
35185   test -z "$as_dir" && as_dir=.
35186     for ac_exec_ext in '' $ac_executable_extensions; do
35187   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35188     ac_cv_prog_MSBUILD="msbuild.exe"
35189     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35190     break 2
35191   fi
35192 done
35193   done
35194 IFS=$as_save_IFS
35195 
35196 fi
35197 fi
35198 MSBUILD=$ac_cv_prog_MSBUILD
35199 if test -n "$MSBUILD"; then
35200   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSBUILD" >&5
35201 $as_echo "$MSBUILD" >&6; }
35202 else
35203   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35204 $as_echo "no" >&6; }
35205 fi
35206 
35207 
35208   fi
35209 
35210   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
35211 
35212 
35213   # Publish this variable in the help.
35214 
35215 
35216   if test "x$STRIP" = x; then
35217     # The variable is not set by user, try to locate tool using the code snippet
35218     for ac_prog in strip
35219 do
35220   # Extract the first word of "$ac_prog", so it can be a program name with args.
35221 set dummy $ac_prog; ac_word=$2
35222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35223 $as_echo_n "checking for $ac_word... " >&6; }
35224 if ${ac_cv_path_STRIP+:} false; then :
35225   $as_echo_n "(cached) " >&6
35226 else
35227   case $STRIP in
35228   [\\/]* | ?:[\\/]*)
35229   ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
35230   ;;
35231   *)
35232   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35233 for as_dir in $PATH
35234 do
35235   IFS=$as_save_IFS
35236   test -z "$as_dir" && as_dir=.
35237     for ac_exec_ext in '' $ac_executable_extensions; do
35238   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35239     ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
35240     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35241     break 2
35242   fi
35243 done
35244   done
35245 IFS=$as_save_IFS
35246 
35247   ;;
35248 esac
35249 fi
35250 STRIP=$ac_cv_path_STRIP
35251 if test -n "$STRIP"; then
35252   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
35253 $as_echo "$STRIP" >&6; }
35254 else
35255   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35256 $as_echo "no" >&6; }
35257 fi
35258 
35259 
35260   test -n "$STRIP" && break
35261 done
35262 
35263   else
35264     # The variable is set, but is it from the command line or the environment?
35265 
35266     # Try to remove the string !STRIP! from our list.
35267     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/}
35268     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
35269       # If it failed, the variable was not from the command line. Ignore it,
35270       # but warn the user (except for BASH, which is always set by the calling BASH).
35271       if test "xSTRIP" != xBASH; then
35272         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5
35273 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;}
35274       fi
35275       # Try to locate tool using the code snippet
35276       for ac_prog in strip
35277 do
35278   # Extract the first word of "$ac_prog", so it can be a program name with args.
35279 set dummy $ac_prog; ac_word=$2
35280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35281 $as_echo_n "checking for $ac_word... " >&6; }
35282 if ${ac_cv_path_STRIP+:} false; then :
35283   $as_echo_n "(cached) " >&6
35284 else
35285   case $STRIP in
35286   [\\/]* | ?:[\\/]*)
35287   ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
35288   ;;
35289   *)
35290   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35291 for as_dir in $PATH
35292 do
35293   IFS=$as_save_IFS
35294   test -z "$as_dir" && as_dir=.
35295     for ac_exec_ext in '' $ac_executable_extensions; do
35296   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35297     ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
35298     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35299     break 2
35300   fi
35301 done
35302   done
35303 IFS=$as_save_IFS
35304 
35305   ;;
35306 esac
35307 fi
35308 STRIP=$ac_cv_path_STRIP
35309 if test -n "$STRIP"; then
35310   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
35311 $as_echo "$STRIP" >&6; }
35312 else
35313   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35314 $as_echo "no" >&6; }
35315 fi
35316 
35317 
35318   test -n "$STRIP" && break
35319 done
35320 
35321     else
35322       # If it succeeded, then it was overridden by the user. We will use it
35323       # for the tool.
35324 
35325       # First remove it from the list of overridden variables, so we can test
35326       # for unknown variables in the end.
35327       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
35328 
35329       # Check if the provided tool contains a complete path.
35330       tool_specified="$STRIP"
35331       tool_basename="${tool_specified##*/}"
35332       if test "x$tool_basename" = "x$tool_specified"; then
35333         # A command without a complete path is provided, search $PATH.
35334         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5
35335 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;}
35336         # Extract the first word of "$tool_basename", so it can be a program name with args.
35337 set dummy $tool_basename; ac_word=$2
35338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35339 $as_echo_n "checking for $ac_word... " >&6; }
35340 if ${ac_cv_path_STRIP+:} false; then :
35341   $as_echo_n "(cached) " >&6
35342 else
35343   case $STRIP in
35344   [\\/]* | ?:[\\/]*)
35345   ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
35346   ;;
35347   *)
35348   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35349 for as_dir in $PATH
35350 do
35351   IFS=$as_save_IFS
35352   test -z "$as_dir" && as_dir=.
35353     for ac_exec_ext in '' $ac_executable_extensions; do
35354   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35355     ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
35356     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35357     break 2
35358   fi
35359 done
35360   done
35361 IFS=$as_save_IFS
35362 
35363   ;;
35364 esac
35365 fi
35366 STRIP=$ac_cv_path_STRIP
35367 if test -n "$STRIP"; then
35368   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
35369 $as_echo "$STRIP" >&6; }
35370 else
35371   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35372 $as_echo "no" >&6; }
35373 fi
35374 
35375 
35376         if test "x$STRIP" = x; then
35377           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
35378         fi
35379       else
35380         # Otherwise we believe it is a complete path. Use it as it is.
35381         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5
35382 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;}
35383         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5
35384 $as_echo_n "checking for STRIP... " >&6; }
35385         if test ! -x "$tool_specified"; then
35386           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
35387 $as_echo "not found" >&6; }
35388           as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5
35389         fi
35390         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
35391 $as_echo "$tool_specified" >&6; }
35392       fi
35393     fi
35394   fi
35395 
35396 
35397 
35398   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35399 
35400   # First separate the path from the arguments. This will split at the first
35401   # space.
35402   complete="$STRIP"
35403   path="${complete%% *}"
35404   tmp="$complete EOL"
35405   arguments="${tmp#* }"
35406 
35407   # Input might be given as Windows format, start by converting to
35408   # unix format.
35409   new_path=`$CYGPATH -u "$path"`
35410 
35411   # Now try to locate executable using which
35412   new_path=`$WHICH "$new_path" 2> /dev/null`
35413   # bat and cmd files are not always considered executable in cygwin causing which
35414   # to not find them
35415   if test "x$new_path" = x \
35416       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35417       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35418     new_path=`$CYGPATH -u "$path"`
35419   fi
35420   if test "x$new_path" = x; then
35421     # Oops. Which didn't find the executable.
35422     # The splitting of arguments from the executable at a space might have been incorrect,
35423     # since paths with space are more likely in Windows. Give it another try with the whole
35424     # argument.
35425     path="$complete"
35426     arguments="EOL"
35427     new_path=`$CYGPATH -u "$path"`
35428     new_path=`$WHICH "$new_path" 2> /dev/null`
35429     # bat and cmd files are not always considered executable in cygwin causing which
35430     # to not find them
35431     if test "x$new_path" = x \
35432         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35433         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35434       new_path=`$CYGPATH -u "$path"`
35435     fi
35436     if test "x$new_path" = x; then
35437       # It's still not found. Now this is an unrecoverable error.
35438       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
35439 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
35440       has_space=`$ECHO "$complete" | $GREP " "`
35441       if test "x$has_space" != x; then
35442         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35443 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35444       fi
35445       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
35446     fi
35447   fi
35448 
35449   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
35450   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
35451   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
35452   # "foo.exe" is OK but "foo" is an error.
35453   #
35454   # This test is therefore slightly more accurate than "test -f" to check for file presence.
35455   # It is also a way to make sure we got the proper file name for the real test later on.
35456   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
35457   if test "x$test_shortpath" = x; then
35458     # Short path failed, file does not exist as specified.
35459     # Try adding .exe or .cmd
35460     if test -f "${new_path}.exe"; then
35461       input_to_shortpath="${new_path}.exe"
35462     elif test -f "${new_path}.cmd"; then
35463       input_to_shortpath="${new_path}.cmd"
35464     else
35465       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5
35466 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;}
35467       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
35468 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
35469       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
35470     fi
35471   else
35472     input_to_shortpath="$new_path"
35473   fi
35474 
35475   # Call helper function which possibly converts this using DOS-style short mode.
35476   # If so, the updated path is stored in $new_path.
35477   new_path="$input_to_shortpath"
35478 
35479   input_path="$input_to_shortpath"
35480   # Check if we need to convert this using DOS-style short mode. If the path
35481   # contains just simple characters, use it. Otherwise (spaces, weird characters),
35482   # take no chances and rewrite it.
35483   # Note: m4 eats our [], so we need to use [ and ] instead.
35484   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
35485   if test "x$has_forbidden_chars" != x; then
35486     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35487     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
35488     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
35489     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
35490       # Going to short mode and back again did indeed matter. Since short mode is
35491       # case insensitive, let's make it lowercase to improve readability.
35492       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35493       # Now convert it back to Unix-stile (cygpath)
35494       input_path=`$CYGPATH -u "$shortmode_path"`
35495       new_path="$input_path"
35496     fi
35497   fi
35498 
35499   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
35500   if test "x$test_cygdrive_prefix" = x; then
35501     # As a simple fix, exclude /usr/bin since it's not a real path.
35502     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
35503       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
35504       # a path prefixed by /cygdrive for fixpath to work.
35505       new_path="$CYGWIN_ROOT_PATH$input_path"
35506     fi
35507   fi
35508 
35509   # remove trailing .exe if any
35510   new_path="${new_path/%.exe/}"
35511 
35512   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35513 
35514   # First separate the path from the arguments. This will split at the first
35515   # space.
35516   complete="$STRIP"
35517   path="${complete%% *}"
35518   tmp="$complete EOL"
35519   arguments="${tmp#* }"
35520 
35521   # Input might be given as Windows format, start by converting to
35522   # unix format.
35523   new_path="$path"
35524 
35525   windows_path="$new_path"
35526   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35527     unix_path=`$CYGPATH -u "$windows_path"`
35528     new_path="$unix_path"
35529   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35530     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35531     new_path="$unix_path"
35532   fi
35533 
35534 
35535   # Now try to locate executable using which
35536   new_path=`$WHICH "$new_path" 2> /dev/null`
35537 
35538   if test "x$new_path" = x; then
35539     # Oops. Which didn't find the executable.
35540     # The splitting of arguments from the executable at a space might have been incorrect,
35541     # since paths with space are more likely in Windows. Give it another try with the whole
35542     # argument.
35543     path="$complete"
35544     arguments="EOL"
35545     new_path="$path"
35546 
35547   windows_path="$new_path"
35548   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35549     unix_path=`$CYGPATH -u "$windows_path"`
35550     new_path="$unix_path"
35551   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35552     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35553     new_path="$unix_path"
35554   fi
35555 
35556 
35557     new_path=`$WHICH "$new_path" 2> /dev/null`
35558     # bat and cmd files are not always considered executable in MSYS causing which
35559     # to not find them
35560     if test "x$new_path" = x \
35561         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35562         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35563       new_path="$path"
35564 
35565   windows_path="$new_path"
35566   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35567     unix_path=`$CYGPATH -u "$windows_path"`
35568     new_path="$unix_path"
35569   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35570     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35571     new_path="$unix_path"
35572   fi
35573 
35574     fi
35575 
35576     if test "x$new_path" = x; then
35577       # It's still not found. Now this is an unrecoverable error.
35578       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
35579 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
35580       has_space=`$ECHO "$complete" | $GREP " "`
35581       if test "x$has_space" != x; then
35582         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35583 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35584       fi
35585       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
35586     fi
35587   fi
35588 
35589   # Now new_path has a complete unix path to the binary
35590   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
35591     # Keep paths in /bin as-is, but remove trailing .exe if any
35592     new_path="${new_path/%.exe/}"
35593     # Do not save /bin paths to all_fixpath_prefixes!
35594   else
35595     # Not in mixed or Windows style, start by that.
35596     new_path=`cmd //c echo $new_path`
35597 
35598   input_path="$new_path"
35599   # Check if we need to convert this using DOS-style short mode. If the path
35600   # contains just simple characters, use it. Otherwise (spaces, weird characters),
35601   # take no chances and rewrite it.
35602   # Note: m4 eats our [], so we need to use [ and ] instead.
35603   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
35604   if test "x$has_forbidden_chars" != x; then
35605     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35606     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35607   fi
35608 
35609     # Output is in $new_path
35610 
35611   windows_path="$new_path"
35612   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35613     unix_path=`$CYGPATH -u "$windows_path"`
35614     new_path="$unix_path"
35615   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35616     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35617     new_path="$unix_path"
35618   fi
35619 
35620     # remove trailing .exe if any
35621     new_path="${new_path/%.exe/}"
35622 
35623     # Save the first 10 bytes of this path to the storage, so fixpath can work.
35624     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
35625   fi
35626 
35627   else
35628     # We're on a unix platform. Hooray! :)
35629     # First separate the path from the arguments. This will split at the first
35630     # space.
35631     complete="$STRIP"
35632     path="${complete%% *}"
35633     tmp="$complete EOL"
35634     arguments="${tmp#* }"
35635 
35636     # Cannot rely on the command "which" here since it doesn't always work.
35637     is_absolute_path=`$ECHO "$path" | $GREP ^/`
35638     if test -z "$is_absolute_path"; then
35639       # Path to executable is not absolute. Find it.
35640       IFS_save="$IFS"
35641       IFS=:
35642       for p in $PATH; do
35643         if test -f "$p/$path" && test -x "$p/$path"; then
35644           new_path="$p/$path"
35645           break
35646         fi
35647       done
35648       IFS="$IFS_save"
35649     else
35650       # This is an absolute path, we can use it without further modifications.
35651       new_path="$path"
35652     fi
35653 
35654     if test "x$new_path" = x; then
35655       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
35656 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
35657       has_space=`$ECHO "$complete" | $GREP " "`
35658       if test "x$has_space" != x; then
35659         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
35660 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
35661       fi
35662       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
35663     fi
35664   fi
35665 
35666   # Now join together the path and the arguments once again
35667   if test "x$arguments" != xEOL; then
35668     new_complete="$new_path ${arguments% *}"
35669   else
35670     new_complete="$new_path"
35671   fi
35672 
35673   if test "x$complete" != "x$new_complete"; then
35674     STRIP="$new_complete"
35675     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5
35676 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;}
35677   fi
35678 
35679 
35680 
35681   # Publish this variable in the help.
35682 
35683 
35684   if test "x$NM" = x; then
35685     # The variable is not set by user, try to locate tool using the code snippet
35686     for ac_prog in nm
35687 do
35688   # Extract the first word of "$ac_prog", so it can be a program name with args.
35689 set dummy $ac_prog; ac_word=$2
35690 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35691 $as_echo_n "checking for $ac_word... " >&6; }
35692 if ${ac_cv_path_NM+:} false; then :
35693   $as_echo_n "(cached) " >&6
35694 else
35695   case $NM in
35696   [\\/]* | ?:[\\/]*)
35697   ac_cv_path_NM="$NM" # Let the user override the test with a path.
35698   ;;
35699   *)
35700   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35701 for as_dir in $PATH
35702 do
35703   IFS=$as_save_IFS
35704   test -z "$as_dir" && as_dir=.
35705     for ac_exec_ext in '' $ac_executable_extensions; do
35706   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35707     ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
35708     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35709     break 2
35710   fi
35711 done
35712   done
35713 IFS=$as_save_IFS
35714 
35715   ;;
35716 esac
35717 fi
35718 NM=$ac_cv_path_NM
35719 if test -n "$NM"; then
35720   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
35721 $as_echo "$NM" >&6; }
35722 else
35723   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35724 $as_echo "no" >&6; }
35725 fi
35726 
35727 
35728   test -n "$NM" && break
35729 done
35730 
35731   else
35732     # The variable is set, but is it from the command line or the environment?
35733 
35734     # Try to remove the string !NM! from our list.
35735     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/}
35736     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
35737       # If it failed, the variable was not from the command line. Ignore it,
35738       # but warn the user (except for BASH, which is always set by the calling BASH).
35739       if test "xNM" != xBASH; then
35740         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5
35741 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;}
35742       fi
35743       # Try to locate tool using the code snippet
35744       for ac_prog in nm
35745 do
35746   # Extract the first word of "$ac_prog", so it can be a program name with args.
35747 set dummy $ac_prog; ac_word=$2
35748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35749 $as_echo_n "checking for $ac_word... " >&6; }
35750 if ${ac_cv_path_NM+:} false; then :
35751   $as_echo_n "(cached) " >&6
35752 else
35753   case $NM in
35754   [\\/]* | ?:[\\/]*)
35755   ac_cv_path_NM="$NM" # Let the user override the test with a path.
35756   ;;
35757   *)
35758   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35759 for as_dir in $PATH
35760 do
35761   IFS=$as_save_IFS
35762   test -z "$as_dir" && as_dir=.
35763     for ac_exec_ext in '' $ac_executable_extensions; do
35764   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35765     ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
35766     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35767     break 2
35768   fi
35769 done
35770   done
35771 IFS=$as_save_IFS
35772 
35773   ;;
35774 esac
35775 fi
35776 NM=$ac_cv_path_NM
35777 if test -n "$NM"; then
35778   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
35779 $as_echo "$NM" >&6; }
35780 else
35781   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35782 $as_echo "no" >&6; }
35783 fi
35784 
35785 
35786   test -n "$NM" && break
35787 done
35788 
35789     else
35790       # If it succeeded, then it was overridden by the user. We will use it
35791       # for the tool.
35792 
35793       # First remove it from the list of overridden variables, so we can test
35794       # for unknown variables in the end.
35795       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
35796 
35797       # Check if the provided tool contains a complete path.
35798       tool_specified="$NM"
35799       tool_basename="${tool_specified##*/}"
35800       if test "x$tool_basename" = "x$tool_specified"; then
35801         # A command without a complete path is provided, search $PATH.
35802         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5
35803 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;}
35804         # Extract the first word of "$tool_basename", so it can be a program name with args.
35805 set dummy $tool_basename; ac_word=$2
35806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
35807 $as_echo_n "checking for $ac_word... " >&6; }
35808 if ${ac_cv_path_NM+:} false; then :
35809   $as_echo_n "(cached) " >&6
35810 else
35811   case $NM in
35812   [\\/]* | ?:[\\/]*)
35813   ac_cv_path_NM="$NM" # Let the user override the test with a path.
35814   ;;
35815   *)
35816   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35817 for as_dir in $PATH
35818 do
35819   IFS=$as_save_IFS
35820   test -z "$as_dir" && as_dir=.
35821     for ac_exec_ext in '' $ac_executable_extensions; do
35822   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
35823     ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
35824     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
35825     break 2
35826   fi
35827 done
35828   done
35829 IFS=$as_save_IFS
35830 
35831   ;;
35832 esac
35833 fi
35834 NM=$ac_cv_path_NM
35835 if test -n "$NM"; then
35836   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
35837 $as_echo "$NM" >&6; }
35838 else
35839   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35840 $as_echo "no" >&6; }
35841 fi
35842 
35843 
35844         if test "x$NM" = x; then
35845           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
35846         fi
35847       else
35848         # Otherwise we believe it is a complete path. Use it as it is.
35849         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5
35850 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;}
35851         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5
35852 $as_echo_n "checking for NM... " >&6; }
35853         if test ! -x "$tool_specified"; then
35854           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
35855 $as_echo "not found" >&6; }
35856           as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5
35857         fi
35858         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
35859 $as_echo "$tool_specified" >&6; }
35860       fi
35861     fi
35862   fi
35863 
35864 
35865 
35866   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35867 
35868   # First separate the path from the arguments. This will split at the first
35869   # space.
35870   complete="$NM"
35871   path="${complete%% *}"
35872   tmp="$complete EOL"
35873   arguments="${tmp#* }"
35874 
35875   # Input might be given as Windows format, start by converting to
35876   # unix format.
35877   new_path=`$CYGPATH -u "$path"`
35878 
35879   # Now try to locate executable using which
35880   new_path=`$WHICH "$new_path" 2> /dev/null`
35881   # bat and cmd files are not always considered executable in cygwin causing which
35882   # to not find them
35883   if test "x$new_path" = x \
35884       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35885       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35886     new_path=`$CYGPATH -u "$path"`
35887   fi
35888   if test "x$new_path" = x; then
35889     # Oops. Which didn't find the executable.
35890     # The splitting of arguments from the executable at a space might have been incorrect,
35891     # since paths with space are more likely in Windows. Give it another try with the whole
35892     # argument.
35893     path="$complete"
35894     arguments="EOL"
35895     new_path=`$CYGPATH -u "$path"`
35896     new_path=`$WHICH "$new_path" 2> /dev/null`
35897     # bat and cmd files are not always considered executable in cygwin causing which
35898     # to not find them
35899     if test "x$new_path" = x \
35900         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
35901         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
35902       new_path=`$CYGPATH -u "$path"`
35903     fi
35904     if test "x$new_path" = x; then
35905       # It's still not found. Now this is an unrecoverable error.
35906       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
35907 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
35908       has_space=`$ECHO "$complete" | $GREP " "`
35909       if test "x$has_space" != x; then
35910         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
35911 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
35912       fi
35913       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35914     fi
35915   fi
35916 
35917   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
35918   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
35919   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
35920   # "foo.exe" is OK but "foo" is an error.
35921   #
35922   # This test is therefore slightly more accurate than "test -f" to check for file presence.
35923   # It is also a way to make sure we got the proper file name for the real test later on.
35924   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
35925   if test "x$test_shortpath" = x; then
35926     # Short path failed, file does not exist as specified.
35927     # Try adding .exe or .cmd
35928     if test -f "${new_path}.exe"; then
35929       input_to_shortpath="${new_path}.exe"
35930     elif test -f "${new_path}.cmd"; then
35931       input_to_shortpath="${new_path}.cmd"
35932     else
35933       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5
35934 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;}
35935       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
35936 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
35937       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
35938     fi
35939   else
35940     input_to_shortpath="$new_path"
35941   fi
35942 
35943   # Call helper function which possibly converts this using DOS-style short mode.
35944   # If so, the updated path is stored in $new_path.
35945   new_path="$input_to_shortpath"
35946 
35947   input_path="$input_to_shortpath"
35948   # Check if we need to convert this using DOS-style short mode. If the path
35949   # contains just simple characters, use it. Otherwise (spaces, weird characters),
35950   # take no chances and rewrite it.
35951   # Note: m4 eats our [], so we need to use [ and ] instead.
35952   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
35953   if test "x$has_forbidden_chars" != x; then
35954     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
35955     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
35956     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
35957     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
35958       # Going to short mode and back again did indeed matter. Since short mode is
35959       # case insensitive, let's make it lowercase to improve readability.
35960       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
35961       # Now convert it back to Unix-stile (cygpath)
35962       input_path=`$CYGPATH -u "$shortmode_path"`
35963       new_path="$input_path"
35964     fi
35965   fi
35966 
35967   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
35968   if test "x$test_cygdrive_prefix" = x; then
35969     # As a simple fix, exclude /usr/bin since it's not a real path.
35970     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
35971       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
35972       # a path prefixed by /cygdrive for fixpath to work.
35973       new_path="$CYGWIN_ROOT_PATH$input_path"
35974     fi
35975   fi
35976 
35977   # remove trailing .exe if any
35978   new_path="${new_path/%.exe/}"
35979 
35980   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35981 
35982   # First separate the path from the arguments. This will split at the first
35983   # space.
35984   complete="$NM"
35985   path="${complete%% *}"
35986   tmp="$complete EOL"
35987   arguments="${tmp#* }"
35988 
35989   # Input might be given as Windows format, start by converting to
35990   # unix format.
35991   new_path="$path"
35992 
35993   windows_path="$new_path"
35994   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
35995     unix_path=`$CYGPATH -u "$windows_path"`
35996     new_path="$unix_path"
35997   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
35998     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
35999     new_path="$unix_path"
36000   fi
36001 
36002 
36003   # Now try to locate executable using which
36004   new_path=`$WHICH "$new_path" 2> /dev/null`
36005 
36006   if test "x$new_path" = x; then
36007     # Oops. Which didn't find the executable.
36008     # The splitting of arguments from the executable at a space might have been incorrect,
36009     # since paths with space are more likely in Windows. Give it another try with the whole
36010     # argument.
36011     path="$complete"
36012     arguments="EOL"
36013     new_path="$path"
36014 
36015   windows_path="$new_path"
36016   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36017     unix_path=`$CYGPATH -u "$windows_path"`
36018     new_path="$unix_path"
36019   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36020     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36021     new_path="$unix_path"
36022   fi
36023 
36024 
36025     new_path=`$WHICH "$new_path" 2> /dev/null`
36026     # bat and cmd files are not always considered executable in MSYS causing which
36027     # to not find them
36028     if test "x$new_path" = x \
36029         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36030         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36031       new_path="$path"
36032 
36033   windows_path="$new_path"
36034   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36035     unix_path=`$CYGPATH -u "$windows_path"`
36036     new_path="$unix_path"
36037   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36038     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36039     new_path="$unix_path"
36040   fi
36041 
36042     fi
36043 
36044     if test "x$new_path" = x; then
36045       # It's still not found. Now this is an unrecoverable error.
36046       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
36047 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
36048       has_space=`$ECHO "$complete" | $GREP " "`
36049       if test "x$has_space" != x; then
36050         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36051 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36052       fi
36053       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
36054     fi
36055   fi
36056 
36057   # Now new_path has a complete unix path to the binary
36058   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
36059     # Keep paths in /bin as-is, but remove trailing .exe if any
36060     new_path="${new_path/%.exe/}"
36061     # Do not save /bin paths to all_fixpath_prefixes!
36062   else
36063     # Not in mixed or Windows style, start by that.
36064     new_path=`cmd //c echo $new_path`
36065 
36066   input_path="$new_path"
36067   # Check if we need to convert this using DOS-style short mode. If the path
36068   # contains just simple characters, use it. Otherwise (spaces, weird characters),
36069   # take no chances and rewrite it.
36070   # Note: m4 eats our [], so we need to use [ and ] instead.
36071   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
36072   if test "x$has_forbidden_chars" != x; then
36073     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36074     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36075   fi
36076 
36077     # Output is in $new_path
36078 
36079   windows_path="$new_path"
36080   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36081     unix_path=`$CYGPATH -u "$windows_path"`
36082     new_path="$unix_path"
36083   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36084     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36085     new_path="$unix_path"
36086   fi
36087 
36088     # remove trailing .exe if any
36089     new_path="${new_path/%.exe/}"
36090 
36091     # Save the first 10 bytes of this path to the storage, so fixpath can work.
36092     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
36093   fi
36094 
36095   else
36096     # We're on a unix platform. Hooray! :)
36097     # First separate the path from the arguments. This will split at the first
36098     # space.
36099     complete="$NM"
36100     path="${complete%% *}"
36101     tmp="$complete EOL"
36102     arguments="${tmp#* }"
36103 
36104     # Cannot rely on the command "which" here since it doesn't always work.
36105     is_absolute_path=`$ECHO "$path" | $GREP ^/`
36106     if test -z "$is_absolute_path"; then
36107       # Path to executable is not absolute. Find it.
36108       IFS_save="$IFS"
36109       IFS=:
36110       for p in $PATH; do
36111         if test -f "$p/$path" && test -x "$p/$path"; then
36112           new_path="$p/$path"
36113           break
36114         fi
36115       done
36116       IFS="$IFS_save"
36117     else
36118       # This is an absolute path, we can use it without further modifications.
36119       new_path="$path"
36120     fi
36121 
36122     if test "x$new_path" = x; then
36123       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
36124 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
36125       has_space=`$ECHO "$complete" | $GREP " "`
36126       if test "x$has_space" != x; then
36127         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
36128 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
36129       fi
36130       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
36131     fi
36132   fi
36133 
36134   # Now join together the path and the arguments once again
36135   if test "x$arguments" != xEOL; then
36136     new_complete="$new_path ${arguments% *}"
36137   else
36138     new_complete="$new_path"
36139   fi
36140 
36141   if test "x$complete" != "x$new_complete"; then
36142     NM="$new_complete"
36143     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5
36144 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;}
36145   fi
36146 
36147 
36148 
36149   # Publish this variable in the help.
36150 
36151 
36152   if test "x$GNM" = x; then
36153     # The variable is not set by user, try to locate tool using the code snippet
36154     for ac_prog in gnm
36155 do
36156   # Extract the first word of "$ac_prog", so it can be a program name with args.
36157 set dummy $ac_prog; ac_word=$2
36158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36159 $as_echo_n "checking for $ac_word... " >&6; }
36160 if ${ac_cv_path_GNM+:} false; then :
36161   $as_echo_n "(cached) " >&6
36162 else
36163   case $GNM in
36164   [\\/]* | ?:[\\/]*)
36165   ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
36166   ;;
36167   *)
36168   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36169 for as_dir in $PATH
36170 do
36171   IFS=$as_save_IFS
36172   test -z "$as_dir" && as_dir=.
36173     for ac_exec_ext in '' $ac_executable_extensions; do
36174   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36175     ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
36176     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36177     break 2
36178   fi
36179 done
36180   done
36181 IFS=$as_save_IFS
36182 
36183   ;;
36184 esac
36185 fi
36186 GNM=$ac_cv_path_GNM
36187 if test -n "$GNM"; then
36188   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
36189 $as_echo "$GNM" >&6; }
36190 else
36191   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36192 $as_echo "no" >&6; }
36193 fi
36194 
36195 
36196   test -n "$GNM" && break
36197 done
36198 
36199   else
36200     # The variable is set, but is it from the command line or the environment?
36201 
36202     # Try to remove the string !GNM! from our list.
36203     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GNM!/}
36204     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
36205       # If it failed, the variable was not from the command line. Ignore it,
36206       # but warn the user (except for BASH, which is always set by the calling BASH).
36207       if test "xGNM" != xBASH; then
36208         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&5
36209 $as_echo "$as_me: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&2;}
36210       fi
36211       # Try to locate tool using the code snippet
36212       for ac_prog in gnm
36213 do
36214   # Extract the first word of "$ac_prog", so it can be a program name with args.
36215 set dummy $ac_prog; ac_word=$2
36216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36217 $as_echo_n "checking for $ac_word... " >&6; }
36218 if ${ac_cv_path_GNM+:} false; then :
36219   $as_echo_n "(cached) " >&6
36220 else
36221   case $GNM in
36222   [\\/]* | ?:[\\/]*)
36223   ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
36224   ;;
36225   *)
36226   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36227 for as_dir in $PATH
36228 do
36229   IFS=$as_save_IFS
36230   test -z "$as_dir" && as_dir=.
36231     for ac_exec_ext in '' $ac_executable_extensions; do
36232   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36233     ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
36234     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36235     break 2
36236   fi
36237 done
36238   done
36239 IFS=$as_save_IFS
36240 
36241   ;;
36242 esac
36243 fi
36244 GNM=$ac_cv_path_GNM
36245 if test -n "$GNM"; then
36246   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
36247 $as_echo "$GNM" >&6; }
36248 else
36249   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36250 $as_echo "no" >&6; }
36251 fi
36252 
36253 
36254   test -n "$GNM" && break
36255 done
36256 
36257     else
36258       # If it succeeded, then it was overridden by the user. We will use it
36259       # for the tool.
36260 
36261       # First remove it from the list of overridden variables, so we can test
36262       # for unknown variables in the end.
36263       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
36264 
36265       # Check if the provided tool contains a complete path.
36266       tool_specified="$GNM"
36267       tool_basename="${tool_specified##*/}"
36268       if test "x$tool_basename" = "x$tool_specified"; then
36269         # A command without a complete path is provided, search $PATH.
36270         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GNM=$tool_basename" >&5
36271 $as_echo "$as_me: Will search for user supplied tool GNM=$tool_basename" >&6;}
36272         # Extract the first word of "$tool_basename", so it can be a program name with args.
36273 set dummy $tool_basename; ac_word=$2
36274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36275 $as_echo_n "checking for $ac_word... " >&6; }
36276 if ${ac_cv_path_GNM+:} false; then :
36277   $as_echo_n "(cached) " >&6
36278 else
36279   case $GNM in
36280   [\\/]* | ?:[\\/]*)
36281   ac_cv_path_GNM="$GNM" # Let the user override the test with a path.
36282   ;;
36283   *)
36284   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36285 for as_dir in $PATH
36286 do
36287   IFS=$as_save_IFS
36288   test -z "$as_dir" && as_dir=.
36289     for ac_exec_ext in '' $ac_executable_extensions; do
36290   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36291     ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext"
36292     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36293     break 2
36294   fi
36295 done
36296   done
36297 IFS=$as_save_IFS
36298 
36299   ;;
36300 esac
36301 fi
36302 GNM=$ac_cv_path_GNM
36303 if test -n "$GNM"; then
36304   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5
36305 $as_echo "$GNM" >&6; }
36306 else
36307   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36308 $as_echo "no" >&6; }
36309 fi
36310 
36311 
36312         if test "x$GNM" = x; then
36313           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
36314         fi
36315       else
36316         # Otherwise we believe it is a complete path. Use it as it is.
36317         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GNM=$tool_specified" >&5
36318 $as_echo "$as_me: Will use user supplied tool GNM=$tool_specified" >&6;}
36319         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5
36320 $as_echo_n "checking for GNM... " >&6; }
36321         if test ! -x "$tool_specified"; then
36322           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
36323 $as_echo "not found" >&6; }
36324           as_fn_error $? "User supplied tool GNM=$tool_specified does not exist or is not executable" "$LINENO" 5
36325         fi
36326         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
36327 $as_echo "$tool_specified" >&6; }
36328       fi
36329     fi
36330   fi
36331 
36332 
36333 
36334   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36335 
36336   # First separate the path from the arguments. This will split at the first
36337   # space.
36338   complete="$GNM"
36339   path="${complete%% *}"
36340   tmp="$complete EOL"
36341   arguments="${tmp#* }"
36342 
36343   # Input might be given as Windows format, start by converting to
36344   # unix format.
36345   new_path=`$CYGPATH -u "$path"`
36346 
36347   # Now try to locate executable using which
36348   new_path=`$WHICH "$new_path" 2> /dev/null`
36349   # bat and cmd files are not always considered executable in cygwin causing which
36350   # to not find them
36351   if test "x$new_path" = x \
36352       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36353       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36354     new_path=`$CYGPATH -u "$path"`
36355   fi
36356   if test "x$new_path" = x; then
36357     # Oops. Which didn't find the executable.
36358     # The splitting of arguments from the executable at a space might have been incorrect,
36359     # since paths with space are more likely in Windows. Give it another try with the whole
36360     # argument.
36361     path="$complete"
36362     arguments="EOL"
36363     new_path=`$CYGPATH -u "$path"`
36364     new_path=`$WHICH "$new_path" 2> /dev/null`
36365     # bat and cmd files are not always considered executable in cygwin causing which
36366     # to not find them
36367     if test "x$new_path" = x \
36368         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36369         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36370       new_path=`$CYGPATH -u "$path"`
36371     fi
36372     if test "x$new_path" = x; then
36373       # It's still not found. Now this is an unrecoverable error.
36374       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
36375 $as_echo "$as_me: The path of GNM, 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}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36379 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36380       fi
36381       as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
36382     fi
36383   fi
36384 
36385   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
36386   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
36387   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
36388   # "foo.exe" is OK but "foo" is an error.
36389   #
36390   # This test is therefore slightly more accurate than "test -f" to check for file presence.
36391   # It is also a way to make sure we got the proper file name for the real test later on.
36392   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
36393   if test "x$test_shortpath" = x; then
36394     # Short path failed, file does not exist as specified.
36395     # Try adding .exe or .cmd
36396     if test -f "${new_path}.exe"; then
36397       input_to_shortpath="${new_path}.exe"
36398     elif test -f "${new_path}.cmd"; then
36399       input_to_shortpath="${new_path}.cmd"
36400     else
36401       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$new_path\", is invalid." >&5
36402 $as_echo "$as_me: The path of GNM, which resolves as \"$new_path\", is invalid." >&6;}
36403       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
36404 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
36405       as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
36406     fi
36407   else
36408     input_to_shortpath="$new_path"
36409   fi
36410 
36411   # Call helper function which possibly converts this using DOS-style short mode.
36412   # If so, the updated path is stored in $new_path.
36413   new_path="$input_to_shortpath"
36414 
36415   input_path="$input_to_shortpath"
36416   # Check if we need to convert this using DOS-style short mode. If the path
36417   # contains just simple characters, use it. Otherwise (spaces, weird characters),
36418   # take no chances and rewrite it.
36419   # Note: m4 eats our [], so we need to use [ and ] instead.
36420   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
36421   if test "x$has_forbidden_chars" != x; then
36422     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36423     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
36424     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
36425     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
36426       # Going to short mode and back again did indeed matter. Since short mode is
36427       # case insensitive, let's make it lowercase to improve readability.
36428       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36429       # Now convert it back to Unix-stile (cygpath)
36430       input_path=`$CYGPATH -u "$shortmode_path"`
36431       new_path="$input_path"
36432     fi
36433   fi
36434 
36435   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
36436   if test "x$test_cygdrive_prefix" = x; then
36437     # As a simple fix, exclude /usr/bin since it's not a real path.
36438     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
36439       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
36440       # a path prefixed by /cygdrive for fixpath to work.
36441       new_path="$CYGWIN_ROOT_PATH$input_path"
36442     fi
36443   fi
36444 
36445   # remove trailing .exe if any
36446   new_path="${new_path/%.exe/}"
36447 
36448   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36449 
36450   # First separate the path from the arguments. This will split at the first
36451   # space.
36452   complete="$GNM"
36453   path="${complete%% *}"
36454   tmp="$complete EOL"
36455   arguments="${tmp#* }"
36456 
36457   # Input might be given as Windows format, start by converting to
36458   # unix format.
36459   new_path="$path"
36460 
36461   windows_path="$new_path"
36462   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36463     unix_path=`$CYGPATH -u "$windows_path"`
36464     new_path="$unix_path"
36465   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36466     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36467     new_path="$unix_path"
36468   fi
36469 
36470 
36471   # Now try to locate executable using which
36472   new_path=`$WHICH "$new_path" 2> /dev/null`
36473 
36474   if test "x$new_path" = x; then
36475     # Oops. Which didn't find the executable.
36476     # The splitting of arguments from the executable at a space might have been incorrect,
36477     # since paths with space are more likely in Windows. Give it another try with the whole
36478     # argument.
36479     path="$complete"
36480     arguments="EOL"
36481     new_path="$path"
36482 
36483   windows_path="$new_path"
36484   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36485     unix_path=`$CYGPATH -u "$windows_path"`
36486     new_path="$unix_path"
36487   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36488     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36489     new_path="$unix_path"
36490   fi
36491 
36492 
36493     new_path=`$WHICH "$new_path" 2> /dev/null`
36494     # bat and cmd files are not always considered executable in MSYS causing which
36495     # to not find them
36496     if test "x$new_path" = x \
36497         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36498         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36499       new_path="$path"
36500 
36501   windows_path="$new_path"
36502   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36503     unix_path=`$CYGPATH -u "$windows_path"`
36504     new_path="$unix_path"
36505   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36506     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36507     new_path="$unix_path"
36508   fi
36509 
36510     fi
36511 
36512     if test "x$new_path" = x; then
36513       # It's still not found. Now this is an unrecoverable error.
36514       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
36515 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
36516       has_space=`$ECHO "$complete" | $GREP " "`
36517       if test "x$has_space" != x; then
36518         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36519 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36520       fi
36521       as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
36522     fi
36523   fi
36524 
36525   # Now new_path has a complete unix path to the binary
36526   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
36527     # Keep paths in /bin as-is, but remove trailing .exe if any
36528     new_path="${new_path/%.exe/}"
36529     # Do not save /bin paths to all_fixpath_prefixes!
36530   else
36531     # Not in mixed or Windows style, start by that.
36532     new_path=`cmd //c echo $new_path`
36533 
36534   input_path="$new_path"
36535   # Check if we need to convert this using DOS-style short mode. If the path
36536   # contains just simple characters, use it. Otherwise (spaces, weird characters),
36537   # take no chances and rewrite it.
36538   # Note: m4 eats our [], so we need to use [ and ] instead.
36539   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
36540   if test "x$has_forbidden_chars" != x; then
36541     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36542     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36543   fi
36544 
36545     # Output is in $new_path
36546 
36547   windows_path="$new_path"
36548   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36549     unix_path=`$CYGPATH -u "$windows_path"`
36550     new_path="$unix_path"
36551   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36552     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36553     new_path="$unix_path"
36554   fi
36555 
36556     # remove trailing .exe if any
36557     new_path="${new_path/%.exe/}"
36558 
36559     # Save the first 10 bytes of this path to the storage, so fixpath can work.
36560     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
36561   fi
36562 
36563   else
36564     # We're on a unix platform. Hooray! :)
36565     # First separate the path from the arguments. This will split at the first
36566     # space.
36567     complete="$GNM"
36568     path="${complete%% *}"
36569     tmp="$complete EOL"
36570     arguments="${tmp#* }"
36571 
36572     # Cannot rely on the command "which" here since it doesn't always work.
36573     is_absolute_path=`$ECHO "$path" | $GREP ^/`
36574     if test -z "$is_absolute_path"; then
36575       # Path to executable is not absolute. Find it.
36576       IFS_save="$IFS"
36577       IFS=:
36578       for p in $PATH; do
36579         if test -f "$p/$path" && test -x "$p/$path"; then
36580           new_path="$p/$path"
36581           break
36582         fi
36583       done
36584       IFS="$IFS_save"
36585     else
36586       # This is an absolute path, we can use it without further modifications.
36587       new_path="$path"
36588     fi
36589 
36590     if test "x$new_path" = x; then
36591       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5
36592 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;}
36593       has_space=`$ECHO "$complete" | $GREP " "`
36594       if test "x$has_space" != x; then
36595         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
36596 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
36597       fi
36598       as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5
36599     fi
36600   fi
36601 
36602   # Now join together the path and the arguments once again
36603   if test "x$arguments" != xEOL; then
36604     new_complete="$new_path ${arguments% *}"
36605   else
36606     new_complete="$new_path"
36607   fi
36608 
36609   if test "x$complete" != "x$new_complete"; then
36610     GNM="$new_complete"
36611     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting GNM to \"$new_complete\"" >&5
36612 $as_echo "$as_me: Rewriting GNM to \"$new_complete\"" >&6;}
36613   fi
36614 
36615 
36616 
36617 
36618   # Publish this variable in the help.
36619 
36620 
36621   if test "x$MCS" = x; then
36622     # The variable is not set by user, try to locate tool using the code snippet
36623     for ac_prog in mcs
36624 do
36625   # Extract the first word of "$ac_prog", so it can be a program name with args.
36626 set dummy $ac_prog; ac_word=$2
36627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36628 $as_echo_n "checking for $ac_word... " >&6; }
36629 if ${ac_cv_path_MCS+:} false; then :
36630   $as_echo_n "(cached) " >&6
36631 else
36632   case $MCS in
36633   [\\/]* | ?:[\\/]*)
36634   ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
36635   ;;
36636   *)
36637   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36638 for as_dir in $PATH
36639 do
36640   IFS=$as_save_IFS
36641   test -z "$as_dir" && as_dir=.
36642     for ac_exec_ext in '' $ac_executable_extensions; do
36643   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36644     ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
36645     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36646     break 2
36647   fi
36648 done
36649   done
36650 IFS=$as_save_IFS
36651 
36652   ;;
36653 esac
36654 fi
36655 MCS=$ac_cv_path_MCS
36656 if test -n "$MCS"; then
36657   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
36658 $as_echo "$MCS" >&6; }
36659 else
36660   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36661 $as_echo "no" >&6; }
36662 fi
36663 
36664 
36665   test -n "$MCS" && break
36666 done
36667 
36668   else
36669     # The variable is set, but is it from the command line or the environment?
36670 
36671     # Try to remove the string !MCS! from our list.
36672     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MCS!/}
36673     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
36674       # If it failed, the variable was not from the command line. Ignore it,
36675       # but warn the user (except for BASH, which is always set by the calling BASH).
36676       if test "xMCS" != xBASH; then
36677         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MCS from the environment. Use command line variables instead." >&5
36678 $as_echo "$as_me: WARNING: Ignoring value of MCS from the environment. Use command line variables instead." >&2;}
36679       fi
36680       # Try to locate tool using the code snippet
36681       for ac_prog in mcs
36682 do
36683   # Extract the first word of "$ac_prog", so it can be a program name with args.
36684 set dummy $ac_prog; ac_word=$2
36685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36686 $as_echo_n "checking for $ac_word... " >&6; }
36687 if ${ac_cv_path_MCS+:} false; then :
36688   $as_echo_n "(cached) " >&6
36689 else
36690   case $MCS in
36691   [\\/]* | ?:[\\/]*)
36692   ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
36693   ;;
36694   *)
36695   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36696 for as_dir in $PATH
36697 do
36698   IFS=$as_save_IFS
36699   test -z "$as_dir" && as_dir=.
36700     for ac_exec_ext in '' $ac_executable_extensions; do
36701   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36702     ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
36703     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36704     break 2
36705   fi
36706 done
36707   done
36708 IFS=$as_save_IFS
36709 
36710   ;;
36711 esac
36712 fi
36713 MCS=$ac_cv_path_MCS
36714 if test -n "$MCS"; then
36715   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
36716 $as_echo "$MCS" >&6; }
36717 else
36718   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36719 $as_echo "no" >&6; }
36720 fi
36721 
36722 
36723   test -n "$MCS" && break
36724 done
36725 
36726     else
36727       # If it succeeded, then it was overridden by the user. We will use it
36728       # for the tool.
36729 
36730       # First remove it from the list of overridden variables, so we can test
36731       # for unknown variables in the end.
36732       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
36733 
36734       # Check if the provided tool contains a complete path.
36735       tool_specified="$MCS"
36736       tool_basename="${tool_specified##*/}"
36737       if test "x$tool_basename" = "x$tool_specified"; then
36738         # A command without a complete path is provided, search $PATH.
36739         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MCS=$tool_basename" >&5
36740 $as_echo "$as_me: Will search for user supplied tool MCS=$tool_basename" >&6;}
36741         # Extract the first word of "$tool_basename", so it can be a program name with args.
36742 set dummy $tool_basename; ac_word=$2
36743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
36744 $as_echo_n "checking for $ac_word... " >&6; }
36745 if ${ac_cv_path_MCS+:} false; then :
36746   $as_echo_n "(cached) " >&6
36747 else
36748   case $MCS in
36749   [\\/]* | ?:[\\/]*)
36750   ac_cv_path_MCS="$MCS" # Let the user override the test with a path.
36751   ;;
36752   *)
36753   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
36754 for as_dir in $PATH
36755 do
36756   IFS=$as_save_IFS
36757   test -z "$as_dir" && as_dir=.
36758     for ac_exec_ext in '' $ac_executable_extensions; do
36759   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
36760     ac_cv_path_MCS="$as_dir/$ac_word$ac_exec_ext"
36761     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
36762     break 2
36763   fi
36764 done
36765   done
36766 IFS=$as_save_IFS
36767 
36768   ;;
36769 esac
36770 fi
36771 MCS=$ac_cv_path_MCS
36772 if test -n "$MCS"; then
36773   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MCS" >&5
36774 $as_echo "$MCS" >&6; }
36775 else
36776   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36777 $as_echo "no" >&6; }
36778 fi
36779 
36780 
36781         if test "x$MCS" = x; then
36782           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
36783         fi
36784       else
36785         # Otherwise we believe it is a complete path. Use it as it is.
36786         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MCS=$tool_specified" >&5
36787 $as_echo "$as_me: Will use user supplied tool MCS=$tool_specified" >&6;}
36788         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MCS" >&5
36789 $as_echo_n "checking for MCS... " >&6; }
36790         if test ! -x "$tool_specified"; then
36791           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
36792 $as_echo "not found" >&6; }
36793           as_fn_error $? "User supplied tool MCS=$tool_specified does not exist or is not executable" "$LINENO" 5
36794         fi
36795         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
36796 $as_echo "$tool_specified" >&6; }
36797       fi
36798     fi
36799   fi
36800 
36801 
36802 
36803   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36804 
36805   # First separate the path from the arguments. This will split at the first
36806   # space.
36807   complete="$MCS"
36808   path="${complete%% *}"
36809   tmp="$complete EOL"
36810   arguments="${tmp#* }"
36811 
36812   # Input might be given as Windows format, start by converting to
36813   # unix format.
36814   new_path=`$CYGPATH -u "$path"`
36815 
36816   # Now try to locate executable using which
36817   new_path=`$WHICH "$new_path" 2> /dev/null`
36818   # bat and cmd files are not always considered executable in cygwin causing which
36819   # to not find them
36820   if test "x$new_path" = x \
36821       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36822       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36823     new_path=`$CYGPATH -u "$path"`
36824   fi
36825   if test "x$new_path" = x; then
36826     # Oops. Which didn't find the executable.
36827     # The splitting of arguments from the executable at a space might have been incorrect,
36828     # since paths with space are more likely in Windows. Give it another try with the whole
36829     # argument.
36830     path="$complete"
36831     arguments="EOL"
36832     new_path=`$CYGPATH -u "$path"`
36833     new_path=`$WHICH "$new_path" 2> /dev/null`
36834     # bat and cmd files are not always considered executable in cygwin causing which
36835     # to not find them
36836     if test "x$new_path" = x \
36837         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36838         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36839       new_path=`$CYGPATH -u "$path"`
36840     fi
36841     if test "x$new_path" = x; then
36842       # It's still not found. Now this is an unrecoverable error.
36843       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
36844 $as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
36845       has_space=`$ECHO "$complete" | $GREP " "`
36846       if test "x$has_space" != x; then
36847         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36848 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36849       fi
36850       as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36851     fi
36852   fi
36853 
36854   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
36855   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
36856   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
36857   # "foo.exe" is OK but "foo" is an error.
36858   #
36859   # This test is therefore slightly more accurate than "test -f" to check for file presence.
36860   # It is also a way to make sure we got the proper file name for the real test later on.
36861   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
36862   if test "x$test_shortpath" = x; then
36863     # Short path failed, file does not exist as specified.
36864     # Try adding .exe or .cmd
36865     if test -f "${new_path}.exe"; then
36866       input_to_shortpath="${new_path}.exe"
36867     elif test -f "${new_path}.cmd"; then
36868       input_to_shortpath="${new_path}.cmd"
36869     else
36870       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$new_path\", is invalid." >&5
36871 $as_echo "$as_me: The path of MCS, which resolves as \"$new_path\", is invalid." >&6;}
36872       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
36873 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
36874       as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36875     fi
36876   else
36877     input_to_shortpath="$new_path"
36878   fi
36879 
36880   # Call helper function which possibly converts this using DOS-style short mode.
36881   # If so, the updated path is stored in $new_path.
36882   new_path="$input_to_shortpath"
36883 
36884   input_path="$input_to_shortpath"
36885   # Check if we need to convert this using DOS-style short mode. If the path
36886   # contains just simple characters, use it. Otherwise (spaces, weird characters),
36887   # take no chances and rewrite it.
36888   # Note: m4 eats our [], so we need to use [ and ] instead.
36889   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
36890   if test "x$has_forbidden_chars" != x; then
36891     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
36892     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
36893     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
36894     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
36895       # Going to short mode and back again did indeed matter. Since short mode is
36896       # case insensitive, let's make it lowercase to improve readability.
36897       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
36898       # Now convert it back to Unix-stile (cygpath)
36899       input_path=`$CYGPATH -u "$shortmode_path"`
36900       new_path="$input_path"
36901     fi
36902   fi
36903 
36904   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
36905   if test "x$test_cygdrive_prefix" = x; then
36906     # As a simple fix, exclude /usr/bin since it's not a real path.
36907     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
36908       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
36909       # a path prefixed by /cygdrive for fixpath to work.
36910       new_path="$CYGWIN_ROOT_PATH$input_path"
36911     fi
36912   fi
36913 
36914   # remove trailing .exe if any
36915   new_path="${new_path/%.exe/}"
36916 
36917   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36918 
36919   # First separate the path from the arguments. This will split at the first
36920   # space.
36921   complete="$MCS"
36922   path="${complete%% *}"
36923   tmp="$complete EOL"
36924   arguments="${tmp#* }"
36925 
36926   # Input might be given as Windows format, start by converting to
36927   # unix format.
36928   new_path="$path"
36929 
36930   windows_path="$new_path"
36931   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36932     unix_path=`$CYGPATH -u "$windows_path"`
36933     new_path="$unix_path"
36934   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36935     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36936     new_path="$unix_path"
36937   fi
36938 
36939 
36940   # Now try to locate executable using which
36941   new_path=`$WHICH "$new_path" 2> /dev/null`
36942 
36943   if test "x$new_path" = x; then
36944     # Oops. Which didn't find the executable.
36945     # The splitting of arguments from the executable at a space might have been incorrect,
36946     # since paths with space are more likely in Windows. Give it another try with the whole
36947     # argument.
36948     path="$complete"
36949     arguments="EOL"
36950     new_path="$path"
36951 
36952   windows_path="$new_path"
36953   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36954     unix_path=`$CYGPATH -u "$windows_path"`
36955     new_path="$unix_path"
36956   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36957     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36958     new_path="$unix_path"
36959   fi
36960 
36961 
36962     new_path=`$WHICH "$new_path" 2> /dev/null`
36963     # bat and cmd files are not always considered executable in MSYS causing which
36964     # to not find them
36965     if test "x$new_path" = x \
36966         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
36967         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
36968       new_path="$path"
36969 
36970   windows_path="$new_path"
36971   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
36972     unix_path=`$CYGPATH -u "$windows_path"`
36973     new_path="$unix_path"
36974   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
36975     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
36976     new_path="$unix_path"
36977   fi
36978 
36979     fi
36980 
36981     if test "x$new_path" = x; then
36982       # It's still not found. Now this is an unrecoverable error.
36983       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
36984 $as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
36985       has_space=`$ECHO "$complete" | $GREP " "`
36986       if test "x$has_space" != x; then
36987         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
36988 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
36989       fi
36990       as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
36991     fi
36992   fi
36993 
36994   # Now new_path has a complete unix path to the binary
36995   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
36996     # Keep paths in /bin as-is, but remove trailing .exe if any
36997     new_path="${new_path/%.exe/}"
36998     # Do not save /bin paths to all_fixpath_prefixes!
36999   else
37000     # Not in mixed or Windows style, start by that.
37001     new_path=`cmd //c echo $new_path`
37002 
37003   input_path="$new_path"
37004   # Check if we need to convert this using DOS-style short mode. If the path
37005   # contains just simple characters, use it. Otherwise (spaces, weird characters),
37006   # take no chances and rewrite it.
37007   # Note: m4 eats our [], so we need to use [ and ] instead.
37008   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
37009   if test "x$has_forbidden_chars" != x; then
37010     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37011     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37012   fi
37013 
37014     # Output is in $new_path
37015 
37016   windows_path="$new_path"
37017   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37018     unix_path=`$CYGPATH -u "$windows_path"`
37019     new_path="$unix_path"
37020   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37021     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37022     new_path="$unix_path"
37023   fi
37024 
37025     # remove trailing .exe if any
37026     new_path="${new_path/%.exe/}"
37027 
37028     # Save the first 10 bytes of this path to the storage, so fixpath can work.
37029     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
37030   fi
37031 
37032   else
37033     # We're on a unix platform. Hooray! :)
37034     # First separate the path from the arguments. This will split at the first
37035     # space.
37036     complete="$MCS"
37037     path="${complete%% *}"
37038     tmp="$complete EOL"
37039     arguments="${tmp#* }"
37040 
37041     # Cannot rely on the command "which" here since it doesn't always work.
37042     is_absolute_path=`$ECHO "$path" | $GREP ^/`
37043     if test -z "$is_absolute_path"; then
37044       # Path to executable is not absolute. Find it.
37045       IFS_save="$IFS"
37046       IFS=:
37047       for p in $PATH; do
37048         if test -f "$p/$path" && test -x "$p/$path"; then
37049           new_path="$p/$path"
37050           break
37051         fi
37052       done
37053       IFS="$IFS_save"
37054     else
37055       # This is an absolute path, we can use it without further modifications.
37056       new_path="$path"
37057     fi
37058 
37059     if test "x$new_path" = x; then
37060       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MCS, which resolves as \"$complete\", is not found." >&5
37061 $as_echo "$as_me: The path of MCS, which resolves as \"$complete\", is not found." >&6;}
37062       has_space=`$ECHO "$complete" | $GREP " "`
37063       if test "x$has_space" != x; then
37064         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
37065 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
37066       fi
37067       as_fn_error $? "Cannot locate the the path of MCS" "$LINENO" 5
37068     fi
37069   fi
37070 
37071   # Now join together the path and the arguments once again
37072   if test "x$arguments" != xEOL; then
37073     new_complete="$new_path ${arguments% *}"
37074   else
37075     new_complete="$new_path"
37076   fi
37077 
37078   if test "x$complete" != "x$new_complete"; then
37079     MCS="$new_complete"
37080     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MCS to \"$new_complete\"" >&5
37081 $as_echo "$as_me: Rewriting MCS to \"$new_complete\"" >&6;}
37082   fi
37083 
37084   elif test "x$OPENJDK_TARGET_OS" != xwindows; then
37085     # FIXME: we should unify this with the solaris case above.
37086 
37087 
37088   # Publish this variable in the help.
37089 
37090 
37091   if test "x$STRIP" = x; then
37092     # The variable is not set by user, try to locate tool using the code snippet
37093     if test -n "$ac_tool_prefix"; then
37094   for ac_prog in strip
37095   do
37096     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37097 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37099 $as_echo_n "checking for $ac_word... " >&6; }
37100 if ${ac_cv_prog_STRIP+:} false; then :
37101   $as_echo_n "(cached) " >&6
37102 else
37103   if test -n "$STRIP"; then
37104   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
37105 else
37106 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37107 for as_dir in $PATH
37108 do
37109   IFS=$as_save_IFS
37110   test -z "$as_dir" && as_dir=.
37111     for ac_exec_ext in '' $ac_executable_extensions; do
37112   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37113     ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog"
37114     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37115     break 2
37116   fi
37117 done
37118   done
37119 IFS=$as_save_IFS
37120 
37121 fi
37122 fi
37123 STRIP=$ac_cv_prog_STRIP
37124 if test -n "$STRIP"; then
37125   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
37126 $as_echo "$STRIP" >&6; }
37127 else
37128   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37129 $as_echo "no" >&6; }
37130 fi
37131 
37132 
37133     test -n "$STRIP" && break
37134   done
37135 fi
37136 if test -z "$STRIP"; then
37137   ac_ct_STRIP=$STRIP
37138   for ac_prog in strip
37139 do
37140   # Extract the first word of "$ac_prog", so it can be a program name with args.
37141 set dummy $ac_prog; ac_word=$2
37142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37143 $as_echo_n "checking for $ac_word... " >&6; }
37144 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
37145   $as_echo_n "(cached) " >&6
37146 else
37147   if test -n "$ac_ct_STRIP"; then
37148   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
37149 else
37150 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37151 for as_dir in $PATH
37152 do
37153   IFS=$as_save_IFS
37154   test -z "$as_dir" && as_dir=.
37155     for ac_exec_ext in '' $ac_executable_extensions; do
37156   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37157     ac_cv_prog_ac_ct_STRIP="$ac_prog"
37158     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37159     break 2
37160   fi
37161 done
37162   done
37163 IFS=$as_save_IFS
37164 
37165 fi
37166 fi
37167 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
37168 if test -n "$ac_ct_STRIP"; then
37169   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
37170 $as_echo "$ac_ct_STRIP" >&6; }
37171 else
37172   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37173 $as_echo "no" >&6; }
37174 fi
37175 
37176 
37177   test -n "$ac_ct_STRIP" && break
37178 done
37179 
37180   if test "x$ac_ct_STRIP" = x; then
37181     STRIP=""
37182   else
37183     case $cross_compiling:$ac_tool_warned in
37184 yes:)
37185 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37186 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37187 ac_tool_warned=yes ;;
37188 esac
37189     STRIP=$ac_ct_STRIP
37190   fi
37191 fi
37192 
37193   else
37194     # The variable is set, but is it from the command line or the environment?
37195 
37196     # Try to remove the string !STRIP! from our list.
37197     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/}
37198     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
37199       # If it failed, the variable was not from the command line. Ignore it,
37200       # but warn the user (except for BASH, which is always set by the calling BASH).
37201       if test "xSTRIP" != xBASH; then
37202         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5
37203 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;}
37204       fi
37205       # Try to locate tool using the code snippet
37206       if test -n "$ac_tool_prefix"; then
37207   for ac_prog in strip
37208   do
37209     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37210 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37212 $as_echo_n "checking for $ac_word... " >&6; }
37213 if ${ac_cv_prog_STRIP+:} false; then :
37214   $as_echo_n "(cached) " >&6
37215 else
37216   if test -n "$STRIP"; then
37217   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
37218 else
37219 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37220 for as_dir in $PATH
37221 do
37222   IFS=$as_save_IFS
37223   test -z "$as_dir" && as_dir=.
37224     for ac_exec_ext in '' $ac_executable_extensions; do
37225   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37226     ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog"
37227     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37228     break 2
37229   fi
37230 done
37231   done
37232 IFS=$as_save_IFS
37233 
37234 fi
37235 fi
37236 STRIP=$ac_cv_prog_STRIP
37237 if test -n "$STRIP"; then
37238   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
37239 $as_echo "$STRIP" >&6; }
37240 else
37241   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37242 $as_echo "no" >&6; }
37243 fi
37244 
37245 
37246     test -n "$STRIP" && break
37247   done
37248 fi
37249 if test -z "$STRIP"; then
37250   ac_ct_STRIP=$STRIP
37251   for ac_prog in strip
37252 do
37253   # Extract the first word of "$ac_prog", so it can be a program name with args.
37254 set dummy $ac_prog; ac_word=$2
37255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37256 $as_echo_n "checking for $ac_word... " >&6; }
37257 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
37258   $as_echo_n "(cached) " >&6
37259 else
37260   if test -n "$ac_ct_STRIP"; then
37261   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
37262 else
37263 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37264 for as_dir in $PATH
37265 do
37266   IFS=$as_save_IFS
37267   test -z "$as_dir" && as_dir=.
37268     for ac_exec_ext in '' $ac_executable_extensions; do
37269   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37270     ac_cv_prog_ac_ct_STRIP="$ac_prog"
37271     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37272     break 2
37273   fi
37274 done
37275   done
37276 IFS=$as_save_IFS
37277 
37278 fi
37279 fi
37280 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
37281 if test -n "$ac_ct_STRIP"; then
37282   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
37283 $as_echo "$ac_ct_STRIP" >&6; }
37284 else
37285   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37286 $as_echo "no" >&6; }
37287 fi
37288 
37289 
37290   test -n "$ac_ct_STRIP" && break
37291 done
37292 
37293   if test "x$ac_ct_STRIP" = x; then
37294     STRIP=""
37295   else
37296     case $cross_compiling:$ac_tool_warned in
37297 yes:)
37298 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37299 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37300 ac_tool_warned=yes ;;
37301 esac
37302     STRIP=$ac_ct_STRIP
37303   fi
37304 fi
37305 
37306     else
37307       # If it succeeded, then it was overridden by the user. We will use it
37308       # for the tool.
37309 
37310       # First remove it from the list of overridden variables, so we can test
37311       # for unknown variables in the end.
37312       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
37313 
37314       # Check if the provided tool contains a complete path.
37315       tool_specified="$STRIP"
37316       tool_basename="${tool_specified##*/}"
37317       if test "x$tool_basename" = "x$tool_specified"; then
37318         # A command without a complete path is provided, search $PATH.
37319         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5
37320 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;}
37321         # Extract the first word of "$tool_basename", so it can be a program name with args.
37322 set dummy $tool_basename; ac_word=$2
37323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37324 $as_echo_n "checking for $ac_word... " >&6; }
37325 if ${ac_cv_path_STRIP+:} false; then :
37326   $as_echo_n "(cached) " >&6
37327 else
37328   case $STRIP in
37329   [\\/]* | ?:[\\/]*)
37330   ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path.
37331   ;;
37332   *)
37333   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37334 for as_dir in $PATH
37335 do
37336   IFS=$as_save_IFS
37337   test -z "$as_dir" && as_dir=.
37338     for ac_exec_ext in '' $ac_executable_extensions; do
37339   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37340     ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext"
37341     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37342     break 2
37343   fi
37344 done
37345   done
37346 IFS=$as_save_IFS
37347 
37348   ;;
37349 esac
37350 fi
37351 STRIP=$ac_cv_path_STRIP
37352 if test -n "$STRIP"; then
37353   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
37354 $as_echo "$STRIP" >&6; }
37355 else
37356   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37357 $as_echo "no" >&6; }
37358 fi
37359 
37360 
37361         if test "x$STRIP" = x; then
37362           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
37363         fi
37364       else
37365         # Otherwise we believe it is a complete path. Use it as it is.
37366         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5
37367 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;}
37368         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5
37369 $as_echo_n "checking for STRIP... " >&6; }
37370         if test ! -x "$tool_specified"; then
37371           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
37372 $as_echo "not found" >&6; }
37373           as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5
37374         fi
37375         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
37376 $as_echo "$tool_specified" >&6; }
37377       fi
37378     fi
37379   fi
37380 
37381 
37382 
37383   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37384 
37385   # First separate the path from the arguments. This will split at the first
37386   # space.
37387   complete="$STRIP"
37388   path="${complete%% *}"
37389   tmp="$complete EOL"
37390   arguments="${tmp#* }"
37391 
37392   # Input might be given as Windows format, start by converting to
37393   # unix format.
37394   new_path=`$CYGPATH -u "$path"`
37395 
37396   # Now try to locate executable using which
37397   new_path=`$WHICH "$new_path" 2> /dev/null`
37398   # bat and cmd files are not always considered executable in cygwin causing which
37399   # to not find them
37400   if test "x$new_path" = x \
37401       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37402       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37403     new_path=`$CYGPATH -u "$path"`
37404   fi
37405   if test "x$new_path" = x; then
37406     # Oops. Which didn't find the executable.
37407     # The splitting of arguments from the executable at a space might have been incorrect,
37408     # since paths with space are more likely in Windows. Give it another try with the whole
37409     # argument.
37410     path="$complete"
37411     arguments="EOL"
37412     new_path=`$CYGPATH -u "$path"`
37413     new_path=`$WHICH "$new_path" 2> /dev/null`
37414     # bat and cmd files are not always considered executable in cygwin causing which
37415     # to not find them
37416     if test "x$new_path" = x \
37417         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37418         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37419       new_path=`$CYGPATH -u "$path"`
37420     fi
37421     if test "x$new_path" = x; then
37422       # It's still not found. Now this is an unrecoverable error.
37423       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
37424 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
37425       has_space=`$ECHO "$complete" | $GREP " "`
37426       if test "x$has_space" != x; then
37427         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37428 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37429       fi
37430       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
37431     fi
37432   fi
37433 
37434   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
37435   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
37436   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
37437   # "foo.exe" is OK but "foo" is an error.
37438   #
37439   # This test is therefore slightly more accurate than "test -f" to check for file presence.
37440   # It is also a way to make sure we got the proper file name for the real test later on.
37441   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
37442   if test "x$test_shortpath" = x; then
37443     # Short path failed, file does not exist as specified.
37444     # Try adding .exe or .cmd
37445     if test -f "${new_path}.exe"; then
37446       input_to_shortpath="${new_path}.exe"
37447     elif test -f "${new_path}.cmd"; then
37448       input_to_shortpath="${new_path}.cmd"
37449     else
37450       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5
37451 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;}
37452       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
37453 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
37454       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
37455     fi
37456   else
37457     input_to_shortpath="$new_path"
37458   fi
37459 
37460   # Call helper function which possibly converts this using DOS-style short mode.
37461   # If so, the updated path is stored in $new_path.
37462   new_path="$input_to_shortpath"
37463 
37464   input_path="$input_to_shortpath"
37465   # Check if we need to convert this using DOS-style short mode. If the path
37466   # contains just simple characters, use it. Otherwise (spaces, weird characters),
37467   # take no chances and rewrite it.
37468   # Note: m4 eats our [], so we need to use [ and ] instead.
37469   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
37470   if test "x$has_forbidden_chars" != x; then
37471     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37472     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
37473     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
37474     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
37475       # Going to short mode and back again did indeed matter. Since short mode is
37476       # case insensitive, let's make it lowercase to improve readability.
37477       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37478       # Now convert it back to Unix-stile (cygpath)
37479       input_path=`$CYGPATH -u "$shortmode_path"`
37480       new_path="$input_path"
37481     fi
37482   fi
37483 
37484   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
37485   if test "x$test_cygdrive_prefix" = x; then
37486     # As a simple fix, exclude /usr/bin since it's not a real path.
37487     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
37488       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
37489       # a path prefixed by /cygdrive for fixpath to work.
37490       new_path="$CYGWIN_ROOT_PATH$input_path"
37491     fi
37492   fi
37493 
37494   # remove trailing .exe if any
37495   new_path="${new_path/%.exe/}"
37496 
37497   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37498 
37499   # First separate the path from the arguments. This will split at the first
37500   # space.
37501   complete="$STRIP"
37502   path="${complete%% *}"
37503   tmp="$complete EOL"
37504   arguments="${tmp#* }"
37505 
37506   # Input might be given as Windows format, start by converting to
37507   # unix format.
37508   new_path="$path"
37509 
37510   windows_path="$new_path"
37511   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37512     unix_path=`$CYGPATH -u "$windows_path"`
37513     new_path="$unix_path"
37514   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37515     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37516     new_path="$unix_path"
37517   fi
37518 
37519 
37520   # Now try to locate executable using which
37521   new_path=`$WHICH "$new_path" 2> /dev/null`
37522 
37523   if test "x$new_path" = x; then
37524     # Oops. Which didn't find the executable.
37525     # The splitting of arguments from the executable at a space might have been incorrect,
37526     # since paths with space are more likely in Windows. Give it another try with the whole
37527     # argument.
37528     path="$complete"
37529     arguments="EOL"
37530     new_path="$path"
37531 
37532   windows_path="$new_path"
37533   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37534     unix_path=`$CYGPATH -u "$windows_path"`
37535     new_path="$unix_path"
37536   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37537     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37538     new_path="$unix_path"
37539   fi
37540 
37541 
37542     new_path=`$WHICH "$new_path" 2> /dev/null`
37543     # bat and cmd files are not always considered executable in MSYS causing which
37544     # to not find them
37545     if test "x$new_path" = x \
37546         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37547         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37548       new_path="$path"
37549 
37550   windows_path="$new_path"
37551   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37552     unix_path=`$CYGPATH -u "$windows_path"`
37553     new_path="$unix_path"
37554   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37555     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37556     new_path="$unix_path"
37557   fi
37558 
37559     fi
37560 
37561     if test "x$new_path" = x; then
37562       # It's still not found. Now this is an unrecoverable error.
37563       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
37564 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
37565       has_space=`$ECHO "$complete" | $GREP " "`
37566       if test "x$has_space" != x; then
37567         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
37568 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
37569       fi
37570       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
37571     fi
37572   fi
37573 
37574   # Now new_path has a complete unix path to the binary
37575   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
37576     # Keep paths in /bin as-is, but remove trailing .exe if any
37577     new_path="${new_path/%.exe/}"
37578     # Do not save /bin paths to all_fixpath_prefixes!
37579   else
37580     # Not in mixed or Windows style, start by that.
37581     new_path=`cmd //c echo $new_path`
37582 
37583   input_path="$new_path"
37584   # Check if we need to convert this using DOS-style short mode. If the path
37585   # contains just simple characters, use it. Otherwise (spaces, weird characters),
37586   # take no chances and rewrite it.
37587   # Note: m4 eats our [], so we need to use [ and ] instead.
37588   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
37589   if test "x$has_forbidden_chars" != x; then
37590     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
37591     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
37592   fi
37593 
37594     # Output is in $new_path
37595 
37596   windows_path="$new_path"
37597   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37598     unix_path=`$CYGPATH -u "$windows_path"`
37599     new_path="$unix_path"
37600   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
37601     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
37602     new_path="$unix_path"
37603   fi
37604 
37605     # remove trailing .exe if any
37606     new_path="${new_path/%.exe/}"
37607 
37608     # Save the first 10 bytes of this path to the storage, so fixpath can work.
37609     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
37610   fi
37611 
37612   else
37613     # We're on a unix platform. Hooray! :)
37614     # First separate the path from the arguments. This will split at the first
37615     # space.
37616     complete="$STRIP"
37617     path="${complete%% *}"
37618     tmp="$complete EOL"
37619     arguments="${tmp#* }"
37620 
37621     # Cannot rely on the command "which" here since it doesn't always work.
37622     is_absolute_path=`$ECHO "$path" | $GREP ^/`
37623     if test -z "$is_absolute_path"; then
37624       # Path to executable is not absolute. Find it.
37625       IFS_save="$IFS"
37626       IFS=:
37627       for p in $PATH; do
37628         if test -f "$p/$path" && test -x "$p/$path"; then
37629           new_path="$p/$path"
37630           break
37631         fi
37632       done
37633       IFS="$IFS_save"
37634     else
37635       # This is an absolute path, we can use it without further modifications.
37636       new_path="$path"
37637     fi
37638 
37639     if test "x$new_path" = x; then
37640       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5
37641 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;}
37642       has_space=`$ECHO "$complete" | $GREP " "`
37643       if test "x$has_space" != x; then
37644         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
37645 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
37646       fi
37647       as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5
37648     fi
37649   fi
37650 
37651   # Now join together the path and the arguments once again
37652   if test "x$arguments" != xEOL; then
37653     new_complete="$new_path ${arguments% *}"
37654   else
37655     new_complete="$new_path"
37656   fi
37657 
37658   if test "x$complete" != "x$new_complete"; then
37659     STRIP="$new_complete"
37660     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5
37661 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;}
37662   fi
37663 
37664 
37665 
37666   # Publish this variable in the help.
37667 
37668 
37669   if test "x$NM" = x; then
37670     # The variable is not set by user, try to locate tool using the code snippet
37671     if test -n "$ac_tool_prefix"; then
37672   for ac_prog in nm
37673   do
37674     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37675 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37677 $as_echo_n "checking for $ac_word... " >&6; }
37678 if ${ac_cv_prog_NM+:} false; then :
37679   $as_echo_n "(cached) " >&6
37680 else
37681   if test -n "$NM"; then
37682   ac_cv_prog_NM="$NM" # Let the user override the test.
37683 else
37684 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37685 for as_dir in $PATH
37686 do
37687   IFS=$as_save_IFS
37688   test -z "$as_dir" && as_dir=.
37689     for ac_exec_ext in '' $ac_executable_extensions; do
37690   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37691     ac_cv_prog_NM="$ac_tool_prefix$ac_prog"
37692     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37693     break 2
37694   fi
37695 done
37696   done
37697 IFS=$as_save_IFS
37698 
37699 fi
37700 fi
37701 NM=$ac_cv_prog_NM
37702 if test -n "$NM"; then
37703   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
37704 $as_echo "$NM" >&6; }
37705 else
37706   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37707 $as_echo "no" >&6; }
37708 fi
37709 
37710 
37711     test -n "$NM" && break
37712   done
37713 fi
37714 if test -z "$NM"; then
37715   ac_ct_NM=$NM
37716   for ac_prog in nm
37717 do
37718   # Extract the first word of "$ac_prog", so it can be a program name with args.
37719 set dummy $ac_prog; ac_word=$2
37720 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37721 $as_echo_n "checking for $ac_word... " >&6; }
37722 if ${ac_cv_prog_ac_ct_NM+:} false; then :
37723   $as_echo_n "(cached) " >&6
37724 else
37725   if test -n "$ac_ct_NM"; then
37726   ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test.
37727 else
37728 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37729 for as_dir in $PATH
37730 do
37731   IFS=$as_save_IFS
37732   test -z "$as_dir" && as_dir=.
37733     for ac_exec_ext in '' $ac_executable_extensions; do
37734   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37735     ac_cv_prog_ac_ct_NM="$ac_prog"
37736     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37737     break 2
37738   fi
37739 done
37740   done
37741 IFS=$as_save_IFS
37742 
37743 fi
37744 fi
37745 ac_ct_NM=$ac_cv_prog_ac_ct_NM
37746 if test -n "$ac_ct_NM"; then
37747   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5
37748 $as_echo "$ac_ct_NM" >&6; }
37749 else
37750   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37751 $as_echo "no" >&6; }
37752 fi
37753 
37754 
37755   test -n "$ac_ct_NM" && break
37756 done
37757 
37758   if test "x$ac_ct_NM" = x; then
37759     NM=""
37760   else
37761     case $cross_compiling:$ac_tool_warned in
37762 yes:)
37763 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37764 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37765 ac_tool_warned=yes ;;
37766 esac
37767     NM=$ac_ct_NM
37768   fi
37769 fi
37770 
37771   else
37772     # The variable is set, but is it from the command line or the environment?
37773 
37774     # Try to remove the string !NM! from our list.
37775     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/}
37776     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
37777       # If it failed, the variable was not from the command line. Ignore it,
37778       # but warn the user (except for BASH, which is always set by the calling BASH).
37779       if test "xNM" != xBASH; then
37780         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5
37781 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;}
37782       fi
37783       # Try to locate tool using the code snippet
37784       if test -n "$ac_tool_prefix"; then
37785   for ac_prog in nm
37786   do
37787     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
37788 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
37789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37790 $as_echo_n "checking for $ac_word... " >&6; }
37791 if ${ac_cv_prog_NM+:} false; then :
37792   $as_echo_n "(cached) " >&6
37793 else
37794   if test -n "$NM"; then
37795   ac_cv_prog_NM="$NM" # Let the user override the test.
37796 else
37797 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37798 for as_dir in $PATH
37799 do
37800   IFS=$as_save_IFS
37801   test -z "$as_dir" && as_dir=.
37802     for ac_exec_ext in '' $ac_executable_extensions; do
37803   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37804     ac_cv_prog_NM="$ac_tool_prefix$ac_prog"
37805     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37806     break 2
37807   fi
37808 done
37809   done
37810 IFS=$as_save_IFS
37811 
37812 fi
37813 fi
37814 NM=$ac_cv_prog_NM
37815 if test -n "$NM"; then
37816   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
37817 $as_echo "$NM" >&6; }
37818 else
37819   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37820 $as_echo "no" >&6; }
37821 fi
37822 
37823 
37824     test -n "$NM" && break
37825   done
37826 fi
37827 if test -z "$NM"; then
37828   ac_ct_NM=$NM
37829   for ac_prog in nm
37830 do
37831   # Extract the first word of "$ac_prog", so it can be a program name with args.
37832 set dummy $ac_prog; ac_word=$2
37833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37834 $as_echo_n "checking for $ac_word... " >&6; }
37835 if ${ac_cv_prog_ac_ct_NM+:} false; then :
37836   $as_echo_n "(cached) " >&6
37837 else
37838   if test -n "$ac_ct_NM"; then
37839   ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test.
37840 else
37841 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37842 for as_dir in $PATH
37843 do
37844   IFS=$as_save_IFS
37845   test -z "$as_dir" && as_dir=.
37846     for ac_exec_ext in '' $ac_executable_extensions; do
37847   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37848     ac_cv_prog_ac_ct_NM="$ac_prog"
37849     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37850     break 2
37851   fi
37852 done
37853   done
37854 IFS=$as_save_IFS
37855 
37856 fi
37857 fi
37858 ac_ct_NM=$ac_cv_prog_ac_ct_NM
37859 if test -n "$ac_ct_NM"; then
37860   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5
37861 $as_echo "$ac_ct_NM" >&6; }
37862 else
37863   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37864 $as_echo "no" >&6; }
37865 fi
37866 
37867 
37868   test -n "$ac_ct_NM" && break
37869 done
37870 
37871   if test "x$ac_ct_NM" = x; then
37872     NM=""
37873   else
37874     case $cross_compiling:$ac_tool_warned in
37875 yes:)
37876 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
37877 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
37878 ac_tool_warned=yes ;;
37879 esac
37880     NM=$ac_ct_NM
37881   fi
37882 fi
37883 
37884     else
37885       # If it succeeded, then it was overridden by the user. We will use it
37886       # for the tool.
37887 
37888       # First remove it from the list of overridden variables, so we can test
37889       # for unknown variables in the end.
37890       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
37891 
37892       # Check if the provided tool contains a complete path.
37893       tool_specified="$NM"
37894       tool_basename="${tool_specified##*/}"
37895       if test "x$tool_basename" = "x$tool_specified"; then
37896         # A command without a complete path is provided, search $PATH.
37897         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5
37898 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;}
37899         # Extract the first word of "$tool_basename", so it can be a program name with args.
37900 set dummy $tool_basename; ac_word=$2
37901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
37902 $as_echo_n "checking for $ac_word... " >&6; }
37903 if ${ac_cv_path_NM+:} false; then :
37904   $as_echo_n "(cached) " >&6
37905 else
37906   case $NM in
37907   [\\/]* | ?:[\\/]*)
37908   ac_cv_path_NM="$NM" # Let the user override the test with a path.
37909   ;;
37910   *)
37911   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
37912 for as_dir in $PATH
37913 do
37914   IFS=$as_save_IFS
37915   test -z "$as_dir" && as_dir=.
37916     for ac_exec_ext in '' $ac_executable_extensions; do
37917   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
37918     ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext"
37919     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
37920     break 2
37921   fi
37922 done
37923   done
37924 IFS=$as_save_IFS
37925 
37926   ;;
37927 esac
37928 fi
37929 NM=$ac_cv_path_NM
37930 if test -n "$NM"; then
37931   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
37932 $as_echo "$NM" >&6; }
37933 else
37934   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37935 $as_echo "no" >&6; }
37936 fi
37937 
37938 
37939         if test "x$NM" = x; then
37940           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
37941         fi
37942       else
37943         # Otherwise we believe it is a complete path. Use it as it is.
37944         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5
37945 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;}
37946         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5
37947 $as_echo_n "checking for NM... " >&6; }
37948         if test ! -x "$tool_specified"; then
37949           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
37950 $as_echo "not found" >&6; }
37951           as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5
37952         fi
37953         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
37954 $as_echo "$tool_specified" >&6; }
37955       fi
37956     fi
37957   fi
37958 
37959 
37960 
37961   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
37962 
37963   # First separate the path from the arguments. This will split at the first
37964   # space.
37965   complete="$NM"
37966   path="${complete%% *}"
37967   tmp="$complete EOL"
37968   arguments="${tmp#* }"
37969 
37970   # Input might be given as Windows format, start by converting to
37971   # unix format.
37972   new_path=`$CYGPATH -u "$path"`
37973 
37974   # Now try to locate executable using which
37975   new_path=`$WHICH "$new_path" 2> /dev/null`
37976   # bat and cmd files are not always considered executable in cygwin causing which
37977   # to not find them
37978   if test "x$new_path" = x \
37979       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37980       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37981     new_path=`$CYGPATH -u "$path"`
37982   fi
37983   if test "x$new_path" = x; then
37984     # Oops. Which didn't find the executable.
37985     # The splitting of arguments from the executable at a space might have been incorrect,
37986     # since paths with space are more likely in Windows. Give it another try with the whole
37987     # argument.
37988     path="$complete"
37989     arguments="EOL"
37990     new_path=`$CYGPATH -u "$path"`
37991     new_path=`$WHICH "$new_path" 2> /dev/null`
37992     # bat and cmd files are not always considered executable in cygwin causing which
37993     # to not find them
37994     if test "x$new_path" = x \
37995         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
37996         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
37997       new_path=`$CYGPATH -u "$path"`
37998     fi
37999     if test "x$new_path" = x; then
38000       # It's still not found. Now this is an unrecoverable error.
38001       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
38002 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
38003       has_space=`$ECHO "$complete" | $GREP " "`
38004       if test "x$has_space" != x; then
38005         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38006 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38007       fi
38008       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
38009     fi
38010   fi
38011 
38012   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
38013   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
38014   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
38015   # "foo.exe" is OK but "foo" is an error.
38016   #
38017   # This test is therefore slightly more accurate than "test -f" to check for file presence.
38018   # It is also a way to make sure we got the proper file name for the real test later on.
38019   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
38020   if test "x$test_shortpath" = x; then
38021     # Short path failed, file does not exist as specified.
38022     # Try adding .exe or .cmd
38023     if test -f "${new_path}.exe"; then
38024       input_to_shortpath="${new_path}.exe"
38025     elif test -f "${new_path}.cmd"; then
38026       input_to_shortpath="${new_path}.cmd"
38027     else
38028       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5
38029 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;}
38030       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
38031 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
38032       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
38033     fi
38034   else
38035     input_to_shortpath="$new_path"
38036   fi
38037 
38038   # Call helper function which possibly converts this using DOS-style short mode.
38039   # If so, the updated path is stored in $new_path.
38040   new_path="$input_to_shortpath"
38041 
38042   input_path="$input_to_shortpath"
38043   # Check if we need to convert this using DOS-style short mode. If the path
38044   # contains just simple characters, use it. Otherwise (spaces, weird characters),
38045   # take no chances and rewrite it.
38046   # Note: m4 eats our [], so we need to use [ and ] instead.
38047   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
38048   if test "x$has_forbidden_chars" != x; then
38049     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38050     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
38051     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
38052     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
38053       # Going to short mode and back again did indeed matter. Since short mode is
38054       # case insensitive, let's make it lowercase to improve readability.
38055       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38056       # Now convert it back to Unix-stile (cygpath)
38057       input_path=`$CYGPATH -u "$shortmode_path"`
38058       new_path="$input_path"
38059     fi
38060   fi
38061 
38062   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
38063   if test "x$test_cygdrive_prefix" = x; then
38064     # As a simple fix, exclude /usr/bin since it's not a real path.
38065     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
38066       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
38067       # a path prefixed by /cygdrive for fixpath to work.
38068       new_path="$CYGWIN_ROOT_PATH$input_path"
38069     fi
38070   fi
38071 
38072   # remove trailing .exe if any
38073   new_path="${new_path/%.exe/}"
38074 
38075   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38076 
38077   # First separate the path from the arguments. This will split at the first
38078   # space.
38079   complete="$NM"
38080   path="${complete%% *}"
38081   tmp="$complete EOL"
38082   arguments="${tmp#* }"
38083 
38084   # Input might be given as Windows format, start by converting to
38085   # unix format.
38086   new_path="$path"
38087 
38088   windows_path="$new_path"
38089   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38090     unix_path=`$CYGPATH -u "$windows_path"`
38091     new_path="$unix_path"
38092   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38093     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38094     new_path="$unix_path"
38095   fi
38096 
38097 
38098   # Now try to locate executable using which
38099   new_path=`$WHICH "$new_path" 2> /dev/null`
38100 
38101   if test "x$new_path" = x; then
38102     # Oops. Which didn't find the executable.
38103     # The splitting of arguments from the executable at a space might have been incorrect,
38104     # since paths with space are more likely in Windows. Give it another try with the whole
38105     # argument.
38106     path="$complete"
38107     arguments="EOL"
38108     new_path="$path"
38109 
38110   windows_path="$new_path"
38111   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38112     unix_path=`$CYGPATH -u "$windows_path"`
38113     new_path="$unix_path"
38114   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38115     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38116     new_path="$unix_path"
38117   fi
38118 
38119 
38120     new_path=`$WHICH "$new_path" 2> /dev/null`
38121     # bat and cmd files are not always considered executable in MSYS causing which
38122     # to not find them
38123     if test "x$new_path" = x \
38124         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38125         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38126       new_path="$path"
38127 
38128   windows_path="$new_path"
38129   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38130     unix_path=`$CYGPATH -u "$windows_path"`
38131     new_path="$unix_path"
38132   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38133     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38134     new_path="$unix_path"
38135   fi
38136 
38137     fi
38138 
38139     if test "x$new_path" = x; then
38140       # It's still not found. Now this is an unrecoverable error.
38141       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
38142 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
38143       has_space=`$ECHO "$complete" | $GREP " "`
38144       if test "x$has_space" != x; then
38145         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38146 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38147       fi
38148       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
38149     fi
38150   fi
38151 
38152   # Now new_path has a complete unix path to the binary
38153   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
38154     # Keep paths in /bin as-is, but remove trailing .exe if any
38155     new_path="${new_path/%.exe/}"
38156     # Do not save /bin paths to all_fixpath_prefixes!
38157   else
38158     # Not in mixed or Windows style, start by that.
38159     new_path=`cmd //c echo $new_path`
38160 
38161   input_path="$new_path"
38162   # Check if we need to convert this using DOS-style short mode. If the path
38163   # contains just simple characters, use it. Otherwise (spaces, weird characters),
38164   # take no chances and rewrite it.
38165   # Note: m4 eats our [], so we need to use [ and ] instead.
38166   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
38167   if test "x$has_forbidden_chars" != x; then
38168     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38169     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38170   fi
38171 
38172     # Output is in $new_path
38173 
38174   windows_path="$new_path"
38175   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38176     unix_path=`$CYGPATH -u "$windows_path"`
38177     new_path="$unix_path"
38178   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38179     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38180     new_path="$unix_path"
38181   fi
38182 
38183     # remove trailing .exe if any
38184     new_path="${new_path/%.exe/}"
38185 
38186     # Save the first 10 bytes of this path to the storage, so fixpath can work.
38187     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
38188   fi
38189 
38190   else
38191     # We're on a unix platform. Hooray! :)
38192     # First separate the path from the arguments. This will split at the first
38193     # space.
38194     complete="$NM"
38195     path="${complete%% *}"
38196     tmp="$complete EOL"
38197     arguments="${tmp#* }"
38198 
38199     # Cannot rely on the command "which" here since it doesn't always work.
38200     is_absolute_path=`$ECHO "$path" | $GREP ^/`
38201     if test -z "$is_absolute_path"; then
38202       # Path to executable is not absolute. Find it.
38203       IFS_save="$IFS"
38204       IFS=:
38205       for p in $PATH; do
38206         if test -f "$p/$path" && test -x "$p/$path"; then
38207           new_path="$p/$path"
38208           break
38209         fi
38210       done
38211       IFS="$IFS_save"
38212     else
38213       # This is an absolute path, we can use it without further modifications.
38214       new_path="$path"
38215     fi
38216 
38217     if test "x$new_path" = x; then
38218       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5
38219 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;}
38220       has_space=`$ECHO "$complete" | $GREP " "`
38221       if test "x$has_space" != x; then
38222         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
38223 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
38224       fi
38225       as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5
38226     fi
38227   fi
38228 
38229   # Now join together the path and the arguments once again
38230   if test "x$arguments" != xEOL; then
38231     new_complete="$new_path ${arguments% *}"
38232   else
38233     new_complete="$new_path"
38234   fi
38235 
38236   if test "x$complete" != "x$new_complete"; then
38237     NM="$new_complete"
38238     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5
38239 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;}
38240   fi
38241 
38242     GNM="$NM"
38243 
38244   fi
38245 
38246   # objcopy is used for moving debug symbols to separate files when
38247   # full debug symbols are enabled.
38248   if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then
38249 
38250 
38251   # Publish this variable in the help.
38252 
38253 
38254   if test "x$OBJCOPY" = x; then
38255     # The variable is not set by user, try to locate tool using the code snippet
38256     if test -n "$ac_tool_prefix"; then
38257   for ac_prog in gobjcopy objcopy
38258   do
38259     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
38260 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
38261 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38262 $as_echo_n "checking for $ac_word... " >&6; }
38263 if ${ac_cv_prog_OBJCOPY+:} false; then :
38264   $as_echo_n "(cached) " >&6
38265 else
38266   if test -n "$OBJCOPY"; then
38267   ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
38268 else
38269 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38270 for as_dir in $PATH
38271 do
38272   IFS=$as_save_IFS
38273   test -z "$as_dir" && as_dir=.
38274     for ac_exec_ext in '' $ac_executable_extensions; do
38275   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38276     ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog"
38277     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38278     break 2
38279   fi
38280 done
38281   done
38282 IFS=$as_save_IFS
38283 
38284 fi
38285 fi
38286 OBJCOPY=$ac_cv_prog_OBJCOPY
38287 if test -n "$OBJCOPY"; then
38288   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
38289 $as_echo "$OBJCOPY" >&6; }
38290 else
38291   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38292 $as_echo "no" >&6; }
38293 fi
38294 
38295 
38296     test -n "$OBJCOPY" && break
38297   done
38298 fi
38299 if test -z "$OBJCOPY"; then
38300   ac_ct_OBJCOPY=$OBJCOPY
38301   for ac_prog in gobjcopy objcopy
38302 do
38303   # Extract the first word of "$ac_prog", so it can be a program name with args.
38304 set dummy $ac_prog; ac_word=$2
38305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38306 $as_echo_n "checking for $ac_word... " >&6; }
38307 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then :
38308   $as_echo_n "(cached) " >&6
38309 else
38310   if test -n "$ac_ct_OBJCOPY"; then
38311   ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test.
38312 else
38313 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38314 for as_dir in $PATH
38315 do
38316   IFS=$as_save_IFS
38317   test -z "$as_dir" && as_dir=.
38318     for ac_exec_ext in '' $ac_executable_extensions; do
38319   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38320     ac_cv_prog_ac_ct_OBJCOPY="$ac_prog"
38321     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38322     break 2
38323   fi
38324 done
38325   done
38326 IFS=$as_save_IFS
38327 
38328 fi
38329 fi
38330 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY
38331 if test -n "$ac_ct_OBJCOPY"; then
38332   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5
38333 $as_echo "$ac_ct_OBJCOPY" >&6; }
38334 else
38335   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38336 $as_echo "no" >&6; }
38337 fi
38338 
38339 
38340   test -n "$ac_ct_OBJCOPY" && break
38341 done
38342 
38343   if test "x$ac_ct_OBJCOPY" = x; then
38344     OBJCOPY=""
38345   else
38346     case $cross_compiling:$ac_tool_warned in
38347 yes:)
38348 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
38349 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
38350 ac_tool_warned=yes ;;
38351 esac
38352     OBJCOPY=$ac_ct_OBJCOPY
38353   fi
38354 fi
38355 
38356   else
38357     # The variable is set, but is it from the command line or the environment?
38358 
38359     # Try to remove the string !OBJCOPY! from our list.
38360     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJCOPY!/}
38361     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
38362       # If it failed, the variable was not from the command line. Ignore it,
38363       # but warn the user (except for BASH, which is always set by the calling BASH).
38364       if test "xOBJCOPY" != xBASH; then
38365         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&5
38366 $as_echo "$as_me: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&2;}
38367       fi
38368       # Try to locate tool using the code snippet
38369       if test -n "$ac_tool_prefix"; then
38370   for ac_prog in gobjcopy objcopy
38371   do
38372     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
38373 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
38374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38375 $as_echo_n "checking for $ac_word... " >&6; }
38376 if ${ac_cv_prog_OBJCOPY+:} false; then :
38377   $as_echo_n "(cached) " >&6
38378 else
38379   if test -n "$OBJCOPY"; then
38380   ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
38381 else
38382 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38383 for as_dir in $PATH
38384 do
38385   IFS=$as_save_IFS
38386   test -z "$as_dir" && as_dir=.
38387     for ac_exec_ext in '' $ac_executable_extensions; do
38388   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38389     ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog"
38390     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38391     break 2
38392   fi
38393 done
38394   done
38395 IFS=$as_save_IFS
38396 
38397 fi
38398 fi
38399 OBJCOPY=$ac_cv_prog_OBJCOPY
38400 if test -n "$OBJCOPY"; then
38401   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
38402 $as_echo "$OBJCOPY" >&6; }
38403 else
38404   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38405 $as_echo "no" >&6; }
38406 fi
38407 
38408 
38409     test -n "$OBJCOPY" && break
38410   done
38411 fi
38412 if test -z "$OBJCOPY"; then
38413   ac_ct_OBJCOPY=$OBJCOPY
38414   for ac_prog in gobjcopy objcopy
38415 do
38416   # Extract the first word of "$ac_prog", so it can be a program name with args.
38417 set dummy $ac_prog; ac_word=$2
38418 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38419 $as_echo_n "checking for $ac_word... " >&6; }
38420 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then :
38421   $as_echo_n "(cached) " >&6
38422 else
38423   if test -n "$ac_ct_OBJCOPY"; then
38424   ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test.
38425 else
38426 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38427 for as_dir in $PATH
38428 do
38429   IFS=$as_save_IFS
38430   test -z "$as_dir" && as_dir=.
38431     for ac_exec_ext in '' $ac_executable_extensions; do
38432   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38433     ac_cv_prog_ac_ct_OBJCOPY="$ac_prog"
38434     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38435     break 2
38436   fi
38437 done
38438   done
38439 IFS=$as_save_IFS
38440 
38441 fi
38442 fi
38443 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY
38444 if test -n "$ac_ct_OBJCOPY"; then
38445   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5
38446 $as_echo "$ac_ct_OBJCOPY" >&6; }
38447 else
38448   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38449 $as_echo "no" >&6; }
38450 fi
38451 
38452 
38453   test -n "$ac_ct_OBJCOPY" && break
38454 done
38455 
38456   if test "x$ac_ct_OBJCOPY" = x; then
38457     OBJCOPY=""
38458   else
38459     case $cross_compiling:$ac_tool_warned in
38460 yes:)
38461 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
38462 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
38463 ac_tool_warned=yes ;;
38464 esac
38465     OBJCOPY=$ac_ct_OBJCOPY
38466   fi
38467 fi
38468 
38469     else
38470       # If it succeeded, then it was overridden by the user. We will use it
38471       # for the tool.
38472 
38473       # First remove it from the list of overridden variables, so we can test
38474       # for unknown variables in the end.
38475       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
38476 
38477       # Check if the provided tool contains a complete path.
38478       tool_specified="$OBJCOPY"
38479       tool_basename="${tool_specified##*/}"
38480       if test "x$tool_basename" = "x$tool_specified"; then
38481         # A command without a complete path is provided, search $PATH.
38482         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJCOPY=$tool_basename" >&5
38483 $as_echo "$as_me: Will search for user supplied tool OBJCOPY=$tool_basename" >&6;}
38484         # Extract the first word of "$tool_basename", so it can be a program name with args.
38485 set dummy $tool_basename; ac_word=$2
38486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38487 $as_echo_n "checking for $ac_word... " >&6; }
38488 if ${ac_cv_path_OBJCOPY+:} false; then :
38489   $as_echo_n "(cached) " >&6
38490 else
38491   case $OBJCOPY in
38492   [\\/]* | ?:[\\/]*)
38493   ac_cv_path_OBJCOPY="$OBJCOPY" # Let the user override the test with a path.
38494   ;;
38495   *)
38496   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38497 for as_dir in $PATH
38498 do
38499   IFS=$as_save_IFS
38500   test -z "$as_dir" && as_dir=.
38501     for ac_exec_ext in '' $ac_executable_extensions; do
38502   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38503     ac_cv_path_OBJCOPY="$as_dir/$ac_word$ac_exec_ext"
38504     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38505     break 2
38506   fi
38507 done
38508   done
38509 IFS=$as_save_IFS
38510 
38511   ;;
38512 esac
38513 fi
38514 OBJCOPY=$ac_cv_path_OBJCOPY
38515 if test -n "$OBJCOPY"; then
38516   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
38517 $as_echo "$OBJCOPY" >&6; }
38518 else
38519   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38520 $as_echo "no" >&6; }
38521 fi
38522 
38523 
38524         if test "x$OBJCOPY" = x; then
38525           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
38526         fi
38527       else
38528         # Otherwise we believe it is a complete path. Use it as it is.
38529         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJCOPY=$tool_specified" >&5
38530 $as_echo "$as_me: Will use user supplied tool OBJCOPY=$tool_specified" >&6;}
38531         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5
38532 $as_echo_n "checking for OBJCOPY... " >&6; }
38533         if test ! -x "$tool_specified"; then
38534           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
38535 $as_echo "not found" >&6; }
38536           as_fn_error $? "User supplied tool OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5
38537         fi
38538         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
38539 $as_echo "$tool_specified" >&6; }
38540       fi
38541     fi
38542   fi
38543 
38544 
38545     # Only call fixup if objcopy was found.
38546     if test -n "$OBJCOPY"; then
38547 
38548   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38549 
38550   # First separate the path from the arguments. This will split at the first
38551   # space.
38552   complete="$OBJCOPY"
38553   path="${complete%% *}"
38554   tmp="$complete EOL"
38555   arguments="${tmp#* }"
38556 
38557   # Input might be given as Windows format, start by converting to
38558   # unix format.
38559   new_path=`$CYGPATH -u "$path"`
38560 
38561   # Now try to locate executable using which
38562   new_path=`$WHICH "$new_path" 2> /dev/null`
38563   # bat and cmd files are not always considered executable in cygwin causing which
38564   # to not find them
38565   if test "x$new_path" = x \
38566       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38567       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38568     new_path=`$CYGPATH -u "$path"`
38569   fi
38570   if test "x$new_path" = x; then
38571     # Oops. Which didn't find the executable.
38572     # The splitting of arguments from the executable at a space might have been incorrect,
38573     # since paths with space are more likely in Windows. Give it another try with the whole
38574     # argument.
38575     path="$complete"
38576     arguments="EOL"
38577     new_path=`$CYGPATH -u "$path"`
38578     new_path=`$WHICH "$new_path" 2> /dev/null`
38579     # bat and cmd files are not always considered executable in cygwin causing which
38580     # to not find them
38581     if test "x$new_path" = x \
38582         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38583         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38584       new_path=`$CYGPATH -u "$path"`
38585     fi
38586     if test "x$new_path" = x; then
38587       # It's still not found. Now this is an unrecoverable error.
38588       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
38589 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
38590       has_space=`$ECHO "$complete" | $GREP " "`
38591       if test "x$has_space" != x; then
38592         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38593 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38594       fi
38595       as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
38596     fi
38597   fi
38598 
38599   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
38600   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
38601   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
38602   # "foo.exe" is OK but "foo" is an error.
38603   #
38604   # This test is therefore slightly more accurate than "test -f" to check for file presence.
38605   # It is also a way to make sure we got the proper file name for the real test later on.
38606   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
38607   if test "x$test_shortpath" = x; then
38608     # Short path failed, file does not exist as specified.
38609     # Try adding .exe or .cmd
38610     if test -f "${new_path}.exe"; then
38611       input_to_shortpath="${new_path}.exe"
38612     elif test -f "${new_path}.cmd"; then
38613       input_to_shortpath="${new_path}.cmd"
38614     else
38615       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&5
38616 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;}
38617       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
38618 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
38619       as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
38620     fi
38621   else
38622     input_to_shortpath="$new_path"
38623   fi
38624 
38625   # Call helper function which possibly converts this using DOS-style short mode.
38626   # If so, the updated path is stored in $new_path.
38627   new_path="$input_to_shortpath"
38628 
38629   input_path="$input_to_shortpath"
38630   # Check if we need to convert this using DOS-style short mode. If the path
38631   # contains just simple characters, use it. Otherwise (spaces, weird characters),
38632   # take no chances and rewrite it.
38633   # Note: m4 eats our [], so we need to use [ and ] instead.
38634   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
38635   if test "x$has_forbidden_chars" != x; then
38636     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38637     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
38638     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
38639     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
38640       # Going to short mode and back again did indeed matter. Since short mode is
38641       # case insensitive, let's make it lowercase to improve readability.
38642       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38643       # Now convert it back to Unix-stile (cygpath)
38644       input_path=`$CYGPATH -u "$shortmode_path"`
38645       new_path="$input_path"
38646     fi
38647   fi
38648 
38649   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
38650   if test "x$test_cygdrive_prefix" = x; then
38651     # As a simple fix, exclude /usr/bin since it's not a real path.
38652     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
38653       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
38654       # a path prefixed by /cygdrive for fixpath to work.
38655       new_path="$CYGWIN_ROOT_PATH$input_path"
38656     fi
38657   fi
38658 
38659   # remove trailing .exe if any
38660   new_path="${new_path/%.exe/}"
38661 
38662   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38663 
38664   # First separate the path from the arguments. This will split at the first
38665   # space.
38666   complete="$OBJCOPY"
38667   path="${complete%% *}"
38668   tmp="$complete EOL"
38669   arguments="${tmp#* }"
38670 
38671   # Input might be given as Windows format, start by converting to
38672   # unix format.
38673   new_path="$path"
38674 
38675   windows_path="$new_path"
38676   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38677     unix_path=`$CYGPATH -u "$windows_path"`
38678     new_path="$unix_path"
38679   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38680     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38681     new_path="$unix_path"
38682   fi
38683 
38684 
38685   # Now try to locate executable using which
38686   new_path=`$WHICH "$new_path" 2> /dev/null`
38687 
38688   if test "x$new_path" = x; then
38689     # Oops. Which didn't find the executable.
38690     # The splitting of arguments from the executable at a space might have been incorrect,
38691     # since paths with space are more likely in Windows. Give it another try with the whole
38692     # argument.
38693     path="$complete"
38694     arguments="EOL"
38695     new_path="$path"
38696 
38697   windows_path="$new_path"
38698   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38699     unix_path=`$CYGPATH -u "$windows_path"`
38700     new_path="$unix_path"
38701   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38702     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38703     new_path="$unix_path"
38704   fi
38705 
38706 
38707     new_path=`$WHICH "$new_path" 2> /dev/null`
38708     # bat and cmd files are not always considered executable in MSYS causing which
38709     # to not find them
38710     if test "x$new_path" = x \
38711         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
38712         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
38713       new_path="$path"
38714 
38715   windows_path="$new_path"
38716   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38717     unix_path=`$CYGPATH -u "$windows_path"`
38718     new_path="$unix_path"
38719   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38720     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38721     new_path="$unix_path"
38722   fi
38723 
38724     fi
38725 
38726     if test "x$new_path" = x; then
38727       # It's still not found. Now this is an unrecoverable error.
38728       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
38729 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
38730       has_space=`$ECHO "$complete" | $GREP " "`
38731       if test "x$has_space" != x; then
38732         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
38733 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
38734       fi
38735       as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
38736     fi
38737   fi
38738 
38739   # Now new_path has a complete unix path to the binary
38740   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
38741     # Keep paths in /bin as-is, but remove trailing .exe if any
38742     new_path="${new_path/%.exe/}"
38743     # Do not save /bin paths to all_fixpath_prefixes!
38744   else
38745     # Not in mixed or Windows style, start by that.
38746     new_path=`cmd //c echo $new_path`
38747 
38748   input_path="$new_path"
38749   # Check if we need to convert this using DOS-style short mode. If the path
38750   # contains just simple characters, use it. Otherwise (spaces, weird characters),
38751   # take no chances and rewrite it.
38752   # Note: m4 eats our [], so we need to use [ and ] instead.
38753   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
38754   if test "x$has_forbidden_chars" != x; then
38755     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
38756     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
38757   fi
38758 
38759     # Output is in $new_path
38760 
38761   windows_path="$new_path"
38762   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
38763     unix_path=`$CYGPATH -u "$windows_path"`
38764     new_path="$unix_path"
38765   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
38766     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
38767     new_path="$unix_path"
38768   fi
38769 
38770     # remove trailing .exe if any
38771     new_path="${new_path/%.exe/}"
38772 
38773     # Save the first 10 bytes of this path to the storage, so fixpath can work.
38774     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
38775   fi
38776 
38777   else
38778     # We're on a unix platform. Hooray! :)
38779     # First separate the path from the arguments. This will split at the first
38780     # space.
38781     complete="$OBJCOPY"
38782     path="${complete%% *}"
38783     tmp="$complete EOL"
38784     arguments="${tmp#* }"
38785 
38786     # Cannot rely on the command "which" here since it doesn't always work.
38787     is_absolute_path=`$ECHO "$path" | $GREP ^/`
38788     if test -z "$is_absolute_path"; then
38789       # Path to executable is not absolute. Find it.
38790       IFS_save="$IFS"
38791       IFS=:
38792       for p in $PATH; do
38793         if test -f "$p/$path" && test -x "$p/$path"; then
38794           new_path="$p/$path"
38795           break
38796         fi
38797       done
38798       IFS="$IFS_save"
38799     else
38800       # This is an absolute path, we can use it without further modifications.
38801       new_path="$path"
38802     fi
38803 
38804     if test "x$new_path" = x; then
38805       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5
38806 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;}
38807       has_space=`$ECHO "$complete" | $GREP " "`
38808       if test "x$has_space" != x; then
38809         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
38810 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
38811       fi
38812       as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5
38813     fi
38814   fi
38815 
38816   # Now join together the path and the arguments once again
38817   if test "x$arguments" != xEOL; then
38818     new_complete="$new_path ${arguments% *}"
38819   else
38820     new_complete="$new_path"
38821   fi
38822 
38823   if test "x$complete" != "x$new_complete"; then
38824     OBJCOPY="$new_complete"
38825     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJCOPY to \"$new_complete\"" >&5
38826 $as_echo "$as_me: Rewriting OBJCOPY to \"$new_complete\"" >&6;}
38827   fi
38828 
38829     fi
38830   fi
38831 
38832 
38833 
38834   # Publish this variable in the help.
38835 
38836 
38837   if test "x$OBJDUMP" = x; then
38838     # The variable is not set by user, try to locate tool using the code snippet
38839     if test -n "$ac_tool_prefix"; then
38840   for ac_prog in gobjdump objdump
38841   do
38842     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
38843 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
38844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38845 $as_echo_n "checking for $ac_word... " >&6; }
38846 if ${ac_cv_prog_OBJDUMP+:} false; then :
38847   $as_echo_n "(cached) " >&6
38848 else
38849   if test -n "$OBJDUMP"; then
38850   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
38851 else
38852 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38853 for as_dir in $PATH
38854 do
38855   IFS=$as_save_IFS
38856   test -z "$as_dir" && as_dir=.
38857     for ac_exec_ext in '' $ac_executable_extensions; do
38858   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38859     ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog"
38860     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38861     break 2
38862   fi
38863 done
38864   done
38865 IFS=$as_save_IFS
38866 
38867 fi
38868 fi
38869 OBJDUMP=$ac_cv_prog_OBJDUMP
38870 if test -n "$OBJDUMP"; then
38871   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
38872 $as_echo "$OBJDUMP" >&6; }
38873 else
38874   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38875 $as_echo "no" >&6; }
38876 fi
38877 
38878 
38879     test -n "$OBJDUMP" && break
38880   done
38881 fi
38882 if test -z "$OBJDUMP"; then
38883   ac_ct_OBJDUMP=$OBJDUMP
38884   for ac_prog in gobjdump objdump
38885 do
38886   # Extract the first word of "$ac_prog", so it can be a program name with args.
38887 set dummy $ac_prog; ac_word=$2
38888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38889 $as_echo_n "checking for $ac_word... " >&6; }
38890 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
38891   $as_echo_n "(cached) " >&6
38892 else
38893   if test -n "$ac_ct_OBJDUMP"; then
38894   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
38895 else
38896 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38897 for as_dir in $PATH
38898 do
38899   IFS=$as_save_IFS
38900   test -z "$as_dir" && as_dir=.
38901     for ac_exec_ext in '' $ac_executable_extensions; do
38902   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38903     ac_cv_prog_ac_ct_OBJDUMP="$ac_prog"
38904     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38905     break 2
38906   fi
38907 done
38908   done
38909 IFS=$as_save_IFS
38910 
38911 fi
38912 fi
38913 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
38914 if test -n "$ac_ct_OBJDUMP"; then
38915   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
38916 $as_echo "$ac_ct_OBJDUMP" >&6; }
38917 else
38918   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38919 $as_echo "no" >&6; }
38920 fi
38921 
38922 
38923   test -n "$ac_ct_OBJDUMP" && break
38924 done
38925 
38926   if test "x$ac_ct_OBJDUMP" = x; then
38927     OBJDUMP=""
38928   else
38929     case $cross_compiling:$ac_tool_warned in
38930 yes:)
38931 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
38932 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
38933 ac_tool_warned=yes ;;
38934 esac
38935     OBJDUMP=$ac_ct_OBJDUMP
38936   fi
38937 fi
38938 
38939   else
38940     # The variable is set, but is it from the command line or the environment?
38941 
38942     # Try to remove the string !OBJDUMP! from our list.
38943     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJDUMP!/}
38944     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
38945       # If it failed, the variable was not from the command line. Ignore it,
38946       # but warn the user (except for BASH, which is always set by the calling BASH).
38947       if test "xOBJDUMP" != xBASH; then
38948         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&5
38949 $as_echo "$as_me: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&2;}
38950       fi
38951       # Try to locate tool using the code snippet
38952       if test -n "$ac_tool_prefix"; then
38953   for ac_prog in gobjdump objdump
38954   do
38955     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
38956 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
38957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
38958 $as_echo_n "checking for $ac_word... " >&6; }
38959 if ${ac_cv_prog_OBJDUMP+:} false; then :
38960   $as_echo_n "(cached) " >&6
38961 else
38962   if test -n "$OBJDUMP"; then
38963   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
38964 else
38965 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
38966 for as_dir in $PATH
38967 do
38968   IFS=$as_save_IFS
38969   test -z "$as_dir" && as_dir=.
38970     for ac_exec_ext in '' $ac_executable_extensions; do
38971   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
38972     ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog"
38973     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
38974     break 2
38975   fi
38976 done
38977   done
38978 IFS=$as_save_IFS
38979 
38980 fi
38981 fi
38982 OBJDUMP=$ac_cv_prog_OBJDUMP
38983 if test -n "$OBJDUMP"; then
38984   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
38985 $as_echo "$OBJDUMP" >&6; }
38986 else
38987   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38988 $as_echo "no" >&6; }
38989 fi
38990 
38991 
38992     test -n "$OBJDUMP" && break
38993   done
38994 fi
38995 if test -z "$OBJDUMP"; then
38996   ac_ct_OBJDUMP=$OBJDUMP
38997   for ac_prog in gobjdump objdump
38998 do
38999   # Extract the first word of "$ac_prog", so it can be a program name with args.
39000 set dummy $ac_prog; ac_word=$2
39001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39002 $as_echo_n "checking for $ac_word... " >&6; }
39003 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
39004   $as_echo_n "(cached) " >&6
39005 else
39006   if test -n "$ac_ct_OBJDUMP"; then
39007   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
39008 else
39009 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39010 for as_dir in $PATH
39011 do
39012   IFS=$as_save_IFS
39013   test -z "$as_dir" && as_dir=.
39014     for ac_exec_ext in '' $ac_executable_extensions; do
39015   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39016     ac_cv_prog_ac_ct_OBJDUMP="$ac_prog"
39017     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39018     break 2
39019   fi
39020 done
39021   done
39022 IFS=$as_save_IFS
39023 
39024 fi
39025 fi
39026 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
39027 if test -n "$ac_ct_OBJDUMP"; then
39028   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
39029 $as_echo "$ac_ct_OBJDUMP" >&6; }
39030 else
39031   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39032 $as_echo "no" >&6; }
39033 fi
39034 
39035 
39036   test -n "$ac_ct_OBJDUMP" && break
39037 done
39038 
39039   if test "x$ac_ct_OBJDUMP" = x; then
39040     OBJDUMP=""
39041   else
39042     case $cross_compiling:$ac_tool_warned in
39043 yes:)
39044 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
39045 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
39046 ac_tool_warned=yes ;;
39047 esac
39048     OBJDUMP=$ac_ct_OBJDUMP
39049   fi
39050 fi
39051 
39052     else
39053       # If it succeeded, then it was overridden by the user. We will use it
39054       # for the tool.
39055 
39056       # First remove it from the list of overridden variables, so we can test
39057       # for unknown variables in the end.
39058       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
39059 
39060       # Check if the provided tool contains a complete path.
39061       tool_specified="$OBJDUMP"
39062       tool_basename="${tool_specified##*/}"
39063       if test "x$tool_basename" = "x$tool_specified"; then
39064         # A command without a complete path is provided, search $PATH.
39065         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJDUMP=$tool_basename" >&5
39066 $as_echo "$as_me: Will search for user supplied tool OBJDUMP=$tool_basename" >&6;}
39067         # Extract the first word of "$tool_basename", so it can be a program name with args.
39068 set dummy $tool_basename; ac_word=$2
39069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39070 $as_echo_n "checking for $ac_word... " >&6; }
39071 if ${ac_cv_path_OBJDUMP+:} false; then :
39072   $as_echo_n "(cached) " >&6
39073 else
39074   case $OBJDUMP in
39075   [\\/]* | ?:[\\/]*)
39076   ac_cv_path_OBJDUMP="$OBJDUMP" # Let the user override the test with a path.
39077   ;;
39078   *)
39079   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39080 for as_dir in $PATH
39081 do
39082   IFS=$as_save_IFS
39083   test -z "$as_dir" && as_dir=.
39084     for ac_exec_ext in '' $ac_executable_extensions; do
39085   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39086     ac_cv_path_OBJDUMP="$as_dir/$ac_word$ac_exec_ext"
39087     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39088     break 2
39089   fi
39090 done
39091   done
39092 IFS=$as_save_IFS
39093 
39094   ;;
39095 esac
39096 fi
39097 OBJDUMP=$ac_cv_path_OBJDUMP
39098 if test -n "$OBJDUMP"; then
39099   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
39100 $as_echo "$OBJDUMP" >&6; }
39101 else
39102   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39103 $as_echo "no" >&6; }
39104 fi
39105 
39106 
39107         if test "x$OBJDUMP" = x; then
39108           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
39109         fi
39110       else
39111         # Otherwise we believe it is a complete path. Use it as it is.
39112         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJDUMP=$tool_specified" >&5
39113 $as_echo "$as_me: Will use user supplied tool OBJDUMP=$tool_specified" >&6;}
39114         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5
39115 $as_echo_n "checking for OBJDUMP... " >&6; }
39116         if test ! -x "$tool_specified"; then
39117           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
39118 $as_echo "not found" >&6; }
39119           as_fn_error $? "User supplied tool OBJDUMP=$tool_specified does not exist or is not executable" "$LINENO" 5
39120         fi
39121         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
39122 $as_echo "$tool_specified" >&6; }
39123       fi
39124     fi
39125   fi
39126 
39127 
39128   if test "x$OBJDUMP" != x; then
39129     # Only used for compare.sh; we can live without it. BASIC_FIXUP_EXECUTABLE
39130     # bails if argument is missing.
39131 
39132   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39133 
39134   # First separate the path from the arguments. This will split at the first
39135   # space.
39136   complete="$OBJDUMP"
39137   path="${complete%% *}"
39138   tmp="$complete EOL"
39139   arguments="${tmp#* }"
39140 
39141   # Input might be given as Windows format, start by converting to
39142   # unix format.
39143   new_path=`$CYGPATH -u "$path"`
39144 
39145   # Now try to locate executable using which
39146   new_path=`$WHICH "$new_path" 2> /dev/null`
39147   # bat and cmd files are not always considered executable in cygwin causing which
39148   # to not find them
39149   if test "x$new_path" = x \
39150       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39151       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39152     new_path=`$CYGPATH -u "$path"`
39153   fi
39154   if test "x$new_path" = x; then
39155     # Oops. Which didn't find the executable.
39156     # The splitting of arguments from the executable at a space might have been incorrect,
39157     # since paths with space are more likely in Windows. Give it another try with the whole
39158     # argument.
39159     path="$complete"
39160     arguments="EOL"
39161     new_path=`$CYGPATH -u "$path"`
39162     new_path=`$WHICH "$new_path" 2> /dev/null`
39163     # bat and cmd files are not always considered executable in cygwin causing which
39164     # to not find them
39165     if test "x$new_path" = x \
39166         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39167         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39168       new_path=`$CYGPATH -u "$path"`
39169     fi
39170     if test "x$new_path" = x; then
39171       # It's still not found. Now this is an unrecoverable error.
39172       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
39173 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
39174       has_space=`$ECHO "$complete" | $GREP " "`
39175       if test "x$has_space" != x; then
39176         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39177 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39178       fi
39179       as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
39180     fi
39181   fi
39182 
39183   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
39184   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
39185   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
39186   # "foo.exe" is OK but "foo" is an error.
39187   #
39188   # This test is therefore slightly more accurate than "test -f" to check for file presence.
39189   # It is also a way to make sure we got the proper file name for the real test later on.
39190   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
39191   if test "x$test_shortpath" = x; then
39192     # Short path failed, file does not exist as specified.
39193     # Try adding .exe or .cmd
39194     if test -f "${new_path}.exe"; then
39195       input_to_shortpath="${new_path}.exe"
39196     elif test -f "${new_path}.cmd"; then
39197       input_to_shortpath="${new_path}.cmd"
39198     else
39199       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&5
39200 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&6;}
39201       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
39202 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
39203       as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
39204     fi
39205   else
39206     input_to_shortpath="$new_path"
39207   fi
39208 
39209   # Call helper function which possibly converts this using DOS-style short mode.
39210   # If so, the updated path is stored in $new_path.
39211   new_path="$input_to_shortpath"
39212 
39213   input_path="$input_to_shortpath"
39214   # Check if we need to convert this using DOS-style short mode. If the path
39215   # contains just simple characters, use it. Otherwise (spaces, weird characters),
39216   # take no chances and rewrite it.
39217   # Note: m4 eats our [], so we need to use [ and ] instead.
39218   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
39219   if test "x$has_forbidden_chars" != x; then
39220     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39221     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
39222     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
39223     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
39224       # Going to short mode and back again did indeed matter. Since short mode is
39225       # case insensitive, let's make it lowercase to improve readability.
39226       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39227       # Now convert it back to Unix-stile (cygpath)
39228       input_path=`$CYGPATH -u "$shortmode_path"`
39229       new_path="$input_path"
39230     fi
39231   fi
39232 
39233   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
39234   if test "x$test_cygdrive_prefix" = x; then
39235     # As a simple fix, exclude /usr/bin since it's not a real path.
39236     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
39237       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
39238       # a path prefixed by /cygdrive for fixpath to work.
39239       new_path="$CYGWIN_ROOT_PATH$input_path"
39240     fi
39241   fi
39242 
39243   # remove trailing .exe if any
39244   new_path="${new_path/%.exe/}"
39245 
39246   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39247 
39248   # First separate the path from the arguments. This will split at the first
39249   # space.
39250   complete="$OBJDUMP"
39251   path="${complete%% *}"
39252   tmp="$complete EOL"
39253   arguments="${tmp#* }"
39254 
39255   # Input might be given as Windows format, start by converting to
39256   # unix format.
39257   new_path="$path"
39258 
39259   windows_path="$new_path"
39260   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39261     unix_path=`$CYGPATH -u "$windows_path"`
39262     new_path="$unix_path"
39263   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39264     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39265     new_path="$unix_path"
39266   fi
39267 
39268 
39269   # Now try to locate executable using which
39270   new_path=`$WHICH "$new_path" 2> /dev/null`
39271 
39272   if test "x$new_path" = x; then
39273     # Oops. Which didn't find the executable.
39274     # The splitting of arguments from the executable at a space might have been incorrect,
39275     # since paths with space are more likely in Windows. Give it another try with the whole
39276     # argument.
39277     path="$complete"
39278     arguments="EOL"
39279     new_path="$path"
39280 
39281   windows_path="$new_path"
39282   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39283     unix_path=`$CYGPATH -u "$windows_path"`
39284     new_path="$unix_path"
39285   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39286     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39287     new_path="$unix_path"
39288   fi
39289 
39290 
39291     new_path=`$WHICH "$new_path" 2> /dev/null`
39292     # bat and cmd files are not always considered executable in MSYS causing which
39293     # to not find them
39294     if test "x$new_path" = x \
39295         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39296         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39297       new_path="$path"
39298 
39299   windows_path="$new_path"
39300   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39301     unix_path=`$CYGPATH -u "$windows_path"`
39302     new_path="$unix_path"
39303   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39304     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39305     new_path="$unix_path"
39306   fi
39307 
39308     fi
39309 
39310     if test "x$new_path" = x; then
39311       # It's still not found. Now this is an unrecoverable error.
39312       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
39313 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
39314       has_space=`$ECHO "$complete" | $GREP " "`
39315       if test "x$has_space" != x; then
39316         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39317 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39318       fi
39319       as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
39320     fi
39321   fi
39322 
39323   # Now new_path has a complete unix path to the binary
39324   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
39325     # Keep paths in /bin as-is, but remove trailing .exe if any
39326     new_path="${new_path/%.exe/}"
39327     # Do not save /bin paths to all_fixpath_prefixes!
39328   else
39329     # Not in mixed or Windows style, start by that.
39330     new_path=`cmd //c echo $new_path`
39331 
39332   input_path="$new_path"
39333   # Check if we need to convert this using DOS-style short mode. If the path
39334   # contains just simple characters, use it. Otherwise (spaces, weird characters),
39335   # take no chances and rewrite it.
39336   # Note: m4 eats our [], so we need to use [ and ] instead.
39337   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
39338   if test "x$has_forbidden_chars" != x; then
39339     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39340     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39341   fi
39342 
39343     # Output is in $new_path
39344 
39345   windows_path="$new_path"
39346   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39347     unix_path=`$CYGPATH -u "$windows_path"`
39348     new_path="$unix_path"
39349   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39350     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39351     new_path="$unix_path"
39352   fi
39353 
39354     # remove trailing .exe if any
39355     new_path="${new_path/%.exe/}"
39356 
39357     # Save the first 10 bytes of this path to the storage, so fixpath can work.
39358     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
39359   fi
39360 
39361   else
39362     # We're on a unix platform. Hooray! :)
39363     # First separate the path from the arguments. This will split at the first
39364     # space.
39365     complete="$OBJDUMP"
39366     path="${complete%% *}"
39367     tmp="$complete EOL"
39368     arguments="${tmp#* }"
39369 
39370     # Cannot rely on the command "which" here since it doesn't always work.
39371     is_absolute_path=`$ECHO "$path" | $GREP ^/`
39372     if test -z "$is_absolute_path"; then
39373       # Path to executable is not absolute. Find it.
39374       IFS_save="$IFS"
39375       IFS=:
39376       for p in $PATH; do
39377         if test -f "$p/$path" && test -x "$p/$path"; then
39378           new_path="$p/$path"
39379           break
39380         fi
39381       done
39382       IFS="$IFS_save"
39383     else
39384       # This is an absolute path, we can use it without further modifications.
39385       new_path="$path"
39386     fi
39387 
39388     if test "x$new_path" = x; then
39389       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5
39390 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;}
39391       has_space=`$ECHO "$complete" | $GREP " "`
39392       if test "x$has_space" != x; then
39393         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
39394 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
39395       fi
39396       as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5
39397     fi
39398   fi
39399 
39400   # Now join together the path and the arguments once again
39401   if test "x$arguments" != xEOL; then
39402     new_complete="$new_path ${arguments% *}"
39403   else
39404     new_complete="$new_path"
39405   fi
39406 
39407   if test "x$complete" != "x$new_complete"; then
39408     OBJDUMP="$new_complete"
39409     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJDUMP to \"$new_complete\"" >&5
39410 $as_echo "$as_me: Rewriting OBJDUMP to \"$new_complete\"" >&6;}
39411   fi
39412 
39413   fi
39414 
39415 
39416   # Restore old path.
39417   PATH="$OLD_PATH"
39418 
39419   # Restore the flags to the user specified values.
39420   # This is necessary since AC_PROG_CC defaults CFLAGS to "-g -O2"
39421   CFLAGS="$ORG_CFLAGS"
39422   CXXFLAGS="$ORG_CXXFLAGS"
39423   OBJCFLAGS="$ORG_OBJCFLAGS"
39424 
39425 
39426 # Finally do some processing after the detection phase
39427 
39428   if test "x$COMPILE_TYPE" = "xcross"; then
39429     # Now we need to find a C/C++ compiler that can build executables for the
39430     # build platform. We can't use the AC_PROG_CC macro, since it can only be
39431     # used once. Also, we need to do this without adding a tools dir to the
39432     # path, otherwise we might pick up cross-compilers which don't use standard
39433     # naming.
39434 
39435     # FIXME: we should list the discovered compilers as an exclude pattern!
39436     # If we do that, we can do this detection before POST_DETECTION, and still
39437     # find the build compilers in the tools dir, if needed.
39438 
39439 
39440   # Publish this variable in the help.
39441 
39442 
39443   if test "x$BUILD_CC" = x; then
39444     # The variable is not set by user, try to locate tool using the code snippet
39445     for ac_prog in cl cc gcc
39446 do
39447   # Extract the first word of "$ac_prog", so it can be a program name with args.
39448 set dummy $ac_prog; ac_word=$2
39449 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39450 $as_echo_n "checking for $ac_word... " >&6; }
39451 if ${ac_cv_path_BUILD_CC+:} false; then :
39452   $as_echo_n "(cached) " >&6
39453 else
39454   case $BUILD_CC in
39455   [\\/]* | ?:[\\/]*)
39456   ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
39457   ;;
39458   *)
39459   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39460 for as_dir in $PATH
39461 do
39462   IFS=$as_save_IFS
39463   test -z "$as_dir" && as_dir=.
39464     for ac_exec_ext in '' $ac_executable_extensions; do
39465   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39466     ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
39467     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39468     break 2
39469   fi
39470 done
39471   done
39472 IFS=$as_save_IFS
39473 
39474   ;;
39475 esac
39476 fi
39477 BUILD_CC=$ac_cv_path_BUILD_CC
39478 if test -n "$BUILD_CC"; then
39479   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
39480 $as_echo "$BUILD_CC" >&6; }
39481 else
39482   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39483 $as_echo "no" >&6; }
39484 fi
39485 
39486 
39487   test -n "$BUILD_CC" && break
39488 done
39489 
39490   else
39491     # The variable is set, but is it from the command line or the environment?
39492 
39493     # Try to remove the string !BUILD_CC! from our list.
39494     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CC!/}
39495     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
39496       # If it failed, the variable was not from the command line. Ignore it,
39497       # but warn the user (except for BASH, which is always set by the calling BASH).
39498       if test "xBUILD_CC" != xBASH; then
39499         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&5
39500 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&2;}
39501       fi
39502       # Try to locate tool using the code snippet
39503       for ac_prog in cl cc gcc
39504 do
39505   # Extract the first word of "$ac_prog", so it can be a program name with args.
39506 set dummy $ac_prog; ac_word=$2
39507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39508 $as_echo_n "checking for $ac_word... " >&6; }
39509 if ${ac_cv_path_BUILD_CC+:} false; then :
39510   $as_echo_n "(cached) " >&6
39511 else
39512   case $BUILD_CC in
39513   [\\/]* | ?:[\\/]*)
39514   ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
39515   ;;
39516   *)
39517   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39518 for as_dir in $PATH
39519 do
39520   IFS=$as_save_IFS
39521   test -z "$as_dir" && as_dir=.
39522     for ac_exec_ext in '' $ac_executable_extensions; do
39523   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39524     ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
39525     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39526     break 2
39527   fi
39528 done
39529   done
39530 IFS=$as_save_IFS
39531 
39532   ;;
39533 esac
39534 fi
39535 BUILD_CC=$ac_cv_path_BUILD_CC
39536 if test -n "$BUILD_CC"; then
39537   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
39538 $as_echo "$BUILD_CC" >&6; }
39539 else
39540   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39541 $as_echo "no" >&6; }
39542 fi
39543 
39544 
39545   test -n "$BUILD_CC" && break
39546 done
39547 
39548     else
39549       # If it succeeded, then it was overridden by the user. We will use it
39550       # for the tool.
39551 
39552       # First remove it from the list of overridden variables, so we can test
39553       # for unknown variables in the end.
39554       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
39555 
39556       # Check if the provided tool contains a complete path.
39557       tool_specified="$BUILD_CC"
39558       tool_basename="${tool_specified##*/}"
39559       if test "x$tool_basename" = "x$tool_specified"; then
39560         # A command without a complete path is provided, search $PATH.
39561         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CC=$tool_basename" >&5
39562 $as_echo "$as_me: Will search for user supplied tool BUILD_CC=$tool_basename" >&6;}
39563         # Extract the first word of "$tool_basename", so it can be a program name with args.
39564 set dummy $tool_basename; ac_word=$2
39565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39566 $as_echo_n "checking for $ac_word... " >&6; }
39567 if ${ac_cv_path_BUILD_CC+:} false; then :
39568   $as_echo_n "(cached) " >&6
39569 else
39570   case $BUILD_CC in
39571   [\\/]* | ?:[\\/]*)
39572   ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path.
39573   ;;
39574   *)
39575   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39576 for as_dir in $PATH
39577 do
39578   IFS=$as_save_IFS
39579   test -z "$as_dir" && as_dir=.
39580     for ac_exec_ext in '' $ac_executable_extensions; do
39581   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39582     ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext"
39583     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39584     break 2
39585   fi
39586 done
39587   done
39588 IFS=$as_save_IFS
39589 
39590   ;;
39591 esac
39592 fi
39593 BUILD_CC=$ac_cv_path_BUILD_CC
39594 if test -n "$BUILD_CC"; then
39595   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5
39596 $as_echo "$BUILD_CC" >&6; }
39597 else
39598   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39599 $as_echo "no" >&6; }
39600 fi
39601 
39602 
39603         if test "x$BUILD_CC" = x; then
39604           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
39605         fi
39606       else
39607         # Otherwise we believe it is a complete path. Use it as it is.
39608         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CC=$tool_specified" >&5
39609 $as_echo "$as_me: Will use user supplied tool BUILD_CC=$tool_specified" >&6;}
39610         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5
39611 $as_echo_n "checking for BUILD_CC... " >&6; }
39612         if test ! -x "$tool_specified"; then
39613           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
39614 $as_echo "not found" >&6; }
39615           as_fn_error $? "User supplied tool BUILD_CC=$tool_specified does not exist or is not executable" "$LINENO" 5
39616         fi
39617         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
39618 $as_echo "$tool_specified" >&6; }
39619       fi
39620     fi
39621   fi
39622 
39623 
39624 
39625   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39626 
39627   # First separate the path from the arguments. This will split at the first
39628   # space.
39629   complete="$BUILD_CC"
39630   path="${complete%% *}"
39631   tmp="$complete EOL"
39632   arguments="${tmp#* }"
39633 
39634   # Input might be given as Windows format, start by converting to
39635   # unix format.
39636   new_path=`$CYGPATH -u "$path"`
39637 
39638   # Now try to locate executable using which
39639   new_path=`$WHICH "$new_path" 2> /dev/null`
39640   # bat and cmd files are not always considered executable in cygwin causing which
39641   # to not find them
39642   if test "x$new_path" = x \
39643       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39644       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39645     new_path=`$CYGPATH -u "$path"`
39646   fi
39647   if test "x$new_path" = x; then
39648     # Oops. Which didn't find the executable.
39649     # The splitting of arguments from the executable at a space might have been incorrect,
39650     # since paths with space are more likely in Windows. Give it another try with the whole
39651     # argument.
39652     path="$complete"
39653     arguments="EOL"
39654     new_path=`$CYGPATH -u "$path"`
39655     new_path=`$WHICH "$new_path" 2> /dev/null`
39656     # bat and cmd files are not always considered executable in cygwin causing which
39657     # to not find them
39658     if test "x$new_path" = x \
39659         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39660         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
39661       new_path=`$CYGPATH -u "$path"`
39662     fi
39663     if test "x$new_path" = x; then
39664       # It's still not found. Now this is an unrecoverable error.
39665       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
39666 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
39667       has_space=`$ECHO "$complete" | $GREP " "`
39668       if test "x$has_space" != x; then
39669         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39670 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39671       fi
39672       as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
39673     fi
39674   fi
39675 
39676   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
39677   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
39678   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
39679   # "foo.exe" is OK but "foo" is an error.
39680   #
39681   # This test is therefore slightly more accurate than "test -f" to check for file presence.
39682   # It is also a way to make sure we got the proper file name for the real test later on.
39683   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
39684   if test "x$test_shortpath" = x; then
39685     # Short path failed, file does not exist as specified.
39686     # Try adding .exe or .cmd
39687     if test -f "${new_path}.exe"; then
39688       input_to_shortpath="${new_path}.exe"
39689     elif test -f "${new_path}.cmd"; then
39690       input_to_shortpath="${new_path}.cmd"
39691     else
39692       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&5
39693 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&6;}
39694       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
39695 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
39696       as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
39697     fi
39698   else
39699     input_to_shortpath="$new_path"
39700   fi
39701 
39702   # Call helper function which possibly converts this using DOS-style short mode.
39703   # If so, the updated path is stored in $new_path.
39704   new_path="$input_to_shortpath"
39705 
39706   input_path="$input_to_shortpath"
39707   # Check if we need to convert this using DOS-style short mode. If the path
39708   # contains just simple characters, use it. Otherwise (spaces, weird characters),
39709   # take no chances and rewrite it.
39710   # Note: m4 eats our [], so we need to use [ and ] instead.
39711   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
39712   if test "x$has_forbidden_chars" != x; then
39713     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39714     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
39715     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
39716     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
39717       # Going to short mode and back again did indeed matter. Since short mode is
39718       # case insensitive, let's make it lowercase to improve readability.
39719       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39720       # Now convert it back to Unix-stile (cygpath)
39721       input_path=`$CYGPATH -u "$shortmode_path"`
39722       new_path="$input_path"
39723     fi
39724   fi
39725 
39726   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
39727   if test "x$test_cygdrive_prefix" = x; then
39728     # As a simple fix, exclude /usr/bin since it's not a real path.
39729     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
39730       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
39731       # a path prefixed by /cygdrive for fixpath to work.
39732       new_path="$CYGWIN_ROOT_PATH$input_path"
39733     fi
39734   fi
39735 
39736   # remove trailing .exe if any
39737   new_path="${new_path/%.exe/}"
39738 
39739   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39740 
39741   # First separate the path from the arguments. This will split at the first
39742   # space.
39743   complete="$BUILD_CC"
39744   path="${complete%% *}"
39745   tmp="$complete EOL"
39746   arguments="${tmp#* }"
39747 
39748   # Input might be given as Windows format, start by converting to
39749   # unix format.
39750   new_path="$path"
39751 
39752   windows_path="$new_path"
39753   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39754     unix_path=`$CYGPATH -u "$windows_path"`
39755     new_path="$unix_path"
39756   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39757     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39758     new_path="$unix_path"
39759   fi
39760 
39761 
39762   # Now try to locate executable using which
39763   new_path=`$WHICH "$new_path" 2> /dev/null`
39764 
39765   if test "x$new_path" = x; then
39766     # Oops. Which didn't find the executable.
39767     # The splitting of arguments from the executable at a space might have been incorrect,
39768     # since paths with space are more likely in Windows. Give it another try with the whole
39769     # argument.
39770     path="$complete"
39771     arguments="EOL"
39772     new_path="$path"
39773 
39774   windows_path="$new_path"
39775   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39776     unix_path=`$CYGPATH -u "$windows_path"`
39777     new_path="$unix_path"
39778   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39779     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39780     new_path="$unix_path"
39781   fi
39782 
39783 
39784     new_path=`$WHICH "$new_path" 2> /dev/null`
39785     # bat and cmd files are not always considered executable in MSYS causing which
39786     # to not find them
39787     if test "x$new_path" = x \
39788         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
39789         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
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     fi
39802 
39803     if test "x$new_path" = x; then
39804       # It's still not found. Now this is an unrecoverable error.
39805       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
39806 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
39807       has_space=`$ECHO "$complete" | $GREP " "`
39808       if test "x$has_space" != x; then
39809         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
39810 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
39811       fi
39812       as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
39813     fi
39814   fi
39815 
39816   # Now new_path has a complete unix path to the binary
39817   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
39818     # Keep paths in /bin as-is, but remove trailing .exe if any
39819     new_path="${new_path/%.exe/}"
39820     # Do not save /bin paths to all_fixpath_prefixes!
39821   else
39822     # Not in mixed or Windows style, start by that.
39823     new_path=`cmd //c echo $new_path`
39824 
39825   input_path="$new_path"
39826   # Check if we need to convert this using DOS-style short mode. If the path
39827   # contains just simple characters, use it. Otherwise (spaces, weird characters),
39828   # take no chances and rewrite it.
39829   # Note: m4 eats our [], so we need to use [ and ] instead.
39830   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
39831   if test "x$has_forbidden_chars" != x; then
39832     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
39833     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
39834   fi
39835 
39836     # Output is in $new_path
39837 
39838   windows_path="$new_path"
39839   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
39840     unix_path=`$CYGPATH -u "$windows_path"`
39841     new_path="$unix_path"
39842   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
39843     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
39844     new_path="$unix_path"
39845   fi
39846 
39847     # remove trailing .exe if any
39848     new_path="${new_path/%.exe/}"
39849 
39850     # Save the first 10 bytes of this path to the storage, so fixpath can work.
39851     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
39852   fi
39853 
39854   else
39855     # We're on a unix platform. Hooray! :)
39856     # First separate the path from the arguments. This will split at the first
39857     # space.
39858     complete="$BUILD_CC"
39859     path="${complete%% *}"
39860     tmp="$complete EOL"
39861     arguments="${tmp#* }"
39862 
39863     # Cannot rely on the command "which" here since it doesn't always work.
39864     is_absolute_path=`$ECHO "$path" | $GREP ^/`
39865     if test -z "$is_absolute_path"; then
39866       # Path to executable is not absolute. Find it.
39867       IFS_save="$IFS"
39868       IFS=:
39869       for p in $PATH; do
39870         if test -f "$p/$path" && test -x "$p/$path"; then
39871           new_path="$p/$path"
39872           break
39873         fi
39874       done
39875       IFS="$IFS_save"
39876     else
39877       # This is an absolute path, we can use it without further modifications.
39878       new_path="$path"
39879     fi
39880 
39881     if test "x$new_path" = x; then
39882       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5
39883 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;}
39884       has_space=`$ECHO "$complete" | $GREP " "`
39885       if test "x$has_space" != x; then
39886         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
39887 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
39888       fi
39889       as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5
39890     fi
39891   fi
39892 
39893   # Now join together the path and the arguments once again
39894   if test "x$arguments" != xEOL; then
39895     new_complete="$new_path ${arguments% *}"
39896   else
39897     new_complete="$new_path"
39898   fi
39899 
39900   if test "x$complete" != "x$new_complete"; then
39901     BUILD_CC="$new_complete"
39902     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CC to \"$new_complete\"" >&5
39903 $as_echo "$as_me: Rewriting BUILD_CC to \"$new_complete\"" >&6;}
39904   fi
39905 
39906 
39907 
39908   # Publish this variable in the help.
39909 
39910 
39911   if test "x$BUILD_CXX" = x; then
39912     # The variable is not set by user, try to locate tool using the code snippet
39913     for ac_prog in cl CC g++
39914 do
39915   # Extract the first word of "$ac_prog", so it can be a program name with args.
39916 set dummy $ac_prog; ac_word=$2
39917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39918 $as_echo_n "checking for $ac_word... " >&6; }
39919 if ${ac_cv_path_BUILD_CXX+:} false; then :
39920   $as_echo_n "(cached) " >&6
39921 else
39922   case $BUILD_CXX in
39923   [\\/]* | ?:[\\/]*)
39924   ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
39925   ;;
39926   *)
39927   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39928 for as_dir in $PATH
39929 do
39930   IFS=$as_save_IFS
39931   test -z "$as_dir" && as_dir=.
39932     for ac_exec_ext in '' $ac_executable_extensions; do
39933   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39934     ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
39935     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39936     break 2
39937   fi
39938 done
39939   done
39940 IFS=$as_save_IFS
39941 
39942   ;;
39943 esac
39944 fi
39945 BUILD_CXX=$ac_cv_path_BUILD_CXX
39946 if test -n "$BUILD_CXX"; then
39947   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
39948 $as_echo "$BUILD_CXX" >&6; }
39949 else
39950   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39951 $as_echo "no" >&6; }
39952 fi
39953 
39954 
39955   test -n "$BUILD_CXX" && break
39956 done
39957 
39958   else
39959     # The variable is set, but is it from the command line or the environment?
39960 
39961     # Try to remove the string !BUILD_CXX! from our list.
39962     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CXX!/}
39963     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
39964       # If it failed, the variable was not from the command line. Ignore it,
39965       # but warn the user (except for BASH, which is always set by the calling BASH).
39966       if test "xBUILD_CXX" != xBASH; then
39967         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&5
39968 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&2;}
39969       fi
39970       # Try to locate tool using the code snippet
39971       for ac_prog in cl CC g++
39972 do
39973   # Extract the first word of "$ac_prog", so it can be a program name with args.
39974 set dummy $ac_prog; ac_word=$2
39975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
39976 $as_echo_n "checking for $ac_word... " >&6; }
39977 if ${ac_cv_path_BUILD_CXX+:} false; then :
39978   $as_echo_n "(cached) " >&6
39979 else
39980   case $BUILD_CXX in
39981   [\\/]* | ?:[\\/]*)
39982   ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
39983   ;;
39984   *)
39985   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
39986 for as_dir in $PATH
39987 do
39988   IFS=$as_save_IFS
39989   test -z "$as_dir" && as_dir=.
39990     for ac_exec_ext in '' $ac_executable_extensions; do
39991   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
39992     ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
39993     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
39994     break 2
39995   fi
39996 done
39997   done
39998 IFS=$as_save_IFS
39999 
40000   ;;
40001 esac
40002 fi
40003 BUILD_CXX=$ac_cv_path_BUILD_CXX
40004 if test -n "$BUILD_CXX"; then
40005   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
40006 $as_echo "$BUILD_CXX" >&6; }
40007 else
40008   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40009 $as_echo "no" >&6; }
40010 fi
40011 
40012 
40013   test -n "$BUILD_CXX" && break
40014 done
40015 
40016     else
40017       # If it succeeded, then it was overridden by the user. We will use it
40018       # for the tool.
40019 
40020       # First remove it from the list of overridden variables, so we can test
40021       # for unknown variables in the end.
40022       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
40023 
40024       # Check if the provided tool contains a complete path.
40025       tool_specified="$BUILD_CXX"
40026       tool_basename="${tool_specified##*/}"
40027       if test "x$tool_basename" = "x$tool_specified"; then
40028         # A command without a complete path is provided, search $PATH.
40029         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CXX=$tool_basename" >&5
40030 $as_echo "$as_me: Will search for user supplied tool BUILD_CXX=$tool_basename" >&6;}
40031         # Extract the first word of "$tool_basename", so it can be a program name with args.
40032 set dummy $tool_basename; ac_word=$2
40033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40034 $as_echo_n "checking for $ac_word... " >&6; }
40035 if ${ac_cv_path_BUILD_CXX+:} false; then :
40036   $as_echo_n "(cached) " >&6
40037 else
40038   case $BUILD_CXX in
40039   [\\/]* | ?:[\\/]*)
40040   ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path.
40041   ;;
40042   *)
40043   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40044 for as_dir in $PATH
40045 do
40046   IFS=$as_save_IFS
40047   test -z "$as_dir" && as_dir=.
40048     for ac_exec_ext in '' $ac_executable_extensions; do
40049   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40050     ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext"
40051     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40052     break 2
40053   fi
40054 done
40055   done
40056 IFS=$as_save_IFS
40057 
40058   ;;
40059 esac
40060 fi
40061 BUILD_CXX=$ac_cv_path_BUILD_CXX
40062 if test -n "$BUILD_CXX"; then
40063   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5
40064 $as_echo "$BUILD_CXX" >&6; }
40065 else
40066   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40067 $as_echo "no" >&6; }
40068 fi
40069 
40070 
40071         if test "x$BUILD_CXX" = x; then
40072           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
40073         fi
40074       else
40075         # Otherwise we believe it is a complete path. Use it as it is.
40076         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CXX=$tool_specified" >&5
40077 $as_echo "$as_me: Will use user supplied tool BUILD_CXX=$tool_specified" >&6;}
40078         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5
40079 $as_echo_n "checking for BUILD_CXX... " >&6; }
40080         if test ! -x "$tool_specified"; then
40081           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
40082 $as_echo "not found" >&6; }
40083           as_fn_error $? "User supplied tool BUILD_CXX=$tool_specified does not exist or is not executable" "$LINENO" 5
40084         fi
40085         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
40086 $as_echo "$tool_specified" >&6; }
40087       fi
40088     fi
40089   fi
40090 
40091 
40092 
40093   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40094 
40095   # First separate the path from the arguments. This will split at the first
40096   # space.
40097   complete="$BUILD_CXX"
40098   path="${complete%% *}"
40099   tmp="$complete EOL"
40100   arguments="${tmp#* }"
40101 
40102   # Input might be given as Windows format, start by converting to
40103   # unix format.
40104   new_path=`$CYGPATH -u "$path"`
40105 
40106   # Now try to locate executable using which
40107   new_path=`$WHICH "$new_path" 2> /dev/null`
40108   # bat and cmd files are not always considered executable in cygwin causing which
40109   # to not find them
40110   if test "x$new_path" = x \
40111       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
40112       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
40113     new_path=`$CYGPATH -u "$path"`
40114   fi
40115   if test "x$new_path" = x; then
40116     # Oops. Which didn't find the executable.
40117     # The splitting of arguments from the executable at a space might have been incorrect,
40118     # since paths with space are more likely in Windows. Give it another try with the whole
40119     # argument.
40120     path="$complete"
40121     arguments="EOL"
40122     new_path=`$CYGPATH -u "$path"`
40123     new_path=`$WHICH "$new_path" 2> /dev/null`
40124     # bat and cmd files are not always considered executable in cygwin causing which
40125     # to not find them
40126     if test "x$new_path" = x \
40127         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
40128         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
40129       new_path=`$CYGPATH -u "$path"`
40130     fi
40131     if test "x$new_path" = x; then
40132       # It's still not found. Now this is an unrecoverable error.
40133       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
40134 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
40135       has_space=`$ECHO "$complete" | $GREP " "`
40136       if test "x$has_space" != x; then
40137         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
40138 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
40139       fi
40140       as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
40141     fi
40142   fi
40143 
40144   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
40145   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
40146   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
40147   # "foo.exe" is OK but "foo" is an error.
40148   #
40149   # This test is therefore slightly more accurate than "test -f" to check for file presence.
40150   # It is also a way to make sure we got the proper file name for the real test later on.
40151   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
40152   if test "x$test_shortpath" = x; then
40153     # Short path failed, file does not exist as specified.
40154     # Try adding .exe or .cmd
40155     if test -f "${new_path}.exe"; then
40156       input_to_shortpath="${new_path}.exe"
40157     elif test -f "${new_path}.cmd"; then
40158       input_to_shortpath="${new_path}.cmd"
40159     else
40160       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&5
40161 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&6;}
40162       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
40163 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
40164       as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
40165     fi
40166   else
40167     input_to_shortpath="$new_path"
40168   fi
40169 
40170   # Call helper function which possibly converts this using DOS-style short mode.
40171   # If so, the updated path is stored in $new_path.
40172   new_path="$input_to_shortpath"
40173 
40174   input_path="$input_to_shortpath"
40175   # Check if we need to convert this using DOS-style short mode. If the path
40176   # contains just simple characters, use it. Otherwise (spaces, weird characters),
40177   # take no chances and rewrite it.
40178   # Note: m4 eats our [], so we need to use [ and ] instead.
40179   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
40180   if test "x$has_forbidden_chars" != x; then
40181     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40182     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
40183     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
40184     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
40185       # Going to short mode and back again did indeed matter. Since short mode is
40186       # case insensitive, let's make it lowercase to improve readability.
40187       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40188       # Now convert it back to Unix-stile (cygpath)
40189       input_path=`$CYGPATH -u "$shortmode_path"`
40190       new_path="$input_path"
40191     fi
40192   fi
40193 
40194   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
40195   if test "x$test_cygdrive_prefix" = x; then
40196     # As a simple fix, exclude /usr/bin since it's not a real path.
40197     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
40198       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
40199       # a path prefixed by /cygdrive for fixpath to work.
40200       new_path="$CYGWIN_ROOT_PATH$input_path"
40201     fi
40202   fi
40203 
40204   # remove trailing .exe if any
40205   new_path="${new_path/%.exe/}"
40206 
40207   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40208 
40209   # First separate the path from the arguments. This will split at the first
40210   # space.
40211   complete="$BUILD_CXX"
40212   path="${complete%% *}"
40213   tmp="$complete EOL"
40214   arguments="${tmp#* }"
40215 
40216   # Input might be given as Windows format, start by converting to
40217   # unix format.
40218   new_path="$path"
40219 
40220   windows_path="$new_path"
40221   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40222     unix_path=`$CYGPATH -u "$windows_path"`
40223     new_path="$unix_path"
40224   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40225     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40226     new_path="$unix_path"
40227   fi
40228 
40229 
40230   # Now try to locate executable using which
40231   new_path=`$WHICH "$new_path" 2> /dev/null`
40232 
40233   if test "x$new_path" = x; then
40234     # Oops. Which didn't find the executable.
40235     # The splitting of arguments from the executable at a space might have been incorrect,
40236     # since paths with space are more likely in Windows. Give it another try with the whole
40237     # argument.
40238     path="$complete"
40239     arguments="EOL"
40240     new_path="$path"
40241 
40242   windows_path="$new_path"
40243   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40244     unix_path=`$CYGPATH -u "$windows_path"`
40245     new_path="$unix_path"
40246   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40247     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40248     new_path="$unix_path"
40249   fi
40250 
40251 
40252     new_path=`$WHICH "$new_path" 2> /dev/null`
40253     # bat and cmd files are not always considered executable in MSYS causing which
40254     # to not find them
40255     if test "x$new_path" = x \
40256         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
40257         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
40258       new_path="$path"
40259 
40260   windows_path="$new_path"
40261   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40262     unix_path=`$CYGPATH -u "$windows_path"`
40263     new_path="$unix_path"
40264   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40265     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40266     new_path="$unix_path"
40267   fi
40268 
40269     fi
40270 
40271     if test "x$new_path" = x; then
40272       # It's still not found. Now this is an unrecoverable error.
40273       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
40274 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
40275       has_space=`$ECHO "$complete" | $GREP " "`
40276       if test "x$has_space" != x; then
40277         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
40278 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
40279       fi
40280       as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
40281     fi
40282   fi
40283 
40284   # Now new_path has a complete unix path to the binary
40285   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
40286     # Keep paths in /bin as-is, but remove trailing .exe if any
40287     new_path="${new_path/%.exe/}"
40288     # Do not save /bin paths to all_fixpath_prefixes!
40289   else
40290     # Not in mixed or Windows style, start by that.
40291     new_path=`cmd //c echo $new_path`
40292 
40293   input_path="$new_path"
40294   # Check if we need to convert this using DOS-style short mode. If the path
40295   # contains just simple characters, use it. Otherwise (spaces, weird characters),
40296   # take no chances and rewrite it.
40297   # Note: m4 eats our [], so we need to use [ and ] instead.
40298   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
40299   if test "x$has_forbidden_chars" != x; then
40300     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40301     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40302   fi
40303 
40304     # Output is in $new_path
40305 
40306   windows_path="$new_path"
40307   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40308     unix_path=`$CYGPATH -u "$windows_path"`
40309     new_path="$unix_path"
40310   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40311     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40312     new_path="$unix_path"
40313   fi
40314 
40315     # remove trailing .exe if any
40316     new_path="${new_path/%.exe/}"
40317 
40318     # Save the first 10 bytes of this path to the storage, so fixpath can work.
40319     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
40320   fi
40321 
40322   else
40323     # We're on a unix platform. Hooray! :)
40324     # First separate the path from the arguments. This will split at the first
40325     # space.
40326     complete="$BUILD_CXX"
40327     path="${complete%% *}"
40328     tmp="$complete EOL"
40329     arguments="${tmp#* }"
40330 
40331     # Cannot rely on the command "which" here since it doesn't always work.
40332     is_absolute_path=`$ECHO "$path" | $GREP ^/`
40333     if test -z "$is_absolute_path"; then
40334       # Path to executable is not absolute. Find it.
40335       IFS_save="$IFS"
40336       IFS=:
40337       for p in $PATH; do
40338         if test -f "$p/$path" && test -x "$p/$path"; then
40339           new_path="$p/$path"
40340           break
40341         fi
40342       done
40343       IFS="$IFS_save"
40344     else
40345       # This is an absolute path, we can use it without further modifications.
40346       new_path="$path"
40347     fi
40348 
40349     if test "x$new_path" = x; then
40350       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5
40351 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;}
40352       has_space=`$ECHO "$complete" | $GREP " "`
40353       if test "x$has_space" != x; then
40354         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
40355 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
40356       fi
40357       as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5
40358     fi
40359   fi
40360 
40361   # Now join together the path and the arguments once again
40362   if test "x$arguments" != xEOL; then
40363     new_complete="$new_path ${arguments% *}"
40364   else
40365     new_complete="$new_path"
40366   fi
40367 
40368   if test "x$complete" != "x$new_complete"; then
40369     BUILD_CXX="$new_complete"
40370     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CXX to \"$new_complete\"" >&5
40371 $as_echo "$as_me: Rewriting BUILD_CXX to \"$new_complete\"" >&6;}
40372   fi
40373 
40374 
40375 
40376   # Publish this variable in the help.
40377 
40378 
40379   if test "x$BUILD_LD" = x; then
40380     # The variable is not set by user, try to locate tool using the code snippet
40381     for ac_prog in ld
40382 do
40383   # Extract the first word of "$ac_prog", so it can be a program name with args.
40384 set dummy $ac_prog; ac_word=$2
40385 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40386 $as_echo_n "checking for $ac_word... " >&6; }
40387 if ${ac_cv_path_BUILD_LD+:} false; then :
40388   $as_echo_n "(cached) " >&6
40389 else
40390   case $BUILD_LD in
40391   [\\/]* | ?:[\\/]*)
40392   ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
40393   ;;
40394   *)
40395   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40396 for as_dir in $PATH
40397 do
40398   IFS=$as_save_IFS
40399   test -z "$as_dir" && as_dir=.
40400     for ac_exec_ext in '' $ac_executable_extensions; do
40401   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40402     ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
40403     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40404     break 2
40405   fi
40406 done
40407   done
40408 IFS=$as_save_IFS
40409 
40410   ;;
40411 esac
40412 fi
40413 BUILD_LD=$ac_cv_path_BUILD_LD
40414 if test -n "$BUILD_LD"; then
40415   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
40416 $as_echo "$BUILD_LD" >&6; }
40417 else
40418   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40419 $as_echo "no" >&6; }
40420 fi
40421 
40422 
40423   test -n "$BUILD_LD" && break
40424 done
40425 
40426   else
40427     # The variable is set, but is it from the command line or the environment?
40428 
40429     # Try to remove the string !BUILD_LD! from our list.
40430     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_LD!/}
40431     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
40432       # If it failed, the variable was not from the command line. Ignore it,
40433       # but warn the user (except for BASH, which is always set by the calling BASH).
40434       if test "xBUILD_LD" != xBASH; then
40435         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_LD from the environment. Use command line variables instead." >&5
40436 $as_echo "$as_me: WARNING: Ignoring value of BUILD_LD from the environment. Use command line variables instead." >&2;}
40437       fi
40438       # Try to locate tool using the code snippet
40439       for ac_prog in ld
40440 do
40441   # Extract the first word of "$ac_prog", so it can be a program name with args.
40442 set dummy $ac_prog; ac_word=$2
40443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40444 $as_echo_n "checking for $ac_word... " >&6; }
40445 if ${ac_cv_path_BUILD_LD+:} false; then :
40446   $as_echo_n "(cached) " >&6
40447 else
40448   case $BUILD_LD in
40449   [\\/]* | ?:[\\/]*)
40450   ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
40451   ;;
40452   *)
40453   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40454 for as_dir in $PATH
40455 do
40456   IFS=$as_save_IFS
40457   test -z "$as_dir" && as_dir=.
40458     for ac_exec_ext in '' $ac_executable_extensions; do
40459   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40460     ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
40461     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40462     break 2
40463   fi
40464 done
40465   done
40466 IFS=$as_save_IFS
40467 
40468   ;;
40469 esac
40470 fi
40471 BUILD_LD=$ac_cv_path_BUILD_LD
40472 if test -n "$BUILD_LD"; then
40473   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
40474 $as_echo "$BUILD_LD" >&6; }
40475 else
40476   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40477 $as_echo "no" >&6; }
40478 fi
40479 
40480 
40481   test -n "$BUILD_LD" && break
40482 done
40483 
40484     else
40485       # If it succeeded, then it was overridden by the user. We will use it
40486       # for the tool.
40487 
40488       # First remove it from the list of overridden variables, so we can test
40489       # for unknown variables in the end.
40490       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
40491 
40492       # Check if the provided tool contains a complete path.
40493       tool_specified="$BUILD_LD"
40494       tool_basename="${tool_specified##*/}"
40495       if test "x$tool_basename" = "x$tool_specified"; then
40496         # A command without a complete path is provided, search $PATH.
40497         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_LD=$tool_basename" >&5
40498 $as_echo "$as_me: Will search for user supplied tool BUILD_LD=$tool_basename" >&6;}
40499         # Extract the first word of "$tool_basename", so it can be a program name with args.
40500 set dummy $tool_basename; ac_word=$2
40501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40502 $as_echo_n "checking for $ac_word... " >&6; }
40503 if ${ac_cv_path_BUILD_LD+:} false; then :
40504   $as_echo_n "(cached) " >&6
40505 else
40506   case $BUILD_LD in
40507   [\\/]* | ?:[\\/]*)
40508   ac_cv_path_BUILD_LD="$BUILD_LD" # Let the user override the test with a path.
40509   ;;
40510   *)
40511   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40512 for as_dir in $PATH
40513 do
40514   IFS=$as_save_IFS
40515   test -z "$as_dir" && as_dir=.
40516     for ac_exec_ext in '' $ac_executable_extensions; do
40517   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40518     ac_cv_path_BUILD_LD="$as_dir/$ac_word$ac_exec_ext"
40519     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40520     break 2
40521   fi
40522 done
40523   done
40524 IFS=$as_save_IFS
40525 
40526   ;;
40527 esac
40528 fi
40529 BUILD_LD=$ac_cv_path_BUILD_LD
40530 if test -n "$BUILD_LD"; then
40531   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_LD" >&5
40532 $as_echo "$BUILD_LD" >&6; }
40533 else
40534   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40535 $as_echo "no" >&6; }
40536 fi
40537 
40538 
40539         if test "x$BUILD_LD" = x; then
40540           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
40541         fi
40542       else
40543         # Otherwise we believe it is a complete path. Use it as it is.
40544         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_LD=$tool_specified" >&5
40545 $as_echo "$as_me: Will use user supplied tool BUILD_LD=$tool_specified" >&6;}
40546         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_LD" >&5
40547 $as_echo_n "checking for BUILD_LD... " >&6; }
40548         if test ! -x "$tool_specified"; then
40549           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
40550 $as_echo "not found" >&6; }
40551           as_fn_error $? "User supplied tool BUILD_LD=$tool_specified does not exist or is not executable" "$LINENO" 5
40552         fi
40553         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
40554 $as_echo "$tool_specified" >&6; }
40555       fi
40556     fi
40557   fi
40558 
40559 
40560 
40561   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40562 
40563   # First separate the path from the arguments. This will split at the first
40564   # space.
40565   complete="$BUILD_LD"
40566   path="${complete%% *}"
40567   tmp="$complete EOL"
40568   arguments="${tmp#* }"
40569 
40570   # Input might be given as Windows format, start by converting to
40571   # unix format.
40572   new_path=`$CYGPATH -u "$path"`
40573 
40574   # Now try to locate executable using which
40575   new_path=`$WHICH "$new_path" 2> /dev/null`
40576   # bat and cmd files are not always considered executable in cygwin causing which
40577   # to not find them
40578   if test "x$new_path" = x \
40579       && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
40580       && test "x`$LS \"$path\" 2>/dev/null`" != x; then
40581     new_path=`$CYGPATH -u "$path"`
40582   fi
40583   if test "x$new_path" = x; then
40584     # Oops. Which didn't find the executable.
40585     # The splitting of arguments from the executable at a space might have been incorrect,
40586     # since paths with space are more likely in Windows. Give it another try with the whole
40587     # argument.
40588     path="$complete"
40589     arguments="EOL"
40590     new_path=`$CYGPATH -u "$path"`
40591     new_path=`$WHICH "$new_path" 2> /dev/null`
40592     # bat and cmd files are not always considered executable in cygwin causing which
40593     # to not find them
40594     if test "x$new_path" = x \
40595         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
40596         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
40597       new_path=`$CYGPATH -u "$path"`
40598     fi
40599     if test "x$new_path" = x; then
40600       # It's still not found. Now this is an unrecoverable error.
40601       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
40602 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
40603       has_space=`$ECHO "$complete" | $GREP " "`
40604       if test "x$has_space" != x; then
40605         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
40606 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
40607       fi
40608       as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
40609     fi
40610   fi
40611 
40612   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
40613   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
40614   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
40615   # "foo.exe" is OK but "foo" is an error.
40616   #
40617   # This test is therefore slightly more accurate than "test -f" to check for file presence.
40618   # It is also a way to make sure we got the proper file name for the real test later on.
40619   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
40620   if test "x$test_shortpath" = x; then
40621     # Short path failed, file does not exist as specified.
40622     # Try adding .exe or .cmd
40623     if test -f "${new_path}.exe"; then
40624       input_to_shortpath="${new_path}.exe"
40625     elif test -f "${new_path}.cmd"; then
40626       input_to_shortpath="${new_path}.cmd"
40627     else
40628       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$new_path\", is invalid." >&5
40629 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$new_path\", is invalid." >&6;}
40630       { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5
40631 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;}
40632       as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
40633     fi
40634   else
40635     input_to_shortpath="$new_path"
40636   fi
40637 
40638   # Call helper function which possibly converts this using DOS-style short mode.
40639   # If so, the updated path is stored in $new_path.
40640   new_path="$input_to_shortpath"
40641 
40642   input_path="$input_to_shortpath"
40643   # Check if we need to convert this using DOS-style short mode. If the path
40644   # contains just simple characters, use it. Otherwise (spaces, weird characters),
40645   # take no chances and rewrite it.
40646   # Note: m4 eats our [], so we need to use [ and ] instead.
40647   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
40648   if test "x$has_forbidden_chars" != x; then
40649     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40650     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
40651     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
40652     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
40653       # Going to short mode and back again did indeed matter. Since short mode is
40654       # case insensitive, let's make it lowercase to improve readability.
40655       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40656       # Now convert it back to Unix-stile (cygpath)
40657       input_path=`$CYGPATH -u "$shortmode_path"`
40658       new_path="$input_path"
40659     fi
40660   fi
40661 
40662   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
40663   if test "x$test_cygdrive_prefix" = x; then
40664     # As a simple fix, exclude /usr/bin since it's not a real path.
40665     if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then
40666       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
40667       # a path prefixed by /cygdrive for fixpath to work.
40668       new_path="$CYGWIN_ROOT_PATH$input_path"
40669     fi
40670   fi
40671 
40672   # remove trailing .exe if any
40673   new_path="${new_path/%.exe/}"
40674 
40675   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40676 
40677   # First separate the path from the arguments. This will split at the first
40678   # space.
40679   complete="$BUILD_LD"
40680   path="${complete%% *}"
40681   tmp="$complete EOL"
40682   arguments="${tmp#* }"
40683 
40684   # Input might be given as Windows format, start by converting to
40685   # unix format.
40686   new_path="$path"
40687 
40688   windows_path="$new_path"
40689   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40690     unix_path=`$CYGPATH -u "$windows_path"`
40691     new_path="$unix_path"
40692   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40693     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40694     new_path="$unix_path"
40695   fi
40696 
40697 
40698   # Now try to locate executable using which
40699   new_path=`$WHICH "$new_path" 2> /dev/null`
40700 
40701   if test "x$new_path" = x; then
40702     # Oops. Which didn't find the executable.
40703     # The splitting of arguments from the executable at a space might have been incorrect,
40704     # since paths with space are more likely in Windows. Give it another try with the whole
40705     # argument.
40706     path="$complete"
40707     arguments="EOL"
40708     new_path="$path"
40709 
40710   windows_path="$new_path"
40711   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40712     unix_path=`$CYGPATH -u "$windows_path"`
40713     new_path="$unix_path"
40714   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40715     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40716     new_path="$unix_path"
40717   fi
40718 
40719 
40720     new_path=`$WHICH "$new_path" 2> /dev/null`
40721     # bat and cmd files are not always considered executable in MSYS causing which
40722     # to not find them
40723     if test "x$new_path" = x \
40724         && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \
40725         && test "x`$LS \"$path\" 2>/dev/null`" != x; then
40726       new_path="$path"
40727 
40728   windows_path="$new_path"
40729   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40730     unix_path=`$CYGPATH -u "$windows_path"`
40731     new_path="$unix_path"
40732   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40733     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40734     new_path="$unix_path"
40735   fi
40736 
40737     fi
40738 
40739     if test "x$new_path" = x; then
40740       # It's still not found. Now this is an unrecoverable error.
40741       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
40742 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
40743       has_space=`$ECHO "$complete" | $GREP " "`
40744       if test "x$has_space" != x; then
40745         { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5
40746 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;}
40747       fi
40748       as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
40749     fi
40750   fi
40751 
40752   # Now new_path has a complete unix path to the binary
40753   if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then
40754     # Keep paths in /bin as-is, but remove trailing .exe if any
40755     new_path="${new_path/%.exe/}"
40756     # Do not save /bin paths to all_fixpath_prefixes!
40757   else
40758     # Not in mixed or Windows style, start by that.
40759     new_path=`cmd //c echo $new_path`
40760 
40761   input_path="$new_path"
40762   # Check if we need to convert this using DOS-style short mode. If the path
40763   # contains just simple characters, use it. Otherwise (spaces, weird characters),
40764   # take no chances and rewrite it.
40765   # Note: m4 eats our [], so we need to use [ and ] instead.
40766   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
40767   if test "x$has_forbidden_chars" != x; then
40768     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
40769     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
40770   fi
40771 
40772     # Output is in $new_path
40773 
40774   windows_path="$new_path"
40775   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40776     unix_path=`$CYGPATH -u "$windows_path"`
40777     new_path="$unix_path"
40778   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40779     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
40780     new_path="$unix_path"
40781   fi
40782 
40783     # remove trailing .exe if any
40784     new_path="${new_path/%.exe/}"
40785 
40786     # Save the first 10 bytes of this path to the storage, so fixpath can work.
40787     all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
40788   fi
40789 
40790   else
40791     # We're on a unix platform. Hooray! :)
40792     # First separate the path from the arguments. This will split at the first
40793     # space.
40794     complete="$BUILD_LD"
40795     path="${complete%% *}"
40796     tmp="$complete EOL"
40797     arguments="${tmp#* }"
40798 
40799     # Cannot rely on the command "which" here since it doesn't always work.
40800     is_absolute_path=`$ECHO "$path" | $GREP ^/`
40801     if test -z "$is_absolute_path"; then
40802       # Path to executable is not absolute. Find it.
40803       IFS_save="$IFS"
40804       IFS=:
40805       for p in $PATH; do
40806         if test -f "$p/$path" && test -x "$p/$path"; then
40807           new_path="$p/$path"
40808           break
40809         fi
40810       done
40811       IFS="$IFS_save"
40812     else
40813       # This is an absolute path, we can use it without further modifications.
40814       new_path="$path"
40815     fi
40816 
40817     if test "x$new_path" = x; then
40818       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&5
40819 $as_echo "$as_me: The path of BUILD_LD, which resolves as \"$complete\", is not found." >&6;}
40820       has_space=`$ECHO "$complete" | $GREP " "`
40821       if test "x$has_space" != x; then
40822         { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5
40823 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;}
40824       fi
40825       as_fn_error $? "Cannot locate the the path of BUILD_LD" "$LINENO" 5
40826     fi
40827   fi
40828 
40829   # Now join together the path and the arguments once again
40830   if test "x$arguments" != xEOL; then
40831     new_complete="$new_path ${arguments% *}"
40832   else
40833     new_complete="$new_path"
40834   fi
40835 
40836   if test "x$complete" != "x$new_complete"; then
40837     BUILD_LD="$new_complete"
40838     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_LD to \"$new_complete\"" >&5
40839 $as_echo "$as_me: Rewriting BUILD_LD to \"$new_complete\"" >&6;}
40840   fi
40841 
40842   else
40843     # If we are not cross compiling, use the normal target compilers for
40844     # building the build platform executables.
40845     BUILD_CC="$CC"
40846     BUILD_CXX="$CXX"
40847     BUILD_LD="$LD"
40848   fi
40849 
40850 
40851 
40852 
40853 
40854 
40855   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40856     # For hotspot, we need these in Windows mixed path,
40857     # so rewrite them all. Need added .exe suffix.
40858     HOTSPOT_CXX="$CXX.exe"
40859     HOTSPOT_LD="$LD.exe"
40860     HOTSPOT_MT="$MT.exe"
40861     HOTSPOT_RC="$RC.exe"
40862 
40863   unix_path="$HOTSPOT_CXX"
40864   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40865     windows_path=`$CYGPATH -m "$unix_path"`
40866     HOTSPOT_CXX="$windows_path"
40867   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40868     windows_path=`cmd //c echo $unix_path`
40869     HOTSPOT_CXX="$windows_path"
40870   fi
40871 
40872 
40873   unix_path="$HOTSPOT_LD"
40874   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40875     windows_path=`$CYGPATH -m "$unix_path"`
40876     HOTSPOT_LD="$windows_path"
40877   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40878     windows_path=`cmd //c echo $unix_path`
40879     HOTSPOT_LD="$windows_path"
40880   fi
40881 
40882 
40883   unix_path="$HOTSPOT_MT"
40884   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40885     windows_path=`$CYGPATH -m "$unix_path"`
40886     HOTSPOT_MT="$windows_path"
40887   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40888     windows_path=`cmd //c echo $unix_path`
40889     HOTSPOT_MT="$windows_path"
40890   fi
40891 
40892 
40893   unix_path="$HOTSPOT_RC"
40894   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
40895     windows_path=`$CYGPATH -m "$unix_path"`
40896     HOTSPOT_RC="$windows_path"
40897   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
40898     windows_path=`cmd //c echo $unix_path`
40899     HOTSPOT_RC="$windows_path"
40900   fi
40901 
40902 
40903 
40904   else
40905     HOTSPOT_CXX="$CXX"
40906     HOTSPOT_LD="$LD"
40907   fi
40908 
40909 
40910 
40911   if test  "x$TOOLCHAIN_TYPE" = xclang; then
40912     USE_CLANG=true
40913   fi
40914 
40915 
40916   # LDEXE is the linker to use, when creating executables. Not really used.
40917   # FIXME: These should just be removed!
40918   LDEXE="$LD"
40919   LDEXECXX="$LDCXX"
40920 
40921 
40922 
40923 
40924 
40925 
40926   # The package path is used only on macosx?
40927   # FIXME: clean this up, and/or move it elsewhere.
40928   PACKAGE_PATH=/opt/local
40929 
40930 
40931   # Check for extra potential brokenness.
40932   if test  "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40933     # On Windows, double-check that we got the right compiler.
40934     CC_VERSION_OUTPUT=`$CC 2>&1 | $HEAD -n 1 | $TR -d '\r'`
40935     COMPILER_CPU_TEST=`$ECHO $CC_VERSION_OUTPUT | $SED -n "s/^.* \(.*\)$/\1/p"`
40936     if test "x$OPENJDK_TARGET_CPU" = "xx86"; then
40937       if test "x$COMPILER_CPU_TEST" != "x80x86"; then
40938         as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"80x86\"." "$LINENO" 5
40939       fi
40940     elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then
40941       if test "x$COMPILER_CPU_TEST" != "xx64"; then
40942         as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5
40943       fi
40944     fi
40945   fi
40946 
40947   if test "x$TOOLCHAIN_TYPE" = xgcc; then
40948     # If this is a --hash-style=gnu system, use --hash-style=both, why?
40949     HAS_GNU_HASH=`$CC -dumpspecs 2>/dev/null | $GREP 'hash-style=gnu'`
40950     # This is later checked when setting flags.
40951 
40952     # "-Og" suppported for GCC 4.8 and later
40953     CFLAG_OPTIMIZE_DEBUG_FLAG="-Og"
40954 
40955   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5
40956 $as_echo_n "checking if compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; }
40957   supports=yes
40958 
40959   saved_cflags="$CFLAGS"
40960   CFLAGS="$CFLAGS $CFLAG_OPTIMIZE_DEBUG_FLAG"
40961   ac_ext=c
40962 ac_cpp='$CPP $CPPFLAGS'
40963 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
40964 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
40965 ac_compiler_gnu=$ac_cv_c_compiler_gnu
40966 
40967   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40968 /* end confdefs.h.  */
40969 int i;
40970 _ACEOF
40971 if ac_fn_c_try_compile "$LINENO"; then :
40972 
40973 else
40974   supports=no
40975 fi
40976 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40977   ac_ext=cpp
40978 ac_cpp='$CXXCPP $CPPFLAGS'
40979 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
40980 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
40981 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
40982 
40983   CFLAGS="$saved_cflags"
40984 
40985   saved_cxxflags="$CXXFLAGS"
40986   CXXFLAGS="$CXXFLAG $CFLAG_OPTIMIZE_DEBUG_FLAG"
40987   ac_ext=cpp
40988 ac_cpp='$CXXCPP $CPPFLAGS'
40989 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
40990 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
40991 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
40992 
40993   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40994 /* end confdefs.h.  */
40995 int i;
40996 _ACEOF
40997 if ac_fn_cxx_try_compile "$LINENO"; then :
40998 
40999 else
41000   supports=no
41001 fi
41002 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41003   ac_ext=cpp
41004 ac_cpp='$CXXCPP $CPPFLAGS'
41005 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41006 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41007 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41008 
41009   CXXFLAGS="$saved_cxxflags"
41010 
41011   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5
41012 $as_echo "$supports" >&6; }
41013   if test "x$supports" = "xyes" ; then
41014     HAS_CFLAG_OPTIMIZE_DEBUG=true
41015   else
41016     HAS_CFLAG_OPTIMIZE_DEBUG=false
41017   fi
41018 
41019 
41020     # "-fsanitize=undefined" supported for GCC 4.9 and later
41021     CFLAG_DETECT_UNDEFINED_BEHAVIOR_FLAG="-fsanitize=undefined -fsanitize-recover"
41022 
41023   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"$CFLAG_DETECT_UNDEFINED_BEHAVIOR_FLAG\"" >&5
41024 $as_echo_n "checking if compiler supports \"$CFLAG_DETECT_UNDEFINED_BEHAVIOR_FLAG\"... " >&6; }
41025   supports=yes
41026 
41027   saved_cflags="$CFLAGS"
41028   CFLAGS="$CFLAGS $CFLAG_DETECT_UNDEFINED_BEHAVIOR_FLAG"
41029   ac_ext=c
41030 ac_cpp='$CPP $CPPFLAGS'
41031 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41032 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41033 ac_compiler_gnu=$ac_cv_c_compiler_gnu
41034 
41035   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41036 /* end confdefs.h.  */
41037 int i;
41038 _ACEOF
41039 if ac_fn_c_try_compile "$LINENO"; then :
41040 
41041 else
41042   supports=no
41043 fi
41044 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41045   ac_ext=cpp
41046 ac_cpp='$CXXCPP $CPPFLAGS'
41047 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41048 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41049 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41050 
41051   CFLAGS="$saved_cflags"
41052 
41053   saved_cxxflags="$CXXFLAGS"
41054   CXXFLAGS="$CXXFLAG $CFLAG_DETECT_UNDEFINED_BEHAVIOR_FLAG"
41055   ac_ext=cpp
41056 ac_cpp='$CXXCPP $CPPFLAGS'
41057 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41058 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41059 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41060 
41061   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41062 /* end confdefs.h.  */
41063 int i;
41064 _ACEOF
41065 if ac_fn_cxx_try_compile "$LINENO"; then :
41066 
41067 else
41068   supports=no
41069 fi
41070 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41071   ac_ext=cpp
41072 ac_cpp='$CXXCPP $CPPFLAGS'
41073 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41074 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41075 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41076 
41077   CXXFLAGS="$saved_cxxflags"
41078 
41079   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5
41080 $as_echo "$supports" >&6; }
41081   if test "x$supports" = "xyes" ; then
41082     HAS_CFLAG_DETECT_UNDEFINED_BEHAVIOR=true
41083   else
41084     HAS_CFLAG_DETECT_UNDEFINED_BEHAVIOR=false
41085   fi
41086 
41087 
41088     # "-z relro" supported in GNU binutils 2.17 and later
41089     LINKER_RELRO_FLAG="-Xlinker -z -Xlinker relro"
41090 
41091   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_RELRO_FLAG\"" >&5
41092 $as_echo_n "checking if linker supports \"$LINKER_RELRO_FLAG\"... " >&6; }
41093   supports=yes
41094 
41095   saved_ldflags="$LDFLAGS"
41096   LDFLAGS="$LDFLAGS $LINKER_RELRO_FLAG"
41097   ac_ext=c
41098 ac_cpp='$CPP $CPPFLAGS'
41099 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41100 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41101 ac_compiler_gnu=$ac_cv_c_compiler_gnu
41102 
41103   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41104 /* end confdefs.h.  */
41105 
41106 int
41107 main ()
41108 {
41109 
41110   ;
41111   return 0;
41112 }
41113 _ACEOF
41114 if ac_fn_c_try_link "$LINENO"; then :
41115 
41116 else
41117   supports=no
41118 fi
41119 rm -f core conftest.err conftest.$ac_objext \
41120     conftest$ac_exeext conftest.$ac_ext
41121   ac_ext=cpp
41122 ac_cpp='$CXXCPP $CPPFLAGS'
41123 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41124 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41125 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41126 
41127   LDFLAGS="$saved_ldflags"
41128 
41129   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5
41130 $as_echo "$supports" >&6; }
41131   if test "x$supports" = "xyes" ; then
41132     HAS_LINKER_RELRO=true
41133   else
41134     HAS_LINKER_RELRO=false
41135   fi
41136 
41137 
41138     # "-z now" supported in GNU binutils 2.11 and later
41139     LINKER_NOW_FLAG="-Xlinker -z -Xlinker now"
41140 
41141   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_NOW_FLAG\"" >&5
41142 $as_echo_n "checking if linker supports \"$LINKER_NOW_FLAG\"... " >&6; }
41143   supports=yes
41144 
41145   saved_ldflags="$LDFLAGS"
41146   LDFLAGS="$LDFLAGS $LINKER_NOW_FLAG"
41147   ac_ext=c
41148 ac_cpp='$CPP $CPPFLAGS'
41149 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41150 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41151 ac_compiler_gnu=$ac_cv_c_compiler_gnu
41152 
41153   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41154 /* end confdefs.h.  */
41155 
41156 int
41157 main ()
41158 {
41159 
41160   ;
41161   return 0;
41162 }
41163 _ACEOF
41164 if ac_fn_c_try_link "$LINENO"; then :
41165 
41166 else
41167   supports=no
41168 fi
41169 rm -f core conftest.err conftest.$ac_objext \
41170     conftest$ac_exeext conftest.$ac_ext
41171   ac_ext=cpp
41172 ac_cpp='$CXXCPP $CPPFLAGS'
41173 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
41174 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
41175 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
41176 
41177   LDFLAGS="$saved_ldflags"
41178 
41179   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5
41180 $as_echo "$supports" >&6; }
41181   if test "x$supports" = "xyes" ; then
41182     HAS_LINKER_NOW=true
41183   else
41184     HAS_LINKER_NOW=false
41185   fi
41186 
41187   fi
41188 
41189   # Check for broken SuSE 'ld' for which 'Only anonymous version tag is allowed
41190   # in executable.'
41191   USING_BROKEN_SUSE_LD=no
41192   if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$TOOLCHAIN_TYPE" = xgcc; then
41193     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken SuSE 'ld' which only understands anonymous version tags in executables" >&5
41194 $as_echo_n "checking for broken SuSE 'ld' which only understands anonymous version tags in executables... " >&6; }
41195     $ECHO "SUNWprivate_1.1 { local: *; };" > version-script.map
41196     $ECHO "int main() { }" > main.c
41197     if $CXX -Xlinker -version-script=version-script.map main.c 2>&5 >&5; then
41198       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41199 $as_echo "no" >&6; }
41200       USING_BROKEN_SUSE_LD=no
41201     else
41202       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41203 $as_echo "yes" >&6; }
41204       USING_BROKEN_SUSE_LD=yes
41205     fi
41206     rm -rf version-script.map main.c a.out
41207   fi
41208 
41209 
41210 
41211 # Setup the JTReg Regression Test Harness.
41212 
41213 
41214 # Check whether --with-jtreg was given.
41215 if test "${with_jtreg+set}" = set; then :
41216   withval=$with_jtreg;
41217 else
41218   with_jtreg=no
41219 fi
41220 
41221 
41222   if test "x$with_jtreg" = xno; then
41223     # jtreg disabled
41224     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5
41225 $as_echo_n "checking for jtreg... " >&6; }
41226     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41227 $as_echo "no" >&6; }
41228   else
41229     if test "x$with_jtreg" != xyes; then
41230       # with path specified.
41231       JT_HOME="$with_jtreg"
41232     fi
41233 
41234     if test "x$JT_HOME" != x; then
41235       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5
41236 $as_echo_n "checking for jtreg... " >&6; }
41237 
41238       # use JT_HOME enviroment var.
41239 
41240   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
41241 
41242   # Input might be given as Windows format, start by converting to
41243   # unix format.
41244   path="$JT_HOME"
41245   new_path=`$CYGPATH -u "$path"`
41246 
41247   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
41248   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
41249   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
41250   # "foo.exe" is OK but "foo" is an error.
41251   #
41252   # This test is therefore slightly more accurate than "test -f" to check for file precense.
41253   # It is also a way to make sure we got the proper file name for the real test later on.
41254   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
41255   if test "x$test_shortpath" = x; then
41256     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5
41257 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;}
41258     as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5
41259   fi
41260 
41261   # Call helper function which possibly converts this using DOS-style short mode.
41262   # If so, the updated path is stored in $new_path.
41263 
41264   input_path="$new_path"
41265   # Check if we need to convert this using DOS-style short mode. If the path
41266   # contains just simple characters, use it. Otherwise (spaces, weird characters),
41267   # take no chances and rewrite it.
41268   # Note: m4 eats our [], so we need to use [ and ] instead.
41269   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
41270   if test "x$has_forbidden_chars" != x; then
41271     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
41272     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
41273     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
41274     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
41275       # Going to short mode and back again did indeed matter. Since short mode is
41276       # case insensitive, let's make it lowercase to improve readability.
41277       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
41278       # Now convert it back to Unix-stile (cygpath)
41279       input_path=`$CYGPATH -u "$shortmode_path"`
41280       new_path="$input_path"
41281     fi
41282   fi
41283 
41284   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
41285   if test "x$test_cygdrive_prefix" = x; then
41286     # As a simple fix, exclude /usr/bin since it's not a real path.
41287     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
41288       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
41289       # a path prefixed by /cygdrive for fixpath to work.
41290       new_path="$CYGWIN_ROOT_PATH$input_path"
41291     fi
41292   fi
41293 
41294 
41295   if test "x$path" != "x$new_path"; then
41296     JT_HOME="$new_path"
41297     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5
41298 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;}
41299   fi
41300 
41301   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
41302 
41303   path="$JT_HOME"
41304   has_colon=`$ECHO $path | $GREP ^.:`
41305   new_path="$path"
41306   if test "x$has_colon" = x; then
41307     # Not in mixed or Windows style, start by that.
41308     new_path=`cmd //c echo $path`
41309   fi
41310 
41311 
41312   input_path="$new_path"
41313   # Check if we need to convert this using DOS-style short mode. If the path
41314   # contains just simple characters, use it. Otherwise (spaces, weird characters),
41315   # take no chances and rewrite it.
41316   # Note: m4 eats our [], so we need to use [ and ] instead.
41317   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
41318   if test "x$has_forbidden_chars" != x; then
41319     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
41320     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
41321   fi
41322 
41323 
41324   windows_path="$new_path"
41325   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
41326     unix_path=`$CYGPATH -u "$windows_path"`
41327     new_path="$unix_path"
41328   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
41329     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
41330     new_path="$unix_path"
41331   fi
41332 
41333   if test "x$path" != "x$new_path"; then
41334     JT_HOME="$new_path"
41335     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5
41336 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;}
41337   fi
41338 
41339   # Save the first 10 bytes of this path to the storage, so fixpath can work.
41340   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
41341 
41342   else
41343     # We're on a unix platform. Hooray! :)
41344     path="$JT_HOME"
41345     has_space=`$ECHO "$path" | $GREP " "`
41346     if test "x$has_space" != x; then
41347       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5
41348 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;}
41349       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
41350     fi
41351 
41352     # Use eval to expand a potential ~
41353     eval path="$path"
41354     if test ! -f "$path" && test ! -d "$path"; then
41355       as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5
41356     fi
41357 
41358     JT_HOME="`cd "$path"; $THEPWDCMD -L`"
41359   fi
41360 
41361 
41362       # jtreg win32 script works for everybody
41363       JTREGEXE="$JT_HOME/win32/bin/jtreg"
41364 
41365       if test ! -f "$JTREGEXE"; then
41366         as_fn_error $? "JTReg executable does not exist: $JTREGEXE" "$LINENO" 5
41367       fi
41368 
41369       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
41370 $as_echo "$JTREGEXE" >&6; }
41371     else
41372       # try to find jtreg on path
41373 
41374 
41375 
41376   # Publish this variable in the help.
41377 
41378 
41379   if test "x$JTREGEXE" = x; then
41380     # The variable is not set by user, try to locate tool using the code snippet
41381     for ac_prog in jtreg
41382 do
41383   # Extract the first word of "$ac_prog", so it can be a program name with args.
41384 set dummy $ac_prog; ac_word=$2
41385 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
41386 $as_echo_n "checking for $ac_word... " >&6; }
41387 if ${ac_cv_path_JTREGEXE+:} false; then :
41388   $as_echo_n "(cached) " >&6
41389 else
41390   case $JTREGEXE in
41391   [\\/]* | ?:[\\/]*)
41392   ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
41393   ;;
41394   *)
41395   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
41396 for as_dir in $PATH
41397 do
41398   IFS=$as_save_IFS
41399   test -z "$as_dir" && as_dir=.
41400     for ac_exec_ext in '' $ac_executable_extensions; do
41401   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
41402     ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
41403     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
41404     break 2
41405   fi
41406 done
41407   done
41408 IFS=$as_save_IFS
41409 
41410   ;;
41411 esac
41412 fi
41413 JTREGEXE=$ac_cv_path_JTREGEXE
41414 if test -n "$JTREGEXE"; then
41415   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
41416 $as_echo "$JTREGEXE" >&6; }
41417 else
41418   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41419 $as_echo "no" >&6; }
41420 fi
41421 
41422 
41423   test -n "$JTREGEXE" && break
41424 done
41425 
41426   else
41427     # The variable is set, but is it from the command line or the environment?
41428 
41429     # Try to remove the string !JTREGEXE! from our list.
41430     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JTREGEXE!/}
41431     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
41432       # If it failed, the variable was not from the command line. Ignore it,
41433       # but warn the user (except for BASH, which is always set by the calling BASH).
41434       if test "xJTREGEXE" != xBASH; then
41435         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&5
41436 $as_echo "$as_me: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&2;}
41437       fi
41438       # Try to locate tool using the code snippet
41439       for ac_prog in jtreg
41440 do
41441   # Extract the first word of "$ac_prog", so it can be a program name with args.
41442 set dummy $ac_prog; ac_word=$2
41443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
41444 $as_echo_n "checking for $ac_word... " >&6; }
41445 if ${ac_cv_path_JTREGEXE+:} false; then :
41446   $as_echo_n "(cached) " >&6
41447 else
41448   case $JTREGEXE in
41449   [\\/]* | ?:[\\/]*)
41450   ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
41451   ;;
41452   *)
41453   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
41454 for as_dir in $PATH
41455 do
41456   IFS=$as_save_IFS
41457   test -z "$as_dir" && as_dir=.
41458     for ac_exec_ext in '' $ac_executable_extensions; do
41459   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
41460     ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
41461     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
41462     break 2
41463   fi
41464 done
41465   done
41466 IFS=$as_save_IFS
41467 
41468   ;;
41469 esac
41470 fi
41471 JTREGEXE=$ac_cv_path_JTREGEXE
41472 if test -n "$JTREGEXE"; then
41473   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
41474 $as_echo "$JTREGEXE" >&6; }
41475 else
41476   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41477 $as_echo "no" >&6; }
41478 fi
41479 
41480 
41481   test -n "$JTREGEXE" && break
41482 done
41483 
41484     else
41485       # If it succeeded, then it was overridden by the user. We will use it
41486       # for the tool.
41487 
41488       # First remove it from the list of overridden variables, so we can test
41489       # for unknown variables in the end.
41490       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
41491 
41492       # Check if the provided tool contains a complete path.
41493       tool_specified="$JTREGEXE"
41494       tool_basename="${tool_specified##*/}"
41495       if test "x$tool_basename" = "x$tool_specified"; then
41496         # A command without a complete path is provided, search $PATH.
41497         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JTREGEXE=$tool_basename" >&5
41498 $as_echo "$as_me: Will search for user supplied tool JTREGEXE=$tool_basename" >&6;}
41499         # Extract the first word of "$tool_basename", so it can be a program name with args.
41500 set dummy $tool_basename; ac_word=$2
41501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
41502 $as_echo_n "checking for $ac_word... " >&6; }
41503 if ${ac_cv_path_JTREGEXE+:} false; then :
41504   $as_echo_n "(cached) " >&6
41505 else
41506   case $JTREGEXE in
41507   [\\/]* | ?:[\\/]*)
41508   ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path.
41509   ;;
41510   *)
41511   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
41512 for as_dir in $PATH
41513 do
41514   IFS=$as_save_IFS
41515   test -z "$as_dir" && as_dir=.
41516     for ac_exec_ext in '' $ac_executable_extensions; do
41517   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
41518     ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext"
41519     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
41520     break 2
41521   fi
41522 done
41523   done
41524 IFS=$as_save_IFS
41525 
41526   ;;
41527 esac
41528 fi
41529 JTREGEXE=$ac_cv_path_JTREGEXE
41530 if test -n "$JTREGEXE"; then
41531   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5
41532 $as_echo "$JTREGEXE" >&6; }
41533 else
41534   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41535 $as_echo "no" >&6; }
41536 fi
41537 
41538 
41539         if test "x$JTREGEXE" = x; then
41540           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
41541         fi
41542       else
41543         # Otherwise we believe it is a complete path. Use it as it is.
41544         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JTREGEXE=$tool_specified" >&5
41545 $as_echo "$as_me: Will use user supplied tool JTREGEXE=$tool_specified" >&6;}
41546         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5
41547 $as_echo_n "checking for JTREGEXE... " >&6; }
41548         if test ! -x "$tool_specified"; then
41549           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
41550 $as_echo "not found" >&6; }
41551           as_fn_error $? "User supplied tool JTREGEXE=$tool_specified does not exist or is not executable" "$LINENO" 5
41552         fi
41553         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
41554 $as_echo "$tool_specified" >&6; }
41555       fi
41556     fi
41557   fi
41558 
41559 
41560 
41561   if test "x$JTREGEXE" = x; then
41562     as_fn_error $? "Could not find required tool for JTREGEXE" "$LINENO" 5
41563   fi
41564 
41565 
41566       JT_HOME="`$DIRNAME $JTREGEXE`"
41567     fi
41568   fi
41569 
41570 
41571 
41572 
41573 
41574 
41575   # Option used to tell the compiler whether to create 32- or 64-bit executables
41576   if test "x$TOOLCHAIN_TYPE" = xxlc; then
41577     COMPILER_TARGET_BITS_FLAG="-q"
41578   else
41579     COMPILER_TARGET_BITS_FLAG="-m"
41580   fi
41581 
41582 
41583   # FIXME: figure out if we should select AR flags depending on OS or toolchain.
41584   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41585     ARFLAGS="-r"
41586   elif test "x$OPENJDK_TARGET_OS" = xaix; then
41587     ARFLAGS="-X64"
41588   elif test "x$OPENJDK_TARGET_OS" = xwindows; then
41589     # lib.exe is used as AR to create static libraries.
41590     ARFLAGS="-nologo -NODEFAULTLIB:MSVCRT"
41591   else
41592     ARFLAGS=""
41593   fi
41594 
41595 
41596   ## Setup strip.
41597   # FIXME: should this really be per platform, or should it be per toolchain type?
41598   # strip is not provided by clang or solstudio; so guessing platform makes most sense.
41599   # FIXME: we should really only export STRIPFLAGS from here, not POST_STRIP_CMD.
41600   if test "x$OPENJDK_TARGET_OS" = xlinux; then
41601     STRIPFLAGS="-g"
41602   elif test "x$OPENJDK_TARGET_OS" = xsolaris; then
41603     STRIPFLAGS="-x"
41604   elif test "x$OPENJDK_TARGET_OS" = xmacosx; then
41605     STRIPFLAGS="-S"
41606   elif test "x$OPENJDK_TARGET_OS" = xaix; then
41607     STRIPFLAGS="-X32_64"
41608   fi
41609 
41610   if test "x$OPENJDK_TARGET_OS" != xwindows; then
41611     POST_STRIP_CMD="$STRIP $STRIPFLAGS"
41612   fi
41613 
41614 
41615   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41616     # FIXME: break out into MCSFLAGS
41617     POST_MCS_CMD="$MCS -d -a \"JDK $FULL_VERSION\""
41618   fi
41619 
41620 
41621   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41622     CC_OUT_OPTION=-Fo
41623     EXE_OUT_OPTION=-out:
41624     LD_OUT_OPTION=-out:
41625     AR_OUT_OPTION=-out:
41626   else
41627     # The option used to specify the target .o,.a or .so file.
41628     # When compiling, how to specify the to be created object file.
41629     CC_OUT_OPTION='-o$(SPACE)'
41630     # When linking, how to specify the to be created executable.
41631     EXE_OUT_OPTION='-o$(SPACE)'
41632     # When linking, how to specify the to be created dynamically linkable library.
41633     LD_OUT_OPTION='-o$(SPACE)'
41634     # When archiving, how to specify the to be create static archive for object files.
41635     AR_OUT_OPTION='rcs$(SPACE)'
41636   fi
41637 
41638 
41639 
41640 
41641 
41642   # On Windows, we need to set RC flags.
41643   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41644     RC_FLAGS="-nologo -l0x409"
41645     if test "x$VARIANT" = xOPT; then
41646       RC_FLAGS="$RC_FLAGS -DNDEBUG"
41647     fi
41648 
41649     # The version variables used to create RC_FLAGS may be overridden
41650     # in a custom configure script, or possibly the command line.
41651     # Let those variables be expanded at make time in spec.gmk.
41652     # The \$ are escaped to the shell, and the $(...) variables
41653     # are evaluated by make.
41654     RC_FLAGS="$RC_FLAGS \
41655         -D\"JDK_BUILD_ID=\$(FULL_VERSION)\" \
41656         -D\"JDK_COMPANY=\$(COMPANY_NAME)\" \
41657         -D\"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \
41658         -D\"JDK_VER=\$(JDK_MINOR_VERSION).\$(JDK_MICRO_VERSION).\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0).\$(COOKED_BUILD_NUMBER)\" \
41659         -D\"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \
41660         -D\"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(JDK_MINOR_VERSION) \$(JDK_UPDATE_META_TAG)\" \
41661         -D\"JDK_FVER=\$(JDK_MINOR_VERSION),\$(JDK_MICRO_VERSION),\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0),\$(COOKED_BUILD_NUMBER)\""
41662   fi
41663 
41664 
41665   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
41666     # silence copyright notice and other headers.
41667     COMMON_CCXXFLAGS="$COMMON_CCXXFLAGS -nologo"
41668   fi
41669 
41670   if test "x$SYSROOT" != "x"; then
41671     if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
41672       if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41673         # Solaris Studio does not have a concept of sysroot. Instead we must
41674         # make sure the default include and lib dirs are appended to each
41675         # compile and link command line.
41676         SYSROOT_CFLAGS="-I$SYSROOT/usr/include"
41677         SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \
41678             -L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR \
41679             -L$SYSROOT/usr/ccs/lib$OPENJDK_TARGET_CPU_ISADIR"
41680       fi
41681     elif test "x$OPENJDK_TARGET_OS" = xmacosx; then
41682       # Apple only wants -isysroot <path>, but we also need -iframework<path>/System/Library/Frameworks
41683       SYSROOT_CFLAGS="-isysroot \"$SYSROOT\" -iframework\"$SYSROOT/System/Library/Frameworks\""
41684       SYSROOT_LDFLAGS=$SYSROOT_CFLAGS
41685     elif test "x$TOOLCHAIN_TYPE" = xgcc; then
41686       SYSROOT_CFLAGS="--sysroot=$SYSROOT"
41687       SYSROOT_LDFLAGS="--sysroot=$SYSROOT"
41688     elif test "x$TOOLCHAIN_TYPE" = xclang; then
41689       SYSROOT_CFLAGS="-isysroot \"$SYSROOT\""
41690       SYSROOT_LDFLAGS="-isysroot \"$SYSROOT\""
41691     fi
41692     # Propagate the sysroot args to hotspot
41693     LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $SYSROOT_CFLAGS"
41694     LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $SYSROOT_CFLAGS"
41695     LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $SYSROOT_LDFLAGS"
41696   fi
41697 
41698   # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework
41699   # set this here so it doesn't have to be peppered throughout the forest
41700   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
41701     SYSROOT_CFLAGS="$SYSROOT_CFLAGS -F\"$SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks\""
41702     SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -F\"$SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks\""
41703   fi
41704 
41705 
41706 
41707 
41708 
41709 # FIXME: Currently we must test this after toolchain but before flags. Fix!
41710 
41711 # Now we can test some aspects on the target using configure macros.
41712 
41713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
41714 $as_echo_n "checking for ANSI C header files... " >&6; }
41715 if ${ac_cv_header_stdc+:} false; then :
41716   $as_echo_n "(cached) " >&6
41717 else
41718   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41719 /* end confdefs.h.  */
41720 #include <stdlib.h>
41721 #include <stdarg.h>
41722 #include <string.h>
41723 #include <float.h>
41724 
41725 int
41726 main ()
41727 {
41728 
41729   ;
41730   return 0;
41731 }
41732 _ACEOF
41733 if ac_fn_cxx_try_compile "$LINENO"; then :
41734   ac_cv_header_stdc=yes
41735 else
41736   ac_cv_header_stdc=no
41737 fi
41738 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41739 
41740 if test $ac_cv_header_stdc = yes; then
41741   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
41742   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41743 /* end confdefs.h.  */
41744 #include <string.h>
41745 
41746 _ACEOF
41747 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
41748   $EGREP "memchr" >/dev/null 2>&1; then :
41749 
41750 else
41751   ac_cv_header_stdc=no
41752 fi
41753 rm -f conftest*
41754 
41755 fi
41756 
41757 if test $ac_cv_header_stdc = yes; then
41758   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
41759   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41760 /* end confdefs.h.  */
41761 #include <stdlib.h>
41762 
41763 _ACEOF
41764 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
41765   $EGREP "free" >/dev/null 2>&1; then :
41766 
41767 else
41768   ac_cv_header_stdc=no
41769 fi
41770 rm -f conftest*
41771 
41772 fi
41773 
41774 if test $ac_cv_header_stdc = yes; then
41775   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
41776   if test "$cross_compiling" = yes; then :
41777   :
41778 else
41779   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41780 /* end confdefs.h.  */
41781 #include <ctype.h>
41782 #include <stdlib.h>
41783 #if ((' ' & 0x0FF) == 0x020)
41784 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
41785 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
41786 #else
41787 # define ISLOWER(c) \
41788                    (('a' <= (c) && (c) <= 'i') \
41789                      || ('j' <= (c) && (c) <= 'r') \
41790                      || ('s' <= (c) && (c) <= 'z'))
41791 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
41792 #endif
41793 
41794 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
41795 int
41796 main ()
41797 {
41798   int i;
41799   for (i = 0; i < 256; i++)
41800     if (XOR (islower (i), ISLOWER (i))
41801         || toupper (i) != TOUPPER (i))
41802       return 2;
41803   return 0;
41804 }
41805 _ACEOF
41806 if ac_fn_cxx_try_run "$LINENO"; then :
41807 
41808 else
41809   ac_cv_header_stdc=no
41810 fi
41811 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
41812   conftest.$ac_objext conftest.beam conftest.$ac_ext
41813 fi
41814 
41815 fi
41816 fi
41817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
41818 $as_echo "$ac_cv_header_stdc" >&6; }
41819 if test $ac_cv_header_stdc = yes; then
41820 
41821 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
41822 
41823 fi
41824 
41825 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
41826 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
41827                   inttypes.h stdint.h unistd.h
41828 do :
41829   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
41830 ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
41831 "
41832 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
41833   cat >>confdefs.h <<_ACEOF
41834 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
41835 _ACEOF
41836 
41837 fi
41838 
41839 done
41840 
41841 
41842 
41843   ###############################################################################
41844   #
41845   # Now we check if libjvm.so will use 32 or 64 bit pointers for the C/C++ code.
41846   # (The JVM can use 32 or 64 bit Java pointers but that decision
41847   # is made at runtime.)
41848   #
41849 
41850   if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xaix; then
41851     # Always specify -m flag on Solaris
41852     # And -q on AIX because otherwise the compiler produces 32-bit objects by default
41853 
41854   # When we add flags to the "official" CFLAGS etc, we need to
41855   # keep track of these additions in ADDED_CFLAGS etc. These
41856   # will later be checked to make sure only controlled additions
41857   # have been made to CFLAGS etc.
41858   ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41859   ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41860   ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41861 
41862   CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
41863   CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
41864   LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
41865 
41866   CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
41867   CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
41868   LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
41869 
41870   elif test "x$COMPILE_TYPE" = xreduced; then
41871     if test "x$OPENJDK_TARGET_OS_TYPE" = xunix; then
41872       # Specify -m if running reduced on unix platforms
41873 
41874   # When we add flags to the "official" CFLAGS etc, we need to
41875   # keep track of these additions in ADDED_CFLAGS etc. These
41876   # will later be checked to make sure only controlled additions
41877   # have been made to CFLAGS etc.
41878   ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41879   ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41880   ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41881 
41882   CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
41883   CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
41884   LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
41885 
41886   CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
41887   CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
41888   LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
41889 
41890     fi
41891   fi
41892 
41893   # Make compilation sanity check
41894   for ac_header in stdio.h
41895 do :
41896   ac_fn_cxx_check_header_mongrel "$LINENO" "stdio.h" "ac_cv_header_stdio_h" "$ac_includes_default"
41897 if test "x$ac_cv_header_stdio_h" = xyes; then :
41898   cat >>confdefs.h <<_ACEOF
41899 #define HAVE_STDIO_H 1
41900 _ACEOF
41901 
41902 else
41903 
41904     { $as_echo "$as_me:${as_lineno-$LINENO}: Failed to compile stdio.h. This likely implies missing compile dependencies." >&5
41905 $as_echo "$as_me: Failed to compile stdio.h. This likely implies missing compile dependencies." >&6;}
41906     if test "x$COMPILE_TYPE" = xreduced; then
41907       { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed." >&5
41908 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed." >&6;}
41909     elif test "x$COMPILE_TYPE" = xcross; then
41910       { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5
41911 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;}
41912     fi
41913     as_fn_error $? "Cannot continue." "$LINENO" 5
41914 
41915 fi
41916 
41917 done
41918 
41919 
41920   # The cast to long int works around a bug in the HP C Compiler
41921 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
41922 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
41923 # This bug is HP SR number 8606223364.
41924 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5
41925 $as_echo_n "checking size of int *... " >&6; }
41926 if ${ac_cv_sizeof_int_p+:} false; then :
41927   $as_echo_n "(cached) " >&6
41928 else
41929   if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p"        "$ac_includes_default"; then :
41930 
41931 else
41932   if test "$ac_cv_type_int_p" = yes; then
41933      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
41934 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
41935 as_fn_error 77 "cannot compute sizeof (int *)
41936 See \`config.log' for more details" "$LINENO" 5; }
41937    else
41938      ac_cv_sizeof_int_p=0
41939    fi
41940 fi
41941 
41942 fi
41943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5
41944 $as_echo "$ac_cv_sizeof_int_p" >&6; }
41945 
41946 
41947 
41948 cat >>confdefs.h <<_ACEOF
41949 #define SIZEOF_INT_P $ac_cv_sizeof_int_p
41950 _ACEOF
41951 
41952 
41953 
41954   # AC_CHECK_SIZEOF defines 'ac_cv_sizeof_int_p' to hold the number of bytes used by an 'int*'
41955   if test "x$ac_cv_sizeof_int_p" = x; then
41956     # The test failed, lets stick to the assumed value.
41957     { $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
41958 $as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;}
41959   else
41960     TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p`
41961 
41962     if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then
41963       # This situation may happen on 64-bit platforms where the compiler by default only generates 32-bit objects
41964       # Let's try to implicitely set the compilers target architecture and retry the test
41965       { $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
41966 $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;}
41967       { $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
41968 $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;}
41969 
41970   # When we add flags to the "official" CFLAGS etc, we need to
41971   # keep track of these additions in ADDED_CFLAGS etc. These
41972   # will later be checked to make sure only controlled additions
41973   # have been made to CFLAGS etc.
41974   ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41975   ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41976   ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
41977 
41978   CFLAGS="${CFLAGS}${ADDED_CFLAGS}"
41979   CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}"
41980   LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}"
41981 
41982   CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}"
41983   CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}"
41984   LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}"
41985 
41986 
41987       # We have to unset 'ac_cv_sizeof_int_p' first, otherwise AC_CHECK_SIZEOF will use the previously cached value!
41988       unset ac_cv_sizeof_int_p
41989       # And we have to undef the definition of SIZEOF_INT_P in confdefs.h by the previous invocation of AC_CHECK_SIZEOF
41990       cat >>confdefs.h <<_ACEOF
41991 #undef SIZEOF_INT_P
41992 _ACEOF
41993 
41994       # The cast to long int works around a bug in the HP C Compiler
41995 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
41996 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
41997 # This bug is HP SR number 8606223364.
41998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5
41999 $as_echo_n "checking size of int *... " >&6; }
42000 if ${ac_cv_sizeof_int_p+:} false; then :
42001   $as_echo_n "(cached) " >&6
42002 else
42003   if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p"        "$ac_includes_default"; then :
42004 
42005 else
42006   if test "$ac_cv_type_int_p" = yes; then
42007      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
42008 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
42009 as_fn_error 77 "cannot compute sizeof (int *)
42010 See \`config.log' for more details" "$LINENO" 5; }
42011    else
42012      ac_cv_sizeof_int_p=0
42013    fi
42014 fi
42015 
42016 fi
42017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5
42018 $as_echo "$ac_cv_sizeof_int_p" >&6; }
42019 
42020 
42021 
42022 cat >>confdefs.h <<_ACEOF
42023 #define SIZEOF_INT_P $ac_cv_sizeof_int_p
42024 _ACEOF
42025 
42026 
42027 
42028       TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p`
42029 
42030       if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then
42031         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
42032       fi
42033     fi
42034   fi
42035 
42036   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target address size" >&5
42037 $as_echo_n "checking for target address size... " >&6; }
42038   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_CPU_BITS bits" >&5
42039 $as_echo "$OPENJDK_TARGET_CPU_BITS bits" >&6; }
42040 
42041 
42042   ###############################################################################
42043   #
42044   # Is the target little of big endian?
42045   #
42046    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
42047 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
42048 if ${ac_cv_c_bigendian+:} false; then :
42049   $as_echo_n "(cached) " >&6
42050 else
42051   ac_cv_c_bigendian=unknown
42052     # See if we're dealing with a universal compiler.
42053     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42054 /* end confdefs.h.  */
42055 #ifndef __APPLE_CC__
42056                not a universal capable compiler
42057              #endif
42058              typedef int dummy;
42059 
42060 _ACEOF
42061 if ac_fn_cxx_try_compile "$LINENO"; then :
42062 
42063         # Check for potential -arch flags.  It is not universal unless
42064         # there are at least two -arch flags with different values.
42065         ac_arch=
42066         ac_prev=
42067         for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
42068          if test -n "$ac_prev"; then
42069            case $ac_word in
42070              i?86 | x86_64 | ppc | ppc64)
42071                if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
42072                  ac_arch=$ac_word
42073                else
42074                  ac_cv_c_bigendian=universal
42075                  break
42076                fi
42077                ;;
42078            esac
42079            ac_prev=
42080          elif test "x$ac_word" = "x-arch"; then
42081            ac_prev=arch
42082          fi
42083        done
42084 fi
42085 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
42086     if test $ac_cv_c_bigendian = unknown; then
42087       # See if sys/param.h defines the BYTE_ORDER macro.
42088       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42089 /* end confdefs.h.  */
42090 #include <sys/types.h>
42091              #include <sys/param.h>
42092 
42093 int
42094 main ()
42095 {
42096 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
42097                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
42098                      && LITTLE_ENDIAN)
42099               bogus endian macros
42100              #endif
42101 
42102   ;
42103   return 0;
42104 }
42105 _ACEOF
42106 if ac_fn_cxx_try_compile "$LINENO"; then :
42107   # It does; now see whether it defined to BIG_ENDIAN or not.
42108          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42109 /* end confdefs.h.  */
42110 #include <sys/types.h>
42111                 #include <sys/param.h>
42112 
42113 int
42114 main ()
42115 {
42116 #if BYTE_ORDER != BIG_ENDIAN
42117                  not big endian
42118                 #endif
42119 
42120   ;
42121   return 0;
42122 }
42123 _ACEOF
42124 if ac_fn_cxx_try_compile "$LINENO"; then :
42125   ac_cv_c_bigendian=yes
42126 else
42127   ac_cv_c_bigendian=no
42128 fi
42129 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
42130 fi
42131 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
42132     fi
42133     if test $ac_cv_c_bigendian = unknown; then
42134       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
42135       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42136 /* end confdefs.h.  */
42137 #include <limits.h>
42138 
42139 int
42140 main ()
42141 {
42142 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
42143               bogus endian macros
42144              #endif
42145 
42146   ;
42147   return 0;
42148 }
42149 _ACEOF
42150 if ac_fn_cxx_try_compile "$LINENO"; then :
42151   # It does; now see whether it defined to _BIG_ENDIAN or not.
42152          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42153 /* end confdefs.h.  */
42154 #include <limits.h>
42155 
42156 int
42157 main ()
42158 {
42159 #ifndef _BIG_ENDIAN
42160                  not big endian
42161                 #endif
42162 
42163   ;
42164   return 0;
42165 }
42166 _ACEOF
42167 if ac_fn_cxx_try_compile "$LINENO"; then :
42168   ac_cv_c_bigendian=yes
42169 else
42170   ac_cv_c_bigendian=no
42171 fi
42172 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
42173 fi
42174 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
42175     fi
42176     if test $ac_cv_c_bigendian = unknown; then
42177       # Compile a test program.
42178       if test "$cross_compiling" = yes; then :
42179   # Try to guess by grepping values from an object file.
42180          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42181 /* end confdefs.h.  */
42182 short int ascii_mm[] =
42183                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
42184                 short int ascii_ii[] =
42185                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
42186                 int use_ascii (int i) {
42187                   return ascii_mm[i] + ascii_ii[i];
42188                 }
42189                 short int ebcdic_ii[] =
42190                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
42191                 short int ebcdic_mm[] =
42192                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
42193                 int use_ebcdic (int i) {
42194                   return ebcdic_mm[i] + ebcdic_ii[i];
42195                 }
42196                 extern int foo;
42197 
42198 int
42199 main ()
42200 {
42201 return use_ascii (foo) == use_ebcdic (foo);
42202   ;
42203   return 0;
42204 }
42205 _ACEOF
42206 if ac_fn_cxx_try_compile "$LINENO"; then :
42207   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
42208               ac_cv_c_bigendian=yes
42209             fi
42210             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
42211               if test "$ac_cv_c_bigendian" = unknown; then
42212                 ac_cv_c_bigendian=no
42213               else
42214                 # finding both strings is unlikely to happen, but who knows?
42215                 ac_cv_c_bigendian=unknown
42216               fi
42217             fi
42218 fi
42219 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
42220 else
42221   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42222 /* end confdefs.h.  */
42223 $ac_includes_default
42224 int
42225 main ()
42226 {
42227 
42228              /* Are we little or big endian?  From Harbison&Steele.  */
42229              union
42230              {
42231                long int l;
42232                char c[sizeof (long int)];
42233              } u;
42234              u.l = 1;
42235              return u.c[sizeof (long int) - 1] == 1;
42236 
42237   ;
42238   return 0;
42239 }
42240 _ACEOF
42241 if ac_fn_cxx_try_run "$LINENO"; then :
42242   ac_cv_c_bigendian=no
42243 else
42244   ac_cv_c_bigendian=yes
42245 fi
42246 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
42247   conftest.$ac_objext conftest.beam conftest.$ac_ext
42248 fi
42249 
42250     fi
42251 fi
42252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
42253 $as_echo "$ac_cv_c_bigendian" >&6; }
42254  case $ac_cv_c_bigendian in #(
42255    yes)
42256      ENDIAN="big";; #(
42257    no)
42258      ENDIAN="little" ;; #(
42259    universal)
42260      ENDIAN="universal_endianness"
42261      ;; #(
42262    *)
42263      ENDIAN="unknown" ;;
42264  esac
42265 
42266 
42267   if test "x$ENDIAN" = xuniversal_endianness; then
42268     as_fn_error $? "Building with both big and little endianness is not supported" "$LINENO" 5
42269   fi
42270   if test "x$ENDIAN" != "x$OPENJDK_TARGET_CPU_ENDIAN"; then
42271     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
42272   fi
42273 
42274 
42275 # Configure flags for the tools
42276 
42277   ###############################################################################
42278   #
42279   # How to compile shared libraries.
42280   #
42281 
42282   if test "x$TOOLCHAIN_TYPE" = xgcc; then
42283     PICFLAG="-fPIC"
42284     C_FLAG_REORDER=''
42285     CXX_FLAG_REORDER=''
42286 
42287     if test "x$OPENJDK_TARGET_OS" = xmacosx; then
42288       # Linking is different on MacOSX
42289       SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG"
42290       SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker @loader_path/.'
42291       SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN"
42292       SET_SHARED_LIBRARY_NAME='-Xlinker -install_name -Xlinker @rpath/$1'
42293       SET_SHARED_LIBRARY_MAPFILE=''
42294     else
42295       # Default works for linux, might work on other platforms as well.
42296       SHARED_LIBRARY_FLAGS='-shared'
42297       SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker \$$$$ORIGIN$1'
42298       SET_SHARED_LIBRARY_ORIGIN="-Xlinker -z -Xlinker origin $SET_EXECUTABLE_ORIGIN"
42299       SET_SHARED_LIBRARY_NAME='-Xlinker -soname=$1'
42300       SET_SHARED_LIBRARY_MAPFILE='-Xlinker -version-script=$1'
42301     fi
42302   elif test "x$TOOLCHAIN_TYPE" = xclang; then
42303     PICFLAG=''
42304     C_FLAG_REORDER=''
42305     CXX_FLAG_REORDER=''
42306 
42307     if test "x$OPENJDK_TARGET_OS" = xmacosx; then
42308       # Linking is different on MacOSX
42309       SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG"
42310       SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker @loader_path/.'
42311       SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN"
42312       SET_SHARED_LIBRARY_NAME='-Xlinker -install_name -Xlinker @rpath/$1'
42313       SET_SHARED_LIBRARY_MAPFILE=''
42314     else
42315       # Default works for linux, might work on other platforms as well.
42316       SHARED_LIBRARY_FLAGS='-shared'
42317       SET_EXECUTABLE_ORIGIN='-Xlinker -rpath -Xlinker \$$$$ORIGIN$1'
42318       SET_SHARED_LIBRARY_ORIGIN="-Xlinker -z -Xlinker origin $SET_EXECUTABLE_ORIGIN"
42319       SET_SHARED_LIBRARY_NAME='-Xlinker -soname=$1'
42320       SET_SHARED_LIBRARY_MAPFILE='-Xlinker -version-script=$1'
42321     fi
42322   elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
42323     PICFLAG="-KPIC"
42324     C_FLAG_REORDER='-xF'
42325     CXX_FLAG_REORDER='-xF'
42326     SHARED_LIBRARY_FLAGS="-G"
42327     SET_EXECUTABLE_ORIGIN='-R\$$$$ORIGIN$1'
42328     SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN"
42329     SET_SHARED_LIBRARY_NAME=''
42330     SET_SHARED_LIBRARY_MAPFILE='-M$1'
42331   elif test "x$TOOLCHAIN_TYPE" = xxlc; then
42332     PICFLAG="-qpic=large"
42333     C_FLAG_REORDER=''
42334     CXX_FLAG_REORDER=''
42335     SHARED_LIBRARY_FLAGS="-qmkshrobj"
42336     SET_EXECUTABLE_ORIGIN=""
42337     SET_SHARED_LIBRARY_ORIGIN=''
42338     SET_SHARED_LIBRARY_NAME=''
42339     SET_SHARED_LIBRARY_MAPFILE=''
42340   elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
42341     PICFLAG=""
42342     C_FLAG_REORDER=''
42343     CXX_FLAG_REORDER=''
42344     SHARED_LIBRARY_FLAGS="-LD"
42345     SET_EXECUTABLE_ORIGIN=''
42346     SET_SHARED_LIBRARY_ORIGIN=''
42347     SET_SHARED_LIBRARY_NAME=''
42348     SET_SHARED_LIBRARY_MAPFILE=''
42349   fi
42350 
42351 
42352 
42353 
42354 
42355 
42356 
42357 
42358 
42359   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
42360     CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__"
42361     CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__"
42362     CFLAGS_JDKLIB_EXTRA='-xstrconst'
42363   fi
42364   # The (cross) compiler is now configured, we can now test capabilities
42365   # of the target platform.
42366 
42367 
42368 
42369   ###############################################################################
42370   #
42371   # Setup the opt flags for different compilers
42372   # and different operating systems.
42373   #
42374 
42375   # FIXME: this was indirectly the old default, but just inherited.
42376   # if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
42377   #   C_FLAG_DEPS="-MMD -MF"
42378   # fi
42379 
42380   # Generate make dependency files
42381   if test "x$TOOLCHAIN_TYPE" = xgcc; then
42382     C_FLAG_DEPS="-MMD -MF"
42383   elif test "x$TOOLCHAIN_TYPE" = xclang; then
42384     C_FLAG_DEPS="-MMD -MF"
42385   elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
42386     C_FLAG_DEPS="-xMMD -xMF"
42387   elif test "x$TOOLCHAIN_TYPE" = xxlc; then
42388     C_FLAG_DEPS="-qmakedep=gcc -MF"
42389   fi
42390   CXX_FLAG_DEPS="$C_FLAG_DEPS"
42391 
42392 
42393 
42394   # Debug symbols
42395   if test "x$TOOLCHAIN_TYPE" = xgcc; then
42396     if test "x$OPENJDK_TARGET_CPU_BITS" = "x64" && test "x$DEBUG_LEVEL" = "xfastdebug"; then
42397       # reduce from default "-g2" option to save space
42398       CFLAGS_DEBUG_SYMBOLS="-g1"
42399       CXXFLAGS_DEBUG_SYMBOLS="-g1"
42400     else
42401       CFLAGS_DEBUG_SYMBOLS="-g"
42402       CXXFLAGS_DEBUG_SYMBOLS="-g"
42403     fi
42404   elif test "x$TOOLCHAIN_TYPE" = xclang; then
42405     CFLAGS_DEBUG_SYMBOLS="-g"
42406     CXXFLAGS_DEBUG_SYMBOLS="-g"
42407   elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
42408     CFLAGS_DEBUG_SYMBOLS="-g -xs"
42409     # FIXME: likely a bug, this disables debug symbols rather than enables them
42410     CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs"
42411   elif test "x$TOOLCHAIN_TYPE" = xxlc; then
42412     CFLAGS_DEBUG_SYMBOLS="-g"
42413     CXXFLAGS_DEBUG_SYMBOLS="-g"
42414   fi
42415 
42416 
42417 
42418   # bounds, memory and behavior checking options
42419   if test "x$TOOLCHAIN_TYPE" = xgcc; then
42420     case $DEBUG_LEVEL in
42421     release )
42422       # no adjustment
42423       ;;
42424     fastdebug )
42425       # no adjustment
42426       ;;
42427     slowdebug )
42428       # Add runtime stack smashing and undefined behavior checks
42429       CFLAGS_DEBUG_OPTIONS="-fstack-protector-all --param ssp-buffer-size=1"
42430       CXXFLAGS_DEBUG_OPTIONS="-fstack-protector-all --param ssp-buffer-size=1"
42431       if test "x$HAS_CFLAG_DETECT_UNDEFINED_BEHAVIOR" = "xtrue"; then
42432         CFLAGS_DEBUG_OPTIONS="$CFLAGS_DEBUG_OPTIONS  $CFLAG_DETECT_UNDEFINED_BEHAVIOR_FLAG"
42433         CXXFLAGS_DEBUG_OPTIONS="$CXXFLAGS_DEBUG_OPTIONS $CFLAG_DETECT_UNDEFINED_BEHAVIsOR_FLAG"
42434       fi
42435       ;;
42436     esac
42437   fi
42438 
42439 
42440 
42441   # Optimization levels
42442   if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
42443     CC_HIGHEST="$CC_HIGHEST -fns -fsimple -fsingle -xbuiltin=%all -xdepend -xrestrict -xlibmil"
42444 
42445     if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then
42446       # FIXME: seems we always set -xregs=no%frameptr; put it elsewhere more global?
42447       C_O_FLAG_HIGHEST="-xO4 -Wu,-O4~yz $CC_HIGHEST -xalias_level=basic -xregs=no%frameptr"
42448       C_O_FLAG_HI="-xO4 -Wu,-O4~yz -xregs=no%frameptr"
42449       C_O_FLAG_NORM="-xO2 -Wu,-O2~yz -xregs=no%frameptr"
42450       C_O_FLAG_DEBUG="-xregs=no%frameptr"
42451       C_O_FLAG_NONE="-xregs=no%frameptr"
42452       CXX_O_FLAG_HIGHEST="-xO4 -Qoption ube -O4~yz $CC_HIGHEST -xregs=no%frameptr"
42453       CXX_O_FLAG_HI="-xO4 -Qoption ube -O4~yz -xregs=no%frameptr"
42454       CXX_O_FLAG_NORM="-xO2 -Qoption ube -O2~yz -xregs=no%frameptr"
42455       CXX_O_FLAG_DEBUG="-xregs=no%frameptr"
42456       CXX_O_FLAG_NONE="-xregs=no%frameptr"
42457       if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then
42458         C_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST -xchip=pentium"
42459         CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HIGHEST -xchip=pentium"
42460       fi
42461     elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then
42462       C_O_FLAG_HIGHEST="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0 $CC_HIGHEST -xalias_level=basic -xprefetch=auto,explicit -xchip=ultra"
42463       C_O_FLAG_HI="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0"
42464       C_O_FLAG_NORM="-xO2 -Wc,-Qrm-s -Wc,-Qiselect-T0"
42465       C_O_FLAG_DEBUG=""
42466       C_O_FLAG_NONE=""
42467       CXX_O_FLAG_HIGHEST="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra"
42468       CXX_O_FLAG_HI="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0"
42469       CXX_O_FLAG_NORM="-xO2 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0"
42470       C_O_FLAG_DEBUG=""
42471       CXX_O_FLAG_NONE=""
42472     fi
42473   else
42474     # The remaining toolchains share opt flags between CC and CXX;
42475     # setup for C and duplicate afterwards.
42476     if test "x$TOOLCHAIN_TYPE" = xgcc; then
42477       if test "x$OPENJDK_TARGET_OS" = xmacosx; then
42478         # On MacOSX we optimize for size, something
42479         # we should do for all platforms?
42480         C_O_FLAG_HIGHEST="-Os"
42481         C_O_FLAG_HI="-Os"
42482         C_O_FLAG_NORM="-Os"
42483       else
42484         C_O_FLAG_HIGHEST="-O3"
42485         C_O_FLAG_HI="-O3"
42486         C_O_FLAG_NORM="-O2"
42487       fi
42488       C_O_FLAG_DEBUG="-O0"
42489       C_O_FLAG_NONE="-O0"
42490     elif test "x$TOOLCHAIN_TYPE" = xclang; then
42491       if test "x$OPENJDK_TARGET_OS" = xmacosx; then
42492         # On MacOSX we optimize for size, something
42493         # we should do for all platforms?
42494         C_O_FLAG_HIGHEST="-Os"
42495         C_O_FLAG_HI="-Os"
42496         C_O_FLAG_NORM="-Os"
42497       else
42498         C_O_FLAG_HIGHEST="-O3"
42499         C_O_FLAG_HI="-O3"
42500         C_O_FLAG_NORM="-O2"
42501       fi
42502       C_O_FLAG_DEBUG="-O0"
42503       C_O_FLAG_NONE="-O0"
42504     elif test "x$TOOLCHAIN_TYPE" = xxlc; then
42505       C_O_FLAG_HIGHEST="-O3"
42506       C_O_FLAG_HI="-O3 -qstrict"
42507       C_O_FLAG_NORM="-O2"
42508       C_O_FLAG_DEBUG="-qnoopt"
42509       C_O_FLAG_NONE="-qnoop"
42510     elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
42511       C_O_FLAG_HIGHEST="-O2"
42512       C_O_FLAG_HI="-O1"
42513       C_O_FLAG_NORM="-O1"
42514       C_O_FLAG_DEBUG="-Od"
42515       C_O_FLAG_NONE="-Od"
42516     fi
42517     CXX_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST"
42518     CXX_O_FLAG_HI="$C_O_FLAG_HI"
42519     CXX_O_FLAG_NORM="$C_O_FLAG_NORM"
42520     CXX_O_FLAG_DEBUG="$C_O_FLAG_DEBUG"
42521     CXX_O_FLAG_NONE="$C_O_FLAG_NONE"
42522   fi
42523 
42524   # Adjust optimization flags according to debug level.
42525   case $DEBUG_LEVEL in
42526     release )
42527       # no adjustment
42528       ;;
42529     fastdebug )
42530       # Not quite so much optimization
42531       C_O_FLAG_HI="$C_O_FLAG_NORM"
42532       CXX_O_FLAG_HI="$CXX_O_FLAG_NORM"
42533       ;;
42534     slowdebug )
42535       # Disable optimization
42536       C_O_FLAG_HIGHEST="$C_O_FLAG_DEBUG"
42537       C_O_FLAG_HI="$C_O_FLAG_DEBUG"
42538       C_O_FLAG_NORM="$C_O_FLAG_DEBUG"
42539       CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_DEBUG"
42540       CXX_O_FLAG_HI="$CXX_O_FLAG_DEBUG"
42541       CXX_O_FLAG_NORM="$CXX_O_FLAG_DEBUG"
42542       ;;
42543   esac
42544 
42545 
42546 
42547 
42548 
42549 
42550 
42551 
42552 
42553 
42554 
42555 
42556 
42557   # Special extras...
42558   if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
42559     if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then
42560       CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -xregs=no%appl"
42561       CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl"
42562     fi
42563   elif test "x$TOOLCHAIN_TYPE" = xxlc; then
42564     LDFLAGS_JDK="${LDFLAGS_JDK} -q64 -brtl -bnolibpath -liconv -bexpall"
42565     CFLAGS_JDK="${CFLAGS_JDK} -qchars=signed -q64 -qfullpath -qsaveopt"
42566     CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -q64 -qfullpath -qsaveopt"
42567   fi
42568 
42569   if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then
42570     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5
42571 $as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;}
42572   fi
42573 
42574   if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then
42575     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5
42576 $as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;}
42577   fi
42578 
42579   if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then
42580     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5
42581 $as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;}
42582   fi
42583 
42584 
42585 # Check whether --with-extra-cflags was given.
42586 if test "${with_extra_cflags+set}" = set; then :
42587   withval=$with_extra_cflags;
42588 fi
42589 
42590 
42591 
42592 # Check whether --with-extra-cxxflags was given.
42593 if test "${with_extra_cxxflags+set}" = set; then :
42594   withval=$with_extra_cxxflags;
42595 fi
42596 
42597 
42598 
42599 # Check whether --with-extra-ldflags was given.
42600 if test "${with_extra_ldflags+set}" = set; then :
42601   withval=$with_extra_ldflags;
42602 fi
42603 
42604 
42605   CFLAGS_JDK="${CFLAGS_JDK} $with_extra_cflags"
42606   CXXFLAGS_JDK="${CXXFLAGS_JDK} $with_extra_cxxflags"
42607   LDFLAGS_JDK="${LDFLAGS_JDK} $with_extra_ldflags"
42608 
42609   # Hotspot needs these set in their legacy form
42610   LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $with_extra_cflags"
42611   LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $with_extra_cxxflags"
42612   LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $with_extra_ldflags"
42613 
42614 
42615 
42616 
42617 
42618   ###############################################################################
42619   #
42620   # Now setup the CFLAGS and LDFLAGS for the JDK build.
42621   # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build.
42622   #
42623 
42624   # Setup compiler/platform specific flags into
42625   #    CFLAGS_JDK    - C Compiler flags
42626   #    CXXFLAGS_JDK  - C++ Compiler flags
42627   #    COMMON_CCXXFLAGS_JDK - common to C and C++
42628   if test "x$TOOLCHAIN_TYPE" = xgcc; then
42629     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wno-parentheses -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \
42630         -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE"
42631     case $OPENJDK_TARGET_CPU_ARCH in
42632       arm )
42633         # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing
42634         CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing"
42635         ;;
42636       ppc )
42637         # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing
42638         CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing"
42639         ;;
42640       * )
42641         COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer"
42642         CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing"
42643         ;;
42644     esac
42645   elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
42646     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS"
42647     if test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then
42648       COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB"
42649       CFLAGS_JDK="$CFLAGS_JDK -erroff=E_BAD_PRAGMA_PACK_VALUE"
42650     fi
42651 
42652     CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal"
42653     CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib"
42654   elif test "x$TOOLCHAIN_TYPE" = xxlc; then
42655     CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC"
42656     CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC"
42657   elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
42658     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Zi -MD -Zc:wchar_t- -W3 -wd4800 \
42659     -D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB -DWIN32_LEAN_AND_MEAN \
42660     -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \
42661     -DWIN32 -DIAL"
42662     if test "x$OPENJDK_TARGET_CPU" = xx86_64; then
42663       COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64"
42664     else
42665       COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86"
42666     fi
42667   fi
42668 
42669   ###############################################################################
42670 
42671   # Adjust flags according to debug level.
42672   case $DEBUG_LEVEL in
42673     fastdebug | slowdebug )
42674       CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS"
42675       CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS"
42676       JAVAC_FLAGS="$JAVAC_FLAGS -g"
42677       ;;
42678     release )
42679       ;;
42680     * )
42681       as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5
42682       ;;
42683   esac
42684 
42685   # Setup LP64
42686   COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK $ADD_LP64"
42687 
42688   # Set some common defines. These works for all compilers, but assume
42689   # -D is universally accepted.
42690 
42691   # Setup endianness
42692   if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then
42693     # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the
42694     #   Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN
42695     #   (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h).
42696     #   Note: -Dmacro         is the same as    #define macro 1
42697     #         -Dmacro=        is the same as    #define macro
42698     if test "x$OPENJDK_TARGET_OS" = xsolaris; then
42699       COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN="
42700     else
42701       COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN"
42702     fi
42703   else
42704     # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they
42705     # are defined in the system?
42706     if test "x$OPENJDK_TARGET_OS" = xsolaris; then
42707       COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN="
42708     else
42709       COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN"
42710     fi
42711   fi
42712 
42713   # Setup target OS define. Use OS target name but in upper case.
42714   OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
42715   COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE"
42716 
42717   # Setup target CPU
42718   COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY"
42719 
42720   # Setup debug/release defines
42721   if test "x$DEBUG_LEVEL" = xrelease; then
42722     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DNDEBUG"
42723     if test "x$OPENJDK_TARGET_OS" = xsolaris; then
42724       COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DTRIMMED"
42725     fi
42726   else
42727     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DDEBUG"
42728   fi
42729 
42730   # Setup release name
42731   COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DRELEASE='\"\$(RELEASE)\"'"
42732 
42733 
42734   # Set some additional per-OS defines.
42735   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
42736     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT"
42737   elif test "x$OPENJDK_TARGET_OS" = xaix; then
42738     # FIXME: PPC64 should not be here.
42739     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DPPC64"
42740   elif test "x$OPENJDK_TARGET_OS" = xbsd; then
42741     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE"
42742   fi
42743 
42744   # Additional macosx handling
42745   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
42746     # Setting these parameters makes it an error to link to macosx APIs that are
42747     # newer than the given OS version and makes the linked binaries compatible
42748     # even if built on a newer version of the OS.
42749     # The expected format is X.Y.Z
42750     MACOSX_VERSION_MIN=10.7.0
42751 
42752 
42753     # The macro takes the version with no dots, ex: 1070
42754     # Let the flags variables get resolved in make for easier override on make
42755     # command line.
42756     COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
42757     LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)"
42758   fi
42759 
42760   # Setup some hard coded includes
42761   COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \
42762       -I${JDK_TOPDIR}/src/java.base/share/native/include \
42763       -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS/native/include \
42764       -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/include"
42765 
42766   # The shared libraries are compiled using the picflag.
42767   CFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA"
42768   CXXFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA "
42769 
42770   # Executable flags
42771   CFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK"
42772   CXXFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK"
42773 
42774 
42775 
42776 
42777 
42778 
42779   # Setup LDFLAGS et al.
42780   #
42781 
42782   # Now this is odd. The JDK native libraries have to link against libjvm.so
42783   # On 32-bit machines there is normally two distinct libjvm.so:s, client and server.
42784   # Which should we link to? Are we lucky enough that the binary api to the libjvm.so library
42785   # is identical for client and server? Yes. Which is picked at runtime (client or server)?
42786   # Neither, since the chosen libjvm.so has already been loaded by the launcher, all the following
42787   # libraries will link to whatever is in memory. Yuck.
42788   #
42789   # Thus we offer the compiler to find libjvm.so first in server then in client. It works. Ugh.
42790   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
42791     LDFLAGS_JDK="$LDFLAGS_JDK -nologo -opt:ref -incremental:no"
42792     if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then
42793       LDFLAGS_JDK="$LDFLAGS_JDK -safeseh"
42794     fi
42795     # TODO: make -debug optional "--disable-full-debug-symbols"
42796     LDFLAGS_JDK="$LDFLAGS_JDK -debug"
42797   elif test "x$TOOLCHAIN_TYPE" = xgcc; then
42798     # If this is a --hash-style=gnu system, use --hash-style=both, why?
42799     # We have previously set HAS_GNU_HASH if this is the case
42800     if test -n "$HAS_GNU_HASH"; then
42801       LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker --hash-style=both"
42802     fi
42803     if test "x$OPENJDK_TARGET_OS" = xlinux; then
42804       # And since we now know that the linker is gnu, then add -z defs, to forbid
42805       # undefined symbols in object files.
42806       LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker -z -Xlinker defs"
42807       case $DEBUG_LEVEL in
42808         release )
42809           # tell linker to optimize libraries.
42810           # Should this be supplied to the OSS linker as well?
42811           LDFLAGS_JDK="${LDFLAGS_JDK} -Xlinker -O1"
42812           ;;
42813         slowdebug )
42814           if test "x$HAS_LINKER_NOW" = "xtrue"; then
42815             # do relocations at load
42816             LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_NOW_FLAG"
42817             LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_NOW_FLAG"
42818           fi
42819           if test "x$HAS_LINKER_RELRO" = "xtrue"; then
42820             # mark relocations read only
42821             LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG"
42822             LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG"
42823           fi
42824           ;;
42825         fastdebug )
42826           if test "x$HAS_LINKER_RELRO" = "xtrue"; then
42827             # mark relocations read only
42828             LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG"
42829             LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG"
42830           fi
42831           ;;
42832         * )
42833           as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5
42834           ;;
42835         esac
42836     fi
42837   elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then
42838     LDFLAGS_JDK="$LDFLAGS_JDK -z defs -xildoff -ztext"
42839     LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK -norunpath -xnolib"
42840   fi
42841 
42842   if test "x$TOOLCHAIN_TYPE" = xgcc || test "x$TOOLCHAIN_TYPE" = xclang; then
42843     # If undefined behaviour detection is enabled then we need to tell linker.
42844     case $DEBUG_LEVEL in
42845       release | fastdebug )
42846         ;;
42847       slowdebug )
42848         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $HAS_CFLAG_DETECT_UNDEFINED_BEHAVIOR" >&5
42849 $as_echo "$as_me: WARNING: $HAS_CFLAG_DETECT_UNDEFINED_BEHAVIOR" >&2;}
42850         if test "x$HAS_CFLAG_DETECT_UNDEFINED_BEHAVIOR" = "xtrue"; then
42851           # enable undefined behaviour checking
42852           LDFLAGS_JDK="$LDFLAGS_JDK `$ECHO -n $CFLAG_DETECT_UNDEFINED_BEHAVIOR_FLAG | sed -e "s/ *\(^ \+\)/ -Xlinker \1/g"`"
42853           LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK `$ECHO -n $CFLAG_DETECT_UNDEFINED_BEHAVIOR_FLAG | sed -e "s/ *\(^ \+\)/ -Xlinker \1/g"`"
42854         fi
42855         ;;
42856       * )
42857         as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5
42858         ;;
42859     esac
42860   fi
42861 
42862   # Customize LDFLAGS for executables
42863 
42864   LDFLAGS_JDKEXE="${LDFLAGS_JDK}"
42865 
42866   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
42867     if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then
42868       LDFLAGS_STACK_SIZE=1048576
42869     else
42870       LDFLAGS_STACK_SIZE=327680
42871     fi
42872     LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE"
42873   elif test "x$OPENJDK_TARGET_OS" = xlinux; then
42874     LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Xlinker --allow-shlib-undefined"
42875   fi
42876 
42877   # Customize LDFLAGS for libs
42878   LDFLAGS_JDKLIB="${LDFLAGS_JDK}"
42879 
42880   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
42881     LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -dll -libpath:${JDK_OUTPUTDIR}/lib"
42882     LDFLAGS_JDKLIB_SUFFIX=""
42883   else
42884     LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB}  ${SHARED_LIBRARY_FLAGS} \
42885         -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}"
42886 
42887     # On some platforms (mac) the linker warns about non existing -L dirs.
42888     # Add server first if available. Linking aginst client does not always produce the same results.
42889     # Only add client dir if client is being built. Add minimal (note not minimal1) if only building minimal1.
42890     # Default to server for other variants.
42891     if test "x$JVM_VARIANT_SERVER" = xtrue; then
42892       LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/server"
42893     elif test "x$JVM_VARIANT_CLIENT" = xtrue; then
42894       LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/client"
42895     elif test "x$JVM_VARIANT_MINIMAL1" = xtrue; then
42896       LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/minimal"
42897     else
42898       LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${JDK_OUTPUTDIR}/lib${OPENJDK_TARGET_CPU_LIBDIR}/server"
42899     fi
42900 
42901     LDFLAGS_JDKLIB_SUFFIX="-ljava -ljvm"
42902     if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
42903       LDFLAGS_JDKLIB_SUFFIX="$LDFLAGS_JDKLIB_SUFFIX -lc"
42904     fi
42905   fi
42906 
42907 
42908 
42909 
42910 
42911 
42912 
42913 
42914   # Some Zero and Shark settings.
42915   # ZERO_ARCHFLAG tells the compiler which mode to build for
42916   case "${OPENJDK_TARGET_CPU}" in
42917     s390)
42918       ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}31"
42919       ;;
42920     *)
42921       ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
42922   esac
42923 
42924   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"$ZERO_ARCHFLAG\"" >&5
42925 $as_echo_n "checking if compiler supports \"$ZERO_ARCHFLAG\"... " >&6; }
42926   supports=yes
42927 
42928   saved_cflags="$CFLAGS"
42929   CFLAGS="$CFLAGS $ZERO_ARCHFLAG"
42930   ac_ext=c
42931 ac_cpp='$CPP $CPPFLAGS'
42932 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42933 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42934 ac_compiler_gnu=$ac_cv_c_compiler_gnu
42935 
42936   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42937 /* end confdefs.h.  */
42938 int i;
42939 _ACEOF
42940 if ac_fn_c_try_compile "$LINENO"; then :
42941 
42942 else
42943   supports=no
42944 fi
42945 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
42946   ac_ext=cpp
42947 ac_cpp='$CXXCPP $CPPFLAGS'
42948 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42949 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42950 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
42951 
42952   CFLAGS="$saved_cflags"
42953 
42954   saved_cxxflags="$CXXFLAGS"
42955   CXXFLAGS="$CXXFLAG $ZERO_ARCHFLAG"
42956   ac_ext=cpp
42957 ac_cpp='$CXXCPP $CPPFLAGS'
42958 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42959 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42960 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
42961 
42962   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42963 /* end confdefs.h.  */
42964 int i;
42965 _ACEOF
42966 if ac_fn_cxx_try_compile "$LINENO"; then :
42967 
42968 else
42969   supports=no
42970 fi
42971 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
42972   ac_ext=cpp
42973 ac_cpp='$CXXCPP $CPPFLAGS'
42974 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
42975 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
42976 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
42977 
42978   CXXFLAGS="$saved_cxxflags"
42979 
42980   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5
42981 $as_echo "$supports" >&6; }
42982   if test "x$supports" = "xyes" ; then
42983     :
42984   else
42985     ZERO_ARCHFLAG=""
42986   fi
42987 
42988 
42989 
42990   # Check that the compiler supports -mX (or -qX on AIX) flags
42991   # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does
42992 
42993   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5
42994 $as_echo_n "checking if compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; }
42995   supports=yes
42996 
42997   saved_cflags="$CFLAGS"
42998   CFLAGS="$CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
42999   ac_ext=c
43000 ac_cpp='$CPP $CPPFLAGS'
43001 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
43002 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
43003 ac_compiler_gnu=$ac_cv_c_compiler_gnu
43004 
43005   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43006 /* end confdefs.h.  */
43007 int i;
43008 _ACEOF
43009 if ac_fn_c_try_compile "$LINENO"; then :
43010 
43011 else
43012   supports=no
43013 fi
43014 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
43015   ac_ext=cpp
43016 ac_cpp='$CXXCPP $CPPFLAGS'
43017 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
43018 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
43019 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
43020 
43021   CFLAGS="$saved_cflags"
43022 
43023   saved_cxxflags="$CXXFLAGS"
43024   CXXFLAGS="$CXXFLAG ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}"
43025   ac_ext=cpp
43026 ac_cpp='$CXXCPP $CPPFLAGS'
43027 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
43028 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
43029 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
43030 
43031   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43032 /* end confdefs.h.  */
43033 int i;
43034 _ACEOF
43035 if ac_fn_cxx_try_compile "$LINENO"; then :
43036 
43037 else
43038   supports=no
43039 fi
43040 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
43041   ac_ext=cpp
43042 ac_cpp='$CXXCPP $CPPFLAGS'
43043 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
43044 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
43045 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
43046 
43047   CXXFLAGS="$saved_cxxflags"
43048 
43049   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5
43050 $as_echo "$supports" >&6; }
43051   if test "x$supports" = "xyes" ; then
43052     COMPILER_SUPPORTS_TARGET_BITS_FLAG=true
43053   else
43054     COMPILER_SUPPORTS_TARGET_BITS_FLAG=false
43055   fi
43056 
43057 
43058 
43059   case "${TOOLCHAIN_TYPE}" in
43060     microsoft)
43061       CFLAGS_WARNINGS_ARE_ERRORS="-WX"
43062       ;;
43063     solstudio)
43064       CFLAGS_WARNINGS_ARE_ERRORS="-errtags -errwarn=%all"
43065       ;;
43066     gcc)
43067       CFLAGS_WARNINGS_ARE_ERRORS="-Werror"
43068       ;;
43069     clang)
43070       CFLAGS_WARNINGS_ARE_ERRORS="-Werror"
43071       ;;
43072   esac
43073 
43074 
43075 
43076 # Setup debug symbols (need objcopy from the toolchain for that)
43077 
43078   #
43079   # ENABLE_DEBUG_SYMBOLS
43080   # This must be done after the toolchain is setup, since we're looking at objcopy.
43081   #
43082   # Check whether --enable-debug-symbols was given.
43083 if test "${enable_debug_symbols+set}" = set; then :
43084   enableval=$enable_debug_symbols;
43085 fi
43086 
43087 
43088   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should generate debug symbols" >&5
43089 $as_echo_n "checking if we should generate debug symbols... " >&6; }
43090 
43091   if test "x$enable_debug_symbols" = "xyes" && test "x$OBJCOPY" = x; then
43092     # explicit enabling of enable-debug-symbols and can't find objcopy
43093     #   this is an error
43094     as_fn_error $? "Unable to find objcopy, cannot enable debug-symbols" "$LINENO" 5
43095   fi
43096 
43097   if test "x$enable_debug_symbols" = "xyes"; then
43098     ENABLE_DEBUG_SYMBOLS=true
43099   elif test "x$enable_debug_symbols" = "xno"; then
43100     ENABLE_DEBUG_SYMBOLS=false
43101   else
43102     # Default is on if objcopy is found
43103     if test "x$OBJCOPY" != x; then
43104       ENABLE_DEBUG_SYMBOLS=true
43105     # MacOS X and Windows don't use objcopy but default is on for those OSes
43106     elif test "x$OPENJDK_TARGET_OS" = xmacosx || test "x$OPENJDK_TARGET_OS" = xwindows; then
43107       ENABLE_DEBUG_SYMBOLS=true
43108     else
43109       ENABLE_DEBUG_SYMBOLS=false
43110     fi
43111   fi
43112 
43113   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_DEBUG_SYMBOLS" >&5
43114 $as_echo "$ENABLE_DEBUG_SYMBOLS" >&6; }
43115 
43116   #
43117   # ZIP_DEBUGINFO_FILES
43118   #
43119   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should zip debug-info files" >&5
43120 $as_echo_n "checking if we should zip debug-info files... " >&6; }
43121   # Check whether --enable-zip-debug-info was given.
43122 if test "${enable_zip_debug_info+set}" = set; then :
43123   enableval=$enable_zip_debug_info; enable_zip_debug_info="${enableval}"
43124 else
43125   enable_zip_debug_info="yes"
43126 fi
43127 
43128   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${enable_zip_debug_info}" >&5
43129 $as_echo "${enable_zip_debug_info}" >&6; }
43130 
43131   if test "x${enable_zip_debug_info}" = "xno"; then
43132     ZIP_DEBUGINFO_FILES=false
43133   else
43134     ZIP_DEBUGINFO_FILES=true
43135   fi
43136 
43137 
43138 
43139 
43140 
43141 ###############################################################################
43142 #
43143 # Check dependencies for external and internal libraries.
43144 #
43145 ###############################################################################
43146 
43147 # After we have toolchain, we can compile fixpath. It's needed by the lib checks.
43148 
43149   # When using cygwin or msys, we need a wrapper binary that renames
43150   # /cygdrive/c/ arguments into c:/ arguments and peeks into
43151   # @files and rewrites these too! This wrapper binary is
43152   # called fixpath.
43153   FIXPATH=
43154   if test "x$OPENJDK_BUILD_OS" = xwindows; then
43155     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5
43156 $as_echo_n "checking if fixpath can be created... " >&6; }
43157     FIXPATH_SRC="$SRC_ROOT/common/src/fixpath.c"
43158     FIXPATH_BIN="$OUTPUT_ROOT/fixpath.exe"
43159     if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then
43160       FIXPATH_SRC=`$CYGPATH -m $FIXPATH_SRC`
43161       FIXPATH_BIN=`$CYGPATH -m $FIXPATH_BIN`
43162       # Important to keep the .exe suffix on Cygwin for Hotspot makefiles
43163       FIXPATH="$OUTPUT_ROOT/fixpath.exe -c"
43164     elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then
43165       FIXPATH_SRC=`cmd //c echo $FIXPATH_SRC`
43166       FIXPATH_BIN=`cmd //c echo $FIXPATH_BIN`
43167 
43168       # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line
43169       # @ was chosen as separator to minimize risk of other tools messing around with it
43170       all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" | tr ' ' '\n' | grep '^/./' | sort | uniq`
43171       fixpath_argument_list=`echo $all_unique_prefixes  | tr ' ' '@'`
43172 
43173       FIXPATH="$OUTPUT_ROOT/fixpath -m$fixpath_argument_list"
43174     fi
43175     rm -f $OUTPUT_ROOT/fixpath*
43176     cd $OUTPUT_ROOT
43177     $CC $FIXPATH_SRC -Fe$FIXPATH_BIN > $OUTPUT_ROOT/fixpath1.log 2>&1
43178     cd $CURDIR
43179 
43180     if test ! -x $OUTPUT_ROOT/fixpath.exe; then
43181       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
43182 $as_echo "no" >&6; }
43183       cat $OUTPUT_ROOT/fixpath1.log
43184       as_fn_error $? "Could not create $OUTPUT_ROOT/fixpath.exe" "$LINENO" 5
43185     fi
43186     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
43187 $as_echo "yes" >&6; }
43188     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5
43189 $as_echo_n "checking if fixpath.exe works... " >&6; }
43190     cd $OUTPUT_ROOT
43191     $FIXPATH $CC $SRC_ROOT/common/src/fixpath.c -Fe$OUTPUT_ROOT/fixpath2.exe > $OUTPUT_ROOT/fixpath2.log 2>&1
43192     cd $CURDIR
43193     if test ! -x $OUTPUT_ROOT/fixpath2.exe; then
43194       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
43195 $as_echo "no" >&6; }
43196       cat $OUTPUT_ROOT/fixpath2.log
43197       as_fn_error $? "fixpath did not work!" "$LINENO" 5
43198     fi
43199     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
43200 $as_echo "yes" >&6; }
43201     rm -f $OUTPUT_ROOT/fixpath?.??? $OUTPUT_ROOT/fixpath.obj
43202   fi
43203 
43204 
43205 
43206 
43207 
43208 
43209   ###############################################################################
43210   #
43211   # OS specific settings that we never will need to probe.
43212   #
43213   if test "x$OPENJDK_TARGET_OS" = xlinux; then
43214     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Linux?" >&5
43215 $as_echo_n "checking what is not needed on Linux?... " >&6; }
43216     PULSE_NOT_NEEDED=yes
43217     { $as_echo "$as_me:${as_lineno-$LINENO}: result: pulse" >&5
43218 $as_echo "pulse" >&6; }
43219   fi
43220 
43221   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
43222     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Solaris?" >&5
43223 $as_echo_n "checking what is not needed on Solaris?... " >&6; }
43224     ALSA_NOT_NEEDED=yes
43225     PULSE_NOT_NEEDED=yes
43226     { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5
43227 $as_echo "alsa pulse" >&6; }
43228   fi
43229 
43230   if test "x$OPENJDK_TARGET_OS" = xaix; then
43231     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on AIX?" >&5
43232 $as_echo_n "checking what is not needed on AIX?... " >&6; }
43233     ALSA_NOT_NEEDED=yes
43234     PULSE_NOT_NEEDED=yes
43235     { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse" >&5
43236 $as_echo "alsa pulse" >&6; }
43237   fi
43238 
43239 
43240   if test "x$OPENJDK_TARGET_OS" = xwindows; then
43241     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on Windows?" >&5
43242 $as_echo_n "checking what is not needed on Windows?... " >&6; }
43243     CUPS_NOT_NEEDED=yes
43244     ALSA_NOT_NEEDED=yes
43245     PULSE_NOT_NEEDED=yes
43246     X11_NOT_NEEDED=yes
43247     { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa cups pulse x11" >&5
43248 $as_echo "alsa cups pulse x11" >&6; }
43249   fi
43250 
43251   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
43252     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on MacOSX?" >&5
43253 $as_echo_n "checking what is not needed on MacOSX?... " >&6; }
43254     ALSA_NOT_NEEDED=yes
43255     PULSE_NOT_NEEDED=yes
43256     X11_NOT_NEEDED=yes
43257     { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa pulse x11" >&5
43258 $as_echo "alsa pulse x11" >&6; }
43259   fi
43260 
43261   if test "x$OPENJDK_TARGET_OS" = xbsd; then
43262     { $as_echo "$as_me:${as_lineno-$LINENO}: checking what is not needed on bsd?" >&5
43263 $as_echo_n "checking what is not needed on bsd?... " >&6; }
43264     ALSA_NOT_NEEDED=yes
43265     { $as_echo "$as_me:${as_lineno-$LINENO}: result: alsa" >&5
43266 $as_echo "alsa" >&6; }
43267   fi
43268 
43269   if test "x$OPENJDK" = "xfalse"; then
43270     FREETYPE_NOT_NEEDED=yes
43271   fi
43272 
43273   if test "x$SUPPORT_HEADFUL" = xno; then
43274     X11_NOT_NEEDED=yes
43275   fi
43276 
43277 
43278 
43279   ###############################################################################
43280   #
43281   # Check for X Windows
43282   #
43283 
43284   if test "x$X11_NOT_NEEDED" = xyes; then
43285     if test "x${with_x}" != x; then
43286       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: X11 is not used, so --with-x is ignored" >&5
43287 $as_echo "$as_me: WARNING: X11 is not used, so --with-x is ignored" >&2;}
43288     fi
43289     X_CFLAGS=
43290     X_LIBS=
43291   else
43292     # Check if the user has specified sysroot, but not --x-includes or --x-libraries.
43293     # Make a simple check for the libraries at the sysroot, and setup --x-includes and
43294     # --x-libraries for the sysroot, if that seems to be correct.
43295     if test "x$OPENJDK_TARGET_OS" = "xlinux"; then
43296       if test "x$SYSROOT" != "x"; then
43297         if test "x$x_includes" = xNONE; then
43298           if test -f "$SYSROOT/usr/X11R6/include/X11/Xlib.h"; then
43299             x_includes="$SYSROOT/usr/X11R6/include"
43300           elif test -f "$SYSROOT/usr/include/X11/Xlib.h"; then
43301             x_includes="$SYSROOT/usr/include"
43302           fi
43303         fi
43304         if test "x$x_libraries" = xNONE; then
43305           if test -f "$SYSROOT/usr/X11R6/lib/libX11.so"; then
43306             x_libraries="$SYSROOT/usr/X11R6/lib"
43307           elif test "$SYSROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
43308             x_libraries="$SYSROOT/usr/lib64"
43309           elif test -f "$SYSROOT/usr/lib/libX11.so"; then
43310             x_libraries="$SYSROOT/usr/lib"
43311           fi
43312         fi
43313       fi
43314     fi
43315 
43316     # Now let autoconf do it's magic
43317     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
43318 $as_echo_n "checking for X... " >&6; }
43319 
43320 
43321 # Check whether --with-x was given.
43322 if test "${with_x+set}" = set; then :
43323   withval=$with_x;
43324 fi
43325 
43326 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
43327 if test "x$with_x" = xno; then
43328   # The user explicitly disabled X.
43329   have_x=disabled
43330 else
43331   case $x_includes,$x_libraries in #(
43332     *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #(
43333     *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then :
43334   $as_echo_n "(cached) " >&6
43335 else
43336   # One or both of the vars are not set, and there is no cached value.
43337 ac_x_includes=no ac_x_libraries=no
43338 rm -f -r conftest.dir
43339 if mkdir conftest.dir; then
43340   cd conftest.dir
43341   cat >Imakefile <<'_ACEOF'
43342 incroot:
43343         @echo incroot='${INCROOT}'
43344 usrlibdir:
43345         @echo usrlibdir='${USRLIBDIR}'
43346 libdir:
43347         @echo libdir='${LIBDIR}'
43348 _ACEOF
43349   if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
43350     # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
43351     for ac_var in incroot usrlibdir libdir; do
43352       eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
43353     done
43354     # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
43355     for ac_extension in a so sl dylib la dll; do
43356       if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
43357          test -f "$ac_im_libdir/libX11.$ac_extension"; then
43358         ac_im_usrlibdir=$ac_im_libdir; break
43359       fi
43360     done
43361     # Screen out bogus values from the imake configuration.  They are
43362     # bogus both because they are the default anyway, and because
43363     # using them would break gcc on systems where it needs fixed includes.
43364     case $ac_im_incroot in
43365         /usr/include) ac_x_includes= ;;
43366         *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
43367     esac
43368     case $ac_im_usrlibdir in
43369         /usr/lib | /usr/lib64 | /lib | /lib64) ;;
43370         *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
43371     esac
43372   fi
43373   cd ..
43374   rm -f -r conftest.dir
43375 fi
43376 
43377 # Standard set of common directories for X headers.
43378 # Check X11 before X11Rn because it is often a symlink to the current release.
43379 ac_x_header_dirs='
43380 /usr/X11/include
43381 /usr/X11R7/include
43382 /usr/X11R6/include
43383 /usr/X11R5/include
43384 /usr/X11R4/include
43385 
43386 /usr/include/X11
43387 /usr/include/X11R7
43388 /usr/include/X11R6
43389 /usr/include/X11R5
43390 /usr/include/X11R4
43391 
43392 /usr/local/X11/include
43393 /usr/local/X11R7/include
43394 /usr/local/X11R6/include
43395 /usr/local/X11R5/include
43396 /usr/local/X11R4/include
43397 
43398 /usr/local/include/X11
43399 /usr/local/include/X11R7
43400 /usr/local/include/X11R6
43401 /usr/local/include/X11R5
43402 /usr/local/include/X11R4
43403 
43404 /usr/X386/include
43405 /usr/x386/include
43406 /usr/XFree86/include/X11
43407 
43408 /usr/include
43409 /usr/local/include
43410 /usr/unsupported/include
43411 /usr/athena/include
43412 /usr/local/x11r5/include
43413 /usr/lpp/Xamples/include
43414 
43415 /usr/openwin/include
43416 /usr/openwin/share/include'
43417 
43418 if test "$ac_x_includes" = no; then
43419   # Guess where to find include files, by looking for Xlib.h.
43420   # First, try using that file with no special directory specified.
43421   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43422 /* end confdefs.h.  */
43423 #include <X11/Xlib.h>
43424 _ACEOF
43425 if ac_fn_cxx_try_cpp "$LINENO"; then :
43426   # We can compile using X headers with no special include directory.
43427 ac_x_includes=
43428 else
43429   for ac_dir in $ac_x_header_dirs; do
43430   if test -r "$ac_dir/X11/Xlib.h"; then
43431     ac_x_includes=$ac_dir
43432     break
43433   fi
43434 done
43435 fi
43436 rm -f conftest.err conftest.i conftest.$ac_ext
43437 fi # $ac_x_includes = no
43438 
43439 if test "$ac_x_libraries" = no; then
43440   # Check for the libraries.
43441   # See if we find them without any special options.
43442   # Don't add to $LIBS permanently.
43443   ac_save_LIBS=$LIBS
43444   LIBS="-lX11 $LIBS"
43445   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43446 /* end confdefs.h.  */
43447 #include <X11/Xlib.h>
43448 int
43449 main ()
43450 {
43451 XrmInitialize ()
43452   ;
43453   return 0;
43454 }
43455 _ACEOF
43456 if ac_fn_cxx_try_link "$LINENO"; then :
43457   LIBS=$ac_save_LIBS
43458 # We can link X programs with no special library path.
43459 ac_x_libraries=
43460 else
43461   LIBS=$ac_save_LIBS
43462 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
43463 do
43464   # Don't even attempt the hair of trying to link an X program!
43465   for ac_extension in a so sl dylib la dll; do
43466     if test -r "$ac_dir/libX11.$ac_extension"; then
43467       ac_x_libraries=$ac_dir
43468       break 2
43469     fi
43470   done
43471 done
43472 fi
43473 rm -f core conftest.err conftest.$ac_objext \
43474     conftest$ac_exeext conftest.$ac_ext
43475 fi # $ac_x_libraries = no
43476 
43477 case $ac_x_includes,$ac_x_libraries in #(
43478   no,* | *,no | *\'*)
43479     # Didn't find X, or a directory has "'" in its name.
43480     ac_cv_have_x="have_x=no";; #(
43481   *)
43482     # Record where we found X for the cache.
43483     ac_cv_have_x="have_x=yes\
43484         ac_x_includes='$ac_x_includes'\
43485         ac_x_libraries='$ac_x_libraries'"
43486 esac
43487 fi
43488 ;; #(
43489     *) have_x=yes;;
43490   esac
43491   eval "$ac_cv_have_x"
43492 fi # $with_x != no
43493 
43494 if test "$have_x" != yes; then
43495   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
43496 $as_echo "$have_x" >&6; }
43497   no_x=yes
43498 else
43499   # If each of the values was on the command line, it overrides each guess.
43500   test "x$x_includes" = xNONE && x_includes=$ac_x_includes
43501   test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
43502   # Update the cache value to reflect the command line values.
43503   ac_cv_have_x="have_x=yes\
43504         ac_x_includes='$x_includes'\
43505         ac_x_libraries='$x_libraries'"
43506   { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
43507 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
43508 fi
43509 
43510     if test "$no_x" = yes; then
43511   # Not all programs may use this symbol, but it does not hurt to define it.
43512 
43513 $as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h
43514 
43515   X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
43516 else
43517   if test -n "$x_includes"; then
43518     X_CFLAGS="$X_CFLAGS -I$x_includes"
43519   fi
43520 
43521   # It would also be nice to do this for all -L options, not just this one.
43522   if test -n "$x_libraries"; then
43523     X_LIBS="$X_LIBS -L$x_libraries"
43524     # For Solaris; some versions of Sun CC require a space after -R and
43525     # others require no space.  Words are not sufficient . . . .
43526     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5
43527 $as_echo_n "checking whether -R must be followed by a space... " >&6; }
43528     ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
43529     ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag
43530     ac_cxx_werror_flag=yes
43531     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43532 /* end confdefs.h.  */
43533 
43534 int
43535 main ()
43536 {
43537 
43538   ;
43539   return 0;
43540 }
43541 _ACEOF
43542 if ac_fn_cxx_try_link "$LINENO"; then :
43543   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
43544 $as_echo "no" >&6; }
43545        X_LIBS="$X_LIBS -R$x_libraries"
43546 else
43547   LIBS="$ac_xsave_LIBS -R $x_libraries"
43548        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43549 /* end confdefs.h.  */
43550 
43551 int
43552 main ()
43553 {
43554 
43555   ;
43556   return 0;
43557 }
43558 _ACEOF
43559 if ac_fn_cxx_try_link "$LINENO"; then :
43560   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
43561 $as_echo "yes" >&6; }
43562           X_LIBS="$X_LIBS -R $x_libraries"
43563 else
43564   { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5
43565 $as_echo "neither works" >&6; }
43566 fi
43567 rm -f core conftest.err conftest.$ac_objext \
43568     conftest$ac_exeext conftest.$ac_ext
43569 fi
43570 rm -f core conftest.err conftest.$ac_objext \
43571     conftest$ac_exeext conftest.$ac_ext
43572     ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag
43573     LIBS=$ac_xsave_LIBS
43574   fi
43575 
43576   # Check for system-dependent libraries X programs must link with.
43577   # Do this before checking for the system-independent R6 libraries
43578   # (-lICE), since we may need -lsocket or whatever for X linking.
43579 
43580   if test "$ISC" = yes; then
43581     X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
43582   else
43583     # Martyn Johnson says this is needed for Ultrix, if the X
43584     # libraries were built with DECnet support.  And Karl Berry says
43585     # the Alpha needs dnet_stub (dnet does not exist).
43586     ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
43587     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43588 /* end confdefs.h.  */
43589 
43590 /* Override any GCC internal prototype to avoid an error.
43591    Use char because int might match the return type of a GCC
43592    builtin and then its argument prototype would still apply.  */
43593 #ifdef __cplusplus
43594 extern "C"
43595 #endif
43596 char XOpenDisplay ();
43597 int
43598 main ()
43599 {
43600 return XOpenDisplay ();
43601   ;
43602   return 0;
43603 }
43604 _ACEOF
43605 if ac_fn_cxx_try_link "$LINENO"; then :
43606 
43607 else
43608   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
43609 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
43610 if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then :
43611   $as_echo_n "(cached) " >&6
43612 else
43613   ac_check_lib_save_LIBS=$LIBS
43614 LIBS="-ldnet  $LIBS"
43615 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43616 /* end confdefs.h.  */
43617 
43618 /* Override any GCC internal prototype to avoid an error.
43619    Use char because int might match the return type of a GCC
43620    builtin and then its argument prototype would still apply.  */
43621 #ifdef __cplusplus
43622 extern "C"
43623 #endif
43624 char dnet_ntoa ();
43625 int
43626 main ()
43627 {
43628 return dnet_ntoa ();
43629   ;
43630   return 0;
43631 }
43632 _ACEOF
43633 if ac_fn_cxx_try_link "$LINENO"; then :
43634   ac_cv_lib_dnet_dnet_ntoa=yes
43635 else
43636   ac_cv_lib_dnet_dnet_ntoa=no
43637 fi
43638 rm -f core conftest.err conftest.$ac_objext \
43639     conftest$ac_exeext conftest.$ac_ext
43640 LIBS=$ac_check_lib_save_LIBS
43641 fi
43642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
43643 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
43644 if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then :
43645   X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
43646 fi
43647 
43648     if test $ac_cv_lib_dnet_dnet_ntoa = no; then
43649       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5
43650 $as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; }
43651 if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then :
43652   $as_echo_n "(cached) " >&6
43653 else
43654   ac_check_lib_save_LIBS=$LIBS
43655 LIBS="-ldnet_stub  $LIBS"
43656 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43657 /* end confdefs.h.  */
43658 
43659 /* Override any GCC internal prototype to avoid an error.
43660    Use char because int might match the return type of a GCC
43661    builtin and then its argument prototype would still apply.  */
43662 #ifdef __cplusplus
43663 extern "C"
43664 #endif
43665 char dnet_ntoa ();
43666 int
43667 main ()
43668 {
43669 return dnet_ntoa ();
43670   ;
43671   return 0;
43672 }
43673 _ACEOF
43674 if ac_fn_cxx_try_link "$LINENO"; then :
43675   ac_cv_lib_dnet_stub_dnet_ntoa=yes
43676 else
43677   ac_cv_lib_dnet_stub_dnet_ntoa=no
43678 fi
43679 rm -f core conftest.err conftest.$ac_objext \
43680     conftest$ac_exeext conftest.$ac_ext
43681 LIBS=$ac_check_lib_save_LIBS
43682 fi
43683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
43684 $as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; }
43685 if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then :
43686   X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
43687 fi
43688 
43689     fi
43690 fi
43691 rm -f core conftest.err conftest.$ac_objext \
43692     conftest$ac_exeext conftest.$ac_ext
43693     LIBS="$ac_xsave_LIBS"
43694 
43695     # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
43696     # to get the SysV transport functions.
43697     # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
43698     # needs -lnsl.
43699     # The nsl library prevents programs from opening the X display
43700     # on Irix 5.2, according to T.E. Dickey.
43701     # The functions gethostbyname, getservbyname, and inet_addr are
43702     # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
43703     ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname"
43704 if test "x$ac_cv_func_gethostbyname" = xyes; then :
43705 
43706 fi
43707 
43708     if test $ac_cv_func_gethostbyname = no; then
43709       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5
43710 $as_echo_n "checking for gethostbyname in -lnsl... " >&6; }
43711 if ${ac_cv_lib_nsl_gethostbyname+:} false; then :
43712   $as_echo_n "(cached) " >&6
43713 else
43714   ac_check_lib_save_LIBS=$LIBS
43715 LIBS="-lnsl  $LIBS"
43716 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43717 /* end confdefs.h.  */
43718 
43719 /* Override any GCC internal prototype to avoid an error.
43720    Use char because int might match the return type of a GCC
43721    builtin and then its argument prototype would still apply.  */
43722 #ifdef __cplusplus
43723 extern "C"
43724 #endif
43725 char gethostbyname ();
43726 int
43727 main ()
43728 {
43729 return gethostbyname ();
43730   ;
43731   return 0;
43732 }
43733 _ACEOF
43734 if ac_fn_cxx_try_link "$LINENO"; then :
43735   ac_cv_lib_nsl_gethostbyname=yes
43736 else
43737   ac_cv_lib_nsl_gethostbyname=no
43738 fi
43739 rm -f core conftest.err conftest.$ac_objext \
43740     conftest$ac_exeext conftest.$ac_ext
43741 LIBS=$ac_check_lib_save_LIBS
43742 fi
43743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5
43744 $as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; }
43745 if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then :
43746   X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
43747 fi
43748 
43749       if test $ac_cv_lib_nsl_gethostbyname = no; then
43750         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5
43751 $as_echo_n "checking for gethostbyname in -lbsd... " >&6; }
43752 if ${ac_cv_lib_bsd_gethostbyname+:} false; then :
43753   $as_echo_n "(cached) " >&6
43754 else
43755   ac_check_lib_save_LIBS=$LIBS
43756 LIBS="-lbsd  $LIBS"
43757 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43758 /* end confdefs.h.  */
43759 
43760 /* Override any GCC internal prototype to avoid an error.
43761    Use char because int might match the return type of a GCC
43762    builtin and then its argument prototype would still apply.  */
43763 #ifdef __cplusplus
43764 extern "C"
43765 #endif
43766 char gethostbyname ();
43767 int
43768 main ()
43769 {
43770 return gethostbyname ();
43771   ;
43772   return 0;
43773 }
43774 _ACEOF
43775 if ac_fn_cxx_try_link "$LINENO"; then :
43776   ac_cv_lib_bsd_gethostbyname=yes
43777 else
43778   ac_cv_lib_bsd_gethostbyname=no
43779 fi
43780 rm -f core conftest.err conftest.$ac_objext \
43781     conftest$ac_exeext conftest.$ac_ext
43782 LIBS=$ac_check_lib_save_LIBS
43783 fi
43784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5
43785 $as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; }
43786 if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then :
43787   X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
43788 fi
43789 
43790       fi
43791     fi
43792 
43793     # lieder@skyler.mavd.honeywell.com says without -lsocket,
43794     # socket/setsockopt and other routines are undefined under SCO ODT
43795     # 2.0.  But -lsocket is broken on IRIX 5.2 (and is not necessary
43796     # on later versions), says Simon Leinen: it contains gethostby*
43797     # variants that don't use the name server (or something).  -lsocket
43798     # must be given before -lnsl if both are needed.  We assume that
43799     # if connect needs -lnsl, so does gethostbyname.
43800     ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect"
43801 if test "x$ac_cv_func_connect" = xyes; then :
43802 
43803 fi
43804 
43805     if test $ac_cv_func_connect = no; then
43806       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5
43807 $as_echo_n "checking for connect in -lsocket... " >&6; }
43808 if ${ac_cv_lib_socket_connect+:} false; then :
43809   $as_echo_n "(cached) " >&6
43810 else
43811   ac_check_lib_save_LIBS=$LIBS
43812 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
43813 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43814 /* end confdefs.h.  */
43815 
43816 /* Override any GCC internal prototype to avoid an error.
43817    Use char because int might match the return type of a GCC
43818    builtin and then its argument prototype would still apply.  */
43819 #ifdef __cplusplus
43820 extern "C"
43821 #endif
43822 char connect ();
43823 int
43824 main ()
43825 {
43826 return connect ();
43827   ;
43828   return 0;
43829 }
43830 _ACEOF
43831 if ac_fn_cxx_try_link "$LINENO"; then :
43832   ac_cv_lib_socket_connect=yes
43833 else
43834   ac_cv_lib_socket_connect=no
43835 fi
43836 rm -f core conftest.err conftest.$ac_objext \
43837     conftest$ac_exeext conftest.$ac_ext
43838 LIBS=$ac_check_lib_save_LIBS
43839 fi
43840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5
43841 $as_echo "$ac_cv_lib_socket_connect" >&6; }
43842 if test "x$ac_cv_lib_socket_connect" = xyes; then :
43843   X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
43844 fi
43845 
43846     fi
43847 
43848     # Guillermo Gomez says -lposix is necessary on A/UX.
43849     ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove"
43850 if test "x$ac_cv_func_remove" = xyes; then :
43851 
43852 fi
43853 
43854     if test $ac_cv_func_remove = no; then
43855       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5
43856 $as_echo_n "checking for remove in -lposix... " >&6; }
43857 if ${ac_cv_lib_posix_remove+:} false; then :
43858   $as_echo_n "(cached) " >&6
43859 else
43860   ac_check_lib_save_LIBS=$LIBS
43861 LIBS="-lposix  $LIBS"
43862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43863 /* end confdefs.h.  */
43864 
43865 /* Override any GCC internal prototype to avoid an error.
43866    Use char because int might match the return type of a GCC
43867    builtin and then its argument prototype would still apply.  */
43868 #ifdef __cplusplus
43869 extern "C"
43870 #endif
43871 char remove ();
43872 int
43873 main ()
43874 {
43875 return remove ();
43876   ;
43877   return 0;
43878 }
43879 _ACEOF
43880 if ac_fn_cxx_try_link "$LINENO"; then :
43881   ac_cv_lib_posix_remove=yes
43882 else
43883   ac_cv_lib_posix_remove=no
43884 fi
43885 rm -f core conftest.err conftest.$ac_objext \
43886     conftest$ac_exeext conftest.$ac_ext
43887 LIBS=$ac_check_lib_save_LIBS
43888 fi
43889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5
43890 $as_echo "$ac_cv_lib_posix_remove" >&6; }
43891 if test "x$ac_cv_lib_posix_remove" = xyes; then :
43892   X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
43893 fi
43894 
43895     fi
43896 
43897     # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
43898     ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat"
43899 if test "x$ac_cv_func_shmat" = xyes; then :
43900 
43901 fi
43902 
43903     if test $ac_cv_func_shmat = no; then
43904       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5
43905 $as_echo_n "checking for shmat in -lipc... " >&6; }
43906 if ${ac_cv_lib_ipc_shmat+:} false; then :
43907   $as_echo_n "(cached) " >&6
43908 else
43909   ac_check_lib_save_LIBS=$LIBS
43910 LIBS="-lipc  $LIBS"
43911 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43912 /* end confdefs.h.  */
43913 
43914 /* Override any GCC internal prototype to avoid an error.
43915    Use char because int might match the return type of a GCC
43916    builtin and then its argument prototype would still apply.  */
43917 #ifdef __cplusplus
43918 extern "C"
43919 #endif
43920 char shmat ();
43921 int
43922 main ()
43923 {
43924 return shmat ();
43925   ;
43926   return 0;
43927 }
43928 _ACEOF
43929 if ac_fn_cxx_try_link "$LINENO"; then :
43930   ac_cv_lib_ipc_shmat=yes
43931 else
43932   ac_cv_lib_ipc_shmat=no
43933 fi
43934 rm -f core conftest.err conftest.$ac_objext \
43935     conftest$ac_exeext conftest.$ac_ext
43936 LIBS=$ac_check_lib_save_LIBS
43937 fi
43938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5
43939 $as_echo "$ac_cv_lib_ipc_shmat" >&6; }
43940 if test "x$ac_cv_lib_ipc_shmat" = xyes; then :
43941   X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
43942 fi
43943 
43944     fi
43945   fi
43946 
43947   # Check for libraries that X11R6 Xt/Xaw programs need.
43948   ac_save_LDFLAGS=$LDFLAGS
43949   test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
43950   # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
43951   # check for ICE first), but we must link in the order -lSM -lICE or
43952   # we get undefined symbols.  So assume we have SM if we have ICE.
43953   # These have to be linked with before -lX11, unlike the other
43954   # libraries we check for below, so use a different variable.
43955   # John Interrante, Karl Berry
43956   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5
43957 $as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; }
43958 if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then :
43959   $as_echo_n "(cached) " >&6
43960 else
43961   ac_check_lib_save_LIBS=$LIBS
43962 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
43963 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43964 /* end confdefs.h.  */
43965 
43966 /* Override any GCC internal prototype to avoid an error.
43967    Use char because int might match the return type of a GCC
43968    builtin and then its argument prototype would still apply.  */
43969 #ifdef __cplusplus
43970 extern "C"
43971 #endif
43972 char IceConnectionNumber ();
43973 int
43974 main ()
43975 {
43976 return IceConnectionNumber ();
43977   ;
43978   return 0;
43979 }
43980 _ACEOF
43981 if ac_fn_cxx_try_link "$LINENO"; then :
43982   ac_cv_lib_ICE_IceConnectionNumber=yes
43983 else
43984   ac_cv_lib_ICE_IceConnectionNumber=no
43985 fi
43986 rm -f core conftest.err conftest.$ac_objext \
43987     conftest$ac_exeext conftest.$ac_ext
43988 LIBS=$ac_check_lib_save_LIBS
43989 fi
43990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
43991 $as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; }
43992 if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then :
43993   X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
43994 fi
43995 
43996   LDFLAGS=$ac_save_LDFLAGS
43997 
43998 fi
43999 
44000 
44001     # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling
44002     # this doesn't make sense so we remove it.
44003     if test "x$COMPILE_TYPE" = xcross; then
44004       X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'`
44005     fi
44006 
44007     if test "x$no_x" = xyes; then
44008 
44009   # Print a helpful message on how to acquire the necessary build dependency.
44010   # x11 is the help tag: freetype, cups, pulse, alsa etc
44011   MISSING_DEPENDENCY=x11
44012 
44013   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44014     cygwin_help $MISSING_DEPENDENCY
44015   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44016     msys_help $MISSING_DEPENDENCY
44017   else
44018     PKGHANDLER_COMMAND=
44019 
44020     case $PKGHANDLER in
44021       apt-get)
44022         apt_help     $MISSING_DEPENDENCY ;;
44023       yum)
44024         yum_help     $MISSING_DEPENDENCY ;;
44025       port)
44026         port_help    $MISSING_DEPENDENCY ;;
44027       pkgutil)
44028         pkgutil_help $MISSING_DEPENDENCY ;;
44029       pkgadd)
44030         pkgadd_help  $MISSING_DEPENDENCY ;;
44031     esac
44032 
44033     if test "x$PKGHANDLER_COMMAND" != x; then
44034       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
44035     fi
44036   fi
44037 
44038       as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5
44039     fi
44040 
44041     if test "x$OPENJDK_TARGET_OS" = xsolaris; then
44042       OPENWIN_HOME="/usr/openwin"
44043       X_CFLAGS="-I$SYSROOT$OPENWIN_HOME/include -I$SYSROOT$OPENWIN_HOME/include/X11/extensions"
44044       X_LIBS="-L$SYSROOT$OPENWIN_HOME/sfw/lib$OPENJDK_TARGET_CPU_ISADIR \
44045           -L$SYSROOT$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR \
44046           -R$OPENWIN_HOME/sfw/lib$OPENJDK_TARGET_CPU_ISADIR \
44047           -R$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR"
44048     fi
44049 
44050     ac_ext=c
44051 ac_cpp='$CPP $CPPFLAGS'
44052 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
44053 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
44054 ac_compiler_gnu=$ac_cv_c_compiler_gnu
44055 
44056     OLD_CFLAGS="$CFLAGS"
44057     CFLAGS="$CFLAGS $SYSROOT_CFLAGS $X_CFLAGS"
44058 
44059     # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10
44060     for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h X11/Intrinsic.h
44061 do :
44062   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
44063 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
44064           # include <X11/Xlib.h>
44065           # include <X11/Xutil.h>
44066 
44067 
44068 "
44069 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
44070   cat >>confdefs.h <<_ACEOF
44071 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
44072 _ACEOF
44073  X11_HEADERS_OK=yes
44074 else
44075   X11_HEADERS_OK=no; break
44076 fi
44077 
44078 done
44079 
44080 
44081     if test "x$X11_HEADERS_OK" = xno; then
44082 
44083   # Print a helpful message on how to acquire the necessary build dependency.
44084   # x11 is the help tag: freetype, cups, pulse, alsa etc
44085   MISSING_DEPENDENCY=x11
44086 
44087   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44088     cygwin_help $MISSING_DEPENDENCY
44089   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44090     msys_help $MISSING_DEPENDENCY
44091   else
44092     PKGHANDLER_COMMAND=
44093 
44094     case $PKGHANDLER in
44095       apt-get)
44096         apt_help     $MISSING_DEPENDENCY ;;
44097       yum)
44098         yum_help     $MISSING_DEPENDENCY ;;
44099       port)
44100         port_help    $MISSING_DEPENDENCY ;;
44101       pkgutil)
44102         pkgutil_help $MISSING_DEPENDENCY ;;
44103       pkgadd)
44104         pkgadd_help  $MISSING_DEPENDENCY ;;
44105     esac
44106 
44107     if test "x$PKGHANDLER_COMMAND" != x; then
44108       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
44109     fi
44110   fi
44111 
44112       as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h Intrinsic.h). $HELP_MSG" "$LINENO" 5
44113     fi
44114 
44115     # If XLinearGradient isn't available in Xrender.h, signal that it needs to be
44116     # defined in libawt_xawt.
44117     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if XlinearGradient is defined in Xrender.h" >&5
44118 $as_echo_n "checking if XlinearGradient is defined in Xrender.h... " >&6; }
44119     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
44120 /* end confdefs.h.  */
44121 #include <X11/extensions/Xrender.h>
44122 int
44123 main ()
44124 {
44125 XLinearGradient x;
44126   ;
44127   return 0;
44128 }
44129 _ACEOF
44130 if ac_fn_c_try_compile "$LINENO"; then :
44131   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
44132 $as_echo "yes" >&6; }
44133 else
44134   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
44135 $as_echo "no" >&6; }
44136          X_CFLAGS="$X_CFLAGS -DSOLARIS10_NO_XRENDER_STRUCTS"
44137 fi
44138 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
44139 
44140     CFLAGS="$OLD_CFLAGS"
44141     ac_ext=cpp
44142 ac_cpp='$CXXCPP $CPPFLAGS'
44143 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
44144 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
44145 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
44146 
44147   fi # X11_NOT_NEEDED
44148 
44149 
44150 
44151 
44152 
44153 
44154   ###############################################################################
44155   #
44156   # The common unix printing system cups is used to print from java.
44157   #
44158 
44159 # Check whether --with-cups was given.
44160 if test "${with_cups+set}" = set; then :
44161   withval=$with_cups;
44162 fi
44163 
44164 
44165 # Check whether --with-cups-include was given.
44166 if test "${with_cups_include+set}" = set; then :
44167   withval=$with_cups_include;
44168 fi
44169 
44170 
44171   if test "x$CUPS_NOT_NEEDED" = xyes; then
44172     if test "x${with_cups}" != x || test "x${with_cups_include}" != x; then
44173       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups is ignored" >&5
44174 $as_echo "$as_me: WARNING: cups not used, so --with-cups is ignored" >&2;}
44175     fi
44176     CUPS_CFLAGS=
44177   else
44178     CUPS_FOUND=no
44179 
44180     if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then
44181       as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5
44182     fi
44183 
44184     if test "x${with_cups}" != x; then
44185       CUPS_CFLAGS="-I${with_cups}/include"
44186       CUPS_FOUND=yes
44187     fi
44188     if test "x${with_cups_include}" != x; then
44189       CUPS_CFLAGS="-I${with_cups_include}"
44190       CUPS_FOUND=yes
44191     fi
44192     if test "x$CUPS_FOUND" = xno; then
44193 
44194 
44195   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
44196     # Source the builddeps file again, to make sure it uses the latest variables!
44197     . $builddepsfile
44198     # Look for a target and build machine specific resource!
44199     eval resource=\${builddep_cups_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
44200     if test "x$resource" = x; then
44201       # Ok, lets instead look for a target specific resource
44202       eval resource=\${builddep_cups_TARGET_${rewritten_target_var}}
44203     fi
44204     if test "x$resource" = x; then
44205       # Ok, lets instead look for a build specific resource
44206       eval resource=\${builddep_cups_BUILD_${rewritten_build_var}}
44207     fi
44208     if test "x$resource" = x; then
44209       # Ok, lets instead look for a generic resource
44210       # (The cups comes from M4 and not the shell, thus no need for eval here.)
44211       resource=${builddep_cups}
44212     fi
44213     if test "x$resource" != x; then
44214       { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for cups" >&5
44215 $as_echo "$as_me: Using builddeps $resource for cups" >&6;}
44216       # If the resource in the builddeps.conf file is an existing directory,
44217       # for example /java/linux/cups
44218       if test -d ${resource}; then
44219         depdir=${resource}
44220       else
44221 
44222   # cups is for example mymodule
44223   # $resource is for example libs/general/libmymod_1_2_3.zip
44224   # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
44225   # $with_builddeps_dir is for example /localhome/builddeps
44226   # depdir is the name of the variable into which we store the depdir, eg MYMOD
44227   # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
44228   # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
44229   filename=`basename $resource`
44230   filebase=`echo $filename | sed 's/\.[^\.]*$//'`
44231   filebase=${filename%%.*}
44232   extension=${filename#*.}
44233   installdir=$with_builddeps_dir/$filebase
44234   if test ! -f $installdir/$filename.unpacked; then
44235     { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency cups from $with_builddeps_server/$resource and installing into $installdir" >&5
44236 $as_echo "$as_me: Downloading build dependency cups from $with_builddeps_server/$resource and installing into $installdir" >&6;}
44237     if test ! -d $installdir; then
44238       mkdir -p $installdir
44239     fi
44240     if test ! -d $installdir; then
44241       as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
44242     fi
44243     tmpfile=`mktemp $installdir/cups.XXXXXXXXX`
44244     touch $tmpfile
44245     if test ! -f $tmpfile; then
44246       as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
44247     fi
44248 
44249   # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
44250   # $tmpfile is the local file name for the downloaded file.
44251   VALID_TOOL=no
44252   if test "x$BDEPS_FTP" = xwget; then
44253     VALID_TOOL=yes
44254     wget -O $tmpfile $with_builddeps_server/$resource
44255   fi
44256   if test "x$BDEPS_FTP" = xlftp; then
44257     VALID_TOOL=yes
44258     lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
44259   fi
44260   if test "x$BDEPS_FTP" = xftp; then
44261     VALID_TOOL=yes
44262     FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
44263     FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
44264     FTPUSERPWD=${FTPSERVER%%@*}
44265     if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
44266       FTPUSER=${userpwd%%:*}
44267       FTPPWD=${userpwd#*@}
44268       FTPSERVER=${FTPSERVER#*@}
44269     else
44270       FTPUSER=ftp
44271       FTPPWD=ftp
44272     fi
44273     # the "pass" command does not work on some
44274     # ftp clients (read ftp.exe) but if it works,
44275     # passive mode is better!
44276     ( \
44277         echo "user $FTPUSER $FTPPWD"        ; \
44278         echo "pass"                         ; \
44279         echo "bin"                          ; \
44280         echo "get $FTPPATH $tmpfile"              ; \
44281     ) | ftp -in $FTPSERVER
44282   fi
44283   if test "x$VALID_TOOL" != xyes; then
44284     as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
44285   fi
44286 
44287     mv $tmpfile $installdir/$filename
44288     if test ! -s $installdir/$filename; then
44289       as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
44290     fi
44291     case "$extension" in
44292       zip)  echo "Unzipping $installdir/$filename..."
44293         (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
44294         ;;
44295       tar.gz) echo "Untaring $installdir/$filename..."
44296         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
44297         ;;
44298       tgz) echo "Untaring $installdir/$filename..."
44299         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
44300         ;;
44301       *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
44302         ;;
44303     esac
44304   fi
44305   if test -f $installdir/$filename.unpacked; then
44306     depdir=$installdir
44307   fi
44308 
44309       fi
44310       # Source the builddeps file again, because in the previous command, the depdir
44311       # was updated to point at the current build dependency install directory.
44312       . $builddepsfile
44313       # Now extract variables from the builddeps.conf files.
44314       theroot=${builddep_cups_ROOT}
44315       thecflags=${builddep_cups_CFLAGS}
44316       thelibs=${builddep_cups_LIBS}
44317       if test "x$depdir" = x; then
44318         as_fn_error $? "Could not download build dependency cups" "$LINENO" 5
44319       fi
44320       CUPS=$depdir
44321       if test "x$theroot" != x; then
44322         CUPS="$theroot"
44323       fi
44324       if test "x$thecflags" != x; then
44325         CUPS_CFLAGS="$thecflags"
44326       fi
44327       if test "x$thelibs" != x; then
44328         CUPS_LIBS="$thelibs"
44329       fi
44330       CUPS_FOUND=yes
44331 
44332     fi
44333 
44334   fi
44335 
44336     fi
44337     if test "x$CUPS_FOUND" = xno; then
44338       # Are the cups headers installed in the default /usr/include location?
44339       for ac_header in cups/cups.h cups/ppd.h
44340 do :
44341   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
44342 ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
44343 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
44344   cat >>confdefs.h <<_ACEOF
44345 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
44346 _ACEOF
44347 
44348             CUPS_FOUND=yes
44349             CUPS_CFLAGS=
44350             DEFAULT_CUPS=yes
44351 
44352 
44353 fi
44354 
44355 done
44356 
44357     fi
44358     if test "x$CUPS_FOUND" = xno; then
44359       # Getting nervous now? Lets poke around for standard Solaris third-party
44360       # package installation locations.
44361       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5
44362 $as_echo_n "checking for cups headers... " >&6; }
44363       if test -s $SYSROOT/opt/sfw/cups/include/cups/cups.h; then
44364         # An SFW package seems to be installed!
44365         CUPS_FOUND=yes
44366         CUPS_CFLAGS="-I$SYSROOT/opt/sfw/cups/include"
44367       elif test -s $SYSROOT/opt/csw/include/cups/cups.h; then
44368         # A CSW package seems to be installed!
44369         CUPS_FOUND=yes
44370         CUPS_CFLAGS="-I$SYSROOT/opt/csw/include"
44371       fi
44372       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5
44373 $as_echo "$CUPS_FOUND" >&6; }
44374     fi
44375     if test "x$CUPS_FOUND" = xno; then
44376 
44377   # Print a helpful message on how to acquire the necessary build dependency.
44378   # cups is the help tag: freetype, cups, pulse, alsa etc
44379   MISSING_DEPENDENCY=cups
44380 
44381   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44382     cygwin_help $MISSING_DEPENDENCY
44383   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44384     msys_help $MISSING_DEPENDENCY
44385   else
44386     PKGHANDLER_COMMAND=
44387 
44388     case $PKGHANDLER in
44389       apt-get)
44390         apt_help     $MISSING_DEPENDENCY ;;
44391       yum)
44392         yum_help     $MISSING_DEPENDENCY ;;
44393       port)
44394         port_help    $MISSING_DEPENDENCY ;;
44395       pkgutil)
44396         pkgutil_help $MISSING_DEPENDENCY ;;
44397       pkgadd)
44398         pkgadd_help  $MISSING_DEPENDENCY ;;
44399     esac
44400 
44401     if test "x$PKGHANDLER_COMMAND" != x; then
44402       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
44403     fi
44404   fi
44405 
44406       as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5
44407     fi
44408   fi
44409 
44410 
44411 
44412 
44413 
44414 
44415   ###############################################################################
44416   #
44417   # The ubiquitous freetype library is used to render fonts.
44418   #
44419 
44420 # Check whether --with-freetype was given.
44421 if test "${with_freetype+set}" = set; then :
44422   withval=$with_freetype;
44423 fi
44424 
44425 
44426 # Check whether --with-freetype-include was given.
44427 if test "${with_freetype_include+set}" = set; then :
44428   withval=$with_freetype_include;
44429 fi
44430 
44431 
44432 # Check whether --with-freetype-lib was given.
44433 if test "${with_freetype_lib+set}" = set; then :
44434   withval=$with_freetype_lib;
44435 fi
44436 
44437 
44438 # Check whether --with-freetype-src was given.
44439 if test "${with_freetype_src+set}" = set; then :
44440   withval=$with_freetype_src;
44441 fi
44442 
44443   # Check whether --enable-freetype-bundling was given.
44444 if test "${enable_freetype_bundling+set}" = set; then :
44445   enableval=$enable_freetype_bundling;
44446 fi
44447 
44448 
44449   # Need to specify explicitly since it needs to be overridden on some versions of macosx
44450   FREETYPE_BASE_NAME=freetype
44451   FREETYPE_CFLAGS=
44452   FREETYPE_LIBS=
44453   FREETYPE_BUNDLE_LIB_PATH=
44454 
44455   if test "x$FREETYPE_NOT_NEEDED" = xyes; then
44456     if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x || test "x$with_freetype_src" != x; then
44457       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype is ignored" >&5
44458 $as_echo "$as_me: WARNING: freetype not used, so --with-freetype is ignored" >&2;}
44459     fi
44460     if test "x$enable_freetype_bundling" != x; then
44461       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&5
44462 $as_echo "$as_me: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&2;}
44463     fi
44464   else
44465     # freetype is needed to build; go get it!
44466 
44467     BUNDLE_FREETYPE="$enable_freetype_bundling"
44468 
44469     if  test "x$with_freetype_src" != x; then
44470       if test "x$OPENJDK_TARGET_OS" = xwindows; then
44471         # Try to build freetype if --with-freetype-src was given on Windows
44472 
44473   FREETYPE_SRC_PATH="$with_freetype_src"
44474   BUILD_FREETYPE=yes
44475 
44476   # Check if the freetype sources are acessible..
44477   if ! test -d $FREETYPE_SRC_PATH; then
44478     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-freetype-src specified, but can't find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&5
44479 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can't find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;}
44480     BUILD_FREETYPE=no
44481   fi
44482   # ..and contain a vc2010 project file
44483   vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj"
44484   if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then
44485     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can't find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&5
44486 $as_echo "$as_me: WARNING: Can't find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;}
44487     BUILD_FREETYPE=no
44488   fi
44489   # Now check if configure found a version of 'msbuild.exe'
44490   if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then
44491     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Can not find an msbuild.exe executable (you may try to install .NET 4.0) - ignoring --with-freetype-src" >&5
44492 $as_echo "$as_me: WARNING: Can not find an msbuild.exe executable (you may try to install .NET 4.0) - ignoring --with-freetype-src" >&2;}
44493     BUILD_FREETYPE=no
44494   fi
44495 
44496   # Ready to go..
44497   if test "x$BUILD_FREETYPE" = xyes; then
44498 
44499     # msbuild requires trailing slashes for output directories
44500     freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/"
44501     freetype_lib_path_unix="$freetype_lib_path"
44502     freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/"
44503 
44504   unix_path="$vcxproj_path"
44505   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44506     windows_path=`$CYGPATH -m "$unix_path"`
44507     vcxproj_path="$windows_path"
44508   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44509     windows_path=`cmd //c echo $unix_path`
44510     vcxproj_path="$windows_path"
44511   fi
44512 
44513 
44514   unix_path="$freetype_lib_path"
44515   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44516     windows_path=`$CYGPATH -m "$unix_path"`
44517     freetype_lib_path="$windows_path"
44518   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44519     windows_path=`cmd //c echo $unix_path`
44520     freetype_lib_path="$windows_path"
44521   fi
44522 
44523 
44524   unix_path="$freetype_obj_path"
44525   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44526     windows_path=`$CYGPATH -m "$unix_path"`
44527     freetype_obj_path="$windows_path"
44528   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44529     windows_path=`cmd //c echo $unix_path`
44530     freetype_obj_path="$windows_path"
44531   fi
44532 
44533     if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
44534       freetype_platform=x64
44535     else
44536       freetype_platform=win32
44537     fi
44538 
44539     # The original freetype project file is for VS 2010 (i.e. 'v100'),
44540     # so we have to adapt the toolset if building with any other toolsed (i.e. SDK).
44541     # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/
44542     # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4
44543     { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5
44544 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;}
44545 
44546     # First we try to build the freetype.dll
44547     $ECHO -e "@echo off\n"\
44548              "$MSBUILD $vcxproj_path "\
44549                        "/p:PlatformToolset=$PLATFORM_TOOLSET "\
44550                        "/p:Configuration=\"Release Multithreaded\" "\
44551                        "/p:Platform=$freetype_platform "\
44552                        "/p:ConfigurationType=DynamicLibrary "\
44553                        "/p:TargetName=freetype "\
44554                        "/p:OutDir=\"$freetype_lib_path\" "\
44555                        "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat
44556     cmd /c freetype.bat
44557 
44558     if test -s "$freetype_lib_path_unix/freetype.dll"; then
44559       # If that succeeds we also build freetype.lib
44560       $ECHO -e "@echo off\n"\
44561                "$MSBUILD $vcxproj_path "\
44562                          "/p:PlatformToolset=$PLATFORM_TOOLSET "\
44563                          "/p:Configuration=\"Release Multithreaded\" "\
44564                          "/p:Platform=$freetype_platform "\
44565                          "/p:ConfigurationType=StaticLibrary "\
44566                          "/p:TargetName=freetype "\
44567                          "/p:OutDir=\"$freetype_lib_path\" "\
44568                          "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat
44569       cmd /c freetype.bat
44570 
44571       if test -s "$freetype_lib_path_unix/freetype.lib"; then
44572         # Once we build both, lib and dll, set freetype lib and include path appropriately
44573         POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include"
44574         POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix"
44575         { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5
44576 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;}
44577       else
44578         BUILD_FREETYPE=no
44579       fi
44580     else
44581       BUILD_FREETYPE=no
44582     fi
44583   fi
44584 
44585         if test "x$BUILD_FREETYPE" = xyes; then
44586           # Okay, we built it. Check that it works.
44587 
44588   POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44589   POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44590   METHOD="--with-freetype-src"
44591 
44592   # Let's start with an optimistic view of the world :-)
44593   FOUND_FREETYPE=yes
44594 
44595   # First look for the canonical freetype main include file ft2build.h.
44596   if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44597     # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite.
44598     POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2"
44599     if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44600       # Fail.
44601       FOUND_FREETYPE=no
44602     fi
44603   fi
44604 
44605   if test "x$FOUND_FREETYPE" = xyes; then
44606     # Include file found, let's continue the sanity check.
44607     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44608 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44609 
44610     # Reset to default value
44611     FREETYPE_BASE_NAME=freetype
44612     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
44613     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44614       if test "x$OPENJDK_TARGET_OS" = xmacosx \
44615           && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then
44616         # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check
44617         # for the .6 version explicitly.
44618         FREETYPE_BASE_NAME=freetype.6
44619         FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
44620         { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5
44621 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;}
44622       else
44623         { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44624 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44625         FOUND_FREETYPE=no
44626       fi
44627     else
44628       if test "x$OPENJDK_TARGET_OS" = xwindows; then
44629         # On Windows, we will need both .lib and .dll file.
44630         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then
44631           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5
44632 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;}
44633           FOUND_FREETYPE=no
44634         fi
44635       elif test "x$OPENJDK_TARGET_OS" = xsolaris \
44636           && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then
44637         # Found lib in isa dir, use that instead.
44638         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR"
44639         { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5
44640 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;}
44641       fi
44642     fi
44643   fi
44644 
44645   if test "x$FOUND_FREETYPE" = xyes; then
44646 
44647   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44648 
44649   # Input might be given as Windows format, start by converting to
44650   # unix format.
44651   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44652   new_path=`$CYGPATH -u "$path"`
44653 
44654   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44655   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44656   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44657   # "foo.exe" is OK but "foo" is an error.
44658   #
44659   # This test is therefore slightly more accurate than "test -f" to check for file precense.
44660   # It is also a way to make sure we got the proper file name for the real test later on.
44661   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44662   if test "x$test_shortpath" = x; then
44663     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44664 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44665     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44666   fi
44667 
44668   # Call helper function which possibly converts this using DOS-style short mode.
44669   # If so, the updated path is stored in $new_path.
44670 
44671   input_path="$new_path"
44672   # Check if we need to convert this using DOS-style short mode. If the path
44673   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44674   # take no chances and rewrite it.
44675   # Note: m4 eats our [], so we need to use [ and ] instead.
44676   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44677   if test "x$has_forbidden_chars" != x; then
44678     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44679     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44680     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44681     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44682       # Going to short mode and back again did indeed matter. Since short mode is
44683       # case insensitive, let's make it lowercase to improve readability.
44684       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44685       # Now convert it back to Unix-stile (cygpath)
44686       input_path=`$CYGPATH -u "$shortmode_path"`
44687       new_path="$input_path"
44688     fi
44689   fi
44690 
44691   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44692   if test "x$test_cygdrive_prefix" = x; then
44693     # As a simple fix, exclude /usr/bin since it's not a real path.
44694     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44695       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44696       # a path prefixed by /cygdrive for fixpath to work.
44697       new_path="$CYGWIN_ROOT_PATH$input_path"
44698     fi
44699   fi
44700 
44701 
44702   if test "x$path" != "x$new_path"; then
44703     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44704     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44705 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44706   fi
44707 
44708   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44709 
44710   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44711   has_colon=`$ECHO $path | $GREP ^.:`
44712   new_path="$path"
44713   if test "x$has_colon" = x; then
44714     # Not in mixed or Windows style, start by that.
44715     new_path=`cmd //c echo $path`
44716   fi
44717 
44718 
44719   input_path="$new_path"
44720   # Check if we need to convert this using DOS-style short mode. If the path
44721   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44722   # take no chances and rewrite it.
44723   # Note: m4 eats our [], so we need to use [ and ] instead.
44724   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44725   if test "x$has_forbidden_chars" != x; then
44726     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44727     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44728   fi
44729 
44730 
44731   windows_path="$new_path"
44732   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44733     unix_path=`$CYGPATH -u "$windows_path"`
44734     new_path="$unix_path"
44735   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44736     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44737     new_path="$unix_path"
44738   fi
44739 
44740   if test "x$path" != "x$new_path"; then
44741     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44742     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44743 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44744   fi
44745 
44746   # Save the first 10 bytes of this path to the storage, so fixpath can work.
44747   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44748 
44749   else
44750     # We're on a unix platform. Hooray! :)
44751     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44752     has_space=`$ECHO "$path" | $GREP " "`
44753     if test "x$has_space" != x; then
44754       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44755 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44756       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44757     fi
44758 
44759     # Use eval to expand a potential ~
44760     eval path="$path"
44761     if test ! -f "$path" && test ! -d "$path"; then
44762       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44763     fi
44764 
44765     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44766   fi
44767 
44768 
44769   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44770 
44771   # Input might be given as Windows format, start by converting to
44772   # unix format.
44773   path="$POTENTIAL_FREETYPE_LIB_PATH"
44774   new_path=`$CYGPATH -u "$path"`
44775 
44776   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44777   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44778   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44779   # "foo.exe" is OK but "foo" is an error.
44780   #
44781   # This test is therefore slightly more accurate than "test -f" to check for file precense.
44782   # It is also a way to make sure we got the proper file name for the real test later on.
44783   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44784   if test "x$test_shortpath" = x; then
44785     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44786 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44787     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44788   fi
44789 
44790   # Call helper function which possibly converts this using DOS-style short mode.
44791   # If so, the updated path is stored in $new_path.
44792 
44793   input_path="$new_path"
44794   # Check if we need to convert this using DOS-style short mode. If the path
44795   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44796   # take no chances and rewrite it.
44797   # Note: m4 eats our [], so we need to use [ and ] instead.
44798   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44799   if test "x$has_forbidden_chars" != x; then
44800     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44801     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44802     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44803     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44804       # Going to short mode and back again did indeed matter. Since short mode is
44805       # case insensitive, let's make it lowercase to improve readability.
44806       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44807       # Now convert it back to Unix-stile (cygpath)
44808       input_path=`$CYGPATH -u "$shortmode_path"`
44809       new_path="$input_path"
44810     fi
44811   fi
44812 
44813   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44814   if test "x$test_cygdrive_prefix" = x; then
44815     # As a simple fix, exclude /usr/bin since it's not a real path.
44816     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44817       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44818       # a path prefixed by /cygdrive for fixpath to work.
44819       new_path="$CYGWIN_ROOT_PATH$input_path"
44820     fi
44821   fi
44822 
44823 
44824   if test "x$path" != "x$new_path"; then
44825     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44826     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44827 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44828   fi
44829 
44830   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44831 
44832   path="$POTENTIAL_FREETYPE_LIB_PATH"
44833   has_colon=`$ECHO $path | $GREP ^.:`
44834   new_path="$path"
44835   if test "x$has_colon" = x; then
44836     # Not in mixed or Windows style, start by that.
44837     new_path=`cmd //c echo $path`
44838   fi
44839 
44840 
44841   input_path="$new_path"
44842   # Check if we need to convert this using DOS-style short mode. If the path
44843   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44844   # take no chances and rewrite it.
44845   # Note: m4 eats our [], so we need to use [ and ] instead.
44846   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44847   if test "x$has_forbidden_chars" != x; then
44848     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44849     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44850   fi
44851 
44852 
44853   windows_path="$new_path"
44854   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44855     unix_path=`$CYGPATH -u "$windows_path"`
44856     new_path="$unix_path"
44857   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44858     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44859     new_path="$unix_path"
44860   fi
44861 
44862   if test "x$path" != "x$new_path"; then
44863     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44864     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44865 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44866   fi
44867 
44868   # Save the first 10 bytes of this path to the storage, so fixpath can work.
44869   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44870 
44871   else
44872     # We're on a unix platform. Hooray! :)
44873     path="$POTENTIAL_FREETYPE_LIB_PATH"
44874     has_space=`$ECHO "$path" | $GREP " "`
44875     if test "x$has_space" != x; then
44876       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44877 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44878       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44879     fi
44880 
44881     # Use eval to expand a potential ~
44882     eval path="$path"
44883     if test ! -f "$path" && test ! -d "$path"; then
44884       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44885     fi
44886 
44887     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44888   fi
44889 
44890 
44891     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44892     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44893 $as_echo_n "checking for freetype includes... " >&6; }
44894     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44895 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44896     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44897     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44898 $as_echo_n "checking for freetype libraries... " >&6; }
44899     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44900 $as_echo "$FREETYPE_LIB_PATH" >&6; }
44901   fi
44902 
44903           if test "x$FOUND_FREETYPE" != xyes; then
44904             as_fn_error $? "Can not use the built freetype at location given by --with-freetype-src" "$LINENO" 5
44905           fi
44906         else
44907           { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&5
44908 $as_echo "$as_me: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&6;}
44909           as_fn_error $? "Consider building freetype manually and using --with-freetype instead." "$LINENO" 5
44910         fi
44911       else
44912         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&5
44913 $as_echo "$as_me: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&2;}
44914       fi
44915     fi
44916 
44917     if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then
44918       # User has specified settings
44919 
44920       if test "x$BUNDLE_FREETYPE" = x; then
44921         # If not specified, default is to bundle freetype
44922         BUNDLE_FREETYPE=yes
44923       fi
44924 
44925       if test "x$with_freetype" != x; then
44926         POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype/include"
44927         POTENTIAL_FREETYPE_LIB_PATH="$with_freetype/lib"
44928       fi
44929 
44930       # Allow --with-freetype-lib and --with-freetype-include to override
44931       if test "x$with_freetype_include" != x; then
44932         POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype_include"
44933       fi
44934       if test "x$with_freetype_lib" != x; then
44935         POTENTIAL_FREETYPE_LIB_PATH="$with_freetype_lib"
44936       fi
44937 
44938       if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x && test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then
44939         # Okay, we got it. Check that it works.
44940 
44941   POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44942   POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44943   METHOD="--with-freetype"
44944 
44945   # Let's start with an optimistic view of the world :-)
44946   FOUND_FREETYPE=yes
44947 
44948   # First look for the canonical freetype main include file ft2build.h.
44949   if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44950     # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite.
44951     POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2"
44952     if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44953       # Fail.
44954       FOUND_FREETYPE=no
44955     fi
44956   fi
44957 
44958   if test "x$FOUND_FREETYPE" = xyes; then
44959     # Include file found, let's continue the sanity check.
44960     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44961 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44962 
44963     # Reset to default value
44964     FREETYPE_BASE_NAME=freetype
44965     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
44966     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44967       if test "x$OPENJDK_TARGET_OS" = xmacosx \
44968           && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then
44969         # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check
44970         # for the .6 version explicitly.
44971         FREETYPE_BASE_NAME=freetype.6
44972         FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
44973         { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5
44974 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;}
44975       else
44976         { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44977 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44978         FOUND_FREETYPE=no
44979       fi
44980     else
44981       if test "x$OPENJDK_TARGET_OS" = xwindows; then
44982         # On Windows, we will need both .lib and .dll file.
44983         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then
44984           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5
44985 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;}
44986           FOUND_FREETYPE=no
44987         fi
44988       elif test "x$OPENJDK_TARGET_OS" = xsolaris \
44989           && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then
44990         # Found lib in isa dir, use that instead.
44991         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR"
44992         { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5
44993 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;}
44994       fi
44995     fi
44996   fi
44997 
44998   if test "x$FOUND_FREETYPE" = xyes; then
44999 
45000   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45001 
45002   # Input might be given as Windows format, start by converting to
45003   # unix format.
45004   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45005   new_path=`$CYGPATH -u "$path"`
45006 
45007   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45008   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45009   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45010   # "foo.exe" is OK but "foo" is an error.
45011   #
45012   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45013   # It is also a way to make sure we got the proper file name for the real test later on.
45014   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45015   if test "x$test_shortpath" = x; then
45016     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45017 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45018     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45019   fi
45020 
45021   # Call helper function which possibly converts this using DOS-style short mode.
45022   # If so, the updated path is stored in $new_path.
45023 
45024   input_path="$new_path"
45025   # Check if we need to convert this using DOS-style short mode. If the path
45026   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45027   # take no chances and rewrite it.
45028   # Note: m4 eats our [], so we need to use [ and ] instead.
45029   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45030   if test "x$has_forbidden_chars" != x; then
45031     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45032     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45033     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45034     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45035       # Going to short mode and back again did indeed matter. Since short mode is
45036       # case insensitive, let's make it lowercase to improve readability.
45037       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45038       # Now convert it back to Unix-stile (cygpath)
45039       input_path=`$CYGPATH -u "$shortmode_path"`
45040       new_path="$input_path"
45041     fi
45042   fi
45043 
45044   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45045   if test "x$test_cygdrive_prefix" = x; then
45046     # As a simple fix, exclude /usr/bin since it's not a real path.
45047     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45048       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45049       # a path prefixed by /cygdrive for fixpath to work.
45050       new_path="$CYGWIN_ROOT_PATH$input_path"
45051     fi
45052   fi
45053 
45054 
45055   if test "x$path" != "x$new_path"; then
45056     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45057     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45058 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45059   fi
45060 
45061   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45062 
45063   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45064   has_colon=`$ECHO $path | $GREP ^.:`
45065   new_path="$path"
45066   if test "x$has_colon" = x; then
45067     # Not in mixed or Windows style, start by that.
45068     new_path=`cmd //c echo $path`
45069   fi
45070 
45071 
45072   input_path="$new_path"
45073   # Check if we need to convert this using DOS-style short mode. If the path
45074   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45075   # take no chances and rewrite it.
45076   # Note: m4 eats our [], so we need to use [ and ] instead.
45077   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45078   if test "x$has_forbidden_chars" != x; then
45079     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45080     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45081   fi
45082 
45083 
45084   windows_path="$new_path"
45085   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45086     unix_path=`$CYGPATH -u "$windows_path"`
45087     new_path="$unix_path"
45088   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45089     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45090     new_path="$unix_path"
45091   fi
45092 
45093   if test "x$path" != "x$new_path"; then
45094     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45095     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45096 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45097   fi
45098 
45099   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45100   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45101 
45102   else
45103     # We're on a unix platform. Hooray! :)
45104     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45105     has_space=`$ECHO "$path" | $GREP " "`
45106     if test "x$has_space" != x; then
45107       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45108 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45109       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45110     fi
45111 
45112     # Use eval to expand a potential ~
45113     eval path="$path"
45114     if test ! -f "$path" && test ! -d "$path"; then
45115       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45116     fi
45117 
45118     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45119   fi
45120 
45121 
45122   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45123 
45124   # Input might be given as Windows format, start by converting to
45125   # unix format.
45126   path="$POTENTIAL_FREETYPE_LIB_PATH"
45127   new_path=`$CYGPATH -u "$path"`
45128 
45129   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45130   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45131   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45132   # "foo.exe" is OK but "foo" is an error.
45133   #
45134   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45135   # It is also a way to make sure we got the proper file name for the real test later on.
45136   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45137   if test "x$test_shortpath" = x; then
45138     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45139 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45140     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45141   fi
45142 
45143   # Call helper function which possibly converts this using DOS-style short mode.
45144   # If so, the updated path is stored in $new_path.
45145 
45146   input_path="$new_path"
45147   # Check if we need to convert this using DOS-style short mode. If the path
45148   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45149   # take no chances and rewrite it.
45150   # Note: m4 eats our [], so we need to use [ and ] instead.
45151   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45152   if test "x$has_forbidden_chars" != x; then
45153     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45154     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45155     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45156     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45157       # Going to short mode and back again did indeed matter. Since short mode is
45158       # case insensitive, let's make it lowercase to improve readability.
45159       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45160       # Now convert it back to Unix-stile (cygpath)
45161       input_path=`$CYGPATH -u "$shortmode_path"`
45162       new_path="$input_path"
45163     fi
45164   fi
45165 
45166   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45167   if test "x$test_cygdrive_prefix" = x; then
45168     # As a simple fix, exclude /usr/bin since it's not a real path.
45169     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45170       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45171       # a path prefixed by /cygdrive for fixpath to work.
45172       new_path="$CYGWIN_ROOT_PATH$input_path"
45173     fi
45174   fi
45175 
45176 
45177   if test "x$path" != "x$new_path"; then
45178     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45179     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45180 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45181   fi
45182 
45183   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45184 
45185   path="$POTENTIAL_FREETYPE_LIB_PATH"
45186   has_colon=`$ECHO $path | $GREP ^.:`
45187   new_path="$path"
45188   if test "x$has_colon" = x; then
45189     # Not in mixed or Windows style, start by that.
45190     new_path=`cmd //c echo $path`
45191   fi
45192 
45193 
45194   input_path="$new_path"
45195   # Check if we need to convert this using DOS-style short mode. If the path
45196   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45197   # take no chances and rewrite it.
45198   # Note: m4 eats our [], so we need to use [ and ] instead.
45199   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45200   if test "x$has_forbidden_chars" != x; then
45201     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45202     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45203   fi
45204 
45205 
45206   windows_path="$new_path"
45207   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45208     unix_path=`$CYGPATH -u "$windows_path"`
45209     new_path="$unix_path"
45210   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45211     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45212     new_path="$unix_path"
45213   fi
45214 
45215   if test "x$path" != "x$new_path"; then
45216     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45217     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45218 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45219   fi
45220 
45221   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45222   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45223 
45224   else
45225     # We're on a unix platform. Hooray! :)
45226     path="$POTENTIAL_FREETYPE_LIB_PATH"
45227     has_space=`$ECHO "$path" | $GREP " "`
45228     if test "x$has_space" != x; then
45229       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45230 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45231       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45232     fi
45233 
45234     # Use eval to expand a potential ~
45235     eval path="$path"
45236     if test ! -f "$path" && test ! -d "$path"; then
45237       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45238     fi
45239 
45240     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45241   fi
45242 
45243 
45244     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45245     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45246 $as_echo_n "checking for freetype includes... " >&6; }
45247     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45248 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45249     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45250     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45251 $as_echo_n "checking for freetype libraries... " >&6; }
45252     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45253 $as_echo "$FREETYPE_LIB_PATH" >&6; }
45254   fi
45255 
45256         if test "x$FOUND_FREETYPE" != xyes; then
45257           as_fn_error $? "Can not find or use freetype at location given by --with-freetype" "$LINENO" 5
45258         fi
45259       else
45260         # User specified only one of lib or include. This is an error.
45261         if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" = x ; then
45262           { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-lib but not --with-freetype-include" >&5
45263 $as_echo "$as_me: User specified --with-freetype-lib but not --with-freetype-include" >&6;}
45264           as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5
45265         else
45266           { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-include but not --with-freetype-lib" >&5
45267 $as_echo "$as_me: User specified --with-freetype-include but not --with-freetype-lib" >&6;}
45268           as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5
45269         fi
45270       fi
45271     else
45272       # User did not specify settings, but we need freetype. Try to locate it.
45273 
45274       if test "x$BUNDLE_FREETYPE" = x; then
45275         # If not specified, default is to bundle freetype only on windows
45276         if test "x$OPENJDK_TARGET_OS" = xwindows; then
45277           BUNDLE_FREETYPE=yes
45278         else
45279           BUNDLE_FREETYPE=no
45280         fi
45281       fi
45282 
45283       if test "x$FOUND_FREETYPE" != xyes; then
45284         # Check builddeps
45285 
45286 
45287   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
45288     # Source the builddeps file again, to make sure it uses the latest variables!
45289     . $builddepsfile
45290     # Look for a target and build machine specific resource!
45291     eval resource=\${builddep_freetype2_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
45292     if test "x$resource" = x; then
45293       # Ok, lets instead look for a target specific resource
45294       eval resource=\${builddep_freetype2_TARGET_${rewritten_target_var}}
45295     fi
45296     if test "x$resource" = x; then
45297       # Ok, lets instead look for a build specific resource
45298       eval resource=\${builddep_freetype2_BUILD_${rewritten_build_var}}
45299     fi
45300     if test "x$resource" = x; then
45301       # Ok, lets instead look for a generic resource
45302       # (The freetype2 comes from M4 and not the shell, thus no need for eval here.)
45303       resource=${builddep_freetype2}
45304     fi
45305     if test "x$resource" != x; then
45306       { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for freetype2" >&5
45307 $as_echo "$as_me: Using builddeps $resource for freetype2" >&6;}
45308       # If the resource in the builddeps.conf file is an existing directory,
45309       # for example /java/linux/cups
45310       if test -d ${resource}; then
45311         depdir=${resource}
45312       else
45313 
45314   # freetype2 is for example mymodule
45315   # $resource is for example libs/general/libmymod_1_2_3.zip
45316   # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
45317   # $with_builddeps_dir is for example /localhome/builddeps
45318   # depdir is the name of the variable into which we store the depdir, eg MYMOD
45319   # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
45320   # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
45321   filename=`basename $resource`
45322   filebase=`echo $filename | sed 's/\.[^\.]*$//'`
45323   filebase=${filename%%.*}
45324   extension=${filename#*.}
45325   installdir=$with_builddeps_dir/$filebase
45326   if test ! -f $installdir/$filename.unpacked; then
45327     { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency freetype2 from $with_builddeps_server/$resource and installing into $installdir" >&5
45328 $as_echo "$as_me: Downloading build dependency freetype2 from $with_builddeps_server/$resource and installing into $installdir" >&6;}
45329     if test ! -d $installdir; then
45330       mkdir -p $installdir
45331     fi
45332     if test ! -d $installdir; then
45333       as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
45334     fi
45335     tmpfile=`mktemp $installdir/freetype2.XXXXXXXXX`
45336     touch $tmpfile
45337     if test ! -f $tmpfile; then
45338       as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
45339     fi
45340 
45341   # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
45342   # $tmpfile is the local file name for the downloaded file.
45343   VALID_TOOL=no
45344   if test "x$BDEPS_FTP" = xwget; then
45345     VALID_TOOL=yes
45346     wget -O $tmpfile $with_builddeps_server/$resource
45347   fi
45348   if test "x$BDEPS_FTP" = xlftp; then
45349     VALID_TOOL=yes
45350     lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
45351   fi
45352   if test "x$BDEPS_FTP" = xftp; then
45353     VALID_TOOL=yes
45354     FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
45355     FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
45356     FTPUSERPWD=${FTPSERVER%%@*}
45357     if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
45358       FTPUSER=${userpwd%%:*}
45359       FTPPWD=${userpwd#*@}
45360       FTPSERVER=${FTPSERVER#*@}
45361     else
45362       FTPUSER=ftp
45363       FTPPWD=ftp
45364     fi
45365     # the "pass" command does not work on some
45366     # ftp clients (read ftp.exe) but if it works,
45367     # passive mode is better!
45368     ( \
45369         echo "user $FTPUSER $FTPPWD"        ; \
45370         echo "pass"                         ; \
45371         echo "bin"                          ; \
45372         echo "get $FTPPATH $tmpfile"              ; \
45373     ) | ftp -in $FTPSERVER
45374   fi
45375   if test "x$VALID_TOOL" != xyes; then
45376     as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
45377   fi
45378 
45379     mv $tmpfile $installdir/$filename
45380     if test ! -s $installdir/$filename; then
45381       as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
45382     fi
45383     case "$extension" in
45384       zip)  echo "Unzipping $installdir/$filename..."
45385         (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
45386         ;;
45387       tar.gz) echo "Untaring $installdir/$filename..."
45388         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
45389         ;;
45390       tgz) echo "Untaring $installdir/$filename..."
45391         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
45392         ;;
45393       *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
45394         ;;
45395     esac
45396   fi
45397   if test -f $installdir/$filename.unpacked; then
45398     depdir=$installdir
45399   fi
45400 
45401       fi
45402       # Source the builddeps file again, because in the previous command, the depdir
45403       # was updated to point at the current build dependency install directory.
45404       . $builddepsfile
45405       # Now extract variables from the builddeps.conf files.
45406       theroot=${builddep_freetype2_ROOT}
45407       thecflags=${builddep_freetype2_CFLAGS}
45408       thelibs=${builddep_freetype2_LIBS}
45409       if test "x$depdir" = x; then
45410         as_fn_error $? "Could not download build dependency freetype2" "$LINENO" 5
45411       fi
45412       FREETYPE=$depdir
45413       if test "x$theroot" != x; then
45414         FREETYPE="$theroot"
45415       fi
45416       if test "x$thecflags" != x; then
45417         FREETYPE_CFLAGS="$thecflags"
45418       fi
45419       if test "x$thelibs" != x; then
45420         FREETYPE_LIBS="$thelibs"
45421       fi
45422       FOUND_FREETYPE=yes
45423       else FOUND_FREETYPE=no
45424 
45425     fi
45426     else FOUND_FREETYPE=no
45427 
45428   fi
45429 
45430         # BDEPS_CHECK_MODULE will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling.
45431         if test "x$FOUND_FREETYPE" = xyes; then
45432           if test "x$BUNDLE_FREETYPE" = xyes; then
45433             { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using builddeps, but ignoring since we can not bundle that" >&5
45434 $as_echo "$as_me: Found freetype using builddeps, but ignoring since we can not bundle that" >&6;}
45435             FOUND_FREETYPE=no
45436           else
45437             { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5
45438 $as_echo_n "checking for freetype... " >&6; }
45439             { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using builddeps)" >&5
45440 $as_echo "yes (using builddeps)" >&6; }
45441           fi
45442         fi
45443       fi
45444 
45445       # If we have a sysroot, assume that's where we are supposed to look and skip pkg-config.
45446       if test "x$SYSROOT" = x; then
45447         if test "x$FOUND_FREETYPE" != xyes; then
45448           # Check modules using pkg-config, but only if we have it (ugly output results otherwise)
45449           if test "x$PKG_CONFIG" != x; then
45450 
45451 pkg_failed=no
45452 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5
45453 $as_echo_n "checking for FREETYPE... " >&6; }
45454 
45455 if test -n "$FREETYPE_CFLAGS"; then
45456     pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS"
45457  elif test -n "$PKG_CONFIG"; then
45458     if test -n "$PKG_CONFIG" && \
45459     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5
45460   ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5
45461   ac_status=$?
45462   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
45463   test $ac_status = 0; }; then
45464   pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null`
45465 else
45466   pkg_failed=yes
45467 fi
45468  else
45469     pkg_failed=untried
45470 fi
45471 if test -n "$FREETYPE_LIBS"; then
45472     pkg_cv_FREETYPE_LIBS="$FREETYPE_LIBS"
45473  elif test -n "$PKG_CONFIG"; then
45474     if test -n "$PKG_CONFIG" && \
45475     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5
45476   ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5
45477   ac_status=$?
45478   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
45479   test $ac_status = 0; }; then
45480   pkg_cv_FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null`
45481 else
45482   pkg_failed=yes
45483 fi
45484  else
45485     pkg_failed=untried
45486 fi
45487 
45488 
45489 
45490 if test $pkg_failed = yes; then
45491 
45492 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
45493         _pkg_short_errors_supported=yes
45494 else
45495         _pkg_short_errors_supported=no
45496 fi
45497         if test $_pkg_short_errors_supported = yes; then
45498                 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1`
45499         else
45500                 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1`
45501         fi
45502         # Put the nasty error message in config.log where it belongs
45503         echo "$FREETYPE_PKG_ERRORS" >&5
45504 
45505         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
45506 $as_echo "no" >&6; }
45507                 FOUND_FREETYPE=no
45508 elif test $pkg_failed = untried; then
45509         FOUND_FREETYPE=no
45510 else
45511         FREETYPE_CFLAGS=$pkg_cv_FREETYPE_CFLAGS
45512         FREETYPE_LIBS=$pkg_cv_FREETYPE_LIBS
45513         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
45514 $as_echo "yes" >&6; }
45515         FOUND_FREETYPE=yes
45516 fi
45517             if test "x$FOUND_FREETYPE" = xyes; then
45518               # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us.
45519               FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'`
45520               # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64
45521               if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
45522                 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'`
45523               fi
45524               # BDEPS_CHECK_MODULE will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling.
45525               if test "x$BUNDLE_FREETYPE" = xyes; then
45526                 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5
45527 $as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;}
45528                 FOUND_FREETYPE=no
45529               else
45530                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5
45531 $as_echo_n "checking for freetype... " >&6; }
45532                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5
45533 $as_echo "yes (using pkg-config)" >&6; }
45534               fi
45535             fi
45536           fi
45537         fi
45538       fi
45539 
45540       if test "x$FOUND_FREETYPE" != xyes; then
45541         # Check in well-known locations
45542         if test "x$OPENJDK_TARGET_OS" = xwindows; then
45543           FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32"
45544 
45545   windows_path="$FREETYPE_BASE_DIR"
45546   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45547     unix_path=`$CYGPATH -u "$windows_path"`
45548     FREETYPE_BASE_DIR="$unix_path"
45549   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45550     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45551     FREETYPE_BASE_DIR="$unix_path"
45552   fi
45553 
45554 
45555   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45556   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
45557   METHOD="well-known location"
45558 
45559   # Let's start with an optimistic view of the world :-)
45560   FOUND_FREETYPE=yes
45561 
45562   # First look for the canonical freetype main include file ft2build.h.
45563   if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45564     # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite.
45565     POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2"
45566     if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45567       # Fail.
45568       FOUND_FREETYPE=no
45569     fi
45570   fi
45571 
45572   if test "x$FOUND_FREETYPE" = xyes; then
45573     # Include file found, let's continue the sanity check.
45574     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45575 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45576 
45577     # Reset to default value
45578     FREETYPE_BASE_NAME=freetype
45579     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
45580     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45581       if test "x$OPENJDK_TARGET_OS" = xmacosx \
45582           && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then
45583         # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check
45584         # for the .6 version explicitly.
45585         FREETYPE_BASE_NAME=freetype.6
45586         FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
45587         { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5
45588 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;}
45589       else
45590         { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45591 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45592         FOUND_FREETYPE=no
45593       fi
45594     else
45595       if test "x$OPENJDK_TARGET_OS" = xwindows; then
45596         # On Windows, we will need both .lib and .dll file.
45597         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then
45598           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5
45599 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;}
45600           FOUND_FREETYPE=no
45601         fi
45602       elif test "x$OPENJDK_TARGET_OS" = xsolaris \
45603           && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then
45604         # Found lib in isa dir, use that instead.
45605         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR"
45606         { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5
45607 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;}
45608       fi
45609     fi
45610   fi
45611 
45612   if test "x$FOUND_FREETYPE" = xyes; then
45613 
45614   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45615 
45616   # Input might be given as Windows format, start by converting to
45617   # unix format.
45618   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45619   new_path=`$CYGPATH -u "$path"`
45620 
45621   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45622   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45623   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45624   # "foo.exe" is OK but "foo" is an error.
45625   #
45626   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45627   # It is also a way to make sure we got the proper file name for the real test later on.
45628   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45629   if test "x$test_shortpath" = x; then
45630     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45631 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45632     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45633   fi
45634 
45635   # Call helper function which possibly converts this using DOS-style short mode.
45636   # If so, the updated path is stored in $new_path.
45637 
45638   input_path="$new_path"
45639   # Check if we need to convert this using DOS-style short mode. If the path
45640   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45641   # take no chances and rewrite it.
45642   # Note: m4 eats our [], so we need to use [ and ] instead.
45643   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45644   if test "x$has_forbidden_chars" != x; then
45645     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45646     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45647     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45648     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45649       # Going to short mode and back again did indeed matter. Since short mode is
45650       # case insensitive, let's make it lowercase to improve readability.
45651       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45652       # Now convert it back to Unix-stile (cygpath)
45653       input_path=`$CYGPATH -u "$shortmode_path"`
45654       new_path="$input_path"
45655     fi
45656   fi
45657 
45658   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45659   if test "x$test_cygdrive_prefix" = x; then
45660     # As a simple fix, exclude /usr/bin since it's not a real path.
45661     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45662       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45663       # a path prefixed by /cygdrive for fixpath to work.
45664       new_path="$CYGWIN_ROOT_PATH$input_path"
45665     fi
45666   fi
45667 
45668 
45669   if test "x$path" != "x$new_path"; then
45670     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45671     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45672 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45673   fi
45674 
45675   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45676 
45677   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45678   has_colon=`$ECHO $path | $GREP ^.:`
45679   new_path="$path"
45680   if test "x$has_colon" = x; then
45681     # Not in mixed or Windows style, start by that.
45682     new_path=`cmd //c echo $path`
45683   fi
45684 
45685 
45686   input_path="$new_path"
45687   # Check if we need to convert this using DOS-style short mode. If the path
45688   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45689   # take no chances and rewrite it.
45690   # Note: m4 eats our [], so we need to use [ and ] instead.
45691   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45692   if test "x$has_forbidden_chars" != x; then
45693     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45694     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45695   fi
45696 
45697 
45698   windows_path="$new_path"
45699   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45700     unix_path=`$CYGPATH -u "$windows_path"`
45701     new_path="$unix_path"
45702   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45703     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45704     new_path="$unix_path"
45705   fi
45706 
45707   if test "x$path" != "x$new_path"; then
45708     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45709     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
45710 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
45711   fi
45712 
45713   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45714   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45715 
45716   else
45717     # We're on a unix platform. Hooray! :)
45718     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45719     has_space=`$ECHO "$path" | $GREP " "`
45720     if test "x$has_space" != x; then
45721       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45722 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45723       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45724     fi
45725 
45726     # Use eval to expand a potential ~
45727     eval path="$path"
45728     if test ! -f "$path" && test ! -d "$path"; then
45729       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45730     fi
45731 
45732     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
45733   fi
45734 
45735 
45736   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45737 
45738   # Input might be given as Windows format, start by converting to
45739   # unix format.
45740   path="$POTENTIAL_FREETYPE_LIB_PATH"
45741   new_path=`$CYGPATH -u "$path"`
45742 
45743   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45744   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45745   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45746   # "foo.exe" is OK but "foo" is an error.
45747   #
45748   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45749   # It is also a way to make sure we got the proper file name for the real test later on.
45750   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45751   if test "x$test_shortpath" = x; then
45752     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45753 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45754     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
45755   fi
45756 
45757   # Call helper function which possibly converts this using DOS-style short mode.
45758   # If so, the updated path is stored in $new_path.
45759 
45760   input_path="$new_path"
45761   # Check if we need to convert this using DOS-style short mode. If the path
45762   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45763   # take no chances and rewrite it.
45764   # Note: m4 eats our [], so we need to use [ and ] instead.
45765   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45766   if test "x$has_forbidden_chars" != x; then
45767     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45768     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45769     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45770     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45771       # Going to short mode and back again did indeed matter. Since short mode is
45772       # case insensitive, let's make it lowercase to improve readability.
45773       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45774       # Now convert it back to Unix-stile (cygpath)
45775       input_path=`$CYGPATH -u "$shortmode_path"`
45776       new_path="$input_path"
45777     fi
45778   fi
45779 
45780   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45781   if test "x$test_cygdrive_prefix" = x; then
45782     # As a simple fix, exclude /usr/bin since it's not a real path.
45783     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45784       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45785       # a path prefixed by /cygdrive for fixpath to work.
45786       new_path="$CYGWIN_ROOT_PATH$input_path"
45787     fi
45788   fi
45789 
45790 
45791   if test "x$path" != "x$new_path"; then
45792     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45793     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45794 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45795   fi
45796 
45797   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45798 
45799   path="$POTENTIAL_FREETYPE_LIB_PATH"
45800   has_colon=`$ECHO $path | $GREP ^.:`
45801   new_path="$path"
45802   if test "x$has_colon" = x; then
45803     # Not in mixed or Windows style, start by that.
45804     new_path=`cmd //c echo $path`
45805   fi
45806 
45807 
45808   input_path="$new_path"
45809   # Check if we need to convert this using DOS-style short mode. If the path
45810   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45811   # take no chances and rewrite it.
45812   # Note: m4 eats our [], so we need to use [ and ] instead.
45813   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
45814   if test "x$has_forbidden_chars" != x; then
45815     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45816     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45817   fi
45818 
45819 
45820   windows_path="$new_path"
45821   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45822     unix_path=`$CYGPATH -u "$windows_path"`
45823     new_path="$unix_path"
45824   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45825     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45826     new_path="$unix_path"
45827   fi
45828 
45829   if test "x$path" != "x$new_path"; then
45830     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
45831     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
45832 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
45833   fi
45834 
45835   # Save the first 10 bytes of this path to the storage, so fixpath can work.
45836   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
45837 
45838   else
45839     # We're on a unix platform. Hooray! :)
45840     path="$POTENTIAL_FREETYPE_LIB_PATH"
45841     has_space=`$ECHO "$path" | $GREP " "`
45842     if test "x$has_space" != x; then
45843       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
45844 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
45845       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
45846     fi
45847 
45848     # Use eval to expand a potential ~
45849     eval path="$path"
45850     if test ! -f "$path" && test ! -d "$path"; then
45851       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45852     fi
45853 
45854     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45855   fi
45856 
45857 
45858     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45859     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45860 $as_echo_n "checking for freetype includes... " >&6; }
45861     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45862 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45863     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45864     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45865 $as_echo_n "checking for freetype libraries... " >&6; }
45866     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45867 $as_echo "$FREETYPE_LIB_PATH" >&6; }
45868   fi
45869 
45870           if test "x$FOUND_FREETYPE" != xyes; then
45871             FREETYPE_BASE_DIR="$ProgramW6432/GnuWin32"
45872 
45873   windows_path="$FREETYPE_BASE_DIR"
45874   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45875     unix_path=`$CYGPATH -u "$windows_path"`
45876     FREETYPE_BASE_DIR="$unix_path"
45877   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
45878     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
45879     FREETYPE_BASE_DIR="$unix_path"
45880   fi
45881 
45882 
45883   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45884   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
45885   METHOD="well-known location"
45886 
45887   # Let's start with an optimistic view of the world :-)
45888   FOUND_FREETYPE=yes
45889 
45890   # First look for the canonical freetype main include file ft2build.h.
45891   if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45892     # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite.
45893     POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2"
45894     if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45895       # Fail.
45896       FOUND_FREETYPE=no
45897     fi
45898   fi
45899 
45900   if test "x$FOUND_FREETYPE" = xyes; then
45901     # Include file found, let's continue the sanity check.
45902     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45903 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45904 
45905     # Reset to default value
45906     FREETYPE_BASE_NAME=freetype
45907     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
45908     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45909       if test "x$OPENJDK_TARGET_OS" = xmacosx \
45910           && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then
45911         # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check
45912         # for the .6 version explicitly.
45913         FREETYPE_BASE_NAME=freetype.6
45914         FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
45915         { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5
45916 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;}
45917       else
45918         { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45919 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45920         FOUND_FREETYPE=no
45921       fi
45922     else
45923       if test "x$OPENJDK_TARGET_OS" = xwindows; then
45924         # On Windows, we will need both .lib and .dll file.
45925         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then
45926           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5
45927 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;}
45928           FOUND_FREETYPE=no
45929         fi
45930       elif test "x$OPENJDK_TARGET_OS" = xsolaris \
45931           && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then
45932         # Found lib in isa dir, use that instead.
45933         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR"
45934         { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5
45935 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;}
45936       fi
45937     fi
45938   fi
45939 
45940   if test "x$FOUND_FREETYPE" = xyes; then
45941 
45942   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
45943 
45944   # Input might be given as Windows format, start by converting to
45945   # unix format.
45946   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45947   new_path=`$CYGPATH -u "$path"`
45948 
45949   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
45950   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
45951   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
45952   # "foo.exe" is OK but "foo" is an error.
45953   #
45954   # This test is therefore slightly more accurate than "test -f" to check for file precense.
45955   # It is also a way to make sure we got the proper file name for the real test later on.
45956   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
45957   if test "x$test_shortpath" = x; then
45958     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
45959 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
45960     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
45961   fi
45962 
45963   # Call helper function which possibly converts this using DOS-style short mode.
45964   # If so, the updated path is stored in $new_path.
45965 
45966   input_path="$new_path"
45967   # Check if we need to convert this using DOS-style short mode. If the path
45968   # contains just simple characters, use it. Otherwise (spaces, weird characters),
45969   # take no chances and rewrite it.
45970   # Note: m4 eats our [], so we need to use [ and ] instead.
45971   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
45972   if test "x$has_forbidden_chars" != x; then
45973     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
45974     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
45975     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
45976     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
45977       # Going to short mode and back again did indeed matter. Since short mode is
45978       # case insensitive, let's make it lowercase to improve readability.
45979       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
45980       # Now convert it back to Unix-stile (cygpath)
45981       input_path=`$CYGPATH -u "$shortmode_path"`
45982       new_path="$input_path"
45983     fi
45984   fi
45985 
45986   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
45987   if test "x$test_cygdrive_prefix" = x; then
45988     # As a simple fix, exclude /usr/bin since it's not a real path.
45989     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
45990       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
45991       # a path prefixed by /cygdrive for fixpath to work.
45992       new_path="$CYGWIN_ROOT_PATH$input_path"
45993     fi
45994   fi
45995 
45996 
45997   if test "x$path" != "x$new_path"; then
45998     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
45999     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46000 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46001   fi
46002 
46003   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46004 
46005   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46006   has_colon=`$ECHO $path | $GREP ^.:`
46007   new_path="$path"
46008   if test "x$has_colon" = x; then
46009     # Not in mixed or Windows style, start by that.
46010     new_path=`cmd //c echo $path`
46011   fi
46012 
46013 
46014   input_path="$new_path"
46015   # Check if we need to convert this using DOS-style short mode. If the path
46016   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46017   # take no chances and rewrite it.
46018   # Note: m4 eats our [], so we need to use [ and ] instead.
46019   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46020   if test "x$has_forbidden_chars" != x; then
46021     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46022     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46023   fi
46024 
46025 
46026   windows_path="$new_path"
46027   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46028     unix_path=`$CYGPATH -u "$windows_path"`
46029     new_path="$unix_path"
46030   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46031     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46032     new_path="$unix_path"
46033   fi
46034 
46035   if test "x$path" != "x$new_path"; then
46036     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
46037     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46038 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46039   fi
46040 
46041   # Save the first 10 bytes of this path to the storage, so fixpath can work.
46042   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46043 
46044   else
46045     # We're on a unix platform. Hooray! :)
46046     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46047     has_space=`$ECHO "$path" | $GREP " "`
46048     if test "x$has_space" != x; then
46049       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46050 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46051       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46052     fi
46053 
46054     # Use eval to expand a potential ~
46055     eval path="$path"
46056     if test ! -f "$path" && test ! -d "$path"; then
46057       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46058     fi
46059 
46060     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
46061   fi
46062 
46063 
46064   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46065 
46066   # Input might be given as Windows format, start by converting to
46067   # unix format.
46068   path="$POTENTIAL_FREETYPE_LIB_PATH"
46069   new_path=`$CYGPATH -u "$path"`
46070 
46071   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46072   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46073   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46074   # "foo.exe" is OK but "foo" is an error.
46075   #
46076   # This test is therefore slightly more accurate than "test -f" to check for file precense.
46077   # It is also a way to make sure we got the proper file name for the real test later on.
46078   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46079   if test "x$test_shortpath" = x; then
46080     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46081 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46082     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
46083   fi
46084 
46085   # Call helper function which possibly converts this using DOS-style short mode.
46086   # If so, the updated path is stored in $new_path.
46087 
46088   input_path="$new_path"
46089   # Check if we need to convert this using DOS-style short mode. If the path
46090   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46091   # take no chances and rewrite it.
46092   # Note: m4 eats our [], so we need to use [ and ] instead.
46093   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46094   if test "x$has_forbidden_chars" != x; then
46095     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46096     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46097     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46098     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46099       # Going to short mode and back again did indeed matter. Since short mode is
46100       # case insensitive, let's make it lowercase to improve readability.
46101       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46102       # Now convert it back to Unix-stile (cygpath)
46103       input_path=`$CYGPATH -u "$shortmode_path"`
46104       new_path="$input_path"
46105     fi
46106   fi
46107 
46108   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46109   if test "x$test_cygdrive_prefix" = x; then
46110     # As a simple fix, exclude /usr/bin since it's not a real path.
46111     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46112       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46113       # a path prefixed by /cygdrive for fixpath to work.
46114       new_path="$CYGWIN_ROOT_PATH$input_path"
46115     fi
46116   fi
46117 
46118 
46119   if test "x$path" != "x$new_path"; then
46120     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
46121     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
46122 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46123   fi
46124 
46125   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46126 
46127   path="$POTENTIAL_FREETYPE_LIB_PATH"
46128   has_colon=`$ECHO $path | $GREP ^.:`
46129   new_path="$path"
46130   if test "x$has_colon" = x; then
46131     # Not in mixed or Windows style, start by that.
46132     new_path=`cmd //c echo $path`
46133   fi
46134 
46135 
46136   input_path="$new_path"
46137   # Check if we need to convert this using DOS-style short mode. If the path
46138   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46139   # take no chances and rewrite it.
46140   # Note: m4 eats our [], so we need to use [ and ] instead.
46141   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46142   if test "x$has_forbidden_chars" != x; then
46143     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46144     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46145   fi
46146 
46147 
46148   windows_path="$new_path"
46149   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46150     unix_path=`$CYGPATH -u "$windows_path"`
46151     new_path="$unix_path"
46152   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46153     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46154     new_path="$unix_path"
46155   fi
46156 
46157   if test "x$path" != "x$new_path"; then
46158     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
46159     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
46160 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46161   fi
46162 
46163   # Save the first 10 bytes of this path to the storage, so fixpath can work.
46164   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46165 
46166   else
46167     # We're on a unix platform. Hooray! :)
46168     path="$POTENTIAL_FREETYPE_LIB_PATH"
46169     has_space=`$ECHO "$path" | $GREP " "`
46170     if test "x$has_space" != x; then
46171       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46172 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46173       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46174     fi
46175 
46176     # Use eval to expand a potential ~
46177     eval path="$path"
46178     if test ! -f "$path" && test ! -d "$path"; then
46179       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46180     fi
46181 
46182     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
46183   fi
46184 
46185 
46186     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46187     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
46188 $as_echo_n "checking for freetype includes... " >&6; }
46189     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
46190 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
46191     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
46192     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
46193 $as_echo_n "checking for freetype libraries... " >&6; }
46194     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
46195 $as_echo "$FREETYPE_LIB_PATH" >&6; }
46196   fi
46197 
46198           fi
46199         else
46200           FREETYPE_BASE_DIR="$SYSROOT/usr"
46201 
46202   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
46203   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
46204   METHOD="well-known location"
46205 
46206   # Let's start with an optimistic view of the world :-)
46207   FOUND_FREETYPE=yes
46208 
46209   # First look for the canonical freetype main include file ft2build.h.
46210   if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
46211     # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite.
46212     POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2"
46213     if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
46214       # Fail.
46215       FOUND_FREETYPE=no
46216     fi
46217   fi
46218 
46219   if test "x$FOUND_FREETYPE" = xyes; then
46220     # Include file found, let's continue the sanity check.
46221     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
46222 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
46223 
46224     # Reset to default value
46225     FREETYPE_BASE_NAME=freetype
46226     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
46227     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
46228       if test "x$OPENJDK_TARGET_OS" = xmacosx \
46229           && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then
46230         # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check
46231         # for the .6 version explicitly.
46232         FREETYPE_BASE_NAME=freetype.6
46233         FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
46234         { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5
46235 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;}
46236       else
46237         { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
46238 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
46239         FOUND_FREETYPE=no
46240       fi
46241     else
46242       if test "x$OPENJDK_TARGET_OS" = xwindows; then
46243         # On Windows, we will need both .lib and .dll file.
46244         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then
46245           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5
46246 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;}
46247           FOUND_FREETYPE=no
46248         fi
46249       elif test "x$OPENJDK_TARGET_OS" = xsolaris \
46250           && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then
46251         # Found lib in isa dir, use that instead.
46252         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR"
46253         { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5
46254 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;}
46255       fi
46256     fi
46257   fi
46258 
46259   if test "x$FOUND_FREETYPE" = xyes; then
46260 
46261   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46262 
46263   # Input might be given as Windows format, start by converting to
46264   # unix format.
46265   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46266   new_path=`$CYGPATH -u "$path"`
46267 
46268   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46269   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46270   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46271   # "foo.exe" is OK but "foo" is an error.
46272   #
46273   # This test is therefore slightly more accurate than "test -f" to check for file precense.
46274   # It is also a way to make sure we got the proper file name for the real test later on.
46275   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46276   if test "x$test_shortpath" = x; then
46277     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46278 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46279     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
46280   fi
46281 
46282   # Call helper function which possibly converts this using DOS-style short mode.
46283   # If so, the updated path is stored in $new_path.
46284 
46285   input_path="$new_path"
46286   # Check if we need to convert this using DOS-style short mode. If the path
46287   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46288   # take no chances and rewrite it.
46289   # Note: m4 eats our [], so we need to use [ and ] instead.
46290   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46291   if test "x$has_forbidden_chars" != x; then
46292     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46293     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46294     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46295     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46296       # Going to short mode and back again did indeed matter. Since short mode is
46297       # case insensitive, let's make it lowercase to improve readability.
46298       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46299       # Now convert it back to Unix-stile (cygpath)
46300       input_path=`$CYGPATH -u "$shortmode_path"`
46301       new_path="$input_path"
46302     fi
46303   fi
46304 
46305   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46306   if test "x$test_cygdrive_prefix" = x; then
46307     # As a simple fix, exclude /usr/bin since it's not a real path.
46308     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46309       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46310       # a path prefixed by /cygdrive for fixpath to work.
46311       new_path="$CYGWIN_ROOT_PATH$input_path"
46312     fi
46313   fi
46314 
46315 
46316   if test "x$path" != "x$new_path"; then
46317     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
46318     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46319 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46320   fi
46321 
46322   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46323 
46324   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46325   has_colon=`$ECHO $path | $GREP ^.:`
46326   new_path="$path"
46327   if test "x$has_colon" = x; then
46328     # Not in mixed or Windows style, start by that.
46329     new_path=`cmd //c echo $path`
46330   fi
46331 
46332 
46333   input_path="$new_path"
46334   # Check if we need to convert this using DOS-style short mode. If the path
46335   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46336   # take no chances and rewrite it.
46337   # Note: m4 eats our [], so we need to use [ and ] instead.
46338   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46339   if test "x$has_forbidden_chars" != x; then
46340     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46341     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46342   fi
46343 
46344 
46345   windows_path="$new_path"
46346   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46347     unix_path=`$CYGPATH -u "$windows_path"`
46348     new_path="$unix_path"
46349   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46350     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46351     new_path="$unix_path"
46352   fi
46353 
46354   if test "x$path" != "x$new_path"; then
46355     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
46356     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46357 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46358   fi
46359 
46360   # Save the first 10 bytes of this path to the storage, so fixpath can work.
46361   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46362 
46363   else
46364     # We're on a unix platform. Hooray! :)
46365     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46366     has_space=`$ECHO "$path" | $GREP " "`
46367     if test "x$has_space" != x; then
46368       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46369 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46370       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46371     fi
46372 
46373     # Use eval to expand a potential ~
46374     eval path="$path"
46375     if test ! -f "$path" && test ! -d "$path"; then
46376       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46377     fi
46378 
46379     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
46380   fi
46381 
46382 
46383   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46384 
46385   # Input might be given as Windows format, start by converting to
46386   # unix format.
46387   path="$POTENTIAL_FREETYPE_LIB_PATH"
46388   new_path=`$CYGPATH -u "$path"`
46389 
46390   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46391   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46392   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46393   # "foo.exe" is OK but "foo" is an error.
46394   #
46395   # This test is therefore slightly more accurate than "test -f" to check for file precense.
46396   # It is also a way to make sure we got the proper file name for the real test later on.
46397   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46398   if test "x$test_shortpath" = x; then
46399     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46400 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46401     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
46402   fi
46403 
46404   # Call helper function which possibly converts this using DOS-style short mode.
46405   # If so, the updated path is stored in $new_path.
46406 
46407   input_path="$new_path"
46408   # Check if we need to convert this using DOS-style short mode. If the path
46409   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46410   # take no chances and rewrite it.
46411   # Note: m4 eats our [], so we need to use [ and ] instead.
46412   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46413   if test "x$has_forbidden_chars" != x; then
46414     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46415     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46416     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46417     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46418       # Going to short mode and back again did indeed matter. Since short mode is
46419       # case insensitive, let's make it lowercase to improve readability.
46420       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46421       # Now convert it back to Unix-stile (cygpath)
46422       input_path=`$CYGPATH -u "$shortmode_path"`
46423       new_path="$input_path"
46424     fi
46425   fi
46426 
46427   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46428   if test "x$test_cygdrive_prefix" = x; then
46429     # As a simple fix, exclude /usr/bin since it's not a real path.
46430     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46431       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46432       # a path prefixed by /cygdrive for fixpath to work.
46433       new_path="$CYGWIN_ROOT_PATH$input_path"
46434     fi
46435   fi
46436 
46437 
46438   if test "x$path" != "x$new_path"; then
46439     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
46440     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
46441 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46442   fi
46443 
46444   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46445 
46446   path="$POTENTIAL_FREETYPE_LIB_PATH"
46447   has_colon=`$ECHO $path | $GREP ^.:`
46448   new_path="$path"
46449   if test "x$has_colon" = x; then
46450     # Not in mixed or Windows style, start by that.
46451     new_path=`cmd //c echo $path`
46452   fi
46453 
46454 
46455   input_path="$new_path"
46456   # Check if we need to convert this using DOS-style short mode. If the path
46457   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46458   # take no chances and rewrite it.
46459   # Note: m4 eats our [], so we need to use [ and ] instead.
46460   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46461   if test "x$has_forbidden_chars" != x; then
46462     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46463     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46464   fi
46465 
46466 
46467   windows_path="$new_path"
46468   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46469     unix_path=`$CYGPATH -u "$windows_path"`
46470     new_path="$unix_path"
46471   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46472     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46473     new_path="$unix_path"
46474   fi
46475 
46476   if test "x$path" != "x$new_path"; then
46477     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
46478     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
46479 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46480   fi
46481 
46482   # Save the first 10 bytes of this path to the storage, so fixpath can work.
46483   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46484 
46485   else
46486     # We're on a unix platform. Hooray! :)
46487     path="$POTENTIAL_FREETYPE_LIB_PATH"
46488     has_space=`$ECHO "$path" | $GREP " "`
46489     if test "x$has_space" != x; then
46490       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46491 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46492       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46493     fi
46494 
46495     # Use eval to expand a potential ~
46496     eval path="$path"
46497     if test ! -f "$path" && test ! -d "$path"; then
46498       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46499     fi
46500 
46501     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
46502   fi
46503 
46504 
46505     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46506     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
46507 $as_echo_n "checking for freetype includes... " >&6; }
46508     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
46509 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
46510     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
46511     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
46512 $as_echo_n "checking for freetype libraries... " >&6; }
46513     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
46514 $as_echo "$FREETYPE_LIB_PATH" >&6; }
46515   fi
46516 
46517 
46518           if test "x$FOUND_FREETYPE" != xyes; then
46519             FREETYPE_BASE_DIR="$SYSROOT/usr/X11"
46520 
46521   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
46522   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
46523   METHOD="well-known location"
46524 
46525   # Let's start with an optimistic view of the world :-)
46526   FOUND_FREETYPE=yes
46527 
46528   # First look for the canonical freetype main include file ft2build.h.
46529   if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
46530     # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite.
46531     POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2"
46532     if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
46533       # Fail.
46534       FOUND_FREETYPE=no
46535     fi
46536   fi
46537 
46538   if test "x$FOUND_FREETYPE" = xyes; then
46539     # Include file found, let's continue the sanity check.
46540     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
46541 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
46542 
46543     # Reset to default value
46544     FREETYPE_BASE_NAME=freetype
46545     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
46546     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
46547       if test "x$OPENJDK_TARGET_OS" = xmacosx \
46548           && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then
46549         # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check
46550         # for the .6 version explicitly.
46551         FREETYPE_BASE_NAME=freetype.6
46552         FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
46553         { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5
46554 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;}
46555       else
46556         { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
46557 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
46558         FOUND_FREETYPE=no
46559       fi
46560     else
46561       if test "x$OPENJDK_TARGET_OS" = xwindows; then
46562         # On Windows, we will need both .lib and .dll file.
46563         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then
46564           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5
46565 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;}
46566           FOUND_FREETYPE=no
46567         fi
46568       elif test "x$OPENJDK_TARGET_OS" = xsolaris \
46569           && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then
46570         # Found lib in isa dir, use that instead.
46571         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR"
46572         { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5
46573 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;}
46574       fi
46575     fi
46576   fi
46577 
46578   if test "x$FOUND_FREETYPE" = xyes; then
46579 
46580   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46581 
46582   # Input might be given as Windows format, start by converting to
46583   # unix format.
46584   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46585   new_path=`$CYGPATH -u "$path"`
46586 
46587   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46588   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46589   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46590   # "foo.exe" is OK but "foo" is an error.
46591   #
46592   # This test is therefore slightly more accurate than "test -f" to check for file precense.
46593   # It is also a way to make sure we got the proper file name for the real test later on.
46594   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46595   if test "x$test_shortpath" = x; then
46596     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46597 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46598     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
46599   fi
46600 
46601   # Call helper function which possibly converts this using DOS-style short mode.
46602   # If so, the updated path is stored in $new_path.
46603 
46604   input_path="$new_path"
46605   # Check if we need to convert this using DOS-style short mode. If the path
46606   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46607   # take no chances and rewrite it.
46608   # Note: m4 eats our [], so we need to use [ and ] instead.
46609   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46610   if test "x$has_forbidden_chars" != x; then
46611     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46612     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46613     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46614     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46615       # Going to short mode and back again did indeed matter. Since short mode is
46616       # case insensitive, let's make it lowercase to improve readability.
46617       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46618       # Now convert it back to Unix-stile (cygpath)
46619       input_path=`$CYGPATH -u "$shortmode_path"`
46620       new_path="$input_path"
46621     fi
46622   fi
46623 
46624   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46625   if test "x$test_cygdrive_prefix" = x; then
46626     # As a simple fix, exclude /usr/bin since it's not a real path.
46627     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46628       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46629       # a path prefixed by /cygdrive for fixpath to work.
46630       new_path="$CYGWIN_ROOT_PATH$input_path"
46631     fi
46632   fi
46633 
46634 
46635   if test "x$path" != "x$new_path"; then
46636     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
46637     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46638 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46639   fi
46640 
46641   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46642 
46643   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46644   has_colon=`$ECHO $path | $GREP ^.:`
46645   new_path="$path"
46646   if test "x$has_colon" = x; then
46647     # Not in mixed or Windows style, start by that.
46648     new_path=`cmd //c echo $path`
46649   fi
46650 
46651 
46652   input_path="$new_path"
46653   # Check if we need to convert this using DOS-style short mode. If the path
46654   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46655   # take no chances and rewrite it.
46656   # Note: m4 eats our [], so we need to use [ and ] instead.
46657   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46658   if test "x$has_forbidden_chars" != x; then
46659     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46660     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46661   fi
46662 
46663 
46664   windows_path="$new_path"
46665   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46666     unix_path=`$CYGPATH -u "$windows_path"`
46667     new_path="$unix_path"
46668   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46669     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46670     new_path="$unix_path"
46671   fi
46672 
46673   if test "x$path" != "x$new_path"; then
46674     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
46675     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46676 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46677   fi
46678 
46679   # Save the first 10 bytes of this path to the storage, so fixpath can work.
46680   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46681 
46682   else
46683     # We're on a unix platform. Hooray! :)
46684     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46685     has_space=`$ECHO "$path" | $GREP " "`
46686     if test "x$has_space" != x; then
46687       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46688 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46689       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46690     fi
46691 
46692     # Use eval to expand a potential ~
46693     eval path="$path"
46694     if test ! -f "$path" && test ! -d "$path"; then
46695       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46696     fi
46697 
46698     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
46699   fi
46700 
46701 
46702   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46703 
46704   # Input might be given as Windows format, start by converting to
46705   # unix format.
46706   path="$POTENTIAL_FREETYPE_LIB_PATH"
46707   new_path=`$CYGPATH -u "$path"`
46708 
46709   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46710   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46711   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46712   # "foo.exe" is OK but "foo" is an error.
46713   #
46714   # This test is therefore slightly more accurate than "test -f" to check for file precense.
46715   # It is also a way to make sure we got the proper file name for the real test later on.
46716   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46717   if test "x$test_shortpath" = x; then
46718     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46719 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46720     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
46721   fi
46722 
46723   # Call helper function which possibly converts this using DOS-style short mode.
46724   # If so, the updated path is stored in $new_path.
46725 
46726   input_path="$new_path"
46727   # Check if we need to convert this using DOS-style short mode. If the path
46728   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46729   # take no chances and rewrite it.
46730   # Note: m4 eats our [], so we need to use [ and ] instead.
46731   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46732   if test "x$has_forbidden_chars" != x; then
46733     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46734     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46735     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46736     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46737       # Going to short mode and back again did indeed matter. Since short mode is
46738       # case insensitive, let's make it lowercase to improve readability.
46739       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46740       # Now convert it back to Unix-stile (cygpath)
46741       input_path=`$CYGPATH -u "$shortmode_path"`
46742       new_path="$input_path"
46743     fi
46744   fi
46745 
46746   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46747   if test "x$test_cygdrive_prefix" = x; then
46748     # As a simple fix, exclude /usr/bin since it's not a real path.
46749     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46750       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46751       # a path prefixed by /cygdrive for fixpath to work.
46752       new_path="$CYGWIN_ROOT_PATH$input_path"
46753     fi
46754   fi
46755 
46756 
46757   if test "x$path" != "x$new_path"; then
46758     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
46759     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
46760 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46761   fi
46762 
46763   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46764 
46765   path="$POTENTIAL_FREETYPE_LIB_PATH"
46766   has_colon=`$ECHO $path | $GREP ^.:`
46767   new_path="$path"
46768   if test "x$has_colon" = x; then
46769     # Not in mixed or Windows style, start by that.
46770     new_path=`cmd //c echo $path`
46771   fi
46772 
46773 
46774   input_path="$new_path"
46775   # Check if we need to convert this using DOS-style short mode. If the path
46776   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46777   # take no chances and rewrite it.
46778   # Note: m4 eats our [], so we need to use [ and ] instead.
46779   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46780   if test "x$has_forbidden_chars" != x; then
46781     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46782     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46783   fi
46784 
46785 
46786   windows_path="$new_path"
46787   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46788     unix_path=`$CYGPATH -u "$windows_path"`
46789     new_path="$unix_path"
46790   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46791     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46792     new_path="$unix_path"
46793   fi
46794 
46795   if test "x$path" != "x$new_path"; then
46796     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
46797     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
46798 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
46799   fi
46800 
46801   # Save the first 10 bytes of this path to the storage, so fixpath can work.
46802   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
46803 
46804   else
46805     # We're on a unix platform. Hooray! :)
46806     path="$POTENTIAL_FREETYPE_LIB_PATH"
46807     has_space=`$ECHO "$path" | $GREP " "`
46808     if test "x$has_space" != x; then
46809       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
46810 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
46811       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
46812     fi
46813 
46814     # Use eval to expand a potential ~
46815     eval path="$path"
46816     if test ! -f "$path" && test ! -d "$path"; then
46817       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
46818     fi
46819 
46820     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
46821   fi
46822 
46823 
46824     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46825     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
46826 $as_echo_n "checking for freetype includes... " >&6; }
46827     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
46828 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
46829     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
46830     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
46831 $as_echo_n "checking for freetype libraries... " >&6; }
46832     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
46833 $as_echo "$FREETYPE_LIB_PATH" >&6; }
46834   fi
46835 
46836           fi
46837 
46838           if test "x$FOUND_FREETYPE" != xyes; then
46839             FREETYPE_BASE_DIR="$SYSROOT/usr/sfw"
46840 
46841   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
46842   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
46843   METHOD="well-known location"
46844 
46845   # Let's start with an optimistic view of the world :-)
46846   FOUND_FREETYPE=yes
46847 
46848   # First look for the canonical freetype main include file ft2build.h.
46849   if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
46850     # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite.
46851     POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2"
46852     if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
46853       # Fail.
46854       FOUND_FREETYPE=no
46855     fi
46856   fi
46857 
46858   if test "x$FOUND_FREETYPE" = xyes; then
46859     # Include file found, let's continue the sanity check.
46860     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
46861 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
46862 
46863     # Reset to default value
46864     FREETYPE_BASE_NAME=freetype
46865     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
46866     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
46867       if test "x$OPENJDK_TARGET_OS" = xmacosx \
46868           && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then
46869         # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check
46870         # for the .6 version explicitly.
46871         FREETYPE_BASE_NAME=freetype.6
46872         FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
46873         { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5
46874 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;}
46875       else
46876         { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
46877 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
46878         FOUND_FREETYPE=no
46879       fi
46880     else
46881       if test "x$OPENJDK_TARGET_OS" = xwindows; then
46882         # On Windows, we will need both .lib and .dll file.
46883         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then
46884           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5
46885 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;}
46886           FOUND_FREETYPE=no
46887         fi
46888       elif test "x$OPENJDK_TARGET_OS" = xsolaris \
46889           && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then
46890         # Found lib in isa dir, use that instead.
46891         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR"
46892         { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5
46893 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;}
46894       fi
46895     fi
46896   fi
46897 
46898   if test "x$FOUND_FREETYPE" = xyes; then
46899 
46900   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46901 
46902   # Input might be given as Windows format, start by converting to
46903   # unix format.
46904   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46905   new_path=`$CYGPATH -u "$path"`
46906 
46907   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
46908   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
46909   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
46910   # "foo.exe" is OK but "foo" is an error.
46911   #
46912   # This test is therefore slightly more accurate than "test -f" to check for file precense.
46913   # It is also a way to make sure we got the proper file name for the real test later on.
46914   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
46915   if test "x$test_shortpath" = x; then
46916     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
46917 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
46918     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
46919   fi
46920 
46921   # Call helper function which possibly converts this using DOS-style short mode.
46922   # If so, the updated path is stored in $new_path.
46923 
46924   input_path="$new_path"
46925   # Check if we need to convert this using DOS-style short mode. If the path
46926   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46927   # take no chances and rewrite it.
46928   # Note: m4 eats our [], so we need to use [ and ] instead.
46929   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
46930   if test "x$has_forbidden_chars" != x; then
46931     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46932     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
46933     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
46934     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
46935       # Going to short mode and back again did indeed matter. Since short mode is
46936       # case insensitive, let's make it lowercase to improve readability.
46937       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46938       # Now convert it back to Unix-stile (cygpath)
46939       input_path=`$CYGPATH -u "$shortmode_path"`
46940       new_path="$input_path"
46941     fi
46942   fi
46943 
46944   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
46945   if test "x$test_cygdrive_prefix" = x; then
46946     # As a simple fix, exclude /usr/bin since it's not a real path.
46947     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
46948       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
46949       # a path prefixed by /cygdrive for fixpath to work.
46950       new_path="$CYGWIN_ROOT_PATH$input_path"
46951     fi
46952   fi
46953 
46954 
46955   if test "x$path" != "x$new_path"; then
46956     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
46957     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46958 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46959   fi
46960 
46961   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46962 
46963   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
46964   has_colon=`$ECHO $path | $GREP ^.:`
46965   new_path="$path"
46966   if test "x$has_colon" = x; then
46967     # Not in mixed or Windows style, start by that.
46968     new_path=`cmd //c echo $path`
46969   fi
46970 
46971 
46972   input_path="$new_path"
46973   # Check if we need to convert this using DOS-style short mode. If the path
46974   # contains just simple characters, use it. Otherwise (spaces, weird characters),
46975   # take no chances and rewrite it.
46976   # Note: m4 eats our [], so we need to use [ and ] instead.
46977   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
46978   if test "x$has_forbidden_chars" != x; then
46979     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
46980     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
46981   fi
46982 
46983 
46984   windows_path="$new_path"
46985   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
46986     unix_path=`$CYGPATH -u "$windows_path"`
46987     new_path="$unix_path"
46988   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
46989     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
46990     new_path="$unix_path"
46991   fi
46992 
46993   if test "x$path" != "x$new_path"; then
46994     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
46995     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
46996 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
46997   fi
46998 
46999   # Save the first 10 bytes of this path to the storage, so fixpath can work.
47000   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
47001 
47002   else
47003     # We're on a unix platform. Hooray! :)
47004     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
47005     has_space=`$ECHO "$path" | $GREP " "`
47006     if test "x$has_space" != x; then
47007       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
47008 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
47009       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
47010     fi
47011 
47012     # Use eval to expand a potential ~
47013     eval path="$path"
47014     if test ! -f "$path" && test ! -d "$path"; then
47015       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
47016     fi
47017 
47018     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
47019   fi
47020 
47021 
47022   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47023 
47024   # Input might be given as Windows format, start by converting to
47025   # unix format.
47026   path="$POTENTIAL_FREETYPE_LIB_PATH"
47027   new_path=`$CYGPATH -u "$path"`
47028 
47029   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
47030   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
47031   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
47032   # "foo.exe" is OK but "foo" is an error.
47033   #
47034   # This test is therefore slightly more accurate than "test -f" to check for file precense.
47035   # It is also a way to make sure we got the proper file name for the real test later on.
47036   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
47037   if test "x$test_shortpath" = x; then
47038     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
47039 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
47040     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
47041   fi
47042 
47043   # Call helper function which possibly converts this using DOS-style short mode.
47044   # If so, the updated path is stored in $new_path.
47045 
47046   input_path="$new_path"
47047   # Check if we need to convert this using DOS-style short mode. If the path
47048   # contains just simple characters, use it. Otherwise (spaces, weird characters),
47049   # take no chances and rewrite it.
47050   # Note: m4 eats our [], so we need to use [ and ] instead.
47051   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
47052   if test "x$has_forbidden_chars" != x; then
47053     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47054     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
47055     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
47056     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
47057       # Going to short mode and back again did indeed matter. Since short mode is
47058       # case insensitive, let's make it lowercase to improve readability.
47059       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47060       # Now convert it back to Unix-stile (cygpath)
47061       input_path=`$CYGPATH -u "$shortmode_path"`
47062       new_path="$input_path"
47063     fi
47064   fi
47065 
47066   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
47067   if test "x$test_cygdrive_prefix" = x; then
47068     # As a simple fix, exclude /usr/bin since it's not a real path.
47069     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
47070       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
47071       # a path prefixed by /cygdrive for fixpath to work.
47072       new_path="$CYGWIN_ROOT_PATH$input_path"
47073     fi
47074   fi
47075 
47076 
47077   if test "x$path" != "x$new_path"; then
47078     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
47079     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
47080 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
47081   fi
47082 
47083   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47084 
47085   path="$POTENTIAL_FREETYPE_LIB_PATH"
47086   has_colon=`$ECHO $path | $GREP ^.:`
47087   new_path="$path"
47088   if test "x$has_colon" = x; then
47089     # Not in mixed or Windows style, start by that.
47090     new_path=`cmd //c echo $path`
47091   fi
47092 
47093 
47094   input_path="$new_path"
47095   # Check if we need to convert this using DOS-style short mode. If the path
47096   # contains just simple characters, use it. Otherwise (spaces, weird characters),
47097   # take no chances and rewrite it.
47098   # Note: m4 eats our [], so we need to use [ and ] instead.
47099   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
47100   if test "x$has_forbidden_chars" != x; then
47101     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47102     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47103   fi
47104 
47105 
47106   windows_path="$new_path"
47107   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47108     unix_path=`$CYGPATH -u "$windows_path"`
47109     new_path="$unix_path"
47110   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47111     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47112     new_path="$unix_path"
47113   fi
47114 
47115   if test "x$path" != "x$new_path"; then
47116     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
47117     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
47118 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
47119   fi
47120 
47121   # Save the first 10 bytes of this path to the storage, so fixpath can work.
47122   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
47123 
47124   else
47125     # We're on a unix platform. Hooray! :)
47126     path="$POTENTIAL_FREETYPE_LIB_PATH"
47127     has_space=`$ECHO "$path" | $GREP " "`
47128     if test "x$has_space" != x; then
47129       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
47130 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
47131       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
47132     fi
47133 
47134     # Use eval to expand a potential ~
47135     eval path="$path"
47136     if test ! -f "$path" && test ! -d "$path"; then
47137       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
47138     fi
47139 
47140     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
47141   fi
47142 
47143 
47144     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
47145     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
47146 $as_echo_n "checking for freetype includes... " >&6; }
47147     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
47148 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
47149     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
47150     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
47151 $as_echo_n "checking for freetype libraries... " >&6; }
47152     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
47153 $as_echo "$FREETYPE_LIB_PATH" >&6; }
47154   fi
47155 
47156           fi
47157 
47158           if test "x$FOUND_FREETYPE" != xyes; then
47159             FREETYPE_BASE_DIR="$SYSROOT/usr"
47160             if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
47161 
47162   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
47163   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/x86_64-linux-gnu"
47164   METHOD="well-known location"
47165 
47166   # Let's start with an optimistic view of the world :-)
47167   FOUND_FREETYPE=yes
47168 
47169   # First look for the canonical freetype main include file ft2build.h.
47170   if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
47171     # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite.
47172     POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2"
47173     if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
47174       # Fail.
47175       FOUND_FREETYPE=no
47176     fi
47177   fi
47178 
47179   if test "x$FOUND_FREETYPE" = xyes; then
47180     # Include file found, let's continue the sanity check.
47181     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
47182 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
47183 
47184     # Reset to default value
47185     FREETYPE_BASE_NAME=freetype
47186     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
47187     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
47188       if test "x$OPENJDK_TARGET_OS" = xmacosx \
47189           && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then
47190         # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check
47191         # for the .6 version explicitly.
47192         FREETYPE_BASE_NAME=freetype.6
47193         FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
47194         { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5
47195 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;}
47196       else
47197         { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
47198 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
47199         FOUND_FREETYPE=no
47200       fi
47201     else
47202       if test "x$OPENJDK_TARGET_OS" = xwindows; then
47203         # On Windows, we will need both .lib and .dll file.
47204         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then
47205           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5
47206 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;}
47207           FOUND_FREETYPE=no
47208         fi
47209       elif test "x$OPENJDK_TARGET_OS" = xsolaris \
47210           && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then
47211         # Found lib in isa dir, use that instead.
47212         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR"
47213         { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5
47214 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;}
47215       fi
47216     fi
47217   fi
47218 
47219   if test "x$FOUND_FREETYPE" = xyes; then
47220 
47221   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47222 
47223   # Input might be given as Windows format, start by converting to
47224   # unix format.
47225   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
47226   new_path=`$CYGPATH -u "$path"`
47227 
47228   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
47229   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
47230   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
47231   # "foo.exe" is OK but "foo" is an error.
47232   #
47233   # This test is therefore slightly more accurate than "test -f" to check for file precense.
47234   # It is also a way to make sure we got the proper file name for the real test later on.
47235   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
47236   if test "x$test_shortpath" = x; then
47237     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
47238 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
47239     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
47240   fi
47241 
47242   # Call helper function which possibly converts this using DOS-style short mode.
47243   # If so, the updated path is stored in $new_path.
47244 
47245   input_path="$new_path"
47246   # Check if we need to convert this using DOS-style short mode. If the path
47247   # contains just simple characters, use it. Otherwise (spaces, weird characters),
47248   # take no chances and rewrite it.
47249   # Note: m4 eats our [], so we need to use [ and ] instead.
47250   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
47251   if test "x$has_forbidden_chars" != x; then
47252     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47253     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
47254     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
47255     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
47256       # Going to short mode and back again did indeed matter. Since short mode is
47257       # case insensitive, let's make it lowercase to improve readability.
47258       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47259       # Now convert it back to Unix-stile (cygpath)
47260       input_path=`$CYGPATH -u "$shortmode_path"`
47261       new_path="$input_path"
47262     fi
47263   fi
47264 
47265   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
47266   if test "x$test_cygdrive_prefix" = x; then
47267     # As a simple fix, exclude /usr/bin since it's not a real path.
47268     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
47269       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
47270       # a path prefixed by /cygdrive for fixpath to work.
47271       new_path="$CYGWIN_ROOT_PATH$input_path"
47272     fi
47273   fi
47274 
47275 
47276   if test "x$path" != "x$new_path"; then
47277     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
47278     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
47279 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
47280   fi
47281 
47282   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47283 
47284   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
47285   has_colon=`$ECHO $path | $GREP ^.:`
47286   new_path="$path"
47287   if test "x$has_colon" = x; then
47288     # Not in mixed or Windows style, start by that.
47289     new_path=`cmd //c echo $path`
47290   fi
47291 
47292 
47293   input_path="$new_path"
47294   # Check if we need to convert this using DOS-style short mode. If the path
47295   # contains just simple characters, use it. Otherwise (spaces, weird characters),
47296   # take no chances and rewrite it.
47297   # Note: m4 eats our [], so we need to use [ and ] instead.
47298   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
47299   if test "x$has_forbidden_chars" != x; then
47300     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47301     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47302   fi
47303 
47304 
47305   windows_path="$new_path"
47306   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47307     unix_path=`$CYGPATH -u "$windows_path"`
47308     new_path="$unix_path"
47309   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47310     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47311     new_path="$unix_path"
47312   fi
47313 
47314   if test "x$path" != "x$new_path"; then
47315     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
47316     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
47317 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
47318   fi
47319 
47320   # Save the first 10 bytes of this path to the storage, so fixpath can work.
47321   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
47322 
47323   else
47324     # We're on a unix platform. Hooray! :)
47325     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
47326     has_space=`$ECHO "$path" | $GREP " "`
47327     if test "x$has_space" != x; then
47328       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
47329 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
47330       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
47331     fi
47332 
47333     # Use eval to expand a potential ~
47334     eval path="$path"
47335     if test ! -f "$path" && test ! -d "$path"; then
47336       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
47337     fi
47338 
47339     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
47340   fi
47341 
47342 
47343   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47344 
47345   # Input might be given as Windows format, start by converting to
47346   # unix format.
47347   path="$POTENTIAL_FREETYPE_LIB_PATH"
47348   new_path=`$CYGPATH -u "$path"`
47349 
47350   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
47351   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
47352   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
47353   # "foo.exe" is OK but "foo" is an error.
47354   #
47355   # This test is therefore slightly more accurate than "test -f" to check for file precense.
47356   # It is also a way to make sure we got the proper file name for the real test later on.
47357   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
47358   if test "x$test_shortpath" = x; then
47359     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
47360 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
47361     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
47362   fi
47363 
47364   # Call helper function which possibly converts this using DOS-style short mode.
47365   # If so, the updated path is stored in $new_path.
47366 
47367   input_path="$new_path"
47368   # Check if we need to convert this using DOS-style short mode. If the path
47369   # contains just simple characters, use it. Otherwise (spaces, weird characters),
47370   # take no chances and rewrite it.
47371   # Note: m4 eats our [], so we need to use [ and ] instead.
47372   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
47373   if test "x$has_forbidden_chars" != x; then
47374     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47375     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
47376     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
47377     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
47378       # Going to short mode and back again did indeed matter. Since short mode is
47379       # case insensitive, let's make it lowercase to improve readability.
47380       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47381       # Now convert it back to Unix-stile (cygpath)
47382       input_path=`$CYGPATH -u "$shortmode_path"`
47383       new_path="$input_path"
47384     fi
47385   fi
47386 
47387   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
47388   if test "x$test_cygdrive_prefix" = x; then
47389     # As a simple fix, exclude /usr/bin since it's not a real path.
47390     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
47391       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
47392       # a path prefixed by /cygdrive for fixpath to work.
47393       new_path="$CYGWIN_ROOT_PATH$input_path"
47394     fi
47395   fi
47396 
47397 
47398   if test "x$path" != "x$new_path"; then
47399     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
47400     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
47401 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
47402   fi
47403 
47404   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47405 
47406   path="$POTENTIAL_FREETYPE_LIB_PATH"
47407   has_colon=`$ECHO $path | $GREP ^.:`
47408   new_path="$path"
47409   if test "x$has_colon" = x; then
47410     # Not in mixed or Windows style, start by that.
47411     new_path=`cmd //c echo $path`
47412   fi
47413 
47414 
47415   input_path="$new_path"
47416   # Check if we need to convert this using DOS-style short mode. If the path
47417   # contains just simple characters, use it. Otherwise (spaces, weird characters),
47418   # take no chances and rewrite it.
47419   # Note: m4 eats our [], so we need to use [ and ] instead.
47420   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
47421   if test "x$has_forbidden_chars" != x; then
47422     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47423     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47424   fi
47425 
47426 
47427   windows_path="$new_path"
47428   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47429     unix_path=`$CYGPATH -u "$windows_path"`
47430     new_path="$unix_path"
47431   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47432     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47433     new_path="$unix_path"
47434   fi
47435 
47436   if test "x$path" != "x$new_path"; then
47437     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
47438     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
47439 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
47440   fi
47441 
47442   # Save the first 10 bytes of this path to the storage, so fixpath can work.
47443   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
47444 
47445   else
47446     # We're on a unix platform. Hooray! :)
47447     path="$POTENTIAL_FREETYPE_LIB_PATH"
47448     has_space=`$ECHO "$path" | $GREP " "`
47449     if test "x$has_space" != x; then
47450       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
47451 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
47452       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
47453     fi
47454 
47455     # Use eval to expand a potential ~
47456     eval path="$path"
47457     if test ! -f "$path" && test ! -d "$path"; then
47458       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
47459     fi
47460 
47461     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
47462   fi
47463 
47464 
47465     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
47466     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
47467 $as_echo_n "checking for freetype includes... " >&6; }
47468     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
47469 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
47470     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
47471     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
47472 $as_echo_n "checking for freetype libraries... " >&6; }
47473     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
47474 $as_echo "$FREETYPE_LIB_PATH" >&6; }
47475   fi
47476 
47477             else
47478 
47479   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
47480   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/i386-linux-gnu"
47481   METHOD="well-known location"
47482 
47483   # Let's start with an optimistic view of the world :-)
47484   FOUND_FREETYPE=yes
47485 
47486   # First look for the canonical freetype main include file ft2build.h.
47487   if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
47488     # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite.
47489     POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2"
47490     if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
47491       # Fail.
47492       FOUND_FREETYPE=no
47493     fi
47494   fi
47495 
47496   if test "x$FOUND_FREETYPE" = xyes; then
47497     # Include file found, let's continue the sanity check.
47498     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
47499 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
47500 
47501     # Reset to default value
47502     FREETYPE_BASE_NAME=freetype
47503     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
47504     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
47505       if test "x$OPENJDK_TARGET_OS" = xmacosx \
47506           && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then
47507         # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check
47508         # for the .6 version explicitly.
47509         FREETYPE_BASE_NAME=freetype.6
47510         FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
47511         { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5
47512 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;}
47513       else
47514         { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
47515 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
47516         FOUND_FREETYPE=no
47517       fi
47518     else
47519       if test "x$OPENJDK_TARGET_OS" = xwindows; then
47520         # On Windows, we will need both .lib and .dll file.
47521         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then
47522           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5
47523 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;}
47524           FOUND_FREETYPE=no
47525         fi
47526       elif test "x$OPENJDK_TARGET_OS" = xsolaris \
47527           && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then
47528         # Found lib in isa dir, use that instead.
47529         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR"
47530         { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5
47531 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;}
47532       fi
47533     fi
47534   fi
47535 
47536   if test "x$FOUND_FREETYPE" = xyes; then
47537 
47538   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47539 
47540   # Input might be given as Windows format, start by converting to
47541   # unix format.
47542   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
47543   new_path=`$CYGPATH -u "$path"`
47544 
47545   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
47546   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
47547   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
47548   # "foo.exe" is OK but "foo" is an error.
47549   #
47550   # This test is therefore slightly more accurate than "test -f" to check for file precense.
47551   # It is also a way to make sure we got the proper file name for the real test later on.
47552   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
47553   if test "x$test_shortpath" = x; then
47554     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
47555 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
47556     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
47557   fi
47558 
47559   # Call helper function which possibly converts this using DOS-style short mode.
47560   # If so, the updated path is stored in $new_path.
47561 
47562   input_path="$new_path"
47563   # Check if we need to convert this using DOS-style short mode. If the path
47564   # contains just simple characters, use it. Otherwise (spaces, weird characters),
47565   # take no chances and rewrite it.
47566   # Note: m4 eats our [], so we need to use [ and ] instead.
47567   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
47568   if test "x$has_forbidden_chars" != x; then
47569     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47570     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
47571     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
47572     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
47573       # Going to short mode and back again did indeed matter. Since short mode is
47574       # case insensitive, let's make it lowercase to improve readability.
47575       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47576       # Now convert it back to Unix-stile (cygpath)
47577       input_path=`$CYGPATH -u "$shortmode_path"`
47578       new_path="$input_path"
47579     fi
47580   fi
47581 
47582   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
47583   if test "x$test_cygdrive_prefix" = x; then
47584     # As a simple fix, exclude /usr/bin since it's not a real path.
47585     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
47586       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
47587       # a path prefixed by /cygdrive for fixpath to work.
47588       new_path="$CYGWIN_ROOT_PATH$input_path"
47589     fi
47590   fi
47591 
47592 
47593   if test "x$path" != "x$new_path"; then
47594     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
47595     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
47596 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
47597   fi
47598 
47599   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47600 
47601   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
47602   has_colon=`$ECHO $path | $GREP ^.:`
47603   new_path="$path"
47604   if test "x$has_colon" = x; then
47605     # Not in mixed or Windows style, start by that.
47606     new_path=`cmd //c echo $path`
47607   fi
47608 
47609 
47610   input_path="$new_path"
47611   # Check if we need to convert this using DOS-style short mode. If the path
47612   # contains just simple characters, use it. Otherwise (spaces, weird characters),
47613   # take no chances and rewrite it.
47614   # Note: m4 eats our [], so we need to use [ and ] instead.
47615   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
47616   if test "x$has_forbidden_chars" != x; then
47617     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47618     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47619   fi
47620 
47621 
47622   windows_path="$new_path"
47623   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47624     unix_path=`$CYGPATH -u "$windows_path"`
47625     new_path="$unix_path"
47626   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47627     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47628     new_path="$unix_path"
47629   fi
47630 
47631   if test "x$path" != "x$new_path"; then
47632     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
47633     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
47634 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
47635   fi
47636 
47637   # Save the first 10 bytes of this path to the storage, so fixpath can work.
47638   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
47639 
47640   else
47641     # We're on a unix platform. Hooray! :)
47642     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
47643     has_space=`$ECHO "$path" | $GREP " "`
47644     if test "x$has_space" != x; then
47645       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
47646 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
47647       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
47648     fi
47649 
47650     # Use eval to expand a potential ~
47651     eval path="$path"
47652     if test ! -f "$path" && test ! -d "$path"; then
47653       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
47654     fi
47655 
47656     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
47657   fi
47658 
47659 
47660   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47661 
47662   # Input might be given as Windows format, start by converting to
47663   # unix format.
47664   path="$POTENTIAL_FREETYPE_LIB_PATH"
47665   new_path=`$CYGPATH -u "$path"`
47666 
47667   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
47668   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
47669   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
47670   # "foo.exe" is OK but "foo" is an error.
47671   #
47672   # This test is therefore slightly more accurate than "test -f" to check for file precense.
47673   # It is also a way to make sure we got the proper file name for the real test later on.
47674   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
47675   if test "x$test_shortpath" = x; then
47676     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
47677 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
47678     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
47679   fi
47680 
47681   # Call helper function which possibly converts this using DOS-style short mode.
47682   # If so, the updated path is stored in $new_path.
47683 
47684   input_path="$new_path"
47685   # Check if we need to convert this using DOS-style short mode. If the path
47686   # contains just simple characters, use it. Otherwise (spaces, weird characters),
47687   # take no chances and rewrite it.
47688   # Note: m4 eats our [], so we need to use [ and ] instead.
47689   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
47690   if test "x$has_forbidden_chars" != x; then
47691     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47692     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
47693     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
47694     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
47695       # Going to short mode and back again did indeed matter. Since short mode is
47696       # case insensitive, let's make it lowercase to improve readability.
47697       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47698       # Now convert it back to Unix-stile (cygpath)
47699       input_path=`$CYGPATH -u "$shortmode_path"`
47700       new_path="$input_path"
47701     fi
47702   fi
47703 
47704   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
47705   if test "x$test_cygdrive_prefix" = x; then
47706     # As a simple fix, exclude /usr/bin since it's not a real path.
47707     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
47708       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
47709       # a path prefixed by /cygdrive for fixpath to work.
47710       new_path="$CYGWIN_ROOT_PATH$input_path"
47711     fi
47712   fi
47713 
47714 
47715   if test "x$path" != "x$new_path"; then
47716     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
47717     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
47718 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
47719   fi
47720 
47721   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47722 
47723   path="$POTENTIAL_FREETYPE_LIB_PATH"
47724   has_colon=`$ECHO $path | $GREP ^.:`
47725   new_path="$path"
47726   if test "x$has_colon" = x; then
47727     # Not in mixed or Windows style, start by that.
47728     new_path=`cmd //c echo $path`
47729   fi
47730 
47731 
47732   input_path="$new_path"
47733   # Check if we need to convert this using DOS-style short mode. If the path
47734   # contains just simple characters, use it. Otherwise (spaces, weird characters),
47735   # take no chances and rewrite it.
47736   # Note: m4 eats our [], so we need to use [ and ] instead.
47737   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
47738   if test "x$has_forbidden_chars" != x; then
47739     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47740     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47741   fi
47742 
47743 
47744   windows_path="$new_path"
47745   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47746     unix_path=`$CYGPATH -u "$windows_path"`
47747     new_path="$unix_path"
47748   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47749     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47750     new_path="$unix_path"
47751   fi
47752 
47753   if test "x$path" != "x$new_path"; then
47754     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
47755     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
47756 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
47757   fi
47758 
47759   # Save the first 10 bytes of this path to the storage, so fixpath can work.
47760   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
47761 
47762   else
47763     # We're on a unix platform. Hooray! :)
47764     path="$POTENTIAL_FREETYPE_LIB_PATH"
47765     has_space=`$ECHO "$path" | $GREP " "`
47766     if test "x$has_space" != x; then
47767       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
47768 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
47769       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
47770     fi
47771 
47772     # Use eval to expand a potential ~
47773     eval path="$path"
47774     if test ! -f "$path" && test ! -d "$path"; then
47775       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
47776     fi
47777 
47778     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
47779   fi
47780 
47781 
47782     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
47783     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
47784 $as_echo_n "checking for freetype includes... " >&6; }
47785     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
47786 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
47787     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
47788     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
47789 $as_echo_n "checking for freetype libraries... " >&6; }
47790     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
47791 $as_echo "$FREETYPE_LIB_PATH" >&6; }
47792   fi
47793 
47794               if test "x$FOUND_FREETYPE" != xyes; then
47795 
47796   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
47797   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32"
47798   METHOD="well-known location"
47799 
47800   # Let's start with an optimistic view of the world :-)
47801   FOUND_FREETYPE=yes
47802 
47803   # First look for the canonical freetype main include file ft2build.h.
47804   if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
47805     # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite.
47806     POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2"
47807     if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
47808       # Fail.
47809       FOUND_FREETYPE=no
47810     fi
47811   fi
47812 
47813   if test "x$FOUND_FREETYPE" = xyes; then
47814     # Include file found, let's continue the sanity check.
47815     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
47816 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
47817 
47818     # Reset to default value
47819     FREETYPE_BASE_NAME=freetype
47820     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
47821     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
47822       if test "x$OPENJDK_TARGET_OS" = xmacosx \
47823           && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then
47824         # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check
47825         # for the .6 version explicitly.
47826         FREETYPE_BASE_NAME=freetype.6
47827         FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}"
47828         { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5
47829 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;}
47830       else
47831         { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
47832 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
47833         FOUND_FREETYPE=no
47834       fi
47835     else
47836       if test "x$OPENJDK_TARGET_OS" = xwindows; then
47837         # On Windows, we will need both .lib and .dll file.
47838         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then
47839           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5
47840 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;}
47841           FOUND_FREETYPE=no
47842         fi
47843       elif test "x$OPENJDK_TARGET_OS" = xsolaris \
47844           && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then
47845         # Found lib in isa dir, use that instead.
47846         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR"
47847         { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5
47848 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;}
47849       fi
47850     fi
47851   fi
47852 
47853   if test "x$FOUND_FREETYPE" = xyes; then
47854 
47855   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47856 
47857   # Input might be given as Windows format, start by converting to
47858   # unix format.
47859   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
47860   new_path=`$CYGPATH -u "$path"`
47861 
47862   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
47863   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
47864   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
47865   # "foo.exe" is OK but "foo" is an error.
47866   #
47867   # This test is therefore slightly more accurate than "test -f" to check for file precense.
47868   # It is also a way to make sure we got the proper file name for the real test later on.
47869   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
47870   if test "x$test_shortpath" = x; then
47871     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
47872 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
47873     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
47874   fi
47875 
47876   # Call helper function which possibly converts this using DOS-style short mode.
47877   # If so, the updated path is stored in $new_path.
47878 
47879   input_path="$new_path"
47880   # Check if we need to convert this using DOS-style short mode. If the path
47881   # contains just simple characters, use it. Otherwise (spaces, weird characters),
47882   # take no chances and rewrite it.
47883   # Note: m4 eats our [], so we need to use [ and ] instead.
47884   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
47885   if test "x$has_forbidden_chars" != x; then
47886     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47887     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
47888     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
47889     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
47890       # Going to short mode and back again did indeed matter. Since short mode is
47891       # case insensitive, let's make it lowercase to improve readability.
47892       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47893       # Now convert it back to Unix-stile (cygpath)
47894       input_path=`$CYGPATH -u "$shortmode_path"`
47895       new_path="$input_path"
47896     fi
47897   fi
47898 
47899   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
47900   if test "x$test_cygdrive_prefix" = x; then
47901     # As a simple fix, exclude /usr/bin since it's not a real path.
47902     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
47903       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
47904       # a path prefixed by /cygdrive for fixpath to work.
47905       new_path="$CYGWIN_ROOT_PATH$input_path"
47906     fi
47907   fi
47908 
47909 
47910   if test "x$path" != "x$new_path"; then
47911     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
47912     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
47913 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
47914   fi
47915 
47916   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47917 
47918   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
47919   has_colon=`$ECHO $path | $GREP ^.:`
47920   new_path="$path"
47921   if test "x$has_colon" = x; then
47922     # Not in mixed or Windows style, start by that.
47923     new_path=`cmd //c echo $path`
47924   fi
47925 
47926 
47927   input_path="$new_path"
47928   # Check if we need to convert this using DOS-style short mode. If the path
47929   # contains just simple characters, use it. Otherwise (spaces, weird characters),
47930   # take no chances and rewrite it.
47931   # Note: m4 eats our [], so we need to use [ and ] instead.
47932   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
47933   if test "x$has_forbidden_chars" != x; then
47934     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
47935     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
47936   fi
47937 
47938 
47939   windows_path="$new_path"
47940   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47941     unix_path=`$CYGPATH -u "$windows_path"`
47942     new_path="$unix_path"
47943   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
47944     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
47945     new_path="$unix_path"
47946   fi
47947 
47948   if test "x$path" != "x$new_path"; then
47949     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
47950     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
47951 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
47952   fi
47953 
47954   # Save the first 10 bytes of this path to the storage, so fixpath can work.
47955   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
47956 
47957   else
47958     # We're on a unix platform. Hooray! :)
47959     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
47960     has_space=`$ECHO "$path" | $GREP " "`
47961     if test "x$has_space" != x; then
47962       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
47963 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
47964       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
47965     fi
47966 
47967     # Use eval to expand a potential ~
47968     eval path="$path"
47969     if test ! -f "$path" && test ! -d "$path"; then
47970       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
47971     fi
47972 
47973     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
47974   fi
47975 
47976 
47977   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
47978 
47979   # Input might be given as Windows format, start by converting to
47980   # unix format.
47981   path="$POTENTIAL_FREETYPE_LIB_PATH"
47982   new_path=`$CYGPATH -u "$path"`
47983 
47984   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
47985   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
47986   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
47987   # "foo.exe" is OK but "foo" is an error.
47988   #
47989   # This test is therefore slightly more accurate than "test -f" to check for file precense.
47990   # It is also a way to make sure we got the proper file name for the real test later on.
47991   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
47992   if test "x$test_shortpath" = x; then
47993     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
47994 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
47995     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
47996   fi
47997 
47998   # Call helper function which possibly converts this using DOS-style short mode.
47999   # If so, the updated path is stored in $new_path.
48000 
48001   input_path="$new_path"
48002   # Check if we need to convert this using DOS-style short mode. If the path
48003   # contains just simple characters, use it. Otherwise (spaces, weird characters),
48004   # take no chances and rewrite it.
48005   # Note: m4 eats our [], so we need to use [ and ] instead.
48006   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
48007   if test "x$has_forbidden_chars" != x; then
48008     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
48009     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
48010     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
48011     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
48012       # Going to short mode and back again did indeed matter. Since short mode is
48013       # case insensitive, let's make it lowercase to improve readability.
48014       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
48015       # Now convert it back to Unix-stile (cygpath)
48016       input_path=`$CYGPATH -u "$shortmode_path"`
48017       new_path="$input_path"
48018     fi
48019   fi
48020 
48021   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
48022   if test "x$test_cygdrive_prefix" = x; then
48023     # As a simple fix, exclude /usr/bin since it's not a real path.
48024     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
48025       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
48026       # a path prefixed by /cygdrive for fixpath to work.
48027       new_path="$CYGWIN_ROOT_PATH$input_path"
48028     fi
48029   fi
48030 
48031 
48032   if test "x$path" != "x$new_path"; then
48033     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
48034     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
48035 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
48036   fi
48037 
48038   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48039 
48040   path="$POTENTIAL_FREETYPE_LIB_PATH"
48041   has_colon=`$ECHO $path | $GREP ^.:`
48042   new_path="$path"
48043   if test "x$has_colon" = x; then
48044     # Not in mixed or Windows style, start by that.
48045     new_path=`cmd //c echo $path`
48046   fi
48047 
48048 
48049   input_path="$new_path"
48050   # Check if we need to convert this using DOS-style short mode. If the path
48051   # contains just simple characters, use it. Otherwise (spaces, weird characters),
48052   # take no chances and rewrite it.
48053   # Note: m4 eats our [], so we need to use [ and ] instead.
48054   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
48055   if test "x$has_forbidden_chars" != x; then
48056     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
48057     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
48058   fi
48059 
48060 
48061   windows_path="$new_path"
48062   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
48063     unix_path=`$CYGPATH -u "$windows_path"`
48064     new_path="$unix_path"
48065   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48066     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
48067     new_path="$unix_path"
48068   fi
48069 
48070   if test "x$path" != "x$new_path"; then
48071     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
48072     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
48073 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
48074   fi
48075 
48076   # Save the first 10 bytes of this path to the storage, so fixpath can work.
48077   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
48078 
48079   else
48080     # We're on a unix platform. Hooray! :)
48081     path="$POTENTIAL_FREETYPE_LIB_PATH"
48082     has_space=`$ECHO "$path" | $GREP " "`
48083     if test "x$has_space" != x; then
48084       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
48085 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
48086       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
48087     fi
48088 
48089     # Use eval to expand a potential ~
48090     eval path="$path"
48091     if test ! -f "$path" && test ! -d "$path"; then
48092       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
48093     fi
48094 
48095     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
48096   fi
48097 
48098 
48099     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
48100     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
48101 $as_echo_n "checking for freetype includes... " >&6; }
48102     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
48103 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
48104     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
48105     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
48106 $as_echo_n "checking for freetype libraries... " >&6; }
48107     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
48108 $as_echo "$FREETYPE_LIB_PATH" >&6; }
48109   fi
48110 
48111               fi
48112             fi
48113           fi
48114         fi
48115       fi # end check in well-known locations
48116 
48117       if test "x$FOUND_FREETYPE" != xyes; then
48118 
48119   # Print a helpful message on how to acquire the necessary build dependency.
48120   # freetype is the help tag: freetype, cups, pulse, alsa etc
48121   MISSING_DEPENDENCY=freetype
48122 
48123   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
48124     cygwin_help $MISSING_DEPENDENCY
48125   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48126     msys_help $MISSING_DEPENDENCY
48127   else
48128     PKGHANDLER_COMMAND=
48129 
48130     case $PKGHANDLER in
48131       apt-get)
48132         apt_help     $MISSING_DEPENDENCY ;;
48133       yum)
48134         yum_help     $MISSING_DEPENDENCY ;;
48135       port)
48136         port_help    $MISSING_DEPENDENCY ;;
48137       pkgutil)
48138         pkgutil_help $MISSING_DEPENDENCY ;;
48139       pkgadd)
48140         pkgadd_help  $MISSING_DEPENDENCY ;;
48141     esac
48142 
48143     if test "x$PKGHANDLER_COMMAND" != x; then
48144       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
48145     fi
48146   fi
48147 
48148         as_fn_error $? "Could not find freetype! $HELP_MSG " "$LINENO" 5
48149       fi
48150     fi # end user specified settings
48151 
48152     # Set FREETYPE_CFLAGS, _LIBS and _LIB_PATH from include and lib dir.
48153     if test "x$FREETYPE_CFLAGS" = x; then
48154 
48155   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
48156 
48157   # Input might be given as Windows format, start by converting to
48158   # unix format.
48159   path="$FREETYPE_INCLUDE_PATH"
48160   new_path=`$CYGPATH -u "$path"`
48161 
48162   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
48163   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
48164   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
48165   # "foo.exe" is OK but "foo" is an error.
48166   #
48167   # This test is therefore slightly more accurate than "test -f" to check for file precense.
48168   # It is also a way to make sure we got the proper file name for the real test later on.
48169   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
48170   if test "x$test_shortpath" = x; then
48171     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
48172 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
48173     as_fn_error $? "Cannot locate the the path of FREETYPE_INCLUDE_PATH" "$LINENO" 5
48174   fi
48175 
48176   # Call helper function which possibly converts this using DOS-style short mode.
48177   # If so, the updated path is stored in $new_path.
48178 
48179   input_path="$new_path"
48180   # Check if we need to convert this using DOS-style short mode. If the path
48181   # contains just simple characters, use it. Otherwise (spaces, weird characters),
48182   # take no chances and rewrite it.
48183   # Note: m4 eats our [], so we need to use [ and ] instead.
48184   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
48185   if test "x$has_forbidden_chars" != x; then
48186     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
48187     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
48188     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
48189     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
48190       # Going to short mode and back again did indeed matter. Since short mode is
48191       # case insensitive, let's make it lowercase to improve readability.
48192       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
48193       # Now convert it back to Unix-stile (cygpath)
48194       input_path=`$CYGPATH -u "$shortmode_path"`
48195       new_path="$input_path"
48196     fi
48197   fi
48198 
48199   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
48200   if test "x$test_cygdrive_prefix" = x; then
48201     # As a simple fix, exclude /usr/bin since it's not a real path.
48202     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
48203       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
48204       # a path prefixed by /cygdrive for fixpath to work.
48205       new_path="$CYGWIN_ROOT_PATH$input_path"
48206     fi
48207   fi
48208 
48209 
48210   if test "x$path" != "x$new_path"; then
48211     FREETYPE_INCLUDE_PATH="$new_path"
48212     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
48213 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
48214   fi
48215 
48216   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48217 
48218   path="$FREETYPE_INCLUDE_PATH"
48219   has_colon=`$ECHO $path | $GREP ^.:`
48220   new_path="$path"
48221   if test "x$has_colon" = x; then
48222     # Not in mixed or Windows style, start by that.
48223     new_path=`cmd //c echo $path`
48224   fi
48225 
48226 
48227   input_path="$new_path"
48228   # Check if we need to convert this using DOS-style short mode. If the path
48229   # contains just simple characters, use it. Otherwise (spaces, weird characters),
48230   # take no chances and rewrite it.
48231   # Note: m4 eats our [], so we need to use [ and ] instead.
48232   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
48233   if test "x$has_forbidden_chars" != x; then
48234     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
48235     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
48236   fi
48237 
48238 
48239   windows_path="$new_path"
48240   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
48241     unix_path=`$CYGPATH -u "$windows_path"`
48242     new_path="$unix_path"
48243   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48244     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
48245     new_path="$unix_path"
48246   fi
48247 
48248   if test "x$path" != "x$new_path"; then
48249     FREETYPE_INCLUDE_PATH="$new_path"
48250     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
48251 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
48252   fi
48253 
48254   # Save the first 10 bytes of this path to the storage, so fixpath can work.
48255   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
48256 
48257   else
48258     # We're on a unix platform. Hooray! :)
48259     path="$FREETYPE_INCLUDE_PATH"
48260     has_space=`$ECHO "$path" | $GREP " "`
48261     if test "x$has_space" != x; then
48262       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
48263 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
48264       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
48265     fi
48266 
48267     # Use eval to expand a potential ~
48268     eval path="$path"
48269     if test ! -f "$path" && test ! -d "$path"; then
48270       as_fn_error $? "The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
48271     fi
48272 
48273     FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
48274   fi
48275 
48276       if test -d $FREETYPE_INCLUDE_PATH/freetype2/freetype; then
48277         FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH/freetype2 -I$FREETYPE_INCLUDE_PATH"
48278       else
48279         FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH"
48280       fi
48281     fi
48282 
48283     if test "x$FREETYPE_LIBS" = x; then
48284 
48285   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
48286 
48287   # Input might be given as Windows format, start by converting to
48288   # unix format.
48289   path="$FREETYPE_LIB_PATH"
48290   new_path=`$CYGPATH -u "$path"`
48291 
48292   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
48293   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
48294   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
48295   # "foo.exe" is OK but "foo" is an error.
48296   #
48297   # This test is therefore slightly more accurate than "test -f" to check for file precense.
48298   # It is also a way to make sure we got the proper file name for the real test later on.
48299   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
48300   if test "x$test_shortpath" = x; then
48301     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
48302 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
48303     as_fn_error $? "Cannot locate the the path of FREETYPE_LIB_PATH" "$LINENO" 5
48304   fi
48305 
48306   # Call helper function which possibly converts this using DOS-style short mode.
48307   # If so, the updated path is stored in $new_path.
48308 
48309   input_path="$new_path"
48310   # Check if we need to convert this using DOS-style short mode. If the path
48311   # contains just simple characters, use it. Otherwise (spaces, weird characters),
48312   # take no chances and rewrite it.
48313   # Note: m4 eats our [], so we need to use [ and ] instead.
48314   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
48315   if test "x$has_forbidden_chars" != x; then
48316     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
48317     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
48318     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
48319     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
48320       # Going to short mode and back again did indeed matter. Since short mode is
48321       # case insensitive, let's make it lowercase to improve readability.
48322       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
48323       # Now convert it back to Unix-stile (cygpath)
48324       input_path=`$CYGPATH -u "$shortmode_path"`
48325       new_path="$input_path"
48326     fi
48327   fi
48328 
48329   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
48330   if test "x$test_cygdrive_prefix" = x; then
48331     # As a simple fix, exclude /usr/bin since it's not a real path.
48332     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
48333       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
48334       # a path prefixed by /cygdrive for fixpath to work.
48335       new_path="$CYGWIN_ROOT_PATH$input_path"
48336     fi
48337   fi
48338 
48339 
48340   if test "x$path" != "x$new_path"; then
48341     FREETYPE_LIB_PATH="$new_path"
48342     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5
48343 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
48344   fi
48345 
48346   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48347 
48348   path="$FREETYPE_LIB_PATH"
48349   has_colon=`$ECHO $path | $GREP ^.:`
48350   new_path="$path"
48351   if test "x$has_colon" = x; then
48352     # Not in mixed or Windows style, start by that.
48353     new_path=`cmd //c echo $path`
48354   fi
48355 
48356 
48357   input_path="$new_path"
48358   # Check if we need to convert this using DOS-style short mode. If the path
48359   # contains just simple characters, use it. Otherwise (spaces, weird characters),
48360   # take no chances and rewrite it.
48361   # Note: m4 eats our [], so we need to use [ and ] instead.
48362   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
48363   if test "x$has_forbidden_chars" != x; then
48364     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
48365     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
48366   fi
48367 
48368 
48369   windows_path="$new_path"
48370   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
48371     unix_path=`$CYGPATH -u "$windows_path"`
48372     new_path="$unix_path"
48373   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48374     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
48375     new_path="$unix_path"
48376   fi
48377 
48378   if test "x$path" != "x$new_path"; then
48379     FREETYPE_LIB_PATH="$new_path"
48380     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5
48381 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
48382   fi
48383 
48384   # Save the first 10 bytes of this path to the storage, so fixpath can work.
48385   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
48386 
48387   else
48388     # We're on a unix platform. Hooray! :)
48389     path="$FREETYPE_LIB_PATH"
48390     has_space=`$ECHO "$path" | $GREP " "`
48391     if test "x$has_space" != x; then
48392       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
48393 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
48394       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
48395     fi
48396 
48397     # Use eval to expand a potential ~
48398     eval path="$path"
48399     if test ! -f "$path" && test ! -d "$path"; then
48400       as_fn_error $? "The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
48401     fi
48402 
48403     FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
48404   fi
48405 
48406       if test "x$OPENJDK_TARGET_OS" = xwindows; then
48407         FREETYPE_LIBS="$FREETYPE_LIB_PATH/$FREETYPE_BASE_NAME.lib"
48408       else
48409         FREETYPE_LIBS="-L$FREETYPE_LIB_PATH -l$FREETYPE_BASE_NAME"
48410       fi
48411     fi
48412 
48413     # Try to compile it
48414     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can compile and link with freetype" >&5
48415 $as_echo_n "checking if we can compile and link with freetype... " >&6; }
48416     ac_ext=cpp
48417 ac_cpp='$CXXCPP $CPPFLAGS'
48418 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
48419 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
48420 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
48421 
48422     PREV_CXXCFLAGS="$CXXFLAGS"
48423     PREV_LIBS="$LIBS"
48424     PREV_CXX="$CXX"
48425     CXXFLAGS="$CXXFLAGS $FREETYPE_CFLAGS"
48426     LIBS="$LIBS $FREETYPE_LIBS"
48427     CXX="$FIXPATH $CXX"
48428     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
48429 /* end confdefs.h.  */
48430 
48431           #include<ft2build.h>
48432           #include FT_FREETYPE_H
48433           int main () {
48434             FT_Init_FreeType(NULL);
48435             return 0;
48436           }
48437 
48438 _ACEOF
48439 if ac_fn_cxx_try_link "$LINENO"; then :
48440 
48441           { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48442 $as_echo "yes" >&6; }
48443 
48444 else
48445 
48446           { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48447 $as_echo "no" >&6; }
48448           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&5
48449 $as_echo "$as_me: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&6;}
48450           { $as_echo "$as_me:${as_lineno-$LINENO}: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&5
48451 $as_echo "$as_me: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&6;}
48452 
48453 
48454   # Print a helpful message on how to acquire the necessary build dependency.
48455   # freetype is the help tag: freetype, cups, pulse, alsa etc
48456   MISSING_DEPENDENCY=freetype
48457 
48458   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
48459     cygwin_help $MISSING_DEPENDENCY
48460   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48461     msys_help $MISSING_DEPENDENCY
48462   else
48463     PKGHANDLER_COMMAND=
48464 
48465     case $PKGHANDLER in
48466       apt-get)
48467         apt_help     $MISSING_DEPENDENCY ;;
48468       yum)
48469         yum_help     $MISSING_DEPENDENCY ;;
48470       port)
48471         port_help    $MISSING_DEPENDENCY ;;
48472       pkgutil)
48473         pkgutil_help $MISSING_DEPENDENCY ;;
48474       pkgadd)
48475         pkgadd_help  $MISSING_DEPENDENCY ;;
48476     esac
48477 
48478     if test "x$PKGHANDLER_COMMAND" != x; then
48479       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
48480     fi
48481   fi
48482 
48483 
48484           as_fn_error $? "Can not continue without freetype. $HELP_MSG" "$LINENO" 5
48485 
48486 
48487 fi
48488 rm -f core conftest.err conftest.$ac_objext \
48489     conftest$ac_exeext conftest.$ac_ext
48490     CXXCFLAGS="$PREV_CXXFLAGS"
48491     LIBS="$PREV_LIBS"
48492     CXX="$PREV_CXX"
48493     ac_ext=cpp
48494 ac_cpp='$CXXCPP $CPPFLAGS'
48495 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
48496 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
48497 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
48498 
48499 
48500     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should bundle freetype" >&5
48501 $as_echo_n "checking if we should bundle freetype... " >&6; }
48502     if test "x$BUNDLE_FREETYPE" = xyes; then
48503       FREETYPE_BUNDLE_LIB_PATH="$FREETYPE_LIB_PATH"
48504     fi
48505     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUNDLE_FREETYPE" >&5
48506 $as_echo "$BUNDLE_FREETYPE" >&6; }
48507 
48508   fi # end freetype needed
48509 
48510 
48511 
48512 
48513 
48514 
48515 
48516   ###############################################################################
48517   #
48518   # Check for alsa headers and libraries. Used on Linux/GNU systems.
48519   #
48520 
48521 # Check whether --with-alsa was given.
48522 if test "${with_alsa+set}" = set; then :
48523   withval=$with_alsa;
48524 fi
48525 
48526 
48527 # Check whether --with-alsa-include was given.
48528 if test "${with_alsa_include+set}" = set; then :
48529   withval=$with_alsa_include;
48530 fi
48531 
48532 
48533 # Check whether --with-alsa-lib was given.
48534 if test "${with_alsa_lib+set}" = set; then :
48535   withval=$with_alsa_lib;
48536 fi
48537 
48538 
48539   if test "x$ALSA_NOT_NEEDED" = xyes; then
48540     if test "x${with_alsa}" != x || test "x${with_alsa_include}" != x || test "x${with_alsa_lib}" != x; then
48541       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa is ignored" >&5
48542 $as_echo "$as_me: WARNING: alsa not used, so --with-alsa is ignored" >&2;}
48543     fi
48544     ALSA_CFLAGS=
48545     ALSA_LIBS=
48546   else
48547     ALSA_FOUND=no
48548 
48549     if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then
48550       as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5
48551     fi
48552 
48553     if test "x${with_alsa}" != x; then
48554       ALSA_LIBS="-L${with_alsa}/lib -lasound"
48555       ALSA_CFLAGS="-I${with_alsa}/include"
48556       ALSA_FOUND=yes
48557     fi
48558     if test "x${with_alsa_include}" != x; then
48559       ALSA_CFLAGS="-I${with_alsa_include}"
48560       ALSA_FOUND=yes
48561     fi
48562     if test "x${with_alsa_lib}" != x; then
48563       ALSA_LIBS="-L${with_alsa_lib} -lasound"
48564       ALSA_FOUND=yes
48565     fi
48566     if test "x$ALSA_FOUND" = xno; then
48567 
48568 
48569   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
48570     # Source the builddeps file again, to make sure it uses the latest variables!
48571     . $builddepsfile
48572     # Look for a target and build machine specific resource!
48573     eval resource=\${builddep_alsa_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
48574     if test "x$resource" = x; then
48575       # Ok, lets instead look for a target specific resource
48576       eval resource=\${builddep_alsa_TARGET_${rewritten_target_var}}
48577     fi
48578     if test "x$resource" = x; then
48579       # Ok, lets instead look for a build specific resource
48580       eval resource=\${builddep_alsa_BUILD_${rewritten_build_var}}
48581     fi
48582     if test "x$resource" = x; then
48583       # Ok, lets instead look for a generic resource
48584       # (The alsa comes from M4 and not the shell, thus no need for eval here.)
48585       resource=${builddep_alsa}
48586     fi
48587     if test "x$resource" != x; then
48588       { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for alsa" >&5
48589 $as_echo "$as_me: Using builddeps $resource for alsa" >&6;}
48590       # If the resource in the builddeps.conf file is an existing directory,
48591       # for example /java/linux/cups
48592       if test -d ${resource}; then
48593         depdir=${resource}
48594       else
48595 
48596   # alsa is for example mymodule
48597   # $resource is for example libs/general/libmymod_1_2_3.zip
48598   # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
48599   # $with_builddeps_dir is for example /localhome/builddeps
48600   # depdir is the name of the variable into which we store the depdir, eg MYMOD
48601   # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
48602   # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
48603   filename=`basename $resource`
48604   filebase=`echo $filename | sed 's/\.[^\.]*$//'`
48605   filebase=${filename%%.*}
48606   extension=${filename#*.}
48607   installdir=$with_builddeps_dir/$filebase
48608   if test ! -f $installdir/$filename.unpacked; then
48609     { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency alsa from $with_builddeps_server/$resource and installing into $installdir" >&5
48610 $as_echo "$as_me: Downloading build dependency alsa from $with_builddeps_server/$resource and installing into $installdir" >&6;}
48611     if test ! -d $installdir; then
48612       mkdir -p $installdir
48613     fi
48614     if test ! -d $installdir; then
48615       as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
48616     fi
48617     tmpfile=`mktemp $installdir/alsa.XXXXXXXXX`
48618     touch $tmpfile
48619     if test ! -f $tmpfile; then
48620       as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
48621     fi
48622 
48623   # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
48624   # $tmpfile is the local file name for the downloaded file.
48625   VALID_TOOL=no
48626   if test "x$BDEPS_FTP" = xwget; then
48627     VALID_TOOL=yes
48628     wget -O $tmpfile $with_builddeps_server/$resource
48629   fi
48630   if test "x$BDEPS_FTP" = xlftp; then
48631     VALID_TOOL=yes
48632     lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
48633   fi
48634   if test "x$BDEPS_FTP" = xftp; then
48635     VALID_TOOL=yes
48636     FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
48637     FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
48638     FTPUSERPWD=${FTPSERVER%%@*}
48639     if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
48640       FTPUSER=${userpwd%%:*}
48641       FTPPWD=${userpwd#*@}
48642       FTPSERVER=${FTPSERVER#*@}
48643     else
48644       FTPUSER=ftp
48645       FTPPWD=ftp
48646     fi
48647     # the "pass" command does not work on some
48648     # ftp clients (read ftp.exe) but if it works,
48649     # passive mode is better!
48650     ( \
48651         echo "user $FTPUSER $FTPPWD"        ; \
48652         echo "pass"                         ; \
48653         echo "bin"                          ; \
48654         echo "get $FTPPATH $tmpfile"              ; \
48655     ) | ftp -in $FTPSERVER
48656   fi
48657   if test "x$VALID_TOOL" != xyes; then
48658     as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
48659   fi
48660 
48661     mv $tmpfile $installdir/$filename
48662     if test ! -s $installdir/$filename; then
48663       as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
48664     fi
48665     case "$extension" in
48666       zip)  echo "Unzipping $installdir/$filename..."
48667         (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
48668         ;;
48669       tar.gz) echo "Untaring $installdir/$filename..."
48670         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
48671         ;;
48672       tgz) echo "Untaring $installdir/$filename..."
48673         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
48674         ;;
48675       *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
48676         ;;
48677     esac
48678   fi
48679   if test -f $installdir/$filename.unpacked; then
48680     depdir=$installdir
48681   fi
48682 
48683       fi
48684       # Source the builddeps file again, because in the previous command, the depdir
48685       # was updated to point at the current build dependency install directory.
48686       . $builddepsfile
48687       # Now extract variables from the builddeps.conf files.
48688       theroot=${builddep_alsa_ROOT}
48689       thecflags=${builddep_alsa_CFLAGS}
48690       thelibs=${builddep_alsa_LIBS}
48691       if test "x$depdir" = x; then
48692         as_fn_error $? "Could not download build dependency alsa" "$LINENO" 5
48693       fi
48694       ALSA=$depdir
48695       if test "x$theroot" != x; then
48696         ALSA="$theroot"
48697       fi
48698       if test "x$thecflags" != x; then
48699         ALSA_CFLAGS="$thecflags"
48700       fi
48701       if test "x$thelibs" != x; then
48702         ALSA_LIBS="$thelibs"
48703       fi
48704       ALSA_FOUND=yes
48705       else ALSA_FOUND=no
48706 
48707     fi
48708     else ALSA_FOUND=no
48709 
48710   fi
48711 
48712     fi
48713     # Do not try pkg-config if we have a sysroot set.
48714     if test "x$SYSROOT" = x; then
48715       if test "x$ALSA_FOUND" = xno; then
48716 
48717 pkg_failed=no
48718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5
48719 $as_echo_n "checking for ALSA... " >&6; }
48720 
48721 if test -n "$ALSA_CFLAGS"; then
48722     pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS"
48723  elif test -n "$PKG_CONFIG"; then
48724     if test -n "$PKG_CONFIG" && \
48725     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5
48726   ($PKG_CONFIG --exists --print-errors "alsa") 2>&5
48727   ac_status=$?
48728   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
48729   test $ac_status = 0; }; then
48730   pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null`
48731 else
48732   pkg_failed=yes
48733 fi
48734  else
48735     pkg_failed=untried
48736 fi
48737 if test -n "$ALSA_LIBS"; then
48738     pkg_cv_ALSA_LIBS="$ALSA_LIBS"
48739  elif test -n "$PKG_CONFIG"; then
48740     if test -n "$PKG_CONFIG" && \
48741     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5
48742   ($PKG_CONFIG --exists --print-errors "alsa") 2>&5
48743   ac_status=$?
48744   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
48745   test $ac_status = 0; }; then
48746   pkg_cv_ALSA_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null`
48747 else
48748   pkg_failed=yes
48749 fi
48750  else
48751     pkg_failed=untried
48752 fi
48753 
48754 
48755 
48756 if test $pkg_failed = yes; then
48757 
48758 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
48759         _pkg_short_errors_supported=yes
48760 else
48761         _pkg_short_errors_supported=no
48762 fi
48763         if test $_pkg_short_errors_supported = yes; then
48764                 ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1`
48765         else
48766                 ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1`
48767         fi
48768         # Put the nasty error message in config.log where it belongs
48769         echo "$ALSA_PKG_ERRORS" >&5
48770 
48771         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48772 $as_echo "no" >&6; }
48773                 ALSA_FOUND=no
48774 elif test $pkg_failed = untried; then
48775         ALSA_FOUND=no
48776 else
48777         ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS
48778         ALSA_LIBS=$pkg_cv_ALSA_LIBS
48779         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48780 $as_echo "yes" >&6; }
48781         ALSA_FOUND=yes
48782 fi
48783       fi
48784     fi
48785     if test "x$ALSA_FOUND" = xno; then
48786       for ac_header in alsa/asoundlib.h
48787 do :
48788   ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default"
48789 if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then :
48790   cat >>confdefs.h <<_ACEOF
48791 #define HAVE_ALSA_ASOUNDLIB_H 1
48792 _ACEOF
48793 
48794             ALSA_FOUND=yes
48795             ALSA_CFLAGS=-Iignoreme
48796             ALSA_LIBS=-lasound
48797             DEFAULT_ALSA=yes
48798 
48799 else
48800   ALSA_FOUND=no
48801 fi
48802 
48803 done
48804 
48805     fi
48806     if test "x$ALSA_FOUND" = xno; then
48807 
48808   # Print a helpful message on how to acquire the necessary build dependency.
48809   # alsa is the help tag: freetype, cups, pulse, alsa etc
48810   MISSING_DEPENDENCY=alsa
48811 
48812   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
48813     cygwin_help $MISSING_DEPENDENCY
48814   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
48815     msys_help $MISSING_DEPENDENCY
48816   else
48817     PKGHANDLER_COMMAND=
48818 
48819     case $PKGHANDLER in
48820       apt-get)
48821         apt_help     $MISSING_DEPENDENCY ;;
48822       yum)
48823         yum_help     $MISSING_DEPENDENCY ;;
48824       port)
48825         port_help    $MISSING_DEPENDENCY ;;
48826       pkgutil)
48827         pkgutil_help $MISSING_DEPENDENCY ;;
48828       pkgadd)
48829         pkgadd_help  $MISSING_DEPENDENCY ;;
48830     esac
48831 
48832     if test "x$PKGHANDLER_COMMAND" != x; then
48833       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
48834     fi
48835   fi
48836 
48837       as_fn_error $? "Could not find alsa! $HELP_MSG " "$LINENO" 5
48838     fi
48839   fi
48840 
48841 
48842 
48843 
48844 
48845 
48846   ###############################################################################
48847   #
48848   # Check for the jpeg library
48849   #
48850 
48851 
48852 # Check whether --with-libjpeg was given.
48853 if test "${with_libjpeg+set}" = set; then :
48854   withval=$with_libjpeg;
48855 fi
48856 
48857 
48858   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libjpeg to use" >&5
48859 $as_echo_n "checking for which libjpeg to use... " >&6; }
48860 
48861   # default is bundled
48862   DEFAULT_LIBJPEG=bundled
48863 
48864   #
48865   # if user didn't specify, use DEFAULT_LIBJPEG
48866   #
48867   if test "x${with_libjpeg}" = "x"; then
48868     with_libjpeg=${DEFAULT_LIBJPEG}
48869   fi
48870 
48871   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libjpeg}" >&5
48872 $as_echo "${with_libjpeg}" >&6; }
48873 
48874   if test "x${with_libjpeg}" = "xbundled"; then
48875     USE_EXTERNAL_LIBJPEG=false
48876   elif test "x${with_libjpeg}" = "xsystem"; then
48877     ac_fn_cxx_check_header_mongrel "$LINENO" "jpeglib.h" "ac_cv_header_jpeglib_h" "$ac_includes_default"
48878 if test "x$ac_cv_header_jpeglib_h" = xyes; then :
48879 
48880 else
48881    as_fn_error $? "--with-libjpeg=system specified, but jpeglib.h not found!" "$LINENO" 5
48882 fi
48883 
48884 
48885     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_CreateDecompress in -ljpeg" >&5
48886 $as_echo_n "checking for jpeg_CreateDecompress in -ljpeg... " >&6; }
48887 if ${ac_cv_lib_jpeg_jpeg_CreateDecompress+:} false; then :
48888   $as_echo_n "(cached) " >&6
48889 else
48890   ac_check_lib_save_LIBS=$LIBS
48891 LIBS="-ljpeg  $LIBS"
48892 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
48893 /* end confdefs.h.  */
48894 
48895 /* Override any GCC internal prototype to avoid an error.
48896    Use char because int might match the return type of a GCC
48897    builtin and then its argument prototype would still apply.  */
48898 #ifdef __cplusplus
48899 extern "C"
48900 #endif
48901 char jpeg_CreateDecompress ();
48902 int
48903 main ()
48904 {
48905 return jpeg_CreateDecompress ();
48906   ;
48907   return 0;
48908 }
48909 _ACEOF
48910 if ac_fn_cxx_try_link "$LINENO"; then :
48911   ac_cv_lib_jpeg_jpeg_CreateDecompress=yes
48912 else
48913   ac_cv_lib_jpeg_jpeg_CreateDecompress=no
48914 fi
48915 rm -f core conftest.err conftest.$ac_objext \
48916     conftest$ac_exeext conftest.$ac_ext
48917 LIBS=$ac_check_lib_save_LIBS
48918 fi
48919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_CreateDecompress" >&5
48920 $as_echo "$ac_cv_lib_jpeg_jpeg_CreateDecompress" >&6; }
48921 if test "x$ac_cv_lib_jpeg_jpeg_CreateDecompress" = xyes; then :
48922   cat >>confdefs.h <<_ACEOF
48923 #define HAVE_LIBJPEG 1
48924 _ACEOF
48925 
48926   LIBS="-ljpeg $LIBS"
48927 
48928 else
48929    as_fn_error $? "--with-libjpeg=system specified, but no libjpeg found" "$LINENO" 5
48930 fi
48931 
48932 
48933     USE_EXTERNAL_LIBJPEG=true
48934   else
48935     as_fn_error $? "Invalid use of --with-libjpeg: ${with_libjpeg}, use 'system' or 'bundled'" "$LINENO" 5
48936   fi
48937 
48938 
48939 
48940   ###############################################################################
48941   #
48942   # Check for the gif library
48943   #
48944 
48945 
48946 # Check whether --with-giflib was given.
48947 if test "${with_giflib+set}" = set; then :
48948   withval=$with_giflib;
48949 fi
48950 
48951 
48952 
48953   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5
48954 $as_echo_n "checking for which giflib to use... " >&6; }
48955 
48956   # default is bundled
48957   DEFAULT_GIFLIB=bundled
48958 
48959   #
48960   # if user didn't specify, use DEFAULT_GIFLIB
48961   #
48962   if test "x${with_giflib}" = "x"; then
48963     with_giflib=${DEFAULT_GIFLIB}
48964   fi
48965 
48966   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5
48967 $as_echo "${with_giflib}" >&6; }
48968 
48969   if test "x${with_giflib}" = "xbundled"; then
48970     USE_EXTERNAL_LIBGIF=false
48971   elif test "x${with_giflib}" = "xsystem"; then
48972     ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
48973 if test "x$ac_cv_header_gif_lib_h" = xyes; then :
48974 
48975 else
48976    as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5
48977 fi
48978 
48979 
48980     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5
48981 $as_echo_n "checking for DGifGetCode in -lgif... " >&6; }
48982 if ${ac_cv_lib_gif_DGifGetCode+:} false; then :
48983   $as_echo_n "(cached) " >&6
48984 else
48985   ac_check_lib_save_LIBS=$LIBS
48986 LIBS="-lgif  $LIBS"
48987 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
48988 /* end confdefs.h.  */
48989 
48990 /* Override any GCC internal prototype to avoid an error.
48991    Use char because int might match the return type of a GCC
48992    builtin and then its argument prototype would still apply.  */
48993 #ifdef __cplusplus
48994 extern "C"
48995 #endif
48996 char DGifGetCode ();
48997 int
48998 main ()
48999 {
49000 return DGifGetCode ();
49001   ;
49002   return 0;
49003 }
49004 _ACEOF
49005 if ac_fn_cxx_try_link "$LINENO"; then :
49006   ac_cv_lib_gif_DGifGetCode=yes
49007 else
49008   ac_cv_lib_gif_DGifGetCode=no
49009 fi
49010 rm -f core conftest.err conftest.$ac_objext \
49011     conftest$ac_exeext conftest.$ac_ext
49012 LIBS=$ac_check_lib_save_LIBS
49013 fi
49014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5
49015 $as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; }
49016 if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then :
49017   cat >>confdefs.h <<_ACEOF
49018 #define HAVE_LIBGIF 1
49019 _ACEOF
49020 
49021   LIBS="-lgif $LIBS"
49022 
49023 else
49024    as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5
49025 fi
49026 
49027 
49028     USE_EXTERNAL_LIBGIF=true
49029   else
49030     as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5
49031   fi
49032 
49033 
49034   ###############################################################################
49035   #
49036   # Check for the lcms2 library
49037   #
49038 
49039 
49040 # Check whether --with-lcms was given.
49041 if test "${with_lcms+set}" = set; then :
49042   withval=$with_lcms;
49043 fi
49044 
49045 
49046   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which lcms to use" >&5
49047 $as_echo_n "checking for which lcms to use... " >&6; }
49048 
49049   DEFAULT_LCMS=bundled
49050 
49051   #
49052   # If user didn't specify, use DEFAULT_LCMS
49053   #
49054   if test "x${with_lcms}" = "x"; then
49055       with_lcms=${DEFAULT_LCMS}
49056   fi
49057 
49058   if test "x${with_lcms}" = "xbundled"; then
49059     USE_EXTERNAL_LCMS=false
49060     { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5
49061 $as_echo "bundled" >&6; }
49062   elif test "x${with_lcms}" = "xsystem"; then
49063     { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5
49064 $as_echo "system" >&6; }
49065 
49066 pkg_failed=no
49067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LCMS" >&5
49068 $as_echo_n "checking for LCMS... " >&6; }
49069 
49070 if test -n "$LCMS_CFLAGS"; then
49071     pkg_cv_LCMS_CFLAGS="$LCMS_CFLAGS"
49072  elif test -n "$PKG_CONFIG"; then
49073     if test -n "$PKG_CONFIG" && \
49074     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5
49075   ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5
49076   ac_status=$?
49077   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
49078   test $ac_status = 0; }; then
49079   pkg_cv_LCMS_CFLAGS=`$PKG_CONFIG --cflags "lcms2" 2>/dev/null`
49080 else
49081   pkg_failed=yes
49082 fi
49083  else
49084     pkg_failed=untried
49085 fi
49086 if test -n "$LCMS_LIBS"; then
49087     pkg_cv_LCMS_LIBS="$LCMS_LIBS"
49088  elif test -n "$PKG_CONFIG"; then
49089     if test -n "$PKG_CONFIG" && \
49090     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5
49091   ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5
49092   ac_status=$?
49093   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
49094   test $ac_status = 0; }; then
49095   pkg_cv_LCMS_LIBS=`$PKG_CONFIG --libs "lcms2" 2>/dev/null`
49096 else
49097   pkg_failed=yes
49098 fi
49099  else
49100     pkg_failed=untried
49101 fi
49102 
49103 
49104 
49105 if test $pkg_failed = yes; then
49106 
49107 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
49108         _pkg_short_errors_supported=yes
49109 else
49110         _pkg_short_errors_supported=no
49111 fi
49112         if test $_pkg_short_errors_supported = yes; then
49113                 LCMS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lcms2" 2>&1`
49114         else
49115                 LCMS_PKG_ERRORS=`$PKG_CONFIG --print-errors "lcms2" 2>&1`
49116         fi
49117         # Put the nasty error message in config.log where it belongs
49118         echo "$LCMS_PKG_ERRORS" >&5
49119 
49120         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
49121 $as_echo "no" >&6; }
49122                 LCMS_FOUND=no
49123 elif test $pkg_failed = untried; then
49124         LCMS_FOUND=no
49125 else
49126         LCMS_CFLAGS=$pkg_cv_LCMS_CFLAGS
49127         LCMS_LIBS=$pkg_cv_LCMS_LIBS
49128         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
49129 $as_echo "yes" >&6; }
49130         LCMS_FOUND=yes
49131 fi
49132     if test "x${LCMS_FOUND}" = "xyes"; then
49133       USE_EXTERNAL_LCMS=true
49134     else
49135       as_fn_error $? "--with-lcms=system specified, but no lcms found!" "$LINENO" 5
49136     fi
49137   else
49138     as_fn_error $? "Invalid value for --with-lcms: ${with_lcms}, use 'system' or 'bundled'" "$LINENO" 5
49139   fi
49140 
49141 
49142 
49143   ###############################################################################
49144   #
49145   # Check for the png library
49146   #
49147 
49148 
49149 # Check whether --with-libpng was given.
49150 if test "${with_libpng+set}" = set; then :
49151   withval=$with_libpng;
49152 fi
49153 
49154 
49155 
49156   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libpng to use" >&5
49157 $as_echo_n "checking for which libpng to use... " >&6; }
49158 
49159   # default is bundled
49160   DEFAULT_LIBPNG=bundled
49161 
49162   #
49163   # if user didn't specify, use DEFAULT_LIBPNG
49164   #
49165   if test "x${with_libpng}" = "x"; then
49166       with_libpng=${DEFAULT_LIBPNG}
49167   fi
49168 
49169   if test "x${with_libpng}" = "xbundled"; then
49170       USE_EXTERNAL_LIBPNG=false
49171       { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5
49172 $as_echo "bundled" >&6; }
49173   elif test "x${with_libpng}" = "xsystem"; then
49174 
49175 pkg_failed=no
49176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PNG" >&5
49177 $as_echo_n "checking for PNG... " >&6; }
49178 
49179 if test -n "$PNG_CFLAGS"; then
49180     pkg_cv_PNG_CFLAGS="$PNG_CFLAGS"
49181  elif test -n "$PKG_CONFIG"; then
49182     if test -n "$PKG_CONFIG" && \
49183     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5
49184   ($PKG_CONFIG --exists --print-errors "libpng") 2>&5
49185   ac_status=$?
49186   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
49187   test $ac_status = 0; }; then
49188   pkg_cv_PNG_CFLAGS=`$PKG_CONFIG --cflags "libpng" 2>/dev/null`
49189 else
49190   pkg_failed=yes
49191 fi
49192  else
49193     pkg_failed=untried
49194 fi
49195 if test -n "$PNG_LIBS"; then
49196     pkg_cv_PNG_LIBS="$PNG_LIBS"
49197  elif test -n "$PKG_CONFIG"; then
49198     if test -n "$PKG_CONFIG" && \
49199     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5
49200   ($PKG_CONFIG --exists --print-errors "libpng") 2>&5
49201   ac_status=$?
49202   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
49203   test $ac_status = 0; }; then
49204   pkg_cv_PNG_LIBS=`$PKG_CONFIG --libs "libpng" 2>/dev/null`
49205 else
49206   pkg_failed=yes
49207 fi
49208  else
49209     pkg_failed=untried
49210 fi
49211 
49212 
49213 
49214 if test $pkg_failed = yes; then
49215 
49216 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
49217         _pkg_short_errors_supported=yes
49218 else
49219         _pkg_short_errors_supported=no
49220 fi
49221         if test $_pkg_short_errors_supported = yes; then
49222                 PNG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libpng" 2>&1`
49223         else
49224                 PNG_PKG_ERRORS=`$PKG_CONFIG --print-errors "libpng" 2>&1`
49225         fi
49226         # Put the nasty error message in config.log where it belongs
49227         echo "$PNG_PKG_ERRORS" >&5
49228 
49229         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
49230 $as_echo "no" >&6; }
49231                  LIBPNG_FOUND=no
49232 elif test $pkg_failed = untried; then
49233          LIBPNG_FOUND=no
49234 else
49235         PNG_CFLAGS=$pkg_cv_PNG_CFLAGS
49236         PNG_LIBS=$pkg_cv_PNG_LIBS
49237         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
49238 $as_echo "yes" >&6; }
49239          LIBPNG_FOUND=yes
49240 fi
49241       if test "x${LIBPNG_FOUND}" = "xyes"; then
49242           USE_EXTERNAL_LIBPNG=true
49243           { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5
49244 $as_echo "system" >&6; }
49245       else
49246           { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5
49247 $as_echo "system not found" >&6; }
49248           as_fn_error $? "--with-libpng=system specified, but no libpng found!" "$LINENO" 5
49249       fi
49250   else
49251       as_fn_error $? "Invalid value of --with-libpng: ${with_libpng}, use 'system' or 'bundled'" "$LINENO" 5
49252   fi
49253 
49254 
49255   ###############################################################################
49256   #
49257   # Check for the zlib library
49258   #
49259 
49260 
49261 # Check whether --with-zlib was given.
49262 if test "${with_zlib+set}" = set; then :
49263   withval=$with_zlib;
49264 fi
49265 
49266 
49267   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5
49268 $as_echo_n "checking for compress in -lz... " >&6; }
49269 if ${ac_cv_lib_z_compress+:} false; then :
49270   $as_echo_n "(cached) " >&6
49271 else
49272   ac_check_lib_save_LIBS=$LIBS
49273 LIBS="-lz  $LIBS"
49274 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
49275 /* end confdefs.h.  */
49276 
49277 /* Override any GCC internal prototype to avoid an error.
49278    Use char because int might match the return type of a GCC
49279    builtin and then its argument prototype would still apply.  */
49280 #ifdef __cplusplus
49281 extern "C"
49282 #endif
49283 char compress ();
49284 int
49285 main ()
49286 {
49287 return compress ();
49288   ;
49289   return 0;
49290 }
49291 _ACEOF
49292 if ac_fn_cxx_try_link "$LINENO"; then :
49293   ac_cv_lib_z_compress=yes
49294 else
49295   ac_cv_lib_z_compress=no
49296 fi
49297 rm -f core conftest.err conftest.$ac_objext \
49298     conftest$ac_exeext conftest.$ac_ext
49299 LIBS=$ac_check_lib_save_LIBS
49300 fi
49301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5
49302 $as_echo "$ac_cv_lib_z_compress" >&6; }
49303 if test "x$ac_cv_lib_z_compress" = xyes; then :
49304    ZLIB_FOUND=yes
49305 else
49306    ZLIB_FOUND=no
49307 fi
49308 
49309 
49310   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5
49311 $as_echo_n "checking for which zlib to use... " >&6; }
49312 
49313   DEFAULT_ZLIB=bundled
49314   if test "x$OPENJDK_TARGET_OS" = xmacosx; then
49315     #
49316     # On macosx default is system...on others default is
49317     #
49318     DEFAULT_ZLIB=system
49319   fi
49320 
49321   if test "x${ZLIB_FOUND}" != "xyes"; then
49322     #
49323     # If we don't find any system...set default to bundled
49324     #
49325     DEFAULT_ZLIB=bundled
49326   fi
49327 
49328   #
49329   # If user didn't specify, use DEFAULT_ZLIB
49330   #
49331   if test "x${with_zlib}" = "x"; then
49332     with_zlib=${DEFAULT_ZLIB}
49333   fi
49334 
49335   if test "x${with_zlib}" = "xbundled"; then
49336     USE_EXTERNAL_LIBZ=false
49337     { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5
49338 $as_echo "bundled" >&6; }
49339   elif test "x${with_zlib}" = "xsystem"; then
49340     if test "x${ZLIB_FOUND}" = "xyes"; then
49341       USE_EXTERNAL_LIBZ=true
49342       { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5
49343 $as_echo "system" >&6; }
49344     else
49345       { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5
49346 $as_echo "system not found" >&6; }
49347       as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5
49348     fi
49349   else
49350     as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5
49351   fi
49352 
49353 
49354 
49355   ###############################################################################
49356   LIBZIP_CAN_USE_MMAP=true
49357 
49358 
49359 
49360   ###############################################################################
49361   #
49362   # Check if altzone exists in time.h
49363   #
49364 
49365   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
49366 /* end confdefs.h.  */
49367 #include <time.h>
49368 int
49369 main ()
49370 {
49371 return (int)altzone;
49372   ;
49373   return 0;
49374 }
49375 _ACEOF
49376 if ac_fn_cxx_try_link "$LINENO"; then :
49377   has_altzone=yes
49378 else
49379   has_altzone=no
49380 fi
49381 rm -f core conftest.err conftest.$ac_objext \
49382     conftest$ac_exeext conftest.$ac_ext
49383   if test "x$has_altzone" = xyes; then
49384 
49385 $as_echo "#define HAVE_ALTZONE 1" >>confdefs.h
49386 
49387   fi
49388 
49389   ###############################################################################
49390   #
49391   # Check the maths library
49392   #
49393 
49394   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5
49395 $as_echo_n "checking for cos in -lm... " >&6; }
49396 if ${ac_cv_lib_m_cos+:} false; then :
49397   $as_echo_n "(cached) " >&6
49398 else
49399   ac_check_lib_save_LIBS=$LIBS
49400 LIBS="-lm  $LIBS"
49401 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
49402 /* end confdefs.h.  */
49403 
49404 /* Override any GCC internal prototype to avoid an error.
49405    Use char because int might match the return type of a GCC
49406    builtin and then its argument prototype would still apply.  */
49407 #ifdef __cplusplus
49408 extern "C"
49409 #endif
49410 char cos ();
49411 int
49412 main ()
49413 {
49414 return cos ();
49415   ;
49416   return 0;
49417 }
49418 _ACEOF
49419 if ac_fn_cxx_try_link "$LINENO"; then :
49420   ac_cv_lib_m_cos=yes
49421 else
49422   ac_cv_lib_m_cos=no
49423 fi
49424 rm -f core conftest.err conftest.$ac_objext \
49425     conftest$ac_exeext conftest.$ac_ext
49426 LIBS=$ac_check_lib_save_LIBS
49427 fi
49428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5
49429 $as_echo "$ac_cv_lib_m_cos" >&6; }
49430 if test "x$ac_cv_lib_m_cos" = xyes; then :
49431   cat >>confdefs.h <<_ACEOF
49432 #define HAVE_LIBM 1
49433 _ACEOF
49434 
49435   LIBS="-lm $LIBS"
49436 
49437 else
49438 
49439         { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5
49440 $as_echo "$as_me: Maths library was not found" >&6;}
49441 
49442 
49443 fi
49444 
49445 
49446 
49447   ###############################################################################
49448   #
49449   # Check for libdl.so
49450 
49451   save_LIBS="$LIBS"
49452   LIBS=""
49453   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
49454 $as_echo_n "checking for dlopen in -ldl... " >&6; }
49455 if ${ac_cv_lib_dl_dlopen+:} false; then :
49456   $as_echo_n "(cached) " >&6
49457 else
49458   ac_check_lib_save_LIBS=$LIBS
49459 LIBS="-ldl  $LIBS"
49460 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
49461 /* end confdefs.h.  */
49462 
49463 /* Override any GCC internal prototype to avoid an error.
49464    Use char because int might match the return type of a GCC
49465    builtin and then its argument prototype would still apply.  */
49466 #ifdef __cplusplus
49467 extern "C"
49468 #endif
49469 char dlopen ();
49470 int
49471 main ()
49472 {
49473 return dlopen ();
49474   ;
49475   return 0;
49476 }
49477 _ACEOF
49478 if ac_fn_cxx_try_link "$LINENO"; then :
49479   ac_cv_lib_dl_dlopen=yes
49480 else
49481   ac_cv_lib_dl_dlopen=no
49482 fi
49483 rm -f core conftest.err conftest.$ac_objext \
49484     conftest$ac_exeext conftest.$ac_ext
49485 LIBS=$ac_check_lib_save_LIBS
49486 fi
49487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
49488 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
49489 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
49490   cat >>confdefs.h <<_ACEOF
49491 #define HAVE_LIBDL 1
49492 _ACEOF
49493 
49494   LIBS="-ldl $LIBS"
49495 
49496 fi
49497 
49498   LIBDL="$LIBS"
49499 
49500   LIBS="$save_LIBS"
49501 
49502 
49503   ###############################################################################
49504   #
49505   # statically link libstdc++ before C++ ABI is stablized on Linux unless
49506   # dynamic build is configured on command line.
49507   #
49508 
49509 # Check whether --with-stdc++lib was given.
49510 if test "${with_stdc__lib+set}" = set; then :
49511   withval=$with_stdc__lib;
49512         if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \
49513                 && test "x$with_stdc__lib" != xdefault; then
49514           as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5
49515         fi
49516 
49517 else
49518   with_stdc__lib=default
49519 
49520 fi
49521 
49522 
49523   if test "x$OPENJDK_TARGET_OS" = xlinux; then
49524     # Test if -lstdc++ works.
49525     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dynamic link of stdc++ is possible" >&5
49526 $as_echo_n "checking if dynamic link of stdc++ is possible... " >&6; }
49527     ac_ext=cpp
49528 ac_cpp='$CXXCPP $CPPFLAGS'
49529 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
49530 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
49531 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
49532 
49533     OLD_CXXFLAGS="$CXXFLAGS"
49534     CXXFLAGS="$CXXFLAGS -lstdc++"
49535     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
49536 /* end confdefs.h.  */
49537 
49538 int
49539 main ()
49540 {
49541 return 0;
49542   ;
49543   return 0;
49544 }
49545 _ACEOF
49546 if ac_fn_cxx_try_link "$LINENO"; then :
49547   has_dynamic_libstdcxx=yes
49548 else
49549   has_dynamic_libstdcxx=no
49550 fi
49551 rm -f core conftest.err conftest.$ac_objext \
49552     conftest$ac_exeext conftest.$ac_ext
49553     CXXFLAGS="$OLD_CXXFLAGS"
49554     ac_ext=cpp
49555 ac_cpp='$CXXCPP $CPPFLAGS'
49556 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
49557 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
49558 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
49559 
49560     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_dynamic_libstdcxx" >&5
49561 $as_echo "$has_dynamic_libstdcxx" >&6; }
49562 
49563     # Test if stdc++ can be linked statically.
49564     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5
49565 $as_echo_n "checking if static link of stdc++ is possible... " >&6; }
49566     STATIC_STDCXX_FLAGS="-Wl,-Bstatic -lstdc++ -lgcc -Wl,-Bdynamic"
49567     ac_ext=cpp
49568 ac_cpp='$CXXCPP $CPPFLAGS'
49569 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
49570 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
49571 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
49572 
49573     OLD_LIBS="$LIBS"
49574     OLD_CXX="$CXX"
49575     LIBS="$STATIC_STDCXX_FLAGS"
49576     CXX="$CC"
49577     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
49578 /* end confdefs.h.  */
49579 
49580 int
49581 main ()
49582 {
49583 return 0;
49584   ;
49585   return 0;
49586 }
49587 _ACEOF
49588 if ac_fn_cxx_try_link "$LINENO"; then :
49589   has_static_libstdcxx=yes
49590 else
49591   has_static_libstdcxx=no
49592 fi
49593 rm -f core conftest.err conftest.$ac_objext \
49594     conftest$ac_exeext conftest.$ac_ext
49595     LIBS="$OLD_LIBS"
49596     CXX="$OLD_CXX"
49597     ac_ext=cpp
49598 ac_cpp='$CXXCPP $CPPFLAGS'
49599 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
49600 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
49601 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
49602 
49603     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5
49604 $as_echo "$has_static_libstdcxx" >&6; }
49605 
49606     if test "x$has_static_libstdcxx" = xno && test "x$has_dynamic_libstdcxx" = xno; then
49607       as_fn_error $? "Cannot link to stdc++, neither dynamically nor statically!" "$LINENO" 5
49608     fi
49609 
49610     if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then
49611       as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5
49612     fi
49613 
49614     if test "x$with_stdc__lib" = xdynamic && test "x$has_dynamic_libstdcxx" = xno; then
49615       as_fn_error $? "Dynamic linking of libstdc++ was not possible!" "$LINENO" 5
49616     fi
49617 
49618     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5
49619 $as_echo_n "checking how to link with libstdc++... " >&6; }
49620     # If dynamic was requested, it's available since it would fail above otherwise.
49621     # If dynamic wasn't requested, go with static unless it isn't available.
49622     if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
49623       LIBCXX="$LIBCXX -lstdc++"
49624       LDCXX="$CXX"
49625       STATIC_CXX_SETTING="STATIC_CXX=false"
49626       { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5
49627 $as_echo "dynamic" >&6; }
49628     else
49629       LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS"
49630       LDCXX="$CC"
49631       STATIC_CXX_SETTING="STATIC_CXX=true"
49632       { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5
49633 $as_echo "static" >&6; }
49634     fi
49635   fi
49636 
49637 
49638   if test "x$JVM_VARIANT_ZERO" = xtrue || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
49639     # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS
49640 
49641 pkg_failed=no
49642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5
49643 $as_echo_n "checking for LIBFFI... " >&6; }
49644 
49645 if test -n "$LIBFFI_CFLAGS"; then
49646     pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS"
49647  elif test -n "$PKG_CONFIG"; then
49648     if test -n "$PKG_CONFIG" && \
49649     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5
49650   ($PKG_CONFIG --exists --print-errors "libffi") 2>&5
49651   ac_status=$?
49652   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
49653   test $ac_status = 0; }; then
49654   pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null`
49655 else
49656   pkg_failed=yes
49657 fi
49658  else
49659     pkg_failed=untried
49660 fi
49661 if test -n "$LIBFFI_LIBS"; then
49662     pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS"
49663  elif test -n "$PKG_CONFIG"; then
49664     if test -n "$PKG_CONFIG" && \
49665     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5
49666   ($PKG_CONFIG --exists --print-errors "libffi") 2>&5
49667   ac_status=$?
49668   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
49669   test $ac_status = 0; }; then
49670   pkg_cv_LIBFFI_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null`
49671 else
49672   pkg_failed=yes
49673 fi
49674  else
49675     pkg_failed=untried
49676 fi
49677 
49678 
49679 
49680 if test $pkg_failed = yes; then
49681 
49682 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
49683         _pkg_short_errors_supported=yes
49684 else
49685         _pkg_short_errors_supported=no
49686 fi
49687         if test $_pkg_short_errors_supported = yes; then
49688                 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1`
49689         else
49690                 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1`
49691         fi
49692         # Put the nasty error message in config.log where it belongs
49693         echo "$LIBFFI_PKG_ERRORS" >&5
49694 
49695         as_fn_error $? "Package requirements (libffi) were not met:
49696 
49697 $LIBFFI_PKG_ERRORS
49698 
49699 Consider adjusting the PKG_CONFIG_PATH environment variable if you
49700 installed software in a non-standard prefix.
49701 
49702 Alternatively, you may set the environment variables LIBFFI_CFLAGS
49703 and LIBFFI_LIBS to avoid the need to call pkg-config.
49704 See the pkg-config man page for more details.
49705 " "$LINENO" 5
49706 elif test $pkg_failed = untried; then
49707         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
49708 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
49709 as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
49710 is in your PATH or set the PKG_CONFIG environment variable to the full
49711 path to pkg-config.
49712 
49713 Alternatively, you may set the environment variables LIBFFI_CFLAGS
49714 and LIBFFI_LIBS to avoid the need to call pkg-config.
49715 See the pkg-config man page for more details.
49716 
49717 To get pkg-config, see <http://pkg-config.freedesktop.org/>.
49718 See \`config.log' for more details" "$LINENO" 5; }
49719 else
49720         LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS
49721         LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS
49722         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
49723 $as_echo "yes" >&6; }
49724         :
49725 fi
49726 
49727   fi
49728 
49729   if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then
49730     # Extract the first word of "llvm-config", so it can be a program name with args.
49731 set dummy llvm-config; ac_word=$2
49732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
49733 $as_echo_n "checking for $ac_word... " >&6; }
49734 if ${ac_cv_prog_LLVM_CONFIG+:} false; then :
49735   $as_echo_n "(cached) " >&6
49736 else
49737   if test -n "$LLVM_CONFIG"; then
49738   ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test.
49739 else
49740 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
49741 for as_dir in $PATH
49742 do
49743   IFS=$as_save_IFS
49744   test -z "$as_dir" && as_dir=.
49745     for ac_exec_ext in '' $ac_executable_extensions; do
49746   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
49747     ac_cv_prog_LLVM_CONFIG="llvm-config"
49748     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
49749     break 2
49750   fi
49751 done
49752   done
49753 IFS=$as_save_IFS
49754 
49755 fi
49756 fi
49757 LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG
49758 if test -n "$LLVM_CONFIG"; then
49759   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5
49760 $as_echo "$LLVM_CONFIG" >&6; }
49761 else
49762   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
49763 $as_echo "no" >&6; }
49764 fi
49765 
49766 
49767 
49768     if test "x$LLVM_CONFIG" != xllvm-config; then
49769       as_fn_error $? "llvm-config not found in $PATH." "$LINENO" 5
49770     fi
49771 
49772     llvm_components="jit mcjit engine nativecodegen native"
49773     unset LLVM_CFLAGS
49774     for flag in $("$LLVM_CONFIG" --cxxflags); do
49775       if echo "${flag}" | grep -q '^-[ID]'; then
49776         if test "${flag}" != "-D_DEBUG" ; then
49777           if test "${LLVM_CFLAGS}" != "" ; then
49778             LLVM_CFLAGS="${LLVM_CFLAGS} "
49779           fi
49780           LLVM_CFLAGS="${LLVM_CFLAGS}${flag}"
49781         fi
49782       fi
49783     done
49784     llvm_version=$("${LLVM_CONFIG}" --version | sed 's/\.//; s/svn.*//')
49785     LLVM_CFLAGS="${LLVM_CFLAGS} -DSHARK_LLVM_VERSION=${llvm_version}"
49786 
49787     unset LLVM_LDFLAGS
49788     for flag in $("${LLVM_CONFIG}" --ldflags); do
49789       if echo "${flag}" | grep -q '^-L'; then
49790         if test "${LLVM_LDFLAGS}" != ""; then
49791           LLVM_LDFLAGS="${LLVM_LDFLAGS} "
49792         fi
49793         LLVM_LDFLAGS="${LLVM_LDFLAGS}${flag}"
49794       fi
49795     done
49796 
49797     unset LLVM_LIBS
49798     for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do
49799       if echo "${flag}" | grep -q '^-l'; then
49800         if test "${LLVM_LIBS}" != ""; then
49801           LLVM_LIBS="${LLVM_LIBS} "
49802         fi
49803         LLVM_LIBS="${LLVM_LIBS}${flag}"
49804       fi
49805     done
49806 
49807 
49808 
49809 
49810   fi
49811 
49812   # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so)
49813   if test "x$TOOLCHAIN_TYPE" = xsolstudio && test "x$LIBCXX" = x; then
49814     LIBCXX="${SYSROOT}/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1"
49815   fi
49816 
49817   # TODO better (platform agnostic) test
49818   if test "x$OPENJDK_TARGET_OS" = xmacosx && test "x$LIBCXX" = x && test "x$TOOLCHAIN_TYPE" = xgcc; then
49819     LIBCXX="-lstdc++"
49820   fi
49821 
49822 
49823 
49824 
49825   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
49826 
49827 
49828 # Check whether --with-msvcr-dll was given.
49829 if test "${with_msvcr_dll+set}" = set; then :
49830   withval=$with_msvcr_dll;
49831 fi
49832 
49833 
49834   if test "x$with_msvcr_dll" != x; then
49835     # If given explicitely by user, do not probe. If not present, fail directly.
49836 
49837   POSSIBLE_MSVCR_DLL="$with_msvcr_dll"
49838   METHOD="--with-msvcr-dll"
49839   if test -e "$POSSIBLE_MSVCR_DLL"; then
49840     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
49841 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
49842 
49843     # Need to check if the found msvcr is correct architecture
49844     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
49845 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
49846     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
49847     if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
49848       # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit"
49849       # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems.
49850       if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
49851         CORRECT_MSVCR_ARCH="PE32 executable"
49852       else
49853         CORRECT_MSVCR_ARCH="PE32+ executable"
49854       fi
49855     else
49856       if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
49857         CORRECT_MSVCR_ARCH=386
49858       else
49859         CORRECT_MSVCR_ARCH=x86-64
49860       fi
49861     fi
49862     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then
49863       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
49864 $as_echo "ok" >&6; }
49865       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
49866       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
49867 $as_echo_n "checking for msvcr100.dll... " >&6; }
49868       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
49869 $as_echo "$MSVCR_DLL" >&6; }
49870     else
49871       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
49872 $as_echo "incorrect, ignoring" >&6; }
49873       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
49874 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
49875     fi
49876   fi
49877 
49878     if test "x$MSVCR_DLL" = x; then
49879       as_fn_error $? "Could not find a proper msvcr100.dll as specified by --with-msvcr-dll" "$LINENO" 5
49880     fi
49881   fi
49882 
49883   if test "x$MSVCR_DLL" = x; then
49884     # Probe: Using well-known location from Visual Studio 10.0
49885     if test "x$VCINSTALLDIR" != x; then
49886       CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR"
49887 
49888   windows_path="$CYGWIN_VC_INSTALL_DIR"
49889   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
49890     unix_path=`$CYGPATH -u "$windows_path"`
49891     CYGWIN_VC_INSTALL_DIR="$unix_path"
49892   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
49893     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
49894     CYGWIN_VC_INSTALL_DIR="$unix_path"
49895   fi
49896 
49897       if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
49898         POSSIBLE_MSVCR_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC100.CRT/msvcr100.dll"
49899       else
49900         POSSIBLE_MSVCR_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC100.CRT/msvcr100.dll"
49901       fi
49902 
49903   POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
49904   METHOD="well-known location in VCINSTALLDIR"
49905   if test -e "$POSSIBLE_MSVCR_DLL"; then
49906     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
49907 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
49908 
49909     # Need to check if the found msvcr is correct architecture
49910     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
49911 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
49912     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
49913     if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
49914       # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit"
49915       # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems.
49916       if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
49917         CORRECT_MSVCR_ARCH="PE32 executable"
49918       else
49919         CORRECT_MSVCR_ARCH="PE32+ executable"
49920       fi
49921     else
49922       if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
49923         CORRECT_MSVCR_ARCH=386
49924       else
49925         CORRECT_MSVCR_ARCH=x86-64
49926       fi
49927     fi
49928     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then
49929       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
49930 $as_echo "ok" >&6; }
49931       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
49932       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
49933 $as_echo_n "checking for msvcr100.dll... " >&6; }
49934       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
49935 $as_echo "$MSVCR_DLL" >&6; }
49936     else
49937       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
49938 $as_echo "incorrect, ignoring" >&6; }
49939       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
49940 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
49941     fi
49942   fi
49943 
49944     fi
49945   fi
49946 
49947   if test "x$MSVCR_DLL" = x; then
49948     # Probe: Check in the Boot JDK directory.
49949     POSSIBLE_MSVCR_DLL="$BOOT_JDK/bin/msvcr100.dll"
49950 
49951   POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
49952   METHOD="well-known location in Boot JDK"
49953   if test -e "$POSSIBLE_MSVCR_DLL"; then
49954     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
49955 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
49956 
49957     # Need to check if the found msvcr is correct architecture
49958     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
49959 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
49960     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
49961     if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
49962       # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit"
49963       # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems.
49964       if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
49965         CORRECT_MSVCR_ARCH="PE32 executable"
49966       else
49967         CORRECT_MSVCR_ARCH="PE32+ executable"
49968       fi
49969     else
49970       if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
49971         CORRECT_MSVCR_ARCH=386
49972       else
49973         CORRECT_MSVCR_ARCH=x86-64
49974       fi
49975     fi
49976     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then
49977       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
49978 $as_echo "ok" >&6; }
49979       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
49980       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
49981 $as_echo_n "checking for msvcr100.dll... " >&6; }
49982       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
49983 $as_echo "$MSVCR_DLL" >&6; }
49984     else
49985       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
49986 $as_echo "incorrect, ignoring" >&6; }
49987       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
49988 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
49989     fi
49990   fi
49991 
49992   fi
49993 
49994   if test "x$MSVCR_DLL" = x; then
49995     # Probe: Look in the Windows system32 directory
49996     CYGWIN_SYSTEMROOT="$SYSTEMROOT"
49997 
49998   windows_path="$CYGWIN_SYSTEMROOT"
49999   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
50000     unix_path=`$CYGPATH -u "$windows_path"`
50001     CYGWIN_SYSTEMROOT="$unix_path"
50002   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
50003     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
50004     CYGWIN_SYSTEMROOT="$unix_path"
50005   fi
50006 
50007     POSSIBLE_MSVCR_DLL="$CYGWIN_SYSTEMROOT/system32/msvcr100.dll"
50008 
50009   POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
50010   METHOD="well-known location in SYSTEMROOT"
50011   if test -e "$POSSIBLE_MSVCR_DLL"; then
50012     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
50013 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
50014 
50015     # Need to check if the found msvcr is correct architecture
50016     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
50017 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
50018     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
50019     if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
50020       # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit"
50021       # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems.
50022       if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
50023         CORRECT_MSVCR_ARCH="PE32 executable"
50024       else
50025         CORRECT_MSVCR_ARCH="PE32+ executable"
50026       fi
50027     else
50028       if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
50029         CORRECT_MSVCR_ARCH=386
50030       else
50031         CORRECT_MSVCR_ARCH=x86-64
50032       fi
50033     fi
50034     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then
50035       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
50036 $as_echo "ok" >&6; }
50037       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
50038       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
50039 $as_echo_n "checking for msvcr100.dll... " >&6; }
50040       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
50041 $as_echo "$MSVCR_DLL" >&6; }
50042     else
50043       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
50044 $as_echo "incorrect, ignoring" >&6; }
50045       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
50046 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
50047     fi
50048   fi
50049 
50050   fi
50051 
50052   if test "x$MSVCR_DLL" = x; then
50053     # Probe: If Visual Studio Express is installed, there is usually one with the debugger
50054     if test "x$VS100COMNTOOLS" != x; then
50055       CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.."
50056 
50057   windows_path="$CYGWIN_VS_TOOLS_DIR"
50058   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
50059     unix_path=`$CYGPATH -u "$windows_path"`
50060     CYGWIN_VS_TOOLS_DIR="$unix_path"
50061   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
50062     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
50063     CYGWIN_VS_TOOLS_DIR="$unix_path"
50064   fi
50065 
50066       if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
50067         POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name msvcr100.dll | $GREP -i /x64/ | $HEAD --lines 1`
50068       else
50069         POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name msvcr100.dll | $GREP -i /x86/ | $HEAD --lines 1`
50070       fi
50071 
50072   POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
50073   METHOD="search of VS100COMNTOOLS"
50074   if test -e "$POSSIBLE_MSVCR_DLL"; then
50075     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
50076 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
50077 
50078     # Need to check if the found msvcr is correct architecture
50079     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
50080 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
50081     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
50082     if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
50083       # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit"
50084       # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems.
50085       if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
50086         CORRECT_MSVCR_ARCH="PE32 executable"
50087       else
50088         CORRECT_MSVCR_ARCH="PE32+ executable"
50089       fi
50090     else
50091       if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
50092         CORRECT_MSVCR_ARCH=386
50093       else
50094         CORRECT_MSVCR_ARCH=x86-64
50095       fi
50096     fi
50097     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then
50098       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
50099 $as_echo "ok" >&6; }
50100       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
50101       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
50102 $as_echo_n "checking for msvcr100.dll... " >&6; }
50103       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
50104 $as_echo "$MSVCR_DLL" >&6; }
50105     else
50106       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
50107 $as_echo "incorrect, ignoring" >&6; }
50108       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
50109 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
50110     fi
50111   fi
50112 
50113     fi
50114   fi
50115 
50116   if test "x$MSVCR_DLL" = x; then
50117     # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now.
50118     # (This was the original behaviour; kept since it might turn up something)
50119     if test "x$CYGWIN_VC_INSTALL_DIR" != x; then
50120       if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
50121         POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $GREP x64 | $HEAD --lines 1`
50122       else
50123         POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1`
50124         if test "x$POSSIBLE_MSVCR_DLL" = x; then
50125           # We're grasping at straws now...
50126           POSSIBLE_MSVCR_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name msvcr100.dll | $HEAD --lines 1`
50127         fi
50128       fi
50129 
50130 
50131   POSSIBLE_MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
50132   METHOD="search of VCINSTALLDIR"
50133   if test -e "$POSSIBLE_MSVCR_DLL"; then
50134     { $as_echo "$as_me:${as_lineno-$LINENO}: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&5
50135 $as_echo "$as_me: Found msvcr100.dll at $POSSIBLE_MSVCR_DLL using $METHOD" >&6;}
50136 
50137     # Need to check if the found msvcr is correct architecture
50138     { $as_echo "$as_me:${as_lineno-$LINENO}: checking found msvcr100.dll architecture" >&5
50139 $as_echo_n "checking found msvcr100.dll architecture... " >&6; }
50140     MSVCR_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVCR_DLL"`
50141     if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
50142       # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit"
50143       # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems.
50144       if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
50145         CORRECT_MSVCR_ARCH="PE32 executable"
50146       else
50147         CORRECT_MSVCR_ARCH="PE32+ executable"
50148       fi
50149     else
50150       if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then
50151         CORRECT_MSVCR_ARCH=386
50152       else
50153         CORRECT_MSVCR_ARCH=x86-64
50154       fi
50155     fi
50156     if $ECHO "$MSVCR_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then
50157       { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
50158 $as_echo "ok" >&6; }
50159       MSVCR_DLL="$POSSIBLE_MSVCR_DLL"
50160       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
50161 $as_echo_n "checking for msvcr100.dll... " >&6; }
50162       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVCR_DLL" >&5
50163 $as_echo "$MSVCR_DLL" >&6; }
50164     else
50165       { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5
50166 $as_echo "incorrect, ignoring" >&6; }
50167       { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&5
50168 $as_echo "$as_me: The file type of the located msvcr100.dll is $MSVCR_DLL_FILETYPE" >&6;}
50169     fi
50170   fi
50171 
50172     fi
50173   fi
50174 
50175   if test "x$MSVCR_DLL" = x; then
50176     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msvcr100.dll" >&5
50177 $as_echo_n "checking for msvcr100.dll... " >&6; }
50178     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
50179 $as_echo "no" >&6; }
50180     as_fn_error $? "Could not find msvcr100.dll. Please specify using --with-msvcr-dll." "$LINENO" 5
50181   fi
50182 
50183 
50184   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
50185 
50186   # Input might be given as Windows format, start by converting to
50187   # unix format.
50188   path="$MSVCR_DLL"
50189   new_path=`$CYGPATH -u "$path"`
50190 
50191   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
50192   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
50193   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
50194   # "foo.exe" is OK but "foo" is an error.
50195   #
50196   # This test is therefore slightly more accurate than "test -f" to check for file precense.
50197   # It is also a way to make sure we got the proper file name for the real test later on.
50198   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
50199   if test "x$test_shortpath" = x; then
50200     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&5
50201 $as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&6;}
50202     as_fn_error $? "Cannot locate the the path of MSVCR_DLL" "$LINENO" 5
50203   fi
50204 
50205   # Call helper function which possibly converts this using DOS-style short mode.
50206   # If so, the updated path is stored in $new_path.
50207 
50208   input_path="$new_path"
50209   # Check if we need to convert this using DOS-style short mode. If the path
50210   # contains just simple characters, use it. Otherwise (spaces, weird characters),
50211   # take no chances and rewrite it.
50212   # Note: m4 eats our [], so we need to use [ and ] instead.
50213   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
50214   if test "x$has_forbidden_chars" != x; then
50215     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
50216     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
50217     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
50218     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
50219       # Going to short mode and back again did indeed matter. Since short mode is
50220       # case insensitive, let's make it lowercase to improve readability.
50221       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
50222       # Now convert it back to Unix-stile (cygpath)
50223       input_path=`$CYGPATH -u "$shortmode_path"`
50224       new_path="$input_path"
50225     fi
50226   fi
50227 
50228   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
50229   if test "x$test_cygdrive_prefix" = x; then
50230     # As a simple fix, exclude /usr/bin since it's not a real path.
50231     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
50232       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
50233       # a path prefixed by /cygdrive for fixpath to work.
50234       new_path="$CYGWIN_ROOT_PATH$input_path"
50235     fi
50236   fi
50237 
50238 
50239   if test "x$path" != "x$new_path"; then
50240     MSVCR_DLL="$new_path"
50241     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVCR_DLL to \"$new_path\"" >&5
50242 $as_echo "$as_me: Rewriting MSVCR_DLL to \"$new_path\"" >&6;}
50243   fi
50244 
50245   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
50246 
50247   path="$MSVCR_DLL"
50248   has_colon=`$ECHO $path | $GREP ^.:`
50249   new_path="$path"
50250   if test "x$has_colon" = x; then
50251     # Not in mixed or Windows style, start by that.
50252     new_path=`cmd //c echo $path`
50253   fi
50254 
50255 
50256   input_path="$new_path"
50257   # Check if we need to convert this using DOS-style short mode. If the path
50258   # contains just simple characters, use it. Otherwise (spaces, weird characters),
50259   # take no chances and rewrite it.
50260   # Note: m4 eats our [], so we need to use [ and ] instead.
50261   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
50262   if test "x$has_forbidden_chars" != x; then
50263     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
50264     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
50265   fi
50266 
50267 
50268   windows_path="$new_path"
50269   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
50270     unix_path=`$CYGPATH -u "$windows_path"`
50271     new_path="$unix_path"
50272   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
50273     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
50274     new_path="$unix_path"
50275   fi
50276 
50277   if test "x$path" != "x$new_path"; then
50278     MSVCR_DLL="$new_path"
50279     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVCR_DLL to \"$new_path\"" >&5
50280 $as_echo "$as_me: Rewriting MSVCR_DLL to \"$new_path\"" >&6;}
50281   fi
50282 
50283   # Save the first 10 bytes of this path to the storage, so fixpath can work.
50284   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
50285 
50286   else
50287     # We're on a unix platform. Hooray! :)
50288     path="$MSVCR_DLL"
50289     has_space=`$ECHO "$path" | $GREP " "`
50290     if test "x$has_space" != x; then
50291       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&5
50292 $as_echo "$as_me: The path of MSVCR_DLL, which resolves as \"$path\", is invalid." >&6;}
50293       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
50294     fi
50295 
50296     # Use eval to expand a potential ~
50297     eval path="$path"
50298     if test ! -f "$path" && test ! -d "$path"; then
50299       as_fn_error $? "The path of MSVCR_DLL, which resolves as \"$path\", is not found." "$LINENO" 5
50300     fi
50301 
50302     MSVCR_DLL="`cd "$path"; $THEPWDCMD -L`"
50303   fi
50304 
50305 
50306 
50307 
50308 # Check whether --with-dxsdk was given.
50309 if test "${with_dxsdk+set}" = set; then :
50310   withval=$with_dxsdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&5
50311 $as_echo "$as_me: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&2;}
50312 fi
50313 
50314 
50315 
50316 
50317 # Check whether --with-dxsdk-lib was given.
50318 if test "${with_dxsdk_lib+set}" = set; then :
50319   withval=$with_dxsdk_lib; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&5
50320 $as_echo "$as_me: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&2;}
50321 fi
50322 
50323 
50324 
50325 
50326 # Check whether --with-dxsdk-include was given.
50327 if test "${with_dxsdk_include+set}" = set; then :
50328   withval=$with_dxsdk_include; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&5
50329 $as_echo "$as_me: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&2;}
50330 fi
50331 
50332 
50333   fi
50334 
50335 
50336 
50337 ###############################################################################
50338 #
50339 # We need to do some final tweaking, when everything else is done.
50340 #
50341 ###############################################################################
50342 
50343 
50344   HOTSPOT_MAKE_ARGS="$HOTSPOT_TARGET"
50345 
50346 
50347   # The name of the Service Agent jar.
50348   SALIB_NAME="${LIBRARY_PREFIX}saproc${SHARED_LIBRARY_SUFFIX}"
50349   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
50350     SALIB_NAME="${LIBRARY_PREFIX}sawindbg${SHARED_LIBRARY_SUFFIX}"
50351   fi
50352 
50353 
50354 
50355     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5
50356 $as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; }
50357 
50358     if test -d "${SRC_ROOT}/jdk/src/jdk.crypto.ec/share/native/libsunec/impl"; then
50359       ENABLE_INTREE_EC=yes
50360       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
50361 $as_echo "yes" >&6; }
50362     else
50363       ENABLE_INTREE_EC=no
50364       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
50365 $as_echo "no" >&6; }
50366     fi
50367 
50368 
50369 
50370 
50371 ###############################################################################
50372 #
50373 # Configure parts of the build that only affect the build performance,
50374 # not the result.
50375 #
50376 ###############################################################################
50377 
50378 
50379   # How many cores do we have on this build system?
50380 
50381 # Check whether --with-num-cores was given.
50382 if test "${with_num_cores+set}" = set; then :
50383   withval=$with_num_cores;
50384 fi
50385 
50386   if test "x$with_num_cores" = x; then
50387     # The number of cores were not specified, try to probe them.
50388 
50389   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5
50390 $as_echo_n "checking for number of cores... " >&6; }
50391   NUM_CORES=1
50392   FOUND_CORES=no
50393 
50394   if test -f /proc/cpuinfo; then
50395     # Looks like a Linux (or cygwin) system
50396     NUM_CORES=`cat /proc/cpuinfo  | grep -c processor`
50397     FOUND_CORES=yes
50398   elif test -x /usr/sbin/psrinfo; then
50399     # Looks like a Solaris system
50400     NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line`
50401     FOUND_CORES=yes
50402   elif test -x /usr/sbin/system_profiler; then
50403     # Looks like a MacOSX system
50404     NUM_CORES=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Cores' | awk  '{print $5}'`
50405     FOUND_CORES=yes
50406   elif test "x$OPENJDK_BUILD_OS" = xaix ; then
50407     NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print $4 }'`
50408     FOUND_CORES=yes
50409   elif test -n "$NUMBER_OF_PROCESSORS"; then
50410     # On windows, look in the env
50411     NUM_CORES=$NUMBER_OF_PROCESSORS
50412     FOUND_CORES=yes
50413   fi
50414 
50415   if test "x$FOUND_CORES" = xyes; then
50416     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5
50417 $as_echo "$NUM_CORES" >&6; }
50418   else
50419     { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5
50420 $as_echo "could not detect number of cores, defaulting to 1" >&6; }
50421     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5
50422 $as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;}
50423   fi
50424 
50425   else
50426     NUM_CORES=$with_num_cores
50427   fi
50428 
50429 
50430 
50431   # How much memory do we have on this build system?
50432 
50433 # Check whether --with-memory-size was given.
50434 if test "${with_memory_size+set}" = set; then :
50435   withval=$with_memory_size;
50436 fi
50437 
50438   if test "x$with_memory_size" = x; then
50439     # The memory size was not specified, try to probe it.
50440 
50441   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5
50442 $as_echo_n "checking for memory size... " >&6; }
50443   # Default to 1024 MB
50444   MEMORY_SIZE=1024
50445   FOUND_MEM=no
50446 
50447   if test -f /proc/meminfo; then
50448     # Looks like a Linux (or cygwin) system
50449     MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'`
50450     MEMORY_SIZE=`expr $MEMORY_SIZE / 1024`
50451     FOUND_MEM=yes
50452   elif test -x /usr/sbin/prtconf; then
50453     # Looks like a Solaris or AIX system
50454     MEMORY_SIZE=`/usr/sbin/prtconf | grep "^Memory [Ss]ize" | awk '{ print $3 }'`
50455     FOUND_MEM=yes
50456   elif test -x /usr/sbin/system_profiler; then
50457     # Looks like a MacOSX system
50458     MEMORY_SIZE=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Memory' | awk  '{print $2}'`
50459     MEMORY_SIZE=`expr $MEMORY_SIZE \* 1024`
50460     FOUND_MEM=yes
50461   elif test "x$OPENJDK_BUILD_OS" = xwindows; then
50462     # Windows, but without cygwin
50463     MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-`
50464     MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024`
50465     FOUND_MEM=yes
50466   fi
50467 
50468   if test "x$FOUND_MEM" = xyes; then
50469     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5
50470 $as_echo "$MEMORY_SIZE MB" >&6; }
50471   else
50472     { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to $MEMORY_SIZE MB" >&5
50473 $as_echo "could not detect memory size, defaulting to $MEMORY_SIZE MB" >&6; }
50474     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5
50475 $as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;}
50476   fi
50477 
50478   else
50479     MEMORY_SIZE=$with_memory_size
50480   fi
50481 
50482 
50483 
50484   # Provide a decent default number of parallel jobs for make depending on
50485   # number of cores, amount of memory and machine architecture.
50486 
50487 # Check whether --with-jobs was given.
50488 if test "${with_jobs+set}" = set; then :
50489   withval=$with_jobs;
50490 fi
50491 
50492   if test "x$with_jobs" = x; then
50493     # Number of jobs was not specified, calculate.
50494     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5
50495 $as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; }
50496     # Approximate memory in GB.
50497     memory_gb=`expr $MEMORY_SIZE / 1024`
50498     # Pick the lowest of memory in gb and number of cores.
50499     if test "$memory_gb" -lt "$NUM_CORES"; then
50500       JOBS="$memory_gb"
50501     else
50502       JOBS="$NUM_CORES"
50503       # On bigger machines, leave some room for other processes to run
50504       if test "$JOBS" -gt "4"; then
50505         JOBS=`expr $JOBS '*' 90 / 100`
50506       fi
50507     fi
50508     # Cap number of jobs to 16
50509     if test "$JOBS" -gt "16"; then
50510       JOBS=16
50511     fi
50512     if test "$JOBS" -eq "0"; then
50513       JOBS=1
50514     fi
50515     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5
50516 $as_echo "$JOBS" >&6; }
50517   else
50518     JOBS=$with_jobs
50519   fi
50520 
50521 
50522 
50523 # Setup arguments for the boot jdk (after cores and memory have been setup)
50524 
50525   ##############################################################################
50526   #
50527   # Specify jvm options for anything that is run with the Boot JDK.
50528   # Not all JVM:s accept the same arguments on the command line.
50529   #
50530 
50531 # Check whether --with-boot-jdk-jvmargs was given.
50532 if test "${with_boot_jdk_jvmargs+set}" = set; then :
50533   withval=$with_boot_jdk_jvmargs;
50534 fi
50535 
50536 
50537   { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command " >&5
50538 $as_echo_n "checking flags for boot jdk java command ... " >&6; }
50539 
50540   # Disable special log output when a debug build is used as Boot JDK...
50541 
50542   $ECHO "Check if jvm arg is ok: -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" >&5
50543   $ECHO "Command: $JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version" >&5
50544   OUTPUT=`$JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version 2>&1`
50545   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
50546   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
50547   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
50548     boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput"
50549     JVM_ARG_OK=true
50550   else
50551     $ECHO "Arg failed:" >&5
50552     $ECHO "$OUTPUT" >&5
50553     JVM_ARG_OK=false
50554   fi
50555 
50556 
50557   # Apply user provided options.
50558 
50559   $ECHO "Check if jvm arg is ok: $with_boot_jdk_jvmargs" >&5
50560   $ECHO "Command: $JAVA $with_boot_jdk_jvmargs -version" >&5
50561   OUTPUT=`$JAVA $with_boot_jdk_jvmargs -version 2>&1`
50562   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
50563   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
50564   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
50565     boot_jdk_jvmargs="$boot_jdk_jvmargs $with_boot_jdk_jvmargs"
50566     JVM_ARG_OK=true
50567   else
50568     $ECHO "Arg failed:" >&5
50569     $ECHO "$OUTPUT" >&5
50570     JVM_ARG_OK=false
50571   fi
50572 
50573 
50574   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs" >&5
50575 $as_echo "$boot_jdk_jvmargs" >&6; }
50576 
50577   # For now, general JAVA_FLAGS are the same as the boot jdk jvmargs
50578   JAVA_FLAGS=$boot_jdk_jvmargs
50579 
50580 
50581 
50582   { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for big workloads" >&5
50583 $as_echo_n "checking flags for boot jdk java command for big workloads... " >&6; }
50584 
50585   # Starting amount of heap memory.
50586 
50587   $ECHO "Check if jvm arg is ok: -Xms64M" >&5
50588   $ECHO "Command: $JAVA -Xms64M -version" >&5
50589   OUTPUT=`$JAVA -Xms64M -version 2>&1`
50590   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
50591   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
50592   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
50593     boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xms64M"
50594     JVM_ARG_OK=true
50595   else
50596     $ECHO "Arg failed:" >&5
50597     $ECHO "$OUTPUT" >&5
50598     JVM_ARG_OK=false
50599   fi
50600 
50601 
50602   # Maximum amount of heap memory.
50603   # Maximum stack size.
50604   JVM_MAX_HEAP=`expr $MEMORY_SIZE / 2`
50605   if test "x$BUILD_NUM_BITS" = x32; then
50606     if test "$JVM_MAX_HEAP" -gt "1100"; then
50607       JVM_MAX_HEAP=1100
50608     elif test "$JVM_MAX_HEAP" -lt "512"; then
50609       JVM_MAX_HEAP=512
50610     fi
50611     STACK_SIZE=768
50612   else
50613     # Running Javac on a JVM on a 64-bit machine, takes more space since 64-bit
50614     # pointers are used. Apparently, we need to increase the heap and stack
50615     # space for the jvm. More specifically, when running javac to build huge
50616     # jdk batch
50617     if test "$JVM_MAX_HEAP" -gt "1600"; then
50618       JVM_MAX_HEAP=1600
50619     elif test "$JVM_MAX_HEAP" -lt "512"; then
50620       JVM_MAX_HEAP=512
50621     fi
50622     STACK_SIZE=1536
50623   fi
50624 
50625   $ECHO "Check if jvm arg is ok: -Xmx${JVM_MAX_HEAP}M" >&5
50626   $ECHO "Command: $JAVA -Xmx${JVM_MAX_HEAP}M -version" >&5
50627   OUTPUT=`$JAVA -Xmx${JVM_MAX_HEAP}M -version 2>&1`
50628   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
50629   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
50630   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
50631     boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xmx${JVM_MAX_HEAP}M"
50632     JVM_ARG_OK=true
50633   else
50634     $ECHO "Arg failed:" >&5
50635     $ECHO "$OUTPUT" >&5
50636     JVM_ARG_OK=false
50637   fi
50638 
50639 
50640   $ECHO "Check if jvm arg is ok: -XX:ThreadStackSize=$STACK_SIZE" >&5
50641   $ECHO "Command: $JAVA -XX:ThreadStackSize=$STACK_SIZE -version" >&5
50642   OUTPUT=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1`
50643   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
50644   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
50645   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
50646     boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -XX:ThreadStackSize=$STACK_SIZE"
50647     JVM_ARG_OK=true
50648   else
50649     $ECHO "Arg failed:" >&5
50650     $ECHO "$OUTPUT" >&5
50651     JVM_ARG_OK=false
50652   fi
50653 
50654 
50655   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_big" >&5
50656 $as_echo "$boot_jdk_jvmargs_big" >&6; }
50657 
50658   JAVA_FLAGS_BIG=$boot_jdk_jvmargs_big
50659 
50660 
50661 
50662   { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for small workloads" >&5
50663 $as_echo_n "checking flags for boot jdk java command for small workloads... " >&6; }
50664 
50665   # Use serial gc for small short lived tools if possible
50666 
50667   $ECHO "Check if jvm arg is ok: -XX:+UseSerialGC" >&5
50668   $ECHO "Command: $JAVA -XX:+UseSerialGC -version" >&5
50669   OUTPUT=`$JAVA -XX:+UseSerialGC -version 2>&1`
50670   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
50671   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
50672   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
50673     boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:+UseSerialGC"
50674     JVM_ARG_OK=true
50675   else
50676     $ECHO "Arg failed:" >&5
50677     $ECHO "$OUTPUT" >&5
50678     JVM_ARG_OK=false
50679   fi
50680 
50681 
50682   $ECHO "Check if jvm arg is ok: -Xms32M" >&5
50683   $ECHO "Command: $JAVA -Xms32M -version" >&5
50684   OUTPUT=`$JAVA -Xms32M -version 2>&1`
50685   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
50686   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
50687   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
50688     boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xms32M"
50689     JVM_ARG_OK=true
50690   else
50691     $ECHO "Arg failed:" >&5
50692     $ECHO "$OUTPUT" >&5
50693     JVM_ARG_OK=false
50694   fi
50695 
50696 
50697   $ECHO "Check if jvm arg is ok: -Xmx512M" >&5
50698   $ECHO "Command: $JAVA -Xmx512M -version" >&5
50699   OUTPUT=`$JAVA -Xmx512M -version 2>&1`
50700   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
50701   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
50702   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
50703     boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xmx512M"
50704     JVM_ARG_OK=true
50705   else
50706     $ECHO "Arg failed:" >&5
50707     $ECHO "$OUTPUT" >&5
50708     JVM_ARG_OK=false
50709   fi
50710 
50711 
50712   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_small" >&5
50713 $as_echo "$boot_jdk_jvmargs_small" >&6; }
50714 
50715   JAVA_FLAGS_SMALL=$boot_jdk_jvmargs_small
50716 
50717 
50718   JAVA_TOOL_FLAGS_SMALL=""
50719   for f in $JAVA_FLAGS_SMALL; do
50720     JAVA_TOOL_FLAGS_SMALL="$JAVA_TOOL_FLAGS_SMALL -J$f"
50721   done
50722 
50723 
50724 
50725 # Setup smart javac (after cores and memory have been setup)
50726 
50727 
50728 # Check whether --with-sjavac-server-java was given.
50729 if test "${with_sjavac_server_java+set}" = set; then :
50730   withval=$with_sjavac_server_java;
50731 fi
50732 
50733 
50734   if test "x$with_sjavac_server_java" != x; then
50735     SJAVAC_SERVER_JAVA="$with_sjavac_server_java"
50736     FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""`
50737     if test "x$FOUND_VERSION" = x; then
50738       as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5
50739     fi
50740   else
50741     SJAVAC_SERVER_JAVA="$JAVA"
50742   fi
50743 
50744 
50745   if test "$MEMORY_SIZE" -gt "3000"; then
50746 
50747   $ECHO "Check if jvm arg is ok: -d64" >&5
50748   $ECHO "Command: $SJAVAC_SERVER_JAVA -d64 -version" >&5
50749   OUTPUT=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1`
50750   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
50751   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
50752   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
50753     SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -d64"
50754     JVM_ARG_OK=true
50755   else
50756     $ECHO "Arg failed:" >&5
50757     $ECHO "$OUTPUT" >&5
50758     JVM_ARG_OK=false
50759   fi
50760 
50761     if test "$JVM_ARG_OK" = true; then
50762       JVM_64BIT=true
50763       JVM_ARG_OK=false
50764     fi
50765   fi
50766 
50767   MX_VALUE=`expr $MEMORY_SIZE / 2`
50768   if test "$JVM_64BIT" = true; then
50769     # Set ms lower than mx since more than one instance of the server might
50770     # get launched at the same time before they figure out which instance won.
50771     MS_VALUE=512
50772     if test "$MX_VALUE" -gt "2048"; then
50773       MX_VALUE=2048
50774     fi
50775   else
50776     MS_VALUE=256
50777     if test "$MX_VALUE" -gt "1500"; then
50778       MX_VALUE=1500
50779     fi
50780   fi
50781   if test "$MX_VALUE" -lt "512"; then
50782     MX_VALUE=512
50783   fi
50784 
50785   $ECHO "Check if jvm arg is ok: -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" >&5
50786   $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version" >&5
50787   OUTPUT=`$SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version 2>&1`
50788   FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn`
50789   FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""`
50790   if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then
50791     SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -Xms${MS_VALUE}M -Xmx${MX_VALUE}M"
50792     JVM_ARG_OK=true
50793   else
50794     $ECHO "Arg failed:" >&5
50795     $ECHO "$OUTPUT" >&5
50796     JVM_ARG_OK=false
50797   fi
50798 
50799 
50800 
50801   # Check whether --enable-sjavac was given.
50802 if test "${enable_sjavac+set}" = set; then :
50803   enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}"
50804 else
50805   ENABLE_SJAVAC='no'
50806 fi
50807 
50808   if test "x$JVM_ARG_OK" = "xfalse"; then
50809     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&5
50810 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&2;}
50811     ENABLE_SJAVAC=no;
50812   fi
50813   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5
50814 $as_echo_n "checking whether to use sjavac... " >&6; }
50815   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5
50816 $as_echo "$ENABLE_SJAVAC" >&6; }
50817 
50818 
50819   if test "x$ENABLE_SJAVAC" = xyes; then
50820     SJAVAC_SERVER_DIR="$OUTPUT_ROOT/javacservers"
50821   else
50822     SJAVAC_SERVER_DIR=
50823   fi
50824 
50825 
50826 
50827 # Can the C/C++ compiler use precompiled headers?
50828 
50829 
50830   ###############################################################################
50831   #
50832   # Can the C/C++ compiler use precompiled headers?
50833   #
50834   # Check whether --enable-precompiled-headers was given.
50835 if test "${enable_precompiled_headers+set}" = set; then :
50836   enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers}
50837 else
50838   ENABLE_PRECOMPH=yes
50839 fi
50840 
50841 
50842   USE_PRECOMPILED_HEADER=1
50843   if test "x$ENABLE_PRECOMPH" = xno; then
50844     USE_PRECOMPILED_HEADER=0
50845   fi
50846 
50847   if test "x$ENABLE_PRECOMPH" = xyes; then
50848     # Check that the compiler actually supports precomp headers.
50849     if test "x$TOOLCHAIN_TYPE" = xgcc; then
50850       { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5
50851 $as_echo_n "checking that precompiled headers work... " >&6; }
50852       echo "int alfa();" > conftest.h
50853       $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5
50854       if test ! -f conftest.hpp.gch; then
50855         USE_PRECOMPILED_HEADER=0
50856         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
50857 $as_echo "no" >&6; }
50858       else
50859         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
50860 $as_echo "yes" >&6; }
50861       fi
50862       rm -f conftest.h conftest.hpp.gch
50863     fi
50864   fi
50865 
50866 
50867 
50868 
50869 # Setup use of ccache, if available
50870 
50871   # Check whether --enable-ccache was given.
50872 if test "${enable_ccache+set}" = set; then :
50873   enableval=$enable_ccache;
50874 fi
50875 
50876 
50877   CCACHE=
50878   { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5
50879 $as_echo_n "checking is ccache enabled... " >&6; }
50880   ENABLE_CCACHE=$enable_ccache
50881   if test "x$enable_ccache" = xyes; then
50882     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
50883 $as_echo "yes" >&6; }
50884     OLD_PATH="$PATH"
50885     if test "x$TOOLCHAIN_PATH" != x; then
50886       PATH=$TOOLCHAIN_PATH:$PATH
50887     fi
50888 
50889 
50890 
50891   # Publish this variable in the help.
50892 
50893 
50894   if test "x$CCACHE" = x; then
50895     # The variable is not set by user, try to locate tool using the code snippet
50896     for ac_prog in ccache
50897 do
50898   # Extract the first word of "$ac_prog", so it can be a program name with args.
50899 set dummy $ac_prog; ac_word=$2
50900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
50901 $as_echo_n "checking for $ac_word... " >&6; }
50902 if ${ac_cv_path_CCACHE+:} false; then :
50903   $as_echo_n "(cached) " >&6
50904 else
50905   case $CCACHE in
50906   [\\/]* | ?:[\\/]*)
50907   ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
50908   ;;
50909   *)
50910   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
50911 for as_dir in $PATH
50912 do
50913   IFS=$as_save_IFS
50914   test -z "$as_dir" && as_dir=.
50915     for ac_exec_ext in '' $ac_executable_extensions; do
50916   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
50917     ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
50918     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
50919     break 2
50920   fi
50921 done
50922   done
50923 IFS=$as_save_IFS
50924 
50925   ;;
50926 esac
50927 fi
50928 CCACHE=$ac_cv_path_CCACHE
50929 if test -n "$CCACHE"; then
50930   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
50931 $as_echo "$CCACHE" >&6; }
50932 else
50933   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
50934 $as_echo "no" >&6; }
50935 fi
50936 
50937 
50938   test -n "$CCACHE" && break
50939 done
50940 
50941   else
50942     # The variable is set, but is it from the command line or the environment?
50943 
50944     # Try to remove the string !CCACHE! from our list.
50945     try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CCACHE!/}
50946     if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then
50947       # If it failed, the variable was not from the command line. Ignore it,
50948       # but warn the user (except for BASH, which is always set by the calling BASH).
50949       if test "xCCACHE" != xBASH; then
50950         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&5
50951 $as_echo "$as_me: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&2;}
50952       fi
50953       # Try to locate tool using the code snippet
50954       for ac_prog in ccache
50955 do
50956   # Extract the first word of "$ac_prog", so it can be a program name with args.
50957 set dummy $ac_prog; ac_word=$2
50958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
50959 $as_echo_n "checking for $ac_word... " >&6; }
50960 if ${ac_cv_path_CCACHE+:} false; then :
50961   $as_echo_n "(cached) " >&6
50962 else
50963   case $CCACHE in
50964   [\\/]* | ?:[\\/]*)
50965   ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
50966   ;;
50967   *)
50968   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
50969 for as_dir in $PATH
50970 do
50971   IFS=$as_save_IFS
50972   test -z "$as_dir" && as_dir=.
50973     for ac_exec_ext in '' $ac_executable_extensions; do
50974   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
50975     ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
50976     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
50977     break 2
50978   fi
50979 done
50980   done
50981 IFS=$as_save_IFS
50982 
50983   ;;
50984 esac
50985 fi
50986 CCACHE=$ac_cv_path_CCACHE
50987 if test -n "$CCACHE"; then
50988   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
50989 $as_echo "$CCACHE" >&6; }
50990 else
50991   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
50992 $as_echo "no" >&6; }
50993 fi
50994 
50995 
50996   test -n "$CCACHE" && break
50997 done
50998 
50999     else
51000       # If it succeeded, then it was overridden by the user. We will use it
51001       # for the tool.
51002 
51003       # First remove it from the list of overridden variables, so we can test
51004       # for unknown variables in the end.
51005       CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var"
51006 
51007       # Check if the provided tool contains a complete path.
51008       tool_specified="$CCACHE"
51009       tool_basename="${tool_specified##*/}"
51010       if test "x$tool_basename" = "x$tool_specified"; then
51011         # A command without a complete path is provided, search $PATH.
51012         { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CCACHE=$tool_basename" >&5
51013 $as_echo "$as_me: Will search for user supplied tool CCACHE=$tool_basename" >&6;}
51014         # Extract the first word of "$tool_basename", so it can be a program name with args.
51015 set dummy $tool_basename; ac_word=$2
51016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
51017 $as_echo_n "checking for $ac_word... " >&6; }
51018 if ${ac_cv_path_CCACHE+:} false; then :
51019   $as_echo_n "(cached) " >&6
51020 else
51021   case $CCACHE in
51022   [\\/]* | ?:[\\/]*)
51023   ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path.
51024   ;;
51025   *)
51026   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
51027 for as_dir in $PATH
51028 do
51029   IFS=$as_save_IFS
51030   test -z "$as_dir" && as_dir=.
51031     for ac_exec_ext in '' $ac_executable_extensions; do
51032   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
51033     ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext"
51034     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
51035     break 2
51036   fi
51037 done
51038   done
51039 IFS=$as_save_IFS
51040 
51041   ;;
51042 esac
51043 fi
51044 CCACHE=$ac_cv_path_CCACHE
51045 if test -n "$CCACHE"; then
51046   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5
51047 $as_echo "$CCACHE" >&6; }
51048 else
51049   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
51050 $as_echo "no" >&6; }
51051 fi
51052 
51053 
51054         if test "x$CCACHE" = x; then
51055           as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5
51056         fi
51057       else
51058         # Otherwise we believe it is a complete path. Use it as it is.
51059         { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CCACHE=$tool_specified" >&5
51060 $as_echo "$as_me: Will use user supplied tool CCACHE=$tool_specified" >&6;}
51061         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5
51062 $as_echo_n "checking for CCACHE... " >&6; }
51063         if test ! -x "$tool_specified"; then
51064           { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
51065 $as_echo "not found" >&6; }
51066           as_fn_error $? "User supplied tool CCACHE=$tool_specified does not exist or is not executable" "$LINENO" 5
51067         fi
51068         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5
51069 $as_echo "$tool_specified" >&6; }
51070       fi
51071     fi
51072   fi
51073 
51074 
51075 
51076   if test "x$CCACHE" = x; then
51077     as_fn_error $? "Could not find required tool for CCACHE" "$LINENO" 5
51078   fi
51079 
51080 
51081     CCACHE_STATUS="enabled"
51082     PATH="$OLD_PATH"
51083   elif test "x$enable_ccache" = xno; then
51084     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, explicitly disabled" >&5
51085 $as_echo "no, explicitly disabled" >&6; }
51086   elif test "x$enable_ccache" = x; then
51087     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
51088 $as_echo "no" >&6; }
51089   else
51090     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5
51091 $as_echo "unknown" >&6; }
51092     as_fn_error $? "--enable-ccache does not accept any parameters" "$LINENO" 5
51093   fi
51094 
51095 
51096 
51097 # Check whether --with-ccache-dir was given.
51098 if test "${with_ccache_dir+set}" = set; then :
51099   withval=$with_ccache_dir;
51100 fi
51101 
51102 
51103   if test "x$with_ccache_dir" != x; then
51104     # When using a non home ccache directory, assume the use is to share ccache files
51105     # with other users. Thus change the umask.
51106     SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002"
51107     if test "x$CCACHE" = x; then
51108       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&5
51109 $as_echo "$as_me: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&2;}
51110     fi
51111   fi
51112 
51113   if test "x$CCACHE" != x; then
51114 
51115   if test "x$CCACHE" != x; then
51116     # Only use ccache if it is 3.1.4 or later, which supports
51117     # precompiled headers.
51118     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ccache supports precompiled headers" >&5
51119 $as_echo_n "checking if ccache supports precompiled headers... " >&6; }
51120     HAS_GOOD_CCACHE=`($CCACHE --version | head -n 1 | grep -E 3.1.[456789]) 2> /dev/null`
51121     if test "x$HAS_GOOD_CCACHE" = x; then
51122       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabling ccache" >&5
51123 $as_echo "no, disabling ccache" >&6; }
51124       CCACHE=
51125       CCACHE_STATUS="disabled"
51126     else
51127       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
51128 $as_echo "yes" >&6; }
51129       { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5
51130 $as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; }
51131       PUSHED_FLAGS="$CXXFLAGS"
51132       CXXFLAGS="-fpch-preprocess $CXXFLAGS"
51133       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
51134 /* end confdefs.h.  */
51135 
51136 int
51137 main ()
51138 {
51139 
51140   ;
51141   return 0;
51142 }
51143 _ACEOF
51144 if ac_fn_cxx_try_compile "$LINENO"; then :
51145   CC_KNOWS_CCACHE_TRICK=yes
51146 else
51147   CC_KNOWS_CCACHE_TRICK=no
51148 fi
51149 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
51150       CXXFLAGS="$PUSHED_FLAGS"
51151       if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then
51152         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
51153 $as_echo "yes" >&6; }
51154       else
51155         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, disabling ccaching of precompiled headers" >&5
51156 $as_echo "no, disabling ccaching of precompiled headers" >&6; }
51157         CCACHE=
51158         CCACHE_STATUS="disabled"
51159       fi
51160     fi
51161   fi
51162 
51163   if test "x$CCACHE" != x; then
51164     CCACHE_SLOPPINESS=time_macros
51165     CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS $CCACHE"
51166     CCACHE_FLAGS=-fpch-preprocess
51167 
51168     if test "x$SET_CCACHE_DIR" != x; then
51169       mkdir -p $CCACHE_DIR > /dev/null 2>&1
51170       chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1
51171     fi
51172   fi
51173 
51174   fi
51175 
51176 
51177 ###############################################################################
51178 #
51179 # And now the finish...
51180 #
51181 ###############################################################################
51182 
51183 # Check for some common pitfalls
51184 
51185   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
51186     file_to_test="$SRC_ROOT/LICENSE"
51187     if test `$STAT -c '%a' "$file_to_test"` -lt 400; then
51188       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
51189     fi
51190   fi
51191 
51192 
51193   # Did user specify any unknown variables?
51194 
51195   if test "x$CONFIGURE_OVERRIDDEN_VARIABLES" != x; then
51196     # Replace the separating ! with spaces before presenting for end user.
51197     unknown_variables=${CONFIGURE_OVERRIDDEN_VARIABLES//!/ }
51198     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The following variables might be unknown to configure: $unknown_variables" >&5
51199 $as_echo "$as_me: WARNING: The following variables might be unknown to configure: $unknown_variables" >&2;}
51200   fi
51201 
51202 
51203   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5
51204 $as_echo_n "checking if build directory is on local disk... " >&6; }
51205 
51206   # df -l lists only local disks; if the given directory is not found then
51207   # a non-zero exit code is given
51208   if test "x$DF" = x; then
51209     if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
51210       # msys does not have df; use Windows "net use" instead.
51211       IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:`
51212       if test "x$IS_NETWORK_DISK" = x; then
51213         OUTPUT_DIR_IS_LOCAL="yes"
51214       else
51215         OUTPUT_DIR_IS_LOCAL="no"
51216       fi
51217     else
51218       # No df here, say it's local
51219       OUTPUT_DIR_IS_LOCAL="yes"
51220     fi
51221   else
51222     if $DF -l $OUTPUT_ROOT > /dev/null 2>&1; then
51223       OUTPUT_DIR_IS_LOCAL="yes"
51224     else
51225       OUTPUT_DIR_IS_LOCAL="no"
51226     fi
51227   fi
51228 
51229   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5
51230 $as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; }
51231 
51232 
51233 
51234   # Check if the user has any old-style ALT_ variables set.
51235   FOUND_ALT_VARIABLES=`env | grep ^ALT_`
51236 
51237   # Before generating output files, test if they exist. If they do, this is a reconfigure.
51238   # Since we can't properly handle the dependencies for this, warn the user about the situation
51239   if test -e $OUTPUT_ROOT/spec.gmk; then
51240     IS_RECONFIGURE=yes
51241   else
51242     IS_RECONFIGURE=no
51243   fi
51244 
51245 
51246 # At the end, call the custom hook. (Dummy macro if no custom sources available)
51247 
51248 
51249 # We're messing a bit with internal autoconf variables to put the config.status
51250 # in the output directory instead of the current directory.
51251 CONFIG_STATUS="$OUTPUT_ROOT/config.status"
51252 
51253 # Create the actual output files. Now the main work of configure is done.
51254 cat >confcache <<\_ACEOF
51255 # This file is a shell script that caches the results of configure
51256 # tests run on this system so they can be shared between configure
51257 # scripts and configure runs, see configure's option --config-cache.
51258 # It is not useful on other systems.  If it contains results you don't
51259 # want to keep, you may remove or edit it.
51260 #
51261 # config.status only pays attention to the cache file if you give it
51262 # the --recheck option to rerun configure.
51263 #
51264 # `ac_cv_env_foo' variables (set or unset) will be overridden when
51265 # loading this file, other *unset* `ac_cv_foo' will be assigned the
51266 # following values.
51267 
51268 _ACEOF
51269 
51270 # The following way of writing the cache mishandles newlines in values,
51271 # but we know of no workaround that is simple, portable, and efficient.
51272 # So, we kill variables containing newlines.
51273 # Ultrix sh set writes to stderr and can't be redirected directly,
51274 # and sets the high bit in the cache file unless we assign to the vars.
51275 (
51276   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
51277     eval ac_val=\$$ac_var
51278     case $ac_val in #(
51279     *${as_nl}*)
51280       case $ac_var in #(
51281       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
51282 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
51283       esac
51284       case $ac_var in #(
51285       _ | IFS | as_nl) ;; #(
51286       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
51287       *) { eval $ac_var=; unset $ac_var;} ;;
51288       esac ;;
51289     esac
51290   done
51291 
51292   (set) 2>&1 |
51293     case $as_nl`(ac_space=' '; set) 2>&1` in #(
51294     *${as_nl}ac_space=\ *)
51295       # `set' does not quote correctly, so add quotes: double-quote
51296       # substitution turns \\\\ into \\, and sed turns \\ into \.
51297       sed -n \
51298         "s/'/'\\\\''/g;
51299           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
51300       ;; #(
51301     *)
51302       # `set' quotes correctly as required by POSIX, so do not add quotes.
51303       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
51304       ;;
51305     esac |
51306     sort
51307 ) |
51308   sed '
51309      /^ac_cv_env_/b end
51310      t clear
51311      :clear
51312      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
51313      t end
51314      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
51315      :end' >>confcache
51316 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
51317   if test -w "$cache_file"; then
51318     if test "x$cache_file" != "x/dev/null"; then
51319       { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
51320 $as_echo "$as_me: updating cache $cache_file" >&6;}
51321       if test ! -f "$cache_file" || test -h "$cache_file"; then
51322         cat confcache >"$cache_file"
51323       else
51324         case $cache_file in #(
51325         */* | ?:*)
51326           mv -f confcache "$cache_file"$$ &&
51327           mv -f "$cache_file"$$ "$cache_file" ;; #(
51328         *)
51329           mv -f confcache "$cache_file" ;;
51330         esac
51331       fi
51332     fi
51333   else
51334     { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
51335 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
51336   fi
51337 fi
51338 rm -f confcache
51339 
51340 test "x$prefix" = xNONE && prefix=$ac_default_prefix
51341 # Let make expand exec_prefix.
51342 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
51343 
51344 # Transform confdefs.h into DEFS.
51345 # Protect against shell expansion while executing Makefile rules.
51346 # Protect against Makefile macro expansion.
51347 #
51348 # If the first sed substitution is executed (which looks for macros that
51349 # take arguments), then branch to the quote section.  Otherwise,
51350 # look for a macro that doesn't take arguments.
51351 ac_script='
51352 :mline
51353 /\\$/{
51354  N
51355  s,\\\n,,
51356  b mline
51357 }
51358 t clear
51359 :clear
51360 s/^[     ]*#[    ]*define[       ][      ]*\([^  (][^    (]*([^)]*)\)[   ]*\(.*\)/-D\1=\2/g
51361 t quote
51362 s/^[     ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)/-D\1=\2/g
51363 t quote
51364 b any
51365 :quote
51366 s/[      `~#$^&*(){}\\|;'\''"<>?]/\\&/g
51367 s/\[/\\&/g
51368 s/\]/\\&/g
51369 s/\$/$$/g
51370 H
51371 :any
51372 ${
51373         g
51374         s/^\n//
51375         s/\n/ /g
51376         p
51377 }
51378 '
51379 DEFS=`sed -n "$ac_script" confdefs.h`
51380 
51381 
51382 ac_libobjs=
51383 ac_ltlibobjs=
51384 U=
51385 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
51386   # 1. Remove the extension, and $U if already installed.
51387   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
51388   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
51389   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
51390   #    will be set to the directory where LIBOBJS objects are built.
51391   as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
51392   as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
51393 done
51394 LIBOBJS=$ac_libobjs
51395 
51396 LTLIBOBJS=$ac_ltlibobjs
51397 
51398 
51399 
51400 : "${CONFIG_STATUS=./config.status}"
51401 ac_write_fail=0
51402 ac_clean_files_save=$ac_clean_files
51403 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
51404 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
51405 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
51406 as_write_fail=0
51407 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
51408 #! $SHELL
51409 # Generated by $as_me.
51410 # Run this file to recreate the current configuration.
51411 # Compiler output produced by configure, useful for debugging
51412 # configure, is in config.log if it exists.
51413 
51414 debug=false
51415 ac_cs_recheck=false
51416 ac_cs_silent=false
51417 
51418 SHELL=\${CONFIG_SHELL-$SHELL}
51419 export SHELL
51420 _ASEOF
51421 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
51422 ## -------------------- ##
51423 ## M4sh Initialization. ##
51424 ## -------------------- ##
51425 
51426 # Be more Bourne compatible
51427 DUALCASE=1; export DUALCASE # for MKS sh
51428 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
51429   emulate sh
51430   NULLCMD=:
51431   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
51432   # is contrary to our usage.  Disable this feature.
51433   alias -g '${1+"$@"}'='"$@"'
51434   setopt NO_GLOB_SUBST
51435 else
51436   case `(set -o) 2>/dev/null` in #(
51437   *posix*) :
51438     set -o posix ;; #(
51439   *) :
51440      ;;
51441 esac
51442 fi
51443 
51444 
51445 as_nl='
51446 '
51447 export as_nl
51448 # Printing a long string crashes Solaris 7 /usr/bin/printf.
51449 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
51450 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
51451 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
51452 # Prefer a ksh shell builtin over an external printf program on Solaris,
51453 # but without wasting forks for bash or zsh.
51454 if test -z "$BASH_VERSION$ZSH_VERSION" \
51455     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
51456   as_echo='print -r --'
51457   as_echo_n='print -rn --'
51458 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
51459   as_echo='printf %s\n'
51460   as_echo_n='printf %s'
51461 else
51462   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
51463     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
51464     as_echo_n='/usr/ucb/echo -n'
51465   else
51466     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
51467     as_echo_n_body='eval
51468       arg=$1;
51469       case $arg in #(
51470       *"$as_nl"*)
51471         expr "X$arg" : "X\\(.*\\)$as_nl";
51472         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
51473       esac;
51474       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
51475     '
51476     export as_echo_n_body
51477     as_echo_n='sh -c $as_echo_n_body as_echo'
51478   fi
51479   export as_echo_body
51480   as_echo='sh -c $as_echo_body as_echo'
51481 fi
51482 
51483 # The user is always right.
51484 if test "${PATH_SEPARATOR+set}" != set; then
51485   PATH_SEPARATOR=:
51486   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
51487     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
51488       PATH_SEPARATOR=';'
51489   }
51490 fi
51491 
51492 
51493 # IFS
51494 # We need space, tab and new line, in precisely that order.  Quoting is
51495 # there to prevent editors from complaining about space-tab.
51496 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
51497 # splitting by setting IFS to empty value.)
51498 IFS=" ""        $as_nl"
51499 
51500 # Find who we are.  Look in the path if we contain no directory separator.
51501 as_myself=
51502 case $0 in #((
51503   *[\\/]* ) as_myself=$0 ;;
51504   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
51505 for as_dir in $PATH
51506 do
51507   IFS=$as_save_IFS
51508   test -z "$as_dir" && as_dir=.
51509     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
51510   done
51511 IFS=$as_save_IFS
51512 
51513      ;;
51514 esac
51515 # We did not find ourselves, most probably we were run as `sh COMMAND'
51516 # in which case we are not to be found in the path.
51517 if test "x$as_myself" = x; then
51518   as_myself=$0
51519 fi
51520 if test ! -f "$as_myself"; then
51521   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
51522   exit 1
51523 fi
51524 
51525 # Unset variables that we do not need and which cause bugs (e.g. in
51526 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
51527 # suppresses any "Segmentation fault" message there.  '((' could
51528 # trigger a bug in pdksh 5.2.14.
51529 for as_var in BASH_ENV ENV MAIL MAILPATH
51530 do eval test x\${$as_var+set} = xset \
51531   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
51532 done
51533 PS1='$ '
51534 PS2='> '
51535 PS4='+ '
51536 
51537 # NLS nuisances.
51538 LC_ALL=C
51539 export LC_ALL
51540 LANGUAGE=C
51541 export LANGUAGE
51542 
51543 # CDPATH.
51544 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
51545 
51546 
51547 # as_fn_error STATUS ERROR [LINENO LOG_FD]
51548 # ----------------------------------------
51549 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
51550 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
51551 # script with STATUS, using 1 if that was 0.
51552 as_fn_error ()
51553 {
51554   as_status=$1; test $as_status -eq 0 && as_status=1
51555   if test "$4"; then
51556     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
51557     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
51558   fi
51559   $as_echo "$as_me: error: $2" >&2
51560   as_fn_exit $as_status
51561 } # as_fn_error
51562 
51563 
51564 # as_fn_set_status STATUS
51565 # -----------------------
51566 # Set $? to STATUS, without forking.
51567 as_fn_set_status ()
51568 {
51569   return $1
51570 } # as_fn_set_status
51571 
51572 # as_fn_exit STATUS
51573 # -----------------
51574 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
51575 as_fn_exit ()
51576 {
51577   set +e
51578   as_fn_set_status $1
51579   exit $1
51580 } # as_fn_exit
51581 
51582 # as_fn_unset VAR
51583 # ---------------
51584 # Portably unset VAR.
51585 as_fn_unset ()
51586 {
51587   { eval $1=; unset $1;}
51588 }
51589 as_unset=as_fn_unset
51590 # as_fn_append VAR VALUE
51591 # ----------------------
51592 # Append the text in VALUE to the end of the definition contained in VAR. Take
51593 # advantage of any shell optimizations that allow amortized linear growth over
51594 # repeated appends, instead of the typical quadratic growth present in naive
51595 # implementations.
51596 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
51597   eval 'as_fn_append ()
51598   {
51599     eval $1+=\$2
51600   }'
51601 else
51602   as_fn_append ()
51603   {
51604     eval $1=\$$1\$2
51605   }
51606 fi # as_fn_append
51607 
51608 # as_fn_arith ARG...
51609 # ------------------
51610 # Perform arithmetic evaluation on the ARGs, and store the result in the
51611 # global $as_val. Take advantage of shells that can avoid forks. The arguments
51612 # must be portable across $(()) and expr.
51613 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
51614   eval 'as_fn_arith ()
51615   {
51616     as_val=$(( $* ))
51617   }'
51618 else
51619   as_fn_arith ()
51620   {
51621     as_val=`expr "$@" || test $? -eq 1`
51622   }
51623 fi # as_fn_arith
51624 
51625 
51626 if expr a : '\(a\)' >/dev/null 2>&1 &&
51627    test "X`expr 00001 : '.*\(...\)'`" = X001; then
51628   as_expr=expr
51629 else
51630   as_expr=false
51631 fi
51632 
51633 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
51634   as_basename=basename
51635 else
51636   as_basename=false
51637 fi
51638 
51639 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
51640   as_dirname=dirname
51641 else
51642   as_dirname=false
51643 fi
51644 
51645 as_me=`$as_basename -- "$0" ||
51646 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
51647          X"$0" : 'X\(//\)$' \| \
51648          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
51649 $as_echo X/"$0" |
51650     sed '/^.*\/\([^/][^/]*\)\/*$/{
51651             s//\1/
51652             q
51653           }
51654           /^X\/\(\/\/\)$/{
51655             s//\1/
51656             q
51657           }
51658           /^X\/\(\/\).*/{
51659             s//\1/
51660             q
51661           }
51662           s/.*/./; q'`
51663 
51664 # Avoid depending upon Character Ranges.
51665 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
51666 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
51667 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
51668 as_cr_digits='0123456789'
51669 as_cr_alnum=$as_cr_Letters$as_cr_digits
51670 
51671 ECHO_C= ECHO_N= ECHO_T=
51672 case `echo -n x` in #(((((
51673 -n*)
51674   case `echo 'xy\c'` in
51675   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
51676   xy)  ECHO_C='\c';;
51677   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
51678        ECHO_T=' ';;
51679   esac;;
51680 *)
51681   ECHO_N='-n';;
51682 esac
51683 
51684 rm -f conf$$ conf$$.exe conf$$.file
51685 if test -d conf$$.dir; then
51686   rm -f conf$$.dir/conf$$.file
51687 else
51688   rm -f conf$$.dir
51689   mkdir conf$$.dir 2>/dev/null
51690 fi
51691 if (echo >conf$$.file) 2>/dev/null; then
51692   if ln -s conf$$.file conf$$ 2>/dev/null; then
51693     as_ln_s='ln -s'
51694     # ... but there are two gotchas:
51695     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
51696     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
51697     # In both cases, we have to default to `cp -pR'.
51698     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
51699       as_ln_s='cp -pR'
51700   elif ln conf$$.file conf$$ 2>/dev/null; then
51701     as_ln_s=ln
51702   else
51703     as_ln_s='cp -pR'
51704   fi
51705 else
51706   as_ln_s='cp -pR'
51707 fi
51708 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
51709 rmdir conf$$.dir 2>/dev/null
51710 
51711 
51712 # as_fn_mkdir_p
51713 # -------------
51714 # Create "$as_dir" as a directory, including parents if necessary.
51715 as_fn_mkdir_p ()
51716 {
51717 
51718   case $as_dir in #(
51719   -*) as_dir=./$as_dir;;
51720   esac
51721   test -d "$as_dir" || eval $as_mkdir_p || {
51722     as_dirs=
51723     while :; do
51724       case $as_dir in #(
51725       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
51726       *) as_qdir=$as_dir;;
51727       esac
51728       as_dirs="'$as_qdir' $as_dirs"
51729       as_dir=`$as_dirname -- "$as_dir" ||
51730 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
51731          X"$as_dir" : 'X\(//\)[^/]' \| \
51732          X"$as_dir" : 'X\(//\)$' \| \
51733          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
51734 $as_echo X"$as_dir" |
51735     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
51736             s//\1/
51737             q
51738           }
51739           /^X\(\/\/\)[^/].*/{
51740             s//\1/
51741             q
51742           }
51743           /^X\(\/\/\)$/{
51744             s//\1/
51745             q
51746           }
51747           /^X\(\/\).*/{
51748             s//\1/
51749             q
51750           }
51751           s/.*/./; q'`
51752       test -d "$as_dir" && break
51753     done
51754     test -z "$as_dirs" || eval "mkdir $as_dirs"
51755   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
51756 
51757 
51758 } # as_fn_mkdir_p
51759 if mkdir -p . 2>/dev/null; then
51760   as_mkdir_p='mkdir -p "$as_dir"'
51761 else
51762   test -d ./-p && rmdir ./-p
51763   as_mkdir_p=false
51764 fi
51765 
51766 
51767 # as_fn_executable_p FILE
51768 # -----------------------
51769 # Test if FILE is an executable regular file.
51770 as_fn_executable_p ()
51771 {
51772   test -f "$1" && test -x "$1"
51773 } # as_fn_executable_p
51774 as_test_x='test -x'
51775 as_executable_p=as_fn_executable_p
51776 
51777 # Sed expression to map a string onto a valid CPP name.
51778 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
51779 
51780 # Sed expression to map a string onto a valid variable name.
51781 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
51782 
51783 
51784 exec 6>&1
51785 ## ----------------------------------- ##
51786 ## Main body of $CONFIG_STATUS script. ##
51787 ## ----------------------------------- ##
51788 _ASEOF
51789 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
51790 
51791 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
51792 # Save the log message, to keep $0 and so on meaningful, and to
51793 # report actual input values of CONFIG_FILES etc. instead of their
51794 # values after options handling.
51795 ac_log="
51796 This file was extended by OpenJDK $as_me jdk9, which was
51797 generated by GNU Autoconf 2.69.  Invocation command line was
51798 
51799   CONFIG_FILES    = $CONFIG_FILES
51800   CONFIG_HEADERS  = $CONFIG_HEADERS
51801   CONFIG_LINKS    = $CONFIG_LINKS
51802   CONFIG_COMMANDS = $CONFIG_COMMANDS
51803   $ $0 $@
51804 
51805 on `(hostname || uname -n) 2>/dev/null | sed 1q`
51806 "
51807 
51808 _ACEOF
51809 
51810 case $ac_config_files in *"
51811 "*) set x $ac_config_files; shift; ac_config_files=$*;;
51812 esac
51813 
51814 
51815 
51816 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
51817 # Files that config.status was made for.
51818 config_files="$ac_config_files"
51819 
51820 _ACEOF
51821 
51822 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
51823 ac_cs_usage="\
51824 \`$as_me' instantiates files and other configuration actions
51825 from templates according to the current configuration.  Unless the files
51826 and actions are specified as TAGs, all are instantiated by default.
51827 
51828 Usage: $0 [OPTION]... [TAG]...
51829 
51830   -h, --help       print this help, then exit
51831   -V, --version    print version number and configuration settings, then exit
51832       --config     print configuration, then exit
51833   -q, --quiet, --silent
51834                    do not print progress messages
51835   -d, --debug      don't remove temporary files
51836       --recheck    update $as_me by reconfiguring in the same conditions
51837       --file=FILE[:TEMPLATE]
51838                    instantiate the configuration file FILE
51839 
51840 Configuration files:
51841 $config_files
51842 
51843 Report bugs to <build-dev@openjdk.java.net>.
51844 OpenJDK home page: <http://openjdk.java.net>."
51845 
51846 _ACEOF
51847 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
51848 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
51849 ac_cs_version="\\
51850 OpenJDK config.status jdk9
51851 configured by $0, generated by GNU Autoconf 2.69,
51852   with options \\"\$ac_cs_config\\"
51853 
51854 Copyright (C) 2012 Free Software Foundation, Inc.
51855 This config.status script is free software; the Free Software Foundation
51856 gives unlimited permission to copy, distribute and modify it."
51857 
51858 ac_pwd='$ac_pwd'
51859 srcdir='$srcdir'
51860 AWK='$AWK'
51861 test -n "\$AWK" || AWK=awk
51862 _ACEOF
51863 
51864 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
51865 # The default lists apply if the user does not specify any file.
51866 ac_need_defaults=:
51867 while test $# != 0
51868 do
51869   case $1 in
51870   --*=?*)
51871     ac_option=`expr "X$1" : 'X\([^=]*\)='`
51872     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
51873     ac_shift=:
51874     ;;
51875   --*=)
51876     ac_option=`expr "X$1" : 'X\([^=]*\)='`
51877     ac_optarg=
51878     ac_shift=:
51879     ;;
51880   *)
51881     ac_option=$1
51882     ac_optarg=$2
51883     ac_shift=shift
51884     ;;
51885   esac
51886 
51887   case $ac_option in
51888   # Handling of the options.
51889   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
51890     ac_cs_recheck=: ;;
51891   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
51892     $as_echo "$ac_cs_version"; exit ;;
51893   --config | --confi | --conf | --con | --co | --c )
51894     $as_echo "$ac_cs_config"; exit ;;
51895   --debug | --debu | --deb | --de | --d | -d )
51896     debug=: ;;
51897   --file | --fil | --fi | --f )
51898     $ac_shift
51899     case $ac_optarg in
51900     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
51901     '') as_fn_error $? "missing file argument" ;;
51902     esac
51903     as_fn_append CONFIG_FILES " '$ac_optarg'"
51904     ac_need_defaults=false;;
51905   --he | --h |  --help | --hel | -h )
51906     $as_echo "$ac_cs_usage"; exit ;;
51907   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
51908   | -silent | --silent | --silen | --sile | --sil | --si | --s)
51909     ac_cs_silent=: ;;
51910 
51911   # This is an error.
51912   -*) as_fn_error $? "unrecognized option: \`$1'
51913 Try \`$0 --help' for more information." ;;
51914 
51915   *) as_fn_append ac_config_targets " $1"
51916      ac_need_defaults=false ;;
51917 
51918   esac
51919   shift
51920 done
51921 
51922 ac_configure_extra_args=
51923 
51924 if $ac_cs_silent; then
51925   exec 6>/dev/null
51926   ac_configure_extra_args="$ac_configure_extra_args --silent"
51927 fi
51928 
51929 _ACEOF
51930 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
51931 if \$ac_cs_recheck; then
51932   set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
51933   shift
51934   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
51935   CONFIG_SHELL='$SHELL'
51936   export CONFIG_SHELL
51937   exec "\$@"
51938 fi
51939 
51940 _ACEOF
51941 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
51942 exec 5>>config.log
51943 {
51944   echo
51945   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
51946 ## Running $as_me. ##
51947 _ASBOX
51948   $as_echo "$ac_log"
51949 } >&5
51950 
51951 _ACEOF
51952 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
51953 _ACEOF
51954 
51955 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
51956 
51957 # Handling of arguments.
51958 for ac_config_target in $ac_config_targets
51959 do
51960   case $ac_config_target in
51961     "$OUTPUT_ROOT/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;;
51962     "$OUTPUT_ROOT/hotspot-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in" ;;
51963     "$OUTPUT_ROOT/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;;
51964     "$OUTPUT_ROOT/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;;
51965     "$OUTPUT_ROOT/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" ;;
51966 
51967   *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
51968   esac
51969 done
51970 
51971 
51972 # If the user did not use the arguments to specify the items to instantiate,
51973 # then the envvar interface is used.  Set only those that are not.
51974 # We use the long form for the default assignment because of an extremely
51975 # bizarre bug on SunOS 4.1.3.
51976 if $ac_need_defaults; then
51977   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
51978 fi
51979 
51980 # Have a temporary directory for convenience.  Make it in the build tree
51981 # simply because there is no reason against having it here, and in addition,
51982 # creating and moving files from /tmp can sometimes cause problems.
51983 # Hook for its removal unless debugging.
51984 # Note that there is a small window in which the directory will not be cleaned:
51985 # after its creation but before its name has been assigned to `$tmp'.
51986 $debug ||
51987 {
51988   tmp= ac_tmp=
51989   trap 'exit_status=$?
51990   : "${ac_tmp:=$tmp}"
51991   { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
51992 ' 0
51993   trap 'as_fn_exit 1' 1 2 13 15
51994 }
51995 # Create a (secure) tmp directory for tmp files.
51996 
51997 {
51998   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
51999   test -d "$tmp"
52000 }  ||
52001 {
52002   tmp=./conf$$-$RANDOM
52003   (umask 077 && mkdir "$tmp")
52004 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
52005 ac_tmp=$tmp
52006 
52007 # Set up the scripts for CONFIG_FILES section.
52008 # No need to generate them if there are no CONFIG_FILES.
52009 # This happens for instance with `./config.status config.h'.
52010 if test -n "$CONFIG_FILES"; then
52011 
52012 
52013 ac_cr=`echo X | tr X '\015'`
52014 # On cygwin, bash can eat \r inside `` if the user requested igncr.
52015 # But we know of no other shell where ac_cr would be empty at this
52016 # point, so we can use a bashism as a fallback.
52017 if test "x$ac_cr" = x; then
52018   eval ac_cr=\$\'\\r\'
52019 fi
52020 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
52021 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
52022   ac_cs_awk_cr='\\r'
52023 else
52024   ac_cs_awk_cr=$ac_cr
52025 fi
52026 
52027 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
52028 _ACEOF
52029 
52030 
52031 {
52032   echo "cat >conf$$subs.awk <<_ACEOF" &&
52033   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
52034   echo "_ACEOF"
52035 } >conf$$subs.sh ||
52036   as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
52037 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
52038 ac_delim='%!_!# '
52039 for ac_last_try in false false false false false :; do
52040   . ./conf$$subs.sh ||
52041     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
52042 
52043   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
52044   if test $ac_delim_n = $ac_delim_num; then
52045     break
52046   elif $ac_last_try; then
52047     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
52048   else
52049     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
52050   fi
52051 done
52052 rm -f conf$$subs.sh
52053 
52054 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
52055 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
52056 _ACEOF
52057 sed -n '
52058 h
52059 s/^/S["/; s/!.*/"]=/
52060 p
52061 g
52062 s/^[^!]*!//
52063 :repl
52064 t repl
52065 s/'"$ac_delim"'$//
52066 t delim
52067 :nl
52068 h
52069 s/\(.\{148\}\)..*/\1/
52070 t more1
52071 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
52072 p
52073 n
52074 b repl
52075 :more1
52076 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
52077 p
52078 g
52079 s/.\{148\}//
52080 t nl
52081 :delim
52082 h
52083 s/\(.\{148\}\)..*/\1/
52084 t more2
52085 s/["\\]/\\&/g; s/^/"/; s/$/"/
52086 p
52087 b
52088 :more2
52089 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
52090 p
52091 g
52092 s/.\{148\}//
52093 t delim
52094 ' <conf$$subs.awk | sed '
52095 /^[^""]/{
52096   N
52097   s/\n//
52098 }
52099 ' >>$CONFIG_STATUS || ac_write_fail=1
52100 rm -f conf$$subs.awk
52101 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
52102 _ACAWK
52103 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
52104   for (key in S) S_is_set[key] = 1
52105   FS = ""
52106 
52107 }
52108 {
52109   line = $ 0
52110   nfields = split(line, field, "@")
52111   substed = 0
52112   len = length(field[1])
52113   for (i = 2; i < nfields; i++) {
52114     key = field[i]
52115     keylen = length(key)
52116     if (S_is_set[key]) {
52117       value = S[key]
52118       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
52119       len += length(value) + length(field[++i])
52120       substed = 1
52121     } else
52122       len += 1 + keylen
52123   }
52124 
52125   print line
52126 }
52127 
52128 _ACAWK
52129 _ACEOF
52130 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
52131 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
52132   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
52133 else
52134   cat
52135 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
52136   || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
52137 _ACEOF
52138 
52139 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
52140 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
52141 # trailing colons and then remove the whole line if VPATH becomes empty
52142 # (actually we leave an empty line to preserve line numbers).
52143 if test "x$srcdir" = x.; then
52144   ac_vpsub='/^[  ]*VPATH[        ]*=[    ]*/{
52145 h
52146 s///
52147 s/^/:/
52148 s/[      ]*$/:/
52149 s/:\$(srcdir):/:/g
52150 s/:\${srcdir}:/:/g
52151 s/:@srcdir@:/:/g
52152 s/^:*//
52153 s/:*$//
52154 x
52155 s/\(=[   ]*\).*/\1/
52156 G
52157 s/\n//
52158 s/^[^=]*=[       ]*$//
52159 }'
52160 fi
52161 
52162 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
52163 fi # test -n "$CONFIG_FILES"
52164 
52165 
52166 eval set X "  :F $CONFIG_FILES      "
52167 shift
52168 for ac_tag
52169 do
52170   case $ac_tag in
52171   :[FHLC]) ac_mode=$ac_tag; continue;;
52172   esac
52173   case $ac_mode$ac_tag in
52174   :[FHL]*:*);;
52175   :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
52176   :[FH]-) ac_tag=-:-;;
52177   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
52178   esac
52179   ac_save_IFS=$IFS
52180   IFS=:
52181   set x $ac_tag
52182   IFS=$ac_save_IFS
52183   shift
52184   ac_file=$1
52185   shift
52186 
52187   case $ac_mode in
52188   :L) ac_source=$1;;
52189   :[FH])
52190     ac_file_inputs=
52191     for ac_f
52192     do
52193       case $ac_f in
52194       -) ac_f="$ac_tmp/stdin";;
52195       *) # Look for the file first in the build tree, then in the source tree
52196          # (if the path is not absolute).  The absolute path cannot be DOS-style,
52197          # because $ac_f cannot contain `:'.
52198          test -f "$ac_f" ||
52199            case $ac_f in
52200            [\\/$]*) false;;
52201            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
52202            esac ||
52203            as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
52204       esac
52205       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
52206       as_fn_append ac_file_inputs " '$ac_f'"
52207     done
52208 
52209     # Let's still pretend it is `configure' which instantiates (i.e., don't
52210     # use $as_me), people would be surprised to read:
52211     #    /* config.h.  Generated by config.status.  */
52212     configure_input='Generated from '`
52213           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
52214         `' by configure.'
52215     if test x"$ac_file" != x-; then
52216       configure_input="$ac_file.  $configure_input"
52217       { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
52218 $as_echo "$as_me: creating $ac_file" >&6;}
52219     fi
52220     # Neutralize special characters interpreted by sed in replacement strings.
52221     case $configure_input in #(
52222     *\&* | *\|* | *\\* )
52223        ac_sed_conf_input=`$as_echo "$configure_input" |
52224        sed 's/[\\\\&|]/\\\\&/g'`;; #(
52225     *) ac_sed_conf_input=$configure_input;;
52226     esac
52227 
52228     case $ac_tag in
52229     *:-:* | *:-) cat >"$ac_tmp/stdin" \
52230       || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
52231     esac
52232     ;;
52233   esac
52234 
52235   ac_dir=`$as_dirname -- "$ac_file" ||
52236 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
52237          X"$ac_file" : 'X\(//\)[^/]' \| \
52238          X"$ac_file" : 'X\(//\)$' \| \
52239          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
52240 $as_echo X"$ac_file" |
52241     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
52242             s//\1/
52243             q
52244           }
52245           /^X\(\/\/\)[^/].*/{
52246             s//\1/
52247             q
52248           }
52249           /^X\(\/\/\)$/{
52250             s//\1/
52251             q
52252           }
52253           /^X\(\/\).*/{
52254             s//\1/
52255             q
52256           }
52257           s/.*/./; q'`
52258   as_dir="$ac_dir"; as_fn_mkdir_p
52259   ac_builddir=.
52260 
52261 case "$ac_dir" in
52262 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
52263 *)
52264   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
52265   # A ".." for each directory in $ac_dir_suffix.
52266   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
52267   case $ac_top_builddir_sub in
52268   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
52269   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
52270   esac ;;
52271 esac
52272 ac_abs_top_builddir=$ac_pwd
52273 ac_abs_builddir=$ac_pwd$ac_dir_suffix
52274 # for backward compatibility:
52275 ac_top_builddir=$ac_top_build_prefix
52276 
52277 case $srcdir in
52278   .)  # We are building in place.
52279     ac_srcdir=.
52280     ac_top_srcdir=$ac_top_builddir_sub
52281     ac_abs_top_srcdir=$ac_pwd ;;
52282   [\\/]* | ?:[\\/]* )  # Absolute name.
52283     ac_srcdir=$srcdir$ac_dir_suffix;
52284     ac_top_srcdir=$srcdir
52285     ac_abs_top_srcdir=$srcdir ;;
52286   *) # Relative name.
52287     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
52288     ac_top_srcdir=$ac_top_build_prefix$srcdir
52289     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
52290 esac
52291 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
52292 
52293 
52294   case $ac_mode in
52295   :F)
52296   #
52297   # CONFIG_FILE
52298   #
52299 
52300 _ACEOF
52301 
52302 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
52303 # If the template does not know about datarootdir, expand it.
52304 # FIXME: This hack should be removed a few years after 2.60.
52305 ac_datarootdir_hack=; ac_datarootdir_seen=
52306 ac_sed_dataroot='
52307 /datarootdir/ {
52308   p
52309   q
52310 }
52311 /@datadir@/p
52312 /@docdir@/p
52313 /@infodir@/p
52314 /@localedir@/p
52315 /@mandir@/p'
52316 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
52317 *datarootdir*) ac_datarootdir_seen=yes;;
52318 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
52319   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
52320 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
52321 _ACEOF
52322 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
52323   ac_datarootdir_hack='
52324   s&@datadir@&$datadir&g
52325   s&@docdir@&$docdir&g
52326   s&@infodir@&$infodir&g
52327   s&@localedir@&$localedir&g
52328   s&@mandir@&$mandir&g
52329   s&\\\${datarootdir}&$datarootdir&g' ;;
52330 esac
52331 _ACEOF
52332 
52333 # Neutralize VPATH when `$srcdir' = `.'.
52334 # Shell code in configure.ac might set extrasub.
52335 # FIXME: do we really want to maintain this feature?
52336 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
52337 ac_sed_extra="$ac_vpsub
52338 $extrasub
52339 _ACEOF
52340 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
52341 :t
52342 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
52343 s|@configure_input@|$ac_sed_conf_input|;t t
52344 s&@top_builddir@&$ac_top_builddir_sub&;t t
52345 s&@top_build_prefix@&$ac_top_build_prefix&;t t
52346 s&@srcdir@&$ac_srcdir&;t t
52347 s&@abs_srcdir@&$ac_abs_srcdir&;t t
52348 s&@top_srcdir@&$ac_top_srcdir&;t t
52349 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
52350 s&@builddir@&$ac_builddir&;t t
52351 s&@abs_builddir@&$ac_abs_builddir&;t t
52352 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
52353 $ac_datarootdir_hack
52354 "
52355 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
52356   >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
52357 
52358 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
52359   { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
52360   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' \
52361       "$ac_tmp/out"`; test -z "$ac_out"; } &&
52362   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
52363 which seems to be undefined.  Please make sure it is defined" >&5
52364 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
52365 which seems to be undefined.  Please make sure it is defined" >&2;}
52366 
52367   rm -f "$ac_tmp/stdin"
52368   case $ac_file in
52369   -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
52370   *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
52371   esac \
52372   || as_fn_error $? "could not create $ac_file" "$LINENO" 5
52373  ;;
52374 
52375 
52376 
52377   esac
52378 
52379 done # for ac_tag
52380 
52381 
52382 as_fn_exit 0
52383 _ACEOF
52384 ac_clean_files=$ac_clean_files_save
52385 
52386 test $ac_write_fail = 0 ||
52387   as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
52388 
52389 
52390 # configure is writing to config.log, and then calls config.status.
52391 # config.status does its own redirection, appending to config.log.
52392 # Unfortunately, on DOS this fails, as config.log is still kept open
52393 # by configure, so config.status won't be able to write to it; its
52394 # output is simply discarded.  So we exec the FD to /dev/null,
52395 # effectively closing config.log, so it can be properly (re)opened and
52396 # appended to by config.status.  When coming back to configure, we
52397 # need to make the FD available again.
52398 if test "$no_create" != yes; then
52399   ac_cs_success=:
52400   ac_config_status_args=
52401   test "$silent" = yes &&
52402     ac_config_status_args="$ac_config_status_args --quiet"
52403   exec 5>/dev/null
52404   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
52405   exec 5>>config.log
52406   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
52407   # would make configure fail if this is the last instruction.
52408   $ac_cs_success || as_fn_exit 1
52409 fi
52410 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
52411   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
52412 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
52413 fi
52414 
52415 
52416 # Try to move the config.log file to the output directory.
52417 if test -e ./config.log; then
52418   $MV -f ./config.log "$OUTPUT_ROOT/config.log" 2> /dev/null
52419 fi
52420 
52421 # Make the compare script executable
52422 $CHMOD +x $OUTPUT_ROOT/compare.sh
52423 
52424 # Finally output some useful information to the user
52425 
52426   # Finally output some useful information to the user
52427 
52428   printf "\n"
52429   printf "====================================================\n"
52430   if test "x$no_create" != "xyes"; then
52431     if test "x$IS_RECONFIGURE" != "xyes"; then
52432       printf "A new configuration has been successfully created in\n%s\n" "$OUTPUT_ROOT"
52433     else
52434       printf "The existing configuration has been successfully updated in\n%s\n" "$OUTPUT_ROOT"
52435     fi
52436   else
52437     if test "x$IS_RECONFIGURE" != "xyes"; then
52438       printf "A configuration has been successfully checked but not created\n"
52439     else
52440       printf "The existing configuration has been successfully checked in\n%s\n" "$OUTPUT_ROOT"
52441     fi
52442   fi
52443   if test "x$CONFIGURE_COMMAND_LINE" != x; then
52444     printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n"
52445   else
52446     printf "using default settings.\n"
52447   fi
52448 
52449   printf "\n"
52450   printf "Configuration summary:\n"
52451   printf "* Debug level:    $DEBUG_LEVEL\n"
52452   printf "* HS debug level: $HOTSPOT_DEBUG_LEVEL\n"
52453   printf "* JDK variant:    $JDK_VARIANT\n"
52454   printf "* JVM variants:   $with_jvm_variants\n"
52455   printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n"
52456 
52457   printf "\n"
52458   printf "Tools summary:\n"
52459   if test "x$OPENJDK_BUILD_OS" = "xwindows"; then
52460     printf "* Environment:    $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n"
52461   fi
52462   printf "* Boot JDK:       $BOOT_JDK_VERSION (at $BOOT_JDK)\n"
52463   printf "* Toolchain:      $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)\n"
52464   printf "* C Compiler:     Version $CC_VERSION_NUMBER (at $CC)\n"
52465   printf "* C++ Compiler:   Version $CXX_VERSION_NUMBER (at $CXX)\n"
52466 
52467   printf "\n"
52468   printf "Build performance summary:\n"
52469   printf "* Cores to use:   $JOBS\n"
52470   printf "* Memory limit:   $MEMORY_SIZE MB\n"
52471   if test "x$CCACHE_STATUS" != "x"; then
52472     printf "* ccache status:  $CCACHE_STATUS\n"
52473   fi
52474   printf "\n"
52475 
52476   if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xyes"; then
52477     printf "NOTE: You have requested to build more than one version of the JVM, which\n"
52478     printf "will result in longer build times.\n"
52479     printf "\n"
52480   fi
52481 
52482   if test "x$FOUND_ALT_VARIABLES" != "x"; then
52483     printf "WARNING: You have old-style ALT_ environment variables set.\n"
52484     printf "These are not respected, and will be ignored. It is recommended\n"
52485     printf "that you clean your environment. The following variables are set:\n"
52486     printf "$FOUND_ALT_VARIABLES\n"
52487     printf "\n"
52488   fi
52489 
52490   if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then
52491     printf "WARNING: Your build output directory is not on a local disk.\n"
52492     printf "This will severely degrade build performance!\n"
52493     printf "It is recommended that you create an output directory on a local disk,\n"
52494     printf "and run the configure script again from that directory.\n"
52495     printf "\n"
52496   fi
52497 
52498   if test "x$IS_RECONFIGURE" = "xyes" && test "x$no_create" != "xyes"; then
52499     printf "WARNING: The result of this configuration has overridden an older\n"
52500     printf "configuration. You *should* run 'make clean' to make sure you get a\n"
52501     printf "proper build. Failure to do so might result in strange build problems.\n"
52502     printf "\n"
52503   fi
52504 
52505   if test "x$IS_RECONFIGURE" != "xyes" && test "x$no_create" = "xyes"; then
52506     printf "WARNING: The result of this configuration was not saved.\n"
52507     printf "You should run without '--no-create | -n' to create the configuration.\n"
52508     printf "\n"
52509   fi
52510 
52511 
52512 
52513 if test -e "$OUTPUT_ROOT/config.log"; then
52514   $GREP '^configure:.*: WARNING:' "$OUTPUT_ROOT/config.log" > /dev/null 2>&1
52515   if test $? -eq 0; then
52516     printf "The following warnings were produced. Repeated here for convenience:\n"
52517     # We must quote sed expression (using []) to stop m4 from eating the [].
52518     $GREP '^configure:.*: WARNING:' "$OUTPUT_ROOT/config.log" | $SED -e  's/^configure:[0-9]*: //'
52519     printf "\n"
52520   fi
52521 fi
52522 
52523